/* ========================================================================
   SHERIA SMART v10.1
   Editorial premium design language. Dark theme. Legal navy, ivory, brass.
   ======================================================================== */

:root {
  /* Canvas: deep ink-navy, the colour of a leather bound legal volume's spine. */
  --canvas:        #0a1628;
  --canvas-soft:   #0a1628;
  --canvas-warm:   #0f1e35;
  --canvas-raised: #1f3760;
  --surface:       #0f1e35;
  --surface-hi:    #1f3760;

  /* Ivory: the type colour against deep ink. Warm, never harsh white. */
  --ivory:         #FDF6E3;
  --ivory-soft:    rgba(253, 246, 227, 0.86);
  --ivory-mute:    rgba(253, 246, 227, 0.65);
  --ivory-faint:   rgba(253, 246, 227, 0.42);
  --ivory-trace:   rgba(253, 246, 227, 0.18);

  /* Brass: the accent, the colour of a senior advocate's reading lamp. */
  --brass:         #FBBF24;
  --brass-warm:    #FCD34D;
  --brass-deep:    #F59E0B;
  --brass-tint:    rgba(251, 191, 36, 0.14);
  --brass-glow:    rgba(251, 191, 36, 0.22);

  /* Subtle Kenyan flag whisper accents, used sparingly for typographic detail. */
  --whisper-green: #4F9D69;
  --whisper-red:   #C75D52;

  /* Hairlines and borders. */
  --rule:          rgba(253, 246, 227, 0.15);
  --rule-soft:     rgba(253, 246, 227, 0.09);
  --rule-faint:    rgba(253, 246, 227, 0.05);
  --rule-brass:    rgba(251, 191, 36, 0.32);

  /* Type. */
  --serif:  "Fraunces", "Iowan Old Style", Georgia, serif;
  --sans:   "Manrope", -apple-system, BlinkMacSystemFont, system-ui, sans-serif;

  /* Rhythm. */
  --gutter: clamp(24px, 5vw, 96px);
  --max-w:  1240px;
  --max-text: 720px;
  --max-prose: 680px;

  /* Depth. Cards lift off the ink canvas with brass-tinted shadows. */
  --shadow-card:
    0 1px 2px rgba(0, 0, 0, 0.30),
    0 8px 24px -4px rgba(0, 0, 0, 0.40),
    0 28px 60px -16px rgba(0, 0, 0, 0.45),
    inset 0 1px 0 rgba(253, 246, 227, 0.06);
  --shadow-card-hover:
    0 2px 4px rgba(0, 0, 0, 0.35),
    0 16px 40px -8px rgba(0, 0, 0, 0.50),
    0 48px 80px -20px rgba(251, 191, 36, 0.18),
    inset 0 1px 0 rgba(253, 246, 227, 0.10);
  --shadow-elev:
    0 4px 16px rgba(0, 0, 0, 0.35),
    inset 0 1px 0 rgba(253, 246, 227, 0.06);
}

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

html {
  background: var(--canvas);
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
}

body {
  font-family: var(--sans);
  font-weight: 400;
  font-size: 17px;
  line-height: 1.62;
  color: var(--ivory-soft);
  background: var(--canvas);
  background-image:
    radial-gradient(ellipse 70% 50% at 20% 0%, rgba(251, 191, 36, 0.08) 0%, transparent 60%),
    radial-gradient(ellipse 60% 40% at 90% 30%, rgba(31, 55, 96, 0.6) 0%, transparent 65%),
    radial-gradient(ellipse 50% 40% at 50% 100%, rgba(251, 191, 36, 0.05) 0%, transparent 70%);
  background-attachment: scroll; /* fixed causes GPU layer bugs on mobile Safari */
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  min-height: 100vh;
  overflow-x: hidden;
}

::selection { background: var(--brass-tint); color: var(--ivory); }

a { color: inherit; text-decoration: none; }

.wrap {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 0 var(--gutter);
}
.wrap-narrow {
  max-width: 880px;
  margin: 0 auto;
  padding: 0 var(--gutter);
}

/* ========================================================================
   NAV (dark, wordmark only)
   ======================================================================== */
