/* ── KASHIFDATA — INDUSTRIAL EDITORIAL DESIGN SYSTEM ── */
/* Aesthetic: Bloomberg Terminal meets The Economist     */

@import url('https://fonts.googleapis.com/css2?family=Lato:wght@300;400;700;900&family=JetBrains+Mono:wght@400;500&display=swap');

/* ── DESIGN TOKENS ── */
:root {
  --bg: #f5efe6;
  --bg2: #fbf8f3;
  --bg3: #efe5d6;
  --surface: rgba(255,255,255,0.82);
  --surface2: #fffdf9;
  --surface3: #f0e5d6;
  --border: rgba(108,76,48,0.10);
  --border2: rgba(108,76,48,0.18);
  --border3: rgba(108,76,48,0.28);
  --accent: #ff6b35;
  --accent-light: #ff8d63;
  --accent-dark: #cf4f1f;
  --gold: #d69b1f;
  --green: #138a52;
  --green-light: #21a565;
  --red: #d64545;
  --amber: #d08a17;
  --text: #19120d;
  --text2: #6e5c4d;
  --text3: #a08a78;
  --sans: 'Lato', sans-serif;
  --body: 'Lato', sans-serif;
  --mono: 'JetBrains Mono', monospace;
  --r: 4px;
  --r-sm: 3px;
  --r-md: 6px;
  --r-lg: 8px;
  --shadow: 0 18px 40px rgba(88,55,24,0.10);
}

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

html { scroll-behavior: smooth; }

body {
  background:
    radial-gradient(circle at top left, rgba(255,143,92,0.16), transparent 28%),
    radial-gradient(circle at top right, rgba(209,155,31,0.10), transparent 24%),
    linear-gradient(180deg, #fcfaf6 0%, var(--bg) 52%, #f0e8db 100%);
  color: var(--text);
  font-family: var(--body);
  min-height: 100vh;
  overflow-x: hidden;
  line-height: 1.6;
}

/* Grain texture overlay */
body::after {
  content: '';
  position: fixed;
  inset: 0;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='300' height='300'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.75' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='300' height='300' filter='url(%23n)' opacity='1'/%3E%3C/svg%3E");
  opacity: 0.018;
  pointer-events: none;
  z-index: 9999;
}

/* ── SCROLLBAR ── */
::-webkit-scrollbar { width: 4px; height: 4px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: var(--surface3); border-radius: 2px; }
::-webkit-scrollbar-thumb:hover { background: var(--accent); }

/* ── TYPOGRAPHY ── */
h1, h2, h3, h4 {
  font-family: var(--sans);
  font-weight: 800;
  line-height: 1.1;
  letter-spacing: -0.02em;
}

.display {
  font-family: var(--sans);
  font-weight: 800;
  font-size: clamp(2.4rem, 5vw, 4.5rem);
  line-height: 1.0;
  letter-spacing: -0.03em;
  color: var(--text);
}

.eyebrow {
  font-family: var(--mono);
  font-size: 10px;
  font-weight: 500;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 16px;
}

.label {
  font-family: var(--mono);
  font-size: 10px;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text2);
}

.section-rule {
  width: 100%;
  height: 1px;
  background: var(--border);
  margin: 40px 0;
}

/* ── LAYOUT ── */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 32px;
}

/* ── RTL ── */
[dir="rtl"] { font-family: 'Noto Sans Arabic', 'Lato', sans-serif; }
[dir="rtl"] .report-table th,
[dir="rtl"] .report-table td { text-align: right; }
[dir="rtl"] .finding-item { flex-direction: row-reverse; }
[dir="rtl"] .check-item { flex-direction: row-reverse; }
[dir="rtl"] .loading-step { flex-direction: row-reverse; }
[dir="rtl"] .report-tabs { direction: rtl; }
[dir="rtl"] .logo { flex-direction: row-reverse; }
[dir="rtl"] .header-right { flex-direction: row-reverse; }
[dir="rtl"] .report-header { flex-direction: row-reverse; }
[dir="rtl"] .quality-score { flex-direction: row-reverse; }
[dir="rtl"] .field label { text-align: right; }
[dir="rtl"] .section-label { flex-direction: row-reverse; }
[dir="rtl"] .section-label::after { display: none; }
[dir="rtl"] .section-label::before { content: ''; flex: 1; height: 1px; background: var(--border); }
[dir="rtl"] .file-badge { text-align: right; }
[dir="rtl"] .verdict-box::before { left: auto; right: 16px; }
[dir="rtl"] .loading-steps { text-align: right; }
[dir="rtl"] .stat-card { direction: rtl; }
[dir="rtl"] .usage-inner { flex-direction: row-reverse; }
[dir="rtl"] .field-hint { border-left: none; border-right: 2px solid rgba(255,107,53,0.35); border-radius: 4px 0 0 4px; }

