/* ══════════════════════════════════════════════
   storylab — homepage styles
   ══════════════════════════════════════════════ */

/* ── HERO ── */
.hero {
  height: 100vh; height: 100dvh; min-height: 500px;
  display: flex; flex-direction: column;
  justify-content: center; align-items: center;
  position: relative; overflow: hidden;
  background: var(--off-white);
  padding: 80px clamp(16px, 4vw, 56px) 60px;
  padding-top: max(80px, calc(env(safe-area-inset-top, 0px) + 60px));
}
.hero-geo {
  position: relative;
  width: min(92vw, 720px);
  height: min(55vh, 480px);
  min-height: 240px;
  display: flex; justify-content: center; align-items: center;
}
.hero-geo canvas { position: absolute; top: 0; left: 0; width: 100%; height: 100%; }
.wm-wrap {
  position: relative; z-index: 2; text-align: center;
  opacity: 0; animation: fadeWM 1.8s ease 9.5s forwards;
}
.wm-wrap h1 { font-family: var(--font); font-size: clamp(36px, 10vw, 84px); font-weight: 400; letter-spacing: -0.02em; line-height: 1; }
.wm-wrap .st { color: var(--black); }
.wm-wrap .lb { color: var(--redwood); }
.wm-wrap .rg { font-size: clamp(8px, 2vw, 14px); vertical-align: super; color: var(--redwood); font-weight: 400; }
.hero-tag {
  margin-top: clamp(20px, 4vh, 36px);
  font-family: var(--font); font-size: clamp(16px, 2.8vw, 22px);
  font-weight: 500; font-style: normal; letter-spacing: 0.04em;
  color: var(--gray-body); text-align: center; padding: 0 20px;
  opacity: 0; animation: fadeUp 1s ease 10.8s forwards;
}
.hero-tag .ht-d { color: var(--redwood); }
.scroll-cue {
  position: absolute; bottom: clamp(20px, 4vh, 48px);
  left: 50%; transform: translateX(-50%);
  display: flex; flex-direction: column; align-items: center; gap: 10px;
  opacity: 0; animation: fadeUp 1s ease 11.6s forwards;
}
.scroll-cue span { font-family: var(--font); font-size: 9px; font-weight: 600; letter-spacing: 0.3em; text-transform: uppercase; color: var(--gray-mid); }
.sc-line { width: 1px; height: 36px; position: relative; overflow: hidden; }
.sc-line::after { content: ''; position: absolute; top: -100%; left: 0; width: 1px; height: 100%; background: linear-gradient(to bottom, transparent, var(--gray-mid)); animation: scPulse 2s ease infinite; }
@keyframes scPulse { 0%{top:-100%} 100%{top:100%} }

/* ── MANIFESTO ── */
.manifesto { text-align: center; }
.manifesto p { font-family: var(--font); font-size: clamp(22px, 3.5vw, 32px); font-weight: 400; line-height: 1.65; color: var(--black); max-width: 820px; margin: 0 auto; }
.manifesto em { font-style: italic; color: var(--redwood); }
.manifesto .m-attr { margin-top: 56px; font-family: var(--font); font-size: 11px; font-weight: 600; letter-spacing: 0.22em; text-transform: uppercase; color: var(--gray-mid); }
.manifesto .m-attr .mr { color: var(--redwood); }

