/* ============================================================
   NEXTOCR V2 — MODERN CLEAN UI (2026)
   ============================================================ */

:root {
  --brand: #2563eb;
  --brand-dark: #1d4ed8;
  --brand-light: #60a5fa;
  --brand-soft: #dbeafe;
  --text-primary: #0f172a;
  --text-secondary: #475569;
  --text-muted: #94a3b8;
  --bg-primary: #ffffff;
  --bg-secondary: #f8fafc;
  --bg-tertiary: #f1f5f9;
  --border: #e2e8f0;
  --border-light: #f1f5f9;
  --success: #10b981;
  --warning: #f59e0b;
  --danger: #ef4444;
  /* Soft semantic tints (match base.html slate/blue system) */
  --success-soft: #d1fae5;
  --success-text: #065f46;
  --danger-soft: #fee2e2;
  --danger-text: #991b1b;
  /* Gemini feature — purple kept intentionally as third-party feature branding,
     used ONLY on the Gemini refine button + result card */
  --gemini: #4f46e5;
  --gemini-dark: #4338ca;
  --gemini-soft: #e0e7ff;
  --gemini-border: #c7d2fe;
  --gemini-text: #3730a3;
  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 16px;
  --radius-xl: 20px;
  --shadow-sm: 0 1px 2px rgba(0,0,0,0.04);
  --shadow-md: 0 4px 12px rgba(0,0,0,0.06);
  --shadow-lg: 0 12px 32px rgba(0,0,0,0.08);
  --shadow-xl: 0 24px 48px rgba(0,0,0,0.1);
  --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

body {
  font-family: 'Nokora', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  background: var(--bg-secondary);
  color: var(--text-primary);
  -webkit-font-smoothing: antialiased;
}

/* ============================================================
   WORKSPACE SECTION — CLEAN & FOCUSED
   ============================================================ */

.workspace-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1.5rem;
  padding: 0 0.5rem;
}

.workspace-title {
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--text-primary);
  letter-spacing: -0.02em;
}

.lang-switcher {
  display: flex;
  gap: 0;
  background: var(--bg-primary);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 3px;
  box-shadow: var(--shadow-sm);
}

.lang-switcher button {
  border: none;
  background: transparent;
  padding: 0.4rem 0.9rem;
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--text-muted);
  border-radius: var(--radius-sm);
  transition: var(--transition);
  cursor: pointer;
}

.lang-switcher button:hover {
  color: var(--text-secondary);
  background: var(--bg-tertiary);
}

.lang-switcher button.active {
  background: var(--brand);
  color: white;
  box-shadow: 0 2px 8px rgba(37, 99, 235, 0.3);
}

/* Workspace Cards */
.workspace-card {
  background: var(--bg-primary);
  border: 1px solid var(--border);
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-md);
  transition: var(--transition);
  overflow: hidden;
}

.workspace-card:hover {
  box-shadow: var(--shadow-lg);
}

/* Dropzone — Clean & Inviting */
.dropzone-area {
  border: 2px dashed var(--border);
  border-radius: var(--radius-lg);
  padding: 3rem 2rem;
  text-align: center;
  transition: var(--transition);
  background: linear-gradient(180deg, var(--bg-primary) 0%, var(--bg-secondary) 100%);
  cursor: pointer;
}

.dropzone-area:hover,
.dropzone-area.dragging {
  border-color: var(--brand);
  background: linear-gradient(180deg, var(--brand-soft) 0%, var(--bg-secondary) 100%);
  transform: scale(1.01);
}

.dropzone-area.dragging {
  border-style: solid;
  border-width: 2px;
}

.dropzone-icon {
  width: 64px;
  height: 64px;
  background: linear-gradient(135deg, var(--brand-soft), #eff6ff);
  border-radius: var(--radius-lg);
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 1rem;
  font-size: 1.75rem;
  transition: var(--transition);
}

.dropzone-area:hover .dropzone-icon {
  transform: translateY(-4px);
  box-shadow: 0 8px 24px rgba(37, 99, 235, 0.15);
}

.dropzone-text {
  color: var(--text-secondary);
  font-size: 0.95rem;
  margin-bottom: 1.25rem;
}

.dropzone-text strong {
  color: var(--brand);
  font-weight: 600;
}

.btn-primary-custom {
  background: linear-gradient(135deg, var(--brand), var(--brand-dark));
  border: none;
  border-radius: var(--radius-md);
  padding: 0.75rem 2rem;
  font-weight: 600;
  font-size: 0.95rem;
  color: white;
  box-shadow: 0 4px 16px rgba(37, 99, 235, 0.25);
  transition: var(--transition);
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
}

.btn-primary-custom:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(37, 99, 235, 0.35);
}

