/* ═══════════════════════════════════════════════════════════════
   Platform 1 — Succession Assessment
   Follows brand guidelines v1.0 (2025)
   ═══════════════════════════════════════════════════════════════ */

/* ─── RESET ─── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

/* ─── BRAND TOKENS (from brand-guidelines.html) ─── */
:root {
  /* Primary palette */
  --p1-dark:          #1a1f1a;   /* Platform Black — navigation, backgrounds */
  --p1-mid:           #2d3a2d;   /* Mid forest — button hover */
  --p1-green:         #5a7a3a;   /* Platform Green — CTAs, accents, links */
  --p1-green-bright:  #7daa45;   /* Platform Lime — highlights, active states */
  --p1-green-light:   #a3c76b;   /* Light Green — tints */
  --p1-green-pale:    #e8f0d8;   /* Pale Green — surface, section backgrounds */
  --p1-offwhite:      #f4f2ec;   /* Warm Off-White — page background */
  --p1-white:         #ffffff;
  --p1-text:          #1a1f1a;   /* Body text */
  --p1-text-muted:    #5a6050;   /* Secondary text */
  --p1-border:        #d6dcc8;   /* Dividers, card borders */
  --p1-digital:       #3898b8;   /* Digital Teal — footer bg only, never print */

  /* Typography */
  --font-display: 'DM Serif Display', Georgia, serif;
  --font-body:    'DM Sans', system-ui, -apple-system, sans-serif;

  /* Radii — 4px for buttons per guidelines, 8px for cards */
  --radius-btn:  4px;
  --radius-card: 8px;

  --shadow-card: 0 2px 16px rgba(26,31,26,0.08);
}

/* ─── BASE ─── */
html { font-size: 16px; -webkit-text-size-adjust: 100%; }

body {
  font-family: var(--font-body);
  background: var(--p1-offwhite);
  color: var(--p1-text);
  line-height: 1.6;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

main { flex: 1; }

a { color: var(--p1-green); text-decoration: none; }
a:hover { text-decoration: underline; }

/* ─── LAYOUT ─── */
.container { width: 100%; max-width: 1080px; margin: 0 auto; padding: 0 24px; }
.container-narrow { max-width: 660px; }

/* ─── EYEBROW LABEL ─── */
/* Per guidelines: 11px / 600 / uppercase / letter-spacing 0.18em / Platform Green */
.eyebrow {
  font-family: var(--font-body);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--p1-green);
  margin-bottom: 12px;
  display: block;
}

/* ─── HEADER ─── */
/* Per guidelines: Platform Black background, white links */
.header {
  background: var(--p1-dark);
  position: sticky;
  top: 0;
  z-index: 100;
  border-bottom: 3px solid var(--p1-green);
}

.header-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 12px 0;
}

.header-logo {
  height: 80px;
  width: auto;
  display: block;
  border-radius: 4px;
  background: #fff;
  padding: 4px 10px;
}

.header-meta {
  font-size: 13px;
  font-weight: 400;
  color: rgba(255,255,255,0.45);
  letter-spacing: 0.01em;
}

/* ─── SCREENS ─── */
.screen { display: none; animation: fadeUp 0.3s ease both; }
.screen.active { display: block; }

/* ─── ENTRY SCREEN ─── */
.screen-entry { padding: 72px 0 80px; }

.entry-hero {
  text-align: center;
  margin-bottom: 64px;
}

/* Display headline — DM Serif Display per typography guidelines */
.entry-headline {
  font-family: var(--font-display);
  font-size: clamp(30px, 4.5vw, 48px);
  font-weight: 400;
  line-height: 1.08;
  color: var(--p1-dark);
  margin-bottom: 20px;
  max-width: 600px;
  margin-left: auto;
  margin-right: auto;
  letter-spacing: -0.01em;
}

.entry-subhead {
  font-size: 17px;
  font-weight: 400;
  color: var(--p1-text-muted);
  line-height: 1.7;
  max-width: 480px;
  margin: 0 auto 32px;
}

.entry-trust {
  margin-top: 16px;
  font-size: 13px;
  color: var(--p1-text-muted);
}

/* Quote card — white surface, green left accent, brand border */
.entry-card {
  background: var(--p1-white);
  border: 1px solid var(--p1-border);
  border-left: 4px solid var(--p1-green);
  border-radius: var(--radius-card);
  padding: 36px 40px;
  box-shadow: var(--shadow-card);
}

.entry-card-inner {
  display: flex;
  gap: 20px;
  margin-bottom: 28px;
}

.avatar {
  width: 52px;
  height: 52px;
  border-radius: 50%;
  background: var(--p1-dark);
  color: #fff;
  font-size: 13px;
  font-weight: 600;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  letter-spacing: 0.04em;
}

