/* Trailmark AI — site styles
   Fraunces (display) over IBM Plex Sans (body). Colors match the design canvas. */

/* Self-hosted (SIL Open Font License) instead of Google Fonts: no render-blocking third-party
   stylesheet, no visitor IPs sent to Google. Variable fonts, Latin subset, as Google Fonts serves them. */
@font-face {
  font-family: 'Fraunces';
  font-style: normal;
  font-weight: 500 600;
  font-display: swap;
  src: url(/assets/fonts/fraunces-latin.woff2) format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'IBM Plex Sans';
  font-style: normal;
  font-weight: 400 600;
  font-display: swap;
  src: url(/assets/fonts/ibm-plex-sans-latin.woff2) format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

:root {
  --ground: #F4EFE6;
  --card: #FFFDF9;
  --ink: #1C1A17;
  --text-2: #4A453D;
  --text-3: #5A554D;
  --rule: #D9D2C5;
  --clay: #B4441C;
  --clay-hover: #8E3416;
  --soft: #E39B7A;
  --muted-dark: #B8B0A3;
  --line-dark: #4A453D;
  --tint: #E6DFD2;
  --serif: 'Fraunces', Georgia, serif;
  --sans: 'IBM Plex Sans', 'Helvetica Neue', Arial, sans-serif;
  --wrap: 1248px;
  --gutter: 24px;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--ground);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}
img, svg { display: block; max-width: 100%; }
[hidden] { display: none !important; }
a { color: var(--clay); text-decoration: none; }
a:hover { color: var(--clay-hover); }
h1, h2, h3, p, ul, ol { margin: 0; }
ul, ol { padding: 0; list-style: none; }
button, input, select, textarea { font: inherit; color: inherit; }
:focus-visible { outline: 3px solid var(--clay); outline-offset: 3px; border-radius: 4px; }

.skip-link {
  position: absolute; left: 16px; top: -60px; z-index: 100;
  background: var(--ink); color: var(--ground); padding: 10px 16px; border-radius: 6px;
}
.skip-link:focus { top: 12px; color: var(--ground); }
.visually-hidden {
  position: absolute !important; width: 1px; height: 1px; overflow: hidden;
  clip: rect(0 0 0 0); white-space: nowrap;
}

.wrap { width: min(var(--wrap), 100% - 2 * var(--gutter)); margin-inline: auto; }

/* ---------- type helpers ---------- */
.eyebrow {
  display: flex; align-items: center; gap: 10px;
  font-size: 13px; font-weight: 600; letter-spacing: 0.08em; text-transform: uppercase;
  color: var(--clay);
}
.eyebrow--rule::before { content: ""; width: 28px; height: 2px; background: var(--clay); }
.eyebrow--dark { color: var(--soft); }
.h2 { font-family: var(--serif); font-size: 40px; line-height: 1.15; font-weight: 500; letter-spacing: -0.01em; }
.section-head { display: flex; flex-direction: column; gap: 12px; }

/* ---------- buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  height: 52px; padding: 0 26px; border-radius: 6px;
  font-size: 16px; font-weight: 600; line-height: 1; cursor: pointer;
  border: 1px solid transparent; transition: background-color .15s, color .15s, border-color .15s;
}
.btn--primary { background: var(--clay); color: #FFFDF9; }
.btn--primary:hover { background: var(--clay-hover); color: #FFFDF9; }
.btn--outline { border-color: var(--ink); color: var(--ink); background: transparent; }
.btn--outline:hover { background: var(--ink); color: var(--ground); }
.btn--dark { background: var(--ink); color: var(--ground); height: 44px; padding: 0 20px; font-size: 15px; }
.btn--dark:hover { background: #000; color: var(--ground); }
.btn--quiet { border-color: var(--rule); color: var(--ink); background: transparent; padding: 0 20px; }
.btn--quiet:hover { border-color: var(--ink); color: var(--ink); }
.btn svg { width: 16px; height: 16px; }

/* ---------- header ---------- */
.site-header { border-bottom: 1px solid var(--rule); background: var(--ground); position: relative; z-index: 20; }
.site-header__inner { height: 84px; display: flex; align-items: center; justify-content: space-between; gap: 24px; }
.logo { display: inline-flex; align-items: center; color: var(--ink); }
.logo svg { height: 26px; width: auto; }
.site-nav { display: flex; align-items: center; gap: 36px; font-size: 15px; font-weight: 500; }
.site-nav a:not(.btn) { color: var(--ink); }
.site-nav a:not(.btn):hover { color: var(--clay); }
.menu-toggle {
  display: none; width: 44px; height: 44px; border: 0; background: transparent;
  align-items: center; justify-content: center; cursor: pointer; border-radius: 6px;
}
.menu-toggle svg { width: 22px; height: 22px; }
.back-link { font-size: 15px; font-weight: 500; color: var(--text-3); white-space: nowrap; }
.back-link:hover { color: var(--ink); }