/* ── PRINT ── */
@media print {
  @page { margin: 15mm; size: auto; }
  body { background: #fff !important; color: #000 !important; font-size: 11pt; }
  header, footer, .nav-premium-btn, .tab-nav, .btns-row, .modal-overlay,
  #shareOverlay, #upload-section, #loading-section, .chart-actions,
  .stats-strip, .usage-bar, #printGuideModal { display: none !important; }
  #report-section { display: block !important; margin: 0 !important; padding: 0 !important; width: 100% !important; max-width: none !important; }
  .report-container { border: none !important; padding: 0 !important; background: transparent !important; box-shadow: none !important; }
  .tab-content {
    display: block !important; opacity: 1 !important; visibility: visible !important;
    height: auto !important; overflow: visible !important; position: relative !important;
    margin-bottom: 30px !important; page-break-after: always;
    border: none !important; background: transparent !important;
    box-shadow: none !important; transform: none !important;
  }
  .tab-content:last-child { page-break-after: auto; }
  .scroll-reveal { opacity: 1 !important; visibility: visible !important; transform: none !important; transition: none !important; animation: none !important; }
  .card { border: 1px solid #eee !important; box-shadow: none !important; background: #fff !important; break-inside: avoid; margin-bottom: 20px !important; color: #111 !important; transform: none !important; }
  .section-label { color: #FF6B35 !important; border-bottom: 1px solid #eee !important; padding-bottom: 8px !important; }
  .verdict-box { background: #f8f8f8 !important; border: 1px solid #eee !important; color: #333 !important; }
  .insight-step { break-inside: avoid; border-left: 2px solid #eee !important; }
  .report-table thead th { background: #f5f5f5 !important; color: #000 !important; }
  .report-table td { border-bottom: 1px solid #eee !important; }
  canvas { max-width: 100% !important; height: auto !important; margin: 20px 0; display: block !important; }
  .gauge-svg { max-width: 140px; margin: 0 auto; display: block !important; }
  * { -webkit-print-color-adjust: exact !important; print-color-adjust: exact !important; transition: none !important; transform: none !important; }
}

/* ── HEADER ── */
header {
  position: sticky;
  top: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 32px;
  height: 56px;
  background: rgba(251,248,243,0.88);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--border2);
}

.logo {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  cursor: pointer;
}

.logo-icon {
  width: 28px;
  height: 28px;
  border-radius: 4px;
  object-fit: cover;
}

.logo-text {
  font-family: var(--sans);
  font-size: 16px;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: var(--text);
}

.logo-text span { color: var(--accent); }

.header-right {
  display: flex;
  align-items: center;
  gap: 8px;
}

/* Language button */
.lang-btn {
  padding: 5px 12px;
  background: transparent;
  border: 1px solid var(--border2);
  color: var(--text2);
  border-radius: var(--r);
  cursor: pointer;
  font-family: var(--mono);
  font-size: 10px;
  transition: all 0.15s;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.lang-btn:hover { border-color: var(--accent); color: var(--accent); }

/* User/plan badges */
.header-badge {
  font-family: var(--mono);
  font-size: 10px;
  color: var(--green);
  border: 1px solid rgba(34,197,94,0.2);
  padding: 4px 10px;
  border-radius: var(--r);
  background: rgba(34,197,94,0.05);
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.plan-badge {
  font-family: var(--mono);
  font-size: 10px;
  font-weight: 700;
  padding: 4px 10px;
  border-radius: var(--r);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  display: none;
  align-items: center;
  gap: 6px;
  animation: fadeUp 0.3s ease;
}

.plan-pro {
  background: rgba(255,107,53,0.1);
  color: var(--accent-light);
  border: 1px solid rgba(255,107,53,0.25);
}

.plan-starter {
  background: rgba(34,197,94,0.08);
  color: var(--green);
  border: 1px solid rgba(34,197,94,0.2);
}

.plan-badge i { font-style: normal; font-size: 12px; }

/* Premium button */
.nav-premium-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 14px;
  background: var(--accent);
  color: #1d120c;
  border: none;
  border-radius: var(--r);
  cursor: pointer;
  font-family: var(--sans);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.02em;
  transition: background 0.15s, transform 0.15s;
  white-space: nowrap;
}

.nav-premium-btn:hover { background: var(--accent-light); transform: translateY(-1px); }

/* User name */
#userNameBadge {
  font-family: var(--mono);
  font-size: 10px;
  color: var(--text2);
  padding: 4px 10px;
  border: 1px solid var(--border);
  border-radius: var(--r);
  background: rgba(255,255,255,0.65);
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

/* Sign out */
#signOutBtn {
  padding: 5px 12px;
  background: transparent;
  border: 1px solid var(--border2);
  color: var(--text2);
  border-radius: var(--r);
  cursor: pointer;
  font-family: var(--mono);
  font-size: 10px;
  transition: all 0.15s;
  letter-spacing: 0.05em;
}

#signOutBtn:hover { border-color: var(--red); color: var(--red); }

/* Mobile nav */
.hamburger,
.hamburger-btn {
  display: none;
  flex-direction: column;
  gap: 4px;
  cursor: pointer;
  padding: 4px;
  background: none;
  border: none;
}

.hamburger span,
.hamburger-btn span {
  width: 20px;
  height: 1.5px;
  background: var(--text2);
  transition: all 0.2s;
}

.mobile-nav,
.mobile-dropdown {
  display: none;
  flex-direction: column;
  gap: 4px;
  padding: 12px 16px;
  border-top: 1px solid var(--border2);
  background: rgba(251,248,243,0.96);
  backdrop-filter: blur(18px);
}

.mobile-nav.open,
.mobile-dropdown.open { display: flex; }
.mobile-nav .lang-btn,
.mobile-dropdown .lang-btn,
.mobile-dropdown .lang-btn-new { justify-content: flex-start; }

/* Language dropdown wrapper */
.lang-wrap { position: relative; }

.lang-dropdown {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  background: var(--surface2);
  border: 1px solid var(--border2);
  border-radius: var(--r-md);
  min-width: 110px;
  overflow: hidden;
  z-index: 200;
  display: none;
  animation: fadeUp 0.15s ease;
}

.lang-dropdown.open { display: block; }

.lang-option,
.lang-opt {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 14px;
  cursor: pointer;
  font-family: var(--body);
  font-size: 12px;
  color: var(--text2);
  transition: background 0.1s, color 0.1s;
  letter-spacing: 0.01em;
  justify-content: space-between;
}

.lang-option:hover,
.lang-opt:hover { background: var(--surface3); color: var(--text); }
.lang-option.active,
.lang-opt.active { color: var(--accent-dark); }

.lang-btn-new {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px 12px;
  background: rgba(255,255,255,0.56);
  border: 1px solid var(--border2);
  border-radius: var(--r);
  color: var(--text2);
  font-family: var(--mono);
  font-size: 10px;
  cursor: pointer;
  transition: all 0.15s;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.lang-btn-new:hover,
.lang-btn-new.open {
  border-color: rgba(255,107,53,0.35);
  color: var(--accent-dark);
  background: rgba(255,255,255,0.9);
}

.mobile-link,
.mobile-lang-link {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 14px 4px;
  color: var(--text2);
  text-decoration: none;
  border-bottom: 1px solid var(--border);
  transition: color 0.15s;
}

.mobile-link:hover,
.mobile-lang-link:hover {
  color: var(--text);
}

.mobile-lang-sub { display: none; }
.mobile-lang-sub.open { display: flex; flex-direction: column; }

/* Mobile header adjustments */
@media (max-width: 768px) {
  header { padding: 0 16px; }
  .logo-text { font-size: 15px; }
  .header-right { display: none; }
  .hamburger-btn { display: flex; }
}

@media (max-width: 600px) {
  .logo-text { display: none; }
  .lang-btn { padding: 4px 8px; font-size: 9px; }
  .nav-premium-btn { padding: 5px 10px; font-size: 9px; }
  .header-badge { display: none; }
  #userNameBadge { display: none !important; }
  .plan-badge { display: none !important; }
  #signOutBtn { padding: 4px 10px; font-size: 9px; }
}

/* ── USAGE BAR ── */
#usageBar {
  display: none;
  background: var(--bg2);
  border-bottom: 1px solid var(--border);
  padding: 6px 32px;
}

.usage-inner {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  gap: 12px;
  font-family: var(--mono);
  font-size: 10px;
  color: var(--text3);
  letter-spacing: 0.05em;
}

.usage-track {
  flex: 1;
  max-width: 120px;
  height: 2px;
  background: var(--border2);
  border-radius: 1px;
  overflow: hidden;
}

#usageProgress {
  height: 100%;
  background: var(--accent);
  border-radius: 1px;
  transition: width 0.4s, background 0.4s;
}

@media (max-width: 600px) {
  #usageBar { padding: 5px 16px; }
  .usage-track { max-width: 80px; }
}

/* ── MAIN ── */
main {
  position: relative;
  z-index: 1;
  max-width: 1200px;
  margin: 0 auto;
  padding: 40px 32px 80px;
}

@media (max-width: 600px) {
  main { padding: 24px 16px 60px; }
}

/* ── BUTTONS ── */
.btn-primary {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 24px;
  background: var(--accent);
  color: #000;
  border: none;
  border-radius: var(--r);
  cursor: pointer;
  font-family: var(--sans);
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 0.01em;
  text-decoration: none;
  transition: background 0.15s, transform 0.15s;
  white-space: nowrap;
}

.btn-primary:hover { background: var(--accent-light); transform: translateY(-1px); }
.btn-primary:active { transform: translateY(0); }
.btn-primary:disabled { background: var(--surface3); color: var(--text3); cursor: not-allowed; transform: none; }

.btn-ghost {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 11px 24px;
  background: transparent;
  color: var(--text);
  border: 1px solid var(--border3);
  border-radius: var(--r);
  cursor: pointer;
  font-family: var(--sans);
  font-size: 14px;
  font-weight: 600;
  text-decoration: none;
  transition: all 0.15s;
}

.btn-ghost:hover { border-color: var(--accent); color: var(--accent); }

.btn-sm {
  padding: 7px 16px;
  font-size: 12px;
}

.btn-icon {
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(255,255,255,0.72);
  border: 1px solid var(--border2);
  border-radius: var(--r);
  cursor: pointer;
  color: var(--text2);
  font-size: 13px;
  transition: all 0.15s;
}

.btn-icon:hover { background: var(--surface3); color: var(--text); border-color: var(--border3); }

.btn-ok {
  padding: 11px 28px;
  background: var(--accent);
  color: #000;
  border: none;
  border-radius: var(--r);
  cursor: pointer;
  font-family: var(--sans);
  font-size: 14px;
  font-weight: 700;
  transition: background 0.15s;
}

.btn-ok:hover { background: var(--accent-light); }

/* ── CARDS ── */
.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-lg);
  padding: 24px;
  position: relative;
  box-shadow: var(--shadow);
  backdrop-filter: blur(10px);
}

/* ── FORMS ── */
.field { margin-bottom: 16px; }

.field label {
  display: block;
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.12em;
  color: var(--text2);
  text-transform: uppercase;
  font-family: var(--mono);
  margin-bottom: 8px;
}

.field textarea,
.field input[type="text"] {
  width: 100%;
  background: rgba(255,255,255,0.84);
  border: 1px solid var(--border2);
  border-radius: var(--r);
  padding: 11px 14px;
  color: var(--text);
  font-family: var(--body);
  font-size: 14px;
  resize: vertical;
  transition: border-color 0.15s, box-shadow 0.15s;
  outline: none;
  line-height: 1.5;
}

.field textarea:focus,
.field input[type="text"]:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(255,107,53,0.12);
}

.field textarea { min-height: 80px; }

.field-label-row {
  display: flex;
  align-items: center;
  gap: 5px;
  margin-bottom: 8px;
}

.field-label-row label { margin-bottom: 0; }

.req-star {
  color: var(--accent);
  font-size: 13px;
  font-weight: 700;
  font-family: var(--mono);
  line-height: 1;
  flex-shrink: 0;
}

.field-hint {
  font-size: 11.5px;
  color: var(--text2);
  line-height: 1.55;
  margin-bottom: 8px;
  font-family: var(--body);
  padding: 8px 12px;
  background: rgba(255,255,255,0.52);
  border-left: 2px solid rgba(255,107,53,0.35);
  border-radius: 0 var(--r) var(--r) 0;
}

.field-error-msg {
  font-size: 11px;
  color: var(--red);
  margin-top: 5px;
  font-family: var(--mono);
  display: none;
  align-items: center;
  gap: 4px;
}

.field-error-msg.visible { display: flex; }

.field textarea.input-error,
.field input.input-error {
  border-color: var(--red) !important;
  box-shadow: 0 0 0 3px rgba(239,68,68,0.12) !important;
}

/* Section labels in report */
.section-label {
  display: flex;
  align-items: center;
  gap: 12px;
  font-family: var(--mono);
  font-size: 10px;
  font-weight: 600;
  color: var(--accent);
  text-transform: uppercase;
  letter-spacing: 0.15em;
  margin-bottom: 20px;
  margin-top: 32px;
}

.section-label::after {
  content: '';
  flex: 1;
  height: 1px;
  background: var(--border);
}

/* ── PRIVACY SHIELD ── */
.privacy-shield {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 7px 14px;
  background: rgba(34,197,94,0.04);
  border: 1px solid rgba(34,197,94,0.15);
  border-radius: var(--r);
  font-family: var(--mono);
  font-size: 10px;
  color: var(--text2);
  cursor: pointer;
  position: relative;
  transition: all 0.2s;
  margin: 16px auto;
  user-select: none;
  letter-spacing: 0.05em;
}

.privacy-shield:hover {
  background: rgba(34,197,94,0.08);
  border-color: rgba(34,197,94,0.3);
  color: var(--green);
}

.ps-icon {
  font-size: 13px;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
}

.ps-icon::after {
  content: '';
  position: absolute;
  inset: -4px;
  background: var(--green);
  border-radius: 50%;
  opacity: 0.15;
  animation: pulse-ring 2s ease infinite;
}

@keyframes pulse-ring {
  0% { transform: scale(0.5); opacity: 0.5; }
  80%, 100% { transform: scale(1.4); opacity: 0; }
}

.ps-popover {
  position: absolute;
  bottom: calc(100% + 10px);
  left: 50%;
  transform: translateX(-50%) translateY(8px);
  width: 270px;
  background: var(--surface2);
  border: 1px solid var(--border3);
  border-radius: var(--r-lg);
  padding: 16px;
  box-shadow: 0 16px 40px rgba(0,0,0,0.8);
  opacity: 0;
  visibility: hidden;
  transition: all 0.2s;
  z-index: 1000;
  text-align: left;
  pointer-events: none;
}

[dir="rtl"] .ps-popover { text-align: right; }

.ps-popover::after {
  content: '';
  position: absolute;
  top: 100%;
  left: 50%;
  transform: translateX(-50%);
  border: 5px solid transparent;
  border-top-color: var(--border3);
}

.privacy-shield:hover .ps-popover {
  opacity: 1;
  visibility: visible;
  transform: translateX(-50%) translateY(0);
}

.ps-title {
  font-weight: 700;
  color: var(--green);
  margin-bottom: 8px;
  font-size: 11px;
  font-family: var(--mono);
  display: flex;
  align-items: center;
  gap: 6px;
  letter-spacing: 0.08em;
}

.ps-details {
  font-size: 11px;
  color: var(--text2);
  line-height: 1.5;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.ps-row { display: flex; gap: 8px; align-items: flex-start; }
.ps-row i { color: var(--green); font-style: normal; flex-shrink: 0; }

/* ── HERO SECTION (dashboard) ── */
.hero {
  text-align: center;
  padding: 48px 0 40px;
  animation: fadeUp 0.6s ease both;
}

.hero-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: rgba(255,107,53,0.08);
  border: 1px solid rgba(255,107,53,0.2);
  border-radius: var(--r);
  padding: 5px 14px;
  font-size: 10px;
  font-weight: 600;
  color: var(--accent);
  letter-spacing: 0.12em;
  margin-bottom: 20px;
  font-family: var(--mono);
  text-transform: uppercase;
}

.hero-pill-dot {
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--accent);
  animation: blink 2s infinite;
}

@keyframes blink {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.2; }
}

.hero h1 {
  font-size: clamp(2rem, 5vw, 3.5rem);
  font-weight: 800;
  line-height: 1.05;
  letter-spacing: -0.03em;
  margin-bottom: 16px;
  color: var(--text);
}

.hero h1 em {
  font-style: normal;
  color: var(--accent);
}

.hero-desc {
  font-size: 15px;
  color: var(--text2);
  max-width: 480px;
  margin: 0 auto 32px;
  line-height: 1.7;
  font-weight: 400;
}

.hero-stats {
  display: flex;
  justify-content: center;
  gap: 40px;
  flex-wrap: wrap;
}

.hero-stat { text-align: center; }

.hero-stat-num {
  font-family: var(--sans);
  font-size: 22px;
  font-weight: 800;
  color: var(--accent);
  letter-spacing: -0.03em;
  display: block;
}

.hero-stat-label {
  font-size: 10px;
  color: var(--text3);
  font-family: var(--mono);
  letter-spacing: 0.12em;
  text-transform: uppercase;
  display: block;
  margin-top: 2px;
}

@media (max-width: 500px) {
  .hero { padding: 32px 0 24px; }
  .hero-stats { gap: 24px; }
}

/* ── UPLOAD CARD ── */
.upload-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-top: 2px solid var(--accent);
  border-radius: var(--r-lg);
  padding: 28px;
  position: relative;
  overflow: hidden;
  animation: fadeUp 0.6s 0.1s ease both;
}

.upload-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 28px;
}

@media (max-width: 700px) {
  .upload-grid { grid-template-columns: 1fr; }
}

/* Drop zone */
.drop-zone {
  position: relative;
  border: 1.5px dashed var(--border3);
  border-radius: var(--r-md);
  padding: 40px 20px;
  text-align: center;
  transition: all 0.2s;
  background: transparent;
  min-height: 210px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

#fileInput {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  opacity: 0;
  cursor: pointer;
  z-index: 10;
}

.drop-zone:hover {
  border-color: var(--accent);
  background: rgba(255,107,53,0.04);
}

.drop-zone.drag-over {
  border-color: var(--green);
  background: rgba(34,197,94,0.06);
}

.drop-zone h3, .drop-zone p, .drop-icon-wrap { pointer-events: none; }

.drop-icon-wrap {
  width: 48px;
  height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--surface2);
  border: 1px solid var(--border2);
  border-radius: var(--r-md);
  margin: 0 auto 16px;
  font-size: 22px;
}

.file-badge {
  display: none;
  margin-top: 12px;
  background: rgba(34,197,94,0.06);
  border: 1px solid rgba(34,197,94,0.2);
  border-radius: var(--r);
  padding: 10px 14px;
  font-family: var(--mono);
  font-size: 11px;
  color: var(--green);
  text-align: left;
  line-height: 1.6;
  letter-spacing: 0.03em;
}

.file-badge.visible { display: block; }

.upload-privacy {
  margin-top: 20px;
  padding-top: 16px;
  border-top: 1px solid var(--border);
  text-align: center;
  font-size: 10px;
  color: var(--text3);
  font-family: var(--mono);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  width: 100%;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

/* Config panel section header */
.config-header {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 20px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--border);
}

.config-header-icon {
  width: 28px;
  height: 28px;
  background: var(--surface2);
  border: 1px solid var(--border2);
  border-radius: var(--r);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 13px;
}

