/* ============================================================
   Fagura · Financiar Director AI — unified stylesheet
   Page scoping: body has .page-landing | .page-app | .page-results
   ============================================================ */

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

:root {
  --mint:     #3BCC9C;
  --mint-d:   #35B782;
  --purple:   #472980;
  --purple-l: #5B49A5;
  --dark:     #0F0D1C;
  --body:     #3D3A52;
  --muted:    #8B87A8;
  --border:   #E4E2F0;
  --surface:  #F5F4FA;
  --white:    #FFFFFF;
  --r:        12px;
  --fh: 'Montserrat', sans-serif;
  --fb: 'Inter', sans-serif;
  --max-w: 1120px;
  --px: 48px;
}

html { scroll-behavior: smooth; height: 100%; }

body {
  font-family: var(--fb);
  background: var(--surface);
  color: var(--body);
  line-height: 1.6;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}
body.page-landing { background: var(--white); }
body.page-app {
  min-height: 100vh;
  display: flex; flex-direction: column;
}

/* ── CONTAINER ── */
.container { max-width: var(--max-w); margin: 0 auto; padding: 0 var(--px); }

/* ── HIGHLIGHT ── */
.hl { color: var(--purple); }

/* ── BUTTONS ── */
.btn {
  font-family: var(--fb); font-size: 14px; font-weight: 600;
  border: none; cursor: pointer; border-radius: var(--r);
  transition: all .15s; display: inline-flex; align-items: center; gap: 7px; white-space: nowrap;
}
.btn-ghost   { background: transparent; color: var(--muted); padding: 8px 14px; }
.btn-ghost:hover { background: var(--surface); color: var(--dark); }
.btn-purple  { background: var(--purple); color: var(--white); padding: 9px 18px; }
.btn-purple:hover { background: var(--purple-l); box-shadow: 0 4px 16px rgba(71,41,128,.22); }
.btn-mint    { background: var(--mint); color: var(--white); padding: 12px 28px; font-size: 15px; font-weight: 700; }
.btn-mint:hover { background: var(--mint-d); box-shadow: 0 4px 20px rgba(59,204,156,.3); }
.btn-outline { background: var(--white); color: var(--purple); border: 1.5px solid var(--border); padding: 11px 22px; font-size: 15px; font-weight: 600; }
.btn-outline:hover { border-color: var(--purple); }

/* ── BADGES ── */
.badge {
  font-size: 11px; font-weight: 600; padding: 4px 12px;
  border-radius: 999px; border: 1px solid;
}
.badge-active { color: var(--mint-d); background: rgba(53,183,130,.08); border-color: rgba(53,183,130,.2); }
.badge-md     { color: var(--purple-l); background: rgba(91,73,165,.08); border-color: rgba(91,73,165,.2); }

