/* PoolCRM + BJG Digital shared design system */
:root {
  --ground: #F7F5F1;
  --panel: #FFFFFF;
  --panel-2: #EFECE6;
  --ink: #131211;
  --ink-2: #4A4744;
  --muted: #7A7671;
  --line: #DAD6CE;
  --orange: #E8552B;
  --orange-ink: #FFFFFF;
  --orange-soft: #FBE9E2;
  --water: #1A7FA3;
  --water-soft: #DDF0F7;
  --bubble-in: #E9E7E2;
  --bubble-out: #1A7FA3;
  --fill: #FFF1B3;
  --shadow: 0 18px 50px rgba(19, 18, 17, 0.12);
  --radius: 6px;
  --maxw: 1180px;
  --measure: 62ch;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --ground: #151412;
    --panel: #1E1C19;
    --panel-2: #262320;
    --ink: #F4F1EA;
    --ink-2: #C9C4BA;
    --muted: #8F8A80;
    --line: #35322D;
    --orange: #F26A3F;
    --orange-ink: #151412;
    --orange-soft: #3A2419;
    --water: #4FB3D6;
    --water-soft: #16303A;
    --bubble-in: #2B2825;
    --bubble-out: #2A86A8;
    --fill: #4A3F12;
    --shadow: 0 18px 50px rgba(0, 0, 0, 0.45);
  }
}
:root[data-theme="dark"] {
  --ground: #151412;
  --panel: #1E1C19;
  --panel-2: #262320;
  --ink: #F4F1EA;
  --ink-2: #C9C4BA;
  --muted: #8F8A80;
  --line: #35322D;
  --orange: #F26A3F;
  --orange-ink: #151412;
  --orange-soft: #3A2419;
  --water: #4FB3D6;
  --water-soft: #16303A;
  --bubble-in: #2B2825;
  --bubble-out: #2A86A8;
  --fill: #4A3F12;
  --shadow: 0 18px 50px rgba(0, 0, 0, 0.45);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
body {
  margin: 0;
  background: var(--ground);
  color: var(--ink);
  font-family: "IBM Plex Sans", "Helvetica Neue", Arial, sans-serif;
  font-size: 17px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
}
h1, h2, h3, .display {
  font-family: "Archivo", "Helvetica Neue", Arial, sans-serif;
  font-weight: 900;
  line-height: 1.02;
  letter-spacing: -0.02em;
  margin: 0;
  text-wrap: balance;
}
h1 { font-size: clamp(2.6rem, 6.2vw, 5rem); }
h2 { font-size: clamp(1.9rem, 3.6vw, 2.8rem); }
h3 { font-size: 1.25rem; line-height: 1.2; letter-spacing: -0.01em; }
p { margin: 0; max-width: var(--measure); }
a { color: var(--water); text-decoration-thickness: 1px; text-underline-offset: 3px; }
a:focus-visible, button:focus-visible { outline: 3px solid var(--water); outline-offset: 3px; }
strong { font-weight: 600; }
.eyebrow {
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--ink-2);
}
.fill { background: var(--fill); padding: 0 0.2em; border-radius: 3px; }

.wrap { max-width: var(--maxw); margin: 0 auto; padding: 0 24px; }
section { padding: 88px 0; }
section + section { border-top: 1px solid var(--line); }
.stack { display: grid; gap: 20px; }
.stack-lg { display: grid; gap: 36px; }

/* Nav */
.nav { position: sticky; top: 0; z-index: 10; background: color-mix(in srgb, var(--ground) 92%, transparent); backdrop-filter: blur(10px); border-bottom: 1px solid var(--line); }
.nav .wrap { display: flex; align-items: center; justify-content: space-between; gap: 24px; height: 76px; }
.brand { display: flex; align-items: baseline; gap: 10px; text-decoration: none; color: var(--ink); }
.brand .mark { font-family: "Archivo", sans-serif; font-weight: 900; font-size: 1.5rem; letter-spacing: -0.03em; }
.brand .by { font-size: 0.75rem; color: var(--muted); letter-spacing: 0.04em; }
.nav-links { display: flex; align-items: center; gap: 28px; }
.nav-links a { color: var(--ink); text-decoration: none; font-weight: 500; }
.nav-links .tel { font-variant-numeric: tabular-nums; }
.nav-links a { white-space: nowrap; }
@media (max-width: 760px) { .nav-links a:not(.btn) { display: none; } }

/* Buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  padding: 16px 26px; border-radius: var(--radius); border: 2px solid transparent;
  font-weight: 600; font-size: 1rem; text-decoration: none; cursor: pointer; white-space: nowrap;
  transition: transform 120ms ease, background 120ms ease;
}
.btn:active { transform: translateY(1px); }
.btn-primary { background: var(--orange); color: var(--orange-ink); }
.btn-primary:hover { background: color-mix(in srgb, var(--orange) 88%, var(--ink)); }
.btn-secondary { background: transparent; color: var(--ink); border-color: var(--ink); }
.btn-secondary:hover { background: var(--panel-2); }
.btn small { font-weight: 400; opacity: 0.85; }
.nav .btn { padding: 12px 20px; }
.cta-row { display: flex; flex-wrap: wrap; gap: 14px; align-items: center; }
.cta-note { font-size: 0.95rem; color: var(--ink-2); }

/* Hero */
.hero { padding: 72px 0 80px; }
.hero .wrap { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, 0.85fr); gap: 56px; align-items: center; }
@media (max-width: 900px) { .hero .wrap { grid-template-columns: 1fr; } }
.hero .lede { font-size: 1.25rem; color: var(--ink-2); }
.proof { display: flex; flex-wrap: wrap; gap: 8px 28px; font-size: 0.95rem; color: var(--ink-2); padding-top: 8px; }
.proof > span::before { content: ""; display: inline-block; width: 8px; height: 8px; border-radius: 50%; background: var(--orange); margin-right: 8px; vertical-align: 1px; }

/* Phone mockup */
.phone {
  width: min(360px, 100%); margin: 0 auto; background: var(--panel); border: 1px solid var(--line);
  border-radius: 34px; padding: 18px 14px 22px; box-shadow: var(--shadow);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
}
.phone-head { text-align: center; font-size: 0.8rem; color: var(--muted); padding-bottom: 12px; border-bottom: 1px solid var(--line); margin-bottom: 12px; }
.phone-head b { display: block; color: var(--ink); font-size: 0.95rem; font-weight: 600; }
.thread { display: grid; gap: 8px; }
.msg { max-width: 82%; padding: 9px 13px; border-radius: 18px; font-size: 0.93rem; line-height: 1.35; }
.msg.in { background: var(--bubble-in); color: var(--ink); justify-self: start; border-bottom-left-radius: 4px; }
.msg.out { background: var(--bubble-out); color: #fff; justify-self: end; border-bottom-right-radius: 4px; }
.msg.sys { justify-self: center; max-width: 100%; background: none; color: var(--muted); font-size: 0.75rem; padding: 4px 0; }
.phone-cap { text-align: center; font-size: 0.85rem; color: var(--muted); margin-top: 14px; font-family: "IBM Plex Sans", sans-serif; }

/* Grids and cards */
.grid-3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 28px; }
.grid-2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 28px; }
@media (max-width: 860px) { .grid-3, .grid-2 { grid-template-columns: 1fr; } }
.feature { display: grid; gap: 14px; align-content: start; }
.feature .num { font-family: "Archivo", sans-serif; font-weight: 900; font-size: 2.6rem; color: var(--orange); line-height: 1; letter-spacing: -0.03em; }
.feature p { color: var(--ink-2); }
.feature a { font-weight: 600; }
.card { background: var(--panel); border: 1px solid var(--line); border-radius: 10px; padding: 28px; }
.leak { display: grid; grid-template-columns: 1fr 1fr; gap: 0; border: 1px solid var(--line); border-radius: 10px; overflow: hidden; }
.leak > div { padding: 22px 26px; }
.leak > div:nth-child(odd) { background: var(--panel-2); color: var(--ink-2); }
.leak > div:nth-child(even) { background: var(--panel); }
.leak > div:nth-child(n+3) { border-top: 1px solid var(--line); }
.leak .h { font-size: 0.78rem; font-weight: 600; letter-spacing: 0.08em; text-transform: uppercase; color: var(--muted); }
@media (max-width: 640px) { .leak { grid-template-columns: 1fr; } .leak > div:nth-child(n+2) { border-top: 1px solid var(--line); } }

