/* AB Associates — informational chambers website */
:root {
  --ink: #1c1915;
  --ink-soft: #3a372f;
  --muted: #5e594f;
  --navy: #1b2a41;
  --navy-2: #24364f;
  --cream: #f4efe6;
  --paper: #fbf8f2;
  --white: #fffcf8;
  --rule: #c4b08a;
  --rule-soft: #e4d9c4;
  --accent: #0c6eab;
  --accent-ink: #0a5a8c;
  --whatsapp: #0f7a43;
  --ph-bg: #f3ead3;
  --ph-ink: #5c4818;
  --serif: "Cormorant Garamond", "Palatino Linotype", Palatino, Georgia, serif;
  --sans: "Source Sans 3", "Segoe UI", system-ui, sans-serif;
  --measure: 72rem;
  --narrow: 44rem;
  --radius: 10px;
}
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
html:focus-within { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--sans);
  font-size: 1.0625rem;
  line-height: 1.65;
  color: var(--ink);
  background: var(--cream);
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; height: auto; }
a { color: var(--accent-ink); text-underline-offset: 0.18em; }
a:hover { color: var(--navy); }
a:focus-visible, button:focus-visible, summary:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
}
.skip {
  position: absolute;
  left: 0.75rem;
  top: -3rem;
  background: var(--navy);
  color: #fff;
  padding: 0.5rem 0.8rem;
  z-index: 2000;
}
.skip:focus { top: 0.75rem; }
.wrap { width: min(var(--measure), calc(100% - 2.4rem)); margin-inline: auto; }
.narrow { width: min(var(--narrow), 100%); }

/* Header */
.site-header {
  background: var(--white);
  border-bottom: 1px solid var(--rule-soft);
  position: sticky;
  top: 0;
  z-index: 40;
}
.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.7rem 0;
}
.brand {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  text-decoration: none;
  color: var(--navy);
  min-width: 0;
}
.brand img { height: 46px; width: auto; display: block; }
.brand-text { display: flex; flex-direction: column; line-height: 1.15; }
.brand-name {
  font-family: var(--serif);
  font-weight: 600;
  font-size: 1.35rem;
  letter-spacing: 0.02em;
}
.brand-sub {
  font-size: 0.72rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--muted);
  font-weight: 500;
}
.nav-toggle {
  display: none;
  background: transparent;
  border: 1px solid var(--rule-soft);
  border-radius: 6px;
  padding: 0.45rem 0.6rem;
  font: inherit;
  font-size: 0.85rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--navy);
  cursor: pointer;
}
.site-nav ul {
  display: flex;
  gap: 0.15rem 1.15rem;
  list-style: none;
  margin: 0;
  padding: 0;
  flex-wrap: wrap;
  justify-content: flex-end;
}
.site-nav a {
  color: var(--ink-soft);
  text-decoration: none;
  font-weight: 500;
  font-size: 0.95rem;
  padding: 0.25rem 0;
  border-bottom: 1px solid transparent;
}
.site-nav a:hover, .site-nav a[aria-current="page"] {
  color: var(--navy);
  border-bottom-color: var(--rule);
}

/* Hero / page heads */
.hero, .page-head {
  padding: 3.4rem 0 2.6rem;
  background:
    linear-gradient(180deg, var(--white) 0%, var(--cream) 100%);
  border-bottom: 1px solid var(--rule-soft);
}
.eyebrow {
  margin: 0 0 0.7rem;
  font-size: 0.78rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  font-weight: 600;
  color: var(--muted);
}
.hero h1, .page-head h1 {
  font-family: var(--serif);
  font-weight: 600;
  font-size: clamp(2.15rem, 5vw, 3.4rem);
  line-height: 1.12;
  color: var(--navy);
  margin: 0 0 1rem;
  letter-spacing: -0.01em;
}
.lede {
  font-size: 1.15rem;
  color: var(--ink-soft);
  max-width: 40rem;
  margin: 0;
}
.rule {
  width: 4rem;
  height: 1px;
  background: var(--rule);
  border: 0;
  margin: 1.2rem 0 1.3rem;
}

