/* Practice Sourcing — landing styles. No framework, no build, no external assets. */
:root {
  --ink: #14171a;
  --ink-soft: #444b52;
  --ink-faint: #6b747c;
  --bg: #eef4f0;      /* soft sage: keeps the warm-neutral feel but echoes the teal accent */
  --panel: #ffffff;
  --line: #d8e2da;
  --accent: #0f6d5f;        /* deep teal — "fresh/new" without generic SaaS blue */
  --accent-dark: #0a4c42;
  --accent-tint: #e8f1ef;
  --warn: #8a5a00;
  --radius: 10px;
  --maxw: 1040px;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  color: var(--ink);
  background: var(--bg);
  line-height: 1.55;
  font-size: 17px;
}
h1, h2, h3 { font-family: Georgia, "Times New Roman", serif; font-weight: 600; line-height: 1.15; letter-spacing: -0.01em; }
h1 { font-size: clamp(2.1rem, 5vw, 3.3rem); margin: 0 0 0.5em; }
h2 { font-size: clamp(1.5rem, 3vw, 2rem); margin: 0 0 0.6em; }
h3 { font-size: 1.15rem; margin: 0 0 0.35em; }
p { margin: 0 0 1em; color: var(--ink-soft); }
a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }
.wrap { max-width: var(--maxw); margin: 0 auto; padding: 0 24px; }
.muted { color: var(--ink-faint); }
.small { font-size: 0.86rem; }

/* header */
.site-head { border-bottom: 1px solid var(--line); background: var(--bg); }
.site-head .wrap { display: flex; align-items: center; justify-content: space-between; height: 68px; }
.brand { font-family: Georgia, serif; font-weight: 600; font-size: 1.45rem; color: var(--ink); letter-spacing: -0.01em; }
.brand .accent { color: var(--accent); }
/* The brand is a link on the inner pages. It carried style="text-decoration:none"
   inline, which also suppressed the a:hover underline; both live here now so the
   CSP can drop 'unsafe-inline' from style-src. */
a.brand, a.brand:hover { text-decoration: none; }
.nav { white-space: nowrap; }
.nav a { color: var(--ink-soft); margin-left: 22px; font-size: 0.95rem; }
/* On a real phone the brand plus two links overruns the row and the nav wraps
   below itself. Desktop never shows this, because shrinking a desktop window
   still leaves a wider viewport than a 390px phone. Below 560px keep only the
   CTA: Pricing is one scroll away and "Get a sample" is the point of the page. */
@media (max-width: 560px) {
  .brand { font-size: 1.2rem; }
  .nav a { margin-left: 14px; }
  .nav a:nth-child(2) { display: none; }
}

/* hero (single column: headline, lede, form, then the full-width feed table) */
.hero { padding: 64px 0 48px; }
/* The global h1 clamp floors at 2.1rem, which never shrinks far enough on a
   phone: "The week they open." measures 350px in Georgia Bold at that size,
   against 342px of usable width at 390px, so "open." dropped to its own line.
   A lower floor with a steeper vw slope keeps the line intact down to 320px and
   leaves the desktop size untouched (8vw exceeds the 3.3rem cap above 660px). */
.hero-title { margin-bottom: 22px; font-size: clamp(1.55rem, 8vw, 3.3rem); }
.hero .lede { font-size: 1.15rem; color: var(--ink-soft); max-width: 38em; }
/* Wide enough for email + segment + territory + submit to sit on ONE row. At the
   old 640px the submit button wrapped to a second line, and any change in the
   territory button's width shoved the controls around. */
.hero-form { margin-top: 26px; max-width: 900px; }
.hero .feed-card { margin-top: 72px; }

/* form */
.form-row { display: flex; gap: 10px; flex-wrap: wrap; align-items: flex-start; }
input[type="email"], select {
  font: inherit; padding: 13px 14px; border: 1px solid var(--line); border-radius: var(--radius);
  background: var(--panel); color: var(--ink); min-width: 0;
}
/* The email field is the only elastic control; everything else holds a fixed
   width so selecting states can never reflow the row. */
input[type="email"] { flex: 1 1 200px; }
select { flex: 0 0 auto; }
.form-row .btn { flex: 0 0 auto; white-space: nowrap; }

/* Territory picker. Without JS the native <select multiple> shows through and
   works; form.js sets .is-enhanced, which swaps in the button + checkbox panel so
   the control reads as one more dropdown in the row. */
.territory { position: relative; flex: 0 0 auto; }
.territory.is-enhanced > select { display: none; }
/* FIXED width, not min/max. The label changes as states are picked, and a button
   that resizes with its own label drags every control in the row with it. */
