/* ════════════════════════════════════════════════════════════════
   AI ResearchPartner — Page-specific overrides
   ════════════════════════════════════════════════════════════════ */

/* ── Audience-page hero (smaller than home hero) ── */
.audience-hero {
  padding: clamp(56px, 7vw, 96px) 0 clamp(32px, 5vw, 64px);
  text-align: center;
}
.audience-hero h1 {
  max-width: 920px;
  margin: 0 auto 18px;
}
.audience-hero .lead {
  margin: 0 auto 28px;
  font-style: italic;
}
.audience-hero .audience-eyebrow {
  margin-bottom: 14px;
  display: inline-block;
}

/* ── ROI calculator ── */
.roi {
  display: grid;
  grid-template-columns: 1fr 1.1fr;
  gap: 32px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-lg);
  padding: 36px;
}
@media (max-width: 900px) { .roi { grid-template-columns: 1fr; } }

.roi-inputs { display: flex; flex-direction: column; gap: 18px; }
.roi-input-row { display: flex; flex-direction: column; gap: 6px; }
.roi-input-row .label { margin-bottom: 0; }
.roi-input-row input[type="number"] {
  width: 100%;
  padding: 12px 14px;
  border: 1px solid var(--border2);
  border-radius: var(--r-sm);
  background: var(--bg);
  font-size: 16px;
  color: var(--text);
  font-weight: 600;
  outline: none;
  transition: border var(--t-fast) var(--ease);
}
.roi-input-row input:focus { border-color: var(--brand); background: var(--surface); }

.roi-result {
  background: var(--bg-dark);
  color: var(--text-inv);
  border-radius: var(--r);
  padding: 28px;
  display: flex;
  flex-direction: column;
  gap: 18px;
}
.roi-result h4 {
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--coral);
}
.roi-stat { display: flex; flex-direction: column; gap: 4px; }
.roi-stat .num {
  font-size: 36px;
  font-weight: 800;
  letter-spacing: -0.04em;
  color: var(--text-inv);
  line-height: 1;
}
.roi-stat .lbl { font-size: 12.5px; color: var(--text-inv2); }
.roi-stat .num.brand { color: var(--coral); }

.roi-divider {
  border: none;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  margin: 4px 0;
}

.roi-fine {
  font-family: 'Source Serif 4', Georgia, serif;
  font-style: italic;
  font-size: 12px;
  color: var(--text-inv2);
  line-height: 1.55;
}

/* ── Product page — feature blocks ── */
.feature-block {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 56px;
  align-items: center;
}
/* Grid items default to min-width:auto, so one wide child (a chart mock, a
   two-column logo grid) can silently force the whole column past the
   viewport on phones. min-width:0 lets columns shrink and children wrap. */
.feature-block > * { min-width: 0; }
@media (max-width: 900px) { .feature-block { grid-template-columns: 1fr; gap: 32px; } }

/* Product page: the sources tally renders two columns of logo tiles on
   desktop but must collapse to one on phones — the tiles' min-content at
   two-up exceeds a 375px viewport (previously an inline style that could
   not collapse). */
