@import url('./fonts.css');
@import url('./form.css');

* {
    margin: 0;
    padding: 0;
    border: 0;
    font: inherit;
    vertical-align: baseline;
    list-style-type: none;
    text-decoration: none;
    box-shadow: none;
    outline: none;
}

html {
    font-size: 62%;
}

body {
    font-family: 'Noto Sans', sans-serif;
    font-weight: 400;

    display: flex;
    flex-direction: column;
    overflow-x: hidden;

    --main-1: rgba(255, 234, 203, 1);
    --main-2: rgba(255, 208, 152, 1);
    --main-3: rgba(255, 178, 102, 1);
    --main-4: rgba(255, 146, 63, 1);
    --main-5: rgba(254, 94, 0, 1);
    --main-6: rgba(218, 68, 0, 1);
    --main-7: rgba(183, 45, 0, 1);
    --main-8: rgba(147, 28, 0, 1);
    --main-9: rgba(121, 15, 0, 1);

    --second-0: rgba(250, 254, 255, 1);
    --second-1: rgba(238, 246, 248, 1);
    --second-2: rgba(223, 236, 242, 1);
    --second-3: rgba(192, 209, 217, 1);
    --second-4: rgba(154, 171, 181, 1);
    --second-5: rgba(108, 122, 135, 1);
    --second-6: rgba(78, 96, 116, 1);
    --second-7: rgba(54, 72, 96, 1);
    --second-8: rgba(34, 51, 77, 1);
    --second-9: rgba(20, 34, 64, 1);
    --second-1: rgba(0, 0, 0, 1);

    --grey-1: rgba(249, 249, 249, 1);
    --grey-2: rgba(237, 237, 237, 1);
    --grey-3: rgba(201, 201, 201, 1);
    --grey-4: rgba(148, 148, 148, 1);
    --grey-5: rgba(78, 78, 78, 1);
    --grey-6: rgba(67, 57, 57, 1);
    --grey-7: rgba(56, 39, 42, 1);
    --grey-8: rgba(45, 24, 30, 1);
    --grey-9: rgba(0, 0, 0, 1);

    --danger-1: rgba(250, 232, 222, 1);
    --danger-2: rgba(245, 204, 190, 1);
    --danger-3: rgba(238, 170, 155, 1);
    --danger-4: rgba(230, 137, 130, 1);
    --danger-5: rgba(221, 95, 95, 1);
    --danger-6: rgba(189, 72, 82, 1);
    --danger-7: rgba(158, 53, 72, 1);
    --danger-8: rgba(127, 37, 61, 1);
    --danger-9: rgba(104, 26, 54, 1);

    --color-orange: rgba(254, 94, 0, 1);
    --color-grey: rgba(108, 122, 135, 1);
    --color-green: rgba(79, 174, 128, 1);
    --color-blue: rgba(9, 197, 244, 1);
    --color-yellow: rgba(255, 220, 46, 1);
    --color-pink: rgba(255, 94, 102, 1);
    --color-purple: rgba(151, 71, 255, 1);
}

#wizard h3 {
    margin-bottom: 3rem;
}

#wizard .btn {
    display: block;
    text-align: center;
    margin: 1rem 0;
}

body.show_menu {
    max-height: 100vh;
    overflow: hidden;
}

ul {
    margin-bottom: 1rem;
}

p,
a,
ul li,
ol li,
pre {
    font-size: 1.5rem;
    color: var(--second-7);
}

b, strong {
    font-weight: bold;
}

em {
    font-style: italic;
}

pre {
    overflow: auto;
    background-color: var(--second-8);
    border-radius: 1rem;
    padding: 1rem;
    margin-bottom: 1rem;
}

pre code {
    color: var(--grey-1);
    font-size: 1.3rem;
}

ul li,
ol li {
    margin-left: 2rem;
    list-style-type: disc;
}

ol li {
    list-style-type: decimal;
}

ul li ul li {
    list-style-type: circle;
}

ul li ul li ul li {
    list-style-type: square;
}

