/* Hamurapi landing. Off-white page, ink type, one terracotta accent. A short hero, the real game under it,
   four steps of a year from the store shots, a terracotta band of features, then where to get it.
   Every colour, size and radius comes from tokens.css. */
:root {
  /* film grain on terracotta surfaces */
  --grain: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='180' height='180'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='3' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 1 0 0 0 0 1 0 0 0 0 1 .28 0 0 0 -.06'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}
* { box-sizing: border-box; margin: 0; }
html { scroll-behavior: smooth; }
body { font-family: var(--font); font-size: var(--size-body); line-height: 24px; color: var(--text); background: var(--bg); -webkit-font-smoothing: antialiased; }
a { color: inherit; }
img { max-width: 100%; }
.wrap { max-width: var(--wrap); margin: 0 auto; padding: 0 var(--sp-5); }
.center { text-align: center; }

h1, h2, h3 { text-wrap: balance; }
h1 { font-size: clamp(56px, 10vw, 144px); line-height: .95; font-weight: 700; letter-spacing: -.045em; }
h2 { font-size: clamp(40px, 5.5vw, 80px); line-height: 1; font-weight: 700; letter-spacing: -.035em; }
h3 { font-size: 22px; line-height: 28px; font-weight: 600; letter-spacing: -.015em; }
.label { display: block; font-size: 12px; line-height: 16px; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; color: var(--sub); margin-bottom: var(--sp-4); }

.btn { height: 44px; padding: 0 var(--sp-5); border-radius: var(--r-pill); display: inline-flex; align-items: center; font-weight: 600; font-size: 15px; text-decoration: none; border: 1px solid transparent; transition: background var(--motion), border-color var(--motion); }
.btn-solid { background: var(--btn); color: #fff; }
.btn-solid:hover { background: color-mix(in srgb, var(--btn) 82%, #fff); }
.btn-ghost { background: var(--surface); color: var(--text); border-color: var(--line); }
.btn-ghost:hover { border-color: var(--text); }
a:focus-visible { outline: 3px solid var(--ring); outline-offset: 2px; }

.nav { position: sticky; top: 0; z-index: 10; display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: var(--sp-5); height: 56px; padding: 0 var(--sp-5); background: color-mix(in srgb, var(--bg) 86%, transparent); backdrop-filter: blur(20px); -webkit-backdrop-filter: blur(20px); border-bottom: 1px solid var(--line); }
.nav .btn { height: 32px; padding: 0 var(--sp-4); }
.nav-brand { grid-column: 2; display: flex; align-items: center; gap: var(--sp-2); font-weight: 700; font-size: 19px; letter-spacing: -.01em; text-decoration: none; }
.nav-brand img { border-radius: var(--r-icon); }
.nav-links { display: flex; gap: var(--sp-5); }
.nav-links a, .nav-get { font-size: 15px; font-weight: 500; text-decoration: none; color: var(--sub); }
.nav-links a:hover, .nav-get:hover { color: var(--text); }
.nav-end { grid-column: 3; justify-self: end; display: flex; align-items: center; gap: var(--sp-5); }

.hero { padding: var(--sp-9) 0 var(--sp-8); }
.hero-icon { display: block; margin: 0 auto var(--sp-6); border-radius: var(--r-icon); box-shadow: 0 12px 32px rgba(0, 0, 0, .18); }
.lead { max-width: 520px; margin: var(--sp-5) auto 0; font-size: 20px; line-height: 28px; color: var(--sub); }
.cta { display: flex; flex-wrap: wrap; justify-content: center; gap: var(--sp-3); margin-top: var(--sp-6); }
.fine { margin-top: var(--sp-4); font-size: var(--size-footnote); line-height: 18px; color: var(--sub); }
.fine a { color: var(--accent); }

/* the real game, full width on a terracotta mat */
.try { margin: 0 clamp(0px, 3vw, 44px); }
.stage { background: var(--grain), var(--band); border-radius: var(--r-group); padding: clamp(12px, 4vw, 64px); }
.stage iframe { display: block; width: 100%; height: min(80svh, 760px); border: 0; border-radius: var(--r-row); background: var(--paper, #f6f6f4); box-shadow: 0 24px 64px rgba(0, 0, 0, .3); }
.hint { margin-top: var(--sp-3); font-size: var(--size-footnote); color: var(--sub); text-align: center; }

.sec { padding: var(--sp-9) 0; }
.head { margin-bottom: var(--sp-7); }
.body { color: var(--sub); margin: var(--sp-5) auto 0; max-width: 560px; }

/* a year in four steps */
.steps { display: grid; grid-template-columns: repeat(2, 1fr); gap: var(--sp-7) var(--sp-6); }
.step img { display: block; width: 100%; height: auto; border-radius: var(--r-row); border: 1px solid var(--line); }
.step figcaption { margin-top: var(--sp-4); }
.step .label { margin-bottom: var(--sp-2); color: var(--accent); }
.step p { margin-top: var(--sp-2); color: var(--sub); font-size: 15px; line-height: 22px; max-width: 440px; }

/* the terracotta band: head, then six ruled cells */
.band { margin: 0 clamp(0px, 3vw, 44px); border-radius: var(--r-group); background: var(--grain), var(--band); color: #fff; overflow: hidden; }
.band .label { color: var(--band-sub); }
.band-copy { text-align: center; padding: var(--sp-9) var(--sp-5) var(--sp-8); }
.cells { display: grid; grid-template-columns: repeat(3, 1fr); border-top: 1px solid var(--band-line); }
.cell { padding: var(--sp-6) var(--sp-6) var(--sp-7); border-right: 1px solid var(--band-line); border-bottom: 1px solid var(--band-line); }
.cell:nth-child(3n) { border-right: 0; }
.cell:nth-last-child(-n+3) { border-bottom: 0; }
.cell p:last-child { margin-top: var(--sp-3); color: var(--band-sub); font-size: 15px; line-height: 22px; }

.plats { display: grid; grid-template-columns: repeat(2, minmax(0, 360px)); justify-content: center; gap: var(--sp-4); margin-top: var(--sp-7); }
.plat { padding: var(--sp-6); border-radius: var(--r-group); background: var(--surface); border: 1px solid var(--line); display: grid; gap: var(--sp-2); justify-items: center; align-content: start; }
.plat small { font-size: 12px; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; color: var(--sub); }
.plat b { font-weight: 700; font-size: 32px; line-height: 40px; letter-spacing: -.03em; }
.plat p { color: var(--sub); font-size: 15px; line-height: 22px; margin-bottom: var(--sp-3); }
.credits { border-top: 1px solid var(--line); }

.foot { padding: var(--sp-8) var(--sp-4) 0; border-top: 1px solid var(--line); overflow: hidden; --scene-paper: var(--bg); --scene-ink: var(--accent); }
.foot-top { max-width: var(--wrap); margin: 0 auto; padding: 0 var(--sp-4); display: flex; flex-wrap: wrap; justify-content: space-between; gap: var(--sp-7); }
.foot-brand { display: grid; gap: var(--sp-2); align-content: start; }
.foot-brand img { border-radius: var(--r-icon); }
.foot-brand b { font-size: 32px; line-height: 40px; letter-spacing: -.03em; }
.foot-brand p { color: var(--sub); font-size: 15px; }
.foot-cols { display: flex; flex-wrap: wrap; gap: var(--sp-8); }
.foot-cols div { display: grid; gap: var(--sp-2); align-content: start; }
.foot-cols .label { margin-bottom: var(--sp-2); }
.foot-cols a { text-decoration: none; font-size: 15px; }
.foot-cols a:hover { color: var(--accent); }
.legal { margin-top: var(--sp-7); text-align: center; font-size: var(--size-footnote); line-height: 16px; color: var(--sub); text-wrap: balance; }
.footer-scene { display: block; width: 100%; height: clamp(150px, 24vw, 340px); margin-top: var(--sp-6); }

.js .reveal { opacity: 0; transform: translateY(16px); transition: opacity .5s ease, transform .5s ease; }
.js .reveal.in { opacity: 1; transform: none; }

@media (max-width: 900px) {
  .cells { grid-template-columns: 1fr 1fr; }
  .cell, .cell:nth-child(3n), .cell:nth-last-child(-n+3) { border-right: 1px solid var(--band-line); border-bottom: 1px solid var(--band-line); }
  .cell:nth-child(2n) { border-right: 0; }
  .cell:nth-last-child(-n+2) { border-bottom: 0; }
}
@media (max-width: 700px) {
  .nav { grid-template-columns: auto 1fr; padding: 0 var(--sp-4); }
  .nav-links, .nav-get { display: none; }
  .nav-brand { grid-column: 1; }
  .nav-end { grid-column: 2; }
  .wrap { padding: 0 var(--sp-4); }
  .hero { padding: var(--sp-8) 0 var(--sp-7); }
  .hero-icon { width: 72px; height: 72px; }
  .sec { padding: var(--sp-8) 0; }
  .steps, .plats { grid-template-columns: 1fr; }
  .stage, .band { border-radius: 0; }
  .stage iframe { height: min(78svh, 640px); }
  .cells { grid-template-columns: 1fr; }
  .cell, .cell:nth-child(2n), .cell:nth-child(3n), .cell:nth-last-child(-n+2) { border-right: 0; border-bottom: 1px solid var(--band-line); padding: var(--sp-5); }
  .cell:last-child { border-bottom: 0; }
  .foot-cols { gap: var(--sp-6); }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .js .reveal { opacity: 1; transform: none; transition: none; }
}
