/* ============================================================
   STILLWATERS LAW FIRM — Design Tokens
   ============================================================ */
@import url('https://fonts.googleapis.com/css2?family=Fraunces:opsz,wght@9..144,300;9..144,400;9..144,500;9..144,600;9..144,700&family=Inter:wght@400;500;600;700&family=IBM+Plex+Mono:wght@400;500&display=swap');

:root{
  /* Color */
  --wine-900:#3D0221;
  --wine-700:#5C0633;
  --wine-500:#7A1348;
  --wine-300:#A84A72;
  --gold-500:#B08D57;
  --gold-300:#D6BD8D;
  --gold-100:#F0E5D2;
  --ink:#201A1D;
  --ink-soft:#5A4F53;
  --cream:#FAF6F1;
  --rose-100:#F1E4EA;
  --white:#FFFFFF;
  --line:#E4D8DC;

  /* Type */
  --font-display:'Fraunces', serif;
  --font-body:'Inter', -apple-system, sans-serif;
  --font-mono:'IBM Plex Mono', monospace;

  /* Layout */
  --max-w:1280px;
  --gutter:clamp(1.25rem, 4vw, 4rem);
  --radius:2px;
}

*,*::before,*::after{box-sizing:border-box;}
html{scroll-behavior:smooth;}
body{
  margin:0;
  background:var(--cream);
  color:var(--ink);
  font-family:var(--font-body);
  font-size:16px;
  line-height:1.6;
  -webkit-font-smoothing:antialiased;
}
img{max-width:100%;display:block;}
a{color:inherit;text-decoration:none;}
h1,h2,h3,h4{
  font-family:var(--font-display);
  font-weight:600;
  line-height:1.08;
  margin:0 0 .5em;
  letter-spacing:-0.01em;
  color:var(--wine-900);
}
h1{font-size:clamp(2.6rem,5.5vw,4.6rem); font-optical-sizing:auto;}
h2{font-size:clamp(2rem,3.6vw,3rem);}
h3{font-size:clamp(1.3rem,2vw,1.7rem);}
p{margin:0 0 1.1em; color:var(--ink-soft);}
.container{max-width:var(--max-w); margin:0 auto; padding:0 var(--gutter);}

@media (prefers-reduced-motion: reduce){
  *{animation-duration:0.001ms !important; animation-iteration-count:1 !important; transition-duration:0.001ms !important; scroll-behavior:auto !important;}
}

/* ---------- Eyebrow / mono labels ---------- */
.eyebrow{
  font-family:var(--font-mono);
  font-size:0.72rem;
  letter-spacing:.14em;
  text-transform:uppercase;
  color:var(--gold-500);
  display:flex;
  align-items:center;
  gap:.6em;
  margin-bottom:.9em;
}
.eyebrow::before{
  content:"";
  width:28px; height:1px;
  background:var(--gold-500);
  display:inline-block;
}

/* ---------- Buttons ---------- */
.btn{
  position:relative;
  overflow:hidden;
  display:inline-flex;
  align-items:center;
  gap:.6em;
  font-family:var(--font-body);
  font-weight:600;
  font-size:.92rem;
  letter-spacing:.01em;
  padding:.95em 1.7em;
  border-radius:var(--radius);
  border:1px solid transparent;
  cursor:pointer;
  transition:transform .25s ease, box-shadow .25s ease, background .25s ease, color .25s ease;
}
.btn-primary{ background:var(--wine-700); color:var(--white); }
.btn-primary:hover{ background:var(--wine-900); transform:translateY(-2px); box-shadow:0 10px 24px -10px rgba(61,2,33,.55); }
.btn-gold{ background:var(--gold-500); color:var(--wine-900); }
.btn-gold:hover{ background:var(--gold-300); transform:translateY(-2px); box-shadow:0 10px 24px -10px rgba(176,141,87,.55); }
.btn-outline{ background:transparent; color:var(--cream); border-color:rgba(250,246,241,.4); }
.btn-outline:hover{ border-color:var(--gold-500); color:var(--gold-300); }
.btn-outline-dark{ background:transparent; color:var(--wine-700); border-color:var(--wine-700); }
.btn-outline-dark:hover{ background:var(--wine-700); color:var(--white); }

.ripple{ position:absolute; border-radius:50%; background:rgba(255,255,255,.55); transform:scale(0); animation:ripple-anim .6s ease-out; pointer-events:none; }
@keyframes ripple-anim{ to{ transform:scale(3.2); opacity:0; } }