.preview-area {
  margin-top: 1.5rem;
  min-height: 120px;
  border-radius: var(--radius-md);
  background: var(--bg-secondary);
  border: 1px solid var(--border-light);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-muted);
  font-size: 0.85rem;
}

/* OCR Text Area — Clean Editor */
.editor-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.75rem 1rem;
  background: var(--bg-tertiary);
  border-bottom: 1px solid var(--border);
  border-radius: var(--radius-xl) var(--radius-xl) 0 0;
}

.editor-title {
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--text-secondary);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.font-controls {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.font-btn {
  width: 32px;
  height: 32px;
  border: 1px solid var(--border);
  background: var(--bg-primary);
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  color: var(--text-secondary);
  cursor: pointer;
  transition: var(--transition);
  font-size: 0.85rem;
}

.font-btn:hover {
  background: var(--brand);
  color: white;
  border-color: var(--brand);
}

.font-size-display {
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--text-muted);
  min-width: 36px;
  text-align: center;
}

#textArea {
  background: var(--bg-primary) !important;
  min-height: 380px;
  font-size: 14pt;
  font-family: 'Nokora', sans-serif !important;
  font-weight: 400 !important;
  line-height: 1.7 !important;
  color: var(--text-primary) !important;
  padding: 1.5rem;
  white-space: pre !important;
  overflow-x: auto !important;
  overflow-y: auto !important;
  word-break: keep-all !important;
  word-wrap: normal !important;
  border: none;
  border-radius: 0 0 var(--radius-xl) var(--radius-xl);
  resize: none;
  outline: none;
}

#textArea:focus {
  background: var(--bg-primary) !important;
}

#textArea:empty:before {
  content: attr(placeholder);
  color: var(--text-muted);
  font-style: italic;
}

/* Action Bar */
.action-bar {
  display: flex;
  gap: 0.75rem;
  padding: 1rem;
  background: var(--bg-tertiary);
  border-top: 1px solid var(--border);
  border-radius: 0 0 var(--radius-xl) var(--radius-xl);
}

.btn-secondary-custom {
  background: var(--bg-primary);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 0.65rem 1.25rem;
  font-weight: 600;
  font-size: 0.9rem;
  color: var(--text-secondary);
  transition: var(--transition);
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  flex: 1;
  justify-content: center;
}

.btn-secondary-custom:hover {
  background: var(--bg-tertiary);
  border-color: var(--text-muted);
  color: var(--text-primary);
}

.btn-gemini {
  background: linear-gradient(135deg, var(--gemini), var(--gemini-dark));
  border: none;
  border-radius: var(--radius-md);
  padding: 0.65rem 1.25rem;
  font-weight: 600;
  font-size: 0.9rem;
  color: white;
  box-shadow: 0 4px 16px rgba(79, 70, 229, 0.25);
  transition: var(--transition);
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  flex: 1;
  justify-content: center;
}

.btn-gemini:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(79, 70, 229, 0.35);
}

.btn-gemini:disabled {
  opacity: 0.5;
  cursor: not-allowed;
  transform: none;
}

/* Pro Email Row */
.pro-row {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.75rem 1rem;
  background: var(--bg-secondary);
  border-top: 1px solid var(--border-light);
}

.pro-input {
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 0.5rem 0.75rem;
  font-size: 0.85rem;
  max-width: 220px;
  transition: var(--transition);
  background: var(--bg-primary);
}

.pro-input:focus {
  outline: none;
  border-color: var(--brand);
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}

.credit-badge {
  font-size: 0.75rem;
  padding: 0.35rem 0.75rem;
  border-radius: 50px;
  font-weight: 600;
}

.credit-badge.success {
  background: #d1fae5;
  color: #065f46;
  border: 1px solid #a7f3d0;
}

.credit-badge.danger {
  background: #fee2e2;
  color: #991b1b;
  border: 1px solid #fecaca;
}

