:root {
    --night: #211711;
    --night-deep: #1B120C;
    --cream-soft: rgba(247, 237, 214, 0.76);
    --cream-faint: rgba(247, 237, 214, 0.16);
    --teal-bright: #4FB3AA;
    --orange-bright: #ED7440;
}

body.theme-night {
    background-color: var(--night);
    background-image: radial-gradient(circle, rgba(247, 237, 214, 0.04) 1px, transparent 1px);
    background-size: 18px 18px;
    color: var(--paper);
}

.theme-night ::selection {
    background: var(--gold);
    color: var(--ink);
}

.theme-night .site-nav {
    background: rgba(27, 18, 12, 0.72);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border-bottom: 1px solid rgba(228, 168, 44, 0.28);
}

.theme-night .nav-link {
    color: var(--paper);
}

.theme-night .nav-link:hover {
    color: var(--gold);
}

.theme-night .lang-toggle {
    border-color: var(--paper);
}

.theme-night .lang-toggle button {
    color: var(--paper);
}

.theme-night .lang-toggle button[aria-pressed="true"] {
    background: var(--paper);
    color: var(--ink);
}

.theme-night .btn {
    border-color: var(--paper);
    box-shadow: 5px 5px 0 rgba(0, 0, 0, 0.45);
    transition: transform 130ms ease-out, box-shadow 130ms ease-out, background-color 130ms ease-out;
}

.theme-night .btn:hover {
    transform: translate(-2px, -2px);
    box-shadow: 8px 8px 0 rgba(0, 0, 0, 0.45);
}

.theme-night .btn:active {
    transform: translate(2px, 2px);
    box-shadow: 2px 2px 0 rgba(0, 0, 0, 0.45);
}

.theme-night .site-footer {
    border-top: 1px solid var(--cream-faint);
}

.theme-night .footer-links a {
    color: var(--paper);
}

.theme-night .footer-links a:hover {
    color: var(--gold);
}

.theme-night .footer-copy {
    color: var(--cream-soft);
}

.theme-night .eyebrow {
    color: var(--gold);
}

.eyebrow .star {
    color: var(--cream-faint);
    font-size: 0.85em;
}

.hero {
    position: relative;
    overflow: hidden;
    display: flex;
    align-items: flex-end;
    justify-content: center;
    text-align: center;
    min-height: calc(100vh - var(--nav-h));
    min-height: calc(100svh - var(--nav-h));
    padding: 7rem 1.5rem 3.6rem;
}

.hero-bg,
.hero-scrim {
    position: absolute;
    inset: 0;
    pointer-events: none;
}

.hero-bg img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: 52% 32%;
    transform-origin: 50% 30%;
    animation: ken-settle 8s cubic-bezier(0.16, 0.55, 0.25, 1) both;
}

.hero-scrim {
    background: linear-gradient(to bottom,
    rgba(27, 18, 12, 0.55) 0%,
    rgba(27, 18, 12, 0.1) 16%,
    rgba(27, 18, 12, 0.22) 36%,
    rgba(27, 18, 12, 0.82) 58%,
    rgba(27, 18, 12, 0.97) 78%,
    var(--night) 100%),
    linear-gradient(to right,
    rgba(27, 18, 12, 0.45),
    transparent 24%,
    transparent 76%,
    rgba(27, 18, 12, 0.45));
}

.hero-inner {
    position: relative;
    z-index: 2;
    max-width: 860px;
    animation: rise 1s 0.35s cubic-bezier(0.2, 0.7, 0.2, 1) both;
}

