/* =========================
   TOKENS
========================= */
:root {
  /* Frame + surfaces */
  --frame: #000;
  --surface: #fff;
  --text: #111;

  /* Stage Definitions */
  --header-height: 125px;        /* AWD sticky header height */
  --frame-thickness: calc(var(--frame-pad) * 2); 
  --stage-height: calc(
    100svh
    - var(--header-height)
    - var(--frame-thickness)
  );

  /* Brand */
  --color-primary: #000;  /* Core brand / text */
  --color-secondary: #C3C3C3;  /* Neutral surfaces, dividers */
  --color-accent:  #FA4D7E;  /* Emphasis / highlights */

  /* Interaction */
  --color-focus:  #D7154D;  /* Focus rings, active states */
  --color-control: #23CDCD;  /* Controls, affordances */


  /* Layout */
  --frame-pad: 20px;
  --container-max: 1100px;
  --gap-1: 12px;
  --gap-2: 20px;
  --gap-3: 30px;
  --gap-4: 50px;
  --gap-5: 200px;
  --half-width: 50%;  

  --header-min: 64px;



  /* Overlay */
  --overlay-bg: rgba(42, 41, 41, 0.8);
  /*--overlay-triangle-bg: rgba(0, 0, 0, 0.29);*/
  --overlay-triangle-bg: rgba(0, 0, 0, 0.35);
  --overlay-pad: 20px;
  --overlay-col2-min: 450px;

  /* Overlay animation */
  --overlay-triangle-enter-duration: 140ms;
  --overlay-triangle-enter-ease: cubic-bezier(0.2, 0.8, 0.2, 1);
  --overlay-panel-enter-delay: 140ms;
  --overlay-panel-enter-duration: 180ms;
}

 /* Phase 1, Layer 3 overlay */
.layer-3 {
  /* ========================= */
  /* Typography Tokens */
  /* ========================= */

  --cs-font-body: 0.875rem;      /* 14px — Layer 3 default */
  --cs-font-body-lg: 1rem;       /* 16px — fallback / future switch */
  --cs-font-h4: 1.375rem;        /* 22px */
  --cs-font-tagline: 1.375rem;   /* 22px */
  --cs-font-reflection: 1.25rem; /* 20px */

  --cs-line-body: 1.5;           /* ~21–24px depending on size */
  --cs-line-tagline: 25px;
  --cs-line-reflection: 32px;

  /* ========================= */
  /* Spacing Tokens */
  /* ========================= */

  --cs-section-gap: 140px; /* B → C → D → E */

  --gap-xs: 8px;
  --gap-sm: 16px;  /* e1 + e2 */
  --gap-md: 20px;
  --gap-lg: 24px;
  --gap-xl: 42px;

  --space-block-sm: 100px; /* composite internal spacing */

  /* ========================= */
  /* Media Tokens */
  /* ========================= */

  --cs-img-ratio: 4 / 3;
  --cs-img-thumb-w: 200px;
  --cs-img-thumb-h: 150px;

  /* ========================= */
  /* Container Tokens */
  /* ========================= */

  --e-block-padding: 0;
}


/* =========================
   BASE
========================= */
/* resets, primitives */

* { box-sizing: border-box; }

/* html, body { min-height: 100vh; overflow: hidden; } This causes mobile to lock after scrolling */

html, body {
  min-height: 100vh;
}

/* Desktop-only scroll locking */
@media (hover: hover) and (pointer: fine) {
  html, body {
    overflow: hidden;
  }
}


body.long-page {
  overflow: auto;
}

body {
  margin: 0;

  background: transparent;      /* black frame */
  padding: var(--frame-pad);     /* fixed 20px frame */
  font-family: var(--font-sans);
  color: var(--text);
  box-sizing: border-box;
  font-size: 16px;
  font-weight: 400;
}

a {
  color: var(--color-primary);
  cursor: pointer;
  /*padding: 5px;*/
}

a:hover {
  color: var(--color-accent);
}

a.is-active {
  color: #ADADAD;
}

/* Fixed viewport frame */
    .frame {
      position: fixed;
      top: 0;
      right: 0;
      bottom: 0;
      left: 0;

      box-sizing: border-box;
      border: var(--frame-pad) solid #FA4D7E;
      background: transparent;

      pointer-events: none;
      z-index: 99;
    }


