/* ===== Design tokens ===== */
:root{
  --bg:#ffffff;
  --ink:#1d1d1f;
  --gray:#6e6e73;
  --gray-light:#86868b;
  --navy:#011d3f;
  --navy-dark:#000f24;
  --gold:#bd8f14;
  --hairline:rgba(0,0,0,0.08);
  --serif:"Source Serif 4", Georgia, "Times New Roman", serif;
}

*{ margin:0; padding:0; box-sizing:border-box; -webkit-font-smoothing:antialiased; }
html{ scroll-behavior:smooth; }
body{
  background:var(--bg);
  color:var(--ink);
  font-family:-apple-system, BlinkMacSystemFont, "Inter", "Helvetica Neue", Helvetica, Arial, sans-serif;
  min-height:100vh;
  display:flex;
  flex-direction:column;
}
a{ color:inherit; }
img{ max-width:100%; }

/* ===== Nav ===== */
nav{
  position:fixed; top:0; left:0; right:0; z-index:20;
  background:rgba(255,255,255,0.8);
  backdrop-filter:saturate(180%) blur(20px);
  -webkit-backdrop-filter:saturate(180%) blur(20px);
  border-bottom:1px solid var(--hairline);
}
.nav-inner{
  max-width:1120px; margin:0 auto; padding:0 24px;
  height:76px; display:flex; align-items:center; justify-content:space-between;
  position:relative;
}
.nav-logo{ display:flex; align-items:center; flex-shrink:0; }
.nav-logo img{ height:46px; width:auto; display:block; }

.nav-links{ display:flex; align-items:center; gap:32px; }
.nav-links a{
  font-size:15px; font-weight:500; letter-spacing:-0.01em; text-decoration:none; color:var(--ink);
  transition:color .2s ease;
}
.nav-links a:hover{ color:var(--navy); }
.nav-links a.current{ color:var(--navy); }
.nav-phone{
  color:var(--navy) !important; font-weight:600 !important;
  border-left:1px solid var(--hairline); padding-left:24px;
}

