/* JLP Media portfolio. Off-white page, dark ink, sage accent (no orange).
   Video banners keep the dark palette so overlay text reads over footage. */
:root {
  --bg: #f3f2ee;
  --deep: #e8e6df;            /* cards, footer */
  --well: #0a120f;            /* video wells */
  --ink: #0a120f;
  --ink-82: rgba(10, 18, 15, 0.82);
  --ink-75: rgba(10, 18, 15, 0.75);
  --muted: rgba(10, 18, 15, 0.66);
  --faint: rgba(10, 18, 15, 0.52);
  --hair: rgba(10, 18, 15, 0.1);
  --hair-strong: rgba(10, 18, 15, 0.22);
  --sage: #55703f;            /* sage for text: 4.5:1+ on bg and deep */
  --sage-fill: #9fb58a;       /* sage for fills: badge, dots, rules */
  --sage-line: rgba(85, 112, 63, 0.4);
  --sage-glow: rgba(159, 181, 138, 0.35);
  --error: #b42318;
  --serif: 'Instrument Serif', serif;
  --sans: 'Instrument Sans', sans-serif;
  --gutter: clamp(20px, 5vw, 56px);
  --section-pad: clamp(48px, 7vw, 88px);
}

/* Dark context for text laid over video. */
.loop-full, .loop-banner {
  --ink: #f3f2ee;
  --ink-82: rgba(243, 242, 238, 0.82);
  --ink-75: rgba(243, 242, 238, 0.75);
  --hair-strong: rgba(243, 242, 238, 0.22);
  --sage: #9fb58a;
  --sage-line: rgba(159, 181, 138, 0.35);
  color: var(--ink);
}

html { color-scheme: light; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--sans);
  letter-spacing: 0.012em;
  -webkit-font-smoothing: antialiased;
  overflow-x: clip;
}
a { color: var(--sage); text-decoration: none; }
a:hover { color: var(--ink); }
::selection { background: var(--ink); color: var(--bg); }
:focus-visible { outline: 2px solid var(--sage); outline-offset: 3px; }
h1, h2, h3, p, figure { margin: 0; }

@keyframes jlpPulse { 0%, 100% { opacity: 1; transform: scale(1); } 50% { opacity: .35; transform: scale(.7); } }

.page { min-height: 100vh; display: flex; flex-direction: column; }
.wrap { max-width: 1200px; margin: 0 auto; padding: 0 var(--gutter); }

/* ---------- Header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 90; overflow-anchor: none;
  background: rgba(243, 242, 238, 0.86);
  backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--hair);
}
.site-header .wrap {
  display: flex; flex-wrap: wrap; align-items: center;
  gap: 12px clamp(16px, 3vw, 28px);
  padding-top: 14px; padding-bottom: 14px;
}
.badge {
  display: flex; flex-direction: column; align-items: center; gap: 3px;
  padding: 8px 11px 6px; border-radius: 10px; background: var(--sage-fill); flex: none;
}
.badge-jlp { font-family: var(--serif); font-size: 19px; line-height: 1; letter-spacing: 0.01em; color: #0a120f; }
.badge-media { font-size: 6px; font-weight: 500; letter-spacing: 0.3em; text-transform: uppercase; color: #0a120f; }
.header-title { margin-right: auto; min-width: 0; font-size: 11px; font-weight: 500; letter-spacing: 0.24em; text-transform: uppercase; color: var(--faint); }
.header-contact { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 16px; font-size: 13px; font-weight: 500; flex: 0 1 auto; }
.header-contact a { color: var(--ink); }
.header-contact a.tel { color: var(--muted); }
.header-contact a:hover { color: var(--sage); }
.resume-link {
  order: 1; display: inline-flex; align-items: center; gap: 6px; flex: none;
  font-size: 12.5px; font-weight: 500; letter-spacing: 0.02em;
  padding: 7px 14px; border-radius: 999px; background: var(--ink); color: var(--bg);
}
.resume-link:hover { background: var(--sage); color: var(--bg); }

main { flex: 1; isolation: isolate; position: relative; z-index: 0; }

/* ---------- Password gate ---------- */
.gate { min-height: 64vh; display: flex; align-items: center; }
.gate-inner {
  display: flex; flex-direction: column; align-items: flex-start; gap: 20px;
  max-width: 440px; width: 100%; padding: clamp(48px, 10vw, 96px) 0;
}
.gate h1 { font-family: var(--serif); font-size: clamp(28px, 5vw, 40px); font-weight: 400; letter-spacing: 0.012em; line-height: 1.08; }
.gate-note { font-size: 15px; line-height: 1.6; color: var(--muted); text-wrap: pretty; }
.gate-field {
  display: flex; gap: 8px; width: 100%; padding: 5px; border-radius: 999px;
  background: rgba(255, 255, 255, 0.6); box-shadow: inset 0 0 0 1px rgba(10, 18, 15, 0.16);
}
.gate-field input {
  flex: 1; min-width: 0; font-family: var(--sans); font-size: 15px; padding: 10px 16px;
  border: none; background: transparent; color: var(--ink); outline: none;
}
.gate-field input::placeholder { color: var(--faint); }
.gate-field button {
  font-family: var(--sans); font-size: 13px; font-weight: 500; padding: 10px 22px;
  border-radius: 999px; border: none; background: var(--ink); color: var(--bg); cursor: pointer;
}
.gate-field button:hover { background: var(--sage); }
.gate-error { font-size: 13.5px; color: var(--error); }

