/* ===========================================================================
   PROppeal — brand stylesheet
   Palette & type per the PROppeal Brand Guidelines v1.0.
   Navy leads (trust); amber is the single loud accent; green signals savings.
   =========================================================================== */

:root {
  /* Core brand */
  --ink: #03093b;        /* primary text, wordmark "ppeal" */
  --navy: #49557d;       /* brand navy — house mark, UI tint */
  --navy-700: #3e4a6e;   /* darker navy for contrast on fills */
  --orange: #fa8c2b;     /* logo accent — the "PRO", the arrow */
  --amber: #fca311;      /* in-app accent & highlights, CTAs */
  --amber-ink: #8a5a02;  /* readable text on amber fills */
  --green: #1f6b4a;      /* money-positive / savings */
  --mist: #dcdff0;       /* logo tonal split; light fills */
  --cloud: #ecece8;      /* app background (light) */
  --slate: #6e8898;      /* secondary text, captions */

  /* Derived neutrals */
  --white: #ffffff;
  --surface: #ffffff;
  --muted: #5c6b86;
  --border: #e2e0da;
  --border-strong: #d8d6d0;

  /* Type */
  --font: "Poppins", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;

  /* Layout */
  --maxw: 1120px;
  --radius: 16px;
  --radius-sm: 12px;
  --shadow-sm: 0 1px 2px rgba(3, 9, 59, 0.06), 0 1px 3px rgba(3, 9, 59, 0.08);
  --shadow-md: 0 8px 24px rgba(3, 9, 59, 0.08), 0 2px 6px rgba(3, 9, 59, 0.06);
  --shadow-lg: 0 24px 60px rgba(3, 9, 59, 0.16), 0 6px 16px rgba(3, 9, 59, 0.1);
}

/* ---------- Reset / base ---------- */
*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  font-family: var(--font);
  font-weight: 400;
  color: var(--ink);
  background: var(--cloud);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

h1,
h2,
h3 {
  margin: 0 0 0.4em;
  line-height: 1.12;
  letter-spacing: -0.02em;
  font-weight: 700;
  color: var(--ink);
}

p {
  margin: 0 0 1rem;
}

a {
  color: var(--navy-700);
  text-decoration: none;
}
a:hover {
  text-decoration: underline;
}

img,
svg {
  display: block;
  max-width: 100%;
}

/* ---------- Helpers ---------- */
.container {
  width: 100%;
  max-width: var(--maxw);
  margin-inline: auto;
  padding-inline: clamp(1.1rem, 4vw, 2rem);
}
.container-narrow {
  max-width: 760px;
}

