/* =========================================
   SHITTY MAPS — style.css
   Aesthetic: paper and ink. Notecards on a table.
   ========================================= */

/* ── JE WHITEBOARD (local custom font) ─────────────────────────────────────── */
@font-face {
  font-family: 'JE Whiteboard';
  src: url('Je_whiteboard-Regular_v1.1.otf') format('opentype'),
       url('Je_whiteboard-Regular_v1.1.ttf') format('truetype');
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

/* ── JE NOTECARD (local custom font) ────────────────────────────────────────── */
@font-face {
  font-family: 'JE Notecard';
  src: url('Je_notecard-Regular_v1.2.otf') format('opentype'),
       url('Je_notecard-Regular_v1.2.ttf') format('truetype');
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

/* ── COMIC NEUE (local) ─────────────────────────────────────────────────────── */
@font-face {
  font-family: 'Comic Neue';
  src: url('Comic_Neue/ComicNeue-Light.ttf') format('truetype');
  font-weight: 300; font-style: normal;
}
@font-face {
  font-family: 'Comic Neue';
  src: url('Comic_Neue/ComicNeue-LightItalic.ttf') format('truetype');
  font-weight: 300; font-style: italic;
}
@font-face {
  font-family: 'Comic Neue';
  src: url('Comic_Neue/ComicNeue-Regular.ttf') format('truetype');
  font-weight: 400; font-style: normal;
}
@font-face {
  font-family: 'Comic Neue';
  src: url('Comic_Neue/ComicNeue-Italic.ttf') format('truetype');
  font-weight: 400; font-style: italic;
}
@font-face {
  font-family: 'Comic Neue';
  src: url('Comic_Neue/ComicNeue-Bold.ttf') format('truetype');
  font-weight: 700; font-style: normal;
}
@font-face {
  font-family: 'Comic Neue';
  src: url('Comic_Neue/ComicNeue-BoldItalic.ttf') format('truetype');
  font-weight: 700; font-style: italic;
}

/* ── TOKENS ─────────────────────────────────────────────────────────────────── */
:root {
  --paper:        #F7F4EF;
  --paper-subtle: #EDE9E3;
  --paper-card:   #FFFFFF;
  --paper-inset:  #F0EDE7;

  --ink:          #1A1917;
  --ink-mid:      #6B6560;
  --ink-light:    #706A64;
  --ink-faint:    #C8C2BB;
  --ink-blue:     #1a2d8e;

  --rule:         #D8D2CB;
  --rule-light:   #E6E1DA;

  --intelligent:    #a8a093;

  --font-body:    'DM Sans', system-ui, -apple-system, sans-serif;
  --font-mono:    'IBM Plex Mono', 'Courier New', monospace;
  --font-display: 'JE Notecard', 'Comic Sans MS', 'Comic Sans', cursive;

  --radius-btn:   3px;
  --radius-input: 4px;
  --card-radius:  2px;

  /* Notecard shadow: two layers — close ambient + distant diffuse */
  --shadow-card:  0 1px 3px rgba(0,0,0,0.47), 0 4px 10px rgba(0,0,0,0.57);
  --shadow-lift:  0 3px 10px rgba(0,0,0,0.11), 0 8px 28px rgba(0,0,0,0.09);

  --max-w: 860px;
}

/* ── RESET ──────────────────────────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html { font-size: 16px; scroll-behavior: smooth; }

body {
  font-family: var(--font-body);
  background: var(--paper);
  color: var(--ink);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

:focus-visible {
  outline: 2px solid var(--ink);
  outline-offset: 3px;
  border-radius: 2px;
}

/* ── LAYOUT ─────────────────────────────────────────────────────────────────── */
.container {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 0 2.5rem;
}

/* ── SHARED TYPOGRAPHY ──────────────────────────────────────────────────────── */
.eyebrow {
  font-family: var(--font-mono);
  font-size: 0.65rem;
  font-weight: 400;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--ink-light);
  margin-bottom: 0.75rem;
}

.eyebrow--light {
  color: rgba(247, 244, 239, 0.4);
}

.section-heading {
  font-family: var(--font-display);
  font-size: clamp(1.5rem, 3vw, 2rem);
  font-weight: 700;
  color: var(--ink);
  line-height: 1.15;
  margin-bottom: 2.75rem;
}

.notecard .section-heading{
  margin-bottom: 0;
  font-size: clamp(2.5rem, 3vw, 2rem);
  text-align: center;
}

/* ── LOGO BAR ───────────────────────────────────────────────────────────────── */
.site-header {
  background: var(--intelligent);
  padding: 1.1rem 0;
}

.header-inner {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 0 2.5rem;
}

.site-logo {
  width: 140px;
  display: block;
}

/* ── HERO: WHITEBOARD ───────────────────────────────────────────────────────── */
/* Dark wall — makes the whiteboard read as a physical object */
.hero-section {
  background: var(--intelligent);
  padding: 3.5rem 0 4.5rem;
}

/*
  The whiteboard itself.
  Frame: two-layer border — outer charcoal + inner lighter edge highlight.
  Surface: clean near-white with faint warm tint.
  Shadow: multi-layer to suggest the board is mounted and has physical depth.
  Tray: ::after pseudo-element as the marker ledge at the bottom.
*/
.whiteboard {
  background: #F5F5F3;
  border: 10px solid #abaaa8;
  border-radius: 3px;
  padding: 2.75rem 3rem;
  position: relative;
  aspect-ratio: 4 / 3;
  overflow: visible;
  display: flex;
  flex-direction: column;
  justify-content: center;

  /* Outer drop shadow + inner rim highlight */
  box-shadow:
    0 10px 40px rgba(0, 0, 0, 0.5),
    0 3px 8px  rgba(0, 0, 0, 0.3),
    inset 0 0 0 1.5px rgba(255, 255, 255, 0.25);
}

/* Bottom marker tray — sits just below the board border */
.whiteboard::after {
  content: '';
  position: absolute;
  bottom: -22px;
  left: -12px;
  right: -12px;
  height: 14px;
  background: #242220;
  border-radius: 0 0 4px 4px;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.4);
}