/* Layout */
main { display: block; }
.section { padding: 3rem 0; }
.section + .section { padding-top: 0; }
.panel {
  background: var(--white);
  border: 1px solid var(--rule-soft);
  border-radius: var(--radius);
  padding: 1.5rem 1.6rem;
}
h2 {
  font-family: var(--serif);
  font-weight: 600;
  font-size: clamp(1.6rem, 3vw, 2.05rem);
  color: var(--navy);
  margin: 0 0 0.8rem;
  line-height: 1.2;
}
h3 {
  font-family: var(--serif);
  font-weight: 600;
  font-size: 1.35rem;
  color: var(--navy);
  margin: 1.6rem 0 0.45rem;
}
p { margin: 0 0 1rem; }
p:last-child { margin-bottom: 0; }
.prose { max-width: var(--narrow); }
.prose ul, .prose ol { margin: 0 0 1rem; padding-left: 1.2rem; }
.prose li { margin: 0.25rem 0; }
.muted { color: var(--muted); }
.small { font-size: 0.92rem; }

/* Practice grid */
.cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(15.5rem, 1fr));
  gap: 0.9rem;
  margin-top: 1.4rem;
}
.card {
  background: var(--white);
  border: 1px solid var(--rule-soft);
  border-radius: var(--radius);
  padding: 1.15rem 1.2rem 1.25rem;
  text-decoration: none;
  color: inherit;
  display: block;
  transition: border-color .15s ease, transform .15s ease;
}
a.card:hover { border-color: var(--rule); transform: translateY(-1px); color: inherit; }
.card h3 { margin: 0 0 0.35rem; font-size: 1.28rem; }
.card p { color: var(--muted); font-size: 0.95rem; }

/* Particulars / advocates */
.particulars, .advocates {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(16.5rem, 1fr));
  gap: 1rem;
  margin-top: 1.3rem;
}
.box h3 { margin-top: 0; }
.advocates h2 { margin-top: 0; font-size: 1.45rem; }
dl.facts { margin: 0; }
dl.facts div { display: grid; grid-template-columns: 11.2rem 1fr; gap: 0.5rem 1rem; padding: 0.45rem 0; border-bottom: 1px solid var(--rule-soft); }
dl.facts dt { color: var(--muted); font-size: 0.88rem; font-weight: 500; }
dl.facts dd { margin: 0; }
@media (max-width: 640px) {
  dl.facts div { grid-template-columns: 1fr; gap: 0.15rem; }
}

/* Placeholders the user must fill */
.ph {
  display: inline;
  background: var(--ph-bg);
  color: var(--ph-ink);
  border-bottom: 1px dashed #b8984a;
  padding: 0 0.15em;
  font-style: italic;
  font-weight: 500;
}