.visually-hidden {
  position: absolute !important;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

.skip-link {
  position: absolute;
  left: 50%;
  top: 0.5rem;
  transform: translateX(-50%) translateY(-200%);
  background: var(--ink);
  color: #fff;
  padding: 0.6rem 1rem;
  border-radius: 8px;
  z-index: 100;
  transition: transform 0.15s ease;
}
.skip-link:focus {
  transform: translateX(-50%) translateY(0);
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.45rem;
  font-family: var(--font);
  font-weight: 600;
  font-size: 1rem;
  line-height: 1;
  padding: 0.95rem 1.5rem;
  border-radius: 14px;
  border: 1px solid transparent;
  cursor: pointer;
  transition: transform 0.12s ease, box-shadow 0.2s ease, background-color 0.2s ease;
  white-space: nowrap;
}
.btn:hover {
  text-decoration: none;
}
.btn-accent {
  background: var(--amber);
  color: var(--amber-ink);
  box-shadow: var(--shadow-sm);
}
.btn-accent:hover {
  background: #ffb02e;
  transform: translateY(-1px);
  box-shadow: var(--shadow-md);
}
.btn-accent:active {
  transform: translateY(0);
}
.btn-sm {
  padding: 0.6rem 1rem;
  font-size: 0.92rem;
  border-radius: 11px;
}

:where(a, button, input, summary):focus-visible {
  outline: 3px solid var(--amber);
  outline-offset: 2px;
  border-radius: 6px;
}

/* ---------- Wordmark ---------- */
.wordmark {
  font-weight: 700;
  letter-spacing: -0.01em;
  color: var(--ink);
  font-size: 1.35rem;
}
.wordmark-pro {
  color: var(--orange);
}
.wordmark.sm {
  font-size: 1.05rem;
}
.wordmark.on-dark {
  color: var(--cloud);
  font-size: 1.5rem;
}

/* ---------- Header ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(236, 236, 232, 0.82);
  backdrop-filter: saturate(160%) blur(12px);
  -webkit-backdrop-filter: saturate(160%) blur(12px);
  border-bottom: 1px solid var(--border);
}
.header-inner {
  display: flex;
  align-items: center;
  gap: 1.25rem;
  min-height: 64px;
}
.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
}
.brand:hover {
  text-decoration: none;
}
.brand-mark {
  width: 30px;
  height: 30px;
  display: block;
}
.brand-mark svg {
  width: 100%;
  height: 100%;
}
.site-nav {
  display: flex;
  gap: 1.6rem;
  margin-left: auto;
  font-weight: 500;
  font-size: 0.96rem;
}
.site-nav a {
  color: var(--muted);
}
.site-nav a:hover {
  color: var(--ink);
  text-decoration: none;
}
.header-cta {
  margin-left: 0.25rem;
}

/* ---------- Sections ---------- */
.section {
  padding: clamp(3.5rem, 8vw, 6rem) 0;
}
.section-alt {
  background: var(--surface);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}
.section-title {
  font-size: clamp(1.7rem, 3.6vw, 2.5rem);
  max-width: 18ch;
}
.section-sub {
  color: var(--muted);
  font-size: 1.08rem;
  max-width: 56ch;
  margin-bottom: 2.5rem;
}

/* ---------- Hero ---------- */
.hero {
  padding: clamp(2.5rem, 6vw, 5rem) 0 clamp(3rem, 7vw, 5.5rem);
  background:
    radial-gradient(1100px 460px at 78% -8%, rgba(73, 85, 125, 0.14), transparent 60%),
    radial-gradient(680px 360px at 6% 8%, rgba(252, 163, 17, 0.1), transparent 60%);
}
.hero-grid {
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  gap: clamp(2rem, 5vw, 4rem);
  align-items: center;
}
.eyebrow {
  display: inline-block;
  font-weight: 600;
  font-size: 0.82rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--navy);
  background: rgba(73, 85, 125, 0.1);
  padding: 0.4rem 0.8rem;
  border-radius: 999px;
  margin-bottom: 1.1rem;
}
.hero h1 {
  font-size: clamp(2.4rem, 6vw, 3.9rem);
  letter-spacing: -0.03em;
}
.lede {
  font-size: clamp(1.05rem, 2vw, 1.25rem);
  color: var(--muted);
  max-width: 42ch;
  margin-bottom: 1.7rem;
}

/* ---------- Waitlist form ---------- */
.waitlist-form {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
  max-width: 460px;
}
.waitlist-form input[type="email"] {
  flex: 1 1 220px;
  min-width: 0;
  font-family: var(--font);
  font-size: 1rem;
  padding: 0.95rem 1.1rem;
  border-radius: 14px;
  border: 1px solid var(--border-strong);
  background: var(--white);
  color: var(--ink);
  box-shadow: var(--shadow-sm);
}
.waitlist-form input[type="email"]::placeholder {
  color: #9aa6ba;
}
.waitlist-form input[type="email"]:focus-visible {
  outline: 3px solid var(--amber);
  outline-offset: 1px;
  border-color: var(--amber);
}
.waitlist-form .btn {
  flex: 0 0 auto;
}
.hp-field {
  position: absolute !important;
  left: -9999px;
  width: 1px;
  height: 1px;
  opacity: 0;
  pointer-events: none;
}
.form-status {
  flex-basis: 100%;
  margin: 0.35rem 0 0;
  font-size: 0.92rem;
  font-weight: 500;
  min-height: 1.2em;
}
.form-status.is-ok {
  color: var(--green);
}
.form-status.is-err {
  color: #b4341f;
}
.form-note {
  margin-top: 0.75rem;
  font-size: 0.85rem;
  color: var(--slate);
}

