/* =============================================
   ODbenchmark.com — Main Stylesheet
   ============================================= */

/* --- Reset & Box Sizing --- */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

/* --- CSS Variables --- */
:root {
  --navy: #0f2338;
  --blue: #1a6fb4;
  --green: #059669;
  --amber: #d97706;
  --grey: #6b7280;
  --bg: #f8fafc;
  --card: #ffffff;
  --border: #e2e8f0;
  --font: 'Inter', system-ui, -apple-system, sans-serif;
  --radius: 8px;
  --shadow: 0 1px 3px rgba(0, 0, 0, .08);
  --shadow-md: 0 4px 12px rgba(0, 0, 0, .10);
  --nav-h: 60px;
}

/* --- Base --- */
html {
  font-size: 16px;
  scroll-behavior: smooth;
}

body {
  font-family: var(--font);
  background: var(--bg);
  color: var(--navy);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

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

a:hover {
  text-decoration: underline;
}

ul {
  list-style: none;
}

/* =============================================
   NAV
   ============================================= */
.top-nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  background: var(--card);
  border-bottom: 1px solid var(--border);
  box-shadow: var(--shadow);
  height: var(--nav-h);
}

.nav-inner {
  max-width: 960px;
  margin: 0 auto;
  padding: 0 20px;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.nav-brand {
  font-size: 1.2rem;
  font-weight: 700;
  color: var(--navy);
  text-decoration: none;
  letter-spacing: -0.01em;
}

.nav-brand:hover {
  text-decoration: none;
  color: var(--blue);
}

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

/* --- Share Button & Dropdown --- */
.share-wrap {
  position: relative;
}

.share-btn {
  background: transparent;
  border: 1.5px solid var(--border);
  border-radius: 20px;
  padding: 6px 16px;
  font-family: var(--font);
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--navy);
  cursor: pointer;
  transition: border-color 0.15s, background 0.15s;
}

.share-btn:hover {
  border-color: var(--blue);
  color: var(--blue);
  background: #f0f7ff;
}

.share-dropdown {
  position: absolute;
  top: calc(100% + 6px);
  right: 0;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow-md);
  min-width: 180px;
  overflow: hidden;
  z-index: 200;
}

.share-option {
  display: block;
  width: 100%;
  padding: 10px 16px;
  text-align: left;
  background: none;
  border: none;
  font-family: var(--font);
  font-size: 0.9rem;
  color: var(--navy);
  cursor: pointer;
  transition: background 0.1s;
}

.share-option:hover {
  background: var(--bg);
}

/* =============================================
   MAIN CONTENT & FOOTER
   ============================================= */
.main-content {
  padding-top: var(--nav-h);
  min-height: calc(100vh - 120px);
}

.site-footer {
  text-align: center;
  padding: 24px 20px;
  font-size: 0.78rem;
  color: var(--grey);
  border-top: 1px solid var(--border);
  margin-top: 40px;
}

/* =============================================
   CARDS
   ============================================= */
.card {
  background: var(--card);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  border: 1px solid var(--border);
}

.card-section {
  padding: 24px;
  margin-bottom: 20px;
}

/* =============================================
   BUTTONS
   ============================================= */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 10px 20px;
  border-radius: var(--radius);
  font-family: var(--font);
  font-size: 0.9rem;
  font-weight: 600;
  cursor: pointer;
  border: 1.5px solid transparent;
  transition: background 0.15s, border-color 0.15s, color 0.15s, transform 0.1s;
  text-decoration: none;
  white-space: nowrap;
}

.btn:hover {
  transform: translateY(-1px);
}

.btn:active {
  transform: translateY(0);
}

.btn-primary {
  background: var(--blue);
  color: #fff;
  border-color: var(--blue);
}

.btn-primary:hover {
  background: #155f9e;
  border-color: #155f9e;
  color: #fff;
  text-decoration: none;
}

.btn-ghost {
  background: transparent;
  color: var(--blue);
  border-color: var(--blue);
}

.btn-ghost:hover {
  background: #f0f7ff;
  text-decoration: none;
}

.btn-lg {
  padding: 14px 28px;
  font-size: 1rem;
}

.btn-full {
  width: 100%;
}

/* =============================================
   FORMS
   ============================================= */
.form-group {
  margin-bottom: 16px;
}

.form-label {
  display: block;
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--navy);
  margin-bottom: 6px;
}

.optional {
  font-weight: 400;
  color: var(--grey);
  font-size: 0.8rem;
}

.form-input {
  width: 100%;
  padding: 10px 14px;
  border: 1.5px solid var(--border);
  border-radius: var(--radius);
  font-family: var(--font);
  font-size: 0.95rem;
  color: var(--navy);
  background: var(--card);
  transition: border-color 0.15s, box-shadow 0.15s;
  outline: none;
}

.form-input:focus {
  border-color: var(--blue);
  box-shadow: 0 0 0 3px rgba(26, 111, 180, 0.15);
}

.form-input-sm {
  width: 80px;
  padding: 6px 8px;
  border: 1.5px solid var(--border);
  border-radius: 6px;
  font-family: var(--font);
  font-size: 0.875rem;
  color: var(--navy);
  outline: none;
}

.form-input-sm:focus {
  border-color: var(--blue);
}

.form-textarea {
  width: 100%;
  padding: 10px 14px;
  border: 1.5px solid var(--border);
  border-radius: var(--radius);
  font-family: var(--font);
  font-size: 0.95rem;
  color: var(--navy);
  background: var(--card);
  resize: vertical;
  outline: none;
  transition: border-color 0.15s;
}

.form-textarea:focus {
  border-color: var(--blue);
  box-shadow: 0 0 0 3px rgba(26, 111, 180, 0.15);
}

.checkbox-group {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-top: 12px;
}

.checkbox-label {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.9rem;
  cursor: pointer;
}

.checkbox-label input[type="checkbox"] {
  width: 16px;
  height: 16px;
  cursor: pointer;
  accent-color: var(--blue);
}

.form-msg {
  margin-top: 8px;
  font-size: 0.875rem;
  min-height: 20px;
}

.error-msg {
  color: #dc2626;
  font-size: 0.875rem;
  padding: 8px 12px;
  background: #fef2f2;
  border: 1px solid #fecaca;
  border-radius: 6px;
  margin-bottom: 12px;
}

/* Edit inline input */
.edit-input {
  padding: 4px 8px;
  border: 1.5px solid var(--blue);
  border-radius: 6px;
  font-family: var(--font);
  font-size: inherit;
  color: var(--navy);
  outline: none;
}

/* =============================================
   SPINNER OVERLAY
   ============================================= */
.spinner-overlay {
  position: fixed;
  inset: 0;
  background: rgba(15, 35, 56, 0.85);
  z-index: 200;
  display: flex;
  align-items: center;
  justify-content: center;
}

.spinner-card {
  background: var(--card);
  border-radius: var(--radius);
  padding: 40px 48px;
  text-align: center;
  max-width: 340px;
  width: 90%;
}

.spinner-circle {
  width: 48px;
  height: 48px;
  border: 4px solid var(--border);
  border-top-color: var(--blue);
  border-radius: 50%;
  margin: 0 auto 20px;
  animation: spin 0.8s linear infinite;
}

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

.spinner-title {
  font-size: 1rem;
  font-weight: 600;
  color: var(--navy);
  margin-bottom: 6px;
}

.spinner-sub {
  font-size: 0.85rem;
  color: var(--grey);
}

/* =============================================
   HERO (INDEX PAGE)
   ============================================= */
.hero {
  background: var(--navy);
  color: #fff;
  padding: 80px 20px 100px;
  text-align: center;
}

.hero-inner {
  max-width: 600px;
  margin: 0 auto;
}