/* ── VALUE / MARK COLORS ── */
.val-pos  { color: var(--mint-d); }
.val-neg  { color: #DC4C4C; }
.val-warn { color: #D97706; }
.val-neu  { color: var(--dark); }
.mark-pos { color: var(--mint-d); }
.mark-neg { color: #DC4C4C; }

/* ── NAV (landing + results) ── */
nav {
  position: static;
  height: 60px; border-bottom: 1px solid var(--border);
  background: var(--white);
}
.nav-inner {
  max-width: var(--max-w); margin: 0 auto; padding: 0 var(--px);
  height: 100%; display: flex; align-items: center; justify-content: space-between;
}
.nav-brand { display: flex; align-items: center; gap: 14px; text-decoration: none; }
.nav-brand-sep { width: 1px; height: 18px; background: var(--border); }
.nav-product { display: flex; align-items: center; gap: 7px; }
.nav-product-name { font-family: var(--fb); font-weight: 500; font-size: 13px; color: var(--muted); }
.nav-links { display: flex; gap: 32px; list-style: none; }
.nav-links a { font-size: 14px; font-weight: 400; color: var(--muted); text-decoration: none; transition: color .15s; }
.nav-links a:hover { color: var(--dark); }
.nav-actions { display: flex; align-items: center; gap: 8px; }

body.page-landing nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 100;
  background: rgba(255,255,255,0.97); backdrop-filter: blur(16px);
}

/* ── TOPBAR (app) ── */
.topbar {
  height: 56px; background: var(--white); border-bottom: 1px solid var(--border);
  display: flex; align-items: center; justify-content: space-between;
  padding: 0 24px; flex-shrink: 0;
  position: sticky; top: 0; z-index: 50;
}
.topbar-brand { display: flex; align-items: center; gap: 12px; }
.topbar-brand-name { font-family: var(--fh); font-weight: 700; font-size: 15px; color: var(--purple); letter-spacing: -.01em; }
.topbar-sep { width: 1px; height: 16px; background: var(--border); }
.topbar-product { font-size: 12px; font-weight: 500; color: var(--muted); }
.topbar-right { display: flex; align-items: center; gap: 12px; }
.topbar-user { display: flex; align-items: center; gap: 8px; font-size: 13px; font-weight: 500; color: var(--body); }
.topbar-avatar {
  width: 30px; height: 30px; border-radius: 50%;
  background: var(--purple); color: var(--white);
  font-family: var(--fh); font-size: 11px; font-weight: 700;
  display: flex; align-items: center; justify-content: center; flex-shrink: 0;
}

/* ── APP LAYOUT ── */
.app-layout { display: flex; flex: 1; min-height: 0; }
.main {
  flex: 1; overflow-y: auto; padding: 28px 0 48px;
  display: flex; flex-direction: column;
}
.main-inner {
  max-width: var(--max-w); margin: 0 auto; padding: 0 var(--px);
  display: flex; flex-direction: column; gap: 20px; width: 100%;
}

/* ── COMPANY BAR (app) ── */
.company-bar {
  background: var(--white); border: 1.5px solid var(--border); border-radius: 16px;
  padding: 18px 22px; display: flex; align-items: center; justify-content: space-between; gap: 20px;
}
.company-bar-left { display: flex; align-items: center; gap: 16px; }
.company-initial {
  width: 44px; height: 44px; border-radius: 12px; background: var(--purple);
  color: var(--white); font-family: var(--fh); font-size: 18px; font-weight: 800;
  display: flex; align-items: center; justify-content: center; flex-shrink: 0;
}
.company-name { font-family: var(--fh); font-size: 18px; font-weight: 800; color: var(--dark); letter-spacing: -.02em; }
.company-meta { font-size: 12px; font-weight: 400; color: var(--muted); margin-top: 2px; }
.company-bar-right { display: flex; align-items: center; gap: 8px; }

/* ── COMPANY HEADER (results) ── */
.company-header { background: var(--white); border-bottom: 1px solid var(--border); padding: 24px 0; }
.company-header-inner { display: flex; align-items: center; justify-content: space-between; gap: 24px; flex-wrap: wrap; }
body.page-results .company-meta {
  display: flex; align-items: center; gap: 20px;
  margin-top: 0; font-size: inherit; color: inherit; font-weight: inherit;
}
body.page-results .company-name { font-size: 20px; }
.company-back {
  width: 36px; height: 36px; border-radius: 10px; border: 1.5px solid var(--border);
  background: var(--white); display: flex; align-items: center; justify-content: center;
  cursor: pointer; color: var(--muted); transition: all .15s; flex-shrink: 0; text-decoration: none;
}
.company-back:hover { border-color: var(--purple); color: var(--purple); }
.company-idno { font-size: 13px; font-weight: 400; color: var(--muted); margin-top: 2px; }
.company-badges { display: flex; align-items: center; gap: 8px; }

/* ── RESULTS PAGE WRAP ── */
.page { padding: 32px 0 96px; }
.results-grid {
  display: grid; grid-template-columns: 1fr 340px; gap: 24px;
  margin-top: 28px; align-items: start;
}
.right-col { display: flex; flex-direction: column; gap: 20px; }

/* ── CARD ── */
.card {
  background: var(--white); border: 1.5px solid var(--border);
  border-radius: 16px; overflow: hidden;
}
.card-header {
  padding: 18px 22px; border-bottom: 1px solid var(--border);
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
}
.card-title {
  font-family: var(--fh); font-size: 12px; font-weight: 700;
  letter-spacing: .1em; text-transform: uppercase; color: var(--muted);
}
.card-body { padding: 22px; }

body.page-app .card-header { padding: 16px 20px; }
body.page-app .card-title  { font-size: 11px; }
body.page-app .card-body   { padding: 20px; }

/* ── METRICS GRID ── */
.metrics-grid {
  display: grid; grid-template-columns: 1fr 1fr; gap: 1px;
  background: var(--border);
}
.metric-cell { background: var(--white); padding: 20px 22px; position: relative; }
.metric-label { font-size: 11px; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); margin-bottom: 8px; }
.metric-value { font-family: var(--fh); font-size: 28px; font-weight: 800; letter-spacing: -.03em; line-height: 1; margin-bottom: 5px; }
.metric-sub { font-size: 12px; font-weight: 400; color: var(--muted); line-height: 1.45; }
.metric-trend {
  display: inline-flex; align-items: center; gap: 4px; margin-top: 6px;
  font-size: 11px; font-weight: 600; padding: 2px 8px; border-radius: 999px;
}
.trend-up   { color: var(--mint-d); background: rgba(53,183,130,.1); }
.trend-down { color: #DC4C4C;       background: rgba(220,76,76,.08); }
.trend-warn { color: #D97706;       background: rgba(217,119,6,.08); }

body.page-app .metrics-grid { grid-template-columns: repeat(4, 1fr); }
body.page-app .metric-cell  { padding: 18px 20px; }
body.page-app .metric-label { font-size: 10px; margin-bottom: 6px; }
body.page-app .metric-value { font-size: 24px; margin-bottom: 4px; }
body.page-app .metric-sub   { font-size: 11px; }
body.page-app .metric-trend { font-size: 10px; padding: 2px 7px; margin-top: 5px; }

/* Locked metric (results) */
.metric-locked .metric-value,
.metric-locked .metric-sub,
.metric-locked .metric-trend { filter: blur(6px); user-select: none; pointer-events: none; }
.lock-overlay { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; background: rgba(255,255,255,.5); }
.lock-pill {
  display: flex; align-items: center; gap: 6px;
  background: var(--white); border: 1.5px solid var(--border);
  border-radius: 999px; padding: 5px 12px;
  font-size: 11px; font-weight: 600; color: var(--muted);
  box-shadow: 0 2px 8px rgba(71,41,128,.08);
}

/* ── CHARTS ROW (app) ── */
.charts-row { display: grid; grid-template-columns: 1.4fr 1fr; gap: 20px; align-items: stretch; }
.charts-row > .card { display: flex; flex-direction: column; }
.chart-inner { padding: 20px 20px 16px; }
.chart-sub { font-size: 12px; font-weight: 400; color: var(--muted); margin-bottom: 16px; }

/* ── CHART SECTION (results) ── */
.chart-section { position: relative; }
.chart-wrap { padding: 22px 22px 8px; }
.chart-legend { display: flex; gap: 16px; padding: 0 22px 20px; }
.chart-legend-item { display: flex; align-items: center; gap: 6px; font-size: 11px; font-weight: 400; color: var(--muted); }
.legend-dot { width: 8px; height: 8px; border-radius: 2px; flex-shrink: 0; }
.chart-locked .chart-wrap,
.chart-locked .chart-legend { filter: blur(5px); pointer-events: none; user-select: none; }
.chart-lock-overlay {
  position: absolute; inset: 0; display: flex; flex-direction: column;
  align-items: center; justify-content: center; gap: 12px;
  background: rgba(255,255,255,.65); backdrop-filter: blur(2px);
  border-radius: 0 0 14px 14px;
}
.chart-lock-overlay p { font-size: 13px; font-weight: 500; color: var(--body); text-align: center; max-width: 220px; line-height: 1.5; }

/* ── CREDIT LIMIT BODY (app, in charts-row) ── */
.credit-limit-body { padding: 20px; display: flex; flex-direction: column; gap: 16px; flex: 1; }
.credit-amount-row { display: flex; align-items: baseline; gap: 8px; }
.credit-amount-unit { font-size: 14px; font-weight: 600; color: var(--muted); }
.credit-amount-label { font-size: 11px; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); margin-bottom: 4px; }
.credit-rows { display: flex; flex-direction: column; gap: 10px; border-top: 1px solid var(--border); padding-top: 14px; }
.credit-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; font-size: 13px; }
.credit-row-label { color: var(--muted); font-weight: 500; }
.credit-row-value { color: var(--dark); font-weight: 600; font-family: var(--fh); }
.confort-badge {
  font-size: 11px; font-weight: 700; padding: 3px 10px; border-radius: 999px;
  color: #D97706; background: rgba(217,119,6,.1); border: 1px solid rgba(217,119,6,.2);
}
.credit-reco {
  background: var(--surface); border: 1px solid var(--border);
  border-radius: var(--r); padding: 14px 16px; margin-top: auto;
}
.credit-reco-label {
  display: inline-flex; align-items: center; gap: 6px;
  font-size: 10px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase;
  color: var(--mint-d); margin-bottom: 8px;
}
.credit-reco-dot { width: 6px; height: 6px; border-radius: 50%; background: var(--mint); }
.credit-reco-text { font-size: 12px; font-weight: 400; color: var(--body); line-height: 1.6; }

/* ── CREDIT AMOUNT — shared with size variants ── */
.credit-amount {
  font-family: var(--fh); font-size: 36px; font-weight: 800;
  color: var(--purple); letter-spacing: -.03em; line-height: 1;
}
body.page-results .credit-amount {
  font-size: 42px; letter-spacing: -.04em; color: var(--white);
}

/* ── CREDIT CARD (results right column) ── */
.credit-card { background: var(--purple); border-radius: 16px; padding: 28px 24px; color: var(--white); }
.credit-label { font-size: 10px; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; color: rgba(255,255,255,.5); margin-bottom: 10px; }
.credit-currency { font-size: 16px; font-weight: 600; color: rgba(255,255,255,.6); margin-left: 4px; }
.credit-desc { font-size: 13px; font-weight: 400; color: rgba(255,255,255,.6); line-height: 1.6; margin: 12px 0 20px; }
.credit-cta {
  background: var(--mint); color: var(--white);
  font-family: var(--fb); font-size: 14px; font-weight: 700;
  border: none; cursor: pointer; border-radius: var(--r);
  padding: 11px 20px; width: 100%; transition: background .15s;
}
.credit-cta:hover { background: var(--mint-d); }
.credit-note { font-size: 11px; color: rgba(255,255,255,.4); text-align: center; margin-top: 10px; }

/* ── RATING (results) ── */
.rating-side-card { overflow: hidden; }
.rating-grade-block { padding: 24px 22px 20px; display: flex; align-items: center; gap: 16px; border-bottom: 1px solid var(--border); }
.rating-grade { font-family: var(--fh); font-size: 72px; font-weight: 800; color: var(--purple); letter-spacing: -.05em; line-height: 1; }
.rating-grade sup { font-size: 28px; vertical-align: super; letter-spacing: 0; }
.rating-grade-label { font-size: 11px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); margin-bottom: 4px; }
.rating-grade-desc { font-family: var(--fh); font-size: 15px; font-weight: 700; color: var(--dark); margin-bottom: 4px; line-height: 1.2; }
.rating-grade-sub { font-size: 12px; font-weight: 400; color: var(--muted); line-height: 1.45; max-width: 160px; }
.rating-bars-block { padding: 18px 22px 22px; display: flex; flex-direction: column; gap: 12px; }
.rating-bar-top { display: flex; justify-content: space-between; align-items: baseline; margin-bottom: 5px; }
.rating-bar-name { font-size: 12px; font-weight: 500; color: var(--body); }
.rating-bar-val { font-family: var(--fh); font-size: 12px; font-weight: 700; color: var(--dark); }
.rating-bar { width: 100%; height: 5px; background: var(--surface); border-radius: 3px; overflow: hidden; }
.rating-bar-fill { height: 100%; border-radius: 3px; transition: width .4s ease; }

