/* Base styles. All colors and fonts come from tokens.css. */

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  font-family: var(--font-body);
  font-size: var(--step-0);
  line-height: var(--leading-body);
  color: var(--color-text);
  background: var(--color-background);
}

h1,
h2,
h3,
h4 {
  font-family: var(--font-heading);
  font-weight: 800;
  line-height: var(--leading-heading);
  letter-spacing: -0.01em;
  margin: 0 0 0.5em;
}

h1 { font-size: var(--step-4); letter-spacing: -0.02em; }
h2 { font-size: var(--step-3); }
h3 { font-size: var(--step-1); font-weight: 700; }

@media (min-width: 48rem) {
  h1 { font-size: var(--step-5); }
}

p,
ul,
ol {
  margin: 0 0 1em;
}

img {
  max-width: 100%;
  height: auto;
}

a {
  color: var(--color-primary);
  text-decoration: underline;
  text-underline-offset: 0.15em;
}

a:hover {
  text-decoration-thickness: 2px;
}

:focus-visible {
  outline: 2px solid var(--color-primary);
  outline-offset: 3px;
}

strong {
  font-weight: 600;
}

/* Marker-style highlight: dark text on yellow only. */
.highlight {
  background: var(--color-accent);
  color: var(--color-text);
  padding: 0 0.15em;
  box-decoration-break: clone;
  -webkit-box-decoration-break: clone;
}

.muted {
  color: var(--color-muted);
}

/* Layout */
.container {
  width: 100%;
  max-width: 72rem;
  margin: 0 auto;
  padding: 0 1rem;
}

@media (min-width: 48rem) {
  .container { padding: 0 2rem; }
}

.prose {
  max-width: 40rem;
}

/* Buttons: one primary style, used for the page's one primary CTA. */
.button {
  display: inline-block;
  min-height: 44px;
  padding: 0.7rem 1.25rem;
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: var(--step-0);
  line-height: 1.2;
  color: var(--color-on-primary);
  background: var(--color-primary);
  border: 2px solid var(--color-primary);
  border-radius: 4px;
  text-decoration: none;
  text-align: center;
}

.button:hover {
  text-decoration: underline;
}

/* Skip link */
.skip-link {
  position: absolute;
  left: 1rem;
  top: -100px;
  z-index: 100;
  padding: 0.5rem 1rem;
  color: var(--color-on-primary);
  background: var(--color-primary);
}

.skip-link:focus {
  top: 1rem;
}

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

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

/* Sections */
.section {
  padding-top: 2.5rem;
  padding-bottom: 2.5rem;
}

@media (min-width: 48rem) {
  .section { padding-top: 4rem; padding-bottom: 4rem; }
}

/* Header */
.site-header {
  border-bottom: 1px solid var(--color-muted);
}

.site-header__inner {
  display: grid;
  grid-template-columns: 1fr auto;
  grid-template-areas:
    "brand toggle"
    "cta   cta"
    "nav   nav";
  align-items: center;
  gap: 0.75rem 1rem;
  padding-top: 0.75rem;
  padding-bottom: 0.75rem;
}

.wordmark {
  grid-area: brand;
  font-family: var(--font-heading);
  font-weight: 800;
  font-size: var(--step-1);
  letter-spacing: -0.02em;
  color: var(--color-text);
  text-decoration: none;
}

.menu-toggle {
  grid-area: toggle;
  min-height: 44px;
  min-width: 44px;
  padding: 0.5rem 0.9rem;
  font: inherit;
  font-weight: 600;
  color: var(--color-text);
  background: var(--color-background);
  border: 2px solid var(--color-text);
  border-radius: 4px;
  cursor: pointer;
}

.site-header__cta {
  grid-area: cta;
  width: 100%;
}

.site-nav {
  grid-area: nav;
}

.has-menu-toggle .site-nav:not(.is-open) {
  display: none;
}