#productSources { grid-template-columns: 1fr 1fr; }
@media (max-width: 560px) { #productSources { grid-template-columns: 1fr; } }
.feature-block + .feature-block { margin-top: clamp(48px, 7vw, 96px); }
.feature-block.reverse > :first-child { order: 2; }
@media (max-width: 900px) { .feature-block.reverse > :first-child { order: 0; } }

.feature-visual {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-lg);
  padding: 28px;
  box-shadow: var(--shadow-whisper);
  min-height: 320px;
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.feature-block h2,
.feature-block h3 {
  font-family: 'Source Serif 4', Georgia, serif;
  font-style: italic;
  font-weight: 500;
  font-size: clamp(26px, 3vw, 36px);
  letter-spacing: -0.025em;
  margin-bottom: 16px;
}
.feature-block p {
  font-size: 16px;
  line-height: 1.65;
  color: var(--text2);
  margin-bottom: 14px;
}

.feature-list {
  list-style: none;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-top: 16px;
}
/* Block layout with an absolutely-positioned dot: a leading <strong> flows
   inline with the description instead of becoming its own narrow flex column
   that wraps word-by-word. */
.feature-list li {
  display: block;
  position: relative;
  padding-left: 20px;
  font-size: 14.5px;
  color: var(--text2);
  line-height: 1.6;
}
.feature-list li::before {
  content: '';
  width: 6px; height: 6px;
  border-radius: 50%;
  background: var(--brand);
  position: absolute;
  left: 2px;
  top: 9px;
}
.feature-list li strong { color: var(--text); font-weight: 650; }

/* ── 10-tab tour ── */
.tab-tour {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 14px;
}
@media (max-width: 1000px) { .tab-tour { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 600px) { .tab-tour { grid-template-columns: 1fr; } }

.tab-tile {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r);
  padding: 22px 20px;
  transition: transform var(--t-fast) var(--ease), box-shadow var(--t-fast) var(--ease);
}
.tab-tile:hover { transform: translateY(-2px); box-shadow: var(--shadow-whisper); }
.tab-tile .num {
  display: inline-block;
  font-size: 11px;
  font-weight: 700;
  color: var(--brand-deep);
  letter-spacing: 0.1em;
  margin-bottom: 6px;
}
.tab-tile h3,
.tab-tile h5 {
  font-size: 14.5px;
  font-weight: 600;
  margin-bottom: 6px;
  color: var(--text);
  letter-spacing: -0.01em;
}
.tab-tile p { font-size: 12.5px; color: var(--text2); line-height: 1.55; }

/* ── FAQ accordion ── */
.faq {
  display: flex;
  flex-direction: column;
  gap: 12px;
  max-width: 820px;
  margin: 0 auto;
}
.faq-item {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r);
  overflow: hidden;
}
.faq-q {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 20px 24px;
  font-size: 15.5px;
  font-weight: 600;
  color: var(--text);
  cursor: pointer;
  background: none;
  border: none;
  width: 100%;
  text-align: left;
  letter-spacing: -0.01em;
}
.faq-q::after {
  content: '+';
  font-size: 22px;
  color: var(--brand-deep);
  font-weight: 400;
  transition: transform var(--t-fast) var(--ease);
  flex-shrink: 0;
}
.faq-item.open .faq-q::after { transform: rotate(45deg); }
.faq-a {
  padding: 0 24px;
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.3s var(--ease), padding 0.3s var(--ease);
}
.faq-item.open .faq-a {
  max-height: 600px;
  padding: 0 24px 22px;
}
.faq-a p {
  font-size: 14.5px;
  color: var(--text2);
  line-height: 1.65;
}

/* ── About page ── */
.about-section {
  max-width: 720px;
  margin: 0 auto;
}
.about-section h2 {
  font-family: 'Source Serif 4', Georgia, serif;
  font-style: italic;
  font-weight: 500;
}
.about-section p {
  font-size: 17px;
  line-height: 1.7;
  margin-bottom: 22px;
  color: var(--text2);
}
.about-section .pull {
  font-family: 'Source Serif 4', Georgia, serif;
  font-style: italic;
  font-size: 24px;
  line-height: 1.4;
  color: var(--text);
  border-left: 3px solid var(--brand);
  padding: 4px 24px;
  margin: 32px 0;
}

.contact-form {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-lg);
  padding: 36px;
  display: flex;
  flex-direction: column;
  gap: 18px;
  max-width: 560px;
  margin: 0 auto;
}
.contact-form-row { display: flex; flex-direction: column; gap: 6px; }
@media (min-width: 600px) {
  .contact-form .row-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
}

/* ── Demo page ── */
.demo-page-hero {
  padding: clamp(48px, 6vw, 80px) 0 clamp(20px, 3vw, 32px);
  text-align: center;
}
.demo-page-hero h1 {
  font-size: clamp(34px, 4vw, 48px);
  margin-bottom: 16px;
}

.demo-page-shell {
  margin-top: 28px;
  margin-bottom: 56px;
}

.demo-grid-2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 18px;
  margin-bottom: 24px;
}
@media (max-width: 900px) { .demo-grid-2 { grid-template-columns: 1fr; } }

