/* Layout: one night-sky column that warms from deep teal to candle-gold as you scroll,
   like the app's own background. Cards are the only saturated colour on the page. */
:root {
  --night: #0b2530;
  --deep: #10333f;
  --tide: #1b5260;
  --dusk: #4a4a3c;
  --gold: #e2bb72;
  --gold-soft: #f1dcae;
  --lilac: #ddd3fb;
  --ink: #f4eee3;
  --mist: #b8c8c6;
  --line: rgba(244, 238, 227, 0.14);
  --panel: rgba(9, 32, 41, 0.55);

  --display: "Jim Nightshade", "Apple Chancery", "URW Chancery L", cursive;
  --body: "Lexend", "Avenir Next", "Segoe UI", system-ui, sans-serif;

  --step--1: clamp(0.8rem, 0.78rem + 0.1vw, 0.86rem);
  --step-0: clamp(1rem, 0.97rem + 0.15vw, 1.08rem);
  --step-1: clamp(1.2rem, 1.1rem + 0.4vw, 1.4rem);
  --step-2: clamp(1.6rem, 1.4rem + 0.9vw, 2.2rem);
  --step-3: clamp(2.4rem, 1.9rem + 2.4vw, 4rem);
  --step-4: clamp(3rem, 2.2rem + 4vw, 5.6rem);

  --wrap: 72rem;
  --gutter: clamp(1rem, 4vw, 2.5rem);
  color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } *, *::before, *::after { animation: none !important; transition: none !important; } }

body {
  margin: 0;
  font-family: var(--body);
  font-weight: 300;
  font-size: var(--step-0);
  line-height: 1.65;
  color: var(--ink);
  background-color: var(--night);
  background-image:
    radial-gradient(1px 1px at 12% 8%, rgba(255,255,255,.7) 50%, transparent 51%),
    radial-gradient(1px 1px at 78% 4%, rgba(255,255,255,.55) 50%, transparent 51%),
    radial-gradient(1.5px 1.5px at 42% 14%, rgba(255,255,255,.6) 50%, transparent 51%),
    radial-gradient(1px 1px at 88% 19%, rgba(255,255,255,.5) 50%, transparent 51%),
    radial-gradient(1px 1px at 23% 27%, rgba(255,255,255,.45) 50%, transparent 51%),
    radial-gradient(1px 1px at 63% 33%, rgba(255,255,255,.4) 50%, transparent 51%),
    linear-gradient(180deg, var(--night) 0%, var(--deep) 30%, var(--tide) 62%, var(--dusk) 88%, #6b5a3a 100%);
  background-repeat: no-repeat;
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; height: auto; display: block; }
main { overflow-x: clip; }
a { color: var(--gold-soft); text-underline-offset: 3px; }
a:hover { color: var(--gold); }
:focus-visible { outline: 2px solid var(--gold); outline-offset: 3px; border-radius: 4px; }

h1, h2, h3 { text-wrap: balance; margin: 0; font-weight: 400; line-height: 1.15; }
p { margin: 0; }

.wrap { width: 100%; max-width: var(--wrap); margin-inline: auto; padding-inline: var(--gutter); }
.skip { position: absolute; left: -999px; top: 0; }
.skip:focus { left: 1rem; top: 1rem; background: var(--gold); color: var(--night); padding: .5rem 1rem; z-index: 10; }

.eyebrow {
  font-size: var(--step--1);
  letter-spacing: .16em;
  text-transform: uppercase;
  color: var(--gold);
  font-weight: 400;
}
.display { font-family: var(--display); font-weight: 400; color: var(--lilac); text-shadow: 0 0 18px rgba(190, 170, 255, .35); }
.lede { color: var(--mist); max-width: 34em; }

/* Header */
.site-header {
  position: sticky; top: env(safe-area-inset-top, 0px); z-index: 5;
  background: rgba(11, 37, 48, .82);
  backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
}
.site-header .wrap { display: flex; align-items: center; justify-content: space-between; gap: 1rem; padding-block: .6rem; }
.brand img { height: 3.1rem; width: auto; }
.nav { display: flex; align-items: center; gap: clamp(.9rem, 2vw, 1.8rem); font-size: var(--step--1); }
.nav a { color: var(--ink); text-decoration: none; letter-spacing: .04em; }
.nav a:hover { color: var(--gold); }
.nav a.store { color: var(--night); }
.lang { border: 1px solid var(--line); border-radius: 999px; padding: .2rem .65rem; letter-spacing: .08em; }
.nav a.store:hover { color: var(--night); }
.nav .hide-sm { display: inline; }
@media (max-width: 720px) { .nav .hide-sm { display: none; } }

/* Store button */
.store {
  display: inline-flex; align-items: center; gap: .7rem;
  padding: .7rem 1.2rem .7rem 1rem;
  background: var(--ink); color: var(--night);
  border-radius: 999px; text-decoration: none;
  font-weight: 500; line-height: 1.15;
  box-shadow: 0 10px 30px -10px rgba(0,0,0,.6);
  transition: transform .2s ease, background .2s ease;
}
.store:hover { background: var(--gold-soft); color: var(--night); transform: translateY(-2px); }
.store svg { width: 1.5rem; height: 1.5rem; flex: none; }
.store small { display: block; font-size: .68rem; font-weight: 400; letter-spacing: .08em; text-transform: uppercase; opacity: .75; }
.store.sm { padding: .45rem .9rem; font-size: var(--step--1); box-shadow: none; }
.store-note { font-size: var(--step--1); color: var(--mist); }

/* Hero */
.hero { overflow: hidden; padding-block: clamp(2.5rem, 7vw, 6rem) clamp(3rem, 8vw, 6rem); }
.hero .wrap { display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, .95fr); gap: clamp(2rem, 5vw, 4rem); align-items: center; }
.hero-copy { display: grid; gap: 1.4rem; min-width: 0; }
.hero h1 { font-size: var(--step-4); }
.hero .cta-row { display: flex; flex-wrap: wrap; align-items: center; gap: .8rem 1.2rem; padding-top: .4rem; }

