/* Page */

/* Page z-indices:
   - 0: background
   - 3: bottom layer
   - 5: main layer
   - 7: upper layer
   - 9: mobile
   - 10: top bar
   - 17: popup
*/

/* Breakpoints (max-width):
    - xs: 0px
    - sm: 400px
    - md: 700px
    - lg: 1100px
    - xl: 1700px
*/

/* Theme defaults */
:root {
    /* Update design/components.php to load the fonts through GoogleFonts. */
    --regular-font: 'Roboto', sans-serif;
    --header-font: 'Roboto Slab', sans-serif;

    --font-size-small: 12px;
    --font-size-regular: 14px;
    --font-size-large: 18px;

    --input-height-regular: 40px;
    --input-height-small: calc(0.8 * var(--input-height-regular));
    --button-radius-ratio: 0;

    --border-radius: 2px;
    --spacing: 4px;

    --palette-background: black;
    --palette-background-paper: white;
    --palette-background-input: rgb(208, 243, 243);
    --palette-background-divider: powderblue;
    --palette-background-dim-1: mintcream;
    --palette-background-dim-2: powderblue;
    --palette-background-text: black;

    --palette-primary-bright: lightblue;
    --palette-primary-main: steelblue;
    --palette-primary-dim: rgb(51, 72, 90);
    --palette-primary-text: white;

    --palette-secondary-bright: #EBEBEB;
    --palette-secondary-main: #ADADAD;
    --palette-secondary-text: #888888;

    --palette-action-disabled: #ADADAD;
    --palette-action-selected: #888888;

    --palette-error-text: #D12F19;
    --palette-error-main: #F8E0DD;

    --palette-warning-text: #D19219;
    --palette-warning-main: #F8F2DD;

    --palette-info-text: #038CA0;
    --palette-info-main: #D9EEF1;

    --palette-success-text: #00A131;
    --palette-success-main: #D9F1E0;

    --palette-attendee-main: rgb(192, 192, 192);
    --palette-attendee-text: black;
    --palette-sponsor-main: #e09c2a;
    --palette-sponsor-text: white;
    --palette-supersponsor-main: #b676d6;
    --palette-supersponsor-text: white;
    --palette-orgateam-main: rgb(197, 69, 44);
    --palette-orgateam-text: white;
    --palette-minor-main: #3261a9;
    --palette-minor-text: white;

    --shadow-regular: 0px 3px 8px rgba(0, 0, 0, 0.25);
    --shadow-regular-length: 11px;

    --layer-bottom: 3;
    --layer-main: 5;
    --layer-upper: 7;
    --layer-top-bar: 10;
    --layer-popup: 20;
}

/* Page defaults */
body {
    --header-height: 80px;
    --header-desktop-visibility-hint: visible;
    --header-mobile-visibility-hint: hidden;

    position: relative;
    font-family: var(--regular-font);
    font-size: var(--font-size-regular);
    padding: 0px;
    margin: 0px;
    min-width: 300px;
    color: var(--palette-background-text);
    overflow-y: scroll;
    background-color: var(--palette-background);
}
    body.mobile {
        --header-height: 60px;
        --header-desktop-visibility-hint: hidden;
        --header-mobile-visibility-hint: visible;
    }
    @media screen and (max-width: 700px) {
        body {
            --header-height: 60px;
            --header-desktop-visibility-hint: hidden;
            --header-mobile-visibility-hint: visible;
        }
    }

#body-background {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: black url("test/background.jpg") center top / contain no-repeat;
}
    @media screen and (max-width: 700px) {
        #body-background {
            background: black url("test/background.jpg") center top / 140% auto no-repeat;
        }
    }

* {
    background-repeat: no-repeat;
    background-position: center center;
}

.hidden {
    display: none !important;
}

.collapsed {
    position: absolute;
    top: 0;
    left: 0;
    width: 1px !important;
    height: 1px !important;
    overflow: hidden !important;
    pointer-events: none !important;
}

.invisible {
    visibility: hidden;
}

p.error {
    color: var(--palette-error-text);
}

.scroll-container-y {
    position: relative;
    overflow: hidden;
    height: auto;
}
    .scroll-container-y.scroll {
        overflow-y: scroll;
    }
    .scroll-container-y > div {
        display: block;
        position: relative;
        height: auto;
    }

.gap {
    z-index: 0;
    visibility: hidden;
    pointer-events: none;
}

