/* ============================================================
   HUSTISYA — Gabay sa Katarungang Pilipino
   Civic classicism: archival parchment, engraved line, flag color
   ============================================================ */

@font-face {
  font-family: "Fraunces";
  src: url("../fonts/fraunces-300.woff2") format("woff2");
  font-weight: 300;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Fraunces";
  src: url("../fonts/fraunces-400.woff2") format("woff2");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Fraunces";
  src: url("../fonts/fraunces-500.woff2") format("woff2");
  font-weight: 500;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Fraunces";
  src: url("../fonts/fraunces-600.woff2") format("woff2");
  font-weight: 600;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Fraunces";
  src: url("../fonts/fraunces-400-italic.woff2") format("woff2");
  font-weight: 400;
  font-style: italic;
  font-display: swap;
}
@font-face {
  font-family: "Public Sans";
  src: url("../fonts/public-sans-400.woff2") format("woff2");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Public Sans";
  src: url("../fonts/public-sans-500.woff2") format("woff2");
  font-weight: 500;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Public Sans";
  src: url("../fonts/public-sans-600.woff2") format("woff2");
  font-weight: 600;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Public Sans";
  src: url("../fonts/public-sans-700.woff2") format("woff2");
  font-weight: 700;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Public Sans";
  src: url("../fonts/public-sans-400-italic.woff2") format("woff2");
  font-weight: 400;
  font-style: italic;
  font-display: swap;
}
@font-face {
  font-family: "IBM Plex Mono";
  src: url("../fonts/ibm-plex-mono-400.woff2") format("woff2");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "IBM Plex Mono";
  src: url("../fonts/ibm-plex-mono-500.woff2") format("woff2");
  font-weight: 500;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "IBM Plex Mono";
  src: url("../fonts/ibm-plex-mono-600.woff2") format("woff2");
  font-weight: 600;
  font-style: normal;
  font-display: swap;
}

/* ---------- tokens ---------- */
:root {
  --parchment: #f3ecda;
  --parchment-deep: #e9dfc4;
  --ivory: #fbf7ec;
  --paper: #f8f3e6;
  --ink: #1f2740;
  --ink-soft: #4c5470;
  --ink-faint: #79809a;
  --navy: #0038a8;
  --navy-deep: #002a7d;
  --navy-ink: #10204f;
  --crimson: #ce1126;
  --crimson-deep: #9c0e1e;
  --gold: #fcd116;
  --gold-ink: #97740f;
  --gold-line: #c8a94e;
  --hairline: rgba(31, 39, 64, 0.16);
  --hairline-soft: rgba(31, 39, 64, 0.09);
  --font-display: "Fraunces", Georgia, "Times New Roman", serif;
  --font-body: "Public Sans", -apple-system, "Segoe UI", sans-serif;
  --font-mono: "IBM Plex Mono", "Courier New", monospace;
  --shadow-panel: 0 1px 2px rgba(31, 39, 64, 0.06), 0 8px 28px -12px rgba(31, 39, 64, 0.22);
  --shadow-lift: 0 2px 4px rgba(31, 39, 64, 0.08), 0 18px 44px -16px rgba(16, 32, 79, 0.35);
  --grain: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='140' height='140'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2' stitchTiles='stitch'/%3E%3CfeColorMatrix type='saturate' values='0'/%3E%3C/filter%3E%3Crect width='140' height='140' filter='url(%23n)' opacity='0.5'/%3E%3C/svg%3E");
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

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

body {
  font-family: var(--font-body);
  font-size: 1.0625rem;
  line-height: 1.7;
  color: var(--ink);
  background-color: var(--parchment);
  background-image: var(--grain);
  background-size: 140px 140px;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}

::selection {
  background: var(--gold);
  color: var(--navy-ink);
}

img,
svg {
  display: block;
  max-width: 100%;
}

a {
  color: var(--navy);
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
}

a:hover {
  color: var(--crimson);
}

:focus-visible {
  outline: 2px solid var(--navy);
  outline-offset: 2px;
  border-radius: 2px;
}

.skip-link {
  position: absolute;
  left: 1rem;
  top: -100%;
  z-index: 200;
  background: var(--navy-ink);
  color: var(--ivory);
  padding: 0.6rem 1rem;
  font-family: var(--font-mono);
  font-size: 0.8rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  text-decoration: none;
  border-radius: 0 0 4px 4px;
}
.skip-link:focus {
  top: 0;
  color: var(--gold);
}

/* ---------- ambient layer ---------- */
.ambient {
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  overflow: hidden;
}
.ambient .map {
  position: absolute;
  right: -6%;
  top: 4%;
  height: 96%;
  opacity: 0.055;
  animation: drift 26s ease-in-out infinite alternate;
}
.ambient .light {
  position: absolute;
  width: 60vw;
  height: 60vw;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(252, 209, 22, 0.14), transparent 62%);
  top: -18vw;
  left: -12vw;
  animation: drift 34s ease-in-out infinite alternate-reverse;
}
.ambient .light--2 {
  width: 44vw;
  height: 44vw;
  background: radial-gradient(circle, rgba(0, 56, 168, 0.08), transparent 60%);
  top: auto;
  bottom: -14vw;
  right: -10vw;
  left: auto;
  animation-duration: 42s;
}
.ambient .scales-watermark {
  position: absolute;
  left: 50%;
  top: 40%;
  width: 44vw;
  max-width: 600px;
  transform: translate(-50%, -50%);
  opacity: 0.035;
  animation: drift 40s ease-in-out infinite alternate;
}
@keyframes drift {
  from {
    transform: translate3d(0, 0, 0);
  }
  to {
    transform: translate3d(2.5vw, 3vh, 0);
  }
}