/* ── INVEST PRIME (results) ── */
.invest-card .card-body { padding: 20px 22px; }
.invest-headline { font-family: var(--fh); font-size: 15px; font-weight: 700; color: var(--dark); margin-bottom: 8px; line-height: 1.3; }
.invest-desc { font-size: 13px; font-weight: 400; color: var(--muted); line-height: 1.6; margin-bottom: 16px; }
.invest-cta {
  background: var(--surface); color: var(--purple);
  font-family: var(--fb); font-size: 13px; font-weight: 600;
  border: 1.5px solid var(--border); cursor: pointer; border-radius: var(--r);
  padding: 10px 18px; width: 100%; transition: all .15s;
}
.invest-cta:hover { border-color: var(--purple); background: rgba(71,41,128,.04); }

/* ── INTERPRETATION (results) ── */
.interpretation { margin-top: 24px; }
.interp-body { padding: 22px; display: flex; flex-direction: column; gap: 20px; }
.interp-group-label { font-size: 10px; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; color: var(--muted); margin-bottom: 10px; }
.interp-item { display: flex; align-items: flex-start; gap: 10px; font-size: 14px; font-weight: 400; color: var(--body); line-height: 1.65; margin-bottom: 8px; }
.interp-mark { font-family: var(--fh); font-size: 11px; font-weight: 700; flex-shrink: 0; margin-top: 3px; width: 16px; }
.interp-locked { position: relative; overflow: hidden; }
.interp-locked .interp-locked-content { filter: blur(5px); pointer-events: none; user-select: none; }
.interp-fade { position: absolute; bottom: 0; left: 0; right: 0; height: 80px; background: linear-gradient(to bottom, transparent, var(--white)); }

/* ── CFO SUMMARY (app) ── */
.cfo-body { padding: 20px; }
.cfo-label {
  display: inline-flex; align-items: center; gap: 6px;
  font-size: 11px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase;
  color: var(--mint-d); margin-bottom: 14px;
}
.cfo-label-dot { width: 6px; height: 6px; border-radius: 50%; background: var(--mint); animation: pulse 2s infinite; }
@keyframes pulse { 0%,100% { opacity: 1; } 50% { opacity: .4; } }
.cfo-text { font-size: 14px; font-weight: 400; color: var(--body); line-height: 1.8; }
.cfo-text p { margin-bottom: 12px; }
.cfo-text p:last-child { margin-bottom: 0; }
.cfo-text strong { font-weight: 600; color: var(--dark); }

/* ── CHAT (app) ── */
.chat-card { position: relative; }
.chat-card.drag-over { border-color: var(--purple); box-shadow: 0 0 0 4px rgba(71,41,128,.08); }
.chat-card.drag-over::after {
  content: 'Eliberează pentru a încărca documentul';
  position: absolute; inset: 0; background: rgba(71,41,128,.04);
  display: flex; align-items: center; justify-content: center;
  font-family: var(--fh); font-size: 14px; font-weight: 700; color: var(--purple);
  pointer-events: none; border-radius: 16px;
}
.chat-intro {
  padding: 16px 20px 12px;
  font-size: 13px; font-weight: 500; color: var(--body);
  display: flex; align-items: center; gap: 8px;
}
.chat-intro-avatar {
  width: 28px; height: 28px; border-radius: 8px; background: var(--purple);
  color: var(--white); font-family: var(--fh); font-size: 9px; font-weight: 800;
  display: flex; align-items: center; justify-content: center; flex-shrink: 0; letter-spacing: .03em;
}
.chat-questions { padding: 0 20px 14px; display: flex; flex-wrap: wrap; gap: 8px; }
.chat-q-btn {
  font-family: var(--fb); font-size: 12px; font-weight: 500; color: var(--purple);
  background: rgba(71,41,128,.06); border: 1px solid rgba(71,41,128,.15);
  padding: 7px 13px; border-radius: var(--r); cursor: pointer; transition: all .15s;
  text-align: left;
}
.chat-q-btn:hover { background: rgba(71,41,128,.12); border-color: rgba(71,41,128,.3); }
.chat-messages {
  padding: 0 20px; min-height: 80px; max-height: 360px; margin-bottom: 14px;
  display: flex; flex-direction: column; gap: 10px;
  overflow-y: auto; overscroll-behavior: contain;
  scrollbar-width: thin; scrollbar-color: var(--border) transparent;
}
.chat-messages::-webkit-scrollbar { width: 8px; }
.chat-messages::-webkit-scrollbar-track { background: transparent; }
.chat-messages::-webkit-scrollbar-thumb { background: var(--border); border-radius: 4px; }
.chat-messages::-webkit-scrollbar-thumb:hover { background: var(--muted); }
.chat-msg { display: flex; gap: 10px; align-items: flex-start; }
.chat-msg-user { flex-direction: row-reverse; }
.chat-msg-avatar {
  width: 28px; height: 28px; border-radius: 8px; flex-shrink: 0;
  display: flex; align-items: center; justify-content: center;
  font-family: var(--fh); font-size: 9px; font-weight: 800;
}
.chat-msg-avatar-ai { background: var(--purple); color: var(--white); }
.chat-msg-avatar-user { background: var(--surface); color: var(--muted); border: 1.5px solid var(--border); }
.chat-msg-bubble { max-width: 80%; padding: 10px 14px; border-radius: 12px; font-size: 13px; font-weight: 400; line-height: 1.6; }
.chat-msg-bubble-ai { background: var(--surface); color: var(--body); border: 1px solid var(--border); border-radius: 4px 12px 12px 12px; }
.chat-msg-bubble-user { background: var(--purple); color: var(--white); border-radius: 12px 4px 12px 12px; }
.chat-file-pill {
  display: inline-flex; align-items: center; gap: 8px;
  background: rgba(71,41,128,.06); border: 1px solid rgba(71,41,128,.15);
  padding: 6px 10px 6px 8px; border-radius: var(--r);
  font-size: 12px; font-weight: 500; color: var(--purple);
}
.chat-file-pill svg { color: var(--purple); }
.chat-attachments { padding: 0 20px 10px; display: flex; flex-wrap: wrap; gap: 8px; }
.chat-attachments:empty { display: none; }
.chat-attachment-chip {
  display: inline-flex; align-items: center; gap: 8px;
  background: var(--surface); border: 1.5px solid var(--border);
  padding: 6px 8px 6px 10px; border-radius: var(--r);
  font-size: 12px; font-weight: 500; color: var(--body);
}
.chat-attachment-chip svg { color: var(--purple); flex-shrink: 0; }
.chat-attachment-remove {
  border: none; background: transparent; cursor: pointer;
  width: 18px; height: 18px; border-radius: 50%;
  display: inline-flex; align-items: center; justify-content: center;
  color: var(--muted); transition: all .15s;
}
.chat-attachment-remove:hover { background: var(--border); color: var(--dark); }
.chat-input-row { padding: 0 20px 20px; display: flex; align-items: flex-end; gap: 10px; }
.chat-attach-btn {
  width: 44px; height: 44px; border-radius: var(--r); flex-shrink: 0;
  background: var(--white); border: 1.5px solid var(--border); cursor: pointer;
  display: flex; align-items: center; justify-content: center; color: var(--muted);
  transition: all .15s;
}
.chat-attach-btn:hover { border-color: var(--purple); color: var(--purple); background: rgba(71,41,128,.04); }
.chat-textarea {
  flex: 1; resize: none; border: 1.5px solid var(--border);
  border-radius: var(--r); padding: 11px 14px;
  font-family: var(--fb); font-size: 13px; font-weight: 400; color: var(--dark);
  background: var(--white); outline: none; line-height: 1.5;
  transition: border-color .15s; min-height: 44px; max-height: 120px; overflow-y: auto;
}
.chat-textarea:focus { border-color: var(--purple); }
.chat-textarea::placeholder { color: var(--muted); }
.chat-send-btn {
  width: 44px; height: 44px; border-radius: var(--r); flex-shrink: 0;
  background: var(--purple); border: none; cursor: pointer;
  display: flex; align-items: center; justify-content: center; color: var(--white);
  transition: background .15s;
}
.chat-send-btn:hover { background: var(--purple-l); }
.chat-hint { padding: 0 20px 14px; font-size: 11px; font-weight: 400; color: var(--muted); display: flex; align-items: center; gap: 6px; }
.chat-hint svg { color: var(--muted); flex-shrink: 0; }
.chat-divider { height: 1px; background: var(--border); margin: 0 20px 16px; }

