/*
Theme Name: TVIAH — Strategically Confident
Theme URI: https://tviah.com
Author: TVIAH
Author URI: https://tviah.com
Description: A refined, editorial WordPress theme for TVIAH | Strategically Confident™ — a thought platform on how confidence is built, sustained, and expressed through alignment, language, and structure. Typography-led, warm-paper palette, structural grid motif. Classic theme; edit the front page copy in front-page.php.
Version: 2.1.1
Requires at least: 6.0
Tested up to: 6.5
Requires PHP: 7.4
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: tviah
Tags: editorial, minimal, business, one-page, custom-logo, custom-menu, threaded-comments, translation-ready
*/

/* =========================================================
   TVIAH — Design tokens
   Confidence, by design. Structure is the visual spine:
   thin rules, a two-column alignment grid, numbered sections.
   ========================================================= */
:root {
  --paper:      #F4F0E8;   /* warm bone */
  --paper-deep: #ECE6DA;   /* slightly recessed panels */
  --ink:        #1B1A16;   /* near-black, warm */
  --ink-soft:   #46423A;   /* secondary text */
  --muted:      #8B8576;   /* labels, meta */
  --line:       rgba(27, 26, 22, 0.16);
  --line-soft:  rgba(27, 26, 22, 0.08);
  --accent:     #9E4226;   /* deep clay — used sparingly */
  --accent-ink: #7E3219;

  --maxw: 1180px;
  --gutter: clamp(1.25rem, 5vw, 4rem);

  --serif: "Fraunces", Georgia, "Times New Roman", serif;
  --sans:  "Hanken Grotesk", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;

  --step--1: clamp(0.82rem, 0.78rem + 0.2vw, 0.9rem);
  --step-0:  clamp(1rem, 0.95rem + 0.25vw, 1.125rem);
  --step-1:  clamp(1.2rem, 1.1rem + 0.5vw, 1.45rem);
  --step-2:  clamp(1.6rem, 1.35rem + 1.1vw, 2.3rem);
  --step-3:  clamp(2.2rem, 1.7rem + 2.4vw, 3.6rem);
  --step-4:  clamp(3rem, 2rem + 4.6vw, 6.5rem);
}

/* =========================================================
   Reset / base
   ========================================================= */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--sans);
  font-size: var(--step-0);
  font-weight: 400;
  line-height: 1.65;
  letter-spacing: 0.005em;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  /* faint grain/texture for paper depth */
  background-image:
    radial-gradient(rgba(27,26,22,0.025) 1px, transparent 1px);
  background-size: 3px 3px;
}

img { max-width: 100%; height: auto; display: block; }
a { color: inherit; text-decoration: none; }

h1, h2, h3, h4 {
  font-family: var(--serif);
  font-weight: 380;
  font-optical-sizing: auto;
  letter-spacing: -0.015em;
  line-height: 1.08;
  margin: 0;
}

p { margin: 0 0 1.1em; }
p:last-child { margin-bottom: 0; }

::selection { background: var(--accent); color: var(--paper); }

/* =========================================================
   Layout primitives
   ========================================================= */
.wrap {
  width: 100%;
  max-width: var(--maxw);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

/* The structural two-column grid: a label rail + content.
   This alignment IS the brand motif. */
.row {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 1.5rem 3rem;
}
@media (min-width: 880px) {
  .row { grid-template-columns: 16rem minmax(0, 1fr); gap: 0 4rem; }
}

.section {
  padding-block: clamp(4rem, 9vw, 8.5rem);
  border-top: 1px solid var(--line);
}

/* Section label: number + small-caps title, sits in the rail */
.rail { position: relative; }
.rail .index {
  font-family: var(--serif);
  font-size: var(--step-1);
  font-weight: 360;
  font-variant-numeric: lining-nums;
  color: var(--accent);
  display: block;
  margin-bottom: 0.4rem;
}
.rail .label {
  font-family: var(--sans);
  font-size: var(--step--1);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.22em;
  color: var(--muted);
}
@media (min-width: 880px) {
  .rail { position: sticky; top: 2.5rem; align-self: start; }
}

/* =========================================================
   Header / nav
   ========================================================= */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: color-mix(in srgb, var(--paper) 88%, transparent);
  backdrop-filter: saturate(140%) blur(8px);
  border-bottom: 1px solid var(--line-soft);
}
.site-header .bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  min-height: 4.5rem;
}
.brand {
  font-family: var(--serif);
  font-weight: 420;
  font-size: 1.25rem;
  letter-spacing: 0.32em;
  text-indent: 0.32em;
}
.brand .tm { font-size: 0.55em; vertical-align: super; letter-spacing: 0; }
.brand img { max-height: 38px; width: auto; }