/* Table */
.table-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: 10px; background: var(--panel); }
table { border-collapse: collapse; width: 100%; min-width: 640px; font-size: 0.95rem; }
th, td { text-align: left; padding: 14px 18px; border-bottom: 1px solid var(--line); vertical-align: top; }
th { font-size: 0.78rem; letter-spacing: 0.06em; text-transform: uppercase; color: var(--muted); font-weight: 600; }
tbody tr:last-child td { border-bottom: 0; }
td:first-child { font-weight: 600; }
.yes { color: var(--water); font-weight: 600; }
.no { color: var(--muted); }
.us { background: var(--orange-soft); }
td, th { font-variant-numeric: tabular-nums; }

/* Pricing */
.price-block { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 40px; align-items: start; background: var(--ink); color: var(--ground); border-radius: 14px; padding: 48px; }
:root[data-theme="dark"] .price-block, .price-block { --pb-muted: color-mix(in srgb, var(--ground) 70%, transparent); }
.price-block .amount { font-family: "Archivo", sans-serif; font-weight: 900; font-size: clamp(3.5rem, 8vw, 6rem); line-height: 1; letter-spacing: -0.04em; }
.price-block .amount small { font-size: 0.3em; font-weight: 600; letter-spacing: 0; margin-left: 6px; }
.price-block p { color: var(--pb-muted); }
.price-block ul { margin: 0; padding: 0; list-style: none; display: grid; gap: 10px; }
.price-block li { padding-left: 22px; position: relative; }
.price-block li::before { content: ""; position: absolute; left: 0; top: 0.55em; width: 10px; height: 10px; background: var(--orange); border-radius: 2px; }
.price-block .btn-primary { margin-top: 8px; }
@media (max-width: 800px) { .price-block { grid-template-columns: 1fr; padding: 32px; } }
.math { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 0; border: 1px solid var(--line); border-radius: 10px; overflow: hidden; background: var(--panel); }
.math > div { padding: 24px; border-left: 1px solid var(--line); }
.math > div:first-child { border-left: 0; }
.math .n { font-family: "Archivo", sans-serif; font-weight: 900; font-size: 2rem; letter-spacing: -0.03em; line-height: 1; }
.math .l { font-size: 0.9rem; color: var(--muted); margin-top: 6px; }
@media (max-width: 720px) { .math { grid-template-columns: 1fr; } .math > div { border-left: 0; border-top: 1px solid var(--line); } .math > div:first-child { border-top: 0; } }

/* Founder */
.founder { display: grid; grid-template-columns: 220px minmax(0, 1fr); gap: 40px; align-items: start; }
.founder .photo { aspect-ratio: 4/5; background: var(--panel-2); border: 1px dashed var(--line); border-radius: 10px; display: grid; place-items: center; color: var(--muted); font-size: 0.85rem; text-align: center; padding: 12px; }
.founder blockquote { margin: 0; font-family: "Archivo", sans-serif; font-weight: 700; font-size: 1.45rem; line-height: 1.25; letter-spacing: -0.01em; }
@media (max-width: 700px) { .founder { grid-template-columns: 1fr; } .founder .photo { width: 180px; } }