.hero-h1 {
  font-size: 2.25rem;
  font-weight: 700;
  line-height: 1.2;
  margin-bottom: 16px;
  letter-spacing: -0.02em;
}

.hero-sub {
  font-size: 1.05rem;
  opacity: 0.88;
  line-height: 1.6;
}

/* Search card overlap */
.search-card-wrap {
  display: flex;
  justify-content: center;
  padding: 0 20px;
  margin-top: -56px;
  margin-bottom: 40px;
  position: relative;
  z-index: 10;
}

.search-card {
  width: 100%;
  max-width: 480px;
  padding: 32px;
  box-shadow: var(--shadow-md);
}

/* =============================================
   FEATURE BOXES (INDEX PAGE)
   ============================================= */
.features-section {
  padding: 0 20px 48px;
}

.features-grid {
  max-width: 800px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}

.feature-box {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 24px 20px;
  text-align: center;
  box-shadow: var(--shadow);
}

.feature-icon {
  font-size: 2rem;
  margin-bottom: 10px;
}

.feature-title {
  font-size: 1rem;
  font-weight: 700;
  color: var(--navy);
  margin-bottom: 8px;
}

.feature-desc {
  font-size: 0.875rem;
  color: var(--grey);
  line-height: 1.5;
}

/* =============================================
   FAQ SECTION (INDEX PAGE)
   ============================================= */
.faq-section {
  padding: 0 20px 60px;
}

.faq-inner {
  max-width: 700px;
  margin: 0 auto;
}

.faq-heading {
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--navy);
  margin-bottom: 28px;
  text-align: center;
}

.faq-item {
  border-bottom: 1px solid var(--border);
  padding: 20px 0;
}

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

.faq-q {
  font-size: 1rem;
  font-weight: 600;
  color: var(--navy);
  margin-bottom: 8px;
}

.faq-a {
  font-size: 0.9rem;
  color: var(--grey);
  line-height: 1.6;
}

/* =============================================
   REPORT PAGE
   ============================================= */
.report-wrap {
  max-width: 800px;
  margin: 0 auto;
  padding: 32px 20px 60px;
}

/* Report header card */
.report-label {
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--grey);
  margin-bottom: 8px;
}

.report-name-row {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  margin-bottom: 4px;
}

.report-name {
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--navy);
}

.report-meta {
  font-size: 0.875rem;
  color: var(--grey);
  margin-bottom: 4px;
}

.report-meta-row {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.9rem;
  color: var(--navy);
  margin-bottom: 4px;
}

/* Edit button */
.edit-btn {
  background: none;
  border: none;
  color: var(--blue);
  font-size: 0.78rem;
  cursor: pointer;
  font-family: var(--font);
  padding: 2px 4px;
  border-radius: 4px;
  transition: background 0.1s;
}

.edit-btn:hover {
  background: #f0f7ff;
}

/* Disclaimer box */
.disclaimer-box {
  background: #fffbeb;
  border: 1px solid #fde68a;
  border-radius: 6px;
  padding: 12px 16px;
  font-size: 0.78rem;
  color: #78350f;
  line-height: 1.5;
  margin-top: 16px;
}

/* Section headers */
.section-header {
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--navy);
  padding-left: 12px;
  border-left: 4px solid var(--blue);
  margin-bottom: 12px;
  line-height: 1.3;
}

.section-header-green {
  border-left-color: var(--green);
}

.section-header-amber {
  border-left-color: var(--amber);
}

.section-sub {
  font-size: 0.875rem;
  color: var(--grey);
  margin-bottom: 16px;
}

.section-note {
  font-size: 0.82rem;
  color: var(--grey);
  font-style: italic;
  margin-bottom: 12px;
}

.subsection-title {
  font-size: 1rem;
  font-weight: 600;
  color: var(--navy);
  margin: 24px 0 8px;
}

/* Stat boxes */
.stat-row {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
  margin-bottom: 16px;
}

.stat-box {
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 16px 12px;
  text-align: center;
  box-shadow: var(--shadow);
}

.stat-val {
  min-height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 4px;
  overflow: hidden;
  max-width: 100%;
}

.stat-val canvas {
  max-width: 100%;
}

.stat-lbl {
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--grey);
  font-weight: 600;
}

/* Canvas containers */
canvas {
  display: block;
}

/* Noscript fallback */
.noscript-blur {
  background: var(--bg);
  border: 1px dashed var(--border);
  border-radius: 6px;
  padding: 16px;
  text-align: center;
  color: var(--grey);
  font-size: 0.875rem;
  margin-bottom: 12px;
}

.noscript-blur-inline {
  filter: blur(4px);
  user-select: none;
}

/* =============================================
   STRENGTH / WEAKNESS CARDS
   ============================================= */
.strength-card {
  border-left: 4px solid var(--green);
}

.weakness-card {
  border-left: 4px solid var(--amber);
}

.strength-list {
  list-style: disc;
  padding-left: 20px;
}

.strength-list li {
  font-size: 0.9rem;
  margin-bottom: 6px;
  color: var(--navy);
}

.weakness-subtitle {
  font-weight: 600;
  color: #92400e;
  margin-bottom: 12px;
  font-size: 0.95rem;
}

.improvement-stats {
  background: #f8fafc;
  border-radius: var(--radius);
  padding: 14px 16px;
  margin: 12px 0 16px;
}

.imp-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 6px 0;
  border-bottom: 1px solid #e2e8f0;
  font-size: 0.9rem;
}

.imp-row:last-child {
  border-bottom: none;
}

.imp-row-total {
  padding-top: 10px;
  font-size: 1rem;
}

.imp-divider {
  height: 1px;
  background: rgba(15,35,56,0.12);
  margin: 6px 0;
  border: none;
}

.imp-row-sub .imp-lbl {
  font-size: 0.88rem;
  opacity: 0.85;
}

/* ---- Color Vision Graphic ---- */
.cv-visual {
  display: flex;
  align-items: center;
  gap: 20px;
  background: var(--navy);
  border-radius: 10px;
  padding: 16px 20px;
  margin: 14px 0 20px;
}

.cv-wheel-wrap {
  position: relative;
  flex-shrink: 0;
  width: 86px;
  height: 86px;
}

.cv-wheel {
  width: 86px;
  height: 86px;
  border-radius: 50%;
  background: conic-gradient(
    #e74c3c 0deg 52deg,
    #e67e22 52deg 104deg,
    #f1c40f 104deg 158deg,
    #2ecc71 158deg 218deg,
    #3498db 218deg 278deg,
    #9b59b6 278deg 336deg,
    #e74c3c 336deg 360deg
  );
  box-shadow: 0 0 16px rgba(255,255,255,0.18);
}

.cv-pupil {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: #0a1628;
  box-shadow: inset 0 0 8px rgba(255,255,255,0.18);
}

.cv-pupil::after {
  content: '';
  position: absolute;
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: rgba(255,255,255,0.72);
  top: 7px;
  right: 7px;
}

.cv-facts {
  display: flex;
  flex-direction: column;
  gap: 9px;
  flex: 1;
}

.cv-fact {
  display: flex;
  align-items: flex-start;
  gap: 9px;
  font-size: 0.82rem;
  color: rgba(255,255,255,0.9);
  line-height: 1.45;
}

.cv-fact-num {
  font-weight: 700;
  font-size: 0.88rem;
  color: #fbbf24;
  white-space: nowrap;
  min-width: 58px;
}

.cv-fact-icon {
  font-size: 1rem;
  color: #fbbf24;
  min-width: 20px;
  flex-shrink: 0;
}

.cv-fact-txt em {
  font-style: italic;
  color: rgba(255,255,255,1);
}

.imp-lbl {
  color: var(--grey);
}

.imp-val {
  color: var(--navy);
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 4px;
}

