/* Lenswalker landing — "Arcane Grimoire" (mirrors client/src/styles/tokens.css) */

@font-face {
  font-family: "Cinzel";
  font-weight: 600;
  font-display: swap;
  src: url("fonts/cinzel-latin-600-normal.woff2") format("woff2");
}
@font-face {
  font-family: "Cinzel";
  font-weight: 700;
  font-display: swap;
  src: url("fonts/cinzel-latin-700-normal.woff2") format("woff2");
}
@font-face {
  font-family: "Inter";
  font-weight: 100 900;
  font-display: swap;
  src: url("fonts/inter-latin-wght-normal.woff2") format("woff2");
}

:root {
  color-scheme: dark;
  --bg: #0b0d1a;
  --bg-2: #12152a;
  --surface: #161a33;
  --surface-2: #1d2244;
  --surface-3: #262c55;
  --text: #ece6d6;
  --text-2: #a9a4ba;
  --text-muted: #6f6b86;
  --border: rgba(236, 230, 214, 0.08);
  --border-gold: rgba(216, 180, 106, 0.22);
  --accent-rgb: 216, 180, 106;
  --gold: #d8b46a;
  --gold-hi: #f0cf86;
  --on-gold: #0b0d1a;
  --mana: #8b7cf6;
  --mana-2: #5ad1e6;
  --error: #e8615a;
  --success: #5fd48a;

  --nature: #5fd48a;
  --water: #62a8f5;
  --fire: #f5873a;
  --earth: #c9a07a;
  --light: #f3d35b;
  --shadow: #9aa0b4;
  --arcane: #b98cf6;
  --energy: #3ed8b0;

  --font-display: "Cinzel", Georgia, "Times New Roman", serif;
  --font-body: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  --radius: 14px;
  --radius-lg: 22px;
  --max: 1120px;
}

*, *::before, *::after { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  background:
    radial-gradient(1200px 600px at 50% -200px, rgba(139, 124, 246, 0.16), transparent 70%),
    radial-gradient(900px 500px at 100% 30%, rgba(var(--accent-rgb), 0.06), transparent 70%),
    var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 17px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

h1, h2, h3 {
  font-family: var(--font-display);
  font-weight: 600;
  letter-spacing: 0.03em;
  line-height: 1.2;
  hyphens: none;
  margin: 0;
}

p { margin: 0; }
a { color: var(--gold); }
img { max-width: 100%; display: block; }

.container {
  width: 100%;
  max-width: var(--max);
  margin: 0 auto;
  padding: 0 20px;
}

.icon {
  width: 1em;
  height: 1em;
  stroke: currentColor;
  fill: none;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
  flex-shrink: 0;
}

/* Starfield */
.stars {
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background-image:
    radial-gradient(1px 1px at 12% 18%, rgba(236, 230, 214, 0.5), transparent),
    radial-gradient(1px 1px at 78% 12%, rgba(236, 230, 214, 0.4), transparent),
    radial-gradient(1.5px 1.5px at 42% 64%, rgba(216, 180, 106, 0.5), transparent),
    radial-gradient(1px 1px at 88% 72%, rgba(236, 230, 214, 0.35), transparent),
    radial-gradient(1px 1px at 22% 86%, rgba(90, 209, 230, 0.45), transparent),
    radial-gradient(1px 1px at 60% 30%, rgba(236, 230, 214, 0.3), transparent),
    radial-gradient(1.5px 1.5px at 5% 50%, rgba(185, 140, 246, 0.4), transparent),
    radial-gradient(1px 1px at 95% 40%, rgba(236, 230, 214, 0.35), transparent);
}

/* ===== Top bar ===== */

.topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 18px 0;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--text);
  text-decoration: none;
  font-family: var(--font-display);
  font-weight: 700;
  letter-spacing: 0.18em;
  font-size: 15px;
}

.brand img {
  width: 34px;
  height: 34px;
  border-radius: 9px;
}

.topbar-links {
  display: flex;
  align-items: center;
  gap: 8px;
}

.lang-link,
.play-link {
  display: inline-flex;
  align-items: center;
  min-height: 40px;
  padding: 0 14px;
  border-radius: 999px;
  font-size: 14px;
  font-weight: 600;
  text-decoration: none;
  white-space: nowrap;
}

.lang-link {
  color: var(--text-2);
  border: 1px solid var(--border);
}

.play-link {
  gap: 6px;
  color: var(--on-gold);
  background: linear-gradient(180deg, var(--gold-hi), var(--gold));
  box-shadow: 0 2px 14px rgba(var(--accent-rgb), 0.35);
}

.play-link .icon { font-size: 16px; }

