/* ==========================================================================
   Propdex — propdex.ai
   Design language: calm financial authority. Emerald on near-white,
   forest panels, soft low-spread elevation. Typeface: Manrope.
   Source of truth: Propdex Brand Guidelines (2026).
   ========================================================================== */

:root {
  /* --- Primary emerald palette (brand guide) ------------------------------ */
  --emerald: #059669;          /* primary identity colour */
  --emerald-deep: #047857;     /* hover + inline links (AA on white) */
  --emerald-darker: #065F46;   /* active / high-contrast */
  --forest: #064E3B;           /* deep forest — dark panels */
  --forest-deep: #053D2F;      /* panel gradient base */
  --mint: #34D399;             /* bright accent */
  --mint-soft: #A7F3D0;        /* soft accent borders, selection */
  --tint: #ECFDF5;             /* pale emerald wash — chips, badges, fills */
  --tint-2: #D1FAE5;           /* slightly stronger tint */

  /* --- Grayscale ---------------------------------------------------------- */
  --space: #9DA2B3;            /* neutral marker (the "other AI" cross) */
  --graphite: #6E7180;

  /* --- Surfaces ----------------------------------------------------------- */
  --white: #FFFFFF;
  --surface-subtle: #FAFAF9;   /* near-white section band */
  --surface-muted: #F4F7F5;    /* chat / inset surfaces */

  /* --- Text --------------------------------------------------------------- */
  --text-strong: #0F172A;      /* headings (cool near-black) */
  --text-body: #475569;        /* body copy */
  --text-muted: #64748B;       /* secondary / captions */
  --text-on-forest: #D6E9E1;   /* body text on forest panels */

  /* --- Borders ------------------------------------------------------------ */
  --border: #E2E8F0;

  /* --- Radii -------------------------------------------------------------- */
  --radius: 14px;
  --radius-sm: 10px;
  --radius-lg: 20px;
  --radius-xl: 28px;

  /* --- Shadows (calm elevation) ------------------------------------------- */
  --shadow-sm: 0 1px 3px 0 rgba(15, 23, 42, 0.06), 0 1px 2px -1px rgba(15, 23, 42, 0.05);
  --shadow-md: 0 4px 6px -1px rgba(15, 23, 42, 0.08), 0 2px 4px -2px rgba(15, 23, 42, 0.05);

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

/* --- Reset / base ------------------------------------------------------- */

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

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: var(--font);
  font-size: 1.0625rem;
  line-height: 1.7;
  color: var(--text-body);
  background: var(--white);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

h1, h2, h3 {
  color: var(--text-strong);
  line-height: 1.14;
  margin: 0 0 1rem;
}

h1 {
  font-size: clamp(2.25rem, 5.5vw, 3.375rem);
  font-weight: 800;
  letter-spacing: -0.03em;
}

h2 {
  font-size: clamp(1.625rem, 3.4vw, 2.25rem);
  font-weight: 800;
  letter-spacing: -0.02em;
}

h3 {
  font-size: 1.125rem;
  font-weight: 700;
  letter-spacing: -0.01em;
  margin-bottom: 0.5rem;
}

p {
  margin: 0 0 1rem;
}

a {
  color: var(--emerald-deep);
  text-decoration: none;
}

a:hover {
  text-decoration: underline;
}

::selection {
  background: var(--mint-soft);
  color: var(--forest);
}

:focus-visible {
  outline: 3px solid var(--emerald-deep); /* solid — 5.48:1 on white (WCAG 1.4.11) */
  outline-offset: 2px;
  border-radius: 4px;
}

[id] {
  scroll-margin-top: 92px;
}

/* --- Utilities ----------------------------------------------------------- */

.container {
  max-width: 1080px;
  margin: 0 auto;
  padding-inline: 24px;
}

.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: 16px;
  top: -64px;
  z-index: 100;
  padding: 10px 16px;
  background: var(--forest);
  color: var(--white);
  border-radius: var(--radius-sm);
  font-weight: 600;
}

.skip-link:focus {
  top: 12px;
}

.kicker {
  display: block;
  font-size: 0.8125rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--emerald-deep);
  margin-bottom: 0.875rem;
}

