/* StorkyVerse one-page site. Mobile first. */
:root {
  --bg: #140c2e;
  --bg-2: #1c1240;
  --surface: #241852;
  --surface-2: #2e2066;
  --line: rgba(255, 255, 255, .1);
  --text: #fff7ec;
  --muted: #cfc6ec;
  --orange: #ff7a1a;
  --orange-2: #ff9a3d;
  --yellow: #ffc22e;
  --green: #8be04e;
  --pink: #ff8fb1;
  --teal: #2fb5a6;
  --radius: 22px;
  --display: "Lilita One", "Arial Rounded MT Bold", system-ui, sans-serif;
  --body: "Nunito", system-ui, -apple-system, "Segoe UI", sans-serif;
  --gutter: 16px;
  --head-h: 64px;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: calc(var(--head-h) + 8px); -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: var(--body);
  font-size: 1.0625rem;
  line-height: 1.6;
  color: var(--text);
  background: var(--bg);
  overflow-x: hidden;
}
img, video { display: block; max-width: 100%; height: auto; }
a { color: var(--yellow); }
a:hover { color: #ffe08a; }
h1, h2, h3 { font-family: var(--display); font-weight: 400; line-height: 1.05; margin: 0 0 .5em; letter-spacing: .01em; }
p { margin: 0 0 1em; }

:focus-visible { outline: 3px solid var(--yellow); outline-offset: 3px; border-radius: 8px; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
.skip { position: absolute; left: 12px; top: -60px; z-index: 100; background: var(--yellow); color: #1a1033; padding: 10px 16px; border-radius: 12px; font-weight: 800; text-decoration: none; }
.skip:focus { top: 12px; }

.wrap { width: 100%; max-width: 1180px; margin: 0 auto; padding: 0 var(--gutter); }
.eyebrow { font-weight: 800; font-size: .78rem; letter-spacing: .12em; text-transform: uppercase; color: var(--orange-2); margin-bottom: .75em; }

/* Buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .5em;
  min-height: 54px; padding: 14px 26px;
  font-family: var(--display); font-size: 1.2rem; letter-spacing: .02em; line-height: 1.1;
  color: #1a1033; text-decoration: none; text-align: center;
  border-radius: 999px; border: 3px solid #1a1033;
  box-shadow: 0 5px 0 #1a1033, 0 12px 26px rgba(0, 0, 0, .35);
  transition: transform .15s ease, box-shadow .15s ease, filter .15s ease;
}
.btn::before { content: "▶"; font-size: .75em; }
.btn:hover { color: #1a1033; transform: translateY(-2px); box-shadow: 0 7px 0 #1a1033, 0 16px 30px rgba(0, 0, 0, .4); filter: brightness(1.06); }
.btn:active { transform: translateY(3px); box-shadow: 0 2px 0 #1a1033, 0 6px 14px rgba(0, 0, 0, .35); }
.btn--survivors { background: linear-gradient(180deg, #b4f36d, var(--green)); }
.btn--neck { background: linear-gradient(180deg, #ffd25e, var(--orange-2)); }

/* Top bar */
.topbar {
  position: sticky; top: 0; z-index: 50;
  background: rgba(20, 12, 46, .82);
  backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--line);
}
.topbar__inner { display: flex; align-items: center; gap: 12px; height: var(--head-h); }
.topbar__logo img { width: 112px; height: auto; }
.topbar__nav { display: flex; gap: 4px; margin-left: auto; }
.topbar__nav a {
  color: var(--text); text-decoration: none; font-weight: 800; font-size: .95rem;
  padding: 8px 10px; border-radius: 999px; transition: background .15s;
}
.topbar__nav a:hover { background: var(--surface-2); color: var(--text); }
.topbar__by { display: none; color: var(--muted); font-size: .82rem; font-weight: 600; text-decoration: none; white-space: nowrap; }
.topbar__by:hover { color: var(--text); text-decoration: underline; }
.hide-sm { display: none; }

/* Hero */
.hero {
  position: relative; overflow: hidden;
  padding: 32px 0 0;
  display: flex; flex-direction: column;
  background:
    radial-gradient(60% 55% at 50% 100%, rgba(255, 122, 26, .55), transparent 70%),
    radial-gradient(40% 40% at 10% 20%, rgba(143, 92, 255, .35), transparent 70%),
    radial-gradient(35% 35% at 92% 15%, rgba(47, 181, 166, .25), transparent 70%),
    var(--bg);
}
.hero__text { text-align: center; position: relative; z-index: 2; }
.hero h1 { font-size: clamp(2.5rem, 10.5vw, 5.4rem); max-width: 14ch; margin: 0 auto .35em; text-shadow: 0 4px 0 rgba(0, 0, 0, .3); }
.hero h1 .hl { color: var(--orange); display: inline-block; transform: rotate(-2deg); }
.hero__sub { color: var(--muted); max-width: 40rem; margin: 0 auto; font-size: 1.08rem; }
/* Phones: lineup first so the Storkys show on the first screen, buttons below. */
.hero__cta { order: 3; width: 100%; position: relative; z-index: 3; display: flex; flex-direction: column; gap: 14px; max-width: 400px; margin: 0 auto; padding-top: 30px; padding-bottom: 44px; }

.hero__stage {
  position: relative; z-index: 1;
  display: flex; justify-content: center; align-items: flex-end;
  /* The six side by side are ~3.3× as wide as they are tall, so the height
     follows the viewport width to keep all six on screen. */
  order: 2; width: 100%;
  height: 46vw;
  margin: 26px auto 0; max-width: 1180px; padding: 0 4px;
}
.hero__stage::after { /* lit floor */
  content: ""; position: absolute; left: 6%; right: 6%; bottom: -26px; height: 60px; z-index: -1;
  background: radial-gradient(50% 50% at 50% 50%, rgba(255, 200, 140, .4), transparent 75%);
}
.hero__bird {
  height: calc(var(--h) * 100%); width: auto; max-width: none;
  margin: 0 -3.6%;
  filter: drop-shadow(0 10px 18px rgba(0, 0, 0, .35));
  animation: bob 4.2s ease-in-out infinite;
  animation-delay: var(--d);
  transform-origin: 50% 100%;
}
.b-dash   { --h: .86; --d: -.4s; }
.b-art    { --h: .92; --d: -1.6s; }
.b-cool   { --h: 1;   --d: -.9s;  position: relative; z-index: 2; }
.b-dev    { --h: 1;   --d: -2.4s; position: relative; z-index: 2; }
.b-cut    { --h: .9;  --d: -3.1s; }
.b-rookie { --h: .85; --d: -1.2s; }
@keyframes bob {
  0%, 100% { transform: translateY(0) rotate(0); }
  50% { transform: translateY(-3.5%) rotate(.6deg); }
}

/* Sections */
.section { padding: 72px 0; position: relative; }
.section__head { text-align: center; max-width: 44rem; margin: 0 auto 36px; }
.section h2 { font-size: clamp(2.2rem, 7vw, 3.4rem); }
.section__intro { color: var(--muted); margin: 0; }

/* Games */
.games { display: grid; gap: 28px; }
.game {
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
  overflow: hidden; display: flex; flex-direction: column;
  box-shadow: 0 18px 40px rgba(0, 0, 0, .3);
  transition: transform .25s ease, box-shadow .25s ease;
}
.game:hover { transform: translateY(-6px); box-shadow: 0 26px 50px rgba(0, 0, 0, .4); }
.game--survivors { border-top: 5px solid var(--green); }
.game--neck { border-top: 5px solid var(--orange-2); }
.game__media { position: relative; }
.game__media > img { width: 100%; aspect-ratio: 16 / 9; object-fit: cover; }
.game__shot {
  position: absolute; right: 12px; bottom: -28px; width: 38%; margin: 0;
  border: 3px solid var(--text); border-radius: 12px; overflow: hidden;
  box-shadow: 0 10px 22px rgba(0, 0, 0, .45); transform: rotate(2deg);
  background: var(--bg);
}
.game__shot figcaption {
  position: absolute; left: 6px; top: 6px; font-size: .68rem; font-weight: 800; letter-spacing: .06em; text-transform: uppercase;
  background: rgba(20, 12, 46, .85); padding: 2px 8px; border-radius: 999px;
}
.game__body { padding: 26px 22px 26px; display: flex; flex-direction: column; flex: 1; }
.game__body h3 { font-size: clamp(1.9rem, 6vw, 2.4rem); padding-right: 38%; }
.game--survivors h3 { color: var(--green); }
.game--neck h3 { color: var(--orange-2); }
.game__body p { color: var(--muted); }
.tags { list-style: none; padding: 0; margin: 4px 0 22px; display: flex; flex-wrap: wrap; gap: 8px; }
.tags li { font-size: .85rem; font-weight: 800; padding: 6px 12px; border-radius: 999px; background: var(--surface-2); border: 1px solid var(--line); }
.game__cta { margin-top: auto; display: flex; flex-wrap: wrap; align-items: center; gap: 12px 18px; }
.game__cta .btn { flex: 1 1 auto; }
.device { font-size: .88rem; font-weight: 700; color: var(--muted); display: inline-flex; align-items: center; gap: 6px; }
.device::before { content: ""; width: 18px; height: 18px; background: currentColor; -webkit-mask: var(--ico) center / contain no-repeat; mask: var(--ico) center / contain no-repeat;
  --ico: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round'%3E%3Crect x='2' y='4' width='14' height='10' rx='1.5'/%3E%3Cpath d='M6 18h6'/%3E%3Crect x='16' y='8' width='6' height='12' rx='1.5'/%3E%3C/svg%3E"); }
.more { text-align: center; margin: 40px 0 0; font-weight: 800; color: var(--muted); font-size: 1.1rem; }

/* Storkys */
.section--storkys { background: linear-gradient(180deg, var(--bg) 0%, var(--bg-2) 30%, var(--bg-2) 70%, var(--bg) 100%); }
.hint-hover { display: none; }
.cast {
  display: flex; gap: 16px; overflow-x: auto; scroll-snap-type: x mandatory;
  padding: 8px var(--gutter) 28px; scroll-padding: 0 var(--gutter);
  scrollbar-width: thin; scrollbar-color: var(--surface-2) transparent;
}
.cast:focus-visible { outline-offset: -3px; }
.storky {
  flex: 0 0 78%; max-width: 320px; scroll-snap-align: start;
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden;
  display: flex; flex-direction: column;
  transition: transform .25s ease, box-shadow .25s ease;
}
.storky:hover { transform: translateY(-6px); box-shadow: 0 22px 40px rgba(0, 0, 0, .35); }
.storky__media {
  position: relative; display: block; width: 100%; padding: 0; border: 0; cursor: pointer;
  aspect-ratio: 4 / 5; overflow: hidden;
  background: radial-gradient(70% 60% at 50% 45%, rgba(255, 255, 255, .45), transparent 70%), var(--c);
}
.storky__media img {
  position: absolute; left: 50%; bottom: 3%; height: 94%; width: auto; max-width: none;
  transform: translateX(-50%);
  transition: transform .3s ease, opacity .3s ease;
}
.storky:hover .storky__media img { transform: translateX(-50%) translateY(-3%) scale(1.03); }
.storky__media video {
  position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; background: var(--c);
  opacity: 0; transition: opacity .35s ease;
}
.storky.is-playing .storky__media video { opacity: 1; }
.storky.is-playing .storky__media img { opacity: 0; }
.storky__media::after { /* play badge */
  content: "▶"; position: absolute; right: 12px; top: 12px; width: 34px; height: 34px; border-radius: 50%;
  display: grid; place-items: center; font-size: .8rem; padding-left: 2px;
  background: rgba(20, 12, 46, .75); color: var(--text); transition: opacity .2s;
}
.storky.is-playing .storky__media::after { content: "❚❚"; font-size: .7rem; padding-left: 0; }
.storky { position: relative; }
.storky__sound { /* Unmute pill: shows while the clip plays */
  position: absolute; left: 12px; top: 12px; z-index: 3;
  display: inline-flex; align-items: center; gap: 6px; min-height: 36px; padding: 6px 14px 6px 10px;
  font: 800 .85rem/1 var(--body); color: var(--text); cursor: pointer;
  background: rgba(20, 12, 46, .82); border: 2px solid rgba(255, 255, 255, .25); border-radius: 999px;
  opacity: 0; pointer-events: none; transform: translateY(-4px);
  transition: opacity .2s ease, transform .2s ease, background .15s ease;
}
.storky.is-playing .storky__sound, .storky__sound:focus-visible { opacity: 1; pointer-events: auto; transform: none; }
.storky__sound:hover { background: var(--orange); color: #1a1033; border-color: #1a1033; }
.storky__sound[aria-pressed="true"] { background: var(--yellow); color: #1a1033; border-color: #1a1033; }
.storky.no-video .storky__media { cursor: default; }
.storky.no-video .storky__media::after { display: none; }
.storky__body { padding: 20px 20px 22px; border-top: 4px solid var(--accent); flex: 1; }
.storky__body h3 { font-size: 2rem; margin-bottom: .1em; }
.storky__tag { font-weight: 800; color: var(--accent); margin-bottom: .6em; filter: brightness(1.25); }
.storky__body p { font-size: .98rem; color: var(--muted); }
.fact { background: var(--surface-2); border-radius: 14px; padding: 10px 14px; margin: 0; }
.fact strong { color: var(--text); }

/* About */
.about { display: grid; gap: 32px; }
.about__text { max-width: 46rem; }
.about__text p { color: var(--muted); }
.about__text p:first-of-type { color: var(--text); font-size: 1.15rem; }
.about__facts { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: 1fr 1fr; gap: 14px; align-content: start; }
.about__facts li { background: var(--surface); border: 1px solid var(--line); border-radius: 18px; padding: 18px; }
.about__facts strong { display: block; font-family: var(--display); font-weight: 400; font-size: 2.4rem; line-height: 1; color: var(--orange); }
.about__facts span { color: var(--muted); font-weight: 700; font-size: .92rem; }

/* FAQ */
.section--faq { padding-top: 24px; }
.faq { max-width: 820px; }
.faq h2 { text-align: center; }
.faq__list { display: grid; gap: 12px; }
.faq details { background: var(--surface); border: 1px solid var(--line); border-radius: 18px; }
.faq summary {
  list-style: none; cursor: pointer; padding: 18px 56px 18px 20px; position: relative;
  font-weight: 800; font-size: 1.08rem; border-radius: 18px;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: "+"; position: absolute; right: 18px; top: 50%; transform: translateY(-50%);
  width: 28px; height: 28px; border-radius: 50%; display: grid; place-items: center;
  background: var(--surface-2); font-size: 1.2rem; line-height: 1; transition: transform .2s;
}
.faq details[open] summary::after { transform: translateY(-50%) rotate(45deg); }
.faq details p { padding: 0 20px 18px; margin: 0; color: var(--muted); }

/* Footer */
.footer { border-top: 1px solid var(--line); padding: 44px 0 36px; background: #0f0924; text-align: center; }
.footer__inner { display: flex; flex-direction: column; align-items: center; gap: 12px; }
.footer__logo img { width: 150px; }
.footer__by { color: var(--muted); font-weight: 700; margin: 0; }
.footer__links { display: flex; flex-wrap: wrap; justify-content: center; gap: 6px 20px; }
.footer__links a { color: var(--text); font-weight: 700; padding: 6px 2px; }
.footer__copy { color: var(--muted); font-size: .88rem; margin: 6px 0 0; }

/* Scroll reveal (only when JS is on) */
.js .reveal { opacity: 0; transform: translateY(26px); transition: opacity .7s ease, transform .7s ease; }
.js .reveal.is-visible { opacity: 1; transform: none; }

/* ≥ 600px */
@media (min-width: 600px) {
  :root { --gutter: 24px; }
  .hide-sm { display: inline; }
  .topbar__logo img { width: 132px; }
  .hero { padding-top: 56px; }
  .hero__cta { order: 1; flex-direction: row; justify-content: center; max-width: none; padding: 28px var(--gutter) 0; }
  .hero__stage { height: min(420px, 36vw); }
  .hero__bird { margin: 0 -2%; }
  .storky { flex-basis: 46%; }
}

/* ≥ 860px */
@media (min-width: 860px) {
  .topbar__by { display: inline; margin-left: 12px; padding-left: 16px; border-left: 1px solid var(--line); }
  .topbar__nav a { padding: 8px 14px; }
  .games { grid-template-columns: 1fr 1fr; }
  .game__body h3 { padding-right: 0; }
  .game__body { padding-top: 40px; }
  .about { grid-template-columns: 1.6fr 1fr; align-items: center; gap: 56px; }
  .section { padding: 96px 0; }
}

/* ≥ 960px: 3 × 2 cast grid */
@media (min-width: 960px) {
  .cast {
    display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px;
    max-width: 1180px; margin: 0 auto; overflow: visible; padding: 8px var(--gutter) 0;
  }
  .storky { max-width: none; }
  .hint-tap { display: none; }
  .hint-hover { display: inline; }
}
@media (hover: none) { .hint-hover { display: none !important; } .hint-tap { display: inline !important; } }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
  .js .reveal { opacity: 1; transform: none; }
  .game:hover, .storky:hover, .btn:hover { transform: none; }
}
