:root {
  --ink-950: #08122f;
  --ink-900: #0b173a;
  --ink-800: #142552;
  --cobalt: #2456d6;
  --cobalt-bright: #3d6df0;
  --aqua: #21c7b7;
  --aqua-pale: #c9f5ed;
  --coral: #ff6d5b;
  --coral-pale: #ffe1db;
  --amber: #f4bb52;
  --cream: #f4f0e7;
  --paper: #fffdf8;
  --mist: #e9eef8;
  --line: #cbd4e8;
  --text: #15203c;
  --muted: #59647c;
  --white: #ffffff;
  --shadow-soft: 0 18px 45px rgba(8, 18, 47, 0.12);
  --shadow-tight: 0 8px 18px rgba(8, 18, 47, 0.11);
  --radius-sm: 10px;
  --radius-md: 18px;
  --radius-lg: 30px;
  --content: 1220px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-width: 280px;
  overflow-x: hidden;
  background:
    radial-gradient(circle at 96% 2%, rgba(33, 199, 183, 0.13), transparent 27rem),
    var(--cream);
  color: var(--text);
  font-family: "Avenir Next", Avenir, "Segoe UI", system-ui, sans-serif;
  line-height: 1.72;
}

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

a {
  color: var(--cobalt);
  text-decoration-thickness: 0.09em;
  text-underline-offset: 0.18em;
}

a:hover {
  color: var(--ink-800);
}

a:focus-visible,
button:focus-visible,
summary:focus-visible {
  outline: 3px solid var(--amber);
  outline-offset: 4px;
}

.skip-link {
  position: absolute;
  z-index: 100;
  top: 0.8rem;
  left: 0.8rem;
  padding: 0.65rem 0.9rem;
  border-radius: 8px;
  background: var(--paper);
  color: var(--ink-950);
  transform: translateY(-160%);
}

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