/* ---------- Navbar ---------- */
.nav{
  position:fixed; top:0; left:0; right:0; z-index:100;
  background:rgba(250,246,241,.86);
  backdrop-filter:blur(10px);
  border-bottom:1px solid transparent;
  transition:border-color .3s ease, background .3s ease;
}
.nav.scrolled{ border-color:var(--line); background:rgba(250,246,241,.97); }
.nav-inner{
  max-width:var(--max-w); margin:0 auto; padding:0 var(--gutter);
  display:flex; align-items:center; justify-content:space-between;
  height:78px;
}
.wordmark{
  font-family:var(--font-display);
  font-weight:600;
  font-size:1.25rem;
  color:var(--wine-900);
  letter-spacing:.01em;
  display:flex; align-items:baseline; gap:.4em;
}
.wordmark small{
  font-family:var(--font-mono);
  font-size:.6rem;
  letter-spacing:.14em;
  color:var(--gold-500);
  font-weight:500;
}
.nav-links{ display:flex; align-items:center; gap:2.2rem; }
.nav-links a{
  font-size:.9rem; font-weight:500; color:var(--ink);
  position:relative; padding:.3em 0;
}
.nav-links a::after{
  content:""; position:absolute; left:0; bottom:0; height:1px; width:0;
  background:var(--wine-700); transition:width .25s ease;
}
.nav-links a:hover::after, .nav-links a.active::after{ width:100%; }
.nav-links a.active{ color:var(--wine-700); }
.nav-cta{
  font-size:.82rem !important; font-weight:600 !important;
  background:var(--wine-700); color:var(--white) !important;
  padding:.65em 1.3em; border-radius:var(--radius);
}
.nav-cta::after{ display:none; }
.nav-cta:hover{ background:var(--wine-900); }
.nav-toggle{ display:none; background:none; border:none; cursor:pointer; padding:.4rem; }
.nav-toggle span{ display:block; width:24px; height:2px; background:var(--wine-900); margin:5px 0; transition:.3s; }

@media (max-width:900px){
  .nav-toggle{ display:block; }
  .nav-links{
    position:fixed; top:78px; left:0; right:0; bottom:0;
    background:var(--cream); flex-direction:column; align-items:flex-start;
    padding:2rem var(--gutter); gap:1.6rem;
    transform:translateX(100%); transition:transform .35s ease;
    overflow-y:auto;
  }
  .nav-links.open{ transform:translateX(0); }
  .nav-links a{ font-size:1.1rem; }
}

/* ---------- Hero (ripple signature) ---------- */
.hero{
  position:relative;
  min-height:100vh;
  display:flex; align-items:flex-end;
  overflow:hidden;
  background:var(--wine-900);
}
.hero-bg{
  position:absolute; inset:0;
  background-size:cover; background-position:center;
  filter:saturate(0.35) contrast(1.05);
}
.hero-bg::after{ content:""; }
.hero-overlay{
  position:absolute; inset:0;
  background:
    linear-gradient(180deg, rgba(61,2,33,.55) 0%, rgba(61,2,33,.75) 55%, rgba(32,10,20,.96) 100%),
    linear-gradient(90deg, rgba(61,2,33,.55), rgba(61,2,33,.2));
  mix-blend-mode:multiply;
  background-color:var(--wine-900);
}
.ripple-rings{
  position:absolute; top:50%; right:-8%; transform:translateY(-50%);
  width:min(60vw,780px); height:min(60vw,780px);
  pointer-events:none;
}
.ripple-rings circle{
  fill:none; stroke:rgba(214,189,141,.35); stroke-width:1;
  transform-origin:center;
  animation:ring-pulse 6s ease-in-out infinite;
}
.ripple-rings circle:nth-child(2){ animation-delay:1.3s; stroke:rgba(214,189,141,.22); }
.ripple-rings circle:nth-child(3){ animation-delay:2.6s; stroke:rgba(214,189,141,.14); }
.ripple-rings circle:nth-child(4){ animation-delay:.4s; stroke:rgba(214,189,141,.28); }
@keyframes ring-pulse{
  0%{ transform:scale(.92); opacity:.4; }
  50%{ transform:scale(1.04); opacity:1; }
  100%{ transform:scale(.92); opacity:.4; }
}
.hero-content{
  position:relative; z-index:2;
  max-width:var(--max-w); margin:0 auto; width:100%;
  padding:0 var(--gutter) 5.5rem;
  color:var(--cream);
}
.hero-content .eyebrow{ color:var(--gold-300); }
.hero-content .eyebrow::before{ background:var(--gold-300); }
.hero h1{ color:var(--white); max-width:14ch; }
.hero h1 em{
  font-style:normal; color:var(--gold-300);
}
.hero-sub{
  color:rgba(250,246,241,.82); max-width:46ch; font-size:1.08rem;
}
.hero-actions{ display:flex; gap:1rem; flex-wrap:wrap; margin-top:1.8rem; }
.scroll-cue{
  position:absolute; bottom:2rem; left:var(--gutter); z-index:2;
  display:flex; align-items:center; gap:.7em;
  font-family:var(--font-mono); font-size:.68rem; letter-spacing:.14em; text-transform:uppercase;
  color:rgba(250,246,241,.55);
}
.scroll-cue .line{ width:1px; height:34px; background:rgba(250,246,241,.4); position:relative; overflow:hidden; }
.scroll-cue .line::after{
  content:""; position:absolute; top:-100%; left:0; width:100%; height:100%;
  background:var(--gold-300); animation:scroll-line 2.2s ease-in-out infinite;
}
@keyframes scroll-line{ 0%{ top:-100%; } 60%{ top:100%; } 100%{ top:100%; } }

