@import url("https://fonts.googleapis.com/css2?family=Fraunces:opsz,wght@9..144,600;9..144,700&family=Space+Grotesk:wght@400;500;700&display=swap");

:root {
  --bg-main: #f8f2e8;
  --bg-deep: #f3e8d9;
  --panel: rgba(255, 250, 243, 0.86);
  --panel-strong: rgba(255, 252, 247, 0.94);
  --panel-dark: #1b2230;
  --line: rgba(43, 39, 32, 0.10);
  --line-strong: rgba(43, 39, 32, 0.18);
  --text-main: #1b2230;
  --text-soft: #5e5a54;
  --text-muted: #847c72;
  --accent: #0f6bff;
  --accent-2: #ef6f42;
  --accent-3: #1aa28a;
  --accent-soft: rgba(15, 107, 255, 0.12);
  --glow-blue: rgba(15, 107, 255, 0.22);
  --glow-orange: rgba(239, 111, 66, 0.16);
  --shadow-lg: 0 36px 90px rgba(45, 37, 24, 0.14);
  --shadow-md: 0 18px 44px rgba(45, 37, 24, 0.10);
  --radius-xl: 2rem;
  --radius-lg: 1.5rem;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: "Space Grotesk", sans-serif;
  color: var(--text-main);
  background:
    radial-gradient(circle at 8% 12%, rgba(15, 107, 255, 0.16), transparent 0 26rem),
    radial-gradient(circle at 88% 6%, rgba(239, 111, 66, 0.18), transparent 0 19rem),
    radial-gradient(circle at 76% 72%, rgba(26, 162, 138, 0.10), transparent 0 24rem),
    linear-gradient(180deg, var(--bg-main) 0%, var(--bg-deep) 100%);
  text-rendering: optimizeLegibility;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  background:
    linear-gradient(90deg, rgba(255, 255, 255, 0.28) 0, rgba(255, 255, 255, 0) 100%),
    repeating-linear-gradient(90deg, rgba(27, 34, 48, 0.045) 0 1px, transparent 1px 120px),
    repeating-linear-gradient(180deg, rgba(27, 34, 48, 0.04) 0 1px, transparent 1px 120px);
  mask-image: linear-gradient(180deg, rgba(0, 0, 0, 0.55), transparent 90%);
  z-index: -2;
}

body::after {
  content: "";
  position: fixed;
  inset: auto 8% 8% auto;
  width: 24rem;
  height: 24rem;
  border-radius: 999px;
  background: radial-gradient(circle, rgba(255, 255, 255, 0.46) 0%, rgba(255, 255, 255, 0) 72%);
  filter: blur(24px);
  pointer-events: none;
  z-index: -1;
}

.bg-apple-cloud {
  background-color: var(--bg-main);
}

.text-apple-ink {
  color: var(--text-main);
}

.text-apple-blue {
  color: var(--accent);
}

.hover\:text-apple-blue:hover {
  color: var(--accent);
}

a {
  color: inherit;
  text-decoration: none;
}

p,
li,
dd,
dt {
  text-wrap: pretty;
}

.page-shell {
  position: relative;
  isolation: isolate;
  overflow: visible;
}

.page-shell::before {
  content: "";
  position: absolute;
  inset: 18rem auto auto 50%;
  width: min(92vw, 78rem);
  height: 34rem;
  transform: translateX(-50%);
  border-radius: 3rem;
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.30), rgba(255, 255, 255, 0.02));
  border: 1px solid rgba(255, 255, 255, 0.45);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.55);
  pointer-events: none;
  z-index: -1;
}

.skip-link {
  position: absolute;
  left: 1rem;
  top: -3rem;
  z-index: 50;
  border-radius: 999px;
  background: #111827;
  color: #ffffff;
  padding: 0.75rem 1rem;
  font-size: 0.875rem;
  font-weight: 600;
  transition: top 0.2s ease;
}

.skip-link:focus {
  top: 1rem;
}

.ambient-orb {
  position: absolute;
  z-index: -1;
  border-radius: 999px;
  filter: blur(10px);
  opacity: 0.9;
  animation: drift 16s ease-in-out infinite alternate;
}

.ambient-orb-left {
  left: -9rem;
  top: 3rem;
  height: 21rem;
  width: 21rem;
  background: radial-gradient(circle, rgba(15, 107, 255, 0.22) 0%, rgba(15, 107, 255, 0.02) 72%);
}