.config-header-title {
  font-family: var(--mono);
  font-size: 10px;
  font-weight: 600;
  color: var(--text2);
  text-transform: uppercase;
  letter-spacing: 0.12em;
}

/* Analytics type cards */
.analytics-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  margin-top: 8px;
}

.analytics-card {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 11px 12px;
  background: var(--bg2);
  border: 1px solid var(--border);
  border-radius: var(--r);
  cursor: pointer;
  transition: all 0.15s;
  user-select: none;
  position: relative;
}

.analytics-card:hover { border-color: var(--border3); background: var(--surface); }

.analytics-card.active {
  border-color: var(--accent);
  background: rgba(255,107,53,0.06);
}

.analytics-icon {
  font-size: 18px;
  flex-shrink: 0;
  width: 34px;
  height: 34px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--surface2);
  border: 1px solid var(--border);
  border-radius: var(--r);
  transition: all 0.15s;
}

.analytics-card.active .analytics-icon {
  background: rgba(255,107,53,0.1);
  border-color: rgba(255,107,53,0.25);
}

.analytics-body { flex: 1; min-width: 0; }

.analytics-name {
  font-size: 12px;
  font-weight: 700;
  font-family: var(--sans);
  color: var(--text);
  margin-bottom: 2px;
}

.analytics-card.active .analytics-name { color: var(--accent); }

.analytics-desc {
  font-size: 10px;
  color: var(--text2);
  font-family: var(--mono);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* Analyse button */
#analyseBtn {
  width: 100%;
  margin-top: 20px;
  padding: 14px;
  background: var(--accent);
  color: #000;
  border: none;
  border-radius: var(--r);
  cursor: pointer;
  font-family: var(--sans);
  font-size: 15px;
  font-weight: 800;
  letter-spacing: 0.01em;
  transition: background 0.15s, transform 0.15s;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

#analyseBtn:hover:not(:disabled) { background: var(--accent-light); transform: translateY(-1px); }
#analyseBtn:disabled { background: var(--surface3); color: var(--text3); cursor: not-allowed; transform: none; }

/* ── LOADING SECTION ── */
#loading-section {
  display: none;
  text-align: center;
  padding: 60px 0;
  animation: fadeUp 0.5s ease;
}

.loading-orb {
  width: 56px;
  height: 56px;
  border: 2px solid var(--border2);
  border-top-color: var(--accent);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
  margin: 0 auto 24px;
}

@keyframes spin { to { transform: rotate(360deg); } }

#loading-section h2 {
  font-family: var(--sans);
  font-size: 22px;
  font-weight: 800;
  margin-bottom: 6px;
  letter-spacing: -0.02em;
}

#loading-section .loading-sub {
  font-size: 12px;
  color: var(--text2);
  font-family: var(--mono);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin-bottom: 32px;
}

.loading-steps {
  display: flex;
  flex-direction: column;
  gap: 10px;
  max-width: 320px;
  margin: 0 auto;
  text-align: left;
}

.loading-step {
  display: flex;
  align-items: center;
  gap: 14px;
  font-family: var(--mono);
  font-size: 11px;
  color: var(--text3);
  letter-spacing: 0.05em;
  transition: color 0.3s;
}

.loading-step .step-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--surface3);
  border: 1px solid var(--border2);
  flex-shrink: 0;
  transition: background 0.3s, border-color 0.3s, transform 0.3s;
}

.loading-step .step-num {
  font-size: 10px;
  color: var(--text3);
  width: 20px;
  text-align: right;
  flex-shrink: 0;
}

.loading-step .step-bar {
  width: 2px;
  height: 16px;
  background: var(--border2);
  border-radius: 1px;
  flex-shrink: 0;
  transition: background 0.3s;
}

.loading-step.active {
  color: var(--text);
}

.loading-step.active .step-dot {
  background: var(--accent);
  border-color: rgba(255,107,53,0.28);
  transform: scale(1.15);
}

.loading-step.active .step-bar { background: var(--accent); }
.loading-step.active .step-num { color: var(--accent); }

.loading-step.done {
  color: var(--text2);
}

.loading-step.done .step-dot {
  background: var(--green);
  border-color: rgba(19,138,82,0.24);
}

.loading-step.done .step-bar { background: var(--green); }
.loading-step.done .step-num { color: var(--green); }

/* ── REPORT SECTION ── */
#report-section {
  display: none;
  animation: fadeUp 0.5s ease;
}

.report-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 20px;
  padding-bottom: 16px;
  border-bottom: 1px solid var(--border);
  flex-wrap: wrap;
}

.report-title {
  font-family: var(--sans);
  font-size: 18px;
  font-weight: 800;
  letter-spacing: -0.02em;
}

.report-title span { color: var(--accent); }

.btns-row {
  display: flex;
  align-items: center;
  gap: 8px;
}

.report-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.btn-report {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 7px 14px;
  background: var(--surface2);
  border: 1px solid var(--border2);
  border-radius: var(--r);
  cursor: pointer;
  font-family: var(--body);
  font-size: 13px;
  font-weight: 700;
  color: var(--text);
  transition: transform 0.18s ease, box-shadow 0.18s ease, border-color 0.18s ease, background 0.18s ease, color 0.18s ease;
  letter-spacing: 0.01em;
  white-space: nowrap;
  box-shadow: 0 10px 24px rgba(88,55,24,0.06);
}

.btn-report:hover {
  border-color: rgba(255,107,53,0.35);
  color: var(--accent-dark);
  background: rgba(255,248,241,0.98);
  transform: translateY(-1px);
  box-shadow: 0 16px 32px rgba(88,55,24,0.10);
}
.btn-report:active { transform: translateY(0); }
.btn-report.btn-new { border-color: var(--border); }

.report-action-btn {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  min-height: 42px;
  padding: 10px 18px;
  border-radius: 12px;
  cursor: pointer;
  font-family: var(--sans);
  font-size: 13px;
  font-weight: 700;
  white-space: nowrap;
  letter-spacing: 0;
  transition: transform 0.18s ease, box-shadow 0.18s ease, border-color 0.18s ease, background 0.18s ease, color 0.18s ease, filter 0.18s ease;
}

.report-action-btn::before {
  content: "";
  position: absolute;
  inset: 1px;
  border-radius: 11px;
  background: linear-gradient(135deg, rgba(255,255,255,0.2), rgba(255,255,255,0));
  opacity: 0;
  transition: opacity 0.18s ease;
  pointer-events: none;
}

.report-action-btn:hover::before,
.report-action-btn:focus-visible::before {
  opacity: 1;
}

.report-action-btn:hover {
  transform: translateY(-2px);
}

.report-action-btn:active {
  transform: translateY(0);
  filter: saturate(1.05);
}

.report-action-btn:focus-visible {
  outline: none;
  box-shadow: 0 0 0 3px rgba(255,107,53,0.18);
}

.btn-action-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 18px;
  height: 18px;
  flex-shrink: 0;
}

.btn-download {
  border: 1px solid rgba(196, 62, 28, 0.2);
  background: linear-gradient(135deg, #ed6c47 0%, #d9562f 46%, #c43e1c 100%);
  color: #fff;
  box-shadow: 0 14px 28px rgba(196, 62, 28, 0.22);
}

.btn-download:hover {
  box-shadow: 0 20px 36px rgba(196, 62, 28, 0.3);
}

.btn-download:disabled {
  opacity: 0.65;
  cursor: not-allowed;
  transform: none;
  box-shadow: none;
}

.btn-share {
  border: 1px solid rgba(0, 206, 201, 0.26);
  background: linear-gradient(135deg, rgba(255,255,255,0.96), rgba(233,255,252,0.98));
  color: #0d8f8c;
  box-shadow: 0 14px 28px rgba(0, 206, 201, 0.12);
}

.btn-share:hover {
  border-color: rgba(0, 206, 201, 0.4);
  box-shadow: 0 20px 36px rgba(0, 206, 201, 0.18);
}

.btn-new {
  border: 1px solid var(--border2);
  background: rgba(255,255,255,0.9);
  color: var(--text2);
  box-shadow: 0 12px 24px rgba(88,55,24,0.08);
}

.btn-new:hover {
  border-color: rgba(255,107,53,0.28);
  color: var(--text);
  box-shadow: 0 18px 34px rgba(88,55,24,0.12);
}

@media (max-width: 640px) {
  .report-actions {
    width: 100%;
  }

  .report-action-btn {
    flex: 1 1 100%;
  }
}

/* Free watermark */
#freeWatermark {
  display: none;
  margin-bottom: 12px;
  padding: 10px 16px;
  background: rgba(255,107,53,0.06);
  border: 1px solid rgba(255,107,53,0.2);
  border-radius: var(--r);
  font-family: var(--mono);
  font-size: 10px;
  color: var(--accent);
  text-align: center;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

/* Retranslate banner */
#retranslateBanner {
  display: none;
  margin-bottom: 12px;
  padding: 10px 16px;
  background: rgba(255,184,0,0.06);
  border: 1px solid rgba(255,184,0,0.2);
  border-radius: var(--r);
  font-family: var(--mono);
  font-size: 10px;
  color: var(--gold);
  text-align: center;
  letter-spacing: 0.05em;
  cursor: pointer;
}

/* Stats row (KPI cards) */
.stats-strip,
.stats-row,
#statsRow {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 12px;
  margin-bottom: 20px;
  animation: fadeUp 0.5s 0.1s ease both;
}

@media (max-width: 700px) {
  .stats-strip,
  .stats-row,
  #statsRow { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 380px) {
  .stats-strip,
  .stats-row,
  #statsRow { grid-template-columns: 1fr; }
}

.stat-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-lg);
  padding: 16px 20px;
  min-height: 90px;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  position: relative;
  overflow: hidden;
}

.stat-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: var(--accent);
  opacity: 0.5;
}

.stat-value {
  font-family: var(--sans);
  font-size: clamp(1.6rem, 3vw, 2.4rem);
  font-weight: 800;
  color: var(--text);
  line-height: 1;
  letter-spacing: -0.03em;
  margin-bottom: 4px;
  font-variant-numeric: tabular-nums;
}

.stat-trend {
  font-family: var(--mono);
  font-size: 11px;
  padding: 2px 6px;
  border-radius: var(--r-sm);
  display: inline-block;
  margin-bottom: 6px;
}

.stat-trend.up { color: var(--green); background: rgba(34,197,94,0.08); }
.stat-trend.down { color: var(--red); background: rgba(239,68,68,0.08); }

.stat-label {
  font-family: var(--mono);
  font-size: 9px;
  color: var(--text3);
  text-transform: uppercase;
  letter-spacing: 0.12em;
}

.stat-subtitle {
  margin-top: 8px;
  font-family: var(--body);
  font-size: 15px;
  line-height: 1.45;
  color: var(--text2);
  letter-spacing: 0;
}

/* ── REPORT TABS ── */
.report-container {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-lg);
  overflow: hidden;
  animation: fadeUp 0.5s 0.15s ease both;
}

.tab-nav {
  display: flex;
  border-bottom: 1px solid var(--border);
  background: var(--bg2);
  overflow-x: auto;
  scrollbar-width: none;
}

.tab-nav::-webkit-scrollbar { display: none; }

.tab-btn {
  flex-shrink: 0;
  padding: 14px 18px;
  background: none;
  border: none;
  border-bottom: 2px solid transparent;
  color: var(--text2);
  font-family: var(--mono);
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  cursor: pointer;
  transition: all 0.15s;
  white-space: nowrap;
  margin-bottom: -1px;
}

.tab-btn:hover { color: var(--text); }
.tab-btn.active { color: var(--accent); border-bottom-color: var(--accent); }

.tab-content {
  display: none;
  padding: 28px;
  opacity: 0;
  transform: translateY(4px);
  transition: opacity 0.2s, transform 0.2s;
}

.tab-content.active {
  display: block;
  opacity: 1;
  transform: none;
}

/* ── REPORT CONTENT COMPONENTS ── */
.report-table-wrap { overflow-x: auto; -webkit-overflow-scrolling: touch; margin-bottom: 20px; }

.report-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13px;
}

.report-table thead th {
  background: var(--bg3);
  padding: 10px 14px;
  text-align: left;
  font-family: var(--mono);
  font-size: 10px;
  font-weight: 600;
  color: var(--text2);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  border-bottom: 1px solid var(--border2);
  white-space: nowrap;
}

