/* ===========================================================
   Wygant Ltd — stylesheet
   A ledger / schedule-of-services aesthetic for an independent
   escrow, corporate trust & agency services firm.
   =========================================================== */

:root {
  /* Colour */
  --ink:        #0F241D;   /* deep pine-ink — header, footer, dark bands */
  --ink-soft:   #1B362C;
  --paper:      #F7F5EE;   /* warm ivory page background */
  --paper-dim:  #EFEAdd;
  --line:       #DAD3BE;   /* hairline rule on paper */
  --line-dark:  rgba(247,245,238,0.18);
  --text:       #1B221E;
  --text-soft:  #4B564E;
  --text-on-ink: #EDEAE0;
  --text-on-ink-soft: #AFC2B7;
  --green:      #2F7A5C;   /* primary accent, from brand mark */
  --green-deep: #1F5B43;
  --green-pale: #DCEBE2;
  --gold:       #B08D4F;   /* secondary accent for small marks/numerals */

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

  --container: 1180px;
  --radius: 3px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }

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

body {
  margin: 0;
  font-family: var(--sans);
  color: var(--text);
  background: var(--paper);
  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(--serif);
  font-weight: 600;
  line-height: 1.15;
  margin: 0 0 0.5em;
  color: var(--ink);
}

h1 { font-size: clamp(2.1rem, 4.4vw, 3.4rem); font-weight: 500; }
h2 { font-size: clamp(1.6rem, 3vw, 2.3rem); }
h3 { font-size: 1.25rem; }

p { margin: 0 0 1em; max-width: 68ch; }
p.lede { font-size: 1.15rem; color: var(--text-soft); }

.container {
  width: 100%;
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 24px;
}

.visually-hidden {
  position: absolute; width: 1px; height: 1px; overflow: hidden;
  clip: rect(0,0,0,0); white-space: nowrap;
}