.imp-note {
  font-size: 0.82rem;
  color: var(--grey);
  margin-bottom: 12px;
  display: flex;
  align-items: center;
  gap: 4px;
  flex-wrap: wrap;
}

/* =============================================
   PRO TIP BOX
   ============================================= */
.pro-tip-box {
  background: var(--navy);
  color: #fff;
  border-radius: var(--radius);
  padding: 20px 24px;
  margin-top: 16px;
}

.pro-tip-title {
  font-weight: 700;
  font-size: 0.95rem;
  margin-bottom: 10px;
}

.pro-tip-box p {
  font-size: 0.875rem;
  line-height: 1.6;
  margin-bottom: 10px;
}

.pro-tip-list {
  padding-left: 4px;
  margin-bottom: 10px;
}

.pro-tip-list li {
  font-size: 0.875rem;
  line-height: 1.6;
  margin-bottom: 6px;
  list-style: none;
}

.pro-tip-citation {
  font-size: 0.75rem;
  opacity: 0.7;
  margin-bottom: 0 !important;
}

/* =============================================
   COLLAPSIBLE CARD (LOAN TIP)
   ============================================= */
.collapsible-card {
  cursor: default;
}

.collapsible-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-weight: 600;
  font-size: 0.95rem;
  color: var(--navy);
  cursor: pointer;
  user-select: none;
  padding: 2px 0;
}

.collapsible-header:hover {
  color: var(--blue);
}

.collapse-arrow {
  font-size: 0.75rem;
  color: var(--grey);
  transition: transform 0.15s;
}

.collapsible-body {
  padding-top: 16px;
}

.collapsible-body p {
  font-size: 0.9rem;
  margin-bottom: 10px;
  line-height: 1.6;
}

.loan-example {
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 12px 16px;
  font-size: 0.875rem !important;
}

/* Loan calculator */
.loan-calc-title {
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--navy);
  margin: 16px 0 12px;
}

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

.loan-output {
  margin-top: 16px;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 16px;
}

.loan-result-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 8px;
  font-size: 0.9rem;
}

.loan-result-row:last-child {
  margin-bottom: 0;
}

.loan-result-label {
  color: var(--grey);
}

/* =============================================
   UPSELL CARD
   ============================================= */
.upsell-card {
  border: 2px solid transparent;
  background: linear-gradient(var(--card), var(--card)) padding-box,
              linear-gradient(135deg, var(--blue), var(--green)) border-box;
}

.upsell-headline {
  font-size: 1.05rem;
  font-weight: 600;
  color: var(--navy);
  margin-bottom: 16px;
}

.upsell-btns {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  margin-bottom: 20px;
}

.divider-or {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 20px 0;
  color: var(--grey);
  font-size: 0.85rem;
}

.divider-or::before,
.divider-or::after {
  content: '';
  flex: 1;
  border-top: 1px solid var(--border);
}

.newsletter-box {
  padding-top: 4px;
}

.newsletter-title {
  font-size: 1rem;
  font-weight: 700;
  color: var(--navy);
  margin-bottom: 4px;
}

.newsletter-sub {
  font-size: 0.85rem;
  color: var(--grey);
  margin-bottom: 12px;
}

/* =============================================
   SPECIALIZATION BUTTONS
   ============================================= */
.spec-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 12px;
}

.spec-btn {
  background: #f1f5f9;
  border: 1.5px solid var(--border);
  border-radius: 20px;
  padding: 6px 14px;
  font-family: var(--font);
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--grey);
  cursor: pointer;
  transition: background 0.15s, color 0.15s, border-color 0.15s;
}

.spec-btn:hover {
  border-color: var(--blue);
  color: var(--blue);
}

.spec-btn.active {
  background: var(--green);
  border-color: var(--green);
  color: #fff;
}

.spec-btn.error {
  background: #fee2e2;
  border-color: #f87171;
  color: #b91c1c;
  text-decoration: line-through;
}

.spec-btn.hidden-spec {
  display: none;
}

.show-more-specs {
  font-size: 0.82rem;
  color: var(--blue);
  display: block;
  margin-bottom: 16px;
}

/* =============================================
   TABLES
   ============================================= */
.table-wrap {
  overflow-x: auto;
  margin-bottom: 12px;
}

.data-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.875rem;
}

.data-table th {
  background: var(--bg);
  border-bottom: 2px solid var(--border);
  padding: 10px 12px;
  text-align: left;
  font-weight: 600;
  color: var(--grey);
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  white-space: nowrap;
}

.data-table td {
  padding: 10px 12px;
  border-bottom: 1px solid var(--border);
  color: var(--navy);
  vertical-align: middle;
}

.data-table tr:last-child td {
  border-bottom: none;
}

.data-table tr:hover td {
  background: #f8fafc;
}

.table-note {
  font-size: 0.78rem;
  color: var(--grey);
  margin-bottom: 4px;
}

/* =============================================
   SECTION 5 — Lens Opportunity Calculator
   ============================================= */
.lens-top-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  margin-bottom: 20px;
}

@media (max-width: 560px) {
  .lens-top-grid { grid-template-columns: 1fr; }
}

.lens-top-box {
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 14px 16px;
}

.lens-box-label {
  font-size: 0.8rem;
  color: var(--grey);
  margin-bottom: 10px;
  font-weight: 500;
}

.lens-pct-label {
  font-weight: 400;
  color: var(--grey);
}

.lens-stepper {
  display: flex;
  align-items: center;
  gap: 8px;
}

.stepper-btn {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  border: 1px solid var(--border);
  background: white;
  color: var(--navy);
  font-size: 0.75rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  line-height: 1;
  transition: background 0.15s;
}

.stepper-btn:hover {
  background: var(--bg);
  border-color: var(--blue);
  color: var(--blue);
}

.lens-num-input {
  width: 90px;
  font-size: 1.3rem;
  font-weight: 700;
  color: var(--navy);
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 4px 8px;
  text-align: center;
  -moz-appearance: textfield;
}

.lens-num-input::-webkit-inner-spin-button,
.lens-num-input::-webkit-outer-spin-button {
  -webkit-appearance: none;
}

.lens-calc-val {
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--blue);
  padding: 4px 0;
}

.lens-opportunity-note {
  font-size: 0.92rem;
  color: var(--grey);
  margin-bottom: 16px;
  font-style: italic;
}

/* Lens opportunity table */
.lens-opp-table .lens-type-cell {
  white-space: nowrap;
}

.rate-input-wrap {
  display: flex;
  align-items: center;
  gap: 4px;
  flex-wrap: wrap;
  row-gap: 4px;
}

.rate-input {
  width: 48px;
  font-size: 0.85rem;
  font-weight: 600;
  text-align: center;
  border: 1px solid var(--border);
  border-radius: 4px;
  padding: 3px 4px;
  color: var(--navy);
  -moz-appearance: textfield;
}

.rate-input::-webkit-inner-spin-button,
.rate-input::-webkit-outer-spin-button {
  -webkit-appearance: none;
}

.rate-pct {
  font-size: 0.8rem;
  color: var(--grey);
  font-weight: 500;
}

.rate-desc {
  font-size: 0.78rem;
  color: var(--grey);
}

.rev-input-wrap {
  display: flex;
  align-items: center;
  gap: 4px;
}

.rev-dollar {
  font-size: 0.9rem;
  color: var(--grey);
  font-weight: 500;
}

.rev-input {
  width: 72px;
  font-size: 0.9rem;
  font-weight: 600;
  text-align: right;
  border: 1px solid var(--border);
  border-radius: 4px;
  padding: 3px 6px;
  color: var(--navy);
  -moz-appearance: textfield;
}

.rev-input::-webkit-inner-spin-button,
.rev-input::-webkit-outer-spin-button {
  -webkit-appearance: none;
}

