/* =========================================
   RESET
========================================= */

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
    background: #08030d;
}

body {
    min-height: 100vh;
    position: relative;
    color: #e8dcf5;
    font-family: "Courier New", Courier, monospace;
    overflow-x: hidden;
    background: transparent;
    cursor: url("assets/cheese-cursor.png") 2 2, auto;
}


/* =========================================
   CUSTOM CHEESE CURSOR
========================================= */

body,
body * {
    cursor: url("assets/cheese-cursor.png") 2 2, auto;
}

a,
a *,
button,
button *,
.language-button,
.language-button *,
[role="button"],
[role="button"] *,
.scroll-indicator,
.scroll-indicator * {
    cursor: url("assets/cheese-cursor-bite.png") 2 2, pointer;
}

input,
textarea {
    cursor: text;
}

select {
    cursor: pointer;
}


/* =========================================
   FIXED BACKGROUND
========================================= */

body::before {
    content: "";
    position: fixed;
    inset: 0;
    width: 100%;
    height: 100vh;
    z-index: 0;

    background-image:
        linear-gradient(
            rgba(7, 2, 11, 0.18),
            rgba(7, 2, 11, 0.30)
        ),
        url("assets/lab-background.png");

    background-size: cover;
    background-position: center center;
    background-repeat: no-repeat;

    pointer-events: none;
}


/* =========================================
   LANDING
========================================= */

.landing {
    width: 100%;
    position: relative;
    z-index: 1;
}


/* =========================================
   HERO
========================================= */

.hero {
    min-height: 100vh;

    display: flex;
    align-items: center;
    justify-content: center;

    position: relative;

    padding: 40px 20px 105px;

    background: transparent;
}

.hero-content {
    width: min(760px, 100%);

    display: flex;
    flex-direction: column;
    align-items: center;

    position: relative;

    text-align: center;
}


/* =========================================
   LOGO
========================================= */

.logo {
    display: block;

    width: min(680px, 90vw);
    height: auto;

    margin-bottom: 8px;

    image-rendering: pixelated;

    filter:
        drop-shadow(0 5px 2px rgba(0, 0, 0, 0.7))
        drop-shadow(0 0 18px rgba(172, 87, 255, 0.18));
}


/* =========================================
   HERO TITLE
========================================= */

h1 {
    margin-top: 0;

    color: #f0e5ff;

    font-size: clamp(2.1rem, 5vw, 4.4rem);
    font-weight: 700;
    line-height: 1;

    letter-spacing: 0.04em;

    text-shadow:
        3px 3px 0 #14091d,
        0 0 15px rgba(178, 112, 255, 0.2);
}


/* =========================================
   DECORATIVE DIVIDER
========================================= */

.divider {
    width: min(340px, 72vw);

    display: flex;
    align-items: center;
    justify-content: center;

    gap: 12px;

    margin: 20px auto 24px;
}

.divider span {
    flex: 1;
    height: 2px;

    background:
        linear-gradient(
            to right,
            transparent,
            #a25bd8
        );

    box-shadow:
        0 0 7px rgba(172, 93, 220, 0.35);
}

.divider span:last-child {
    background:
        linear-gradient(
            to left,
            transparent,
            #a25bd8
        );
}

.divider b {
    width: 9px;
    height: 9px;

    display: block;

    background: #d34866;

    transform: rotate(45deg);

    box-shadow:
        0 0 8px rgba(211, 72, 102, 0.5);
}


/* =========================================
   INTRO
========================================= */

.intro {
    font-size: clamp(0.92rem, 1.5vw, 1.1rem);
    line-height: 1.75;

    color: #c9b5dc;

    text-shadow:
        2px 2px 3px rgba(0, 0, 0, 0.95);
}

.intro p {
    margin: 2px 0;
}

.potion-message {
    margin-top: 15px !important;

    color: #d75a77;

    font-weight: bold;
}


/* =========================================
   LANGUAGE SELECTOR
========================================= */

.language-selector {
    display: flex;
    align-items: center;
    justify-content: center;

    gap: 10px;

    margin-top: 30px;

    color: #654977;
}