/* ---------- layout primitives ---------- */
.shell {
  max-width: 74rem;
  margin-inline: auto;
  padding-inline: clamp(1.1rem, 4.5vw, 2.5rem);
}
.section {
  padding-block: clamp(4rem, 9vw, 7.5rem);
  position: relative;
}
.section--alt {
  background:
    linear-gradient(rgba(248, 243, 230, 0.6), rgba(248, 243, 230, 0.6)),
    var(--grain);
  background-color: var(--paper);
  border-block: 1px solid var(--hairline-soft);
}
.section--navy {
  background-color: var(--navy-ink);
  background-image:
    radial-gradient(1200px 500px at 80% -10%, rgba(0, 56, 168, 0.55), transparent 60%),
    var(--grain);
  color: #e9edf8;
  border-block: 3px double var(--gold-line);
}
.section--navy .eyebrow {
  color: var(--gold);
  border-color: rgba(252, 209, 22, 0.4);
}
.section--navy .section-title {
  color: var(--ivory);
}
.section--navy .section-lede {
  color: #b9c4e2;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.7rem;
  font-family: var(--font-mono);
  font-size: 0.74rem;
  font-weight: 500;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--crimson-deep);
  border-bottom: 1px solid var(--hairline);
  padding-bottom: 0.55rem;
  margin-bottom: 1.4rem;
}
.eyebrow::before {
  content: "";
  width: 2rem;
  height: 3px;
  background: linear-gradient(90deg, var(--crimson), var(--gold));
  flex-shrink: 0;
}

.section-title {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: clamp(2.1rem, 5.2vw, 3.4rem);
  line-height: 1.08;
  letter-spacing: -0.015em;
  text-wrap: balance;
  color: var(--navy-ink);
  max-width: 22ch;
}
.section-title em {
  font-style: italic;
  color: var(--crimson);
}
.section-lede {
  margin-top: 1.2rem;
  font-size: clamp(1.05rem, 1.6vw, 1.2rem);
  line-height: 1.75;
  color: var(--ink-soft);
  max-width: 58ch;
  text-wrap: pretty;
}

/* ---------- header ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(243, 236, 218, 0.92);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--hairline);
  box-shadow: 0 1px 0 rgba(252, 209, 22, 0.5), 0 6px 18px -14px rgba(31, 39, 64, 0.4);
}
.site-header .shell {
  display: flex;
  align-items: center;
  gap: 1rem;
  min-height: 72px;
}
.brand {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  text-decoration: none;
  color: var(--navy-ink);
  margin-right: auto;
}
.brand:hover {
  color: var(--navy-ink);
}
.brand__seal {
  width: 42px;
  height: 42px;
  flex-shrink: 0;
  filter: drop-shadow(0 1px 1px rgba(31, 39, 64, 0.25));
  transition: transform 0.5s cubic-bezier(0.2, 0.8, 0.3, 1.2), filter 0.45s ease;
}
.brand:hover .brand__seal {
  transform: rotate(-8deg) scale(1.06);
  filter: drop-shadow(0 0 7px rgba(252, 209, 22, 0.6)) drop-shadow(0 2px 2px rgba(31, 39, 64, 0.35));
}
.brand__name {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1.45rem;
  letter-spacing: 0.04em;
  line-height: 1;
}
.brand__sub {
  display: block;
  font-family: var(--font-mono);
  font-size: 0.58rem;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--crimson-deep);
  margin-top: 0.3rem;
}
.main-nav {
  display: none;
  align-items: center;
  gap: 0.25rem;
}
.main-nav a {
  font-family: var(--font-mono);
  font-size: 0.76rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--ink-soft);
  text-decoration: none;
  padding: 0.55rem 0.75rem;
  border-radius: 3px;
}
.main-nav a:hover {
  color: var(--navy);
  background: rgba(0, 56, 168, 0.07);
}
.main-nav a[aria-current="true"] {
  color: var(--crimson-deep);
  background: rgba(206, 17, 38, 0.08);
}
.nav-toggle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border: 1px solid var(--hairline);
  background: var(--ivory);
  color: var(--navy-ink);
  border-radius: 4px;
  cursor: pointer;
}
.nav-toggle svg {
  width: 20px;
  height: 20px;
}
@media (min-width: 940px) {
  .main-nav {
    display: flex;
  }
  .nav-toggle {
    display: none;
  }
}

.mobile-nav {
  position: fixed;
  inset: 0;
  z-index: 150;
  display: none;
}
.mobile-nav[data-open="true"] {
  display: block;
}
.mobile-nav__scrim {
  position: absolute;
  inset: 0;
  background: rgba(16, 32, 79, 0.55);
  animation: fadeIn 0.25s ease both;
}
.mobile-nav__panel {
  position: absolute;
  top: 0;
  right: 0;
  height: 100%;
  width: min(20rem, 86vw);
  background: var(--ivory);
  border-left: 3px double var(--gold-line);
  padding: 1.4rem 1.4rem 2rem;
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
  animation: slideIn 0.3s cubic-bezier(0.2, 0.8, 0.3, 1) both;
  overflow-y: auto;
}
.mobile-nav__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 1.2rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid var(--hairline);
}
.mobile-nav__title {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: var(--crimson-deep);
}
.mobile-nav a {
  font-family: var(--font-display);
  font-size: 1.35rem;
  font-weight: 500;
  color: var(--navy-ink);
  text-decoration: none;
  padding: 0.7rem 0.5rem;
  border-bottom: 1px solid var(--hairline-soft);
  display: flex;
  justify-content: space-between;
  align-items: baseline;
}
.mobile-nav a small {
  font-family: var(--font-mono);
  font-size: 0.62rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--ink-faint);
}
.mobile-nav a:hover {
  color: var(--crimson);
  padding-left: 0.9rem;
  transition: padding-left 0.2s ease, color 0.2s ease;
}
@keyframes fadeIn {
  from {
    opacity: 0;
  }
}
@keyframes slideIn {
  from {
    transform: translateX(40px);
    opacity: 0;
  }
}

/* ---------- opening: the living document ---------- */
.opening {
  position: relative;
  padding-block: clamp(3.2rem, 7vw, 6rem) clamp(4rem, 8vw, 6.5rem);
  overflow: hidden;
}
.opening .shell {
  display: grid;
  gap: clamp(2.5rem, 5vw, 4rem);
  align-items: center;
}
@media (min-width: 1000px) {
  .opening .shell {
    grid-template-columns: minmax(0, 46fr) minmax(0, 54fr);
  }
}
.opening__kicker {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: var(--crimson-deep);
  display: flex;
  align-items: center;
  gap: 0.8rem;
  margin-bottom: 1.6rem;
}
.opening__kicker::after {
  content: "";
  flex: 1;
  height: 1px;
  background: linear-gradient(90deg, var(--hairline), transparent);
}
.opening h1 {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: clamp(2.6rem, 7.2vw, 4.6rem);
  line-height: 1.02;
  letter-spacing: -0.02em;
  color: var(--navy-ink);
  text-wrap: balance;
  max-width: 14ch;
}
.opening h1 em {
  font-style: italic;
  font-weight: 500;
  color: var(--crimson);
}
.opening__lede {
  margin-top: 1.5rem;
  font-size: clamp(1.05rem, 1.7vw, 1.22rem);
  line-height: 1.75;
  color: var(--ink-soft);
  max-width: 46ch;
  text-wrap: pretty;
}
.opening__actions {
  margin-top: 2.2rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.9rem;
}
.opening__facts {
  margin-top: 2.6rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0;
  border-top: 1px solid var(--hairline);
  padding-top: 1.3rem;
}
.fact {
  padding-right: 1.6rem;
  margin-right: 1.6rem;
  border-right: 1px solid var(--hairline);
}
.fact:last-child {
  border-right: none;
  margin-right: 0;
  padding-right: 0;
}
.fact b {
  display: block;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1.7rem;
  line-height: 1.1;
  color: var(--navy);
  font-variant-numeric: lining-nums;
}
.fact span {
  font-family: var(--font-mono);
  font-size: 0.64rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--ink-faint);
}