.entry-quote { border: none; padding: 0; }

.entry-quote p {
  font-size: 15px;
  font-weight: 400;
  color: var(--p1-text-muted);
  line-height: 1.72;
  margin-bottom: 12px;
}

.entry-quote p:last-of-type { margin-bottom: 10px; }

.entry-quote cite {
  font-style: normal;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.cite-name {
  font-size: 26px;
  font-weight: 600;
  color: var(--p1-text-muted);
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.cite-title {
  font-size: 14px;
  font-weight: 400;
  color: var(--p1-text-muted);
  letter-spacing: 0.01em;
}

.entry-card-cta { text-align: center; padding-top: 4px; }

/* ─── SURVEY SCREEN ─── */
.screen-survey {
  padding: 52px 0 80px;
  min-height: calc(100vh - 67px);
}

.progress-wrap {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-bottom: 52px;
}

.progress-bar {
  flex: 1;
  height: 4px;
  background: var(--p1-border);
  border-radius: 2px;
  overflow: hidden;
}

.progress-fill {
  height: 100%;
  background: var(--p1-green);
  border-radius: 2px;
  width: 0%;
  transition: width 0.45s cubic-bezier(0.4, 0, 0.2, 1);
}

.progress-label {
  font-size: 12px;
  font-weight: 500;
  color: var(--p1-text-muted);
  letter-spacing: 0.04em;
  white-space: nowrap;
  min-width: 110px;
  text-align: right;
}

/* Question uses DM Serif Display — "H1 heading" tier */
.question { animation: fadeUp 0.25s ease both; }
.question.hidden { display: none; }

.question-text {
  font-family: var(--font-display);
  font-size: clamp(21px, 3vw, 28px);
  font-weight: 400;
  line-height: 1.25;
  color: var(--p1-dark);
  margin-bottom: 28px;
  letter-spacing: -0.01em;
}

.options { display: flex; flex-direction: column; gap: 10px; }

.option {
  background: var(--p1-white);
  border: 1.5px solid var(--p1-border);
  border-radius: var(--radius-card);
  padding: 16px 20px;
  font-size: 15px;
  font-weight: 400;
  font-family: var(--font-body);
  color: var(--p1-text);
  text-align: left;
  cursor: pointer;
  line-height: 1.5;
  transition: border-color 0.15s, background 0.15s, transform 0.1s;
}

.option:hover {
  border-color: var(--p1-green);
  background: var(--p1-green-pale);
  transform: translateX(4px);
}

.option:focus-visible {
  outline: 2px solid var(--p1-green);
  outline-offset: 2px;
}

/* Selected state — Platform Black, white text (strong confirmation) */
.option.selected {
  border-color: var(--p1-dark);
  background: var(--p1-dark);
  color: var(--p1-white);
  transform: translateX(4px);
}

/* ─── GATE SCREEN ─── */
.screen-gate {
  padding: 80px 0;
  min-height: calc(100vh - 67px);
}

.gate-card {
  background: var(--p1-white);
  border: 1px solid var(--p1-border);
  border-top: 4px solid var(--p1-green);
  border-radius: var(--radius-card);
  padding: 48px;
  box-shadow: var(--shadow-card);
}

.gate-headline {
  font-family: var(--font-display);
  font-size: clamp(24px, 3vw, 32px);
  font-weight: 400;
  line-height: 1.2;
  color: var(--p1-dark);
  margin-bottom: 14px;
}

.gate-body {
  font-size: 16px;
  color: var(--p1-text-muted);
  line-height: 1.7;
  margin-bottom: 8px;
}

.gate-form { margin-top: 28px; }

.form-field { margin-bottom: 16px; }

.form-field label {
  display: block;
  font-size: 13px;
  font-weight: 600;
  color: var(--p1-text-muted);
  margin-bottom: 6px;
  letter-spacing: 0.01em;
}

.form-field input {
  width: 100%;
  padding: 12px 14px;
  border: 1.5px solid var(--p1-border);
  border-radius: var(--radius-btn);
  font-size: 15px;
  font-family: var(--font-body);
  color: var(--p1-text);
  background: var(--p1-offwhite);
  transition: border-color 0.15s, background 0.15s;
}

.form-field input:focus {
  outline: none;
  border-color: var(--p1-green);
  background: var(--p1-white);
}

.form-field input::placeholder { color: #a0a890; }

.form-error {
  font-size: 13px;
  font-weight: 500;
  color: #8f2222;
  margin-bottom: 12px;
}

.form-error.hidden { display: none; }

.form-trust {
  margin-top: 12px;
  font-size: 12px;
  color: var(--p1-text-muted);
  line-height: 1.6;
}

/* ─── RESULT SCREENS ─── */
.screen-result { padding: 80px 0 100px; min-height: calc(100vh - 67px); }

/* Result badge pill */
.result-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-body);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  padding: 6px 14px;
  border-radius: 100px;
  margin-bottom: 20px;
}

.result-badge::before {
  content: '';
  display: block;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  flex-shrink: 0;
}

/* A — Platform Green (strong positive) */
.result-badge-a         { background: var(--p1-green-pale); color: var(--p1-green); }
.result-badge-a::before { background: var(--p1-green); }

/* B — Lime (progress, warmth) */
.result-badge-b         { background: #f0f5e4; color: #5c7830; }
.result-badge-b::before { background: var(--p1-green-bright); }

/* C — Neutral warm grey */
.result-badge-c         { background: #eeede9; color: #5a5a50; }
.result-badge-c::before { background: #9a9a8a; }

/* Headline — DM Serif Display */
.result-headline {
  font-family: var(--font-display);
  font-size: clamp(24px, 3.5vw, 36px);
  font-weight: 400;
  line-height: 1.15;
  color: var(--p1-dark);
  margin-bottom: 28px;
  max-width: 580px;
}

/* Body — pale green left rule (brand section-divider pattern) */
.result-body {
  margin-bottom: 44px;
  max-width: 580px;
  padding-left: 20px;
  border-left: 3px solid var(--p1-green-pale);
}

.result-body p {
  font-size: 16px;
  font-weight: 400;
  color: var(--p1-text-muted);
  line-height: 1.75;
  margin-bottom: 16px;
}

.result-body p:last-child { margin-bottom: 0; }

.result-trust {
  margin-top: 14px;
  font-size: 13px;
  color: var(--p1-text-muted);
  line-height: 1.6;
  max-width: 420px;
}

/* ─── BUTTONS ─── */
/* Per guidelines: Primary = Platform Green #5A7A3A, white text, 4px radius
                   Secondary = outline, Platform Green border and text         */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 13px 26px;
  border-radius: var(--radius-btn);
  font-size: 15px;
  font-weight: 600;
  font-family: var(--font-body);
  border: 1.5px solid transparent;
  cursor: pointer;
  text-decoration: none;
  line-height: 1;
  letter-spacing: 0.01em;
  transition: background 0.15s, color 0.15s, border-color 0.15s, transform 0.1s;
  white-space: nowrap;
}

.btn:active { transform: scale(0.98); }

.btn-primary {
  background: var(--p1-green);
  color: var(--p1-white);
  border-color: var(--p1-green);
}

.btn-primary:hover {
  background: var(--p1-mid);
  border-color: var(--p1-mid);
  text-decoration: none;
  color: var(--p1-white);
}

.btn-secondary {
  background: transparent;
  color: var(--p1-green);
  border-color: var(--p1-green);
}

.btn-secondary:hover {
  background: var(--p1-green);
  color: var(--p1-white);
  text-decoration: none;
}

.btn-large  { padding: 16px 32px; font-size: 16px; }
.btn-full   { width: 100%; }

.btn:disabled,
.btn.loading { opacity: 0.6; cursor: not-allowed; transform: none; }

.btn:focus-visible { outline: 2px solid var(--p1-green); outline-offset: 3px; }

/* ─── FOOTER ─── */
/* Per guidelines: Digital Teal (#3898B8) — approved for footer only, never print */
.footer {
  background: var(--p1-digital);
  padding: 24px 0;
  margin-top: auto;
}

.footer-text {
  font-size: 13px;
  color: rgba(255,255,255,0.65);
  text-align: center;
  font-weight: 400;
}

.footer-text a { color: rgba(255,255,255,0.85); }
.footer-text a:hover { color: #fff; text-decoration: underline; }

/* ─── ANIMATIONS ─── */
@keyframes fadeUp {
  from { opacity: 0; transform: translateY(10px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* ─── EXPLAINER BLOCK (P1.2) ─── */
.explainer {
  max-width: 580px;
  margin: 0 auto 52px;
  text-align: center;
}

.explainer p {
  font-size: 16px;
  color: var(--p1-text-muted);
  line-height: 1.75;
  margin-bottom: 12px;
}

.explainer p:last-child { margin-bottom: 0; }

/* ─── STATS STRIP (P1.3) ─── */
.stats-strip {
  display: flex;
  justify-content: center;
  gap: 0;
  margin-bottom: 56px;
  border: 1px solid var(--p1-border);
  border-radius: var(--radius-card);
  background: var(--p1-white);
  overflow: hidden;
}

.stat {
  flex: 1;
  text-align: center;
  padding: 28px 20px;
  border-right: 1px solid var(--p1-border);
}

.stat:last-child { border-right: none; }

.stat-number {
  font-family: var(--font-display);
  font-size: clamp(28px, 4vw, 40px);
  font-weight: 400;
  color: var(--p1-green);
  line-height: 1;
  margin-bottom: 8px;
  letter-spacing: -0.01em;
}

.stat-label {
  font-size: 12px;
  font-weight: 500;
  color: var(--p1-text-muted);
  letter-spacing: 0.04em;
  line-height: 1.4;
}

/* ─── AVATAR PHOTO (P1.10A) ─── */
.avatar-photo {
  width: 104px;
  height: 104px;
  border-radius: 50%;
  object-fit: cover;
  flex-shrink: 0;
  border: 2px solid var(--p1-border);
}

/* ─── LINKEDIN ICON LINK (P1.10B) ─── */
.linkedin-link {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  color: var(--p1-text-muted);
  text-decoration: none;
  vertical-align: middle;
  margin-left: 8px;
  transition: color 0.15s;
}

.linkedin-link:hover { color: var(--p1-green); text-decoration: none; }

.linkedin-link svg { display: block; flex-shrink: 0; }

/* ─── BACK BUTTON (P2.2) ─── */
.back-btn {
  background: none;
  border: none;
  padding: 0;
  font-size: 13px;
  font-family: var(--font-body);
  font-weight: 500;
  color: var(--p1-text-muted);
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-top: 24px;
  letter-spacing: 0.01em;
  transition: color 0.15s;
  text-decoration: none;
}

.back-btn::before { content: '←'; font-size: 14px; }

.back-btn:hover { color: var(--p1-green); text-decoration: none; }

/* ─── CALL AGENDA (P1.6 — Result A) ─── */
.call-agenda {
  background: var(--p1-green-pale);
  border: 1px solid var(--p1-border);
  border-radius: var(--radius-card);
  padding: 24px 28px;
  margin-bottom: 32px;
  max-width: 480px;
}

.call-agenda-label {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--p1-green);
  margin-bottom: 12px;
  display: block;
}

.call-agenda ul {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.call-agenda li {
  font-size: 14px;
  color: var(--p1-text);
  line-height: 1.5;
  padding-left: 18px;
  position: relative;
}

.call-agenda li::before {
  content: '✓';
  position: absolute;
  left: 0;
  color: var(--p1-green);
  font-size: 13px;
  font-weight: 600;
}

/* ─── CONTACT LINE (P1.10C — below CTAs on result screens) ─── */
.contact-line {
  margin-top: 20px;
  font-size: 13px;
  color: var(--p1-text-muted);
  line-height: 1.7;
}

.contact-line a { color: var(--p1-green); }
.contact-line a:hover { text-decoration: underline; }

/* ─── FOOTER CONTACT STRIP (P1.10D) ─── */
.footer-contact {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
  margin-top: 8px;
  font-size: 13px;
  color: rgba(255,255,255,0.55);
  font-weight: 400;
}

.footer-contact a {
  color: rgba(255,255,255,0.55);
  font-size: 13px;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  text-decoration: none;
  transition: color 0.15s;
}

.footer-contact a:hover { color: rgba(255,255,255,0.85); text-decoration: none; }

.footer-linkedin-icon { display: inline-flex; align-items: center; color: rgba(255,255,255,0.55); }

/* ─── NO-JS MESSAGE (P2.4) ─── */
.noscript-msg {
  background: #fff8e6;
  border: 1px solid #e0c84a;
  border-radius: var(--radius-btn);
  padding: 16px 20px;
  font-size: 14px;
  color: #6b5800;
  text-align: center;
  margin: 24px auto;
  max-width: 480px;
}

/* ─── RESPONSIVE ─── */
@media (max-width: 600px) {
  .entry-card {
    padding: 24px 20px;
  }

  .entry-card-inner {
    flex-direction: column;
    gap: 16px;
  }

  .gate-card {
    padding: 28px 20px;
  }

  .screen-entry {
    padding: 48px 0 56px;
  }

  .progress-wrap {
    margin-bottom: 36px;
  }

  .progress-label {
    display: none;
  }

  .result-headline,
  .result-body {
    max-width: 100%;
  }

  .result-body {
    border-left: none;
    padding-left: 0;
  }

  /* P2.3: stat strip stacks vertically below 600px */
  .stats-strip {
    flex-direction: column;
    max-width: 280px;
    margin-left: auto;
    margin-right: auto;
  }

  .stat {
    border-right: none;
    border-bottom: 1px solid var(--p1-border);
    padding: 20px;
  }

  .stat:last-child { border-bottom: none; }

  .call-agenda { max-width: 100%; }

  .footer-contact { gap: 16px; }
}

@media (max-width: 480px) {
  /* P2.3: hide header meta text on narrow phones */
  .header-meta { display: none; }
}
