/*
 * Emergelle brand palette — forest green, tan/gold, cream.
 * Override variables on :root to retheme without touching markup.
 */
:root {
  /* Brand */
  --forest: #13402c;
  --forest-deep: #0e3220;
  --forest-soft: #1d4e38;
  --gold: #b89c6c;
  --gold-soft: #c9b187;
  --cream: #f5f1e8;
  --cream-warm: #ede7d8;
  --ivory: #fbf8f1;

  /* Semantic */
  --bg: var(--cream);
  --surface: var(--ivory);
  --surface-alt: #ffffff;
  --text: var(--forest-deep);
  --text-muted: #6b6557;
  --text-on-dark: var(--cream);
  --text-muted-on-dark: #c4bca7;
  --border: #e1dac6;
  --border-strong: #cbc1a6;
  --border-on-dark: rgba(245, 241, 232, 0.18);
  --accent: var(--forest);
  --accent-contrast: var(--cream);
  --accent-hover: var(--forest-soft);
  --danger: #9b2c20;
  --success: var(--forest);
  --radius-sm: 6px;
  --radius-md: 4px;
  --shadow: 0 1px 2px rgba(19, 64, 44, 0.06),
    0 12px 32px rgba(19, 64, 44, 0.08);
  --shadow-soft: 0 1px 2px rgba(19, 64, 44, 0.04),
    0 6px 18px rgba(19, 64, 44, 0.05);
  --font-display: "Playfair Display", Georgia, "Times New Roman", serif;
  --font-sans: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto,
    "Helvetica Neue", Arial, sans-serif;
  --container: 1180px;
}

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

html {
  scroll-behavior: smooth;
  scroll-padding-top: 96px;
}

:target,
[id] {
  scroll-margin-top: 96px;
}

html,
body {
  height: 100%;
}

body {
  margin: 0;
  font-family: var(--font-sans);
  color: var(--text);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  line-height: 1.6;
}

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

@media (max-width: 560px) {
  .container {
    padding: 0 20px;
  }
}

/* ---------- NAV ---------- */
.nav {
  position: sticky;
  top: 0;
  z-index: 10;
  background: rgba(245, 241, 232, 0.85);
  backdrop-filter: saturate(120%) blur(10px);
  -webkit-backdrop-filter: saturate(120%) blur(10px);
  border-bottom: 1px solid var(--border);
}

.nav__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 14px;
  padding-bottom: 14px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  color: var(--forest);
  font-family: var(--font-display);
  font-style: italic;
  font-weight: 600;
  font-size: 20px;
}

.brand__mark {
  display: inline-grid;
  place-items: center;
  width: 30px;
  height: 30px;
  background: var(--forest);
  color: var(--gold-soft);
  border-radius: 4px;
  font-family: var(--font-display);
  font-style: italic;
  font-weight: 600;
  font-size: 17px;
  line-height: 1;
}

.brand__name {
  letter-spacing: -0.005em;
}

.nav__links {
  display: flex;
  align-items: center;
  gap: 22px;
}

.nav__link {
  color: var(--text-muted);
  text-decoration: none;
  font-size: 14px;
  letter-spacing: 0.03em;
  transition: color 140ms ease;
}

.nav__link:hover {
  color: var(--forest);
}

@media (max-width: 560px) {
  .nav__link:not(.button) {
    display: none;
  }
}

/* ---------- HERO ---------- */
.hero {
  padding: 64px 0 88px;
}

@media (max-width: 720px) {
  .hero {
    padding: 40px 0 56px;
  }
}

.hero__inner {
  display: flex;
  justify-content: center;
}

.hero__copy {
  max-width: 560px;
}

/* ---------- TYPE ---------- */
.eyebrow {
  margin: 0 0 14px;
  font-size: 12px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--gold);
  font-weight: 500;
}

.eyebrow--centered {
  text-align: center;
}

.eyebrow--on-dark {
  color: var(--gold-soft);
}

.display {
  font-family: var(--font-display);
  font-weight: 500;
  letter-spacing: -0.01em;
  color: var(--forest);
  margin: 0;
  line-height: 1.05;
}

.display em {
  font-style: italic;
  font-weight: 500;
}

.display--xl {
  font-size: clamp(40px, 6vw, 64px);
  margin-bottom: 18px;
}

.display--lg {
  font-size: clamp(32px, 4.5vw, 48px);
  margin-bottom: 18px;
}

.display--md {
  font-size: clamp(24px, 3vw, 32px);
  margin: 0 0 12px;
}

.display--centered {
  text-align: center;
}

.display--on-dark {
  color: var(--cream);
}

