/* Byme Living — public website.
   Brand (CLAUDE.md §15) and the app's own look: Plus Jakarta Sans, purple leading on
   warm ivory, copper as the accent and never as body text. Dark mode lets copper lead.
   Mobile-first, zero JavaScript (visitors are on low-end Android over 3G). Every 3D
   scroll effect is a CSS scroll-driven animation behind @supports, so older browsers
   get a clean static page, and all motion stops when the device asks for less. */

/* ── Fonts (self-hosted) ──────────────────────────────────────────────────────── */
@font-face {
    font-family: "Plus Jakarta Sans";
    src: url("../../brand/fonts/plus-jakarta-sans-latin-wght-normal.woff2") format("woff2-variations");
    font-weight: 200 800;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: "Plus Jakarta Sans";
    src: url("../../brand/fonts/plus-jakarta-sans-latin-wght-italic.woff2") format("woff2-variations");
    font-weight: 200 800;
    font-style: italic;
    font-display: swap;
}

@font-face {
    font-family: "Plus Jakarta Sans";
    src: url("../../brand/fonts/plus-jakarta-sans-latin-ext-wght-normal.woff2") format("woff2-variations");
    font-weight: 200 800;
    font-display: swap;
    unicode-range: U+0100-02AF, U+0304, U+0308, U+0329, U+1E00-1E9F, U+1EF2-1EFF, U+2020,
        U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

@font-face {
    font-family: "Noto Nastaliq Urdu";
    src: url("../../brand/fonts/noto-nastaliq-urdu-arabic-400-normal.woff2") format("woff2");
    font-weight: 400;
    font-display: swap;
}

@font-face {
    font-family: "Noto Nastaliq Urdu";
    src: url("../../brand/fonts/noto-nastaliq-urdu-arabic-700-normal.woff2") format("woff2");
    font-weight: 700;
    font-display: swap;
}

/* ── Tokens ───────────────────────────────────────────────────────────────────── */
:root {
    --purple: #6b2f7d;
    --purple-dark: #492055;
    --purple-deep: #2a1430;
    --purple-light: #7a448a;
    --copper: #ce8a63;
    --copper-dark: #a97151;
    --copper-light: #dcab8e;
    --ivory: #fbf8f5;

    --ground: var(--ivory);
    --surface: #ffffff;
    --tint: #f5efe9;
    --ink: #2a2430;
    --ink-loud: #1b1520;
    --muted: #6e6472;
    --line: rgba(42, 36, 48, 0.09);
    --accent: var(--purple);
    --accent-strong: var(--purple-dark);
    --accent-soft: var(--copper-dark);
    --on-accent: #ffffff;
    --glass: rgba(255, 255, 255, 0.72);
    --shadow-sm: 0 1px 2px rgba(42, 36, 48, 0.06);
    --shadow: 0 12px 32px -14px rgba(73, 32, 85, 0.28), 0 2px 6px rgba(42, 36, 48, 0.05);
    --shadow-lg: 0 50px 90px -30px rgba(73, 32, 85, 0.5);

    --font: "Plus Jakarta Sans", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
    --radius: 22px;
    --radius-lg: 32px;
    --wrap: 1200px;
    --gutter: clamp(16px, 4vw, 40px);
    --space: clamp(72px, 10vw, 136px);

    color-scheme: light dark;
}

@media (prefers-color-scheme: dark) {
    :root {
        --ground: #120e14;
        --surface: #1c1620;
        --tint: #19131c;
        --ink: #ece6ee;
        --ink-loud: #ffffff;
        --muted: #a99fad;
        --line: rgba(236, 230, 238, 0.1);
        --accent: var(--copper-light);
        --accent-strong: #ebc6ae;
        --accent-soft: var(--copper-light);
        --on-accent: #1a1420;
        --glass: rgba(28, 22, 32, 0.72);
        --shadow: 0 12px 32px -14px rgba(0, 0, 0, 0.6);
        --shadow-lg: 0 50px 90px -30px rgba(0, 0, 0, 0.8);
    }
}

/* ── Base ─────────────────────────────────────────────────────────────────────── */
@view-transition {
    navigation: auto;
}

*,
*::before,
*::after {
    box-sizing: border-box;
}

html {
    -webkit-text-size-adjust: 100%;
    scroll-behavior: smooth;
    scroll-padding-top: 88px;
}

body {
    margin: 0;
    background: var(--ground);
    color: var(--ink);
    font-family: var(--font);
    font-size: 17px;
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
    /* clip, not hidden: hidden makes body a scroll container, and iOS Safari then lets the
       sticky header jump and detach while the page scrolls back up. */
    overflow-x: clip;
}

html[dir="rtl"] body {
    font-family: "Noto Nastaliq Urdu", var(--font);
    line-height: 2.1;
}

img,
svg {
    max-width: 100%;
    display: block;
}

a {
    color: var(--accent);
    text-underline-offset: 3px;
}

h1,
h2,
h3 {
    margin: 0;
    color: var(--ink-loud);
    font-weight: 700;
    line-height: 1.1;
    letter-spacing: -0.02em;
    text-wrap: balance;
}

p {
    margin: 0 0 1em;
    text-wrap: pretty;
}

ul[role="list"],
ol[role="list"] {
    list-style: none;
    margin: 0;
    padding: 0;
}

:focus-visible {
    outline: 3px solid var(--copper);
    outline-offset: 3px;
    border-radius: 6px;
}

.visually-hidden {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip: rect(0 0 0 0);
    white-space: nowrap;
}

.skip {
    position: absolute;
    inset-inline-start: 16px;
    top: -60px;
    z-index: 100;
    padding: 10px 16px;
    border-radius: 10px;
    background: var(--purple-dark);
    color: #fff;
}

.skip:focus {
    top: 12px;
}

.wrap {
    width: min(100% - 2 * var(--gutter), var(--wrap));
    margin-inline: auto;
}

.narrow {
    width: min(100% - 2 * var(--gutter), 780px);
}

/* Film grain: one inline SVG, so flat colour never looks like a template. */
body::before {
    content: "";
    position: fixed;
    inset: 0;
    z-index: 60;
    pointer-events: none;
    opacity: 0.045;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

/* ── Type ─────────────────────────────────────────────────────────────────────── */
.display {
    font-size: clamp(2.7rem, 7.4vw, 5.6rem);
    font-weight: 800;
    line-height: 1;
    letter-spacing: -0.045em;
}

.display em,
.title em {
    font-style: italic;
    font-weight: 700;
    color: var(--accent-soft);
    padding-inline-end: 0.04em;
}

.display-page {
    font-size: clamp(2.4rem, 5.6vw, 4.4rem);
}

html[dir="rtl"] .display,
html[dir="rtl"] .title {
    font-family: "Noto Nastaliq Urdu", serif;
    font-weight: 700;
    letter-spacing: 0;
    line-height: 1.8;
}

html[dir="rtl"] .display {
    font-size: clamp(2rem, 5.4vw, 3.8rem);
}

.title {
    font-size: clamp(2rem, 4.6vw, 3.4rem);
    font-weight: 800;
    letter-spacing: -0.035em;
    margin-bottom: clamp(28px, 4vw, 52px);
    max-width: 17ch;
}

.title-small {
    font-size: clamp(1.5rem, 3vw, 2.1rem);
    max-width: none;
    margin-bottom: 20px;
}

.title-light {
    color: #fff;
}

.lead {
    font-size: clamp(1.08rem, 1.5vw, 1.25rem);
    color: var(--muted);
    max-width: 40ch;
    margin-block: 24px 32px;
}

.body-lg {
    font-size: clamp(1.05rem, 1.4vw, 1.18rem);
    color: var(--muted);
    max-width: 52ch;
}

.eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 18px;
    font-size: 0.76rem;
    font-weight: 800;
    letter-spacing: 0.16em;
    text-transform: uppercase;
    color: var(--accent);
}

html[dir="rtl"] .eyebrow {
    letter-spacing: 0;
    font-size: 1rem;
}

.eyebrow-light {
    color: var(--copper-light);
}

.dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--copper);
    animation: pulse 2.4s infinite;
}

.fine {
    color: var(--muted);
    font-size: 0.92rem;
    margin-top: 24px;
}

.more-link {
    margin-top: 28px;
}

.more-link a {
    font-weight: 700;
    text-decoration: none;
    background: linear-gradient(currentColor, currentColor) 0 100% / 0 2px no-repeat;
    transition: background-size 0.3s ease;
}

.more-link a:hover {
    background-size: 100% 2px;
}

/* ── Announcement + header ────────────────────────────────────────────────────── */
.announce {
    background: var(--purple-deep);
    color: #f3e9f5;
    font-size: 0.88rem;
    text-align: center;
    padding: 9px 0;
}

.announce a {
    color: var(--copper-light);
    text-decoration: none;
}