/* ---------- Shared type ---------- */
.eyebrow {
  display: flex; align-items: center; gap: 12px;
  font-size: 11px; font-weight: 500; letter-spacing: 0.24em; text-transform: uppercase; color: var(--muted);
}
.eyebrow::before { content: ''; width: 22px; height: 2px; border-radius: 2px; background: var(--sage-fill); flex: none; }
.label { font-size: 11px; font-weight: 500; letter-spacing: 0.24em; text-transform: uppercase; color: var(--muted); margin-bottom: 18px; }

/* ---------- Hero ---------- */
.hero {
  padding: clamp(28px, 4.5vw, 52px) 0 var(--section-pad);
  display: flex; flex-wrap: wrap; gap: clamp(32px, 5vw, 72px); align-items: flex-end;
}
.hero-text { flex: 1 1 420px; min-width: 0; display: flex; flex-direction: column; gap: 22px; }
.hero-name { display: flex; flex-direction: column; gap: 14px; }
.hero h1 { font-family: var(--serif); font-size: clamp(56px, 11vw, 120px); line-height: 0.9; letter-spacing: 0.005em; font-weight: 400; }
.hero-sub { font-family: var(--serif); font-size: clamp(24px, 3.2vw, 34px); line-height: 1; letter-spacing: 0.012em; color: var(--sage); }
.hero-bio { font-size: clamp(16px, 2vw, 19px); line-height: 1.7; max-width: 58ch; color: var(--muted); text-wrap: pretty; }
.portrait {
  flex: 0 1 260px; max-width: 260px; width: 100%; position: relative; aspect-ratio: 4 / 5;
  border-radius: 18px; overflow: hidden; background: var(--deep);
  box-shadow: 0 0 0 1px var(--hair), 0 30px 60px -30px rgba(10, 18, 15, 0.4);
}
.cover { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }

/* ---------- Sections ---------- */
.section { border-top: 1px solid var(--hair); padding: var(--section-pad) 0; }
.sec-head {
  display: flex; flex-wrap: wrap; gap: 20px clamp(24px, 5vw, 72px); align-items: flex-start;
  margin-bottom: clamp(28px, 4vw, 48px);
}
.sec-key { flex: 0 0 200px; padding-top: 10px; }
.sec-body { flex: 1 1 400px; min-width: 0; }
.sec-body h2 { font-family: var(--serif); font-size: clamp(28px, 4.4vw, 40px); line-height: 1.05; letter-spacing: 0.012em; font-weight: 400; margin-bottom: 18px; text-wrap: balance; }
.lead { font-size: 16px; line-height: 1.75; max-width: 62ch; color: var(--muted); text-wrap: pretty; }
.lead + .btns { margin-top: 26px; }
.lead + .socials { margin-top: 24px; }