/* SVG whiteboard lines — text follows a bezier curve, so the baseline itself arcs */
.wb-line {
  display: block;
  width: 100%;
  overflow: visible;  /* let arced corners breathe outside the viewBox */
}

.wb-line--lead    { margin-bottom: 0.9rem; }
.wb-line--body    { margin-bottom: 0.6rem; }
.wb-line--gap     { margin-bottom: 1.1rem; }  /* extra gap after body, before rule */
.wb-line--tagline { margin-top: 0.25rem; }

/* Font-family via CSS so the web font is properly applied to SVG text */
.wb-text {
  font-family: 'JE Whiteboard', 'Comic Sans MS', 'Comic Sans', cursive;
  letter-spacing: -.12rem;
  font-feature-settings: "calt" 1, "salt" 1, "ss01" 1, "ss02" 1;
}
.wb-text--lead    { color: var(--ink-blue); font-size: clamp(3rem, 7.5vw, 4.5rem); line-height: 2.5rem; }
.wb-text--body    { color: var(--ink);     font-size: clamp(2rem, 4.5vw, 2.75rem); line-height: 1.6rem; }
.wb-text--tagline { color: var(--ink-blue); font-size: clamp(2.5rem, 6vw, 3.5rem); line-height: 2rem;}

/* Divider stroke between body and tagline */
.wb-rule {
  display: block;
  width: 75%;
  overflow: visible;
  margin: 0.1rem 0 1.6rem;
}

/* Screen-reader utility */
.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;
}

.whiteboard-tray {
    display: flex;
    background-color: #2E2B27;
    height: 9px;
    width: 410px;
    margin: auto;
    position: relative;
    padding: 0 10px 2px 70px;
    gap: 10px;
    border-radius: 3px;
    top: -3px;
}

.marker {
    display: block;
    background: white;
    height: 11px;
    position: relative;
    width: 79px;
    top: -5px;
    box-shadow: inset 0 -2px 4px rgba(0, 0, 0, .75);
}

.marker.blue {
    box-shadow: inset 20px 0 blue, inset 0 -2px 4px rgba(0, 0, 0, .75);
}

.red {
    box-shadow: inset 20px 0 red, inset 0 -2px 4px rgba(0, 0, 0, .75);
}

.green {
    box-shadow: inset 20px 0 green, inset 0 -2px 4px rgba(0, 0, 0, .75);
}

/* ── NOTECARD STAMP ─────────────────────────────────────────────────────────── */
/* Floated stamp in the upper-left corner — text wraps around it */
.card-stamp {
  float: left;
  width: 100px;
  height: 100px;
  object-fit: contain;
  margin: -1rem 1rem 0.5rem -1.5rem;
  shape-outside: circle(50%);
  display: block;
}

/* ── DEFINITION ─────────────────────────────────────────────────────────────── */
/* One big quote card — first notecard the reader encounters */
.definition {
  background: url('woodtable.jpeg') center / cover;
  padding: 6rem 0 5.5rem;
}

.def-quote {
  max-width: 720px;
  margin-bottom: 2.5rem;
  transform: rotate(-1.4deg);
  transform-origin: center center;
}

.def-quote:hover {
  transform: rotate(0deg);
}


/* Text — bottom portion of the card */
.def-text {
  font-family: var(--font-display);
  font-size: clamp(1.8rem, 1.8vw, 1.25rem);
  font-weight: 700;
  color: var(--ink);
  line-height: 1;
  flex-shrink: 0;
  position: relative;
  z-index: 1;
  text-align: center;
}

/* Diagram — top portion of the card, graphic is a pseudo-element background */
.def-diagram {
  position: relative;
  flex: 1 1 0;
  min-height: 0;
}

/* The actual graphic — inverted so black bg becomes white, multiply drops the white */
.def-diagram::before {
  content: '';
  position: absolute;
  inset: 0;
  background: url('ExplanationGraphic.png') center / contain no-repeat;
}

/* Text labels inside each drawn box — positioned as % of the diagram container */
.def-diagram__label {
  position: absolute;
  font-family: var(--font-display);
  font-weight: 700;
  color: var(--ink);
  transform: translate(-50%, -50%);
  text-align: center;
  white-space: nowrap;
  pointer-events: none;
}

.def-diagram__label--top { top: 18%; left: 47%; font-size: clamp(1.75rem, 1.6vw, 1.05rem); }
.def-diagram__label--bl  { top: 82%; left: 15%; font-size: clamp(1.6rem, 1.2vw, 0.85rem); }
.def-diagram__label--bm  { top: 82%; left: 46%; font-size: clamp(1.6rem, 1.2vw, 0.85rem); }
.def-diagram__label--br  { top: 82%; left: 83%; font-size: clamp(1.6rem, 1.2vw, 0.85rem); }