/* Media primitive */
.media-slot {
  width: 100%;
  aspect-ratio: 3 / 2; /* or 16 / 10 — pick one */
  background: #eee;    /* subtle fallback */
  overflow: hidden;
}

.media-slot > img,
.media-slot > svg {
  width: 100%;
  height: 100%;
  object-fit: cover;   /* fill without distortion */
  object-position: top center;
  display: block;
}

a { color: inherit; }
img, svg { max-width: 100%; height: auto; display: block; }

/* The website lives inside the frame */
.site {
  background: var(--surface);
  padding: 0 var(--gap-4);
}

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

/* Centering container that stays fluid */
.container {
  max-width: var(--container-max);
  margin-inline: auto;
  padding: var(--gap-3);
}

.section > .container {
  min-height: 100%;
  display: grid;
  place-items: center;
  padding: clamp(2rem, 4vw, 6rem);
}

.visually-hidden {
  visibility: hidden;
  display: none;
}

/* =========================
   COMPONENTS
========================= */

/* LOGO */
.logo {
  width: auto;
  height: 2.1875rem; /* 35px at 16px base */
  display: block;
}

/* PRIMARY BUTTON */
.primary-btn {
  appearance: none;
  background-color: #000;
  border: 0;
  padding: 24px 48px;
  font: inherit;
  text-decoration: none;
  cursor: pointer;
  color: #fff;
  font-family: var(--font-serif);
  font-size: 1.5rem;
  text-transform: uppercase;
}
.primary-btn:focus-visible {
  outline: 2px solid currentColor;
  outline-offset: 3px;
  background-color: #fff;
  color: #000;
}

.primary-btn:hover {
  color: #000;
  background-color: #fff;
  box-shadow: 0 1px 2.4px rgba(0, 0, 0, 0.25);
}

/* TEXT LINK BUTTON */
.link-btn {
  appearance: none;
  background-color: transparent;
  cursor: pointer;
  color: var(--color-accent); 
  font-family: var(--font-sans);
  padding: 0 0 0 5px;
}
/*
.link-btn:focus-visible {
  outline: 2px solid currentColor;
  outline-offset: 3px;
  color: #000;
}
  */

.link-btn:hover {
  color: #000;
}

/* GLOBAL HEADER */
.global-header {
  position: sticky;
  z-index: 10; /* above page content, below overlay */
  background: var(--surface);
}

.global-header .header-inner {
  min-height: var(--header-min);
  display: flex;
  align-items: end;
  justify-content: space-between;
  flex-direction:row;
  padding: 30px;
  gap: 10px;
}
/* move to a token (ChatGPT: CSS Media Query nesting */
@media (max-width: 768px) {
  .global-header .header-inner {
    flex-direction: column;
    align-items: center;
  }
}

.designer-name {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.designer-name a {
  text-decoration: none;
  color: initial;
}

.designer-name p {
  text-transform: uppercase;
  padding: 0;
  margin: 0;
}

.designer-name p:last-child {
  color:#868686;
}

.global-nav__list {
  display: flex;
  list-style: none;
  gap: 0;
  padding: 0;
  margin: 0;
  justify-content: end;
}

.global-nav__list li + li::before {
  content: "/";
  margin-inline: 15px;
  opacity: 0.4;
}

.global-nav__list li {
  font-size: 14px;
  text-transform: uppercase;
}

.global-nav__list li a {
  text-decoration: none;
}

@media (max-width: 768px) {
  .designer-name {
  flex-direction: row;
  gap: 8px;
}

  .global-nav__list {
    justify-content: center;
  }
}


/* CARDS */

/* List reset */
.card ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

/* List items */
.card li {
  margin: 0.15rem 0;
  line-height: 1.5;
}

/* Toggle Switch */
.toggle-switch {
  width: 100%;
  display: flex;
  justify-content: end;
}
.toggle-switch li {
  display: inline-block;
  cursor: pointer;
  color: #868686;
  text-transform: uppercase;
}

.toggle-switch li + li::before {
    content: "/";
    margin-inline: 15px;
    opacity: 0.4;
}

.toggle-switch li.active {
  color: #FA4D7E;
}

/* Toggle visibility */
.toggle-wrapper[data-visible="false"] {
  display: none;
}

.toggle-wrapper[data-visible="true"] {
  display: block;
}

/* =========================
   PHASE 1 INTRO PAGE LAYOUT - REMOVE PHASE 2 LAUNCH
========================= */
.intro-main {
  display: grid;
  gap: var(--gap-3);
}

/* Row 1: centered single column, tall */
.intro-hero {
  min-height: min(75vh, 720px);
  display: grid;
  align-content: center;
  place-items: center;
  text-align: center;
  padding: var(--gap-4) var(--gap-3);
}

.intro-hero .media-slot {
  max-width: 275px;
}


/* Row 2: 2 columns (stack <=768) */
.two-col {
  display: grid;
  grid-template-columns: 50% 50%;
}

.two-col > :first-child {
  justify-self: start;
}

.two-col > :last-child {
  justify-self: end;
  align-self: end;
}

@media (max-width: 768px) {
  .two-col {
    grid-template-columns: 1fr;
  }
  .two-col .right {
    justify-self: start;
    align-self: end;
  }
}

/* =========================
   CONTEXTUAL OVERRIDES
========================= */

.global-header .logo {
  max-width: 120px;
}


/* =========================
   NAVIGATION
========================= */
.content-rail {
  will-change: transform;
}

#content-rail[data-locked="true"] {
  overflow: hidden;
  pointer-events: none;
}


