/* ==========================================================================
   Dr. Sam Lee — DrSamLeeOrtho.com
   Design system: black / white / off-white / charcoal, restrained ink-blue
   accent. Editorial, cinematic, generous whitespace.
   ========================================================================== */

:root{
  --black:#0a0a0a;
  --ink:#111111;
  --charcoal:#1c1c1c;
  --gray-800:#2b2b2b;
  --gray-600:#4a4a4a;
  --gray-500:#6b6b6b;
  --gray-400:#8f8c86;
  --gray-300:#b9b6b0;
  --gray-200:#e4e1da;
  --gray-100:#eeece6;
  --off-white:#f5f3ee;
  --white:#ffffff;
  --accent:#1c3a5e;      /* restrained ink-blue, used sparingly */
  --accent-soft:#3f5f86;

  --serif: "Fraunces", "Iowan Old Style", Georgia, serif;
  --sans: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;

  --container: 1240px;
  --gutter: clamp(1.25rem, 4vw, 3.5rem);

  --ease: cubic-bezier(.22,.61,.36,1);
}

*,*::before,*::after{ box-sizing:border-box; }
html{ scroll-behavior:smooth; }
@media (prefers-reduced-motion: reduce){
  html{ scroll-behavior:auto; }
  *,*::before,*::after{ animation-duration:.001ms !important; animation-iteration-count:1 !important; transition-duration:.001ms !important; scroll-behavior:auto !important; }
}

body{
  margin:0;
  background:var(--off-white);
  color:var(--ink);
  font-family:var(--sans);
  font-size:16px;
  line-height:1.6;
  -webkit-font-smoothing:antialiased;
  -moz-osx-font-smoothing:grayscale;
}

img{ max-width:100%; display:block; }
a{ color:inherit; text-decoration:none; }
h1,h2,h3,h4{ font-family:var(--serif); font-weight:500; line-height:1.08; margin:0; letter-spacing:-0.01em; }
p{ margin:0; }
ul{ margin:0; padding:0; list-style:none; }
button{ font-family:inherit; }

.container{ max-width:var(--container); margin:0 auto; padding:0 var(--gutter); }

.eyebrow{
  font-family:var(--sans);
  font-size:.72rem;
  letter-spacing:.22em;
  text-transform:uppercase;
  color:var(--gray-500);
  font-weight:600;
}
.eyebrow.on-dark{ color:var(--gray-300); }
.eyebrow.accent{ color:var(--accent-soft); }

.section{ padding:clamp(4.5rem,9vw,8.5rem) 0; }
.section--tight{ padding:clamp(3rem,6vw,5rem) 0; }
.section--dark{ background:var(--black); color:var(--white); }
.section--charcoal{ background:var(--charcoal); color:var(--white); }
.section--line-top{ border-top:1px solid var(--gray-200); }
.section--dark .eyebrow{ color:var(--gray-400); }

.kicker-rule{ display:flex; align-items:center; gap:.9rem; margin-bottom:1.4rem; }
.kicker-rule::before{ content:""; width:2.2rem; height:1px; background:var(--accent-soft); display:block; }

/* ---------- Buttons / links ---------- */
.btn{
  display:inline-flex; align-items:center; gap:.6rem;
  font-size:.85rem; letter-spacing:.06em; text-transform:uppercase; font-weight:600;
  padding:.95rem 1.7rem;
  border:1px solid var(--ink);
  color:var(--ink);
  background:transparent;
  transition:background .35s var(--ease), color .35s var(--ease), border-color .35s var(--ease);
  white-space:nowrap;
}
.btn:hover{ background:var(--ink); color:var(--white); }
.btn--solid{ background:var(--ink); color:var(--white); }
.btn--solid:hover{ background:transparent; color:var(--ink); }
.btn--on-dark{ border-color:var(--white); color:var(--white); }
.btn--on-dark:hover{ background:var(--white); color:var(--black); }