/* ---------- Hero visual: sample letter ---------- */
.hero-visual {
  display: flex;
  flex-direction: column;
  align-items: center;
}
.letter-card {
  width: 100%;
  max-width: 380px;
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow-lg);
  padding: 1.4rem 1.4rem 1.6rem;
  transform: rotate(-1.4deg);
}
.letter-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-bottom: 0.9rem;
  border-bottom: 1px solid var(--border);
}
.letter-tag {
  font-size: 0.72rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--slate);
}
.letter-lines {
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
  margin: 1.1rem 0 1.3rem;
}
.letter-lines .ln {
  height: 9px;
  border-radius: 5px;
  background: var(--cloud);
}
.ln.w-70 { width: 70%; }
.ln.w-90 { width: 90%; }
.ln.w-50 { width: 50%; }

.savings-chip {
  display: flex;
  flex-direction: column;
  gap: 0.1rem;
  background: rgba(31, 107, 74, 0.08);
  border: 1px solid rgba(31, 107, 74, 0.25);
  border-radius: var(--radius-sm);
  padding: 0.85rem 1rem;
  margin-bottom: 1.2rem;
}
.savings-label {
  font-size: 0.74rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--green);
}
.savings-value {
  font-size: 1.7rem;
  font-weight: 700;
  color: var(--green);
}
.savings-value span {
  font-size: 0.9rem;
  font-weight: 500;
}
.comp-rows {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}
.comp-row {
  display: grid;
  grid-template-columns: 1fr auto;
  grid-template-areas: "addr price" "meta price";
  align-items: center;
  gap: 0 0.5rem;
  padding: 0.55rem 0.7rem;
  border-radius: 10px;
  background: var(--cloud);
  font-size: 0.84rem;
}
.comp-addr {
  grid-area: addr;
  font-weight: 600;
  color: var(--ink);
}
.comp-meta {
  grid-area: meta;
  font-size: 0.72rem;
  color: var(--slate);
}
.comp-price {
  grid-area: price;
  font-weight: 700;
  color: var(--navy);
}
.comp-row.is-subject {
  background: rgba(252, 163, 17, 0.12);
  border: 1px solid rgba(252, 163, 17, 0.4);
}
.comp-row.is-subject .comp-price {
  color: var(--amber-ink);
}
.visual-caption {
  margin-top: 1rem;
  font-size: 0.76rem;
  color: var(--slate);
  text-align: center;
}

/* ---------- Stats ---------- */
.stat-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1rem;
}
.stat {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.4rem 1.3rem;
  box-shadow: var(--shadow-sm);
}
.stat-big {
  font-size: clamp(1.6rem, 3vw, 2.1rem);
  font-weight: 700;
  color: var(--amber-ink);
  letter-spacing: -0.02em;
}
.stat-big.stat-savings {
  color: var(--green);
}
/* Word-based values (e.g. "Multi-source") shouldn't render at numeral size */
.stat-big.stat-word {
  font-size: clamp(1.25rem, 2.2vw, 1.55rem);
  hyphens: none;
}
.stat-title {
  font-weight: 600;
  font-size: 0.95rem;
  color: var(--ink);
}
.stat-body {
  font-size: 0.9rem;
  color: var(--muted);
}

/* ---------- Steps ---------- */
.steps {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1.25rem;
  counter-reset: step;
}
.step {
  position: relative;
  background: var(--cloud);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.6rem 1.5rem 1.5rem;
}
.section-alt .step {
  background: #f7f7f4;
}
.step-num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  border-radius: 11px;
  background: var(--navy);
  color: #fff;
  font-weight: 700;
  font-size: 1.05rem;
  margin-bottom: 0.9rem;
}
.step h3 {
  font-size: 1.18rem;
}
.step p {
  margin: 0;
  color: var(--muted);
  font-size: 0.97rem;
}

/* ---------- Honesty band ---------- */
.creed {
  background:
    radial-gradient(800px 400px at 85% 0%, rgba(252, 163, 17, 0.12), transparent 60%),
    linear-gradient(160deg, var(--ink), #1a2358 80%);
  color: var(--cloud);
}
.creed-inner {
  max-width: 760px;
}
.creed h2 {
  color: #fff;
  font-size: clamp(1.8rem, 4vw, 2.6rem);
}
.creed-lede {
  font-size: 1.15rem;
  color: #c8cce4;
  max-width: 60ch;
}
.creed-points {
  list-style: none;
  margin: 1.8rem 0 0;
  padding: 0;
  display: grid;
  gap: 0.7rem;
}
.creed-points li {
  position: relative;
  padding-left: 1.9rem;
  color: #dcdff0;
  font-size: 0.98rem;
}
.creed-points li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.45em;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: var(--amber);
  box-shadow: 0 0 0 4px rgba(252, 163, 17, 0.18);
}