.calc-cell {
  font-weight: 600;
  color: var(--navy);
}

.opp-cell {
  color: var(--green);
  font-weight: 700;
}

.missed-row td {
  background: #fffbf2;
  color: var(--grey);
}

.missed-badge {
  display: inline-block;
  font-size: 0.68rem;
  font-weight: 600;
  background: #fef3c7;
  color: var(--amber);
  border-radius: 4px;
  padding: 1px 6px;
  margin-top: 2px;
  text-transform: uppercase;
  letter-spacing: 0.03em;
}

.missed-opp-cell {
  color: var(--amber) !important;
  font-weight: 700 !important;
}

.calc-cell-na {
  color: var(--grey);
  font-size: 0.85rem;
}

.section-divider {
  border: none;
  border-top: 1px solid var(--border);
  margin: 22px 0 18px;
}

.subsection-title {
  font-size: 1rem;
  font-weight: 700;
  color: var(--navy);
  margin-bottom: 6px;
}

.rev-entry-wrap {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-top: 4px;
}

.rev-entry-dollar {
  font-size: 1.3rem;
  font-weight: 600;
  color: var(--grey);
}

.rev-entry-input {
  font-size: 1.3rem;
  font-weight: 700;
  color: var(--navy);
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 5px 10px;
  width: 160px;
  -moz-appearance: textfield;
}

.rev-entry-input::-webkit-inner-spin-button,
.rev-entry-input::-webkit-outer-spin-button {
  -webkit-appearance: none;
}

/* =============================================
   KEY PRACTICE BENCHMARKS TABLE
   ============================================= */
.bench-kpi-table .kpi-label-cell { min-width: 200px; }

.kpi-sub {
  display: block;
  font-size: 0.72rem;
  color: var(--grey);
  font-weight: 400;
  margin-top: 2px;
}

.kpi-range-cell {
  white-space: nowrap;
  font-size: 0.85rem;
  color: var(--grey);
}

.kpi-input-wrap {
  display: flex;
  align-items: center;
  gap: 4px;
}

.kpi-pfx, .kpi-sfx {
  font-size: 0.82rem;
  color: var(--grey);
  white-space: nowrap;
}

.kpi-input {
  width: 68px;
  font-size: 0.9rem;
  font-weight: 600;
  text-align: right;
  border: 1px solid var(--border);
  border-radius: 4px;
  padding: 4px 6px;
  color: var(--navy);
  -moz-appearance: textfield;
}

.kpi-input::-webkit-inner-spin-button,
.kpi-input::-webkit-outer-spin-button {
  -webkit-appearance: none;
}

.kpi-status-cell {
  min-width: 130px;
}

.kpi-badge {
  display: inline-block;
  font-size: 0.74rem;
  font-weight: 600;
  border-radius: 20px;
  padding: 3px 10px;
  white-space: nowrap;
}

