/* =========================================================
   BRICS NETWORK / TRUTHFARIAN
   Full revised stylesheet
   AA-oriented contrast and font-size corrections included
   ========================================================= */

/* ── Design tokens ── */
:root {
  --bg-warm:      #F5EDD8;
  --bg-gold:      #FBF0DC;
  --bg-parchment: #F8F1E3;
  --bg-deep:      #1A0E05;
  --bg-mid:       #24140A;

  --gold:         #8A4F05;
  --gold-bright:  #6F3F03;
  --gold-pale:    #F3CD84;
  --gold-wash:    rgba(138, 79, 5, 0.08);

  --text:         #1A0E05;
  --text-mid:     #4A3427;
  --text-light:   #6A5445;

  --border:       #D8C2A3;
  --border-dark:  #9B7A57;
  --border-gold:  #9A5A06;

  --red:          #B42318;
  --green:        #166534;
  --white:        #FFFFFF;

  --f-display: 'Playfair Display', Georgia, serif;
  --f-body:    'Source Serif 4', Georgia, serif;
  --f-mono:    'JetBrains Mono', monospace;

  --container: 1160px;
  --section-v: 96px;
}

/* ── Reset ── */
*, *::before, *::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--f-body);
  background: var(--bg);
  color: var(--text);
  line-height: 1.7;
  font-size: 17px;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

img,
svg {
  max-width: 100%;
  height: auto;
}

a {
  color: var(--gold);
}

a:hover,
a:focus-visible {
  color: var(--gold-bright);
}

/* ── Skip nav ── */
.skip-nav {
  position: absolute;
  top: -999px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--gold);
  color: var(--white);
  font-weight: 600;
  font-size: 0.95rem;
  padding: 0.85rem 1.5rem;
  z-index: 9999;
  text-decoration: none;
  white-space: nowrap;
}

.skip-nav:focus {
  top: 0.5rem;
  outline: 3px solid var(--text);
}

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

:focus:not(:focus-visible) {
  outline: none;
}

/* ── Container ── */
.container {
  max-width: var(--container);
  margin: 0 auto;
  padding: 20px 0;
}

@media (max-width: 768px) {
  .container {
    padding: 0 24px;
  }
}

/* ── Header ── */
header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  background: rgba(250, 250, 247, 0.97);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--border);
}

header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.logo-area {
  display: flex;
  align-items: center;
  gap: 1rem;
  text-decoration: none;
}

.logo-placeholder {
  width: 48px;
  height: 48px;
  background: var(--gold);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--f-display);
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--white);
  letter-spacing: -0.02em;
  flex-shrink: 0;
}

.logo-text {
  font-family: var(--f-display);
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--text);
  letter-spacing: -0.01em;
  line-height: 1.2;
}

.logo-text span {
  display: block;
  font-family: var(--f-mono);
  font-size: 0.74rem;
  font-weight: 400;
  color: var(--text-mid);
  letter-spacing: 0.12em;
  text-transform: uppercase;
  margin-top: 0.1rem;
}

nav {
  display: flex;
  align-items: center;
  gap: 0;
}

nav a {
  font-family: var(--f-mono);
  font-size: 0.82rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-mid);
  text-decoration: none;
  padding: 0.5rem 1rem;
  transition: color 0.2s;
  min-height: 44px;
  display: inline-flex;
  align-items: center;
}

nav a:hover,
nav a:focus-visible {
  color: var(--gold-bright);
}

.nav-cta {
  background: var(--gold);
  color: var(--white) ;
  border-radius: 6px;
  margin-left: 0.5rem;
  font-weight: 500;
  padding: 0.5rem 1.2rem ;
}

.nav-cta:hover,
.nav-cta:focus-visible {
  background: var(--gold-bright) ;
  color: var(--white) ;
}

/* ── Shared buttons ── */
.btn {
  font-family: var(--f-mono);
  font-size: 0.82rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 1rem 1.8rem;
  text-decoration: none;
  border-radius: 6px;
  transition: all 0.2s;
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  min-height: 48px;
  cursor: pointer;
  font-weight: 500;
  border: none;
}

.btn-gold {
  background: var(--gold);
  color: var(--white);
}

.btn-gold:hover,
.btn-gold:focus-visible {
  background: var(--gold-bright);
  color: var(--white);
}

.btn-outline {
  background: transparent;
  color: var(--text);
  border: 1.5px solid var(--border-dark);
}

.btn-outline:hover,
.btn-outline:focus-visible {
  border-color: var(--gold-bright);
  color: var(--gold-bright);
}

.btn-ghost {
  background: transparent;
  color: #F0C97F;
  border: 1px solid rgba(240, 201, 127, 0.45);
}

.btn-ghost:hover,
.btn-ghost:focus-visible {
  border-color: var(--gold-pale);
  color: #FFF2D2;
}

/* ── Hero ── */
.hero {
  padding-bottom: 0;
  background: var(--white);
  border-bottom: 1px solid var(--border);
  overflow: hidden;
  position: relative;
  padding-top: 3rem;
}

.hero-inner {
  display: grid;
  grid-template-columns: 1fr 420px;
  gap: 0;
  align-items: end;
}

.hero-left {
  padding: 80px 60px 80px 0;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.hero-eyebrow {
  font-family: var(--f-mono);
  font-size: 0.78rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 1.5rem;
  display: flex;
  align-items: center;
  gap: 0.8rem;
}

.hero-eyebrow::before {
  content: '';
  display: block;
  width: 32px;
  height: 1px;
  background: var(--gold);
}

.hero h1 {
  font-family: var(--f-display);
  font-size: clamp(2.8rem, 5.5vw, 5rem);
  font-weight: 700;
  line-height: 1.08;
  letter-spacing: -0.02em;
  color: var(--text);
  margin-bottom: 2rem;
}

.hero h1 em {
  font-style: italic;
  color: var(--gold);
}

.hero-sub {
  font-family: var(--f-body);
  font-size: 1.15rem;
  font-weight: 400;
  color: var(--text-mid);
  max-width: 520px;
  line-height: 1.75;
  margin-bottom: 2.5rem;
}

.hero-actions {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
  align-items: center;
}

.hero-stat-row {
  margin-top: 3.5rem;
  padding-top: 2.5rem;
  border-top: 1px solid var(--border);
  display: flex;
  gap: 3rem;
}

.hero-stat dt {
  font-family: var(--f-mono);
  font-size: 0.74rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--text-mid);
  margin-bottom: 0.3rem;
}

.hero-stat dd {
  font-family: var(--f-display);
  font-size: 2rem;
  font-weight: 700;
  color: var(--text);
  line-height: 1;
}

.hero-stat dd span {
  font-size: 1rem;
  font-weight: 400;
  color: var(--gold);
}

/* Hero right */
.hero-right {
  background: var(--bg-deep);
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

.hero-right-inner {
  padding: 60px 48px;
  position: relative;
  z-index: 1;
}

.hero-right::before {
  content: '';
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse at 30% 60%, rgba(138, 79, 5, 0.32) 0%, transparent 60%),
    radial-gradient(ellipse at 80% 20%, rgba(243, 205, 132, 0.12) 0%, transparent 55%);
}