/* =========================
   LONG PAGE SECTIONS
========================= */
.page-main {
  display: grid;
  gap: 0;
}


.section {
  min-height: var(--stage-height);
  height: var(--stage-height);
  padding: 0;
  margin: 0;
}

/*
.section + .section {
  margin-top: var(--gap-5); /* ample whitespace between sections *
}

* Last section has no whitespace below it *
.section:last-child {
  padding-bottom: var(--gap-3);
  margin-bottom: var(--gap-4);
}
*/

/* =========================
   TYPOGRAPHY
========================= */
h1, h2, h3, h4, p, .subtitle, .caption {
  margin: 0;
}

h1 {
  font-family: var(--font-serif);
  font-size: 1.875rem;

 }

 h2 {
  font-family: var(--font-serif);
  font-size: 2.5rem;
  line-height: auto;

  color: var(--color-accent);
 }

 @media (max-width: 768px) {
 h2 {
    font-size: 2.3rem;
    line-height: 40px;
  }
}
 


 h3, dt {
  text-transform: uppercase;
  line-height: auto;
  letter-spacing: 0.01em;
  font-weight: bold;
 }

 h3 {
  font-size: 1.875rem;
  border-bottom: 1px solid #000;
  padding: 10px 0;
 }

 p {
  font-family: var(--font-sans);
  line-height: 1.5625rem;
  margin: 0 0 1.5rem 0;
  font-weight: 300;
 }


/* ===== HEADING PATTERN ===== */

/* Section heading wrapper */
.section-heading {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
}


.heading-main {
  font-family: var(--font-sans);
  font-weight: 900;
  line-height: var(--lh-tight);
  letter-spacing: var(--ls-tight);
  text-transform: uppercase;
  color: var(--color-primary);
}

.heading-accent {
  font-family: var(--font-serif-text);
  font-style: italic;
  font-weight: 400;
  letter-spacing: var(--ls-script);
  color: #ff4f87;
  margin-top: -16px;
}

/* Scale Modifiers */

.heading--display .heading-main {
  font-size: var(--type-display);
}

.heading--display .heading-accent {
  font-size: calc(var(--type-display) * 0.85);
  margin-top: -16px;
}

.heading--h1 .heading-main {
  font-size: var(--type-h1);
}

.heading--h1 .heading-accent {
  font-size: calc(var(--type-h1) * 0.85);
  margin-top: -12px;
}

.heading--h2 .heading-main {
  font-size: var(--type-h2);
}

.heading--h2 .heading-accent {
  font-size: calc(var(--type-h2) * 0.85);
  margin-top: -8px;
}

/* Mobile Behavior for System Headings (Proportional scale) */
@media (max-width: 768px) {
  :root {
    --type-display: 42px;
    --type-h1: 36px;
    --type-h2: 28px;
    --type-body-lg: 20px;
  }
}

/* =========================
   WORK SECTION
========================= */
.projects-wrapper {
  width: 100%;
}

#project-list {
  height: 560px;
  overflow: scroll;
}

article.project-card {
  display: flex;
  gap: 2rem;
  flex-direction: row;
  align-items: center;
  min-width: 0; /* important in flex layouts */
  border-bottom: 1px solid #F2F2F2;
  box-sizing: border-box;
  padding: 20px 0;
}