/* ---------- Sections ---------- */
section{ padding:6.5rem 0; }
.section-tight{ padding:4rem 0; }
.section-dark{ background:var(--wine-900); color:var(--cream); }
.section-dark h2, .section-dark h3{ color:var(--white); }
.section-dark p{ color:rgba(250,246,241,.72); }
.section-rose{ background:var(--rose-100); }

.section-head{ max-width:640px; margin-bottom:3.2rem; }
.section-head.center{ margin-left:auto; margin-right:auto; text-align:center; }

/* divider ripple */
.divider{
  display:flex; align-items:center; justify-content:center; gap:.5rem;
  margin:0 auto 2.5rem; width:fit-content;
}
.divider span{ width:5px; height:5px; border-radius:50%; background:var(--gold-500); opacity:.35; }
.divider span:nth-child(2){ opacity:.6; width:6px; height:6px; }
.divider span:nth-child(3){ opacity:1; width:7px; height:7px; }

/* ---------- Stats ---------- */
.stats{
  display:grid; grid-template-columns:repeat(4,1fr); gap:2rem;
  border-top:1px solid rgba(250,246,241,.15); border-bottom:1px solid rgba(250,246,241,.15);
  padding:2.6rem 0;
}
.stat b{
  display:block; font-family:var(--font-mono); font-size:clamp(1.6rem,3vw,2.4rem);
  color:var(--gold-300); font-weight:500;
}
.stat span{ font-size:.82rem; color:rgba(250,246,241,.65); }
@media (max-width:800px){ .stats{ grid-template-columns:repeat(2,1fr); } }

/* ---------- Practice area cards ---------- */
.grid-3{ display:grid; grid-template-columns:repeat(3,1fr); gap:1.75rem; }
.grid-2{ display:grid; grid-template-columns:repeat(2,1fr); gap:2rem; }
@media (max-width:900px){ .grid-3{ grid-template-columns:1fr 1fr; } .grid-2{ grid-template-columns:1fr; } }
@media (max-width:640px){ .grid-3{ grid-template-columns:1fr; } }

.pa-card{
  background:var(--white); border:1px solid var(--line);
  padding:2.2rem 1.9rem; position:relative;
  transition:transform .3s ease, box-shadow .3s ease, border-color .3s ease;
}
.pa-card:hover{ transform:translateY(-6px); box-shadow:0 24px 44px -24px rgba(61,2,33,.28); border-color:var(--gold-500); }
.pa-card .num{ font-family:var(--font-mono); font-size:.75rem; color:var(--gold-500); }
.pa-card h3{ margin:.9rem 0 .6rem; }
.pa-card p{ font-size:.94rem; margin-bottom:1.1rem; }
.pa-card a{ font-size:.85rem; font-weight:600; color:var(--wine-700); display:inline-flex; align-items:center; gap:.4em; }
.pa-card a .arrow{ transition:transform .25s ease; }
.pa-card:hover a .arrow{ transform:translateX(4px); }

/* ---------- reveal on scroll ---------- */
.reveal{ opacity:0; transform:translateY(28px); transition:opacity .7s ease, transform .7s ease; }
.reveal.in{ opacity:1; transform:translateY(0); }

/* ---------- Image + text split ---------- */
.split{ display:grid; grid-template-columns:1fr 1fr; gap:4rem; align-items:center; }
@media (max-width:860px){ .split{ grid-template-columns:1fr; gap:2.5rem; } }
.split img{ width:100%; height:100%; object-fit:cover; }