/* ---------- FAQ ---------- */
.faq {
  display: flex;
  flex-direction: column;
  gap: 0.7rem;
}
.faq-item {
  background: var(--cloud);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 0 1.2rem;
}
.section-alt .faq-item {
  background: #f7f7f4;
}
.faq-item summary {
  list-style: none;
  cursor: pointer;
  font-weight: 600;
  font-size: 1.05rem;
  padding: 1.05rem 2rem 1.05rem 0;
  position: relative;
  color: var(--ink);
}
.faq-item summary::-webkit-details-marker {
  display: none;
}
.faq-item summary::after {
  content: "+";
  position: absolute;
  right: 0.1rem;
  top: 50%;
  transform: translateY(-50%);
  font-size: 1.5rem;
  font-weight: 400;
  color: var(--navy);
  transition: transform 0.2s ease;
}
.faq-item[open] summary::after {
  content: "–";
}
.faq-item p {
  margin: 0;
  padding: 0 0 1.15rem;
  color: var(--muted);
}

/* ---------- Final CTA band ---------- */
.cta-band {
  background: var(--surface);
  border-top: 1px solid var(--border);
}
.cta-inner {
  text-align: center;
  max-width: 640px;
}
.cta-inner h2 {
  font-size: clamp(1.8rem, 4vw, 2.6rem);
}
.cta-inner p {
  color: var(--muted);
  font-size: 1.1rem;
  margin-bottom: 1.8rem;
}
.waitlist-form-lg {
  margin-inline: auto;
  max-width: 500px;
  justify-content: center;
}
.cta-inner .form-status {
  text-align: center;
}

/* ---------- Footer ---------- */
.site-footer {
  background: var(--ink);
  color: #aab1d0;
  padding: clamp(2.5rem, 5vw, 3.5rem) 0 2rem;
}
.footer-inner {
  display: flex;
  flex-wrap: wrap;
  gap: 1.5rem 2rem;
  justify-content: space-between;
  align-items: flex-start;
  padding-bottom: 1.6rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}
.footer-brand p {
  margin: 0.5rem 0 0;
  max-width: 36ch;
  font-size: 0.95rem;
  color: #9aa1c2;
}
.footer-meta {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
  text-align: right;
  font-size: 0.92rem;
}
.footer-meta a {
  color: var(--amber);
  font-weight: 500;
}
.footer-soon {
  color: #7a82a6;
}
.footer-fine {
  padding-top: 1.4rem;
}
.footer-fine p {
  font-size: 0.78rem;
  color: #777fa3;
  max-width: 80ch;
  margin: 0 0 0.6rem;
}
.copyright {
  font-size: 0.8rem;
  color: #9aa1c2;
}

/* ---------- Reveal on scroll ---------- */
.reveal {
  opacity: 0;
  transform: translateY(16px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}
.reveal.is-visible {
  opacity: 1;
  transform: none;
}

/* ---------- Responsive ---------- */
@media (max-width: 920px) {
  .hero-grid {
    grid-template-columns: 1fr;
  }
  .hero-visual {
    order: -1;
    margin-bottom: 0.5rem;
  }
  .letter-card {
    transform: rotate(-1deg);
    max-width: 340px;
  }
  .stat-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 720px) {
  .site-nav {
    display: none;
  }
  .header-cta {
    margin-left: auto;
  }
}

@media (max-width: 560px) {
  .steps {
    grid-template-columns: 1fr;
  }
  .footer-inner {
    flex-direction: column;
  }
  .footer-meta {
    text-align: left;
  }
  .waitlist-form .btn {
    flex: 1 1 100%;
  }
}

/* ---------- Reduced motion ---------- */
@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
  .reveal {
    opacity: 1;
    transform: none;
    transition: none;
  }
  .btn,
  .btn:hover {
    transform: none;
  }
}
