/* Sparker's website: ivory playing cards on a navy table (dusk blue in light mode), lit evenly, with gold buttons, like the app.
   Mobile first, light and dark. No web fonts: the system serif (New York on Apple devices, Georgia elsewhere). */

:root {
    --table-top: #dde3ee;
    --table-bottom: #b4bfd3;
    --lift: rgb(255 255 255 / 0.06);
    --ink-on-table: #18202e;
    --muted-on-table: #3b445c;
    --rail: #f4f6fa;
    --rail-stroke: #8f99ad;
    --felt: #e0a93e;
    --brass: #9a6a1e;
    --card: #fbf6ec;
    --card-edge: #d8d0c0;
    --ink: #1e2433;
    --ink-muted: #5a6275;
    --shadow: 0 1px 1.5px rgb(0 0 0 / 0.32), 0 8px 24px rgb(10 14 24 / 0.22);
    --serif: "New York", ui-serif, Georgia, "Times New Roman", serif;
    --sans: -apple-system, system-ui, "Segoe UI", Roboto, sans-serif;
    --radius: 18px;
    --wrap: 1120px;
    color-scheme: light dark;
}

@media (prefers-color-scheme: dark) {
    :root {
        --table-top: #1f2c47;
        --table-bottom: #0a1020;
        --lift: rgb(255 255 255 / 0.04);
        --ink-on-table: #eef1f6;
        --muted-on-table: #a9b2c4;
        --rail: #2e3d5c;
        --rail-stroke: #4a5a7c;
        --felt: #e8b852;
        --brass: #d3a24e;
        --card: #eee6d6;
        --card-edge: #b8ae9c;
        --shadow: 0 1px 2px rgb(0 0 0 / 0.45), 0 12px 32px rgb(0 0 0 / 0.4);
    }
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 64px; -webkit-text-size-adjust: 100%; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } * { animation: none !important; transition: none !important; } }

body {
    margin: 0;
    font: 18px/1.6 var(--serif);
    color: var(--ink-on-table);
    background:
        radial-gradient(90% 60% at 50% 45%, var(--lift) 0%, transparent 70%),
        linear-gradient(180deg, var(--table-top), var(--table-bottom));
    background-attachment: fixed;
    min-height: 100vh;
}

img { max-width: 100%; height: auto; display: block; }
a { color: inherit; }
h1, h2, h3 { font-family: var(--serif); line-height: 1.15; margin: 0 0 0.5em; letter-spacing: -0.01em; }
h1 { font-size: clamp(2.6rem, 6vw + 1rem, 4.6rem); }
h2 { font-size: clamp(1.9rem, 3vw + 1rem, 2.8rem); }
h3 { font-size: 1.25rem; }
p { margin: 0 0 1em; }
.muted { color: var(--muted-on-table); }
.wrap { max-width: var(--wrap); margin: 0 auto; padding: 0 22px; }
.visually-hidden { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: absolute; left: -999px; top: 8px; background: var(--card); color: var(--ink); padding: 8px 14px; border-radius: 8px; z-index: 10; }
.skip:focus { left: 8px; }
:focus-visible { outline: 3px solid var(--brass); outline-offset: 3px; border-radius: 6px; }

/* Header */
.site-header { position: sticky; top: 0; z-index: 5; backdrop-filter: saturate(1.4) blur(14px); -webkit-backdrop-filter: saturate(1.4) blur(14px);
    background: color-mix(in srgb, var(--table-top) 72%, transparent); border-bottom: 1px solid color-mix(in srgb, var(--rail-stroke) 35%, transparent); }
.site-header .wrap { display: flex; align-items: center; gap: 18px; min-height: 64px; }
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; font-weight: 700; font-size: 1.1rem; white-space: nowrap; }
.brand img { border-radius: 8px; }
.site-nav { display: flex; gap: 18px; margin-left: auto; font-family: var(--sans); font-size: 0.95rem; }
.site-nav a { text-decoration: none; color: var(--muted-on-table); }
.site-nav a:hover, .site-nav a[aria-current] { color: var(--ink-on-table); }
@media (max-width: 640px) { .nav-extra { display: none; } .store-badge.header-store { display: none; } }

/* Apple's official App Store badge (images/app-store-badge.svg). Apple asks for it unaltered, at least 40px tall on
   screen, with clear space of a quarter of its height around it. */
.store-badge { display: inline-block; line-height: 0; border-radius: 9px; }
.store-badge img { display: block; height: 54px; width: auto; }
.header-store img { height: 40px; }