.hero-equation {
  font-family: var(--f-mono);
  font-size: 1.5rem;
  color: #FFF0C8;
  letter-spacing: 0.04em;
  margin-bottom: 2rem;
  line-height: 1.5;
}

.hero-equation em {
  display: block;
  font-style: normal;
  font-size: 0.78rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: #F0C97F;
  margin-bottom: 0.5rem;
}

.engine-badge {
  background: rgba(138, 79, 5, 0.18);
  border: 1px solid rgba(243, 205, 132, 0.28);
  border-radius: 8px;
  padding: 1.5rem;
  margin-bottom: 1.5rem;
}

.engine-badge p {
  font-family: var(--f-mono);
  font-size: 0.78rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #F0C97F;
  margin-bottom: 0.5rem;
}

.engine-badge h3 {
  font-family: var(--f-display);
  font-size: 1.1rem;
  font-weight: 400;
  font-style: italic;
  color: rgba(255, 244, 220, 0.96);
}

.engine-links {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.engine-link {
  font-family: var(--f-mono);
  font-size: 0.78rem;
  letter-spacing: 0.04em;
  color: #F0C97F;
  text-decoration: none;
  padding: 0.4rem 0;
  border-bottom: 1px solid rgba(243, 205, 132, 0.18);
  display: flex;
  justify-content: space-between;
  align-items: center;
  transition: color 0.15s;
}

.engine-link:last-child {
  border-bottom: none;
}

.engine-link:hover,
.engine-link:focus-visible {
  color: #FFF2D2;
}

.engine-link::after {
  content: '→';
  opacity: 0.7;
}

/* ── Shared sections ── */
.section {
  padding: var(--section-v) 0;
}

.section.alt {
  background: var(--bg-gold);
}

.section.dark {
  background: var(--bg-deep);
}

.section.parchment {
  background: var(--bg-parchment);
}

.section.ruled {
  border-bottom: 1px solid var(--border);
}

.sec-label,
.sec-kicker {
  font-family: var(--f-mono);
  font-size: 0.78rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 0.6rem;
  display: flex;
  align-items: center;
  gap: 0.7rem;
}

.sec-label::before,
.sec-kicker::before {
  content: '';
  display: block;
  width: 24px;
  height: 1px;
  background: var(--gold);
}

.sec-label.centre,
.sec-kicker.centre {
  justify-content: center;
}

.sec-label.centre::before,
.sec-kicker.centre::before {
  display: none;
}

.sec-kicker.light,
.sec-label.light {
  color: #F0C97F;
}

.sec-kicker.light::before,
.sec-label.light::before {
  background: #F0C97F;
}

h2.display,
h2.st {
  font-family: var(--f-display);
  font-size: clamp(2rem, 4vw, 3.2rem);
  font-weight: 700;
  line-height: 1.12;
  letter-spacing: -0.02em;
  color: var(--text);
  margin-bottom: 1.2rem;
}

h2.display em,
h2.st em {
  font-style: italic;
  color: var(--gold);
}

h2.display.centre,
h2.st.centre {
  text-align: center;
}

h2.display.light,
h2.st.light {
  color: rgba(255, 244, 220, 0.96);
}

h2.display.light em,
h2.st.light em {
  color: var(--gold-pale);
}

.lead,
.body-p {
  font-family: var(--f-body);
  font-size: 1.05rem;
  font-weight: 400;
  color: var(--text-mid);
  max-width: 640px;
  line-height: 1.8;
  margin-bottom: 1.2rem;
}

.lead.centre {
  text-align: center;
  margin-left: auto;
  margin-right: auto;
}

.lead.light {
  color: rgba(255, 234, 196, 0.9);
}

.body-p strong,
.intro-text p strong,
.breach-text strong,
.pl-plain strong,
.constraint-list li strong,
.principle-list li strong {
  color: var(--text);
  font-weight: 600;
}

.body-p a,
.intro-text a,
.about-text a {
  color: var(--gold);
  text-decoration: underline;
  text-underline-offset: 3px;
}

/* ── Intro / about shared grids ── */
.intro-grid,
.plain-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 80px;
  align-items: start;
}

.about-grid,
.magna-grid {
  display: grid;
  grid-template-columns: 1fr 380px;
  gap: 80px;
  align-items: start;
}

.intro-text p,
.about-text p {
  font-size: 1rem;
  color: var(--text-mid);
  line-height: 1.85;
  margin-bottom: 1.2rem;
}

/* ── Pull quote ── */
.pull-quote {
  border-left: 3px solid var(--gold);
  padding: 0.5rem 0 0.5rem 2rem;
  margin: 2.5rem 0;
}

.pull-quote blockquote {
  font-family: var(--f-display);
  font-size: 1.35rem;
  font-style: italic;
  font-weight: 400;
  color: var(--text);
  line-height: 1.5;
}

.pull-quote cite {
  display: block;
  margin-top: 0.8rem;
  font-family: var(--f-mono);
  font-size: 0.74rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-mid);
  font-style: normal;
}

/* ── Lists ── */
.principle-list,
.constraint-list,
.plain-list,
.mv-list {
  list-style: none;
}

.principle-list {
  margin-top: 2rem;
}

.principle-list li,
.constraint-list li {
  display: flex;
  gap: 1.2rem;
  align-items: baseline;
  padding: 1.2rem 0;
  border-bottom: 1px solid var(--border);
  font-size: 0.98rem;
  color: var(--text-mid);
  line-height: 1.7;
}

.principle-list li:last-child,
.constraint-list li:last-child,
.plain-list li:last-child {
  border-bottom: none;
}

.principle-list li::before {
  content: attr(data-n);
  font-family: var(--f-mono);
  font-size: 0.74rem;
  letter-spacing: 0.08em;
  color: var(--gold);
  flex-shrink: 0;
  padding-top: 0.15rem;
}

.c-num {
  font-family: var(--f-mono);
  font-size: 0.74rem;
  letter-spacing: 0.08em;
  color: var(--gold);
  flex-shrink: 0;
  padding-top: 0.2rem;
}

/* ── Domains ── */
.domains-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1px;
  background: var(--border);
  border: 1px solid var(--border);
}

.domain-tile {
  background: var(--white);
  padding: 40px 36px;
  position: relative;
  transition: background 0.2s;
  text-decoration: none;
  display: block;
}

.domain-tile:hover,
.domain-tile:focus-visible {
  background: var(--bg-gold);
}

.domain-tile:hover .domain-arrow,
.domain-tile:focus-visible .domain-arrow {
  opacity: 1;
  transform: translateX(0);
}

.domain-num {
  font-family: var(--f-mono);
  font-size: 0.74rem;
  letter-spacing: 0.12em;
  color: var(--text-mid);
  margin-bottom: 1.5rem;
}

.domain-icon {
  width: 44px;
  height: 44px;
  margin-bottom: 1.2rem;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.3rem;
}

.domain-tile h3 {
  font-family: var(--f-display);
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 0.7rem;
  line-height: 1.3;
}