.nav { display: flex; gap: clamp(1rem, 3vw, 2.25rem); align-items: center; }
.nav ul { display: flex; gap: clamp(1rem, 3vw, 2.25rem); list-style: none; margin: 0; padding: 0; }
.nav a {
  font-size: var(--step--1);
  letter-spacing: 0.12em;
  text-transform: uppercase;
  font-weight: 500;
  color: var(--ink-soft);
  position: relative;
  padding-block: 0.25rem;
}
.nav a::after {
  content: "";
  position: absolute; left: 0; bottom: 0;
  width: 0; height: 1px; background: var(--accent);
  transition: width 0.4s cubic-bezier(0.2, 0.7, 0.2, 1);
}
.nav a:hover::after, .nav .current-menu-item > a::after { width: 100%; }

.nav-toggle { display: none; }

@media (max-width: 720px) {
  .nav-toggle {
    display: inline-flex; align-items: center; gap: 0.5rem;
    background: none; border: 1px solid var(--line); border-radius: 999px;
    padding: 0.4rem 0.9rem; font-family: var(--sans); font-size: var(--step--1);
    letter-spacing: 0.16em; text-transform: uppercase; color: var(--ink); cursor: pointer;
  }
  .nav {
    position: absolute; inset: 100% 0 auto 0;
    flex-direction: column; align-items: flex-start;
    background: var(--paper); border-bottom: 1px solid var(--line);
    padding: 1rem var(--gutter) 1.5rem;
    max-height: 0; overflow: hidden; transition: max-height 0.4s ease, padding 0.4s ease;
    padding-block: 0;
  }
  .nav ul { flex-direction: column; gap: 0.85rem; width: 100%; }
  .site-header[data-open="true"] .nav { max-height: 60vh; padding-block: 1rem 1.5rem; }
}

/* =========================================================
   Hero
   ========================================================= */
.hero {
  padding-block: clamp(5rem, 13vw, 11rem) clamp(4rem, 9vw, 8rem);
  position: relative;
  overflow: hidden;
}
.hero .eyebrow {
  font-size: var(--step--1);
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: var(--muted);
  font-weight: 600;
  margin-bottom: clamp(1.5rem, 4vw, 2.5rem);
}
.hero .eyebrow .tm { letter-spacing: 0; }
.hero h1 {
  font-size: var(--step-4);
  font-weight: 340;
  line-height: 0.98;
  letter-spacing: -0.03em;
  max-width: 16ch;
}
.hero h1 em {
  font-style: italic;
  font-variation-settings: "SOFT" 40;
  color: var(--accent);
}
.hero .lede {
  margin-top: clamp(1.75rem, 5vw, 3rem);
  max-width: 48ch;
  font-size: var(--step-1);
  font-weight: 360;
  line-height: 1.5;
  color: var(--ink-soft);
  font-family: var(--serif);
}
.hero .cue {
  margin-top: clamp(3rem, 8vw, 5.5rem);
  display: inline-flex; align-items: center; gap: 0.75rem;
  font-size: var(--step--1); letter-spacing: 0.2em; text-transform: uppercase;
  color: var(--muted); font-weight: 600;
}
.hero .cue .line { width: 3rem; height: 1px; background: var(--ink); display: inline-block; transform-origin: left; }