/* ---------- hero ---------- */
.hero { padding: 96px 0 88px; }
.hero__grid { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: var(--gutter); align-items: center; }
.hero__copy { grid-column: 1 / span 7; display: flex; flex-direction: column; gap: 28px; }
.hero h1 { font-family: var(--serif); font-size: 56px; line-height: 1.06; font-weight: 500; letter-spacing: -0.02em; }
.hero__lede { font-size: 20px; line-height: 1.5; color: var(--text-2); max-width: 600px; }
.cta-row { display: flex; flex-wrap: wrap; align-items: center; gap: 14px; margin-top: 8px; }
.trust { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 24px; margin-top: 12px; font-size: 14px; color: var(--text-3); }
.trust li { display: flex; align-items: center; gap: 24px; }
.trust li + li::before { content: ""; width: 4px; height: 4px; border-radius: 2px; background: var(--clay); margin-left: -12px; margin-right: -12px; }
.stat-card {
  grid-column: 9 / span 4; background: var(--card); border: 1px solid var(--rule); border-radius: 10px;
  padding: 28px; display: flex; flex-direction: column; gap: 18px;
}
.stat-card__label { font-size: 12px; font-weight: 600; letter-spacing: 0.08em; text-transform: uppercase; color: var(--text-3); }
.stat { display: flex; flex-direction: column; gap: 4px; }
.stat__num { font-family: var(--serif); font-size: 56px; line-height: 1; font-weight: 500; }
.stat__num--clay { color: var(--clay); }
.stat__text { font-size: 15px; color: var(--text-2); }
.stat-card hr { border: 0; height: 1px; background: var(--rule); margin: 0; }
.stat-card__source { font-size: 13px; line-height: 1.5; color: var(--text-3); }

/* ---------- cards ---------- */
.cards-3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--gutter); }
.card {
  background: var(--card); border: 1px solid var(--rule); border-radius: 10px;
  padding: 32px; display: flex; flex-direction: column; gap: 14px;
}
.card svg.icon { width: 28px; height: 28px; }
.card h3 { font-size: 20px; line-height: 1.3; font-weight: 600; }
.card p { font-size: 15px; line-height: 1.55; color: var(--text-2); }

/* ---------- pain ---------- */
.pain { padding: 0 0 96px; }
.pain .section-head { max-width: 760px; margin-bottom: 40px; }
.pain .section-head p { font-size: 17px; line-height: 1.55; color: var(--text-2); }

/* ---------- how it works ---------- */
.how { background: var(--ink); color: var(--ground); padding: 96px 0; }
.how__head { display: flex; justify-content: space-between; align-items: flex-end; gap: 48px; margin-bottom: 56px; }
.how__head .section-head { max-width: 640px; }
.how__head > p { font-size: 16px; line-height: 1.55; color: var(--muted-dark); max-width: 380px; }
.steps { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: var(--gutter); counter-reset: step; }
.step { display: flex; flex-direction: column; gap: 20px; }
.step__mark { display: flex; align-items: center; gap: 12px; }
.step__num {
  display: inline-flex; align-items: center; justify-content: center; flex-shrink: 0;
  width: 40px; height: 40px; border-radius: 20px; background: var(--soft); color: var(--ink);
  font-family: var(--serif); font-size: 20px; font-weight: 600;
}
.step__mark::after { content: ""; flex-grow: 1; height: 1px; background: var(--line-dark); }
.step:last-child .step__mark::after { display: none; }
.step__body { display: flex; flex-direction: column; gap: 8px; }
.step__tag { font-size: 13px; font-weight: 600; letter-spacing: 0.06em; text-transform: uppercase; color: var(--soft); }
.step h3 { font-size: 22px; line-height: 1.25; font-weight: 600; }
.step p { font-size: 15px; line-height: 1.55; color: var(--muted-dark); }

/* ---------- services ---------- */
.services { padding: 96px 0; }
.services .section-head { max-width: 720px; margin-bottom: 48px; }
.service { padding: 36px 32px; gap: 18px; }
.card .service__num { font-family: var(--serif); font-size: 15px; font-weight: 600; color: var(--clay); }
.service h3 { font-size: 24px; line-height: 1.25; }
.service ul { display: flex; flex-direction: column; gap: 8px; margin-top: 4px; font-size: 14px; color: var(--text-2); }
.service li { display: flex; gap: 10px; }
.service li::before { content: "—"; color: var(--clay); }