.def-body {
  font-family: var(--font-body);
  font-size: 1rem;
  color: var(--ink-mid);
  line-height: 1.7;
  max-width: 58ch;
  padding-left: 0.25rem;
}

/* ── FANCY MAPS FAIL ────────────────────────────────────────────────────────── */
/*
  Intentionally polished — ironic contrast to the Shitty Maps aesthetic.
  Mimics Figma's canvas: toolbar, rulers, alignment guides, selection handles, gloss.
*/
.fail-section {
  background-color: #141414;
  background-image:
    linear-gradient(rgba(255,255,255,0.025) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,0.025) 1px, transparent 1px),
    radial-gradient(circle, rgba(255,255,255,0.07) 1px, transparent 1px);
  background-size: 88px 88px, 88px 88px, 22px 22px;
  border-top: none;
  padding: 5.5rem 0 6rem;
  position: relative;
  overflow: clip;
}

/* ── TOOLBAR ── */
.canvas-toolbar {
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 48px;
  background: #2C2C2C;
  border-bottom: 1px solid #3D3D3D;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 14px;
  z-index: 10;
  font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif;
}

.canvas-toolbar__tools {
  display: flex;
  align-items: center;
  gap: 2px;
}

.tb-logo {
  font-size: 14px;
  color: rgba(255,255,255,0.9);
  margin-right: 6px;
}

.tb-sep {
  width: 1px;
  height: 18px;
  background: #444;
  margin: 0 8px;
  display: inline-block;
}

.tb-tool {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  border-radius: 6px;
  font-size: 13px;
  color: rgba(255,255,255,0.55);
  cursor: default;
  transition: background 0.1s;
}

.tb-tool--active {
  background: #18A0FB;
  color: #fff;
}

.tb-tool--text {
  font-weight: 700;
  font-size: 15px;
}

.canvas-toolbar__title {
  font-size: 12px;
  font-weight: 500;
  color: rgba(255,255,255,0.8);
  letter-spacing: -0.01em;
}

.tb-saved {
  color: rgba(255,255,255,0.35);
  font-weight: 400;
}

.canvas-toolbar__actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

.tb-zoom {
  font-size: 11px;
  color: rgba(255,255,255,0.5);
  padding: 4px 8px;
  border-radius: 4px;
  background: rgba(255,255,255,0.06);
  cursor: default;
}

.tb-share {
  font-size: 11px;
  font-weight: 600;
  color: #fff;
  background: #18A0FB;
  padding: 5px 12px;
  border-radius: 6px;
  cursor: default;
}

.tb-avatar {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: #7B61FF;
  background: url('Joe-Outdoors-Smile.jpeg') center / cover;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 10px;
  font-weight: 700;
  color: #ffffff00;
  letter-spacing: 0.02em;
}

/* ── RULERS ── */
.canvas-ruler--h {
  position: absolute;
  top: 48px; left: 0; right: 0;
  height: 20px;
  background:
    repeating-linear-gradient(90deg,
      transparent, transparent 9px,
      rgba(255,255,255,0.1) 9px, rgba(255,255,255,0.1) 10px),
    repeating-linear-gradient(90deg,
      transparent, transparent 49px,
      rgba(255,255,255,0.25) 49px, rgba(255,255,255,0.25) 50px),
    #1E1E1E;
  border-bottom: 1px solid #2C2C2C;
  z-index: 5;
}

.canvas-ruler--v {
  position: absolute;
  top: 48px; left: 0; bottom: 0;
  width: 20px;
  background:
    repeating-linear-gradient(180deg,
      transparent, transparent 9px,
      rgba(255,255,255,0.1) 9px, rgba(255,255,255,0.1) 10px),
    repeating-linear-gradient(180deg,
      transparent, transparent 49px,
      rgba(255,255,255,0.25) 49px, rgba(255,255,255,0.25) 50px),
    #1E1E1E;
  border-right: 1px solid #2C2C2C;
  z-index: 5;
}

/* ── CANVAS GUIDES ── */
.canvas-guides {
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  overflow: visible;
}

/* Guide positions — desktop (2-column grid) */
.guide--v1 { left: 0; }
.guide--v2 { left: calc(50% - 0.75rem); }
.guide--v3 { left: calc(50% + 0.75rem); }
.guide--v4 { left: 100%; }
.guide--h1 { top: 0; }
.guide--h2 { top: 50%; }
.guide--h3 { top: 100%; }

.guide {
  position: absolute;
  pointer-events: none;
  background: rgba(24, 160, 251, 0.55);
}

.guide--v {
  width: 1px;
  top: -1000px;
  height: calc(100% + 2000px);
}

.guide--h {
  height: 1px;
  left: -500px;
  right: -500px;
}

/* Dimension badge on guides — mimics Figma's spacing labels */
.guide-label {
  position: absolute;
  top: 50%;
  left: 3px;
  transform: translateY(-50%);
  font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif;
  font-size: 9px;
  font-weight: 600;
  color: #fff;
  background: #18A0FB;
  padding: 1px 4px;
  border-radius: 2px;
  white-space: nowrap;
  line-height: 1.4;
}

.guide-label--h {
  top: 3px;
  left: 50%;
  transform: translateX(-50%);
}

/* Cursor-tracking crosshair guides */
.cursor-guide {
  position: absolute;
  pointer-events: none;
  background: rgba(24, 160, 251, 0.55);
  opacity: 0;
  transition: opacity 0.1s ease;
  z-index: 10;
}