.language-button {
    appearance: none;

    border: 0;
    background: transparent;

    color: #8f76a4;

    padding: 7px 5px;

    font: inherit;
    font-size: 0.82rem;
    font-weight: bold;

    letter-spacing: 0.1em;

    transition:
        color 0.18s ease,
        text-shadow 0.18s ease;
}

.language-button:hover {
    color: #d2b6ea;
}

.language-button.active {
    color: #d34c6b;

    text-shadow:
        0 0 7px rgba(211, 76, 107, 0.45);
}


/* =========================================
   SCROLL INDICATOR
========================================= */

.scroll-indicator {
    position: absolute;

    left: 50%;
    bottom: 24px;

    transform: translateX(-50%);

    z-index: 3;

    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;

    gap: 7px;

    min-width: 180px;

    color: #aa86c4;

    text-decoration: none;
    text-align: center;

    opacity: 0.78;

    transition:
        color 0.2s ease,
        opacity 0.2s ease,
        text-shadow 0.2s ease;
}

.scroll-indicator:hover {
    color: #d8b8ee;

    opacity: 1;

    text-shadow:
        0 0 9px rgba(184, 111, 230, 0.38);
}

.scroll-indicator-label {
    display: flex;
    align-items: center;
    justify-content: center;

    gap: 9px;

    font-size: 0.72rem;
    font-weight: bold;

    letter-spacing: 0.16em;

    text-transform: uppercase;

    text-shadow:
        2px 2px 3px rgba(0, 0, 0, 0.9);
}

.scroll-indicator-label::before,
.scroll-indicator-label::after {
    content: "◆";

    color: #d34c6b;

    font-size: 0.48rem;

    text-shadow:
        0 0 6px rgba(211, 76, 107, 0.48);
}

.scroll-arrow {
    display: block;

    color: #c28de2;

    font-size: 1.25rem;
    line-height: 1;

    text-shadow:
        0 0 8px rgba(194, 141, 226, 0.35);

    animation:
        scroll-bounce 1.8s ease-in-out infinite;
}

@keyframes scroll-bounce {
    0%,
    100% {
        transform: translateY(0);
    }

    50% {
        transform: translateY(6px);
    }
}


/* =========================================
   TODAY IN TIBIA
========================================= */

.today-section {
    position: relative;

    min-height: 100vh;

    padding: 90px 20px 120px;

    background: transparent;

    scroll-margin-top: 0;
}

.today-section::before {
    content: "";

    position: absolute;

    top: 0;
    left: 50%;

    width: min(900px, 80vw);
    height: 1px;

    transform: translateX(-50%);

    background:
        linear-gradient(
            to right,
            transparent,
            rgba(163, 92, 208, 0.45),
            transparent
        );
}

.today-container {
    width: min(900px, 100%);

    margin: 0 auto;
}


/* =========================================
   TODAY HEADER
========================================= */

.today-header {
    margin-bottom: 45px;

    text-align: center;

    text-shadow:
        2px 2px 4px rgba(0, 0, 0, 0.9);
}

.section-eyebrow {
    margin-bottom: 10px;

    color: #a98aba;

    font-size: 0.72rem;
    font-weight: bold;

    letter-spacing: 0.22em;

    text-transform: uppercase;
}

.today-header h2 {
    color: #eee2fa;

    font-size: clamp(1.9rem, 4vw, 3rem);
    line-height: 1.1;

    text-shadow:
        3px 3px 0 #100817,
        0 0 14px rgba(178, 112, 255, 0.18);
}

.today-divider {
    margin-bottom: 0;
}


/* =========================================
   DAILY GRID
========================================= */

.daily-grid {
    display: grid;

    grid-template-columns:
        repeat(2, minmax(0, 1fr));

    gap: 22px;
}


/* =========================================
   CARDS
========================================= */