.nav {
  position: sticky; top: 0; z-index: 100;
  background: rgba(10, 22, 40, 0.85);
  backdrop-filter: saturate(180%) blur(20px);
  -webkit-backdrop-filter: saturate(180%) blur(20px);
  border-bottom: 1px solid var(--rule-faint);
  padding: 18px 0;
}
.nav-inner { display: flex; align-items: center; justify-content: space-between; gap: 24px; }

.brand {
  display: inline-flex;
  align-items: center;
  gap: 14px;
  font-family: var(--serif);
  font-weight: 500;
  font-size: 22px;
  letter-spacing: -0.018em;
  color: var(--ivory);
  transition: color 0.2s;
}
.brand:hover { color: var(--brass-warm); }
.brand:hover .brand-mark {
  transform: translateY(-1px);
}
.brand-mark {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  width: 40px;
  height: 40px;
  transition: transform 0.25s cubic-bezier(0.2, 0.8, 0.2, 1);
}
.brand-mark img { width: 100%; height: 100%; object-fit: contain; display: block; }
.brand-mark svg, .brand-mark-svg {
  width: 100%;
  height: 100%;
  display: block;
}
.brand-wordmark {
  display: inline-flex;
  align-items: baseline;
  gap: 5px;
}
.brand em {
  font-style: italic;
  font-weight: 300;
  color: var(--brass);
}

.nav-center { display: flex; align-items: center; gap: 28px; }
.nav-link {
  font-family: var(--sans); font-size: 14.5px; font-weight: 500;
  color: var(--ivory-mute); transition: color 0.2s; position: relative;
}
.nav-link:hover { color: var(--ivory); }
.nav-link.active { color: var(--ivory); }
.nav-link.active::after,
.nav-link:hover::after {
  content: ""; position: absolute; bottom: -6px; left: 0; right: 0;
  height: 1px; background: var(--brass);
}

/* Language toggle pill */
.lang-toggle {
  display: inline-flex; align-items: center;
  background: rgba(253, 246, 227, 0.05);
  border: 1px solid var(--rule-soft);
  border-radius: 100px;
  padding: 3px;
  margin-left: 12px;
}
.lang-toggle a {
  font-family: var(--sans);
  font-size: 12px; font-weight: 500;
  letter-spacing: 0.04em;
  color: var(--ivory-mute);
  padding: 5px 11px;
  border-radius: 100px;
  transition: all 0.2s;
}
.lang-toggle a.active {
  background: var(--brass);
  color: var(--canvas);
  font-weight: 600;
}
.lang-toggle a:not(.active):hover { color: var(--ivory); }

.nav-cta {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 9px 18px;
  background: var(--brass);
  color: var(--canvas);
  border-radius: 100px;
  font-size: 14px; font-weight: 600; letter-spacing: 0.005em;
  transition: all 0.25s;
  box-shadow: 0 2px 12px rgba(251, 191, 36, 0.25);
}
.nav-cta:hover {
  background: var(--brass-warm);
  transform: translateY(-1px);
  box-shadow: 0 4px 16px rgba(251, 191, 36, 0.35);
}
.nav-cta svg { width: 14px; height: 14px; }

@media (max-width: 900px) { .nav-center .nav-link { display: none; } }
/* ========================================================================
   MOBILE SCROLL AND OVERLAP FIXES
   ======================================================================== */
/* Prevent iOS bounce/momentum scroll from causing compositing overlap */
html {
  -webkit-overflow-scrolling: touch;
}

/* Ensure the sticky nav does not overlap article content on scroll */
.section, .page-hero, article, .prose {
  scroll-margin-top: 80px;
}

@media (max-width: 600px) {
  .brand { font-size: 18px; gap: 10px; }
  .brand-mark { width: 34px; height: 34px; }
  .nav-cta { padding: 8px 14px; font-size: 13px; }
  .nav-cta svg { display: none; }
  .nav { padding: 14px 0; }
  .lang-toggle a { padding: 4px 9px; font-size: 11px; }
}

/* ========================================================================
   BUTTONS
   ======================================================================== */