.text-link{
  position:relative; display:inline-block; font-weight:600; font-size:.95rem;
  padding-bottom:2px;
  background-image:linear-gradient(currentColor,currentColor);
  background-position:0 100%; background-repeat:no-repeat; background-size:0% 1px;
  transition:background-size .4s var(--ease);
}
.text-link:hover{ background-size:100% 1px; }
.text-link svg{ vertical-align:-2px; margin-left:.3em; transition:transform .3s var(--ease); }
.text-link:hover svg{ transform:translateX(3px); }

/* ---------- Header / nav ---------- */
.site-header{
  position:fixed; top:0; left:0; right:0; z-index:100;
  padding:1.4rem 0;
  transition:background .4s var(--ease), padding .4s var(--ease), border-color .4s var(--ease);
  border-bottom:1px solid transparent;
}
.site-header .container{ display:flex; align-items:center; justify-content:space-between; }
.site-header.is-scrolled, .site-header.is-light{
  background:var(--off-white);
  border-bottom-color:var(--gray-200);
  padding:1rem 0;
}
.site-header.is-dark-page:not(.is-scrolled){ }
.brand{
  font-family:var(--serif); font-size:1.15rem; letter-spacing:.02em; font-weight:600;
  color:var(--white);
}
.site-header.is-scrolled .brand,
.site-header.is-light .brand{ color:var(--ink); }
.brand small{ display:block; font-family:var(--sans); font-weight:500; font-size:.6rem; letter-spacing:.2em; color:var(--gray-400); margin-top:.15rem; }

.nav{ display:flex; align-items:center; gap:2.2rem; }
.nav a{
  font-size:.78rem; letter-spacing:.12em; text-transform:uppercase; font-weight:600;
  color:rgba(255,255,255,.82);
  position:relative; padding:.3rem 0;
}
.site-header.is-scrolled .nav a, .site-header.is-light .nav a{ color:var(--gray-600); }
.nav a::after{
  content:""; position:absolute; left:0; right:0; bottom:0; height:1px; background:currentColor;
  transform:scaleX(0); transform-origin:right; transition:transform .35s var(--ease);
}
.nav a:hover::after, .nav a.is-active::after{ transform:scaleX(1); transform-origin:left; }
.nav a.is-active{ color:var(--white); }
.site-header.is-scrolled .nav a.is-active, .site-header.is-light .nav a.is-active{ color:var(--ink); }
.nav .nav-cta{
  border:1px solid rgba(255,255,255,.55); padding:.55rem 1.1rem;
}
.site-header.is-scrolled .nav-cta, .site-header.is-light .nav-cta{ border-color:var(--ink); }
.nav .nav-cta::after{ display:none; }

.nav-toggle{
  display:none; width:2.2rem; height:2.2rem; border:none; background:none; cursor:pointer;
  position:relative; z-index:200;
}
.nav-toggle span{
  position:absolute; left:.3rem; right:.3rem; height:1px; background:var(--white);
  transition:transform .3s var(--ease), opacity .3s var(--ease), background .3s var(--ease);
}
.site-header.is-scrolled .nav-toggle span, .site-header.is-light .nav-toggle span{ background:var(--ink); }
.nav-toggle span:nth-child(1){ top:.8rem; }
.nav-toggle span:nth-child(2){ top:1.35rem; }
body.nav-open .nav-toggle span{ background:var(--ink) !important; }
body.nav-open .nav-toggle span:nth-child(1){ transform:translateY(.275rem) rotate(45deg); }
body.nav-open .nav-toggle span:nth-child(2){ transform:translateY(-.275rem) rotate(-45deg); }

@media (max-width:900px){
  .nav{
    position:fixed; inset:0; z-index:150;
    background:var(--off-white);
    flex-direction:column; justify-content:center; align-items:flex-start;
    gap:1.6rem; padding:0 8vw;
    transform:translateY(-100%); opacity:0;
    transition:transform .5s var(--ease), opacity .4s var(--ease);
    pointer-events:none;
  }
  body.nav-open .nav{ transform:translateY(0); opacity:1; pointer-events:auto; }
  .nav a{ color:var(--ink); font-size:1.5rem; font-family:var(--serif); letter-spacing:0; text-transform:none; font-weight:500; }
  .nav a.is-active{ color:var(--ink); }
  .nav .nav-cta{ border-color:var(--ink); margin-top:1rem; font-family:var(--sans); font-size:.85rem; text-transform:uppercase; letter-spacing:.1em; }
  .nav-toggle{ display:block; }
}