.fan { position: relative; aspect-ratio: 1 / 1.05; max-width: 30rem; width: 100%; justify-self: center; }
.fan > img {
  position: absolute; width: 52%; top: 12%; left: 24%;
  border-radius: 4.5% / 3.2%;
  box-shadow: 0 30px 60px -20px rgba(0,0,0,.75), 0 0 0 1px rgba(255,255,255,.08);
  transform-origin: 50% 110%;
  transition: transform .5s cubic-bezier(.2,.7,.2,1);
}
.fan > img:nth-child(1) { transform: rotate(-16deg) translateX(-14%); }
.fan > img:nth-child(2) { transform: rotate(0deg) translateY(-4%); z-index: 2; }
.fan > img:nth-child(3) { transform: rotate(16deg) translateX(14%); }
.fan:hover > img:nth-child(1) { transform: rotate(-22deg) translateX(-20%); }
.fan:hover > img:nth-child(3) { transform: rotate(22deg) translateX(20%); }
.fan:hover > img:nth-child(2) { transform: translateY(-8%); }

@media (max-width: 820px) {
  .hero .wrap { grid-template-columns: 1fr; }
  .fan { max-width: 22rem; order: -1; }
}

/* Sections */
section { padding-block: clamp(3.5rem, 9vw, 7rem); }
.section-head { display: grid; gap: .9rem; max-width: 40rem; margin-bottom: clamp(2rem, 5vw, 3.5rem); }
.section-head h2 { font-size: var(--step-3); }
.section-head.center { margin-inline: auto; text-align: center; justify-items: center; }

/* Statement */
.statement .wrap { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: clamp(2rem, 6vw, 5rem); align-items: start; }
.statement h2 { font-size: var(--step-3); }
.statement .body { display: grid; gap: 1.1rem; color: var(--mist); }
.statement .body strong { color: var(--ink); font-weight: 400; }
@media (max-width: 760px) { .statement .wrap { grid-template-columns: 1fr; } }