article.project-card div {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

article.project-card p {
  margin: 0;
}

article.project-card img {
  width: 300px;
  height: 200px;
  object-fit: cover;
}

/* move to a token (ChatGPT: CSS Media Query Nesting) */
@media (max-width: 768px) {
  article.project-card {
    flex-direction: column;
    align-items: start;
    padding: 0 0 20px;
    gap: 1.2rem;
  }
  article.project-card img {
  width: 100%;
}
}

/* =========================
   SERVICES SECTION
========================= */
.cards {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: var(--gap-3);
  align-items: stretch;
  width: 100%;
}

.card {
  padding: var(--gap-3) 0;
}

header .tagline {
  font-size: 1.375rem;
}

@media (max-width: 768px) {
  .cards { grid-template-columns: 1fr; }
}

@media (max-width: 480px) {
  .section header h2 {
    font-size: 1.875rem;
  }
  .section header p {
    display: none;
  }
  .section .container .cards {
    gap: 0;
  }
  .section .container .cards .card {
    padding-bottom: 0;
  }
  .section .container .cards .card h3 {
    font-size: 1.375rem;
    padding-bottom: 8px;
    margin-bottom: 8px;
  }
}

/* =========================
   ABOUT SECTION
========================= */

.media {
  display: grid;
  grid-template-columns: minmax(180px, 1fr) 2fr;
  gap: var(--gap-3);
  align-items: start;
}

.about p {
  margin: 0.875rem 0 1.5rem 0;
}

.about-footer {
  display: flex;
  justify-content: flex-end;
  margin-top: var(--gap-3);
  width: 100%;
}

.about-me {
  flex-direction: row;
  align-items: end;
}

.about-me .heading-accent {
  line-height: 30px;
}

@media (max-width: 768px) {
  .media { grid-template-columns: 1fr; }
  .about-footer { justify-content: center; }
  .pad-about { padding:0; }
}

@media (max-width: 480px) {
  .section .container .about {
    padding: 0;
  }
  .section .container .about img {
    margin: 0 auto
  }
  .section .container .about p:last-child {
    display: none;
  }
}



/* =========================
   TEXT STYLE TOKENS
========================= */

.logotext {
  font-family: var(--font-sans);
  font-size: 1rem;
  font-weight: 400;
}

@media (max-width: 768px) {
  .logotext {
    font-size: 1rem;
    text-align: center;
  }
}

.tagline {
  font-family: var(--font-sans);
  font-size: 1.5rem;
  font-optical-sizing: auto;
  font-weight: 300;
  line-height: 1.3;
}






/* =========================
   WIREFRAME DEBUG LAYERS
   (blue = structure, green = padding stripes)
========================= */
.wf-structure { background: var(--wf-blue); }
.wf-padding   { background: var(--wf-green); }
.wf-region    { background: var(--wf-red); }

/* =========================
   PADDING & ALIGNMENT
========================= */
.pad {
  padding: var(--gap-3);
}
.pad-lg {
  padding: var(--gap-4);
}

.pad-vt {
  padding-top: var(--gap-4);
  padding-bottom: var(--gap-4);
}

.pad-about {
  padding: var(--gap-3) 150px; 
}

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

/* =========================
   TYPOGRAPHY PLACEHOLDERS
========================= */
.ph-title,
.ph-subtitle,
.ph-paragraph,
.ph-chip {
  background: var(--ph);
  border-radius: 6px;
}

.ph-title {
  height: 22px;
  width: min(520px, 90%);
}
.ph-subtitle {
  height: 16px;
  width: min(420px, 80%);
}
.ph-paragraph {
  height: 92px;
  width: min(520px, 100%);
}
.ph-chip {
  display: inline-block;
  height: 18px;
  width: 120px;
}

/* Image / SVG placeholder (box with X) */
.ph-media {
  background: var(--ph-strong);
  /*aspect-ratio: 16 / 9;*/
  position: relative;
  overflow: hidden;
}
.ph-media::before,
.ph-media::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(45deg, transparent 49%, rgba(0,0,0,0.25) 50%, transparent 51%),
    linear-gradient(-45deg, transparent 49%, rgba(0,0,0,0.25) 50%, transparent 51%);
}


/* ======================================================
   LAYER 3 — CASE STUDY OVERLAY (Phase 1)
   Do not refactor existing styles above this line
====================================================== */