.daily-card,
.info-card {
    position: relative;

    overflow: hidden;

    border:
        1px solid rgba(177, 112, 216, 0.32);

    background:
        linear-gradient(
            145deg,
            rgba(31, 16, 42, 0.86),
            rgba(15, 7, 21, 0.90)
        );

    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);

    box-shadow:
        0 14px 35px rgba(0, 0, 0, 0.32),
        inset 0 0 25px rgba(166, 87, 218, 0.035);
}

.daily-card::before,
.info-card::before {
    content: "";

    position: absolute;

    top: 0;
    left: 20%;
    right: 20%;

    height: 1px;

    background:
        linear-gradient(
            to right,
            transparent,
            rgba(205, 120, 255, 0.55),
            transparent
        );
}


/* =========================================
   DAILY CARD
========================================= */

.daily-card {
    min-height: 285px;

    padding: 24px;

    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
}


/* =========================================
   CARD HEADINGS
========================================= */

.card-heading,
.events-heading {
    display: flex;
    align-items: center;
    justify-content: center;

    gap: 10px;

    width: 100%;

    margin-bottom: 20px;
}

.card-heading h3,
.events-heading h3 {
    color: #cdb5de;

    font-size: 0.83rem;
    line-height: 1.2;

    letter-spacing: 0.12em;

    text-transform: uppercase;

    text-shadow:
        2px 2px 3px rgba(0, 0, 0, 0.8);
}

.card-symbol {
    color: #ce4968;

    font-size: 0.65rem;

    text-shadow:
        0 0 6px rgba(206, 73, 104, 0.5);
}


/* =========================================
   DAILY SPRITES
========================================= */

.daily-image-area {
    width: 145px;
    height: 145px;

    display: flex;
    align-items: center;
    justify-content: center;

    margin: 3px 0 10px;

    position: relative;
}

.daily-image-area::after {
    content: "";

    position: absolute;

    left: 50%;
    bottom: 10px;

    width: 85px;
    height: 15px;

    transform: translateX(-50%);

    border-radius: 50%;

    background: rgba(0, 0, 0, 0.32);

    filter: blur(5px);

    z-index: 0;
}

.daily-sprite {
    position: relative;

    z-index: 1;

    max-width: 128px;
    max-height: 128px;

    object-fit: contain;

    image-rendering: pixelated;

    filter:
        drop-shadow(0 5px 2px rgba(0, 0, 0, 0.55));
}

.daily-name {
    margin-top: auto;

    color: #eadff2;

    font-size: 1.03rem;
    font-weight: bold;

    line-height: 1.35;

    text-align: center;

    text-shadow:
        2px 2px 3px rgba(0, 0, 0, 0.8);
}


/* =========================================
   LOADING
========================================= */