/* Gemini Result Card */
.gemini-card {
  background: linear-gradient(135deg, #eef2ff, var(--gemini-soft));
  border: 1px solid var(--gemini-border);
  border-radius: var(--radius-xl);
  overflow: hidden;
  box-shadow: var(--shadow-md);
}

.gemini-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1rem 1.25rem;
  background: rgba(79, 70, 229, 0.06);
  border-bottom: 1px solid var(--gemini-border);
}

.gemini-title {
  font-size: 0.9rem;
  font-weight: 700;
  color: var(--gemini-text);
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.gemini-body {
  padding: 1.25rem;
  background: var(--bg-primary);
}

#geminiTextArea {
  background: var(--bg-primary) !important;
  min-height: 180px;
  font-family: 'Nokora', sans-serif;
  font-size: 14pt;
  line-height: 1.7;
  color: var(--text-primary);
  padding: 0;
  white-space: pre;
  overflow-x: auto;
  overflow-y: auto;
  word-break: keep-all;
  word-wrap: normal;
  border: none;
  outline: none;
  resize: none;
}

/* Status & Progress */
.status-bar {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.75rem;
  color: var(--text-muted);
  font-size: 0.85rem;
}

.spinner-custom {
  width: 18px;
  height: 18px;
  border: 2px solid var(--border);
  border-top-color: var(--brand);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}

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

/* ============================================================
   MARKETING SECTIONS — MODERN & CLEAN
   ============================================================ */

.marketing-divider {
  border: none;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--border), transparent);
  margin: 3rem 0;
}

