/* ============================================================
   Edge — shared site styles for inner pages
   Pairs with colors_and_type.css. Mirrors the homepage system.
   ============================================================ */

:root {
  --nav-h: 76px;
  --img-overlay: linear-gradient(180deg, rgba(7,32,47,0.35) 0%, rgba(7,32,47,0.15) 35%, rgba(7,32,47,0.78) 100%); /* @kind other */
  --img-overlay-soft: linear-gradient(180deg, rgba(7,32,47,0.45) 0%, rgba(7,32,47,0.30) 50%, rgba(7,32,47,0.72) 100%); /* @kind other */
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0; padding: 0;
  font-family: 'Poppins', system-ui, sans-serif;
  font-weight: 300;
  color: var(--edge-ink);
  background: var(--edge-paper);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
::selection { background: var(--edge-clay); color: #fff; }
img { display: block; max-width: 100%; }
a { text-decoration: none; color: inherit; }

.wrap { width: 100%; max-width: 1280px; margin: 0 auto; padding: 0 var(--gutter); }

h1, h2, h3 { margin: 0; font-weight: 700; letter-spacing: -0.035em; line-height: 0.98; text-wrap: balance; }
.eyebrow {
  font-size: 12px; font-weight: 500; letter-spacing: 0.18em;
  text-transform: uppercase; color: var(--edge-clay); margin: 0;
}
.eyebrow.on-dark { color: var(--edge-mint); }
mark { background: transparent; color: var(--edge-clay); font-weight: inherit; }

/* ---------- Buttons ---------- */
.btn {
  --by: 0px;
  display: inline-flex; align-items: center; gap: 10px;
  font-family: 'Poppins', sans-serif; font-weight: 500; font-size: 14px; letter-spacing: 0.01em;
  height: 52px; padding: 0 28px; border: 0; border-radius: 999px; cursor: pointer;
  transition: background .24s var(--ease-out), color .24s var(--ease-out), transform .08s var(--ease-out), box-shadow .24s var(--ease-out);
  transform: translateY(var(--by));
}
.btn .arw { transition: transform .24s var(--ease-out); }
.btn:hover .arw { transform: translateX(4px); }
.btn .arw.back { transition: transform .24s var(--ease-out); }
.btn:hover .arw.back { transform: translateX(-4px); }
.btn:active { transform: scale(0.98); }
.btn-primary { background: var(--edge-clay); color: #fff; }
.btn-primary:hover { background: var(--edge-clay-700); box-shadow: var(--shadow-accent); }
.btn-ghost-light { background: transparent; color: #fff; border: 1px solid rgba(255,255,255,0.55); }
.btn-ghost-light:hover { background: #fff; color: var(--edge-deep); border-color: #fff; }
.btn-ghost-ink { background: transparent; color: var(--edge-ink); border: 1px solid var(--edge-ink); }
.btn-ghost-ink:hover { background: var(--edge-ink); color: #fff; }
.btn-sm { height: 42px; padding: 0 20px; font-size: 13px; }

/* ---------- Nav ---------- */
nav.top {
  position: fixed; top: 0; left: 0; right: 0; z-index: 100;
  height: var(--nav-h);
  display: flex; align-items: center;
  transition: background .3s var(--ease-out), border-color .3s var(--ease-out), backdrop-filter .3s var(--ease-out);
  background: transparent; border-bottom: 1px solid transparent;
}
nav.top .wrap { display: flex; align-items: center; justify-content: space-between; }
nav.top .logo { height: 22px; width: auto; transition: opacity .2s; }
nav.top .links { display: flex; gap: 34px; align-items: center; }
nav.top .links a {
  font-size: 13px; font-weight: 500; letter-spacing: 0.01em; color: #fff;
  opacity: 0.8; transition: opacity .18s; padding: 6px 0; position: relative;
}
nav.top .links a:hover { opacity: 1; }
nav.top .links a::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: -2px; height: 2px;
  background: var(--edge-clay); transform: scaleX(0); transform-origin: left; transition: transform .24s var(--ease-out);
}
nav.top .links a:hover::after, nav.top .links a.active::after { transform: scaleX(1); }
nav.top.scrolled {
  background: rgba(255,255,255,0.86); backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--edge-gray-100);
}
nav.top.scrolled .logo-white { display: none; }
nav.top.scrolled .logo-dark { display: block; }
nav.top .logo-dark { display: none; }
nav.top.scrolled .links a { color: var(--edge-ink); }
.nav-right { display: flex; align-items: center; gap: 22px; }
/* Solid nav variant for light-top pages */
nav.top.solid {
  background: rgba(255,255,255,0.92); backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--edge-gray-100);
}
nav.top.solid .logo-white { display: none; }
nav.top.solid .logo-dark { display: block; }
nav.top.solid .links a { color: var(--edge-ink); }

/* ---------- Reveal ---------- */
.reveal { opacity: 0; transform: translateY(26px); transition: opacity .7s var(--ease-out), transform .7s var(--ease-out); }
.reveal.in { opacity: 1; transform: none; }
.reveal.d1 { transition-delay: .08s; }
.reveal.d2 { transition-delay: .16s; }
.reveal.d3 { transition-delay: .24s; }
.reveal.d4 { transition-delay: .32s; }
@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; transition: none; }
  html { scroll-behavior: auto; }
}

/* ---------- Sub-hero (inner page full-bleed) ---------- */
.subhero {
  position: relative; min-height: 78vh; display: flex; align-items: flex-end;
  background-color: var(--edge-deep);
  background-image: var(--img-overlay-soft), var(--subhero-img);
  background-size: cover; background-position: center; color: #fff; overflow: hidden;
}
.subhero .wrap { padding-bottom: 7vh; padding-top: calc(var(--nav-h) + 40px); width: 100%; }
.subhero-inner { max-width: 920px; }
.breadcrumb {
  display: inline-flex; align-items: center; gap: 10px; margin-bottom: 26px;
  font-size: 12px; font-weight: 500; letter-spacing: 0.04em; color: rgba(255,255,255,0.72);
}
.breadcrumb a { color: rgba(255,255,255,0.72); transition: color .18s; }
.breadcrumb a:hover { color: #fff; }
.breadcrumb .sep { opacity: 0.5; }
.subhero .num { font-family: var(--font-mono); font-size: 13px; letter-spacing: 0.1em; color: var(--edge-mint); }
.subhero h1 {
  font-size: clamp(2.8rem, 6.6vw, 6rem); color: #fff; margin: 18px 0 0; line-height: 0.95;
}
.subhero p.sub {
  font-size: clamp(1rem, 1.5vw, 1.28rem); font-weight: 300; line-height: 1.5;
  color: rgba(255,255,255,0.84); max-width: 560px; margin: 28px 0 0;
}
.subhero .meta-row { display: flex; gap: 14px; flex-wrap: wrap; margin-top: 34px; }
.subhero .badge {
  font-size: 12px; font-weight: 500; letter-spacing: 0.02em; color: #fff;
  padding: 8px 16px; border-radius: 999px; background: rgba(255,255,255,0.12);
  border: 1px solid rgba(255,255,255,0.32); backdrop-filter: blur(6px);
}
.subhero .credit { position: absolute; top: calc(var(--nav-h) + 16px); right: var(--gutter); font-family: var(--font-mono); font-size: 10.5px; letter-spacing: 0.08em; color: rgba(255,255,255,0.55); }

/* ---------- Overview (editorial two-col) ---------- */
.overview { padding: clamp(90px, 13vh, 170px) 0; background: var(--edge-paper); }
.overview .grid { display: grid; grid-template-columns: 1fr 2.3fr; gap: 64px; align-items: start; }
.overview .side { font-size: 14px; font-weight: 300; line-height: 1.7; color: var(--edge-gray-700); }
.overview h2 { font-size: clamp(2rem, 4vw, 3.4rem); color: var(--edge-ink); line-height: 1.02; }
.overview .lede { margin-top: 28px; font-size: clamp(1.05rem, 1.6vw, 1.32rem); font-weight: 300; line-height: 1.5; color: var(--edge-deep-700); max-width: 720px; }
.overview .lede + .lede { margin-top: 20px; font-size: 1rem; color: var(--edge-gray-700); line-height: 1.7; }

/* ---------- Process steps ---------- */
.process { background: var(--edge-deep); color: var(--edge-mint); padding: clamp(96px, 13vh, 160px) 0; }
.process .head { display: grid; grid-template-columns: 1fr 2fr; gap: 56px; align-items: start; margin-bottom: 64px; }
.process h2 { font-size: clamp(1.9rem, 3.6vw, 3.2rem); color: #fff; }
.process .step {
  display: grid; grid-template-columns: 70px 1fr; gap: 32px; align-items: start;
  padding: 34px 0; border-top: 1px solid rgba(255,255,255,0.12);
}
.process .steps .step:last-child { border-bottom: 1px solid rgba(255,255,255,0.12); }
.process .step .idx { font-family: var(--font-mono); font-size: 13px; color: var(--edge-mint-400); letter-spacing: 0.04em; padding-top: 6px; }
.process .step .st-title { font-size: clamp(1.3rem, 2.4vw, 1.9rem); font-weight: 700; letter-spacing: -0.02em; color: #fff; }
.process .step .st-body { font-size: 14px; font-weight: 300; line-height: 1.65; color: var(--edge-deep-300); max-width: 560px; margin-top: 10px; }

/* ---------- Deliverables grid ---------- */
.deliver { padding: clamp(90px, 12vh, 150px) 0; background: var(--edge-paper-warm); }
.deliver .head { max-width: 720px; margin-bottom: 60px; }
.deliver h2 { font-size: clamp(2rem, 4vw, 3.2rem); color: var(--edge-ink); margin-top: 16px; }
.deliver .grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1px; background: var(--edge-gray-200); border: 1px solid var(--edge-gray-200); border-radius: 18px; overflow: hidden; }
.deliver .card { background: var(--edge-paper); padding: 38px 32px; transition: background .24s var(--ease-out); }
.deliver .card:hover { background: var(--edge-mint-50); }
.deliver .card .dnum { font-family: var(--font-mono); font-size: 12px; color: var(--edge-clay); letter-spacing: 0.06em; }
.deliver .card h3 { font-size: 1.25rem; color: var(--edge-ink); margin: 16px 0 12px; line-height: 1.1; letter-spacing: -0.01em; }
.deliver .card p { font-size: 13.5px; font-weight: 300; line-height: 1.6; color: var(--edge-gray-700); }

/* ---------- Stats strip ---------- */
.stats { background: var(--edge-deep-900); color: var(--edge-mint); padding: clamp(80px,11vh,130px) 0; }
.stats .grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 28px; }
.stat { padding-left: 26px; border-left: 1px solid rgba(255,255,255,0.14); }
.stat:first-child { border-left: 0; padding-left: 0; }
.stat .num { font-size: clamp(2.6rem, 4.6vw, 4.4rem); font-weight: 700; letter-spacing: -0.04em; line-height: 1; color: #fff; }
.stat .num mark { color: var(--edge-clay); }
.stat .lab { font-size: 13px; font-weight: 300; line-height: 1.5; color: var(--edge-mint-400); margin-top: 14px; max-width: 190px; }

/* ---------- Quote ---------- */
.quote { background: var(--edge-paper); padding: clamp(96px,14vh,180px) 0; }
.quote .inner { max-width: 980px; margin: 0 auto; text-align: center; }
.quote .qmark { font-size: 120px; line-height: 0.5; color: var(--edge-clay); font-weight: 700; }
.quote p { font-size: clamp(1.5rem, 3.2vw, 2.7rem); font-weight: 300; line-height: 1.22; letter-spacing: -0.02em; color: var(--edge-ink); margin: 18px 0 0; text-wrap: balance; }
.quote p mark { font-weight: 500; }
.quote .by { margin-top: 40px; font-size: 13px; font-weight: 500; letter-spacing: 0.04em; color: var(--edge-gray-500); }

/* ---------- Next / pager ---------- */
.pager {
  position: relative; min-height: 56vh; display: flex; align-items: center;
  background-color: var(--edge-deep-900);
  background-image: var(--img-overlay), var(--pager-img);
  background-size: cover; background-position: center; color: #fff; overflow: hidden;
}
.pager .wrap { width: 100%; }
.pager .lab { font-size: 11px; font-weight: 500; letter-spacing: 0.16em; text-transform: uppercase; color: rgba(255,255,255,0.66); }
.pager h2 { font-size: clamp(2.2rem, 5vw, 4.2rem); color: #fff; margin: 14px 0 24px; line-height: 0.98; }

/* ---------- CTA ---------- */
.cta { background: var(--edge-clay); color: #fff; padding: clamp(90px,12vh,150px) 0; }
.cta .grid { display: grid; grid-template-columns: 1.55fr 1fr; gap: 56px; align-items: end; }
.cta h2 { font-size: clamp(2.4rem, 5vw, 4.6rem); color: #fff; line-height: 0.98; }
.cta p { font-size: 16px; font-weight: 300; line-height: 1.6; color: rgba(255,255,255,0.9); margin: 0 0 26px; }

/* ---------- Footer ---------- */
footer { background: #061924; color: var(--edge-mint); padding: 88px 0 30px; }
footer .cols { display: grid; grid-template-columns: 1.6fr 1fr 1fr 1fr 1fr; gap: 44px; margin-bottom: 60px; }
footer .logo { height: 28px; margin-bottom: 22px; }
footer .about { font-size: 14px; font-weight: 300; line-height: 1.6; color: var(--edge-mint-400); max-width: 270px; }
footer .colhead { font-size: 11px; font-weight: 500; letter-spacing: 0.16em; text-transform: uppercase; color: var(--edge-mint-400); margin-bottom: 16px; }
footer .colitem { font-size: 14px; font-weight: 300; color: var(--edge-mint); opacity: 0.82; margin-bottom: 10px; display: block; transition: opacity .15s; }
footer a.colitem:hover { opacity: 1; color: #fff; }
footer .base { border-top: 1px solid rgba(255,255,255,0.09); padding-top: 22px; display: flex; justify-content: space-between; font-size: 12px; font-weight: 300; color: var(--edge-mint-400); }

/* ---------- Sticky conversion bar ---------- */
.cta-bar {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 90;
  background: var(--edge-deep); color: #fff;
  transform: translateY(120%); transition: transform .42s var(--ease-out);
  border-top: 1px solid rgba(255,255,255,0.08);
}
.cta-bar.show { transform: translateY(0); }
.cta-bar .wrap { display: flex; align-items: center; justify-content: space-between; gap: 20px; padding-top: 14px; padding-bottom: 14px; }
.cta-bar .msg { font-size: 14px; font-weight: 300; color: rgba(255,255,255,0.92); }
.cta-bar .msg strong { font-weight: 600; color: #fff; }
.cta-bar .right { display: flex; align-items: center; gap: 8px; }
.cta-bar .close { background: transparent; border: 0; color: rgba(255,255,255,0.55); cursor: pointer; font-size: 20px; line-height: 1; padding: 8px; }
.cta-bar .close:hover { color: #fff; }

/* ---------- Work index ---------- */
.work-head { padding: clamp(96px,13vh,150px) 0 0; background: var(--edge-paper); }
.work-head .wrap { padding-top: calc(var(--nav-h) + 20px); }
.work-head h1 { font-size: clamp(2.6rem, 6vw, 5.2rem); color: var(--edge-ink); margin: 18px 0 0; line-height: 0.95; }
.work-head .sub { font-size: clamp(1.05rem,1.6vw,1.3rem); font-weight: 300; line-height: 1.5; color: var(--edge-gray-700); max-width: 600px; margin: 28px 0 0; }
.filters { display: flex; gap: 10px; flex-wrap: wrap; margin: 48px 0 0; padding-bottom: 6px; }
.filter {
  font-family: 'Poppins', sans-serif; font-size: 13px; font-weight: 500; letter-spacing: 0.01em;
  height: 40px; padding: 0 20px; border-radius: 999px; cursor: pointer;
  background: transparent; color: var(--edge-gray-700); border: 1px solid var(--edge-gray-200);
  transition: background .2s var(--ease-out), color .2s, border-color .2s;
}
.filter:hover { border-color: var(--edge-ink); color: var(--edge-ink); }
.filter.active { background: var(--edge-ink); color: #fff; border-color: var(--edge-ink); }

.work-grid-sec { padding: clamp(48px,7vh,80px) 0 clamp(90px,12vh,150px); background: var(--edge-paper); }
.work-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: clamp(24px,3vw,40px); }
.proj {
  position: relative; display: block; border-radius: 18px; overflow: hidden;
  aspect-ratio: 4 / 3; background: var(--edge-deep-900); color: #fff;
}
.proj .img {
  position: absolute; inset: 0; background-size: cover; background-position: center;
  transition: transform .9s var(--ease-out);
}
.proj:hover .img { transform: scale(1.05); }
.proj .scrim { position: absolute; inset: 0; background: linear-gradient(180deg, rgba(7,32,47,0.05) 0%, rgba(7,32,47,0.25) 45%, rgba(7,32,47,0.82) 100%); }
.proj .body { position: absolute; inset: 0; display: flex; flex-direction: column; justify-content: flex-end; padding: 34px; }
.proj .cat { font-family: var(--font-mono); font-size: 10.5px; letter-spacing: 0.1em; color: rgba(255,255,255,0.78); text-transform: uppercase; }
.proj h3 { font-size: clamp(1.6rem, 2.6vw, 2.3rem); color: #fff; margin: 10px 0 0; line-height: 0.98; }
.proj .row { display: flex; align-items: center; justify-content: space-between; gap: 16px; margin-top: 16px; }
.proj .metric { font-size: 13px; font-weight: 300; color: rgba(255,255,255,0.88); }
.proj .metric strong { font-weight: 600; color: var(--edge-mint); }
.proj .go {
  width: 44px; height: 44px; border-radius: 999px; border: 1px solid rgba(255,255,255,0.3);
  display: flex; align-items: center; justify-content: center; font-size: 17px; color: #fff; flex: 0 0 auto;
  transition: background .24s var(--ease-out), border-color .24s, transform .24s var(--ease-out);
}
.proj:hover .go { background: var(--edge-clay); border-color: var(--edge-clay); transform: translateX(3px); }
.proj.tall { aspect-ratio: 4 / 5; }
.proj.hide { display: none; }

/* ---------- Case study body ---------- */
.cs-brief { padding: clamp(90px,13vh,170px) 0; background: var(--edge-paper); }
.cs-brief .grid { display: grid; grid-template-columns: 0.85fr 1.6fr; gap: 64px; align-items: start; }
.cs-brief .facts { display: grid; gap: 26px; }
.cs-brief .fact span { display: block; font-size: 11px; font-weight: 500; letter-spacing: 0.14em; text-transform: uppercase; color: var(--edge-gray-500); margin-bottom: 6px; }
.cs-brief .fact { font-size: 15px; font-weight: 300; color: var(--edge-deep-700); line-height: 1.5; }
.cs-brief h2 { font-size: clamp(1.9rem, 3.6vw, 3rem); color: var(--edge-ink); line-height: 1.04; }
.cs-brief .lede { margin-top: 26px; font-size: clamp(1.05rem,1.6vw,1.3rem); font-weight: 300; line-height: 1.5; color: var(--edge-deep-700); }
.cs-brief .lede + p { margin-top: 20px; font-size: 1rem; line-height: 1.7; color: var(--edge-gray-700); font-weight: 300; }

.cs-figure { position: relative; height: clamp(60vh, 72vh, 80vh); background-size: cover; background-position: center; }
.cs-figure .cap { position: absolute; left: var(--gutter); bottom: 26px; font-family: var(--font-mono); font-size: 10.5px; letter-spacing: 0.08em; color: rgba(255,255,255,0.85); background: rgba(7,32,47,0.4); backdrop-filter: blur(6px); padding: 8px 14px; border-radius: 999px; }

.cs-cols { padding: clamp(90px,12vh,150px) 0; background: var(--edge-paper-warm); }
.cs-cols .grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: clamp(32px,5vw,72px); }
.cs-cols .blk h3 { font-size: clamp(1.5rem,2.6vw,2rem); color: var(--edge-ink); margin-bottom: 18px; line-height: 1.05; }
.cs-cols .blk p { font-size: 15px; font-weight: 300; line-height: 1.7; color: var(--edge-gray-700); }
.cs-cols .blk p + p { margin-top: 16px; }
.cs-cols .eyebrow { margin-bottom: 12px; }

.cs-applied { padding: clamp(80px,11vh,140px) 0; background: var(--edge-paper); }
.cs-applied .head { margin-bottom: 48px; }
.cs-applied h2 { font-size: clamp(1.8rem,3.4vw,2.8rem); color: var(--edge-ink); margin-top: 14px; }
.cs-applied .tags { display: flex; flex-wrap: wrap; gap: 12px; }
.cs-applied .tag {
  display: inline-flex; align-items: center; gap: 10px;
  font-size: 14px; font-weight: 400; color: var(--edge-ink);
  padding: 12px 22px; border-radius: 999px; border: 1px solid var(--edge-gray-200);
  transition: border-color .2s, background .2s, color .2s;
}
.cs-applied a.tag:hover { border-color: var(--edge-clay); color: var(--edge-clay); }
.cs-applied .tag .dot { width: 7px; height: 7px; border-radius: 999px; background: var(--edge-clay); }

@media (max-width: 880px) {
  .work-grid { grid-template-columns: 1fr; }
  .proj, .proj.tall { aspect-ratio: 4 / 3; }
  .cs-brief .grid, .cs-cols .grid { grid-template-columns: 1fr; gap: 36px; }
}

/* ---------- Responsive ---------- */
@media (max-width: 880px) {
  nav.top .links { display: none; }
  .overview .grid, .process .head, .cta .grid { grid-template-columns: 1fr; gap: 32px; }
  .deliver .grid { grid-template-columns: 1fr; }
  .stats .grid { grid-template-columns: repeat(2, 1fr); gap: 36px 28px; }
  .stat:nth-child(3) { border-left: 0; padding-left: 0; }
  footer .cols { grid-template-columns: 1fr 1fr; gap: 36px; }
  .process .step { grid-template-columns: 44px 1fr; gap: 18px; }
  .cta-bar .msg { font-size: 13px; }
}