.honey {
  position: absolute !important;
  left: -9999px !important;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

/* --- Buttons ------------------------------------------------------------- */

.btn {
  display: inline-block;
  padding: 13px 24px;
  border: 0;
  border-radius: var(--radius-sm);
  font-family: var(--font);
  font-size: 1.0625rem;
  font-weight: 700;
  letter-spacing: -0.01em;
  line-height: 1.3;
  cursor: pointer;
  text-decoration: none;
  transition: background-color 0.15s ease, border-color 0.15s ease;
}

.btn:hover {
  text-decoration: none;
}

.btn-primary {
  background: var(--emerald-deep); /* #047857 — white text 5.48:1 (AA) */
  color: var(--white);
}

.btn-primary:hover {
  background: var(--emerald-darker); /* #065F46 — white text 7.09:1 */
}

.btn-secondary {
  background: var(--white);
  color: var(--emerald-deep);
  border: 1px solid var(--border);
}

.btn-secondary:hover {
  border-color: var(--emerald);
}

/* --- Header / nav --------------------------------------------------------- */

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(250, 250, 249, 0.94);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--border);
}

.nav {
  display: flex;
  align-items: center;
  gap: 32px;
  min-height: 68px;
}

.wordmark {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 1.375rem;
  font-weight: 800;
  letter-spacing: -0.03em;
  color: var(--forest);
  text-decoration: none;
}

.logo-mark {
  display: block;
  flex: none;
  height: 28px;
  width: auto;
}

.wordmark:hover {
  text-decoration: none;
}

.nav-links {
  display: flex;
  gap: 28px;
  margin-left: auto;
}

.nav-links a {
  padding: 12px 0; /* widen hit area in the 68px bar */
  font-size: 0.9375rem;
  font-weight: 500;
  color: var(--text-strong);
}

.nav-links a:hover {
  color: var(--emerald-deep);
  text-decoration: none;
}

.btn-nav {
  padding: 10px 18px;
  font-size: 0.9375rem;
  min-height: 44px; /* tap target */
  display: inline-flex;
  align-items: center;
}

@media (max-width: 819px) {
  .nav-links {
    display: none;
  }

  .nav .btn-nav {
    margin-left: auto;
  }
}

/* --- Sections ------------------------------------------------------------- */

section {
  padding: 3.75rem 0;
}

@media (min-width: 720px) {
  section {
    padding: 5.5rem 0;
  }
}

.section-narrow {
  max-width: 720px;
}

.section-center {
  max-width: 720px;
  margin-inline: auto;
  text-align: center;
}

.lede {
  font-size: 1.1875rem;
}

.band {
  background: var(--surface-subtle);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}

/* --- Hero ------------------------------------------------------------------ */

.hero {
  padding-top: 4rem;
  background: var(--white);
}

.hero-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 56px;
  align-items: center;
}

@media (min-width: 920px) {
  .hero-grid {
    grid-template-columns: 1.05fr 0.95fr;
    gap: 72px;
  }
}

.hero-badge {
  display: inline-block;
  padding: 6px 14px;
  border: 1px solid var(--mint-soft);
  border-radius: 999px;
  background: var(--tint);
  color: var(--emerald-deep);
  font-size: 0.8125rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  margin-bottom: 1.5rem;
}

.hero h1 {
  line-height: 1.12;
}

.hero-sub {
  font-size: 1.1875rem;
  max-width: 34rem;
  margin-bottom: 1.75rem;
}

/* --- WhatsApp waitlist CTA ---------------------------------------------- */

.btn-whatsapp {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding-inline: 24px;
  font-size: 1rem;
  box-shadow: var(--shadow-sm);
}

.section-center .btn-whatsapp {
  margin-inline: auto;
}

.form-note {
  font-size: 0.9375rem;
  margin: 0.875rem 0 0.25rem;
}

.form-privacy {
  font-size: 0.8125rem;
  color: var(--text-muted);
  margin: 0;
}

/* --- Chat mockup ---------------------------------------------------------------- */

.phone {
  margin: 0;
  max-width: 420px;
  justify-self: center;
  width: 100%;
}

.phone-frame {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: 28px;
  padding: 10px;
  box-shadow: var(--shadow-md);
}

.phone-top {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 14px;
  border-bottom: 1px solid var(--border);
}

.phone-avatar {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: var(--emerald);
  flex: none;
}

.phone-name {
  font-size: 0.9375rem;
  font-weight: 600;
  color: var(--text-strong);
  line-height: 1.3;
}

.phone-status {
  display: block;
  font-size: 0.75rem;
  font-weight: 400;
  color: var(--text-muted);
}

.chat {
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: 16px 12px 14px;
  background: var(--surface-muted);
  border-radius: 0 0 20px 20px;
}

.bubble {
  max-width: 88%;
  padding: 10px 14px;
  font-size: 0.875rem;
  line-height: 1.55;
  color: var(--text-strong);
}

.bubble p {
  margin: 0;
}

.bubble-user {
  align-self: flex-end;
  background: #D7F2E4;
  border-radius: 16px 16px 4px 16px;
}

.bubble-reply {
  align-self: flex-start;
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: 16px 16px 16px 4px;
}