.btn {
  display: inline-flex; align-items: center; gap: 10px;
  padding: 16px 26px;
  border-radius: 100px;
  font-family: var(--sans);
  font-size: 15.5px; font-weight: 500; letter-spacing: 0.005em;
  transition: all 0.25s cubic-bezier(0.2, 0.8, 0.2, 1);
  cursor: pointer;
  border: 1px solid transparent;
}
.btn-primary {
  background: var(--brass);
  color: var(--canvas);
  font-weight: 600;
  box-shadow: 0 4px 16px rgba(251, 191, 36, 0.30);
}
.btn-primary:hover {
  background: var(--brass-warm);
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(251, 191, 36, 0.40);
}
.btn-secondary {
  background: transparent;
  color: var(--ivory);
  border-color: var(--rule);
}
.btn-secondary:hover {
  background: rgba(253, 246, 227, 0.06);
  border-color: var(--ivory-mute);
  transform: translateY(-2px);
}
.btn-ghost {
  display: inline-flex; align-items: center; gap: 6px;
  background: transparent; color: var(--brass);
  font-size: 14.5px; font-weight: 500;
  padding: 8px 0;
}
.btn-ghost:hover { color: var(--brass-warm); gap: 10px; }
.btn-ghost::after { content: "→"; }
.btn svg { width: 16px; height: 16px; }

/* ========================================================================
   SECTION HEADERS
   ======================================================================== */
.section {
  padding: clamp(64px, 10vw, 120px) 0;
  position: relative;
  background-color: var(--canvas);
  isolation: isolate;
}
.section-tight {
  padding: clamp(48px, 7vw, 80px) 0;
  position: relative;
  background-color: var(--canvas);
  isolation: isolate;
}

.section-label {
  font-size: 12px; font-weight: 500; letter-spacing: 0.14em;
  text-transform: uppercase; color: var(--brass);
  margin-bottom: 16px;
  display: flex; align-items: center; gap: 12px;
}
.section-label::before {
  content: ""; width: 24px; height: 1px; background: var(--brass);
}
.section-label.center { justify-content: center; }
.section-label.center::before { display: none; }

h2.section-title, .section-title {
  font-family: var(--serif); font-weight: 400;
  font-size: clamp(32px, 4.2vw, 52px);
  line-height: 1.08; letter-spacing: -0.022em;
  color: var(--ivory); margin-bottom: 20px; max-width: 720px;
}
.section-title em { font-style: italic; color: var(--brass); font-weight: 300; }

.section-lede {
  font-size: clamp(16px, 1.4vw, 18.5px); line-height: 1.6;
  color: var(--ivory-soft); max-width: 640px; margin-bottom: 56px;
}

/* ========================================================================
   PAGE HERO
   ======================================================================== */
.page-hero {
  padding: clamp(80px, 12vw, 140px) 0 clamp(48px, 8vw, 80px);
  text-align: center; position: relative;
}
.page-hero::before {
  content: ""; position: absolute; top: 0; left: 50%;
  transform: translateX(-50%);
  width: min(900px, 80vw); height: 400px;
  background: radial-gradient(ellipse, rgba(251, 191, 36, 0.14) 0%, transparent 70%);
  pointer-events: none;
  z-index: -1; /* ensure it stays behind content, never above */
}
.page-hero {
  overflow: hidden; /* contain the absolute pseudo-element */
}
.page-hero-inner { position: relative; }
.page-hero h1 {
  font-family: var(--serif); font-weight: 400;
  font-size: clamp(38px, 5.2vw, 72px);
  line-height: 1.06; letter-spacing: -0.022em;
  color: var(--ivory); margin-bottom: 24px;
  max-width: 920px; margin-left: auto; margin-right: auto;
}
.page-hero h1 em { font-style: italic; color: var(--brass); font-weight: 300; }
.page-hero .lede {
  font-size: clamp(17px, 1.6vw, 20px); line-height: 1.6;
  color: var(--ivory-soft); max-width: 640px; margin: 0 auto;
}
.eyebrow {
  display: inline-flex; align-items: center; gap: 10px;
  font-size: 12px; font-weight: 500; letter-spacing: 0.12em;
  text-transform: uppercase; color: var(--brass);
  margin-bottom: 28px; padding: 7px 16px;
  background: var(--brass-tint);
  border: 1px solid var(--rule-brass);
  border-radius: 100px;
}
.eyebrow-dot {
  width: 6px; height: 6px; border-radius: 50%;
  background: var(--brass); box-shadow: 0 0 0 4px rgba(251, 191, 36, 0.25);
}

/* ========================================================================
   COMPLIANCE STRIP (compact disclosure ribbon)
   ======================================================================== */