.domain-tile p {
  font-size: 0.95rem;
  color: var(--text-mid);
  line-height: 1.7;
  margin-bottom: 1.5rem;
}

.domain-tag-list {
  display: flex;
  flex-wrap: wrap;
  gap: 0.3rem;
}

.domain-tag {
  font-family: var(--f-mono);
  font-size: 0.74rem;
  letter-spacing: 0.05em;
  color: var(--text-mid);
  border: 1px solid var(--border);
  padding: 0.25rem 0.55rem;
  border-radius: 3px;
}

.domain-arrow {
  position: absolute;
  bottom: 1.5rem;
  right: 1.5rem;
  font-size: 1.2rem;
  color: var(--gold);
  opacity: 0;
  transform: translateX(-6px);
  transition: all 0.2s;
}

.domain-tile[data-d="health"]    .domain-icon { background: #F0FDF4; color: #166534; }
.domain-tile[data-d="cognitive"] .domain-icon { background: #F0F9FF; color: #0C4A6E; }
.domain-tile[data-d="ecology"]   .domain-icon { background: #ECFDF5; color: #065F46; }
.domain-tile[data-d="legal"]     .domain-icon { background: #FFFBEB; color: #92400E; }
.domain-tile[data-d="economic"]  .domain-icon { background: #FFF7ED; color: #9A3412; }
.domain-tile[data-d="ai"]        .domain-icon { background: #F5F3FF; color: #5B21B6; }

/* ── TFQ strip ── */
.tfq-strip {
  background: var(--bg-deep);
  padding: 80px 0;
}

.tfq-strip .container {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 60px;
  align-items: center;
}

.tfq-heading {
  font-family: var(--f-display);
  font-size: 2.2rem;
  font-weight: 700;
  font-style: italic;
  color: rgba(255, 244, 220, 0.96);
  margin-bottom: 1rem;
  line-height: 1.2;
}

.tfq-sub {
  font-size: 1rem;
  color: rgba(255, 234, 196, 0.9);
  font-weight: 400;
  max-width: 520px;
  line-height: 1.8;
}

.tfq-cta {
  display: flex;
  flex-direction: column;
  gap: 0.8rem;
  align-items: flex-end;
}

/* ── Open access ── */
.open-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 32px;
  margin-top: 3rem;
}

.open-card {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 36px 32px;
  border-top: 3px solid var(--gold);
  transition: box-shadow 0.2s, transform 0.2s;
}

.open-card:hover,
.open-card:focus-within {
  box-shadow: 0 12px 40px rgba(138, 79, 5, 0.12);
  transform: translateY(-2px);
}

.open-card h3 {
  font-family: var(--f-display);
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 0.7rem;
  line-height: 1.3;
}

.open-card p {
  font-size: 0.95rem;
  color: var(--text-mid);
  line-height: 1.75;
  margin-bottom: 1.5rem;
}

.open-link,
.tool-link {
  font-family: var(--f-mono);
  font-size: 0.78rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--gold);
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  transition: gap 0.2s, color 0.2s, border-color 0.2s;
}

.open-link:hover,
.open-link:focus-visible,
.tool-link:hover,
.tool-link:focus-visible {
  gap: 0.7rem;
  color: var(--gold-bright);
}

.open-link::after,
.tool-link::after {
  content: '→';
}

.tool-link {
  border-bottom: 1px solid var(--border-gold);
  padding-bottom: 0.15rem;
}

/* ── Disclosure strip ── */
.disclosure-strip {
  background: var(--bg-warm);
  padding: 60px 0;
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}

.disclosure-inner {
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 48px;
  align-items: center;
}

.disc-icon {
  font-size: 3rem;
}

.disc-text h3 {
  font-family: var(--f-display);
  font-size: 1.3rem;
  font-weight: 700;
  margin-bottom: 0.5rem;
}

.disc-text p {
  font-size: 0.95rem;
  color: var(--text-mid);
  line-height: 1.7;
}

/* ── Nations strip ── */
.nations-strip {
  padding: 56px 0;
  background: var(--white);
  border-top: 1px solid var(--border);
}

.nations-label {
  font-family: var(--f-mono);
  font-size: 0.74rem;
  letter-spacing: 0.16em;
  color: var(--text-mid);
  text-transform: uppercase;
  text-align: center;
  margin-bottom: 1.5rem;
}

.nations-list {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0;
  border: 1px solid var(--border);
}

.nation {
  padding: 0.9rem 1.8rem;
  font-family: var(--f-mono);
  font-size: 0.82rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-mid);
  border-right: 1px solid var(--border);
  transition: background 0.15s, color 0.15s;
}

.nation:last-child {
  border-right: none;
}

.nation:hover,
.nation:focus-visible {
  background: var(--bg-gold);
  color: var(--gold-bright);
}

/* ── Licence box ── */
.licence-box {
  background: var(--bg-gold);
  border: 1px solid var(--border-dark);
  border-radius: 10px;
  padding: 28px;
}

.licence-box h4 {
  font-family: var(--f-mono);
  font-size: 0.78rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 1.2rem;
}

.licence-item {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  padding: 0.7rem 0;
  border-bottom: 1px solid var(--border);
}

.licence-item:last-child {
  border-bottom: none;
}

.licence-item dt {
  font-size: 0.92rem;
  color: var(--text);
  font-weight: 600;
}

.licence-item dd {
  font-family: var(--f-mono);
  font-size: 0.74rem;
  color: var(--text-mid);
  letter-spacing: 0.05em;
}

/* ── Contact ── */
.contact-inner {
  max-width: 640px;
  margin: 0 auto;
  text-align: center;
}

.contact-inner p {
  font-size: 1rem;
  color: var(--text-mid);
  margin-bottom: 2.5rem;
  line-height: 1.8;
}

.contact-email {
  font-family: var(--f-display);
  font-size: 1.6rem;
  font-style: italic;
  color: var(--gold);
  text-decoration: none;
  display: inline-block;
  border-bottom: 2px solid var(--gold-pale);
  padding-bottom: 0.2rem;
  transition: border-color 0.2s, color 0.2s;
}

.contact-email:hover,
.contact-email:focus-visible {
  border-color: var(--gold-bright);
  color: var(--gold-bright);
}

/* ── Animations ── */
@keyframes fadeUp {
  from { opacity: 0; transform: translateY(20px); }
  to   { opacity: 1; transform: translateY(0); }
}

.hero-left > * {
  animation: fadeUp 0.7s ease both;
}

.hero-left > *:nth-child(1) { animation-delay: 0.1s; }
.hero-left > *:nth-child(2) { animation-delay: 0.2s; }
.hero-left > *:nth-child(3) { animation-delay: 0.3s; }
.hero-left > *:nth-child(4) { animation-delay: 0.4s; }
.hero-left > *:nth-child(5) { animation-delay: 0.5s; }

/* ── Masthead ── */
.masthead {
  padding-top: 90px;
  background: var(--white);
  border-bottom: 3px solid var(--gold);
}

.masthead-inner {
  padding: 72px 0 0;
}

.masthead-kicker {
  font-family: var(--f-mono);
  font-size: 0.78rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--gold);
  display: flex;
  align-items: center;
  gap: 1rem;
  margin-bottom: 1.5rem;
}

.masthead-kicker::before {
  content: '';
  display: block;
  width: 40px;
  height: 1px;
  background: var(--gold);
}

.masthead h1 {
  font-family: var(--f-display);
  font-size: clamp(2.6rem, 6vw, 5rem);
  font-weight: 900;
  line-height: 1.04;
  letter-spacing: -0.025em;
  color: var(--text);
  max-width: 820px;
  margin-bottom: 2rem;
}

.masthead h1 em {
  font-style: italic;
  color: var(--gold);
}

.masthead-deck {
  font-size: 1.15rem;
  font-weight: 400;
  color: var(--text-mid);
  max-width: 640px;
  line-height: 1.8;
  margin-bottom: 2.5rem;
}

/* ── Formula strip ── */
.formula-strip {
  background: var(--bg-deep);
  padding: 2rem 3rem;
  display: flex;
  align-items: center;
  gap: 4rem;
  flex-wrap: wrap;
  margin-top: 3rem;
}

.formula-main {
  font-family: var(--f-display);
  font-size: 2rem;
  font-style: italic;
  color: #FFF0C8;
  letter-spacing: -0.01em;
  flex-shrink: 0;
}

.formula-vars {
  display: flex;
  gap: 2.5rem;
  flex-wrap: wrap;
}

.fvar {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.fvar-sym {
  font-family: var(--f-mono);
  font-size: 1.05rem;
  color: #FFF0C8;
}

.fvar-label {
  font-family: var(--f-mono);
  font-size: 0.82rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #F0C97F;
}

.formula-note {
  font-family: var(--f-mono);
  font-size: 0.88rem;
  color: rgba(255, 234, 196, 0.92);
  letter-spacing: 0.03em;
  line-height: 1.8;
  max-width: 320px;
  margin-left: auto;
}

/* ── Magna Carta block ── */
.charter-quote {
  background: var(--bg-parchment);
  border-left: 4px solid var(--gold);
  padding: 2.5rem 2.5rem 2.5rem 3rem;
  margin: 2.5rem 0;
  position: relative;
}

.charter-quote::before {
  content: '"';
  font-family: var(--f-display);
  font-size: 6rem;
  font-weight: 900;
  color: var(--gold-pale);
  opacity: 0.55;
  position: absolute;
  top: -1rem;
  left: 1.5rem;
  line-height: 1;
}

.charter-quote blockquote {
  font-family: var(--f-body);
  font-size: 1.05rem;
  font-style: italic;
  color: var(--text);
  line-height: 1.75;
  position: relative;
}

.charter-quote cite {
  display: block;
  margin-top: 1.2rem;
  font-family: var(--f-mono);
  font-size: 0.74rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-mid);
  font-style: normal;
}

/* ── Math sidebar ── */
.math-card,
.eq-vis {
  background: var(--bg-deep);
  padding: 2.5rem;
  position: sticky;
  top: 80px;
  border-radius: 2px;
}

.math-card-label,
.eq-vis-label {
  font-family: var(--f-mono);
  font-size: 0.74rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: rgba(255, 234, 196, 0.88);
  margin-bottom: 1.5rem;
}

.ml {
  font-family: var(--f-display);
  font-style: italic;
  color: #FFF0C8;
  line-height: 1.4;
  margin-bottom: 1.2rem;
}

.ml.lg { font-size: 1.5rem; }
.ml.md { font-size: 1.1rem; }
.ml.sm {
  font-size: 0.88rem;
  color: rgba(255, 234, 196, 0.84);
}

.math-divider {
  border: none;
  border-top: 1px solid rgba(243, 205, 132, 0.22);
  margin: 1.5rem 0;
}

.mv-list li {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  padding: 0.55rem 0;
  border-bottom: 1px solid rgba(243, 205, 132, 0.14);
  font-family: var(--f-mono);
  font-size: 0.8rem;
}

.mv-list li:last-child {
  border-bottom: none;
}

.mv-sym {
  color: #FFF0C8;
}

.mv-def {
  color: rgba(255, 234, 196, 0.88);
  font-size: 0.74rem;
  letter-spacing: 0.03em;
  text-align: right;
}

.mv-list li.breach .mv-sym {
  color: #FFB4B4;
}

.mv-list li.breach .mv-def {
  color: #FFD0D0;
}

.math-note {
  margin-top: 1.5rem;
  padding: 1rem;
  background: rgba(138, 79, 5, 0.12);
  border: 1px solid rgba(243, 205, 132, 0.22);
  border-radius: 4px;
  font-family: var(--f-mono);
  font-size: 0.78rem;
  line-height: 1.8;
  color: rgba(255, 234, 196, 0.92);
  letter-spacing: 0.02em;
}

/* ── Variables ── */
.vars-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 1px;
  background: var(--border);
  border: 1px solid var(--border);
  margin-top: 3rem;
}

.var-tile {
  background: var(--white);
  padding: 32px 24px;
  position: relative;
}

.var-tile::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
}