/* Contact */
.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1.15fr;
  gap: 1.4rem;
  align-items: start;
}
.map-wrap {
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid var(--rule-soft);
  background: var(--white);
  min-height: 22rem;
}
.map-wrap iframe { width: 100%; height: 22rem; border: 0; display: block; }
.contact-list { list-style: none; margin: 0; padding: 0; }
.contact-list li { margin: 0 0 1rem; }
.contact-list span.label {
  display: block;
  font-size: 0.75rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--muted);
  font-weight: 600;
  margin-bottom: 0.15rem;
}
.btn-row { display: flex; flex-wrap: wrap; gap: 0.6rem; margin-top: 1.1rem; }
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  padding: 0.62rem 1rem;
  border-radius: 6px;
  text-decoration: none;
  font-weight: 600;
  font-size: 0.95rem;
  border: 1px solid transparent;
}
.btn-navy { background: var(--navy); color: #fff; }
.btn-navy:hover { background: var(--navy-2); color: #fff; }
.btn-wa { background: var(--whatsapp); color: #fff; }
.btn-wa:hover { color: #fff; filter: brightness(1.05); }
.btn-ghost { background: transparent; color: var(--navy); border-color: var(--rule); }
.btn-ghost:hover { background: var(--white); color: var(--navy); }

/* Practice page sections */
.toc { display: flex; flex-wrap: wrap; gap: 0.4rem 0.9rem; margin: 1rem 0 0; padding: 0; list-style: none; }
.toc a { font-size: 0.95rem; }
.pa { padding: 1.6rem 0; border-top: 1px solid var(--rule-soft); }
.pa:first-of-type { border-top: 0; }
.pa h2 { margin-top: 0; }

/* Footer */
.site-footer {
  background: var(--navy);
  color: #e8e2d6;
  padding: 2.4rem 0 1.6rem;
  margin-top: 2rem;
}
.site-footer a { color: #f0e7d4; }
.footer-grid {
  display: grid;
  grid-template-columns: 1.3fr 1fr 1fr;
  gap: 1.6rem;
  margin-bottom: 1.6rem;
}
.site-footer h2 {
  color: #f4efe6;
  font-size: 1.15rem;
  margin-bottom: 0.5rem;
}
.site-footer ul { list-style: none; margin: 0; padding: 0; }
.site-footer li { margin: 0.25rem 0; }
.footer-note {
  border-top: 1px solid rgba(196,176,138,.35);
  padding-top: 1rem;
  font-size: 0.88rem;
  color: #cfc6b6;
}
.footer-note p { margin: 0 0 0.4rem; }
.site-footer .footer-label { display: inline-block; font-size: 0.82rem; letter-spacing: 0.04em; text-transform: uppercase; color: #cfc6b6; margin-bottom: 0.15rem; }
.site-footer p + p { margin-top: 0.85rem; }

/* Disclaimer overlay */
.overlay {
  position: fixed;
  inset: 0;
  background: rgba(16, 18, 24, 0.62);
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1.2rem;
}
.overlay[hidden] { display: none !important; }
.overlay-card {
  background: var(--white);
  color: var(--ink);
  max-width: 36rem;
  width: 100%;
  max-height: min(90vh, 44rem);
  overflow: auto;
  border-radius: 12px;
  padding: 1.6rem 1.6rem 1.4rem;
  box-shadow: 0 20px 50px rgba(0,0,0,.28);
  border-top: 3px solid var(--rule);
}
.overlay-card h2 { font-size: 1.7rem; margin-bottom: 0.7rem; }
.overlay-actions { display: flex; flex-wrap: wrap; gap: 0.6rem; margin-top: 1.2rem; }
body.no-scroll { overflow: hidden; }

/* Legal pages */
.legal h2 { margin-top: 1.8rem; }

@media (max-width: 860px) {
  .contact-grid, .footer-grid { grid-template-columns: 1fr; }
  .nav-toggle { display: inline-flex; }
  .site-nav {
    display: none;
    position: absolute;
    left: 0; right: 0;
    top: 100%;
    background: var(--white);
    border-bottom: 1px solid var(--rule-soft);
    padding: 0.4rem 1.2rem 1rem;
  }
  .site-nav.is-open { display: block; }
  .site-nav ul { flex-direction: column; gap: 0.4rem; }
  .header-inner { position: relative; }
  .brand img { height: 40px; }
}
@media (max-width: 480px) {
  .hero, .page-head { padding: 2.3rem 0 1.8rem; }
  .overlay-card { padding: 1.15rem 1.05rem 1.1rem; }
  .overlay-card h2 { font-size: 1.35rem; margin-bottom: 0.45rem; }
  .overlay-card p { margin-bottom: 0.7rem; }
  .brand-name { font-size: 1.15rem; }
  .brand-sub { letter-spacing: 0.08em; }
}
@media (max-width: 640px) {
  .overlay {
    align-items: flex-start;
    padding: 4.6rem 0.7rem 1.2rem;
    overflow: auto;
  }
  .overlay-card { max-height: none; }
}