.signal-strip {
  background: var(--ink-950);
  color: #dce5ff;
  font-size: 0.74rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.signal-strip__inner {
  width: min(calc(100% - 2rem), var(--content));
  min-width: 0;
  margin: 0 auto;
  padding: 0.38rem 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 0.35rem 1rem;
}

.signal-live {
  display: inline-flex;
  align-items: center;
  gap: 0.48rem;
}

.signal-live::before {
  width: 0.55rem;
  height: 0.55rem;
  border: 2px solid var(--ink-950);
  border-radius: 50%;
  background: var(--aqua);
  box-shadow: 0 0 0 2px var(--aqua);
  content: "";
}

.site-header {
  position: relative;
  z-index: 20;
  border-bottom: 1px solid rgba(11, 23, 58, 0.12);
  background: rgba(255, 253, 248, 0.95);
}

.nav-shell {
  width: min(calc(100% - 2rem), var(--content));
  min-width: 0;
  margin: 0 auto;
  padding: 0.9rem 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 0.8rem 1.5rem;
}

.brand {
  min-width: 0;
  display: inline-flex;
  align-items: center;
  gap: 0.65rem;
  color: var(--ink-950);
  font-size: 1.28rem;
  font-weight: 800;
  letter-spacing: -0.04em;
  text-decoration: none;
}

.brand__mark {
  width: 2.35rem;
  height: 2.35rem;
  display: grid;
  place-items: center;
  flex: 0 0 auto;
  border-radius: 9px 16px 9px 16px;
  background: linear-gradient(145deg, var(--coral), #ff8d62);
  color: var(--ink-950);
  font-family: Georgia, serif;
  font-size: 1.38rem;
  font-weight: 700;
  box-shadow: 5px 5px 0 var(--aqua);
}

.nav-list {
  min-width: 0;
  margin: 0;
  padding: 0;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  flex-wrap: wrap;
  gap: 0.28rem;
  list-style: none;
}

.nav-list li,
.nav-list a {
  min-width: 0;
}

.nav-list a {
  display: block;
  padding: 0.52rem 0.7rem;
  border-radius: 9px;
  color: var(--ink-800);
  font-size: 0.83rem;
  font-weight: 700;
  text-decoration: none;
}

.nav-list a:hover,
.nav-list a[aria-current="page"] {
  background: var(--mist);
  color: var(--cobalt);
}

.topic-drawer {
  min-width: 0;
  position: relative;
}

.topic-drawer summary {
  padding: 0.49rem 0.75rem;
  border: 1px solid var(--line);
  border-radius: 10px;
  color: var(--ink-800);
  cursor: pointer;
  font-size: 0.82rem;
  font-weight: 750;
  list-style: none;
}

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

.topic-drawer summary::after {
  margin-left: 0.45rem;
  content: "+";
  color: var(--coral);
}

.topic-drawer[open] summary::after {
  content: "−";
}

.topic-drawer__panel {
  position: absolute;
  top: calc(100% + 0.7rem);
  right: 0;
  width: min(34rem, calc(100vw - 2rem));
  padding: 1rem;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.35rem;
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  background: var(--paper);
  box-shadow: var(--shadow-soft);
}

.topic-drawer__panel a {
  min-width: 0;
  padding: 0.55rem 0.65rem;
  border-radius: 8px;
  color: var(--ink-800);
  font-size: 0.8rem;
  line-height: 1.3;
  text-decoration: none;
}

.topic-drawer__panel a:hover {
  background: var(--aqua-pale);
}

.page-main {
  position: relative;
}

.hero {
  position: relative;
  overflow: hidden;
  color: var(--white);
  background:
    linear-gradient(118deg, var(--ink-950) 0%, var(--ink-900) 54%, #183273 100%);
}

.hero::before {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(255,255,255,0.035) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,0.035) 1px, transparent 1px);
  background-size: 32px 32px;
  content: "";
  pointer-events: none;
}

.hero::after {
  position: absolute;
  right: -8rem;
  bottom: -13rem;
  width: 32rem;
  height: 32rem;
  border: 4rem solid rgba(33, 199, 183, 0.13);
  border-radius: 50%;
  content: "";
}

.hero__grid {
  width: min(calc(100% - 2rem), var(--content));
  min-width: 0;
  position: relative;
  z-index: 2;
  margin: 0 auto;
  padding: clamp(3rem, 7vw, 6.4rem) 0;
  display: grid;
  grid-template-columns: minmax(0, 0.88fr) minmax(320px, 1.12fr);
  align-items: center;
  gap: clamp(2rem, 5vw, 5rem);
}

.hero__copy,
.hero__media {
  min-width: 0;
}

.hero__eyebrow {
  margin: 0 0 1rem;
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.55rem;
  color: #b9c8f4;
  font-size: 0.76rem;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.hero__eyebrow span {
  padding: 0.28rem 0.48rem;
  border: 1px solid rgba(255,255,255,0.2);
  border-radius: 6px;
  color: var(--aqua);
}

.hero h1 {
  margin: 0;
  max-width: 15ch;
  color: var(--white);
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(2.5rem, 5.7vw, 5.35rem);
  font-weight: 500;
  letter-spacing: -0.055em;
  line-height: 0.98;
}

.hero__lead {
  max-width: 59ch;
  margin: 1.45rem 0 0;
  color: #d9e0f1;
  font-size: clamp(1rem, 1.6vw, 1.14rem);
  line-height: 1.65;
}

.hero__note {
  margin: 1.35rem 0 0;
  padding-left: 1rem;
  border-left: 3px solid var(--coral);
  color: #aebbd9;
  font-size: 0.86rem;
}

.hero__media {
  position: relative;
}

.hero__media::before {
  position: absolute;
  top: -1.2rem;
  left: -1.2rem;
  width: 5rem;
  height: 5rem;
  border: 2px solid var(--aqua);
  border-radius: 50%;
  content: "";
}

.hero__media::after {
  position: absolute;
  right: -1rem;
  bottom: -1rem;
  width: 34%;
  height: 4.3rem;
  background: var(--coral);
  content: "";
  clip-path: polygon(0 36%, 100% 0, 100% 100%, 14% 100%);
}

.hero__image {
  width: 100%;
  position: relative;
  z-index: 1;
  aspect-ratio: 3 / 2;
  border-radius: 72px 18px 72px 18px;
  object-fit: cover;
  box-shadow: 0 30px 75px rgba(0, 0, 0, 0.35);
}

.hero--home .hero__image {
  aspect-ratio: 16 / 9;
}

.hero__signal-board {
  min-height: 25rem;
  padding: 2rem;
  position: relative;
  display: grid;
  align-content: center;
  gap: 1rem;
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 72px 18px 72px 18px;
  background: rgba(255, 255, 255, 0.055);
  box-shadow: 0 30px 75px rgba(0, 0, 0, 0.25);
}

.signal-card {
  max-width: 85%;
  padding: 0.9rem 1rem;
  display: flex;
  align-items: center;
  gap: 0.8rem;
  border: 1px solid rgba(255,255,255,0.14);
  border-radius: 10px 20px 10px 20px;
  background: rgba(255,255,255,0.09);
  color: #e7edff;
  font-size: 0.82rem;
}

.signal-card:nth-child(2) {
  margin-left: 15%;
}

.signal-card:nth-child(3) {
  margin-left: 7%;
}

.signal-card__dot {
  width: 0.8rem;
  height: 0.8rem;
  flex: 0 0 auto;
  border-radius: 50%;
  background: var(--aqua);
  box-shadow: 0 0 0 5px rgba(33,199,183,0.13);
}

.signal-card:nth-child(2) .signal-card__dot {
  background: var(--coral);
  box-shadow: 0 0 0 5px rgba(255,109,91,0.13);
}

.signal-card:nth-child(3) .signal-card__dot {
  background: var(--amber);
  box-shadow: 0 0 0 5px rgba(244,187,82,0.13);
}

.content-shell {
  width: min(calc(100% - 2rem), var(--content));
  min-width: 0;
  margin: 0 auto;
  padding: clamp(3rem, 6vw, 6rem) 0;
  display: grid;
  grid-template-columns: minmax(190px, 0.28fr) minmax(0, 0.72fr);
  align-items: start;
  gap: clamp(2rem, 6vw, 5.8rem);
}

.side-channel {
  min-width: 0;
  position: sticky;
  top: 1rem;
  padding: 1.15rem;
  border: 1px solid var(--line);
  border-radius: 12px 25px 12px 25px;
  background: rgba(255,253,248,0.85);
  box-shadow: var(--shadow-tight);
}

.side-channel__label {
  margin: 0 0 0.7rem;
  color: var(--coral);
  font-size: 0.68rem;
  font-weight: 850;
  letter-spacing: 0.13em;
  text-transform: uppercase;
}

.side-channel ol {
  margin: 0;
  padding: 0;
  display: grid;
  gap: 0.15rem;
  list-style: none;
}

.side-channel a {
  padding: 0.46rem 0.5rem 0.46rem 1.45rem;
  position: relative;
  display: block;
  border-radius: 7px;
  color: var(--muted);
  font-size: 0.76rem;
  line-height: 1.35;
  text-decoration: none;
}

.side-channel a::before {
  position: absolute;
  top: 0.77rem;
  left: 0.48rem;
  width: 0.44rem;
  height: 0.44rem;
  border: 2px solid var(--cobalt);
  border-radius: 50%;
  background: var(--paper);
  content: "";
}

.side-channel a:hover {
  background: var(--mist);
  color: var(--ink-900);
}

.side-channel__next {
  margin-top: 1rem;
  padding-top: 0.9rem;
  border-top: 1px solid var(--line);
}

.side-channel__next a {
  padding: 0;
  color: var(--cobalt);
  font-weight: 750;
}

.side-channel__next a::before {
  content: none;
}

.article {
  min-width: 0;
  font-family: "Iowan Old Style", Georgia, serif;
  font-size: clamp(1rem, 1.5vw, 1.12rem);
}

.article > h2 {
  margin: 3.5rem 0 1rem;
  padding: 1rem 0 0.2rem;
  position: relative;
  color: var(--ink-950);
  font-family: "Avenir Next", Avenir, "Segoe UI", sans-serif;
  font-size: clamp(1.62rem, 3vw, 2.45rem);
  letter-spacing: -0.045em;
  line-height: 1.12;
}

.article > h2::before {
  position: absolute;
  top: 0;
  left: 0;
  width: 5rem;
  height: 0.3rem;
  border-radius: 10px;
  background: linear-gradient(90deg, var(--coral) 0 35%, var(--aqua) 35% 70%, var(--cobalt) 70%);
  content: "";
}

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

.article p {
  margin: 0 0 1.25rem;
}

.article p:first-of-type::first-letter {
  margin: 0.08em 0.08em 0 0;
  float: left;
  color: var(--cobalt);
  font-family: Georgia, serif;
  font-size: 3.55em;
  font-weight: 700;
  line-height: 0.78;
}

.article ul,
.article ol {
  margin: 1.4rem 0 1.7rem;
  padding: 1.2rem 1.4rem 1.2rem 2.8rem;
  border-left: 4px solid var(--aqua);
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  background: var(--paper);
  box-shadow: var(--shadow-tight);
}

.article li + li {
  margin-top: 0.55rem;
}

.article a[href^="http"]::after {
  margin-left: 0.22rem;
  content: "↗";
  font-family: sans-serif;
  font-size: 0.72em;
  text-decoration: none;
}

.article strong {
  color: var(--ink-900);
}

.context-panel {
  margin: 4.2rem 0 0;
  padding: clamp(1.4rem, 3vw, 2.2rem);
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 1rem;
  border-radius: 12px 30px 12px 30px;
  background: var(--ink-900);
  color: #dbe4fa;
}

.context-panel__mark {
  width: 2.8rem;
  height: 2.8rem;
  display: grid;
  place-items: center;
  border-radius: 9px 15px 9px 15px;
  background: var(--aqua);
  color: var(--ink-950);
  font-size: 1.2rem;
  font-weight: 900;
}

.context-panel p {
  margin: 0;
  font-family: "Avenir Next", Avenir, "Segoe UI", sans-serif;
  font-size: 0.88rem;
  line-height: 1.6;
}

.guide-grid {
  width: min(calc(100% - 2rem), var(--content));
  min-width: 0;
  margin: 0 auto;
  padding: clamp(3rem, 6vw, 6rem) 0;
}

.guide-grid__heading {
  margin-bottom: 2rem;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(220px, 0.55fr);
  align-items: end;
  gap: 1.5rem;
}

.guide-grid__heading h2 {
  margin: 0;
  color: var(--ink-950);
  font-family: Georgia, serif;
  font-size: clamp(2.1rem, 4.5vw, 4.1rem);
  font-weight: 500;
  letter-spacing: -0.05em;
  line-height: 1;
}

.guide-grid__heading p {
  margin: 0;
  color: var(--muted);
  font-size: 0.9rem;
}

.guide-cards {
  min-width: 0;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1rem;
}

.guide-card {
  min-width: 0;
  min-height: 13rem;
  padding: 1.25rem;
  position: relative;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  border: 1px solid var(--line);
  border-radius: 12px 26px 12px 26px;
  background: var(--paper);
  color: var(--ink-900);
  text-decoration: none;
  box-shadow: var(--shadow-tight);
}

.guide-card::after {
  position: absolute;
  right: -1.5rem;
  bottom: -1.5rem;
  width: 5rem;
  height: 5rem;
  border: 1rem solid var(--aqua-pale);
  border-radius: 50%;
  content: "";
}

.guide-card:nth-child(3n+2)::after {
  border-color: var(--coral-pale);
}

.guide-card:nth-child(3n)::after {
  border-color: var(--mist);
}

.guide-card:hover {
  border-color: var(--cobalt);
  color: var(--cobalt);
  transform: translateY(-3px);
}

.guide-card__index {
  color: var(--coral);
  font-size: 0.68rem;
  font-weight: 850;
  letter-spacing: 0.13em;
  text-transform: uppercase;
}

.guide-card strong {
  max-width: 14ch;
  position: relative;
  z-index: 1;
  font-family: Georgia, serif;
  font-size: 1.4rem;
  font-weight: 500;
  line-height: 1.15;
}

.guide-card small {
  position: relative;
  z-index: 1;
  color: var(--muted);
}

.site-footer {
  background: var(--ink-950);
  color: #c2cce3;
}

.footer-grid {
  width: min(calc(100% - 2rem), var(--content));
  min-width: 0;
  margin: 0 auto;
  padding: 3.2rem 0 2.2rem;
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) repeat(3, minmax(130px, 0.6fr));
  gap: 2rem;
}

.footer-grid h2,
.footer-grid h3 {
  margin: 0 0 0.8rem;
  color: var(--white);
  font-size: 0.82rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.footer-grid p {
  max-width: 44ch;
  margin: 0;
  font-size: 0.82rem;
}

.footer-links {
  margin: 0;
  padding: 0;
  display: grid;
  gap: 0.4rem;
  list-style: none;
}

.footer-links a {
  color: #cbd7f0;
  font-size: 0.78rem;
  text-decoration: none;
}

.footer-links a:hover {
  color: var(--aqua);
}

.footer-base {
  width: min(calc(100% - 2rem), var(--content));
  min-width: 0;
  margin: 0 auto;
  padding: 1rem 0 1.6rem;
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 0.6rem 1.4rem;
  border-top: 1px solid rgba(255,255,255,0.12);
  color: #8d9bb9;
  font-size: 0.7rem;
}

.not-found {
  min-height: 68vh;
  padding: 5rem 1rem;
  display: grid;
  place-items: center;
  background:
    radial-gradient(circle at 25% 30%, rgba(33,199,183,0.18), transparent 16rem),
    linear-gradient(135deg, var(--ink-950), #183273);
  color: var(--white);
}

.not-found__card {
  width: min(100%, 46rem);
  padding: clamp(2rem, 6vw, 5rem);
  border: 1px solid rgba(255,255,255,0.18);
  border-radius: 14px 42px 14px 42px;
  background: rgba(255,255,255,0.07);
  box-shadow: 0 28px 70px rgba(0,0,0,0.25);
}

.not-found__code {
  color: var(--coral);
  font-weight: 850;
  letter-spacing: 0.18em;
}

.not-found h1 {
  margin: 0.6rem 0 1rem;
  font-family: Georgia, serif;
  font-size: clamp(2.6rem, 8vw, 5.8rem);
  font-weight: 500;
  letter-spacing: -0.06em;
  line-height: 0.95;
}

.not-found p {
  color: #d9e2f5;
}

.text-link {
  display: inline-block;
  margin-top: 1rem;
  padding: 0.72rem 0.95rem;
  border-radius: 8px 16px 8px 16px;
  background: var(--aqua);
  color: var(--ink-950);
  font-weight: 800;
  text-decoration: none;
}

.text-link:hover {
  background: var(--white);
  color: var(--ink-950);
}

@media (max-width: 900px) {
  .hero__grid {
    grid-template-columns: minmax(0, 1fr);
  }

  .hero__copy {
    max-width: 46rem;
  }

  .hero__media {
    max-width: 48rem;
  }

  .content-shell {
    grid-template-columns: minmax(0, 1fr);
  }

  .side-channel {
    position: static;
  }

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

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

@media (max-width: 680px) {
  .nav-shell {
    align-items: flex-start;
  }

  .nav-list {
    width: 100%;
    justify-content: flex-start;
  }

  .topic-drawer {
    width: 100%;
  }

  .topic-drawer summary {
    width: 100%;
  }

  .topic-drawer__panel {
    position: static;
    width: 100%;
    margin-top: 0.55rem;
    grid-template-columns: minmax(0, 1fr);
    box-shadow: none;
  }

  .hero__grid {
    padding: 3rem 0 3.5rem;
  }

  .hero h1 {
    font-size: clamp(2.4rem, 12vw, 4rem);
  }

  .hero__image,
  .hero__signal-board {
    border-radius: 38px 12px 38px 12px;
  }

  .hero__signal-board {
    min-height: 19rem;
    padding: 1.2rem;
  }

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

  .side-channel ol {
    grid-template-columns: minmax(0, 1fr);
  }

  .article {
    font-size: 1rem;
  }

  .article > h2 {
    margin-top: 2.8rem;
  }

  .context-panel {
    grid-template-columns: minmax(0, 1fr);
  }

  .guide-grid__heading,
  .footer-grid {
    grid-template-columns: minmax(0, 1fr);
  }

  .guide-cards {
    grid-template-columns: minmax(0, 1fr);
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    transition-duration: 0.01ms !important;
  }
}

@media print {
  .signal-strip,
  .site-header,
  .side-channel,
  .site-footer {
    display: none;
  }

  body,
  .hero {
    background: #fff;
    color: #111;
  }

  .hero__grid,
  .content-shell {
    width: 100%;
    display: block;
    padding: 1rem 0;
  }

  .hero h1,
  .hero__lead {
    color: #111;
  }

  .hero__media {
    display: none;
  }
}
