/* Throne Era — shared site styles */

:root {
  --ink: #15151a;
  --ink-soft: #2a2a32;
  --ink-muted: #6b6258;
  --parchment: #f5efe2;
  --cream: #faf6ec;
  --paper: #fdfbf4;
  --line: #e4ddca;
  --line-strong: #c9bfa5;
  --gold: #b08641;
  --gold-soft: #d4b272;
  --gold-tint: #f0e5cb;
  --oxblood: #6b1f23;
  --sage: #3f5145;
  --slate: #4b5563;
  --danger: #a83232;
  --good: #2f6b3a;

  --font-display: "Spectral", "Iowan Old Style", Georgia, serif;
  --font-body: "IBM Plex Sans", -apple-system, BlinkMacSystemFont, "Segoe UI", system-ui, sans-serif;
  --font-mono: "IBM Plex Mono", ui-monospace, "SF Mono", Menlo, monospace;

  --shadow-card: 0 1px 0 rgba(21,21,26,0.04), 0 1px 3px rgba(21,21,26,0.06);
  --shadow-lift: 0 6px 24px -8px rgba(21,21,26,0.18);

  --radius: 4px;
  --radius-lg: 8px;
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

a { color: var(--ink); text-decoration: none; }
a:hover { color: var(--gold); }

h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-weight: 500;
  letter-spacing: -0.01em;
  color: var(--ink);
  margin: 0;
  text-wrap: balance;
}

h1 { font-size: clamp(38px, 5.6vw, 64px); line-height: 1.05; letter-spacing: -0.025em; }
h2 { font-size: clamp(28px, 3.4vw, 40px); line-height: 1.12; }
h3 { font-size: 22px; line-height: 1.25; }
h4 { font-size: 17px; line-height: 1.3; font-family: var(--font-body); font-weight: 600; letter-spacing: 0; }

p { margin: 0 0 1em 0; color: var(--ink-soft); text-wrap: pretty; }
p:last-child { margin-bottom: 0; }

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

.container-narrow {
  width: 100%;
  max-width: 760px;
  padding: 0 28px;
  margin: 0 auto;
}

/* ---------- Top Nav ---------- */

.nav {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(253, 251, 244, 0.85);
  backdrop-filter: saturate(140%) blur(10px);
  -webkit-backdrop-filter: saturate(140%) blur(10px);
  border-bottom: 1px solid var(--line);
}

.nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 64px;
  gap: 32px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-display);
  font-size: 19px;
  font-weight: 600;
  letter-spacing: 0.01em;
  color: var(--ink);
  white-space: nowrap;
}

.brand-mark {
  width: 26px;
  height: 26px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--gold);
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 28px;
  font-size: 14px;
  color: var(--ink-soft);
}

.nav-links a {
  color: var(--ink-soft);
  font-weight: 500;
  position: relative;
  padding: 4px 0;
}
.nav-links a:hover { color: var(--ink); }
.nav-links a.active { color: var(--ink); }
.nav-links a.active::after {
  content: "";
  position: absolute;
  left: 0; right: 0; bottom: -22px;
  height: 2px;
  background: var(--gold);
}

.nav-cta {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

/* ---------- Buttons ---------- */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  height: 40px;
  padding: 0 18px;
  border-radius: var(--radius);
  font-size: 14px;
  font-weight: 500;
  font-family: var(--font-body);
  letter-spacing: 0.005em;
  border: 1px solid transparent;
  cursor: pointer;
  transition: transform 0.06s ease, background 0.15s, color 0.15s, border-color 0.15s;
  white-space: nowrap;
}

.btn:active { transform: translateY(1px); }

