:root {
    --ink:    #1a1a18;
    --muted:  #6b6b60;
    --rule:   #e0ddd6;
    --bg:     #f7f6f2;
    --white:  #ffffff;
    --red:    #c0392b;
    --green:  #2d5a3d;
    --tag-bg: #edeae3;
  }

  * { box-sizing: border-box; }

  html, body {
    height: 100%;
    margin: 0;
    overflow: hidden;
    overscroll-behavior: none;
  }

  body {
    font-family: 'DM Sans', sans-serif;
    background: var(--bg);
    color: var(--ink);
    position: relative;
  }

  /* ── ambient background — disabled, didn't match the rest of the site ── */
  .ambient { display: none; }

  /* ── return home button ── */
  .home-btn {
    position: fixed;
    top: clamp(0.9rem, 2.4vh, 1.6rem);
    left: clamp(1.2rem, 3vw, 2.4rem);
    z-index: 20;
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    font-size: clamp(0.66rem, 1.4vh, 0.75rem);
    font-weight: 500;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--ink);
    text-decoration: none;
    border: 1px solid var(--ink);
    padding: 0.5rem 0.9rem;
    border-radius: 999px;
    background: rgba(254,252,245,0.7);
    backdrop-filter: blur(4px);
    transition: background 0.2s, color 0.2s, transform 0.2s;
  }
  .home-btn:hover {
    background: var(--ink);
    color: var(--white);
    transform: translateX(-2px);
  }
  .home-btn svg { width: 13px; height: 13px; flex-shrink: 0; }

  /* ── page frame ── */
  .page {
    position: relative;
    z-index: 1;
    height: 100vh;
    height: 100dvh;
    display: flex;
    flex-direction: column;
    padding: clamp(3.4rem, 8vh, 4.6rem) clamp(1.2rem, 4vw, 4rem) clamp(0.8rem, 2vh, 1.4rem);
    gap: clamp(0.6rem, 1.6vh, 1.1rem);
  }

  /* ── HERO ── */
  .z-hero { max-width: 860px; flex: 0 0 auto; }
  .z-eyebrow {
    font-size: clamp(0.68rem, 1.5vh, 0.8rem);
    font-weight: 500;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: var(--green);
    margin: 0 0 clamp(0.4rem, 1vh, 0.7rem);
    opacity: 0;
    animation: rise 0.6s 0.05s ease forwards;
  }
  .z-hero h1 {
    font-family: 'Playfair Display', serif;
    font-size: clamp(1.7rem, 4.6vh, 2.6rem);
    font-weight: 600;
    line-height: 1.12;
    color: var(--ink);
    margin: 0 0 clamp(0.4rem, 1vh, 0.7rem);
    opacity: 0;
    animation: rise 0.6s 0.15s ease forwards;
  }
  .z-hero h1 em { font-style: italic; font-weight: 400; }
  .z-hero-sub {
    font-size: clamp(0.85rem, 1.85vh, 1.02rem);
    line-height: 1.55;
    color: var(--muted);
    max-width: 580px;
    margin: 0;
    opacity: 0;
    animation: rise 0.6s 0.25s ease forwards;
  }
  @keyframes rise {
    from { opacity: 0; transform: translateY(10px); }
    to   { opacity: 1; transform: translateY(0); }
  }

  /* ── MAIN TWO COLUMN AREA ── */
  .z-body {
    flex: 1 1 auto;
    min-height: 0;
    display: flex;
    gap: clamp(1.2rem, 3vw, 2.6rem);
    border-top: 2px solid var(--ink);
    padding-top: clamp(0.6rem, 1.6vh, 1rem);
  }

  .z-panel {
    display: flex;
    flex-direction: column;
    min-height: 0;
    min-width: 0;
  }
  /* 58/42 split between Felder and Kriterien panels */
  .z-fields-panel { flex: 1 1 58%; border-right: 1px solid var(--rule); padding-right: clamp(1.2rem, 3vw, 2.6rem); }
  .z-criteria-panel { flex: 1 1 42%; max-width: 520px; }

  .panel-head {
    flex: 0 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.8rem;
    padding-bottom: clamp(0.6rem, 1.4vh, 0.9rem);
    border-bottom: 1px solid var(--rule);
    flex-wrap: wrap;
  }
  .z-col-label {
    font-size: clamp(0.66rem, 1.3vh, 0.74rem);
    font-weight: 500;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: var(--muted);
    margin: 0;
    white-space: nowrap;
  }

  /* stepper controls (shared by Felder and Kriterien panels) */
  .stepper-nav { display: flex; align-items: center; gap: 0.55rem; flex-wrap: wrap; justify-content: flex-end; }
  .step-arrow {
    width: clamp(24px, 3.6vh, 30px);
    height: clamp(24px, 3.6vh, 30px);
    border-radius: 50%;
    border: 1px solid var(--rule);
    background: transparent;
    color: var(--ink);
    font-size: 0.95rem;
    line-height: 1;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s, color 0.2s, border-color 0.2s;
    flex-shrink: 0;
  }
  .step-arrow:hover { background: var(--ink); color: var(--white); border-color: var(--ink); }
  .step-dots { display: flex; gap: 0.35rem; flex-wrap: wrap; justify-content: flex-end; }
  .dot {
    font-size: clamp(0.66rem, 1.3vh, 0.76rem);
    font-weight: 500;
    letter-spacing: 0.02em;
    color: var(--muted);
    background: transparent;
    border: 1px solid var(--rule);
    padding: 0.3rem 0.7rem;
    border-radius: 999px;
    cursor: pointer;
    white-space: nowrap;
    transition: background 0.2s, color 0.2s, border-color 0.2s;
  }
  .dot.active { background: var(--ink); color: var(--white); border-color: var(--ink); }
  .dot:not(.active):hover { border-color: var(--ink); color: var(--ink); }

  /* criteria tabs (right panel) — sits inside .stepper-nav alongside its own
     prev/next arrows. The 42%-width panel doesn't have room for 4 pills to
     wrap cleanly, so this stays a single scrollable line at ALL widths
     (not just mobile) — roughly 3 tabs show fully, the 4th is one arrow
     click or a scroll away. */
  .z-criteria-panel .stepper-nav { flex-wrap: nowrap; min-width: 0; }
  .crit-tabs {
    display: flex;
    flex-wrap: nowrap;
    gap: 0.4rem;
    justify-content: flex-start;
    flex: 1 1 auto;
    min-width: 0;
    overflow-x: auto;
    scrollbar-width: none;
    -ms-overflow-style: none;
    -webkit-overflow-scrolling: touch;
    padding: 0.15rem 0;
  }
  .crit-tabs::-webkit-scrollbar { display: none; }
  .crit-tab {
    font-size: clamp(0.68rem, 1.3vh, 0.76rem);
    font-weight: 500;
    color: var(--muted);
    background: transparent;
    border: 1px solid var(--rule);
    padding: 0.3rem 0.6rem;
    border-radius: 999px;
    cursor: pointer;
    white-space: nowrap;
    flex-shrink: 0;
    transition: background 0.2s, color 0.2s, border-color 0.2s;
  }
  .crit-tab.active { background: var(--green); color: var(--white); border-color: var(--green); }
  .crit-tab:not(.active):hover { border-color: var(--green); color: var(--green); }

  /* ── STAGE (slide container) ── */
  .stage { position: relative; flex: 1 1 auto; min-height: 0; }
  .slide {
    position: absolute;
    inset: 0;
    display: flex;
    flex-direction: column;
    justify-content: center;
    opacity: 0;
    transform: translateY(10px);
    pointer-events: none;
    transition: opacity 0.45s ease, transform 0.45s ease;
  }
  .slide.active {
    opacity: 1;
    transform: translateY(0);
    pointer-events: auto;
  }

  /* field slide content */
  .field-slide { padding-right: clamp(0.5rem, 2vw, 1.5rem); }
  .z-num {
    font-size: clamp(0.6rem, 1.2vh, 0.65rem);
    font-weight: 500;
    letter-spacing: 0.1em;
    color: var(--muted);
    display: block;
    margin-bottom: clamp(0.4rem, 1vh, 0.7rem);
  }
  .field-slide h2 {
    font-family: 'Playfair Display', serif;
    font-size: clamp(1.3rem, 3vh, 1.85rem);
    font-weight: 600;
    line-height: 1.2;
    color: var(--ink);
    margin: 0 0 clamp(0.55rem, 1.5vh, 1rem);
  }
  .field-body {
    font-size: clamp(0.9rem, 1.85vh, 1.06rem);
    line-height: 1.65;
    color: var(--muted);
    margin: 0 0 clamp(0.8rem, 2vh, 1.2rem);
    max-width: 62ch;
  }
  .z-tags { display: flex; flex-wrap: wrap; gap: 0.4rem; }
  .z-tag {
    font-size: clamp(0.7rem, 1.4vh, 0.8rem);
    background: var(--tag-bg);
    color: var(--ink);
    padding: 0.28rem 0.65rem;
    border-radius: 2px;
  }

  /* conviction slide */
  .conviction-slide {
    background: var(--ink);
    color: var(--white);
    margin: -1.4rem;
    padding: clamp(1.4rem, 4vh, 2.4rem);
    border-radius: 4px;
  }
  .conviction-label {
    font-size: clamp(0.6rem, 1.2vh, 0.66rem);
    font-weight: 500;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: rgba(255,255,255,0.45);
    margin-bottom: clamp(0.5rem, 1.4vh, 0.8rem);
  }
  .conviction-slide h2 {
    font-family: 'Playfair Display', serif;
    font-size: clamp(1.3rem, 3vh, 1.85rem);
    font-weight: 600;
    color: var(--white);
    margin: 0 0 clamp(0.65rem, 1.6vh, 1rem);
  }
  .conviction-slide p {
    font-size: clamp(0.9rem, 1.85vh, 1.04rem);
    line-height: 1.65;
    color: rgba(255,255,255,0.65);
    margin: 0 0 clamp(0.5rem, 1.3vh, 0.8rem);
    max-width: 58ch;
  }
  .conviction-slide p:last-child { margin-bottom: 0; }

  /* criteria rows */
  .crit-slide { justify-content: flex-start; padding-top: clamp(0.6rem, 1.6vh, 1rem); }
  .crit-slide h3 {
    font-family: 'Playfair Display', serif;
    font-size: clamp(1rem, 2.2vh, 1.2rem);
    font-weight: 600;
    color: var(--ink);
    margin: 0 0 clamp(0.55rem, 1.5vh, 1rem);
  }
  .crit-row {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    padding: clamp(0.34rem, 1vh, 0.55rem) 0;
    border-bottom: 1px solid var(--rule);
    gap: 1rem;
  }
  .crit-row:last-child { border-bottom: none; }
  .cr-label { font-size: clamp(0.82rem, 1.65vh, 0.95rem); color: var(--muted); flex-shrink: 0; }
  .cr-value { font-size: clamp(0.82rem, 1.65vh, 0.95rem); font-weight: 500; color: var(--ink); text-align: right; }

  .qual-item {
    display: flex;
    gap: 0.65rem;
    padding: clamp(0.36rem, 1vh, 0.6rem) 0;
    border-bottom: 1px solid var(--rule);
    align-items: flex-start;
  }
  .qual-item:last-child { border-bottom: none; }
  .qual-dot {
    width: 5px; height: 5px; border-radius: 50%;
    background: var(--green);
    flex-shrink: 0;
    margin-top: 0.5rem;
  }
  .qual-dot.red { background: var(--red); }
  .qual-text { font-size: clamp(0.8rem, 1.6vh, 0.92rem); line-height: 1.55; color: var(--muted); }
  .qual-text strong { color: var(--ink); font-weight: 500; }

  /* ── FOOTER CTA ── */
  .z-cta {
    flex: 0 0 auto;
    margin-top: clamp(0.3rem, 0.9vh, 0.6rem);
    padding: clamp(0.55rem, 1.3vh, 0.85rem) clamp(1rem, 2.4vw, 1.6rem);
    background: var(--ink);
    color: var(--white);
    border-radius: 4px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1.2rem;
    flex-wrap: wrap;
  }
  .z-cta h3 {
    font-family: 'Playfair Display', serif;
    font-size: clamp(0.85rem, 1.7vh, 1rem);
    font-weight: 600;
    margin: 0 0 0.15rem;
  }
  .z-cta p { font-size: clamp(0.68rem, 1.3vh, 0.76rem); opacity: 0.55; margin: 0; line-height: 1.4; }
  .z-cta-btn {
    flex-shrink: 0;
    display: inline-block;
    background: var(--white);
    color: var(--ink);
    text-decoration: none;
    font-size: clamp(0.68rem, 1.3vh, 0.76rem);
    font-weight: 500;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    padding: clamp(0.42rem, 1vh, 0.6rem) clamp(0.85rem, 1.8vw, 1.3rem);
    border-radius: 999px;
    transition: background 0.2s, color 0.2s;
  }
  .z-cta-btn:hover { background: var(--green); color: var(--white); }

  /* ── RESPONSIVE (narrow) ── */
  @media (max-width: 860px) {
    .page { padding-top: clamp(3rem, 7vh, 3.6rem); }
    .home-btn span.txt { display: none; }
    .z-hero-sub { display: none; }
    .z-body { flex-direction: column; gap: clamp(0.5rem, 1.4vh, 0.9rem); }
    .z-fields-panel { border-right: none; border-bottom: 1px solid var(--rule); padding-right: 0; padding-bottom: clamp(0.5rem, 1.4vh, 0.9rem); flex: 1 1 58%; }
    .z-criteria-panel { flex: 1 1 42%; max-width: none; }
    .crit-tabs { justify-content: flex-start; }
    .conviction-slide { margin: -0.6rem; }

    /* keep prev/dots/next stepper on one line for BOTH panels: dots/tabs scroll
       horizontally instead of wrapping, mirroring the Felder stepper exactly */
    .panel-head { flex-wrap: nowrap; }
    .stepper-nav {
      flex-wrap: nowrap;
      width: 100%;
      min-width: 0;
    }
    .step-arrow { flex-shrink: 0; }
    .step-dots {
      flex-wrap: nowrap;
      flex: 1 1 auto;
      min-width: 0;
      overflow-x: auto;
      justify-content: flex-start;
      scrollbar-width: none;
      -ms-overflow-style: none;
      -webkit-overflow-scrolling: touch;
      padding: 0.15rem 0;
    }
    .step-dots::-webkit-scrollbar { display: none; }
    .dot { flex-shrink: 0; }
    /* .crit-tabs single-line/scroll behavior is now applied at all widths,
       see the base (non-media) rule above — nothing extra needed here. */
  }

  /* ── RESPONSIVE (mobile & tablet): allow this page to scroll ── */
  @media (max-width: 1024px) {
    html, body {
      height: auto;
      overflow-y: auto;
      overflow-x: hidden;
      overscroll-behavior: auto;
      -webkit-overflow-scrolling: touch;
    }
    .page {
      height: auto;
      min-height: 100vh;
      min-height: 100dvh;
    }
    .z-body { overflow: visible; }
    .z-panel { min-height: auto; }
    .stage {
      position: relative;
      height: auto;
      min-height: 0;
    }
    .slide {
      position: relative;
      inset: auto;
      display: none;
      transform: none;
      pointer-events: none;
    }
    .slide.active {
      display: flex;
      opacity: 1;
      pointer-events: auto;
    }
  }

  @media (prefers-reduced-motion: reduce) {
    .ambient::before, .ambient::after { animation: none; }
    .z-eyebrow, .z-hero h1, .z-hero-sub { animation: none; opacity: 1; }
    .slide { transition: opacity 0.2s ease; }
  }