.report-table tbody tr { border-bottom: 1px solid var(--border); }
.report-table tbody tr:last-child { border-bottom: none; }
.report-table tbody tr:hover { background: rgba(255,255,255,0.02); }

.report-table td {
  padding: 10px 14px;
  color: var(--text);
  vertical-align: top;
  font-size: 13px;
  line-height: 1.5;
}

/* Severity badges */
.sev-badge {
  display: inline-block;
  padding: 2px 8px;
  border-radius: var(--r-sm);
  font-family: var(--mono);
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.sev-high { background: rgba(239,68,68,0.12); color: var(--red); }
.sev-mid { background: rgba(245,158,11,0.12); color: var(--amber); }
.sev-low { background: rgba(34,197,94,0.1); color: var(--green); }

/* Status dots */
.status-dot {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
}

.status-dot::before {
  content: '';
  width: 6px;
  height: 6px;
  border-radius: 50%;
  flex-shrink: 0;
}

.status-clean::before { background: var(--green); }
.status-warn::before { background: var(--amber); }
.status-crit::before { background: var(--red); }

/* Quality gauge */
.quality-score {
  display: flex;
  align-items: center;
  gap: 24px;
  padding: 24px;
  background: var(--bg2);
  border: 1px solid var(--border);
  border-radius: var(--r-lg);
  margin-bottom: 24px;
}

.gauge-wrap {
  flex-shrink: 0;
  width: 100px;
  height: 100px;
}

.gauge-svg { width: 100%; height: 100%; }

.quality-details { flex: 1; }
.quality-score-num {
  font-family: var(--sans);
  font-size: 3rem;
  font-weight: 800;
  color: var(--text);
  line-height: 1;
  letter-spacing: -0.03em;
  font-variant-numeric: tabular-nums;
}

.quality-label {
  font-family: var(--mono);
  font-size: 10px;
  color: var(--text2);
  text-transform: uppercase;
  letter-spacing: 0.12em;
  margin-top: 4px;
}

/* Cards inside report */
.insight-card {
  background: var(--bg2);
  border: 1px solid var(--border);
  border-left: 3px solid var(--accent);
  border-radius: 0 var(--r-lg) var(--r-lg) 0;
  padding: 20px;
  margin-bottom: 16px;
}

.insight-card-title {
  font-family: var(--mono);
  font-size: 10px;
  font-weight: 600;
  color: var(--accent);
  text-transform: uppercase;
  letter-spacing: 0.12em;
  margin-bottom: 8px;
}

.insight-card p {
  font-size: 14px;
  color: var(--text);
  line-height: 1.65;
}

/* Verdict / insight steps */
.insight-step {
  display: flex;
  gap: 16px;
  padding: 20px 0;
  border-bottom: 1px solid var(--border);
}

.insight-step:last-child { border-bottom: none; }

.insight-step-num {
  font-family: var(--mono);
  font-size: 11px;
  color: var(--accent);
  flex-shrink: 0;
  width: 24px;
  text-align: right;
  padding-top: 2px;
  font-weight: 600;
}

.insight-step-body { flex: 1; }

.insight-step-title {
  font-family: var(--sans);
  font-size: 15px;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 6px;
}

.insight-step-text {
  font-size: 13px;
  color: var(--text2);
  line-height: 1.65;
}

/* Verdict box */
.verdict-box {
  background: var(--bg2);
  border: 1px solid var(--border);
  border-left: 3px solid var(--accent);
  border-radius: 0 var(--r-lg) var(--r-lg) 0;
  padding: 24px 28px;
  font-size: 14px;
  line-height: 1.8;
  color: var(--text);
  position: relative;
}

.verdict-rating {
  font-family: var(--sans);
  font-size: 1.2rem;
  font-weight: 800;
  color: var(--accent);
  margin-bottom: 12px;
  letter-spacing: -0.01em;
}

/* Findings list */
.finding-item {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  padding: 12px 0;
  border-bottom: 1px solid var(--border);
}

.finding-item:last-child { border-bottom: none; }

.finding-num {
  font-family: var(--mono);
  font-size: 10px;
  color: var(--text3);
  flex-shrink: 0;
  width: 20px;
  text-align: right;
  padding-top: 2px;
}

.finding-body { flex: 1; }
.finding-title { font-size: 13px; font-weight: 600; color: var(--text); margin-bottom: 3px; }
.finding-text { font-size: 12px; color: var(--text2); line-height: 1.5; }

/* Check items (recommendations) */
.check-item {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  padding: 10px 0;
  font-size: 13px;
  color: var(--text);
  border-bottom: 1px solid var(--border);
}

.check-item:last-child { border-bottom: none; }

.check-mark {
  color: var(--accent);
  flex-shrink: 0;
  font-style: normal;
  font-family: var(--mono);
  font-size: 11px;
  padding-top: 2px;
}

/* Correlation direction */
.dir-pos { color: var(--green); font-family: var(--mono); font-size: 11px; }
.dir-neg { color: var(--red); font-family: var(--mono); font-size: 11px; }
.dir-neu { color: var(--text2); font-family: var(--mono); font-size: 11px; }

/* Confidence badges */
.conf-badge {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-family: var(--mono);
  font-size: 10px;
  padding: 3px 8px;
  border-radius: var(--r-sm);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.conf-high { background: rgba(34,197,94,0.1); color: var(--green); }
.conf-med { background: rgba(245,158,11,0.1); color: var(--amber); }
.conf-low { background: rgba(239,68,68,0.1); color: var(--red); }

/* Trend chip */
.trend-chip {
  display: inline-block;
  padding: 2px 8px;
  border-radius: var(--r-sm);
  font-family: var(--mono);
  font-size: 10px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.trend-grow { background: rgba(34,197,94,0.1); color: var(--green); }
.trend-decl { background: rgba(239,68,68,0.1); color: var(--red); }
.trend-flat { background: rgba(136,136,130,0.1); color: var(--text2); }
.trend-mix { background: rgba(245,158,11,0.1); color: var(--amber); }

/* Econometric model elements */
.regression-banner {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 14px;
  background: rgba(34,197,94,0.06);
  border: 1px solid rgba(34,197,94,0.2);
  border-radius: var(--r);
  font-family: var(--mono);
  font-size: 10px;
  color: var(--green);
  margin-bottom: 16px;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.gauss-status {
  padding: 10px 14px;
  border-radius: var(--r);
  font-family: var(--mono);
  font-size: 11px;
  margin-bottom: 16px;
  letter-spacing: 0.04em;
}

.gauss-ok { background: rgba(34,197,94,0.07); border: 1px solid rgba(34,197,94,0.2); color: var(--green); }
.gauss-warn { background: rgba(245,158,11,0.07); border: 1px solid rgba(245,158,11,0.2); color: var(--amber); }

.model-interp-btn {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  background: none;
  border: none;
  color: var(--text3);
  font-family: var(--mono);
  font-size: 10px;
  cursor: pointer;
  padding: 0;
  transition: color 0.15s;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.model-interp-btn:hover { color: var(--accent); }

.model-interp-text {
  font-size: 12px;
  color: var(--text2);
  line-height: 1.6;
  padding: 10px 14px;
  background: rgba(255,255,255,0.02);
  border-left: 2px solid var(--border2);
  border-radius: 0 var(--r) var(--r) 0;
  margin-top: 8px;
  display: none;
}

.model-interp-text.visible { display: block; }

/* Chart container */
.chart-wrap {
  background: var(--bg2);
  border: 1px solid var(--border);
  border-radius: var(--r-lg);
  padding: 20px;
  margin-bottom: 16px;
}

.chart-title {
  font-family: var(--mono);
  font-size: 10px;
  font-weight: 600;
  color: var(--text2);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  margin-bottom: 14px;
}

.chart-actions {
  display: flex;
  gap: 6px;
  margin-top: 10px;
  flex-wrap: wrap;
}

.chart-btn {
  padding: 5px 10px;
  background: var(--surface2);
  border: 1px solid var(--border);
  border-radius: var(--r-sm);
  cursor: pointer;
  font-family: var(--mono);
  font-size: 9px;
  color: var(--text2);
  transition: all 0.15s;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.chart-btn:hover { border-color: var(--accent); color: var(--accent); }

/* Passport table */
.passport-wrap {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 10px;
  margin-bottom: 20px;
}

.passport-item {
  background: var(--bg2);
  border: 1px solid var(--border);
  border-radius: var(--r-md);
  padding: 12px 14px;
}

.passport-key {
  font-family: var(--mono);
  font-size: 9px;
  color: var(--text3);
  text-transform: uppercase;
  letter-spacing: 0.12em;
  margin-bottom: 4px;
}

.passport-val {
  font-family: var(--sans);
  font-size: 16px;
  font-weight: 700;
  color: var(--text);
  letter-spacing: -0.01em;
}

/* ── MODALS ── */
.modal-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.8);
  z-index: 9999;
  align-items: center;
  justify-content: center;
}

.modal-overlay.flex { display: flex !important; }

#limitModal, #printGuideModal, #rowLimitModal, #congratsModal, #premiumModal {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.8);
  z-index: 9999;
  align-items: center;
  justify-content: center;
}

.limit-card, .pg-card, .modal-card {
  background: var(--surface);
  border: 1px solid var(--border2);
  border-top: 2px solid var(--accent);
  border-radius: var(--r-lg);
  padding: 36px 32px;
  max-width: 420px;
  width: 90%;
  text-align: center;
  box-shadow: 0 24px 60px rgba(0,0,0,0.7);
  animation: fadeUp 0.25s ease;
}

.limit-icon, .pg-icon { font-size: 40px; margin-bottom: 16px; }

.limit-card h3, .pg-title {
  font-family: var(--sans);
  font-size: 20px;
  font-weight: 800;
  margin-bottom: 10px;
  letter-spacing: -0.02em;
}

.limit-card p, .pg-desc {
  color: var(--text2);
  font-size: 13px;
  line-height: 1.7;
  margin-bottom: 24px;
}

.pg-progress-container {
  margin-bottom: 20px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
}

.pg-spinner {
  width: 36px;
  height: 36px;
  border: 2px solid var(--border2);
  border-top-color: var(--accent);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}

.pg-status {
  font-family: var(--mono);
  font-size: 10px;
  color: var(--accent);
  text-transform: uppercase;
  letter-spacing: 0.1em;
}

.pg-btns { display: none; }

/* Row limit modal comparison card */
.row-compare {
  display: flex;
  gap: 12px;
  justify-content: center;
  margin: 16px 0 24px;
}

.row-box {
  background: var(--bg2);
  border: 1px solid var(--border);
  border-radius: var(--r-md);
  padding: 14px 20px;
  text-align: center;
  flex: 1;
  max-width: 140px;
}

.row-box-num {
  font-family: var(--sans);
  font-size: 1.4rem;
  font-weight: 800;
  letter-spacing: -0.03em;
  margin-bottom: 4px;
}

.row-box-num.over { color: var(--red); }
.row-box-num.limit { color: var(--accent); }

.row-box-label {
  font-family: var(--mono);
  font-size: 9px;
  color: var(--text3);
  text-transform: uppercase;
  letter-spacing: 0.1em;
}

/* Congrats modal */
.congrats-icon { font-size: 48px; margin-bottom: 20px; }

/* ── PREMIUM OVERLAY (pricing) ── */
#premiumOverlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.85);
  z-index: 10000;
  align-items: center;
  justify-content: center;
  padding: 20px;
}

.premium-overlay-card {
  background: var(--surface);
  border: 1px solid var(--border2);
  border-radius: var(--r-lg);
  width: 100%;
  max-width: 640px;
  max-height: 90vh;
  overflow-y: auto;
  box-shadow: 0 24px 64px rgba(0,0,0,0.8);
  animation: fadeUp 0.3s ease;
}

.po-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px 24px 16px;
  border-bottom: 1px solid var(--border);
}

.po-title {
  font-family: var(--sans);
  font-size: 18px;
  font-weight: 800;
  letter-spacing: -0.02em;
}

.po-title span { color: var(--accent); }

.po-close {
  width: 28px;
  height: 28px;
  background: var(--surface2);
  border: 1px solid var(--border2);
  border-radius: var(--r);
  cursor: pointer;
  color: var(--text2);
  font-size: 13px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.15s;
}

.po-close:hover { background: rgba(239,68,68,0.15); color: var(--red); border-color: rgba(239,68,68,0.3); }

.po-plans {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  padding: 20px 24px;
}

@media (max-width: 500px) { .po-plans { grid-template-columns: 1fr; } }

.po-plan {
  background: var(--bg2);
  border: 1px solid var(--border);
  border-radius: var(--r-lg);
  padding: 20px;
  position: relative;
}

.po-plan.featured {
  border-color: var(--accent);
  background: rgba(255,107,53,0.04);
}

.po-plan-badge {
  position: absolute;
  top: -10px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--accent);
  color: #000;
  font-family: var(--mono);
  font-size: 9px;
  font-weight: 700;
  padding: 3px 10px;
  border-radius: 20px;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  white-space: nowrap;
}