.compliance-strip {
  display: inline-flex; align-items: center; gap: 14px;
  margin: 0 auto;
  padding: 14px 24px;
  background: rgba(15, 30, 53, 0.6);
  border: 1px solid var(--rule-soft);
  border-radius: 100px;
  font-size: 14px;
  color: var(--ivory-soft);
}
.compliance-strip .pin {
  width: 8px; height: 8px;
  border-radius: 50%;
  background: var(--whisper-green);
  box-shadow: 0 0 0 4px rgba(79, 157, 105, 0.20);
  flex-shrink: 0;
}
.compliance-strip strong { color: var(--ivory); font-weight: 600; }

.compliance-strip-wrap {
  text-align: center;
  padding: 8px 0 0;
}

/* ========================================================================
   ARTICLE / PROSE
   ======================================================================== */
.prose {
  max-width: var(--max-prose);
  margin: 0 auto;
  color: var(--ivory-soft);
}
.prose p, .prose ul, .prose ol, .prose blockquote {
  font-size: 17.5px;
  line-height: 1.72;
  color: var(--ivory-soft);
  margin-bottom: 22px;
}
.prose p strong, .prose li strong { color: var(--ivory); font-weight: 600; }
.prose ul, .prose ol { padding-left: 24px; }
.prose li { margin-bottom: 10px; }
.prose li::marker { color: var(--brass); }

.prose h2 {
  font-family: var(--serif); font-weight: 500;
  font-size: clamp(26px, 3vw, 34px);
  line-height: 1.15; letter-spacing: -0.018em;
  color: var(--ivory);
  margin: 56px 0 16px;
}
.prose h2 em { font-style: italic; color: var(--brass); font-weight: 400; }
.prose h3 {
  font-family: var(--serif); font-weight: 500;
  font-size: 22px; line-height: 1.25; letter-spacing: -0.012em;
  color: var(--ivory);
  margin: 36px 0 12px;
}
.prose a {
  color: var(--brass);
  border-bottom: 1px solid var(--rule-brass);
  transition: all 0.2s;
}
.prose a:hover { color: var(--brass-warm); border-bottom-color: var(--brass); }

.prose blockquote {
  font-family: var(--serif); font-style: italic;
  font-size: 22px; line-height: 1.45;
  color: var(--ivory);
  padding: 4px 0 4px 24px;
  border-left: 3px solid var(--brass);
  margin: 32px 0;
}

.prose .legal-block {
  background: var(--surface);
  border: 1px solid var(--rule-soft);
  border-radius: 12px;
  padding: 20px 24px;
  font-family: var(--sans);
  font-style: normal;
  font-size: 15.5px;
  line-height: 1.55;
  color: var(--ivory-soft);
  margin: 24px 0;
}

.prose .lede-first {
  font-size: 19.5px;
  line-height: 1.6;
  color: var(--ivory);
}
.prose .lede-first::first-letter {
  font-family: var(--serif); font-weight: 500;
  font-size: 4em;
  float: left;
  line-height: 0.88;
  margin: 6px 12px 0 0;
  color: var(--brass);
}

.byline {
  display: block;
  margin: 48px 0 32px;
  padding: 18px 0 4px;
  border-top: 1px solid var(--rule-soft);
  font-size: 14px;
  letter-spacing: 0.01em;
  color: var(--ivory-mute);
}
.byline strong { color: var(--ivory); font-weight: 600; }

/* ========================================================================
   CARDS (general purpose, dark surfaces)
   ======================================================================== */
.card {
  position: relative;
  background: var(--surface);
  border: 1px solid var(--rule-soft);
  border-radius: 18px;
  padding: 28px;
  box-shadow: var(--shadow-card);
  transition: all 0.3s cubic-bezier(0.2, 0.8, 0.2, 1);
}
.card:hover {
  transform: translateY(-4px);
  border-color: var(--rule-brass);
  box-shadow: var(--shadow-card-hover);
}
.card h3 {
  font-family: var(--serif); font-weight: 500;
  font-size: 22px; line-height: 1.2; letter-spacing: -0.015em;
  color: var(--ivory); margin-bottom: 12px;
}
.card h3 em { font-style: italic; color: var(--brass); font-weight: 300; }
.card p {
  font-size: 15px; line-height: 1.6;
  color: var(--ivory-soft);
}
.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
@media (max-width: 760px) {
  .grid-2, .grid-3 { grid-template-columns: 1fr; gap: 16px; }
}

