/* Cofrade Road — site styles.
   Palette taken from the game itself: madrugá night sky, albero sand,
   cirio gold, nazareno purple. */

@font-face {
  font-family: "Titan One";
  src: url("TitanOne-Regular.ttf") format("truetype");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

:root {
  --night: #16111f;
  --night-2: #1e1830;
  --night-3: #272040;
  --albero: #c2ab74;
  --albero-dim: #8d7b52;
  --gold: #f7e08a;
  --gold-2: #e8c65c;
  --purple: #7b3fb0;
  --purple-dim: #4b2570;
  --ink: #ece7f5;
  --ink-dim: #a99fbd;
  --line: rgba(247, 224, 138, 0.16);
  --radius: 14px;
  --wrap: 1080px;
  --prose: 720px;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--night);
  color: var(--ink);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto,
    "Helvetica Neue", Arial, sans-serif;
  font-size: 17px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  overflow-wrap: break-word; /* long urls and ids never widen the page */
}

img { max-width: 100%; display: block; }

a { color: var(--gold); text-decoration-color: rgba(247, 224, 138, 0.4); }
a:hover { color: #fff2bd; }

.wrap {
  max-width: var(--wrap);
  margin-inline: auto;
  padding-inline: 20px;
}

.prose { max-width: var(--prose); }

/* ---------- display type ---------- */

.display {
  font-family: "Titan One", Georgia, serif;
  font-weight: 400;
  letter-spacing: 0.01em;
  line-height: 1.08;
  color: var(--gold);
  text-shadow: 0 3px 0 rgba(0, 0, 0, 0.55);
}

/* ---------- top bar ---------- */

.topbar {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 10px 20px;
  background: rgba(22, 17, 31, 0.88);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
}

.topbar__brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-family: "Titan One", Georgia, serif;
  font-size: 18px;
  color: var(--gold);
  text-decoration: none;
  margin-right: auto;
}

.topbar__brand img { width: 30px; height: 30px; border-radius: 7px; }

.topbar__links {
  display: flex;
  gap: 18px;
  font-size: 15px;
}

.topbar__links a { color: var(--ink-dim); text-decoration: none; }
.topbar__links a:hover,
.topbar__links a[aria-current="page"] { color: var(--gold); }

/* language switch */

.lang {
  display: inline-flex;
  border: 1px solid var(--line);
  border-radius: 999px;
  overflow: hidden;
  flex: none;
}

.lang button {
  appearance: none;
  border: 0;
  background: transparent;
  color: var(--ink-dim);
  font: inherit;
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.04em;
  padding: 5px 12px;
  cursor: pointer;
}

.lang button[aria-pressed="true"] {
  background: var(--gold);
  color: #241a08;
}

/* ---------- hero ---------- */