.kpi-badge-inrange { background: #d1fae5; color: #065f46; }
.kpi-badge-below   { background: #fef3c7; color: #92400e; }
.kpi-badge-above   { background: #dbeafe; color: #1e40af; }

.kpi-bar-track {
  position: relative;
  height: 6px;
  background: #e5e7eb;
  border-radius: 3px;
  margin-top: 7px;
  overflow: visible;
}

.kpi-bar-zone {
  position: absolute;
  top: 0;
  bottom: 0;
  background: #a7f3d0;
  border-radius: 3px;
}

.kpi-bar-dot {
  position: absolute;
  top: 50%;
  transform: translate(-50%, -50%);
  width: 11px;
  height: 11px;
  border-radius: 50%;
  border: 2px solid white;
  box-shadow: 0 1px 3px rgba(0,0,0,.2);
}

.kpi-dot-inrange { background: var(--green); }
.kpi-dot-below   { background: var(--amber); }
.kpi-dot-above   { background: var(--blue); }

/* Fake KPI rows (frost block) */
.fake-kpi-rows { margin-top: 12px; }

.fake-kpi-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 8px 0;
  border-bottom: 1px solid var(--border);
  font-size: 0.88rem;
}

.fake-kpi-label { color: var(--navy); }

/* =============================================
   PRACTICE VALUE CALCULATOR
   ============================================= */
.pvc-formula {
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 12px 16px;
  font-size: 0.92rem;
  color: var(--navy);
  margin-bottom: 16px;
}

.pvc-range-note {
  font-size: 0.8rem;
  color: var(--grey);
}

.pvc-rev-box {
  display: inline-block;
  margin-bottom: 20px;
}

.pvc-results-grid {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 12px;
  margin-bottom: 16px;
}

@media (max-width: 560px) {
  .pvc-results-grid { grid-template-columns: 1fr; }
}

.pvc-result-box {
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 14px 16px;
  text-align: center;
}

.pvc-result-mid {
  border-color: var(--green);
  background: #f0fdf4;
}

.pvc-result-label {
  font-size: 0.72rem;
  font-weight: 700;
  color: var(--grey);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 2px;
}

.pvc-result-mult {
  font-size: 0.8rem;
  color: var(--grey);
  margin-bottom: 6px;
}

.pvc-result-val {
  font-size: 1.35rem;
  font-weight: 700;
  color: var(--navy);
}

.pvc-result-mid .pvc-result-val {
  color: var(--green);
}

.pvc-disclaimer {
  font-size: 0.75rem;
  color: var(--grey);
  line-height: 1.6;
  margin-top: 8px;
}

.dpm-output {
  font-weight: 600;
  color: var(--green);
}

/* =============================================
   COMPARISON BARS
   ============================================= */
.comparison-bars {
  margin: 16px 0;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.comp-bar-row {
  display: flex;
  align-items: center;
  gap: 12px;
}

.comp-bar-label {
  font-size: 0.8rem;
  color: var(--grey);
  min-width: 70px;
}

.comp-bar-track {
  flex: 1;
  height: 10px;
  background: #e2e8f0;
  border-radius: 5px;
  overflow: hidden;
}

.comp-bar {
  height: 100%;
  border-radius: 5px;
  transition: width 0.6s ease;
}

.comp-bar.your-bar {
  background: var(--blue);
}

.comp-bar.avg-bar {
  background: var(--grey);
  opacity: 0.5;
}

.ratio-label {
  font-size: 0.9rem;
  color: var(--navy);
  margin-bottom: 8px;
}

/* =============================================
   BENCHMARK ROW (PRACTICE SIZE / LANES)
   ============================================= */
.edit-row {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 0.95rem;
  flex-wrap: wrap;
  margin-bottom: 12px;
}

.benchmark-row {
  display: flex;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
  font-size: 0.875rem;
}

.bench-label {
  color: var(--grey);
  font-weight: 600;
}

.bench-val {
  color: var(--navy);
  font-weight: 600;
}

.bench-pending {
  color: var(--grey);
  font-weight: 400;
  font-style: italic;
}

/* =============================================
   INFLUENCE NETWORK
   ============================================= */
.influence-inputs {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-top: 12px;
}

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

.influence-results {
  margin-top: 12px;
  font-size: 0.9rem;
  color: var(--navy);
  min-height: 20px;
}

.divider {
  border: none;
  border-top: 1px solid var(--border);
  margin: 20px 0;
}

/* =============================================
   SHARE SECTION
   ============================================= */
.share-action-row {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

/* =============================================
   LOCKED SECTION (PAID GATE)
   ============================================= */
.locked-section {
  position: relative;
  overflow: hidden;
  min-height: 280px;
}

.locked-blur-content {
  filter: blur(5px);
  user-select: none;
  pointer-events: none;
  padding: 8px;
  opacity: 0.5;
}

.locked-overlay {
  position: absolute;
  inset: 0;
  background: rgba(255, 255, 255, 0.88);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 2;
  backdrop-filter: blur(2px);
}

.locked-inner {
  text-align: center;
  padding: 32px 24px;
  max-width: 380px;
}

.locked-title {
  font-size: 1.3rem;
  font-weight: 700;
  color: var(--navy);
  margin-bottom: 16px;
}

.locked-features {
  list-style: disc;
  text-align: left;
  padding-left: 20px;
  margin-bottom: 24px;
}

.locked-features li {
  font-size: 0.9rem;
  color: var(--navy);
  margin-bottom: 6px;
  line-height: 1.5;
}

/* =============================================
   MODAL (QUARTERLY POPUP)
   ============================================= */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(15, 35, 56, 0.6);
  z-index: 300;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
}

.modal-card {
  background: var(--card);
  border-radius: var(--radius);
  padding: 32px;
  max-width: 440px;
  width: 100%;
  box-shadow: var(--shadow-md);
}

.modal-title {
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--navy);
  margin-bottom: 12px;
}

.modal-card p {
  font-size: 0.9rem;
  color: var(--navy);
  line-height: 1.6;
  margin-bottom: 20px;
}

.modal-btns {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

/* =============================================
   THANK YOU / REMINDER
   ============================================= */
.thanks-text {
  font-weight: 600;
  margin-bottom: 8px;
  color: var(--navy);
}

.reminder-inputs {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  margin-top: 12px;
  align-items: center;
}

.reminder-inputs .form-input {
  max-width: 260px;
}

/* =============================================
   REPORT HEADER CARD SPECIFICS
   ============================================= */
.report-header-card {
  border-top: 4px solid var(--navy);
}

/* =============================================
   RESPONSIVE — MOBILE FIRST
   ============================================= */
@media (max-width: 768px) {
  .hero-h1 {
    font-size: 1.65rem;
  }

  .hero {
    padding: 60px 20px 80px;
  }

  .search-card {
    padding: 24px 20px;
  }

  .features-grid {
    grid-template-columns: 1fr;
    gap: 14px;
  }

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

  .loan-grid {
    grid-template-columns: 1fr;
  }

  .upsell-btns {
    flex-direction: column;
  }

  .upsell-btns .btn {
    width: 100%;
  }

  .modal-btns {
    flex-direction: column;
  }

  .modal-btns .btn {
    width: 100%;
  }

  .benchmark-row {
    gap: 8px;
  }

  .influence-row {
    flex-direction: column;
    align-items: stretch;
  }

  .influence-row .inf-state {
    max-width: 100% !important;
  }

  .reminder-inputs {
    flex-direction: column;
    align-items: stretch;
  }

  .reminder-inputs .form-input {
    max-width: 100%;
  }

  .comp-bar-label {
    min-width: 55px;
  }

  .report-name {
    font-size: 1.2rem;
  }

  .card-section {
    padding: 18px 16px;
  }
}

@media (max-width: 480px) {
  .nav-brand {
    font-size: 1rem;
  }

  .share-btn {
    padding: 6px 12px;
    font-size: 0.8rem;
  }

  .stat-row {
    grid-template-columns: repeat(3, 1fr);
  }

  .stat-box {
    padding: 12px 8px;
  }

  .stat-lbl {
    font-size: 0.65rem;
  }
}

/* =============================================
   PAYWALL / SEASONAL PRICING
   ============================================= */

.paywall-cta-card {
  border: 2px solid var(--blue);
  background: linear-gradient(135deg, #f0f7ff 0%, #ffffff 100%);
}

.paywall-subhead {
  font-size: 1.05rem;
  color: var(--navy);
  margin-bottom: 16px;
}

.paywall-sale-badge {
  display: inline-block;
  background: var(--amber);
  color: #fff;
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  padding: 4px 12px;
  border-radius: 20px;
  margin-bottom: 8px;
}

.paywall-price-row {
  display: flex;
  align-items: baseline;
  gap: 14px;
  margin-bottom: 20px;
}

.paywall-price-main {
  font-size: 2.4rem;
  font-weight: 700;
  color: var(--navy);
}

.paywall-price-was {
  font-size: 1rem;
  color: var(--grey);
}

.paywall-features-wrap {
  background: var(--bg);
  border-radius: var(--radius);
  padding: 16px 18px;
  margin-bottom: 20px;
}

.paywall-features-title {
  font-weight: 700;
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--grey);
  margin-bottom: 10px;
}

.paywall-features-list {
  list-style: none;
  padding: 0;
}

.paywall-features-list li {
  font-size: 0.88rem;
  padding: 7px 0;
  border-bottom: 1px solid var(--border);
  color: var(--navy);
  display: flex;
  gap: 8px;
}

.paywall-features-list li:last-child {
  border-bottom: none;
}

.paywall-features-list li::before {
  content: "✓";
  color: var(--green);
  font-weight: 700;
  flex-shrink: 0;
}

.paywall-unlock-btn {
  width: 100%;
  font-size: 1.05rem;
  padding: 14px;
  margin-bottom: 14px;
}

.paywall-guarantee {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  background: #f0fdf4;
  border: 1px solid #bbf7d0;
  border-radius: var(--radius);
  padding: 12px 14px;
  font-size: 0.84rem;
  color: #065f46;
  margin-bottom: 20px;
  line-height: 1.5;
}

.guarantee-icon {
  flex-shrink: 0;
  font-size: 1rem;
}

/* Paywall wrapper + frost overlay */
.paywall-wrapper {
  position: relative;
  border-radius: var(--radius);
  overflow: hidden;
  margin-bottom: 24px;
  min-height: 420px;
}

.paywall-frost {
  position: absolute;
  inset: 0;
  z-index: 20;
  background: linear-gradient(
    to bottom,
    rgba(248, 250, 252, 0.0) 0px,
    rgba(248, 250, 252, 0.75) 60px,
    rgba(248, 250, 252, 0.97) 130px,
    rgba(248, 250, 252, 1.0) 190px
  );
  backdrop-filter: blur(3px);
  -webkit-backdrop-filter: blur(3px);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
  padding: 90px 16px 40px;
  pointer-events: all;
}

.paywall-frost-inner {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 12px;
  box-shadow: var(--shadow-md);
  padding: 24px 28px;
  text-align: center;
  max-width: 340px;
  width: 100%;
}

.frost-sale-badge {
  display: inline-block;
  background: var(--amber);
  color: #fff;
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  padding: 3px 10px;
  border-radius: 20px;
  margin-bottom: 10px;
}

.frost-price {
  font-size: 1.9rem;
  font-weight: 700;
  color: var(--navy);
  margin-bottom: 14px;
  display: flex;
  align-items: baseline;
  justify-content: center;
  gap: 10px;
}

.frost-was {
  font-size: 1rem;
  color: var(--grey);
  font-weight: 400;
}

.frost-guarantee {
  font-size: 0.78rem;
  color: #065f46;
  margin-top: 12px;
}

/* Fake content under frost — blur + no interaction */
.paywall-wrapper .card {
  filter: blur(1.5px);
  user-select: none;
  pointer-events: none;
}

.fake-stat {
  font-size: 1.4rem;
  font-weight: 700;
  color: var(--navy);
}

/* Section header with inline feedback button */
.section-header-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 4px;
  gap: 8px;
}

.section-header-row .section-header {
  margin-bottom: 0;
}

.btn-feedback-sm {
  font-size: 0.74rem;
  color: var(--grey);
  background: none;
  border: 1px solid var(--border);
  border-radius: 20px;
  padding: 3px 10px;
  cursor: pointer;
  white-space: nowrap;
  flex-shrink: 0;
  line-height: 1.4;
}

.btn-feedback-sm:hover {
  background: var(--bg);
  color: var(--navy);
  border-color: var(--grey);
}

/* Completed By select in table */
.form-select-sm {
  font-size: 0.8rem;
  padding: 4px 6px;
  border: 1px solid var(--border);
  border-radius: 4px;
  background: white;
  cursor: pointer;
  min-width: 78px;
  color: var(--navy);
}

/* Section feedback modal */
.sfb-desc {
  font-size: 0.88rem;
  color: var(--grey);
  margin-bottom: 12px;
}

/* ============================================================
   PAYWALL HOOK
   ============================================================ */
.paywall-hook {
  font-size: 0.97rem;
  color: #374151;
  background: #eff6ff;
  border: 1px solid #bfdbfe;
  border-radius: var(--radius);
  padding: 12px 16px;
  margin-bottom: 16px;
  line-height: 1.55;
}
.paywall-hook-amount {
  color: var(--green);
  font-size: 1.08rem;
}

/* ============================================================
   REVENUE OPPORTUNITY GRID
   ============================================================ */
.opp-grid {
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.opp-card {
  display: flex;
  gap: 14px;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 16px;
  align-items: flex-start;
}
.opp-card-icon {
  font-size: 1.6rem;
  flex-shrink: 0;
  width: 36px;
  text-align: center;
  margin-top: 2px;
}
.opp-card-body {
  flex: 1;
  min-width: 0;
}
.opp-card-title {
  font-size: 1rem;
  font-weight: 700;
  color: var(--navy);
  margin-bottom: 4px;
}
.opp-card-desc {
  font-size: 0.87rem;
  color: #374151;
  line-height: 1.5;
  margin-bottom: 4px;
}
.opp-card-action {
  font-size: 0.8rem;
  color: var(--blue);
  font-style: italic;
}
.opp-card-val {
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--green);
  white-space: nowrap;
  flex-shrink: 0;
  padding-top: 2px;
}
.opp-total {
  display: none;
  justify-content: space-between;
  align-items: center;
  background: var(--navy);
  color: #fff;
  border-radius: var(--radius);
  padding: 14px 18px;
  margin-top: 4px;
}
.opp-total-label {
  font-size: 1rem;
  font-weight: 600;
}
#opp-total-val {
  font-size: 1.4rem;
  font-weight: 800;
  color: #86efac;
}

/* ============================================================
   PRACTICE HEALTH SCORE
   ============================================================ */
.score-layout {
  display: flex;
  gap: 24px;
  align-items: flex-start;
  flex-wrap: wrap;
}
.score-gauge-wrap {
  display: flex;
  flex-direction: column;
  align-items: center;
  flex-shrink: 0;
  min-width: 160px;
}
.score-gauge-wrap canvas {
  display: block;
}
.score-callout {
  display: flex;
  flex-direction: column;
  align-items: center;
  margin-top: -10px;
}
.score-number {
  font-size: 2.4rem;
  font-weight: 800;
  color: var(--navy);
  line-height: 1;
}
.score-grade {
  font-size: 1.5rem;
  font-weight: 800;
  margin-top: 2px;
}
.score-sublabel {
  font-size: 0.78rem;
  color: var(--grey);
  margin-top: 2px;
}
.score-breakdown {
  flex: 1;
  min-width: 240px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.score-row {
  display: grid;
  grid-template-columns: 140px 1fr 40px auto;
  align-items: center;
  gap: 8px;
}
.score-row-label {
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--navy);
}
.score-bar-wrap {
  height: 8px;
  background: #e5e7eb;
  border-radius: 4px;
  overflow: hidden;
}
.score-bar-fill {
  height: 100%;
  border-radius: 4px;
  transition: width 0.6s ease;
}
.score-row-pts {
  font-size: 0.78rem;
  color: var(--grey);
  text-align: right;
  white-space: nowrap;
}
.score-row-desc {
  font-size: 0.76rem;
  color: var(--grey);
  grid-column: 2 / -1;
  margin-top: -6px;
}
/* Action plan */
.action-plan {
  margin-top: 20px;
  display: flex;
  flex-direction: column;
  gap: 14px;
}
.action-item {
  display: flex;
  gap: 14px;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 14px 16px;
}
.action-priority {
  width: 28px;
  height: 28px;
  background: var(--navy);
  color: #fff;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.85rem;
  font-weight: 700;
  flex-shrink: 0;
  margin-top: 2px;
}
.action-body { flex: 1; min-width: 0; }
.action-header-row {
  display: flex;
  gap: 8px;
  align-items: flex-start;
  flex-wrap: wrap;
  margin-bottom: 6px;
}
.action-title {
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--navy);
  flex: 1;
}
.action-badge {
  font-size: 0.7rem;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: 20px;
  white-space: nowrap;
  flex-shrink: 0;
}
.badge-quick { background: #dcfce7; color: #166534; }
.badge-30d   { background: #dbeafe; color: #1e40af; }
.badge-90d   { background: #fef9c3; color: #854d0e; }
.action-impact {
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--green);
  white-space: nowrap;
  flex-shrink: 0;
}
.action-desc {
  font-size: 0.84rem;
  color: #374151;
  line-height: 1.5;
  margin-bottom: 6px;
}
.action-timeframe {
  font-size: 0.78rem;
  color: var(--grey);
}

/* ============================================================
   LTV CALCULATOR
   ============================================================ */
.ltv-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 12px;
  margin-top: 16px;
}
.ltv-result-box {
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 14px;
  text-align: center;
}
.ltv-result-box.ltv-primary {
  border-color: var(--navy);
  background: #eff6ff;
}
.ltv-result-label {
  font-size: 0.77rem;
  color: var(--grey);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  margin-bottom: 6px;
}
.ltv-primary-val,
.ltv-result-val {
  font-size: 1.5rem;
  font-weight: 800;
  color: var(--navy);
  line-height: 1;
}
.ltv-insight {
  font-size: 0.83rem;
  color: #374151;
  margin-top: 12px;
  line-height: 1.5;
  background: #f0fdf4;
  border: 1px solid #bbf7d0;
  border-radius: var(--radius);
  padding: 10px 12px;
}

/* ============================================================
   EQUIPMENT ROI
   ============================================================ */
.equip-note {
  display: none;
  font-size: 0.84rem;
  color: #374151;
  background: #eff6ff;
  border: 1px solid #bfdbfe;
  border-radius: var(--radius);
  padding: 10px 14px;
  margin-bottom: 12px;
  line-height: 1.5;
}

/* ============================================================
   PRODUCT RECS
   ============================================================ */
.prod-recs-grid {
  display: flex;
  flex-direction: column;
  gap: 14px;
}
.prod-card {
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.prod-cat {
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--blue);
  background: #dbeafe;
  padding: 2px 8px;
  border-radius: 20px;
  align-self: flex-start;
}
.prod-name {
  font-size: 1rem;
  font-weight: 700;
  color: var(--navy);
}
.prod-why {
  font-size: 0.86rem;
  color: #374151;
  line-height: 1.5;
}
.prod-roi {
  font-size: 0.83rem;
  color: var(--green);
  font-weight: 600;
}
.prod-action {
  align-self: flex-start;
  font-size: 0.83rem;
  font-weight: 600;
  color: var(--blue);
  text-decoration: none;
  border: 1px solid var(--blue);
  border-radius: 20px;
  padding: 4px 12px;
  margin-top: 4px;
  transition: background 0.15s;
}
.prod-action:hover {
  background: var(--blue);
  color: #fff;
}

/* ============================================================
   ASSOCIATE ROI / GENERIC CALC RESULT BOX
   ============================================================ */
#assoc-results { margin-top: 14px; }
#assoc-results .pvc-results-grid { margin-top: 0; }

/* ============================================================
   SECTION DESCRIPTION TEXT
   ============================================================ */
.section-desc {
  font-size: 0.9rem;
  color: #374151;
  line-height: 1.65;
  margin-bottom: 16px;
  max-width: 760px;
}
.section-desc strong {
  color: var(--navy);
}

/* Print button */
.btn-print {
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--navy);
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 6px 14px;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 6px;
  transition: background 0.15s, border-color 0.15s;
}
.btn-print:hover {
  background: var(--bg);
  border-color: var(--navy);
}