/* ---------- why ---------- */
.why { padding: 0 0 96px; }
.why__grid { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: var(--gutter); align-items: center; }
.why__visual { grid-column: 1 / span 5; display: flex; flex-direction: column; gap: 12px; }
.why__copy { grid-column: 7 / span 6; display: flex; flex-direction: column; gap: 28px; }
.why__points { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 24px 32px; }
.why__points h3 { font-size: 17px; font-weight: 600; margin-bottom: 6px; }
.why__points p { font-size: 15px; line-height: 1.5; color: var(--text-2); }
.caption { font-size: 13px; line-height: 1.5; color: var(--text-3); }

/* the illustrated after-hours inquiry */
.inquiry {
  background: var(--card); border: 1px solid var(--rule); border-radius: 10px;
  padding: 24px; display: flex; flex-direction: column; gap: 14px; min-height: 440px;
}
.inquiry__top { display: flex; justify-content: space-between; align-items: baseline; }
.inquiry__label { font-size: 11px; font-weight: 600; letter-spacing: 0.08em; text-transform: uppercase; color: var(--text-3); }
.inquiry__time { font-size: 14px; font-weight: 600; }
.bubble { max-width: 86%; padding: 12px 14px; display: flex; flex-direction: column; gap: 4px; font-size: 14px; line-height: 1.45; }
.bubble small { font-size: 12px; color: var(--text-3); }
.bubble--in { align-self: flex-start; background: var(--ground); border-radius: 10px 10px 10px 2px; }
.bubble--out { align-self: flex-end; background: var(--ink); color: var(--ground); border-radius: 10px 10px 2px 10px; }
.bubble--out small { color: var(--muted-dark); }
.inquiry__done { margin-top: auto; border-top: 1px solid var(--rule); padding-top: 14px; display: flex; flex-direction: column; gap: 8px; font-size: 14px; }
.inquiry__done li { display: flex; gap: 10px; align-items: center; }
.inquiry__done svg { width: 16px; height: 16px; flex-shrink: 0; }