.site-header {
    position: sticky;
    top: 0;
    z-index: 50;
    backdrop-filter: saturate(160%) blur(16px);
    -webkit-backdrop-filter: saturate(160%) blur(16px);
    background: var(--glass);
    border-bottom: 1px solid var(--line);
}

.header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    min-height: 72px;
    gap: 16px;
}

.brand {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    text-decoration: none;
    color: var(--ink-loud);
}

.brand-logo {
    width: 34px;
    height: auto;
    filter: drop-shadow(0 2px 3px rgba(73, 32, 85, 0.25));
}

.brand-name {
    font-size: 1.3rem;
    font-weight: 800;
    letter-spacing: -0.03em;
    direction: ltr;
    white-space: nowrap;
}

.nav {
    display: flex;
    align-items: center;
    gap: 4px;
}

.nav a {
    white-space: nowrap;
    padding: 8px 12px;
    border-radius: 999px;
    color: var(--ink);
    font-size: 0.94rem;
    font-weight: 600;
    text-decoration: none;
    transition: background-color 0.2s ease, color 0.2s ease;
}

.nav a:hover {
    background: var(--tint);
    color: var(--accent-strong);
}

/* A feature that is announced but not live yet. */
.soon {
    margin-inline-start: 4px;
    padding: 1px 7px;
    border-radius: 999px;
    border: 1px solid var(--copper-light);
    color: var(--copper-light);
    font-size: 0.68rem;
    font-weight: 700;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    vertical-align: 2px;
}

.nav .lang {
    font-family: "Noto Nastaliq Urdu", serif;
}

.nav-desktop {
    display: none;
}

.menu summary {
    display: none;
    list-style: none;
    cursor: pointer;
}

.menu summary::-webkit-details-marker {
    display: none;
}

@media (min-width: 1280px) {
    .nav-desktop {
        display: flex;
    }

    .menu {
        display: none;
    }
}

@media (max-width: 1279px) {
    .menu summary {
        display: grid;
        gap: 5px;
        place-content: center;
        width: 44px;
        height: 44px;
        border-radius: 12px;
        border: 1px solid var(--line);
        background: var(--surface);
    }

    .menu summary span {
        display: block;
        width: 18px;
        height: 2px;
        border-radius: 2px;
        background: var(--ink-loud);
        transition: transform 0.25s ease, opacity 0.25s ease;
    }

    .menu[open] summary span:nth-child(1) {
        transform: translateY(7px) rotate(45deg);
    }

    .menu[open] summary span:nth-child(2) {
        opacity: 0;
    }

    .menu[open] summary span:nth-child(3) {
        transform: translateY(-7px) rotate(-45deg);
    }

    .menu>.nav {
        position: absolute;
        inset-inline: var(--gutter);
        top: 80px;
        flex-direction: column;
        align-items: stretch;
        padding: 12px;
        border-radius: var(--radius);
        background: var(--surface);
        border: 1px solid var(--line);
        box-shadow: var(--shadow-lg);
    }

    .menu>.nav a {
        padding: 14px 16px;
        font-size: 1.05rem;
    }

    .menu>.nav .btn {
        margin-top: 8px;
        text-align: center;
    }
}

/* ── Buttons + store badges ───────────────────────────────────────────────────── */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 14px 24px;
    border-radius: 999px;
    background: linear-gradient(140deg, var(--purple-light), var(--purple-dark));
    color: #fff !important;
    font-weight: 700;
    text-decoration: none;
    white-space: nowrap;
    box-shadow: var(--shadow);
    transition: transform 0.2s ease, filter 0.2s ease;
}

.btn:hover {
    transform: translateY(-2px);
    filter: brightness(1.1);
}

.btn-small {
    padding: 9px 18px;
    font-size: 0.9rem;
}

.stores {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
}

.store {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    min-width: 186px;
    padding: 11px 20px 11px 16px;
    border-radius: 16px;
    background: var(--ink-loud);
    color: var(--ground);
    text-decoration: none;
    line-height: 1.15;
    font-weight: 700;
    font-size: 1.05rem;
    box-shadow: var(--shadow);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

a.store:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-lg);
}

.store svg {
    width: 26px;
    height: 26px;
    flex: none;
}

.store span {
    display: flex;
    flex-direction: column;
    direction: ltr;
}

.store small {
    font-size: 0.68rem;
    font-weight: 500;
    letter-spacing: 0.03em;
    opacity: 0.75;
}

.store.is-soon {
    background: transparent;
    color: var(--ink-loud);
    border: 1.5px dashed color-mix(in srgb, var(--ink) 30%, transparent);
    box-shadow: none;
}

/* ── Device: a real screenshot in a phone with physical depth ─────────────────── */
/* The ::after is the phone's back plate, pushed behind the screen in 3D space, so
   the phone reads as a solid object as soon as it turns. */
