    /* ======================================
       1. RESET
    ====================================== */
    *, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
    img { display: block; max-width: 100%; height: auto; }
    button { font: inherit; cursor: pointer; border: 0; background: none; }
    a { color: inherit; text-decoration: none; }
    ul, ol { list-style: none; }

    /* ======================================
       2. CSS CUSTOM PROPERTIES
    ====================================== */
    :root {
      --bg: #FAFAFA;
      --bg-alt: #F0F0F0;
      --bg-dark: #0A0A0A;
      --text: #0A0A0A;
      --text-muted: #525252;
      --line: #D4D4D4;
      --accent: #FF4500;
      --accent-link: #C4341A;
      --mono: #171717;

      --font-display: "Inter Tight", -apple-system, BlinkMacSystemFont, sans-serif;
      --font-body: "Inter", -apple-system, BlinkMacSystemFont, sans-serif;
      --font-mono: "JetBrains Mono", "SF Mono", Menlo, monospace;

      --container: 1280px;
      --gutter: 24px;
    }

    /* ======================================
       3. BASE TYPOGRAPHY
    ====================================== */
    html { -webkit-text-size-adjust: 100%; }
    body {
      font-family: var(--font-body);
      font-weight: 400;
      line-height: 1.55;
      color: var(--text);
      background: var(--bg);
      -webkit-font-smoothing: antialiased;
      -moz-osx-font-smoothing: grayscale;
      touch-action: manipulation;
    }
    h1, h2, h3 { text-wrap: balance; font-family: var(--font-display); font-weight: 800; letter-spacing: -0.04em; line-height: 1.05; }
    p, li, dd, blockquote { text-wrap: pretty; }
    h1 { font-size: clamp(2.4rem, 5.6vw, 4.4rem); }
    h2 { font-size: clamp(1.8rem, 3.4vw, 2.8rem); }
    h3 { font-size: clamp(1.15rem, 1.6vw, 1.3rem); font-weight: 700; letter-spacing: -0.02em; line-height: 1.2; }
    p { color: var(--text); }
    .muted { color: var(--text-muted); }
    .mono { font-family: var(--font-mono); font-weight: 500; font-variant-numeric: tabular-nums; }
    .label {
      font-family: var(--font-display);
      font-weight: 700;
      text-transform: uppercase;
      letter-spacing: 0.06em;
      font-size: 0.78rem;
      color: var(--text-muted);
    }
    .eyebrow {
      font-family: var(--font-mono);
      font-weight: 500;
      font-size: 0.82rem;
      color: var(--text-muted);
      text-transform: uppercase;
      letter-spacing: 0.04em;
      font-variant-numeric: tabular-nums;
    }
    .accent-link { color: var(--accent-link); text-decoration: underline; text-underline-offset: 3px; text-decoration-thickness: 1px; }
    .accent-link:hover { text-decoration-thickness: 2px; }

    /* ======================================
       4. LAYOUT
    ====================================== */
    .container { max-width: var(--container); margin: 0 auto; padding: 0 var(--gutter); }
    [id] { scroll-margin-top: 80px; }
    main { display: block; }
    section { padding: clamp(64px, 8vw, 112px) 0; }
    .section-tight { padding: clamp(48px, 6vw, 80px) 0; }

    /* ======================================
       5. COMPONENTS
    ====================================== */

    /* --- Skip link & a11y --- */
    .skip-link {
      position: absolute;
      top: -100px;
      left: 8px;
      background: var(--text);
      color: var(--bg);
      padding: 10px 16px;
      font-family: var(--font-mono);
      font-size: 0.85rem;
      font-weight: 500;
      z-index: 100;
    }
    .skip-link:focus { top: 8px; }
    .sr-only {
      position: absolute;
      width: 1px;
      height: 1px;
      padding: 0;
      margin: -1px;
      overflow: hidden;
      clip: rect(0, 0, 0, 0);
      white-space: nowrap;
      border: 0;
    }

    /* --- Header / Nav --- */
    header.site-header {
      position: sticky;
      top: 0;
      z-index: 50;
      background: var(--bg);
      border-bottom: 1px solid var(--line);
    }
    header.site-header > .container {
      display: flex;
      align-items: center;
      justify-content: space-between;
      padding-top: 16px;
      padding-bottom: 16px;
      gap: 24px;
    }
    .logo { display: inline-flex; align-items: center; }
    .logo img { width: 120px; height: 40px; object-fit: contain; }
    .logo-text {
      font-family: var(--font-display);
      font-size: 1.25rem;
      line-height: 1;
      letter-spacing: -0.045em;
      align-items: baseline;
    }
    .logo-text .logo-thin { font-weight: 300; color: var(--text); }
    .logo-text .logo-bold { font-weight: 800; color: var(--accent); }
    nav[aria-label="Primary"] { display: flex; gap: 28px; flex: 1; justify-content: center; }
    nav[aria-label="Primary"] a {
      font-family: var(--font-mono);
      font-weight: 500;
      font-size: 0.86rem;
      color: var(--text);
      letter-spacing: 0.02em;
      transition: color 150ms ease;
      position: relative;
    }
    nav[aria-label="Primary"] a:hover { color: var(--accent-link); }
    nav[aria-label="Primary"] a[aria-current="page"] { color: var(--accent-link); }
    nav[aria-label="Primary"] a[aria-current="page"]::after {
      content: "";
      position: absolute;
      bottom: -6px;
      left: 0;
      right: 0;
      height: 2px;
      background: var(--accent);
    }

    /* --- Buttons --- */
    .btn {
      display: inline-flex;
      align-items: center;
      gap: 10px;
      padding: 14px 22px;
      font-family: var(--font-mono);
      font-weight: 500;
      font-size: 0.88rem;
      letter-spacing: 0.02em;
      border: 1px solid var(--text);
      border-radius: 0;
      transition: background-color 160ms ease, color 160ms ease, border-color 160ms ease;
    }
    .btn-cta {
      background: var(--accent);
      color: #fff;
      border-color: var(--accent);
      padding: 12px 18px;
      font-size: 0.84rem;
    }
    .btn-cta:hover { background: var(--text); border-color: var(--text); color: var(--bg); }
    .btn-primary {
      background: var(--accent);
      color: #fff;
      border-color: var(--accent);
    }
    .btn-primary:hover { background: var(--text); border-color: var(--text); color: var(--bg); }
    .btn-ghost {
      background: transparent;
      color: var(--text);
      border-color: var(--text);
    }
    .btn-ghost:hover { background: var(--text); color: var(--bg); }
    .btn-ghost-light {
      background: transparent;
      color: #fff;
      border-color: #fff;
    }
    .btn-ghost-light:hover { background: #fff; color: var(--bg-dark); }

    /* --- Hero (full-bleed image background, type overlaid) --- */
    .hero {
      position: relative;
      padding: clamp(96px, 12vw, 168px) 0 clamp(96px, 12vw, 168px);
      isolation: isolate;
      overflow: hidden;
      border-bottom: 1px solid var(--line);
    }
    .hero-grain {
      position: absolute;
      inset: 0;
      pointer-events: none;
      z-index: 0;
      background-color: var(--bg);
      overflow: hidden;
    }
    .hero-grain .blob {
      position: absolute;
      border-radius: 50%;
      filter: blur(120px);
      pointer-events: none;
    }
    .hero-grain .blob-1 {
      width: 720px; height: 720px;
      background: #FF4500;
      top: -180px;
      right: -120px;
      opacity: 0.32;
    }
    .hero-grain .blob-2 {
      width: 560px; height: 560px;
      background: #FFB07A;
      bottom: -160px;
      left: -80px;
      opacity: 0.42;
    }
    .hero-grain .blob-3 {
      width: 440px; height: 440px;
      background: #FFD9B8;
      top: 38%;
      left: 42%;
      opacity: 0.55;
    }
    .hero-grain .blob-4 {
      width: 360px; height: 360px;
      background: #FF6B2D;
      bottom: 8%;
      right: 22%;
      opacity: 0.22;
    }
    .hero-grain::after {
      content: '';
      position: absolute;
      inset: 0;
      pointer-events: none;
      mix-blend-mode: multiply;
      opacity: 0.6;
      background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='400' height='400'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='3' stitchTiles='stitch'/><feColorMatrix values='0 0 0 0 0  0 0 0 0 0  0 0 0 0 0  0 0 0 0.16 0'/></filter><rect width='100%' height='100%' filter='url(%23n)'/></svg>");
      background-size: 240px 240px;
    }
    .hero > .container {
      position: relative;
      z-index: 1;
      display: grid;
      gap: clamp(20px, 2vw, 28px);
    }
    .hero .eyebrow { display: block; }
    .hero h1 {
      max-width: 18ch;
      font-size: clamp(2.4rem, 5.6vw, 4.4rem);
      line-height: 1.05;
      letter-spacing: -0.045em;
    }
    .hero p.lede {
      font-size: clamp(1.06rem, 1.6vw, 1.22rem);
      color: var(--text-muted);
      max-width: 60ch;
      line-height: 1.55;
      text-wrap: pretty;
    }
    .hero .actions { display: flex; gap: 18px; align-items: center; flex-wrap: wrap; margin-top: 4px; }
    .hero .secondary-link {
      font-family: var(--font-mono);
      font-weight: 500;
      font-size: 0.9rem;
      color: var(--text);
      border-bottom: 1px solid var(--text);
      padding-bottom: 2px;
      transition: color 160ms ease, border-color 160ms ease;
    }
    .hero .secondary-link:hover { color: var(--accent-link); border-color: var(--accent-link); }

    /* --- Value prop --- */
    .value-prop {
      padding: clamp(48px, 6vw, 96px) 0;
      border-bottom: 1px solid var(--line);
    }
    .value-prop .vp-eyebrow {
      display: block;
      color: var(--accent);
      margin-bottom: 24px;
    }
    .value-prop .vp-text {
      font-family: var(--font-display);
      font-weight: 700;
      font-size: clamp(1.5rem, 3.4vw, 2.4rem);
      line-height: 1.2;
      letter-spacing: -0.025em;
      max-width: 40ch;
      color: var(--text);
    }

    /* --- System overview / index --- */
    .system-index {
      display: grid;
      grid-template-columns: 1fr;
      border-top: 1px solid var(--line);
    }
    .system-index .pillar {
      display: grid;
      grid-template-columns: 88px 1.2fr 2fr 1.4fr;
      gap: 24px;
      padding: 36px 0;
      border-bottom: 1px solid var(--line);
      align-items: start;
    }
    .system-index .num {
      font-family: var(--font-mono);
      font-weight: 600;
      font-variant-numeric: tabular-nums;
      font-size: 0.92rem;
      color: var(--text-muted);
      letter-spacing: 0.04em;
      padding-top: 4px;
    }
    .system-index .title {
      font-family: var(--font-display);
      font-weight: 800;
      font-size: 1.65rem;
      letter-spacing: -0.03em;
    }
    .system-index .subtitle {
      display: block;
      font-family: var(--font-mono);
      font-weight: 500;
      font-size: 0.82rem;
      color: var(--text-muted);
      margin-top: 6px;
      letter-spacing: 0.01em;
    }
    .system-index .desc {
      color: var(--text-muted);
      font-size: 1rem;
      line-height: 1.55;
    }
    .system-index .stack-tag {
      display: inline-block;
      font-family: var(--font-mono);
      font-weight: 500;
      font-size: 0.74rem;
      color: var(--mono);
      background: var(--bg-alt);
      border: 1px solid var(--line);
      padding: 8px 12px;
      letter-spacing: 0.04em;
      align-self: start;
    }
    .system-index .pillar:hover .num { color: var(--accent); transition: color 200ms ease; }

    /* --- Section header pattern --- */
    .section-head {
      display: flex;
      justify-content: space-between;
      align-items: end;
      gap: 24px;
      margin-bottom: 40px;
      padding-bottom: 20px;
      border-bottom: 1px solid var(--line);
    }
    .section-head h2 { max-width: 24ch; }
    .section-head .meta {
      font-family: var(--font-mono);
      font-weight: 500;
      font-size: 0.82rem;
      color: var(--text-muted);
      letter-spacing: 0.04em;
      text-align: right;
      white-space: nowrap;
    }

    /* --- Selected work cards --- */
    .work-grid {
      display: grid;
      grid-template-columns: repeat(3, 1fr);
      gap: 0;
      border-top: 1px solid var(--line);
      border-left: 1px solid var(--line);
    }
    .work-card {
      padding: 28px;
      border-right: 1px solid var(--line);
      border-bottom: 1px solid var(--line);
      background: var(--bg);
      display: grid;
      grid-template-rows: auto auto auto auto 1fr auto;
      gap: 14px;
      transition: background-color 200ms ease;
    }
    .work-card:hover { background: var(--bg-alt); }
    .work-card .index {
      font-family: var(--font-mono);
      font-weight: 600;
      font-size: 0.82rem;
      color: var(--text-muted);
      font-variant-numeric: tabular-nums;
      letter-spacing: 0.04em;
    }
    .work-card .vert {
      display: inline-block;
      font-family: var(--font-mono);
      font-weight: 500;
      font-size: 0.7rem;
      color: var(--mono);
      border: 1px solid var(--line);
      padding: 4px 8px;
      letter-spacing: 0.06em;
      align-self: start;
      justify-self: start;
    }
    .work-card h3 {
      font-size: 1.5rem;
      margin-top: 4px;
    }
    .work-card .desc {
      color: var(--text-muted);
      font-size: 0.95rem;
      line-height: 1.5;
    }
    .work-card .still {
      font-family: var(--font-mono);
      font-weight: 500;
      font-size: 0.78rem;
      color: var(--mono);
      padding-top: 14px;
      border-top: 1px solid var(--line);
      line-height: 1.5;
    }
    .work-card .still strong { color: var(--accent-link); font-weight: 500; }

    /* --- Pricing table --- */
    .pricing-table {
      width: 100%;
      border-top: 1px solid var(--text);
      border-collapse: collapse;
      font-family: var(--font-body);
    }
    .pricing-table tr {
      border-bottom: 1px solid var(--line);
      transition: background-color 160ms ease;
    }
    .pricing-table tr:hover { background: var(--bg-alt); }
    .pricing-table td {
      padding: 22px 16px;
      vertical-align: middle;
    }
    .pricing-table td:first-child { padding-left: 0; }
    .pricing-table td:last-child { padding-right: 0; text-align: right; }
    .pricing-table .name {
      font-family: var(--font-display);
      font-weight: 700;
      font-size: 1.2rem;
      letter-spacing: -0.02em;
      width: 30%;
    }
    .pricing-table .price {
      font-family: var(--font-mono);
      font-weight: 600;
      font-variant-numeric: tabular-nums;
      font-size: 1.05rem;
      color: var(--mono);
      width: 14%;
      white-space: nowrap;
    }
    .pricing-table .desc {
      color: var(--text-muted);
      font-size: 0.95rem;
      font-family: var(--font-mono);
      font-weight: 500;
      letter-spacing: 0.01em;
    }
    .pricing-foot {
      margin-top: 24px;
      font-family: var(--font-mono);
      font-weight: 500;
      font-size: 0.88rem;
    }
    .pricing-foot a { color: var(--accent-link); border-bottom: 1px solid var(--accent-link); padding-bottom: 2px; }
    .pricing-foot a:hover { color: var(--text); border-color: var(--text); }

    /* --- Quotes / system I/O --- */
    .quotes-block {
      display: grid;
      grid-template-columns: repeat(2, 1fr);
      gap: 0;
      border: 1px solid var(--line);
      background: var(--bg);
    }
    .quote-card {
      padding: 32px;
      border-right: 1px solid var(--line);
      display: grid;
      grid-template-rows: auto 1fr auto;
      gap: 20px;
    }
    .quote-card:last-child { border-right: 0; }
    .quote-card .quote-head {
      font-family: var(--font-mono);
      font-weight: 500;
      font-size: 0.74rem;
      color: var(--text-muted);
      letter-spacing: 0.06em;
      text-transform: uppercase;
    }
    .quote-card blockquote {
      font-family: var(--font-display);
      font-weight: 500;
      font-size: 1.18rem;
      letter-spacing: -0.02em;
      line-height: 1.45;
      color: var(--text);
      quotes: "\201C" "\201D";
    }
    .quote-card blockquote::before { content: open-quote; color: var(--accent); margin-right: 2px; }
    .quote-card blockquote::after { content: close-quote; color: var(--accent); margin-left: 2px; }
    .quote-card cite {
      font-family: var(--font-mono);
      font-weight: 500;
      font-size: 0.82rem;
      color: var(--mono);
      font-style: normal;
      letter-spacing: 0.02em;
      padding-top: 14px;
      border-top: 1px solid var(--line);
    }

    /* --- Journal cards --- */
    .journal-grid {
      display: grid;
      grid-template-columns: repeat(3, 1fr);
      gap: 24px;
    }
    .journal-card {
      display: grid;
      grid-template-rows: auto auto 1fr auto;
      gap: 14px;
      transition: transform 200ms ease;
    }
    .journal-card:hover { transform: translateY(-4px); }
    .journal-card .img-wrap {
      width: 100%;
      aspect-ratio: 4/3;
      overflow: hidden;
      border: 1px solid var(--line);
    }
    .journal-card .img-wrap img { width: 100%; height: 100%; object-fit: cover; transition: transform 400ms ease; }
    .journal-card:hover .img-wrap img { transform: scale(1.04); }
    .journal-card .date {
      font-family: var(--font-mono);
      font-weight: 500;
      font-size: 0.78rem;
      color: var(--text-muted);
      font-variant-numeric: tabular-nums;
      letter-spacing: 0.04em;
    }
    .journal-card h3 {
      font-size: 1.15rem;
      letter-spacing: -0.02em;
    }
    .journal-card .read {
      font-family: var(--font-mono);
      font-weight: 500;
      font-size: 0.82rem;
      color: var(--mono);
      align-self: end;
      position: relative;
      padding-bottom: 4px;
    }
    .journal-card .read::after {
      content: "";
      position: absolute;
      left: 0;
      bottom: 0;
      height: 1px;
      width: 100%;
      background: var(--text);
      transform: scaleX(0.4);
      transform-origin: left;
      transition: transform 220ms ease;
    }
    .journal-card:hover .read::after { transform: scaleX(1); }

    /* --- Footer CTA + Footer (dark) --- */
    .footer-band {
      background: var(--bg-dark);
      color: #fff;
    }
    .footer-cta {
      padding: clamp(64px, 8vw, 112px) 0;
      border-bottom: 1px solid #262626;
    }
    .footer-cta h2 {
      max-width: 22ch;
      color: #fff;
      font-size: clamp(1.8rem, 3.6vw, 2.8rem);
      margin-bottom: 28px;
    }
    .footer-cta .accent-rule {
      display: inline-block;
      width: 48px;
      height: 2px;
      background: var(--accent);
      margin-bottom: 24px;
      transition: width 240ms ease;
    }
    .footer-cta:hover .accent-rule { width: 96px; }

    .footer-grid {
      padding: 56px 0 24px;
      display: grid;
      grid-template-columns: 1.6fr 1fr 1fr 1fr;
      gap: 32px;
      align-items: start;
    }
    .footer-logo {
      display: block;
      width: 48px;
      height: 48px;
      margin-bottom: 14px;
      object-fit: contain;
    }
    .footer-brand { font-family: var(--font-display); font-weight: 800; font-size: 1.4rem; letter-spacing: -0.03em; color: #fff; }
    .footer-brand-sub {
      display: block;
      font-family: var(--font-mono);
      font-weight: 500;
      font-size: 0.78rem;
      color: #A3A3A3;
      margin-top: 8px;
      letter-spacing: 0.04em;
    }
    .footer-col h4 {
      font-family: var(--font-mono);
      font-weight: 500;
      font-size: 0.74rem;
      text-transform: uppercase;
      letter-spacing: 0.06em;
      color: #A3A3A3;
      margin-bottom: 14px;
    }
    .footer-col ul { display: grid; gap: 8px; }
    .footer-col a {
      font-family: var(--font-mono);
      font-weight: 500;
      font-size: 0.86rem;
      color: #fff;
      transition: color 160ms ease;
    }
    .footer-col a:hover { color: var(--accent); }
    .footer-meta {
      padding: 24px 0 32px;
      border-top: 1px solid #262626;
      font-family: var(--font-mono);
      font-weight: 500;
      font-size: 0.78rem;
      color: #A3A3A3;
      letter-spacing: 0.02em;
      display: flex;
      justify-content: space-between;
      gap: 20px;
      flex-wrap: wrap;
    }

    /* ======================================
       6. ACCESSIBILITY
    ====================================== */
    :focus-visible {
      outline: 2px solid var(--accent);
      outline-offset: 2px;
    }
    .btn:focus-visible { outline-offset: 4px; }

    /* ======================================
       7. ANIMATIONS
    ====================================== */
    .animate-on-scroll {
      opacity: 0;
      transform: translateY(20px);
      transition: opacity 600ms ease, transform 600ms ease;
    }
    .animate-on-scroll.is-visible {
      opacity: 1;
      transform: translateY(0);
    }
    .animate-on-scroll.delay-1 { transition-delay: 80ms; }
    .animate-on-scroll.delay-2 { transition-delay: 160ms; }
    .animate-on-scroll.delay-3 { transition-delay: 240ms; }

    /* ======================================
       8. RESPONSIVE
    ====================================== */
    @media (max-width: 1024px) {
      .work-grid { grid-template-columns: repeat(2, 1fr); }
      .journal-grid { grid-template-columns: repeat(2, 1fr); }
      .footer-grid { grid-template-columns: 1.4fr 1fr 1fr; }
      .footer-grid .footer-col:last-child { grid-column: span 3; }
    }
    @media (max-width: 768px) {
      header.site-header > .container { flex-wrap: wrap; padding-bottom: 14px; }
      nav[aria-label="Primary"] {
        order: 3;
        flex-basis: 100%;
        justify-content: flex-start;
        gap: 18px;
        padding-top: 14px;
        border-top: 1px solid var(--line);
        overflow-x: auto;
        white-space: nowrap;
      }
      .system-index .pillar {
        grid-template-columns: 1fr;
        grid-template-areas:
          "num"
          "title"
          "desc"
          "stack";
        gap: 8px;
      }
      .system-index .num { grid-area: num; }
      .system-index .title-wrap { grid-area: title; }
      .system-index .desc { grid-area: desc; margin-top: 4px; }
      .system-index .stack-tag { grid-area: stack; margin-top: 12px; }
      .work-grid { grid-template-columns: 1fr; }
      .quotes-block { grid-template-columns: 1fr; }
      .quote-card { border-right: 0; border-bottom: 1px solid var(--line); }
      .quote-card:last-child { border-bottom: 0; }
      .journal-grid { grid-template-columns: 1fr; }
      .pricing-table .name { font-size: 1.05rem; }
      .pricing-table td { padding: 16px 8px; }
      .pricing-table td.desc { display: none; }
      .footer-grid { grid-template-columns: 1fr 1fr; }
      .footer-grid .footer-col:last-child { grid-column: span 2; }
      .footer-meta { flex-direction: column; gap: 8px; }
      .section-head { flex-direction: column; align-items: flex-start; }
      .section-head .meta { text-align: left; }
    }
    @media (max-width: 480px) {
      .hero .actions { flex-direction: column; align-items: stretch; }
      .hero .actions .btn, .hero .actions .secondary-link { width: 100%; justify-content: center; text-align: center; }
      .footer-grid { grid-template-columns: 1fr; }
      .footer-grid .footer-col:last-child { grid-column: span 1; }
      .work-card { padding: 22px; }
    }

    /* ======================================
       9. REDUCED MOTION
    ====================================== */
    @media (prefers-reduced-motion: reduce) {
      *, ::before, ::after { animation: none !important; transition: none !important; }
      .animate-on-scroll { opacity: 1; transform: none; }
    }

/* ============================================================
   CASE STUDY COMPONENTS (extracted from www/option-b/aagla.html)
   ============================================================ */

    /* ======================================
       1. RESET
    ====================================== */
    *, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
    img { display: block; max-width: 100%; height: auto; }
    button { font: inherit; cursor: pointer; border: 0; background: none; }
    a { color: inherit; text-decoration: none; }
    ul, ol { list-style: none; }

    /* ======================================
       2. CSS CUSTOM PROPERTIES
    ====================================== */
    :root {
      --bg: #FAFAFA;
      --bg-alt: #F0F0F0;
      --bg-dark: #0A0A0A;
      --text: #0A0A0A;
      --text-muted: #525252;
      --line: #D4D4D4;
      --accent: #FF4500;
      --accent-link: #C4341A;
      --mono: #171717;

      --font-display: "Inter Tight", -apple-system, BlinkMacSystemFont, sans-serif;
      --font-body: "Inter", -apple-system, BlinkMacSystemFont, sans-serif;
      --font-mono: "JetBrains Mono", "SF Mono", Menlo, monospace;

      --container: 1280px;
      --gutter: 24px;
    }

    /* ======================================
       3. BASE TYPOGRAPHY
    ====================================== */
    html { -webkit-text-size-adjust: 100%; }
    body {
      font-family: var(--font-body);
      font-weight: 400;
      line-height: 1.55;
      color: var(--text);
      background: var(--bg);
      -webkit-font-smoothing: antialiased;
      -moz-osx-font-smoothing: grayscale;
      touch-action: manipulation;
    }
    h1, h2, h3 { text-wrap: balance; font-family: var(--font-display); font-weight: 800; letter-spacing: -0.04em; line-height: 1.05; }
    p, li, dd, blockquote { text-wrap: pretty; }
    h1 { font-size: clamp(2.4rem, 5.6vw, 4.4rem); }
    h2 { font-size: clamp(1.8rem, 3.4vw, 2.8rem); }
    h3 { font-size: clamp(1.15rem, 1.6vw, 1.3rem); font-weight: 700; letter-spacing: -0.02em; line-height: 1.2; }
    p { color: var(--text); }
    .muted { color: var(--text-muted); }
    .mono { font-family: var(--font-mono); font-weight: 500; font-variant-numeric: tabular-nums; }
    .label {
      font-family: var(--font-display);
      font-weight: 700;
      text-transform: uppercase;
      letter-spacing: 0.06em;
      font-size: 0.78rem;
      color: var(--text-muted);
    }
    .eyebrow {
      font-family: var(--font-mono);
      font-weight: 500;
      font-size: 0.82rem;
      color: var(--text-muted);
      text-transform: uppercase;
      letter-spacing: 0.04em;
      font-variant-numeric: tabular-nums;
    }
    .accent-link { color: var(--accent-link); text-decoration: underline; text-underline-offset: 3px; text-decoration-thickness: 1px; }
    .accent-link:hover { text-decoration-thickness: 2px; }

    /* ======================================
       4. LAYOUT
    ====================================== */
    .container { max-width: var(--container); margin: 0 auto; padding: 0 var(--gutter); }
    [id] { scroll-margin-top: 80px; }
    main { display: block; }
    section { padding: clamp(64px, 8vw, 112px) 0; }
    .section-tight { padding: clamp(48px, 6vw, 80px) 0; }

    /* ======================================
       5. COMPONENTS
    ====================================== */

    /* --- Skip link & a11y --- */
    .skip-link {
      position: absolute;
      top: -100px;
      left: 8px;
      background: var(--text);
      color: var(--bg);
      padding: 10px 16px;
      font-family: var(--font-mono);
      font-size: 0.85rem;
      font-weight: 500;
      z-index: 100;
    }
    .skip-link:focus { top: 8px; }
    .sr-only {
      position: absolute;
      width: 1px;
      height: 1px;
      padding: 0;
      margin: -1px;
      overflow: hidden;
      clip: rect(0, 0, 0, 0);
      white-space: nowrap;
      border: 0;
    }

    /* --- Header / Nav --- */
    header.site-header {
      position: sticky;
      top: 0;
      z-index: 50;
      background: var(--bg);
      border-bottom: 1px solid var(--line);
    }
    header.site-header > .container {
      display: flex;
      align-items: center;
      justify-content: space-between;
      padding-top: 16px;
      padding-bottom: 16px;
      gap: 24px;
    }
    .logo { display: inline-flex; align-items: center; }
    .logo img { width: 120px; height: 40px; object-fit: contain; }
    .logo-text {
      font-family: var(--font-display);
      font-size: 1.25rem;
      line-height: 1;
      letter-spacing: -0.045em;
      align-items: baseline;
    }
    .logo-text .logo-thin { font-weight: 300; color: var(--text); }
    .logo-text .logo-bold { font-weight: 800; color: var(--accent); }
    nav[aria-label="Primary"] { display: flex; gap: 28px; flex: 1; justify-content: center; }
    nav[aria-label="Primary"] a {
      font-family: var(--font-mono);
      font-weight: 500;
      font-size: 0.86rem;
      color: var(--text);
      letter-spacing: 0.02em;
      transition: color 150ms ease;
      position: relative;
    }
    nav[aria-label="Primary"] a:hover { color: var(--accent-link); }
    nav[aria-label="Primary"] a[aria-current="page"] { color: var(--accent-link); }
    nav[aria-label="Primary"] a[aria-current="page"]::after {
      content: "";
      position: absolute;
      bottom: -6px;
      left: 0;
      right: 0;
      height: 2px;
      background: var(--accent);
    }

    /* --- Buttons --- */
    .btn {
      display: inline-flex;
      align-items: center;
      gap: 10px;
      padding: 14px 22px;
      font-family: var(--font-mono);
      font-weight: 500;
      font-size: 0.88rem;
      letter-spacing: 0.02em;
      border: 1px solid var(--text);
      border-radius: 0;
      transition: background-color 160ms ease, color 160ms ease, border-color 160ms ease;
    }
    .btn-cta {
      background: var(--accent);
      color: #fff;
      border-color: var(--accent);
      padding: 12px 18px;
      font-size: 0.84rem;
    }
    .btn-cta:hover { background: var(--text); border-color: var(--text); color: var(--bg); }
    .btn-primary {
      background: var(--accent);
      color: #fff;
      border-color: var(--accent);
    }
    .btn-primary:hover { background: var(--text); border-color: var(--text); color: var(--bg); }
    .btn-ghost {
      background: transparent;
      color: var(--text);
      border-color: var(--text);
    }
    .btn-ghost:hover { background: var(--text); color: var(--bg); }
    .btn-ghost-light {
      background: transparent;
      color: #fff;
      border-color: #fff;
    }
    .btn-ghost-light:hover { background: #fff; color: var(--bg-dark); }

    /* --- Case study hero --- */
    .case-hero { padding: clamp(48px, 6vw, 80px) 0 0; }
    .case-hero .container { display: grid; gap: 28px; max-width: 1100px; }
    .case-hero .eyebrow { display: block; }
    .case-hero h1 { max-width: 22ch; }
    .case-hero p.lede {
      font-size: clamp(1.06rem, 1.6vw, 1.22rem);
      color: var(--text-muted);
      max-width: 64ch;
      line-height: 1.55;
    }
    .case-hero .meta-line {
      display: flex;
      gap: 12px;
      flex-wrap: wrap;
      align-items: center;
      font-family: var(--font-mono);
      font-weight: 500;
      font-size: 0.78rem;
      color: var(--text-muted);
      letter-spacing: 0.04em;
      padding-top: 8px;
      border-top: 1px solid var(--line);
      margin-top: 4px;
    }
    .case-hero .meta-line .dot { color: var(--line); }
    .case-hero .meta-line .vert {
      display: inline-block;
      font-family: var(--font-mono);
      font-weight: 500;
      font-size: 0.72rem;
      color: var(--mono);
      border: 1px solid var(--line);
      padding: 4px 8px;
      letter-spacing: 0.06em;
    }
    .hero-image-band {
      margin-top: clamp(48px, 6vw, 80px);
      width: 100%;
    }
    .hero-image-band img {
      width: 100%;
      height: auto;
      aspect-ratio: 1440 / 800;
      object-fit: cover;
      display: block;
      border-radius: 0;
    }

    /* --- Stats grid --- */
    .stats-band {
      padding: 0;
      background: var(--bg);
    }
    .stats-grid {
      display: grid;
      grid-template-columns: repeat(4, 1fr);
      border-top: 1px solid var(--line);
      border-bottom: 1px solid var(--line);
    }
    .stat {
      padding: 32px 28px;
      border-right: 1px solid var(--line);
      display: grid;
      gap: 8px;
    }
    .stat:last-child { border-right: 0; }
    .stat .stat-num {
      font-family: var(--font-mono);
      font-weight: 600;
      font-variant-numeric: tabular-nums;
      font-size: clamp(1.4rem, 2.4vw, 1.85rem);
      color: var(--mono);
      letter-spacing: -0.01em;
      line-height: 1.05;
    }
    .stat .stat-label {
      font-family: var(--font-display);
      font-weight: 700;
      text-transform: uppercase;
      letter-spacing: 0.06em;
      font-size: 0.7rem;
      color: var(--text-muted);
    }

    /* --- Section header pattern --- */
    .section-head {
      display: flex;
      justify-content: space-between;
      align-items: end;
      gap: 24px;
      margin-bottom: 40px;
      padding-bottom: 20px;
      border-bottom: 1px solid var(--line);
    }
    .section-head h2 { max-width: 28ch; }
    .section-head .meta {
      font-family: var(--font-mono);
      font-weight: 500;
      font-size: 0.82rem;
      color: var(--text-muted);
      letter-spacing: 0.04em;
      text-align: right;
      white-space: nowrap;
    }

    /* --- Brief / prose blocks --- */
    .prose-grid {
      display: grid;
      grid-template-columns: 1fr 1.6fr;
      gap: 48px;
      align-items: start;
    }
    .prose-grid .col-aside {
      font-family: var(--font-mono);
      font-weight: 500;
      font-size: 0.8rem;
      color: var(--text-muted);
      letter-spacing: 0.04em;
      line-height: 1.6;
      padding-top: 6px;
      border-top: 2px solid var(--text);
    }
    .prose-grid .col-aside .aside-key {
      display: block;
      color: var(--mono);
      margin-bottom: 4px;
      font-weight: 600;
    }
    .prose-grid .col-aside .aside-row {
      padding: 10px 0;
      border-bottom: 1px solid var(--line);
    }
    .prose-grid .col-aside .aside-row:last-child { border-bottom: 0; }
    .prose-grid .col-body p {
      font-size: 1.05rem;
      line-height: 1.65;
      color: var(--text);
      max-width: 62ch;
    }
    .prose-grid .col-body p + p { margin-top: 18px; }

    /* --- What we built (numbered list) --- */
    .built-list {
      display: grid;
      grid-template-columns: 1fr;
      border-top: 1px solid var(--line);
    }
    .built-list .item {
      display: grid;
      grid-template-columns: 88px 1.2fr 2.4fr;
      gap: 24px;
      padding: 36px 0;
      border-bottom: 1px solid var(--line);
      align-items: start;
    }
    .built-list .num {
      font-family: var(--font-mono);
      font-weight: 600;
      font-variant-numeric: tabular-nums;
      font-size: 0.92rem;
      color: var(--text-muted);
      letter-spacing: 0.04em;
      padding-top: 4px;
    }
    .built-list .title-wrap .title {
      font-family: var(--font-display);
      font-weight: 800;
      font-size: 1.5rem;
      letter-spacing: -0.03em;
      display: block;
    }
    .built-list .title-wrap .subtitle {
      display: block;
      font-family: var(--font-mono);
      font-weight: 500;
      font-size: 0.78rem;
      color: var(--text-muted);
      margin-top: 6px;
      letter-spacing: 0.02em;
    }
    .built-list .desc {
      color: var(--text-muted);
      font-size: 1rem;
      line-height: 1.6;
      max-width: 60ch;
    }
    .built-list .item:hover .num { color: var(--accent); transition: color 200ms ease; }

    /* --- Still running (DARK BAND, centerpiece) --- */
    .still-band {
      background: var(--bg-dark);
      color: #fff;
    }
    .still-band section { padding: clamp(72px, 9vw, 128px) 0; }
    .still-band .section-head {
      border-bottom-color: #262626;
    }
    .still-band .section-head h2 { color: #fff; max-width: 30ch; }
    .still-band .section-head .meta { color: #A3A3A3; }
    .still-band .eyebrow { color: var(--accent); }
    .still-band .accent-rule {
      display: inline-block;
      width: 48px;
      height: 2px;
      background: var(--accent);
      margin-bottom: 22px;
    }
    .still-lead {
      font-family: var(--font-display);
      font-weight: 500;
      font-size: clamp(1.3rem, 2.2vw, 1.7rem);
      letter-spacing: -0.02em;
      line-height: 1.35;
      color: #fff;
      max-width: 36ch;
      margin-bottom: 48px;
    }
    .still-lead .accent-text { color: var(--accent); }
    .still-list {
      display: grid;
      gap: 0;
      border-top: 1px solid #262626;
    }
    .still-list .row {
      display: grid;
      grid-template-columns: 36px 1fr;
      gap: 18px;
      padding: 22px 0;
      border-bottom: 1px solid #262626;
      align-items: start;
    }
    .still-list .tick {
      font-family: var(--font-mono);
      font-weight: 600;
      font-size: 1rem;
      color: var(--accent);
      letter-spacing: 0.02em;
      padding-top: 2px;
    }
    .still-list .row-body {
      font-family: var(--font-mono);
      font-weight: 500;
      font-size: 0.95rem;
      color: #fff;
      letter-spacing: 0.01em;
      line-height: 1.55;
    }
    .still-list .row-body strong {
      font-weight: 600;
      color: #fff;
    }
    .still-list .row:hover .tick { color: #fff; transition: color 160ms ease; }
    .still-foot {
      margin-top: 36px;
      font-family: var(--font-mono);
      font-weight: 500;
      font-size: 0.84rem;
      color: #A3A3A3;
      letter-spacing: 0.04em;
    }

    /* --- Testimonial card --- */
    .testimonial-card {
      border: 1px solid var(--line);
      background: var(--bg);
      padding: clamp(36px, 5vw, 56px);
      display: grid;
      gap: 24px;
      max-width: 920px;
      margin: 0 auto;
    }
    .testimonial-card .frame-head {
      font-family: var(--font-mono);
      font-weight: 500;
      font-size: 0.74rem;
      color: var(--text-muted);
      letter-spacing: 0.06em;
      text-transform: uppercase;
      padding-bottom: 14px;
      border-bottom: 1px solid var(--line);
    }
    .testimonial-card .lead {
      font-family: var(--font-mono);
      font-weight: 500;
      font-size: 0.88rem;
      color: var(--text-muted);
      letter-spacing: 0.02em;
      line-height: 1.55;
      max-width: 62ch;
    }
    .testimonial-card blockquote {
      font-family: var(--font-display);
      font-weight: 500;
      font-size: clamp(1.2rem, 2.1vw, 1.5rem);
      letter-spacing: -0.02em;
      line-height: 1.4;
      color: var(--text);
      quotes: "\201C" "\201D";
      max-width: 50ch;
    }
    .testimonial-card blockquote::before { content: open-quote; color: var(--accent); margin-right: 2px; }
    .testimonial-card blockquote::after { content: close-quote; color: var(--accent); margin-left: 2px; }
    .testimonial-card cite {
      font-family: var(--font-mono);
      font-weight: 500;
      font-size: 0.84rem;
      color: var(--mono);
      font-style: normal;
      letter-spacing: 0.02em;
      padding-top: 18px;
      border-top: 1px solid var(--line);
      display: block;
    }

    /* --- Related work cards --- */
    .related-grid {
      display: grid;
      grid-template-columns: repeat(2, 1fr);
      gap: 0;
      border-top: 1px solid var(--line);
      border-left: 1px solid var(--line);
    }
    .related-card {
      padding: 28px;
      border-right: 1px solid var(--line);
      border-bottom: 1px solid var(--line);
      background: var(--bg);
      display: grid;
      grid-template-rows: auto auto auto auto 1fr auto;
      gap: 14px;
      transition: background-color 200ms ease;
    }
    .related-card:hover { background: var(--bg-alt); }
    .related-card .index {
      font-family: var(--font-mono);
      font-weight: 600;
      font-size: 0.82rem;
      color: var(--text-muted);
      font-variant-numeric: tabular-nums;
      letter-spacing: 0.04em;
    }
    .related-card .vert {
      display: inline-block;
      font-family: var(--font-mono);
      font-weight: 500;
      font-size: 0.7rem;
      color: var(--mono);
      border: 1px solid var(--line);
      padding: 4px 8px;
      letter-spacing: 0.06em;
      align-self: start;
      justify-self: start;
    }
    .related-card h3 {
      font-size: 1.5rem;
      margin-top: 4px;
    }
    .related-card .desc {
      color: var(--text-muted);
      font-size: 0.95rem;
      line-height: 1.5;
    }
    .related-card .still {
      font-family: var(--font-mono);
      font-weight: 500;
      font-size: 0.78rem;
      color: var(--mono);
      padding-top: 14px;
      border-top: 1px solid var(--line);
      line-height: 1.5;
    }
    .related-card .still strong { color: var(--accent-link); font-weight: 500; }
    .related-card .read {
      font-family: var(--font-mono);
      font-weight: 500;
      font-size: 0.82rem;
      color: var(--mono);
      padding-top: 10px;
    }

    /* --- Footer CTA + Footer (dark) --- */
    .footer-band {
      background: var(--bg-dark);
      color: #fff;
    }
    .footer-cta {
      padding: clamp(64px, 8vw, 112px) 0;
      border-bottom: 1px solid #262626;
    }
    .footer-cta h2 {
      max-width: 22ch;
      color: #fff;
      font-size: clamp(1.8rem, 3.6vw, 2.8rem);
      margin-bottom: 28px;
    }
    .footer-cta .accent-rule {
      display: inline-block;
      width: 48px;
      height: 2px;
      background: var(--accent);
      margin-bottom: 24px;
      transition: width 240ms ease;
    }
    .footer-cta:hover .accent-rule { width: 96px; }

    .footer-grid {
      padding: 56px 0 24px;
      display: grid;
      grid-template-columns: 1.6fr 1fr 1fr 1fr;
      gap: 32px;
      align-items: start;
    }
    .footer-logo {
      display: block;
      width: 48px;
      height: 48px;
      margin-bottom: 14px;
      object-fit: contain;
    }
    .footer-brand { font-family: var(--font-display); font-weight: 800; font-size: 1.4rem; letter-spacing: -0.03em; color: #fff; }
    .footer-brand-sub {
      display: block;
      font-family: var(--font-mono);
      font-weight: 500;
      font-size: 0.78rem;
      color: #A3A3A3;
      margin-top: 8px;
      letter-spacing: 0.04em;
    }
    .footer-col h4 {
      font-family: var(--font-mono);
      font-weight: 500;
      font-size: 0.74rem;
      text-transform: uppercase;
      letter-spacing: 0.06em;
      color: #A3A3A3;
      margin-bottom: 14px;
    }
    .footer-col ul { display: grid; gap: 8px; }
    .footer-col a {
      font-family: var(--font-mono);
      font-weight: 500;
      font-size: 0.86rem;
      color: #fff;
      transition: color 160ms ease;
    }
    .footer-col a:hover { color: var(--accent); }
    .footer-meta {
      padding: 24px 0 32px;
      border-top: 1px solid #262626;
      font-family: var(--font-mono);
      font-weight: 500;
      font-size: 0.78rem;
      color: #A3A3A3;
      letter-spacing: 0.02em;
      display: flex;
      justify-content: space-between;
      gap: 20px;
      flex-wrap: wrap;
    }

    /* ======================================
       6. ACCESSIBILITY
    ====================================== */
    :focus-visible {
      outline: 2px solid var(--accent);
      outline-offset: 2px;
    }
    .btn:focus-visible { outline-offset: 4px; }

    /* ======================================
       7. ANIMATIONS
    ====================================== */
    .animate-on-scroll {
      opacity: 0;
      transform: translateY(20px);
      transition: opacity 600ms ease, transform 600ms ease;
    }
    .animate-on-scroll.is-visible {
      opacity: 1;
      transform: translateY(0);
    }
    .animate-on-scroll.delay-1 { transition-delay: 80ms; }
    .animate-on-scroll.delay-2 { transition-delay: 160ms; }
    .animate-on-scroll.delay-3 { transition-delay: 240ms; }

    /* ======================================
       8. RESPONSIVE
    ====================================== */
    @media (max-width: 1024px) {
      .stats-grid { grid-template-columns: repeat(2, 1fr); }
      .stats-grid .stat:nth-child(2) { border-right: 0; }
      .stats-grid .stat:nth-child(1),
      .stats-grid .stat:nth-child(2) { border-bottom: 1px solid var(--line); }
      .prose-grid { grid-template-columns: 1fr; gap: 28px; }
      .prose-grid .col-aside { order: 2; }
      .built-list .item { grid-template-columns: 60px 1fr; }
      .built-list .desc { grid-column: 2; }
      .related-grid { grid-template-columns: 1fr; }
      .footer-grid { grid-template-columns: 1.4fr 1fr 1fr; }
      .footer-grid .footer-col:last-child { grid-column: span 3; }
    }
    @media (max-width: 768px) {
      header.site-header > .container { flex-wrap: wrap; padding-bottom: 14px; }
      nav[aria-label="Primary"] {
        order: 3;
        flex-basis: 100%;
        justify-content: flex-start;
        gap: 18px;
        padding-top: 14px;
        border-top: 1px solid var(--line);
        overflow-x: auto;
        white-space: nowrap;
      }
      .stats-grid { grid-template-columns: 1fr; }
      .stats-grid .stat { border-right: 0; border-bottom: 1px solid var(--line); }
      .stats-grid .stat:last-child { border-bottom: 0; }
      .built-list .item {
        grid-template-columns: 48px 1fr;
        grid-template-areas:
          "num title"
          "num desc";
        gap: 12px 16px;
      }
      .built-list .num { grid-area: num; }
      .built-list .title-wrap { grid-area: title; }
      .built-list .desc { grid-area: desc; grid-column: 2; }
      .still-list .row { grid-template-columns: 28px 1fr; gap: 12px; }
      .footer-grid { grid-template-columns: 1fr 1fr; }
      .footer-grid .footer-col:last-child { grid-column: span 2; }
      .footer-meta { flex-direction: column; gap: 8px; }
      .section-head { flex-direction: column; align-items: flex-start; }
      .section-head .meta { text-align: left; }
    }
    @media (max-width: 480px) {
      .footer-grid { grid-template-columns: 1fr; }
      .footer-grid .footer-col:last-child { grid-column: span 1; }
      .related-card { padding: 22px; }
      .testimonial-card { padding: 28px; }
    }

    /* ======================================
       9. REDUCED MOTION
    ====================================== */
    @media (prefers-reduced-motion: reduce) {
      *, ::before, ::after { animation: none !important; transition: none !important; }
      .animate-on-scroll { opacity: 1; transform: none; }
    }

/* ============================================================
   CASE-STUDY BLOB HERO VARIANT (added 2026-05-11)
   Replaces .hero-image-band with typographic-over-blob using
   per-client brand colors via .case-<slug> modifier.
   ============================================================ */
.case-hero-blob { position: relative; isolation: isolate; background: var(--bg); padding-bottom: clamp(48px, 6vw, 80px); }
.case-hero-blob .hero-grain { position: absolute; inset: 0; z-index: -1; background: var(--bg); overflow: hidden; }
.case-hero-blob .blob { position: absolute; border-radius: 50%; filter: blur(120px); }
.case-hero-blob .blob-1 { width: 720px; height: 720px; top: -180px; right: -120px; background: var(--blob-1); opacity: 0.32; }
.case-hero-blob .blob-2 { width: 560px; height: 560px; bottom: -200px; left: -120px; background: var(--blob-2); opacity: 0.42; }
.case-hero-blob .blob-3 { width: 440px; height: 440px; top: 50%; left: 50%; transform: translate(-50%, -50%); background: var(--blob-3); opacity: 0.55; }
.case-hero-blob .blob-4 { width: 360px; height: 360px; bottom: -100px; right: 20%; background: var(--blob-4); opacity: 0.22; }

.case-aagla          { --blob-1: #415F82; --blob-2: #B17D34; --blob-3: #D4B580; --blob-4: #1E3A5F; }
.case-mmp            { --blob-1: #B2292E; --blob-2: #7A1B1F; --blob-3: #E8B5B7; --blob-4: #5C0E12; }
.case-cubex-academy  { --blob-1: #016BFF; --blob-2: #00D9FF; --blob-3: #A8E0F5; --blob-4: #014499; }
.case-jiu            { --blob-1: #7D3B7D; --blob-2: #FFB23C; --blob-3: #F5D9A5; --blob-4: #5C2B5C; }

/* ============================================================
   CONTACT FORM (added 2026-05-12)
   Native form, posts directly to Lead Engine WF1.
   No JS — webhook handles 303-redirect on success.
   ============================================================ */
.contact-form { display: grid; gap: 20px; max-width: 640px; }
.contact-form label { display: grid; gap: 6px; font-family: var(--font-mono); font-size: 0.84rem; letter-spacing: 0.04em; color: var(--text-muted); text-transform: uppercase; }
.contact-form input,
.contact-form textarea { font: inherit; font-family: var(--font-body); font-size: 1rem; padding: 12px 14px; border: 1px solid var(--line); background: var(--bg); border-radius: 0; color: var(--text); text-transform: none; letter-spacing: normal; }
.contact-form textarea { resize: vertical; min-height: 140px; }
.contact-form input:focus,
.contact-form textarea:focus { outline: 2px solid var(--accent); outline-offset: 2px; border-color: var(--accent); }
.contact-form button[type="submit"] { justify-self: start; }

/* --- Footer CTA: headline + button on one row (right-aligned button) ---
   Added 2026-05-13. Wraps the h2 + .btn from footer.php in .footer-cta-row,
   sets flex layout so the button sits next to the copy, with mobile wrap fallback. */
.footer-cta-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 32px;
  flex-wrap: wrap;
  margin-top: 14px;
}
.footer-cta .footer-cta-row h2 { margin: 0; flex: 1 1 320px; }
.footer-cta-row .btn { flex: 0 0 auto; }
@media (max-width: 640px) {
  .footer-cta-row { align-items: flex-start; }
}

/* --- About page: aside-column portrait ---
   Added 2026-05-13. Sits at the top of the Studio Metadata aside on /about/.
   Square image, ~240px display, sharp-edge (0px radius matches Option B). */
.aside-portrait {
  margin: 0 0 28px 0;
  width: 100%;
}
.aside-portrait img {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 1 / 1;
  object-fit: cover;
  border-radius: 0;
}

/* --- About page: optional "How I work" working-shot portrait ---
   Activated when a second image is dropped into the commented <figure> slot
   in page_about.md. Sized as a band-width contextual image, not a portrait. */
.howiwork-portrait {
  margin: 0 0 32px 0;
  max-width: 480px;
}
.howiwork-portrait img {
  display: block;
  width: 100%;
  height: auto;
  border-radius: 0;
}

/* ============================================================
   Journal single-post layout
   Posts in /journal/ ship a hero + journal-body in their content.
   Hide WP's default entry-header/footer/sidebar so the content
   carries the full page.
   ============================================================ */
.single-post .entry-header,
.single-post .entry-footer,
.single-post .post-navigation,
.single-post #secondary,
.single-post .widget-area { display: none; }

.single-post .site-main > article > .entry-content {
    padding: 0;
    margin: 0;
}
.single-post .site-main > article { margin: 0; }
.single-post .site-main { padding: 0; margin: 0; }

/* Base accent-rule (the existing .footer-cta and .still-band scoped
   rules override by specificity, so this is safe). */
.accent-rule {
    display: inline-block;
    width: 48px;
    height: 2px;
    background: var(--accent);
    vertical-align: middle;
    margin-right: 12px;
}

/* Journal body: era markers + reading-column constraint */
.journal-body { padding-top: 32px; }
.journal-body .container { max-width: 760px; }
.journal-body .accent-rule {
    display: block;
    margin: 56px 0 12px;
}
.journal-body > .container > .accent-rule:first-child { margin-top: 0; }
.journal-body .eyebrow { display: block; margin-bottom: 10px; }
.journal-body h2 {
    font-size: clamp(1.6rem, 2.8vw, 2.2rem);
    line-height: 1.15;
    letter-spacing: -0.02em;
    margin: 0 0 22px;
}
.journal-body p {
    margin: 0 0 14px;
    line-height: 1.65;
    color: var(--text);
}
.journal-body p strong { font-weight: 700; color: var(--text); }

/* Hero grain mirrored variant: blob positions flipped left-right.
   Same palette + sizing as default .hero-grain so the look stays
   consistent, just rotated. Use on interior pages that share the
   homepage hero treatment. */
.hero-grain-mirror .blob-1 { right: auto; left: -120px; }
.hero-grain-mirror .blob-2 { left: auto; right: -80px; }
.hero-grain-mirror .blob-3 { left: auto; right: 42%; }
.hero-grain-mirror .blob-4 { right: auto; left: 22%; }

/* Header logo icon (sits next to the SonnenbergDesign wordmark).
   Higher specificity than the generic .logo img rule (120x40) so the
   icon stays compact and aligned with the text. */
.logo-text { align-items: center; gap: 10px; }
.logo img.logo-icon {
    width: 36px;
    height: 36px;
    object-fit: contain;
}
@media (max-width: 640px) {
    .logo img.logo-icon { width: 32px; height: 32px; }
}

/* Subtle rotation on the logo icon on hover. */
.logo img.logo-icon {
    transition: transform 320ms cubic-bezier(0.2, 0.8, 0.2, 1);
}
.logo:hover img.logo-icon,
.logo:focus-visible img.logo-icon {
    transform: rotate(12deg);
}

/* Logo wordmark: swap from Inter Tight (display) to JetBrains Mono.
   Mono needs lighter base weights and zeroed letter-spacing to read
   well at this size. */
.logo-text {
    font-family: var(--font-mono);
    font-size: 1.4rem;
    letter-spacing: 0;
}
.logo-text .logo-thin { font-weight: 400; }
.logo-text .logo-bold { font-weight: 700; }

/* Logo: zero gap so the two wordmark spans sit flush, then put the
   icon's breathing room back via margin-right on the icon itself. */
.logo-text { gap: 0; }
.logo img.logo-icon { margin-right: 10px; }

/* Footer logo: same wordmark treatment as header, both spans white
   to read on the dark band. Sub-line stays the existing muted gray. */
.logo-light .logo-thin,
.logo-light .logo-bold { color: #fff; }
.logo-light { margin-bottom: 4px; }

/* Blank-image placeholder for journal cards that have no featured image.
   Uses the brand gradient (accent → dark) at the same aspect-ratio as
   real images, so card heights stay consistent across the grid. */
.journal-card .img-wrap-blank {
    width: 100%;
    aspect-ratio: 4/3;
    background:
        radial-gradient(circle at 22% 28%, var(--accent) 0%, transparent 60%),
        radial-gradient(circle at 78% 76%, #FFB07A 0%, transparent 55%),
        linear-gradient(135deg, var(--bg-alt) 0%, #1A1A1A 100%);
    border: 1px solid var(--line);
    transition: opacity 240ms ease;
}
.journal-card:hover .img-wrap-blank { opacity: 0.92; }

/* Journal archive: padding around the grid + hide WP defaults that
   the single-post rules already hid, so the category template renders
   clean against the dark band footer. */
.category-journal .site-main { padding: 0; margin: 0; }
.category-journal .post-navigation,
.category-journal #secondary,
.category-journal .widget-area { display: none; }
.journal-archive-body { padding: clamp(56px, 6vw, 96px) 0; }
.journal-archive-body .container { max-width: var(--container); }
.journal-archive-body .posts-navigation { margin-top: 48px; }

/* Reset Underscores' default ul indent + disc bullets inside footer
   columns so the link list aligns flush with the column heading. */
.footer-col ul {
    list-style: none;
    padding: 0;
    margin: 0;
    display: grid;
    gap: 8px;
}
.footer-col li { margin: 0; }

/* Kill the Underscores default `.post, .page { margin: 0 0 1.5em; }`.
   That 1.5em bottom margin sits OUTSIDE any section's background, so
   on pages whose last section has a colored bg (bg-alt, bg-dark) the
   gray/dark block ends and then a 24px strip of body bg shows before
   the footer-CTA dark band. Zero it out site-wide. */
.post, .page { margin: 0; }

/* About / How I Work intro: image left, copy right.
   Uses the SAME column template as .system-index .pillar below so the
   paragraph's left edge lines up with each pillar's "desc" column
   ("Brand and design judgment...", "Drafts I review..."). */
.howiwork-intro {
    display: grid;
    grid-template-columns: 88px 1.2fr 2fr 1.4fr;
    gap: 24px;
    align-items: start;
    margin-bottom: 40px;
}
.howiwork-intro .howiwork-portrait {
    grid-column: 1 / 3;
    margin: 0;
    max-width: none;
}
.howiwork-intro .muted {
    grid-column: 3 / 5;
    margin: 0;
    max-width: 64ch;
    font-size: 1.05rem;
    line-height: 1.6;
    padding-top: 4px;
}
@media (max-width: 768px) {
    .howiwork-intro {
        grid-template-columns: 1fr;
        gap: 24px;
    }
    .howiwork-intro .howiwork-portrait,
    .howiwork-intro .muted {
        grid-column: auto;
    }
}

/* Logo wordmark tuning (2026-05-14): tighten letter-spacing site-wide
   and give "Sonnenberg" a small right-pad so the join with "Design"
   reads as one token without crowding the bold weight. */
.logo-text { letter-spacing: -1px; }
.logo-text .logo-thin { padding-right: 3px; }

/* Value-prop scroll-reveal: each word wrapped in .reveal-word by JS,
   starts muted gray, transitions to brand orange as the user scrolls
   the block through the viewport. Respects prefers-reduced-motion. */
.value-prop .vp-text { color: var(--text-muted); }
.value-prop .vp-text .reveal-word {
    color: inherit;
    transition: color 240ms cubic-bezier(0.2, 0.8, 0.2, 1);
}
.value-prop .vp-text .reveal-word.lit { color: var(--accent); }
@media (prefers-reduced-motion: reduce) {
    .value-prop .vp-text .reveal-word { transition: none; }
}

/* Spacing between stacked testimonial cards when more than one renders. */
.testimonial-card + .testimonial-card { margin-top: 24px; }

/* About page: when the aside column leads with a portrait, drop the
   col-aside top rule + padding. The portrait is the visual anchor;
   the rule is redundant and visually crowds the section divider
   directly above it. */
.prose-grid .col-aside:has(.aside-portrait:first-child) {
    border-top: 0;
    padding-top: 0;
}

/* Search results layout: tighten section padding (the hero already
   carries the top spacing) and hide WP defaults that won't render
   since the template no longer calls get_sidebar(). */
.search .site-main { padding: 0; margin: 0; }
.search-results-body { padding: clamp(56px, 6vw, 96px) 0; }
.search-results-body .posts-navigation { margin-top: 48px; }

/* Search form inside the hero — match the mono/utility feel of the
   design system rather than the browser default. */
.search-hero-form { margin-top: 28px; max-width: 560px; }
.search-hero-form .search-form {
    display: flex;
    gap: 12px;
    align-items: stretch;
    flex-wrap: wrap;
}
.search-hero-form .search-form label {
    flex: 1 1 280px;
    min-width: 0;
    display: flex;
}
.search-hero-form .search-form .search-field {
    flex: 1;
    min-width: 0;
    font-family: var(--font-mono);
    font-size: 0.92rem;
    padding: 12px 16px;
    background: var(--bg);
    border: 1px solid var(--text);
    border-radius: 0;
    color: var(--text);
}
.search-hero-form .search-form .search-field:focus {
    outline: 2px solid var(--accent);
    outline-offset: 2px;
}
.search-hero-form .search-form .search-submit {
    font-family: var(--font-mono);
    font-weight: 500;
    font-size: 0.86rem;
    padding: 12px 22px;
    background: var(--text);
    color: var(--bg);
    border: 1px solid var(--text);
    border-radius: 0;
    cursor: pointer;
    transition: background-color 160ms ease, color 160ms ease;
}
.search-hero-form .search-form .search-submit:hover {
    background: var(--accent);
    border-color: var(--accent);
}

/* Hybrid text-wrap split (2026-05-14, revised same day): h1 + h2 keep
   text-wrap:balance from the base h1/h2/h3 rule for deliberate line
   distribution on hero + section headlines. Only h3 gets pretty —
   smaller subheads tolerate greedy line-breaking without losing the
   "designed" feel. */
h3 { text-wrap: pretty; }

/* ============================================================
   Mobile nav: full-screen overlay with MENU/CLOSE text trigger
   + calendar-icon CTA. Desktop nav + CTA button hide below 900px;
   mobile trigger + icon CTA appear in their place.
   ============================================================ */

/* Defaults: desktop shows full nav + CTA; mobile triggers hidden.
   .mobile-menu visibility is controlled by the [hidden] attribute
   (toggled by mobile-nav.js); browser-default {display:none} on
   [hidden] handles the closed state — don't force display:none here
   or the JS toggle becomes a no-op. */
.menu-toggle,
.cta-mobile-icon { display: none; }
.mobile-menu { display: block; }

/* Menu toggle button — mono text trigger */
.menu-toggle {
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    padding: 0;
    background: transparent;
    border: 1px solid var(--text);
    color: var(--text);
    cursor: pointer;
    transition: background-color 160ms ease, color 160ms ease;
}
.menu-toggle:hover,
.menu-toggle:focus-visible { background: var(--text); color: var(--bg); }
.menu-toggle svg { display: block; }

/* Mobile icon CTA — appears in place of desktop "Schedule a call" */
.cta-mobile-icon {
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    color: #fff;
    background: var(--accent);
    border: 1px solid var(--accent);
    transition: background-color 160ms ease, color 160ms ease;
}
.cta-mobile-icon:hover,
.cta-mobile-icon:focus-visible { background: var(--text); border-color: var(--text); color: var(--bg); }
.cta-mobile-icon svg { display: block; }

/* Full-screen overlay */
.mobile-menu {
    position: fixed;
    inset: 0;
    z-index: 60;          /* above sticky header (z-index 50) */
    background: var(--bg);
    overflow-y: auto;
}
.mobile-menu[hidden] { display: none !important; }
.mobile-menu-inner {
    min-height: 100dvh;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    justify-content: center;
    gap: 12px;
    padding: 96px var(--gutter) 64px;
    max-width: var(--container);
    margin: 0 auto;
}
.mobile-menu-inner a {
    font-family: var(--font-display);
    font-weight: 800;
    font-size: clamp(2rem, 7vw, 3rem);
    line-height: 1.05;
    letter-spacing: -0.04em;
    color: var(--text);
    text-decoration: none;
    transition: color 160ms ease;
}
.mobile-menu-inner a:hover,
.mobile-menu-inner a:focus-visible { color: var(--accent); }
.mobile-menu-inner .mobile-menu-cta {
    margin-top: 32px;
    font-size: 0.92rem;
    font-family: var(--font-mono);
    letter-spacing: 0.02em;
    font-weight: 500;
    text-transform: none;
}

/* Body scroll-lock when overlay is open */
body.mobile-menu-open { overflow: hidden; }

/* Breakpoint: hide desktop nav + CTA, show mobile triggers */
@media (max-width: 900px) {
    header.site-header .nav-primary,
    header.site-header .cta-desktop { display: none; }
    .menu-toggle,
    .cta-mobile-icon { display: inline-flex; }
    header.site-header > .container {
        gap: 12px;
    }
    /* Single-line layout: [LOGO] ............... [CALENDAR] [HAMBURGER]
       Calendar gets margin-left:auto to push the icon group to the
       far right (with hamburger following on its right). Both icons
       use flex-shrink:0 so they keep their square geometry instead of
       compressing. */
    header.site-header .cta-mobile-icon { margin-left: auto; }
    header.site-header .menu-toggle,
    header.site-header .cta-mobile-icon { flex-shrink: 0; }
}

/* Tighter sizing on the smallest phone viewports so the logo +
   calendar + hamburger trio stays on a single line at ~375px width
   (iPhone SE) instead of wrapping. */
@media (max-width: 500px) {
    .logo-text { font-size: 1.05rem; }
    .logo img.logo-icon { width: 30px; height: 30px; margin-right: 8px; }
    .menu-toggle, .cta-mobile-icon { width: 40px; height: 40px; }
    header.site-header > .container { gap: 8px; padding-left: 16px; padding-right: 16px; }
}

/* In-overlay close X — pinned to the EXACT same spot as the hamburger
   .menu-toggle in the header so the X feels like it morphed in place
   from the hamburger. Header padding-top is 16px and the icon button
   is 44×44, so top:16px lines up the centers. Right edge matches the
   container's gutter. The narrower-viewport breakpoint mirrors the
   shrunk hamburger dimensions (40×40, 16px gutter). */
.mobile-menu-close {
    position: absolute;
    top: 16px;
    right: var(--gutter);
    width: 44px;
    height: 44px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: transparent;
    border: 1px solid var(--text);
    color: var(--text);
    cursor: pointer;
    transition: background-color 160ms ease, color 160ms ease;
    z-index: 1;
}
.mobile-menu-close:hover,
.mobile-menu-close:focus-visible { background: var(--text); color: var(--bg); }
.mobile-menu-close svg { display: block; }
@media (max-width: 500px) {
    .mobile-menu-close {
        top: 16px;
        right: 16px;
        width: 40px;
        height: 40px;
    }
}

/* ============================================================
   Mobile homepage tweaks (2026-05-14)
   ============================================================ */

/* Hero: reduce vertical padding on mobile + tone down the blob
   intensity so the background reads more white than orange. */
@media (max-width: 768px) {
    .hero {
        padding: clamp(48px, 8vw, 72px) 0;
    }
    .hero-grain { opacity: 0.4; }
}

/* Pricing table: stack each row on mobile so the table doesn't
   horizontal-overflow. Each row becomes a block with the name on
   top, price on the next line, description after. Name + price
   stay readable; desc wraps naturally. */
@media (max-width: 768px) {
    .pricing-table,
    .pricing-table tbody,
    .pricing-table tr,
    .pricing-table td { display: block; width: 100%; }
    .pricing-table tr {
        padding: 20px 0;
        border-bottom: 1px solid var(--line);
    }
    .pricing-table tr:hover { background: transparent; }
    .pricing-table td {
        padding: 4px 0;
    }
    .pricing-table td:first-child,
    .pricing-table td:last-child {
        padding-left: 0;
        padding-right: 0;
        text-align: left;
    }
    .pricing-table .name { font-size: 1.1rem; margin-bottom: 4px; }
    .pricing-table .price { font-size: 0.92rem; white-space: normal; }
    .pricing-table .desc { font-size: 0.88rem; line-height: 1.5; }
}

/* Pillar-title links get a subtle underline so users (especially on
   mobile where there's no hover) can tell which titles are tappable.
   1px underline at 3px offset on rest, thickens to 2px + accent color
   on hover/focus — same affordance pattern as the existing
   .accent-link class but scoped to pillar titles so the rule only
   fires on title spans that contain a link. */
.system-index .pillar .title a {
    text-decoration: underline;
    text-decoration-thickness: 1px;
    text-underline-offset: 3px;
    transition: text-decoration-thickness 160ms ease, color 160ms ease;
}
.system-index .pillar .title a:hover,
.system-index .pillar .title a:focus-visible {
    text-decoration-thickness: 2px;
    color: var(--accent-link);
}