.popup-background {
    position: fixed;
    display: none;
    width: 100vw;
    height: 100vh;
    pointer-events: auto;
    background-color: var(--palette-background);
    opacity: 0.5;
}

/* User classes */
.userAttendee {
    color: var(--palette-background-paper);
    background-color: var(--palette-attendee-main);
    border-color: var(--palette-attendee-main);
}
    .userAttendee.inline {
        color: var(--palette-attendee-main);
        background: none;
    }

.userSponsor {
    color: var(--palette-background-paper);
    background-color: var(--palette-sponsor-main);
    border-color: var(--palette-sponsor-main);
}
    .userSponsor.inline {
        color: var(--palette-sponsor-main);
        background: none;
    }

.userSuper {
    color: var(--palette-background-paper);
    background-color: var(--palette-supersponsor-main);
    border-color: var(--palette-supersponsor-main);
}
    .userSuper.inline {
        color: var(--palette-supersponsor-main);
        background: none;
    }

.userOrga {
    color: var(--palette-background-paper);
    background-color: var(--palette-orgateam-main);
    border-color: var(--palette-orgateam-main);
}
    .userOrga.inline {
        color: var(--palette-orgateam-main);
        background: none;
    }

.minor {
    color: var(--palette-background-paper);
    background-color: var(--palette-minor-main);
}
    .minor.inline {
        color: var(--palette-minor-main);
        background: none;
    }


/* User classes */
.role {
    position: absolute;
    width: 16px;
    height: 20px;
    right: 4px;
    bottom: 4px;
    color: var(--palette-background-text);
    background-color: transparent;
    background-repeat: no-repeat;
    background-position: right bottom;
    background-size: contain;
    text-align: center;
    vertical-align: middle;
    font-family: monospace;
    font-size: 20px;
    font-weight: bold;
    line-height: 100%;
    cursor: default;
}

.role-icon {
    background-color: transparent;
    background-repeat: no-repeat;
    background-position: right bottom;
    background-size: contain;
}

.roleConOps {
    width: 16px;
    background-image: url('gfx-2020/style/role-conops.svg');
}

.roleStaff {
    width: 16px;
    background-image: url('gfx-2020/style/role-staff.svg');
}

.roleSecurity {
    width: 13px;
    background-image: url('gfx-2020/style/role-security.svg');
}

.roleMedic {
    width: 16px;
    background-image: url('gfx-2020/style/role-medic.svg');
}

.roleGoH {
    width: 16px;
    background-image: url('gfx-2020/style/role-goh.svg');
}


/* Admin box */
#page-admin-box {
    position: absolute;
    top: 0;
    right: 0;
    padding-left: calc(2 * var(--spacing));
    padding-right: calc(1 * var(--spacing));
    padding-top: calc(1 * var(--spacing));
    padding-bottom: calc(1 * var(--spacing));

    background-color: var(--palette-background-dim-1);
    border-bottom-left-radius: var(--border-radius);
    border-left: 1px solid var(--palette-background-divider);
    border-bottom: 1px solid var(--palette-background-divider);
    overflow: hidden;

    display: flex;
    flex-direction: row;
    gap: calc(2 * var(--spacing));
    align-items: center;
}
    #page-admin-access-label {
        font-size: 80%;
        opacity: 0.6;
    }
    #page-admin-box-close {
        cursor: pointer;
    }
        #page-admin-box-close:hover {
            color: var(--palette-primary-dim);
        }

/* Watermark */
#test-watermark {
    position: fixed;
    top: 0px;
    left: 0px;
    width: 100%;
    margin: 0;
    pointer-events: none;
    z-index: 9000;
    opacity: 0.9;
    overflow: hidden;
    text-align: center;
    white-space: nowrap;
    background-color: transparent;
    line-height: 0;
    border: none;
}
#test-watermark-body {
    display: inline-block;
    height: 22px;
    padding-top: 4px;
    padding-bottom: 2px;
    padding-left: 8px;
    padding-right: 8px;
    margin: 0;
    pointer-events: none;
    text-align: center;
    white-space: nowrap;
    color: white;
    background-color: darkgray;
    font-size: 16px;
    line-height: 100%;

    font-weight: bold;
    border-bottom-left-radius: var(--border-radius);
    border-bottom-right-radius: var(--border-radius);
    border-top: none;
}
    #test-watermark-body a {
        color: inherit;
        pointer-events: initial;
    }