.loading-spinner {
    width: 24px;
    height: 24px;

    border:
        2px solid rgba(178, 116, 214, 0.18);

    border-top-color: #b875d6;

    border-radius: 50%;

    animation:
        spin 0.8s linear infinite;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

.hidden {
    display: none !important;
}


/* =========================================
   RASHID + EVENTS
========================================= */

.info-card {
    margin-top: 22px;

    display: grid;

    grid-template-columns:
        minmax(0, 1fr)
        minmax(0, 1fr);
}

.info-panel {
    position: relative;

    min-width: 0;

    padding: 26px 30px;
}


/* =========================================
   RASHID
========================================= */

.rashid-panel::after {
    content: "";

    position: absolute;

    top: 24px;
    right: 0;
    bottom: 24px;

    width: 1px;

    background:
        linear-gradient(
            to bottom,
            transparent,
            rgba(177, 112, 216, 0.30),
            transparent
        );
}

.info-heading {
    justify-content: flex-start;

    margin-bottom: 14px;
}

.rashid-content {
    display: flex;
    align-items: center;
    justify-content: center;

    gap: 24px;

    min-height: 120px;
}

.rashid-image-area {
    width: 105px;
    height: 105px;

    flex: 0 0 105px;

    display: flex;
    align-items: center;
    justify-content: center;

    position: relative;
}

.rashid-image-area::after {
    content: "";

    position: absolute;

    left: 50%;
    bottom: 7px;

    width: 70px;
    height: 13px;

    transform: translateX(-50%);

    border-radius: 50%;

    background: rgba(0, 0, 0, 0.32);

    filter: blur(5px);
}

.rashid-sprite {
    position: relative;

    z-index: 1;

    max-width: 95px;
    max-height: 95px;

    object-fit: contain;

    image-rendering: pixelated;

    filter:
        drop-shadow(0 5px 2px rgba(0, 0, 0, 0.55));
}

.rashid-text {
    min-width: 0;

    text-align: left;
}

.rashid-label {
    margin-bottom: 7px;

    color: #b39ac2;

    font-size: 0.86rem;
}

.rashid-city {
    color: #eee0f7;

    font-size: clamp(1.35rem, 2.5vw, 1.9rem);
    font-weight: bold;

    text-shadow:
        0 0 12px rgba(172, 92, 215, 0.2);
}


/* =========================================
   EVENTS
========================================= */

.events-preview {
    text-align: left;
}

.events-heading {
    justify-content: flex-start;

    margin-bottom: 17px;
}

.events-list {
    display: flex;
    flex-direction: column;

    gap: 17px;
}

.event-item {
    display: grid;

    grid-template-columns:
        16px
        minmax(0, 1fr);

    gap: 9px;

    align-items: start;
}

.event-item-symbol {
    padding-top: 2px;

    color: #82668f;

    font-size: 0.65rem;
    line-height: 1.2;

    text-align: center;
}

.event-item-content {
    min-width: 0;

    display: grid;

    grid-template-columns:
        minmax(0, 1fr)
        auto;

    column-gap: 10px;
    row-gap: 4px;

    align-items: baseline;
}

.event-item-name {
    min-width: 0;

    color: #ddd0e7;

    font-size: 0.82rem;
    font-weight: bold;

    line-height: 1.35;
}

.event-item-status {
    color: #927c9e;

    font-size: 0.61rem;
    font-weight: bold;

    line-height: 1.2;

    letter-spacing: 0.08em;

    text-transform: uppercase;

    white-space: nowrap;
}

.event-item-date {
    grid-column: 1 / -1;

    color: #9f8aaa;

    font-size: 0.72rem;

    line-height: 1.4;
}

.event-item.active .event-item-symbol {
    color: #d34c6b;

    text-shadow:
        0 0 6px rgba(211, 76, 107, 0.48);
}

.event-item.active .event-item-status {
    color: #d75a77;

    text-shadow:
        0 0 6px rgba(215, 90, 119, 0.22);
}

.events-message {
    color: #a993b7;

    font-size: 0.82rem;

    line-height: 1.5;
}

.events-message.error {
    color: #b994a6;
}


/* =========================================
   ERROR
========================================= */

.daily-name.error {
    color: #b994a6;

    font-size: 0.82rem;
    font-weight: normal;
}


/* =========================================
   LEGAL
========================================= */

.legal-section {
    position: relative;

    width: 100%;

    padding: 10px 20px 55px;

    background:
        linear-gradient(
            to bottom,
            transparent,
            rgba(8, 3, 13, 0.60)
        );
}

.legal-content {
    width: min(760px, 100%);

    margin: 0 auto;

    color: rgba(186, 166, 199, 0.68);

    font-size: 0.67rem;
    line-height: 1.7;

    text-align: center;

    text-shadow:
        1px 1px 3px rgba(0, 0, 0, 0.95);
}

.legal-decoration {
    width: 190px;

    display: flex;
    align-items: center;
    justify-content: center;

    gap: 9px;

    margin: 0 auto 18px;
}

.legal-decoration span {
    flex: 1;

    height: 1px;

    background:
        linear-gradient(
            to right,
            transparent,
            rgba(163, 91, 216, 0.45)
        );
}

.legal-decoration span:last-child {
    background:
        linear-gradient(
            to left,
            transparent,
            rgba(163, 91, 216, 0.45)
        );
}

.legal-decoration b {
    display: block;

    width: 6px;
    height: 6px;

    background: rgba(211, 72, 102, 0.75);

    transform: rotate(45deg);

    box-shadow:
        0 0 5px rgba(211, 72, 102, 0.3);
}

.legal-main-line {
    margin-bottom: 5px;

    color: rgba(215, 198, 226, 0.78);

    font-weight: bold;
}

.legal-copyright {
    max-width: 700px;

    margin: 0 auto;
}

.legal-content a {
    color: rgba(191, 138, 220, 0.88);

    text-decoration: none;

    border-bottom:
        1px dotted rgba(191, 138, 220, 0.35);

    transition:
        color 0.18s ease,
        border-color 0.18s ease,
        text-shadow 0.18s ease;
}

.legal-content a:hover {
    color: #d75a77;

    border-color:
        rgba(215, 90, 119, 0.6);

    text-shadow:
        0 0 6px rgba(215, 90, 119, 0.28);
}


/* =========================================
   SITE FOOTER
========================================= */

.site-footer {
    position: fixed;

    left: 22px;
    bottom: 18px;

    z-index: 10;

    pointer-events: none;
}

.site-credit {
    display: flex;
    flex-direction: column;
    align-items: flex-start;

    gap: 3px;

    max-width: 390px;

    padding: 10px 13px;

    color: rgba(210, 194, 221, 0.72);

    font-size: 0.68rem;
    line-height: 1.45;

    text-align: left;

    text-shadow:
        1px 1px 3px rgba(0, 0, 0, 0.95);

    background:
        rgba(8, 3, 13, 0.42);

    border-left:
        1px solid rgba(177, 112, 216, 0.32);

    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);

    box-shadow:
        0 6px 18px rgba(0, 0, 0, 0.15);

    pointer-events: auto;
}