/* ---------- Hero (home) ---------- */
.hero{
  position:relative; min-height:100svh; display:flex; align-items:flex-end;
  background:var(--black); overflow:hidden; color:var(--white);
}
.hero-video-wrap{
  position:absolute; inset:0; overflow:hidden; background:var(--black);
}
.hero-video-wrap video, .hero-video-wrap img{
  position:absolute; inset:0; width:100%; height:100%; object-fit:cover; object-position:center 40%;
}
/* Two dedicated clips: a true horizontal edit for desktop/tablet, a true
   vertical edit for phones (picked via <source media> in the markup, since
   the box the video sits in is a different shape on each). object-position
   just nudges the crop up slightly on each so heads aren't cut off. */
@media (max-width:640px){
  .hero-video-wrap video, .hero-video-wrap img{ object-position:center 28%; }
}
.hero::before{
  content:""; position:absolute; inset:0;
  background:linear-gradient(180deg, rgba(10,10,10,.15) 0%, rgba(10,10,10,.1) 38%, rgba(10,10,10,.86) 100%);
  z-index:1;
}
.hero-content{ position:relative; z-index:2; width:100%; padding-bottom:clamp(2.5rem,7vw,5.5rem); }
.hero-name{ font-size:.85rem; letter-spacing:.28em; text-transform:uppercase; color:var(--gray-200); margin-bottom:1.1rem; }
.hero-headline{
  font-size:clamp(2.3rem,6.2vw,5.4rem); color:var(--white); max-width:15ch;
}
.hero-sub{ margin-top:1.4rem; font-size:clamp(.95rem,1.4vw,1.15rem); color:var(--gray-200); letter-spacing:.02em; }
.hero-scroll{
  position:absolute; z-index:2; left:var(--gutter); bottom:2rem;
  font-size:.7rem; letter-spacing:.2em; text-transform:uppercase; color:var(--gray-300);
  display:flex; align-items:center; gap:.6rem;
}
.hero-scroll .line{ width:1px; height:2.2rem; background:var(--gray-400); display:inline-block; animation:scrollpulse 2.2s infinite; }
@keyframes scrollpulse{ 0%,100%{ opacity:.25; } 50%{ opacity:1; } }

/* ---------- Page hero (interior pages) ---------- */
.page-hero{
  padding:clamp(9rem,16vw,12rem) 0 clamp(3rem,6vw,4.5rem);
  background:var(--off-white);
}
.page-hero--dark{ background:var(--black); color:var(--white); }
.page-hero h1{ font-size:clamp(2.2rem,5vw,3.9rem); max-width:16ch; margin-top:1rem; }
.page-hero .lede{ margin-top:1.4rem; max-width:56ch; font-size:1.1rem; color:var(--gray-600); }
.page-hero--dark .lede{ color:var(--gray-300); }

/* ---------- Reveal ---------- */
.reveal{ opacity:0; transform:translateY(26px); transition:opacity .9s var(--ease), transform .9s var(--ease); }
.reveal.is-visible{ opacity:1; transform:none; }
.reveal-delay-1{ transition-delay:.08s; }
.reveal-delay-2{ transition-delay:.16s; }
.reveal-delay-3{ transition-delay:.24s; }
.reveal-delay-4{ transition-delay:.32s; }

/* ---------- Grid helpers ---------- */
.grid{ display:grid; gap:var(--gutter); }
.grid-2{ grid-template-columns:repeat(2,1fr); }
.grid-3{ grid-template-columns:repeat(3,1fr); }
.grid-4{ grid-template-columns:repeat(4,1fr); }
@media (max-width:900px){
  .grid-2,.grid-3,.grid-4{ grid-template-columns:1fr; }
}