/* ── FOUNDATIONAL STORYLABS ── */
.fs-sec { padding: clamp(80px, 10vw, 140px) clamp(20px, 4vw, 56px) clamp(100px, 12vw, 160px); background: var(--black); color: var(--white); }
.fs-sec > h2 { font-family: var(--font); font-size: clamp(24px, 3.5vw, 36px); font-weight: 400; line-height: 1.5; max-width: 600px; margin-bottom: clamp(48px, 6vw, 80px); }
.fs-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 1px; background: rgba(255,255,255,0.07); max-width: 1200px; margin: 0 auto; }
.fs-card { background: var(--black); padding: clamp(32px, 4vw, 56px) clamp(24px, 3.5vw, 52px); cursor: pointer; transition: all 0.5s cubic-bezier(0.25, 0.1, 0.25, 1); min-height: 300px; display: flex; flex-direction: column; justify-content: space-between; position: relative; overflow: hidden; }
.fs-card::after { content: ''; position: absolute; inset: 0; background: var(--redwood); opacity: 0; transition: opacity 0.5s ease; }
.fs-card:hover::after { opacity: 0.06; }
.fs-card > * { position: relative; z-index: 1; }
.c-geo { width: 80px; height: 80px; margin-bottom: 36px; opacity: 0.35; transition: opacity 0.5s ease; }
.fs-card:hover .c-geo { opacity: 0.9; }
.c-geo svg { width: 100%; height: 100%; }
.fs-card h3 { font-family: var(--font); font-size: clamp(22px, 2.5vw, 26px); font-weight: 500; margin-bottom: 14px; }
.fs-card .c-sub { font-family: var(--font); font-size: 15px; font-weight: 400; font-style: italic; color: rgba(255,255,255,0.55); max-width: 320px; line-height: 1.7; }
.c-bot { display: flex; justify-content: space-between; align-items: flex-end; margin-top: 40px; }
.c-tags { display: flex; gap: 10px; flex-wrap: wrap; }
.c-tag { font-family: var(--font); font-size: 9px; font-weight: 600; letter-spacing: 0.15em; text-transform: uppercase; padding: 5px 14px; border: 1px solid rgba(255,255,255,0.15); color: rgba(255,255,255,0.5); }
a.c-arr-link,
a.c-arr-link:link,
a.c-arr-link:visited,
a.c-arr-link:hover,
a.c-arr-link:active,
a.c-arr-link:focus {
  text-decoration: none !important;
  text-decoration-line: none !important;
  -webkit-text-decoration: none !important;
  color: var(--redwood) !important;
  display: inline-flex;
  border: none;
  border-bottom: none !important;
  outline: none;
  box-shadow: none !important;
}
.fs-card a, .fs-card a:link, .fs-card a:visited { text-decoration: none !important; color: inherit !important; }
.c-arr { font-size: 22px; color: var(--redwood) !important; opacity: 0; transform: translateX(-8px); transition: all 0.4s ease; }
.fs-card:hover .c-arr { opacity: 1; transform: translateX(0); }

/* ── WE THINK DIFFERENTLY ── */
.wr-sec { display: flex; justify-content: center; }
.wr-in { max-width: 740px; width: 100%; }
.wr-in h2 { font-family: var(--font); font-size: clamp(24px, 3.5vw, 34px); font-weight: 400; line-height: 1.6; margin-bottom: 56px; }
.wr-in h2 strong { font-weight: 600; color: var(--redwood); }
.wr-in p { font-family: var(--font); font-size: 17px; font-weight: 400; line-height: 1.9; color: var(--gray-body); margin-bottom: 24px; }
.wr-in p em { font-style: italic; color: var(--black); }
.scale-row { margin-top: 64px; padding-top: 56px; border-top: 1px solid var(--gray-subtle); display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 200px), 1fr)); gap: clamp(32px, 4vw, 48px); }
.scale-item .sc-lbl { font-family: var(--font); font-size: 10px; font-weight: 600; letter-spacing: 0.22em; text-transform: uppercase; color: var(--redwood); margin-bottom: 14px; }
.scale-item h4 { font-family: var(--font); font-size: 20px; font-weight: 500; margin-bottom: 10px; color: var(--black); }
.scale-item p { font-family: var(--font); font-size: 14px; font-weight: 400; color: var(--gray-body); line-height: 1.75; margin-bottom: 0; }
.cl-scroll { margin-top: 80px; padding-top: 48px; border-top: 1px solid var(--gray-subtle); }
.cl-scroll .cl-lbl { font-family: var(--font); font-size: 10px; font-weight: 600; letter-spacing: 0.25em; text-transform: uppercase; color: var(--gray-mid); margin-bottom: 28px; }
.cl-names { font-family: var(--font); font-size: clamp(14px, 1.8vw, 16px); font-weight: 400; font-style: italic; color: var(--gray-mid); line-height: 2.4; }
.cl-names .sep { margin: 0 clamp(8px, 1.5vw, 18px); color: var(--gray-subtle); }