.device {
    position: relative;
    margin: 0;
    width: min(290px, 70vw);
    padding: 9px;
    border-radius: 46px;
    background: linear-gradient(160deg, #3a2341, #120a14);
    box-shadow: inset 0 0 0 1.5px rgba(255, 255, 255, 0.1);
    transform-style: preserve-3d;
}

.device::after {
    content: "";
    position: absolute;
    inset: 0;
    z-index: -1;
    border-radius: inherit;
    background: linear-gradient(160deg, #24152a, #070308);
    transform: translateZ(-16px);
    box-shadow: var(--shadow-lg);
}

.device img {
    position: relative;
    width: 100%;
    height: auto;
    border-radius: 38px;
    background: var(--ivory);
    transform: translateZ(1px);
}

.device-island {
    position: absolute;
    top: 18px;
    left: 50%;
    z-index: 2;
    width: 30%;
    height: 22px;
    translate: -50% 0;
    border-radius: 999px;
    background: #0b060c;
    transform: translateZ(2px);
}

/* ── Hero ─────────────────────────────────────────────────────────────────────── */
.hero {
    position: relative;
    isolation: isolate;
    overflow: hidden;
    padding-block: clamp(40px, 7vw, 96px) clamp(120px, 18vw, 250px);
}

.hero::before,
.hero::after,
.aurora {
    content: "";
    position: absolute;
    z-index: -2;
    border-radius: 50%;
    filter: blur(70px);
    opacity: 0.55;
    pointer-events: none;
}

.hero::before {
    width: 52vw;
    height: 52vw;
    max-width: 720px;
    max-height: 720px;
    inset-inline-end: -10vw;
    top: -16vw;
    background: radial-gradient(circle, rgba(206, 138, 99, 0.55), transparent 65%);
    animation: drift 18s ease-in-out infinite alternate;
}

.hero::after {
    width: 46vw;
    height: 46vw;
    max-width: 640px;
    max-height: 640px;
    inset-inline-start: -16vw;
    bottom: -18vw;
    background: radial-gradient(circle, rgba(107, 47, 125, 0.45), transparent 65%);
    animation: drift 22s ease-in-out infinite alternate-reverse;
}

/* Pakistan's landmarks behind the phones, with the neighbourhood's rooftops in front.
   Each layer is a little wider than the screen so it has room to slide as the page
   scrolls: the landmarks drift one way and rise, the rooftops the other, which is what
   reads as depth. */
.skyline {
    position: absolute;
    inset-inline: 0;
    bottom: 0;
    z-index: -1;
    height: clamp(150px, 24vw, 330px);
    overflow: hidden;
    pointer-events: none;
}

.skyline img {
    position: absolute;
    bottom: 0;
    left: -6%;
    width: 112%;
    /* The base `img { max-width: 100% }` would cancel the extra width the slide needs. */
    max-width: none;
    object-fit: cover;
    object-position: bottom;
    will-change: transform;
}

.skyline-far {
    height: 100%;
}

.skyline-near {
    height: 46%;
}

@supports (animation-timeline: scroll()) {
    .skyline img {
        animation-timing-function: linear;
        animation-fill-mode: both;
        animation-timeline: scroll(root);
        animation-range: 0 100vh;
    }

    .skyline-far {
        animation-name: skyline-far;
    }

    .skyline-near {
        animation-name: skyline-near;
    }
}

@keyframes skyline-far {
    to {
        transform: translate3d(-4%, -6%, 0);
    }
}

@keyframes skyline-near {
    to {
        transform: translate3d(5%, 4%, 0);
    }
}

/* ── Centre stage: three real screens fanned out in 3D ─────────────────────── */
.hero-stage {
    padding-top: clamp(28px, 4vw, 56px);
    padding-bottom: clamp(40px, 6vw, 90px);
}

.hero-center {
    text-align: center;
}

.hero-center .display {
    max-width: 13ch;
    margin-inline: auto;
}

.hero-center .lead {
    margin-inline: auto;
}

.hero-center .stores {
    justify-content: center;
}

.stage {
    position: relative;
    height: clamp(420px, 56vw, 700px);
    margin-top: clamp(20px, 3vw, 36px);
    perspective: 1600px;
    perspective-origin: 50% 20%;
    transform-style: preserve-3d;
}

/* A giant outlined word behind the phones, drifting the other way on scroll. */
.stage-word {
    position: absolute;
    top: 22%;
    left: 50%;
    translate: -50% 0;
    font-size: clamp(3.4rem, 14vw, 13rem);
    font-weight: 800;
    font-style: italic;
    letter-spacing: -0.06em;
    line-height: 1;
    white-space: nowrap;
    color: transparent;
    -webkit-text-stroke: 2px color-mix(in srgb, var(--copper) 55%, transparent);
    pointer-events: none;
    user-select: none;
}

.fan {
    position: absolute;
    top: 0;
    left: 50%;
    width: clamp(170px, 22vw, 300px);
    margin-left: calc(clamp(170px, 22vw, 300px) / -2);
}

.fan-center {
    z-index: 3;
    transform: translateZ(80px);
}

.fan-left {
    z-index: 2;
    top: 9%;
    transform: translateX(-82%) translateZ(-60px) rotateY(32deg) rotateZ(-7deg);
}

.fan-right {
    z-index: 2;
    top: 9%;
    transform: translateX(82%) translateZ(-60px) rotateY(-32deg) rotateZ(7deg);
}

@media (max-width: 640px) {
    .hero-stage {
        padding-top: 28px;
    }

    .hero-center .lead {
        font-size: 1rem;
        margin-block: 16px 22px;
    }

    .stage {
        height: 400px;
        margin-top: 28px;
    }

    .fan {
        width: 170px;
        margin-left: -85px;
    }

    .fan-left {
        transform: translateX(-62%) translateZ(-60px) rotateY(30deg) rotateZ(-7deg);
    }

    .fan-right {
        transform: translateX(62%) translateZ(-60px) rotateY(-30deg) rotateZ(7deg);
    }

}

/* Scrolling opens the fan wider, lifts the centre phone and slides the word. */
@supports (animation-timeline: scroll()) {

    .fan,
    .stage-word {
        animation-timeline: scroll(root);
        animation-range: 0 80vh;
        animation-fill-mode: both;
        animation-timing-function: linear;
    }

    .fan-center {
        animation-name: fan-lift;
    }

    .fan-left {
        animation-name: fan-open-left;
    }

    .fan-right {
        animation-name: fan-open-right;
    }

    .stage-word {
        animation-name: word-slide;
    }
}

@keyframes fan-lift {
    to {
        transform: translateZ(160px) translateY(-6%) rotateX(8deg);
    }
}

@keyframes fan-open-left {
    to {
        transform: translateX(-118%) translateY(6%) translateZ(-140px) rotateY(48deg) rotateZ(-12deg);
    }
}

@keyframes fan-open-right {
    to {
        transform: translateX(118%) translateY(6%) translateZ(-140px) rotateY(-48deg) rotateZ(12deg);
    }
}

@keyframes word-slide {
    to {
        translate: -62% 0;
    }
}

/* ── The verified file: a dark, lit stage with dossier callouts ──────────────── */
.dark-stage {
    --mono: ui-monospace, "SF Mono", "JetBrains Mono", Menlo, Consolas, monospace;
    background:
        radial-gradient(ellipse 60% 55% at 50% 62%, rgba(122, 68, 138, 0.55), transparent 70%),
        radial-gradient(ellipse 40% 30% at 50% 100%, rgba(206, 138, 99, 0.28), transparent 70%),
        #0e0910;
    color: #e9dcec;
}

.dark-stage::before,
.dark-stage::after,
.dark-stage .aurora {
    display: none;
}

.dark-stage .display {
    color: #fff;
}

.dark-stage .display em {
    position: relative;
    color: var(--copper-light);
}

/* A hand-drawn copper stroke under the accent word. */
.dark-stage .display em::after {
    content: "";
    position: absolute;
    inset-inline: 2% 6%;
    bottom: -0.08em;
    height: 0.18em;
    background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 200 14' preserveAspectRatio='none'%3E%3Cpath d='M2 9 C 40 2, 90 13, 130 6 S 185 4, 198 8' fill='none' stroke='%23CE8A63' stroke-width='4' stroke-linecap='round'/%3E%3C/svg%3E") center / 100% 100% no-repeat;
}

.dark-stage .lead {
    color: #cbbccf;
    margin-block: 18px 26px;
}

.dark-stage .display {
    font-size: clamp(2.6rem, 6.4vw, 5rem);
}

/* Every page opens on a dark stage, so the header is dark everywhere. */
.site-header {
    background: rgba(14, 9, 16, 0.9);
    border-bottom-color: rgba(255, 255, 255, 0.08);
}

.site-header .brand,
.nav-desktop a,
.page-home-ur .site-header .nav a {
    color: #f3e6ec;
}

.nav-desktop a:hover {
    background: rgba(255, 255, 255, 0.08);
    color: #fff;
}

.menu summary {
    background: rgba(255, 255, 255, 0.06);
    border-color: rgba(255, 255, 255, 0.14);
}

.menu summary span {
    background: #fff;
}

.dark-stage .eyebrow {
    color: var(--copper-light);
}

.dark-stage .store.is-soon {
    color: #fff;
    border-color: rgba(255, 255, 255, 0.35);
}

.dark-stage .skyline-far {
    opacity: 0.85;
}

/* Blueprint grid, fading out towards the edges. */
.blueprint {
    position: absolute;
    inset: 0;
    z-index: -1;
    background:
        linear-gradient(rgba(220, 171, 142, 0.08) 1px, transparent 1px) 0 0 / 64px 64px,
        linear-gradient(90deg, rgba(220, 171, 142, 0.08) 1px, transparent 1px) 0 0 / 64px 64px;
    mask-image: radial-gradient(ellipse 70% 70% at 50% 55%, #000 30%, transparent 75%);
    pointer-events: none;
}

.dark-stage .stage-word {
    -webkit-text-stroke-color: rgba(220, 171, 142, 0.32);
}

/* The phones stand on a mirror floor. */
.dark-stage .fan {
    -webkit-box-reflect: below 6px linear-gradient(transparent 72%, rgba(255, 255, 255, 0.16));
}

.dark-stage .device::after {
    box-shadow: 0 40px 80px -20px rgba(0, 0, 0, 0.8), 0 0 60px rgba(206, 138, 99, 0.12);
}

/* A rubber stamp that thumps down onto the centre phone. */
.stamp {
    position: absolute;
    z-index: 5;
    top: 44%;
    left: 50%;
    display: grid;
    justify-items: center;
    padding: 10px 22px 8px;
    border: 3px solid #e2735b;
    border-radius: 10px;
    outline: 1.5px solid #e2735b;
    outline-offset: 4px;
    color: #e2735b;
    font-family: var(--mono);
    text-transform: uppercase;
    background: rgba(14, 9, 16, 0.55);
    backdrop-filter: blur(2px);
    transform: translate(-50%, 0) rotate(-12deg) translateZ(260px);
    animation: stamp-down 0.9s cubic-bezier(0.3, 1.6, 0.5, 1) 0.6s both;
}

.stamp b {
    font-size: clamp(1.4rem, 2.6vw, 2.2rem);
    font-weight: 800;
    letter-spacing: 0.18em;
    line-height: 1;
}

.stamp small {
    margin-top: 4px;
    font-size: 0.62rem;
    letter-spacing: 0.22em;
}

/* Technical-drawing callouts: a leader line and a dot pointing into the phones. */
.callout {
    position: absolute;
    z-index: 4;
    /* In front of the phones in 3D space, so a fanned-out phone never covers a label. */
    transform: translateZ(240px) scale(0.86);
    display: grid;
    gap: 2px;
    font-family: var(--mono);
    font-size: 0.78rem;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: #f3e6ec;
    white-space: nowrap;
}

.callout i {
    font-style: normal;
    font-size: 0.66rem;
    letter-spacing: 0.16em;
    color: var(--copper-light);
}

.callout::before,
.callout::after {
    content: "";
    position: absolute;
    top: 50%;
}

.callout::before {
    width: clamp(40px, 7vw, 110px);
    height: 1px;
    background: linear-gradient(90deg, rgba(220, 171, 142, 0.9), rgba(220, 171, 142, 0.2));
}

.callout::after {
    width: 7px;
    height: 7px;
    margin-top: -3px;
    border-radius: 50%;
    background: var(--copper);
    box-shadow: 0 0 0 4px rgba(206, 138, 99, 0.25);
}

/* Left-hand callouts point right, into the phones; right-hand ones point left. */
.callout-a,
.callout-c {
    text-align: right;
}

.callout-a::before,
.callout-c::before {
    left: calc(100% + 12px);
}

.callout-a::after,
.callout-c::after {
    left: calc(100% + 12px + clamp(40px, 7vw, 110px));
}

.callout-b::before,
.callout-d::before {
    right: calc(100% + 12px);
    background: linear-gradient(270deg, rgba(220, 171, 142, 0.9), rgba(220, 171, 142, 0.2));
}

.callout-b::after,
.callout-d::after {
    right: calc(100% + 12px + clamp(40px, 7vw, 110px));
}

.callout-a {
    top: 10%;
    right: calc(50% + clamp(250px, 29vw, 420px));
}

.callout-c {
    top: 46%;
    right: calc(50% + clamp(250px, 29vw, 420px));
}

.callout-b {
    top: 20%;
    left: calc(50% + clamp(250px, 29vw, 420px));
}

.callout-d {
    top: 54%;
    left: calc(50% + clamp(250px, 29vw, 420px));
}

@media (max-width: 900px) {
    .callout {
        display: none;
    }
}

@media (min-width: 901px) {
    .stamp {
        top: 18%;
    }
}

@keyframes stamp-down {
    from {
        opacity: 0;
        transform: translate(-50%, 0) rotate(-24deg) translateZ(260px) scale(2.6);
    }

    to {
        opacity: 1;
        transform: translate(-50%, 0) rotate(-12deg) translateZ(260px) scale(1);
    }
}

/* ── Statement: the ink fills in, word by word, as it scrolls past ─────────── */
.statement {
    padding-block: clamp(80px, 12vw, 160px);
}

.statement-text {
    margin-block: 0;
    font-size: clamp(2.2rem, 6.4vw, 5.4rem);
    font-weight: 800;
    letter-spacing: -0.045em;
    line-height: 1.04;
    color: var(--ink-loud);
}

.statement-text em {
    display: block;
    margin-top: 0.3em;
    font-style: italic;
    font-weight: 700;
    color: var(--accent-soft);
}

@supports (animation-timeline: view()) {
    .statement-text span {
        color: transparent;
        background: linear-gradient(90deg, var(--ink-loud) 50%, color-mix(in srgb, var(--ink) 14%, transparent) 50%);
        background-size: 200% 100%;
        background-position: 100% 0;
        -webkit-background-clip: text;
        background-clip: text;
        animation: ink-fill linear both;
        animation-timeline: view();
        animation-range: cover 20% cover 45%;
    }

    .statement-text span:nth-child(2) {
        animation-range: cover 28% cover 53%;
    }

    .statement-text span:nth-child(3) {
        animation-range: cover 36% cover 61%;
    }
}

@keyframes ink-fill {
    to {
        background-position: 0 0;
    }
}

/* ── Story: a 3D phone that turns as you scroll, screens flipping in ──────────── */
.story {
    padding-block: var(--space);
}

.story-grid {
    display: grid;
    gap: 40px;
}

.story-step {
    padding-block: 36px;
    border-top: 1px solid var(--line);
}

.story-step h3 {
    font-size: clamp(1.7rem, 3.4vw, 2.6rem);
    font-weight: 800;
    letter-spacing: -0.035em;
    margin-bottom: 14px;
    max-width: 18ch;
}

.story-step p {
    font-size: 1.12rem;
    color: var(--muted);
    max-width: 40ch;
}

/* Without scroll timelines — or on a phone — every step shows its own screen. */
.step-shot {
    margin-top: 28px;
    width: min(250px, 66vw);
}

.story-stage {
    display: none;
}

/* Below the desktop layout each step's phone turns on its own: with the scroll where
   the browser can, otherwise a slow sway, so a phone never sees a flat screenshot. */
@media (max-width: 959px) {
    .story-step {
        perspective: 1200px;
    }

    .step-shot {
        margin-inline: auto;
        animation: phone-sway 9s ease-in-out infinite;
    }

    @supports (animation-timeline: view()) {
        .step-shot {
            animation: phone-turn linear both;
            animation-timeline: view();
            animation-range: cover 0% cover 100%;
        }
    }
}

@supports (animation-timeline: view()) {
    @media (min-width: 960px) {
        .story-grid {
            grid-template-columns: 1fr 1fr;
            gap: 64px;
            timeline-scope: --story, --step-listing, --step-profile;
        }

        .story-steps {
            view-timeline-name: --story;
        }

        .story-step {
            min-height: 80vh;
            display: flex;
            flex-direction: column;
            justify-content: center;
            animation: step-focus linear both;
            animation-timeline: view();
            animation-range: cover 0% cover 100%;
        }

        #step-listing {
            view-timeline-name: --step-listing;
        }

        #step-profile {
            view-timeline-name: --step-profile;
        }

        .step-shot {
            display: none;
        }

        .story-stage {
            position: sticky;
            top: 0;
            height: 100vh;
            display: grid;
            place-items: center;
            perspective: 1200px;
        }

        .story-phone {
            position: relative;
            z-index: 1;
            width: 300px;
            aspect-ratio: 430 / 923;
            padding: 10px;
            border-radius: 48px;
            background: linear-gradient(160deg, #3a2341, #120a14);
            box-shadow: inset 0 0 0 1.5px rgba(255, 255, 255, 0.1);
            transform-style: preserve-3d;
            animation: phone-turn linear both;
            animation-timeline: --story;
            animation-range: contain 0% contain 100%;
        }

        .story-phone::after {
            content: "";
            position: absolute;
            inset: 0;
            border-radius: inherit;
            background: linear-gradient(160deg, #24152a, #070308);
            transform: translateZ(-18px);
            box-shadow: 0 60px 100px -30px rgba(73, 32, 85, 0.6);
        }

        .story-phone .screen {
            position: absolute;
            inset: 10px;
            width: calc(100% - 20px);
            height: calc(100% - 20px);
            border-radius: 40px;
            object-fit: cover;
            object-position: top;
            backface-visibility: hidden;
            transform: translateZ(1px);
        }

        /* Each new screen flips in like a card turning over. */
        .screen-2,
        .screen-3 {
            transform-origin: 0 50%;
            animation: screen-flip linear both;
            animation-range: entry 55% cover 48%;
        }

        .screen-2 {
            animation-timeline: --step-listing;
        }

        .screen-3 {
            animation-timeline: --step-profile;
        }

        .story-phone .device-island {
            transform: translateZ(3px);
        }

        .stage-ring {
            position: absolute;
            width: 540px;
            height: 540px;
            border-radius: 50%;
            background:
                radial-gradient(circle, rgba(206, 138, 99, 0.25), transparent 60%),
                conic-gradient(from 0deg, transparent, rgba(107, 47, 125, 0.18), transparent 40%);
            transform: rotateX(70deg) translateZ(-260px);
            animation: spin-flat 30s linear infinite;
        }
    }
}

/* ── Stacked panels: each slides over the last, which tips back into depth ────── */
.stack {
    position: relative;
}

.panel {
    position: relative;
    padding-block: var(--space);
    border-radius: 44px 44px 0 0;
    margin-top: -44px;
    box-shadow: 0 -24px 60px -30px rgba(42, 20, 48, 0.35);
    perspective: 1400px;
}

.panel-light {
    background: var(--ground);
}

.panel-tint {
    background: var(--tint);
}

.panel-dark {
    background:
        radial-gradient(circle at 90% 0%, rgba(206, 138, 99, 0.3), transparent 40%),
        radial-gradient(circle at 0% 100%, rgba(122, 68, 138, 0.55), transparent 45%),
        var(--purple-deep);
    color: #e9dcec;
}

@supports (animation-timeline: view()) {
    .panel>.wrap {
        transform-origin: 50% 0%;
        animation: tip-back linear both;
        animation-timeline: view();
        animation-range: exit 45% exit 100%;
    }

    .panel .question-card,
    .panel .tile,
    .panel .audience-card {
        transform-origin: 50% 100%;
        animation: tilt-up linear both;
        animation-timeline: view();
        animation-range: entry 0% entry 90%;
    }
}

/* ── Question cards ───────────────────────────────────────────────────────────── */
.split {
    display: grid;
    gap: 20px;
}

@media (min-width: 820px) {
    .split {
        grid-template-columns: 1fr 1fr;
        gap: 28px;
    }
}

.question-card {
    padding: clamp(24px, 3vw, 40px);
    border-radius: var(--radius-lg);
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(255, 255, 255, 0.12);
    text-align: center;
}

.question-card h3 {
    font-size: clamp(1.4rem, 2.4vw, 1.9rem);
    font-weight: 800;
    font-style: italic;
    color: #fff;
    margin-bottom: 10px;
}

.question-card p {
    color: #d8c8dc;
    margin: 0 auto;
    max-width: 36ch;
}

.question-art {
    width: 100%;
    max-width: 300px;
    height: auto;
    margin: 0 auto 14px;
    border-radius: 24px;
    background: var(--ivory);
}

/* The Urdu page uses these cards on a light ground. */
.section .question-card {
    background: var(--surface);
    border-color: var(--line);
}

.section .question-card h3 {
    color: var(--ink-loud);
}

.section .question-card p {
    color: var(--muted);
}

/* ── Bento ────────────────────────────────────────────────────────────────────── */
.bento {
    display: grid;
    gap: 16px;
}

@media (min-width: 720px) {
    .bento {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (min-width: 1040px) {
    .bento {
        grid-template-columns: repeat(4, 1fr);
    }

    .tile-wide {
        grid-column: span 2;
        display: grid;
        grid-template-columns: 0.9fr 1.1fr;
        align-items: center;
        column-gap: 24px;
    }

    .tile-wide .tile-art {
        grid-row: span 3;
        margin: 0;
    }
}

.tile {
    position: relative;
    display: flex;
    flex-direction: column;
    gap: 8px;
    padding: clamp(22px, 3vw, 30px);
    border-radius: var(--radius-lg);
    background: var(--surface);
    border: 1px solid var(--line);
    box-shadow: var(--shadow);
    overflow: hidden;
    transition: box-shadow 0.3s ease;
}

.tile:hover {
    box-shadow: var(--shadow-lg);
}

.tile h3 {
    font-size: clamp(1.2rem, 1.8vw, 1.45rem);
    font-weight: 800;
}

.tile p {
    color: var(--muted);
    margin: 0;
}

.tile-art {
    width: 100%;
    max-width: 230px;
    height: auto;
    margin: 0 auto 8px;
    transition: transform 0.5s ease;
}

.tile:hover .tile-art {
    transform: scale(1.06) rotate(-2deg);
}

.tile-dark {
    background:
        radial-gradient(circle at 85% 0%, rgba(206, 138, 99, 0.45), transparent 50%),
        linear-gradient(150deg, var(--purple), var(--purple-deep));
    border-color: transparent;
}

.tile-dark h3 {
    color: #fff;
}

.tile-copper {
    background:
        radial-gradient(circle at 10% 100%, rgba(255, 255, 255, 0.35), transparent 45%),
        linear-gradient(140deg, var(--copper-light), var(--copper));
    border-color: transparent;
}

.tile-copper h3,
.tile-copper p {
    color: var(--purple-deep);
}

.badge-row {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 6px;
}

.badge-row span,
.pill {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 7px 14px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.14);
    border: 1px solid rgba(255, 255, 255, 0.22);
    color: #fff;
    font-size: 0.85rem;
    font-weight: 700;
}

.badge-row span::before,
.pill::before {
    content: "✓";
    color: var(--copper-light);
}

/* ── Audience ─────────────────────────────────────────────────────────────────── */
/* Each card carries its own --tone: a glow behind the art, the hover border and the
   arrow. Two cards run wide, so the grid reads as a layout rather than a spreadsheet. */
.audience {
    display: grid;
    gap: 16px;
}

@media (min-width: 640px) {
    .audience {
        grid-template-columns: repeat(2, 1fr);
    }

    .audience-wide {
        grid-column: span 2;
    }
}

@media (min-width: 1040px) {
    .audience {
        grid-template-columns: repeat(3, 1fr);
        gap: 20px;
    }

    /* Two classes: the base `.audience-card` comes later in this file and would win. */
    .audience-card.audience-wide {
        flex-direction: row;
    }

    .audience-wide .audience-art {
        order: 2;
        flex: 1.1;
        height: auto;
    }

    .audience-wide .audience-art img {
        height: 210px;
    }

    .audience-wide .audience-body {
        flex: 1;
        padding: 32px;
    }

    .audience-card.audience-wide h3 {
        font-size: clamp(1.6rem, 2.4vw, 2.1rem);
    }

    .audience-card.audience-wide .audience-line {
        font-size: 1.05rem;
    }
}

.audience-card {
    --tone: var(--purple);
    position: relative;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    border-radius: var(--radius-lg);
    background:
        radial-gradient(circle at 100% 100%, color-mix(in srgb, var(--tone) 14%, transparent), transparent 55%),
        var(--surface);
    border: 1px solid var(--line);
    box-shadow: var(--shadow);
    color: var(--ink);
    text-decoration: none;
    transition: transform 0.35s cubic-bezier(0.2, 0.8, 0.2, 1), border-color 0.25s ease,
        box-shadow 0.35s ease;
}

.audience-art {
    display: grid;
    place-items: center;
    height: 190px;
    overflow: hidden;
    background:
        radial-gradient(circle at 50% 60%, color-mix(in srgb, var(--tone) 38%, transparent), transparent 62%),
        linear-gradient(160deg, color-mix(in srgb, var(--tone) 12%, var(--tint)), var(--tint));
}

.audience-art img {
    width: auto;
    height: 100%;
    max-width: 100%;
    object-fit: contain;
    transition: transform 0.5s cubic-bezier(0.2, 0.8, 0.2, 1);
}

.audience-body {
    flex: 1;
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 16px;
    padding: 20px 22px 22px 24px;
}

.audience-text {
    display: grid;
    gap: 6px;
}

.audience-card h3 {
    font-size: 1.25rem;
    font-weight: 800;
}

.audience-line {
    color: var(--muted);
    font-size: 0.95rem;
    line-height: 1.45;
}

.audience-card .soon {
    color: var(--accent);
    border-color: currentColor;
    font-size: 0.62rem;
    vertical-align: 4px;
}

.audience-card .arrow {
    flex: none;
    display: grid;
    place-items: center;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    border: 1.5px solid color-mix(in srgb, var(--tone) 45%, transparent);
    color: var(--accent);
    transition: transform 0.25s ease, background-color 0.25s ease, color 0.25s ease;
}

.audience-card:hover {
    transform: translateY(-6px);
    border-color: color-mix(in srgb, var(--tone) 70%, transparent);
    box-shadow: var(--shadow-lg);
}

.audience-card:hover .audience-art img {
    transform: scale(1.08) rotate(-2deg);
}

.audience-card:hover .arrow {
    transform: rotate(-45deg);
    background: var(--tone);
    border-color: var(--tone);
    color: #fff;
}

/* `ul[role="list"]` resets margins with a higher specificity than a single class. */
.chips.areas-row {
    margin-top: 32px;
}

/* ── Chips, lists, cards ──────────────────────────────────────────────────────── */
.chips {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 0;
}

.chips li {
    padding: 10px 18px;
    border-radius: 999px;
    background: var(--surface);
    border: 1px solid var(--line);
    font-weight: 600;
    font-size: 0.95rem;
}

.chips-links li {
    padding: 0;
}

.chips-links a {
    display: block;
    padding: 10px 18px;
    border-radius: 999px;
    color: var(--ink);
    text-decoration: none;
    transition: background-color 0.2s ease, color 0.2s ease;
}

.chips-links a:hover {
    background: var(--accent);
    color: var(--on-accent);
}

.checklist {
    counter-reset: item;
    display: grid;
    gap: 12px;
}

.checklist li {
    counter-increment: item;
    position: relative;
    padding: 18px 20px 18px 64px;
    border-radius: 18px;
    background: var(--surface);
    border: 1px solid var(--line);
    font-weight: 500;
}

.checklist li::before {
    content: counter(item);
    position: absolute;
    inset-inline-start: 18px;
    top: 16px;
    display: grid;
    place-items: center;
    width: 30px;
    height: 30px;
    border-radius: 50%;
    background: var(--tint);
    color: var(--accent);
    font-weight: 800;
    font-size: 0.9rem;
}

.cards-3 {
    display: grid;
    gap: 16px;
    perspective: 1200px;
}

@media (min-width: 860px) {
    .cards-3 {
        grid-template-columns: repeat(3, 1fr);
        gap: 20px;
    }
}

.info-card {
    padding: clamp(24px, 3vw, 34px);
    border-radius: var(--radius-lg);
    background: var(--surface);
    border: 1px solid var(--line);
    box-shadow: var(--shadow);
}

.info-card h3 {
    font-size: 1.2rem;
    margin-bottom: 8px;
}

.info-card p {
    color: var(--muted);
    margin: 0;
}

/* Illustrated cards: art on top, two short lines, a conic border and a 3D lift on
   hover. */
.art-card {
    position: relative;
    isolation: isolate;
    padding: 16px 16px 26px;
    border-radius: var(--radius-lg);
    background: var(--surface);
    border: 1px solid var(--line);
    box-shadow: var(--shadow);
    text-align: center;
    transform-style: preserve-3d;
    transition: transform 0.45s cubic-bezier(0.2, 0.8, 0.2, 1), box-shadow 0.45s ease;
}

.art-card::before {
    content: "";
    position: absolute;
    inset: -1px;
    z-index: -1;
    border-radius: inherit;
    padding: 2px;
    background: conic-gradient(from var(--angle, 0deg), transparent 0 70%, var(--copper) 85%, var(--purple) 100%);
    -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
    -webkit-mask-composite: xor;
    mask-composite: exclude;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.art-card:hover {
    transform: translateY(-8px) rotateX(8deg) rotateY(-6deg);
    box-shadow: var(--shadow-lg);
}

.art-card:hover::before {
    opacity: 1;
    animation: sweep 2.4s linear infinite;
}

.art-card-art {
    margin-bottom: 14px;
    border-radius: 22px;
    background: var(--tint);
    overflow: hidden;
    transform: translateZ(30px);
}

.art-card-art img {
    width: 100%;
    height: auto;
}

.art-card h3 {
    font-size: 1.3rem;
    font-weight: 800;
    margin-bottom: 6px;
    transform: translateZ(20px);
}

.art-card p {
    margin: 0;
    color: var(--muted);
}

@supports (animation-timeline: view()) {
    .cards-3>.art-card {
        animation: tilt-up linear both;
        animation-timeline: view();
        animation-range: entry 0% entry 90%;
    }
}

.badge-table {
    display: grid;
    gap: 12px;
    margin: 0;
}

.badge-table div {
    display: grid;
    gap: 8px;
    align-items: center;
    padding: 20px 24px;
    border-radius: 20px;
    background: var(--surface);
    border: 1px solid var(--line);
}

@media (min-width: 700px) {
    .badge-table div {
        grid-template-columns: 240px 1fr;
    }
}

.badge-table dd {
    margin: 0;
    color: var(--muted);
}

.pill {
    background: var(--purple);
    border: none;
}

.pill-copper {
    background: var(--copper-dark);
}

.pill-dark {
    background: var(--purple-deep);
}

.side-art {
    width: min(100%, 440px);
    height: auto;
    margin-inline: auto;
}

.promise {
    text-align: center;
}

.promise .title,
.promise .body-lg {
    margin-inline: auto;
}

/* ── FAQ ──────────────────────────────────────────────────────────────────────── */
.faq {
    display: grid;
    gap: 12px;
}

.faq details {
    border-radius: 20px;
    background: var(--surface);
    border: 1px solid var(--line);
    transition: box-shadow 0.25s ease;
}

.faq details[open] {
    box-shadow: var(--shadow);
}

.faq summary {
    position: relative;
    padding: 22px 64px 22px 24px;
    cursor: pointer;
    list-style: none;
    font-weight: 700;
    font-size: 1.05rem;
    color: var(--ink-loud);
}

.faq summary::-webkit-details-marker {
    display: none;
}

.faq summary::after {
    content: "+";
    position: absolute;
    inset-inline-end: 22px;
    top: 50%;
    translate: 0 -50%;
    display: grid;
    place-items: center;
    width: 30px;
    height: 30px;
    border-radius: 50%;
    background: var(--tint);
    color: var(--accent);
    font-size: 1.2rem;
    transition: rotate 0.25s ease;
}

.faq details[open] summary::after {
    rotate: 45deg;
}

.faq details p {
    padding: 0 24px 22px;
    margin: 0;
    color: var(--muted);
}

/* ── Inner pages ──────────────────────────────────────────────────────────────── */
.section {
    padding-block: var(--space);
}

.section-tint {
    background: var(--tint);
}

.split-wide {
    display: grid;
    gap: 36px;
    align-items: center;
}

@media (min-width: 900px) {
    .split-wide {
        grid-template-columns: 1.1fr 0.9fr;
        gap: 64px;
    }
}

.page-hero {
    position: relative;
    isolation: isolate;
    overflow: hidden;
    padding-block: clamp(36px, 6vw, 88px) clamp(56px, 8vw, 110px);
}

.page-hero .aurora {
    width: 60vw;
    height: 60vw;
    max-width: 760px;
    max-height: 760px;
    inset-inline-end: -18vw;
    top: -28vw;
    background: radial-gradient(circle, rgba(206, 138, 99, 0.5), rgba(107, 47, 125, 0.25) 45%, transparent 70%);
    animation: drift 20s ease-in-out infinite alternate;
}

.page-hero-grid {
    display: grid;
    gap: 32px;
    align-items: center;
}

@media (min-width: 900px) {
    .page-hero-grid {
        grid-template-columns: 1.1fr 0.9fr;
        gap: 56px;
    }
}

.hero-art {
    position: relative;
    display: grid;
    place-items: center;
    perspective: 1000px;
}

.hero-art img {
    position: relative;
    width: min(100%, 480px);
    height: auto;
    animation: float-3d 9s ease-in-out infinite;
}

.hero-art-glow {
    position: absolute;
    inset: 12%;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(206, 138, 99, 0.35), transparent 70%);
    filter: blur(30px);
    animation: breathe 6s ease-in-out infinite;
}

.crumbs {
    padding-top: 22px;
    font-size: 0.85rem;
}

.crumbs ol {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin: 0;
    padding: 0;
    list-style: none;
    color: var(--muted);
}

.crumbs li+li::before {
    content: "/";
    margin-inline-end: 8px;
    opacity: 0.5;
}

.crumbs a {
    color: var(--muted);
    text-decoration: none;
}

.crumbs a:hover {
    color: var(--accent);
}

/* ── Download ─────────────────────────────────────────────────────────────────── */
.download {
    position: relative;
    isolation: isolate;
    overflow: hidden;
    padding-block: var(--space);
    border-radius: 44px 44px 0 0;
    margin-top: -44px;
    background:
        radial-gradient(circle at 90% 0%, rgba(206, 138, 99, 0.35), transparent 40%),
        radial-gradient(circle at 0% 100%, rgba(122, 68, 138, 0.6), transparent 45%),
        var(--purple-deep);
    color: #e9dcec;
}

.download h2 {
    font-size: clamp(2.2rem, 5.2vw, 4rem);
    font-weight: 800;
    letter-spacing: -0.04em;
    color: #fff;
    margin-bottom: 18px;
    max-width: 14ch;
}

html[dir="rtl"] .download h2 {
    font-family: "Noto Nastaliq Urdu", serif;
    letter-spacing: 0;
    line-height: 1.8;
    max-width: none;
}

.download p {
    max-width: 44ch;
    margin-bottom: 30px;
}

.download .store {
    background: #fff;
    color: var(--purple-deep);
}

.download .store.is-soon {
    background: transparent;
    color: #fff;
    border-color: rgba(255, 255, 255, 0.4);
}

.download-inner {
    display: grid;
    gap: 40px;
    align-items: center;
}

@media (min-width: 900px) {
    .download-inner {
        grid-template-columns: 1.3fr auto 0.8fr;
    }
}

.promise-list {
    display: grid;
    gap: 14px;
}

.promise-list li {
    display: flex;
    align-items: center;
    gap: 12px;
    font-weight: 600;
    color: #fff;
}

.promise-list li::before {
    content: "✓";
    display: grid;
    place-items: center;
    flex: none;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: var(--copper);
    color: var(--purple-deep);
    font-weight: 800;
    font-size: 0.85rem;
}

.qr-codes {
    display: flex;
    gap: 16px;
}

.qr-codes figure {
    margin: 0;
    padding: 12px;
    border-radius: 20px;
    background: #fff;
    text-align: center;
}

.qr-codes img {
    width: 120px;
    height: 120px;
    border-radius: 8px;
}

.qr-codes figcaption {
    margin-top: 8px;
    font-size: 0.75rem;
    font-weight: 700;
    color: var(--purple-deep);
}

/* ── Footer ───────────────────────────────────────────────────────────────────── */
.site-footer {
    position: relative;
    padding-block: 72px 32px;
    background: var(--surface);
    border-top: 1px solid var(--line);
}

.footer-grid {
    display: grid;
    gap: 36px;
}

@media (min-width: 760px) {
    .footer-grid {
        grid-template-columns: 1.4fr 1fr 1fr 1fr;
    }
}

.footer-brand p {
    margin-top: 16px;
    color: var(--muted);
    max-width: 30ch;
}

.site-footer nav {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.site-footer h3 {
    margin-bottom: 8px;
    font-size: 0.76rem;
    font-weight: 800;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: var(--muted);
}

.site-footer nav a {
    color: var(--ink);
    text-decoration: none;
    width: fit-content;
}

.site-footer nav a:hover {
    color: var(--accent);
}

.footer-base {
    margin-top: 56px;
    padding-top: 24px;
    border-top: 1px solid var(--line);
    color: var(--muted);
    font-size: 0.86rem;
}

/* ── Motion ───────────────────────────────────────────────────────────────────── */
@property --angle {
    syntax: "<angle>";
    inherits: false;
    initial-value: 0deg;
}

@keyframes drift {
    from {
        transform: translate(0, 0) scale(1);
    }

    to {
        transform: translate(-6%, 8%) scale(1.12);
    }
}

@keyframes float {

    0%,
    100% {
        translate: 0 0;
    }

    50% {
        translate: 0 -14px;
    }
}

@keyframes float-3d {

    0%,
    100% {
        transform: rotateY(-10deg) rotateX(4deg) translateY(0);
    }

    50% {
        transform: rotateY(10deg) rotateX(-4deg) translateY(-12px);
    }
}

@keyframes spin-flat {
    from {
        transform: rotateX(70deg) translateZ(-260px) rotate(0deg);
    }

    to {
        transform: rotateX(70deg) translateZ(-260px) rotate(360deg);
    }
}

@keyframes pulse {
    0% {
        box-shadow: 0 0 0 0 rgba(206, 138, 99, 0.55);
    }

    70% {
        box-shadow: 0 0 0 10px rgba(206, 138, 99, 0);
    }

    100% {
        box-shadow: 0 0 0 0 rgba(206, 138, 99, 0);
    }
}

@keyframes sweep {
    to {
        --angle: 360deg;
    }
}

@keyframes breathe {

    0%,
    100% {
        opacity: 0.7;
        scale: 1;
    }

    50% {
        opacity: 1;
        scale: 1.08;
    }
}

/* The story phone swings through 3D space across the whole story. */
@keyframes phone-turn {
    0% {
        transform: rotateY(-32deg) rotateX(10deg) rotateZ(-3deg);
    }

    50% {
        transform: rotateY(0deg) rotateX(0deg) scale(1.04);
    }

    100% {
        transform: rotateY(32deg) rotateX(-6deg) rotateZ(3deg);
    }
}

@keyframes screen-flip {
    from {
        opacity: 0;
        transform: translateZ(1px) rotateY(-95deg);
    }

    to {
        opacity: 1;
        transform: translateZ(1px) rotateY(0deg);
    }
}

@keyframes step-focus {

    0%,
    100% {
        opacity: 0.22;
    }

    35%,
    65% {
        opacity: 1;
    }
}

/* A panel being covered tips back and away, like a card laid down. */
@keyframes tip-back {
    to {
        transform: rotateX(14deg) scale(0.93);
        opacity: 0.5;
        filter: blur(1px);
    }
}

/* Cards stand up out of the page as they arrive. */
@keyframes tilt-up {
    from {
        opacity: 0;
        transform: rotateX(-38deg) translateY(60px);
    }

    to {
        opacity: 1;
        transform: none;
    }
}

@media (prefers-reduced-motion: reduce) {

    *,
    *::before,
    *::after {
        animation: none !important;
        transition: none !important;
        scroll-behavior: auto !important;
    }

    @view-transition {
        navigation: none;
    }

    .story-phone .screen-2,
    .story-phone .screen-3 {
        display: none;
    }
}

/* ── Contact ──────────────────────────────────────────────────────────────────── */
.contact-grid {
    display: grid;
    gap: 32px;
    align-items: start;
}

@media (min-width: 900px) {
    .contact-grid {
        grid-template-columns: 0.8fr 1.2fr;
        gap: 56px;
    }
}

.contact-points {
    display: grid;
    gap: 14px;
}

.contact-points li {
    display: flex;
    gap: 14px;
    padding: 18px;
    border-radius: 20px;
    background: var(--surface);
    border: 1px solid var(--line);
}

.contact-points b {
    display: block;
    color: var(--ink-loud);
}

.contact-points div {
    color: var(--muted);
    overflow-wrap: anywhere;
}

.contact-icon {
    flex: none;
    display: grid;
    place-items: center;
    width: 40px;
    height: 40px;
    border-radius: 12px;
    background: linear-gradient(140deg, var(--purple-light), var(--purple-dark));
    color: var(--copper-light);
    font-size: 1.1rem;
}

.contact-card {
    position: relative;
    padding: clamp(24px, 4vw, 44px);
    border-radius: var(--radius-lg);
    background: var(--surface);
    border: 1px solid var(--line);
    box-shadow: var(--shadow-lg);
}

/* A copper rule across the top of the form card, the one ornament on the page. */
.contact-card::before {
    content: "";
    position: absolute;
    inset: 0 32px auto;
    height: 4px;
    border-radius: 0 0 4px 4px;
    background: linear-gradient(90deg, var(--copper), var(--purple));
}

.field-row {
    display: grid;
    gap: 0 18px;
}

@media (min-width: 640px) {
    .field-row {
        grid-template-columns: 1fr 1fr;
    }
}

.field {
    display: grid;
    gap: 6px;
    margin-bottom: 18px;
}

.field label {
    font-size: 0.88rem;
    font-weight: 700;
    color: var(--ink-loud);
}

.req {
    color: var(--copper-dark);
}

.field input,
.field select,
.field textarea {
    width: 100%;
    padding: 13px 16px;
    border-radius: 14px;
    border: 1.5px solid var(--line);
    background: var(--ground);
    color: var(--ink);
    font: inherit;
    font-size: 1rem;
    transition: border-color 0.2s ease, box-shadow 0.2s ease, background-color 0.2s ease;
}

.field textarea {
    resize: vertical;
    min-height: 140px;
}

.field input:focus,
.field select:focus,
.field textarea:focus {
    outline: none;
    border-color: var(--accent);
    background: var(--surface);
    box-shadow: 0 0 0 4px color-mix(in srgb, var(--accent) 18%, transparent);
}

.has-error input,
.has-error select,
.has-error textarea {
    border-color: #c0392b;
}

.field-error,
.form-error {
    margin: 0;
    color: #c0392b;
    font-size: 0.86rem;
    font-weight: 600;
}

.form-error {
    margin-bottom: 18px;
    padding: 12px 16px;
    border-radius: 12px;
    background: color-mix(in srgb, #c0392b 10%, transparent);
}

.btn-wide {
    width: 100%;
    padding-block: 16px;
    border: none;
    font: inherit;
    font-weight: 700;
    font-size: 1.05rem;
    cursor: pointer;
}

.form-note {
    margin: 14px 0 0;
    text-align: center;
    font-size: 0.85rem;
    color: var(--muted);
}

.contact-sent {
    display: grid;
    justify-items: center;
    gap: 10px;
    padding-block: 40px;
    text-align: center;
}

.contact-sent h2 {
    font-size: 1.8rem;
    font-weight: 800;
}

.contact-sent p {
    color: var(--muted);
}

.contact-sent-mark {
    display: grid;
    place-items: center;
    width: 72px;
    height: 72px;
    border-radius: 50%;
    background: linear-gradient(140deg, var(--copper-light), var(--copper));
    color: var(--purple-deep);
    font-size: 2rem;
    font-weight: 800;
    animation: pop-in 0.7s cubic-bezier(0.3, 1.6, 0.5, 1) both;
}

@keyframes pop-in {
    from {
        opacity: 0;
        transform: scale(2.2) rotate(-20deg);
    }

    to {
        opacity: 1;
        transform: none;
    }
}


/* ── File tag: the monospace case reference that opens every page ──────────── */
.file-tag {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 6px 14px;
    margin: 0 0 18px;
    font-family: var(--mono, ui-monospace, monospace);
    font-size: 0.74rem;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: #cbbccf;
}

.file-tag span+span::before {
    content: "/";
    margin-inline-end: 14px;
    opacity: 0.4;
}

.file-tag b {
    padding: 3px 10px;
    border: 1px solid rgba(220, 171, 142, 0.5);
    border-radius: 999px;
    color: var(--copper-light);
    font-weight: 700;
}

/* ── Inner-page hero: one lit 3D phone or a lit illustration ─────────────────── */
.page-hero.dark-stage {
    padding-block: clamp(36px, 6vw, 80px) clamp(56px, 8vw, 100px);
}

.dark-stage .display-page {
    color: #fff;
}

.spot {
    position: absolute;
    inset: -10% 5% 5%;
    border-radius: 50%;
    background: radial-gradient(ellipse at 50% 40%, rgba(206, 138, 99, 0.32), rgba(122, 68, 138, 0.22) 45%, transparent 70%);
    filter: blur(20px);
    animation: breathe 7s ease-in-out infinite;
}

.hero-phone {
    position: relative;
    display: grid;
    place-items: center;
    min-height: 520px;
    perspective: 1400px;
}

.hero-phone .device {
    width: min(270px, 64vw);
    -webkit-box-reflect: below 6px linear-gradient(transparent 74%, rgba(255, 255, 255, 0.14));
    animation: phone-sway 9s ease-in-out infinite;
}

@keyframes phone-sway {

    0%,
    100% {
        transform: rotateY(-24deg) rotateX(8deg) rotateZ(3deg) translateY(0);
    }

    50% {
        transform: rotateY(-8deg) rotateX(4deg) rotateZ(1deg) translateY(-12px);
    }
}

.stamp-small {
    top: 46%;
    left: 50%;
    padding: 6px 14px 5px;
}

.stamp-small b {
    font-size: 1.3rem;
}

.dark-stage .hero-art img {
    -webkit-box-reflect: below 4px linear-gradient(transparent 76%, rgba(255, 255, 255, 0.12));
    filter: drop-shadow(0 30px 40px rgba(0, 0, 0, 0.45));
}

@media (max-width: 899px) {
    .hero-phone {
        min-height: 440px;
    }
}

/* ── Split-flap board ─────────────────────────────────────────────────────────── */
.board {
    padding-block: clamp(40px, 6vw, 72px);
    background: #0e0910;
}

.board-frame {
    padding: clamp(16px, 2.4vw, 28px);
    border-radius: 24px;
    background: linear-gradient(180deg, #1b1220, #120b15);
    border: 1px solid rgba(255, 255, 255, 0.07);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.06), 0 30px 60px -30px rgba(0, 0, 0, 0.8);
    font-family: ui-monospace, "SF Mono", "JetBrains Mono", Menlo, Consolas, monospace;
}

.board-top {
    display: flex;
    justify-content: space-between;
    margin-bottom: 16px;
    font-size: 0.72rem;
    letter-spacing: 0.2em;
    text-transform: uppercase;
    color: var(--copper-light);
}

.board-clock {
    color: #8f8195;
}

.board-grid {
    display: grid;
    grid-template-columns: 1.3fr 1fr auto;
    gap: 10px 12px;
    align-items: center;
}

.board-head {
    font-size: 0.68rem;
    letter-spacing: 0.22em;
    text-transform: uppercase;
    color: #8f8195;
}

/* One tile per row and column; its words take turns flipping into place. */
.flap {
    position: relative;
    display: block;
    height: clamp(44px, 5vw, 60px);
    border-radius: 10px;
    background: linear-gradient(180deg, #2a1d30 0 50%, #22172a 50% 100%);
    box-shadow: inset 0 -2px 0 rgba(0, 0, 0, 0.4), inset 0 1px 0 rgba(255, 255, 255, 0.05);
    overflow: hidden;
    perspective: 400px;
}

/* The hinge across the middle of every tile. */
.flap::after {
    content: "";
    position: absolute;
    inset: 50% 0 auto;
    height: 1px;
    background: rgba(0, 0, 0, 0.6);
    z-index: 2;
}

.flap span {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    padding-inline: clamp(12px, 1.6vw, 20px);
    font-size: clamp(1rem, 2vw, 1.55rem);
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    white-space: nowrap;
    color: #f6ece2;
    opacity: 0;
    transform-origin: 50% 50%;
    backface-visibility: hidden;
    animation: flap 24s infinite;
    animation-delay: calc((var(--i) - var(--row) * 2) * 3s);
}

.board-type-col.flap span {
    color: var(--copper-light);
}

.board-status {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 14px;
    border-radius: 10px;
    background: rgba(46, 155, 95, 0.12);
    color: #6fd39b;
    font-size: 0.82rem;
    font-weight: 700;
    letter-spacing: 0.16em;
    text-transform: uppercase;
}

.board-status i {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #3fc47c;
    box-shadow: 0 0 10px #3fc47c;
    animation: led 1.6s ease-in-out infinite;
}

@keyframes flap {
    0% {
        opacity: 0;
        transform: rotateX(-90deg);
    }

    1.8% {
        opacity: 1;
        transform: rotateX(8deg);
    }

    2.6%,
    11.4% {
        opacity: 1;
        transform: rotateX(0);
    }

    12.5%,
    100% {
        opacity: 0;
        transform: rotateX(90deg);
    }
}

@keyframes led {

    0%,
    100% {
        opacity: 1;
    }

    50% {
        opacity: 0.35;
    }
}

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

    .board-grid {
        grid-template-columns: 1fr auto;
    }

    .board-type-col {
        display: none;
    }

    .board-status {
        padding: 10px;
        font-size: 0.7rem;
        letter-spacing: 0.1em;
    }
}

@media (prefers-reduced-motion: reduce) {
    .flap span:first-child {
        opacity: 1;
    }
}

/* ── Contact hero: the form is the hero's right-hand side ─────────────────────── */
.contact-hero .page-hero-grid {
    align-items: start;
}

.dark-stage .contact-points li {
    background: rgba(255, 255, 255, 0.05);
    border-color: rgba(255, 255, 255, 0.1);
}

.dark-stage .contact-points b {
    color: #fff;
}

.dark-stage .contact-points div,
.dark-stage .contact-points a {
    color: #cbbccf;
}

.dark-stage .contact-card {
    background: #fbf8f5;
    color: #2a2430;
    box-shadow: 0 50px 100px -30px rgba(0, 0, 0, 0.8), 0 0 0 1px rgba(255, 255, 255, 0.06);
    transform: perspective(1400px) rotateY(-4deg) rotateX(2deg);
}

.dark-stage .contact-card h2,
.dark-stage .contact-card .field label {
    color: #1b1520;
}

.dark-stage .contact-card .field input,
.dark-stage .contact-card .field select,
.dark-stage .contact-card .field textarea {
    background: #fff;
    color: #2a2430;
    border-color: rgba(42, 36, 48, 0.14);
}

.contact-card-tag {
    margin: 0 0 18px;
    font-family: ui-monospace, "SF Mono", Menlo, Consolas, monospace;
    font-size: 0.72rem;
    letter-spacing: 0.16em;
    text-transform: uppercase;
    color: #6e6472;
}

.contact-card-tag span {
    color: #a97151;
}

@media (max-width: 899px) {
    .dark-stage .contact-card {
        transform: none;
    }
}

/* Every inner page opens on the dark stage, so the breadcrumb sits on it too. */
.crumbs-bar {
    background: #0e0910;
}

.crumbs-bar .crumbs {
    padding-block: 18px 0;
}

.crumbs-bar .crumbs ol,
.crumbs-bar .crumbs a {
    color: #a99fad;
}

.crumbs-bar .crumbs a:hover {
    color: var(--copper-light);
}

/* ── Topic chips: real radio buttons, drawn as pills ─────────────────────────── */
.topic-field {
    margin: 0 0 18px;
    padding: 0;
    border: none;
    min-width: 0;
}

.topic-field legend {
    margin-bottom: 8px;
    padding: 0;
    font-size: 0.88rem;
    font-weight: 700;
    color: #1b1520;
}

.topic-chips {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.topic-chip {
    position: relative;
    cursor: pointer;
}

/* The input stays in the page for keyboards and screen readers; the pill shows it. */
.topic-chip input {
    position: absolute;
    inset: 0;
    opacity: 0;
    margin: 0;
    cursor: pointer;
}

.topic-chip span {
    display: inline-block;
    padding: 9px 15px;
    border-radius: 999px;
    border: 1.5px solid rgba(42, 36, 48, 0.14);
    background: #fff;
    color: #2a2430;
    font-size: 0.9rem;
    font-weight: 600;
    transition: background-color 0.2s ease, border-color 0.2s ease, color 0.2s ease, transform 0.15s ease;
}

.topic-chip:hover span {
    border-color: var(--purple);
}

.topic-chip input:checked+span {
    background: linear-gradient(140deg, var(--purple-light), var(--purple-dark));
    border-color: transparent;
    color: #fff;
    transform: translateY(-1px);
    box-shadow: 0 6px 14px -6px rgba(73, 32, 85, 0.6);
}

.topic-chip input:checked+span::before {
    content: "✓ ";
    color: var(--copper-light);
}

.topic-chip input:focus-visible+span {
    outline: 3px solid var(--copper);
    outline-offset: 2px;
}

/* ── Legibility in both themes (checked by contrast audit, WCAG AA) ───────────── */
/* copperDark only clears AA at large sizes (CLAUDE.md §15); small copper text uses a
   deeper copper, or the accent, which flips to copper-light in dark mode. */
.pill-copper {
    background: #8a5a3f;
}

/* The ivory contact card keeps its own colours whatever the page theme is. */
.contact-card .form-note {
    color: #5e5462;
}

.contact-card-tag span,
.contact-card .req {
    color: #8a5a3f;
}

/* Secondary text on the dark stage, a step brighter for margin over the lit purple. */
.dark-stage .lead,
.file-tag,
.dark-stage .contact-points div,
.dark-stage .contact-points a {
    color: #ddd2e1;
}

.question-card p {
    color: #e2d6e5;
}

/* The Urdu header has no menu, so on a phone its two links and the brand must fit one row. */
@media (max-width: 420px) {
    .page-home-ur .header-inner {
        gap: 8px;
    }

    .page-home-ur .brand-name {
        font-size: 1.1rem;
    }

    .page-home-ur .brand-logo {
        width: 28px;
    }

    .page-home-ur .nav a:not(.btn) {
        padding-inline: 6px;
    }

    .page-home-ur .btn-small {
        padding: 6px 12px;
        font-size: 0.82rem;
    }
}
