/* ============================================================
   PAIGE SIMM — CASE STUDY BASE STYLES
   Replaces the original case-study.css
   Works with style.css (vars: --bg, --card, --dark, --white,
   --accent, --accent2, --muted, --border, --serif, --sans,
   --glass-bg, --glass-border, --glass-shadow)
   ============================================================ */

body {
  background: linear-gradient(145deg, #faf7f2 0%, #f0ebe1 100%);
  color: var(--dark);
}

/* ---- FLOATING BLOBS ---- */
body::before {
  content: '';
  position: fixed;
  top: -20%; left: -10%;
  width: 80vw; height: 80vw;
  background: radial-gradient(circle, rgba(232,98,42,0.07) 0%, transparent 70%);
  border-radius: 50%;
  pointer-events: none; z-index: -2;
  animation: floatA 24s infinite alternate ease-in-out;
}
body::after {
  content: '';
  position: fixed;
  bottom: -10%; right: -10%;
  width: 70vw; height: 70vw;
  background: radial-gradient(circle, rgba(240,164,74,0.05) 0%, transparent 70%);
  border-radius: 50%;
  pointer-events: none; z-index: -2;
  animation: floatB 20s infinite alternate ease-in-out;
}
@keyframes floatA { 0%{transform:translate(0,0) scale(1)} 100%{transform:translate(5%,4%) scale(1.08)} }
@keyframes floatB { 0%{transform:translate(0,0) scale(1)} 100%{transform:translate(-4%,-6%) scale(1.12)} }

/* ---- STICKY READING PROGRESS ---- */
#reading-progress {
  position: fixed;
  top: 0; left: 0;
  height: 3px; z-index: 9999;
  background: linear-gradient(90deg, var(--accent), var(--accent2));
  width: 0%;
  transition: width 0.08s linear;
  pointer-events: none;
}