/* Deck: flip cards */
.deck-hint { font-size: var(--step--1); color: var(--gold-soft); display: flex; align-items: center; gap: .5rem; }
.deck-hint svg { width: 1rem; height: 1rem; }
.deck-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: clamp(1.2rem, 3vw, 2.2rem); }
.flip { perspective: 1400px; display: grid; gap: .8rem; min-width: 0; }
.flip-inner {
  position: relative; aspect-ratio: 1304 / 1872; width: 100%;
  transform-style: preserve-3d; transition: transform .7s cubic-bezier(.3,.7,.2,1);
  cursor: pointer; border-radius: 5% / 3.5%;
}
.flip-inner:focus-visible { outline: 2px solid var(--gold); outline-offset: 4px; }
.flip.is-flipped .flip-inner { transform: rotateY(180deg); }
.face { position: absolute; inset: 0; backface-visibility: hidden; -webkit-backface-visibility: hidden; border-radius: 5% / 3.5%; overflow: hidden; box-shadow: 0 22px 44px -20px rgba(0,0,0,.85); }
.face.front img { width: 100%; height: 100%; object-fit: cover; transition: transform .35s ease; }
.flip:not(.is-flipped) .flip-inner:hover .front img { transform: scale(1.03); }
.face.back {
  transform: rotateY(180deg);
  background:
    linear-gradient(180deg, rgba(14, 40, 48, .9), rgba(22, 46, 50, .93)),
    url("card-back.webp") center / cover;
  border: 1px solid rgba(226, 187, 114, .45);
  display: grid; grid-template-rows: auto minmax(0, 1fr) auto;
}
.back-head { padding: 1.1rem 1.2rem .6rem; border-bottom: 1px solid var(--line); }
.back-head h3 { font-family: var(--display); font-size: var(--step-2); color: var(--lilac); line-height: 1.05; }
.back-body { overflow-y: auto; overscroll-behavior: contain; padding: .8rem 1.2rem 1rem; display: grid; gap: .8rem; align-content: start; font-size: .88rem; line-height: 1.6; color: var(--mist); scrollbar-width: thin; scrollbar-color: rgba(226,187,114,.5) transparent; }
.back-foot { padding: .55rem 1.2rem .7rem; font-size: .72rem; letter-spacing: .12em; text-transform: uppercase; color: var(--gold); border-top: 1px solid var(--line); }
.flip-name { font-size: var(--step-0); color: var(--ink); font-weight: 400; }
@media (max-width: 900px) { .deck-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 560px) {
  .deck-grid { display: flex; overflow-x: auto; scroll-snap-type: x mandatory; gap: 1rem; padding-bottom: 1rem; margin-inline: calc(-1 * var(--gutter)); padding-inline: var(--gutter); scrollbar-width: none; }
  .deck-grid::-webkit-scrollbar { display: none; }
  .flip { flex: 0 0 78%; scroll-snap-align: center; }
}

/* Readings */
.readings .wrap { display: grid; gap: clamp(2rem, 5vw, 3rem); }
.reading-types { display: grid; align-items: start; grid-template-columns: minmax(0, .8fr) minmax(0, 1.2fr); gap: clamp(1rem, 3vw, 2rem); }
.reading { background: var(--panel); border: 1px solid var(--line); border-radius: 1.25rem; padding: clamp(1.4rem, 3vw, 2.2rem); display: grid; gap: 1rem; align-content: start; min-width: 0; }
.reading h3 { font-size: var(--step-2); }
.reading p { color: var(--mist); }

.spread { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: .8rem; max-width: 26rem; }
.slot { display: grid; gap: .45rem; justify-items: center; text-align: center; font-size: var(--step--1); color: var(--gold-soft); min-width: 0; }
.slot img { width: 100%; border-radius: 6% / 4%; box-shadow: 0 12px 26px -12px rgba(0,0,0,.85); }
.slot .n { color: var(--lilac); font-family: var(--display); font-size: 1.15rem; margin-right: .2rem; }
.slot.outcome { grid-column: 2; }
.single .slot { max-width: 7.5rem; }