/* Hero — Modern Light with Subtle Gradients */
.hero-v2 {
  position: relative;
  background: linear-gradient(135deg, #ffffff 0%, #f0f6ff 50%, #ffffff 100%);
  color: var(--text-primary);
  border: 1px solid var(--border);
  border-radius: var(--radius-xl);
  padding: 4rem 3rem;
  overflow: hidden;
  margin: 0;
  box-shadow: var(--shadow-md);
}

.hero-v2::before {
  content: "";
  position: absolute;
  top: -50%;
  right: -20%;
  width: 600px;
  height: 600px;
  background: radial-gradient(circle, rgba(37, 99, 235, 0.08), transparent 70%);
  pointer-events: none;
}

.hero-v2::after {
  content: "";
  position: absolute;
  bottom: -30%;
  left: -10%;
  width: 400px;
  height: 400px;
  background: radial-gradient(circle, rgba(96, 165, 250, 0.07), transparent 70%);
  pointer-events: none;
}

.hero-v2 > * { position: relative; z-index: 1; }

.hero-v2 h1 {
  font-size: 2.5rem;
  font-weight: 800;
  line-height: 1.15;
  letter-spacing: -0.03em;
  margin-bottom: 1rem;
}

.hero-v2 .accent {
  background: linear-gradient(135deg, var(--brand), var(--brand-dark));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.hero-subtitle {
  font-size: 1.15rem;
  color: var(--text-secondary);
  line-height: 1.6;
  max-width: 540px;
  margin-bottom: 0.5rem;
}

.hero-note {
  font-size: 0.9rem;
  color: var(--text-muted);
  margin-bottom: 2rem;
}

.hero-cta {
  display: flex;
  gap: 0.75rem;
  flex-wrap: wrap;
}

.btn-hero-primary {
  background: linear-gradient(135deg, #3b82f6, #2563eb);
  border: none;
  border-radius: var(--radius-md);
  padding: 0.85rem 1.75rem;
  font-weight: 600;
  font-size: 0.95rem;
  color: white;
  box-shadow: 0 4px 20px rgba(37, 99, 235, 0.35);
  transition: var(--transition);
}

.btn-hero-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 28px rgba(37, 99, 235, 0.45);
}

.btn-hero-secondary {
  background: var(--bg-primary);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 0.85rem 1.5rem;
  font-weight: 600;
  font-size: 0.95rem;
  color: var(--text-secondary);
  transition: var(--transition);
}

.btn-hero-secondary:hover {
  background: rgba(37, 99, 235, 0.06);
  border-color: var(--brand-light);
  color: var(--brand);
}

/* KPI Cards — Clean Light */
.kpi-v2 {
  background: var(--bg-primary);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 1.5rem;
  height: 100%;
  transition: var(--transition);
  box-shadow: var(--shadow-sm);
}

.kpi-v2:hover {
  border-color: var(--brand-light);
  box-shadow: var(--shadow-lg);
  transform: translateY(-4px);
}

.kpi-icon {
  width: 40px;
  height: 40px;
  background: linear-gradient(135deg, var(--brand-soft), #eff6ff);
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.1rem;
  margin-bottom: 0.75rem;
}

.kpi-title-v2 {
  font-weight: 700;
  font-size: 1rem;
  color: var(--text-primary);
  margin-bottom: 0.25rem;
}

.kpi-desc-v2 {
  color: var(--text-secondary);
  font-size: 0.85rem;
  line-height: 1.5;
}

/* Section Styles */
.section-v2 {
  padding: 4rem 0;
}

.section-header {
  margin-bottom: 2rem;
}

.section-label {
  display: inline-block;
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--brand);
  background: var(--brand-soft);
  padding: 0.35rem 0.75rem;
  border-radius: 50px;
  margin-bottom: 0.75rem;
}

.section-title-v2 {
  font-size: 1.75rem;
  font-weight: 800;
  color: var(--text-primary);
  letter-spacing: -0.02em;
  line-height: 1.2;
}

.section-desc {
  color: var(--text-secondary);
  font-size: 1rem;
  line-height: 1.6;
  max-width: 600px;
}

/* Feature Cards — Clean White */
.feature-card {
  background: var(--bg-primary);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 1.75rem;
  height: 100%;
  transition: var(--transition);
}

.feature-card:hover {
  border-color: var(--brand-light);
  box-shadow: var(--shadow-lg);
  transform: translateY(-4px);
}

.feature-icon {
  width: 48px;
  height: 48px;
  background: linear-gradient(135deg, var(--brand-soft), #eff6ff);
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.25rem;
  margin-bottom: 1rem;
  transition: var(--transition);
}

.feature-card:hover .feature-icon {
  background: linear-gradient(135deg, var(--brand), var(--brand-dark));
  color: white;
  transform: scale(1.1) rotate(-4deg);
}

.feature-title {
  font-weight: 700;
  font-size: 1rem;
  color: var(--text-primary);
  margin-bottom: 0.4rem;
}

.feature-desc {
  color: var(--text-secondary);
  font-size: 0.9rem;
  line-height: 1.5;
}

/* Compare Section */
.compare-v2 {
  background: var(--bg-primary);
  border: 1px solid var(--border);
  border-radius: var(--radius-xl);
  padding: 2rem;
  box-shadow: var(--shadow-md);
}

.compare-card-v2 {
  background: var(--bg-secondary);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-lg);
  padding: 1.5rem;
  height: 100%;
  transition: var(--transition);
}

.compare-card-v2:hover {
  box-shadow: var(--shadow-md);
}

.compare-winner-v2 {
  background: linear-gradient(135deg, #ecfdf5, #d1fae5);
  border: 2px solid #6ee7b7;
  position: relative;
}

.compare-winner-v2::after {
  content: "✓ Winner";
  position: absolute;
  top: 0.75rem;
  right: 0.75rem;
  font-size: 0.7rem;
  font-weight: 700;
  color: #065f46;
  background: #6ee7b7;
  padding: 0.2rem 0.6rem;
  border-radius: 50px;
}

.compare-badge {
  display: inline-block;
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  padding: 0.25rem 0.6rem;
  border-radius: 50px;
  margin-bottom: 0.75rem;
}

.badge-traditional {
  background: #fee2e2;
  color: #991b1b;
}

.badge-vision {
  background: #d1fae5;
  color: #065f46;
}

/* Language Badges */
.lang-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.lang-badge-v2 {
  background: var(--bg-primary);
  border: 1px solid var(--border);
  border-radius: 50px;
  padding: 0.5rem 1rem;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-secondary);
  transition: var(--transition);
}

.lang-badge-v2:hover {
  border-color: var(--brand-light);
  color: var(--brand);
  transform: translateY(-2px);
  box-shadow: var(--shadow-sm);
}

.lang-badge-v2.core {
  background: linear-gradient(135deg, #d1fae5, #a7f3d0);
  border-color: #6ee7b7;
  color: #065f46;
}

.lang-badge-v2.active-lang {
  background: linear-gradient(135deg, var(--brand-soft), #dbeafe);
  border-color: var(--brand-light);
  color: var(--brand-dark);
}

/* Use Cases — Bento Grid */
.bento-v2 {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 1rem;
}

.bento-item {
  background: var(--bg-primary);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 1.5rem;
  transition: var(--transition);
  position: relative;
  overflow: hidden;
}

.bento-item::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: linear-gradient(90deg, var(--brand), var(--brand-light));
  opacity: 0;
  transition: opacity 0.3s ease;
}

.bento-item:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-lg);
  border-color: var(--brand-light);
}

.bento-item:hover::before { opacity: 1; }

.bento-item.wide {
  grid-column: span 2;
}

@media (max-width: 768px) {
  .bento-item.wide { grid-column: span 1; }
}

.bento-icon {
  width: 44px;
  height: 44px;
  background: linear-gradient(135deg, var(--brand-soft), #eff6ff);
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.25rem;
  margin-bottom: 0.75rem;
}

/* Case Study Stats */
.stat-box {
  display: inline-flex;
  align-items: baseline;
  gap: 0.5rem;
}

.stat-number-v2 {
  font-size: 2.5rem;
  font-weight: 800;
  line-height: 1;
}

.stat-number-v2.success {
  background: linear-gradient(135deg, #10b981, #059669);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.stat-number-v2.danger {
  background: linear-gradient(135deg, #ef4444, #dc2626);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.stat-label-v2 {
  font-size: 0.9rem;
  color: var(--text-muted);
}

/* Contact */
.contact-v2 {
  background: var(--bg-primary);
  border: 1px solid var(--border);
  border-radius: var(--radius-xl);
  padding: 2rem;
  box-shadow: var(--shadow-md);
}

.contact-item-v2 {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 0.875rem;
  border-radius: var(--radius-md);
  transition: var(--transition);
}

.contact-item-v2:hover {
  background: var(--bg-secondary);
}

.contact-icon-v2 {
  width: 44px;
  height: 44px;
  background: linear-gradient(135deg, var(--brand-soft), #eff6ff);
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.1rem;
  flex-shrink: 0;
  transition: var(--transition);
}

.contact-item-v2:hover .contact-icon-v2 {
  background: linear-gradient(135deg, var(--brand), var(--brand-dark));
  color: white;
}

/* Scroll Reveal */
.reveal-v2 {
  opacity: 0;
  transform: translateY(30px);
  transition: all 0.7s cubic-bezier(0.4, 0, 0.2, 1);
}

.reveal-v2.active {
  opacity: 1;
  transform: translateY(0);
}

/* Responsive */
@media (max-width: 768px) {
  .hero-v2 { padding: 2.5rem 1.5rem; }
  .hero-v2 h1 { font-size: 1.75rem; }
  .workspace-title { font-size: 1.25rem; }
  .section-title-v2 { font-size: 1.4rem; }
  .stat-number-v2 { font-size: 2rem; }
}

/* ============================================================
   PRICING PAGE
   ============================================================ */

/* Page Header — Light, matches hero-v2 */
.pricing-header {
  position: relative;
  background: linear-gradient(135deg, #ffffff 0%, #f0f6ff 50%, #ffffff 100%);
  border: 1px solid var(--border);
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-md);
  color: var(--text-primary);
  padding: 3rem 2rem;
  text-align: center;
  margin-bottom: 3rem;
  overflow: hidden;
}

.pricing-header::before {
  content: "";
  position: absolute;
  top: -60%;
  right: -15%;
  width: 500px;
  height: 500px;
  background: radial-gradient(circle, rgba(37, 99, 235, 0.08), transparent 70%);
  pointer-events: none;
}

.pricing-header > * { position: relative; z-index: 1; }

.pricing-header h1 {
  font-weight: 800;
  letter-spacing: -0.02em;
}

.pricing-header p {
  color: var(--text-secondary);
  max-width: 46rem;
  margin: 0.75rem auto 0;
}

/* Plan Cards */
.plan-card {
  background: var(--bg-primary);
  border: 1px solid var(--border);
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-md);
  padding: 2.25rem 1.75rem;
  height: 100%;
  display: flex;
  flex-direction: column;
  transition: var(--transition);
}

.plan-card:hover {
  transform: translateY(-4px);
  border-color: var(--brand-light);
  box-shadow: var(--shadow-lg);
}

.plan-card.featured {
  border: 2px solid var(--brand);
  position: relative;
}

.badge-featured {
  position: absolute;
  top: -14px;
  left: 50%;
  transform: translateX(-50%);
  background: linear-gradient(135deg, var(--brand), var(--brand-dark));
  color: #fff;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.5px;
  padding: 0.3rem 0.95rem;
  border-radius: 999px;
  white-space: nowrap;
  box-shadow: 0 4px 12px rgba(37, 99, 235, 0.3);
}

.plan-name {
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 0.35rem;
}

.plan-price {
  font-size: 2.6rem;
  font-weight: 800;
  line-height: 1;
  color: var(--text-primary);
}

.plan-price sup {
  font-size: 1.2rem;
  font-weight: 700;
  vertical-align: super;
  line-height: 1;
}

.plan-price .per {
  font-size: 0.95rem;
  font-weight: 500;
  color: var(--text-muted);
}

.plan-price.custom {
  font-size: 2rem;
  color: var(--brand);
}

.plan-desc {
  font-size: 0.92rem;
  color: var(--text-secondary);
  margin: 0.6rem 0 1.4rem;
}

.plan-divider {
  border: none;
  border-top: 1px solid var(--border-light);
  margin: 1.2rem 0;
}

.feature-list {
  list-style: none;
  padding: 0;
  margin: 0 0 1.75rem;
  flex: 1;
}

.feature-list li {
  display: flex;
  align-items: flex-start;
  gap: 0.55rem;
  font-size: 0.93rem;
  color: var(--text-secondary);
  margin-bottom: 0.65rem;
}

.feature-list li .ico {
  flex-shrink: 0;
  margin-top: 2px;
}

.ico-yes { color: var(--success); }
.ico-no  { color: var(--text-muted); opacity: 0.5; }

.plan-cta .btn {
  border-radius: 999px;
  font-weight: 600;
  padding: 0.65rem 1.4rem;
  width: 100%;
}

/* Enterprise Banner — Light */
.enterprise-banner {
  position: relative;
  background: linear-gradient(135deg, var(--brand-soft) 0%, #eff6ff 60%, #ffffff 100%);
  border: 1px solid var(--brand-light);
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-md);
  padding: 2.75rem 2rem;
  color: var(--text-primary);
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 1.5rem;
  justify-content: space-between;
  overflow: hidden;
}

.enterprise-banner::before {
  content: "";
  position: absolute;
  top: -40%;
  right: -10%;
  width: 400px;
  height: 400px;
  background: radial-gradient(circle, rgba(37, 99, 235, 0.1), transparent 70%);
  pointer-events: none;
}

.enterprise-banner > * { position: relative; z-index: 1; }

.enterprise-banner h3 {
  font-weight: 800;
  margin: 0 0 0.4rem;
  color: var(--text-primary);
}

.enterprise-banner p {
  color: var(--text-secondary);
  margin: 0;
  font-size: 0.95rem;
}

.enterprise-features {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 0.85rem;
  margin-top: 0.9rem;
}

.enterprise-features span {
  font-size: 0.83rem;
  color: var(--text-secondary);
  display: flex;
  align-items: center;
  gap: 0.3rem;
}

.enterprise-features span::before {
  content: "✓";
  color: var(--brand);
  font-weight: 700;
}

.enterprise-contact-email {
  color: var(--text-muted);
  font-size: 0.83rem;
}

/* FAQ */
.faq-title {
  font-weight: 800;
  color: var(--text-primary);
  border-left: 5px solid var(--brand);
  padding-left: 14px;
  margin-bottom: 1.5rem;
}

.accordion-button:not(.collapsed) {
  color: var(--brand);
  background: var(--brand-soft);
}

.accordion-button:focus {
  box-shadow: 0 0 0 0.2rem rgba(37, 99, 235, 0.15);
}

/* ============================================================
   AI TRAINER PAGE
   ============================================================ */

/* Section title with brand bar (shared pattern with .faq-title) */
.section-title-bar {
  font-weight: 800;
  color: var(--text-primary);
  border-left: 5px solid var(--brand);
  padding-left: 14px;
  margin-bottom: 1rem;
}

/* Soft white card */
.card-soft {
  background: var(--bg-primary);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-md);
}

/* Simple comparison box */
.compare-box {
  background: var(--bg-tertiary);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 1.75rem 1.25rem;
}

.compare-box .muted {
  color: var(--text-secondary);
}

/* Trainer Cards */
.trainer-card {
  background: var(--bg-primary);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-md);
  padding: 1.75rem;
  height: 100%;
  transition: var(--transition);
}

.trainer-card:hover {
  transform: translateY(-3px);
  border-color: var(--brand-light);
  box-shadow: var(--shadow-lg);
}

.trainer-avatar {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 1.25rem;
  color: #fff;
  background: linear-gradient(135deg, var(--brand), var(--brand-dark));
  box-shadow: 0 4px 12px rgba(37, 99, 235, 0.25);
  flex: none;
}

.trainer-name {
  font-weight: 700;
  font-size: 1.1rem;
  color: var(--text-primary);
}

.trainer-role {
  color: var(--brand-dark);
  font-weight: 600;
  font-size: 0.9rem;
}

.trainer-desc {
  color: var(--text-secondary);
  font-size: 0.95rem;
}

#contact a {
  word-break: break-word;
}

/* ============================================================
   CASE STUDY PAGES
   ============================================================ */

/* Generic muted text (light theme) */
.muted { color: var(--text-secondary); }

/* Hero extras */
.hero-meta {
  color: var(--text-muted);
  font-size: 0.9rem;
}

.hero-badge {
  background: var(--brand-soft);
  color: var(--brand-dark);
  border: 1px solid var(--brand-light);
}

/* KPI stat variant (number + label, inside .kpi-v2) */
.kpi-value {
  font-size: 2.2rem;
  font-weight: 800;
  color: var(--brand);
  line-height: 1;
}

.kpi-label {
  color: var(--text-secondary);
  font-size: 0.92rem;
  margin-top: 0.3rem;
}

/* Comparison Table */
.compare-table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
  border-radius: var(--radius-md);
  overflow: hidden;
  font-size: 0.95rem;
}