/* ---------- closing call to action ---------- */
.cta { padding: 0 0 96px; }
.cta__box {
  background: var(--ink); color: var(--ground); border-radius: 12px; padding: 72px;
  display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: var(--gutter); align-items: center;
}
.cta__copy { grid-column: 1 / span 7; display: flex; flex-direction: column; gap: 14px; }
.cta__copy h2 { font-family: var(--serif); font-size: 44px; line-height: 1.1; font-weight: 500; letter-spacing: -0.01em; }
.cta__copy p { font-size: 17px; line-height: 1.5; color: var(--muted-dark); }
.cta__action { grid-column: 9 / span 4; display: flex; flex-direction: column; gap: 14px; }
.cta__action .btn { height: 56px; width: 100%; }
.cta__action p { font-size: 14px; color: var(--muted-dark); text-align: center; }
.cta__action a:not(.btn) { color: var(--soft); }
.cta__action a:not(.btn):hover { color: #F0B89E; }

/* ---------- footer ---------- */
.site-footer { border-top: 1px solid var(--rule); padding: 40px 0; font-size: 14px; color: var(--text-3); }
.site-footer__inner { display: flex; justify-content: space-between; align-items: center; gap: 20px; flex-wrap: wrap; }
.site-footer__brand { display: flex; align-items: center; gap: 10px; }
.site-footer__brand svg { height: 19px; width: auto; }
.site-footer__links { display: flex; gap: 28px; flex-wrap: wrap; }
.site-footer a { color: var(--text-3); }
.site-footer a:hover { color: var(--ink); }

/* ---------- simple content pages (privacy, 404) ---------- */
.page { padding: 80px 0 96px; }
.page__body { max-width: 720px; display: flex; flex-direction: column; gap: 18px; }
.page__body h1 { font-family: var(--serif); font-size: 44px; line-height: 1.1; font-weight: 500; }
.page__body h2 { font-family: var(--serif); font-size: 24px; font-weight: 500; margin-top: 12px; }
.page__body p, .page__body li { font-size: 17px; line-height: 1.6; color: var(--text-2); }
.page__body ul { list-style: disc; padding-left: 22px; display: flex; flex-direction: column; gap: 6px; }

/* ======================================================
   Tablet
   ====================================================== */
@media (max-width: 1100px) {
  .hero__copy, .stat-card { grid-column: 1 / -1; }
  .stat-card { margin-top: 48px; max-width: 520px; }
  .cards-3 { grid-template-columns: 1fr; }
  .steps { grid-template-columns: repeat(2, minmax(0, 1fr)); row-gap: 40px; }
  .step:nth-child(2) .step__mark::after { display: none; }
  .how__head { flex-direction: column; align-items: flex-start; }
  .why__visual, .why__copy { grid-column: 1 / -1; }
  .why__visual { order: 2; margin-top: 40px; max-width: 560px; }
  .cta__copy, .cta__action { grid-column: 1 / -1; }
  .cta__action { margin-top: 28px; max-width: 360px; }
}

/* ======================================================
   Phone (matches the 390px mobile artboard)
   ====================================================== */
@media (max-width: 760px) {
  :root { --gutter: 20px; }
  .site-header__inner { height: 64px; }
  .logo svg { height: 22px; }
  .menu-toggle { display: inline-flex; }
  .site-nav {
    display: none; position: absolute; left: 0; right: 0; top: 64px;
    flex-direction: column; align-items: stretch; gap: 0;
    background: var(--ground); border-bottom: 1px solid var(--rule); padding: 8px 20px 20px;
  }
  .site-nav.is-open { display: flex; }
  .site-nav a:not(.btn) { padding: 14px 0; border-bottom: 1px solid var(--rule); font-size: 16px; }
  .site-nav .btn { margin-top: 16px; height: 52px; font-size: 16px; }

  .eyebrow { font-size: 11px; gap: 8px; }
  .eyebrow--rule::before { width: 20px; }
  .h2 { font-size: 28px; }

  .hero { padding: 44px 0 40px; }
  .hero__copy { gap: 20px; }
  .hero h1 { font-size: 40px; text-wrap: balance; }
  .hero h1 br { display: none; }
  .hero__lede { font-size: 17px; }
  .cta-row { flex-direction: column; align-items: stretch; gap: 10px; margin-top: 4px; }
  .trust { display: block; font-size: 13px; margin-top: 0; }
  .trust li { display: inline; }
  .trust li + li::before { content: " · "; display: inline; width: auto; height: auto; background: none; margin: 0; color: var(--text-3); }
  .stat-card { margin-top: 40px; padding: 24px; gap: 14px; display: grid; grid-template-columns: 1fr 1fr; column-gap: 16px; }
  .stat-card__label, .stat-card hr, .stat-card__source { grid-column: 1 / -1; }
  .stat-card hr { display: none; }
  .stat__num { font-size: 44px; }
  .stat__text { font-size: 13px; line-height: 1.4; }
  .stat-card__source { font-size: 12px; }

  .pain { padding-bottom: 48px; }
  .pain .section-head { margin-bottom: 20px; }
  .pain .section-head p { font-size: 15px; }
  .card { padding: 20px; gap: 8px; }
  .card svg.icon { display: none; }
  .card h3 { font-size: 17px; }
  .card p { font-size: 14px; line-height: 1.5; }

  .how { padding: 48px 0; }
  .how__head { margin-bottom: 28px; gap: 12px; }
  .how__head > p { font-size: 14px; }
  .steps { grid-template-columns: 1fr; row-gap: 24px; }
  .step { flex-direction: row; gap: 16px; }
  .step__mark::after { display: none; }
  .step__num { width: 36px; height: 36px; font-size: 18px; }
  .step__body { gap: 4px; }
  .step__tag { font-size: 11px; }
  .step h3 { font-size: 18px; }
  .step p { font-size: 14px; line-height: 1.5; }

  .services { padding: 48px 0; }
  .services .section-head { margin-bottom: 20px; }
  .service { padding: 22px 20px; gap: 8px; }
  .card .service__num { font-size: 13px; }
  .service h3 { font-size: 19px; }

  .why { padding-bottom: 48px; }
  .why__copy { gap: 20px; }
  .why__visual { order: 0; margin: 0 0 32px; }
  .why__points { grid-template-columns: 1fr; gap: 16px; }
  .why__points h3 { font-size: 16px; margin-bottom: 4px; }
  .why__points p { font-size: 14px; }
  .inquiry { min-height: 0; }

  .cta { padding-bottom: 40px; }
  .cta__box { padding: 32px 24px; }
  .cta__copy h2 { font-size: 30px; }
  .cta__copy p { font-size: 15px; }
  .cta__action { margin-top: 20px; max-width: none; }
  .cta__action .btn { height: 52px; }

  .site-footer { padding: 28px 0; font-size: 13px; }
  .site-footer__inner { flex-direction: column; align-items: flex-start; gap: 12px; }
  .site-footer__links { gap: 16px; }

  .page { padding: 48px 0 64px; }
  .page__body h1 { font-size: 32px; }
}

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