.positions { display: grid; gap: .9rem; margin: 0; padding: 0; list-style: none; }
.positions li { display: grid; grid-template-columns: 6.5rem minmax(0, 1fr); gap: 1rem; padding-top: .9rem; border-top: 1px solid var(--line); }
.positions b { color: var(--ink); font-weight: 400; }
.positions span.time { display: block; font-size: var(--step--1); color: var(--gold); }
.positions p { color: var(--mist); font-size: .95em; }
@media (max-width: 820px) { .reading-types { grid-template-columns: 1fr; } }
@media (max-width: 420px) { .positions li { grid-template-columns: 1fr; gap: .2rem; } }

/* Journal */
.journal .wrap { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: clamp(2rem, 6vw, 5rem); align-items: center; }
.journal .copy { display: grid; gap: 1.2rem; }
.journal h2 { font-size: var(--step-3); }
.journal ul { margin: 0; padding: 0; list-style: none; display: grid; gap: .7rem; color: var(--mist); }
.journal li { padding-left: 1.4rem; position: relative; }
.journal li::before { content: ""; position: absolute; left: 0; top: .7em; width: .5rem; height: .5rem; border-radius: 50%; background: var(--gold); box-shadow: 0 0 10px var(--gold); }
@media (max-width: 760px) { .journal .wrap { grid-template-columns: 1fr; } }