.cursor-guide--v {
  width: 1px;
  top: 0;
  bottom: 0;
  left: 0;
}

.cursor-guide--h {
  height: 1px;
  left: 0;
  right: 0;
  top: 0;
}

.cursor-guide__label {
  position: absolute;
  font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif;
  font-size: 9px;
  font-weight: 600;
  color: #fff;
  background: #18A0FB;
  padding: 1px 4px;
  border-radius: 2px;
  white-space: nowrap;
  line-height: 1.4;
}

.cursor-guide__label--v {
  top: 56px; /* sits just below the toolbar */
  left: 3px;
}

.cursor-guide__label--h {
  left: 8px;
  top: 3px;
}

/* ── HEADINGS ── */
.fail-section .eyebrow {
  color: rgba(255,255,255,0.3);
  font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif;
  position: relative;
  z-index: 1;
}

.fail-section .section-heading {
  font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif;
  font-weight: 200;
  font-size: clamp(2rem, 4vw, 3.2rem);
  letter-spacing: -0.03em;
  color: #ffffff;
  position: relative;
  z-index: 1;
  margin-bottom: 3rem;
}

/* ── GRID ── */
.fail-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.5rem;
  position: relative;
  z-index: 1;
}

/* ── CARDS ── */
/*
  No overflow:hidden — allows selection handles to sit at corners.
  Background clips naturally to border-box; gloss stays inside via ::after inset.
*/
.fail-item {
  background: linear-gradient(155deg, #ffffff 0%, #eef1f7 100%);
  border-radius: 3px;
  padding: 2rem 1.75rem 1.75rem;
  overflow: visible;
  position: relative;
  transform: none;
  transition: box-shadow 0.18s ease, outline 0.18s ease;
  outline: 1.5px solid rgba(151, 71, 255, 0.5);
  outline-offset: 0;
  box-shadow:
    0 0 0 0.5px rgba(151,71,255,0.15),
    0 2px 4px rgba(0,0,0,0.25),
    0 6px 16px rgba(0,0,20,0.3);
}

.fail-item:hover {
  outline: 2px solid #9747FF;
  box-shadow:
    0 0 0 0.5px rgba(151,71,255,0.3),
    0 4px 8px rgba(0,0,0,0.3),
    0 12px 28px rgba(0,0,30,0.4);
  z-index: 2;
}

/* One card appears "primary selected" */
.fail-item:nth-child(3) {
  outline: 2px solid #9747FF;
}

/* Figma-style layer name label */
.fail-item::before {
  content: 'Fancy Component';
  position: absolute;
  top: -18px; left: 0;
  font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif;
  font-size: 10px;
  font-weight: 500;
  letter-spacing: 0.02em;
  color: #9747FF;
  white-space: nowrap;
}

/* Gloss — strong top-left light source */
.fail-item::after {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background: linear-gradient(
    140deg,
    rgba(255,255,255,0.45) 0%,
    rgba(255,255,255,0.15) 30%,
    rgba(255,255,255,0.0) 60%
  );
  pointer-events: none;
}

/* ── SELECTION HANDLES ── */
.selection-handles {
  position: absolute;
  inset: 0;
  pointer-events: none;
  display: none; /* hidden by default; shown only on the selected item */
}

.fail-item:nth-child(3) .selection-handles {
  display: block;
}

.handle {
  position: absolute;
  width: 8px;
  height: 8px;
  background: #fff;
  border: 1.5px solid #9747FF;
  border-radius: 1px;
  display: block;
}

.handle--tl { top: -5px;  left: -5px;  }
.handle--tr { top: -5px;  right: -5px; }
.handle--bl { bottom: -5px; left: -5px;  }
.handle--br { bottom: -5px; right: -5px; }

/* ── CARD TYPOGRAPHY ── */
.fail-heading {
  font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif;
  font-size: 1rem;
  font-weight: 600;
  color: #0D0D0D;
  letter-spacing: -0.02em;
  margin-bottom: 0.5rem;
  line-height: 1.3;
}

.fail-body {
  font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif;
  font-size: 0.8rem;
  font-weight: 400;
  color: #555;
  line-height: 1.7;
  letter-spacing: -0.005em;
}

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

/* ── SHITTY PRINCIPLES ──────────────────────────────────────────────────────── */
.principles-section {
  background-image: url('woodtable.jpeg');
  background-size: contain;
  background-repeat: repeat;
  border-top: 1px solid var(--rule);
  padding: 5.5rem 0 7rem;
}

/* Three notecards stacked with slight overlap as they descend */
.notecard-stack {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0;
  margin-top: 3rem;
}

.notecard {
  display: flex;
  flex-direction: column;
  font-style: normal;
  position: relative;
  width: 100%;
  max-width: 720px;
  aspect-ratio: 3 / 2;
  background: url('NotecardTexture.jpg') center / cover var(--paper-card);
  box-shadow: var(--shadow-card);
  border-radius: var(--card-radius);
  padding: 1.5rem 2rem;
  overflow: hidden;
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.combo-shapes-diagram,
.practice-performance-diagram,
.six-shapes-diagram {
  position: relative;
  flex: 1 1 0;
  min-height: 0;
}

.combo-shapes-diagram::before {
  content: '';
  position: absolute;
  inset: 0;
  background: url('combo-shapes.png') center / contain no-repeat;
}
.practice-performance-diagram::before {
  content: '';
  position: absolute;
  inset: 0;
  background: url('practiceforperformance.png') center / contain no-repeat;
}
.six-shapes-diagram::before {
  content: '';
  position: absolute;
  inset: 0;
  background: url('six-shapes.png') center / contain no-repeat;
}
/* Text labels inside each drawn box — positioned as % of the diagram container */
.combo-shapes-diagram__label,
.practice-performance-diagram__label {
  position: absolute;
  font-family: var(--font-display);
  font-weight: 700;
  color: var(--ink);
  transform: translate(-50%, -50%);
  text-align: center;
  pointer-events: none;
}

.combo-shapes-diagram__label{
  top: 35%;
  right: 14%;
  font-size: 2.8rem;
}

.practice-performance-diagram__label{
  font-size: 2.8rem;
  line-height: 2.8rem;;
}
.practice-performance-diagram__label--low{
  width: 220px;
  top: 49%;
  left: 20%;
}
.practice-performance-diagram__label--enables{
  top: 48%;
  left: 47%;
  width: 80px;
  font-size: 1.5rem;
}
.practice-performance-diagram__label--high{
  top: 46%;
  left: 81%;
  width: 220px;
}

.third-box{
  background: url('third-box.png') center / contain no-repeat;
}

.notecard .card-stamp {
  position: absolute;
  top: 1rem;
  left: 1rem;
  width: 72px;
  height: 72px;
  float: none;
  margin: 0;
  z-index: 2;
  opacity: 0.85;
}

.notecard-stack > .notecard:nth-child(1) { transform: rotate(-1deg)   translateX(clamp(-80px, -8vw, 0px)); z-index: 3; margin-bottom: -20px; }
.notecard-stack > .notecard:nth-child(2) { transform: rotate( 0.8deg) translateX(clamp(0px,   8vw, 80px));  z-index: 2; margin-bottom: -20px; }
.notecard-stack > .notecard:nth-child(3) { transform: rotate(-0.5deg) translateX(clamp(-60px, -5vw, 0px)); z-index: 1; }

.notecard-stack > .notecard:nth-child(1):hover { transform: rotate(0deg) translateX(clamp(-80px, -8vw, 0px)) translateY(-6px); }
.notecard-stack > .notecard:nth-child(2):hover { transform: rotate(0deg) translateX(clamp(0px,   8vw, 80px))  translateY(-6px); }
.notecard-stack > .notecard:nth-child(3):hover { transform: rotate(0deg) translateX(clamp(-60px, -5vw, 0px)) translateY(-6px); }

.notecard-stack > .notecard:hover {
  z-index: 10;
  box-shadow:
    0 8px 20px rgba(0,0,0,0.35),
    0 24px 60px rgba(0,0,0,0.3);
}

.notecard-body {
  font-family: var(--font-display);
  font-size: clamp(1.8rem, 1.8vw, 1.25rem);
  font-weight: 700;
  color: var(--ink);
  line-height: 1.3;
  position: relative;
  z-index: 1;
  text-align: center;
}

.practice-performance .notecard-body {
    margin-bottom: 40px;
}

.six-shapes .notecard-body{
  text-align: center;
  font-size: clamp(2.8rem, 1.8vw, 1.25rem);
}

.notecard-body + .notecard-body {
  margin-top: 0.4rem;
}

/* Rules card: three equal boxes side-by-side below the stamp */
.rules-grid {
  display: flex;
  flex: 1 1 0;
  align-items: stretch;
  margin-top: calc(10px + 1.5rem);
}

.rules .third-box {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: normal;
  padding: 5rem 1rem 0;
  margin-top: 0;
  text-align: center;
}

.rules .notecard-body strong {
  display: block;
  font-size: clamp(1.8rem, 1.4vw, 1rem);
  line-height: 1.4rem;
  margin-bottom: 0.75rem;
}

.rules .notecard-body {
  font-size: clamp(1.3rem, 1vw, 0.75rem);
  line-height: 1.25rem;
}

.notecard img:not(.card-stamp) {
  flex: 1 1 0;
  min-height: 0;
  max-width: 100%;
  object-fit: contain;
  object-position: center;
}

/* ── PRACTICE CTA ───────────────────────────────────────────────────────────── */
.practice-cta {
  background: var(--paper);
  border-top: 1px solid var(--rule);
  border-bottom: 1px solid var(--rule);
  padding: 5.5rem 0;
}

.practice-cta .container {
  max-width: 900px;
  margin: 0 auto;
  padding: 0 2.5rem;
}

.practice-heading {
  font-family: var(--font-display);
  font-size: clamp(1.85rem, 3.5vw, 2.6rem);
  font-weight: 700;
  color: var(--ink);
  line-height: 1.1;
  margin-bottom: 1rem;
}

.practice-body {
  font-family: var(--font-body);
  font-size: 1rem;
  color: var(--ink-mid);
  line-height: 1.7;
  margin-bottom: 2.25rem;
}

.btn-practice {
  display: block;
  background: var(--ink);
  color: var(--paper);
  border: none;
  border-radius: var(--radius-btn);
  padding: 13px 26px;
  font-family: var(--font-body);
  font-size: 0.95rem;
  font-weight: 600;
  text-decoration: none;
  transition: background 0.15s, box-shadow 0.15s;
  margin: 0 auto;
  width: 200px;
}

.btn-practice:hover {
  background: #2E2C2A;
  box-shadow: 0 2px 12px rgba(0,0,0,0.20);
}

/* PRACTICE CTA: intro narrowing */
.practice-cta__intro {
  margin-bottom: 3rem;
}

/* Card spread — three series groups side by side */
.practice-card-spread {
  display: flex;
  gap: 1.25rem;
  margin-bottom: 3rem;
  align-items: flex-start;
  overflow: hidden;
}

/* Series group: labeled box bounding each stack */
.practice-series-group {
  flex: 1;
  border-radius: 6px;
  border: 1px solid rgba(255,255,255,0.08);
  padding: 14px 14px 16px;
  width: 100%;
}
.practice-series-group--mode    { border-color: rgba(90, 110, 140, 0.35); background: rgba(90, 110, 140, 0.06); }
.practice-series-group--persona { border-color: rgba(122, 92, 58, 0.35);  background: rgba(122, 92, 58, 0.06); }
.practice-series-group--subject { border-color: rgba(61, 107, 79, 0.35);  background: rgba(61, 107, 79, 0.06); }

/* Series label — sits above the card stack */
.practice-series-group__label {
  font-family: var(--font-mono);
  font-size: 0.6rem;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  display: block;
  margin-bottom: 12px;
}
.practice-series-group--mode    .practice-series-group__label { color: #5A6E8C; }
.practice-series-group--persona .practice-series-group__label { color: #7A5C3A; }
.practice-series-group--subject .practice-series-group__label { color: #3D6B4F; }

/* Stack: relative container for the layered cards */
.practice-card-stack {
  position: relative;
  height: 280px;
}

/* Card */
.practice-card {
  position: absolute;
  left: 0;
  right: 0;
  background: var(--paper-card);
  border: 1px solid var(--rule);
  border-radius: var(--card-radius);
  padding: 8px 12px;
  overflow: hidden;
  width: 90%;
  height: 220px;
}

/* 3px accent top border — matches notecard */
.practice-card::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 3px;
}
.practice-card--mode::before    { background: #5A6E8C; }
.practice-card--persona::before { background: #7A5C3A; }
.practice-card--subject::before { background: #3D6B4F; }

/* Title */
.practice-card__title {
  font-family: var(--font-body);
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--ink);
  line-height: 1.25;
  margin: 0 0 5px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.practice-card--subject .practice-card__title {
  font-style: italic;
  text-transform: lowercase;
}

/* Body — tiny, decorative texture */
.practice-card__body {
  font-family: var(--font-body);
  font-size: 0.6rem;
  color: var(--ink-mid);
  line-height: 1.5;
  margin: 0;
}

/* Detail list — dash-prefixed, matches app's notecard__detail */
.practice-card__detail {
  list-style: none;
  padding: 0;
  margin: 6px 0 0;
  border-top: 1px solid var(--rule-light);
  padding-top: 6px;
  display: flex;
  flex-direction: column;
  gap: 3px;
}
.practice-card__detail li {
  font-family: var(--font-body);
  font-size: 0.58rem;
  color: var(--ink-light);
  line-height: 1.4;
  padding-left: 12px;
  position: relative;
}
.practice-card__detail li::before {
  content: '—';
  position: absolute;
  left: 0;
}

.practice-series-group .footer{
    z-index: 100;
    position: relative;
    width: 113%;
    margin: -28px 0 -17px -15px;
    border-radius: 0 0 5px 5px;
    color: white;
    text-align: center;
    font-family: 'IBM Plex Mono';
    font-size: .75rem;
    height: 54px;
    padding-top: 24px;
    font-weight: 700;
}

.practice-series-group--mode .footer{
    background: linear-gradient(0deg, #5A6E8C, transparent);
}
.practice-series-group--persona .footer{
    background: linear-gradient(0deg, #7A5C3A, transparent);
}
.practice-series-group--subject .footer{
    background: linear-gradient(0deg, #3D6B4F, transparent);
}

/* Stack: back card (nth-child 3) sits highest, front card (nth-child 1) sits lowest */
.practice-card-stack .practice-card:nth-child(4){
    z-index: 4;
    top: 90px;
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.07);
    left: 30px;
}
.practice-card-stack .practice-card:nth-child(3) {
  z-index: 1;
  top: 0;
  box-shadow: 0 1px 4px rgba(0,0,0,0.07);
}
.practice-card-stack .practice-card:nth-child(2) {
  z-index: 2;
  top: 30px;
  left: 10px;
  box-shadow: 0 1px 6px rgba(0,0,0,0.10);
}
.practice-card-stack .practice-card:nth-child(1) {
  z-index: 3;
  top: 60px;
  left: 20px;
  box-shadow: 0 2px 10px rgba(0,0,0,0.16);
}
@media (max-width: 830px) {
  .practice-card-stack {
    display: none;
  }
  .practice-series-group__label{
    margin: 0;
    text-align: center;
  }
}
/* Responsive */
@media (max-width: 630px) {
  .practice-cta__intro {
    max-width: 100%;
  }
  .practice-card-spread {
    flex-direction: column;
    gap: 1rem;
  }

  .practice-card-stack .practice-card {
    position: relative;
    top: auto;
    left: auto;
    width: 100%;
    height: auto;
  }
}

/* ── SIGNUP ─────────────────────────────────────────────────────────────────── */
/* Clean, no cards — just type and a form */
.signup {
  background: var(--intelligent);
  border-top: 1px solid var(--rule);
  padding: 5rem 0;
}

.signup-heading {
  font-family: var(--font-display);
  font-size: clamp(1.85rem, 3.5vw, 2.6rem);
  font-weight: 700;
  color: var(--ink);
  line-height: 1.25;
  margin-bottom: 0.5rem;
  text-align:center;

}

.signup-sub {
  font-family: var(--font-body);
  font-size: 0.92rem;
  color: var(--ink-mid);
  line-height: 1.6;
  margin-bottom: 1.75rem;
  text-align: center;
}

/* Inline: input + button on one row */
.signup-form {
  display: flex;
  gap: 0.5rem; 
  max-width: 520px;
  margin: 0 auto;
}

.signup-form input[type="email"] {
  flex: 1;
  min-width: 0;
  background: var(--paper-card);
  border: 1.5px solid var(--rule);
  border-radius: var(--radius-input);
  padding: 0.7rem 1rem;
  font-family: var(--font-body);
  font-size: 0.92rem;
  color: var(--ink);
  outline: none;
  transition: border-color 0.15s;
}

.signup-form input[type="email"]::placeholder { color: var(--ink-faint); }
.signup-form input[type="email"]:focus       { border-color: var(--ink); }

.signup-form button {
  background: var(--ink);
  color: var(--paper);
  border: none;
  border-radius: var(--radius-btn);
  padding: 0.7rem 1.25rem;
  font-family: var(--font-body);
  font-size: 0.92rem;
  font-weight: 600;
  cursor: pointer;
  white-space: nowrap;
  transition: background 0.15s;
}

.signup-form button:hover { background: #2E2B27; }

.about-photo-col a{
  color: var(--paper);
  font-family: var(--font-mono)
}

@media (max-width: 630px) {
  .signup-form { flex-direction: column; }
  .signup-form button { width: 100%; }
  .signup { padding: 3.5rem 0; }

  /* ── HERO: marker tray ── */
  .whiteboard-tray {
    width: min(410px, 88%);
    padding-left: clamp(16px, 5%, 70px);
    gap: 8px;
  }
  .marker {
    width: clamp(52px, 19%, 79px);
  }

  /* ── FAIL SECTION: Figma chrome ── */
  .canvas-toolbar__tools { display: none; }
  .canvas-toolbar { padding: 0 12px; }
  .canvas-toolbar__title { font-size: 11px; }
  .canvas-ruler--h { display: none; }
  .canvas-ruler--v { display: none; }
  .fail-section { padding: 4rem 0 4.5rem; }

  /* ── FAIL SECTION: one big Figma card ── */

  /* The grid becomes the single card */
  .fail-grid {
    gap: 0;
    background: linear-gradient(155deg, #ffffff 0%, #eef1f7 100%);
    outline: 2px solid #9747FF;
    border-radius: 3px;
    overflow: visible;
    box-shadow:
      0 0 0 0.5px rgba(151,71,255,0.15),
      0 2px 4px rgba(0,0,0,0.25),
      0 6px 16px rgba(0,0,20,0.3);
  }

  /* Strip individual card chrome */
  .fail-item {
    background: transparent;
    outline: none;
    box-shadow: none;
    border-radius: 0;
    padding: 1.25rem 1.5rem;
    border-bottom: 1px solid rgba(0,0,0,0.07);
  }

  .fail-item:last-child   { border-bottom: none; }
  .fail-item:nth-child(3) { outline: none; }

  /* Layer label and gloss: show only on the first item (top of box) */
  .fail-item::before { display: none; }
  .fail-item::after  { display: none; }
  .fail-item:nth-child(2)::before { display: block; }
  .fail-item:nth-child(2)::after  { display: block; }

  /* Handles: hide all (including the higher-specificity desktop nth-child(3) rule), then show only the 4 box corners */
  .selection-handles { display: none; }
  .fail-item:nth-child(3) .selection-handles { display: none; }

  .fail-item:nth-child(2) .selection-handles,
  .fail-item:last-child   .selection-handles { display: block; }

  /* First item: top corners only */
  .fail-item:nth-child(2) .handle--bl,
  .fail-item:nth-child(2) .handle--br { display: none; }

  /* Last item: bottom corners only */
  .fail-item:last-child .handle--tl,
  .fail-item:last-child .handle--tr { display: none; }

  /* ── PRINCIPLES: notecard aspect ratio release ── */
  .notecard {
    aspect-ratio: unset;
    min-height: 280px;
  }
  .six-shapes-diagram,
  .combo-shapes-diagram{
    min-height: 110px;
  }
  .practice-performance-diagram {
    min-height: 250px;
  }
  .principles-section { padding: 3.5rem 0 4.5rem; }

  /* ── PRINCIPLES: notecard stack translations ── */
  .notecard-stack > .notecard:nth-child(1) { transform: rotate(-1deg)   translateX(-10px); }
  .notecard-stack > .notecard:nth-child(2) { transform: rotate( 0.8deg) translateX(10px); }
  .notecard-stack > .notecard:nth-child(3) { transform: rotate(-0.5deg) translateX(-8px); }

  .notecard-stack > .notecard:nth-child(1):hover { transform: rotate(0deg) translateX(-10px) translateY(-4px); }
  .notecard-stack > .notecard:nth-child(2):hover { transform: rotate(0deg) translateX(10px)  translateY(-4px); }
  .notecard-stack > .notecard:nth-child(3):hover { transform: rotate(0deg) translateX(-8px)  translateY(-4px); }

  .notecard-stack > .notecard:nth-child(1),
  .notecard-stack > .notecard:nth-child(2) { margin-bottom: -10px; }

  /* ── PRINCIPLES: rules grid — mobile sizing ── */
  .rules-grid { flex-direction: column; gap: 0.75rem; }
  .rules .third-box { padding: 0.6rem 0.75rem; }

  /* ── PRINCIPLES: practice-performance — vertical image on mobile ── */
  .practice-performance-diagram::before {
    background-image: url('practiceperformance_vert.png');
    height: 250px;
  }

  .rules .notecard-body {
    font-size: 1.5rem;
    line-height: 1.5rem;
    background: none;
  }
  .rules .notecard-body strong {
    font-size: 2rem;
    line-height: 1.3rem;
  }

  /* ── PRINCIPLES: diagram labels ── */
  .combo-shapes-diagram__label {
    font-size: 1.6rem;
    left: 71%;
  }
  .practice-performance-diagram__label {
    font-size: 1.6rem;
    line-height: 1.6rem;
  }
  .practice-performance-diagram__label--low  { width: 130px; left: 46%; top:18%; }
  .practice-performance-diagram__label--high { width: 130px; left: 49%; top: 81%; }
  .practice-performance-diagram__label--enables {
    font-size: 1.4rem;
    width: 60px;
    top: 51%;
  }

  /* ── FOOTER ── */
  .site-footer p { font-size: 1.1rem; line-height: 1.5; }
}

/* ── ABOUT ──────────────────────────────────────────────────────────────────── */
/* Prose and a face — editorial, not cards */
.about {
  background: var(--ink);
  padding: 5rem 0 4.5rem;
}

.about-inner {
  display: grid;
  grid-template-columns: 1fr 200px;
  gap: 4rem;
  align-items: start;
}

.about-heading {
  font-family: var(--font-display);
  font-size: clamp(1.85rem, 3.5vw, 2.6rem);
  font-weight: 700;
  color: var(--paper);
  margin-bottom: 1.25rem;
}

.about-text p {
  font-family: var(--font-display);
  font-size: 1.5rem;
  color: var(--paper-subtle);
  line-height: 1.25;
  margin-bottom: 1rem;
  font-weight: 600;
}

.about-text p:last-child { margin-bottom: 0; }

.about-cta {
  border-left: 2px solid var(--rule);
  padding-left: 1rem;
  color: var(--paper) !important;
  font-weight: 500;
  font-style: italic;
}

.about-photo-col {
  padding-top: 0.25rem;
}

.about-photo {
  display: block;
  width: 100%;
  aspect-ratio: 1;
  border-radius: 100px;
  object-fit: cover;
  object-position: center top;
  
}

@media (max-width: 640px) {
  .about-inner {
    grid-template-columns: 1fr;
    gap: 2rem;
  }
  .about-photo { max-width: 140px; }
  .about-photo-col { text-align: center; }
  .about-photo     { margin: 0 auto; }
}

/* ── FOOTER ─────────────────────────────────────────────────────────────────── */
.site-footer {
  background: var(--ink);
  padding: 1.75rem 0;
}

.site-footer p {
  font-family: var(--font-display);
  font-size: 1.5rem;
  color: var(--paper-subtle);
  font-weight: 600;
  text-align: center;
}

.site-footer strong { color: var(--paper-subtle); }

.site-footer a {
  color: var(--paper);
  text-decoration: underline;
  
}

.site-footer a:hover { text-decoration: underline; }

/* ── MOBILE: 480px ────────────────────────────────────────────────────────── */
/* (see signup-form block above for the existing 480px rules)                  */

/* ── MOBILE: 430px — phone-specific refinements ────────────────────────────── */
@media (max-width: 430px) {

  /* ── GLOBAL: container padding ── */
  .container,
  .header-inner,
  .practice-cta .container {
    padding-left: 1.25rem;
    padding-right: 1.25rem;
  }

  /* ── HEADER ── */
  .site-logo { width: 120px; }

  /* ── HERO: whiteboard → portrait ── */
  .hero-section { padding: 2.5rem 0 3rem; }

  .whiteboard {
    padding: 2rem 1.75rem;
    border-width: 7px;
  }
  .whiteboard::after {
    bottom: -16px;
    left: -8px;
    right: -8px;
    height: 10px;
  }

  /* ── DEFINITION ── */
  .definition { padding: 3.5rem 0 3rem; }

  .card-stamp {
    width: 72px;
    height: 72px;
    margin: -0.5rem 0.75rem 0.5rem -0.75rem;
  }
  .def-diagram { min-height: 130px; }

  /* ── FAIL SECTION: guide positions — mobile (1-column grid) ── */
  .cursor-guide { display: none; }

  .guide--v2 { left: 24px; }
  .guide--v3 { left: calc(100% - 24px); }
  .guide--h2 { top: 24px; }

  /* ── NOTECARD: padding + stamp ── */
  .notecard { padding: 1.25rem 1.25rem; }
  .notecard .card-stamp {
    width: 52px;
    height: 52px;
  }
  .six-shapes h2{
    margin-top: 43px;
  }

  /* ── PRACTICE CTA ── */
  .practice-cta { padding: 3.5rem 0; }
  .practice-series-group__label { font-size: 1rem; margin-bottom:0; text-align: center;}
  .practice-card{display: none;}


  /* ── ABOUT ── */
  .about { padding: 3rem 0 2.5rem; }
  .about-text p { font-size: 1.2rem; }
}