/* "Already playing?" call to action under the invite form */
.hero-play {
  margin-top: 22px;
  max-width: 480px;
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.hero-play-or {
  display: flex;
  align-items: center;
  gap: 12px;
  color: var(--text-muted);
  font-size: 13px;
  text-transform: uppercase;
  letter-spacing: 0.14em;
}

.hero-play-or::before,
.hero-play-or::after {
  content: "";
  flex: 1;
  height: 1px;
  background: var(--border-gold);
}

.btn-play {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  min-height: 64px;
  padding: 10px 12px 10px 24px;
  border-radius: 999px;
  border: 1.5px solid var(--gold);
  background: rgba(var(--accent-rgb), 0.08);
  color: var(--gold);
  text-decoration: none;
  transition: background 0.15s ease, transform 0.15s ease;
}

.btn-play:hover { background: rgba(var(--accent-rgb), 0.16); }
.btn-play:active { transform: scale(0.98); }

.btn-play-text {
  display: flex;
  flex-direction: column;
  text-align: left;
  font-size: 19px;
  font-weight: 700;
  line-height: 1.2;
}

.btn-play-text small {
  font-size: 13px;
  font-weight: 500;
  color: var(--text-2);
}

.btn-play-arrow {
  flex-shrink: 0;
  width: 44px;
  height: 44px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: linear-gradient(180deg, var(--gold-hi), var(--gold));
  color: var(--on-gold);
  font-size: 20px;
  font-weight: 700;
}

/* ===== Hero ===== */

.hero {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr);
  align-items: center;
  gap: 48px;
  padding: 40px 0 72px;
}

.badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 14px;
  border-radius: 999px;
  border: 1px solid var(--border-gold);
  background: rgba(var(--accent-rgb), 0.08);
  color: var(--gold);
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.04em;
}

.badge-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--success);
  box-shadow: 0 0 8px var(--success);
}

.hero h1 {
  margin-top: 22px;
  font-size: clamp(36px, 5.4vw, 62px);
  color: var(--text);
}

.hero h1 .gold {
  display: block;
  background: linear-gradient(90deg, var(--gold), var(--gold-hi), var(--gold));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.hero-lead {
  margin-top: 20px;
  max-width: 34em;
  color: var(--text-2);
  font-size: 18px;
  hyphens: auto;
}

.hero-note {
  margin-top: 12px;
  font-size: 14px;
  color: var(--text-muted);
}

.hero-note a { text-decoration: none; font-weight: 600; }

/* Waitlist / invite form */
.invite-form {
  margin-top: 28px;
  max-width: 480px;
}

.invite-row {
  display: flex;
  gap: 8px;
  padding: 6px;
  border-radius: 999px;
  background: var(--surface);
  border: 1px solid var(--border-gold);
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.35);
}

.invite-row input[type="email"] {
  flex: 1;
  min-width: 0;
  min-height: 48px;
  padding: 0 18px;
  border: none;
  border-radius: 999px;
  background: transparent;
  color: var(--text);
  font: inherit;
  font-size: 16px;
  outline: none;
}

.invite-row input[type="email"]::placeholder { color: var(--text-muted); }

.honeypot {
  position: absolute;
  left: -9999px;
  width: 1px;
  height: 1px;
  opacity: 0;
}