.citation-chip {
  display: inline-block;
  margin-top: 10px;
  padding: 3px 10px;
  background: var(--tint);
  border: 1px solid var(--mint-soft);
  border-radius: 999px;
  color: var(--emerald-deep);
  font-size: 0.71875rem;
  font-weight: 600;
  letter-spacing: 0.01em;
}

.phone-caption {
  margin-top: 10px;
  text-align: center;
  font-size: 0.8125rem;
  color: var(--text-muted);
}

/* --- Trust cards ("Built to be right") ------------------------------------------- */

.card-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 20px;
  margin-top: 2.25rem;
}

@media (min-width: 720px) {
  .card-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

.card {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 28px 26px;
  box-shadow: var(--shadow-sm);
}

.card p {
  font-size: 0.9844rem;
  margin: 0;
}

.card-rule {
  width: 28px;
  height: 3px;
  background: var(--emerald);
  border-radius: 2px;
  margin-bottom: 1.125rem;
}

/* --- Propdex vs other AI comparison (#comparison) --------------------------------- */

.cmp-lede {
  max-width: 40rem;
  margin-bottom: 2.5rem;
}

.cmp-head {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
  margin-bottom: 0.875rem;
}

.cmp-head-title {
  margin: 0;
  font-size: 1.25rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: var(--graphite);
}

.cmp-head-title.cmp-head-mine {
  color: var(--forest);
}

.cmp-head-sub {
  margin: 2px 0 0;
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--text-muted);
}

.cmp-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px 24px;
  align-items: stretch;
}

.cmp-rowlabel {
  grid-column: 1 / -1;
  margin-top: 0.5rem;
}

.cmp-rowlabel span {
  display: block;
  font-size: 0.8125rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--emerald-deep);
}

.cmp-card {
  display: flex;
  gap: 14px;
  border-radius: var(--radius);
  padding: 20px 22px;
}

.cmp-card p {
  margin: 0;
  font-size: 1rem;
  line-height: 1.5;
  font-weight: 500;
}

.cmp-card b {
  font-weight: 800;
}

.cmp-card--mine {
  background: var(--tint);
  border: 1px solid var(--mint-soft);
  border-left: 3px solid var(--emerald);
}

.cmp-card--mine p {
  color: var(--forest);
}

.cmp-card--other {
  background: #F8FAFC;
  border: 1px solid var(--border);
}

.cmp-card--other p {
  color: var(--text-muted);
}

.cmp-icon {
  flex: none;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--white);
}

.cmp-icon svg {
  width: 15px;
  height: 15px;
}

.cmp-icon--yes {
  background: var(--emerald);
}

.cmp-icon--no {
  background: var(--space);
}

/* Per-card "Propdex" / "Other AI" label: read by assistive tech always,
   shown to sighted users only when the two columns stack on mobile (the
   column headers then no longer sit above their cards). */