/* ---------- Credentials strip ---------- */
.strip{
  display:flex; flex-wrap:wrap; border-top:1px solid var(--gray-200); border-bottom:1px solid var(--gray-200);
}
.strip-item{
  flex:1 1 220px; padding:1.6rem var(--gutter); border-left:1px solid var(--gray-200);
}
.strip-item:first-child{ border-left:none; }
.strip-item .num{ font-family:var(--serif); font-size:.75rem; color:var(--gray-400); display:block; margin-bottom:.5rem; }
.strip-item p{ font-size:.92rem; color:var(--gray-600); }
@media (max-width:760px){
  .strip-item{ flex:1 1 50%; border-left:1px solid var(--gray-200); }
  .strip-item:nth-child(odd){ border-left:none; }
}

/* ---------- Section headers ---------- */
.section-head{ max-width:44rem; margin-bottom:clamp(2.5rem,5vw,4rem); }
.section-head h2{ font-size:clamp(1.9rem,3.6vw,3rem); }
.section-head .lede{ margin-top:1.1rem; font-size:1.08rem; color:var(--gray-600); max-width:52ch; }
.section--dark .section-head .lede, .section--charcoal .section-head .lede{ color:var(--gray-300); }
.section-head.center{ margin-left:auto; margin-right:auto; text-align:center; }

/* ---------- Statement blocks ---------- */
.statement{
  font-family:var(--serif); font-weight:500; letter-spacing:-.01em;
  font-size:clamp(1.6rem,3.4vw,2.7rem); line-height:1.28; max-width:24ch;
}
.statement.center{ margin:0 auto; text-align:center; max-width:20ch; }
.statement .muted{ color:var(--gray-400); }

/* ---------- Pillars / Focus ---------- */
.pillar{
  padding:2.6rem 0; border-top:1px solid var(--gray-200);
  display:grid; grid-template-columns:5rem 1fr; gap:var(--gutter);
}
.pillar:last-child{ border-bottom:1px solid var(--gray-200); }
.pillar .idx{ font-family:var(--serif); font-size:1.1rem; color:var(--gray-400); padding-top:.2rem; }
.pillar h3{ font-size:clamp(1.3rem,2.4vw,1.8rem); }
.pillar .tagline{ font-size:.95rem; color:var(--accent-soft); font-weight:600; letter-spacing:.02em; margin-top:.5rem; }
.pillar p{ margin-top:1rem; color:var(--gray-600); max-width:60ch; }
.pillar .tags{ margin-top:1.2rem; display:flex; flex-wrap:wrap; gap:.5rem; }
.pillar .tags span{
  font-size:.72rem; letter-spacing:.05em; text-transform:uppercase; color:var(--gray-500);
  border:1px solid var(--gray-200); padding:.35rem .7rem;
}
@media (max-width:640px){
  .pillar{ grid-template-columns:1fr; gap:.6rem; }
}

/* ---------- Journey diagram ---------- */
.journey{ display:flex; flex-wrap:wrap; }
.journey-step{
  flex:1 1 160px; padding:1.8rem 1.2rem 1.8rem 0; position:relative;
}
.journey-step h4{ font-family:var(--sans); font-size:.78rem; letter-spacing:.18em; text-transform:uppercase; font-weight:700; color:var(--white); }
.journey-step .arrow{ display:none; }
.journey-step p{ margin-top:.7rem; font-size:.88rem; color:var(--gray-400); line-height:1.55; }
@media (min-width:900px){
  .journey-step:not(:last-child)::after{
    content:"→"; position:absolute; right:-.1rem; top:1.8rem; color:var(--gray-600); font-size:1rem;
  }
}

/* ---------- Cards ---------- */
.card{
  background:var(--white); border:1px solid var(--gray-200); padding:2.2rem;
  display:flex; flex-direction:column; gap:1rem; height:100%;
}
.card h3{ font-size:1.35rem; }
.card p{ color:var(--gray-600); font-size:.96rem; }
.card .card-link{ margin-top:auto; }