/* big faint structural marks behind hero — alignment motif */
.hero::before {
  content: "";
  position: absolute; top: 0; bottom: 0; right: clamp(2rem, 16vw, 14rem);
  width: 1px; background: var(--line-soft);
  pointer-events: none;
}

/* ---- Masthead background video ---- */
.hero.has-video {
  min-height: clamp(600px, 90vh, 880px);
  display: flex;
  align-items: center;
  color: var(--paper);
}
.hero.has-video::before { display: none; }
.hero-media {
  position: absolute; inset: 0; z-index: 0;
  overflow: hidden; background: var(--ink);
}
.hero-video {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  object-fit: cover;
}
.hero-veil {
  position: absolute; inset: 0; pointer-events: none;
  background: linear-gradient(
    to bottom,
    rgba(20, 19, 16, calc(var(--veil, 0.55) * 0.6)) 0%,
    rgba(20, 19, 16, var(--veil, 0.55)) 70%,
    rgba(20, 19, 16, calc(var(--veil, 0.55) + 0.08)) 100%
  );
}
.hero.has-video .wrap { position: relative; z-index: 1; }
.hero.has-video .eyebrow { color: rgba(244, 240, 232, 0.78); }
.hero.has-video h1 { color: var(--paper); }
.hero.has-video h1 em { color: #E9B295; }
.hero.has-video .lede { color: rgba(244, 240, 232, 0.92); }
.hero.has-video .cue { color: rgba(244, 240, 232, 0.82); }
.hero.has-video .cue .line { background: var(--paper); }

/* =========================================================
   Content blocks
   ========================================================= */
.lead-statement {
  font-family: var(--serif);
  font-size: var(--step-2);
  font-weight: 340;
  line-height: 1.28;
  letter-spacing: -0.015em;
  max-width: 24ch;
}
.prose p { max-width: 60ch; }
.prose p + p { margin-top: 1.2em; }
.prose .big {
  font-family: var(--serif);
  font-size: var(--step-1);
  line-height: 1.45;
  color: var(--ink);
  font-weight: 360;
  margin-bottom: 1.4em;
}

/* Focus list — aligned, numbered, structural */
.focus-list { list-style: none; margin: 0; padding: 0; }
.focus-list li {
  display: grid;
  grid-template-columns: 3.5rem 1fr;
  gap: 0 1.25rem;
  align-items: baseline;
  padding-block: clamp(1.1rem, 2.5vw, 1.6rem);
  border-top: 1px solid var(--line-soft);
  font-family: var(--serif);
  font-size: var(--step-1);
  font-weight: 350;
  line-height: 1.35;
}
.focus-list li:last-child { border-bottom: 1px solid var(--line-soft); }
.focus-list .n {
  font-family: var(--sans);
  font-size: var(--step--1);
  font-weight: 600;
  letter-spacing: 0.1em;
  color: var(--accent);
  font-variant-numeric: tabular-nums;
  padding-top: 0.45em;
}

/* Values grid — Who this is for */
.values {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 16rem), 1fr));
  gap: 1px;
  background: var(--line-soft);
  border: 1px solid var(--line-soft);
}
.values .v {
  background: var(--paper);
  padding: clamp(1.5rem, 4vw, 2.4rem);
  display: flex; flex-direction: column; gap: 0.6rem;
  transition: background 0.4s ease;
}
.values .v:hover { background: var(--paper-deep); }
.values .v .vn {
  font-family: var(--sans); font-size: var(--step--1); font-weight: 600;
  letter-spacing: 0.1em; color: var(--accent); font-variant-numeric: tabular-nums;
}
.values .v p {
  font-family: var(--serif); font-size: var(--step-1); font-weight: 350;
  line-height: 1.3; margin: 0;
}