.territory-btn {
  font: inherit; padding: 13px 14px; border: 1px solid var(--line); border-radius: var(--radius);
  background: var(--panel); color: var(--ink); cursor: pointer; text-align: left;
  width: 178px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
/* Chevron drawn in CSS so the button matches the native selects beside it without
   shipping an image (the CSP blocks remote assets anyway). */
.territory-btn::after {
  content: ""; float: right; margin: 7px 0 0 10px; width: 7px; height: 7px;
  border-right: 2px solid var(--ink-faint); border-bottom: 2px solid var(--ink-faint);
  transform: rotate(45deg);
}
.territory.is-open .territory-btn { border-color: var(--accent); }
.territory-panel {
  position: absolute; z-index: 30; top: calc(100% + 6px); left: 0;
  width: 250px; max-height: 288px; overflow-y: auto;
  background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius);
  box-shadow: 0 8px 28px rgba(10, 76, 66, 0.16); padding: 6px;
}
.territory-row {
  display: flex; align-items: center; gap: 9px; padding: 7px 9px;
  border-radius: 6px; cursor: pointer; font-size: 0.95rem; color: var(--ink);
}
.territory-row:hover { background: var(--accent-tint); }
.territory-row input { accent-color: var(--accent); margin: 0; }
.territory-row.is-national { font-weight: 600; }
.territory-row.is-disabled { color: var(--ink-faint); cursor: not-allowed; }
.territory-row.is-disabled:hover { background: transparent; }
.territory-rule { height: 1px; background: var(--line); margin: 5px 2px; }
.btn {
  display: inline-block; font: inherit; font-weight: 600; cursor: pointer;
  padding: 13px 22px; border-radius: var(--radius); border: 1px solid var(--accent);
  background: var(--accent); color: #fff; text-align: center;
}
.btn:hover { background: var(--accent-dark); border-color: var(--accent-dark); text-decoration: none; }
.btn.secondary { background: transparent; color: var(--accent); }
.btn.secondary:hover { background: var(--accent-tint); }
.btn.block { display: block; width: 100%; }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.form-note { margin-top: 10px; font-size: 0.85rem; color: var(--ink-faint); }

/* Narrow screens: one control per line, each full width. The fixed territory
   width above must be overridden or it sits stranded in a full-width column. */
@media (max-width: 820px) {
  input[type="email"], select, .territory, .territory-btn, .form-row .btn { width: 100%; flex: 1 1 100%; }
  .territory-panel { width: 100%; }
}