.site-credit strong {
    color: rgba(231, 216, 242, 0.92);

    font-size: 0.72rem;

    letter-spacing: 0.12em;
}


/* =========================================
   CREATOR
========================================= */

.creator-line {
    display: flex;
    flex-wrap: wrap;
    align-items: center;

    column-gap: 5px;
}

.creator-character {
    color: rgba(194, 150, 219, 0.88);

    text-decoration: none;

    border-bottom:
        1px dotted rgba(194, 150, 219, 0.35);

    transition:
        color 0.18s ease,
        border-color 0.18s ease,
        text-shadow 0.18s ease;
}

.creator-character:hover {
    color: #d75a77;

    border-color:
        rgba(215, 90, 119, 0.6);

    text-shadow:
        0 0 7px rgba(215, 90, 119, 0.4);
}


/* =========================================
   CONTACT
========================================= */

.contact-email {
    color: rgba(194, 150, 219, 0.88);

    text-decoration: none;

    transition:
        color 0.18s ease,
        text-shadow 0.18s ease;
}

.contact-email:hover {
    color: #d75a77;

    text-shadow:
        0 0 7px rgba(215, 90, 119, 0.4);
}

.site-credit .copyright {
    margin-top: 2px;

    color: rgba(151, 128, 164, 0.68);
}


/* =========================================
   TABLET
========================================= */

@media (max-width: 900px) {

    .site-footer {
        position: relative;

        left: auto;
        bottom: auto;

        z-index: 2;

        width: 100%;

        padding: 10px 20px 35px;

        pointer-events: auto;
    }

    .site-credit {
        align-items: center;

        width: 100%;
        max-width: 100%;

        padding: 18px 10px;

        border-left: 0;

        border-top:
            1px solid rgba(177, 112, 216, 0.25);

        background:
            rgba(8, 3, 13, 0.52);

        text-align: center;
    }

    .creator-line {
        justify-content: center;
    }
}


/* =========================================
   MOBILE
========================================= */