.btn-primary {
  background: var(--ink);
  color: var(--cream);
}
.btn-primary:hover { background: #000; color: var(--cream); }

.btn-secondary {
  background: var(--cream);
  color: var(--ink);
  border-color: var(--line-strong);
}
.btn-secondary:hover { background: var(--gold-tint); color: var(--ink); border-color: var(--gold-soft); }

.btn-ghost {
  background: transparent;
  color: var(--ink);
  border-color: var(--line);
}
.btn-ghost:hover { background: var(--cream); border-color: var(--line-strong); }

.btn-gold {
  background: var(--gold);
  color: #fff;
}
.btn-gold:hover { background: #95702f; color: #fff; }

.btn-lg { height: 48px; padding: 0 24px; font-size: 15px; }

/* ---------- Hero ---------- */

.hero {
  padding: 80px 0 72px;
  position: relative;
  background:
    radial-gradient(1100px 480px at 75% -10%, rgba(176, 134, 65, 0.12), transparent 60%),
    radial-gradient(800px 380px at 5% 105%, rgba(63, 81, 69, 0.08), transparent 60%),
    var(--paper);
  border-bottom: 1px solid var(--line);
  overflow: hidden;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 18px;
}

.eyebrow::before {
  content: "";
  display: inline-block;
  width: 28px;
  height: 1px;
  background: currentColor;
}

.hero h1 {
  max-width: 18ch;
  margin-bottom: 22px;
}

.hero-lede {
  font-size: 18px;
  line-height: 1.55;
  color: var(--ink-soft);
  max-width: 56ch;
  margin-bottom: 32px;
}

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

.hero-meta {
  margin-top: 28px;
  display: flex;
  gap: 18px;
  font-size: 13px;
  color: var(--ink-muted);
  flex-wrap: wrap;
}
.hero-meta span { display: inline-flex; align-items: center; gap: 6px; }

/* ---------- Section primitives ---------- */

.section { padding: 88px 0; border-bottom: 1px solid var(--line); }
.section-tight { padding: 56px 0; }
.section-dark {
  background: var(--ink);
  color: var(--cream);
  border-bottom: none;
}
.section-dark h2, .section-dark h3 { color: var(--cream); }
.section-dark p { color: rgba(245, 239, 226, 0.72); }

.section-head {
  max-width: 720px;
  margin-bottom: 48px;
}
.section-head .eyebrow { color: var(--gold); }
.section-dark .eyebrow { color: var(--gold-soft); }

/* ---------- Cards ---------- */

.card {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: 28px;
  box-shadow: var(--shadow-card);
}

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

.grid-3 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}
.grid-2 {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 20px;
}
@media (max-width: 880px) {
  .grid-3, .grid-2 { grid-template-columns: 1fr; }
}

/* ---------- Footer ---------- */

.footer {
  background: var(--ink);
  color: rgba(245, 239, 226, 0.65);
  padding: 56px 0 32px;
  font-size: 14px;
}

.footer a { color: rgba(245, 239, 226, 0.78); }
.footer a:hover { color: var(--gold-soft); }

.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1fr;
  gap: 32px;
  padding-bottom: 36px;
  border-bottom: 1px solid rgba(245, 239, 226, 0.08);
}

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

.footer h5 {
  font-family: var(--font-body);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--cream);
  margin: 0 0 16px 0;
}

.footer-links {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.footer-brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  white-space: nowrap;
  font-family: var(--font-display);
  font-size: 19px;
  font-weight: 600;
  color: var(--cream);
  margin-bottom: 14px;
}
.footer-brand .brand-mark { color: var(--gold-soft); }

.footer-bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: 24px;
  font-size: 12px;
  color: rgba(245, 239, 226, 0.45);
  flex-wrap: wrap;
  gap: 12px;
}

/* ---------- Policy / Legal pages ---------- */

.legal-hero {
  padding: 72px 0 40px;
  border-bottom: 1px solid var(--line);
  background:
    radial-gradient(700px 300px at 20% 0%, rgba(176, 134, 65, 0.08), transparent 60%),
    var(--paper);
}

.legal-body {
  padding: 56px 0 96px;
}

.legal-body h2 {
  font-family: var(--font-display);
  font-size: 24px;
  margin: 48px 0 12px;
  letter-spacing: -0.01em;
}
.legal-body h2:first-of-type { margin-top: 0; }
.legal-body h3 {
  font-family: var(--font-body);
  font-size: 16px;
  font-weight: 600;
  margin: 28px 0 8px;
}
.legal-body p, .legal-body li {
  color: var(--ink-soft);
  font-size: 15.5px;
  line-height: 1.65;
}
.legal-body ul { padding-left: 22px; margin: 0 0 16px; }
.legal-body li { margin-bottom: 6px; }
.legal-body strong { color: var(--ink); font-weight: 600; }
.legal-meta {
  font-size: 13px;
  color: var(--ink-muted);
  margin-top: 8px;
}

.callout {
  border: 1px solid var(--line-strong);
  background: var(--gold-tint);
  border-radius: var(--radius-lg);
  padding: 20px 22px;
  margin: 24px 0;
  font-size: 15px;
  color: var(--ink);
}
.callout strong { color: var(--ink); }

.callout-warn {
  border: 1px solid #d9bfa3;
  background: #fbf1e4;
  color: #5b3a1c;
}

/* ---------- Utility ---------- */

.ornament {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  color: var(--gold);
  font-size: 14px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
}
.ornament::before, .ornament::after {
  content: "";
  width: 40px;
  height: 1px;
  background: currentColor;
  opacity: 0.6;
}

.kbd {
  font-family: var(--font-mono);
  font-size: 12px;
  background: var(--cream);
  border: 1px solid var(--line);
  border-bottom-width: 2px;
  border-radius: 4px;
  padding: 2px 6px;
  color: var(--ink);
}

.tag {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  font-weight: 500;
  padding: 4px 10px;
  border-radius: 999px;
  background: var(--cream);
  border: 1px solid var(--line);
  color: var(--ink-soft);
}

.divider-ornament {
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 64px 0;
  color: var(--gold);
}
.divider-ornament::before, .divider-ornament::after {
  content: "";
  flex: 1;
  height: 1px;
  background: var(--line-strong);
  max-width: 160px;
}
.divider-ornament svg {
  margin: 0 18px;
}
