/* Word Rush website: the landing page (index.html). */
@font-face {
  font-family: "Bricolage";
  src: url("/fonts/bricolage-800.woff2") format("woff2");
  font-weight: 800;
  font-display: swap;
}

:root {
  --bg: #121d34;
  --bg2: #1a2a48;
  --card: #1f3256;
  --line: #2f4877;
  --text: #eef2fa;
  --muted: #a7b6d3;
  --amber: #ffae42;
  --amber-d: #c97d1c;
  --cream: #f6ecd4;
  --cream-d: #d9c7a1;
  --ink: #16233d;
  --radius: 22px;
  color-scheme: dark;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 17px/1.6 system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; display: block; }
a { color: var(--amber); }
h1, h2, h3 { font-family: "Bricolage", system-ui, sans-serif; font-weight: 800; line-height: 1.08; letter-spacing: -.01em; margin: 0; text-wrap: balance; }
p { margin: 0; }
.wrap { max-width: 1120px; margin: 0 auto; padding: 0 20px; }
.muted { color: var(--muted); }

/* Header */
.top {
  position: sticky; top: 0; z-index: 10;
  background: rgba(18, 29, 52, .82);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(255, 255, 255, .06);
}
.top .wrap { display: flex; align-items: center; gap: 12px; height: 64px; }
.brand { display: flex; align-items: center; gap: 10px; color: var(--text); text-decoration: none; font-family: "Bricolage", sans-serif; font-size: 21px; }
.brand img { width: 36px; height: 36px; border-radius: 10px; }
.top nav { margin-left: auto; display: flex; gap: 22px; }
.top nav a { color: var(--muted); text-decoration: none; font-weight: 600; font-size: 15px; }
.top nav a:hover { color: var(--text); }
@media (max-width: 640px) { .top nav { display: none; } }