/* product table (hero visual + proof) */
.feed-card { background: var(--panel); border: 2px solid var(--accent-dark); border-radius: var(--radius); overflow: hidden; box-shadow: 0 2px 4px rgba(10,76,66,0.10), 0 14px 40px rgba(10,76,66,0.14); }
.feed-card .cap { display: flex; justify-content: space-between; align-items: center; gap: 10px; flex-wrap: wrap; padding: 13px 18px; background: var(--accent); }
.feed-card .cap .t { font-weight: 600; font-size: 0.95rem; color: #fff; }
.feed-card .cap .d { font-size: 0.8rem; color: rgba(255,255,255,0.85); }
.feed-table { width: 100%; border-collapse: collapse; font-size: 0.92rem; }
/* wrapping text + auto layout keeps the table inside its container: no horizontal scroll on desktop */
.feed-table th, .feed-table td { text-align: left; padding: 12px 18px; border-bottom: 1px solid var(--line); white-space: normal; }
.feed-table td.phone, .feed-table td:last-child, .feed-table thead th { white-space: nowrap; }
.feed-table thead th { font-size: 0.72rem; text-transform: uppercase; letter-spacing: 0.06em; color: var(--accent-dark); font-weight: 700; background: var(--accent-tint); }
.feed-table tbody tr:last-child td { border-bottom: none; }
.feed-table tbody tr:nth-child(even) td { background: #f6faf7; }
.feed-table td.org { font-weight: 600; color: var(--ink); }
.feed-table td.phone { font-variant-numeric: tabular-nums; }
.table-scroll { overflow-x: auto; }

/* sections */
section { padding: 52px 0; border-top: 1px solid var(--line); }
section.plain { border-top: none; }
.section-lead { max-width: 42em; }

/* how it works */
.steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; margin-top: 12px; }
.step { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 13px 22px 22px; }
.step .n { font-family: Georgia, serif; font-size: 1.1rem; color: var(--accent); font-weight: 600; }
.removed { margin-top: 8px; padding-left: 18px; }
.removed li { margin: 3px 0; color: var(--ink-soft); font-size: 0.95rem; }

/* numbers strip */
.numbers { background: var(--accent); color: #fff; }
.numbers .wrap { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; padding: 34px 24px; text-align: center; }
.numbers .num { font-family: Georgia, serif; font-size: 1.9rem; font-weight: 600; }
.numbers .lbl { font-size: 0.9rem; opacity: 0.9; }

/* pricing */
.cards { display: grid; grid-template-columns: repeat(2, 1fr); gap: 22px; margin-top: 14px; }
.card { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 28px; display: flex; flex-direction: column; }
.card h3 { font-size: 1.25rem; }
.card .price { font-family: Georgia, serif; font-size: 2.2rem; font-weight: 600; margin: 6px 0 2px; }
.card .price span { font-family: inherit; font-size: 0.95rem; color: var(--ink-faint); font-weight: 400; }
.card ul { padding-left: 18px; margin: 14px 0 22px; }
.card li { margin: 6px 0; color: var(--ink-soft); font-size: 0.95rem; }
.card .btn { margin-top: auto; }
.selfserve { text-align: center; color: var(--ink-faint); font-size: 0.9rem; margin-top: 16px; }

/* comparison block (how-it-works) — table shares the sample table's card chrome
   (.feed-card provides the teal cap, 2px dark border and shadow) */
.compare { margin-top: 48px; }
.compare-table { width: 100%; border-collapse: collapse; background: var(--panel); font-size: 0.92rem; }
.compare-table th, .compare-table td { text-align: left; padding: 12px 18px; border-bottom: 1px solid var(--line); vertical-align: top; }
.compare-table thead th { font-size: 0.72rem; text-transform: uppercase; letter-spacing: 0.06em; color: var(--accent-dark); font-weight: 700; background: var(--accent-tint); }
.compare-table tbody th { font-weight: 600; color: var(--ink); width: 22%; white-space: nowrap; }
.compare-table tbody td { color: var(--ink-soft); width: 39%; }
.compare-table td.win { color: var(--ink); font-weight: 500; background: var(--accent-tint); border-bottom-color: #d5e5e1; }
.compare-table tbody tr:last-child th, .compare-table tbody tr:last-child td { border-bottom: none; }
.compare-note { margin-top: 12px; }
/* Per-state volume table: 51 rows, so it gets its own capped scroll rather than
   pushing the rest of the FAQ off the page. */
.state-table { font-size: 0.86rem; }
.state-table th, .state-table td { padding: 7px 14px; }
.state-table tbody th { width: auto; font-weight: 500; }
.state-table tbody td { width: 26%; font-variant-numeric: tabular-nums; }
.state-table + *, .doc .table-scroll { margin-top: 12px; }
details .table-scroll { max-height: 340px; overflow-y: auto; border: 1px solid var(--line); border-radius: var(--radius); }
@media (max-width: 640px) {
  .compare-table, .compare-table thead, .compare-table tbody, .compare-table tr, .compare-table th, .compare-table td { display: block; }
  .compare-table thead { display: none; }
  .compare-table tbody th { width: auto; white-space: normal; padding-bottom: 2px; }
  .compare-table tbody td { width: auto; }
  .compare-table tbody td:first-of-type::before { content: "Public NPI file: "; color: var(--ink-faint); font-weight: 600; }
  .compare-table tbody td.win::before { content: "Practice Sourcing: "; color: var(--accent); font-weight: 600; }
  .compare-table tbody tr { border-bottom: 1px solid var(--line); padding: 8px 0; }
}

/* faq */
.faq details { border: 1px solid var(--line); border-radius: var(--radius); background: var(--panel); margin-bottom: 10px; padding: 4px 18px; }
.faq summary { cursor: pointer; font-weight: 600; padding: 14px 0; list-style: none; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; float: right; color: var(--accent); font-weight: 700; }
.faq details[open] summary::after { content: "\2013"; }
.faq details p { margin: 0 0 14px; }

/* footer */
.site-foot { border-top: 1px solid var(--line); padding: 34px 0; color: var(--ink-faint); font-size: 0.9rem; }
.site-foot .wrap { display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; }
.site-foot a { color: var(--ink-soft); }

/* legal + thanks pages */
.doc { max-width: 720px; padding: 48px 0 64px; }
.doc h1 { font-size: 2rem; }
.doc h2 { font-size: 1.2rem; margin-top: 1.6em; }
.doc p, .doc li { color: var(--ink-soft); }
.doc .updated { color: var(--ink-faint); font-size: 0.85rem; }
/* `text-align: center` only centres the TEXT inside the box; without the auto
   margin the 620px box itself sat against the left edge of .wrap, which is what
   made the page look left-hugging. 840px because "Your sample is on the way."
   measures ~725px in Georgia at the h1's 3.3rem cap — widening the box keeps the
   headline on one line at full size rather than shrinking the type to fit. */
.thanks { text-align: center; max-width: 840px; margin: 0 auto; padding: 90px 0; }
/* Prose stays at a readable measure; only the headline uses the extra width. */
.thanks p { max-width: 620px; margin-left: auto; margin-right: auto; }
.thanks .back { margin-top: 28px; }
.thanks .check { width: 54px; height: 54px; border-radius: 50%; background: var(--accent-tint); color: var(--accent); display: inline-flex; align-items: center; justify-content: center; font-size: 1.6rem; margin-bottom: 18px; }

@media (max-width: 800px) {
  .hero-grid, .steps, .cards, .numbers .wrap { grid-template-columns: 1fr; }
  .hero { padding: 40px 0 24px; }
  .nav a:first-child { display: none; }
}