.var-tile[data-v="P"]::before { background: var(--gold); }
.var-tile[data-v="R"]::before { background: #8B4513; }
.var-tile[data-v="L"]::before { background: #1A5C2A; }
.var-tile[data-v="E"]::before { background: #1A3A7A; }
.var-tile[data-v="D"]::before { background: #6A1A6A; }

.var-sym {
  font-family: var(--f-display);
  font-size: 2.8rem;
  font-weight: 900;
  font-style: italic;
  line-height: 1;
  margin-bottom: 0.8rem;
}

.var-tile[data-v="P"] .var-sym { color: var(--gold); }
.var-tile[data-v="R"] .var-sym { color: #8B4513; }
.var-tile[data-v="L"] .var-sym { color: #1A5C2A; }
.var-tile[data-v="E"] .var-sym { color: #1A3A7A; }
.var-tile[data-v="D"] .var-sym { color: #6A1A6A; }

.var-name {
  font-family: var(--f-mono);
  font-size: 0.74rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-mid);
  margin-bottom: 0.7rem;
}

.var-tile p {
  font-size: 0.92rem;
  color: var(--text-mid);
  line-height: 1.65;
}

.breach-rule {
  background: var(--bg-parchment);
  border: 1px solid var(--border-gold);
  padding: 1.5rem 2rem;
  margin-top: 2.5rem;
  display: flex;
  align-items: baseline;
  gap: 1.5rem;
  flex-wrap: wrap;
}

.breach-formula {
  font-family: var(--f-display);
  font-size: 1.2rem;
  font-style: italic;
  color: var(--red);
  flex-shrink: 0;
}

.breach-text {
  font-size: 0.95rem;
  color: var(--text-mid);
  line-height: 1.7;
}

/* ── Jurisdiction table ── */
.juris-header {
  display: grid;
  grid-template-columns: 1fr 320px;
  gap: 64px;
  align-items: start;
  margin-bottom: 3.5rem;
}

.juris-stat {
  background: var(--bg-deep);
  padding: 2.5rem;
  text-align: center;
  border-radius: 2px;
}

.juris-stat dt {
  font-family: var(--f-mono);
  font-size: 0.74rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: rgba(255, 234, 196, 0.88);
  margin-bottom: 0.8rem;
}

.juris-stat dd {
  font-family: var(--f-display);
  font-size: 4rem;
  font-weight: 900;
  color: #FFF0C8;
  line-height: 1;
}

.juris-stat dd span {
  font-size: 1.8rem;
}

.juris-stat p {
  font-family: var(--f-mono);
  font-size: 0.78rem;
  color: rgba(255, 234, 196, 0.88);
  letter-spacing: 0.03em;
  margin-top: 0.6rem;
}

.juris-note {
  background: rgba(138, 79, 5, 0.06);
  border-left: 3px solid var(--gold);
  padding: 1.5rem 2rem;
  font-size: 0.95rem;
  color: var(--text-mid);
  line-height: 1.8;
  margin-top: 1.5rem;
}

.juris-note strong {
  color: var(--text);
}

.region-table,
.compare-table {
  width: 100%;
  border-collapse: collapse;
  margin-top: 2rem;
}

.region-table thead tr {
  border-bottom: 2px solid var(--border-gold);
}

.compare-table thead tr {
  border-bottom: 2px solid var(--gold);
}

.region-table th,
.compare-table th {
  font-family: var(--f-mono);
  font-size: 0.74rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  padding: 1rem 0;
  text-align: left;
  font-weight: 500;
}

.region-table th {
  color: var(--gold);
}

.region-table th:last-child {
  text-align: right;
}

.compare-table th {
  padding: 1rem 1.2rem;
}

.compare-table th:nth-child(2) {
  color: var(--gold);
}

.compare-table th:nth-child(3) {
  color: var(--text-mid);
}

.region-table tbody tr,
.compare-table tbody tr {
  border-bottom: 1px solid var(--border);
  transition: background 0.15s;
}

.region-table tbody tr:hover,
.compare-table tbody tr:hover {
  background: var(--bg-gold);
}

.region-table td {
  padding: 1.1rem 0;
  font-size: 0.95rem;
  color: var(--text-mid);
  vertical-align: top;
  line-height: 1.6;
}

.region-table td:first-child {
  font-family: var(--f-mono);
  font-size: 0.8rem;
  color: var(--gold);
  width: 160px;
}

.region-table td:last-child {
  font-family: var(--f-mono);
  font-size: 0.78rem;
  text-align: right;
  color: var(--text-mid);
}

.compare-table td {
  padding: 1rem 1.2rem;
  font-size: 0.92rem;
  color: var(--text-mid);
  vertical-align: top;
  line-height: 1.6;
}

.compare-table td:first-child {
  font-weight: 600;
  color: var(--text);
  font-size: 0.9rem;
}

.compare-table td.phm {
  color: var(--green);
  font-family: var(--f-mono);
  font-size: 0.82rem;
}

.compare-table td.vento {
  color: var(--text-mid);
  font-family: var(--f-mono);
  font-size: 0.82rem;
}

/* ── Substrate box ── */
.substrate-box {
  background: var(--bg-deep);
  padding: 3rem 3.5rem;
  margin-top: 3.5rem;
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 2.5rem;
  align-items: center;
}

.substrate-icon {
  font-family: var(--f-display);
  font-size: 3.5rem;
  font-style: italic;
  color: #FFF0C8;
  opacity: 0.4;
  flex-shrink: 0;
}

.substrate-text h3 {
  font-family: var(--f-display);
  font-size: 1.3rem;
  font-style: italic;
  color: rgba(255, 244, 220, 0.96);
  margin-bottom: 0.8rem;
  font-weight: 400;
  line-height: 1.4;
}

.substrate-text p {
  font-size: 0.92rem;
  color: rgba(255, 234, 196, 0.9);
  line-height: 1.85;
  max-width: 600px;
}

/* ── Plain language ── */
.plain-list {
  margin-top: 2rem;
}

.plain-list li {
  display: grid;
  grid-template-columns: 110px 1fr;
  gap: 1.5rem;
  padding: 1.3rem 0;
  border-bottom: 1px solid var(--border);
  align-items: baseline;
}

.pl-formal {
  font-family: var(--f-mono);
  font-size: 0.78rem;
  color: var(--gold);
  letter-spacing: 0.03em;
}

.pl-plain {
  font-size: 0.95rem;
  color: var(--text-mid);
  line-height: 1.75;
}

/* ── Equilibrium visualiser ── */
.eq-row {
  display: flex;
  align-items: center;
  gap: 0.8rem;
  padding: 0.75rem 0;
  border-bottom: 1px solid rgba(243, 205, 132, 0.08);
}

.eq-row:last-of-type {
  border-bottom: none;
}

.eq-var {
  font-family: var(--f-display);
  font-style: italic;
  font-size: 1.1rem;
  color: #FFF0C8;
  width: 22px;
  flex-shrink: 0;
}

.eq-bar-wrap {
  flex: 1;
  height: 5px;
  background: rgba(243, 205, 132, 0.12);
  border-radius: 3px;
}

.eq-bar {
  height: 100%;
  border-radius: 3px;
}

.eq-bar.hold    { width: 100%; background: #2D7A3A; }
.eq-bar.breach  { width: 28%;  background: #8B1A1A; }
.eq-bar.partial { width: 62%;  background: var(--gold); }

.eq-var-name {
  font-family: var(--f-mono);
  font-size: 0.74rem;
  color: rgba(255, 234, 196, 0.88);
  width: 70px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.eq-status {
  font-family: var(--f-mono);
  font-size: 0.74rem;
  width: 74px;
  text-align: right;
  letter-spacing: 0.03em;
}

.eq-status.hold    { color: #79D28C; }
.eq-status.breach  { color: #FFB4B4; }
.eq-status.partial { color: #F0C97F; }

.eq-result {
  margin-top: 1.8rem;
  padding: 1.2rem;
  background: rgba(138, 79, 5, 0.12);
  border: 1px solid rgba(243, 205, 132, 0.22);
}

.eq-result-label {
  font-family: var(--f-mono);
  font-size: 0.74rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: rgba(255, 234, 196, 0.88);
  margin-bottom: 0.5rem;
}

.eq-result-val {
  font-family: var(--f-display);
  font-style: italic;
  font-size: 1.05rem;
  color: #FFF0C8;
}

.eq-cta {
  font-family: var(--f-mono);
  font-size: 0.78rem;
  color: rgba(255, 234, 196, 0.9);
  margin-top: 1.5rem;
  letter-spacing: 0.03em;
}

/* ── Tools ── */
.tools-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
  margin-top: 3rem;
}

.tool-card {
  background: var(--white);
  border: 1px solid var(--border);
  border-top: 3px solid var(--gold);
  padding: 36px 32px;
  transition: box-shadow 0.2s, transform 0.2s;
}

.tool-card:hover,
.tool-card:focus-within {
  box-shadow: 0 8px 32px rgba(138, 79, 5, 0.14);
  transform: translateY(-2px);
}

.tool-audience {
  font-family: var(--f-mono);
  font-size: 0.74rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text-mid);
  margin-bottom: 1rem;
}

.tool-card h3 {
  font-family: var(--f-display);
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 0.7rem;
  line-height: 1.3;
}

.tool-card p {
  font-size: 0.95rem;
  color: var(--text-mid);
  line-height: 1.75;
  margin-bottom: 1.8rem;
}

/* ── Disclosures ── */
.disclosures-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2px;
  background: rgba(243, 205, 132, 0.18);
  margin-top: 3rem;
}

.disclosure-item {
  background: var(--bg-mid);
  padding: 28px 32px;
  text-decoration: none;
  display: block;
  transition: background 0.15s;
}

.disclosure-item:hover,
.disclosure-item:focus-visible {
  background: rgba(138, 79, 5, 0.22);
}

.di-type {
  font-family: var(--f-mono);
  font-size: 0.74rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #F0C97F;
  margin-bottom: 0.6rem;
}

.di-title {
  font-family: var(--f-body);
  font-size: 0.96rem;
  color: rgba(255, 244, 220, 0.95);
  line-height: 1.6;
}

/* ── Action strip ── */
.action-strip {
  background: var(--bg-deep);
  padding: 80px 0;
}

.action-inner {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 64px;
  align-items: center;
}

.action-text h2 {
  font-family: var(--f-display);
  font-size: 2.2rem;
  font-weight: 700;
  font-style: italic;
  color: rgba(255, 244, 220, 0.96);
  margin-bottom: 1rem;
  line-height: 1.2;
}

.action-text p {
  font-size: 1rem;
  color: rgba(255, 234, 196, 0.9);
  line-height: 1.8;
  font-weight: 400;
  max-width: 440px;
}

.action-btns {
  display: flex;
  flex-direction: column;
  gap: 0.8rem;
}

/* ── Footer ── */
footer {
  background: var(--bg-deep);
  padding: 56px 0 36px;
}

.footer-top,
.footer-grid {
  display: grid;
  gap: 48px;
  padding-bottom: 40px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  margin-bottom: 32px;
}

.footer-top {
  grid-template-columns: 1fr 1fr 1fr;
}

.footer-grid {
  grid-template-columns: 1.5fr 1fr 1fr;
}

.footer-brand p {
  font-family: var(--f-display);
  font-size: 1.05rem;
  font-style: italic;
  color: rgba(255, 244, 220, 0.96);
  margin-bottom: 0.5rem;
}

.footer-brand small {
  font-family: var(--f-mono);
  font-size: 0.74rem;
  color: rgba(255, 234, 196, 0.9);
  letter-spacing: 0.04em;
  line-height: 1.8;
  display: block;
}

.footer-col h4 {
  font-family: var(--f-mono);
  font-size: 0.74rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: rgba(255, 234, 196, 0.9);
  margin-bottom: 1rem;
}

.footer-col a {
  display: block;
  font-family: var(--f-mono);
  font-size: 0.8rem;
  letter-spacing: 0.03em;
  color: #F0C97F;
  text-decoration: none;
  padding: 0.3rem 0;
  transition: color 0.15s;
}

.footer-col a:hover,
.footer-col a:focus-visible {
  color: #FFF2D2;
}

.footer-bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 1rem;
}

.footer-bottom p {
  font-family: var(--f-mono);
  font-size: 0.74rem;
  letter-spacing: 0.04em;
  color: rgba(255, 234, 196, 0.9);
}

/* =========================================================
   PORTAL STORYBOARD
   ========================================================= */
.portal-storyboard {
  margin-bottom: 2rem;
}

.portal-storyboard__head {
  margin-bottom: 1.5rem;
}

.portal-storyboard__eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.65rem;
  margin: 0 0 0.8rem;
  font-family: var(--f-mono);
  font-size: 0.78rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--gold);
}

.portal-storyboard__eyebrow::before {
  content: "";
  width: 28px;
  height: 1px;
  background: var(--gold);
  display: block;
}

.portal-storyboard__title {
  margin: 0 0 0.85rem;
  font-family: var(--f-display);
  font-size: clamp(2rem, 3vw, 2.8rem);
  line-height: 1.08;
  letter-spacing: -0.02em;
  color: var(--text);
}

.portal-storyboard__intro {
  max-width: 760px;
  margin: 0;
  font-size: 1rem;
  line-height: 1.8;
  color: var(--text-mid);
}

.portal-storyboard__shell {
  position: relative;
  background: linear-gradient(180deg, var(--white) 0%, #fffaf2 100%);
  border: 1px solid var(--border);
  border-radius: 18px;
  overflow: hidden;
  box-shadow: 0 20px 50px rgba(26, 14, 5, 0.06);
}

.portal-storyboard__track-wrap {
  overflow: hidden;
}

.portal-storyboard__track {
  display: flex;
  transition: transform 0.38s ease;
  will-change: transform;
}

.portal-slide {
  flex: 0 0 100%;
  width: 100%;
  display: grid;
  grid-template-columns: 1.05fr 1fr;
  align-items: stretch;
  min-height: 420px;
}

.portal-slide__media {
  position: relative;
  padding: 2rem;
  background:
    radial-gradient(circle at 20% 20%, rgba(243, 205, 132, 0.32), transparent 35%),
    radial-gradient(circle at 80% 75%, rgba(138, 79, 5, 0.14), transparent 35%),
    linear-gradient(180deg, var(--bg-gold) 0%, var(--bg-warm) 100%);
  border-right: 1px solid var(--border);
}

.portal-slide__placeholder {
  width: 100%;
  height: 100%;
  min-height: 260px;
  border: 1px dashed var(--border-dark);
  border-radius: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(255, 255, 255, 0.55);
  color: var(--text-mid);
  font-family: var(--f-mono);
  font-size: 0.8rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  text-align: center;
  padding: 1rem;
}

.portal-slide__body {
  padding: 2.2rem 2rem 2rem;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.portal-slide__meta {
  display: flex;
  align-items: center;
  gap: 0.8rem;
  margin-bottom: 1rem;
}

.portal-slide__num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 48px;
  height: 32px;
  padding: 0 0.8rem;
  border-radius: 999px;
  background: var(--gold);
  color: var(--white);
  font-family: var(--f-mono);
  font-size: 0.78rem;
  letter-spacing: 0.06em;
}

.portal-slide__tag {
  font-family: var(--f-mono);
  font-size: 0.78rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-mid);
}

.portal-slide__title {
  margin: 0 0 0.9rem;
  font-family: var(--f-display);
  font-size: clamp(1.5rem, 2vw, 2rem);
  line-height: 1.18;
  color: var(--text);
}

.portal-slide__text {
  margin: 0;
  font-size: 1rem;
  line-height: 1.85;
  color: var(--text-mid);
  max-width: 44ch;
}

.portal-storyboard__controls {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 1rem 1.25rem 1.2rem;
  border-top: 1px solid var(--border);
  background: rgba(250, 250, 247, 0.92);
}

.portal-storyboard__nav {
  width: 48px;
  height: 48px;
  border: 1px solid var(--border-dark);
  border-radius: 999px;
  background: var(--white);
  color: var(--text);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 1rem;
  cursor: pointer;
  transition: all 0.2s ease;
}

.portal-storyboard__nav:hover,
.portal-storyboard__nav:focus-visible {
  border-color: var(--gold);
  color: var(--gold);
  background: var(--bg-gold);
}

.portal-storyboard__dots {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.6rem;
  flex-wrap: wrap;
}

.portal-storyboard__dot {
  min-width: 46px;
  height: 36px;
  border: 1px solid var(--border-dark);
  border-radius: 999px;
  background: var(--white);
  color: var(--text-mid);
  padding: 0 0.85rem;
  font-family: var(--f-mono);
  font-size: 0.78rem;
  letter-spacing: 0.05em;
  cursor: pointer;
  transition: all 0.2s ease;
}

.portal-storyboard__dot:hover,
.portal-storyboard__dot:focus-visible {
  border-color: var(--gold);
  color: var(--gold);
}

.portal-storyboard__dot.is-active {
  background: var(--gold);
  border-color: var(--gold);
  color: var(--white);
}

.portal-slide__notice {
  margin-top: 1.1rem;
  padding: 1rem 1rem 0.95rem;
  background: var(--bg-warm);
  border: 1px solid var(--border);
  border-left: 3px solid var(--gold);
  border-radius: 10px;
}

.portal-slide__notice p {
  margin: 0 0 0.7rem;
  font-size: 0.95rem;
  line-height: 1.7;
  color: var(--text-mid);
}

.portal-slide__notice p:last-child {
  margin-bottom: 0;
}

.portal-slide__notice strong {
  color: var(--text);
}

/* ── Responsive ── */
@media (max-width: 1024px) {
  .hero-inner { grid-template-columns: 1fr; }
  .hero-right { display: none; }
  .intro-grid,
  .plain-grid,
  .magna-grid,
  .about-grid { grid-template-columns: 1fr; gap: 40px; }
  .domains-grid { grid-template-columns: repeat(2, 1fr); }
  .open-grid { grid-template-columns: repeat(2, 1fr); }
  .footer-top,
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .math-card,
  .eq-vis { position: static; }
  .action-inner { grid-template-columns: 1fr; gap: 2.5rem; }
  .juris-header { grid-template-columns: 1fr; gap: 2rem; }
  .vars-grid { grid-template-columns: repeat(3, 1fr); }
}

@media (max-width: 991.98px) {
  .portal-slide {
    grid-template-columns: 1fr;
  }

  .portal-slide__media {
    border-right: 0;
    border-bottom: 1px solid var(--border);
    padding: 1.25rem;
  }

  .portal-slide__body {
    padding: 1.5rem 1.25rem 1.4rem;
  }

  .portal-slide__placeholder {
    min-height: 220px;
  }
}

@media (max-width: 768px) {
  :root { --section-v: 64px; }

  .domains-grid,
  .open-grid,
  .tools-grid,
  .disclosures-grid,
  .footer-top,
  .footer-grid { grid-template-columns: 1fr; }

  .tfq-strip .container { grid-template-columns: 1fr; }
  .tfq-cta { align-items: flex-start; }
  .disclosure-inner,
  .substrate-box { grid-template-columns: 1fr; text-align: center; }
  .disc-icon { font-size: 2rem; }
  nav { display: none; }
  .hero h1 { font-size: 2.4rem; }
  .hero-stat-row { gap: 1.5rem; flex-wrap: wrap; }
  .formula-strip { padding: 1.5rem; gap: 2rem; }
  .formula-note { display: none; }
  .vars-grid { grid-template-columns: 1fr 1fr; }
  .portal-storyboard__title { font-size: 1.8rem; }
  .portal-storyboard__intro,
  .portal-slide__text { font-size: 0.95rem; line-height: 1.75; }
  .portal-storyboard__controls { padding: 0.9rem 0.9rem 1rem; }
  .portal-storyboard__nav { width: 42px; height: 42px; }
  .portal-storyboard__dot { min-width: 40px; height: 34px; padding: 0 0.7rem; }
}

@media (max-width: 640px) {
  .plain-list li {
    grid-template-columns: 1fr;
    gap: 0.45rem;
  }

  .region-table td:first-child,
  .region-table td:last-child {
    width: auto;
  }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation: none ;
    transition: none ;
  }

  html {
    scroll-behavior: auto;
  }
}

/* =========================
   FULL SCREEN MOBILE MENU
   ========================= */

.header-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  position: relative;
}

.desktop-nav {
  display: flex;
  align-items: center;
  gap: 0;
}

.mobile-menu-toggle {
  display: none;
  width: 48px;
  height: 48px;
  padding: 0;
  border: 1px solid var(--border-dark);
  border-radius: 8px;
  background: var(--white);
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 5px;
  cursor: pointer;
  flex-shrink: 0;
  position: relative;
  z-index: 1201;
}

.mobile-menu-toggle span {
  display: block;
  width: 20px;
  height: 2px;
  background: var(--text);
  border-radius: 2px;
}

.mobile-menu-overlay {
  position: fixed;
  inset: 0;
  background: white;
  z-index: 1200;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity 0.28s ease, visibility 0.28s ease;
}

.mobile-menu-panel {
  position: absolute;
  top: 0;
  right: 0;
  width: min(88vw, 360px);
  height: 100%;
  background: var(--bg);
  box-shadow: -16px 0 40px rgba(26, 14, 5, 0.18);
  transform: translateX(100%);
  transition: transform 0.28s ease;
  display: flex;
  flex-direction: column;
  padding: 1.25rem;
}

.mobile-menu-overlay.is-open {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
}

.mobile-menu-overlay.is-open .mobile-menu-panel {
  transform: translateX(0);
}

.mobile-menu-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid var(--border);
  margin-bottom: 1rem;
}

.mobile-menu-title {
  font-family: var(--f-mono);
  font-size: 0.82rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text-mid);
}

.mobile-menu-close {
  width: 44px;
  height: 44px;
  border: 1px solid var(--border-dark);
  border-radius: 8px;
  background: var(--white);
  position: relative;
  cursor: pointer;
  flex-shrink: 0;
}

.mobile-menu-close span {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 18px;
  height: 2px;
  background: var(--text);
  border-radius: 2px;
}

.mobile-menu-close span:first-child {
  transform: translate(-50%, -50%) rotate(45deg);
}

.mobile-menu-close span:last-child {
  transform: translate(-50%, -50%) rotate(-45deg);
}

.mobile-menu-nav {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
}

.mobile-menu-nav a {
  display: flex;
  align-items: center;
  min-height: 48px;
  padding: 0.95rem 1rem;
  border-radius: 10px;
  text-decoration: none;
  font-family: var(--f-mono);
  font-size: 0.82rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-mid);
  background: transparent;
}

.mobile-menu-nav a:hover,
.mobile-menu-nav a:focus-visible {
  background: var(--bg-gold);
  color: var(--gold-bright);
}

.mobile-menu-nav .nav-cta {
  margin-left: 0;
  margin-top: 0.35rem;
  justify-content: center;
  background: var(--gold);
  color: var(--white) ;
}

.mobile-menu-nav .nav-cta:hover,
.mobile-menu-nav .nav-cta:focus-visible {
  background: var(--gold-bright);
  color: var(--white) ;
}

body.menu-open {
  overflow: hidden;
}

@media (max-width: 768px) {
  .desktop-nav {
    display: none;
  }

  .mobile-menu-toggle {
    display: inline-flex;
  }
}

/* Logo must shrink on small screens */
.logo-area svg {
  display: block;
  width: clamp(180px, 48vw, 320px);
  height: auto;
  max-width: 100%;
}

/* Header container needs room on tablets */
header .container {
  gap: 1rem;
}

/* Hero / masthead inner spacing */
@media (max-width: 1024px) {
  .hero-left {
    padding: 56px 0 56px 0;
  }

  .masthead-inner {
    padding: 20px;
  }
}
/* =========================
   FORCE MOBILE HEADER LOGO SIZE
   ========================= */

header .header-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  position: relative;
}

header .logo-area {
  display: flex;
  align-items: center;
  flex: 1 1 auto;
  min-width: 0;
}

header .site-logo {
  display: block;
  width: 320px ;
  height: auto ;
  max-width: none ;
  flex-shrink: 0;
}

header .mobile-menu-toggle {
  flex: 0 0 48px;
}

.header-bar{padding: 0 10px;}

.section.dark {
  background: #1b0d04;
  color: #f0dfc7;
}

.section.dark .sec-kicker.light {
  color: #e0a84d;
}

.section.dark .st.light,
.section.dark h2,
.section.dark h3 {
  color: #fff4e6;
}

.section.dark p,
.section.dark li,
.section.dark td,
.section.dark th,
.section.dark .substrate-text p,
.section.dark .compare-table td,
.section.dark .compare-table th {
  color: #f0dfc7 !important;
  transition: background-color 0.2s ease, color 0.2s ease;
}

.section.dark .compare-table,
.section.dark .compare-table td,
.section.dark .compare-table th {
  border-color: rgba(240, 192, 96, 0.5);
}

.section.dark .phm {
  color: #7ff0b8 !important;
}

.section.dark .vento {
  color: #f3d3a8 !important;
}

.section.dark a {
  color: #f0c060;
}

.section.dark a:hover,
.section.dark a:focus {
  color: #ffd78f;
}

.section.dark .compare-table tbody tr:hover td,
.section.dark .compare-table tbody tr:hover th,
.section.dark .compare-table tbody tr:focus-within td,
.section.dark .compare-table tbody tr:focus-within th {
  background: #f0dfc7;
  color: #1b0d04 !important;
}

.section.dark .compare-table tbody tr:hover .phm,
.section.dark .compare-table tbody tr:hover .vento,
.section.dark .compare-table tbody tr:focus-within .phm,
.section.dark .compare-table tbody tr:focus-within .vento {
  color: #1b0d04 !important;
}

.beta-banner {
  width: 100%;
  background: #1b0d04;
  color: #fff4e6;
  text-align: center;
  font-size: 0.9rem;
  line-height: 1.4;
  padding: 0.45rem 1rem;
  border-bottom: 1px solid rgba(240, 192, 96, 0.45);
  position: relative;
  z-index: 1100;
  top:70px;
}

.beta-intro-block{padding:6rem 0 0 0;width: 90vw;
  margin: 0 auto;}
.beta-intro-block {
  padding: 6rem 0 0 0;
}

.beta-intro-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
  align-items: stretch;
}