.compare-table thead th {
  background: var(--brand-soft);
  color: var(--text-primary);
  font-weight: 700;
  padding: 0.85rem 1rem;
  border-bottom: 2px solid var(--brand-light);
  text-align: left;
}

.compare-table tbody tr:nth-child(even) td {
  background: var(--bg-secondary);
}

.compare-table tbody td {
  padding: 0.8rem 1rem;
  border-bottom: 1px solid var(--border-light);
  vertical-align: top;
}

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

.text-success-dark { color: var(--success-text); }
.text-danger-dark  { color: var(--danger-text); }

.badge-result-good {
  display: inline-block;
  background: var(--success-soft);
  color: var(--success-text);
  border-radius: 6px;
  padding: 2px 8px;
  font-size: 0.82rem;
  font-weight: 700;
}

.badge-result-bad {
  display: inline-block;
  background: var(--danger-soft);
  color: var(--danger-text);
  border-radius: 6px;
  padding: 2px 8px;
  font-size: 0.82rem;
  font-weight: 700;
}

/* Result big numbers */
.result-number {
  font-size: 3rem;
  font-weight: 800;
  line-height: 1;
}

.result-number.good { color: var(--success-text); }
.result-number.bad  { color: var(--danger-text); }

/* Verdict Block — Light */
.verdict {
  position: relative;
  background: linear-gradient(135deg, var(--brand-soft) 0%, #eff6ff 60%, #ffffff 100%);
  border: 1px solid var(--brand-light);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-md);
  color: var(--text-primary);
  padding: 2rem 2rem;
  overflow: hidden;
}