.btns { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; }
.btn { display: inline-flex; align-items: center; gap: 10px; font-size: 13px; font-weight: 500; letter-spacing: 0.02em; border-radius: 999px; }
.btn-solid { padding: 12px 20px; background: var(--ink); color: var(--bg); }
.btn-solid:hover { background: var(--sage); color: var(--bg); }
.btn-ghost { padding: 11px 19px; border: 1px solid var(--hair-strong); color: var(--ink); }
.btn-ghost:hover { border-color: var(--sage); color: var(--sage); }
.fineprint { font-size: 13px; line-height: 1.5; color: var(--faint); margin-top: 14px; }

/* ---------- Background video loops ---------- */
.loop-full {
  position: relative; width: 100vw; margin-left: calc(50% - 50vw);
  height: 76vh; min-height: 560px; max-height: 820px; overflow: hidden;
  background: var(--well); margin-bottom: clamp(40px, 6vw, 72px);
}
.loop-full > iframe {
  position: absolute; top: 50%; left: 50%;
  width: max(100vw, 135vh, 1000px); height: max(56.25vw, 76vh, 562px);
  transform: translate(-50%, -50%); border: 0; pointer-events: none;
}
.loop-full-inner {
  position: relative; height: 100%; max-width: 1200px; margin: 0 auto;
  padding: clamp(24px, 4vw, 40px) var(--gutter); box-sizing: border-box;
  display: flex; flex-direction: column; justify-content: space-between; gap: 24px;
}
/* Compact banners stay 16:9 with no crop or zoom (client-approved). */
.loop-banner {
  position: relative; width: 100%; aspect-ratio: 16 / 9; container-type: size; overflow: hidden;
  border-radius: 16px; background: var(--well); box-shadow: 0 0 0 1px var(--hair);
  margin-bottom: clamp(32px, 4vw, 48px);
}
.loop-banner > iframe {
  position: absolute; top: 50%; left: 50%; width: 100cqw; height: 56.25cqw;
  transform: translate(-50%, -50%); border: 0; pointer-events: none;
}
.loop-banner-inner {
  position: relative; height: 100%; padding: clamp(16px, 2.4vw, 26px); box-sizing: border-box;
  display: flex; flex-direction: column; justify-content: space-between; gap: 16px;
}
.scrim { position: absolute; inset: 0; background: linear-gradient(180deg, rgba(10,18,15,0.7) 0%, rgba(10,18,15,0.15) 30%, rgba(10,18,15,0.5) 60%, rgba(10,18,15,0.96) 100%); }
.scrim--light { background: linear-gradient(180deg, rgba(10,18,15,0.55) 0%, rgba(10,18,15,0) 30%, rgba(10,18,15,0) 70%, rgba(10,18,15,0.45) 100%); }
.loop-top { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px; }
.loop-full .loop-top { gap: 12px; }
.loop-caption { font-size: 11px; font-weight: 600; letter-spacing: 0.22em; text-transform: uppercase; color: var(--ink-75); }

.now {
  display: inline-flex; align-items: center; gap: 8px;
  font-size: 10px; font-weight: 600; letter-spacing: 0.2em; text-transform: uppercase; color: var(--ink);
  padding: 6px 12px; border-radius: 999px; background: rgba(6, 12, 10, 0.6);
  backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px);
}
.now::before { content: ''; width: 6px; height: 6px; border-radius: 999px; background: var(--sage-fill); animation: jlpPulse 1.6s ease-in-out infinite; }
.now--lg { gap: 10px; font-size: 11px; letter-spacing: 0.22em; padding: 8px 14px; }
.now--lg::before { width: 7px; height: 7px; }

/* ---------- Stats ---------- */
.stats { display: grid; }
.stat { display: flex; flex-direction: column; border-top: 1px solid var(--hair-strong); }
.stat-num { display: flex; align-items: baseline; font-family: var(--serif); line-height: 0.9; color: var(--ink); font-variant-numeric: tabular-nums; }
.stat-num small { color: var(--sage); font-size: 0.6em; }
.stat-label { color: var(--ink-82); text-wrap: pretty; }

.stats--lg { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: clamp(20px, 3vw, 36px) clamp(20px, 3vw, 40px); }
.stats--lg .stat { gap: 8px; padding-top: 14px; }
.stats--lg .stat-num { gap: 4px; font-size: clamp(48px, 7vw, 92px); }
.stats--lg .stat-label { font-size: 13.5px; line-height: 1.45; max-width: 24ch; }