.ambient-orb-right {
  right: -7rem;
  top: 10rem;
  height: 16rem;
  width: 16rem;
  background: radial-gradient(circle, rgba(239, 111, 66, 0.18) 0%, rgba(239, 111, 66, 0.02) 74%);
  animation-duration: 19s;
}

.site-nav {
  position: sticky;
  top: 1rem;
  z-index: 40;
  width: min(calc(100% - 1.5rem), 80rem);
  margin-top: 1rem;
  border: 1px solid rgba(255, 255, 255, 0.55);
  border-radius: 999px;
  background: rgba(255, 252, 247, 0.72);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
  box-shadow: 0 12px 32px rgba(45, 37, 24, 0.08);
}

.site-nav > a:first-child {
  font-weight: 700;
  letter-spacing: 0.22em;
  color: var(--text-main);
}

.site-nav > div a {
  position: relative;
}

.site-nav > div a::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -0.4rem;
  width: 100%;
  height: 2px;
  border-radius: 999px;
  background: linear-gradient(90deg, var(--accent), var(--accent-2));
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.25s ease;
}

.site-nav > div a:hover::after {
  transform: scaleX(1);
}

.site-nav > a:last-child,
.cta-primary {
  position: relative;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.28);
  background: linear-gradient(135deg, var(--accent), #3a8dff 55%, #69b0ff 100%);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.42),
    0 18px 36px rgba(15, 107, 255, 0.20);
}

.site-nav > a:last-child::before,
.cta-primary::before {
  content: "";
  position: absolute;
  inset: 1px;
  border-radius: inherit;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.30), rgba(255, 255, 255, 0));
  pointer-events: none;
}

.cta-primary:hover,
.site-nav > a:last-child:hover {
  transform: translateY(-2px);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.42),
    0 22px 40px rgba(15, 107, 255, 0.25);
}

.cta-secondary {
  position: relative;
  border-color: rgba(27, 34, 48, 0.12);
  background: rgba(255, 255, 255, 0.56);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.8);
}

.cta-secondary:hover {
  transform: translateY(-2px);
  background: rgba(255, 255, 255, 0.82);
}

.hero-grid {
  align-items: start;
}

.hero-copy {
  position: relative;
  padding-top: 1.2rem;
}

.hero-copy::after {
  content: "";
  position: absolute;
  left: 0;
  top: 100%;
  width: 10rem;
  height: 0.45rem;
  border-radius: 999px;
  background: linear-gradient(90deg, var(--accent), var(--accent-2), transparent);
  opacity: 0.7;
}

.hero-kicker {
  border-color: rgba(255, 255, 255, 0.75);
  background: rgba(255, 255, 255, 0.68);
  color: var(--text-main);
  box-shadow: 0 12px 28px rgba(45, 37, 24, 0.06);
}

.hero-title,
.section-title,
.content-panel > h1,
.content-panel h2 {
  font-family: "Fraunces", serif;
  font-weight: 700;
  letter-spacing: -0.04em;
}

.hero-title {
  max-width: 9ch;
  font-size: clamp(3.4rem, 7vw, 6.8rem);
  line-height: 0.92;
  text-wrap: balance;
}

.hero-lead {
  max-width: 38rem;
  color: var(--text-soft);
  font-size: 1.08rem;
}

.hero-pills span {
  font-size: 0.78rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.hero-pills a,
.page-links a,
.footer-links a {
  position: relative;
  overflow: hidden;
  border: 1px solid rgba(27, 34, 48, 0.10);
  background: rgba(255, 255, 255, 0.54);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.75);
  transition:
    transform 0.25s ease,
    border-color 0.25s ease,
    background 0.25s ease,
    box-shadow 0.25s ease;
}

.hero-pills a:hover,
.page-links a:hover,
.footer-links a:hover {
  transform: translateY(-2px);
  border-color: rgba(15, 107, 255, 0.26);
  background: rgba(255, 255, 255, 0.82);
  box-shadow: 0 10px 24px rgba(45, 37, 24, 0.08);
}

.hero-metrics .info-chip:nth-child(1) {
  --chip-accent: rgba(15, 107, 255, 0.16);
}