/* the document panel */
.document {
  position: relative;
  background:
    linear-gradient(160deg, rgba(255, 255, 255, 0.5), rgba(233, 223, 196, 0.35)),
    var(--ivory);
  border: 1px solid var(--hairline);
  outline: 3px double var(--gold-line);
  outline-offset: 6px;
  border-radius: 4px;
  padding: clamp(1.6rem, 3.4vw, 2.8rem);
  box-shadow: var(--shadow-panel);
}
.document::before,
.document::after {
  content: "";
  position: absolute;
  width: 26px;
  height: 26px;
  border: 2px solid var(--gold-line);
  opacity: 0.9;
}
.document::before {
  top: 10px;
  left: 10px;
  border-right: none;
  border-bottom: none;
}
.document::after {
  bottom: 10px;
  right: 10px;
  border-left: none;
  border-top: none;
}
.document__head {
  text-align: center;
  border-bottom: 1px solid var(--hairline);
  padding-bottom: 1.1rem;
  margin-bottom: 1.3rem;
}
.document__head .mono {
  font-family: var(--font-mono);
  font-size: 0.66rem;
  letter-spacing: 0.34em;
  text-transform: uppercase;
  color: var(--crimson-deep);
}
.document__head h2 {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: clamp(1.5rem, 2.6vw, 2rem);
  letter-spacing: 0.02em;
  color: var(--navy-ink);
  margin-top: 0.4rem;
}
.preamble {
  font-family: var(--font-display);
  font-size: clamp(1.02rem, 1.5vw, 1.16rem);
  line-height: 1.85;
  color: var(--ink);
  text-align: justify;
  hyphens: auto;
}
.preamble .w {
  opacity: 0;
  display: inline-block;
  transform: translateY(0.35em);
  transition: opacity 0.5s ease, transform 0.5s ease;
}
.preamble.is-sealed .w {
  opacity: 1;
  transform: none;
}
.preamble .dropcap {
  float: left;
  font-size: 3.4em;
  line-height: 0.82;
  padding-right: 0.12em;
  font-weight: 600;
  color: var(--navy);
}
.preamble strong {
  font-weight: 600;
  color: var(--navy-ink);
}
.document__seal {
  position: absolute;
  right: clamp(0.9rem, 3vw, 2rem);
  bottom: clamp(0.9rem, 3vw, 2rem);
  width: clamp(84px, 12vw, 128px);
  height: clamp(84px, 12vw, 128px);
  opacity: 0;
  transform: scale(1.7) rotate(-14deg);
  transition: opacity 0.55s ease, transform 0.55s cubic-bezier(0.2, 1.4, 0.4, 1);
  filter: drop-shadow(0 3px 6px rgba(156, 14, 30, 0.35));
  pointer-events: none;
}
.document.is-sealed .document__seal {
  opacity: 0.92;
  transform: scale(1) rotate(-8deg);
}
.document__ratified {
  margin-top: 1.4rem;
  padding-top: 0.9rem;
  padding-right: clamp(88px, 11vw, 132px);
  border-top: 1px solid var(--hairline);
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: baseline;
  gap: 0.5rem 1rem;
  font-family: var(--font-mono);
  font-size: 0.66rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--ink-faint);
}
.document__ratified b {
  color: var(--crimson-deep);
  font-weight: 600;
}

/* courthouse elevation */
.courthouse {
  position: relative;
  margin-top: clamp(2rem, 4vw, 0);
}
.courthouse svg {
  width: 100%;
  height: auto;
}
.courthouse .draw {
  stroke-dasharray: 1;
  stroke-dashoffset: 1;
  transition: stroke-dashoffset 1.6s ease var(--d, 0s);
}
.courthouse.is-drawn .draw {
  stroke-dashoffset: 0;
}
.courthouse figcaption {
  margin-top: 0.9rem;
  font-family: var(--font-mono);
  font-size: 0.68rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--ink-faint);
  text-align: center;
}