/* ── SECTIONS (landing) ── */
.section { padding: 96px 0; }
.section-label {
  font-family: var(--fh); font-size: 10px; font-weight: 700; letter-spacing: .12em; text-transform: uppercase;
  color: var(--purple-l); margin-bottom: 14px; display: block;
}
h2 {
  font-family: var(--fh); font-size: clamp(26px, 3vw, 38px);
  font-weight: 700; line-height: 1.18; letter-spacing: -.025em; color: var(--dark);
}
.section-body { font-size: 16px; font-weight: 400; color: var(--body); line-height: 1.75; margin-top: 14px; }

/* ── HERO (landing) ── */
.hero {
  padding-top: 24px;
  background: linear-gradient(180deg, rgba(71,41,128,.055) 0%, rgba(71,41,128,.02) 50%, rgba(255,255,255,0) 100%);
}
.hero > .container { padding-top: 32px; }
.hero-top { display: grid; grid-template-columns: 1fr 1fr; gap: 64px; align-items: center; padding-bottom: 52px; }
.hero-eyebrow { display: inline-flex; align-items: center; gap: 10px; margin-bottom: 28px; }
.hero-eyebrow-divider { width: 1px; height: 18px; background: var(--border); }
.hero-eyebrow-text { font-size: 13px; font-weight: 400; color: var(--muted); }
.hero h1 {
  font-family: var(--fh); font-size: clamp(34px, 3.8vw, 52px);
  font-weight: 800; line-height: 1.07; letter-spacing: -.03em;
  color: var(--dark); margin-bottom: 20px;
}
.hero-lead { font-size: 16px; font-weight: 400; color: var(--body); line-height: 1.75; }
.hero-card {
  background: var(--white);
  border: 1.5px solid var(--border); border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 16px 56px rgba(71,41,128,.1), 0 2px 8px rgba(71,41,128,.06);
}
.hc-header { padding: 14px 18px; background: var(--surface); border-bottom: 1px solid var(--border); display: flex; align-items: center; justify-content: space-between; }
.hc-company { font-family: var(--fh); font-size: 13px; font-weight: 700; color: var(--dark); }
.hc-idno { font-size: 11px; font-weight: 400; color: var(--muted); margin-top: 1px; }
.hc-status {
  font-size: 11px; font-weight: 600; color: var(--mint-d);
  background: rgba(53,183,130,.1); border: 1px solid rgba(53,183,130,.2);
  padding: 3px 10px; border-radius: 999px; flex-shrink: 0;
}
.hc-metrics { display: grid; grid-template-columns: 1fr 1fr; border-bottom: 1px solid var(--border); }
.hc-metric { padding: 12px 14px; border-right: 1px solid var(--border); border-bottom: 1px solid var(--border); }
.hc-metric:nth-child(2) { border-right: none; }
.hc-metric:nth-child(3) { border-bottom: none; }
.hc-metric:nth-child(4) { border-right: none; border-bottom: none; }
.hc-metric-label { font-size: 9px; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); margin-bottom: 4px; }
.hc-metric-value { font-family: var(--fh); font-size: 17px; font-weight: 800; letter-spacing: -.025em; line-height: 1; margin-bottom: 3px; }
.hc-metric-sub { font-size: 9.5px; font-weight: 400; color: var(--muted); line-height: 1.4; }
.hc-body { display: grid; grid-template-columns: 1fr 1fr; }
.hc-chart { padding: 16px 18px; border-right: 1px solid var(--border); }
.hc-panel-label { font-size: 10px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); margin-bottom: 10px; display: block; }
.hc-insights { padding: 16px 18px; display: flex; flex-direction: column; gap: 14px; }
.hc-insight-group-label { font-size: 10px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); margin-bottom: 6px; }
.hc-insight-item { display: flex; align-items: flex-start; gap: 6px; font-size: 11px; font-weight: 400; color: var(--body); line-height: 1.5; margin-bottom: 5px; }
.hc-insight-mark { font-family: var(--fh); font-size: 10px; font-weight: 700; flex-shrink: 0; width: 12px; margin-top: 1px; }
.hc-cta {
  border-top: 1px solid var(--border); padding: 12px 18px;
  display: flex; align-items: center; justify-content: space-between; gap: 8px;
  background: rgba(71,41,128,.03);
}
.hc-cta-text { font-size: 11px; font-weight: 500; color: var(--purple); }
.hc-cta-link { font-size: 11px; font-weight: 700; color: var(--purple); text-decoration: none; white-space: nowrap; flex-shrink: 0; transition: color .15s; }
.hc-cta-link:hover { color: var(--mint-d); }