/* ========================================================================
   CTA BAND (reusable, brass-glow on deep navy)
   ======================================================================== */
.cta-band {
  background: linear-gradient(135deg, var(--canvas-warm) 0%, var(--canvas-raised) 100%);
  border: 1px solid var(--rule-brass);
  color: var(--ivory);
  border-radius: 24px;
  padding: clamp(48px, 8vw, 80px) clamp(28px, 6vw, 64px);
  text-align: center;
  position: relative; overflow: hidden; isolation: isolate;
  margin: clamp(48px, 7vw, 80px) 0;
  box-shadow: var(--shadow-card);
}
.cta-band::before {
  content: ""; position: absolute; inset: 0;
  background:
    radial-gradient(ellipse 60% 50% at 20% 0%, rgba(251, 191, 36, 0.22) 0%, transparent 60%),
    radial-gradient(ellipse 50% 40% at 80% 100%, rgba(251, 191, 36, 0.16) 0%, transparent 70%);
  z-index: -1;
}
.cta-band h2 {
  font-family: var(--serif); font-weight: 400;
  font-size: clamp(30px, 4vw, 48px);
  line-height: 1.1; letter-spacing: -0.022em;
  color: var(--ivory); margin-bottom: 16px;
}
.cta-band h2 em { font-style: italic; color: var(--brass); font-weight: 300; }
.cta-band p {
  font-size: 17px; color: var(--ivory-soft);
  max-width: 560px; margin: 0 auto 32px;
}
.cta-row {
  display: flex; gap: 14px; justify-content: center; flex-wrap: wrap;
}

/* ========================================================================
   FOOTER (deep ink with brass accents)
   ======================================================================== */
.footer {
  background: #050D1A;
  color: var(--ivory-mute);
  padding: 72px 0 32px;
  font-size: 14px;
  border-top: 1px solid var(--rule-faint);
}
.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr repeat(3, 1fr);
  gap: 56px; margin-bottom: 56px;
}
@media (max-width: 760px) {
  .footer-grid { grid-template-columns: 1fr 1fr; gap: 36px; }
}
.footer-brand .brand { color: var(--ivory); margin-bottom: 16px; }
.footer-tagline {
  font-family: var(--serif); font-style: italic;
  font-size: 16px; color: var(--ivory-mute);
  max-width: 280px; line-height: 1.5;
}
.footer-col h4 {
  font-size: 12px; font-weight: 600; letter-spacing: 0.14em;
  text-transform: uppercase; color: var(--brass);
  margin-bottom: 18px;
}
.footer-col ul { list-style: none; display: flex; flex-direction: column; gap: 12px; }
.footer-col a {
  color: var(--ivory-mute); transition: color 0.2s; font-size: 14px;
}
.footer-col a:hover { color: var(--ivory); }

.footer-legal {
  border-top: 1px solid var(--rule-faint);
  padding-top: 24px;
  font-size: 11px; line-height: 1.6;
  color: rgba(254, 249, 232, 0.32);
  letter-spacing: 0.005em;
}
.footer-legal p { margin-bottom: 10px; }
.footer-legal p:last-child { margin-bottom: 0; }
.footer-legal strong { color: rgba(254, 249, 232, 0.55); font-weight: 500; }
.footer-bottom {
  margin-top: 20px;
  display: flex; justify-content: space-between; align-items: center;
  flex-wrap: wrap; gap: 12px;
  font-size: 10.5px; color: rgba(254, 249, 232, 0.30);
  letter-spacing: 0.01em;
}

/* ========================================================================
   UTILITIES
   ======================================================================== */
.center { text-align: center; }
.flex-row { display: flex; gap: 14px; flex-wrap: wrap; }
.flex-row.center-row { justify-content: center; }
.rule {
  width: 60px; height: 1px; background: var(--brass);
  margin: 32px auto;
}