.beta-intro-card {
  background: var(--white);
  border: 1px solid var(--border);
  border-top: 3px solid var(--gold);
  border-radius: 12px;
  box-shadow: 0 12px 32px rgba(26, 14, 5, 0.06);
  min-height: 100%;
  transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}

.beta-intro-card:hover,
.beta-intro-card:focus-within {
  transform: translateY(-2px);
  box-shadow: 0 18px 40px rgba(26, 14, 5, 0.1);
  border-color: var(--border-dark);
}

.beta-intro-card-body {
  padding: 2rem;
}

.beta-intro-card h2 {
  font-family: var(--f-display);
  font-size: 1.5rem;
  line-height: 1.2;
  letter-spacing: -0.02em;
  color: var(--text);
  margin: 0 0 1rem 0;
}

.beta-intro-card p {
  font-size: 0.98rem;
  line-height: 1.82;
  color: var(--text-mid);
  margin: 0 0 1rem 0;
}

.beta-intro-card p:last-child {
  margin-bottom: 0;
}

.beta-intro-card a {
  color: var(--gold);
  text-decoration: underline;
  text-underline-offset: 3px;
  text-decoration-thickness: 1px;
}

.beta-intro-card a:hover,
.beta-intro-card a:focus-visible {
  color: var(--gold-bright);
}