.heatmap-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r);
  padding: 24px;
  overflow-x: auto;
}
.heatmap-table { width: 100%; border-collapse: collapse; font-size: 12.5px; }
.heatmap-table th {
  text-align: left;
  padding: 10px 12px;
  font-size: 10.5px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.07em;
  color: var(--text3);
  border-bottom: 1px solid var(--border2);
}
.heatmap-table td {
  padding: 12px;
  border-bottom: 1px solid var(--border);
  vertical-align: middle;
}
.heatmap-table tr:hover td { background: rgba(201, 100, 66, 0.03); }
.heatmap-table .opp { color: var(--brand-deep); font-weight: 700; letter-spacing: 0.04em; font-size: 14px; }

/* ── Legal pages (privacy / terms) ── */
.legal-meta {
  font-size: 12.5px;
  color: var(--text3);
  font-style: italic;
  font-family: 'Source Serif 4', Georgia, serif;
  margin-bottom: 32px;
}
.about-section h3 {
  font-size: 19px;
  font-weight: 600;
  letter-spacing: -0.015em;
  margin: 32px 0 12px;
}
.about-section ul {
  margin: 0 0 22px 20px;
  color: var(--text2);
  font-size: 15.5px;
  line-height: 1.7;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

/* ── Credibility / built-by block ── */
.cred-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
}
@media (max-width: 900px) { .cred-grid { grid-template-columns: 1fr; } }
.cred-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r);
  padding: 26px 24px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.cred-card h4 {
  font-size: 15px;
  font-weight: 600;
  letter-spacing: -0.01em;
  color: var(--text);
}
.cred-card p {
  font-size: 13.5px;
  line-height: 1.6;
  color: var(--text2);
}

/* ── 404 page ── */
.notfound {
  min-height: 70vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 60px 20px;
}
.notfound .code {
  font-family: 'Source Serif 4', Georgia, serif;
  font-style: italic;
  font-size: 120px;
  font-weight: 500;
  color: var(--brand-deep);
  letter-spacing: -0.05em;
  line-height: 1;
}

/* ── Insights post pages ──
   Post pages read as one 720px article column: the hero (eyebrow, title,
   lead, byline) and the body share the same left edge instead of a centered
   hero sitting over a left-set text column. */
.post-hero {
  text-align: left;
  padding: clamp(48px, 6vw, 84px) 0 clamp(20px, 3vw, 32px);
}
.post-hero .eyebrow,
.post-hero h1,
.post-hero .lead,
.post-hero .post-byline {
  display: block;
  max-width: 720px;
  margin-left: auto;
  margin-right: auto;
}
.post-hero .eyebrow { margin-bottom: 14px; }
.post-hero h1 {
  font-size: clamp(32px, 4.2vw, 50px);
  margin-bottom: 16px;
}
.post-hero .lead { margin-bottom: 0; }
.post-hero .post-byline {
  margin-top: 26px;
  padding-top: 16px;
  border-top: 1px solid var(--border2);
  font-family: 'Source Serif 4', Georgia, serif;
  font-style: italic;
  font-size: 13.5px;
  color: var(--text3);
}

/* Body starts right under the hero byline.
   section.compact sets shorthand padding at higher specificity (0-1-1),
   so the override must match it. */
section.compact.post-body { padding-top: clamp(4px, 1vw, 10px); }
.post-body h2 {
  font-size: clamp(23px, 2.6vw, 30px);
  margin: 34px 0 14px;
}
.post-body .about-section ul {
  font-size: 16.5px;
  margin: 0 0 24px 20px;
  gap: 10px;
}
.post-tags { margin: 30px 0 0; }

.post-figure { margin: 30px 0 0; }
.post-figure a { display: block; border-radius: 14px; }
.post-figure img {
  width: 100%;
  height: auto;
  border-radius: 14px;
  border: 1px solid rgba(28, 25, 23, 0.08);
  cursor: zoom-in;
  transition: box-shadow var(--t-mid) var(--ease), transform var(--t-mid) var(--ease);
}
.post-figure a:hover img {
  box-shadow: var(--shadow-soft);
  transform: translateY(-2px);
}
.post-figure figcaption {
  margin-top: 10px;
  font-size: 12.5px;
  color: var(--text3);
  font-family: 'Source Serif 4', Georgia, serif;
  font-style: italic;
}

.post-cta {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 30px;
}
.post-back { margin-top: 26px; }
.post-back a { color: var(--brand-deep); font-weight: 600; }
