:root {
  --bg: #120b08;
  --bg-2: #251712;
  --wood: #6b4629;
  --wood-2: #8c5b31;
  --paper: #efe0c8;
  --paper-2: #e2cfad;
  --ink: #24160e;
  --muted: #6f5c4c;
  --accent: #d08a40;
  --accent-2: #9a5f22;
  --line: rgba(36, 22, 14, 0.12);
  --shadow: 0 28px 80px rgba(0, 0, 0, 0.42);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  color: var(--ink);
  font-family: "Inter", system-ui, sans-serif;
  background:
    radial-gradient(circle at 10% 12%, rgba(255, 186, 106, 0.18), transparent 0 22%),
    radial-gradient(circle at 85% 18%, rgba(255, 220, 160, 0.12), transparent 0 24%),
    linear-gradient(145deg, #1d120d 0%, #3a2419 30%, #24160f 60%, #130b08 100%);
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.02) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.02) 1px, transparent 1px);
  background-size: 38px 38px;
  opacity: 0.18;
}

.page-shell {
  width: min(1180px, calc(100% - 28px));
  margin: 0 auto;
  padding: 26px 0 42px;
}

.hero {
  display: grid;
  grid-template-columns: minmax(0, 1.08fr) minmax(320px, 0.92fr);
  gap: 24px;
  align-items: stretch;
}

.hero-copy,
.passport-book,
.section,
.action-panel,
.completion-panel {
  position: relative;
  overflow: hidden;
  box-shadow: var(--shadow);
}

.hero-copy,
.section,
.action-panel,
.completion-panel {
  padding: 30px;
  border-radius: 28px;
  color: var(--paper);
  border: 1px solid rgba(255, 230, 189, 0.12);
  background:
    linear-gradient(180deg, rgba(33, 20, 15, 0.94), rgba(20, 11, 8, 0.96));
}

.passport-book {
  border-radius: 28px;
  padding: 28px;
  background:
    radial-gradient(circle at 50% 0%, rgba(255, 255, 255, 0.06), transparent 24%),
    linear-gradient(180deg, #4a2d1f, #2b1b12 34%, #1b100c 100%);
  color: var(--paper);
  border: 1px solid rgba(255, 230, 189, 0.12);
  min-height: 100%;
}

.passport-book::before {
  content: "";
  position: absolute;
  inset: 18px;
  border-radius: 22px;
  border: 1px solid rgba(255, 219, 176, 0.08);
  pointer-events: none;
}

.passport-book::after,
.hero-copy::after,
.section::after,
.action-panel::after,
.completion-panel::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.06), transparent 22%, transparent 78%, rgba(255, 255, 255, 0.04));
}