.hero-metrics .info-chip:nth-child(2) {
  --chip-accent: rgba(239, 111, 66, 0.14);
}

.hero-metrics .info-chip:nth-child(3) {
  --chip-accent: rgba(26, 162, 138, 0.14);
}

.glass-panel,
.content-panel,
.info-chip,
.subtle-card,
.step-card,
.feature-card,
.faq-card {
  position: relative;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.42);
  background: linear-gradient(180deg, rgba(255, 252, 247, 0.94), rgba(253, 249, 242, 0.82));
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
  box-shadow: var(--shadow-md);
}

.glass-panel::before,
.content-panel::before,
.info-chip::before,
.subtle-card::before,
.step-card::before,
.feature-card::before,
.faq-card::before {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.55), rgba(255, 255, 255, 0) 30%),
    radial-gradient(circle at top right, rgba(15, 107, 255, 0.10), transparent 34%);
}

.glass-panel,
.content-panel {
  border-radius: var(--radius-xl);
}

.glass-panel {
  padding: 1.6rem;
  background:
    linear-gradient(180deg, rgba(255, 251, 245, 0.95), rgba(247, 240, 230, 0.88));
}

.hero-aside {
  transform: translateY(0.6rem) rotate(-1.5deg);
}

.hero-aside > * {
  transform: rotate(1.5deg);
}

.content-panel {
  padding: 1.8rem;
}

.content-panel:nth-of-type(3n + 2) {
  background:
    linear-gradient(180deg, rgba(245, 249, 255, 0.94), rgba(255, 251, 244, 0.84));
}

.content-panel:nth-of-type(3n + 3) {
  background:
    linear-gradient(180deg, rgba(255, 245, 238, 0.94), rgba(255, 251, 245, 0.84));
}

.content-panel > section + section {
  border-top: 1px dashed rgba(27, 34, 48, 0.10);
  padding-top: 1.6rem;
}

.section-header {
  max-width: 50rem;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  margin: 0;
  padding: 0.45rem 0.85rem;
  border-radius: 999px;
  border: 1px solid rgba(27, 34, 48, 0.09);
  background: rgba(255, 255, 255, 0.46);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: var(--text-muted);
}

.section-title {
  margin: 1rem 0 0;
  max-width: 18ch;
  font-size: clamp(2.1rem, 3vw + 1rem, 3.4rem);
  line-height: 0.98;
  color: #161d2a;
  text-wrap: balance;
}

.section-copy {
  margin: 1rem 0 1.9rem;
  max-width: 60ch;
  font-size: 1rem;
  line-height: 1.9;
  color: var(--text-soft);
}

.info-chip {
  --chip-accent: rgba(15, 107, 255, 0.12);
  border-radius: 1.55rem;
  padding: 1rem 1.1rem 1.15rem;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.94), rgba(249, 242, 232, 0.92));
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.info-chip::after {
  content: "";
  position: absolute;
  inset: 0 auto auto 0;
  width: 100%;
  height: 0.38rem;
  background: linear-gradient(90deg, var(--chip-accent), transparent 70%);
}

.info-chip:hover,
.subtle-card:hover,
.step-card:hover,
.feature-card:hover,
.faq-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-lg);
}

.subtle-card,
.step-card,
.feature-card,
.faq-card {
  border-radius: var(--radius-lg);
  padding: 1.45rem;
  transition: transform 0.35s ease, box-shadow 0.35s ease, border-color 0.35s ease;
}

.subtle-card::after,
.feature-card::after,
.faq-card::after {
  content: "";
  position: absolute;
  right: -2rem;
  top: -2rem;
  width: 6rem;
  height: 6rem;
  border-radius: 999px;
  background: radial-gradient(circle, rgba(15, 107, 255, 0.14) 0%, rgba(15, 107, 255, 0) 70%);
  opacity: 0.9;
  pointer-events: none;
}

.subtle-card h3,
.feature-card h3,
.faq-card h3,
.step-card h3 {
  line-height: 1.15;
  text-wrap: balance;
}