p {
    margin-bottom: 1rem;
}

p > b {
    font-weight: bold;
}

p > i {
    vertical-align: middle;
    margin-right: 1rem;
}

code {
    color: var(--second-7);
    font-family: monospace;
}

p>a:not(.btn),
ul:not(.tabs)>li>a,
table tr td a:not(.btn):hover,
form div span.supporting a,
label>a {
    text-decoration: underline;
    color: var(--main-5);
}

content {
    display: flex;
    box-sizing: border-box;
    gap: 3rem;
    min-height: calc(100vh - 11rem);
}

body.welcome content {
    min-height: calc(100vh - 18rem);
    align-items: center;
    margin: 0 auto;
    max-width: 1024px;
}

@media screen and (max-width: 800px) {
    body.welcome content {
        min-height: calc(100vh - 16rem);
    }
}

hr {
    border-bottom: 1px solid var(--grey-3);
    margin: 2rem 0;
}

hr.clear {
    clear: both;
    border-bottom: none;
}

a.permalink {
    margin-left: 1rem;
}

/** Tabs **/

ul.tabs {
    display: flex;
    flex-direction: row;
    flex-wrap: wrap;
    border-bottom: 2px solid var(--grey-2);
    margin-bottom: 2rem;
    width: 100%;
}

ul.tabs li {
    font-weight: 800;
    color: var(--main-6);
    border-bottom: 2px solid transparent;
    list-style-type: none;
    line-height: 4rem;
    font-size: 3rem;
    margin: 0 1rem;
    margin-bottom: -2px;
    opacity: 0.5;
}

ul.tabs li a {
    display: block;
    white-space: nowrap;
}

ul.tabs li.current,
ul.tabs li:hover {
    opacity: 1;
}

ul.tabs li:first-child {
    margin-left: 0;
}

ul.tabs li:last-child {
    margin-right: 0;
}

ul.tabs li.current {
    border-color: var(--main-5);
}

/** Header **/

header nav {
    padding: 3rem 1rem;
    display: flex;
    min-height: 5rem;
}

header nav a {
    display: flex;
    align-items: center;
    padding: 0 2rem;
    line-height: 4rem;
    color: var(--second-5);
}

header nav a i {
    margin-right: 1rem;
    font-size: 2.5rem;
}

header nav a#logo {
    font-weight: 700;
    padding-left: 2rem;
}

header nav a#menu {
    color: var(--main-5);
}

header nav a#menu:after {
    display: block;
    font-family: 'Phosphor';
    content: "\e2f0";
    font-size: 3rem;
}

body.show_menu header nav a#menu:after {
    font-family: 'Phosphor'

    header nav a#logo {
        position: absolute;
        left: calc(50% - 1.5rem);
        top: 1.5rem;
        padding: 0;
    }
}

header nav a#logo::before {
    content: '';
    width: 3rem;
    height: 3rem;
    padding: 1rem;
    background-image: url('../img/logo.svg');
    background-color: var(--main-5);
    background-size: 3rem;
    background-position: center;
    background-repeat: no-repeat;
    display: block;
    border-radius: 1rem;
    box-shadow: 0 0 2rem rgba(0, 0, 0, 0.2);
    margin-right: 2rem;
}

header nav a.oppose {
    margin-left: auto;
}

header nav a.oppose~a.oppose {
    margin-left: 0;
}

header nav span.badge {
    margin-left: 1rem;
}

@media screen and (max-width: 800px) {
    header nav {
        padding: 1rem;
    }

    header nav a,
    header nav a#logo {
        padding: 1rem;
    }

    header nav a#logo::before {
        margin-right: 0;
    }

    header nav a i {
        margin-right: 0;
    }
}

/** Section **/

content section {
    margin: 0 auto;
    max-width: 1024px;
    padding: 1rem;
    box-sizing: border-box;
}

content:has(section.documentation) {
    margin: 0;
}

content section.documentation {
    max-width: calc(100% - 35rem);
    margin: 0;
    margin-left: 35rem;
}