/* ---------- buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  font-family: var(--font-mono);
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  text-decoration: none;
  padding: 0.85rem 1.4rem;
  border-radius: 3px;
  border: 1px solid transparent;
  cursor: pointer;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.btn svg {
  width: 15px;
  height: 15px;
  flex-shrink: 0;
  transition: transform 0.25s ease;
}
.btn:hover svg {
  transform: translateX(3px);
}
.btn--primary {
  background: var(--navy);
  color: var(--ivory);
  box-shadow: 0 1px 0 rgba(252, 209, 22, 0.8) inset, 0 10px 24px -12px rgba(0, 42, 125, 0.7);
}
.btn--primary:hover {
  background: var(--navy-deep);
  color: var(--gold);
  transform: translateY(-2px);
  box-shadow: 0 1px 0 rgba(252, 209, 22, 0.8) inset, 0 16px 30px -12px rgba(0, 42, 125, 0.8);
}
.btn--ghost {
  background: transparent;
  color: var(--navy-ink);
  border-color: var(--hairline);
}
.btn--ghost:hover {
  border-color: var(--crimson);
  color: var(--crimson);
  transform: translateY(-2px);
}
.btn--light {
  background: var(--gold);
  color: var(--navy-ink);
  box-shadow: 0 10px 24px -12px rgba(0, 0, 0, 0.6);
}
.btn--light:hover {
  background: #ffe04d;
  color: var(--navy-ink);
  transform: translateY(-2px);
}

/* ---------- scroll reveal ---------- */
.reveal {
  opacity: 0;
  transform: translateY(26px);
  transition: opacity 0.8s ease, transform 0.8s cubic-bezier(0.2, 0.7, 0.3, 1);
}
.reveal.is-in {
  opacity: 1;
  transform: none;
}
.reveal[data-delay="1"] {
  transition-delay: 0.12s;
}
.reveal[data-delay="2"] {
  transition-delay: 0.24s;
}
.reveal[data-delay="3"] {
  transition-delay: 0.36s;
}

/* ---------- court explorer ---------- */
.explorer {
  margin-top: clamp(2.4rem, 5vw, 3.6rem);
  display: grid;
  gap: 2rem;
}
@media (min-width: 1020px) {
  .explorer {
    grid-template-columns: minmax(0, 9fr) minmax(0, 8fr);
    align-items: start;
  }
}
.pyramid {
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
}
.pyramid__tier {
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
  align-items: center;
}
.court-btn {
  position: relative;
  font-family: var(--font-display);
  font-weight: 500;
  color: var(--navy-ink);
  background: var(--ivory);
  border: 1px solid var(--hairline);
  border-radius: 4px;
  padding: 0.85rem 1.1rem 0.8rem;
  cursor: pointer;
  text-align: center;
  box-shadow: 0 1px 0 rgba(31, 39, 64, 0.05);
  transition: transform 0.25s cubic-bezier(0.2, 0.8, 0.3, 1), box-shadow 0.25s ease, border-color 0.25s ease;
  width: 100%;
}
.court-btn small {
  display: block;
  font-family: var(--font-mono);
  font-size: 0.6rem;
  font-weight: 500;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--ink-faint);
  margin-top: 0.3rem;
}
.court-btn:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-lift);
  border-color: var(--gold-line);
}
.court-btn[aria-pressed="true"] {
  background: var(--navy-ink);
  color: var(--gold);
  border-color: var(--navy-ink);
  box-shadow: 0 0 0 3px rgba(252, 209, 22, 0.35), var(--shadow-lift);
}
.court-btn[aria-pressed="true"] small {
  color: #aebadd;
}
.tier-1 .court-btn {
  max-width: 340px;
  font-size: 1.25rem;
  padding-block: 1.1rem;
}
.tier-2 .court-btn {
  max-width: 250px;
  font-size: 1.02rem;
}
.tier-3 .court-btn {
  max-width: 216px;
  font-size: 0.95rem;
}
.tier-4 .court-btn {
  max-width: 190px;
  font-size: 0.9rem;
}
.pyramid__row {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.55rem;
  width: 100%;
}
.pyramid__row .court-btn {
  flex: 1 1 150px;
  max-width: none;
}
@media (min-width: 640px) {
  .tier-2 .court-btn {
    flex: 0 1 240px;
  }
  .tier-3 .court-btn {
    flex: 0 1 210px;
  }
  .tier-4 .court-btn {
    flex: 0 1 185px;
  }
}
.pyramid__label {
  font-family: var(--font-mono);
  font-size: 0.6rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--ink-faint);
  align-self: flex-start;
  margin-bottom: -0.1rem;
}
.pyramid__connector {
  width: 1px;
  height: 14px;
  background: var(--hairline);
}

.quasi {
  margin-top: 1.6rem;
  border-top: 3px double var(--gold-line);
  padding-top: 1.2rem;
}
.quasi h3 {
  font-family: var(--font-mono);
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--crimson-deep);
  margin-bottom: 0.9rem;
}
.quasi__row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}
.quasi-chip {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  font-family: var(--font-body);
  font-size: 0.86rem;
  font-weight: 500;
  color: var(--navy-ink);
  background: var(--paper);
  border: 1px solid var(--hairline);
  border-radius: 100px;
  padding: 0.45rem 0.95rem 0.45rem 0.5rem;
  cursor: pointer;
  transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}
.quasi-chip img {
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: var(--ivory);
  padding: 2px;
  border: 1px solid var(--hairline-soft);
  transition: transform 0.3s cubic-bezier(0.2, 0.8, 0.3, 1.2), filter 0.3s ease;
}
.quasi-chip:hover img {
  transform: scale(1.1);
  filter: drop-shadow(0 1px 2px rgba(31, 39, 64, 0.4)) brightness(1.04);
}
.quasi-chip:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-panel);
  border-color: var(--gold-line);
}
.quasi-chip[aria-pressed="true"] {
  background: var(--navy-ink);
  color: var(--gold);
  border-color: var(--navy-ink);
}