/* ── HERO SEARCH BAND (landing) ── */
.hero-bottom { background: var(--purple); padding: 48px 0 52px; text-align: center; }
.hero-bottom-inner {
  max-width: var(--max-w); margin: 0 auto; padding: 0 var(--px);
  display: flex; flex-direction: column; align-items: center; gap: 16px;
}
.hero-search-wrap {
  background: var(--white);
  border: 1.5px solid var(--white);
  border-radius: 14px;
  padding: 7px 7px 7px 20px;
  display: flex; align-items: center;
  box-shadow: 0 8px 40px rgba(0,0,0,.25);
  transition: border-color .15s, box-shadow .15s;
  width: 100%; max-width: 640px;
}
.hero-search-wrap:focus-within {
  border-color: var(--mint);
  box-shadow: 0 0 0 3px rgba(59,204,156,.25), 0 8px 40px rgba(0,0,0,.28);
}
.search-icon { color: var(--muted); flex-shrink: 0; margin-right: 10px; }
.hero-search-wrap input {
  flex: 1; border: none; outline: none; background: transparent;
  font-family: var(--fb); font-size: 15px; font-weight: 400; color: var(--dark); min-width: 0;
}
.hero-search-wrap input::placeholder { color: var(--muted); }
.hero-search-btn {
  background: var(--mint); color: var(--white);
  font-family: var(--fb); font-size: 14px; font-weight: 700;
  border: none; cursor: pointer; border-radius: 10px; padding: 10px 22px;
  white-space: nowrap; flex-shrink: 0;
  transition: background .15s, box-shadow .15s;
}
.hero-search-btn:hover { background: var(--mint-d); box-shadow: 0 4px 16px rgba(59,204,156,.35); }
.hero-trust { display: flex; align-items: center; justify-content: center; gap: 28px; flex-wrap: wrap; }
.trust-item { display: flex; align-items: center; gap: 7px; font-size: 13px; font-weight: 500; color: rgba(255,255,255,.55); }
.trust-dot { width: 5px; height: 5px; border-radius: 50%; background: var(--mint); flex-shrink: 0; }

/* ── STEPS (landing) ── */
.steps-bg { background: var(--surface); }
.steps-head { max-width: 520px; margin: 0 auto 52px; text-align: center; }
.steps-wrap { position: relative; border: 1.5px solid var(--border); border-radius: 14px; overflow: hidden; background: var(--white); }
.steps-connector-track {
  position: absolute; top: 54px;
  left: calc(28px + 18px); right: calc(28px + 18px);
  height: 1px; background: var(--border); z-index: 0; pointer-events: none;
}
.steps-grid { display: grid; grid-template-columns: repeat(4, 1fr); position: relative; }
.step-card { padding: 36px 28px 28px; background: var(--white); border-right: 1.5px solid var(--border); transition: background .18s; }
.step-card:last-child { border-right: none; }
.step-card:hover { background: #FDFDFF; }
.step-circle {
  width: 36px; height: 36px; border-radius: 50%;
  border: 1.5px solid var(--border); background: var(--white);
  display: flex; align-items: center; justify-content: center;
  font-family: var(--fh); font-size: 12px; font-weight: 700; color: var(--purple);
  position: relative; z-index: 1; margin-bottom: 28px;
  transition: border-color .18s, background .18s;
}
.step-card:hover .step-circle { border-color: var(--mint); background: rgba(59,204,156,.06); color: var(--mint-d); }
.step-card h3 { font-family: var(--fh); font-size: 15px; font-weight: 700; color: var(--dark); margin-bottom: 10px; line-height: 1.3; }
.step-card p { font-size: 13px; font-weight: 400; color: var(--muted); line-height: 1.7; margin-bottom: 0; }
.step-outcome {
  display: inline-flex; align-items: center; gap: 5px;
  font-size: 11px; font-weight: 600; color: var(--mint-d);
  background: rgba(53,183,130,.08); border: 1px solid rgba(53,183,130,.2);
  padding: 4px 10px; border-radius: 999px;
}
.step-outcome-dot { width: 4px; height: 4px; border-radius: 50%; background: var(--mint); flex-shrink: 0; }
.steps-foot { margin-top: 40px; display: flex; flex-direction: column; align-items: center; gap: 12px; }
.steps-foot-note { font-size: 12px; font-weight: 400; color: var(--muted); }

/* ── CTA BAND (landing) — big purple ── */
body.page-landing .cta-band {
  background: var(--purple); padding: 80px 0;
  position: relative; overflow: hidden;
}
body.page-landing .cta-band::before {
  content: ''; position: absolute; right: 0; top: -140px;
  width: 500px; height: 500px; border-radius: 50%;
  background: radial-gradient(circle, rgba(59,204,156,.13) 0%, transparent 65%); pointer-events: none;
}
body.page-landing .cta-band-inner { display: flex; justify-content: space-between; align-items: center; gap: 48px; flex-wrap: wrap; }
body.page-landing .cta-band h2 { color: var(--white); max-width: 480px; }
body.page-landing .cta-band .section-body { color: rgba(255,255,255,.5); max-width: 400px; }
body.page-landing .cta-band-actions { display: flex; flex-direction: column; align-items: flex-start; gap: 12px; flex-shrink: 0; }
body.page-landing .cta-band-link { font-size: 13px; font-weight: 400; color: rgba(255,255,255,.4); text-decoration: none; transition: color .15s; }
body.page-landing .cta-band-link:hover { color: var(--mint); }

/* ── CTA BAND (results) — light card ── */
body.page-results .cta-band {
  margin-top: 24px;
  background: var(--surface);
  border: 1.5px solid var(--border);
  border-radius: 16px;
  padding: 28px 32px;
  display: flex; align-items: center; justify-content: space-between; gap: 40px; flex-wrap: wrap;
}
.cta-band-title { font-family: var(--fh); font-size: 18px; font-weight: 800; color: var(--dark); letter-spacing: -.02em; margin-bottom: 6px; line-height: 1.2; }
.cta-band-desc { font-size: 14px; font-weight: 400; color: var(--muted); line-height: 1.65; max-width: 460px; }
.cta-band-features { display: flex; flex-direction: column; gap: 7px; margin-top: 7px; }
.cta-band-feat { display: flex; align-items: center; gap: 8px; font-size: 13px; font-weight: 500; color: var(--body); }
.feat-dot { width: 5px; height: 5px; border-radius: 50%; background: var(--mint); flex-shrink: 0; }
body.page-results .cta-band-actions { display: flex; flex-direction: row; align-items: center; gap: 16px; flex-shrink: 0; }
body.page-results .cta-band-link { font-size: 13px; font-weight: 500; color: var(--muted); text-decoration: none; transition: color .15s; white-space: nowrap; }
body.page-results .cta-band-link:hover { color: var(--purple); }

/* ── ABOUT FAGURA (landing) ── */
.fagura-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 96px; align-items: center; }
.fagura-stats { display: flex; gap: 40px; margin-top: 40px; }
.fstat-num { font-family: var(--fh); font-size: 28px; font-weight: 800; color: var(--dark); letter-spacing: -.03em; line-height: 1; }
.fstat-label { font-size: 12px; font-weight: 500; color: var(--muted); margin-top: 4px; }
.fagura-panel { background: var(--surface); border: 1.5px solid var(--border); border-radius: 20px; padding: 24px; display: flex; flex-direction: column; gap: 12px; }
.fp-top { background: var(--purple); border-radius: 12px; padding: 22px 24px; }
.fp-top-label { font-size: 10px; font-weight: 600; letter-spacing: .1em; text-transform: uppercase; color: rgba(255,255,255,.5); margin-bottom: 6px; }
.fp-top-val { font-family: var(--fh); font-size: 32px; font-weight: 800; color: var(--white); letter-spacing: -.03em; line-height: 1; }
.fp-top-sub { font-size: 12px; font-weight: 500; color: var(--mint); margin-top: 4px; }
.fp-row { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.fp-card { background: var(--white); border: 1.5px solid var(--border); border-radius: 12px; padding: 18px 16px; }
.fp-card-label { font-size: 10px; font-weight: 600; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); margin-bottom: 6px; }
.fp-card-val { font-family: var(--fh); font-size: 22px; font-weight: 800; color: var(--dark); letter-spacing: -.02em; line-height: 1; }
.fp-card-sub { font-size: 11px; font-weight: 500; color: var(--mint-d); margin-top: 4px; }
.fp-stars { display: flex; gap: 2px; margin-top: 6px; }
.fp-star { width: 10px; height: 10px; }