.stats--sm { gap: 16px clamp(16px, 2.4vw, 28px); }
.stats--sm .stat { gap: 6px; padding-top: 10px; }
.stats--sm .stat-num { gap: 3px; font-size: clamp(32px, 3.6vw, 48px); }
.stats--sm .stat-label { font-size: 12.5px; line-height: 1.4; max-width: 22ch; }
.stats--3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.stats--4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }

.ot-bottom { display: flex; flex-direction: column; gap: 16px; }
.networks { display: flex; flex-wrap: wrap; gap: 6px; margin: 0; padding: 0; list-style: none; }
.networks li {
  font-size: 10.5px; font-weight: 600; letter-spacing: 0.14em; text-transform: uppercase; color: var(--ink);
  padding: 5px 10px; border-radius: 999px; background: rgba(6, 12, 10, 0.55);
  box-shadow: inset 0 0 0 1px var(--sage-line);
}

/* ---------- Timeline ---------- */
.timeline {
  display: grid; grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 28px clamp(16px, 2vw, 28px); margin: 0 0 clamp(48px, 7vw, 80px); padding: 0; list-style: none;
}
.tl { display: flex; flex-direction: column; gap: 10px; }
.tl-mark { display: flex; align-items: center; gap: 10px; }
.tl-mark::before { content: ''; width: 11px; height: 11px; border-radius: 999px; background: var(--sage-fill); box-shadow: 0 0 0 4px var(--sage-glow); flex: none; }
.tl:last-child .tl-mark::before { background: var(--sage); }
.tl-mark::after { content: ''; flex: 1; height: 1px; background: rgba(10, 18, 15, 0.16); }
.tl-year { font-family: var(--serif); font-size: 30px; line-height: 1; color: var(--sage); }
.tl-role { font-size: 11px; font-weight: 600; letter-spacing: 0.18em; text-transform: uppercase; color: var(--sage); }
.tl-note { font-size: 14px; line-height: 1.6; color: var(--muted); text-wrap: pretty; }

/* ---------- Grids & media ---------- */
.grid { display: grid; gap: clamp(16px, 2vw, 24px); }
.cols-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.cols-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }

.video { display: flex; flex-direction: column; gap: 12px; }
.frame {
  position: relative; aspect-ratio: 16 / 9; border-radius: 12px; overflow: hidden; background: var(--well);
  box-shadow: 0 0 0 1px var(--hair), 0 18px 40px -24px rgba(10, 18, 15, 0.35);
}
.frame iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.frame .contain { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; }
.video figcaption { display: flex; flex-direction: column; gap: 3px; }
.video figcaption.plain { display: block; }
.video-title { font-size: 14.5px; font-weight: 500; letter-spacing: -0.015em; line-height: 1.3; }
.video-meta { font-size: 12.5px; color: var(--faint); }

.watch { position: absolute; inset: 0; display: flex; align-items: flex-end; justify-content: flex-end; padding: 0 10px 2px 0; }
.watch span { display: inline-flex; align-items: center; gap: 4px; font-size: 10px; font-weight: 500; padding: 4px 9px; border-radius: 999px; background: rgba(6, 12, 10, 0.85); color: var(--sage-fill); }

.title-card { display: flex; flex-direction: column; gap: 14px; }
.title-text { display: flex; flex-direction: column; gap: 6px; }
.title-kind { font-size: 10.5px; font-weight: 500; letter-spacing: 0.2em; text-transform: uppercase; color: var(--sage); }
.title-text h3 { font-family: var(--serif); font-size: 17px; font-weight: 400; letter-spacing: 0.012em; line-height: 1.2; text-wrap: balance; max-width: 16ch; }
.title-note { font-size: 14px; line-height: 1.6; margin-top: 2px; color: var(--muted); text-wrap: pretty; }
.title-role { font-size: 12.5px; line-height: 1.5; margin-top: 4px; padding-top: 10px; border-top: 1px solid var(--hair); color: var(--faint); }