/* Hero */
.hero {
  position: relative;
  overflow: hidden;
  background:
    radial-gradient(60% 70% at 78% 40%, rgba(255, 174, 66, .16), transparent 60%),
    radial-gradient(80% 90% at 10% 0%, #263d68, transparent 70%),
    var(--bg2);
}
.hero .wrap { display: grid; grid-template-columns: 1.1fr .9fr; gap: 40px; align-items: center; padding-top: 72px; padding-bottom: 80px; }
.hero h1 { font-size: clamp(42px, 6.4vw, 76px); }
.hero h1 span { color: var(--amber); }
.hero p.lead { font-size: 20px; color: #d6deee; margin: 20px 0 28px; max-width: 34em; }
.cta { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; }
.badge {
  display: inline-flex; align-items: center; gap: 12px;
  background: #000; color: #fff; text-decoration: none;
  border: 1px solid #5f6b80; border-radius: 12px; padding: 9px 18px 9px 14px;
}
.badge svg { width: 26px; height: 28px; flex: none; }
.badge small { display: block; font-size: 11px; letter-spacing: .02em; color: #c9cfda; line-height: 1.2; }
.badge b { display: block; font-size: 19px; line-height: 1.15; font-weight: 600; }
.badge.soon { cursor: default; }
.pill {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 10px 16px; border-radius: 999px;
  background: rgba(255, 255, 255, .07); border: 1px solid rgba(255, 255, 255, .12);
  color: #e7edf8; font-weight: 600; font-size: 15px;
}
.pill i { width: 9px; height: 9px; border-radius: 50%; background: #57d9a3; display: inline-block; }
.facts { display: grid; grid-template-columns: repeat(4, auto); justify-content: start; gap: 18px 30px; margin-top: 34px; }
@media (max-width: 520px) { .facts { grid-template-columns: repeat(2, auto); } }
.facts div b { display: block; font-family: "Bricolage", sans-serif; font-size: 30px; color: var(--amber); line-height: 1.1; }
.facts div span { color: var(--muted); font-size: 14px; }

/* Animated letter wheel */
.wheel { width: min(440px, 100%); justify-self: center; aspect-ratio: 1; }
.wheel svg { width: 100%; height: 100%; overflow: visible; }
.wheel.fire img { width: 100%; height: 100%; display: block; border-radius: 50%; box-shadow: 0 0 80px rgba(255, 106, 26, .4); }
.wheel .disc { fill: rgba(255, 255, 255, .05); stroke: rgba(255, 255, 255, .12); stroke-width: 3; }
.wheel .trail { fill: none; stroke: var(--cream); stroke-width: 22; stroke-linecap: round; stroke-linejoin: round; stroke-dasharray: 600; stroke-dashoffset: 600; filter: drop-shadow(0 0 10px rgba(246, 236, 212, .55)); animation: draw 4.8s ease-in-out infinite; }
.wheel .t circle.edge { fill: var(--cream-d); }
.wheel .t circle.face { fill: var(--cream); }
.wheel .t text { font-family: "Bricolage", sans-serif; font-weight: 800; font-size: 50px; fill: var(--ink); text-anchor: middle; dominant-baseline: central; }
.wheel .t { animation: pick 4.8s ease-in-out infinite; }
.wheel .t .face { animation: face 4.8s ease-in-out infinite; animation-delay: inherit; }
.wheel .t .edge { animation: edge 4.8s ease-in-out infinite; animation-delay: inherit; }
.wheel .t1 { animation-delay: 0s; }
.wheel .t2 { animation-delay: .55s; }
.wheel .t3 { animation-delay: 1.1s; }
.wheel .t4 { animation-delay: 1.65s; }
.wheel .word { font-family: "Bricolage", sans-serif; font-size: 34px; fill: var(--amber); text-anchor: middle; opacity: 0; animation: word 4.8s ease-in-out infinite; }
@keyframes draw { 0%, 8% { stroke-dashoffset: 600; } 48%, 82% { stroke-dashoffset: 0; } 92%, 100% { stroke-dashoffset: 600; opacity: .0; } }
@keyframes face { 0%, 8% { fill: var(--cream); } 14%, 84% { fill: var(--amber); } 92%, 100% { fill: var(--cream); } }
@keyframes edge { 0%, 8% { fill: var(--cream-d); } 14%, 84% { fill: var(--amber-d); } 92%, 100% { fill: var(--cream-d); } }
@keyframes pick { 0%, 8% { transform: scale(1); } 12% { transform: scale(1.08); } 18%, 100% { transform: scale(1); } }
@keyframes word { 0%, 50% { opacity: 0; transform: translateY(8px); } 58%, 82% { opacity: 1; transform: none; } 92%, 100% { opacity: 0; } }
.wheel .t { transform-box: fill-box; transform-origin: center; }
@media (prefers-reduced-motion: reduce) {
  .wheel .trail { animation: none; stroke-dashoffset: 0; }
  .wheel .t, .wheel .t .face, .wheel .t .edge, .wheel .word { animation: none; }
  .wheel .t .face { fill: var(--amber); }
  .wheel .t .edge { fill: var(--amber-d); }
  .wheel .word { opacity: 1; }
}

@media (max-width: 860px) {
  .hero .wrap { grid-template-columns: 1fr; padding-top: 44px; padding-bottom: 56px; }
  .wheel { order: -1; width: min(300px, 80%); }
}

/* Sections */
section { padding: 84px 0; }
section.alt { background: var(--bg2); }
.kicker { color: var(--amber); font-weight: 700; letter-spacing: .14em; text-transform: uppercase; font-size: 13px; }
section h2 { font-size: clamp(30px, 4.2vw, 46px); margin: 8px 0 14px; }
section .intro { color: var(--muted); font-size: 19px; max-width: 38em; }

/* Screenshots */
.shots { display: grid; grid-auto-flow: column; grid-auto-columns: 240px; gap: 22px; overflow-x: auto; padding: 34px 20px 18px; margin: 0 -20px; scroll-snap-type: x mandatory; scrollbar-width: thin; }
.shots figure { margin: 0; scroll-snap-align: start; }
.shots img { width: 240px; height: auto; aspect-ratio: 1 / 2; object-fit: cover; border-radius: 26px; border: 6px solid #0b1222; box-shadow: 0 24px 50px rgba(0, 0, 0, .45); background: #0b1222; }
.shots figcaption { margin-top: 12px; color: var(--muted); font-size: 15px; text-align: center; }

/* Features */
.grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; margin-top: 38px; }
@media (max-width: 900px) { .grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 560px) { .grid { grid-template-columns: 1fr; } }
.feat { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 24px; }
.feat .tile {
  width: 48px; height: 48px; border-radius: 14px;
  display: grid; place-items: center;
  font-family: "Bricolage", sans-serif; font-size: 24px;
  background: var(--amber); color: var(--ink); box-shadow: 0 4px 0 var(--amber-d);
  margin-bottom: 16px;
}
.feat .tile.cream { background: var(--cream); box-shadow: 0 4px 0 var(--cream-d); }
/* The four style sets, in their own colours. */
.feat .tile.ember { background: radial-gradient(circle at 50% 80%, #ffb347, #e8461a 55%, #5a160a); color: #fff3d6; box-shadow: 0 4px 0 #3a0e06, 0 0 22px rgba(255, 106, 26, .55); }
.feat .tile.frost { background: linear-gradient(160deg, #f2fbff, #9fdcff 60%, #5aa9d6); color: #0d3550; box-shadow: 0 4px 0 #3c7ea6, 0 0 22px rgba(127, 211, 255, .45); }
.feat .tile.cosmos { background: radial-gradient(circle at 30% 30%, #b06cff, #3a1e7a 60%, #120a2e); color: #fff; box-shadow: 0 4px 0 #0a0620, 0 0 22px rgba(176, 108, 255, .45); }
.feat .tile.gold { background: linear-gradient(160deg, #fff2b0, #f2c14e 55%, #b8860b); color: #3a2600; box-shadow: 0 4px 0 #7a5806, 0 0 22px rgba(242, 193, 78, .5); }
.feat h3 { font-size: 22px; margin-bottom: 6px; }
.feat p { color: var(--muted); font-size: 16px; }

/* How to play */
.steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; margin-top: 38px; counter-reset: step; }
@media (max-width: 800px) { .steps { grid-template-columns: 1fr; } }
.step { position: relative; padding: 26px 24px 24px 24px; border-radius: var(--radius); background: rgba(255, 255, 255, .04); border: 1px solid var(--line); }
.step::before { counter-increment: step; content: counter(step); font-family: "Bricolage", sans-serif; font-size: 44px; color: var(--amber); line-height: 1; display: block; margin-bottom: 10px; }
.step h3 { font-size: 21px; margin-bottom: 6px; }
.step p { color: var(--muted); font-size: 16px; }

/* Packs */
.packs { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 30px; }
.packs span { padding: 9px 16px; border-radius: 999px; background: var(--card); border: 1px solid var(--line); font-weight: 600; font-size: 15px; }
.packs span.free { border-color: rgba(87, 217, 163, .6); }
.packs span.free::after { content: " · free"; color: #57d9a3; font-weight: 700; }

/* FAQ */
.faq { margin-top: 30px; display: grid; gap: 12px; max-width: 820px; }
.faq details { background: var(--card); border: 1px solid var(--line); border-radius: 16px; padding: 4px 20px; }
.faq summary { cursor: pointer; padding: 14px 0; font-weight: 700; list-style: none; display: flex; justify-content: space-between; gap: 16px; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; color: var(--amber); font-size: 22px; line-height: 1; }
.faq details[open] summary::after { content: "–"; }
.faq details p { color: var(--muted); padding: 0 0 16px; font-size: 16px; }

/* Closing call to action */
.end { text-align: center; }
.end .icon { width: 104px; height: 104px; border-radius: 26px; margin: 0 auto 22px; box-shadow: 0 18px 40px rgba(0, 0, 0, .45); }
.end .cta { justify-content: center; margin-top: 26px; }

footer { border-top: 1px solid rgba(255, 255, 255, .06); padding: 28px 0 40px; color: var(--muted); font-size: 14px; }
footer .wrap { display: flex; flex-wrap: wrap; gap: 10px 22px; align-items: center; }
footer a { color: var(--muted); }
footer .sp { margin-left: auto; }
@media (max-width: 560px) { footer .sp { margin-left: 0; width: 100%; } }