.btn-gold {
  flex-shrink: 0;
  min-height: 48px;
  padding: 0 24px;
  border: none;
  border-radius: 999px;
  background: linear-gradient(180deg, var(--gold-hi), var(--gold));
  color: var(--on-gold);
  font: inherit;
  font-size: 16px;
  font-weight: 700;
  cursor: pointer;
  white-space: nowrap;
  box-shadow: 0 4px 20px rgba(var(--accent-rgb), 0.35);
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.btn-gold:hover { box-shadow: 0 6px 28px rgba(var(--accent-rgb), 0.5); }
.btn-gold:active { transform: scale(0.97); }
.btn-gold:disabled { opacity: 0.6; cursor: wait; }

.form-message {
  min-height: 1.6em;
  margin-top: 10px;
  padding-left: 18px;
  font-size: 14px;
}

.form-message.success { color: var(--success); }
.form-message.error { color: var(--error); }

.hero-perks {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 18px;
  margin-top: 6px;
  padding-left: 18px;
  font-size: 13px;
  color: var(--text-muted);
}

.hero-perks span {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.hero-perks .icon { color: var(--gold); font-size: 14px; }

/* Phones */
.phones {
  position: relative;
  overflow: visible;
  contain: paint; /* the glow must not widen the page on small phones */
  display: flex;
  justify-content: center;
  min-height: 560px;
}

.phone {
  position: relative;
  width: 270px;
  aspect-ratio: 360 / 740;
  border-radius: 38px;
  padding: 10px;
  background: linear-gradient(160deg, #2a2f55, #10132a);
  box-shadow:
    0 0 0 1px rgba(236, 230, 214, 0.08),
    0 30px 80px rgba(0, 0, 0, 0.6),
    0 0 120px rgba(139, 124, 246, 0.18);
}

.phone img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: top;
  border-radius: 29px;
}

.phones .phone-back {
  position: absolute;
  top: 60px;
  right: calc(50% - 250px);
  width: 230px;
  transform: rotate(6deg);
  opacity: 0.75;
  filter: saturate(0.9);
}

.phones .phone-front {
  z-index: 1;
  transform: translateX(-40px) rotate(-3deg);
}

.lens-glow {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 420px;
  height: 420px;
  transform: translate(-60%, -50%);
  border-radius: 50%;
  background: radial-gradient(circle, rgba(90, 209, 230, 0.16), rgba(139, 124, 246, 0.1) 40%, transparent 70%);
  filter: blur(10px);
  z-index: 0;
}

/* ===== Sections ===== */

section { padding: 80px 0; }

.section-head {
  max-width: 640px;
  margin: 0 auto 44px;
  text-align: center;
}

.eyebrow {
  display: inline-block;
  margin-bottom: 12px;
  color: var(--gold);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}

.section-head h2 {
  font-size: clamp(28px, 4vw, 42px);
}

.section-head p {
  margin-top: 14px;
  color: var(--text-2);
  hyphens: auto;
}

.divider {
  height: 1px;
  max-width: var(--max);
  margin: 0 auto;
  background: linear-gradient(90deg, transparent, var(--border-gold), transparent);
}

/* Steps */
.steps {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 20px;
  counter-reset: step;
}

.step {
  position: relative;
  padding: 28px 24px;
  border-radius: var(--radius-lg);
  background: linear-gradient(170deg, var(--surface-2), var(--surface) 60%);
  border: 1px solid var(--border);
}

.step-num {
  position: absolute;
  top: 18px;
  right: 22px;
  font-family: var(--font-display);
  font-size: 40px;
  font-weight: 700;
  color: rgba(var(--accent-rgb), 0.14);
  line-height: 1;
}

.step-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 52px;
  height: 52px;
  border-radius: 14px;
  font-size: 26px;
  color: var(--gold);
  background: rgba(var(--accent-rgb), 0.1);
  border: 1px solid var(--border-gold);
}

.step:nth-child(2) .step-icon {
  color: var(--mana-2);
  background: rgba(90, 209, 230, 0.08);
  border-color: rgba(90, 209, 230, 0.25);
}

.step h3 {
  margin-top: 18px;
  font-size: 21px;
}

.step p {
  margin-top: 10px;
  color: var(--text-2);
  font-size: 15.5px;
  hyphens: auto;
}

/* Elements strip */
.elements {
  display: grid;
  grid-template-columns: repeat(8, minmax(0, 1fr));
  gap: 12px;
  margin-top: 48px;
}

.element {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  padding: 16px 6px;
  border-radius: var(--radius);
  background: var(--surface);
  border: 1px solid var(--border);
  font-size: 13px;
  color: var(--text-2);
  min-width: 0;
}

.element .icon {
  font-size: 26px;
  color: var(--c);
  filter: drop-shadow(0 0 10px color-mix(in srgb, var(--c) 50%, transparent));
}

.element span {
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

/* Rarity scale */
.rarity {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 10px;
  margin-top: 16px;
}

.rarity div {
  padding: 12px 10px;
  border-radius: 12px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-top: 3px solid var(--c);
  font-size: 13px;
  color: var(--text-2);
  min-width: 0;
}

.rarity b {
  display: block;
  color: var(--c);
  font-size: 14px;
}

/* Guild showcase */
.showcase {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr);
  align-items: center;
  gap: 56px;
}

.showcase-phones {
  display: flex;
  justify-content: center;
  gap: 18px;
}

.showcase-phones .phone { width: 230px; }
.showcase-phones .phone:nth-child(2) { margin-top: 60px; }

.new-pill {
  display: inline-block;
  margin-left: 8px;
  padding: 2px 10px;
  border-radius: 999px;
  background: var(--gold);
  color: var(--on-gold);
  font-family: var(--font-body);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.08em;
  vertical-align: middle;
}

.showcase h2 { font-size: clamp(28px, 4vw, 42px); }

.showcase-lead {
  margin-top: 16px;
  color: var(--text-2);
  hyphens: auto;
}

.check-list {
  list-style: none;
  margin: 24px 0 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.check-list li {
  display: flex;
  gap: 14px;
  align-items: flex-start;
}

.check-list .li-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  border-radius: 11px;
  flex-shrink: 0;
  font-size: 19px;
  color: var(--gold);
  background: rgba(var(--accent-rgb), 0.1);
  border: 1px solid var(--border-gold);
}

.check-list b { display: block; }

.check-list span {
  color: var(--text-2);
  font-size: 15.5px;
  hyphens: auto;
}

/* Feature grid */
.features {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
}

.feature {
  padding: 22px 20px;
  border-radius: var(--radius-lg);
  background: var(--surface);
  border: 1px solid var(--border);
  transition: border-color 0.2s ease, transform 0.2s ease;
  min-width: 0;
}

.feature:hover {
  border-color: var(--border-gold);
  transform: translateY(-2px);
}

.feature .icon {
  font-size: 24px;
  color: var(--gold);
}

.feature h3 {
  margin-top: 14px;
  font-size: 17px;
}

.feature p {
  margin-top: 8px;
  font-size: 14.5px;
  color: var(--text-2);
  hyphens: auto;
}

/* FAQ */
.faq {
  max-width: 760px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.faq details {
  border-radius: var(--radius);
  background: var(--surface);
  border: 1px solid var(--border);
  padding: 0 20px;
}

.faq details[open] { border-color: var(--border-gold); }

.faq summary {
  list-style: none;
  cursor: pointer;
  padding: 18px 0;
  font-weight: 600;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
}

.faq summary::-webkit-details-marker { display: none; }

.faq summary::after {
  content: "+";
  font-size: 22px;
  color: var(--gold);
  transition: transform 0.2s ease;
}

.faq details[open] summary::after { transform: rotate(45deg); }

.faq details p {
  padding-bottom: 18px;
  color: var(--text-2);
  font-size: 15.5px;
  hyphens: auto;
}

/* Final CTA */
.cta {
  text-align: center;
  padding: 64px 28px;
  border-radius: 28px;
  background:
    radial-gradient(600px 300px at 50% 0%, rgba(var(--accent-rgb), 0.14), transparent 70%),
    linear-gradient(170deg, var(--surface-2), var(--surface));
  border: 1px solid var(--border-gold);
}

.cta h2 { font-size: clamp(28px, 4vw, 44px); }

.cta p {
  margin: 14px auto 0;
  max-width: 32em;
  color: var(--text-2);
}

.cta .invite-form { margin: 28px auto 0; }
.cta .hero-perks { justify-content: center; padding-left: 0; }
.cta .form-message { padding-left: 0; }

/* Footer */
footer {
  padding: 48px 0 40px;
  text-align: center;
  color: var(--text-muted);
  font-size: 14px;
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px 20px;
  margin-top: 14px;
}

.footer-links a {
  color: var(--text-2);
  text-decoration: none;
}

.footer-links a:hover { color: var(--gold); }

.footer-privacy {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-top: 14px;
  font-size: 13px;
}

/* Scroll reveal (content stays visible without JS) */
.js .reveal {
  opacity: 0;
  transform: translateY(18px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}

.js .reveal.in {
  opacity: 1;
  transform: none;
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .js .reveal { opacity: 1; transform: none; transition: none; }
  .feature:hover { transform: none; }
}

/* ===== Responsive ===== */

@media (max-width: 960px) {
  .hero,
  .showcase {
    grid-template-columns: minmax(0, 1fr);
    gap: 40px;
  }

  .hero { padding-top: 16px; text-align: center; }
  .hero-lead, .invite-form, .hero-play { margin-left: auto; margin-right: auto; }
  .hero-perks { justify-content: center; padding-left: 0; }
  .form-message { padding-left: 0; }

  .phones { min-height: 0; }
  .phones .phone-back { display: none; }
  .phones .phone-front { transform: none; }

  .showcase-phones { order: 2; }
  .features { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .steps { grid-template-columns: minmax(0, 1fr); }
  .elements { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}

@media (max-width: 560px) {
  body { font-size: 16px; }
  section { padding: 56px 0; }
  .container { padding: 0 16px; }
  .topbar .play-link { padding: 0 14px; }
  .lang-link { padding: 0 10px; }

  .invite-row {
    flex-direction: column;
    border-radius: 22px;
    padding: 8px;
  }

  .invite-row input[type="email"] { text-align: center; }
  .btn-gold { width: 100%; }

  .phone { width: 240px; }
  .showcase-phones .phone { width: 46%; max-width: 200px; border-radius: 26px; padding: 6px; }
  .showcase-phones .phone img { border-radius: 21px; }
  .showcase-phones .phone:nth-child(2) { margin-top: 36px; }

  .features { grid-template-columns: minmax(0, 1fr); }
  .rarity { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .rarity div:last-child { grid-column: 1 / -1; }
  .cta { padding: 44px 18px; border-radius: 22px; }
}

/* Narrow phones: logo icon only, so language + play fit on one line */
@media (max-width: 420px) {
  .brand-name { display: none; }
}