/* Phones */
.phones { display: flex; gap: clamp(.8rem, 2.5vw, 1.6rem); justify-content: center; align-items: flex-end; flex-wrap: wrap; }
.phone {
  width: clamp(9rem, 22vw, 13rem); flex: none;
  border-radius: 1.8rem; padding: .45rem;
  background: linear-gradient(160deg, #2a3236, #0c1316);
  box-shadow: 0 30px 60px -25px rgba(0,0,0,.85), inset 0 0 0 1px rgba(255,255,255,.08);
}
.phone img { border-radius: 1.4rem; width: 100%; }
.phone.lift { transform: translateY(-1.2rem); }
.journal .phones { justify-content: flex-start; }
@media (max-width: 520px) { .phone { width: calc(50% - .5rem); } .phone.lift { transform: none; } }

/* FAQ */
.faq-list { display: grid; gap: 0; max-width: 46rem; margin-inline: auto; }
.faq-list details { border-top: 1px solid var(--line); padding-block: 1.1rem; }
.faq-list details:last-child { border-bottom: 1px solid var(--line); }
.faq-list summary { cursor: pointer; list-style: none; display: flex; justify-content: space-between; gap: 1rem; font-size: var(--step-1); font-weight: 300; }
.faq-list summary::-webkit-details-marker { display: none; }
.faq-list summary::after { content: "+"; color: var(--gold); font-size: 1.5rem; line-height: 1; transition: transform .25s ease; }
.faq-list details[open] summary::after { transform: rotate(45deg); }
.faq-list details p { color: var(--mist); padding-top: .7rem; max-width: 40em; }

/* Closing */
.closing { text-align: center; }
.closing .wrap { display: grid; justify-items: center; gap: 1.4rem; }
.closing h2 { font-size: var(--step-4); }

/* Footer */
.site-footer { border-top: 1px solid var(--line); padding-block: 2.5rem 3rem; background: rgba(8, 22, 28, .55); font-size: var(--step--1); color: var(--mist); }
.site-footer .wrap { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 1.5rem 2rem; }
.studio { display: flex; align-items: center; gap: .8rem; color: var(--mist); text-decoration: none; }
.studio img { height: 1.6rem; width: auto; }
.foot-links { display: flex; flex-wrap: wrap; gap: .6rem 1.4rem; }
.foot-links a { color: var(--ink); text-decoration: none; }
.foot-links a:hover { color: var(--gold); }
.socs { display: flex; gap: .5rem; }
.soc { display: grid; place-items: center; width: 2.4rem; height: 2.4rem; border-radius: 50%; border: 1px solid var(--line); color: var(--gold); background: rgba(255,255,255,.03); transition: background .2s, color .2s, border-color .2s; }
.soc svg { width: 1.15rem; height: 1.15rem; fill: currentColor; }
.soc:hover { background: var(--gold); border-color: var(--gold); color: var(--night); }

/* Legal / support pages */
.doc { padding-block: clamp(2.5rem, 7vw, 5rem); }
.doc .wrap { max-width: 46rem; display: grid; gap: 1.2rem; }
.doc h1 { font-size: var(--step-3); }
.doc h2 { font-size: var(--step-1); color: var(--gold-soft); margin-top: 1.4rem; font-weight: 400; }
.doc p, .doc li { color: var(--mist); }
.doc ul { margin: 0; padding-left: 1.2rem; display: grid; gap: .4rem; }
.doc .meta { font-size: var(--step--1); color: var(--gold); letter-spacing: .06em; }
.contact-card { background: var(--panel); border: 1px solid var(--line); border-radius: 1rem; padding: 1.4rem 1.6rem; display: grid; gap: .3rem; }
.contact-card b { font-weight: 400; color: var(--ink); }

/* Reading spreads: tap a card back to turn it over */
.spread-hint { font-size: var(--step--1); color: var(--gold-soft); display: flex; align-items: center; gap: .5rem; }
.spread-hint svg { width: 1rem; height: 1rem; flex: none; }
.slot-card { appearance: none; border: 0; padding: 0; margin: 0; background: none; display: block; width: 100%; cursor: pointer; perspective: 900px; border-radius: 6% / 4%; font: inherit; color: inherit; }
.slot-card:focus-visible { outline: 2px solid var(--gold); outline-offset: 4px; }
.slot-inner { position: relative; display: block; aspect-ratio: 420 / 603; transform-style: preserve-3d; transition: transform .65s cubic-bezier(.3,.7,.2,1); }
.slot-card:hover .slot-inner { transform: translateY(-3px); }
.slot.is-flipped .slot-inner { transform: rotateY(180deg); }
.slot .sface { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; backface-visibility: hidden; -webkit-backface-visibility: hidden; }
.slot .sfront { transform: rotateY(180deg); }
.slot-name { display: block; font-size: .78rem; color: var(--ink); line-height: 1.3; min-height: 1.3em; opacity: 0; transition: opacity .4s ease .25s; }
.slot.is-flipped .slot-name { opacity: 1; }

/* Creator */
.creator .wrap { display: grid; grid-template-columns: minmax(0, .8fr) minmax(0, 1.2fr); gap: clamp(2rem, 6vw, 5rem); align-items: center; }
.portrait { margin: 0; position: relative; max-width: 24rem; width: 100%; justify-self: center; }
.portrait::before { content: ""; position: absolute; inset: -.7rem; border: 1px solid rgba(226, 187, 114, .5); border-radius: 50% 50% 1.2rem 1.2rem / 36% 36% 1.2rem 1.2rem; }
.portrait img { width: 100%; aspect-ratio: 3 / 4; object-fit: cover; border-radius: 50% 50% .8rem .8rem / 34% 34% .8rem .8rem; box-shadow: 0 30px 60px -25px rgba(0,0,0,.8); }
.creator-copy { display: grid; gap: 1rem; min-width: 0; }
.creator-copy h2 { font-size: var(--step-4); }
.creator-copy .roles { font-size: var(--step--1); letter-spacing: .12em; text-transform: uppercase; color: var(--gold-soft); }
.creator-lead { font-size: var(--step-1); color: var(--ink); line-height: 1.5; }
.creator-copy p:not(.eyebrow):not(.roles):not(.creator-lead):not(.creator-links) { color: var(--mist); max-width: 38em; }
.creator-links { display: flex; flex-wrap: wrap; align-items: center; gap: .5rem 1.2rem; font-size: var(--step--1); padding-top: .4rem; }
.creator-links span { color: var(--mist); }
.creator-links a { color: var(--ink); text-decoration: none; border-bottom: 1px solid rgba(226, 187, 114, .5); padding-bottom: .1rem; }
.creator-links a:hover { color: var(--gold); }
@media (max-width: 760px) { .creator .wrap { grid-template-columns: 1fr; } .portrait { max-width: 17rem; } }

/* App logo + "by Soulspark Studio" lockup */
.brand-group { display: flex; align-items: center; gap: .7rem; min-width: 0; }
.by-studio { display: inline-flex; align-items: center; gap: .45rem; text-decoration: none; color: var(--mist); opacity: .85; transition: opacity .2s ease; padding-top: .35rem; }
.by-studio:hover { opacity: 1; }
.by-studio span { font-size: .78rem; letter-spacing: .04em; font-style: italic; }
.by-studio img { height: 1.6rem; width: auto; }
.by-studio .by-rule { width: 2px; height: 2.4rem; border-radius: 1px; background: rgba(238, 242, 247, .55); opacity: 1; margin: 0 .35rem; }
@media (max-width: 420px) { .by-studio img { height: 1.25rem; } .brand-group { gap: .45rem; } .by-studio span { font-size: .7rem; } }
@media (max-width: 420px) { .by-studio .by-rule { height: 1.8rem; margin: 0 .2rem; } }

/* 12 Oct 2026: social buttons beside the Play button, creator icons, two-row footer */
.hero .cta-row { justify-content: space-between; }
.creator-links .socs { gap: .5rem; }
.creator-links a.soc { color: var(--gold); border: 1px solid var(--line); padding: 0; }
.creator-links a.soc:hover { color: var(--night); border-color: var(--gold); }
.site-footer .wrap { flex-direction: column; align-items: stretch; gap: 1.4rem; }
.foot-top { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 1rem 2rem; }
/* App icon badge on the card fan, links to Google Play */
.fan-badge { position: absolute; z-index: 3; right: 6%; bottom: 4%; width: 22%; line-height: 0; transition: transform .45s cubic-bezier(.2,.7,.2,1); }
.fan-badge img { width: 100%; border-radius: 22%; box-shadow: 0 14px 30px -10px rgba(0,0,0,.8), 0 0 0 2px rgba(241, 220, 174, .55); }
.fan-badge:hover { transform: scale(1.15); }
.fan-badge:hover img { box-shadow: 0 18px 40px -10px rgba(0,0,0,.85), 0 0 0 2px rgba(241, 220, 174, .8), 0 0 26px rgba(190, 170, 255, .5); }
.closing-icon { display: block; width: clamp(4.5rem, 9vw, 6rem); line-height: 0; transition: transform .45s cubic-bezier(.2,.7,.2,1); }
.closing-icon img { width: 100%; border-radius: 22%; box-shadow: 0 14px 30px -10px rgba(0,0,0,.8), 0 0 0 2px rgba(241, 220, 174, .55); }
.closing-icon:hover { transform: scale(1.15); }
.closing-icon:hover img { box-shadow: 0 18px 40px -10px rgba(0,0,0,.85), 0 0 0 2px rgba(241, 220, 174, .8), 0 0 26px rgba(190, 170, 255, .5); }

/* Share button (header) */
.share-btn { position: relative; display: inline-grid; place-items: center; flex: none; width: 2rem; height: 2rem; padding: 0; border-radius: 6px; border: 0; background: transparent; color: var(--ink); opacity: .8; cursor: pointer; transition: opacity .2s, color .2s; }
.share-btn:hover { opacity: 1; color: var(--gold); }
.share-btn svg { width: auto; height: 1.35rem; }
.share-tip { position: absolute; top: calc(100% + .5rem); right: 0; white-space: nowrap; font-size: .75rem; letter-spacing: .03em; padding: .3rem .7rem; border-radius: 999px; background: var(--ink); color: var(--night); opacity: 0; pointer-events: none; transition: opacity .2s; }
.share-btn.copied .share-tip { opacity: 1; }