.ticket {
    display: inline-block;
    background: var(--paper);
    color: var(--ink);
    font-size: 0.72rem;
    font-weight: 800;
    letter-spacing: 0.16em;
    text-transform: uppercase;
    padding: 0.62rem 1.7rem;
    margin: 0;
    border-radius: 8px;
    text-wrap: balance;
    -webkit-mask-image: radial-gradient(circle 8px at 0 50%, transparent 7px, #000 7.5px),
    radial-gradient(circle 8px at 100% 50%, transparent 7px, #000 7.5px);
    -webkit-mask-composite: source-in;
    mask-image: radial-gradient(circle 8px at 0 50%, transparent 7px, #000 7.5px),
    radial-gradient(circle 8px at 100% 50%, transparent 7px, #000 7.5px);
    mask-composite: intersect;
}

.hero h1 {
    margin: 1.3rem 0 0;
    line-height: 1;
}

.h1-line {
    display: block;
    font: 400 clamp(1.6rem, 4vw, 2.6rem)/1.15 'Righteous', sans-serif;
    letter-spacing: 0.04em;
    color: var(--paper);
    text-shadow: 0 2px 18px rgba(27, 18, 12, 0.7);
}

.h1-mark {
    display: inline-block;
    font: 400 clamp(3rem, 8vw, 5.4rem)/1.05 'Righteous', sans-serif;
    color: var(--gold);
    transform: rotate(-2deg);
    margin-top: 0.05em;
    text-shadow: 0.045em 0.045em 0 var(--brick),
    0.1em 0.1em 0 rgba(0, 0, 0, 0.4),
    0 0.15em 0.9em rgba(27, 18, 12, 0.85);
}

.hero .lede {
    font-size: 1.1rem;
    color: var(--cream-soft);
    max-width: 560px;
    margin: 1.3rem auto 0;
    text-wrap: balance;
}

.hero-actions {
    display: flex;
    gap: 1rem;
    justify-content: center;
    flex-wrap: wrap;
    margin-top: 1.9rem;
}

.hero-plate {
    display: inline-flex;
    align-items: center;
    gap: 0.6rem;
    border: 1.5px solid rgba(247, 237, 214, 0.35);
    border-radius: 999px;
    padding: 0.45rem 1.2rem;
    font-size: 0.7rem;
    font-weight: 800;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: var(--cream-soft);
    margin: 1.9rem 0 0;
}

.hero-plate .star {
    color: var(--gold);
}

.spark {
    position: absolute;
    pointer-events: none;
    animation: twinkle 3.6s ease-in-out infinite alternate;
}

.spark-1 {
    top: 12%;
    left: 7%;
    font-size: 1.4rem;
    color: var(--gold);
    animation-delay: 0.2s;
}

.spark-2 {
    top: 34%;
    right: 6%;
    font-size: 1rem;
    color: var(--teal-bright);
    animation-delay: 1.2s;
}

.spark-3 {
    bottom: 8%;
    left: 12%;
    font-size: 0.9rem;
    color: var(--orange-bright);
    animation-delay: 2s;
}

.spark-4 {
    top: 24%;
    right: 12%;
    font-size: 1.2rem;
    color: var(--gold);
    animation-delay: 0.8s;
}

.spark-5 {
    bottom: 20%;
    left: 9%;
    font-size: 0.9rem;
    color: var(--teal-bright);
    animation-delay: 2.6s;
}

.download {
    position: relative;
    max-width: 980px;
    margin: 0 auto;
    padding: 6.5rem 1.5rem 0;
    text-align: center;
    scroll-margin-top: calc(var(--nav-h) + 0.5rem);
}

.download h2,
.feedback h2 {
    font: 400 clamp(1.8rem, 4vw, 2.3rem)/1.2 'Righteous', sans-serif;
    letter-spacing: 0.03em;
    color: var(--paper);
    margin: 0.7rem 0 0;
}

.cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(min(100%, 300px), 1fr));
    gap: 2rem;
    margin-top: 2.8rem;
    text-align: left;
}

.card {
    background: var(--paper-raised);
    color: var(--ink);
    border: 2px solid var(--ink);
    border-radius: var(--radius);
    padding: 2rem;
    box-shadow: 10px 10px 0 rgba(0, 0, 0, 0.4);
    display: flex;
    flex-direction: column;
    gap: 1.3rem;
    scroll-margin-top: calc(var(--nav-h) + 0.5rem);
    transition: transform 200ms ease-out;
}

.card-android {
    transform: rotate(-1.1deg);
}

.card-ios {
    transform: rotate(1deg);
}

.card:hover {
    transform: rotate(0deg);
}

.card-head {
    display: flex;
    align-items: center;
    gap: 0.95rem;
}

.card-icon {
    flex: none;
    width: 48px;
    height: 48px;
    border-radius: 14px;
    border: 1.5px solid var(--ink);
    display: flex;
    align-items: center;
    justify-content: center;
    font: 400 1.3rem 'Righteous', sans-serif;
    color: var(--paper-raised);
}

.card-android .card-icon {
    background: var(--teal);
}

.card-ios .card-icon {
    background: var(--orange);
}

.card-platform {
    font: 400 1.35rem 'Righteous', sans-serif;
    line-height: 1.1;
}

.card-tagline {
    font-size: 0.68rem;
    font-weight: 800;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    margin-top: 0.2rem;
}

.card-android .card-tagline {
    color: var(--teal-deep);
}

.card-ios .card-tagline {
    color: var(--orange-deep);
}

.theme-night .card .btn {
    border-color: var(--ink);
    box-shadow: 4px 4px 0 rgba(43, 33, 24, 0.35);
}

.theme-night .card .btn:hover {
    box-shadow: 6px 6px 0 rgba(43, 33, 24, 0.35);
}

.theme-night .card .btn:active {
    box-shadow: 2px 2px 0 rgba(43, 33, 24, 0.35);
}

.steps {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 0.85rem;
    counter-reset: step;
}

.steps li {
    counter-increment: step;
    display: flex;
    gap: 0.8rem;
    font-size: 0.95rem;
    line-height: 1.55;
}

.steps li .step-body {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 0.7rem;
}

.steps li .step-body .btn {
    align-self: stretch;
    margin-bottom: 0.35rem;
}

.steps li::before {
    content: counter(step);
    flex: none;
    width: 26px;
    height: 26px;
    border-radius: 50%;
    background: var(--ink);
    color: var(--paper-raised);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.78rem;
    font-weight: 700;
    margin-top: 0.15rem;
}

.card-footnote {
    margin-top: auto;
    padding-top: 1rem;
    border-top: 1px dashed rgba(43, 33, 24, 0.35);
    font-size: 0.78rem;
    font-weight: 700;
    letter-spacing: 0.04em;
    color: var(--ink-soft);
}

.feedback {
    position: relative;
    max-width: 620px;
    margin: 0 auto;
    padding: 6.5rem 1.5rem 7rem;
    text-align: center;
}

.feedback p {
    color: var(--cream-soft);
    max-width: 420px;
    margin: 0.9rem auto 1.8rem;
    text-wrap: balance;
}

@keyframes rise {
    from {
        opacity: 0;
        transform: translateY(28px);
    }
    to {
        opacity: 1;
        transform: none;
    }
}

@keyframes ken-settle {
    from {
        transform: scale(1.16);
    }
    to {
        transform: scale(1.04);
    }
}

@keyframes twinkle {
    from {
        opacity: 0.2;
    }
    to {
        opacity: 1;
    }
}

@media (max-width: 640px) {
    .spark {
        display: none;
    }

    .hero {
        padding: 4.5rem 1.25rem 2.8rem;
    }

    .ticket {
        font-size: 0.62rem;
        letter-spacing: 0.12em;
        padding: 0.55rem 1.2rem;
    }

    .hero .lede {
        font-size: 1rem;
    }

    .hero-actions {
        flex-direction: column;
        align-items: stretch;
        width: min(100%, 320px);
        margin: 1.7rem auto 0;
    }

    .hero-plate {
        margin-top: 1.6rem;
    }

    .download {
        padding-top: 4.5rem;
    }

    .cards {
        gap: 1.6rem;
        margin-top: 2.2rem;
    }

    .card {
        padding: 1.6rem 1.35rem;
        box-shadow: 7px 7px 0 rgba(0, 0, 0, 0.4);
    }

    .feedback {
        padding: 4.5rem 1.5rem 5.5rem;
    }
}

@media (prefers-reduced-motion: reduce) {
    .hero-bg img,
    .hero-inner,
    .spark {
        animation: none;
    }

    .theme-night .btn,
    .card {
        transition: none;
    }
}