/* ── CAPABILITIES ── */
.cap-sec { padding: clamp(56px, 8vw, 100px) clamp(20px, 4vw, 56px); border-top: 1px solid var(--gray-subtle); border-bottom: 1px solid var(--gray-subtle); background: var(--gray-light); }
.cap-sec .sl { text-align: center; }
.cap-list { display: flex; flex-wrap: wrap; justify-content: center; gap: 14px; max-width: 960px; margin: 0 auto; }
.cap-pill { font-family: var(--font); font-size: 14px; font-weight: 400; padding: 12px 28px; border: 1px solid var(--gray-subtle); background: var(--white); color: var(--black); transition: all 0.3s ease; cursor: default; border-radius: 2px; }
.cap-pill:hover { border-color: var(--redwood); color: var(--redwood); }

/* ── COURSES ── */
.crs-sec { text-align: center; }
.crs-sec h2 { font-family: var(--font); font-size: clamp(24px, 3.5vw, 34px); font-weight: 400; margin-bottom: 16px; line-height: 1.4; }
.crs-sub { font-family: var(--font); font-size: 16px; font-weight: 400; font-style: italic; color: var(--gray-mid); margin-bottom: clamp(48px, 6vw, 72px); }
.crs-sub .cr { color: var(--redwood); }
.crs-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 280px), 1fr)); gap: 32px; max-width: 1020px; margin: 0 auto; }
.crs-card { text-align: left; padding: clamp(32px, 3.5vw, 44px) clamp(24px, 3vw, 36px); border: 1px solid var(--gray-subtle); transition: all 0.4s ease; cursor: pointer; }
.crs-card:hover { border-color: var(--redwood); }
.crs-card h4 { font-family: var(--font); font-size: 21px; font-weight: 500; margin-bottom: 14px; line-height: 1.35; }
.crs-card p { font-family: var(--font); font-size: 15px; font-weight: 400; color: var(--gray-body); line-height: 1.75; }
.crs-card .crs-w { margin-top: 20px; font-family: var(--font); font-size: 10px; font-weight: 600; letter-spacing: 0.15em; text-transform: uppercase; color: var(--redwood); }

/* ── THE LAB ── */
.lab-sec { padding: clamp(80px, 10vw, 140px) clamp(20px, 4vw, 56px) clamp(100px, 12vw, 160px); background: var(--black); color: var(--white); }
.lab-hd { text-align: center; margin-bottom: clamp(48px, 6vw, 80px); }
.lab-hd h2 { font-family: var(--font); font-size: clamp(28px, 4vw, 38px); font-weight: 400; margin-bottom: 20px; }
.lab-hd .lab-d { font-family: var(--font); font-size: 16px; font-weight: 400; font-style: italic; color: rgba(255,255,255,0.55); max-width: 520px; margin: 0 auto; line-height: 1.7; }
.lab-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 280px), 1fr)); gap: 1px; background: rgba(255,255,255,0.07); max-width: 1100px; margin: 0 auto; }
.lab-c { background: var(--black); padding: clamp(32px, 3.5vw, 48px) clamp(24px, 3vw, 40px); cursor: pointer; transition: all 0.4s ease; }
.lab-c:hover { background: rgba(193,16,32,0.04); }
.lab-c .lt { font-family: var(--font); font-size: 9px; font-weight: 600; letter-spacing: 0.22em; text-transform: uppercase; color: var(--redwood); margin-bottom: 20px; }
.lab-c h4 { font-family: var(--font); font-size: 20px; font-weight: 500; margin-bottom: 14px; line-height: 1.4; }
.lab-c p { font-family: var(--font); font-size: 14px; font-weight: 400; color: rgba(255,255,255,0.55); line-height: 1.8; }
.lab-c .fmts { margin-top: 28px; display: flex; gap: 10px; flex-wrap: wrap; }
.fmt { font-family: var(--font); font-size: 9px; font-weight: 600; letter-spacing: 0.12em; text-transform: uppercase; padding: 5px 14px; border: 1px solid rgba(255,255,255,0.15); color: rgba(255,255,255,0.5); }