/* detail panel */
.detail {
  position: sticky;
  top: 96px;
  background: var(--ivory);
  border: 1px solid var(--hairline);
  border-top: 4px solid var(--navy);
  border-radius: 4px;
  box-shadow: var(--shadow-panel);
  overflow: hidden;
}
.detail__inner {
  padding: clamp(1.4rem, 3vw, 2rem);
  animation: panelIn 0.4s cubic-bezier(0.2, 0.8, 0.3, 1) both;
}
@keyframes panelIn {
  from {
    opacity: 0;
    transform: translateY(14px);
  }
}
.detail__rank {
  font-family: var(--font-mono);
  font-size: 0.64rem;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: var(--crimson-deep);
}
.detail h3 {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: clamp(1.5rem, 2.6vw, 1.9rem);
  letter-spacing: -0.01em;
  color: var(--navy-ink);
  margin-top: 0.35rem;
  line-height: 1.15;
}
.detail__fil {
  font-family: var(--font-display);
  font-style: italic;
  color: var(--ink-soft);
  font-size: 1rem;
  margin-top: 0.2rem;
}
.detail dl {
  margin-top: 1.3rem;
  display: grid;
  gap: 1.05rem;
}
.detail dt {
  font-family: var(--font-mono);
  font-size: 0.64rem;
  font-weight: 600;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--gold-ink);
  display: flex;
  align-items: center;
  gap: 0.5rem;
}
.detail dt::after {
  content: "";
  flex: 1;
  height: 1px;
  background: var(--hairline-soft);
}
.detail dd {
  font-size: 0.98rem;
  line-height: 1.7;
  color: var(--ink-soft);
  margin-top: 0.35rem;
}
.detail dd strong {
  color: var(--ink);
  font-weight: 600;
}
.detail__law {
  margin-top: 1.4rem;
  padding: 0.8rem 1rem;
  background: rgba(0, 56, 168, 0.05);
  border-left: 3px solid var(--navy);
  border-radius: 0 3px 3px 0;
  font-family: var(--font-mono);
  font-size: 0.74rem;
  letter-spacing: 0.04em;
  color: var(--navy-ink);
}
.detail__empty {
  padding: 3rem 2rem;
  text-align: center;
  color: var(--ink-faint);
}
.detail__empty svg {
  width: 44px;
  height: 44px;
  margin: 0 auto 1rem;
  opacity: 0.5;
}

/* appointment strip */
.jbc {
  margin-top: clamp(2.5rem, 5vw, 3.5rem);
  background: var(--ivory);
  border: 1px solid var(--hairline);
  border-radius: 4px;
  padding: clamp(1.4rem, 3vw, 2rem);
  box-shadow: var(--shadow-panel);
}
.jbc h3 {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1.35rem;
  color: var(--navy-ink);
}
.jbc p {
  color: var(--ink-soft);
  font-size: 0.98rem;
  margin-top: 0.4rem;
  max-width: 70ch;
}
.jbc__flow {
  margin-top: 1.4rem;
  display: flex;
  flex-wrap: wrap;
  align-items: stretch;
  gap: 0.6rem;
}
.jbc__step {
  flex: 1 1 160px;
  background: var(--paper);
  border: 1px solid var(--hairline-soft);
  border-radius: 4px;
  padding: 0.9rem 1rem;
  position: relative;
}
.jbc__step b {
  display: block;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1rem;
  color: var(--navy);
}
.jbc__step span {
  font-size: 0.82rem;
  color: var(--ink-soft);
  line-height: 1.55;
  display: block;
  margin-top: 0.25rem;
}
.jbc__step .num {
  position: absolute;
  top: -0.55rem;
  left: 0.8rem;
  font-family: var(--font-mono);
  font-size: 0.6rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  background: var(--crimson);
  color: var(--ivory);
  padding: 0.1rem 0.45rem;
  border-radius: 2px;
}
.jbc__arrow {
  align-self: center;
  color: var(--gold-ink);
  font-size: 1.1rem;
  flex: 0 0 auto;
}
@media (max-width: 700px) {
  .jbc__arrow {
    transform: rotate(90deg);
    margin-inline: auto;
  }
}

/* ---------- timeline ---------- */
.timeline {
  margin-top: clamp(2.5rem, 5vw, 3.5rem);
  position: relative;
  padding-left: clamp(1.6rem, 4vw, 2.4rem);
}
.timeline::before {
  content: "";
  position: absolute;
  left: 5px;
  top: 6px;
  bottom: 6px;
  width: 2px;
  background: var(--hairline-soft);
}
.timeline__progress {
  position: absolute;
  left: 5px;
  top: 6px;
  width: 2px;
  height: 100%;
  background: linear-gradient(180deg, var(--crimson), var(--navy) 55%, var(--gold-ink));
  transform-origin: top;
  transform: scaleY(0);
  transition: transform 0.15s linear;
}
.era {
  position: relative;
  padding-bottom: clamp(2.2rem, 4vw, 3rem);
}
.era:last-child {
  padding-bottom: 0;
}
.era::before {
  content: "";
  position: absolute;
  left: calc(-1 * clamp(1.6rem, 4vw, 2.4rem) - 1px);
  top: 8px;
  width: 13px;
  height: 13px;
  border-radius: 50%;
  background: var(--parchment);
  border: 3px solid var(--navy);
  transition: background 0.3s ease, transform 0.3s ease;
  z-index: 1;
}
.era.is-in::before {
  background: var(--crimson);
  border-color: var(--crimson);
  transform: scale(1.15);
}
.era__date {
  display: inline-block;
  font-family: var(--font-mono);
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--crimson-deep);
  border: 1px solid rgba(206, 17, 38, 0.35);
  background: rgba(206, 17, 38, 0.06);
  padding: 0.28rem 0.7rem;
  border-radius: 2px;
}
.era h3 {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: clamp(1.4rem, 2.6vw, 1.8rem);
  letter-spacing: -0.01em;
  color: var(--navy-ink);
  margin-top: 0.7rem;
  line-height: 1.2;
}
.era h3 em {
  font-style: italic;
  font-weight: 500;
  color: var(--crimson);
}
.era__body {
  margin-top: 0.7rem;
  color: var(--ink-soft);
  font-size: 1rem;
  line-height: 1.75;
  max-width: 66ch;
  text-wrap: pretty;
}
.era__note {
  margin-top: 0.9rem;
  display: flex;
  gap: 0.7rem;
  align-items: flex-start;
  background: var(--ivory);
  border: 1px solid var(--hairline-soft);
  border-left: 3px solid var(--gold-line);
  border-radius: 0 4px 4px 0;
  padding: 0.8rem 1rem;
  max-width: 66ch;
}
.era__note svg {
  width: 18px;
  height: 18px;
  flex-shrink: 0;
  margin-top: 0.2rem;
  color: var(--gold-ink);
}
.era__note p {
  font-size: 0.92rem;
  line-height: 1.65;
  color: var(--ink);
}
.era__note b {
  font-weight: 600;
}
.era__figure {
  margin-top: 0.6rem;
  font-family: var(--font-display);
  font-style: italic;
  color: var(--ink-faint);
  font-size: 0.95rem;
}