/* Closing line — full bleed statement */
.closing {
  background: var(--ink);
  color: var(--paper);
  border-top: none;
}
.closing::selection { background: var(--accent); }
.closing .label { color: rgba(244, 240, 232, 0.55); }
.closing .index { color: var(--accent); }
.closing .statement {
  font-family: var(--serif);
  font-size: var(--step-3);
  font-weight: 320;
  line-height: 1.12;
  letter-spacing: -0.02em;
  max-width: 18ch;
}
.closing .statement em { font-style: italic; color: var(--accent); }
.closing .sub {
  margin-top: clamp(1.5rem, 4vw, 2.25rem);
  font-family: var(--sans);
  font-size: var(--step-0);
  color: rgba(244, 240, 232, 0.7);
  max-width: 44ch;
}

/* =========================================================
   The Three Lanes — homepage cards
   ========================================================= */
.lanes {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1px;
  background: var(--line-soft);
  border: 1px solid var(--line-soft);
}
@media (min-width: 820px) { .lanes { grid-template-columns: repeat(3, 1fr); } }

.lane-card {
  background: var(--paper);
  padding: clamp(1.75rem, 3vw, 2.5rem);
  display: flex;
  flex-direction: column;
  gap: 0.7rem;
  position: relative;
  scroll-margin-top: 6rem;
  transition: background 0.45s ease, transform 0.45s cubic-bezier(0.2,0.7,0.2,1);
  border-top: 3px solid var(--lane, var(--accent));
}
.lane-card:hover { background: var(--paper-deep); }
.lane-dot {
  width: 12px; height: 12px; border-radius: 50%;
  background: var(--lane, var(--accent)); margin-bottom: 0.4rem;
}
.lane-name {
  font-family: var(--serif);
  font-size: var(--step-2);
  font-weight: 360;
  letter-spacing: -0.015em;
}
.lane-essence {
  font-family: var(--sans);
  font-size: var(--step--1);
  letter-spacing: 0.12em;
  text-transform: uppercase;
  font-weight: 600;
  color: var(--lane, var(--accent));
}
.lane-desc {
  color: var(--ink-soft);
  font-size: var(--step-0);
  line-height: 1.6;
  flex: 1;
}
.lane-go {
  margin-top: 0.6rem;
  font-size: var(--step--1);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  font-weight: 600;
  color: var(--ink);
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
}
.lane-go span { transition: transform 0.35s cubic-bezier(0.2,0.7,0.2,1); color: var(--lane, var(--accent)); }
.lane-card:hover .lane-go span { transform: translateX(5px); }

/* =========================================================
   Lane pages (template-live / lead / legacy)
   ========================================================= */
.lane-hero {
  padding-block: clamp(4.5rem, 11vw, 9rem) clamp(3rem, 7vw, 6rem);
  position: relative;
  border-bottom: 1px solid var(--line-soft);
}
.lane-hero::before {
  content: "";
  position: absolute; left: 0; top: 0; bottom: 0;
  width: 4px; background: var(--lane, var(--accent));
}
.lane-hero .eyebrow {
  font-size: var(--step--1); letter-spacing: 0.28em; text-transform: uppercase;
  color: var(--muted); font-weight: 600; margin-bottom: clamp(1.25rem, 3vw, 2rem);
}
.lane-hero h1 {
  font-size: var(--step-4);
  font-weight: 340;
  line-height: 0.98;
  letter-spacing: -0.03em;
  color: var(--lane, var(--ink));
}
.lane-hero .lane-essence {
  margin-top: 1rem;
  font-size: var(--step-1);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  font-weight: 600;
  color: var(--ink-soft);
}
.lane-hero .lede {
  margin-top: clamp(1.5rem, 4vw, 2.5rem);
  max-width: 52ch;
  font-size: var(--step-1);
  font-weight: 360;
  line-height: 1.5;
  color: var(--ink-soft);
  font-family: var(--serif);
}
.lane-index { color: var(--lane, var(--accent)) !important; }
.lane-list .n { color: var(--lane, var(--accent)); }
.lane-close {
  font-family: var(--serif);
  font-size: var(--step-1);
  font-style: italic;
  color: var(--lane, var(--accent));
  max-width: 40ch;
}