.lede {
  margin: 0 0 28px;
  color: var(--text-muted);
  font-size: 17px;
  line-height: 1.6;
}

.prose {
  margin: 0 0 16px;
  color: var(--text-muted);
  font-size: 16px;
  line-height: 1.75;
}

.prose--on-dark {
  color: var(--text-muted-on-dark);
}

.prose--centered {
  text-align: center;
  max-width: 620px;
  margin-left: auto;
  margin-right: auto;
}

/* ---------- SECTIONS ---------- */
.section {
  padding: 88px 0;
}

@media (max-width: 720px) {
  .section {
    padding: 60px 0;
  }
}

.section__inner--narrow {
  max-width: 720px;
  margin: 0 auto;
}

.section--cream {
  background: var(--cream);
}

.section--dark {
  background: var(--forest);
  color: var(--cream);
}

.section--cta {
  background: var(--forest-deep);
  color: var(--cream);
  text-align: center;
}

/* ---------- FORM ---------- */
.form {
  display: grid;
  gap: 14px;
  padding: 28px;
  background: var(--surface-alt);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow);
}

.form__title {
  margin: 0 0 6px;
  font-family: var(--font-display);
  font-style: italic;
  font-weight: 600;
  font-size: 26px;
  color: var(--gold);
  letter-spacing: -0.01em;
}

.field {
  display: grid;
  gap: 6px;
}

.field-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

@media (max-width: 420px) {
  .field-row {
    grid-template-columns: 1fr;
  }
}

.field__label {
  font-size: 11px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-muted);
  font-weight: 500;
}

.field__input {
  width: 100%;
  padding: 13px 14px;
  font: inherit;
  font-size: 15px;
  color: var(--text);
  background: #fff;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  outline: none;
  transition: border-color 140ms ease, box-shadow 140ms ease;
}

.field__input::placeholder {
  color: #a39c89;
}

.field__input:focus {
  border-color: var(--forest);
  box-shadow: 0 0 0 3px rgba(19, 64, 44, 0.12);
}

.field__input[aria-invalid="true"] {
  border-color: var(--danger);
}

.fieldset {
  margin: 0;
  padding: 0;
  border: 0;
}

.role-group {
  display: flex;
  align-items: baseline;
  gap: 8px;
  padding: 4px 0 2px;
}

.role-chip {
  flex: 1;
  position: relative;
  cursor: pointer;
  text-align: center;
  padding: 10px 8px 14px;
}

.role-chip input[type="radio"] {
  position: absolute;
  opacity: 0;
  inset: 0;
  width: 100%;
  height: 100%;
  margin: 0;
  cursor: pointer;
}

.role-chip__label {
  display: inline-block;
  font-family: var(--font-display);
  font-size: 22px;
  letter-spacing: 0.01em;
  color: var(--text-muted);
  padding-bottom: 6px;
  border-bottom: 1px solid transparent;
  transition: color 180ms ease, border-color 180ms ease;
}

.role-chip:hover .role-chip__label {
  color: var(--text);
}

.role-chip input[type="radio"]:focus-visible + .role-chip__label {
  outline: 2px solid rgba(19, 64, 44, 0.25);
  outline-offset: 4px;
  border-radius: 2px;
}

.role-chip:has(input[type="radio"]:checked) .role-chip__label {
  color: var(--forest);
  border-bottom-color: var(--gold);
}

.role-group[aria-invalid="true"] .role-chip__label {
  color: var(--danger);
  border-bottom-color: var(--danger);
}

/* ---------- BUTTONS ---------- */
.button {
  appearance: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid transparent;
  cursor: pointer;
  padding: 14px 22px;
  font: inherit;
  font-size: 13px;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent-contrast);
  background: var(--accent);
  border-radius: var(--radius-sm);
  text-decoration: none;
  transition: background-color 140ms ease, transform 80ms ease,
    color 140ms ease, border-color 140ms ease;
  margin-top: 6px;
}

.button:hover:not([disabled]) {
  background: var(--accent-hover);
}

.button:active:not([disabled]) {
  transform: translateY(1px);
}

.button[disabled] {
  opacity: 0.55;
  cursor: not-allowed;
}

.button--sm {
  padding: 9px 14px;
  font-size: 12px;
  margin-top: 0;
}

.button--ghost {
  background: transparent;
  color: var(--forest);
  border-color: var(--forest);
}

.button--ghost:hover:not([disabled]) {
  background: var(--forest);
  color: var(--cream);
}

.button--inverse {
  background: var(--cream);
  color: var(--forest-deep);
}

.button--inverse:hover:not([disabled]) {
  background: #fff;
}

.cta-row {
  margin: 28px 0 0;
}