.site-nav__list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.site-nav__list a {
  display: block;
  padding: 0.6rem 0;
  min-height: 44px;
  font-weight: 600;
  color: var(--color-text);
  text-decoration: none;
}

.site-nav__list a:hover,
.site-nav__list a[aria-current="page"] {
  text-decoration: underline;
  text-decoration-thickness: 2px;
}

/* Tablet: brand and CTA on the first row, menu on the second. */
@media (min-width: 48rem) {
  .site-header__inner {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.25rem 1.5rem;
  }

  .wordmark { margin-right: auto; order: 1; }
  .site-header__cta { width: auto; order: 2; }
  .site-nav { order: 3; flex-basis: 100%; }

  .site-nav__list {
    display: flex;
    flex-wrap: wrap;
    gap: 0 1.25rem;
  }
}

/* Wide screens: everything on one row. */
@media (min-width: 75rem) {
  .site-header__inner { flex-wrap: nowrap; }
  .site-nav { order: 2; flex-basis: auto; }
  .site-header__cta { order: 3; }
  .site-nav__list { flex-wrap: nowrap; gap: 0 1.1rem; }
  .site-nav__list a { font-size: var(--step--1); white-space: nowrap; }
}

/* Footer */
.site-footer {
  margin-top: 3rem;
  padding: 2.5rem 0 1.5rem;
  border-top: 1px solid var(--color-muted);
  font-size: var(--step--1);
}

.site-footer__inner {
  display: grid;
  gap: 1.5rem;
}

@media (min-width: 48rem) {
  .site-footer__inner {
    grid-template-columns: 2fr 1fr 1fr;
  }
}

.site-footer__name {
  font-family: var(--font-heading);
  font-weight: 800;
  font-size: var(--step-0);
}

.site-footer__heading {
  font-family: var(--font-body);
  font-size: var(--step--1);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--color-muted);
  margin-bottom: 0.5rem;
}

.site-footer ul {
  list-style: none;
  padding: 0;
}

.site-footer li a {
  display: inline-block;
  padding: 0.3rem 0;
  min-height: 24px;
}

.site-footer p {
  margin-bottom: 0.4rem;
}

.site-footer__legal {
  margin-top: 1.5rem;
  padding-top: 1rem;
  border-top: 1px solid var(--color-muted);
  color: var(--color-muted);
}

/* Shared content patterns */
.h3 {
  font-size: var(--step-1);
  font-weight: 700;
}

.section--rule {
  border-top: 1px solid var(--color-muted);
}

/* Hero */
.hero__grid {
  display: grid;
  gap: 2.5rem;
}

@media (min-width: 60rem) {
  .hero__grid {
    grid-template-columns: 3fr 2fr;
    align-items: start;
    gap: 4rem;
  }
}

.hero__lead {
  font-size: var(--step-1);
  max-width: 34rem;
}

.hero__actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.75rem 1.5rem;
}

.hero__secondary {
  font-weight: 600;
  padding: 0.6rem 0;
}

.hero__note {
  font-size: var(--step--1);
}

/* Check list */
.check-list {
  list-style: none;
  padding: 0;
}

.check-list li {
  position: relative;
  padding-left: 1.5rem;
  margin-bottom: 0.4rem;
}

.check-list li::before {
  content: "";
  position: absolute;
  left: 0.2rem;
  top: 0.55em;
  width: 0.55rem;
  height: 0.55rem;
  background: var(--color-accent);
  border: 2px solid var(--color-text);
}

/* Service cards */
.cards {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  gap: 1rem;
}

@media (min-width: 48rem) {
  .cards {
    grid-template-columns: repeat(3, 1fr);
    gap: 1.5rem;
  }
}

.card {
  padding: 1.25rem;
  border: 2px solid var(--color-text);
  border-radius: 4px;
}

.card__title {
  margin-bottom: 0.5rem;
}

.card__title a {
  color: var(--color-text);
}