/* ---------- navigator ---------- */
.situations {
  margin-top: clamp(2rem, 4vw, 3rem);
  background: var(--ivory);
  border: 1px solid var(--hairline);
  border-radius: 4px;
  padding: clamp(1.3rem, 3vw, 2rem);
  box-shadow: var(--shadow-panel);
}
.situations h3 {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1.4rem;
  color: var(--navy-ink);
}
.situations > p {
  color: var(--ink-soft);
  font-size: 0.96rem;
  margin-top: 0.3rem;
}
.situation-grid {
  margin-top: 1.2rem;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(158px, 1fr));
  gap: 0.6rem;
}
.situation {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 0.55rem;
  text-align: left;
  font-family: var(--font-body);
  font-size: 0.88rem;
  font-weight: 500;
  line-height: 1.4;
  color: var(--navy-ink);
  background: var(--paper);
  border: 1px solid var(--hairline);
  border-radius: 4px;
  padding: 0.85rem 0.9rem;
  cursor: pointer;
  transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}
.situation svg {
  width: 20px;
  height: 20px;
  color: var(--crimson);
  flex-shrink: 0;
}
.situation:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-panel);
  border-color: var(--gold-line);
}
.situation[aria-pressed="true"] {
  background: var(--navy-ink);
  color: var(--ivory);
  border-color: var(--navy-ink);
  box-shadow: 0 0 0 3px rgba(252, 209, 22, 0.3);
}
.situation[aria-pressed="true"] svg {
  color: var(--gold);
}
.navigator-result {
  margin-top: 1.2rem;
  border-top: 1px dashed var(--hairline);
  padding-top: 1.2rem;
  font-size: 0.95rem;
  color: var(--ink-soft);
  min-height: 3.4rem;
}
.navigator-result strong {
  color: var(--navy-ink);
}
.navigator-result .rec {
  display: inline-flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  margin-top: 0.6rem;
}
.navigator-result .rec a {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  text-decoration: none;
  color: var(--navy);
  border: 1px solid rgba(0, 56, 168, 0.4);
  background: rgba(0, 56, 168, 0.06);
  padding: 0.4rem 0.8rem;
  border-radius: 100px;
  transition: transform 0.2s ease, background 0.2s ease;
}
.navigator-result .rec a:hover {
  background: var(--navy);
  color: var(--gold);
  transform: translateY(-2px);
}

.pathways {
  margin-top: clamp(2.4rem, 5vw, 3.2rem);
  display: grid;
  gap: 0.9rem;
}
.pathway {
  background: var(--ivory);
  border: 1px solid var(--hairline);
  border-radius: 4px;
  overflow: hidden;
  transition: box-shadow 0.25s ease, border-color 0.25s ease, transform 0.25s ease;
}
.pathway:hover {
  box-shadow: var(--shadow-panel);
}
.pathway.is-highlight {
  border-color: var(--crimson);
  box-shadow: 0 0 0 3px rgba(206, 17, 38, 0.15), var(--shadow-lift);
}
.pathway__head {
  display: flex;
  align-items: center;
  gap: 1rem;
  width: 100%;
  text-align: left;
  background: none;
  border: none;
  cursor: pointer;
  padding: 1.05rem clamp(1rem, 2.5vw, 1.5rem);
  font-family: var(--font-body);
  color: var(--ink);
}
.pathway__seal {
  width: 46px;
  height: 46px;
  flex-shrink: 0;
  border-radius: 50%;
  background: var(--paper);
  border: 1px solid var(--hairline-soft);
  padding: 4px;
  transition: transform 0.3s cubic-bezier(0.2, 0.8, 0.3, 1.2), filter 0.3s ease, border-color 0.3s ease;
}
.pathway:hover .pathway__seal {
  transform: scale(1.06);
  filter: drop-shadow(0 2px 3px rgba(31, 39, 64, 0.32));
  border-color: var(--gold-line);
}
.pathway__title {
  flex: 1;
  min-width: 0;
}
.pathway__title b {
  display: block;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1.12rem;
  color: var(--navy-ink);
  line-height: 1.25;
}
.pathway__title span {
  display: block;
  font-size: 0.86rem;
  color: var(--ink-soft);
  margin-top: 0.15rem;
}
.pathway__cost {
  flex-shrink: 0;
  font-family: var(--font-mono);
  font-size: 0.62rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--gold-ink);
  background: rgba(252, 209, 22, 0.16);
  border: 1px solid rgba(200, 169, 78, 0.5);
  padding: 0.3rem 0.6rem;
  border-radius: 2px;
  white-space: nowrap;
}
.pathway__cost--free {
  color: #1c6b34;
  background: rgba(34, 130, 66, 0.1);
  border-color: rgba(34, 130, 66, 0.35);
}
.pathway__chev {
  flex-shrink: 0;
  width: 18px;
  height: 18px;
  color: var(--ink-faint);
  transition: transform 0.3s cubic-bezier(0.2, 0.8, 0.3, 1);
}
.pathway.is-open .pathway__chev {
  transform: rotate(180deg);
}
.pathway__body {
  display: grid;
  grid-template-rows: 0fr;
  transition: grid-template-rows 0.4s cubic-bezier(0.2, 0.8, 0.3, 1);
}
.pathway.is-open .pathway__body {
  grid-template-rows: 1fr;
}
.pathway__body > div {
  overflow: hidden;
}
.pathway__grid {
  border-top: 1px solid var(--hairline-soft);
  padding: 1.3rem clamp(1rem, 2.5vw, 1.5rem) 1.5rem;
  display: grid;
  gap: 1.2rem;
}
@media (min-width: 760px) {
  .pathway__grid {
    grid-template-columns: repeat(3, 1fr);
  }
}
.pathway__grid h4 {
  font-family: var(--font-mono);
  font-size: 0.64rem;
  font-weight: 600;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--crimson-deep);
  margin-bottom: 0.5rem;
}
.pathway__grid ul {
  list-style: none;
  display: grid;
  gap: 0.4rem;
}
.pathway__grid li {
  font-size: 0.92rem;
  line-height: 1.6;
  color: var(--ink-soft);
  padding-left: 1.15rem;
  position: relative;
}
.pathway__grid li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.55em;
  width: 6px;
  height: 6px;
  background: var(--gold-line);
  transform: rotate(45deg);
}
.pathway__grid li strong {
  color: var(--ink);
  font-weight: 600;
}
.pathway__contact {
  grid-column: 1 / -1;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.6rem;
  border-top: 1px dashed var(--hairline);
  padding-top: 1.1rem;
}
.pathway__contact .label {
  font-family: var(--font-mono);
  font-size: 0.62rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--ink-faint);
  margin-right: 0.4rem;
}
.hotline {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-family: var(--font-mono);
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-decoration: none;
  color: var(--navy-ink);
  background: var(--paper);
  border: 1px solid var(--hairline);
  padding: 0.5rem 0.9rem;
  border-radius: 100px;
  transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}