/* ── HELVETAS (landing) ── */
.helvetas-strip { border-top: 1px solid var(--border); padding: 40px 0; }
.helvetas-inner { display: flex; flex-direction: column; align-items: center; text-align: center; gap: 24px; }
.helvetas-disclaimer { font-size: 12px; font-weight: 400; color: var(--muted); line-height: 1.6; max-width: 560px; }
.helvetas-logos { display: flex; align-items: center; justify-content: center; gap: 40px; flex-wrap: wrap; }
.helvetas-logo-img { display: block; width: auto; object-fit: contain; }
.helvetas-logo-switzerland { height: 44px; }
.helvetas-logo-helvetas    { height: 28px; }
.helvetas-logo-optim       { height: 38px; }
@media (max-width: 640px) {
  .helvetas-strip { padding: 32px 0; }
  .helvetas-inner { gap: 20px; }
  .helvetas-disclaimer { font-size: 11px; }
  .helvetas-logos { gap: 28px; }
  .helvetas-logo-switzerland { height: 36px; }
  .helvetas-logo-helvetas    { height: 22px; }
  .helvetas-logo-optim       { height: 30px; }
}

/* ── PRODUCT CARDS (results) ── */
.products-row { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; margin-top: 24px; }
.product-card { border-radius: 16px; padding: 32px 28px; display: flex; flex-direction: column; position: relative; overflow: hidden; }
.product-card-finance { background: var(--purple); color: var(--white); }
.product-card-invest  { background: var(--white); border: 1.5px solid var(--border); color: var(--dark); }
.product-card::before {
  content: ''; position: absolute; right: -40px; top: -40px;
  width: 160px; height: 160px; border-radius: 50%; pointer-events: none;
}
.product-card-finance::before { background: radial-gradient(circle, rgba(59,204,156,.18) 0%, transparent 70%); }
.product-card-invest::before  { background: radial-gradient(circle, rgba(91,73,165,.07) 0%, transparent 70%); }
.product-tag { font-size: 10px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; margin-bottom: 14px; display: block; }
.product-card-finance .product-tag { color: rgba(255,255,255,.5); }
.product-card-invest  .product-tag { color: var(--purple-l); }
.product-title { font-family: var(--fh); font-size: 20px; font-weight: 800; line-height: 1.15; letter-spacing: -.02em; margin-bottom: 12px; }
.product-card-finance .product-title { color: var(--white); }
.product-card-invest  .product-title { color: var(--dark); }
.product-desc { font-size: 14px; font-weight: 400; line-height: 1.7; flex: 1; margin-bottom: 24px; }
.product-card-finance .product-desc { color: rgba(255,255,255,.65); }
.product-card-invest  .product-desc { color: var(--muted); }
.product-btn {
  font-family: var(--fb); font-size: 14px; font-weight: 700;
  border: none; cursor: pointer; border-radius: var(--r);
  padding: 12px 20px; transition: all .15s;
  display: inline-flex; align-items: center; gap: 7px; width: fit-content;
}
.product-btn-finance { background: var(--mint); color: var(--white); }
.product-btn-finance:hover { background: var(--mint-d); box-shadow: 0 4px 16px rgba(59,204,156,.35); }
.product-btn-invest  { background: var(--purple); color: var(--white); }
.product-btn-invest:hover  { background: var(--purple-l); box-shadow: 0 4px 16px rgba(71,41,128,.25); }

/* ── FOOTER (landing) ── */
footer { background: var(--dark); padding: 64px 0 32px; }
.ft-inner { max-width: var(--max-w); margin: 0 auto; padding: 0 var(--px); }
.ft-grid {
  display: grid; grid-template-columns: 200px repeat(4, 1fr); gap: 48px;
  padding-bottom: 40px; border-bottom: 1px solid rgba(255,255,255,.07); margin-bottom: 28px;
}
.ft-brand-desc { font-size: 13px; font-weight: 400; color: rgba(255,255,255,.35); line-height: 1.65; max-width: 180px; margin-top: 12px; }
.ft-col h4 { font-family: var(--fh); font-size: 10px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: rgba(255,255,255,.4); margin-bottom: 16px; }
.ft-col a { display: block; font-size: 13px; font-weight: 400; color: rgba(255,255,255,.35); text-decoration: none; margin-bottom: 10px; transition: color .15s; }
.ft-col a:hover { color: rgba(255,255,255,.75); }
.ft-bottom { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 12px; }
.ft-copy { font-size: 12px; font-weight: 400; color: rgba(255,255,255,.25); }
.ft-socials { display: flex; gap: 8px; }
.ft-soc {
  width: 30px; height: 30px; border-radius: 8px;
  border: 1px solid rgba(255,255,255,.1);
  display: flex; align-items: center; justify-content: center;
  text-decoration: none; transition: all .15s;
}
.ft-soc:hover { border-color: var(--mint); background: rgba(59,204,156,.1); }

/* ── FOOTER STRIP (results) ── */
.footer-strip { margin-top: 48px; padding: 32px 0; border-top: 1px solid var(--border); background: var(--white); }
.footer-strip-inner { display: flex; align-items: center; justify-content: space-between; gap: 20px; flex-wrap: wrap; }
.footer-strip-brand { display: flex; align-items: center; gap: 10px; }
.footer-strip-brand span { font-family: var(--fh); font-size: 14px; font-weight: 700; color: var(--dark); }
.footer-strip-links { display: flex; gap: 24px; }
.footer-strip-links a { font-size: 13px; font-weight: 400; color: var(--muted); text-decoration: none; }
.footer-strip-links a:hover { color: var(--dark); }
.footer-copy { font-size: 12px; color: var(--muted); }

/* ── ANIMATIONS (landing) ── */
@keyframes fadeUp { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: translateY(0); } }
.hero-left > * { animation: fadeUp .5s ease both; }
.hero-left > *:nth-child(1) { animation-delay: .05s; }
.hero-left > *:nth-child(2) { animation-delay: .12s; }
.hero-left > *:nth-child(3) { animation-delay: .19s; }
.hero-right { animation: fadeUp .6s ease .2s both; }
.hero-bottom { animation: fadeUp .5s ease .3s both; }