.article-meta {
  display: flex; flex-wrap: wrap; gap: 16px;
  font-size: 13px; color: var(--ivory-mute);
  letter-spacing: 0.01em;
  margin-top: 24px;
}
.article-meta-item {
  display: inline-flex; align-items: center; gap: 6px;
}
.article-meta-item svg { width: 14px; height: 14px; color: var(--brass); }
.article-meta-divider {
  width: 4px; height: 4px; border-radius: 50%;
  background: var(--rule); align-self: center;
}

.tag {
  display: inline-flex; align-items: center;
  padding: 5px 12px;
  background: var(--brass-tint); color: var(--brass);
  border: 1px solid var(--rule-brass);
  border-radius: 100px;
  font-size: 11.5px; font-weight: 500;
  letter-spacing: 0.08em; text-transform: uppercase;
}

@keyframes rise {
  from { opacity: 0; transform: translateY(20px); }
  to   { opacity: 1; transform: translateY(0); }
}
.reveal-1 { opacity: 0; animation: rise 1.0s 0.10s cubic-bezier(0.2, 0.8, 0.2, 1) forwards; isolation: isolate; }
.reveal-2 { opacity: 0; animation: rise 1.0s 0.25s cubic-bezier(0.2, 0.8, 0.2, 1) forwards; isolation: isolate; }
.reveal-3 { opacity: 0; animation: rise 1.0s 0.45s cubic-bezier(0.2, 0.8, 0.2, 1) forwards; isolation: isolate; }
.reveal-4 { opacity: 0; animation: rise 1.0s 0.65s cubic-bezier(0.2, 0.8, 0.2, 1) forwards; isolation: isolate; }
.reveal-5 { opacity: 0; animation: rise 1.0s 0.85s cubic-bezier(0.2, 0.8, 0.2, 1) forwards; isolation: isolate; }

/* On mobile, disable the entrance animation entirely — just show content.
   The translateY start position is the primary cause of scroll overlap on
   narrow screens where content paints before the animation resolves. */
@media (max-width: 760px) {
  .reveal-1, .reveal-2, .reveal-3, .reveal-4, .reveal-5 {
    opacity: 1;
    animation: none;
    transform: none;
  }
}

/* Respect user preference for reduced motion */
@media (prefers-reduced-motion: reduce) {
  .reveal-1, .reveal-2, .reveal-3, .reveal-4, .reveal-5 {
    opacity: 1;
    animation: none;
    transform: none;
  }
}

/* ========================================================================
   LOGO PLACEMENTS — strategic spots beyond the nav and footer
   ======================================================================== */

/* Hero centred mark: appears above the eyebrow chip on the home page only */
.hero-mark {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 96px;
  height: 96px;
  margin-bottom: 28px;
  opacity: 0;
  animation: rise 1.0s 0s cubic-bezier(0.2, 0.8, 0.2, 1) forwards;
}
.hero-mark img { width: 100%; height: 100%; object-fit: contain; display: block; }
.hero-mark svg { width: 100%; height: 100%; display: block; }

/* 404 background mark: large faded mark behind the page number */
.notfound-mark {
  position: absolute;
  top: 50%; left: 50%;
  transform: translate(-50%, -50%);
  font-family: var(--serif);
  font-style: italic;
  font-weight: 300;
  font-size: clamp(280px, 50vw, 520px);
  line-height: 1;
  color: var(--brass);
  opacity: 0.04;
  letter-spacing: -0.08em;
  z-index: 0;
  pointer-events: none;
  user-select: none;
}

/* Byline mark: small italic S beside the editorial team attribution */
.byline-mark {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 22px; height: 22px;
  margin-right: 4px;
  vertical-align: -5px;
}
.byline-mark img { width: 100%; height: 100%; object-fit: contain; display: block; }
.byline-mark svg { width: 100%; height: 100%; display: block; }

/* Founder signature mark: above the Dr. Jan Law byline */
.founder-mark {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px; height: 32px;
  margin-bottom: 14px;
}
.founder-mark img { width: 100%; height: 100%; object-fit: contain; display: block; }
.founder-mark svg { width: 100%; height: 100%; display: block; }

/* ========================================================================
   Z-INDEX STACKING FIX — prevents reveal-animated cards from overlapping
   prose content during scroll on mobile
   ======================================================================== */
.prose, .page-hero, .page-hero-inner, .wrap-narrow > p, .wrap-narrow > h1 {
  position: relative;
  z-index: 1;
}
.briefing-card, .section-label, .eyebrow {
  position: relative;
  z-index: 0;
}