/* FAQ */
.faq { display: grid; gap: 0; border-top: 1px solid var(--line); }
.faq details { border-bottom: 1px solid var(--line); }
.faq summary { cursor: pointer; padding: 20px 0; font-weight: 600; font-size: 1.05rem; list-style: none; display: flex; justify-content: space-between; gap: 20px; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; color: var(--orange); font-weight: 700; font-size: 1.3rem; line-height: 1; }
.faq details[open] summary::after { content: "–"; }
.faq details p { padding: 0 0 22px; color: var(--ink-2); }

/* Article pages */
.article { padding: 64px 0 88px; }
.article .wrap { max-width: 800px; }
.article h1 { font-size: clamp(2.2rem, 5vw, 3.6rem); }
.article h2 { font-size: clamp(1.5rem, 2.8vw, 2rem); margin-top: 20px; }
.article p, .article li { color: var(--ink-2); }
.article ol, .article ul { padding-left: 22px; margin: 0; display: grid; gap: 8px; max-width: var(--measure); }
.article .lede { font-size: 1.2rem; color: var(--ink-2); }
.callout { background: var(--water-soft); border-left: 4px solid var(--water); padding: 18px 22px; border-radius: 0 8px 8px 0; }
.callout p { color: var(--ink); }
.related { display: flex; flex-wrap: wrap; gap: 12px; }
.related a { border: 1px solid var(--line); border-radius: 999px; padding: 8px 16px; text-decoration: none; color: var(--ink); font-weight: 500; }
.related a:hover { background: var(--panel-2); }

/* Final CTA + footer */
.final { background: var(--orange); color: var(--orange-ink); }
.final h2 { color: var(--orange-ink); }
.final p { color: color-mix(in srgb, var(--orange-ink) 85%, transparent); }
.final .btn-secondary { color: var(--orange-ink); border-color: var(--orange-ink); }
.final .btn-secondary:hover { background: color-mix(in srgb, var(--orange-ink) 12%, transparent); }
footer { padding: 40px 0; font-size: 0.9rem; color: var(--muted); border-top: 1px solid var(--line); }
footer .wrap { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 16px 32px; }
footer nav { display: flex; flex-wrap: wrap; gap: 18px; }
footer a { color: var(--muted); }

/* Case study stat */
.stat { display: grid; gap: 4px; }
.stat .n { font-family: "Archivo", sans-serif; font-weight: 900; font-size: clamp(2.6rem, 5vw, 4rem); letter-spacing: -0.04em; line-height: 1; color: var(--orange); }
.stat .l { color: var(--ink-2); }
.two-offers { display: grid; grid-template-columns: 1fr 1fr; gap: 28px; }
.offer { background: var(--panel); border: 1px solid var(--line); border-radius: 12px; padding: 36px; display: grid; gap: 18px; align-content: start; }
.offer.dark { background: var(--ink); color: var(--ground); border-color: var(--ink); }
.offer.dark p, .offer.dark li { color: color-mix(in srgb, var(--ground) 75%, transparent); }
.offer.dark h3 { color: var(--ground); }
.offer ul { margin: 0; padding-left: 20px; display: grid; gap: 6px; color: var(--ink-2); }
.offer .tag { font-size: 0.78rem; font-weight: 600; letter-spacing: 0.08em; text-transform: uppercase; color: var(--orange); }
@media (max-width: 800px) { .two-offers { grid-template-columns: 1fr; } }

/* GHL calendar embed */
.calendar-embed { background: var(--panel); border-radius: 12px; padding: 8px; overflow: hidden; }
.calendar-embed iframe { display: block; border-radius: 8px; background: #fff; }

.founder.no-photo { grid-template-columns: 1fr; max-width: 760px; }

/* Legal pages */
.legal h2 { font-size: 1.35rem; margin-top: 8px; }
.legal .stack { gap: 12px; }
.legal p, .legal li { font-size: 1rem; }
.legal ul { gap: 6px; }