/* Felt buttons and chips */
.felt-button { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 48px; padding: 12px 24px; border-radius: 999px; border: 0;
    background: var(--felt); color: #1e1a10; font: 700 1rem var(--serif); cursor: pointer; text-decoration: none;
    box-shadow: inset 0 0 0 4px var(--felt), inset 0 0 0 5.5px rgb(30 26 16 / 0.25), 0 4px 10px rgb(0 0 0 / 0.25); }
.felt-button:active { transform: scale(0.97); }
.ribbon { display: inline-block; padding: 2px 10px; border-radius: 999px; background: var(--brass); color: var(--card); font: 800 0.72rem var(--serif); letter-spacing: 0.06em; text-transform: uppercase; }

/* Sections */
section { padding: 72px 0; }
.section-rail { background: color-mix(in srgb, var(--rail) 55%, transparent); border-block: 1px solid color-mix(in srgb, var(--rail-stroke) 30%, transparent); }
.section-head { max-width: 720px; margin-bottom: 36px; }
.eyebrow { display: block; font: 800 0.8rem var(--sans); letter-spacing: 0.12em; text-transform: uppercase; color: var(--brass); margin-bottom: 10px; }

/* Hero */
.hero { padding-top: 56px; }
.hero .wrap { display: grid; gap: 40px; align-items: center; }
@media (min-width: 900px) { .hero .wrap { grid-template-columns: 1.1fr 0.9fr; } }
.hero p.lede { font-size: 1.3rem; color: var(--muted-on-table); max-width: 34ch; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 14px; align-items: center; margin-top: 26px; }
.phone { width: min(320px, 78vw); margin: 0 auto; border-radius: 44px; padding: 10px; background: #111; box-shadow: var(--shadow), inset 0 0 0 2px #333; }
.phone img { border-radius: 34px; }

/* Numbers */

/* Playing cards (2.5 x 3.5) */
.card { aspect-ratio: 5 / 7; background: var(--card); color: var(--ink); border-radius: 5% / 3.6%; border: 1px solid var(--card-edge); box-shadow: var(--shadow);
    position: relative; display: flex; align-items: center; justify-content: center; text-align: center; padding: 18% 14%; }
.card::before { content: ""; position: absolute; inset: 5%; border: 1px solid color-mix(in srgb, var(--pack-ink) 18%, transparent); border-radius: 3.5% / 2.5%; pointer-events: none; }
.card { --pack-ink: #7a1c2e; }
.screen .card { --pack-ink: inherit; }
.card .kind { position: absolute; top: 9%; left: 10%; font: 800 0.74rem var(--serif); letter-spacing: 0.08em; text-transform: uppercase; color: var(--pack-ink); }
.card q { quotes: none; font-weight: 600; font-size: clamp(1.1rem, 2.4vw, 1.5rem); line-height: 1.3; color: var(--pack-ink); }
/* The working phone in the hero: the pack's light table, its card stack and ink, from the app's PackStyle */
.hero-demo { margin: 0; display: grid; justify-items: center; gap: 14px; }
.hero-demo figcaption { text-align: center; }
.live-phone .screen {
    aspect-ratio: 9 / 19.5; border-radius: 34px; overflow: hidden; display: flex; flex-direction: column; padding: 14px 16px 18px;
    color: #18202e; font-family: var(--sans); background: linear-gradient(180deg, var(--t1), var(--t2)); }
.screen .status { display: flex; justify-content: space-between; padding: 2px 14px 0; font-size: 0.82rem; font-weight: 600; }
.screen .status-icons { width: 22px; height: 10px; border-radius: 3px; border: 1.5px solid currentColor; opacity: 0.85; background: linear-gradient(90deg, currentColor 0 70%, transparent 70%) content-box; padding: 1px; }
.screen-top { display: flex; justify-content: space-between; margin-top: 16px; }
.screen .pill { display: inline-flex; align-items: center; justify-content: center; gap: 6px; padding: 6px 12px; border-radius: 999px;
    font: 600 0.72rem var(--serif); color: inherit; background: rgb(255 255 255 / 0.7); border: 1px solid rgb(0 0 0 / 0.06); box-shadow: 0 1px 3px rgb(0 0 0 / 0.15); }
.screen-title { display: grid; justify-items: center; margin-top: 8px; line-height: 1.2; }
.screen-title strong { font: 700 1.3rem var(--serif); letter-spacing: -0.01em; color: var(--pack-ink); }
.screen-title small { margin-top: 2px; font: 700 0.62rem var(--sans); letter-spacing: 0.1em; text-transform: uppercase; color: var(--pack-ink); opacity: 0.75; }
.screen .stack { flex: 1; display: grid; place-items: center; perspective: 1200px; padding: 10px 10px 0; }
.screen .flip { width: 100%; max-width: 230px; }
.screen .card { font-family: var(--serif); padding: 18% 12%; box-shadow: 4px 5px 0 -1px var(--main), 8px 10px 0 -2px color-mix(in srgb, var(--main) 70%, #000), 0 12px 24px rgb(0 0 0 / 0.25); }
.screen .card .kind { font-size: 0.62rem; }
.screen .card q { font-size: 1.12rem; }
.screen-actions { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-top: 16px; }
.screen-actions .pill { padding: 8px; cursor: pointer; }
.screen-actions .pill svg { width: 14px; height: 14px; fill: none; stroke: currentColor; stroke-width: 2; }
.screen-actions [aria-pressed="true"] svg { fill: currentColor; }
.screen-actions .next { grid-column: 1 / -1; padding: 10px; border-radius: 999px; border: 2px dashed rgb(120 80 10 / 0.45); outline: 3px solid #e8b44a; outline-offset: -1px;
    background: #e8b44a; color: #2a1d05; font: 700 0.85rem var(--serif); cursor: pointer; }
.screen button:disabled { cursor: default; }
.screen[data-pack="couples"] { --t1: #f9dadd; --t2: #dfb0b4; --main: #96233f; --pack-ink: #7e1e35; }
.screen[data-pack="engaged"] { --t1: #f9dae0; --t2: #ddb0ba; --main: #ba5f78; --pack-ink: #772741; }
.screen[data-pack="table"] { --t1: #d4ead6; --t2: #a8c8aa; --main: #378143; --pack-ink: #08571e; }
.screen[data-pack="teens"] { --t1: #d1ead9; --t2: #a2c9af; --main: #07995a; --pack-ink: #025631; }
.screen[data-pack="adultchildren"] { --t1: #e6def7; --t2: #c3b6dc; --main: #7d5fad; --pack-ink: #52367b; }
.screen[data-pack="elders"] { --t1: #eadef2; --t2: #c8b6d3; --main: #65407a; --pack-ink: #59376c; }
.screen[data-pack="friends"] { --t1: #cdeae7; --t2: #9dc8c4; --main: #2a9f9a; --pack-ink: #005350; }
.screen[data-pack="group"] { --t1: #cdeaea; --t2: #9dc7c8; --main: #007f81; --pack-ink: #035354; }
.flip { position: relative; transition: transform 0.45s ease; transform-style: preserve-3d; }
.flip.down { transform: rotateY(180deg); }
.flip .face, .flip .back { backface-visibility: hidden; -webkit-backface-visibility: hidden; }
.flip .back { position: absolute; inset: 0; transform: rotateY(180deg); }
.flip .back img { width: 100%; height: 100%; object-fit: contain; }

/* Steps */
.steps { display: grid; gap: 28px; }
@media (min-width: 860px) { .steps { grid-template-columns: repeat(3, 1fr); } }
.step figure { margin: 0 0 16px; }
.step .phone { width: min(250px, 70vw); border-radius: 36px; padding: 8px; }
.step .phone img { border-radius: 28px; }
.step h3 { display: flex; gap: 10px; align-items: baseline; }
.step h3 .num { font-size: 0.85rem; color: var(--brass); }

/* Packs */
.packs { display: grid; gap: 22px; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); }
.pack { background: color-mix(in srgb, var(--rail) 70%, transparent); border: 1px solid color-mix(in srgb, var(--rail-stroke) 35%, transparent);
    border-radius: var(--radius); padding: 18px; display: grid; gap: 8px; align-content: start; }
.pack .backs { position: relative; height: 150px; margin-bottom: 6px; }
.pack .backs img { position: absolute; left: 50%; bottom: 0; width: 92px; filter: drop-shadow(0 4px 6px rgb(0 0 0 / 0.3)); }
.pack .backs img:first-child { transform: translateX(-80%) rotate(-9deg); transform-origin: bottom center; }
.pack .backs img:last-child { transform: translateX(-20%) rotate(7deg); transform-origin: bottom center; }
.pack h4 { margin: 0; font-size: 1.15rem; }
.pack-group + .pack-group { margin-top: 34px; }
.pack-group > h3 { margin: 0 0 14px; }
/* Category marks: the same drawings as the app, tinted brass with a mask */
.mark { display: inline-block; width: 1.1em; height: 1.1em; margin-right: 0.45em; vertical-align: -0.16em; background-color: var(--brass);
    -webkit-mask: center / contain no-repeat; mask: center / contain no-repeat; }
.mark-marriage { -webkit-mask-image: url(../images/marks/marriage.svg); mask-image: url(../images/marks/marriage.svg); }
.mark-family { -webkit-mask-image: url(../images/marks/family.svg); mask-image: url(../images/marks/family.svg); }
.mark-generations { -webkit-mask-image: url(../images/marks/generations.svg); mask-image: url(../images/marks/generations.svg); }
.mark-community { -webkit-mask-image: url(../images/marks/community.svg); mask-image: url(../images/marks/community.svg); }
.mark-missions { -webkit-mask-image: url(../images/marks/missions.svg); mask-image: url(../images/marks/missions.svg); }
.mark-work { -webkit-mask-image: url(../images/marks/work.svg); mask-image: url(../images/marks/work.svg); }
.pack p { margin: 0; color: var(--muted-on-table); font-size: 0.95rem; }
.pack .meta { font-family: var(--sans); font-size: 0.85rem; color: var(--muted-on-table); display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }

/* Pricing */
.prices { display: grid; gap: 20px; }
@media (min-width: 860px) { .prices { grid-template-columns: repeat(3, 1fr); } }
.price { background: var(--card); color: var(--ink); border-radius: var(--radius); padding: 26px; border: 1px solid var(--card-edge); box-shadow: var(--shadow); display: grid; gap: 10px; align-content: start; }
.price.best { outline: 3px solid var(--brass); outline-offset: -3px; }
.price .amount { font-size: 2.6rem; font-weight: 700; line-height: 1; }
.price .amount small { font-size: 0.42em; font-weight: 600; letter-spacing: 0.02em; margin-right: 0.15em; vertical-align: 0.35em; }
.price ul { margin: 0; padding-left: 1.1em; color: var(--ink-muted); }
.price .label { font: 800 0.78rem var(--sans); letter-spacing: 0.1em; text-transform: uppercase; color: var(--ink-muted); }

/* Feature list */
.features { display: grid; gap: 20px; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); }
.feature { padding: 20px; border-radius: var(--radius); background: color-mix(in srgb, var(--rail) 55%, transparent); }
.feature h3 { margin-bottom: 6px; }
.feature p { margin: 0; color: var(--muted-on-table); }

/* Privacy band, CTA, footer */
.privacy-band { text-align: center; }
.privacy-band p { max-width: 640px; margin: 0 auto 1em; color: var(--muted-on-table); }
.cta { text-align: center; }
.cta .fan { display: flex; justify-content: center; margin-bottom: 26px; height: 170px; }
.cta .fan img { width: 96px; margin: 0 -26px; transform-origin: bottom center; filter: drop-shadow(0 4px 6px rgb(0 0 0 / 0.3)); }
.site-footer { padding: 36px 0 48px; font-family: var(--sans); font-size: 0.9rem; color: var(--muted-on-table); }
.site-footer .wrap { display: flex; flex-wrap: wrap; gap: 14px 24px; justify-content: space-between; }
.site-footer nav { display: flex; gap: 18px; }

/* Text pages (privacy, support) */
.page { max-width: 760px; margin: 0 auto; padding: 48px 22px 72px; }
.page h2 { font-size: 1.6rem; margin-top: 1.6em; }
.page li { margin-bottom: 0.4em; }
.faq details { background: color-mix(in srgb, var(--rail) 60%, transparent); border-radius: 14px; padding: 14px 18px; margin-bottom: 12px; }
.faq summary { font-weight: 700; cursor: pointer; }
.faq details p { margin: 10px 0 0; color: var(--muted-on-table); }

/* Small helpers (kept out of the HTML so the content security policy can stay strict). */
.note { margin-top: 18px; }
.note.small { font-size: 0.9rem; }
.centered { text-align: center; }
.section-head.centered { margin: 0 auto 8px; }
.cta .fan img:nth-child(1) { transform: rotate(-18deg); }
.cta .fan img:nth-child(2) { transform: rotate(-9deg); }
.cta .fan img:nth-child(4) { transform: rotate(9deg); }
.cta .fan img:nth-child(5) { transform: rotate(18deg); }
.lost-card { margin: 0 auto 24px; transform: rotate(-6deg); }

/* Packs: an intro with a Free to try panel, then a section per circle whose heading carries its price */
.free-try { padding: 26px 28px; border-radius: var(--radius); background: color-mix(in srgb, var(--rail) 70%, transparent);
    border: 1px solid color-mix(in srgb, var(--rail-stroke) 35%, transparent); }
.free-try-head { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 14px; margin-bottom: 18px; }
.free-try-head h3 { margin: 0; font-size: 1.45rem; }
.free-try ol { list-style: none; margin: 0; padding: 0; display: grid; gap: 18px; counter-reset: step; }
@media (min-width: 820px) { .free-try ol { grid-template-columns: repeat(3, 1fr); gap: 28px; } }
.free-try li { counter-increment: step; position: relative; padding-left: 44px; color: var(--muted-on-table); }
.free-try li::before { content: counter(step); position: absolute; left: 0; top: 0; width: 30px; height: 30px; border-radius: 50%; display: grid; place-items: center;
    background: var(--brass); color: var(--card); font: 800 0.95rem var(--sans); }
.free-try li strong { display: block; color: var(--ink-on-table); }
.pack-group-head { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 18px; margin: 0 0 14px; }
.pack-group-head h2 { margin: 0; font-size: 1.7rem; }
.circle { padding: 52px 0; }
.pack h3 { margin: 0; font-size: 1.15rem; }
.circle-price { margin: 0; display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 10px; font: 600 0.85rem var(--sans); color: var(--muted-on-table); }
.circle-price .amount { font: 700 1.35rem var(--serif, inherit); color: var(--ink-on-table, inherit); }
/* Pack cards: the card count sits on the bottom edge, level across a row */
.pack { display: flex; flex-direction: column; }
.pack .meta { margin-top: auto; padding-top: 4px; }
/* Hero: a chip for every circle, in the circle's color (its first pack's main color in the app's PackStyle), each jumping
   to its section. The mark is an <img> turned white with a filter, so it shows even where CSS masks don't load. */
.circle-chips { list-style: none; margin: 22px 0 0; padding: 0; display: flex; flex-wrap: wrap; justify-content: flex-start; gap: 10px; max-width: 560px; }
.circle-chips a { display: inline-flex; align-items: center; gap: 8px; min-height: 40px; padding: 6px 16px 6px 13px; border-radius: 999px; text-decoration: none;
    font: 700 0.95rem var(--sans); color: #fff; text-shadow: 0 1px 1px rgb(0 0 0 / 0.3);
    background:
        repeating-linear-gradient(135deg, rgb(255 255 255 / 0.07) 0 2px, transparent 2px 7px),
        linear-gradient(180deg, color-mix(in srgb, var(--circle) 78%, #fff), var(--circle) 55%, color-mix(in srgb, var(--circle) 78%, #000));
    box-shadow: inset 0 1px 0 rgb(255 255 255 / 0.3), inset 0 -1px 0 rgb(0 0 0 / 0.25), 0 2px 6px rgb(0 0 0 / 0.2);
    transition: filter 0.15s, transform 0.15s; }
.circle-chips a:hover { filter: brightness(1.08); transform: translateY(-1px); }
.chip-mark { width: 18px; height: 18px; flex: none; filter: brightness(0) invert(1) drop-shadow(0 1px 1px rgb(0 0 0 / 0.3)); }
.chip-marriage { --circle: #96233f; }
.chip-family { --circle: #378143; }
.chip-generations { --circle: #7d5fad; }
.chip-community { --circle: #007f81; }
.chip-missions { --circle: #b44e2e; }
.chip-work { --circle: #426882; }

/* Packs and circles, centered: intro, Free to try panel, circle headings and pack cards */
#packs { padding-bottom: 48px; }
#packs .section-head.centered { margin-bottom: 0; }
#packs .section-head.centered p { margin-left: auto; margin-right: auto; }
.free-try { text-align: center; }
.free-try-head { flex-direction: column; justify-content: center; }
.free-try li { padding-left: 0; padding-top: 42px; }
.free-try li::before { left: 50%; transform: translateX(-50%); }
.circle .pack-group-head { justify-content: center; text-align: center; }
.circle .packs { display: flex; flex-wrap: wrap; justify-content: center; }
.circle .pack { flex: 0 1 240px; text-align: center; }
.circle .pack .meta { justify-content: center; }
.heading-mark { width: 1em; height: 1em; margin-right: 0.4em; vertical-align: -0.12em; fill: none; stroke: var(--brass); stroke-width: 1.75; stroke-linecap: round; stroke-linejoin: round; }
.circle-free { margin: 24px 0 0; display: flex; justify-content: center; align-items: center; gap: 12px; }
.circle-free .amount { font: 700 1.5rem var(--serif); color: var(--ink-on-table); }