/* ── RESPONSIVE ── */
@media (max-width: 960px) {
  :root { --px: 24px; }
  .nav-links { display: none; }
  .hero-top { grid-template-columns: 1fr; gap: 40px; }
  .hero-right { order: -1; }
  .hc-body { grid-template-columns: 1fr; }
  .hc-chart { border-right: none; border-bottom: 1px solid var(--border); }
  .hero-bottom-inner { gap: 14px; }
  .steps-grid { grid-template-columns: 1fr 1fr; }
  .steps-connector-track { display: none; }
  .step-card { border-bottom: 1.5px solid var(--border); }
  .step-card:nth-child(2) { border-right: none; }
  .step-card:nth-child(3), .step-card:nth-child(4) { border-bottom: none; }
  .fagura-grid { grid-template-columns: 1fr; gap: 48px; }
  .ft-grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 900px) {
  .results-grid { grid-template-columns: 1fr; }
  .right-col { order: -1; }
  .products-row { grid-template-columns: 1fr; }
  body.page-results .cta-band { padding: 32px 28px; }
  body.page-results .metrics-grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 880px) {
  body.page-app .charts-row   { grid-template-columns: 1fr; }
  body.page-app .metrics-grid { grid-template-columns: repeat(2, 1fr); }
}

/* ── MOBILE (≤ 600px) ── */
@media (max-width: 600px) {
  :root { --px: 20px; }

  /* Layout density */
  .section { padding: 48px 0; }
  .hero { padding-top: 12px; }
  .hero > .container { padding-top: 16px; }
  .hero-top { gap: 28px; padding-bottom: 28px; }
  .hero h1 { font-size: clamp(28px, 8vw, 38px); line-height: 1.1; }
  .hero-lead { font-size: 15px; }

  /* Nav (landing/results) */
  .nav-inner { padding: 0 20px; }
  .nav-brand { gap: 10px; }
  .nav-product { display: none; }
  .nav-brand-sep { display: none; }
  .nav-actions .btn-ghost { display: none; }

  /* Topbar (app) — collapse secondary labels */
  .topbar { padding: 0 16px; }
  .topbar-product { display: none; }
  .topbar-sep { display: none; }
  .topbar-user { font-size: 0; gap: 0; }
  .topbar-user .topbar-avatar { font-size: 11px; }

  /* Hero search row stacks */
  .hero-bottom { padding: 36px 0 40px; }
  .hero-search-wrap { padding: 8px; flex-wrap: wrap; }
  .hero-search-wrap .search-icon { margin-left: 6px; }
  .hero-search-wrap input { padding: 6px 0; min-width: 0; width: 100%; flex: 1 1 60%; }
  .hero-search-btn { width: 100%; padding: 12px 20px; margin-top: 6px; }
  .hero-trust { gap: 14px 20px; }

  /* Hero card metrics */
  .hc-metric { padding: 10px 12px; }
  .hc-metric-label { font-size: 8.5px; margin-bottom: 3px; }
  .hc-metric-value { font-size: 15px; }
  .hc-metric-sub { font-size: 9px; }

  /* Company bar (app) */
  .company-bar { padding: 14px 16px; flex-wrap: wrap; gap: 12px; }
  .company-bar-left { gap: 12px; min-width: 0; }
  .company-initial { width: 38px; height: 38px; font-size: 15px; border-radius: 10px; }
  .company-name { font-size: 16px; }
  .company-bar-right { gap: 6px; flex-wrap: wrap; }

  /* Company header (results) */
  .company-header { padding: 16px 0; }
  .company-header-inner { gap: 14px; flex-direction: column; align-items: flex-start; }
  body.page-results .company-meta { gap: 12px; }
  body.page-results .company-name { font-size: 17px; }

  /* Unified header → first-card spacing (~20px on both pages) */
  .main { padding: 20px 0 36px; }
  .main-inner { gap: 16px; }
  .page { padding: 0 0 56px; }
  .results-grid { margin-top: 20px; gap: 16px; }

  /* Card padding tighter */
  .card-header { padding: 14px 16px; }
  .card-body { padding: 18px 16px; }
  body.page-app .card-header { padding: 14px 16px; }
  body.page-app .card-body { padding: 16px; }

  /* Metrics: keep 2-col, slightly smaller numbers */
  .metric-cell { padding: 16px 14px; }
  .metric-value { font-size: 22px; }
  body.page-app .metric-cell  { padding: 14px 14px; }
  body.page-app .metric-value { font-size: 20px; }

  /* CFO summary */
  .cfo-body { padding: 16px; }
  .cfo-text { font-size: 13.5px; line-height: 1.7; }

  /* Charts */
  .chart-inner { padding: 16px 14px 14px; }
  .chart-wrap { padding: 16px 16px 6px; }
  .chart-legend { padding: 0 16px 16px; gap: 12px; flex-wrap: wrap; }

  /* Credit limit (app) */
  .credit-limit-body { padding: 16px; gap: 14px; }
  .credit-amount { font-size: 30px; }
  body.page-results .credit-amount { font-size: 34px; }

  /* Credit card (results right column) */
  .credit-card { padding: 22px 18px; }

  /* Rating */
  .rating-grade-block { padding: 18px 16px; gap: 14px; }
  .rating-grade { font-size: 60px; }
  .rating-grade sup { font-size: 22px; }
  .rating-bars-block { padding: 16px; gap: 10px; }

  /* Chat (app) */
  .chat-intro { padding: 14px 16px 10px; }
  .chat-questions { padding: 0 16px 12px; }
  .chat-q-btn { font-size: 11.5px; padding: 6px 11px; }
  .chat-divider { margin: 0 16px 14px; }
  .chat-messages { padding: 0 16px; max-height: 320px; }
  .chat-messages:empty { min-height: 0; margin-bottom: 0; }
  .chat-msg-bubble { max-width: 88%; padding: 9px 12px; font-size: 12.5px; }
  .chat-attachments { padding: 0 16px 8px; }
  .chat-input-row { padding: 0 16px 16px; gap: 8px; }
  .chat-attach-btn,
  .chat-send-btn { width: 40px; height: 40px; }
  .chat-textarea { min-height: 40px; padding: 9px 12px; }
  .chat-hint { padding: 0 16px 12px; }

  /* Steps (landing) */
  .steps-head { margin-bottom: 36px; }
  .steps-grid { grid-template-columns: 1fr; }
  .step-card { padding: 22px 20px 20px; border-right: none; border-bottom: 1.5px solid var(--border); }
  .step-card:nth-child(3) { border-bottom: 1.5px solid var(--border); }
  .step-card:last-child { border-bottom: none; }
  .step-circle { width: 32px; height: 32px; font-size: 11px; margin-bottom: 16px; }
  .step-card h3 { font-size: 15px; margin-bottom: 6px; }
  .step-card p { font-size: 13px; line-height: 1.6; margin-bottom: 0; }

  /* CTA band (landing) */
  body.page-landing .cta-band { padding: 56px 0; }
  body.page-landing .cta-band-inner { flex-direction: column; align-items: flex-start; gap: 24px; }
  body.page-landing .cta-band-actions { width: 100%; align-items: stretch; }
  body.page-landing .cta-band-actions .btn { justify-content: center; }

  /* CTA band (results) */
  body.page-results .cta-band { padding: 24px; gap: 20px; flex-direction: column; align-items: flex-start; }
  body.page-results .cta-band-actions { width: 100%; flex-direction: column; align-items: stretch; gap: 10px; }

  /* Product cards (results) */
  .product-card { padding: 26px 22px; }
  .product-title { font-size: 18px; }

  /* About Fagura */
  .fagura-stats { gap: 24px; flex-wrap: wrap; }
  .fagura-panel { padding: 18px; }
  .fp-top { padding: 18px 20px; }
  .fp-top-val { font-size: 26px; }
  .fp-card { padding: 14px 14px; }
  .fp-card-val { font-size: 18px; }

  /* Helvetas */
  .helvetas-strip { padding: 56px 0; }
  .helvetas-inner { gap: 36px; }

  /* Footer (landing) */
  .ft-grid { grid-template-columns: 1fr 1fr; gap: 32px 24px; }
  footer { padding: 48px 0 28px; }
  .ft-bottom { justify-content: flex-start; }

  /* Footer strip (results) */
  .footer-strip { padding: 24px 0; margin-top: 32px; }
  .footer-strip-links { gap: 16px; flex-wrap: wrap; }
}