/* ---- STICKY SECTION TRACKER (right side) ---- */
#section-dots {
  position: fixed;
  right: 1.5rem; top: 50%;
  transform: translateY(-50%);
  display: flex; flex-direction: column; gap: 0.5rem;
  z-index: 50;
}
.sdot {
  width: 6px; height: 6px;
  border-radius: 50%;
  background: rgba(0,0,0,0.15);
  transition: background 0.3s, transform 0.3s;
  cursor: pointer;
}
.sdot.active { background: var(--accent); transform: scale(1.5); }
@media (max-width: 768px) { #section-dots { display: none; } }

/* ---- NAV (light glass, matches homepage) ---- */
.nav {
  background: rgba(250,247,242,0.75);
  backdrop-filter: blur(20px);
  border-bottom: 1px solid rgba(0,0,0,0.05);
}
.nav.scrolled { background: rgba(250,247,242,0.92); }
.nav-logo, .nav-links a { color: var(--dark); }

/* ---- HERO ---- */
.cs-hero {
  min-height: 85vh;
  display: flex; flex-direction: column; justify-content: flex-end;
  padding: 0 3rem 4rem;
  position: relative; overflow: hidden;
}
.cs-hero-bg { position: absolute; inset: 0; z-index: 0; }
.cs-hero-bg::before, .cs-hero-bg::after {
  content: '';
  position: absolute; border-radius: 50%;
  filter: blur(90px); opacity: 0.55; z-index: 0;
}
.cs-hero-bg::before { top:-20%; right:-10%; width:70%; height:70%; }
.cs-hero-bg::after  { bottom:-20%; left:-10%; width:60%; height:60%; }

/* Per-project hero colours */
.cs-hero.splashy  .cs-hero-bg::before { background: radial-gradient(circle,#a0d8ef,#3a9fb0); }
.cs-hero.splashy  .cs-hero-bg::after  { background: radial-gradient(circle,#c5edf5,#6ecfe0); }
.cs-hero.automote .cs-hero-bg::before { background: radial-gradient(circle,#80a0ff,#3a5fcc); }
.cs-hero.automote .cs-hero-bg::after  { background: radial-gradient(circle,#b0c4ff,#5a7fdf); }
.cs-hero.hunza    .cs-hero-bg::before { background: radial-gradient(circle,#c8a96e,#a07a3a); }
.cs-hero.hunza    .cs-hero-bg::after  { background: radial-gradient(circle,#e8cfa0,#c89a50); }

.cs-hero-top {
  position: absolute; top: 6rem; left: 3rem; right: 3rem;
  display: flex; justify-content: space-between; z-index: 2;
  opacity: 0; animation: fadeUp 0.7s 0.3s forwards;
  flex-wrap: wrap; gap: 0.5rem;
}
.cs-eyebrow, .cs-year {
  font-size: 0.68rem; letter-spacing: 0.18em; text-transform: uppercase;
  background: rgba(255,255,255,0.65); backdrop-filter: blur(6px);
  padding: 0.3rem 0.85rem; border-radius: 40px; color: var(--dark);
}
.cs-eyebrow { color: var(--accent); }
.cs-year    { color: rgba(0,0,0,0.45); }

.cs-hero-content { position: relative; z-index: 2; }
.cs-title {
  font-family: var(--serif);
  font-size: clamp(3.5rem, 9vw, 8.5rem);
  line-height: 0.9; letter-spacing: -0.02em; color: var(--dark);
}
.cs-title-line {
  display: block; opacity: 0; transform: translateY(22px);
  animation: slideUp 0.9s cubic-bezier(0.16,1,0.3,1) forwards;
}
.cs-title-line:nth-child(1) { animation-delay: 0.1s; }
.cs-title-line:nth-child(2) { animation-delay: 0.25s; font-style: italic; color: var(--accent); }

.cs-hero-meta {
  display: flex; gap: 0; flex-wrap: wrap;
  margin-top: 2.5rem; padding-top: 2rem;
  border-top: 1px solid rgba(0,0,0,0.08);
  opacity: 0; animation: fadeUp 0.8s 0.7s forwards;
}
.cs-hero-meta > div {
  padding: 0 2.5rem 0 0; margin: 0 2.5rem 0 0;
  border-right: 1px solid rgba(0,0,0,0.1);
}
.cs-hero-meta > div:last-child { border-right: none; margin-right: 0; padding-right: 0; }
.cs-meta-label {
  font-size: 0.6rem; letter-spacing: 0.18em; text-transform: uppercase;
  color: rgba(0,0,0,0.4); margin-bottom: 0.3rem;
}
.cs-meta-value { font-size: 0.9rem; font-weight: 500; color: var(--dark); }

/* ---- SECTIONS ---- */
.cs-section {
  padding: 5rem 3rem;
  border-bottom: 1px solid rgba(0,0,0,0.05);
  opacity: 0; transform: translateY(28px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}
.cs-section.visible { opacity: 1; transform: none; }
.cs-section:nth-child(even) { background: rgba(255,255,255,0.35); }
.inner { max-width: 1100px; margin: 0 auto; }

.section-label {
  font-size: 0.68rem; letter-spacing: 0.2em; text-transform: uppercase;
  color: var(--accent); display: inline-block;
  background: rgba(232,98,42,0.08); padding: 0.2rem 0.8rem;
  border-radius: 40px; margin-bottom: 1rem;
}
.section-heading {
  font-family: var(--serif);
  font-size: clamp(1.8rem, 3vw, 2.8rem);
  line-height: 1.08; letter-spacing: -0.02em; color: var(--dark);
  margin-bottom: 1.8rem;
}
.sec-num {
  font-family: var(--serif); font-style: italic;
  font-size: clamp(5rem, 12vw, 9rem); line-height: 1;
  color: rgba(0,0,0,0.04);
  position: absolute; top: 1rem; right: 0;
  pointer-events: none; user-select: none; letter-spacing: -0.04em;
}

/* ---- STAT PILLS (animated counters) ---- */
.stat-row { display: flex; flex-wrap: wrap; gap: 0.75rem; margin: 2.5rem 0; }
.stat-pill {
  background: rgba(255,255,255,0.75);
  backdrop-filter: blur(14px);
  border: 1px solid rgba(255,255,255,0.9);
  border-radius: 60px; padding: 0.9rem 1.6rem;
  display: flex; align-items: baseline; gap: 0.6rem;
  transition: transform 0.3s, background 0.3s, box-shadow 0.3s;
  cursor: default;
}
.stat-pill:hover {
  transform: translateY(-4px);
  background: rgba(255,255,255,0.95);
  box-shadow: 0 12px 30px rgba(232,98,42,0.12);
}
.stat-pill-val {
  font-family: var(--serif); font-style: italic;
  font-size: 2rem; color: var(--accent); line-height: 1;
}
.stat-pill-label {
  font-size: 0.65rem; letter-spacing: 0.08em; text-transform: uppercase;
  color: var(--muted); max-width: 14ch; line-height: 1.3;
}

/* ---- GLASS CARD ---- */
.glass-card {
  background: rgba(255,255,255,0.65);
  backdrop-filter: blur(14px) saturate(150%);
  border: 1px solid rgba(255,255,255,0.85);
  border-radius: 24px; overflow: hidden;
  position: relative;
  transition: transform 0.3s, box-shadow 0.3s;
}
.glass-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 20px 50px rgba(0,0,0,0.08);
}

/* ---- TWO COL ---- */
.two-col {
  display: grid; grid-template-columns: 1fr 1fr;
  gap: 3rem 5rem; align-items: start; margin-top: 1rem;
}
.body-text p {
  font-size: 1rem; line-height: 1.85;
  color: rgba(0,0,0,0.58); margin-bottom: 1rem;
}
.body-text p strong { color: var(--dark); font-weight: 600; }

/* ---- PROBLEM GRID ---- */
.problem-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 0.75rem; }
.prob {
  background: rgba(255,255,255,0.65);
  backdrop-filter: blur(14px);
  border: 1px solid rgba(255,255,255,0.85);
  border-top: 3px solid var(--accent);
  border-radius: 20px; padding: 1.6rem;
  transition: transform 0.3s, box-shadow 0.3s;
}
.prob:hover { transform: translateY(-4px); box-shadow: 0 16px 40px rgba(232,98,42,0.1); }
.prob-n {
  font-family: var(--serif); font-style: italic; font-size: 3rem;
  color: rgba(232,98,42,0.1); line-height: 1; margin-bottom: 0.7rem;
}
.prob-t { font-size: 0.97rem; font-weight: 700; color: var(--dark); margin-bottom: 0.4rem; }
.prob-b { font-size: 0.86rem; line-height: 1.72; color: var(--muted); }

/* ---- INSIGHTS ---- */
.insights { display: flex; flex-direction: column; gap: 0.75rem; }
.insight {
  background: rgba(255,255,255,0.65);
  backdrop-filter: blur(14px);
  border: 1px solid rgba(255,255,255,0.85);
  border-left: 3px solid var(--accent);
  border-radius: 0 20px 20px 0;
  padding: 1.2rem 1.5rem;
  transition: transform 0.25s, border-left-color 0.25s, box-shadow 0.25s;
}
.insight:hover {
  transform: translateX(4px);
  border-left-color: var(--accent2);
  box-shadow: 0 8px 24px rgba(0,0,0,0.06);
}
.insight-q {
  font-family: var(--serif); font-style: italic; font-size: 1rem;
  color: var(--dark); margin-bottom: 0.5rem; line-height: 1.4;
}
.insight-a { font-size: 0.85rem; line-height: 1.75; color: var(--muted); }

/* ---- USER FLOW (bubble chain) ---- */
.user-flow {
  display: flex; flex-wrap: wrap;
  align-items: center; justify-content: center; gap: 0.4rem;
  background: rgba(255,255,255,0.5); backdrop-filter: blur(12px);
  border-radius: 80px; padding: 1rem 2rem;
}
.flow-step { display: flex; align-items: center; }
.flow-box {
  background: white; border-radius: 60px;
  padding: 0.55rem 1.1rem;
  font-size: 0.78rem; font-weight: 600; color: var(--dark);
  box-shadow: 0 2px 8px rgba(0,0,0,0.04);
  border: 1px solid rgba(0,0,0,0.06);
  transition: transform 0.2s, box-shadow 0.2s;
}
.flow-box:hover { transform: translateY(-2px); box-shadow: 0 6px 16px rgba(0,0,0,0.08); }
.flow-box--accent { background: var(--accent); color: white; border-color: var(--accent); }
.flow-box--blue   { background: #5a7fdf; color: white; border-color: #5a7fdf; }
.flow-arrow {
  width: 24px; height: 2px; background: rgba(0,0,0,0.18);
  position: relative; margin: 0 0.2rem; flex-shrink: 0;
}
.flow-arrow::after {
  content: ''; position: absolute; right: 0; top: -3px;
  border: 4px solid transparent; border-left-color: rgba(0,0,0,0.2);
}

/* ---- WIREFRAMES ---- */
.wireframes { display: grid; grid-template-columns: repeat(3,1fr); gap: 0.75rem; margin-top: 2rem; }
.wireframe {
  background: rgba(255,255,255,0.65);
  backdrop-filter: blur(14px);
  border: 1px solid rgba(255,255,255,0.85);
  border-radius: 20px; overflow: hidden;
  transition: transform 0.3s, box-shadow 0.3s;
}
.wireframe:hover { transform: translateY(-6px); box-shadow: 0 18px 40px rgba(0,0,0,0.1); }
.wf-bar { padding: 0.6rem 0.8rem; background: rgba(0,0,0,0.03); display: flex; gap: 0.4rem; }
.wf-dot { width: 7px; height: 7px; border-radius: 50%; }
.wf-dot:nth-child(1){background:#FF5F57} .wf-dot:nth-child(2){background:#FEBC2E} .wf-dot:nth-child(3){background:#28C840}
.wf-body { padding: 1rem; display: flex; flex-direction: column; gap: 0.5rem; }
.wf-line { height: 7px; border-radius: 10px; background: rgba(0,0,0,0.08); }
.wf-line--short{width:40%} .wf-line--med{width:65%} .wf-line--full{width:100%}
.wf-block { height: 48px; border-radius: 10px; background: rgba(0,0,0,0.05); border: 1.5px dashed rgba(0,0,0,0.12); display:flex;align-items:center;justify-content:center; }
.wf-block--btn { height: 28px; border-radius: 40px; background: rgba(232,98,42,0.15); border: 1.5px solid rgba(232,98,42,0.3); width: 55%; }
.wf-label { font-size: 0.62rem; letter-spacing: 0.12em; text-transform: uppercase; color: rgba(0,0,0,0.45); font-weight: 700; text-align: center; padding: 0.6rem 0.8rem 0.2rem; }
.wf-version { font-size: 0.58rem; color: rgba(0,0,0,0.35); padding: 0.3rem 0.8rem 0.9rem; line-height: 1.5; text-align: center; }

/* ---- PHONES SHOWCASE (LARGE) ---- */
.phones-showcase {
  background: linear-gradient(135deg, rgba(168,225,218,0.25), rgba(247,247,245,0.6));
  border: 1px solid rgba(255,255,255,0.85);
  border-radius: 28px; padding: 3rem 2rem 2rem;
  margin-top: 2rem; display: flex; gap: 1.5rem;
  justify-content: center; flex-wrap: wrap; position: relative; overflow: hidden;
}
.phones-showcase::before {
  content: ''; position: absolute; top: 50%; left: 50%;
  transform: translate(-50%,-50%);
  width: 400px; height: 400px; border-radius: 50%;
  background: radial-gradient(circle, rgba(110,207,224,0.12), transparent 70%);
  pointer-events: none;
}
.phone-item { display: flex; flex-direction: column; align-items: center; gap: 0.8rem; z-index: 1; }
.phone-item img {
  width: 140px; height: 300px; object-fit: cover; border-radius: 22px;
  box-shadow: 0 24px 60px rgba(0,0,0,0.18), 0 6px 16px rgba(0,0,0,0.1);
  transition: transform 0.4s cubic-bezier(0.34,1.56,0.64,1);
  display: block;
}
.phone-item:hover img { transform: translateY(-10px) scale(1.02); }
.phone-item:nth-child(even) img { transform: translateY(8px); }
.phone-item:nth-child(even):hover img { transform: translateY(-4px) scale(1.02); }
.phone-stub {
  width: 140px; height: 300px; border-radius: 22px;
  background: rgba(255,255,255,0.5); border: 1.5px solid rgba(0,0,0,0.08);
  display: flex; align-items: center; justify-content: center;
  font-size: 0.62rem; color: rgba(0,0,0,0.3); text-align: center; padding: 1rem;
  font-weight: 600; letter-spacing: 0.04em; text-transform: uppercase;
  transition: transform 0.3s;
}
.phone-item:hover .phone-stub { transform: translateY(-10px); }
.phone-lbl {
  font-size: 0.6rem; font-weight: 700; letter-spacing: 0.12em;
  text-transform: uppercase; color: rgba(0,0,0,0.38);
}

/* ---- DESKTOP SCREENSHOT (full-width) ---- */
.screen-full {
  border-radius: 16px; overflow: hidden;
  border: 1px solid rgba(0,0,0,0.08);
  box-shadow: 0 20px 60px rgba(0,0,0,0.12);
  margin-top: 2rem; transition: transform 0.4s;
}
.screen-full:hover { transform: translateY(-4px); }
.screen-full img { width: 100%; display: block; }
.screen-full-stub {
  width: 100%; height: 340px; background: rgba(0,0,0,0.04);
  display: flex; align-items: center; justify-content: center;
  font-size: 0.7rem; color: rgba(0,0,0,0.25); font-weight: 600;
  letter-spacing: 0.1em; text-transform: uppercase;
}
.screen-duo { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; margin-top: 2rem; }
.screen-duo .screen-full { margin-top: 0; }
.screen-cap {
  font-size: 0.78rem; color: var(--muted); line-height: 1.6;
  padding: 0.9rem 1rem 0;
}

/* ---- ITERATIONS ---- */
.iterations { display: grid; grid-template-columns: 1fr 1fr; gap: 0.75rem; margin-top: 1.5rem; }
.iteration {
  border-radius: 20px; padding: 1.6rem;
  border-left: 4px solid; transition: transform 0.25s;
}
.iteration:hover { transform: translateY(-3px); }
.iteration--problem { background: rgba(255,235,230,0.7); border-left-color: #ff8a7a; border: 1px solid rgba(255,138,122,0.25); border-left: 4px solid #ff8a7a; }
.iteration--solution { background: rgba(230,255,235,0.7); border-left-color: #5cba78; border: 1px solid rgba(92,186,120,0.25); border-left: 4px solid #5cba78; }
.iteration-tag { font-size: 0.58rem; letter-spacing: 0.15em; text-transform: uppercase; font-weight: 700; margin-bottom: 0.6rem; display: block; }
.iteration--problem .iteration-tag { color: #c04040; }
.iteration--solution .iteration-tag { color: #2a7a42; }
.iteration-title { font-size: 0.97rem; font-weight: 700; color: var(--dark); margin-bottom: 0.45rem; }
.iteration-body { font-size: 0.86rem; line-height: 1.72; color: rgba(0,0,0,0.55); }

/* ---- CONSTRAINTS ---- */
.constraints {
  background: rgba(255,255,255,0.65); backdrop-filter: blur(14px);
  border: 1px solid rgba(255,255,255,0.85);
  border-radius: 20px; padding: 1.5rem 1.8rem; margin-top: 1rem;
}
.constraints-title {
  font-size: 0.62rem; letter-spacing: 0.18em; text-transform: uppercase;
  color: var(--accent); font-weight: 700; margin-bottom: 0.9rem;
}
.constraints ul { list-style: none; }
.constraints li {
  font-size: 0.88rem; color: rgba(0,0,0,0.55); line-height: 1.65;
  padding: 0.3rem 0; display: flex; gap: 0.6rem; align-items: flex-start;
  border-bottom: 1px solid rgba(0,0,0,0.04);
}
.constraints li:last-child { border-bottom: none; }
.constraints li::before { content: '→'; color: var(--accent); font-weight: 700; flex-shrink: 0; margin-top: 1px; }

/* ---- OUTCOMES ---- */
.outcomes { display: flex; flex-direction: column; gap: 0.75rem; }
.outcome {
  background: rgba(255,255,255,0.65); backdrop-filter: blur(14px);
  border: 1px solid rgba(255,255,255,0.85);
  border-radius: 20px; padding: 1.4rem 1.6rem;
  display: flex; align-items: flex-start; gap: 1.2rem;
  transition: transform 0.25s, box-shadow 0.25s;
}
.outcome:hover { transform: translateX(6px); box-shadow: 0 8px 24px rgba(0,0,0,0.07); }
.outcome-icon { width: 36px; height: 36px; color: var(--accent); flex-shrink: 0; }
.outcome-icon svg { width: 100%; height: 100%; }
.outcome-t { font-size: 0.97rem; font-weight: 700; color: var(--dark); margin-bottom: 0.3rem; }
.outcome-b { font-size: 0.86rem; line-height: 1.72; color: var(--muted); }

/* ---- BLOCKQUOTE / REFLECTION ---- */
.reflect-wrap { display: grid; grid-template-columns: 1fr 2fr; gap: 3rem; align-items: start; }
blockquote {
  font-family: var(--serif); font-style: italic; font-weight: 600;
  font-size: clamp(1.1rem, 2vw, 1.5rem); line-height: 1.45;
  color: var(--dark); padding: 1.5rem 1.5rem 1.5rem 2rem;
  border-left: 4px solid var(--accent);
  border-radius: 0 20px 20px 0;
  background: rgba(232,98,42,0.05); margin: 0;
}
blockquote em { color: var(--accent); }
.reflect-body p { font-size: 0.95rem; line-height: 1.85; color: rgba(0,0,0,0.55); margin-bottom: 1rem; }
.reflect-body p strong { color: var(--dark); font-weight: 700; }

/* ---- PAIN LIST (Automote) ---- */
.pain-list { list-style: none; }
.pain-item {
  display: grid; grid-template-columns: 2.5rem 1fr; gap: 1.2rem;
  padding: 1.2rem 0; border-bottom: 1px solid rgba(0,0,0,0.06);
  align-items: start; transition: padding-left 0.25s, background 0.25s;
  border-radius: 0 12px 12px 0;
}
.pain-item:first-child { border-top: 1px solid rgba(0,0,0,0.06); }
.pain-item:hover { padding-left: 0.75rem; background: rgba(255,255,255,0.5); }
.pain-num { font-family: var(--serif); font-style: italic; font-size: 1.1rem; color: rgba(232,98,42,0.4); padding-top: 2px; }
.pain-text strong { display: block; font-size: 0.92rem; font-weight: 700; color: var(--dark); margin-bottom: 0.25rem; }
.pain-text p { font-size: 0.84rem; line-height: 1.65; color: var(--muted); }

/* ---- DECISIONS GRID (Automote) ---- */
.decisions-grid { display: grid; grid-template-columns: repeat(3,1fr); gap: 0.75rem; margin-top: 1.5rem; }
.decision-card {
  background: rgba(255,255,255,0.65); backdrop-filter: blur(14px);
  border: 1px solid rgba(255,255,255,0.85);
  border-radius: 20px; padding: 1.5rem;
  transition: transform 0.3s, box-shadow 0.3s;
}
.decision-card:hover { transform: translateY(-5px); box-shadow: 0 16px 40px rgba(0,0,0,0.09); }
.decision-icon { font-size: 1.3rem; margin-bottom: 0.9rem; display: block; }
.decision-title { font-size: 0.92rem; font-weight: 700; color: var(--dark); margin-bottom: 0.4rem; }
.decision-body { font-size: 0.84rem; line-height: 1.7; color: var(--muted); }

/* ---- BEFORE/AFTER (Hunza) ---- */
.ba-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; margin-top: 2rem; }
.ba-panel {
  background: rgba(255,255,255,0.65); backdrop-filter: blur(14px);
  border: 1px solid rgba(255,255,255,0.85);
  border-radius: 20px; overflow: hidden;
  transition: transform 0.3s;
}
.ba-panel:hover { transform: translateY(-4px); }
.ba-header {
  display: flex; align-items: center; justify-content: space-between;
  padding: 0.85rem 1.2rem; border-bottom: 1px solid rgba(0,0,0,0.06);
}
.ba-header span:first-child { font-size: 0.72rem; color: rgba(0,0,0,0.4); font-weight: 500; }
.ba-tag {
  font-size: 0.58rem; letter-spacing: 0.14em; text-transform: uppercase;
  padding: 0.22rem 0.7rem; border-radius: 100px; font-weight: 700;
}
.ba-tag.before { background: rgba(0,0,0,0.06); color: rgba(0,0,0,0.4); }
.ba-tag.after  { background: rgba(232,98,42,0.12); color: var(--accent); }
.ba-panel img { width: 100%; display: block; transition: transform 0.4s; }
.ba-panel:hover img { transform: scale(1.02); }
.ba-img-stub { width: 100%; height: 240px; background: rgba(0,0,0,0.04); display:flex;align-items:center;justify-content:center;font-size:0.7rem;color:rgba(0,0,0,0.25);font-weight:600;letter-spacing:0.1em;text-transform:uppercase; }
.ba-caption { padding: 0.9rem 1.2rem; font-size: 0.76rem; color: var(--muted); line-height: 1.6; }

/* ---- SQL BLOCK (Hunza) ---- */
.sql-highlight { display: grid; grid-template-columns: 1fr 1fr; gap: 2rem; margin-top: 1.5rem; align-items: start; }
.sql-text p { font-size: 0.92rem; line-height: 1.8; color: rgba(0,0,0,0.58); margin-bottom: 1rem; }
.sql-text p strong { color: var(--dark); font-weight: 700; }
.sql-block {
  background: #1a1a18; border: 1px solid rgba(255,255,255,0.06);
  border-radius: 20px; overflow: hidden;
  box-shadow: 0 20px 50px rgba(0,0,0,0.2);
}
.sql-block-header {
  padding: 0.8rem 1.2rem; border-bottom: 1px solid rgba(255,255,255,0.06);
  display: flex; align-items: center; gap: 0.5rem; background: rgba(255,255,255,0.03);
}
.sql-dots { display: flex; gap: 5px; }
.sql-dots span { width: 9px; height: 9px; border-radius: 50%; }
.sql-dots span:nth-child(1){background:#FF5F57} .sql-dots span:nth-child(2){background:#FEBC2E} .sql-dots span:nth-child(3){background:#28C840}
.sql-filename { font-family: monospace; font-size: 0.65rem; color: rgba(255,255,255,0.25); margin-left: 0.5rem; }
.sql-code { font-family: 'Courier New', monospace; font-size: 0.77rem; padding: 1.5rem; color: rgba(130,200,130,0.9); line-height: 1.9; }
.sql-kw  { color: rgba(130,160,255,0.9); }
.sql-str { color: rgba(255,190,100,0.9); }
.sql-comment { color: rgba(255,255,255,0.22); font-style: italic; }

/* ---- ROLE SECTION (Hunza) ---- */
.role-bento { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; margin-top: 1.5rem; }
.role-list-card {
  background: rgba(255,255,255,0.65); backdrop-filter: blur(14px);
  border: 1px solid rgba(255,255,255,0.85); border-radius: 20px; padding: 1.8rem;
}
.role-list { list-style: none; }
.role-item {
  display: flex; align-items: flex-start; gap: 0.9rem;
  padding: 0.85rem 0; border-bottom: 1px solid rgba(0,0,0,0.05);
  font-size: 0.88rem; color: rgba(0,0,0,0.6); line-height: 1.55;
  transition: padding-left 0.2s;
}
.role-item:hover { padding-left: 0.4rem; color: var(--dark); }
.role-item:first-child { padding-top: 0; }
.role-item:last-child { border-bottom: none; padding-bottom: 0; }
.check {
  width: 20px; height: 20px; border-radius: 50%;
  background: rgba(232,98,42,0.1); border: 1px solid rgba(232,98,42,0.25);
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0; color: var(--accent); margin-top: 1px;
}
.tools-card { display: flex; flex-direction: column; gap: 0.75rem; }
.aside-box {
  background: rgba(255,255,255,0.65); backdrop-filter: blur(14px);
  border: 1px solid rgba(255,255,255,0.85); border-radius: 16px;
  padding: 1.2rem; flex: 1;
}
.aside-title { font-size: 0.6rem; letter-spacing: 0.2em; text-transform: uppercase; color: var(--accent); font-weight: 700; margin-bottom: 0.8rem; }
.tags { display: flex; flex-wrap: wrap; gap: 0.4rem; }
.tag {
  font-size: 0.62rem; letter-spacing: 0.07em; text-transform: uppercase;
  padding: 0.25rem 0.65rem;
  border: 1px solid rgba(0,0,0,0.12); border-radius: 100px;
  color: var(--muted); transition: all 0.2s;
}
.tag:hover { background: var(--accent); color: white; border-color: var(--accent); }

/* ---- END STRIP ---- */
.cs-end {
  max-width: 1100px; margin: 0 auto; padding: 4rem 3rem;
  display: flex; justify-content: space-between; align-items: center;
  flex-wrap: wrap; gap: 1.5rem;
}
.end-label { font-size: 0.6rem; letter-spacing: 0.2em; text-transform: uppercase; color: var(--muted); margin-bottom: 0.3rem; }
.end-link { font-family: var(--serif); font-size: 2rem; text-decoration: none; color: var(--dark); display: block; transition: color 0.2s; }
.end-link:hover { color: var(--accent); }
.end-cta { background: var(--dark); color: white; padding: 0.7rem 1.5rem; border-radius: 40px; text-decoration: none; font-size: 0.8rem; font-weight: 600; transition: background 0.2s, transform 0.2s; }
.end-cta:hover { background: var(--accent); transform: translateY(-2px); }

/* ---- FOOTER ---- */
footer { background: transparent; border-top: 1px solid rgba(0,0,0,0.06); padding: 1.5rem 3rem; }
footer span, footer a { color: rgba(0,0,0,0.35); font-size: 0.72rem; }
footer a:hover { color: var(--accent); }

/* ---- KEYFRAMES ---- */
@keyframes slideUp { to { opacity: 1; transform: translateY(0); } }
@keyframes fadeUp  { to { opacity: 1; } }

/* ---- RESPONSIVE ---- */
@media (max-width: 900px) {
  .two-col, .reflect-wrap, .role-bento, .sql-highlight,
  .ba-grid, .decisions-grid { grid-template-columns: 1fr; gap: 1.5rem; }
  .decisions-grid { grid-template-columns: 1fr 1fr; }
  .wireframes { grid-template-columns: 1fr 1fr; }
  .screen-duo { grid-template-columns: 1fr; }
}
@media (max-width: 640px) {
  .cs-hero { padding: 0 1.5rem 3rem; }
  .cs-hero-top { left: 1.5rem; right: 1.5rem; top: 5rem; flex-direction: column; align-items: flex-start; }
  .cs-section { padding: 3.5rem 1.5rem; }
  .cs-hero-meta { flex-direction: column; gap: 1rem; }
  .cs-hero-meta > div { border-right: none; border-bottom: 1px solid rgba(0,0,0,0.08); padding: 0 0 0.8rem; margin: 0; }
  .cs-hero-meta > div:last-child { border-bottom: none; padding-bottom: 0; }
  .problem-grid, .iterations, .pain-list .two-col { grid-template-columns: 1fr; }
  .wireframes { grid-template-columns: 1fr; }
  .decisions-grid { grid-template-columns: 1fr; }
  .phones-showcase { padding: 1.5rem 0.8rem; gap: 0.75rem; }
  .phone-item img, .phone-stub { width: 100px; height: 215px; }
  .user-flow { border-radius: 24px; flex-direction: column; }
  .flow-arrow { width: 2px; height: 20px; margin: 0; }
  .flow-arrow::after { top: auto; bottom: 0; left: -3px; border-left: none; border-top-color: rgba(0,0,0,0.2); }
  .cs-end { padding: 2.5rem 1.5rem; flex-direction: column; align-items: flex-start; }
  footer { padding: 1.5rem; }
  .stat-row { gap: 0.5rem; }
  .stat-pill { padding: 0.7rem 1.1rem; }
  .stat-pill-val { font-size: 1.5rem; }
}

/* =====================================================
   IMAGE SIZING FIXES — appended
   ===================================================== */

/* Before/after panels: never collapse, images never squash */
.ba-panel img {
  width: 100%;
  height: auto;          /* KEY FIX: was collapsing to 0 */
  min-height: 220px;
  object-fit: cover;
  display: block;
}
.ba-img-stub {
  min-height: 240px;    /* bigger stub when image missing */
}

/* Screen full images: height auto, not fixed */
.screen-full img {
  width: 100%;
  height: auto;
  min-height: 200px;
  object-fit: cover;
  display: block;
}
.screen-full-stub {
  min-height: 320px;
}

/* Phone showcase: bigger and not fixed-height collapsed */
.phones-showcase {
  padding: 3rem 2rem 2.5rem;
}
.phone-item img {
  width: 150px;
  height: 324px;         /* 2:1 ratio at 150px wide */
  object-fit: cover;
  border-radius: 24px;
  box-shadow: 0 28px 64px rgba(0,0,0,0.2), 0 8px 20px rgba(0,0,0,0.12);
  display: block;
  transition: transform 0.4s cubic-bezier(0.34,1.56,0.64,1);
}
.phone-item:nth-child(even) img   { transform: translateY(12px); }
.phone-item:hover img              { transform: translateY(-12px) scale(1.02); }
.phone-item:nth-child(even):hover img { transform: translateY(0) scale(1.02); }
.phone-stub {
  width: 150px;
  height: 324px;
  min-height: unset;
}

/* Desktop screen duo: reasonable height */
.screen-duo {
  gap: 1.2rem;
}
.screen-duo .screen-full img {
  min-height: 280px;
  max-height: 480px;
}

/* Wireframe cards: a bit taller */
.wf-body {
  padding: 1.2rem;
  min-height: 140px;
}

/* Stat row pills: slightly bigger on desktop */
.stat-pill {
  padding: 1rem 1.8rem;
}
.stat-pill-val {
  font-size: 2.2rem;
}

/* Section breathing room */
.cs-section {
  padding: 5.5rem 3rem;
}

/* Larger section headings */
.section-heading {
  font-size: clamp(1.9rem, 3.2vw, 3rem);
}

/* Mobile fixes */
@media (max-width: 640px) {
  .phone-item img, .phone-stub { width: 110px; height: 238px; }
  .phones-showcase { padding: 1.5rem 0.75rem; gap: 0.6rem; }
  .ba-panel img { min-height: 160px; }
  .screen-full-stub { min-height: 200px; }
}