.nav-toggle{
  display:none; flex-direction:column; justify-content:center; gap:5px;
  width:32px; height:32px; background:none; border:0; cursor:pointer; padding:0;
}
.nav-toggle span{ display:block; width:100%; height:2px; background:var(--ink); transition:transform .25s ease, opacity .25s ease; }
.nav-toggle[aria-expanded="true"] span:nth-child(1){ transform:translateY(7px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] span:nth-child(2){ opacity:0; }
.nav-toggle[aria-expanded="true"] span:nth-child(3){ transform:translateY(-7px) rotate(-45deg); }

@media (max-width:760px){
  .nav-toggle{ display:flex; }
  .nav-links{
    position:absolute; top:76px; left:0; right:0;
    background:rgba(255,255,255,0.98);
    backdrop-filter:saturate(180%) blur(20px);
    -webkit-backdrop-filter:saturate(180%) blur(20px);
    border-bottom:1px solid var(--hairline);
    flex-direction:column; align-items:flex-start; gap:0;
    max-height:0; overflow:hidden; visibility:hidden; transition:max-height .3s ease, visibility 0s linear .3s;
  }
  .nav-links.open{ max-height:280px; visibility:visible; transition:max-height .3s ease, visibility 0s linear; }
  .nav-links a{ width:100%; padding:16px 24px; border-bottom:1px solid var(--hairline); }
  .nav-phone{ border-left:0; padding-left:24px; }
}

/* ===== Layout shell ===== */
main{ flex:1; padding-top:76px; }
.section{ padding:96px 24px; }
.section-narrow{ max-width:720px; margin:0 auto; }
.section-wide{ max-width:1120px; margin:0 auto; }
.section-alt{ background:#f5f5f7; }

/* ===== Hero ===== */
.hero{ padding:120px 24px 96px; text-align:center; max-width:820px; margin:0 auto; }
.eyebrow{ font-size:17px; font-weight:600; color:var(--navy); letter-spacing:-0.01em; margin-bottom:8px; }
h1{
  font-family:var(--serif); font-size:clamp(40px, 7vw, 80px); line-height:1.08;
  font-weight:700; letter-spacing:-0.01em; color:var(--ink);
}
.sub{ font-size:clamp(19px, 2.4vw, 25px); font-weight:500; letter-spacing:-0.01em; color:var(--gray); margin-top:14px; }
.lede{ font-size:19px; line-height:1.6; color:var(--gray); max-width:560px; margin:28px auto 0; }

/* ===== Buttons ===== */
.cta-row{ display:flex; justify-content:center; gap:16px; margin-top:40px; flex-wrap:wrap; }
.btn{
  display:inline-flex; align-items:center; justify-content:center; padding:12px 26px;
  border-radius:980px; font-size:17px; font-weight:400; letter-spacing:-0.01em;
  text-decoration:none; transition:transform .2s ease, background .2s ease, opacity .2s ease;
}
.btn-primary{ background:var(--navy); color:#fff; }
.btn-primary:hover{ background:var(--navy-dark); }
.btn-secondary{ color:var(--navy); }
.btn-secondary:hover{ text-decoration:underline; }
.btn:focus-visible{ outline:2px solid var(--navy); outline-offset:3px; }

/* ===== Page header (Services / Contact) ===== */
.page-header{ padding:140px 24px 56px; text-align:center; max-width:720px; margin:0 auto; }
.page-header h1{ font-size:clamp(36px, 6vw, 56px); }
.page-header p{ font-size:19px; color:var(--gray); margin-top:16px; line-height:1.6; }

/* ===== Section headings ===== */
h2{
  font-family:var(--serif); font-size:clamp(28px, 4vw, 40px); font-weight:700;
  letter-spacing:-0.01em; color:var(--ink); margin-bottom:16px;
}
.text-center{ text-align:center; }

/* ===== Service cards (Home teaser) ===== */
.card-grid{ display:grid; grid-template-columns:repeat(3, 1fr); gap:24px; margin-top:48px; }
.card{
  border:1px solid var(--hairline); border-radius:18px; padding:32px 28px;
  text-decoration:none; color:inherit; transition:transform .25s ease, box-shadow .25s ease, border-color .25s ease;
}
.card:hover{ transform:translateY(-4px); box-shadow:0 16px 40px rgba(1,29,63,0.08); border-color:transparent; }
.card h3{ font-size:20px; font-weight:600; letter-spacing:-0.01em; margin-bottom:10px; }
.card p{ font-size:15px; line-height:1.55; color:var(--gray); }
.card .card-arrow{ display:inline-block; margin-top:16px; font-size:14px; font-weight:600; color:var(--navy); }
@media (max-width:900px){ .card-grid{ grid-template-columns:1fr; } }

/* ===== Why-us strip ===== */
.value-row{ display:grid; grid-template-columns:repeat(3, 1fr); gap:40px; margin-top:16px; }
.value-row div{ text-align:center; }
.value-row h3{ font-size:17px; font-weight:600; margin-bottom:8px; }
.value-row p{ font-size:15px; line-height:1.55; color:var(--gray); }
@media (max-width:760px){ .value-row{ grid-template-columns:1fr; gap:32px; } }

/* ===== Service detail sections (Services page) ===== */
.service-block{ padding:64px 24px; border-top:1px solid var(--hairline); scroll-margin-top:92px; }
.service-block:first-of-type{ border-top:0; }
.service-block-inner{ max-width:720px; margin:0 auto; }
.service-block-inner > p{ font-size:18px; line-height:1.65; color:var(--gray); margin-bottom:20px; }
.service-list{ list-style:none; display:grid; gap:12px; }
.service-list li{ font-size:16px; line-height:1.5; color:var(--ink); padding-left:28px; position:relative; }
.service-list li::before{ content:""; position:absolute; left:0; top:9px; width:14px; height:2px; background:var(--gold); }

/* ===== Contact page ===== */
.contact-grid{ display:grid; grid-template-columns:1fr 1fr; gap:56px; align-items:start; }
.contact-list{ list-style:none; display:grid; gap:24px; }
.contact-list dt{ font-size:13px; text-transform:uppercase; letter-spacing:.06em; color:var(--gray-light); margin-bottom:4px; }
.contact-list dd{ font-size:19px; font-weight:500; }
.contact-list a{ text-decoration:none; }
.contact-list a:hover{ color:var(--navy); }
.map-frame{ border:1px solid var(--hairline); border-radius:18px; overflow:hidden; aspect-ratio:4/3; }
.map-frame iframe{ width:100%; height:100%; border:0; display:block; }
@media (max-width:860px){ .contact-grid{ grid-template-columns:1fr; gap:40px; } }

/* ===== CTA band ===== */
.cta-band{ background:var(--navy); color:#fff; text-align:center; padding:88px 24px; }
.cta-band h2{ color:#fff; }
.cta-band p{ color:rgba(255,255,255,0.75); font-size:18px; max-width:520px; margin:0 auto 32px; }
.cta-band .btn-primary{ background:#fff; color:var(--navy); }
.cta-band .btn-primary:hover{ background:#f0f0f0; }
.cta-band .btn-secondary{ color:#fff; }

/* ===== Footer ===== */
footer{ padding:48px 24px 36px; border-top:1px solid var(--hairline); }
.footer-inner{ max-width:1120px; margin:0 auto; display:grid; grid-template-columns:2fr 1fr 1fr; gap:32px; }
.footer-brand img{ height:26px; margin-bottom:12px; }
.footer-brand p{ font-size:13px; color:var(--gray-light); line-height:1.6; max-width:280px; }
.footer-col h4{ font-size:13px; text-transform:uppercase; letter-spacing:.06em; color:var(--gray-light); margin-bottom:12px; }
.footer-col a, .footer-col span{ display:block; font-size:14px; color:var(--gray); text-decoration:none; margin-bottom:8px; }
.footer-col a:hover{ color:var(--navy); }
.footer-bottom{
  max-width:1120px; margin:32px auto 0; padding-top:24px; border-top:1px solid var(--hairline);
  font-size:12px; color:var(--gray-light);
}
@media (max-width:760px){ .footer-inner{ grid-template-columns:1fr; gap:28px; } }

/* ===== Reveal-on-scroll (driven by main.js) ===== */
.reveal{ transform:translateY(24px); transition:opacity .8s cubic-bezier(.22,1,.36,1), transform .8s cubic-bezier(.22,1,.36,1); }
.js .reveal{ opacity:0; }
.reveal.reveal-visible{ opacity:1; transform:translateY(0); }

/* ===== Hero fade-up (first paint, not scroll-triggered) ===== */
.fade-up{ opacity:0; animation:reveal .9s cubic-bezier(.22,1,.36,1) forwards; }
.fade-up.d1{ animation-delay:.05s; }
.fade-up.d2{ animation-delay:.2s; }
.fade-up.d3{ animation-delay:.35s; }
.fade-up.d4{ animation-delay:.5s; }
.fade-up.d5{ animation-delay:.65s; }
@keyframes reveal{ from{ opacity:0; transform:translateY(16px); } to{ opacity:1; transform:translateY(0); } }

@media (prefers-reduced-motion: reduce){
  .fade-up, .reveal{ animation:none !important; transition:none !important; opacity:1 !important; transform:none !important; }
}

@media (max-width:480px){
  .hero{ padding:120px 20px 72px; }
  .page-header{ padding:120px 20px 48px; }
  .cta-row{ flex-direction:column; align-items:center; }
}