/* ---------- Socials ---------- */
.socials { display: flex; flex-wrap: wrap; gap: 8px; }
.social {
  display: inline-flex; align-items: baseline; gap: 7px; padding: 8px 14px; border-radius: 999px;
  border: 1px solid rgba(10, 18, 15, 0.16); font-size: 12px; font-weight: 500; color: var(--ink); white-space: nowrap;
}
.social small { font-size: 11px; color: var(--faint); }
.social:hover { border-color: var(--sage); color: var(--sage); }

/* ---------- Clients ---------- */
.clients { gap: clamp(14px, 1.8vw, 20px); margin-bottom: clamp(32px, 4vw, 48px); }
.client {
  display: flex; flex-direction: column; gap: 14px; padding: clamp(20px, 2.4vw, 28px);
  border-radius: 16px; background: var(--deep); box-shadow: inset 0 0 0 1px var(--hair);
}
.client:hover { box-shadow: inset 0 0 0 1px rgba(85, 112, 63, 0.45); }
.client-top { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.client-kind { font-size: 10.5px; font-weight: 600; letter-spacing: 0.2em; text-transform: uppercase; color: var(--sage); }
.client-num { font-family: var(--serif); font-size: 22px; line-height: 1; color: rgba(10, 18, 15, 0.3); }
.client-name { display: flex; flex-direction: column; gap: 4px; }
.client h3 { font-family: var(--serif); font-size: clamp(24px, 2.6vw, 30px); font-weight: 400; line-height: 1.05; color: var(--ink); }
.client-sector { font-size: 13px; color: var(--faint); }
.client-note { font-size: 14px; line-height: 1.6; color: var(--muted); text-wrap: pretty; }
.tags { display: flex; flex-wrap: wrap; gap: 5px; margin: auto 0 0; padding: 6px 0 0; list-style: none; }
.tags li { font-size: 10.5px; font-weight: 500; padding: 4px 8px; white-space: nowrap; border-radius: 999px; color: var(--ink); box-shadow: inset 0 0 0 1px var(--sage-line); }

/* ---------- Marketing photos ---------- */
.mkt { display: grid; grid-template-columns: 1fr 1.45fr 1fr; gap: clamp(12px, 1.6vw, 18px); max-width: 820px; align-items: stretch; }
.mkt-tile { position: relative; aspect-ratio: 4 / 5; border-radius: 12px; overflow: hidden; background: var(--deep); box-shadow: 0 0 0 1px var(--hair); }
.mkt-tile--wide { aspect-ratio: auto; min-height: 220px; }
.mkt-tile--crop .cover { object-position: 62% 26%; transform: scale(1.12); transform-origin: 62% 26%; }

/* ---------- Footer ---------- */
.site-footer { border-top: 1px solid var(--hair); background: var(--deep); }
.site-footer .wrap {
  padding-top: var(--section-pad); padding-bottom: clamp(40px, 5vw, 56px);
  display: flex; flex-wrap: wrap; gap: 36px 60px; align-items: flex-end;
}
.site-footer h2 { font-family: var(--serif); font-size: clamp(34px, 6vw, 64px); font-weight: 400; letter-spacing: 0.012em; line-height: 1; margin: 0 auto 0 0; max-width: 14ch; text-wrap: balance; }
.footer-contact { display: flex; flex-direction: column; gap: 8px; font-size: 15px; }
.footer-contact a { font-weight: 500; color: var(--ink); }
.footer-contact a.tel { font-weight: 400; color: var(--muted); }
.footer-contact a:hover { color: var(--sage); }
.copyright { color: var(--faint); font-size: 12px; letter-spacing: 0.04em; margin-top: 14px; }

/* ---------- Gate visibility ---------- */
.is-unlocked .gate { display: none; }

/* ---------- Responsive (breakpoints match the design's renderVals) ---------- */
@media (max-width: 959px) {
  .cols-4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .stats--lg { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .timeline { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 759px) {
  .cols-3 { grid-template-columns: minmax(0, 1fr); }
  .stats--3, .stats--4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .sec-key { flex: 1 1 100%; padding-top: 0; }
}
@media (max-width: 559px) {
  .cols-4, .timeline, .mkt { grid-template-columns: minmax(0, 1fr); }
  .portrait { max-width: 200px; }
  .header-contact { font-size: 12.5px; flex: 1 1 100%; order: 2; }
}
