/* =============================================================================
   styles.css — v3: light, warm, friendly. Cream + terracotta.
   For local small businesses. Real device frames; the screenshots bring color.
   Reskin via the variables in :root.
   ========================================================================== */

:root {
  /* Working palette: forest + turmeric + sage (swap these 11 lines to reskin). */
  --cream:      #f6f6f2;   /* page bg */
  --cream-2:    #ecede5;   /* tinted band */
  --card:       #ffffff;
  --ink:        #1c2420;
  --ink-soft:   #5a6660;
  --ink-dim:    #9aa39a;
  --line:       #e2e4dd;
  --terra:      #1f6f5c;   /* forest green — primary */
  --terra-deep: #185748;
  --olive:      #8a9a6b;   /* sage */
  --gold:       #d99a07;   /* turmeric */

  --font-display: "Bricolage Grotesque", system-ui, sans-serif;
  --font-body:    "Instrument Sans", system-ui, sans-serif;

  --r:    10px;
  --r-lg: 14px;
  --maxw: 1080px;
  --header-h: 64px;
  --shadow:    0 22px 50px -28px rgba(30,41,59,.28);
  --shadow-sm: 0 8px 22px -14px rgba(30,41,59,.20);
}

/* ---- Reset ----------------------------------------------------------- */
* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: calc(var(--header-h) + 14px); -webkit-text-size-adjust: 100%; }
body {
  font-family: var(--font-body);
  color: var(--ink);
  background: var(--cream);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
h1, h2, h3 { font-family: var(--font-display); font-weight: 600; line-height: 1.08; letter-spacing: -.01em; }
::selection { background: var(--terra); color: #fff; }
:focus-visible { outline: 2px solid var(--terra); outline-offset: 3px; border-radius: 4px; }

/* ---- Layout ---------------------------------------------------------- */
.section { padding: clamp(40px, 6vw, 76px) 22px; }
.inner { max-width: var(--maxw); margin: 0 auto; }
.section-title { font-size: clamp(1.7rem, 4vw, 2.6rem); }
.head { text-align: center; margin-bottom: clamp(36px, 6vw, 60px); }
.head-sub { color: var(--ink-soft); max-width: 56ch; margin: .9em auto 0; font-size: 1.06rem; }

/* ---- Tricolor wordmark ----------------------------------------------- */
.brand-name { font-family: var(--font-display); font-weight: 600; font-size: 1.3rem; letter-spacing: -.02em; }
.bw-1 { color: var(--terra); }
.bw-2 { color: var(--gold); }
.bw-3 { color: var(--olive); }

/* ---- Buttons --------------------------------------------------------- */
.btn {
  display: inline-flex; align-items: center; gap: .5em;
  font-family: var(--font-body); font-weight: 600; font-size: .98rem; letter-spacing: .005em;
  padding: .62em 1.15em; border-radius: 7px; border: 1.5px solid transparent;
  cursor: pointer; transition: transform .15s ease, background .15s ease, border-color .15s ease;
}
.btn-sm { padding: .46em .9em; font-size: .88rem; }
.btn-primary { background: transparent; color: var(--terra); border-color: var(--terra); }
.btn-primary:hover { background: var(--terra); color: #fff; transform: translateY(-1px); }
.btn-ghost { background: transparent; color: var(--ink); border-color: var(--line); }
.btn-ghost:hover { border-color: var(--ink); transform: translateY(-1px); }
.btn .arrow { transition: transform .18s ease; }
.btn:hover .arrow { transform: translateX(3px); }

/* ---- Header ---------------------------------------------------------- */
.site-header {
  position: sticky; top: 0; z-index: 50; height: var(--header-h);
  display: flex; align-items: center; justify-content: space-between;
  padding: 0 max(22px, calc((100% - var(--maxw)) / 2));  /* full-width bar, centered content */
  background: transparent; transition: background .25s ease;
}
.site-header.scrolled {
  background: color-mix(in srgb, var(--cream) 90%, transparent); backdrop-filter: blur(10px);
}
.site-nav { display: flex; align-items: center; gap: 1.3em; }
.nav-link { font-weight: 600; font-size: .95rem; color: var(--ink-soft); }
.nav-link:hover { color: var(--terra); }

/* ---- Hero ------------------------------------------------------------ */
.hero { padding: clamp(40px, 7vw, 80px) 22px clamp(48px, 8vw, 96px); }
.hero .inner {
  display: grid; grid-template-columns: 1.05fr .95fr; gap: clamp(28px, 5vw, 64px);
  align-items: center;
}
.hero-copy { max-width: 520px; }
.hero-headline { font-size: clamp(2.2rem, 5.4vw, 3.8rem); display: flex; flex-direction: column; }
.hero-headline .hl-pre { color: var(--ink); }
.hero-headline .hl-post { color: var(--ink); }
.hl-cycle { color: var(--terra); position: relative; }
.animate .hl-cycle { opacity: 0; transform: translateY(.25em); transition: opacity .32s ease, transform .32s ease; }
.animate .hl-cycle.in { opacity: 1; transform: none; }
.hero .lede { font-size: clamp(1.05rem, 2vw, 1.25rem); color: var(--ink-soft); max-width: 40ch; margin-top: .9em; }
.hero-actions { margin-top: 1.8em; display: flex; gap: .8em; flex-wrap: wrap; align-items: center; }
.hero-phone-wrap { display: flex; justify-content: center; }
.hero-phone-wrap .phone { height: min(70vh, 540px); width: auto; }

/* ---- iPhone frame (real mockup PNG, screen knocked transparent) ------ */
.phone {
  position: relative; width: 150px; aspect-ratio: 1892 / 3888;
  filter: drop-shadow(0 20px 38px rgba(30,41,59,.26));
}
.phone::after {  /* the mockup overlays the screenshot: bezel, island, buttons on top */
  content: ""; position: absolute; inset: 0; z-index: 2; pointer-events: none;
  background: url("img/iphone-frame.png") center / 100% 100% no-repeat;
}
.phone-screen {  /* sits in the frame's screen opening (measured insets) */
  position: absolute; top: 1.16%; left: 3.28%; width: 93.92%; height: 97.66%;
  z-index: 1; overflow: hidden; border-radius: 7% / 3.4%; background: var(--cream-2);
}
.phone-screen img { width: 100%; height: 100%; object-fit: cover; object-position: top center; }

/* ---- Browser frame --------------------------------------------------- */
.browser {
  width: 100%; border-radius: 12px; overflow: hidden; background: var(--card);
  border: 1px solid var(--line); box-shadow: var(--shadow);
}
.browser-bar {
  display: flex; align-items: center; gap: 7px; height: 34px; padding: 0 14px;
  background: var(--cream-2); border-bottom: 1px solid var(--line);
}
.browser-bar .dot { width: 11px; height: 11px; border-radius: 50%; background: var(--line); }
.browser-bar .dot:nth-child(1) { background: var(--terra); }
.browser-bar .dot:nth-child(2) { background: var(--gold); }
.browser-bar .dot:nth-child(3) { background: var(--olive); }
.browser-screen { aspect-ratio: 1280 / 840; overflow: hidden; background: var(--cream-2); }
.browser-screen img { width: 100%; height: 100%; object-fit: cover; object-position: top center; }

/* ---- Device duo (desktop + overlapping phone) ------------------------ */
.device-duo { position: relative; max-width: 600px; margin: 0 auto; padding: 0 5% 7% 0; }
.device-duo .phone {
  position: absolute; right: 0; bottom: 0; width: clamp(92px, 24%, 152px);
  z-index: 2;
}

/* ---- Who ------------------------------------------------------------- */
.who .inner { max-width: 780px; }
.who-card {
  display: flex; gap: 26px; align-items: center; flex-wrap: wrap;
  background: var(--card); border: 1px solid var(--line); border-radius: var(--r-lg);
  padding: clamp(26px, 4vw, 40px); box-shadow: var(--shadow-sm);
}
.who-photo {
  width: 96px; height: 96px; border-radius: 50%; flex-shrink: 0; overflow: hidden;
  display: grid; place-items: center; background: var(--cream-2);
  border: 2px solid var(--terra); color: var(--terra);
  font-family: var(--font-display); font-size: 2.3rem;
}
.who-photo img { width: 100%; height: 100%; object-fit: cover; }
.who-text { flex: 1; min-width: 240px; }
.who-text .who-name { font-family: var(--font-display); font-size: 1.55rem; }
.who-text p { color: var(--ink-soft); margin-top: .5em; font-size: 1.08rem; line-height: 1.55; }
.who-link { display: inline-flex; align-items: center; gap: .4em; margin-top: .9em; font-weight: 600; color: var(--terra); }
.who-link:hover { color: var(--terra-deep); }

/* ---- About page ------------------------------------------------------ */
.about-hero { text-align: center; padding-top: clamp(48px, 8vw, 96px); }
.about-hero .inner { max-width: 680px; }
.about-photo {
  width: 110px; height: 110px; margin: 0 auto 1em; border-radius: 50%;
  display: grid; place-items: center; background: var(--cream-2);
  border: 2px solid var(--terra); color: var(--terra);
  font-family: var(--font-display); font-size: 2.6rem;
}
.about-name { font-size: clamp(2rem, 5vw, 3rem); }
.about-lede { margin-top: .6em; color: var(--ink-soft); font-size: clamp(1.1rem, 2.2vw, 1.35rem); }
.about-body .inner { max-width: 680px; }
.about-h { font-size: clamp(1.3rem, 3vw, 1.7rem); margin: 1.6em 0 .4em; }
.about-body .about-h:first-child { margin-top: 0; }
.about-body p { color: var(--ink-soft); font-size: 1.1rem; line-height: 1.65; }
.about-body p strong { color: var(--ink); }
.about-body p + p { margin-top: 1.4em; }
.about-cta { text-align: center; background: var(--cream-2); }
.about-cta .inner { max-width: 560px; }
.about-cta .about-h { margin-bottom: .7em; }

/* ---- Work (template story) ------------------------------------------- */
.carousel { position: relative; }
.carousel-track {
  display: flex; gap: clamp(20px, 4vw, 44px);
  overflow-x: auto; scroll-snap-type: x mandatory;
  scrollbar-width: none; -ms-overflow-style: none;
}
.carousel-track::-webkit-scrollbar { display: none; }
.carousel-track > .work-item { flex: 0 0 100%; scroll-snap-align: center; min-width: 0; }
.carousel-nav { display: flex; align-items: center; justify-content: center; gap: 1.2em; margin-top: clamp(20px, 3vw, 32px); }
.carousel-arrow {
  width: 40px; height: 40px; border-radius: 50%; border: 1.5px solid var(--line);
  background: var(--card); color: var(--ink); font-size: 1.1rem; line-height: 1;
  cursor: pointer; display: grid; place-items: center; transition: border-color .15s, color .15s;
}
.carousel-arrow:hover { border-color: var(--terra); color: var(--terra); }
.carousel-dots { display: flex; gap: .5em; }
.carousel-dot {
  width: 9px; height: 9px; border-radius: 50%; border: none; padding: 0; cursor: pointer;
  background: var(--line); transition: background .15s, transform .15s;
}
.carousel-dot.active { background: var(--terra); transform: scale(1.25); }
.work-item { display: grid; grid-template-columns: 1.2fr .8fr; gap: clamp(20px, 3.5vw, 44px); align-items: center; }
.device-duo { max-width: 520px; }
.steps-cta { text-align: center; margin-top: clamp(28px, 4vw, 40px); }
.work-item:nth-child(even) .device-duo { order: 2; }
.work-caption h3 { font-size: clamp(1.5rem, 3vw, 2rem); }
.work-caption .work-line { color: var(--ink-soft); font-size: 1.08rem; margin-top: .4em; }
.work-caption .work-link {
  display: inline-flex; align-items: center; gap: .4em;
  margin-top: 1em; font-weight: 700; color: var(--terra);
}
.work-caption .work-link:hover { color: var(--terra-deep); }
.work-outro {
  margin-top: clamp(40px, 6vw, 64px); text-align: center;
  color: var(--ink-soft); font-size: 1.04rem; max-width: 56ch;
  margin-left: auto; margin-right: auto;
}

/* ---- Everyone band --------------------------------------------------- */
.everyone { background: var(--cream-2); text-align: center; }
.everyone .inner { max-width: 720px; }
.everyone-title { font-size: clamp(1.9rem, 4.6vw, 3rem); }
.everyone-body { margin-top: .9em; color: var(--ink-soft); font-size: clamp(1.06rem, 2vw, 1.25rem); }

/* ---- Steps ----------------------------------------------------------- */
.steps-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); gap: 28px; }
.step { text-align: center; }
.step .num {
  width: 56px; height: 56px; margin: 0 auto .7em; border-radius: 50%;
  display: grid; place-items: center;
  font-family: var(--font-display); font-size: 1.5rem; font-weight: 600;
  color: var(--terra); background: var(--card);
  border: 1.5px solid var(--terra); box-shadow: var(--shadow-sm);
}
.step h3 { font-family: var(--font-body); font-weight: 700; font-size: 1.2rem; margin-bottom: .25em; }
.step p { color: var(--ink-soft); }

/* ---- Scope ----------------------------------------------------------- */
.scope .inner { max-width: 760px; text-align: center; }
.scope-body { margin-top: 1em; color: var(--ink-soft); font-size: 1.12rem; }
.scope-tips {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: clamp(16px, 2.5vw, 22px); margin-top: 1.8em; text-align: left;
}
.scope-note {
  text-align: left;
  background: var(--card); border: 1px solid var(--line); border-left: 4px solid var(--terra);
  border-radius: var(--r); padding: clamp(20px, 2.6vw, 26px); box-shadow: var(--shadow-sm);
}
.scope-note p { color: var(--ink-soft); font-size: 1.04rem; line-height: 1.55; }
.scope-note-label { display: inline-block; font-size: .72rem; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; color: var(--terra); margin-bottom: .5em; }

/* ---- Compare (time = money) ------------------------------------------ */
.work, .steps { background: var(--cream-2); }   /* alternating tint cadence */
.table-wrap { border-radius: var(--r-lg); }
.compare-table {
  width: 100%; border-collapse: separate; border-spacing: 0;
  background: var(--card); border-radius: var(--r-lg); overflow: hidden;
  box-shadow: var(--shadow-sm);
}
.compare-table th, .compare-table td {
  padding: .9em 1em; text-align: center; font-size: .98rem;
  border-bottom: 1px solid var(--line); vertical-align: middle;
}
.compare-table thead th { background: var(--ink); color: #fff; font-weight: 700; font-family: var(--font-body); font-size: .92rem; }
.compare-table .rowhead { text-align: left; font-weight: 700; color: var(--ink); }
.compare-table tbody .rowhead { background: var(--card); }
.compare-table tbody tr:last-child th, .compare-table tbody tr:last-child td { border-bottom: none; }
.compare-table td { color: var(--ink-soft); }
/* the localwebsitebuilds column, highlighted */
.compare-table .us-col { background: rgba(79,70,229,.07); }
.compare-table tbody td.us-col { color: var(--ink); font-weight: 700; }
.compare-table thead th.us-col { background: var(--terra); }
.us-mark { font-family: var(--font-display); font-size: 1rem; white-space: nowrap; }
.us-mark .bw-1 { color: var(--terra); }
.us-mark .bw-2 { color: var(--gold); }
.us-mark .bw-3 { color: var(--olive); }
.compare-table thead .us-mark .bw-1,
.compare-table thead .us-mark .bw-2,
.compare-table thead .us-mark .bw-3 { color: #fff; }
/* mobile: card per solution (hidden on desktop) */
.compare-cards { display: none; gap: 14px; }
.ccard { background: var(--card); border: 1px solid var(--line); border-radius: var(--r); box-shadow: var(--shadow-sm); padding: 0 1.1em; }
.ccard.us-card { border: 2px solid var(--terra); }
.ccard-name { font-weight: 700; font-size: 1.15rem; padding: .75em 0 .55em; border-bottom: 1px solid var(--line); }
.ccard-row { display: flex; justify-content: space-between; gap: 1em; padding: .6em 0; border-bottom: 1px solid var(--line); font-size: .96rem; }
.ccard-row:last-child { border-bottom: none; }
.ccard-label { color: var(--ink-dim); font-weight: 600; }
.ccard-val { text-align: right; color: var(--ink); }
.us-card .ccard-val { font-weight: 700; }
.compare-kicker {
  margin: clamp(28px, 4vw, 40px) auto 0; max-width: 60ch; text-align: center;
  color: var(--ink); font-size: 1.1rem; line-height: 1.55;
}
.compare-cta { text-align: center; margin-top: 1.8em; }

/* ---- Footer ---------------------------------------------------------- */
.site-footer {
  border-top: 1px solid var(--line); padding: 40px 22px;
  max-width: var(--maxw); margin: 0 auto;
  display: flex; flex-wrap: wrap; gap: 20px; justify-content: space-between; align-items: center;
}
.footer-brand .brand-name, .footer-brand { font-family: var(--font-display); font-size: 1.2rem; }
.footer-contact { display: flex; gap: 1.4em; flex-wrap: wrap; font-size: .95rem; color: var(--ink-soft); }
.footer-contact a:hover { color: var(--terra); }
.version-tag { color: var(--ink-dim); font-size: .8rem; font-variant-numeric: tabular-nums; width: 100%; text-align: right; }

/* ---- Motion ---------------------------------------------------------- */
.reveal { transition: opacity .6s ease, transform .6s ease; }
.animate .reveal { opacity: 0; transform: translateY(16px); }
.reveal.in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  *, *::before { animation: none !important; transition: none !important; }
  .reveal, .hl-cycle { opacity: 1; transform: none; }
  html { scroll-behavior: auto; }
}

/* ---- Responsive ------------------------------------------------------ */
@media (max-width: 820px) {
  .work-item { grid-template-columns: 1fr; text-align: center; }
  .work-item:nth-child(even) .device-duo { order: 0; }
  .work-caption .work-link { margin-top: .6em; }
}
/* Comparison: table on desktop, card-per-solution on phones */
@media (max-width: 680px) {
  .compare-table { display: none; }
  .compare-cards { display: grid; }
}

@media (max-width: 760px) {
  .hero .inner { grid-template-columns: 1fr; text-align: center; }
  .hero-copy { max-width: none; margin: 0 auto; }
  .hero-headline { align-items: center; }
  .hero .lede { margin-left: auto; margin-right: auto; }
  .hero-actions { justify-content: center; }
  .hero-phone-wrap { order: 0; margin-top: 2.4em; }
  .hero-phone-wrap .phone { width: clamp(190px, 52vw, 230px); height: auto; }
  .who-card { text-align: center; justify-content: center; }
}