/* ========================================================================
   MOBILE SECTION ISOLATION — prevents GPU layer bleed during scroll
   ======================================================================== */
@media (max-width: 900px) {
  body {
    background-attachment: scroll;
    background-image: none; /* remove fixed gradient on mobile to prevent compositing issues */
    background-color: var(--canvas);
  }
  .section, .section-tight {
    overflow: hidden;
    transform: translateZ(0); /* force own GPU layer */
  }
  .page-hero {
    overflow: hidden;
    transform: translateZ(0);
  }
}

/* ========================================================================
   RESPONSIVE GRID FIXES — all inline grids that need mobile collapse
   ======================================================================== */
@media (max-width: 760px) {
  .install-steps-grid {
    grid-template-columns: 1fr !important;
    gap: 20px !important;
  }
  .feature-tiles {
    grid-template-columns: 1fr !important;
  }
}

/* ===== daily quote, online dot, visitor count ===== */
.daily-quote {
  max-width: 600px;
  margin: 22px auto 0;
  text-align: center;
  font-family: var(--serif);
  color: var(--ivory);
  opacity: 0.92;
}
.daily-quote .dq-text { display: block; font-size: clamp(15px, 1.7vw, 18px); font-style: italic; line-height: 1.5; }
.daily-quote .dq-author { display: block; margin-top: 8px; font-size: 12px; letter-spacing: 0.08em; text-transform: uppercase; color: var(--gold, #C89B3C); font-family: var(--sans, sans-serif); font-style: normal; }
.status-dot {
  display: inline-flex; align-items: center; gap: 8px;
  font-size: 12px; letter-spacing: 0.06em; text-transform: uppercase;
  color: #9fb3a6; font-weight: 600;
}
.status-dot::before {
  content: ""; width: 9px; height: 9px; border-radius: 50%;
  background: #2ecc71; box-shadow: 0 0 0 0 rgba(46, 204, 113, 0.55);
  animation: statusPulse 2s infinite;
}
@keyframes statusPulse {
  0% { box-shadow: 0 0 0 0 rgba(46, 204, 113, 0.5); }
  70% { box-shadow: 0 0 0 8px rgba(46, 204, 113, 0); }
  100% { box-shadow: 0 0 0 0 rgba(46, 204, 113, 0); }
}
.visit-wrap { font-size: 12px; color: var(--muted, #8a93a6); letter-spacing: 0.04em; }
.visit-wrap b { color: var(--gold, #C89B3C); font-weight: 700; }

/* ===== contact form ===== */
.contact-form { max-width: 620px; margin: 0 auto; }
.contact-form .cf-row { display: flex; gap: 16px; }
.contact-form .cf-row .cf-field { flex: 1; }
@media (max-width: 640px) { .contact-form .cf-row { flex-direction: column; gap: 0; } }
.cf-field { margin-bottom: 18px; }
.cf-field label { display: block; font-size: 13px; letter-spacing: 0.03em; color: var(--ivory); margin-bottom: 7px; font-weight: 600; }
.cf-field input, .cf-field textarea {
  width: 100%; box-sizing: border-box;
  background: rgba(15, 23, 42, 0.6);
  border: 1px solid var(--rule-soft, rgba(255,255,255,0.12));
  border-radius: 10px; padding: 13px 15px;
  color: var(--ivory); font-size: 15px; font-family: inherit;
  transition: border-color 0.2s, box-shadow 0.2s;
}
.cf-field input:focus, .cf-field textarea:focus {
  outline: none; border-color: var(--gold, #C89B3C);
  box-shadow: 0 0 0 3px rgba(196,146,42,0.15);
}
.cf-field textarea { min-height: 150px; resize: vertical; }
.cf-hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.cf-status { margin-top: 14px; font-size: 14px; line-height: 1.6; min-height: 20px; }
.cf-status.ok { color: #6fcf97; }
.cf-status.err { color: #e0a; }
.cf-note { margin-top: 18px; font-size: 12px; color: var(--text-muted, #8a93a6); line-height: 1.6; }
.contact-meta { text-align: center; margin-bottom: 30px; color: var(--text-muted); font-size: 14px; }
.contact-meta a { color: var(--gold, #C89B3C); text-decoration: none; }
