:root {
  --ink: #0e0e0e;
  --muted: #666;
  --paper: #fff;
  --rule: #e6e6e6;
  --section-gap: 40px; /* vertical space between sections */
}

/* Base */
* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
  font-size: 1.0625rem; /* ~17px */
  line-height: 1.5;
  font-family: -apple-system, BlinkMacSystemFont, "Helvetica Neue", Helvetica, "Segoe UI", Roboto, Arial, sans-serif;
  color: var(--ink);
  background: var(--paper);
}

/* Layout container */
.wrap { max-width: 1080px; margin: 0 auto; padding: 0 16px; }
@media (max-width: 768px) {
  .wrap {
    /* more side padding on phones for comfortable reading */
    padding-left: clamp(20px, 6vw, 28px);
    padding-right: clamp(20px, 6vw, 28px);
  }
}

.section { padding: var(--section-gap) 0; }
.section--center { text-align: center; }
.section--rule { border-top: 0; }

/* Type */
h1, h2, h3 { margin: 0 0 1rem; line-height: 1.2; }
h1 { font-size: 2.5rem; font-weight: 700; }
h2 { font-size: 1.75rem; font-weight: 700; }
h3 { font-size: 1.375rem; font-weight: 600; }
p { margin: 0 0 .75rem; }

@media (max-width: 768px) {
  h1 { font-size: 2.125rem; }
  h2 { font-size: 1.5rem; }
  h3 { font-size: 1.25rem; }
}

/* Links */
a { color: inherit; }
a:hover { text-decoration: underline; }

/* Buttons */
.btn {
  display: inline-block;
  padding: .6rem 1rem;
  border-radius: 999px;
  background: #111;
  color: #fff;
  text-decoration: none;
  font-weight: 600;
  letter-spacing: .2px;
  transition: transform .12s ease, box-shadow .12s ease, filter .12s ease;
}
.btn:hover {
  filter: brightness(.95);
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0,0,0,.08);
}

/* Skip link (keyboard users) */
.skip-link { position: absolute; left: -9999px; }
.skip-link:focus {
  left: 8px; top: 8px;
  background: #fff;
  padding: .5rem 1rem;
  border: 1px solid var(--rule);
  border-radius: 6px;
}

/* Hero button row: centered as a group with responsive spacing */
.btn-row {
  display: flex;
  justify-content: center;
  flex-wrap: wrap; /* allows stacking on small screens */
  gap: 1rem; /* default gap for mobile */
}

/* On wider screens, scale the gap up smoothly */
@media (min-width: 768px) {
  .btn-row {
    gap: clamp(2.5rem, 6vw, 5rem); /* roomy on desktop */
  }
}

/* Extra breathing room above buttons in hero */
  .hero .btn-row {
    margin-top: 1.5rem;
}

/* Header & nav */
.header { border-bottom: 0; background: var(--paper); }
.nav {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: .8rem 0;
}
.brand { font-weight: 400; letter-spacing: .2px; color: var(--ink); font-size: 1.2rem; }
.brand strong { font-weight: 700; }
.nav__menu {
  list-style: none;
  margin-left: auto;
  display: flex;
  gap: .9rem;
  align-items: center;
  padding: 0;
}

/* Mobile nav toggle */
.nav__toggle {
  background: none;
  border: 0;
  padding: 0;
  width: 44px; height: 44px;
  display: none; /* shown only on mobile */
  cursor: pointer;
}
.nav__toggle .hamburger,
.nav__toggle .hamburger::before,
.nav__toggle .hamburger::after {
  content: "";
  display: block;
  width: 24px; height: 2px;
  background: var(--ink);
  border-radius: 2px;
  margin: 0 auto;
  position: relative;
}
.nav__toggle .hamburger::before { position: absolute; top: -7px; }
.nav__toggle .hamburger::after  { position: absolute; top:  7px; }

@media (max-width: 800px){
  .nav__toggle { display: inline-block; margin-left: auto; }
  .nav__menu {
    position: absolute;
    right: 16px; top: 58px;
    background: #fff;
    padding: 10px 12px;
    border: 1px solid var(--rule);
    border-radius: 10px;
    display: none;
    flex-direction: column;
    gap: .5rem;
    box-shadow: 0 6px 18px rgba(0,0,0,.08);
  }
  .nav__menu.open { display: flex; }
}

/* Hero */
.hero { display: grid; gap: 20px; align-items: center; }
.hero__media { display: grid; place-items: center; }
.hero__copy {
  text-align: center;
  justify-self: center;
  max-width: 640px;
  margin: 0 auto;
}
.hero__media img { max-width: 100%; height: auto; display: block; }
@media (min-width: 900px){
  .hero { grid-template-columns: 1fr 1fr; }
}

/* Services */
.cards.cards--fixed {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  justify-content: center;
}
.cards.cards--fixed .card {
  text-align: center;
  border: 1px solid var(--rule);
  border-radius: 10px;
  padding: 16px;
  max-width: 320px;
  background: #fff;
  transition: transform .12s ease, box-shadow .12s ease;
  flex: 1 1 300px;
}
.cards.cards--fixed .card:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 24px rgba(0,0,0,.06);
}

/* About */
.about--grid {
  display: flex;
  flex-direction: column;
  align-items: center;
}

/* Remove default figure margins so h2 → content gap matches other sections */
.about__pic {
  margin: 0;
}

.about__pic .headshot {
  max-width: 280px;
  height: auto;
  border-radius: 8px;
}

.caption {
  margin-top: 4px; /* tighter gap between photo and caption */
  font-size: 0.9rem;
  color: var(--muted);
  text-align: center;
}

.about__copy {
  max-width: 700px;  /* keeps line length readable on desktop */
  text-align: left;
  margin-top: 16px;   /* space between caption and body text */
}

.ticks {
  padding-left: 3rem;
}

/* Contact */
#contact p { margin: .3rem 0; }

/* Footer */
.footer { border-top: 1px solid var(--rule); color: #555; }
.footer .wrap { padding: 14px 16px; text-align: center; }

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
  .btn,
  .cards.cards--fixed .card { transition: none !important; }
  .cards.cards--fixed .card:hover {
    transform: none !important;
    box-shadow: none !important;
  }
}
/* Extra padding on mobile (overrides everything above) */
@media (max-width: 768px) {
  .wrap {
    padding-left: max(24px, env(safe-area-inset-left)) !important;
    padding-right: max(24px, env(safe-area-inset-right)) !important;
  }
}