@media screen and (max-width: 800px) {
    content section.documentation {
        max-width: 100%;
        margin-left: 0;
    }
}

form section {
    margin: initial;
    max-width: initial;
    padding: 0;
    grid-column: 1 / 3;
}

.grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1.5rem;
}

.grid .card {
    margin: 0;
}

.grid.third {
    grid-template-columns: repeat(3, 1fr);
}

@media screen and (max-width: 800px) {
    .grid {
        display: block;
    }

    .grid.third {
        grid-template-columns: repeat(2, 1fr);
    }
}

.grid header,
.grid .large {
    grid-column: span 2;
}

.grid.third header,
.grid.third .large {
    grid-column: span 3;
}

.grid.third .mid {
    grid-column: span 2;
}

content section header {
    display: flex;
    gap: 1rem;
    align-items: center;
    margin-bottom: 3rem;
    flex-flow: wrap;
}

content section header p {
    margin-bottom: 0;
}

content section header form {
    display: inline-block;
}

content section header>*.oppose {
    margin-left: auto;
}

content nav+section {
    min-width: calc(80% - 20rem);
    margin-bottom: 4rem;
}

@media screen and (max-width: 800px) {
    content nav+section {
        min-width: 100%;
    }
}

/** Sidenav **/

content>nav {
    background-color: var(--main-5);
    width: 20rem;
    margin-left: 0;
    padding: 5rem 1.5rem;
    padding-bottom: 10rem;
    border-radius: 0 3rem 0 0;
    background-size: auto 10rem;
    background-position: bottom center;
    background-repeat: repeat-x;
    background-image: url('../img/footer.svg');

    z-index: 1;
}

content>nav a {
    color: white;
    font-weight: 600;
    font-size: 1.75rem;
    display: flex;
    align-items: center;
    line-height: 5rem;
    margin: 0.5rem 0;
    position: relative;
    white-space: nowrap;
    padding: 0 1.5rem;
    overflow: hidden;
}

content>nav a:first-child {
    margin-top: 0;
}

content>nav a.current {
    background-color: white;
    border-radius: 4rem;
    color: var(--main-5);
    box-shadow: 0 0 0.5rem rgba(0, 0, 0, 0.2);
}

content>nav a i {
    margin-right: 1rem;
    font-size: 2rem;
}

@media screen and (max-width: 800px) {
    content>nav {
        width: 100%;
        position: absolute;
        min-height: 100vh;
        max-height: 100%;
        overflow-y: scroll;
        box-sizing: border-box;
        border-radius: 0;
        padding-top: 2rem;

        transition: transform 0.5s ease-in-out;
        transform: translateX(-100%);
    }

    content>nav a {
        margin-left: 0;
    }

    content>nav a.current:after {
        display: none;
    }

    body.show_menu content>nav {
        transform: translateX(0);
    }
}

/** Footer **/

body.welcome::after {
    background-position: top center;
    background-repeat: repeat-x;
    background-image: url('../img/footer.svg');
    display: block;
    height: 10rem;
    width: 100%;
    background-size: 51rem;
    content: '';
    height: 5rem;
    margin-top: 2rem;
}

/** Titles **/

h1 {
    font-size: 3.5rem;
    line-height: 4rem;
    font-weight: 800;
    color: var(--second-6);
    display: flex;
    align-items: center;
    margin-right: 1rem;
    margin-bottom: 1rem;
}

header>h1 {
    margin-bottom: 0;
}

h1 i {
    font-size: 3rem;
    min-width: 3rem;
    margin-right: 1rem;
}

h2 {
    font-size: 2.25rem;
    min-width: 2.25rem;
    font-weight: 800;
    padding: 1rem 0;
    color: var(--second-7);
}

h2 i {
    font-size: 2rem;
    margin-right: 1rem;
}

h3 {
    font-size: 1.75rem;
    color: var(--second-6);
    padding: 0.5rem 0;
    padding-bottom: 1rem;
    margin-bottom: 0.5rem;
    font-weight: bold;
    border-bottom: 1px solid var(--grey-2);
}