.spotlight-card {
  position: relative;
  overflow: hidden;
  background:
    radial-gradient(circle at top right, rgba(90, 178, 255, 0.24), transparent 34%),
    linear-gradient(155deg, #111827 0%, #1e293b 48%, #13213a 100%);
  box-shadow: 0 30px 70px rgba(17, 24, 39, 0.34);
}

.spotlight-card::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(120deg, rgba(255, 255, 255, 0.14), rgba(255, 255, 255, 0) 44%),
    radial-gradient(circle at 80% 20%, rgba(239, 111, 66, 0.22), transparent 32%);
  pointer-events: none;
}

.mini-spotlight {
  min-height: 100%;
}

.key-points li {
  position: relative;
  padding-left: 1.35rem;
}

.key-points li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.75rem;
  width: 0.55rem;
  height: 0.55rem;
  border-radius: 999px;
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  box-shadow: 0 0 0 6px rgba(15, 107, 255, 0.08);
}

.callout-card {
  background:
    linear-gradient(180deg, rgba(236, 246, 255, 0.95), rgba(226, 240, 255, 0.88));
  border-color: rgba(15, 107, 255, 0.14);
}

.callout-card p {
  color: #275287;
}

.game-shell {
  position: relative;
  overflow: hidden;
  border-color: rgba(255, 255, 255, 0.18);
  box-shadow: 0 32px 76px rgba(8, 15, 27, 0.28);
}

.game-stage {
  display: grid;
  gap: 1rem;
}

.game-stage-intro {
  display: flex;
  flex-wrap: wrap;
  align-items: end;
  justify-content: space-between;
  gap: 1rem;
}

.game-stage-kicker {
  margin: 0;
  font-size: 0.74rem;
  font-weight: 700;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: var(--text-muted);
}

.game-stage-title {
  margin: 0.55rem 0 0;
  max-width: 16ch;
  font-family: "Fraunces", serif;
  font-size: clamp(2rem, 3vw + 1rem, 3.1rem);
  line-height: 0.96;
  letter-spacing: -0.04em;
  color: #182130;
  text-wrap: balance;
}

.game-stage-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 0.65rem;
}

.game-stage-badges span {
  display: inline-flex;
  align-items: center;
  border: 1px solid rgba(27, 34, 48, 0.10);
  border-radius: 999px;
  padding: 0.58rem 0.9rem;
  background: rgba(255, 255, 255, 0.6);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.8);
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text-soft);
}

.game-shell::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  border: 1px solid rgba(255, 255, 255, 0.12);
  pointer-events: none;
}

.game-frame-shell {
  position: relative;
  aspect-ratio: 16 / 10;
  min-height: 31rem;
  background:
    radial-gradient(circle at top left, rgba(78, 157, 255, 0.16), transparent 28%),
    repeating-linear-gradient(90deg, rgba(255, 255, 255, 0.04) 0 1px, transparent 1px 52px),
    repeating-linear-gradient(180deg, rgba(255, 255, 255, 0.03) 0 1px, transparent 1px 52px),
    linear-gradient(180deg, rgba(14, 20, 34, 0.92) 0%, rgba(11, 18, 31, 1) 100%);
}

.game-frame-shell::before {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.04), transparent 20%),
    radial-gradient(circle at 50% 0%, rgba(15, 107, 255, 0.20), transparent 36%);
}

.game-frame-shell iframe {
  display: block;
  height: 100%;
  width: 100%;
  border: 0;
  background: #0f172a;
}

.game-action-bar {
  display: grid;
  gap: 0.9rem;
  padding: 1.15rem 1.2rem 0.1rem;
}

.game-action-copy {
  margin: 0;
  max-width: 65ch;
  color: var(--text-soft);
  font-size: 0.95rem;
  line-height: 1.8;
}

.play-side-stack {
  align-content: start;
}

.play-side-hero {
  background:
    linear-gradient(180deg, rgba(244, 249, 255, 0.96), rgba(255, 249, 241, 0.88));
}

.play-checklist {
  padding: 0;
  margin: 0;
  list-style: none;
}

.play-checklist li {
  position: relative;
  padding-left: 1.5rem;
}

.play-checklist li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.72rem;
  width: 0.55rem;
  height: 0.55rem;
  border-radius: 999px;
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  box-shadow: 0 0 0 5px rgba(15, 107, 255, 0.08);
}

.play-facts dt {
  color: var(--text-soft);
}

.play-facts dd {
  margin: 0;
}

.related-link {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
}

.related-link::after {
  content: "->";
  font-size: 0.78rem;
  transition: transform 0.25s ease;
}