/* ── FIND US ── */
.find-sec { padding: clamp(100px, 14vw, 200px) clamp(20px, 4vw, 56px); text-align: center; }
.find-sec h2 { font-family: var(--font); font-size: clamp(36px, 7vw, 64px); font-weight: 400; margin-bottom: 28px; }
.find-sec .fd { color: var(--redwood); }
.find-sec .f-sub { font-family: var(--font); font-size: clamp(15px, 2vw, 18px); font-weight: 400; font-style: italic; color: var(--gray-mid); margin-bottom: 56px; }
.f-cta { display: inline-block; font-family: var(--font); font-size: 12px; font-weight: 600; letter-spacing: 0.2em; text-transform: uppercase; color: var(--black); text-decoration: none; padding: 20px clamp(36px, 5vw, 60px); border: 1px solid var(--black); transition: all 0.4s ease; }
.f-cta:hover { background: var(--redwood); border-color: var(--redwood); color: var(--white); }

/* ── HOMEPAGE RESPONSIVE — TABLET (768px) ── */
@media (max-width: 768px) {
  /* Hero */
  .hero { padding: 72px clamp(16px, 4vw, 40px) 48px; }
  .hero-geo { width: min(88vw, 560px); height: min(45vh, 380px); }

  /* Manifesto */
  .manifesto p { font-size: clamp(20px, 5vw, 28px); }
  .manifesto .m-attr { margin-top: 40px; }

  /* Foundational Storylabs */
  .fs-grid { grid-template-columns: 1fr; }
  .fs-card { min-height: auto; padding: 32px 24px; }

  /* Scale row → single column */
  .scale-row { grid-template-columns: 1fr; gap: 32px; margin-top: 48px; padding-top: 40px; }
  .scale-item p { max-width: 480px; }

  /* Client names */
  .cl-scroll { margin-top: 56px; padding-top: 36px; }
  .cl-names { font-size: 14px; line-height: 2.2; }
  .cl-names .sep { margin: 0 8px; }

  /* Capabilities */
  .cap-pill { padding: 10px 20px; font-size: 13px; }
  .cap-list { gap: 10px; }

  /* Courses */
  .crs-grid { gap: 24px; }
  .crs-card { padding: 28px 24px; }

  /* Lab */
  .lab-grid { grid-template-columns: 1fr; }
  .lab-c { padding: 32px 24px; }

  /* Find Us */
  .find-sec { padding: clamp(72px, 10vw, 140px) 20px; }
  .f-cta { padding: 18px 32px; }
}

/* ── HOMEPAGE RESPONSIVE — MOBILE (480px) ── */
@media (max-width: 480px) {
  /* Hero */
  .hero { min-height: 400px; padding: 60px 16px 40px; }
  .hero-geo { width: 92vw; height: min(40vh, 300px); min-height: 200px; }

  /* Manifesto */
  .manifesto .m-attr { margin-top: 32px; }

  /* Foundational Storylabs */
  .fs-sec { padding: 64px 16px 80px; }
  .fs-sec > h2 { font-size: clamp(20px, 5.5vw, 28px); margin-bottom: 40px; }
  .fs-card { padding: 28px 20px; }
  .fs-card h3 { font-size: 20px; }
  .c-geo { width: 60px; height: 60px; margin-bottom: 24px; }
  .c-bot { margin-top: 28px; }

  /* We Think Differently */
  .wr-in h2 { font-size: clamp(20px, 5.5vw, 28px); margin-bottom: 36px; }
  .wr-in p { font-size: 15px; }
  .scale-row { margin-top: 36px; padding-top: 32px; gap: 28px; }
  .scale-item h4 { font-size: 18px; }

  /* Client names */
  .cl-scroll { margin-top: 40px; padding-top: 28px; }

  /* Capabilities */
  .cap-sec { padding: 48px 16px; }
  .cap-pill { padding: 8px 16px; font-size: 12px; }
  .cap-list { gap: 8px; }

  /* Courses */
  .crs-sec h2 { font-size: clamp(20px, 5.5vw, 28px); }
  .crs-sub { font-size: 14px; margin-bottom: 36px; }
  .crs-card { padding: 24px 20px; }
  .crs-card h4 { font-size: 19px; }

  /* Lab */
  .lab-sec { padding: 64px 16px 80px; }
  .lab-hd h2 { font-size: clamp(24px, 6vw, 32px); }
  .lab-hd .lab-d { font-size: 14px; }
  .lab-c { padding: 28px 20px; }
  .lab-c h4 { font-size: 18px; }

  /* Find Us */
  .find-sec { padding: 64px 16px; }
  .find-sec .f-sub { font-size: 14px; margin-bottom: 36px; }
  .f-cta { padding: 16px 28px; font-size: 11px; letter-spacing: 0.15em; width: 100%; text-align: center; }
}