.hotline svg {
  width: 14px;
  height: 14px;
  color: var(--crimson);
  flex-shrink: 0;
}
.hotline:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-panel);
  border-color: var(--crimson);
  color: var(--crimson);
}

/* hotline banner */
.hotline-banner {
  margin-top: clamp(2.4rem, 5vw, 3.2rem);
  background: var(--navy-ink);
  background-image: radial-gradient(800px 300px at 90% 0%, rgba(0, 56, 168, 0.6), transparent 60%);
  border-radius: 4px;
  border-top: 3px solid var(--gold);
  padding: clamp(1.5rem, 3.5vw, 2.2rem);
  color: #dfe6f6;
  box-shadow: var(--shadow-lift);
}
.hotline-banner h3 {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1.5rem;
  color: var(--ivory);
}
.hotline-banner h3 em {
  font-style: italic;
  color: var(--gold);
}
.hotline-banner > p {
  font-size: 0.95rem;
  color: #b9c4e2;
  margin-top: 0.35rem;
  max-width: 62ch;
}
.hotline-banner__grid {
  margin-top: 1.4rem;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 0.7rem;
}
.hotline-card {
  display: block;
  text-decoration: none;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 4px;
  padding: 0.9rem 1rem;
  transition: transform 0.2s ease, background 0.2s ease, border-color 0.2s ease;
}
.hotline-card:hover {
  transform: translateY(-3px);
  background: rgba(255, 255, 255, 0.1);
  border-color: var(--gold);
}
.hotline-card b {
  display: block;
  font-family: var(--font-display);
  font-size: 1.45rem;
  font-weight: 600;
  color: var(--gold);
  font-variant-numeric: lining-nums;
  letter-spacing: 0.02em;
}
.hotline-card span {
  display: block;
  font-family: var(--font-mono);
  font-size: 0.62rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: #aebadd;
  margin-top: 0.25rem;
  line-height: 1.5;
}

/* ---------- rights section ---------- */
.rights-grid {
  margin-top: clamp(2.4rem, 5vw, 3.2rem);
  display: grid;
  gap: 1.6rem;
}
@media (min-width: 960px) {
  .rights-grid {
    grid-template-columns: minmax(0, 7fr) minmax(0, 5fr);
    align-items: start;
  }
}
.miranda {
  background: var(--navy-ink);
  background-image: radial-gradient(700px 340px at 0% 100%, rgba(0, 56, 168, 0.55), transparent 60%);
  border-radius: 4px;
  border-left: 4px solid var(--crimson);
  padding: clamp(1.5rem, 3.5vw, 2.4rem);
  color: #dfe6f6;
  box-shadow: var(--shadow-lift);
  position: relative;
  overflow: hidden;
}
.miranda::after {
  content: "§12";
  position: absolute;
  right: -0.6rem;
  bottom: -2.4rem;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 9rem;
  color: rgba(252, 209, 22, 0.07);
  pointer-events: none;
}
.miranda h3 {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: var(--gold);
}
.miranda ol {
  margin-top: 1.2rem;
  list-style: none;
  display: grid;
  gap: 0.9rem;
  counter-reset: mir;
}
.miranda li {
  counter-increment: mir;
  font-family: var(--font-display);
  font-size: clamp(1.05rem, 1.7vw, 1.22rem);
  line-height: 1.6;
  color: var(--ivory);
  padding-left: 2.6rem;
  position: relative;
  text-wrap: pretty;
}
.miranda li::before {
  content: counter(mir, decimal-leading-zero);
  position: absolute;
  left: 0;
  top: 0.15em;
  font-family: var(--font-mono);
  font-size: 0.72rem;
  font-weight: 600;
  color: var(--gold);
  border: 1px solid rgba(252, 209, 22, 0.4);
  padding: 0.15rem 0.4rem;
  border-radius: 2px;
}
.miranda li em {
  font-style: italic;
  color: #ffd95e;
}
.miranda__note {
  margin-top: 1.4rem;
  padding-top: 1.1rem;
  border-top: 1px solid rgba(255, 255, 255, 0.14);
  font-size: 0.9rem;
  line-height: 1.7;
  color: #b9c4e2;
}
.miranda__note strong {
  color: var(--ivory);
}

.writs {
  display: grid;
  gap: 0.9rem;
}
.writ {
  background: var(--ivory);
  border: 1px solid var(--hairline);
  border-radius: 4px;
  padding: 1.2rem 1.3rem;
  transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
}
.writ:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-lift);
  border-color: var(--gold-line);
}
.writ h4 {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1.2rem;
  color: var(--navy-ink);
  display: flex;
  align-items: baseline;
  gap: 0.6rem;
  flex-wrap: wrap;
}
.writ h4 .tag {
  font-family: var(--font-mono);
  font-size: 0.58rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--crimson-deep);
  border: 1px solid rgba(206, 17, 38, 0.35);
  padding: 0.14rem 0.5rem;
  border-radius: 100px;
}
.writ p {
  font-size: 0.94rem;
  line-height: 1.7;
  color: var(--ink-soft);
  margin-top: 0.5rem;
}
.writ p strong {
  color: var(--ink);
}
.writ .when {
  margin-top: 0.7rem;
  font-size: 0.86rem;
  color: var(--ink);
  background: rgba(252, 209, 22, 0.14);
  border-left: 3px solid var(--gold-line);
  padding: 0.55rem 0.8rem;
  border-radius: 0 3px 3px 0;
}
.writ .when b {
  font-weight: 600;
}

