:root {
  --navy: #0b1f3a;
  --navy-2: #102b4e;
  --ivory: #f7f2ea;
  --paper: #fffdf8;
  --ink: #172033;
  --muted: #5b6270;
  --line: #d8d0c4;
  --red: #d9232e;
  --purple: #6650a4;
  --terracotta: #c45a2f;
  --terracotta-text: #963b1d;
  --teal: #167c80;
  --sage: #6f8e63;
  --ochre: #d79b23;
  --white: #ffffff;
  --shadow: 0 18px 50px rgba(11, 31, 58, 0.13);
  --shadow-small: 0 8px 24px rgba(11, 31, 58, 0.1);
  --radius: 1.35rem;
  --radius-small: 0.75rem;
  --content: 1180px;
  --display: "Arial Narrow", "Roboto Condensed", "Helvetica Neue", Arial, sans-serif;
  --body: "Atkinson Hyperlegible", "Lexend", Arial, sans-serif;
}

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

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--ink);
  background: var(--ivory);
  font-family: var(--body);
  font-size: 1rem;
  line-height: 1.65;
  text-rendering: optimizeLegibility;
}

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

.sr-only {
  position: absolute !important;
  overflow: hidden !important;
  width: 1px !important;
  height: 1px !important;
  padding: 0 !important;
  margin: -1px !important;
  white-space: nowrap !important;
  border: 0 !important;
  clip: rect(0, 0, 0, 0) !important;
  clip-path: inset(50%) !important;
}

a {
  color: inherit;
  text-decoration-thickness: 0.1em;
  text-underline-offset: 0.18em;
}

button,
select {
  font: inherit;
}

:focus-visible {
  outline: 3px solid var(--ochre);
  outline-offset: 4px;
}

.skip-link {
  position: fixed;
  z-index: 9999;
  top: 0.75rem;
  left: 0.75rem;
  padding: 0.75rem 1rem;
  color: var(--white);
  background: var(--navy);
  border-radius: 0.5rem;
  transform: translateY(-160%);
}

.skip-link:focus {
  transform: translateY(0);
}

.container {
  width: min(calc(100% - 2rem), var(--content));
  margin-inline: auto;
}

.narrow {
  width: min(calc(100% - 2rem), 780px);
  margin-inline: auto;
}

.site-header {
  position: sticky;
  z-index: 100;
  top: 0;
  border-bottom: 1px solid rgba(11, 31, 58, 0.09);
  background: rgba(247, 242, 234, 0.96);
  backdrop-filter: blur(14px);
}

.nav-shell {
  min-height: 78px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.25rem;
}

.brand-logo {
  flex: 0 0 auto;
  display: inline-flex;
  width: clamp(190px, 24vw, 290px);
}

.site-nav {
  display: flex;
  align-items: center;
  gap: 0.3rem;
}

.site-nav a {
  padding: 0.65rem 0.75rem;
  color: var(--navy);
  font-weight: 700;
  text-decoration: none;
  border-radius: 0.55rem;
}

.site-nav a:hover,
.site-nav a[aria-current="page"] {
  background: rgba(11, 31, 58, 0.08);
}

.menu-button {
  display: none;
  align-items: center;
  justify-content: center;
  width: 46px;
  height: 46px;
  color: var(--navy);
  background: transparent;
  border: 2px solid var(--navy);
  border-radius: 50%;
  cursor: pointer;
}

.button,
.text-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.45rem;
  min-height: 48px;
  padding: 0.75rem 1.15rem;
  border: 2px solid var(--navy);
  border-radius: 999px;
  font-weight: 800;
  text-decoration: none;
  transition: transform 160ms ease, box-shadow 160ms ease, background 160ms ease;
}

.button:hover,
.text-link:hover {
  transform: translateY(-2px);
}

.button-primary {
  color: var(--white);
  background: var(--navy);
  box-shadow: var(--shadow-small);
}

.button-secondary {
  color: var(--navy);
  background: transparent;
}

.button-disabled {
  color: var(--muted);
  background: #ece6dc;
  border-color: #b8afa2;
  cursor: not-allowed;
}