/* ── SMALL MOBILE (≤ 420px) ── */
@media (max-width: 420px) {
  :root { --px: 16px; }
  .topbar { padding: 0 14px; }
  .topbar-brand { gap: 8px; }
  .hero h1 { font-size: clamp(24px, 8.5vw, 30px); }
  .ft-grid { grid-template-columns: 1fr; gap: 24px; }
  .company-bar-right .badge { font-size: 10px; padding: 3px 9px; }
  .credit-amount { font-size: 28px; }
  body.page-results .credit-amount { font-size: 30px; }
  .metric-value { font-size: 20px; }
  body.page-app .metric-value { font-size: 18px; }
  .rating-grade { font-size: 52px; }
  .rating-grade sup { font-size: 18px; }
}

/* ── Minimal landing top bar (logo + back link) ── */
.ai-topbar {
  position: sticky;
  top: 0;
  z-index: 100;
  height: 64px;
  background: rgba(255, 255, 255, .97);
  backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border);
}
.ai-topbar-inner {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 0 var(--px);
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.ai-topbar-logo {
  display: inline-flex;
  align-items: center;
  text-decoration: none;
}
.ai-topbar-logo img,
.ai-topbar-logo svg {
  display: block;
}
.ai-topbar-back {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  font-family: var(--fb);
  font-size: 14px;
  font-weight: 500;
  color: var(--muted);
  text-decoration: none;
  transition: color .15s;
}
.ai-topbar-back:hover {
  color: var(--dark);
}
.ai-topbar-back svg {
  display: block;
}
.admin-bar .ai-topbar {
  top: 32px;
}
@media (max-width: 782px) {
  .admin-bar .ai-topbar {
    top: 46px;
  }
}
@media (max-width: 768px) {
  .ai-topbar-inner {
    padding: 0 20px;
  }
}

/* ── Hero company search dropdown ── */
.hero-search-box {
  position: relative;
  width: 100%;
  max-width: 640px;
}
.hero-search-box .hero-search-wrap {
  max-width: none;
}
.hero-search-results {
  position: absolute;
  top: calc(100% + 8px);
  left: 0;
  right: 0;
  z-index: 60;
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: 12px;
  box-shadow: 0 12px 40px rgba(0, 0, 0, .18);
  overflow: hidden auto;
  max-height: 340px;
  text-align: left;
}
.hero-search-results[hidden] {
  display: none;
}
.hsr-item {
  display: block;
  width: 100%;
  padding: 12px 18px;
  border: none;
  border-bottom: 1px solid var(--border);
  background: transparent;
  cursor: pointer;
  text-align: left;
  font-family: var(--fb);
  transition: background .12s;
}
.hsr-item:last-child {
  border-bottom: none;
}
.hsr-item:hover,
.hsr-item.is-active {
  background: var(--surface);
}
.hsr-name {
  display: block;
  font-size: 14px;
  font-weight: 600;
  color: var(--dark);
}
.hsr-meta {
  display: block;
  margin-top: 2px;
  font-size: 12px;
  color: var(--muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.hsr-empty {
  padding: 14px 18px;
  font-size: 13px;
  color: var(--muted);
  text-align: left;
}

/* ── Search loading indicator ── */
@keyframes hsr-spin {
  to { transform: rotate(360deg); }
}
.hero-search-spinner {
  width: 16px;
  height: 16px;
  flex-shrink: 0;
  margin-right: 8px;
  border: 2px solid var(--border);
  border-top-color: var(--purple);
  border-radius: 50%;
  animation: hsr-spin .6s linear infinite;
}
.hero-search-spinner[hidden] {
  display: none;
}
.hsr-loading {
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 14px 18px;
  font-size: 13px;
  color: var(--muted);
}
.hsr-loading::before {
  content: "";
  width: 14px;
  height: 14px;
  flex-shrink: 0;
  border: 2px solid var(--border);
  border-top-color: var(--purple);
  border-radius: 50%;
  animation: hsr-spin .6s linear infinite;
}

/* ── Topbar: WordPress custom (site) logo ── */
.ai-topbar .custom-logo-link {
  display: inline-flex;
  align-items: center;
  line-height: 0;
}
.ai-topbar .custom-logo {
  display: block;
  height: 30px;
  width: auto;
}

/* Trim the hero's top padding when the landing top bar is present, so there
   is no oversized empty band between the header and the hero content. */
.ai-topbar + .hero {
  padding-top: 0;
}
.ai-topbar + .hero > .container {
  padding-top: 24px;
}

/* ── CTA buttons rendered as links (<a>) — keep the button look ── */
a.product-btn,
a.invest-cta,
a.credit-cta {
  text-decoration: none;
}
a.invest-cta,
a.credit-cta {
  display: block;
  text-align: center;
}

/* Kill the .page padding (32px 0 96px) that added empty space on the body.
   WordPress body_class() adds a "page" class to <body>, so the .page rule
   applied to the body itself on both the landing and the results page.
   On results, also reset the inner .page wrapper. */
body.page-landing,
body.page-results,
body.page-results .page {
  padding: 0;
}

/* Mobile: hide the hero card mini-chart ("Cifră de afaceri") — saves space. */
@media (max-width: 768px) {
  .hc-chart {
    display: none;
  }
}

/* "Creează cont" CTAs rendered as links — no underline. */
a.btn,
a.lock-pill {
  text-decoration: none;
}

/* Remove the focus outline ring on buttons. */
.btn:focus,
.hero-search-btn:focus,
.product-btn:focus,
.invest-cta:focus,
.credit-cta:focus,
.lock-pill:focus {
  outline: none;
}

/* ── Info tooltip (Interpretare AI disclaimer) ── */
.info-tip {
  position: relative;
  display: inline-flex;
  align-items: center;
  margin-left: 5px;
  color: var(--muted);
  cursor: help;
  vertical-align: middle;
}
.info-tip svg {
  display: block;
}
.info-tip-bubble {
  position: absolute;
  top: calc(100% + 8px);
  left: 50%;
  transform: translateX(-50%);
  width: 240px;
  padding: 9px 12px;
  background: var(--dark);
  color: var(--white);
  font-family: var(--fb);
  font-size: 11px;
  font-weight: 400;
  line-height: 1.55;
  border-radius: 8px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, .22);
  opacity: 0;
  visibility: hidden;
  transition: opacity .15s;
  z-index: 70;
  pointer-events: none;
}
.info-tip:hover .info-tip-bubble,
.info-tip:focus .info-tip-bubble,
.info-tip:focus-visible .info-tip-bubble {
  opacity: 1;
  visibility: visible;
}