/* ============================================================
   WEBSITE ANALYSIS SECTION
   ============================================================ */

/* Score header layout */
.ws-score-header {
  display: flex;
  gap: 24px;
  align-items: center;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px;
  margin-bottom: 20px;
  flex-wrap: wrap;
}
.ws-score-main {
  display: flex;
  flex-direction: column;
  align-items: center;
  flex-shrink: 0;
  min-width: 90px;
}
.ws-score-circle {
  width: 80px;
  height: 80px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  border: 4px solid;
}
.ws-score-a { border-color: var(--green); }
.ws-score-b { border-color: var(--blue); }
.ws-score-c { border-color: var(--amber); }
.ws-score-d { border-color: #dc2626; }
.ws-score-num {
  font-size: 1.6rem;
  font-weight: 800;
  color: var(--navy);
  line-height: 1;
}
.ws-score-denom {
  font-size: 0.7rem;
  color: var(--grey);
}
.ws-score-label {
  font-size: 0.72rem;
  color: var(--grey);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-top: 6px;
}
.ws-dimension-bars {
  flex: 1;
  min-width: 240px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.ws-dim-row {
  display: grid;
  grid-template-columns: 90px 1fr 32px;
  align-items: center;
  gap: 8px;
}
.ws-dim-label {
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--navy);
}
.ws-dim-track {
  height: 8px;
  background: #e5e7eb;
  border-radius: 4px;
  overflow: hidden;
}
.ws-dim-fill {
  height: 100%;
  border-radius: 4px;
  transition: width 0.5s ease;
}
.ws-fill-green { background: var(--green); }
.ws-fill-amber { background: var(--amber); }
.ws-fill-red   { background: #dc2626; }
.ws-dim-val {
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--navy);
  text-align: right;
}

/* Detected signals grid */
.ws-detected-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 8px;
  margin-bottom: 16px;
}
.ws-det-item {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  font-size: 0.83rem;
  padding: 8px 10px;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  line-height: 1.4;
}
.ws-det-ok   { background: #f0fdf4; border-color: #bbf7d0; }
.ws-det-bad  { background: #fef2f2; border-color: #fecaca; }
.ws-det-warn { background: #fffbeb; border-color: #fde68a; }
.ws-det-icon {
  font-size: 0.9rem;
  flex-shrink: 0;
  margin-top: 1px;
}
.ws-det-ok .ws-det-icon   { color: var(--green); }
.ws-det-bad .ws-det-icon  { color: #dc2626; }
.ws-det-warn .ws-det-icon { color: var(--amber); font-weight: 700; }
.ws-det-text { color: #374151; }
.ws-det-text em { font-style: normal; font-weight: 600; color: var(--navy); }

/* Keyword tags */
.ws-kw-list {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 16px;
}
.ws-kw-tag {
  font-size: 0.8rem;
  background: #dbeafe;
  color: #1e40af;
  border-radius: 20px;
  padding: 4px 12px;
  font-weight: 500;
}

/* Findings */
.ws-findings {
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.ws-finding {
  border-radius: var(--radius);
  border: 1px solid var(--border);
  padding: 12px 14px;
}
.ws-finding-high   { border-left: 4px solid #dc2626; background: #fef2f2; }
.ws-finding-medium { border-left: 4px solid var(--amber); background: #fffbeb; }
.ws-finding-low    { border-left: 4px solid var(--blue); background: #eff6ff; }
.ws-finding-header {
  display: flex;
  align-items: baseline;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 6px;
}
.ws-finding-badge {
  font-size: 0.65rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  border-radius: 20px;
  padding: 2px 7px;
  flex-shrink: 0;
}
.ws-badge-high   { background: #fecaca; color: #991b1b; }
.ws-badge-medium { background: #fde68a; color: #92400e; }
.ws-badge-low    { background: #bfdbfe; color: #1e40af; }
.ws-finding-cat {
  font-size: 0.72rem;
  color: var(--grey);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  flex-shrink: 0;
}
.ws-finding-issue {
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--navy);
}
.ws-finding-rec {
  font-size: 0.84rem;
  color: #374151;
  line-height: 1.5;
  margin-bottom: 4px;
}
.ws-finding-impact {
  font-size: 0.78rem;
  color: var(--grey);
  font-style: italic;
}

/* Error / no-URL states */
.ws-error-box {
  display: flex;
  gap: 14px;
  align-items: flex-start;
  background: #fffbeb;
  border: 1px solid #fde68a;
  border-radius: var(--radius);
  padding: 16px;
  font-size: 0.88rem;
  color: #374151;
}
.ws-error-icon { font-size: 1.4rem; flex-shrink: 0; }
.ws-no-url-box {
  display: flex;
  gap: 14px;
  align-items: flex-start;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px;
  font-size: 0.88rem;
  color: #374151;
}
.ws-no-url-icon { font-size: 1.6rem; flex-shrink: 0; }

/* =====================================================================
   Per-section inline feedback widget
   ===================================================================== */
.section-fb-bar {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-top: 20px;
  padding-top: 14px;
  border-top: 1px solid var(--border);
  flex-wrap: wrap;
}
.section-fb-prompt {
  font-size: 0.78rem;
  color: var(--grey);
  flex-shrink: 0;
}
.section-fb-quick {
  display: flex;
  gap: 6px;
}
.section-fb-btn {
  font-size: 0.78rem;
  padding: 4px 10px;
  border-radius: 20px;
  border: 1px solid var(--border);
  background: var(--white);
  color: #374151;
  cursor: pointer;
  transition: background 0.15s, border-color 0.15s;
  font-family: inherit;
}
.section-fb-btn:hover  { background: var(--bg); border-color: #9ca3af; }
.section-fb-btn.fb-sel-pos { background: #dcfce7; border-color: #16a34a; color: #15803d; }
.section-fb-btn.fb-sel-neg { background: #fee2e2; border-color: #dc2626; color: #b91c1c; }
.section-fb-expand {
  display: none;
  margin-top: 10px;
  width: 100%;
}
.section-fb-expand.open { display: block; }
.section-fb-stars {
  display: flex;
  gap: 4px;
  margin-bottom: 8px;
}
.section-fb-star {
  font-size: 1.1rem;
  cursor: pointer;
  color: #d1d5db;
  transition: color 0.1s;
}
.section-fb-star.active { color: #f59e0b; }
.section-fb-textarea {
  width: 100%;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 8px 10px;
  font-size: 0.84rem;
  font-family: inherit;
  resize: vertical;
  min-height: 60px;
  color: var(--navy);
  box-sizing: border-box;
}
.section-fb-send {
  margin-top: 6px;
  padding: 5px 14px;
  border-radius: 6px;
  border: 1px solid var(--blue);
  background: var(--white);
  color: var(--blue);
  font-size: 0.82rem;
  cursor: pointer;
  font-family: inherit;
}
.section-fb-send:hover { background: #eff6ff; }
.section-fb-thanks {
  font-size: 0.8rem;
  color: var(--green);
  margin-top: 6px;
}

/* =====================================================================
   Drug prescription profile section
   ===================================================================== */
.drug-bar-row {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 8px;
}
.drug-bar-label {
  flex: 0 0 180px;
  font-size: 0.84rem;
  color: var(--navy);
  font-weight: 500;
  text-align: right;
}
.drug-bar-track {
  flex: 1;
  height: 16px;
  background: var(--bg);
  border-radius: 8px;
  overflow: hidden;
  min-width: 80px;
}
.drug-bar-fill {
  height: 100%;
  border-radius: 8px;
  background: linear-gradient(90deg, #2563eb, #60a5fa);
}
.drug-bar-pct {
  flex: 0 0 36px;
  font-size: 0.82rem;
  color: var(--grey);
  text-align: right;
}
.drug-pill {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 3px 10px;
  border-radius: 20px;
  font-size: 0.78rem;
  font-weight: 600;
  border: 1px solid;
}
.drug-pill-glaucoma { background: #eff6ff; color: #1d4ed8; border-color: #bfdbfe; }
.drug-pill-dry      { background: #f0fdf4; color: #15803d; border-color: #86efac; }
.drug-pill-myopia   { background: #fdf4ff; color: #7e22ce; border-color: #e9d5ff; }
.drug-pill-other    { background: #f9fafb; color: #374151; border-color: #e5e7eb; }

/* =====================================================================
   Patient health profile section
   ===================================================================== */
.patient-stat-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(130px, 1fr));
  gap: 14px;
  margin-bottom: 16px;
}
.patient-stat-box {
  background: var(--bg);
  border-radius: var(--radius);
  padding: 14px 12px;
  text-align: center;
}
.patient-stat-val {
  font-size: 1.6rem;
  font-weight: 800;
  color: var(--navy);
  line-height: 1.1;
}
.patient-stat-lbl {
  font-size: 0.72rem;
  color: var(--grey);
  margin-top: 4px;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}
.cc-tag-list {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 10px;
}
.cc-tag {
  padding: 3px 10px;
  background: #fff7ed;
  border: 1px solid #fed7aa;
  color: #c2410c;
  border-radius: 20px;
  font-size: 0.78rem;
  font-weight: 500;
}

/* =====================================================================
   CPT peer gap section
   ===================================================================== */
.gap-row {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 8px;
  flex-wrap: wrap;
}
.gap-cpt-code {
  flex: 0 0 52px;
  font-size: 0.84rem;
  font-weight: 700;
  color: var(--amber);
  font-family: monospace;
}
.gap-desc {
  flex: 1 1 180px;
  font-size: 0.82rem;
  color: #374151;
}
.gap-bar-wrap {
  flex: 0 0 100px;
}
.gap-bar-track {
  height: 12px;
  background: var(--bg);
  border-radius: 6px;
  overflow: hidden;
}
.gap-bar-fill {
  height: 100%;
  border-radius: 6px;
  background: linear-gradient(90deg, #92400e, #f59e0b);
}
.gap-pct {
  flex: 0 0 36px;
  font-size: 0.78rem;
  color: var(--amber);
  text-align: right;
}
.gap-rate {
  flex: 0 0 52px;
  font-size: 0.78rem;
  color: var(--grey);
  text-align: right;
}

/* =====================================================================
   Revenue trend chart
   ===================================================================== */
.trend-chart-wrap {
  overflow-x: auto;
  margin-top: 12px;
}
.trend-bars {
  display: flex;
  align-items: flex-end;
  gap: 6px;
  height: 120px;
  border-bottom: 2px solid var(--border);
  padding-bottom: 4px;
  min-width: 280px;
}
.trend-bar-col {
  display: flex;
  flex-direction: column;
  align-items: center;
  flex: 1;
  min-width: 28px;
  height: 100%;
  justify-content: flex-end;
}
.trend-bar {
  width: 100%;
  border-radius: 4px 4px 0 0;
  min-height: 4px;
  transition: opacity 0.2s;
}
.trend-bar:hover { opacity: 0.85; }
.trend-bar-year {
  font-size: 0.65rem;
  color: var(--grey);
  margin-top: 4px;
  text-align: center;
}
.trend-bar-val {
  font-size: 0.6rem;
  color: var(--grey);
  text-align: center;
  margin-top: 2px;
}
.trend-legend {
  display: flex;
  gap: 16px;
  margin-top: 10px;
  flex-wrap: wrap;
}
.trend-legend-item {
  display: flex;
  align-items: center;
  gap: 5px;
  font-size: 0.78rem;
  color: var(--grey);
}
.trend-legend-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  flex-shrink: 0;
}

/* =====================================================================
   Industry payments widget
   ===================================================================== */
.op-companies-list {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-top: 10px;
}
.op-company-row {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 0.84rem;
  padding: 6px 10px;
  background: var(--bg);
  border-radius: var(--radius);
}
.op-company-name {
  flex: 1;
  font-weight: 500;
  color: var(--navy);
}
.op-company-amt {
  font-weight: 700;
  color: var(--blue);
}
.op-company-nature {
  font-size: 0.72rem;
  color: var(--grey);
  font-style: italic;
}

/* =====================================================================
   EMAIL / PRINT BAR
   ===================================================================== */
.email-pdf-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: linear-gradient(135deg, #0f3460 0%, #1a5276 100%);
  border: 1px solid #2e86c1;
  border-radius: var(--radius);
  padding: 10px 18px;
  margin-bottom: 10px;
  gap: 12px;
  flex-wrap: wrap;
}
.email-pdf-bar-left {
  display: flex;
  align-items: center;
  gap: 8px;
}
.email-pdf-bar-label {
  font-size: 0.87rem;
  font-weight: 600;
  color: #aed6f1;
}
.email-pdf-bar-right {
  display: flex;
  gap: 8px;
  flex-shrink: 0;
}
.btn-email-pdf {
  font-size: 0.82rem;
  font-weight: 600;
  color: #1a5276;
  background: #aed6f1;
  border: 1px solid #7fb3d3;
  border-radius: var(--radius);
  padding: 6px 14px;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 6px;
  transition: background 0.15s;
}
.btn-email-pdf:hover {
  background: #d6eaf8;
}
.email-pdf-hint {
  background: #1e4d2b;
  border: 1px solid #27ae60;
  border-radius: var(--radius);
  padding: 8px 14px;
  font-size: 0.82rem;
  color: #a9dfbf;
  margin-bottom: 10px;
}

/* =====================================================================
   PRINT STYLES  — clean PDF output, no UI chrome
   ===================================================================== */
@media print {
  /* Hide all screen-only chrome */
  nav, header, footer,
  .no-print,
  .paywall-section,
  .section-fb-bar,
  .newsletter-section,
  .btn-feedback-sm,
  .btn-print,
  .btn-email-pdf,
  .email-pdf-bar,
  .email-pdf-hint { display: none !important; }

  /* Show the print cover page that's hidden on screen */
  .print-cover { display: block !important; page-break-after: always; }

  /* Force white backgrounds and dark text for readability */
  body, .card, .card-section { background: #fff !important; color: #111 !important; }
  .stat-row, .stat-box, .metric-grid { background: #f5f8fa !important; }

  /* Avoid breaking inside cards */
  .card, .card-section { page-break-inside: avoid; }

  /* Keep colors on key numbers */
  .text-green  { color: #1a7a4a !important; }
  .text-red    { color: #c0392b !important; }
  .text-blue   { color: #1a5276 !important; }
  .big-number  { color: #1a5276 !important; }

  @page { margin: 0.75in; size: letter; }
}

/* ── Data freshness tag on section headers ─────────────────────────── */
.data-tag {
  display: inline-block;
  font-size: 0.62rem;
  font-weight: 500;
  color: #6b7280;
  background: #f3f4f6;
  border: 1px solid #e5e7eb;
  border-radius: 10px;
  padding: 1px 8px;
  margin-left: 8px;
  white-space: nowrap;
  vertical-align: middle;
  letter-spacing: 0.01em;
  line-height: 1.7;
}
@media print { .data-tag { display: none; } }