.photo-frame{ position:relative; }
.photo-frame::before{
  content:""; position:absolute; top:16px; left:16px; right:-16px; bottom:-16px;
  border:1px solid var(--gold-500); z-index:-1;
}

/* ---------- Gallery ---------- */
.gallery{ display:grid; grid-template-columns:1.4fr 1fr 1fr; grid-template-rows:auto auto; gap:.9rem; }
.gallery img{ width:100%; height:100%; object-fit:cover; }
.gallery .g1{ grid-row:1 / span 2; }
@media (max-width:760px){ .gallery{ grid-template-columns:1fr 1fr; } .gallery .g1{ grid-column:1/-1; grid-row:auto; } }

/* ---------- Cards: insights ---------- */
.insight-card{
  border-bottom:1px solid var(--line); padding:2rem 0;
  display:grid; grid-template-columns:120px 1fr; gap:1.6rem;
}
@media (max-width:600px){ .insight-card{ grid-template-columns:1fr; } }
.insight-date{ font-family:var(--font-mono); font-size:.78rem; color:var(--gold-500); }
.tag{
  display:inline-block; font-family:var(--font-mono); font-size:.68rem; letter-spacing:.08em;
  text-transform:uppercase; color:var(--wine-700); background:var(--rose-100);
  padding:.3em .7em; margin-bottom:.7em;
}
.tag.event{ color:var(--gold-500); background:var(--wine-900); }

.filter-bar{ display:flex; gap:.7rem; flex-wrap:wrap; margin-bottom:2.5rem; }
.filter-btn{
  font-family:var(--font-mono); font-size:.75rem; letter-spacing:.05em;
  padding:.6em 1.1em; border:1px solid var(--line); background:transparent; cursor:pointer;
  color:var(--ink-soft); transition:.25s;
}
.filter-btn.active, .filter-btn:hover{ background:var(--wine-700); color:var(--white); border-color:var(--wine-700); }

/* ---------- Footer ---------- */
footer{ background:var(--wine-900); color:rgba(250,246,241,.7); padding:5rem 0 2rem; }
.footer-grid{ display:grid; grid-template-columns:1.4fr 1fr 1fr 1fr; gap:3rem; padding-bottom:3.5rem; border-bottom:1px solid rgba(250,246,241,.14); }
@media (max-width:860px){ .footer-grid{ grid-template-columns:1fr 1fr; } }
@media (max-width:520px){ .footer-grid{ grid-template-columns:1fr; } }
.footer-word{ font-family:var(--font-display); font-size:1.5rem; color:var(--white); margin-bottom:.7rem; }
footer h4{ font-family:var(--font-mono); font-size:.72rem; letter-spacing:.12em; text-transform:uppercase; color:var(--gold-300); margin-bottom:1.1rem; }
footer ul{ list-style:none; padding:0; margin:0; display:flex; flex-direction:column; gap:.65rem; }
footer a:hover{ color:var(--gold-300); }
.footer-bottom{ display:flex; justify-content:space-between; align-items:center; padding-top:1.6rem; font-size:.8rem; flex-wrap:wrap; gap:1rem; }

/* ---------- Form ---------- */
.form-field{ margin-bottom:1.4rem; }
.form-field label{ display:block; font-size:.82rem; font-weight:600; margin-bottom:.5rem; color:var(--wine-900); }
.form-field input, .form-field select, .form-field textarea{
  width:100%; padding:.85em 1em; border:1px solid var(--line); background:var(--white);
  font-family:var(--font-body); font-size:.95rem; color:var(--ink); border-radius:var(--radius);
}
.form-field textarea{ resize:vertical; min-height:120px; }
.form-field input:focus, .form-field select:focus, .form-field textarea:focus{
  outline:2px solid var(--gold-500); outline-offset:1px; border-color:var(--gold-500);
}

/* ---------- Page header (interior pages) ---------- */
.page-head{
  padding:11rem 0 4.5rem; background:var(--wine-900); color:var(--cream); position:relative; overflow:hidden;
}
.page-head .eyebrow{ color:var(--gold-300); }
.page-head .eyebrow::before{ background:var(--gold-300); }
.page-head h1{ color:var(--white); max-width:16ch; }
.page-head p{ color:rgba(250,246,241,.75); max-width:52ch; font-size:1.05rem; }

/* utility */
.mt-lg{ margin-top:3rem; }
.text-center{ text-align:center; }
.visually-hidden{ position:absolute; width:1px; height:1px; overflow:hidden; clip:rect(0 0 0 0); }
:focus-visible{ outline:2px solid var(--gold-500); outline-offset:3px; }