/* ---------- disclaimer ---------- */
.disclaimer {
  background: var(--crimson-deep);
  background-image: linear-gradient(120deg, rgba(0, 0, 0, 0.18), transparent 55%);
  color: #ffe9ec;
  border-block: 3px double var(--gold-line);
  padding-block: clamp(2.2rem, 5vw, 3.4rem);
}
.disclaimer .shell {
  display: flex;
  gap: 1.4rem;
  align-items: flex-start;
}
.disclaimer svg {
  width: 40px;
  height: 40px;
  flex-shrink: 0;
  color: var(--gold);
  margin-top: 0.3rem;
}
.disclaimer h2 {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: clamp(1.4rem, 3vw, 1.9rem);
  color: #fff;
  line-height: 1.25;
}
.disclaimer h2 em {
  font-style: italic;
  color: var(--gold);
}
.disclaimer p {
  margin-top: 0.7rem;
  font-size: 1rem;
  line-height: 1.75;
  max-width: 74ch;
  text-wrap: pretty;
}
.disclaimer p strong {
  color: #fff;
}

/* ---------- sources ---------- */
.sources-grid {
  margin-top: clamp(2rem, 4vw, 3rem);
  display: grid;
  gap: 2.4rem;
}
@media (min-width: 900px) {
  .sources-grid {
    grid-template-columns: minmax(0, 7fr) minmax(0, 5fr);
  }
}
.source-list {
  list-style: none;
  display: grid;
}
.source-list li {
  padding: 0.85rem 0;
  border-bottom: 1px solid var(--hairline-soft);
  display: flex;
  gap: 1rem;
  align-items: baseline;
}
.source-list .idx {
  font-family: var(--font-mono);
  font-size: 0.66rem;
  font-weight: 600;
  color: var(--crimson-deep);
  flex-shrink: 0;
  width: 2ch;
}
.source-list a {
  font-weight: 500;
  color: var(--navy-ink);
  text-decoration-color: rgba(0, 56, 168, 0.4);
}
.source-list a:hover {
  color: var(--crimson);
}
.source-list small {
  display: block;
  font-size: 0.8rem;
  color: var(--ink-faint);
  margin-top: 0.1rem;
}
.seal-credits {
  background: var(--ivory);
  border: 1px solid var(--hairline);
  border-radius: 4px;
  padding: 1.4rem;
  box-shadow: var(--shadow-panel);
  align-self: start;
}
.seal-credits h3 {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1.25rem;
  color: var(--navy-ink);
}
.seal-credits > p {
  font-size: 0.86rem;
  color: var(--ink-soft);
  margin-top: 0.35rem;
  line-height: 1.65;
}
.seal-credits ul {
  list-style: none;
  margin-top: 1rem;
  display: grid;
  gap: 0.7rem;
}
.seal-credits li {
  display: flex;
  gap: 0.8rem;
  align-items: center;
  font-size: 0.84rem;
  color: var(--ink-soft);
  border-bottom: 1px dashed var(--hairline-soft);
  padding-bottom: 0.7rem;
}
.seal-credits li:last-child {
  border-bottom: none;
  padding-bottom: 0;
}
.seal-credits img {
  width: 34px;
  height: 34px;
  flex-shrink: 0;
  border-radius: 50%;
  background: var(--paper);
  border: 1px solid var(--hairline-soft);
  padding: 3px;
}
.seal-credits b {
  color: var(--ink);
  font-weight: 600;
  display: block;
  font-size: 0.86rem;
}
.seal-credits .badge {
  margin-left: auto;
  font-family: var(--font-mono);
  font-size: 0.55rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--gold-ink);
  border: 1px solid rgba(200, 169, 78, 0.6);
  background: rgba(252, 209, 22, 0.14);
  padding: 0.18rem 0.5rem;
  border-radius: 100px;
  white-space: nowrap;
  flex-shrink: 0;
}

/* ---------- footer ---------- */
.site-footer {
  background: var(--navy-ink);
  background-image: var(--grain);
  color: #b9c4e2;
  border-top: 3px double var(--gold-line);
  padding-block: clamp(3rem, 6vw, 4.5rem) 2rem;
}
.footer-grid {
  display: grid;
  gap: 2.4rem;
}
@media (min-width: 860px) {
  .footer-grid {
    grid-template-columns: minmax(0, 5fr) minmax(0, 3fr) minmax(0, 4fr);
  }
}
.footer-brand .brand__name {
  color: var(--ivory);
  font-size: 1.7rem;
}
.footer-brand p {
  margin-top: 0.9rem;
  font-size: 0.92rem;
  line-height: 1.75;
  max-width: 40ch;
}
.site-footer h4 {
  font-family: var(--font-mono);
  font-size: 0.66rem;
  font-weight: 600;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 1rem;
}
.footer-nav {
  list-style: none;
  display: grid;
  gap: 0.55rem;
}
.footer-nav a {
  color: #dfe6f6;
  text-decoration: none;
  font-size: 0.94rem;
}
.footer-nav a:hover {
  color: var(--gold);
  text-decoration: underline;
  text-decoration-color: rgba(252, 209, 22, 0.5);
  text-underline-offset: 4px;
}
.footer-bottom {
  margin-top: clamp(2.4rem, 5vw, 3.4rem);
  padding-top: 1.4rem;
  border-top: 1px solid rgba(255, 255, 255, 0.12);
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  justify-content: space-between;
  align-items: center;
  font-family: var(--font-mono);
  font-size: 0.68rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: #8494bd;
}
.footer-flag {
  display: inline-flex;
  gap: 4px;
}
.footer-flag i {
  width: 14px;
  height: 9px;
  display: block;
}
.footer-flag i:nth-child(1) {
  background: var(--navy);
}
.footer-flag i:nth-child(2) {
  background: var(--crimson);
}
.footer-flag i:nth-child(3) {
  background: var(--gold);
}

/* ---------- reduced motion ---------- */
@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
  .reveal,
  .preamble .w {
    opacity: 1 !important;
    transform: none !important;
  }
  .courthouse .draw {
    stroke-dashoffset: 0 !important;
  }
  .document__seal {
    opacity: 0.92 !important;
    transform: scale(1) rotate(-8deg) !important;
  }
}