/* ---------- Image / editorial media blocks ---------- */
.media-frame{ overflow:hidden; background:var(--gray-200); position:relative; }
.media-frame img, .media-frame video{ width:100%; height:100%; object-fit:cover; transition:transform 1.2s var(--ease); }
.media-frame.zoom:hover img{ transform:scale(1.045); }
.ratio-4-5{ aspect-ratio:4/5; }
.ratio-3-2{ aspect-ratio:3/2; }
.ratio-16-9{ aspect-ratio:16/9; }
.ratio-1-1{ aspect-ratio:1/1; }

.caption{ font-size:.78rem; color:var(--gray-500); margin-top:.8rem; letter-spacing:.02em; }

/* ---------- Split sections ---------- */
.split{ display:grid; grid-template-columns:1fr 1fr; gap:clamp(2rem,6vw,5rem); align-items:center; }
.split.reverse{ direction:rtl; }
.split.reverse > *{ direction:ltr; }
@media (max-width:900px){
  .split{ grid-template-columns:1fr; }
  .split.reverse{ direction:ltr; }
}

/* ---------- Full bleed image sections ---------- */
.bleed{ position:relative; min-height:72vh; display:flex; align-items:flex-end; background:var(--black); color:var(--white); overflow:hidden; }
.bleed img{ position:absolute; inset:0; width:100%; height:100%; object-fit:cover; object-position:center 72%; z-index:0; }
.bleed::before{ content:""; position:absolute; inset:0; background:rgba(8,8,8,.5); z-index:1; }
.bleed::after{ content:""; position:absolute; inset:0; background:linear-gradient(180deg, rgba(10,10,10,.1) 0%, rgba(10,10,10,.25) 30%, rgba(10,10,10,.92) 100%); z-index:1; }
.bleed-content{ position:relative; z-index:2; padding:3.5rem 0; }
.bleed-content .statement{ max-width:26ch; text-shadow:0 2px 24px rgba(0,0,0,.35); }

/* ---------- Figure + caption (for busy source photography) ---------- */
.figure-caption{ position:relative; }
.figure-caption .media-frame{ margin-bottom:0; }
.figure-block{ background:var(--black); color:var(--white); }
.figure-block .caption-panel{ padding:clamp(2.2rem,5vw,3.5rem) 0; }