/* ── HOMEPAGE RESPONSIVE — SMALL MOBILE (360px) ── */
@media (max-width: 360px) {
  .hero-geo { height: min(36vh, 260px); min-height: 180px; }
  .wm-wrap h1 { font-size: 32px; }
  .hero-tag { font-size: 14px; }

  .manifesto p { font-size: 18px; }

  .fs-sec { padding: 56px 14px 64px; }
  .fs-card { padding: 24px 16px; }
  .fs-card h3 { font-size: 18px; }
  .fs-card .c-sub { font-size: 13px; }
  .c-tag { font-size: 8px; padding: 4px 10px; }

  .cap-pill { padding: 7px 12px; font-size: 11px; }

  .crs-card { padding: 20px 16px; }
  .lab-c { padding: 24px 16px; }

  .find-sec h2 { font-size: 32px; }
  .f-cta { padding: 14px 24px; }
}

/* ── HOMEPAGE RESPONSIVE — TINY MOBILE (320px) ── */
@media (max-width: 320px) {
  /* Hero — prevent canvas from dominating tiny screens */
  .hero { min-height: 380px; padding: 56px 12px 36px; }
  .hero-geo { height: min(32vh, 220px); min-height: 160px; }
  .wm-wrap h1 { font-size: 28px; }
  .hero-tag { font-size: 13px; padding: 0 8px; }
  .scroll-cue span { font-size: 8px; }

  /* Manifesto */
  .manifesto p { font-size: 17px; }
  .manifesto .m-attr { font-size: 9px; letter-spacing: 0.18em; }

  /* Foundational Storylabs */
  .fs-sec { padding: 48px 12px 56px; }
  .fs-sec > h2 { font-size: 19px; margin-bottom: 32px; }
  .fs-card { padding: 22px 14px; }
  .fs-card h3 { font-size: 17px; }
  .fs-card .c-sub { font-size: 12px; }
  .c-geo { width: 48px; height: 48px; margin-bottom: 20px; }
  .c-tag { font-size: 7px; padding: 3px 8px; letter-spacing: 0.1em; }

  /* We Think Differently */
  .wr-in h2 { font-size: 19px; margin-bottom: 28px; }
  .wr-in p { font-size: 14px; }
  .scale-item h4 { font-size: 17px; }
  .scale-item p { font-size: 13px; }
  .scale-item .sc-lbl { font-size: 9px; }

  /* Client names — tighten separators */
  .cl-names { font-size: 13px; line-height: 2; }
  .cl-names .sep { margin: 0 5px; }

  /* Capabilities */
  .cap-sec { padding: 40px 12px; }
  .cap-pill { padding: 6px 10px; font-size: 10px; }
  .cap-list { gap: 6px; }

  /* Courses */
  .crs-sec h2 { font-size: 19px; }
  .crs-sub { font-size: 13px; margin-bottom: 28px; }
  .crs-card { padding: 18px 14px; }
  .crs-card h4 { font-size: 17px; }
  .crs-card p { font-size: 13px; }

  /* Lab */
  .lab-sec { padding: 48px 12px 56px; }
  .lab-hd h2 { font-size: 22px; }
  .lab-hd .lab-d { font-size: 13px; }
  .lab-c { padding: 22px 14px; }
  .lab-c h4 { font-size: 17px; }
  .lab-c p { font-size: 13px; }

  /* Find Us */
  .find-sec { padding: 48px 12px; }
  .find-sec h2 { font-size: 28px; }
  .find-sec .f-sub { font-size: 13px; margin-bottom: 28px; }
  .f-cta { padding: 14px 20px; font-size: 10px; width: 100%; text-align: center; }
}

/* ── SAFE AREA — BOTTOM (find-us + footer on notched phones) ── */
@supports (padding-bottom: env(safe-area-inset-bottom)) {
  .find-sec { padding-bottom: max(clamp(100px, 14vw, 200px), env(safe-area-inset-bottom)); }
}
