:root {
  --ink: #24303a;
  --muted: #5c6b78;
  --line: #dde3e9;
  --accent: #6992d0;
  --accent-dark: #4a7ba7;
  --brand-navy: #445865;
  --bg-soft: #f4f7fb;
  --accent-soft: #eaf1fb;
  --accent-soft-border: #cddef2;
  --accent-soft-text: #2d4a68;
  --danger: #b3261e;
  --danger-soft: #fdecec;
  --danger-soft-border: #f3c6c2;
  --success: #2f6f4e;
  /* Report priority tiers: a dark-to-light ramp within the brand palette
     (darkest slate = most urgent) rather than a separate red/amber/green
     scale, so the report stays visually on-brand. */
  --top: #24303a;
  --high: #445865;
  --medium: #6992d0;
  --low: #aac3e6;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Helvetica, Arial, sans-serif;
  color: var(--ink);
  background: var(--bg-soft);
  line-height: 1.55;
}

.site-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1.1rem 2rem;
  border-bottom: 1px solid var(--line);
  background: #fff;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.65rem;
  text-decoration: none;
}
.brand-logo { height: 28px; width: auto; display: block; }
.brand-divider { width: 1px; height: 22px; background: var(--line); }
.brand-name {
  font-weight: 700;
  font-size: 1.25rem;
  letter-spacing: 0.05em;
  color: var(--brand-navy);
}
.brand-dot { color: var(--accent); }

.site-header nav a {
  margin-left: 1.25rem;
  color: var(--ink);
  text-decoration: none;
  font-size: 0.95rem;
}
.site-header nav a:hover { color: var(--accent-dark); }
.nav-email { color: var(--muted); font-size: 0.9rem; margin-right: 0.5rem; }

.cta-small {
  background: var(--accent);
  color: #fff !important;
  padding: 0.45rem 0.9rem;
  border-radius: 6px;
}

.site-main {
  max-width: 880px;
  margin: 0 auto;
  padding: 2.5rem 1.5rem 4rem;
}

.site-footer {
  text-align: center;
  color: var(--muted);
  font-size: 0.85rem;
  padding: 2rem 1rem;
}

.hero { text-align: left; padding: 1rem 0 2.5rem; }
.eyebrow { color: var(--accent-dark); text-transform: uppercase; letter-spacing: 0.08em; font-size: 0.8rem; font-weight: 600; }
.hero h1 { font-size: 2.1rem; margin: 0.5rem 0 1rem; max-width: 30ch; color: var(--brand-navy); }
.hero-sub { color: var(--muted); max-width: 60ch; }

.cta {
  display: inline-block;
  background: var(--accent);
  color: #fff;
  text-decoration: none;
  padding: 0.85rem 1.5rem;
  border-radius: 8px;
  font-weight: 600;
  border: none;
  cursor: pointer;
  font-size: 1rem;
  margin-top: 0.75rem;
}
.cta:hover { background: var(--accent-dark); }