/* ---------- World / global list ---------- */
.locations{ columns:2; column-gap:var(--gutter); }
@media (max-width:640px){ .locations{ columns:1; } }
.locations li{ padding:.65rem 0; border-bottom:1px solid var(--gray-700); break-inside:avoid; display:flex; justify-content:space-between; gap:1rem; font-size:.95rem; }
.section--dark .locations li{ border-color:#2a2a2a; }
.locations li span:last-child{ color:var(--gray-500); }

/* ---------- Speaking topics ---------- */
.topic{ padding:1.9rem 0; border-top:1px solid var(--gray-200); }
.topic:last-child{ border-bottom:1px solid var(--gray-200); }
.topic-head{ display:flex; justify-content:space-between; align-items:baseline; gap:1rem; }
.topic h3{ font-size:1.2rem; }
.topic .num{ font-size:.78rem; color:var(--gray-400); font-family:var(--serif); }
.topic p{ margin-top:.6rem; color:var(--gray-600); font-size:.94rem; max-width:60ch; }

/* ---------- Timeline (selected engagements) ---------- */
.timeline-row{
  display:grid; grid-template-columns:7rem 1fr; gap:var(--gutter); padding:1.5rem 0; border-top:1px solid var(--gray-200);
}
.timeline-row:last-child{ border-bottom:1px solid var(--gray-200); }
.timeline-row .year{ font-family:var(--serif); font-size:1rem; color:var(--gray-500); }
.timeline-row h4{ font-size:1.1rem; font-weight:600; font-family:var(--sans); }
.timeline-row p{ margin-top:.35rem; color:var(--gray-500); font-size:.9rem; }

/* ---------- Insights / media grids ---------- */
.insight-card, .media-card{
  border-top:1px solid var(--gray-200); padding-top:1.4rem;
}
.insight-card .eyebrow, .media-card .eyebrow{ margin-bottom:.7rem; }
.insight-card h3{ font-size:1.25rem; }
.insight-card p{ margin-top:.6rem; color:var(--gray-600); font-size:.92rem; }
.coming-soon-tag{
  display:inline-block; font-size:.68rem; letter-spacing:.14em; text-transform:uppercase;
  color:var(--accent-soft); border:1px solid var(--gray-200); padding:.3rem .6rem; margin-top:1rem;
}

.filter-row{ display:flex; flex-wrap:wrap; gap:.6rem; margin-bottom:2.5rem; }
.filter-pill{
  font-size:.75rem; letter-spacing:.08em; text-transform:uppercase; font-weight:600;
  border:1px solid var(--gray-200); padding:.55rem 1rem; color:var(--gray-600); cursor:pointer; background:none;
  transition:all .3s var(--ease);
}
.filter-pill.is-active, .filter-pill:hover{ border-color:var(--ink); color:var(--ink); }

/* ---------- Contact ---------- */
.contact-grid{ display:grid; grid-template-columns:1.1fr .9fr; gap:clamp(2.5rem,6vw,5rem); }
@media (max-width:900px){ .contact-grid{ grid-template-columns:1fr; } }
.field{ margin-bottom:1.5rem; }
.field label{ display:block; font-size:.75rem; letter-spacing:.1em; text-transform:uppercase; color:var(--gray-500); margin-bottom:.55rem; }
.field input, .field select, .field textarea{
  width:100%; border:none; border-bottom:1px solid var(--gray-300); background:transparent;
  font-family:var(--sans); font-size:1rem; padding:.65rem 0; color:var(--ink); outline:none;
  transition:border-color .3s var(--ease);
}
.field input:focus, .field select:focus, .field textarea:focus{ border-color:var(--ink); }
.field textarea{ resize:vertical; min-height:110px; }
.pathway-card{ border:1px solid var(--gray-200); padding:2rem; margin-bottom:1.4rem; }
.pathway-card .eyebrow{ margin-bottom:.7rem; }
.pathway-card p{ color:var(--gray-600); margin:.8rem 0 1.2rem; font-size:.94rem; }

/* ---------- Footer ---------- */
.site-footer{ background:var(--black); color:var(--gray-400); padding:4.5rem 0 2rem; font-size:.9rem; }
.footer-top{ display:grid; grid-template-columns:1.4fr 1fr 1fr 1fr; gap:2.5rem; padding-bottom:3rem; border-bottom:1px solid #232323; }
@media (max-width:820px){ .footer-top{ grid-template-columns:1fr 1fr; } }
@media (max-width:520px){ .footer-top{ grid-template-columns:1fr; } }
.footer-brand{ font-family:var(--serif); color:var(--white); font-size:1.3rem; margin-bottom:.9rem; }
.footer-top p{ color:var(--gray-500); font-size:.88rem; max-width:32ch; }
.footer-col h5{ font-size:.72rem; letter-spacing:.14em; text-transform:uppercase; color:var(--gray-500); margin-bottom:1.1rem; }
.footer-col li{ margin-bottom:.7rem; }
.footer-col a{ color:var(--gray-300); font-size:.92rem; }
.footer-col a:hover{ color:var(--white); }
.footer-bottom{ display:flex; flex-wrap:wrap; justify-content:space-between; gap:1rem; padding-top:2rem; font-size:.78rem; color:var(--gray-600); }
.footer-disclaimer{ max-width:70ch; line-height:1.6; }

/* ---------- Utility ---------- */
.mt-0{ margin-top:0 !important; }
.text-center{ text-align:center; }
.max-w-content{ max-width:70ch; }
.mx-auto{ margin-left:auto; margin-right:auto; }
.mb-lg{ margin-bottom:clamp(2rem,5vw,3.5rem); }
.hidden-sr{ position:absolute; width:1px; height:1px; overflow:hidden; clip:rect(0,0,0,0); white-space:nowrap; }
.skip-link{
  position:absolute; left:-999px; top:0; background:var(--white); color:var(--black); padding:.8rem 1.2rem; z-index:1000;
}
.skip-link:focus{ left:1rem; top:1rem; }