@media (max-width: 700px) {

    body::before {
        height: 100svh;

        background-position:
            center center;
    }

    /*
       O hero usa a altura VISÍVEL do celular.
       Isso impede o indicador Today in Tibia
       de ficar escondido atrás da barra do browser.
    */

    .hero {
        min-height: 100svh;

        padding:
            20px
            18px
            78px;

        align-items: center;
    }

    /*
       Só sobe o conteúdo um pouquinho.
       Não mexe no indicador.
    */

    .hero-content {
        transform: translateY(-12px);
    }

    .logo {
        width: min(580px, 94vw);
    }

    .intro {
        max-width: 92vw;
    }

    .scroll-indicator {
        left: 50%;
        bottom: 12px;

        min-width: 160px;

        transform: translateX(-50%);
    }

    .scroll-indicator-label {
        font-size: 0.67rem;
    }

    /*
       Cards ficam em uma coluna.
    */

    .today-section {
        min-height: auto;

        padding:
            60px
            16px
            70px;
    }

    .today-header {
        margin-bottom: 32px;
    }

    .daily-grid {
        grid-template-columns: 1fr;
    }

    .daily-card {
        min-height: 260px;
    }

    /*
       Rashid + Events:
       no desktop são lado a lado;
       no celular ficam empilhados.
    */

    .info-card {
        grid-template-columns: 1fr;
    }

    .info-panel {
        width: 100%;

        padding:
            24px
            18px;
    }

    /*
       Remove o divisor vertical do desktop
       e cria um horizontal.
    */

    .rashid-panel::after {
        top: auto;
        left: 18px;
        right: 18px;
        bottom: 0;

        width: auto;
        height: 1px;

        background:
            linear-gradient(
                to right,
                transparent,
                rgba(177, 112, 216, 0.30),
                transparent
            );
    }

    .info-heading,
    .events-heading {
        justify-content: center;
    }

    /*
       Rashid continua lado a lado no celular
       quando houver espaço. Isso evita aquela
       aparência quebrada/esticada.
    */

    .rashid-content {
        flex-direction: row;

        justify-content: center;
        align-items: center;

        gap: 18px;

        min-height: 105px;

        text-align: left;
    }

    .rashid-image-area {
        width: 90px;
        height: 90px;

        flex: 0 0 90px;
    }

    .rashid-sprite {
        max-width: 82px;
        max-height: 82px;
    }

    .rashid-text {
        text-align: left;
    }

    .rashid-city {
        font-size: 1.4rem;
    }

    .events-preview {
        text-align: left;
    }

    .events-list {
        width: 100%;
        max-width: 400px;

        margin: 0 auto;
    }

    .legal-section {
        padding:
            5px
            18px
            35px;
    }

    .legal-content {
        font-size: 0.64rem;

        line-height: 1.65;
    }
}


/* =========================================
   SMALL MOBILE
========================================= */

@media (max-width: 420px) {

    .hero {
        padding:
            16px
            14px
            72px;
    }

    .hero-content {
        transform: translateY(-8px);
    }

    .logo {
        width: 92vw;
    }

    h1 {
        font-size: 2rem;
    }

    .divider {
        width: 230px;
    }

    .intro {
        font-size: 0.86rem;

        line-height: 1.6;
    }

    .potion-message {
        margin-top: 11px !important;
    }

    .language-selector {
        margin-top: 20px;
    }

    .scroll-indicator {
        bottom: 9px;
    }

    .scroll-indicator-label {
        gap: 7px;

        font-size: 0.62rem;

        letter-spacing: 0.12em;
    }

    .scroll-arrow {
        font-size: 1.1rem;
    }

    .daily-card {
        padding:
            22px
            16px;
    }

    /*
       Em telas realmente estreitas,
       Rashid passa para coluna.
    */

    .rashid-content {
        flex-direction: column;

        gap: 6px;

        text-align: center;
    }

    .rashid-text {
        text-align: center;
    }

    .event-item-content {
        grid-template-columns: 1fr;
    }

    .event-item-status {
        grid-column: 1;
    }

    .event-item-date {
        grid-column: 1;
    }

    .legal-decoration {
        width: 150px;
    }

    .site-footer {
        padding:
            5px
            14px
            25px;
    }

    .site-credit {
        font-size: 0.65rem;
    }
}


/* =========================================
   REDUCED MOTION
========================================= */

@media (prefers-reduced-motion: reduce) {

    html {
        scroll-behavior: auto;
    }

    .scroll-arrow {
        animation: none;
    }

}