.po-plan-name {
  font-family: var(--mono);
  font-size: 10px;
  color: var(--text3);
  text-transform: uppercase;
  letter-spacing: 0.12em;
  margin-bottom: 8px;
}

.po-plan-price {
  font-family: var(--sans);
  font-size: 2rem;
  font-weight: 800;
  color: var(--text);
  letter-spacing: -0.03em;
  margin-bottom: 4px;
}

.po-plan-price span {
  font-size: 0.9rem;
  font-weight: 400;
  color: var(--text2);
  letter-spacing: 0;
}

.po-plan-desc {
  font-size: 12px;
  color: var(--text2);
  margin-bottom: 16px;
  line-height: 1.5;
}

.po-plan-features {
  list-style: none;
  margin-bottom: 20px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.po-plan-features li {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  font-size: 12px;
  color: var(--text2);
}

.po-plan-features li::before {
  content: '—';
  color: var(--accent);
  font-family: var(--mono);
  font-size: 10px;
  flex-shrink: 0;
  margin-top: 2px;
}

.po-plan-features .crossed { text-decoration: line-through; opacity: 0.4; }

.po-paypal { width: 100%; }

/* Promo code */
.po-promo {
  padding: 16px 24px;
  border-top: 1px solid var(--border);
  display: flex;
  gap: 8px;
}

.po-promo input {
  flex: 1;
  background: var(--bg2);
  border: 1px solid var(--border2);
  border-radius: var(--r);
  padding: 9px 12px;
  color: var(--text);
  font-family: var(--mono);
  font-size: 12px;
  outline: none;
  transition: border-color 0.15s;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.po-promo input:focus { border-color: var(--accent); }

/* Premium modal (gating) */
.premium-modal-card {
  background: var(--surface);
  border: 1px solid var(--border2);
  border-top: 2px solid var(--accent);
  border-radius: var(--r-lg);
  padding: 32px;
  max-width: 480px;
  width: 90%;
  text-align: center;
  box-shadow: 0 24px 60px rgba(0,0,0,0.8);
  animation: fadeUp 0.25s ease;
}

.premium-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 14px;
  background: rgba(255,107,53,0.1);
  border: 1px solid rgba(255,107,53,0.25);
  border-radius: 20px;
  font-family: var(--mono);
  font-size: 10px;
  color: var(--accent);
  margin-bottom: 16px;
  text-transform: uppercase;
  letter-spacing: 0.1em;
}

.premium-features-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin: 20px 0 24px;
  text-align: left;
}

.premium-feature-item {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  font-size: 12px;
  color: var(--text2);
  line-height: 1.4;
}

.premium-feature-item::before {
  content: '—';
  color: var(--accent);
  font-family: var(--mono);
  font-size: 10px;
  flex-shrink: 0;
  margin-top: 1px;
}

/* ── SHARE OVERLAY ── */
#shareOverlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.85);
  z-index: 10001;
  align-items: center;
  justify-content: center;
  padding: 20px;
}

.share-card {
  background: var(--surface);
  border: 1px solid var(--border2);
  border-radius: var(--r-lg);
  width: 100%;
  max-width: 540px;
  max-height: 90vh;
  overflow-y: auto;
  box-shadow: 0 24px 64px rgba(0,0,0,0.8);
  animation: fadeUp 0.25s ease;
}

.share-card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px 22px 14px;
  border-bottom: 1px solid var(--border);
}

.share-card-title {
  font-family: var(--sans);
  font-size: 16px;
  font-weight: 800;
  letter-spacing: -0.02em;
}

/* Share tabs */
.share-tabs {
  display: flex;
  border-bottom: 1px solid var(--border);
}

.share-tab-btn {
  flex: 1;
  padding: 12px;
  background: none;
  border: none;
  border-bottom: 2px solid transparent;
  color: var(--text2);
  font-family: var(--mono);
  font-size: 10px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  cursor: pointer;
  transition: all 0.15s;
  margin-bottom: -1px;
}

.share-tab-btn:hover { color: var(--text); }
.share-tab-btn.active { color: var(--accent); border-bottom-color: var(--accent); }

.share-tab-content { display: none; padding: 20px 22px; }
.share-tab-content.active { display: block; }

/* Share preview */
.share-preview {
  background: var(--bg2);
  border: 1px solid var(--border);
  border-radius: var(--r-md);
  padding: 16px;
  margin-bottom: 16px;
}

.share-preview-logo {
  font-family: var(--sans);
  font-size: 11px;
  font-weight: 800;
  color: var(--accent);
  margin-bottom: 8px;
  letter-spacing: 0.05em;
}

.share-preview-title {
  font-family: var(--sans);
  font-size: 14px;
  font-weight: 700;
  margin-bottom: 10px;
  letter-spacing: -0.01em;
}

.share-preview-kpis {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  margin-bottom: 10px;
}

.share-kpi {
  background: var(--surface2);
  border: 1px solid var(--border);
  border-radius: var(--r-sm);
  padding: 6px 10px;
}

.share-kpi-num { font-family: var(--sans); font-size: 14px; font-weight: 800; color: var(--accent); }
.share-kpi-label { font-family: var(--mono); font-size: 9px; color: var(--text3); text-transform: uppercase; }

.share-preview-insight {
  font-size: 12px;
  color: var(--text2);
  line-height: 1.5;
  border-left: 2px solid var(--accent);
  padding-left: 10px;
  margin-bottom: 10px;
}

.share-preview-footer {
  font-family: var(--mono);
  font-size: 9px;
  color: var(--text3);
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

/* Access type toggle */
.access-toggle {
  display: flex;
  gap: 4px;
  background: var(--bg2);
  border: 1px solid var(--border);
  border-radius: var(--r);
  padding: 3px;
  margin-bottom: 12px;
}

.access-btn {
  flex: 1;
  padding: 7px;
  background: none;
  border: none;
  border-radius: var(--r-sm);
  cursor: pointer;
  font-family: var(--mono);
  font-size: 10px;
  color: var(--text2);
  transition: all 0.15s;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.access-btn.active { background: var(--surface3); color: var(--text); }

/* Share link box */
.share-link-box {
  display: flex;
  gap: 8px;
  margin: 12px 0;
}

.share-link-input {
  flex: 1;
  background: var(--bg2);
  border: 1px solid var(--border2);
  border-radius: var(--r);
  padding: 9px 12px;
  color: var(--accent);
  font-family: var(--mono);
  font-size: 11px;
  outline: none;
  letter-spacing: 0.03em;
}

.share-social-row {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
  margin-top: 12px;
}

.social-btn {
  flex: 1;
  min-width: 80px;
  padding: 8px 10px;
  border: 1px solid var(--border2);
  border-radius: var(--r);
  cursor: pointer;
  font-family: var(--mono);
  font-size: 10px;
  color: var(--text2);
  background: var(--surface2);
  transition: all 0.15s;
  text-align: center;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.social-btn:hover { border-color: var(--accent); color: var(--accent); }

/* History items */
.history-item {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  padding: 14px 0;
  border-bottom: 1px solid var(--border);
  cursor: pointer;
}

.history-item:last-child { border-bottom: none; }
.history-item:hover { color: var(--accent); }

.history-item-info { flex: 1; min-width: 0; }

.history-item-title {
  font-size: 13px;
  font-weight: 600;
  color: var(--text);
  margin-bottom: 4px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.history-item-meta {
  font-family: var(--mono);
  font-size: 10px;
  color: var(--text3);
  letter-spacing: 0.05em;
}

.history-item-actions {
  display: flex;
  gap: 4px;
  flex-shrink: 0;
}

/* ── HISTORY DRAWER (Premium) ── */
#historyDrawerBtn {
  position: fixed;
  bottom: 24px;
  right: 24px;
  z-index: 900;
  display: flex;
  align-items: center;
  gap: 8px;
  background: var(--accent);
  color: #000;
  border: none;
  border-radius: var(--r);
  padding: 10px 16px;
  cursor: pointer;
  font-family: var(--sans);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.02em;
  box-shadow: 0 8px 24px rgba(255,107,53,0.3), 0 2px 8px rgba(0,0,0,0.3);
  transition: transform 0.2s, box-shadow 0.2s, opacity 0.2s;
  animation: fadeUp 0.5s 0.4s ease both;
}

#historyDrawerBtn:hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 32px rgba(255,107,53,0.4), 0 4px 12px rgba(0,0,0,0.35);
}

.hdb-badge {
  background: var(--red);
  color: #fff;
  font-size: 9px;
  font-weight: 800;
  border-radius: 10px;
  padding: 1px 6px;
  margin-left: 2px;
  line-height: 1.5;
}

.history-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.6);
  z-index: 1000;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s;
}

.history-backdrop.open { opacity: 1; pointer-events: all; }

.history-drawer {
  position: fixed;
  top: 0; right: 0; bottom: 0;
  width: 360px;
  max-width: 95vw;
  z-index: 1001;
  transform: translateX(100%);
  transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  display: flex;
  flex-direction: column;
}

.history-drawer.open { transform: translateX(0); }

.history-drawer-inner {
  display: flex;
  flex-direction: column;
  height: 100%;
  background: var(--bg2);
  border-left: 1px solid var(--border2);
  box-shadow: -20px 0 60px rgba(0,0,0,0.5);
  overflow: hidden;
}

.history-drawer-inner::before {
  content: '';
  height: 2px;
  background: var(--accent);
  flex-shrink: 0;
}

.history-drawer-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 18px 20px 14px;
  border-bottom: 1px solid var(--border);
  flex-shrink: 0;
  gap: 12px;
}

.history-drawer-title {
  font-family: var(--sans);
  font-size: 16px;
  font-weight: 800;
  letter-spacing: -0.02em;
}

.history-drawer-title span { color: var(--accent); }

.hd-action-btn {
  width: 28px;
  height: 28px;
  border-radius: var(--r);
  border: 1px solid var(--border2);
  background: var(--surface2);
  color: var(--text2);
  cursor: pointer;
  font-size: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.15s, color 0.15s;
  flex-shrink: 0;
}

.hd-action-btn:hover { background: var(--surface3); color: var(--text); }
.hd-close-btn:hover { background: rgba(239,68,68,0.15); color: var(--red); border-color: rgba(239,68,68,0.3); }

.history-drawer-list { flex: 1; overflow-y: auto; }
.history-drawer-list::-webkit-scrollbar { width: 3px; }
.history-drawer-list::-webkit-scrollbar-thumb { background: var(--border2); border-radius: 2px; }

.history-drawer-empty {
  text-align: center;
  padding: 60px 20px;
  color: var(--text3);
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.06em;
}

.history-drawer-list .history-item {
  padding: 12px 20px !important;
  border-bottom: 1px solid var(--border) !important;
  transition: background 0.15s;
}

.history-drawer-list .history-item:hover { background: rgba(0,0,0,0.015); }
.history-drawer-list .history-item:last-child { border-bottom: none !important; }

#historyDrawerBtn.drawer-open { opacity: 0; pointer-events: none; transform: translateY(6px); }

@media (max-width: 480px) {
  .history-drawer { width: 100vw; }
  #historyDrawerBtn { bottom: 16px; right: 16px; padding: 8px 14px; font-size: 11px; }
}