.verdict::before {
  content: "";
  position: absolute;
  top: -40%;
  right: -10%;
  width: 400px;
  height: 400px;
  background: radial-gradient(circle, rgba(37, 99, 235, 0.1), transparent 70%);
  pointer-events: none;
}

.verdict > * { position: relative; z-index: 1; }

.verdict h3 { color: var(--text-primary); }

.verdict p { color: var(--text-secondary); }

.verdict .accent {
  color: var(--brand);
}

.verdict .accent-bad {
  color: var(--danger-text);
  font-weight: 700;
}

/* Khmer font hint */
.kh { font-family: 'Nokora', sans-serif; }

/* Image Comparison Panels */
.img-panel {
  border-radius: var(--radius-md);
  overflow: hidden;
  border: 1px solid var(--border);
  box-shadow: var(--shadow-md);
  background: var(--bg-primary);
}

.img-panel img {
  width: 100%;
  display: block;
}

.img-panel-label {
  padding: 0.65rem 1rem;
  font-weight: 600;
  font-size: 0.88rem;
  border-top: 1px solid var(--border-light);
}

.img-panel-label.good    { background: #f0fdf4; color: var(--success-text); }
.img-panel-label.bad     { background: #fef2f2; color: var(--danger-text); }
.img-panel-label.neutral { background: var(--brand-soft); color: var(--brand-dark); }