/* ---------- STATUS / FINEPRINT ---------- */
.status {
  margin: 4px 0 0;
  min-height: 1.25em;
  font-size: 14px;
  color: var(--text-muted);
}

.status[data-tone="error"] {
  color: var(--forest-deep);
  background: var(--cream-warm);
  font-weight: 500;
  padding: 8px 12px;
  border-radius: var(--radius-sm);
  border-left: 3px solid var(--gold);
}

.status[data-tone="success"] {
  color: var(--forest-deep);
  background: var(--cream-warm);
  font-weight: 500;
  padding: 8px 12px;
  border-radius: var(--radius-sm);
  border-left: 3px solid var(--forest);
}

.fineprint {
  margin: 6px 0 0;
  font-size: 12px;
  color: var(--text-muted);
}

/* ---------- SPLIT (artist + collector) ---------- */
.split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
  margin-top: 48px;
}

@media (max-width: 760px) {
  .split {
    grid-template-columns: 1fr;
  }
}

.split__card {
  padding: 36px;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-on-dark);
  background: rgba(245, 241, 232, 0.04);
}

.card-eyebrow {
  margin: 0 0 12px;
  font-size: 11px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--gold-soft);
  font-weight: 500;
}

.split__card .display {
  color: var(--cream);
}

.bullets {
  margin: 16px 0 0;
  padding: 0;
  list-style: none;
}

.bullets li {
  position: relative;
  padding-left: 22px;
  color: var(--text-muted-on-dark);
  font-size: 15px;
  line-height: 1.7;
}

.bullets li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.7em;
  width: 10px;
  height: 1px;
  background: var(--gold);
}

/* ---------- STATS ---------- */
.stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  margin-top: 48px;
}

@media (max-width: 760px) {
  .stats {
    grid-template-columns: 1fr;
  }
}

.stat {
  padding: 36px 28px;
  border-radius: var(--radius-md);
  background: var(--surface);
  border: 1px solid var(--border);
  text-align: center;
  box-shadow: var(--shadow-soft);
}

.stat__value {
  margin: 0 0 8px;
  font-family: var(--font-display);
  font-style: italic;
  font-weight: 500;
  font-size: 44px;
  line-height: 1;
  color: var(--forest);
}

.stat__label {
  margin: 0;
  font-size: 14px;
  color: var(--text-muted);
  line-height: 1.55;
}

/* ---------- FOOTER ---------- */
.footer {
  background: var(--forest-deep);
  color: var(--text-muted-on-dark);
  padding: 40px 0;
}

.footer__inner {
  display: grid;
  gap: 8px;
  text-align: center;
}

.footer__brand {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  margin: 0 auto 6px;
  font-family: var(--font-display);
  font-style: italic;
  font-weight: 500;
  font-size: 18px;
  color: var(--cream);
}

.footer__meta {
  margin: 0;
  font-size: 13px;
  letter-spacing: 0.06em;
}

.footer__legal {
  margin: 0;
  font-size: 12px;
  opacity: 0.7;
}

/* ---------- DARK MODE ---------- */
@media (prefers-color-scheme: dark) {
  :root {
    --bg: var(--forest-deep);
    --surface: var(--forest);
    --surface-alt: var(--forest-soft);
    --text: var(--cream);
    --text-muted: var(--text-muted-on-dark);
    --border: #2a5942;
    --border-strong: #3d6c54;
    --accent: var(--cream);
    --accent-contrast: var(--forest-deep);
    --accent-hover: #e8e1cd;
    --shadow: 0 1px 2px rgba(0, 0, 0, 0.35),
      0 12px 32px rgba(0, 0, 0, 0.4);
  }

  .nav {
    background: rgba(14, 50, 32, 0.85);
    border-bottom-color: var(--border);
  }

  .brand,
  .nav__link:hover {
    color: var(--cream);
  }

  .section--cream {
    background: var(--forest-deep);
  }

  .display {
    color: var(--cream);
  }

  .stat__value {
    color: var(--gold-soft);
  }

  .field__input {
    background: var(--forest);
    color: var(--cream);
  }

  .field__input:focus {
    box-shadow: 0 0 0 3px rgba(245, 241, 232, 0.18);
  }

  .role-chip__label {
    color: var(--text-muted-on-dark);
  }

  .role-chip:hover .role-chip__label {
    color: var(--cream);
  }

  .role-chip:has(input[type="radio"]:checked) .role-chip__label {
    color: var(--cream);
    border-bottom-color: var(--gold-soft);
  }

  .button--ghost {
    color: var(--cream);
    border-color: var(--cream);
  }

  .button--ghost:hover:not([disabled]) {
    background: var(--cream);
    color: var(--forest-deep);
  }
}