/* ── LANDING PAGE ── */
.landing-header {
  position: sticky;
  top: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 48px;
  height: 60px;
  background: var(--bg);
  border-bottom: 1px solid var(--border);
}

@media (max-width: 768px) {
  .landing-header { padding: 0 20px; }
}

.landing-header-right {
  display: flex;
  align-items: center;
  gap: 12px;
}

/* Landing hero */
.landing-hero {
  padding: 80px 48px 64px;
  max-width: 1200px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 48px;
  align-items: center;
}

@media (max-width: 900px) {
  .landing-hero {
    grid-template-columns: 1fr;
    padding: 56px 24px 48px;
    gap: 40px;
  }
}

.landing-hero-left {}

.landing-hero-eyebrow {
  font-family: var(--mono);
  font-size: 10px;
  font-weight: 600;
  color: var(--accent);
  text-transform: uppercase;
  letter-spacing: 0.15em;
  margin-bottom: 20px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.landing-hero-eyebrow::before {
  content: '';
  width: 24px;
  height: 1px;
  background: var(--accent);
}

.landing-hero h1 {
  font-family: var(--sans);
  font-size: clamp(2.6rem, 5vw, 4.2rem);
  font-weight: 800;
  line-height: 0.98;
  letter-spacing: -0.04em;
  margin-bottom: 24px;
  color: var(--text);
}

.landing-hero h1 em {
  font-style: normal;
  color: var(--accent);
}

.landing-hero-desc {
  font-size: 15px;
  color: var(--text2);
  line-height: 1.7;
  max-width: 420px;
  margin-bottom: 32px;
}

.landing-hero-actions {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}

/* Hero stats panel */
.landing-hero-right {
  display: flex;
  flex-direction: column;
  gap: 1px;
  border: 1px solid var(--border2);
  border-radius: var(--r-lg);
  overflow: hidden;
  background: var(--border);
}

.landing-stat-block {
  background: var(--surface);
  padding: 24px 28px;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.landing-stat-block:first-child { border-radius: var(--r-lg) var(--r-lg) 0 0; }
.landing-stat-block:last-child { border-radius: 0 0 var(--r-lg) var(--r-lg); }

.landing-stat-num {
  font-family: var(--sans);
  font-size: 2.6rem;
  font-weight: 800;
  color: var(--accent);
  line-height: 1;
  letter-spacing: -0.04em;
  font-variant-numeric: tabular-nums;
}

.landing-stat-label {
  font-family: var(--mono);
  font-size: 10px;
  color: var(--text2);
  text-transform: uppercase;
  letter-spacing: 0.12em;
}

.landing-stat-desc {
  font-size: 12px;
  color: var(--text3);
  line-height: 1.4;
  margin-top: 2px;
}

/* Features section */
.landing-features {
  padding: 64px 48px;
  max-width: 1200px;
  margin: 0 auto;
  border-top: 1px solid var(--border);
}

@media (max-width: 768px) {
  .landing-features { padding: 48px 24px; }
}

.landing-features-header {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  margin-bottom: 40px;
  gap: 20px;
}

.landing-features-header h2 {
  font-family: var(--sans);
  font-size: clamp(1.8rem, 3vw, 2.8rem);
  font-weight: 800;
  letter-spacing: -0.03em;
}

.landing-features-header h2 em {
  font-style: normal;
  color: var(--accent);
}

.landing-features-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1px;
  background: var(--border);
  border: 1px solid var(--border2);
  border-radius: var(--r-lg);
  overflow: hidden;
}

@media (max-width: 768px) {
  .landing-features-grid { grid-template-columns: 1fr; }
}

.landing-feature-card {
  background: var(--surface);
  padding: 28px;
}

.landing-feature-num {
  font-family: var(--mono);
  font-size: 10px;
  color: var(--text3);
  letter-spacing: 0.1em;
  margin-bottom: 16px;
}

.landing-feature-icon {
  font-size: 28px;
  margin-bottom: 14px;
  display: block;
}

.landing-feature-title {
  font-family: var(--sans);
  font-size: 17px;
  font-weight: 800;
  margin-bottom: 8px;
  letter-spacing: -0.02em;
}

.landing-feature-desc {
  font-size: 13px;
  color: var(--text2);
  line-height: 1.65;
}

/* Steps section */
.landing-steps {
  padding: 64px 48px;
  max-width: 1200px;
  margin: 0 auto;
  border-top: 1px solid var(--border);
}

@media (max-width: 768px) {
  .landing-steps { padding: 48px 24px; }
}

.landing-steps-header {
  margin-bottom: 48px;
}

.landing-steps-header h2 {
  font-family: var(--sans);
  font-size: clamp(1.8rem, 3vw, 2.8rem);
  font-weight: 800;
  letter-spacing: -0.03em;
}

.landing-steps-header h2 em {
  font-style: normal;
  color: var(--accent);
}

.landing-steps-list {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 32px;
}

@media (max-width: 768px) {
  .landing-steps-list { grid-template-columns: 1fr; gap: 0; }
}

.landing-step {
  position: relative;
  padding-top: 4px;
}

@media (max-width: 768px) {
  .landing-step {
    padding: 20px 0;
    border-bottom: 1px solid var(--border);
    display: flex;
    gap: 20px;
    align-items: flex-start;
  }
  .landing-step:last-child { border-bottom: none; }
}

.landing-step-num {
  font-family: var(--sans);
  font-size: 5rem;
  font-weight: 800;
  color: var(--border2);
  line-height: 1;
  letter-spacing: -0.05em;
  margin-bottom: 16px;
  font-variant-numeric: tabular-nums;
}

@media (max-width: 768px) {
  .landing-step-num { font-size: 3rem; flex-shrink: 0; margin-bottom: 0; }
}

.landing-step-title {
  font-family: var(--sans);
  font-size: 17px;
  font-weight: 800;
  margin-bottom: 8px;
  letter-spacing: -0.02em;
}

.landing-step-desc {
  font-size: 13px;
  color: var(--text2);
  line-height: 1.65;
}

/* Landing footer */
.landing-footer {
  border-top: 1px solid var(--border);
  padding: 28px 48px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

@media (max-width: 768px) {
  .landing-footer { padding: 20px 24px; flex-direction: column; text-align: center; gap: 8px; }
}

.landing-footer-copy {
  font-family: var(--mono);
  font-size: 10px;
  color: var(--text3);
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

/* ── LOGIN PAGE ── */
.auth-layout {
  min-height: 100vh;
  display: grid;
  grid-template-columns: 1fr 1fr;
}

@media (max-width: 768px) {
  .auth-layout { grid-template-columns: 1fr; }
}

.auth-brand {
  background: var(--bg2);
  border-right: 1px solid var(--border);
  padding: 48px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  position: relative;
  overflow: hidden;
}

.auth-brand::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: var(--accent);
}

@media (max-width: 768px) {
  .auth-brand { padding: 32px 24px 28px; border-right: none; border-bottom: 1px solid var(--border); }
}

.auth-brand-logo {
  font-family: var(--sans);
  font-size: 18px;
  font-weight: 800;
  letter-spacing: -0.02em;
}

.auth-brand-logo span { color: var(--accent); }

.auth-brand-main { flex: 1; display: flex; flex-direction: column; justify-content: center; padding: 48px 0 0; }

@media (max-width: 768px) {
  .auth-brand-main { padding: 24px 0 0; }
}

.auth-brand-tagline {
  font-family: var(--sans);
  font-size: clamp(2rem, 3.5vw, 3rem);
  font-weight: 800;
  line-height: 1.0;
  letter-spacing: -0.04em;
  margin-bottom: 20px;
  color: var(--text);
}

.auth-brand-tagline em { font-style: normal; color: var(--accent); }

@media (max-width: 768px) {
  .auth-brand-tagline { font-size: 1.8rem; }
}

.auth-brand-desc {
  font-size: 13px;
  color: var(--text2);
  line-height: 1.65;
  max-width: 320px;
  margin-bottom: 32px;
}

.auth-brand-features {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.auth-brand-features li {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-size: 13px;
  color: var(--text2);
}

.auth-brand-features li::before {
  content: '—';
  color: var(--accent);
  font-family: var(--mono);
  font-size: 11px;
  flex-shrink: 0;
  margin-top: 2px;
}

.auth-form-panel {
  background: var(--bg);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 48px 32px;
}

.auth-form-wrap {
  width: 100%;
  max-width: 380px;
}

.auth-form-title {
  font-family: var(--sans);
  font-size: 22px;
  font-weight: 800;
  letter-spacing: -0.03em;
  margin-bottom: 6px;
}

.auth-form-sub {
  font-size: 13px;
  color: var(--text2);
  margin-bottom: 28px;
}

.auth-tabs {
  display: flex;
  background: var(--surface);
  border: 1px solid var(--border2);
  border-radius: var(--r-md);
  padding: 3px;
  gap: 3px;
  margin-bottom: 24px;
}

.auth-tab-btn {
  flex: 1;
  padding: 9px;
  background: none;
  border: none;
  border-radius: var(--r-sm);
  cursor: pointer;
  font-family: var(--mono);
  font-size: 11px;
  color: var(--text2);
  transition: all 0.15s;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.auth-tab-btn.active { background: var(--surface3); color: var(--text); }

.auth-google-btn {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 11px;
  background: var(--surface);
  border: 1px solid var(--border2);
  border-radius: var(--r);
  cursor: pointer;
  font-family: var(--body);
  font-size: 14px;
  font-weight: 500;
  color: var(--text);
  transition: all 0.15s;
  margin-bottom: 20px;
}

.auth-google-btn:hover { border-color: var(--border3); background: var(--surface2); }

.auth-divider {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 20px;
}

.auth-divider-line {
  flex: 1;
  height: 1px;
  background: var(--border);
}

.auth-divider-text {
  font-family: var(--mono);
  font-size: 10px;
  color: var(--text3);
  text-transform: uppercase;
  letter-spacing: 0.1em;
}

.auth-field { margin-bottom: 14px; }

.auth-field label {
  display: block;
  font-family: var(--mono);
  font-size: 10px;
  font-weight: 600;
  color: var(--text2);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  margin-bottom: 7px;
}

.auth-field input {
  width: 100%;
  background: var(--bg2);
  border: 1px solid var(--border2);
  border-radius: var(--r);
  padding: 11px 14px;
  color: var(--text);
  font-family: var(--body);
  font-size: 14px;
  outline: none;
  transition: border-color 0.15s, box-shadow 0.15s;
}

.auth-field input:focus { border-color: var(--accent); box-shadow: 0 0 0 3px rgba(255,107,53,0.1); }

.auth-field-pw { position: relative; }

.auth-field-pw input { padding-right: 40px; }

.pw-toggle {
  position: absolute;
  right: 12px;
  top: 50%;
  transform: translateY(-50%);
  background: none;
  border: none;
  cursor: pointer;
  color: var(--text3);
  font-size: 14px;
  padding: 2px;
  transition: color 0.15s;
}

.pw-toggle:hover { color: var(--text2); }

.auth-extras {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 20px;
  gap: 8px;
}

.auth-checkbox {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 12px;
  color: var(--text2);
  cursor: pointer;
}

.auth-checkbox input { accent-color: var(--accent); }

.auth-forgot {
  font-family: var(--mono);
  font-size: 10px;
  color: var(--text2);
  text-decoration: none;
  transition: color 0.15s;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.auth-forgot:hover { color: var(--accent); }

.auth-submit-btn {
  width: 100%;
  padding: 13px;
  background: var(--accent);
  color: #000;
  border: none;
  border-radius: var(--r);
  cursor: pointer;
  font-family: var(--sans);
  font-size: 15px;
  font-weight: 700;
  transition: background 0.15s, transform 0.15s;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

.auth-submit-btn:hover { background: var(--accent-light); transform: translateY(-1px); }
.auth-submit-btn:disabled { background: var(--surface3); color: var(--text3); cursor: not-allowed; transform: none; }

.auth-terms {
  margin-top: 20px;
  font-size: 11px;
  color: var(--text3);
  text-align: center;
  line-height: 1.6;
}

.auth-terms a { color: var(--text2); text-decoration: none; }
.auth-terms a:hover { color: var(--accent); }

/* Auth spinner */
.auth-spinner {
  width: 16px;
  height: 16px;
  border: 2px solid rgba(0,0,0,0.2);
  border-top-color: #000;
  border-radius: 50%;
  animation: spin 0.7s linear infinite;
  display: none;
}

.auth-spinner.active { display: block; }

/* ── ABOUT PAGE ── */
.about-header {
  position: sticky;
  top: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 48px;
  height: 60px;
  background: var(--bg);
  border-bottom: 1px solid var(--border);
}

@media (max-width: 768px) {
  .about-header { padding: 0 20px; }
}

.about-content { max-width: 900px; margin: 0 auto; padding: 0 48px; }

@media (max-width: 768px) {
  .about-content { padding: 0 24px; }
}

.about-hero {
  padding: 72px 0 56px;
  border-bottom: 1px solid var(--border);
}

.about-hero h1 {
  font-family: var(--sans);
  font-size: clamp(2.4rem, 5vw, 4rem);
  font-weight: 800;
  line-height: 0.98;
  letter-spacing: -0.04em;
  margin-top: 16px;
}

.about-hero h1 em { font-style: normal; color: var(--accent); }

.about-section {
  padding: 56px 0;
  border-bottom: 1px solid var(--border);
}

.about-section:last-of-type { border-bottom: none; }

.about-section-num {
  font-family: var(--mono);
  font-size: 10px;
  color: var(--text3);
  letter-spacing: 0.15em;
  text-transform: uppercase;
  margin-bottom: 24px;
}

.about-section h2 {
  font-family: var(--sans);
  font-size: clamp(1.4rem, 2.5vw, 2rem);
  font-weight: 800;
  letter-spacing: -0.03em;
  margin-bottom: 16px;
}

.about-section p {
  font-size: 15px;
  color: var(--text2);
  line-height: 1.8;
  margin-bottom: 16px;
  max-width: 680px;
}

.about-pullquote {
  font-family: var(--sans);
  font-size: clamp(1.2rem, 2.5vw, 1.6rem);
  font-weight: 700;
  line-height: 1.3;
  letter-spacing: -0.02em;
  color: var(--text);
  border-left: 3px solid var(--accent);
  padding: 16px 24px;
  margin: 32px 0;
}

.about-dna-list {
  display: flex;
  flex-direction: column;
  gap: 0;
}

.about-dna-item {
  display: flex;
  gap: 24px;
  padding: 20px 0;
  border-bottom: 1px solid var(--border);
  align-items: flex-start;
}

.about-dna-item:last-child { border-bottom: none; }

.about-dna-num {
  font-family: var(--sans);
  font-size: 2.5rem;
  font-weight: 800;
  color: var(--border2);
  line-height: 1;
  letter-spacing: -0.05em;
  flex-shrink: 0;
  width: 56px;
  font-variant-numeric: tabular-nums;
}

.about-dna-body {}
.about-dna-title { font-family: var(--sans); font-size: 16px; font-weight: 800; margin-bottom: 4px; letter-spacing: -0.02em; }
.about-dna-text { font-size: 13px; color: var(--text2); line-height: 1.65; }

.about-trust-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin-top: 24px;
}

@media (max-width: 600px) {
  .about-trust-grid { grid-template-columns: 1fr; }
}

.about-trust-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-left: 3px solid var(--accent);
  border-radius: 0 var(--r-lg) var(--r-lg) 0;
  padding: 20px;
}

.about-trust-title {
  font-family: var(--sans);
  font-size: 15px;
  font-weight: 800;
  margin-bottom: 8px;
  letter-spacing: -0.02em;
}

.about-trust-text {
  font-size: 13px;
  color: var(--text2);
  line-height: 1.65;
}

/* About footer */
.about-footer {
  border-top: 1px solid var(--border);
  padding: 28px 48px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

@media (max-width: 768px) {
  .about-footer { padding: 20px 24px; flex-direction: column; text-align: center; }
}

/* ── SHARED REPORT VIEWER ── */
.viewer-header {
  position: sticky;
  top: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 32px;
  height: 56px;
  background: var(--bg);
  border-bottom: 1px solid var(--border);
}

.viewer-header-left {
  display: flex;
  align-items: center;
  gap: 16px;
}

.viewer-report-title {
  font-family: var(--mono);
  font-size: 11px;
  color: var(--text2);
  letter-spacing: 0.06em;
  text-transform: uppercase;
  padding-left: 16px;
  border-left: 1px solid var(--border2);
}

.viewer-banner {
  background: var(--surface);
  border-bottom: 1px solid var(--border);
  padding: 10px 32px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

@media (max-width: 600px) {
  .viewer-banner { padding: 8px 16px; flex-direction: column; text-align: center; gap: 8px; }
  .viewer-header { padding: 0 16px; }
}

.viewer-banner-text {
  font-family: var(--mono);
  font-size: 11px;
  color: var(--text2);
  letter-spacing: 0.06em;
}

.viewer-banner-cta {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 14px;
  background: var(--accent);
  color: #000;
  border: none;
  border-radius: var(--r);
  cursor: pointer;
  font-family: var(--mono);
  font-size: 10px;
  font-weight: 700;
  text-decoration: none;
  transition: background 0.15s;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  white-space: nowrap;
}

.viewer-banner-cta:hover { background: var(--accent-light); }

.viewer-main {
  max-width: 1100px;
  margin: 0 auto;
  padding: 32px 24px 80px;
}

/* Viewer password gate */
.viewer-pw-gate {
  min-height: 60vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 40px 20px;
}

.viewer-pw-card {
  background: var(--surface);
  border: 1px solid var(--border2);
  border-top: 2px solid var(--accent);
  border-radius: var(--r-lg);
  padding: 40px 36px;
  max-width: 380px;
  width: 100%;
  text-align: center;
}

.viewer-pw-icon { font-size: 36px; margin-bottom: 16px; }

.viewer-pw-title {
  font-family: var(--sans);
  font-size: 20px;
  font-weight: 800;
  letter-spacing: -0.02em;
  margin-bottom: 8px;
}

.viewer-pw-desc {
  font-size: 13px;
  color: var(--text2);
  margin-bottom: 24px;
  line-height: 1.6;
}

.viewer-pw-input {
  width: 100%;
  background: var(--bg2);
  border: 1px solid var(--border2);
  border-radius: var(--r);
  padding: 11px 14px;
  color: var(--text);
  font-family: var(--body);
  font-size: 14px;
  outline: none;
  margin-bottom: 12px;
  text-align: center;
  transition: border-color 0.15s;
}

.viewer-pw-input:focus { border-color: var(--accent); }

.viewer-pw-error {
  font-family: var(--mono);
  font-size: 10px;
  color: var(--red);
  display: none;
  margin-bottom: 10px;
  letter-spacing: 0.06em;
}

/* Viewer footer */
.viewer-footer {
  border-top: 1px solid var(--border);
  padding: 20px 32px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

@media (max-width: 600px) {
  .viewer-footer { padding: 16px; flex-direction: column; text-align: center; gap: 8px; }
}

.viewer-footer-brand {
  font-family: var(--mono);
  font-size: 10px;
  color: var(--text3);
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

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

@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

@keyframes slideIn {
  from { opacity: 0; transform: translateX(20px); }
  to { opacity: 1; transform: translateX(0); }
}

.scroll-reveal {
  opacity: 1;
  transform: none;
  transition: opacity 0.5s ease, transform 0.5s ease;
}

.scroll-reveal.revealed,
.scroll-reveal.visible {
  opacity: 1;
  transform: none;
}

/* ── MISC UTILITIES ── */
.text-accent { color: var(--accent); }
.text-muted { color: var(--text2); }
.text-mono { font-family: var(--mono); }
.text-sans { font-family: var(--sans); }
.font-800 { font-weight: 800; }

.divider {
  height: 1px;
  background: var(--border);
  margin: 24px 0;
}

.badge {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 3px 8px;
  border-radius: var(--r-sm);
  font-family: var(--mono);
  font-size: 9px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.badge-accent { background: rgba(255,107,53,0.1); color: var(--accent); border: 1px solid rgba(255,107,53,0.2); }
.badge-green { background: rgba(34,197,94,0.1); color: var(--green); border: 1px solid rgba(34,197,94,0.2); }
.badge-gold { background: rgba(255,184,0,0.1); color: var(--gold); border: 1px solid rgba(255,184,0,0.2); }

/* Error/success messages */
.alert {
  padding: 10px 14px;
  border-radius: var(--r);
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.04em;
  margin-bottom: 12px;
}

.alert-error { background: rgba(239,68,68,0.08); border: 1px solid rgba(239,68,68,0.2); color: var(--red); }
.alert-success { background: rgba(34,197,94,0.06); border: 1px solid rgba(34,197,94,0.2); color: var(--green); }
.alert-warn { background: rgba(255,184,0,0.06); border: 1px solid rgba(255,184,0,0.2); color: var(--gold); }

/* Loading dots for async buttons */
.loading-dots::after {
  content: '';
  animation: dots 1.2s steps(3, end) infinite;
}

@keyframes dots {
  0%, 20% { content: '.'; }
  40%, 60% { content: '..'; }
  80%, 100% { content: '...'; }
}

/* Light-mode hard overrides for inline-heavy surfaces */
#limitModal,
#congratsModal,
#rowLimitModal,
#premiumOverlay,
#premiumModal,
#pdfGuideOverlay,
#shareOverlay {
  background: rgba(245,239,230,0.72) !important;
  backdrop-filter: blur(14px);
}

.limit-card,
.premium-card,
.premium-overlay-card,
.premium-modal-card,
.share-card,
.modal,
.modal-card,
.pg-card {
  background: var(--surface2) !important;
  border-color: var(--border2) !important;
  box-shadow: 0 24px 72px rgba(99,69,39,0.14) !important;
}

#limitTitle,
#congratsTitle,
#pdfGuideTitle,
#premiumTitle,
#premiumModalTitle,
.premium-card h2,
.premium-plan-item h4,
.premium-feat-item strong {
  color: var(--text) !important;
}

#limitDesc,
#congratsDesc,
.premium-card p,
.premium-feat-item p,
.viewer-pw-card p {
  color: var(--text2) !important;
}

/* Report experience refresh */
.tab-btn {
  position: relative;
  border-radius: 10px 10px 0 0;
  transition: color 0.18s ease, background 0.18s ease, transform 0.18s ease;
}

.tab-btn:hover {
  background: rgba(255,255,255,0.58);
  transform: translateY(-1px);
}

.tab-btn.active {
  background: rgba(255,107,53,0.10);
  box-shadow: inset 0 -2px 0 var(--accent);
}

#report-section .card,
.chart-wrap-v2,
.econ-spec-card,
.strategic-verdict-card,
.exec-brief,
.accordion-item,
.priority-rec,
.risk-alert,
.benchmark-card,
.completeness-row {
  transition: transform 0.18s ease, box-shadow 0.18s ease, border-color 0.18s ease, background 0.18s ease;
}

#report-section .card:hover,
.chart-wrap-v2:hover,
.econ-spec-card:hover,
.strategic-verdict-card:hover,
.exec-brief:hover,
.accordion-item:hover,
.priority-rec:hover,
.benchmark-card:hover,
.completeness-row:hover {
  transform: translateY(-2px);
  box-shadow: 0 18px 34px rgba(99,69,39,0.10);
  border-color: rgba(255,107,53,0.20);
}

.report-table-wrapper {
  overflow-x: auto;
  border: 1px solid var(--border);
  border-radius: 14px;
  background: rgba(255,255,255,0.62);
}

.report-table tbody tr:hover {
  background: rgba(255,107,53,0.04);
}

.gauge-track {
  fill: none;
  stroke: rgba(108,76,48,0.12);
  stroke-width: 10;
  stroke-linecap: round;
}

.gauge-fill {
  fill: none;
  stroke-width: 10;
  stroke-linecap: round;
  transition: stroke-dashoffset 0.55s ease, stroke 0.3s ease;
}

.gauge-num {
  fill: var(--text);
  font-family: var(--sans);
  font-size: 24px;
  font-weight: 900;
  letter-spacing: -0.03em;
}

.quality-hero-card {
  display: grid;
  grid-template-columns: 120px minmax(0, 1fr);
  gap: 24px;
  padding: 22px;
  margin-bottom: 20px;
  background: linear-gradient(135deg, rgba(255,255,255,0.82), rgba(255,248,241,0.88));
  border: 1px solid var(--border);
  border-radius: 18px;
}

.quality-hero-body {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 8px;
}

.quality-hero-kicker {
  font-family: var(--mono);
  font-size: 10px;
  color: var(--accent);
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.quality-hero-title {
  font-family: var(--sans);
  font-size: 28px;
  font-weight: 900;
  color: var(--text);
  letter-spacing: -0.03em;
}

.quality-hero-summary {
  font-size: 14px;
  color: var(--text2);
  line-height: 1.7;
}

.completeness-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.completeness-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px 12px;
  align-items: center;
  padding: 14px 16px;
  border: 1px solid var(--border);
  border-radius: 14px;
  background: rgba(255,255,255,0.66);
}

.completeness-name {
  font-size: 13px;
  font-weight: 700;
  color: var(--text);
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.completeness-pct {
  font-family: var(--mono);
  font-size: 11px;
  color: var(--accent-dark);
}

.completeness-bar-wrap {
  grid-column: 1 / -1;
  height: 8px;
  background: rgba(108,76,48,0.08);
  border-radius: 999px;
  overflow: hidden;
}

.completeness-bar {
  width: 0;
  height: 100%;
  border-radius: inherit;
  transition: width 0.6s ease;
}

.benchmark-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.benchmark-card {
  padding: 16px 18px;
  border: 1px solid var(--border);
  border-radius: 16px;
  background: rgba(255,255,255,0.66);
}

.benchmark-metric {
  font-family: var(--mono);
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--text3);
  margin-bottom: 10px;
}

.benchmark-your {
  font-family: var(--sans);
  font-size: 24px;
  font-weight: 900;
  letter-spacing: -0.03em;
  margin-bottom: 6px;
}

.benchmark-industry {
  font-size: 12px;
  color: var(--text2);
}

.insight-chain {
  display: grid;
  gap: 12px;
}

.insight-step {
  align-items: flex-start;
  gap: 14px;
  padding: 16px 18px;
  border: 1px solid var(--border);
  border-radius: 16px;
  background: rgba(255,255,255,0.60);
  cursor: pointer;
  border-bottom: 1px solid var(--border);
}

.insight-step:last-child {
  border-bottom: 1px solid var(--border);
}

.insight-step:focus-visible {
  outline: 2px solid rgba(255,107,53,0.35);
  outline-offset: 2px;
}

.insight-step-icon {
  width: 40px;
  height: 40px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 12px;
  background: rgba(255,107,53,0.10);
  border: 1px solid rgba(255,107,53,0.18);
  flex-shrink: 0;
  font-size: 16px;
}

.insight-step-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 4px;
}

.insight-step-label {
  font-family: var(--sans);
  font-size: 15px;
  font-weight: 800;
  color: var(--text);
}

.insight-step-toggle {
  font-family: var(--mono);
  font-size: 10px;
  color: var(--accent-dark);
  text-transform: uppercase;
  letter-spacing: 0.10em;
}

.insight-step-text {
  max-height: 0;
  opacity: 0;
  overflow: hidden;
  transition: max-height 0.28s ease, opacity 0.18s ease;
}

.insight-step.is-open .insight-step-text {
  max-height: 220px;
  opacity: 1;
  margin-top: 6px;
}

.insight-step.is-open .insight-step-toggle::after {
  content: " -";
}

.verdict-box,
.exec-brief {
  background: linear-gradient(135deg, rgba(255,255,255,0.76), rgba(255,248,241,0.88));
  border: 1px solid var(--border);
  border-left: 4px solid var(--accent);
  border-radius: 16px;
  padding: 22px 24px;
}

.verdict-label,
.exec-brief-label {
  font-family: var(--mono);
  font-size: 10px;
  color: var(--accent);
  text-transform: uppercase;
  letter-spacing: 0.12em;
  margin-bottom: 10px;
}

.verdict-text,
.exec-brief-text {
  font-size: 15px;
  line-height: 1.8;
  color: var(--text);
}

.chart-wrap-v2 {
  padding: 18px;
  border: 1px solid var(--border);
  border-radius: 18px;
  background: rgba(255,255,255,0.70);
  margin-bottom: 16px;
}

.chart-header-v2 {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
  margin-bottom: 14px;
}

.chart-title-v2 {
  font-family: var(--sans);
  font-size: 20px;
  font-weight: 900;
  color: var(--text);
  letter-spacing: -0.02em;
}

.chart-meta-row {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.chart-type-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 10px;
  border-radius: 999px;
  background: rgba(255,107,53,0.10);
  color: var(--accent-dark);
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.chart-why-toggle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  appearance: none;
  -webkit-appearance: none;
  padding: 6px 10px;
  border: 1px solid var(--border2);
  border-radius: 999px;
  background: rgba(255,255,255,0.80);
  color: var(--text2);
  font-family: var(--mono);
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  cursor: pointer;
}

.chart-why-toggle:hover {
  color: var(--accent-dark);
  border-color: rgba(255,107,53,0.28);
  background: rgba(255,248,241,0.98);
}

.chart-why-body {
  max-height: 0;
  overflow: hidden;
  opacity: 0;
  margin-bottom: 0;
  padding: 0 14px;
  border-left: 3px solid rgba(255,107,53,0.24);
  background: rgba(255,107,53,0.05);
  border-radius: 0 12px 12px 0;
  transition: max-height 0.28s ease, opacity 0.18s ease, margin-bottom 0.18s ease, padding 0.18s ease;
}

.chart-why-body.open {
  max-height: 180px;
  opacity: 1;
  margin-bottom: 14px;
  padding: 12px 14px;
}

.chart-canvas-area {
  min-height: 340px;
  padding: 10px 8px 0;
  border-radius: 14px;
  background: linear-gradient(180deg, rgba(255,255,255,0.78), rgba(248,241,232,0.72));
  border: 1px solid rgba(108,76,48,0.08);
}

.model-grid-dynamic {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
  align-items: start;
}

.econ-spec-card,
.strategic-verdict-card {
  padding: 18px 20px;
  border: 1px solid var(--border);
  border-radius: 18px;
  background: rgba(255,255,255,0.68);
}

.accordion-item {
  border: 1px solid var(--border);
  border-radius: 16px;
  background: rgba(255,255,255,0.68);
  margin-bottom: 12px;
  overflow: hidden;
}

.accordion-header {
  display: grid;
  grid-template-columns: auto 1fr auto auto;
  align-items: center;
  gap: 12px;
  padding: 16px 18px;
  cursor: pointer;
}

.accordion-header:focus-visible {
  outline: 2px solid rgba(255,107,53,0.28);
  outline-offset: -2px;
}

.accordion-num {
  font-family: var(--mono);
  font-size: 12px;
  color: var(--accent-dark);
}

.accordion-title {
  font-size: 15px;
  font-weight: 700;
  color: var(--text);
}

.accordion-arrow {
  color: var(--text2);
  transition: transform 0.2s ease;
}

.accordion-body {
  max-height: 0;
  overflow: hidden;
  padding: 0 18px;
  opacity: 0;
  transition: max-height 0.28s ease, opacity 0.18s ease, padding 0.18s ease;
}

.accordion-item.open .accordion-body {
  max-height: 240px;
  opacity: 1;
  padding: 0 18px 18px;
}

.accordion-item.open .accordion-arrow {
  transform: rotate(180deg);
}

.priority-cards {
  display: grid;
  gap: 12px;
}

.priority-rec {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 14px;
  padding: 16px 18px;
  border: 1px solid var(--border);
  border-left: 4px solid var(--prec-color, var(--accent));
  border-radius: 16px;
  background: rgba(255,255,255,0.74);
}

.findings-stack,
.next-steps-list {
  display: grid;
  gap: 14px;
}

.next-steps-list > div {
  padding: 14px 16px !important;
  border: 1px solid var(--border);
  border-radius: 14px;
  background: rgba(255,255,255,0.72);
  box-shadow: 0 10px 28px rgba(57, 35, 18, 0.05);
}

.priority-num {
  width: 34px;
  height: 34px;
  border-radius: 10px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: rgba(255,107,53,0.10);
  color: var(--accent-dark);
  font-family: var(--mono);
  font-size: 12px;
  font-weight: 700;
}

.priority-action {
  font-family: var(--sans);
  font-size: 18px;
  font-weight: 900;
  color: var(--text);
  margin-bottom: 8px;
}

.priority-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 8px;
}

.priority-detail,
.priority-measure {
  font-size: 13px;
  color: var(--text2);
  line-height: 1.65;
}

.influence-card {
  background: linear-gradient(135deg, rgba(255,255,255,0.80), rgba(255,248,241,0.90));
}

.fi-chart {
  display: grid;
  gap: 14px;
  margin-top: 8px;
}

.fi-row {
  display: grid;
  grid-template-columns: minmax(160px, 0.9fr) minmax(0, 1.6fr) auto;
  align-items: center;
  gap: 14px;
  padding: 14px 16px;
  border: 1px solid var(--border);
  border-radius: 14px;
  background: rgba(255,255,255,0.74);
  box-shadow: 0 10px 28px rgba(57, 35, 18, 0.05);
  transition: transform 0.18s ease, box-shadow 0.18s ease, border-color 0.18s ease;
}

.fi-row:hover {
  transform: translateY(-1px);
  box-shadow: 0 16px 30px rgba(57, 35, 18, 0.08);
  border-color: rgba(255,107,53,0.20);
}

.fi-name {
  font-family: var(--body);
  font-size: 15px;
  font-weight: 700;
  color: var(--text);
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.fi-bar-wrap {
  position: relative;
  height: 12px;
  border-radius: 999px;
  overflow: hidden;
  background: rgba(108,76,48,0.08);
}

.fi-bar {
  width: 0;
  height: 100%;
  border-radius: inherit;
  transition: width 0.65s ease;
}

.fi-bar-pos { background: linear-gradient(90deg, rgba(19,138,82,0.82), rgba(33,165,101,1)); }
.fi-bar-neg { background: linear-gradient(90deg, rgba(214,69,69,0.82), rgba(255,107,53,1)); }
.fi-bar-neu { background: linear-gradient(90deg, rgba(210,138,23,0.82), rgba(255,180,78,1)); }

.fi-pct {
  font-family: var(--mono);
  font-size: 11px;
  color: var(--accent-dark);
  min-width: 54px;
  text-align: right;
}

.econ-human-label {
  margin-top: 14px;
  padding: 12px 14px;
  border: 1px solid rgba(255,107,53,0.12);
  border-radius: 12px;
  background: rgba(255,107,53,0.05);
  font-family: var(--body);
  font-size: 13px;
  line-height: 1.6;
  color: var(--text2);
}

.verdict-header {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  margin-bottom: 14px;
}

.verdict-sub-title {
  font-family: var(--mono);
  font-size: 10px;
  color: var(--accent);
  letter-spacing: 0.12em;
  text-transform: uppercase;
  margin-bottom: 6px;
}

.verdict-main-title {
  font-family: var(--sans);
  font-size: 26px;
  font-weight: 900;
  line-height: 1.05;
  letter-spacing: -0.03em;
  color: var(--text);
}

.verdict-body {
  color: var(--text2);
}

.verdict-context-tag {
  margin-top: 14px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 12px;
  border-radius: 999px;
  background: rgba(255,107,53,0.10);
  color: var(--accent-dark);
  font-family: var(--mono);
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.risk-alert {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 12px;
  align-items: start;
  padding: 14px 16px;
  margin-bottom: 10px;
  border: 1px solid rgba(214,69,69,0.20);
  border-radius: 14px;
  background: rgba(214,69,69,0.06);
}

.risk-icon {
  width: 30px;
  height: 30px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 10px;
  background: rgba(214,69,69,0.14);
}

@media (max-width: 900px) {
  .quality-hero-card,
  .model-grid-dynamic,
  .benchmark-grid,
  .completeness-list {
    grid-template-columns: 1fr;
  }

  .chart-header-v2,
  .insight-step-head {
    flex-direction: column;
    align-items: flex-start;
  }

  .fi-row {
    grid-template-columns: 1fr;
    gap: 10px;
  }

  .fi-pct {
    text-align: left;
  }
}