.hero {
  position: relative;
  overflow: hidden;
  padding: 72px 0 64px;
  background:
    radial-gradient(120% 90% at 50% 0%, #2b2145 0%, var(--night) 62%),
    var(--night);
  border-bottom: 1px solid var(--line);
}

/* faint albero checker, the game's ground plane */
.hero::after {
  content: "";
  position: absolute;
  inset: auto 0 -10px 0;
  height: 190px;
  background-image:
    linear-gradient(to top, rgba(194, 171, 116, 0.14), transparent),
    repeating-conic-gradient(rgba(194, 171, 116, 0.06) 0% 25%, transparent 0% 50%);
  background-size: auto, 64px 64px;
  pointer-events: none;
}

.hero__inner {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: 48px;
  align-items: center;
}

.hero h1 {
  font-family: "Titan One", Georgia, serif;
  font-weight: 400;
  font-size: clamp(44px, 7vw, 76px);
  line-height: 1;
  margin: 0 0 6px;
  color: var(--gold);
  text-shadow: 0 5px 0 rgba(0, 0, 0, 0.5);
}

.hero__tag {
  font-size: clamp(19px, 2.4vw, 24px);
  color: var(--albero);
  margin: 0 0 22px;
  font-weight: 600;
}

.hero__lede {
  font-size: 18px;
  color: var(--ink-dim);
  margin: 0 0 30px;
  max-width: 46ch;
}

.hero__art {
  filter: drop-shadow(0 24px 40px rgba(0, 0, 0, 0.55));
}

.hero__art img {
  width: 100%;
  max-width: 340px;
  margin-inline: auto;
  border-radius: 28px;
}

/* ---------- store buttons ---------- */

.stores {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: center;
}

.store-btn {
  display: inline-flex;
  align-items: center;
  gap: 11px;
  padding: 12px 20px;
  border-radius: 12px;
  background: var(--gold);
  color: #241a08;
  font-weight: 700;
  font-size: 16px;
  text-decoration: none;
  border: 1px solid transparent;
  transition: transform 0.12s ease, background 0.12s ease;
}

.store-btn:hover { background: #ffeda8; color: #241a08; transform: translateY(-1px); }
.store-btn svg { width: 20px; height: 20px; fill: currentColor; flex: none; }

.store-btn--ghost {
  background: transparent;
  color: var(--gold);
  border-color: var(--line);
}

.store-btn--ghost:hover { background: rgba(247, 224, 138, 0.08); color: var(--gold); }

/* pre-launch state — remove .is-soon (and the href placeholder) on launch day */
.store-btn.is-soon {
  background: rgba(247, 224, 138, 0.1);
  color: var(--gold);
  border-color: var(--line);
  cursor: default;
  pointer-events: none;
}

.stores__note {
  flex-basis: 100%;
  font-size: 14px;
  color: var(--ink-dim);
  margin: 4px 0 0;
}

/* ---------- sections ---------- */

section { padding: 72px 0; }
section + section { border-top: 1px solid rgba(247, 224, 138, 0.08); }

/* keep in-page anchors clear of the sticky top bar */
[id] { scroll-margin-top: 72px; }

.section-title {
  font-family: "Titan One", Georgia, serif;
  font-weight: 400;
  font-size: clamp(28px, 4vw, 38px);
  color: var(--gold);
  margin: 0 0 10px;
}

.section-lede {
  color: var(--ink-dim);
  margin: 0 0 40px;
  max-width: 60ch;
  font-size: 17px;
}

/* ---------- feature grid ---------- */

.features {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 18px;
}

.feature {
  background: var(--night-2);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 24px;
}

.feature__icon {
  font-size: 26px;
  line-height: 1;
  margin-bottom: 12px;
}

.feature h3 {
  margin: 0 0 8px;
  font-size: 18px;
  color: var(--albero);
}

.feature p { margin: 0; color: var(--ink-dim); font-size: 15.5px; }

/* ---------- screenshots ---------- */

.shots {
  display: flex;
  gap: 18px;
  overflow-x: auto;
  padding-bottom: 14px;
  scroll-snap-type: x mandatory;
  -webkit-overflow-scrolling: touch;
}

.shots img {
  flex: none;
  width: 240px;
  border-radius: 18px;
  border: 1px solid var(--line);
  scroll-snap-align: start;
  background: var(--night-2);
}

/* ---------- roster ---------- */

.roster {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 24px;
}

.roster__group {
  background: var(--night-2);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 26px;
}

.roster__group h3 {
  margin: 0 0 4px;
  color: var(--gold);
  font-size: 19px;
}

.roster__count {
  color: var(--ink-dim);
  font-size: 14px;
  margin: 0 0 16px;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.chips { display: flex; flex-wrap: wrap; gap: 8px; margin: 0; padding: 0; list-style: none; }

.chips li {
  font-size: 14px;
  padding: 5px 11px;
  border-radius: 999px;
  background: var(--night-3);
  border: 1px solid rgba(247, 224, 138, 0.1);
  color: var(--ink);
}

/* ---------- call to action band ---------- */

.cta {
  background: linear-gradient(180deg, var(--purple-dim), #2a1640);
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  text-align: center;
}

.cta .stores { justify-content: center; }
.cta .stores__note { text-align: center; }

/* ---------- document pages ---------- */

.doc-head {
  padding: 56px 0 32px;
  border-bottom: 1px solid var(--line);
  background: radial-gradient(100% 120% at 50% 0%, #2b2145 0%, var(--night) 70%);
}

.doc-head h1 {
  font-family: "Titan One", Georgia, serif;
  font-weight: 400;
  font-size: clamp(32px, 5vw, 46px);
  color: var(--gold);
  margin: 0 0 10px;
}

.doc-meta { color: var(--ink-dim); font-size: 15px; margin: 0; }

.doc { padding: 44px 0 80px; }

.doc h2 {
  font-size: 24px;
  color: var(--gold);
  margin: 46px 0 12px;
  padding-top: 6px;
}

.doc h2:first-child { margin-top: 0; }

.doc h3 {
  font-size: 18.5px;
  color: var(--albero);
  margin: 30px 0 8px;
}

.doc p, .doc li { color: var(--ink); }
.doc ul, .doc ol { padding-left: 22px; }
.doc li { margin-bottom: 7px; }
.doc strong { color: #fff; }

.callout {
  background: var(--night-2);
  border: 1px solid var(--line);
  border-left: 4px solid var(--gold-2);
  border-radius: 0 var(--radius) var(--radius) 0;
  padding: 20px 24px;
  margin: 26px 0;
}

.callout p:first-child { margin-top: 0; }
.callout p:last-child { margin-bottom: 0; }

/* faq */

.faq {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--night-2);
  margin-bottom: 12px;
  overflow: hidden;
}

.faq summary {
  cursor: pointer;
  padding: 17px 22px;
  font-weight: 650;
  color: var(--albero);
  list-style: none;
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: center;
}

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

.faq summary::after {
  content: "+";
  font-family: "Titan One", Georgia, serif;
  color: var(--gold);
  font-size: 19px;
  flex: none;
}

.faq[open] summary::after { content: "–"; }
.faq[open] summary { color: var(--gold); }

.faq__body { padding: 0 22px 18px; color: var(--ink-dim); }
.faq__body p:first-child { margin-top: 0; }
.faq__body p:last-child { margin-bottom: 0; }

/* contact card */

.contact {
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
  align-items: center;
  justify-content: space-between;
  background: var(--night-2);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 26px 28px;
}

.contact h3 { margin: 0 0 6px; color: var(--gold); font-size: 20px; }
.contact p { margin: 0; color: var(--ink-dim); font-size: 15.5px; }

.contact__mail {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  padding: 12px 22px;
  border-radius: 12px;
  background: var(--gold);
  color: #241a08;
  font-weight: 700;
  text-decoration: none;
  white-space: nowrap;
}

.contact__mail:hover { background: #ffeda8; color: #241a08; }

/* ---------- footer ---------- */

.footer {
  border-top: 1px solid var(--line);
  padding: 40px 0 56px;
  color: var(--ink-dim);
  font-size: 14.5px;
}

.footer__row {
  display: flex;
  flex-wrap: wrap;
  gap: 16px 26px;
  align-items: center;
  justify-content: space-between;
}

.footer__links { display: flex; flex-wrap: wrap; gap: 18px; }
.footer__links a { color: var(--ink-dim); text-decoration: none; }
.footer__links a:hover { color: var(--gold); }

.footer__note { margin: 22px 0 0; max-width: 62ch; font-size: 13.5px; opacity: 0.8; }

/* ---------- language visibility ----------
   Both languages ship in the markup; the one that doesn't match <html lang>
   is hidden. Written as "hide the others" rather than "show this one" so
   elements keep whatever display their own rules give them (the screenshot
   row is a flex container, and `display: revert` would flatten it back to
   the UA default). */

html[lang="es"] [data-lang]:not([data-lang="es"]),
html[lang="en"] [data-lang]:not([data-lang="en"]) { display: none; }

/* ---------- responsive ---------- */

@media (max-width: 820px) {
  .hero__inner { grid-template-columns: 1fr; gap: 32px; text-align: center; }
  .hero__lede { margin-inline: auto; }
  .stores { justify-content: center; }
  .hero__art { order: -1; }
  .hero__art img { max-width: 220px; }
  .topbar__links { display: none; }
}

@media (max-width: 560px) {
  body { font-size: 16px; }
  section { padding: 54px 0; }
  .hero { padding: 48px 0 44px; }
  .shots img { width: 220px; }
  .contact { flex-direction: column; align-items: flex-start; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { transition: none !important; }
}

/* ---------- launch date + beta (pre-launch only) ---------- */

.launch {
  display: inline-block;
  margin: 0 0 18px;
  padding: 8px 14px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: rgba(123, 63, 176, 0.22);
  color: var(--ink);
  font-size: 15.5px;
}

.launch strong { color: var(--gold); }

.betas {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 18px;
}

.betas .feature { display: flex; flex-direction: column; gap: 14px; }
.betas .feature h3 { margin: 0; }
.betas .stores { margin-top: auto; }

.steps { margin: 0; padding-left: 20px; color: var(--ink-dim); font-size: 15.5px; }
.steps li + li { margin-top: 6px; }