.cmp-tag {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

.cmp-punch {
  text-align: center;
  margin: 2.5rem auto 0;
  max-width: 44rem;
  font-size: clamp(1.125rem, 2.2vw, 1.375rem);
  font-weight: 800;
  letter-spacing: -0.01em;
  color: var(--text-strong);
}

@media (max-width: 919px) {
  .cmp-head {
    display: none; /* header labels only make sense above two live columns */
  }

  .cmp-grid {
    grid-template-columns: 1fr;
    gap: 12px;
  }

  .cmp-tag {
    position: static;
    width: auto;
    height: auto;
    margin: 0 0 4px;
    clip: auto;
    display: block;
    font-size: 0.6875rem;
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: var(--text-muted);
  }

  .cmp-card--mine .cmp-tag {
    color: var(--emerald-deep);
  }
}

/* --- How it works (numbered steps) ----------------------------------------------- */

.steps {
  display: grid;
  grid-template-columns: 1fr;
  gap: 36px;
  margin: 2.5rem 0 0;
  padding: 0;
  list-style: none;
  counter-reset: step;
}

@media (min-width: 720px) {
  .steps {
    grid-template-columns: repeat(3, 1fr);
    gap: 32px;
  }
}

.steps li {
  counter-increment: step;
  border-top: 1px solid var(--border);
  padding-top: 1.5rem;
}

.steps li::before {
  content: "0" counter(step);
  display: block;
  font-size: 0.875rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  color: var(--emerald-deep);
  margin-bottom: 0.75rem;
}

.steps p {
  font-size: 0.9844rem;
  margin: 0;
}

/* --- Ask chips ----------------------------------------------------------------------- */

.chips {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 2rem 0 0;
  padding: 0;
  list-style: none;
}

.chips li {
  padding: 9px 18px;
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: 999px;
  font-size: 0.9375rem;
  color: var(--text-strong);
  transition: border-color 0.15s ease, background-color 0.15s ease;
}

.chips li:hover {
  border-color: var(--emerald);
  background: var(--tint);
}

/* --- Forest panel (privacy) ------------------------------------------------------------ */

.panel-forest {
  background: linear-gradient(165deg, var(--forest), var(--forest-deep));
  border-radius: var(--radius-lg);
  padding: clamp(36px, 6vw, 64px);
  color: var(--text-on-forest);
}

.panel-forest .kicker {
  color: var(--mint);
}

.panel-forest h2 {
  color: var(--white);
}

.panel-forest p {
  max-width: 46rem;
  font-size: 1.0625rem;
}

.panel-forest a {
  color: var(--mint);
  font-weight: 600;
}

.panel-forest a:focus-visible {
  outline-color: var(--mint); /* solid — 5.06:1 on forest */
}

/* --- FAQ ------------------------------------------------------------------------------------ */

.faq-list {
  max-width: 760px;
  margin: 2rem auto 0;
  border-top: 1px solid var(--border);
}

.faq-list details {
  border-bottom: 1px solid var(--border);
}

.faq-list summary {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 16px;
  padding: 1.125rem 0.25rem;
  font-size: 1.0625rem;
  font-weight: 600;
  color: var(--text-strong);
  cursor: pointer;
  list-style: none;
}

.faq-list summary::-webkit-details-marker {
  display: none;
}

.faq-list summary::after {
  content: "\FF0B";           /* fullwidth plus, matching the design */
  content: "\FF0B" / "";      /* alt-text syntax mutes the glyph for AT; <details> conveys state */
  flex: none;
  font-size: 1.25rem;
  font-weight: 500;
  color: var(--emerald-deep);
  line-height: 1;
}

.faq-list details[open] summary::after {
  content: "\2013";           /* en dash */
  content: "\2013" / "";
}

.faq-list details p {
  padding: 0 0.25rem;
  margin: 0 0 1.25rem;
  max-width: 44rem;
  font-size: 0.9844rem;
}

/* --- Closing CTA / thanks --------------------------------------------------------------------- */

.thanks {
  display: none;
}

.thanks:target {
  display: block;
  max-width: 30rem;
  margin: 0 auto 1.75rem;
  padding: 14px 20px;
  background: var(--tint);
  border: 1px solid var(--mint-soft);
  border-radius: var(--radius);
  color: var(--emerald-darker);
  font-size: 0.9375rem;
  font-weight: 500;
}

/* In-page acknowledgment injected by form.js in place of a submitted form */
.form-ack {
  display: flex;
  align-items: center;
  gap: 10px;
  max-width: 30rem;
  margin: 0 0 1rem;
  padding: 14px 18px;
  background: var(--tint);
  border: 1px solid var(--mint-soft);
  border-radius: 12px;
  color: var(--emerald-darker);
  font-size: 0.9375rem;
  font-weight: 600;
}

.section-center .form-ack {
  margin-inline: auto;
  display: inline-flex;
  text-align: left;
}

/* --- Footer -------------------------------------------------------------------------------------- */

.site-footer {
  border-top: 1px solid var(--border);
  background: var(--surface-subtle);
  padding: 3.5rem 0 2.5rem;
  font-size: 0.875rem;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 32px;
}

@media (min-width: 720px) {
  .footer-grid {
    grid-template-columns: 1.2fr 1fr;
    gap: 64px;
  }
}

.footer-tag {
  margin: 0.875rem 0 0;
  max-width: 24rem;
}

.footer-meta p {
  margin: 0 0 0.625rem;
}

.footer-links {
  display: flex;
  gap: 20px;
  margin: 0.25rem 0 0.875rem;
}

.footer-links a {
  display: inline-block;
  padding: 10px 0; /* tap target */
  font-weight: 500;
}

.footer-copy {
  color: var(--text-muted);
}

/* --- Legal pages ------------------------------------------------------------------------------------ */

.legal {
  max-width: 760px;
  margin: 0 auto;
  padding: 3.5rem 24px 4.5rem;
}

.legal h1 {
  font-size: clamp(2rem, 4.5vw, 2.625rem);
}

.legal h2 {
  font-size: 1.375rem;
  font-weight: 800;
  margin-top: 2.5rem;
}

.legal ul {
  padding-left: 1.25rem;
  margin: 0 0 1rem;
}

.legal li {
  margin-bottom: 0.5rem;
}

/* --- Reduced motion ----------------------------------------------------------------------------------- */

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    transition: none !important;
    animation: none !important;
  }
}