.card__price {
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: var(--step-1);
  margin: 0;
}

/* Credential line */
.credential-line {
  font-family: var(--font-heading);
  font-weight: 700;
}

/* Numbered steps */
.steps {
  list-style: none;
  counter-reset: step;
  padding: 0;
  display: grid;
  gap: 1rem;
}

@media (min-width: 48rem) {
  .steps {
    grid-template-columns: repeat(4, 1fr);
    gap: 1.5rem;
  }
}

.steps li {
  counter-increment: step;
  position: relative;
  padding-top: 2.75rem;
}

.steps li::before {
  content: counter(step);
  position: absolute;
  top: 0;
  left: 0;
  width: 2.25rem;
  height: 2.25rem;
  display: grid;
  place-items: center;
  font-family: var(--font-heading);
  font-weight: 700;
  color: var(--color-text);
  background: var(--color-accent);
  border-radius: 50%;
}

.steps strong {
  display: block;
}

/* CTA band */
.cta-band {
  padding: 2.5rem 0;
  background: var(--color-text);
  color: var(--color-background);
}

.cta-band__inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 1rem 2rem;
}

.cta-band__title {
  margin: 0;
  font-size: var(--step-2);
}

.cta-band .button {
  border-color: var(--color-background);
}

.site-footer {
  margin-top: 0;
}

/* On the dark band, the focus outline switches to white (green on near-black is 2.14:1). */
.cta-band :focus-visible {
  outline-color: var(--color-background);
}

/* Service pages */
.price-line {
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: var(--step-2);
  margin-bottom: 1rem;
}

.fit {
  display: grid;
  gap: 2rem;
}

@media (min-width: 48rem) {
  .fit {
    grid-template-columns: 3fr 2fr;
    gap: 4rem;
  }
}

/* FAQ: native details/summary, keyboard accessible and announced by default. */
.faq details {
  border-top: 1px solid var(--color-muted);
  padding: 0.25rem 0;
}

.faq details:last-child {
  border-bottom: 1px solid var(--color-muted);
}

.faq summary {
  min-height: 44px;
  padding: 0.6rem 0;
  font-weight: 600;
  cursor: pointer;
}

.faq details p {
  margin-top: 0.25rem;
}

.next-step {
  padding-top: 1.5rem;
}

/* Service hero on phones: keep the price and button above the fold at 375×667. */
@media (max-width: 47.99rem) {
  .hero--service.section { padding-top: 1.5rem; }
  .hero--service h1 { font-size: var(--step-3); }
  .hero--service .hero__lead { font-size: var(--step-0); }
  .hero--service .price-line { font-size: var(--step-1); margin-bottom: 0.75rem; }
}

/* About page: name treatment in place of a photo (owner decision, no photo). */
.about-hero {
  display: grid;
  gap: 1.5rem;
  align-items: center;
}

@media (min-width: 48rem) {
  .about-hero {
    grid-template-columns: auto 1fr;
    gap: 3rem;
  }
}

.monogram {
  font-family: var(--font-heading);
  font-weight: 800;
  font-size: var(--step-5);
  line-height: 1;
  letter-spacing: -0.03em;
  color: var(--color-text);
  background: var(--color-accent);
  padding: 0.5em 0.4em;
  width: max-content;
}

@media (min-width: 48rem) {
  .monogram { font-size: calc(var(--step-5) * 1.6); }
}

.facts {
  list-style: none;
  padding: 0;
  display: grid;
  gap: 0.75rem;
}

.facts li {
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: var(--step-2);
  line-height: var(--leading-heading);
}

/* About hero on phones: keep the button above the fold at 375×667. */
@media (max-width: 47.99rem) {
  .about-hero { gap: 1rem; }
  .about-hero h1 { font-size: var(--step-3); }
  .hero:has(.about-hero).section { padding-top: 1.5rem; }
  .monogram { font-size: var(--step-3); }
}