.dimensions { margin: 2.5rem 0; }
.dim-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 1rem; margin-top: 1rem; }
.dim-card { background: #fff; border: 1px solid var(--line); border-radius: 10px; padding: 1.1rem; }
.dim-card h3 { margin: 0.4rem 0 0.4rem; font-size: 1rem; }
.dim-card p { margin: 0; color: var(--muted); font-size: 0.9rem; }
.dim-key {
  display: inline-block;
  background: var(--brand-navy); color: #fff;
  font-weight: 700; font-size: 0.75rem;
  width: 1.6rem; height: 1.6rem; line-height: 1.6rem;
  text-align: center; border-radius: 50%;
}

.step-nav { margin-bottom: 1.75rem; }
.step-nav ol {
  display: flex; flex-wrap: wrap; gap: 0.5rem; list-style: none; margin: 0; padding: 0;
}
.step-nav-item {
  font-size: 0.85rem; padding: 0.4rem 0.8rem; border-radius: 999px;
  background: #eef1f4; color: var(--muted);
}
.step-nav-item a { color: var(--muted); text-decoration: none; }
.step-nav-item a:hover { color: var(--accent-dark); text-decoration: underline; }
.step-nav-number {
  display: inline-block; width: 1.2rem; height: 1.2rem; line-height: 1.2rem;
  text-align: center; border-radius: 50%; background: #d7dee4; color: #555;
  font-size: 0.72rem; font-weight: 700; margin-right: 0.2rem;
}
.step-nav-item.step-current { background: var(--accent); color: #fff; font-weight: 600; }
.step-nav-item.step-current .step-nav-number { background: rgba(255,255,255,0.35); color: #fff; }
.step-nav-item.step-visited { background: var(--accent-soft); }
.step-nav-item.step-visited .step-nav-number { background: var(--accent); color: #fff; }
.step-nav-item.step-upcoming { opacity: 0.55; }

.reminder-banner {
  background: var(--accent-soft);
  border: 1px solid var(--accent-soft-border);
  border-left: 4px solid var(--accent);
  border-radius: 8px;
  padding: 0.85rem 1.1rem;
  margin-bottom: 1.5rem;
  font-size: 0.9rem;
  color: var(--accent-soft-text);
}
.reminder-banner strong { color: var(--accent-dark); }

textarea.autogrow { resize: none; overflow-y: hidden; }

.combobox { position: relative; }
.combobox-input {
  width: 100%; padding: 0.6rem 0.7rem; border: 1px solid var(--line); border-radius: 6px; font-size: 0.95rem;
  font-family: inherit;
}
.combobox-list {
  list-style: none; margin: 0.3rem 0 0; padding: 0.3rem 0;
  border: 1px solid var(--line); border-radius: 8px; background: #fff;
  max-height: 220px; overflow-y: auto;
  position: absolute; left: 0; right: 0; z-index: 20;
  box-shadow: 0 6px 16px rgba(36,48,58,0.1);
}
.combobox-list.hidden { display: none; }
.combobox-option {
  padding: 0.5rem 0.9rem; cursor: pointer; font-size: 0.9rem;
}
.combobox-option:hover, .combobox-option.active { background: var(--accent-soft); }
.combobox-other-field { margin-top: 0.6rem; }
.combobox-other-field.hidden { display: none; }

.gate-message {
  display: block; margin-top: 0.6rem; color: var(--danger); font-size: 0.85rem;
}

.submit-loading {
  display: inline-flex; align-items: center; gap: 0.5rem;
  margin-left: 0.75rem; color: var(--muted); font-size: 0.9rem;
}
.dot-spinner { display: inline-flex; gap: 0.25rem; }
.dot-spinner span {
  width: 0.4rem; height: 0.4rem; border-radius: 50%;
  background: var(--accent); opacity: 0.3;
  animation: dot-spin 1s infinite ease-in-out;
}
.dot-spinner span:nth-child(2) { animation-delay: 0.15s; }
.dot-spinner span:nth-child(3) { animation-delay: 0.3s; }
@keyframes dot-spin {
  0%, 80%, 100% { opacity: 0.3; transform: scale(0.85); }
  40% { opacity: 1; transform: scale(1); }
}

.clarify-block {
  display: flex; gap: 0.6rem; align-items: flex-start;
  margin-top: 0.6rem; padding: 0.75rem 0.9rem;
  background: var(--danger-soft); border: 1px solid var(--danger-soft-border); border-radius: 8px;
}
.clarify-icon {
  flex: none; width: 1.4rem; height: 1.4rem; line-height: 1.4rem;
  text-align: center; border-radius: 50%;
  background: var(--danger); color: #fff; font-weight: 700; font-size: 0.85rem;
}
.clarify-content { flex: 1; }
.clarify-question { margin: 0 0 0.4rem; font-size: 0.88rem; color: var(--danger); font-weight: 600; }
.clarify-content textarea { width: 100%; }

.how-it-works ol { padding-left: 1.2rem; color: var(--muted); }
.how-it-works li { margin-bottom: 0.5rem; }
.how-it-works strong { color: var(--ink); }

.auth-card, .intake, .questions, .report {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 2rem;
}

.auth-card { max-width: 420px; margin: 0 auto; }
.auth-card form { display: flex; flex-direction: column; gap: 1rem; margin-top: 1rem; }
.auth-card label, .intake label { display: flex; flex-direction: column; gap: 0.35rem; font-size: 0.9rem; color: var(--muted); }
.auth-card input { padding: 0.6rem 0.7rem; border: 1px solid var(--line); border-radius: 6px; font-size: 1rem; }
.auth-switch { text-align: center; margin-top: 1.25rem; font-size: 0.9rem; color: var(--muted); }
.error { color: var(--danger); font-size: 0.9rem; }
.muted { color: var(--muted); }
.mock-note { background: #fff6ea; border: 1px dashed #d8b978; padding: 0.75rem 1rem; border-radius: 8px; font-size: 0.85rem; color: #6b5416; margin: 0.75rem 0; }

.auth-card label.checkbox-row { flex-direction: row; align-items: flex-start; gap: 0.6rem; font-size: 0.85rem; }
.auth-card input[type="checkbox"] { width: auto; padding: 0; margin-top: 0.2rem; flex: 0 0 auto; }

.paypal-gated { opacity: 0.45; pointer-events: none; transition: opacity 0.15s ease; }
.paypal-gated.consent-given { opacity: 1; pointer-events: auto; }

.legal-page { max-width: 720px; margin: 0 auto; background: #fff; border: 1px solid var(--line); border-radius: 12px; padding: 2rem; line-height: 1.6; }
.legal-page h2 { margin-top: 2rem; margin-bottom: 0.5rem; font-size: 1.1rem; }
.legal-page h1 { margin-bottom: 0.25rem; }
.legal-page ul { padding-left: 1.25rem; }
.legal-page li { margin-bottom: 0.5rem; }

.intake-block { margin-bottom: 1.5rem; }
.intake-block label { display: block; margin-bottom: 0.4rem; font-weight: 600; color: var(--ink); }
.intake-question { display: block; font-weight: 400; color: var(--muted); font-size: 0.85rem; margin-top: 0.15rem; }
.intake textarea, .questions textarea {
  width: 100%; padding: 0.7rem; border: 1px solid var(--line); border-radius: 8px;
  font-family: inherit; font-size: 0.95rem; resize: vertical;
}
.intake-block select, .intake-block input[type="text"] {
  display: block; width: 100%; padding: 0.6rem 0.7rem; border: 1px solid var(--line);
  border-radius: 6px; font-size: 0.95rem; font-family: inherit; background: #fff;
}

.question-block { padding: 1.25rem 0; border-bottom: 1px solid var(--line); }
.question-block:last-of-type { border-bottom: none; }
.question-head { display: flex; align-items: center; gap: 0.5rem; margin-bottom: 0.4rem; }
.dim-label { color: var(--muted); font-size: 0.8rem; text-transform: uppercase; letter-spacing: 0.04em; }
.question-block h3 { margin: 0.2rem 0 0.5rem; font-size: 1.05rem; }
.rationale { color: var(--muted); font-size: 0.82rem; font-style: italic; margin: -0.2rem 0 0.75rem; }

.mc-options { display: flex; flex-direction: column; gap: 0.5rem; margin-bottom: 0.75rem; }
.mc-option {
  display: grid; grid-template-columns: auto 1fr; align-items: start; gap: 0.6rem;
  padding: 0.55rem 0.7rem; border: 1px solid var(--line); border-radius: 8px; cursor: pointer; font-size: 0.88rem;
}
.mc-option:has(input:checked) { border-color: var(--accent); background: var(--accent-soft); }
.mc-desc { color: var(--muted); }

.before-you-start {
  background: var(--accent-soft); border: 1px solid var(--accent-soft-border); border-radius: 8px;
  padding: 0.85rem 1.1rem; margin-bottom: 1.5rem; font-size: 0.9rem; color: var(--accent-soft-text);
}
.before-you-start strong { color: var(--accent-dark); }
.free-text-label { display: block; font-size: 0.85rem; color: var(--muted); margin-top: 0.5rem; }
.free-text-label textarea { margin-top: 0.35rem; }

.report-letterhead {
  display: flex; align-items: center; gap: 0.65rem;
  margin-bottom: 1.5rem; padding-bottom: 1.25rem; border-bottom: 1px solid var(--line);
}
.report-letterhead .brand-logo { height: 32px; }
.report-letterhead .brand-divider { height: 26px; }
.report-letterhead .brand-name { font-size: 1.4rem; }
.report-letterhead .letterhead-tagline { color: var(--muted); font-size: 0.85rem; margin-left: 0.25rem; }

.report-actions { display: flex; align-items: center; flex-wrap: wrap; gap: 0.75rem; margin-bottom: 1.5rem; }
.report-actions button {
  padding: 0.55rem 1rem; border: 1px solid var(--line); background: #fff; border-radius: 6px; cursor: pointer; font-size: 0.9rem;
}
.account-reminder { color: var(--muted); font-size: 0.85rem; }
.summary { font-size: 1.05rem; color: var(--muted); max-width: 65ch; }

.framework-explainer {
  background: #fff; border: 1px solid var(--line); border-radius: 10px;
  padding: 1.5rem; margin-bottom: 2rem;
}
.framework-explainer h2 { margin-top: 0; font-size: 1.1rem; }
.explainer-dims { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 1rem; margin: 1rem 0 1.5rem; }
.explainer-dim { display: flex; gap: 0.6rem; align-items: flex-start; }
.explainer-dim h3 { margin: 0 0 0.2rem; font-size: 0.95rem; }
.explainer-dim p { margin: 0; color: var(--muted); font-size: 0.85rem; }
.explainer-levels { margin: 0; padding-left: 0; list-style: none; color: var(--muted); font-size: 0.85rem; }
.explainer-levels li { margin-bottom: 0.35rem; }
.explainer-levels strong { color: var(--ink); }

.chart-section { margin: 2rem 0; background: #fff; border: 1px solid var(--line); border-radius: 10px; padding: 1.5rem; }
.chart-section h2 { margin-top: 0; font-size: 1.1rem; }
.chart-caption { font-size: 0.82rem; margin-top: 0.75rem; }

.dim-report-grid { display: grid; gap: 1rem; margin-top: 1.5rem; }
.dim-report-card { border: 1px solid var(--line); border-radius: 10px; padding: 1.2rem; border-left: 5px solid var(--medium); }
.dim-report-card.tier-top { border-left-color: var(--top); }
.dim-report-card.tier-high { border-left-color: var(--high); }
.dim-report-card.tier-medium { border-left-color: var(--medium); }
.dim-report-card.tier-low { border-left-color: var(--low); }
.dim-report-head { display: flex; justify-content: space-between; align-items: baseline; }
.dim-report-head h2 { font-size: 1.05rem; margin: 0; }
.tier-badge { font-size: 0.72rem; text-transform: uppercase; letter-spacing: 0.05em; color: var(--muted); }
.level-track { display: flex; align-items: center; gap: 0.6rem; margin: 0.5rem 0; font-size: 0.9rem; }
.level-current { color: var(--muted); }
.level-target { font-weight: 600; }
.level-arrow { color: var(--accent-dark); }
.dim-rationale { color: var(--muted); font-size: 0.9rem; }
.steps-label { font-weight: 600; font-size: 0.85rem; margin: 0.75rem 0 0.25rem; }
.steps-list { margin: 0; padding-left: 1.1rem; font-size: 0.9rem; }
.steps-list li { margin-bottom: 0.3rem; }

.report-cta { margin-top: 2rem; padding: 1.5rem; background: var(--bg-soft); border-radius: 10px; text-align: center; }
.report-cta h2 { margin-top: 0; font-size: 1.15rem; }
.review-note { font-size: 0.75rem; color: #999; margin-top: 1.5rem; }

@media print {
  .site-header, .site-footer, .no-print { display: none !important; }
  body { background: #fff; }
  .report { border: none; padding: 0; }
  .report-letterhead { border-bottom-color: #ccc; }
}

/* Scoped to .auth-card .promo-form (not just .promo-form) so this beats
   .auth-card form's own rules on specificity. Stacked one under another
   (label, then input, then button), left-aligned, with extra bottom
   margin so the checkbox below isn't crowded against the Apply button. */
.auth-card .promo-form { display: flex; flex-direction: column; align-items: flex-start; gap: 0.5rem; margin: 1rem 0 1.25rem; }
.auth-card .promo-form label { display: flex; flex-direction: column; gap: 0.35rem; font-size: 0.9rem; color: var(--muted); }
.auth-card .promo-form input { width: 100%; padding: 0.5rem 0.6rem; border: 1px solid var(--line); border-radius: 6px; font-size: 0.95rem; }
.promo-error { color: var(--danger); font-size: 0.85rem; margin: 0.25rem 0 0.75rem; }
.promo-applied { color: var(--success); font-size: 0.9rem; margin: 0.25rem 0 0.75rem; }
.price-strike { text-decoration: line-through; color: var(--muted); font-weight: normal; font-size: 0.7em; }

/* --- Coach mode (internal only) ------------------------------------------ */
.admin-table { width: 100%; border-collapse: collapse; margin-top: 1rem; }
.admin-table th, .admin-table td { text-align: left; padding: 0.6rem 0.75rem; border-bottom: 1px solid var(--line); font-size: 0.9rem; }
.admin-table th { color: var(--muted); font-weight: 600; font-size: 0.8rem; text-transform: uppercase; letter-spacing: 0.03em; }

.client-context-block { margin: 1.25rem 0; border: 1px solid var(--line); border-radius: 10px; padding: 0.9rem 1.2rem; }
.client-context-block summary { cursor: pointer; font-weight: 600; }
.client-context-body { margin-top: 0.75rem; }

.coach-notes-form { display: flex; flex-direction: column; gap: 0.6rem; margin: 1.5rem 0; }
.coach-notes-form label { font-weight: 600; font-size: 0.9rem; }
.coach-notes-form textarea { width: 100%; padding: 0.7rem; border: 1px solid var(--line); border-radius: 8px; font-family: inherit; font-size: 0.95rem; }
.coach-notes-form button { align-self: flex-start; }

.coach-brief { margin-top: 2rem; }
.agenda-list { padding-left: 1.2rem; }
.agenda-list li { margin-bottom: 0.4rem; }

.session-history-item { margin: 0.75rem 0; border: 1px solid var(--line); border-radius: 8px; padding: 0.7rem 1rem; }
.session-history-item summary { cursor: pointer; color: var(--muted); font-size: 0.9rem; }

/* --- Security-related utility classes -------------------------------------
   CSP disallows inline style="" and onclick="" attributes, so the two
   places that used them (report.html's "Print" button and its email form)
   use these instead. */
.inline-form { display: inline; }
.print-button { cursor: pointer; }