@media (max-width: 1024px) {
  .beta-intro-grid {
    grid-template-columns: 1fr;
    gap: 20px;
  }

  .beta-intro-card-body {
    padding: 1.5rem;
  }

  .beta-intro-card h2 {
    font-size: 1.35rem;
  }
}

@media (max-width: 768px) {
  .beta-intro-block {
    padding: 6.5rem 0 0 0;
  }

  .beta-intro-grid {
    gap: 16px;
  }

  .beta-intro-card-body {
    padding: 1.25rem;
  }

  .beta-intro-card p {
    font-size: 0.95rem;
    line-height: 1.75;
  }
}

.row.g-6.pt-5.mt-4 {
  display: flex;
  flex-wrap: wrap;
  gap: 3rem 0;
  padding-top: 3rem;
  margin-top: 1.5rem;
  margin-left: -12px;
  margin-right: -12px;
}

.row.g-6.pt-5.mt-4 > .col-12.col-lg-6 {
  width: 100%;
  padding-left: 12px;
  padding-right: 12px;
}

.text-left {
  text-align: left;
}

.img-fluid {
  max-width: 100%;
  height: auto;
}

.row.g-6.pt-5.mt-4 iframe {
  display: block;
  width: 100%;
  max-width: 100%;
  height: 315px;
  border: 0;
  margin-bottom: 1.25rem;
}

.row.g-6.pt-5.mt-4 h2 {
  font-family: var(--f-display);
  font-size: 1.6rem;
  line-height: 1.2;
  letter-spacing: -0.02em;
  color: var(--text);
  margin: 0 0 0.85rem 0;
}

.row.g-6.pt-5.mt-4 p {
  font-size: 1rem;
  line-height: 1.8;
  color: var(--text-mid);
  margin: 0;
}

@media (min-width: 992px) {
  .row.g-6.pt-5.mt-4 > .col-12.col-lg-6 {
    width: 50%;
  }
}

@media (max-width: 768px) {
  .row.g-6.pt-5.mt-4 {
    padding-top: 2rem;
    margin-top: 1rem;
    gap: 2rem 0;
  }

  .row.g-6.pt-5.mt-4 iframe {
    height: 220px;
  }

  .row.g-6.pt-5.mt-4 h2 {
    font-size: 1.35rem;
  }

  .row.g-6.pt-5.mt-4 p {
    font-size: 0.95rem;
    line-height: 1.75;
  }
}