.book-spine {
  position: absolute;
  inset: 0 auto 0 0;
  width: 18px;
  background:
    linear-gradient(90deg, rgba(0, 0, 0, 0.35), transparent),
    linear-gradient(180deg, #1f120d, #4e2f21 40%, #1c100b 100%);
  box-shadow: inset -1px 0 0 rgba(255, 229, 194, 0.08);
}

.eyebrow {
  color: #efc180;
  text-transform: uppercase;
  letter-spacing: 0.22em;
  font-size: 0.74rem;
  font-weight: 800;
  margin-bottom: 16px;
}

h1,
h2,
h3,
.passport-name,
.trail-title,
.completion-title {
  font-family: "Cinzel", Georgia, serif;
  line-height: 0.98;
  letter-spacing: -0.02em;
  margin: 0;
}

h1 {
  font-size: clamp(3rem, 5vw, 5.4rem);
  max-width: 11ch;
}

.lede {
  color: rgba(239, 224, 200, 0.88);
  font-size: clamp(1.04rem, 1.65vw, 1.22rem);
  line-height: 1.7;
  max-width: 58ch;
  margin: 18px 0 24px;
}

.hero-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.hero-badges span {
  display: inline-flex;
  align-items: center;
  padding: 10px 14px;
  border-radius: 999px;
  background: rgba(239, 224, 200, 0.08);
  border: 1px solid rgba(239, 224, 200, 0.12);
  color: rgba(239, 224, 200, 0.94);
  font-size: 0.92rem;
  font-weight: 600;
}

.book-header {
  position: relative;
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 18px;
  padding-left: 6px;
}

.passport-label {
  display: block;
  color: #a78a72;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  font-size: 0.67rem;
  font-weight: 800;
  margin-bottom: 8px;
}

.passport-name {
  font-size: clamp(1.8rem, 3vw, 2.35rem);
  color: var(--paper);
}

.seal {
  width: 92px;
  height: 92px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  text-align: center;
  padding: 16px;
  color: #f8deb3;
  background:
    radial-gradient(circle at 30% 30%, rgba(255, 255, 255, 0.15), transparent 22%),
    linear-gradient(160deg, #bc6a29, #6f3b17);
  font-weight: 900;
  letter-spacing: 0.14em;
  font-size: 0.72rem;
  box-shadow: inset 0 0 0 7px rgba(255, 255, 255, 0.1), 0 16px 30px rgba(122, 64, 23, 0.3);
}

.book-meta {
  position: relative;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  margin-bottom: 22px;
}

.book-meta strong {
  display: block;
  font-size: 0.98rem;
  line-height: 1.35;
  color: var(--paper);
}

.book-progress {
  display: grid;
  grid-template-columns: 172px minmax(0, 1fr);
  gap: 20px;
  align-items: center;
}

.progress-ring {
  width: 172px;
  aspect-ratio: 1;
  border-radius: 50%;
  padding: 13px;
  background: conic-gradient(var(--accent) 0deg, rgba(83, 50, 29, 0.22) 0deg);
  box-shadow: inset 0 0 0 1px rgba(255, 235, 206, 0.12), 0 18px 28px rgba(0, 0, 0, 0.14);
}

.progress-ring-inner {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  background: linear-gradient(180deg, #f4e5ca, #ead6af);
  display: grid;
  place-items: center;
  text-align: center;
  color: var(--ink);
}

.progress-ring-inner span {
  display: block;
  font-family: "Cinzel", Georgia, serif;
  font-size: 2.5rem;
  line-height: 1;
}

.progress-ring-inner small {
  display: block;
  text-transform: uppercase;
  letter-spacing: 0.16em;
  color: var(--muted);
  font-weight: 800;
  margin-top: 6px;
}

.progress-kicker {
  color: #efc180;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  font-size: 0.75rem;
  font-weight: 800;
  margin-bottom: 10px;
}

.progress-count {
  font-family: "Cinzel", Georgia, serif;
  font-size: clamp(2rem, 3vw, 2.7rem);
  font-weight: 700;
  color: var(--paper);
  margin-bottom: 8px;
}

.progress-copy p {
  margin: 0;
  color: rgba(239, 224, 200, 0.82);
  line-height: 1.65;
}

.section {
  margin-top: 24px;
}

.section-head {
  margin-bottom: 18px;
}

.section-head.compact {
  margin-bottom: 14px;
}

.section-head h2 {
  font-size: clamp(1.9rem, 3.4vw, 2.9rem);
  color: var(--paper);
  max-width: 14ch;
}

.spread {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
}

.trail-card {
  position: relative;
  min-height: 380px;
  padding: 18px 18px 20px;
  border-radius: 24px;
  background:
    radial-gradient(circle at 50% 8%, rgba(255, 255, 255, 0.08), transparent 22%),
    linear-gradient(180deg, #f1e3ca, #e7d3ae 80%, #ddc28f);
  border: 1px solid rgba(36, 22, 14, 0.12);
  color: var(--ink);
  display: grid;
  grid-template-rows: auto auto 1fr auto;
  gap: 12px;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.22), 0 22px 48px rgba(0, 0, 0, 0.28);
}

.trail-card::before {
  content: "";
  position: absolute;
  inset: 16px;
  border-radius: 18px;
  border: 1px solid rgba(36, 22, 14, 0.08);
  pointer-events: none;
}

.trail-card.is-stamped {
  transform: translateY(-2px);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.22), 0 26px 54px rgba(0, 0, 0, 0.32);
}

.trail-index {
  display: flex;
  align-items: center;
  gap: 12px;
  padding-top: 4px;
}

.trail-number {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: #17110d;
  color: #f9e9c9;
  font-size: 1rem;
  font-weight: 800;
}

.trail-location {
  text-transform: uppercase;
  letter-spacing: 0.12em;
  font-size: 0.7rem;
  font-weight: 800;
  color: rgba(36, 22, 14, 0.76);
}

.trail-title {
  font-size: clamp(1.7rem, 2.8vw, 2.2rem);
  color: var(--ink);
  z-index: 1;
}

.trail-art {
  align-self: center;
  width: min(190px, 100%);
  aspect-ratio: 1.05;
  border-radius: 16px;
  border: 10px solid rgba(255, 247, 233, 0.34);
  box-shadow: 0 16px 24px rgba(0, 0, 0, 0.18);
  background-size: cover;
  background-position: center;
}

.art-alaska {
  background:
    radial-gradient(circle at 22% 18%, rgba(255, 255, 255, 0.96), transparent 8%),
    radial-gradient(circle at 58% 22%, rgba(47, 156, 255, 0.9), transparent 20%),
    radial-gradient(circle at 44% 64%, rgba(255, 255, 255, 0.96), transparent 12%),
    linear-gradient(180deg, #0b2149 0%, #26477b 45%, #d7e4f8 46%, #6b798b 100%);
}

.art-honduras {
  background:
    radial-gradient(circle at 18% 18%, rgba(253, 206, 100, 0.95), transparent 12%),
    linear-gradient(180deg, #1f6f6b 0%, #56a6a0 52%, #d8efe8 53%, #5a8f60 100%);
}

.stamp-ring {
  justify-self: center;
  width: 110px;
  height: 110px;
  border-radius: 50%;
  border: 2px dashed rgba(36, 22, 14, 0.52);
  background: transparent;
  color: rgba(36, 22, 14, 0.64);
  font-size: 0.72rem;
  font-weight: 900;
  letter-spacing: 0.16em;
  display: grid;
  place-items: center;
  cursor: pointer;
  transition: transform 180ms ease, background-color 180ms ease, color 180ms ease, border-color 180ms ease;
}

.stamp-ring:hover {
  transform: translateY(-2px);
  border-color: rgba(36, 22, 14, 0.8);
}

.stamp-ring.is-stamped {
  background: radial-gradient(circle at 35% 30%, rgba(255, 255, 255, 0.12), transparent 22%), linear-gradient(160deg, #c2692a, #7f4014);
  color: #f9dfb6;
  border-style: solid;
  border-color: rgba(121, 63, 20, 0.55);
  box-shadow: inset 0 0 0 7px rgba(255, 255, 255, 0.08);
}

.split {
  display: grid;
  grid-template-columns: minmax(0, 0.88fr) minmax(320px, 0.62fr);
  gap: 24px;
}

.button-stack {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 18px;
}

.ghost-button {
  appearance: none;
  border: 1px solid rgba(239, 224, 200, 0.16);
  background: rgba(239, 224, 200, 0.06);
  color: var(--paper);
  padding: 12px 16px;
  border-radius: 14px;
  font: inherit;
  font-weight: 700;
  cursor: pointer;
  transition: transform 160ms ease, background-color 160ms ease, border-color 160ms ease;
}

.ghost-button:hover {
  transform: translateY(-1px);
  background: rgba(239, 224, 200, 0.1);
  border-color: rgba(239, 224, 200, 0.26);
}

.info-card {
  border-radius: 20px;
  padding: 18px;
  background: rgba(239, 224, 200, 0.06);
  border: 1px solid rgba(239, 224, 200, 0.1);
}

.info-card + .info-card {
  margin-top: 14px;
}

.info-card h3 {
  color: var(--paper);
  margin-bottom: 10px;
  font-size: 1.15rem;
}

.info-card ol {
  margin: 0;
  padding-left: 18px;
  color: rgba(239, 224, 200, 0.84);
  line-height: 1.65;
}

.info-card p {
  margin: 0;
  color: rgba(239, 224, 200, 0.82);
  line-height: 1.65;
}

.info-card code {
  color: #ffd39a;
  font-family: "SFMono-Regular", Consolas, monospace;
}

.muted {
  background: rgba(255, 255, 255, 0.04);
}

.completion-panel {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  min-height: 100%;
}

.completion-cover {
  min-height: 330px;
  border-radius: 24px;
  padding: 28px 24px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  text-align: center;
  color: #f1cc90;
  border: 1px solid rgba(244, 215, 163, 0.16);
  background:
    radial-gradient(circle at 50% 0%, rgba(255, 255, 255, 0.08), transparent 28%),
    linear-gradient(180deg, #4a2f22, #2c1c14 52%, #1c110d);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.05);
}

.completion-kicker {
  text-transform: uppercase;
  letter-spacing: 0.18em;
  font-size: 0.8rem;
  font-weight: 900;
  margin-bottom: 14px;
}

.completion-title {
  font-size: clamp(2rem, 3.4vw, 3rem);
  color: #ffcf8b;
  margin-bottom: 16px;
}

.completion-cover p {
  margin: 0;
  color: rgba(255, 225, 184, 0.88);
  line-height: 1.6;
}

.completion-stats {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin-top: 16px;
}

.completion-stats > div {
  padding: 16px;
  border-radius: 18px;
  background: rgba(239, 224, 200, 0.06);
  border: 1px solid rgba(239, 224, 200, 0.1);
}

.completion-stats strong {
  display: block;
  color: var(--paper);
  font-size: 1.05rem;
}

.completion-panel.is-complete .completion-cover {
  border-color: rgba(255, 214, 157, 0.35);
  box-shadow: 0 0 0 1px rgba(255, 214, 157, 0.12), inset 0 0 0 1px rgba(255, 255, 255, 0.08);
}

@media (max-width: 980px) {
  .hero,
  .split,
  .spread {
    grid-template-columns: 1fr;
  }

  .passport-book {
    min-height: auto;
  }

  .book-progress {
    grid-template-columns: 150px minmax(0, 1fr);
  }
}

@media (max-width: 680px) {
  .page-shell {
    width: min(100% - 18px, 1180px);
    padding: 12px 0 24px;
  }

  .hero-copy,
  .section,
  .action-panel,
  .completion-panel,
  .passport-book {
    border-radius: 22px;
    padding: 20px;
  }

  .book-header {
    flex-direction: column;
  }

  .seal {
    width: 82px;
    height: 82px;
  }

  .book-meta {
    grid-template-columns: 1fr;
  }

  .book-progress {
    grid-template-columns: 1fr;
    justify-items: center;
    text-align: center;
  }

  .trail-card {
    min-height: 340px;
  }

  .completion-stats {
    grid-template-columns: 1fr;
  }
}