.related-link:hover::after {
  transform: translateX(4px);
}

.category-link {
  align-items: center;
  gap: 0.55rem;
}

.category-link::after {
  content: "->";
  font-size: 0.8rem;
  transition: transform 0.25s ease;
}

.category-link:hover::after {
  transform: translateX(4px);
}

.page-links {
  margin-bottom: 1.8rem;
}

.page-links a,
.footer-links a {
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  padding: 0.52rem 0.95rem;
}

.footer-panel {
  position: relative;
  overflow: hidden;
  background:
    linear-gradient(180deg, rgba(255, 252, 247, 0.92), rgba(249, 241, 229, 0.86));
  box-shadow: var(--shadow-md);
}

.footer-panel::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(120deg, rgba(255, 255, 255, 0.34), rgba(255, 255, 255, 0) 48%),
    radial-gradient(circle at 100% 0%, rgba(15, 107, 255, 0.12), transparent 30%);
  pointer-events: none;
}

.footer-links {
  gap: 0.55rem;
}

.footer-panel .text-xs {
  max-width: 54rem;
}

.content-panel > h1 {
  margin-top: 0.5rem;
  font-size: clamp(2.6rem, 5vw, 4.4rem);
  line-height: 0.96;
  color: #161d2a;
}

.content-panel > section h2,
.content-panel > div > section h2 {
  font-size: clamp(1.55rem, 2vw + 1rem, 2.35rem);
  line-height: 1.04;
  color: #182130;
}

.content-panel h3 {
  color: #182130;
}

.fade-up {
  animation: fadeUp 0.75s cubic-bezier(0.22, 1, 0.36, 1) both;
}

@keyframes fadeUp {
  from {
    opacity: 0;
    transform: translateY(22px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

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

  to {
    transform: translate3d(18px, 12px, 0) scale(1.08);
  }
}

@media (max-width: 1180px) {
  .hero-title {
    max-width: 12ch;
    font-size: clamp(3rem, 7vw, 5.6rem);
  }
}

@media (max-width: 1024px) {
  .site-nav {
    width: calc(100% - 1.5rem);
  }

  .hero-aside {
    transform: none;
  }

  .hero-aside > * {
    transform: none;
  }

  .game-frame-shell {
    min-height: 25rem;
  }
}

@media (max-width: 768px) {
  body::before {
    background:
      linear-gradient(90deg, rgba(255, 255, 255, 0.18) 0, rgba(255, 255, 255, 0) 100%),
      repeating-linear-gradient(90deg, rgba(27, 34, 48, 0.04) 0 1px, transparent 1px 72px),
      repeating-linear-gradient(180deg, rgba(27, 34, 48, 0.04) 0 1px, transparent 1px 72px);
  }

  .site-nav {
    position: relative;
    top: 0;
    margin-top: 0.8rem;
    width: calc(100% - 1rem);
    border-radius: 1.7rem;
  }

  .hero-copy::after {
    width: 6rem;
  }

  .glass-panel,
  .content-panel {
    padding: 1.25rem;
  }

  .content-panel > h1 {
    font-size: clamp(2.4rem, 10vw, 3.5rem);
  }

  .section-title {
    max-width: 100%;
    font-size: clamp(1.9rem, 7vw, 2.8rem);
  }

  .game-frame-shell {
    aspect-ratio: 4 / 3;
    min-height: 21rem;
  }

  .page-shell::before {
    display: none;
  }
}

@media (max-width: 520px) {
  .hero-title {
    font-size: clamp(2.7rem, 14vw, 4rem);
  }

  .hero-pills,
  .footer-links,
  .page-links {
    gap: 0.5rem;
  }

  .hero-pills a,
  .page-links a,
  .footer-links a {
    padding: 0.48rem 0.82rem;
    font-size: 0.84rem;
  }

  .game-frame-shell {
    aspect-ratio: 1 / 1;
    min-height: 18rem;
  }

  .section-copy {
    line-height: 1.72;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  .fade-up,
  .ambient-orb,
  .info-chip,
  .subtle-card,
  .step-card,
  .feature-card,
  .faq-card,
  .cta-primary,
  .cta-secondary,
  .site-nav > a:last-child,
  .hero-pills a,
  .page-links a,
  .footer-links a {
    animation: none;
    transition: none;
  }
}