.header-cta {
  margin-left: 0.3rem;
  padding-inline: 1rem !important;
  color: var(--white) !important;
  background: var(--navy);
}

.hero {
  overflow: hidden;
  padding: clamp(3rem, 8vw, 7rem) 0 5rem;
  background:
    radial-gradient(circle at 95% 10%, rgba(102, 80, 164, 0.16), transparent 34%),
    linear-gradient(135deg, var(--ivory) 0 67%, #efe7db 67% 100%);
}

.hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(300px, 0.95fr);
  align-items: center;
  gap: clamp(2rem, 6vw, 5rem);
}

.eyebrow {
  margin: 0 0 1rem;
  color: var(--terracotta-text);
  font-family: var(--display);
  font-size: 0.9rem;
  font-weight: 900;
  letter-spacing: 0.13em;
  text-transform: uppercase;
}

h1,
h2,
h3 {
  color: var(--navy);
  font-family: var(--display);
  font-weight: 900;
  line-height: 1.05;
  text-wrap: balance;
}

h1 {
  margin: 0;
  font-size: clamp(2.8rem, 7vw, 6.5rem);
  letter-spacing: -0.04em;
}

h2 {
  margin: 0 0 1rem;
  font-size: clamp(2rem, 4.2vw, 4rem);
  letter-spacing: -0.025em;
}

h3 {
  margin: 0 0 0.65rem;
  font-size: clamp(1.35rem, 2vw, 1.8rem);
}

.hero h1 span {
  display: block;
  color: var(--terracotta);
}

.hero-lead {
  max-width: 62ch;
  margin: 1.5rem 0 0;
  color: #343c49;
  font-size: clamp(1.05rem, 1.8vw, 1.25rem);
}

.hero-actions,
.actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.8rem;
  margin-top: 1.8rem;
}

.cover-stack {
  position: relative;
  min-height: 520px;
}

.cover-stack img {
  position: absolute;
  left: 50%;
  width: clamp(190px, 24vw, 270px);
  border: 1px solid rgba(11, 31, 58, 0.15);
  border-radius: 0.45rem;
  box-shadow: 0 25px 55px rgba(11, 31, 58, 0.25);
}

.cover-stack img:nth-child(1) {
  z-index: 3;
  top: 0;
  transform: translateX(-50%) rotate(-1deg);
}

.cover-stack img:nth-child(2) {
  z-index: 2;
  top: 38px;
  transform: translateX(-100%) rotate(-8deg);
}

.cover-stack img:nth-child(3) {
  z-index: 1;
  top: 52px;
  transform: translateX(0%) rotate(8deg);
}

.section {
  padding: clamp(4rem, 8vw, 7rem) 0;
}

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

.section-navy {
  color: var(--white);
  background: var(--navy);
}

.section-navy h2,
.section-navy h3,
.section-navy .eyebrow {
  color: var(--white);
}

.section-heading {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(280px, 0.7fr);
  align-items: end;
  gap: 2rem;
  margin-bottom: 2.5rem;
}

.section-heading p {
  margin: 0;
  color: var(--muted);
}

.section-navy .section-heading p {
  color: #d8e0eb;
}

.book-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1.35rem;
}

.book-card {
  --accent: var(--navy);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  background: var(--paper);
  border: 1px solid rgba(11, 31, 58, 0.12);
  border-radius: var(--radius);
  box-shadow: var(--shadow-small);
}

.book-card[hidden] {
  display: none;
}

.book-card-media {
  position: relative;
  overflow: hidden;
  aspect-ratio: 3 / 4;
  background: color-mix(in srgb, var(--accent) 12%, var(--paper));
}

.book-card-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: top center;
  transition: transform 260ms ease;
}

.book-card:hover .book-card-media img {
  transform: scale(1.025);
}

.book-card-body {
  flex: 1;
  display: flex;
  flex-direction: column;
  padding: 1.35rem;
  border-top: 6px solid var(--accent);
}

.book-card-body p {
  margin: 0 0 1rem;
}

.book-card-body .text-link {
  align-self: flex-start;
  margin-top: auto;
  color: var(--navy);
  background: transparent;
}

.meta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  margin-bottom: 0.9rem;
}