h3 > i {
    line-height: 2rem;
    margin-right: 1rem;
    vertical-align: middle;
}

h4 {
    font-size: 1.6rem;
    color: var(--second-9);
    padding: 0.5rem 0;
}

p+h1,
p+h2,
p+h3,
p+h4,
ul+h1,
ul+h2,
ul+h3,
ul+h4,
h3+p {
    margin-top: 1rem;
}

h3+p:has(span.badge) {
    margin-top: 0;
}

.line {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

/** Badge **/

.badge {
    background-color: var(--grey-4);
    color: white;
    border-radius: 0.5rem;
    font-weight: 700;
    line-height: 2.25rem;
    font-size: 1.25rem;
    padding: 0 1.25rem;
    vertical-align: bottom;
    display: inline-block;
}

.badge.oppose {
    float: right;
}

h3 .badge {
    margin-left: 1rem;
}

h3 .badge + .badge {
    margin-left: 0;
}

.badge.badge-info {
    background-color: var(--color-blue);
}

.badge.badge-success {
    background-color: var(--color-green);
}

.badge.badge-warning {
    background-color: var(--color-yellow);
}

.badge.badge-error {
    background-color: var(--color-pink);
}

.badge.badge-message {
    background-color: var(--color-purple);
}

/** Table **/

table {
    border-collapse: collapse;
    width: 100%;
}

h3 + table {
    margin-top: -0.5rem;
}

table tr td a {
    display: inline-block;
}

table tr td,
table tr th {
    width: 20rem;
    padding: 1rem;
    font-size: 1.5rem;
    vertical-align: middle;
}

table tr td form {
    display: block;
}

.card table tr td:first-child,
.card table tr th:first-child {
    padding-left: 0;
}

table tr:not(.empty) th.actions,
table tr:not(.empty) td.actions {
    text-align: right;
}

.card table tr:not(.empty) th.actions,
.card table tr:not(.empty) td.actions {
    padding-right: 0;
}


table tr th {
    padding: 0 1rem;
    line-height: 4rem;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

table tr td.line,
table tr th.line {
    max-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

table tr th,
table tr th a {
    text-transform: uppercase;
    font-weight: 600;
    color: var(--second-4);
    text-align: left;
}

table tr th a i {
    font-size: 2.5rem;
    vertical-align: middle;
}

table thead {
    border-bottom: 1px solid var(--grey-2);
}

table tr:nth-child(2n) {
    background-color: var(--grey-1);
}

table tr.empty {
    background-color: var(--grey-2);
    text-align: center;
    color: var(--second-4);
}

table tr.empty td {
    font-size: 2rem;
    padding-bottom: 9rem;
}

table tr.empty td:before {
    content: '\e602';
    font-family: 'Phosphor';
    font-size: 8rem;
    color: var(--second-4);
    display: block;
    text-align: center;
    margin: 9rem;
    margin-bottom: 1rem;
    line-height: 8rem;
}

/* Display/hide */

.on_mobile {
    display: none !important;
}

.on_mobile_after:after {
    display: none !important;
}

@media screen and (max-width: 800px) {

    .on_mobile,
    .on_mobile_after:after {
        display: inherit !important;
    }

    .on_mobile.material-icons-outlined {
        display: inline !important;
    }

    .on_desktop {
        display: none !important;
    }
}

/** Chips **/

.chip {
    display: inline-block;
    line-height: 2.5rem;
    padding: 0 1rem;
}

.chip i {
    margin: 0;
}

.chip.selected {
    font-weight: bold;
}

/** Pagination **/

ul.pagination {
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: center;
    margin: 1rem 0;
}

ul.pagination li {
    display: block;
}

ul.pagination li .page-link {
    font-size: 1.6rem;
    padding: 0.5rem;
    line-height: 2rem;
    border-radius: 2rem;
    margin: 0 0.5rem;
    text-align: center;
    min-width: 2rem;
    display: block;
    border: 1px solid transparent;
}

ul.pagination li:not(.disabled).active .page-link {
    color: white;
    background-color: var(--main-5);
}

ul.pagination li:not(.disabled) .page-link {
    color: var(--main-5);
}

ul.pagination li:not(.disabled):not(.active) .page-link:hover {
    background-color: var(--main-1);
}

ul.pagination li:not(.disabled) .page-link:hover {
    border-color: var(--main-5);
}

/** List Toggle */

select.list_toggle {
    display: none;
}

/** Specific elements */

.table-of-contents {
    max-width: 33rem;
    max-height: calc(100vh - 19rem);
    overflow-y: scroll;
    position: fixed;
    top: 11rem;
    left: 0;
    padding: 2rem;
    box-sizing: border-box;
    background-color: var(--grey-1);
    border-radius: 0 1rem 1rem 0;
}

@media screen and (max-width: 800px) {
    .table-of-contents {
        display: none;
    }
}

.card {
    background-color: var(--grey-1);
    border-radius: 1rem;
    padding: 1.5rem;
    box-sizing: border-box;
    margin-bottom: 1rem;
    overflow: hidden;
}

.card .icon {
    font-size: 3rem;
    color: var(--second-6);
}

.disabled {
    opacity: 0.3;
    pointer-events: none;
}

.crossed {
    text-decoration: line-through;
}

.chart {
    min-height: 80vh;
}

/** Breadcrumb **/

.breadcrumb {
    margin-bottom: 2rem;
}

.breadcrumb li {
    display: inline-block;
    font-size: 1.5rem;
    line-height: 2rem;
    margin-left: 0;
}

.breadcrumb li a {
    color: var(--main-5);
}

.breadcrumb li.active {
    color: var(--grey-5);
}

.breadcrumb li+li:before {
    content: ">";
    margin: 0 1rem;
    font-size: 1rem;
    line-height: 2rem;
    display: inline-block;
}

/* Progress */

progress {
    width: 100%;
    border-radius: 2rem;
}

progress::-webkit-progress-bar,
progress::-moz-progress-bar {
    background-color: var(--color-green);
}

progress.yellow::-webkit-progress-bar,
progress.yellow::-moz-progress-bar {
    background-color: var(--color-yellow);
}

progress.orange::-webkit-progress-bar,
progress.orange::-moz-progress-bar {
    background-color: var(--color-orange);
}

/* Steps */

ol.steps {
    counter-reset: css-counter 0;
    padding-top: 6.5rem;
}

ol.steps li {
    counter-increment: css-counter 1;
    display: inline-block;
    position: relative;
    font-weight: 600;
    color: var(--grey-5);
}

ol.steps li+li {
    margin-left: 9rem;
}

ol.steps li+li:after {
    display: block;
    border-top: 1px solid var(--grey-3);
    content: "";
    width: 7rem;
    position: absolute;
    top: -3rem;
    left: -8rem;
}

ol.steps li:before {
    content: counter(css-counter);
    display: block;
    font-size: 2rem;
    font-weight: 300;
    border-radius: 3rem;
    line-height: 5rem;
    width: 5rem;
    text-align: center;
    border: 1px solid var(--grey-3);
    position: absolute;
    left: calc(50% - 2.5rem - 1px);
    bottom: 3rem;
}

ol.steps li.active:before {
    background-color: var(--main-5);
    border-color: var(--main-5);
    color: white;
}

/** Show/hide toggle **/

details > summary::before {
    content: "▶";
    color: var(--grey-4);
    font-size: 1.5rem;
    line-height: 4rem;
    padding: 0 1rem;
    float: right;
}

details[open] > summary::before {
    content: "▼";
}

details > summary:hover {
    cursor: pointer;
}

/** Small **/

small {
    display: block;
    font-weight: 300;
    color: var(--second-6);
    font-size: 1.25rem;
    margin-top: 0.25rem;
}

small a {
    font-size: 1.25rem;
}

small.error {
    color: var(--danger-6);
}