a:focus-visible, button:focus-visible, input:focus-visible, textarea:focus-visible, summary:focus-visible {
  outline: 2px solid var(--green);
  outline-offset: 2px;
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--sans);
  font-size: 0.95rem;
  font-weight: 600;
  padding: 13px 26px;
  border-radius: var(--radius);
  border: 1px solid transparent;
  cursor: pointer;
  transition: background-color .18s ease, color .18s ease, border-color .18s ease;
}
.btn-primary { background: var(--green); color: #fff; }
.btn-primary:hover { background: var(--green-deep); }
.btn-ghost { background: transparent; color: var(--text-on-ink); border-color: rgba(237,234,224,0.4); }
.btn-ghost:hover { border-color: var(--text-on-ink); background: rgba(237,234,224,0.08); }
.btn-outline { background: transparent; color: var(--green-deep); border-color: var(--green-deep); }
.btn-outline:hover { background: var(--green-deep); color: #fff; }

/* ---------- Header ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--paper);
  border-bottom: 1px solid var(--line);
}
.site-header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 84px;
}
.brand { display: flex; align-items: center; gap: 10px; }
.brand img { height: 40px; width: auto; }

.main-nav { display: flex; align-items: center; gap: 36px; }
.main-nav ul { list-style: none; display: flex; gap: 30px; margin: 0; padding: 0; }
.main-nav ul a {
  font-size: 0.96rem;
  color: var(--text-soft);
  padding: 6px 0;
  border-bottom: 2px solid transparent;
}
.main-nav ul a:hover, .main-nav ul a[aria-current="page"] {
  color: var(--ink);
  border-bottom-color: var(--green);
}
.header-actions { display: flex; align-items: center; gap: 14px; }
.header-actions .btn { padding: 10px 20px; font-size: 0.88rem; }

.nav-toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 8px;
  flex-direction: column;
  gap: 5px;
}
.nav-toggle span {
  display: block; width: 24px; height: 2px; background: var(--ink);
  transition: transform .2s ease, opacity .2s 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); }

/* ---------- Hero ---------- */
.hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  background: linear-gradient(155deg, var(--ink) 0%, var(--ink-soft) 62%, #234436 100%);
  color: var(--text-on-ink);
  overflow: hidden;
}
.hero.compact { min-height: auto; }
.hero::before {
  content: "";
  position: absolute; inset: 0;
  background-image: var(--hero-image, none);
  background-size: cover;
  background-position: center;
  opacity: 0.16;
  mix-blend-mode: luminosity;
  pointer-events: none;
}
.hero::after {
  content: "";
  position: absolute; inset: 0;
  background: repeating-linear-gradient(
    100deg,
    transparent 0 120px,
    rgba(237,234,224,0.035) 120px 121px
  );
  pointer-events: none;
}
.hero-inner {
  position: relative;
  z-index: 1;
  padding: 88px 24px 68px;
  display: grid;
  gap: 28px;
}
.hero.compact .hero-inner { padding: 62px 24px 46px; }
.hero-eyebrow {
  font-family: var(--serif);
  font-style: italic;
  font-size: 1.05rem;
  color: var(--text-on-ink-soft);
}
.hero h1 { color: #fff; max-width: 24ch; }
.hero p.lede { color: var(--text-on-ink-soft); max-width: 78ch; }
.hero-cta { display: flex; gap: 16px; flex-wrap: wrap; margin-top: 6px; }

/* Ledger fact strip */
.factstrip {
  position: relative;
  background: var(--ink);
  border-top: 1px solid var(--line-dark);
}
.factstrip .container {
  display: flex;
  flex-wrap: wrap;
  gap: 0;
}
.factstrip dl {
  flex: 1 1 200px;
  margin: 0;
  padding: 20px 26px;
  border-right: 1px solid var(--line-dark);
}
.factstrip dl:last-child { border-right: none; }
.factstrip dt {
  font-size: 0.74rem;
  letter-spacing: 0.02em;
  color: var(--text-on-ink-soft);
  margin-bottom: 4px;
}
.factstrip dd {
  margin: 0;
  font-family: var(--serif);
  font-size: 1.08rem;
  color: #fff;
}

/* ---------- Sections ---------- */
.section { padding: 76px 0; }
.section + .section { border-top: 1px solid var(--line); }
.section-dark {
  background: var(--ink);
  color: var(--text-on-ink);
}
.section-dark h2, .section-dark h3 { color: #fff; }
.section-dark p { color: var(--text-on-ink-soft); }
.section-tint { background: var(--paper-dim); }

.section-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  gap: 24px;
  margin-bottom: 40px;
  flex-wrap: wrap;
}
.section-head p { margin: 0; }
.kicker {
  font-family: var(--serif);
  font-style: italic;
  color: var(--green-deep);
  font-size: 1rem;
  display: block;
  margin-bottom: 6px;
}
.section-dark .kicker { color: #9FD3B9; }

/* ---------- Table-of-contents style service list ---------- */
.toc-list { border-top: 1px solid var(--line); }
.toc-item {
  display: grid;
  grid-template-columns: 40px 1fr auto;
  gap: 20px;
  align-items: start;
  padding: 28px 0;
  border-bottom: 1px solid var(--line);
  text-decoration: none;
}
.toc-item .mark {
  font-family: var(--serif);
  font-style: italic;
  color: var(--gold);
  font-size: 1.1rem;
  padding-top: 4px;
}
.toc-item h3 { margin-bottom: 6px; }
.toc-item p { margin: 0; color: var(--text-soft); max-width: 60ch; }
.toc-item .tags { margin-top: 8px; font-size: 0.85rem; color: var(--text-soft); }
.toc-item .goto {
  align-self: center;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--green-deep);
  white-space: nowrap;
  padding-top: 4px;
}
a.toc-item:hover { background: rgba(47,122,92,0.045); }
a.toc-item:hover h3 { color: var(--green-deep); }

/* Plain (non-link) detail list used within service pages */
.clause { padding: 30px 0; border-bottom: 1px solid var(--line); }
.clause:first-child { padding-top: 0; }
.clause:last-child { border-bottom: none; }
.clause h3 { margin-bottom: 10px; }
.clause ul { margin: 14px 0 0; padding-left: 0; list-style: none; }
.clause ul li {
  padding: 9px 0 9px 22px;
  border-top: 1px solid var(--line);
  position: relative;
  color: var(--text-soft);
}
.clause ul li:first-child { border-top: none; }
.clause ul li::before {
  content: "";
  position: absolute; left: 2px; top: 18px;
  width: 6px; height: 6px;
  background: var(--green);
  border-radius: 50%;
}
.clause ul li strong { color: var(--text); }

/* ---------- Icon grid (why us / values) ---------- */
.icon-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1px;
  background: var(--line);
  border: 1px solid var(--line);
}
.icon-card {
  background: var(--paper);
  padding: 30px 28px;
}
.section-dark .icon-card { background: var(--ink); }
.icon-card .ic {
  width: 34px; height: 34px;
  color: var(--green);
  margin-bottom: 16px;
}
.section-dark .icon-card .ic { color: #9FD3B9; }
.icon-card h3 { font-size: 1.08rem; margin-bottom: 8px; }
.icon-card p { font-size: 0.94rem; margin: 0; color: var(--text-soft); }

/* ---------- Process steps ---------- */
.process {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 28px;
}
.process-step { position: relative; padding-top: 46px; }
.process-step .num {
  font-family: var(--serif);
  font-style: italic;
  font-size: 1.9rem;
  color: var(--green);
  position: absolute;
  top: -4px; left: 0;
}
.process-step h3 { font-size: 1.05rem; margin-bottom: 8px; }
.process-step p { font-size: 0.93rem; color: var(--text-soft); margin: 0; }
.process-step:not(:last-child)::after {
  content: "";
  position: absolute;
  top: 4px; right: -14px;
  width: 1px; height: 40px;
  background: var(--line);
  display: none;
}
@media (min-width: 861px) {
  .process-step:not(:last-child)::after { display: block; }
}

/* ---------- Two column split ---------- */
.split {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 56px;
  align-items: start;
}
.split img { border: 1px solid var(--line); }
.split.reverse { grid-template-columns: 0.9fr 1.1fr; }
.split.reverse .figure { order: 2; }

.sidebar-card {
  border: 1px solid var(--line);
  padding: 26px;
  background: var(--paper);
}
.sidebar-card + .sidebar-card { margin-top: 20px; }
.sidebar-card h4 {
  font-family: var(--sans);
  font-weight: 700;
  font-size: 0.82rem;
  letter-spacing: 0.03em;
  color: var(--text-soft);
  margin-bottom: 14px;
}
.sidebar-card dl { margin: 0; }
.sidebar-card dl div { display: flex; justify-content: space-between; gap: 12px; padding: 9px 0; border-top: 1px solid var(--line); }
.sidebar-card dl div:first-child { border-top: none; }
.sidebar-card dt { color: var(--text-soft); font-size: 0.92rem; }
.sidebar-card dd { margin: 0; font-weight: 600; text-align: right; font-size: 0.92rem; }

/* ---------- CTA band ---------- */
.cta-band {
  background: var(--ink);
  color: var(--text-on-ink);
  padding: 60px 0;
  text-align: center;
}
.cta-band h2 { color: #fff; }
.cta-band p { color: var(--text-on-ink-soft); margin-left: auto; margin-right: auto; }
.cta-band .hero-cta { justify-content: center; margin-top: 22px; }

/* ---------- FAQ ---------- */
.faq { border-top: 1px solid var(--line); }
.faq details {
  border-bottom: 1px solid var(--line);
  padding: 20px 0;
}
.faq summary {
  cursor: pointer;
  list-style: none;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 20px;
  font-family: var(--serif);
  font-size: 1.12rem;
  color: var(--ink);
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary .plus {
  flex-shrink: 0;
  width: 22px; height: 22px;
  position: relative;
}
.faq summary .plus::before, .faq summary .plus::after {
  content: "";
  position: absolute; background: var(--green-deep);
  transition: transform .2s ease;
}
.faq summary .plus::before { width: 100%; height: 2px; top: 10px; left: 0; }
.faq summary .plus::after { width: 2px; height: 100%; top: 0; left: 10px; }
.faq details[open] summary .plus::after { transform: scaleY(0); }
.faq .faq-body { padding-top: 14px; color: var(--text-soft); max-width: 70ch; }

/* ---------- Forms ---------- */
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }
.field { display: flex; flex-direction: column; gap: 6px; margin-bottom: 20px; }
.field.full { grid-column: 1 / -1; }
.field label { font-size: 0.85rem; font-weight: 600; color: var(--text); }
.field input, .field textarea, .field select {
  font-family: var(--sans);
  font-size: 1rem;
  padding: 12px 14px;
  border: 1px solid var(--line);
  background: #fff;
  border-radius: var(--radius);
  color: var(--text);
}
.field input:focus, .field textarea:focus { border-color: var(--green); }
.form-note { font-size: 0.85rem; color: var(--text-soft); margin-top: -4px; }
#form-status { margin-top: 14px; font-size: 0.92rem; }
#form-status[data-state="success"] { color: var(--green-deep); }
#form-status[data-state="error"] { color: #A5402F; }

/* ---------- Contact details list ---------- */
.contact-list { list-style: none; margin: 0; padding: 0; }
.contact-list li {
  display: flex; gap: 14px; align-items: flex-start;
  padding: 16px 0; border-top: 1px solid var(--line);
}
.contact-list li:first-child { border-top: none; }
.contact-list .ic { width: 20px; height: 20px; color: var(--green); flex-shrink: 0; margin-top: 3px; }
.contact-list a:hover { color: var(--green-deep); }

.map-wrap { border-top: 1px solid var(--line); }
.map-wrap iframe { width: 100%; height: 460px; border: 0; display: block; filter: grayscale(0.15) contrast(1.02); }

/* ---------- Footer ---------- */
.site-footer { background: var(--ink); color: var(--text-on-ink-soft); }
.footer-top {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1.2fr;
  gap: 40px;
  padding: 60px 0 40px;
  border-bottom: 1px solid var(--line-dark);
}
.footer-brand img { height: 45px; margin-bottom: 16px; }
.footer-brand p { font-size: 0.92rem; max-width: 32ch; }
.site-footer h4 {
  font-family: var(--sans); font-weight: 700; font-size: 0.82rem;
  letter-spacing: 0.03em; color: var(--text-on-ink); margin-bottom: 16px;
}
.site-footer ul { list-style: none; margin: 0; padding: 0; }
.site-footer ul li { margin-bottom: 10px; font-size: 0.92rem; }
.site-footer ul a:hover { color: #fff; }
.footer-legal {
  display: flex; justify-content: space-between; align-items: center;
  padding: 22px 0; font-size: 0.82rem; flex-wrap: wrap; gap: 10px;
}
.footer-legal .disclaimer { max-width: 62ch; color: rgba(175,194,183,0.75); }

/* subscribe */
.subscribe-row { display: flex; gap: 0; margin-top: 4px; }
.subscribe-row input {
  flex: 1; padding: 11px 14px; border: 1px solid rgba(175,194,183,0.35);
  background: transparent; color: #fff; border-radius: var(--radius) 0 0 var(--radius);
  font-family: var(--sans);
}
.subscribe-row input::placeholder { color: rgba(175,194,183,0.65); }
.subscribe-row button {
  border-radius: 0 var(--radius) var(--radius) 0;
  padding: 11px 18px;
}

/* ---------- Utility ---------- */
.mt-0 { margin-top: 0; }
.stack { display: grid; gap: 18px; }

/* =========================================================
   Responsive
   ========================================================= */
@media (max-width: 980px) {
  .split { grid-template-columns: 1fr; }
  .split.reverse .figure { order: 0; }
  .footer-top { grid-template-columns: 1fr 1fr; }
  .process { grid-template-columns: 1fr 1fr; }
  .icon-grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 860px) {
  .main-nav { display: none; }
  .nav-toggle { display: flex; }
  .header-actions .btn-outline { display: none; }

  .site-header.nav-open .main-nav {
    display: flex;
    position: absolute;
    top: 84px; left: 0; right: 0;
    background: var(--paper);
    border-bottom: 1px solid var(--line);
    flex-direction: column;
    align-items: stretch;
    padding: 8px 24px 24px;
    gap: 0;
  }
  .site-header.nav-open .main-nav ul {
    flex-direction: column; gap: 0; width: 100%;
  }
  .site-header.nav-open .main-nav ul li { border-top: 1px solid var(--line); }
  .site-header.nav-open .main-nav ul li:first-child { border-top: none; }
  .site-header.nav-open .main-nav a { display: block; padding: 14px 0; }
  .site-header.nav-open .main-nav .header-actions {
    padding: 14px 0 4px;
    flex-direction: column;
    align-items: stretch;
    gap: 12px;
  }
  .site-header.nav-open .main-nav .header-actions .btn { width: 100%; justify-content: center; }
  .site-header.nav-open .main-nav .header-actions .btn-outline { display: inline-flex; }

  .factstrip dl { flex: 1 1 45%; border-right: none; border-bottom: 1px solid var(--line-dark); }
  .toc-item { grid-template-columns: 28px 1fr; }
  .toc-item .goto { grid-column: 2; padding-top: 0; }
  .form-grid { grid-template-columns: 1fr; }
  .process { grid-template-columns: 1fr; }
}

@media (max-width: 620px) {
  .section { padding: 54px 0; }
  .icon-grid { grid-template-columns: 1fr; }
  .footer-top { grid-template-columns: 1fr; padding: 44px 0 30px; }
  .footer-legal { flex-direction: column; align-items: flex-start; }
  .hero-inner, .hero.compact .hero-inner { padding: 56px 24px 42px; }
  .subscribe-row { flex-direction: column; gap: 10px; }
  .subscribe-row input, .subscribe-row button { border-radius: var(--radius); }
  h1 { font-size: 2rem; }
}