/* ======================================================
   LAYER 3 — CASE STUDY OVERLAY (Phase 1)
====================================================== */

.layer-3-overlay {
  position: fixed;
  inset: 0;
  z-index: 9999;
  display: none;
}

.layer-3-overlay.is-open {
  display: block;
}

/* Frame */
.layer-3-frame {
  position: fixed;
  inset: 0;
  background: var(--near-black, #313131);
}

/* Close button */
.layer-3-close {
  position: absolute;
  top: 16px;
  right: 16px;
  padding: 20px;
  background: transparent;
  border: none;
  color: #fff;
  font-size: 20px;
  cursor: pointer;
}

/* Watermark */
.layer-3-watermark {
  position: absolute;
  right: 2rem;
  bottom: 2rem;
  opacity: 1;
  pointer-events: none;
}

/* Stage */
.layer-3-stage {
  position: absolute;
  inset: 0;
  margin: auto;
  width: 80vw;
  height: 80vh;
  background: #fff;
  overflow-y: auto;
  box-shadow: 0 10px 40px rgba(0,0,0,0.35);
}



/* ================================
   Layer 3 stage content
================================ */

/* No section owns margins */
.layer-3 .cs-section {
  display: block;
}

.layer-3 .cs-section + .cs-section {
  margin-top: var(--cs-section-gap);
}

/* No margins */
.layer-3 .e-block {
  padding: var(--e-block-padding);
  box-sizing: border-box;
}

/* Non-composite e-blocks */
.layer-3 .e-block {
  padding: var(--e-block-padding);
  box-sizing: border-box;
}
/* Per block example */
.layer-3 .e-block--e2 {
  --e-block-gap: var(--gap-sm); /* 16px */
}

/* ================================
   Layer 3 Component Layout Primitives
================================ */

/* e2 - Image + Paragraph side by side */
.layer-3 .e2 {
  display: flex;
  gap: var(--gap-md); /* 20px */
  align-items: flex-start;
}

.layer-3 .e2-media img {
  width: 200px;
  max-width: none;
  height: 150px;
  object-fit: cover;
}

/* Composite Block Contract */
.layer-3 .e-block--composite .e-stack {
  display: flex;
  flex-direction: column;
}
/* Composite Internal Spacing (allowed margin usage HERE ONLY for Composite blocks */
.layer-3 .e-block--composite .e6 {
  margin-bottom: var(--space-block-sm);
}

.layer-3 .e-block--composite .e3 {
  margin-bottom: var(--space-block-sm);
}

.layer-3 .e-block--composite .e7 {
  margin-bottom: var(--space-block-sm);
}

.btn-primary-small {
  border: 0;
    padding: 8px 35px;
    background-color: #000;
    color: white;
    font-family: var(--font-serif);
    text-transform: uppercase;
    font-size: 1rem;
    letter-spacing: 1px;
    margin-top: 10px;
    display: inline-block;
}

.btn-primary-small:hover {
    background-color: #fff;
    color: #000;
    filter: drop-shadow(1px 1px 1px rgba(0, 0, 0, 0.2));
}

/* ================================
   Layer 3 Visibility Hooks
================================ */

.layer-3 [data-summary] {
  display: block;
}

.layer-3 [data-description] {
  display: block;
}

/* ================================
   Layer 3 Typography (.layer-3 scope)
================================ */
.layer-3 h2 {
  text-align: center;
  padding-top: 20px;
}

.layer-3 h2 + p {
  text-align: center;
  text-transform: uppercase;
  font-size: 1.2rem;
}

.layer-3 p, .layer-3 li {
  font-size: var(--cs-font-body);
  line-height: var(--cs-line-body);
  margin: 0;
}

/* Layer 3 Header */
.layer-3 h3 {
  padding-top: 60px;
}
.layer-3 h4,
.layer-3 .e1 {
  font-size: var(--cs-font-h4); /* 22px */
  line-height: 1.2;
  text-transform: uppercase;

  padding-bottom: var(--gap-xs); /* 8px */
  border-bottom: 1px solid currentColor;

  margin: 0;
}

/* Global card component override */
.layer-3 .card h4 {
  font-size: var(--cs-font-h4);
  text-transform: uppercase;
  margin: 0;
}

/* Lists */
.layer-3 ul {
  line-height: 24px;
  margin: 0;
}

.layer-3 li {
  max-width: 60ch; /* character-limit guardrail */
}

.layer-3 figure img{
  padding-top: 10px;
}

/* Blockquote */
.layer-3 blockquote {
  border-left: 1px solid #cecece;
    padding: 10px 25px;
    margin-left: 50px;
    font-style: italic;
    font-family: var(--font-serif);
    font-size: 1.2rem;
    color: var(--color-focus);
}

/* Summary / Description */
.layer-3 [data-summary],
.layer-3 [data-description] {
  font-size: var(--cs-font-body);
  line-height: var(--cs-line-body);
}

/* Tagline (e6) */
.layer-3 .e6 {
  font-size: var(--cs-font-tagline); /* 22px */
  line-height: var(--cs-line-tagline); /* 25px */
  text-align: right;
  padding-left: 16px;
  margin: 0;
}

/* Reflection (e8) */
.layer-3 .e8 {
  font-size: var(--cs-font-reflection); /* 20px */
  line-height: var(--cs-line-reflection); /* 32px */
  text-align: center;
  margin: 0;
}

/* ================================
   Section 3 Case Study 2022 Merge
================================ */

.layer-3 section  {
 padding: 25px 10%;
}

.layer-3 section:not(:first-of-type)  {
 padding: 0 20%;
}

.layer-3 section:last-child {
  margin-bottom: 40px;
}


/* Image w Captions */

.layer-3 figure figcaption {
  text-align: center;
  padding:5px;
}

.layer-3 figure figcaption, .inline-media .caption {
  font-size: small;
  font-style: italic;
  font-family: var(--font-serif);
  letter-spacing: 0.5px;
}

.layer-3 p.project-overview {
    font-weight: 300;
    font-size: 1rem;
    font-style: normal;
}

.layer-3 h3 + p, .layer-3 .list-header {
    font-style: italic;
    font-weight: bold;
    padding: 10px 0;
}

.layer-3 .description ol {
    list-style: none;
    counter-reset: item;
}

.layer-3 ol li {
    counter-increment: item;
    margin-bottom: 15px;
    overflow: auto;
}

.layer-3 ol li:before {
    margin: -10px 10px 15px 0;
    content: counter(item);
    font-size: 2em;
    font-family: var(--font-serif);
    color: #ccc;
    width: 1.2em;
    text-align: center;
    display: inline-block;
    /*float: left;*/
    clear: both;
}

/* ================================
   Section 3 Code Review Items
================================ */

/* Check if this is needed (conflicts with lines 845-850 */
.layer-3 .tagline {
  font-size: var(--cs-font-tagline);
  line-height: var(--cs-line-tagline);
  text-align: right;
  padding-left: 16px;
}

.layer-3 .list {
  margin: 0;
  padding-left: 16px;
}

.layer-3 .list--bullet {
  list-style: disc;
}

.layer-3 .list--check {
  list-style: none;
  padding-left: 0;
}

.layer-3 .list--check li {
  position: relative;
  padding-left: 28px;
}

.layer-3 .list--check li::before {
  content: "✓";
  position: absolute;
  left: 0;
  font-size: 20px;
}

/* Result Block Quote (e4) */
.layer-3 .result-quote {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 20px;
  align-items: start;
}

.layer-3 .result-label {
  text-transform: uppercase;
  font-size: 12px;
  letter-spacing: 0.04em;
}

.layer-3 .result-copy {
  border-left: 1px solid #000;
  padding-left: 16px;
}

.layer-3 .result-copy p {
  margin: 0;
}

/* Slideshows (narrow + wide) */
.layer-3 .slideshow {
  margin: 0;
}

.layer-3 .slides {
  display: flex;
  gap: 6px;
  height: 300px;
}

.layer-3 .slides img {
  height: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
}

.layer-3 .slideshow--narrow .slides {
  max-width: 70%;
  margin-inline: auto;
}

.layer-3 .slideshow--wide .slides {
  width: 100%;
}

/* Reflection Padding (e8) */
.layer-3 .e-block--high-fidelity .e8 {
  padding: 0 150px;
  text-align: center;
}



/* ================================
   Layer 3 Visuals
================================ */

/* ===================================== */
/* Layer 3 — Visual Styles (Hybrid Mode) */
/* ===================================== */

.layer-3 {
  /* Colors (hard-coded by spec) */
  --cs-tertiary: #F495B0;
  --cs-divider: #000;
  --cs-muted: #D9D9D9;
}

/* ---------- Headers ---------- */
.layer-3 h4,
.layer-3 .e1 {
  color: inherit;
}

/* ---------- Hero ---------- */
.layer-3 .hero {
  margin: 0 auto;
  height: 360px;
  aspect-ratio: 16/9;
}

/*.layer-3 .hero img {
  height: 360px;
  aspect-ratio: 16/9;
}
  */

.layer-3 .hero h2 {
  text-align: center;
}

.layer-3 .hero .subtitle {
  text-align: center;
  font-size: 14px;
  text-transform: uppercase;
}

/* ---------- Cards (Section B) ---------- */

/* ---------- Lists ---------- */

.layer-3 .checklist li::before {
  content: "✓";
  position: absolute;
  left: 0;
  font-size: 20px;
}

/* ---------- Slideshow ---------- */
.layer-3 .e7,
.layer-3 .e5 {
  height: 300px;
  display: flex;
  gap: 6px;
  width: 100%;
  overflow: hidden;
}

.layer-3 .e7 img,
.layer-3 .e5 img {
  height: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
}

/* ---------- Caption ---------- */
.layer-3 .caption {
  font-size: 12px;
  text-transform: uppercase;
}


/* ---------- Layer 3 Mobile ---------- */

@media (max-width: 480px) {
 .layer-3 h2 {
    font-size: 1.8rem;
    line-height: 30px;
    padding: 20px 0 5px;
}
.layer-3 h2 + p {
  font-size: 1.1rem;
}
.layer-3 h3 {
    padding-top: 30px;
    font-size: 1.3rem;
}
 .layer-3 section {
    padding: 0;
}
  .layer-3 section:not(:first-of-type) {
    padding: 0;
 }
 .cards {
  padding-top:20px;
 }
 .card {
    padding: 0;
}
.layer-3 blockquote {
  margin-left: 20px;
  font-size: 1.1rem;
}

.layer-3 ol {
  padding:0;
}
.layer-3 figure {
  margin: 10px 0;
}



/* Watermark */
.layer-3-watermark {
  position: absolute;
  right: 1.5rem;
  bottom: 1.5rem;
}



/* 
  MOBILE OVERRIDE — DO NOT REMOVE
  Desktop frame model intentionally disabled on mobile.
  Prevents section overlap when desktop frame model is active
  Do not remove without re-testing section stacking.
*/
.section,
  .snap-section {
    height: auto !important;
    min-height: 100svh;
    overflow: visible;
  }

}


/* ======================================================
   Layer 3 — Spec Lock Patches (v3)
   Additive only. Do not refactor above.
====================================================== */

/* Stage content padding (matches your print spec spacing) */
.layer-3-stage > .layer-3,
.layer-3-stage > .case-study,
.layer-3-stage > section {
  padding: 20px;
  box-sizing: border-box;
  inset: 20px;
}

.layer-3-stage > article.wide {
  padding-left: 45px;
  padding-right: 45px;
}



/* ================================
   Layer 3 scrolling (CRITICAL)
================================ */

/* Scrollbar (stage only) */
.layer-3-stage::-webkit-scrollbar {
  width: 10px;
}

.layer-3-stage::-webkit-scrollbar-thumb {
  background: var(--accent-pink);
  border-radius: 6px;
}

.layer-3-overlay {
  position: fixed;
  inset: 0;
  pointer-events: auto;
}

.layer-3-frame {
  position: fixed;
  inset: 0;
  pointer-events: none; /* frame should NOT capture scroll */
}

.layer-3-stage {
  position: fixed;
  inset: 0;
  margin: auto;
  width: 80vw;
  height: 80vh;

  background: #fff;

  overflow-y: auto;     /* ✅ THIS enables scrolling */
  overflow-x: hidden;

  pointer-events: auto; /* ✅ THIS receives wheel/touch */

  -webkit-overflow-scrolling: touch;
}

/* ================================
   Layer 3 scroll lock (additive)
================================ */

body.is-layer-3-open {
  overflow: hidden;
}

.layer-3-close {
  pointer-events: auto;
}

.layer-3 h2.section-heading {
  flex-direction: row;
  align-items: baseline;
  text-align: center;
  justify-content: center;
}

@media (max-width: 768px) {
      :root {
        --frame-pad: 12px;
      }
    }