.lane-switch { border-top: 1px solid var(--line); }
.lane-switch-grid { display: grid; gap: 1px; background: var(--line-soft); border: 1px solid var(--line-soft); grid-template-columns: 1fr; }
@media (min-width: 680px) { .lane-switch-grid { grid-template-columns: 1fr 1fr; } }
.lane-switch-card {
  background: var(--paper);
  padding: clamp(1.5rem, 3vw, 2.25rem);
  display: flex; flex-direction: column; gap: 0.55rem;
  border-top: 3px solid var(--lane, var(--accent));
  transition: background 0.4s ease;
}
.lane-switch-card:hover { background: var(--paper-deep); }
.lane-switch-card .lsc-dot { width: 11px; height: 11px; border-radius: 50%; background: var(--lane, var(--accent)); }
.lane-switch-card .lsc-name { font-family: var(--serif); font-size: var(--step-2); font-weight: 360; }
.lane-switch-card .lsc-essence { font-size: var(--step--1); letter-spacing: 0.12em; text-transform: uppercase; font-weight: 600; color: var(--muted); }
.lane-switch-card .lsc-go { margin-top: 0.4rem; font-size: var(--step--1); letter-spacing: 0.1em; text-transform: uppercase; font-weight: 600; color: var(--lane, var(--accent)); }

/* =========================================================
   Events — list-style calendar
   ========================================================= */
.events-list { list-style: none; margin: 0; padding: 0; }
.event {
  display: grid;
  grid-template-columns: 5.5rem 1fr;
  gap: 0 clamp(1.25rem, 3vw, 2.25rem);
  padding: clamp(1.4rem, 3vw, 2rem) 0 clamp(1.4rem, 3vw, 2rem) clamp(1rem, 2vw, 1.5rem);
  border-top: 1px solid var(--line-soft);
  border-left: 3px solid var(--lane, var(--accent));
  scroll-margin-top: 6rem;
}
.event:last-child { border-bottom: 1px solid var(--line-soft); }

.event-date {
  display: flex; flex-direction: column; align-items: flex-start; line-height: 1;
  padding-top: 0.2rem;
}
.event-date .ev-month {
  font-family: var(--sans); font-size: var(--step--1);
  letter-spacing: 0.18em; text-transform: uppercase; font-weight: 700;
  color: var(--lane, var(--accent));
}
.event-date .ev-day {
  font-family: var(--serif); font-size: clamp(2rem, 4vw, 2.8rem);
  font-weight: 380; color: var(--ink); margin: 0.1rem 0;
}
.event-date .ev-year { font-size: var(--step--1); color: var(--muted); letter-spacing: 0.06em; }

.event-main { min-width: 0; }
.event-lane {
  display: inline-block; font-family: var(--sans); font-size: 0.72rem;
  letter-spacing: 0.16em; text-transform: uppercase; font-weight: 700;
  color: var(--lane, var(--accent));
  border: 1px solid color-mix(in srgb, var(--lane, var(--accent)) 45%, transparent);
  border-radius: 999px; padding: 0.25rem 0.7rem; margin-bottom: 0.6rem;
}
.event-title {
  font-family: var(--serif); font-size: var(--step-2); font-weight: 360;
  line-height: 1.15; letter-spacing: -0.01em; margin: 0;
}
.event-meta {
  font-family: var(--sans); font-size: var(--step--1); letter-spacing: 0.04em;
  color: var(--muted); margin: 0.5rem 0 0; text-transform: uppercase;
}
.event-desc { color: var(--ink-soft); margin: 0.7rem 0 0; max-width: 60ch; line-height: 1.6; }
.event-link {
  display: inline-flex; align-items: center; gap: 0.4rem; margin-top: 0.85rem;
  font-size: var(--step--1); letter-spacing: 0.1em; text-transform: uppercase;
  font-weight: 600; color: var(--lane, var(--accent));
}
.event-link:hover { text-decoration: underline; text-underline-offset: 3px; }