.badge {
  display: inline-flex;
  align-items: center;
  min-height: 30px;
  padding: 0.28rem 0.62rem;
  color: var(--navy);
  background: var(--ivory);
  border: 1px solid rgba(11, 31, 58, 0.22);
  border-radius: 999px;
  font-size: 0.8rem;
  font-weight: 800;
}

.badge-status {
  color: var(--white);
  background: var(--navy);
  border-color: var(--navy);
}

.journey-grid,
.feature-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1rem;
}

.journey-card,
.feature-card {
  position: relative;
  overflow: hidden;
  min-height: 220px;
  padding: 1.5rem;
  color: var(--white);
  background: var(--navy-2);
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: var(--radius);
  text-decoration: none;
}

.journey-card::before {
  content: "";
  position: absolute;
  inset: 0 auto 0 0;
  width: 8px;
  background: var(--accent);
}

.journey-card h3,
.feature-card h3 {
  color: var(--white);
}

.journey-card p,
.feature-card p {
  margin: 0;
  color: #dbe3ee;
}

.journey-card:hover {
  background: #17365e;
}

.split {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(300px, 0.75fr);
  align-items: center;
  gap: clamp(2rem, 7vw, 6rem);
}

.quote-panel {
  padding: clamp(1.7rem, 4vw, 3.5rem);
  color: var(--white);
  background: var(--navy);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

.quote-panel blockquote {
  margin: 0;
  font-family: var(--display);
  font-size: clamp(1.8rem, 3vw, 3rem);
  font-weight: 900;
  line-height: 1.12;
}

.notice {
  padding: 1.1rem 1.25rem;
  color: #293143;
  background: #eee8dc;
  border-left: 5px solid var(--ochre);
  border-radius: 0 var(--radius-small) var(--radius-small) 0;
}

.page-hero {
  padding: clamp(3.5rem, 8vw, 6.5rem) 0 3.5rem;
  background: linear-gradient(135deg, var(--ivory), #eee6d9);
}

.page-hero h1 {
  max-width: 13ch;
}

.page-hero p {
  max-width: 65ch;
  font-size: 1.15rem;
}

.filters {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr)) auto;
  align-items: end;
  gap: 1rem;
  margin-bottom: 1.5rem;
  padding: 1.25rem;
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--radius);
}

.field label {
  display: block;
  margin-bottom: 0.35rem;
  color: var(--navy);
  font-weight: 800;
}

.field select {
  width: 100%;
  min-height: 48px;
  padding: 0.55rem 2.4rem 0.55rem 0.75rem;
  color: var(--ink);
  background: var(--white);
  border: 2px solid #9a9287;
  border-radius: 0.55rem;
}

.result-line {
  min-height: 1.75rem;
  margin: 0 0 1rem;
  color: var(--muted);
  font-weight: 700;
}

.empty-state {
  padding: 2rem;
  text-align: center;
  background: var(--paper);
  border: 1px dashed var(--muted);
  border-radius: var(--radius);
}

.book-detail {
  --accent: var(--navy);
  padding: clamp(3rem, 7vw, 6rem) 0;
  background: linear-gradient(135deg, color-mix(in srgb, var(--accent) 9%, var(--ivory)), var(--ivory) 60%);
}

.book-detail-grid {
  display: grid;
  grid-template-columns: minmax(260px, 390px) minmax(0, 1fr);
  align-items: start;
  gap: clamp(2rem, 7vw, 6rem);
}

.book-cover-large {
  width: 100%;
  border-radius: 0.5rem;
  box-shadow: var(--shadow);
}

.book-detail h1 {
  font-size: clamp(2.8rem, 6vw, 5.8rem);
}

.book-promise {
  max-width: 36ch;
  margin: 1rem 0 1.5rem;
  color: var(--accent);
  font-size: clamp(1.25rem, 2.4vw, 1.7rem);
  font-weight: 900;
}

.benefit-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.75rem;
  margin: 1.5rem 0;
  padding: 0;
  list-style: none;
}

.benefit-list li {
  padding: 0.8rem 0.9rem 0.8rem 2.35rem;
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--radius-small);
  position: relative;
}

.benefit-list li::before {
  content: "✓";
  position: absolute;
  top: 0.78rem;
  left: 0.85rem;
  color: var(--accent);
  font-weight: 900;
}

.prose h2 {
  margin-top: 2.4rem;
  font-size: clamp(1.8rem, 3vw, 2.7rem);
}

.prose h3 {
  margin-top: 1.8rem;
}

.prose p,
.prose li {
  max-width: 72ch;
}

.prose a {
  color: var(--navy);
  font-weight: 800;
}

.steps {
  counter-reset: steps;
  display: grid;
  gap: 1rem;
  padding: 0;
  list-style: none;
}

.steps li {
  counter-increment: steps;
  padding: 1.2rem 1.2rem 1.2rem 4.3rem;
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--radius-small);
  position: relative;
}

.steps li::before {
  content: counter(steps);
  position: absolute;
  top: 1rem;
  left: 1rem;
  display: grid;
  place-items: center;
  width: 2.35rem;
  height: 2.35rem;
  color: var(--white);
  background: var(--navy);
  border-radius: 50%;
  font-weight: 900;
}

.site-footer {
  padding: 3rem 0 1.5rem;
  color: #dce4ef;
  background: #07172d;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.25fr repeat(2, minmax(160px, 0.55fr));
  gap: 2rem;
}

.footer-logo {
  width: min(290px, 100%);
  padding: 0.7rem;
  background: var(--ivory);
  border-radius: 0.65rem;
}

.site-footer h2,
.site-footer h3 {
  color: var(--white);
  font-size: 1rem;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.footer-links {
  margin: 0;
  padding: 0;
  list-style: none;
}

.footer-links li + li {
  margin-top: 0.45rem;
}

.footer-links a {
  color: #dce4ef;
}

.footer-bottom {
  margin-top: 2.5rem;
  padding-top: 1.25rem;
  border-top: 1px solid rgba(255, 255, 255, 0.16);
  font-size: 0.9rem;
}

.placeholder-note {
  padding: 1rem;
  color: #4d4235;
  background: #fff0ce;
  border: 1px solid #d9af59;
  border-radius: var(--radius-small);
}

@media (max-width: 980px) {
  .menu-button {
    display: inline-flex;
  }

  .site-nav {
    position: absolute;
    top: 78px;
    right: 1rem;
    left: 1rem;
    display: none;
    align-items: stretch;
    flex-direction: column;
    padding: 1rem;
    background: var(--paper);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
  }

  .site-nav[data-open="true"] {
    display: flex;
  }

  .header-cta {
    margin: 0.4rem 0 0;
  }

  .hero-grid,
  .split,
  .book-detail-grid {
    grid-template-columns: 1fr;
  }

  .hero-copy {
    max-width: 760px;
  }

  .cover-stack {
    min-height: 480px;
    margin-top: 1rem;
  }

  .book-grid,
  .journey-grid,
  .feature-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .section-heading {
    grid-template-columns: 1fr;
  }

  .filters {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 650px) {
  body {
    font-size: 0.98rem;
  }

  .container,
  .narrow {
    width: min(calc(100% - 1.25rem), var(--content));
  }

  .nav-shell {
    min-height: 70px;
  }

  .site-nav {
    top: 70px;
  }

  .brand-logo {
    width: 185px;
  }

  .hero {
    padding-top: 3.2rem;
  }

  .cover-stack {
    min-height: 390px;
  }

  .cover-stack img {
    width: 190px;
  }

  .book-grid,
  .journey-grid,
  .feature-grid,
  .filters,
  .benefit-list,
  .footer-grid {
    grid-template-columns: 1fr;
  }

  .book-card-media {
    aspect-ratio: 3 / 4.2;
  }

  .button,
  .text-link {
    width: 100%;
  }

  .hero-actions,
  .actions {
    align-items: stretch;
    flex-direction: column;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    transition-duration: 0.01ms !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
  }
}

@media print {
  .site-header,
  .site-footer,
  .hero-actions,
  .actions,
  .filters {
    display: none !important;
  }

  body {
    color: #000;
    background: #fff;
  }
}