.events-empty {
  font-family: var(--serif); font-size: var(--step-1); font-style: italic;
  color: var(--muted); padding: 2rem 0;
}

/* =========================================================
   Events gallery — grouped by event
   ========================================================= */
.gallery-group { padding-block: clamp(2rem, 5vw, 3.5rem); border-top: 1px solid var(--line-soft); }
.gallery-group:first-child { border-top: none; padding-top: 0; }
.gallery-head {
  border-left: 3px solid var(--lane, var(--accent));
  padding-left: 1rem; margin-bottom: clamp(1.25rem, 3vw, 1.75rem);
}
.gallery-head .event-lane { margin-bottom: 0.55rem; }
.gallery-title { font-family: var(--serif); font-size: var(--step-2); font-weight: 360; letter-spacing: -0.01em; }
.gallery-grid {
  display: grid; gap: 10px;
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 200px), 1fr));
}
.gallery-item {
  display: block; overflow: hidden; border-radius: 3px;
  background: var(--paper-deep); aspect-ratio: 4 / 3;
}
.gallery-item.is-image { cursor: zoom-in; }
.gallery-item img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.6s cubic-bezier(0.2,0.7,0.2,1); }
.gallery-item.is-image:hover img { transform: scale(1.05); }
.gallery-item.is-video { aspect-ratio: auto; background: #000; }
.gallery-item video { width: 100%; height: 100%; display: block; }

/* lightbox */
.tviah-lightbox {
  position: fixed; inset: 0; z-index: 1000;
  background: rgba(12, 11, 9, 0.93);
  display: flex; align-items: center; justify-content: center;
  padding: clamp(1.5rem, 5vw, 4rem); cursor: zoom-out;
  opacity: 0; transition: opacity 0.25s ease;
}
.tviah-lightbox.open { opacity: 1; }
.tviah-lightbox img {
  max-width: 100%; max-height: 100%; border-radius: 2px;
  box-shadow: 0 24px 70px rgba(0,0,0,0.55);
}
.tviah-lightbox .lb-close {
  position: absolute; top: 1.25rem; right: 1.5rem;
  background: none; border: none; color: rgba(255,255,255,0.85);
  font-size: 2rem; line-height: 1; cursor: pointer;
}

/* =========================================================
   Shared CTA buttons
   ========================================================= */
.btn-cta {
  display: inline-flex; align-items: center; gap: 0.5rem;
  background: var(--ink); color: var(--paper);
  border: none; cursor: pointer;
  font-family: var(--sans); font-size: var(--step--1);
  letter-spacing: 0.14em; text-transform: uppercase; font-weight: 600;
  padding: 0.85rem 1.6rem; border-radius: 2px;
  transition: background 0.3s ease, transform 0.08s ease;
}
.btn-cta:hover { background: var(--accent); }
.btn-cta:active { transform: translateY(1px); }
.btn-cta:disabled { opacity: 0.55; cursor: default; }
.btn-ghost-line {
  background: none; border: 1px solid var(--line);
  cursor: pointer; font-family: var(--sans); font-size: var(--step--1);
  letter-spacing: 0.14em; text-transform: uppercase; font-weight: 600;
  padding: 0.85rem 1.4rem; border-radius: 2px; color: var(--ink-soft);
}
.btn-ghost-line:hover { border-color: var(--ink); color: var(--ink); }

/* =========================================================
   Quiz
   ========================================================= */
.tviah-quiz { max-width: 720px; }
.quiz-title { font-family: var(--serif); font-size: var(--step-3); font-weight: 340; letter-spacing: -0.02em; line-height: 1.05; }
.quiz-lede { margin: 1.1rem 0 2rem; font-family: var(--serif); font-size: var(--step-1); color: var(--ink-soft); line-height: 1.5; max-width: 52ch; }
.quiz-progress { height: 2px; background: var(--line-soft); margin-bottom: clamp(2rem, 5vw, 3rem); }
.quiz-progress-bar { display: block; height: 100%; width: 0; background: var(--accent); transition: width 0.4s cubic-bezier(0.2,0.7,0.2,1); }
.quiz-q { border: none; margin: 0; padding: 0; }
.quiz-q-text { font-family: var(--serif); font-size: var(--step-2); font-weight: 350; line-height: 1.2; margin-bottom: clamp(1.25rem, 3vw, 1.75rem); display: block; }
.quiz-q-num { display: inline-block; font-family: var(--sans); font-size: var(--step--1); font-weight: 700; letter-spacing: 0.1em; color: var(--accent); margin-right: 0.75rem; }
.quiz-opt {
  display: flex; align-items: flex-start; gap: 0.85rem;
  padding: clamp(0.9rem, 2vw, 1.15rem) 1.25rem; margin-bottom: 0.75rem;
  border: 1px solid var(--line); border-radius: 3px; cursor: pointer;
  transition: border-color 0.25s ease, background 0.25s ease;
}
.quiz-opt:hover { border-color: var(--accent); background: var(--paper-deep); }
.quiz-opt input { margin-top: 0.3rem; accent-color: var(--accent); flex: 0 0 auto; }
.quiz-opt:has(input:checked) { border-color: var(--accent); background: var(--paper-deep); }
.quiz-opt-text { font-family: var(--serif); font-size: var(--step-1); line-height: 1.4; }
.quiz-nav { display: flex; gap: 0.75rem; margin-top: clamp(1.5rem, 4vw, 2.25rem); }
.quiz-nav .quiz-next, .quiz-nav .quiz-submit { margin-left: auto; }
.quiz-result {
  border-left: 4px solid var(--lane, var(--accent));
  padding: clamp(1.5rem, 4vw, 2.5rem) clamp(1.5rem, 4vw, 2.5rem);
  background: var(--paper-deep); border-radius: 0 4px 4px 0;
}
.quiz-result-dot { display: inline-block; width: 14px; height: 14px; border-radius: 50%; background: var(--lane, var(--accent)); margin-bottom: 1rem; }
.quiz-result-title { font-family: var(--serif); font-size: var(--step-2); font-weight: 350; line-height: 1.15; margin-bottom: 0.75rem; color: var(--lane, var(--ink)); }
.quiz-result-desc { color: var(--ink-soft); font-size: var(--step-0); line-height: 1.6; max-width: 56ch; margin-bottom: 1.5rem; }

/* =========================================================
   Newsletter signup
   ========================================================= */
.tviah-signup { max-width: 560px; }
.signup-heading { font-family: var(--serif); font-size: var(--step-2); font-weight: 350; letter-spacing: -0.01em; }
.signup-blurb { color: var(--ink-soft); margin: 0.6rem 0 1.5rem; line-height: 1.55; }
.signup-fields { display: flex; flex-wrap: wrap; gap: 0.6rem; }
.signup-fields input, .signup-fields select {
  font-family: var(--sans); font-size: var(--step-0); color: var(--ink);
  background: var(--paper); border: 1px solid var(--line);
  border-radius: 2px; padding: 0.85rem 1rem; flex: 1 1 14rem; min-width: 0;
}
.signup-fields input:focus, .signup-fields select:focus { outline: none; border-color: var(--accent); }
.signup-fields .signup-btn { flex: 0 0 auto; }
.signup-msg { font-size: var(--step--1); margin: 0.85rem 0 0; min-height: 1.2em; }
.signup-msg.is-ok { color: var(--live, #55634F); }
.signup-msg.is-err { color: var(--accent); }
.footer-signup { padding-block: clamp(2.5rem, 6vw, 4rem); border-top: 1px solid var(--line-soft); }
.is-compact .signup-fields { gap: 0.5rem; }

@media (max-width: 540px) {
  .event { grid-template-columns: 1fr; gap: 0.75rem 0; }
  .event-date { flex-direction: row; align-items: baseline; gap: 0.5rem; }
  .event-date .ev-day { font-size: 1.6rem; }
}




/* =========================================================
   Generic page / post (for page.php, single.php)
   ========================================================= */
.entry { padding-block: clamp(3rem, 8vw, 6rem); }
.entry .entry-title { font-size: var(--step-3); margin-bottom: 1.5rem; max-width: 22ch; }
.entry .entry-content { max-width: 66ch; }
.entry .entry-content h2 { font-size: var(--step-2); margin: 2em 0 0.6em; }
.entry .entry-content h3 { font-size: var(--step-1); margin: 1.6em 0 0.5em; }
.entry .entry-content a { color: var(--accent-ink); text-decoration: underline; text-underline-offset: 3px; text-decoration-thickness: 1px; }
.entry .entry-content blockquote {
  margin: 1.6em 0; padding-left: 1.4rem; border-left: 2px solid var(--accent);
  font-family: var(--serif); font-size: var(--step-1); font-style: italic; color: var(--ink-soft);
}
.entry img { border-radius: 2px; margin-block: 1.5rem; }

/* =========================================================
   Footer
   ========================================================= */
.site-footer {
  border-top: 1px solid var(--line);
  padding-block: clamp(3rem, 7vw, 5rem);
}
.site-footer .grid {
  display: grid; gap: 2rem;
  grid-template-columns: 1fr; align-items: end;
}
@media (min-width: 720px) {
  .site-footer .grid { grid-template-columns: 1fr auto; }
}
.site-footer .fbrand {
  font-family: var(--serif); font-size: var(--step-2); font-weight: 380; letter-spacing: 0.06em;
}
.site-footer .fbrand .tm { font-size: 0.4em; vertical-align: super; }
.site-footer .ftag {
  font-size: var(--step--1); letter-spacing: 0.22em; text-transform: uppercase;
  color: var(--muted); font-weight: 600; margin-top: 0.5rem;
}
.site-footer .legal { font-size: var(--step--1); color: var(--muted); text-align: left; }
@media (min-width: 720px) { .site-footer .legal { text-align: right; } }
.site-footer nav ul { list-style: none; display: flex; gap: 1.5rem; padding: 0; margin: 0 0 0.75rem; flex-wrap: wrap; }
.site-footer nav a { font-size: var(--step--1); letter-spacing: 0.12em; text-transform: uppercase; color: var(--ink-soft); }
.site-footer nav a:hover { color: var(--accent-ink); }

/* =========================================================
   Entrance motion — restrained, staggered on load
   ========================================================= */
/* Hidden initial states apply ONLY when JS is active (.js on <html>) and
   the user has not requested reduced motion. No-JS visitors see everything. */
@media (prefers-reduced-motion: no-preference) {
  .js [data-reveal] { opacity: 0; transform: translateY(18px); }
  .js.is-ready [data-reveal] {
    opacity: 1; transform: none;
    transition: opacity 0.9s cubic-bezier(0.2,0.7,0.2,1), transform 0.9s cubic-bezier(0.2,0.7,0.2,1);
    transition-delay: var(--d, 0ms);
  }
  .js .reveal-on-scroll { opacity: 0; transform: translateY(24px); transition: opacity 0.9s cubic-bezier(0.2,0.7,0.2,1), transform 0.9s cubic-bezier(0.2,0.7,0.2,1); }
  .js .reveal-on-scroll.in { opacity: 1; transform: none; }
}

/* Accessibility helpers */
.screen-reader-text {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0;
}
.skip-link {
  position: absolute; left: 0.5rem; top: -3rem; background: var(--ink); color: var(--paper);
  padding: 0.6rem 1rem; border-radius: 2px; z-index: 100; transition: top 0.2s ease;
}
.skip-link:focus { top: 0.5rem; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }
