@import url('https://fonts.googleapis.com/css2?family=JetBrains+Mono:wght@500;600;700&family=Noto+Sans+Devanagari:wght@400;500;600;700;800&family=Plus+Jakarta+Sans:wght@400;500;600;700;800&display=swap');

:root {
  /* MandiKhata Official Brand Palette (from lib/theme.ts & Brand Logo) */
  --color-primary: #F59E0B;          /* Marigold Gold */
  --color-primary-dark: #D97706;     /* Deep Marigold */
  --color-primary-deep: #92400E;     /* Amber Ink */
  --color-cream: #FFFBEB;            /* Marigold Soft Cream */
  --color-badge-bg: #FEF3C7;         /* Warm Gold Badge Fill */

  --color-crimson: #DC2626;          /* Bahi-Khata Crimson */
  --color-crimson-dark: #B91C1C;     /* Deep Ledger Red */
  --color-crimson-light: #FEF2F2;    /* Soft Naam/Debit Tint */

  --color-emerald: #15803D;          /* Mandi APMC Emerald */
  --color-emerald-dark: #166534;     /* Deep Forest Emerald */
  --color-emerald-deep: #0F2E1E;     /* Official APMC Crest Green */
  --color-emerald-light: #DCFCE7;    /* Verified Jama/Credit Tint */

  --color-navy: #0F172A;             /* Logo Rounded-Square Deep Slate */
  --color-navy-elevated: #1E293B;    /* Dark Card Surface */
  --color-navy-border: #334155;      /* Dark Hairline */

  /* Light Mode Surfaces */
  --color-bg: #F8FAFC;
  --color-surface: #FFFFFF;
  --color-surface-mandi: #FAF9F5;    /* Warm Bahi Parchment */
  --color-text: #0F172A;
  --color-text-secondary: #475569;   /* WCAG AA+ 7.2:1 on white */
  --color-text-muted: #64748B;
  --color-border: #E2E8F0;
  --color-border-mandi: #E4DEC9;

  /* Typography */
  --font-sans: 'Plus Jakarta Sans', 'Noto Sans Devanagari', -apple-system, BlinkMacSystemFont, sans-serif;
  --font-hindi: 'Noto Sans Devanagari', 'Plus Jakarta Sans', sans-serif;
  --font-mono: 'JetBrains Mono', monospace;

  /* Spacing Scale (Density 4/10 Standard) */
  --space-xs: 0.25rem;
  --space-sm: 0.5rem;
  --space-md: 1rem;
  --space-lg: 1.5rem;
  --space-xl: 2rem;
  --space-2xl: 3rem;
  --space-3xl: 4.5rem;
  --space-4xl: 6rem;

  /* Radii & Shadows (Bento + Soft UI Evolution) */
  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 16px;
  --radius-xl: 24px;
  --radius-full: 9999px;

  --shadow-xs: 0 1px 2px rgba(15, 23, 42, 0.04);
  --shadow-sm: 0 2px 6px -1px rgba(15, 23, 42, 0.06), 0 1px 3px -1px rgba(15, 23, 42, 0.04);
  --shadow-md: 0 10px 25px -5px rgba(15, 23, 42, 0.07), 0 4px 10px -2px rgba(15, 23, 42, 0.04);
  --shadow-lg: 0 20px 40px -12px rgba(15, 23, 42, 0.12), 0 8px 16px -4px rgba(15, 23, 42, 0.05);
  --shadow-xl: 0 28px 60px -15px rgba(15, 23, 42, 0.22);
  --shadow-gold: 0 10px 25px -4px rgba(245, 158, 11, 0.32);

  --transition-fast: 180ms cubic-bezier(0.16, 1, 0.3, 1);
  --transition-base: 260ms cubic-bezier(0.16, 1, 0.3, 1);
}

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

html {
  scroll-behavior: smooth;
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

html[lang="hi"] body {
  font-family: var(--font-hindi);
  line-height: 1.65;
}

body {
  font-family: var(--font-sans);
  background-color: var(--color-bg);
  color: var(--color-text);
  line-height: 1.6;
  overflow-x: hidden;
}

/* Focus Accessibility (WCAG 2.2 Focus Not Obscured) */
:focus-visible {
  outline: 3px solid var(--color-primary-dark);
  outline-offset: 3px;
}

a {
  color: inherit;
  text-decoration: none;
}

button {
  font-family: inherit;
  cursor: pointer;
  border: none;
  background: none;
}

img {
  max-width: 100%;
  display: block;
}

.container {
  width: 100%;
  max-width: 1240px;
  margin: 0 auto;
  padding: 0 1.5rem;
}

.mono {
  font-family: var(--font-mono);
}

/* Keep section headings clear of the sticky header when jumping from the menu */
section[id] {
  scroll-margin-top: 64px;
}

/* ==========================================================================
   1. STICKY GLASSMORPHISM NAVBAR
   ========================================================================== */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(255, 255, 255, 0.86);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid rgba(226, 232, 240, 0.85);
  transition: box-shadow var(--transition-base);
}

.site-header.scrolled {
  box-shadow: var(--shadow-sm);
}

.nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 76px;
  gap: 1.25rem;
}

.brand-link {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  font-weight: 800;
  font-size: 1.25rem;
  letter-spacing: -0.02em;
  color: var(--color-navy);
}

.brand-logo-img {
  width: 44px;
  height: 44px;
  border-radius: 11px;
  object-fit: cover;
  box-shadow: 0 2px 8px rgba(15, 23, 42, 0.14);
}

.brand-text-wrap {
  display: flex;
  flex-direction: column;
  line-height: 1.15;
}

.brand-title {
  display: flex;
  align-items: center;
  gap: 0.35rem;
  font-size: 1.25rem;
  font-weight: 800;
}

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

.brand-sub-pill {
  font-size: 0.68rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--color-emerald);
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 2rem;
  list-style: none;
}

.nav-links a {
  white-space: nowrap;
  font-size: 0.9375rem;
  font-weight: 600;
  color: var(--color-text-secondary);
  transition: color var(--transition-fast);
  padding: 0.35rem 0;
  position: relative;
}

.nav-links a:hover {
  color: var(--color-navy);
}

.nav-links a::after {
  content: '';
  position: absolute;
  left: 0;
  bottom: -2px;
  width: 0;
  height: 2px;
  background: var(--color-primary);
  transition: width var(--transition-base);
}

.nav-links a:hover::after {
  width: 100%;
}

.nav-actions {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

/* Segmented Pure English / Pure Hindi Switcher */
.lang-switcher {
  display: inline-flex;
  align-items: center;
  background: #F1F5F9;
  border: 1px solid var(--color-border);
  padding: 3px;
  border-radius: var(--radius-full);
  gap: 2px;
}

.lang-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.38rem 0.85rem;
  border-radius: var(--radius-full);
  font-size: 0.825rem;
  font-weight: 700;
  color: var(--color-text-secondary);
  transition: all var(--transition-fast);
}

.lang-btn.active {
  background: var(--color-navy);
  color: #FFFFFF;
  box-shadow: 0 2px 6px rgba(15, 23, 42, 0.18);
}

.lang-btn:not(.active):hover {
  color: var(--color-navy);
  background: rgba(255, 255, 255, 0.6);
}

/* Primary Buttons (WCAG AAA 9.1:1 #0F172A on #F59E0B) */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  font-weight: 700;
  font-size: 0.9375rem;
  padding: 0.72rem 1.35rem;
  border-radius: var(--radius-md);
  transition: all var(--transition-fast);
  cursor: pointer;
  white-space: nowrap;
}

.btn-primary {
  background: var(--color-primary);
  color: var(--color-navy);
  box-shadow: 0 2px 8px rgba(245, 158, 11, 0.25);
  border: 1px solid rgba(217, 119, 6, 0.3);
}

.btn-primary:hover {
  background: #FBBF24;
  transform: translateY(-1px);
  box-shadow: var(--shadow-gold);
}

.btn-navy {
  background: var(--color-navy);
  color: #FFFFFF;
  border: 1px solid var(--color-navy);
}

.btn-navy:hover {
  background: var(--color-navy-elevated);
  transform: translateY(-1px);
  box-shadow: var(--shadow-md);
}

.btn-outline {
  background: var(--color-surface);
  color: var(--color-navy);
  border: 1.5px solid var(--color-border);
}

.btn-outline:hover {
  border-color: var(--color-navy);
  background: #F8FAFC;
  transform: translateY(-1px);
}

.btn-lg {
  padding: 0.9rem 1.75rem;
  font-size: 1rem;
  border-radius: 14px;
}

/* ==========================================================================
   2. HERO SECTION (Enterprise Agri-Fintech Showcase)
   ========================================================================== */
.hero-section {
  position: relative;
  padding: 4.5rem 0 5rem;
  overflow: hidden;
  background:
    radial-gradient(circle at 12% 18%, rgba(245, 158, 11, 0.14) 0%, transparent 42%),
    radial-gradient(circle at 88% 22%, rgba(21, 128, 61, 0.10) 0%, transparent 40%),
    radial-gradient(circle at 50% 85%, rgba(220, 38, 38, 0.06) 0%, transparent 45%),
    linear-gradient(180deg, #FFFFFF 0%, #F8FAFC 100%);
  border-bottom: 1px solid var(--color-border);
}

.hero-grid {
  display: grid;
  grid-template-columns: 1.08fr 0.92fr;
  gap: 3.5rem;
  align-items: center;
}

.apmc-trust-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  background: var(--color-emerald-light);
  color: var(--color-emerald-deep);
  border: 1px solid rgba(21, 128, 61, 0.25);
  padding: 0.4rem 0.95rem;
  border-radius: var(--radius-full);
  font-size: 0.8125rem;
  font-weight: 700;
  margin-bottom: 1.35rem;
}

.live-pulse-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--color-emerald);
  box-shadow: 0 0 0 4px rgba(21, 128, 61, 0.2);
}

.hero-title {
  font-size: clamp(2.35rem, 4.2vw, 3.6rem);
  font-weight: 800;
  line-height: 1.12;
  letter-spacing: -0.03em;
  color: var(--color-navy);
  margin-bottom: 1.25rem;
}

html[lang="hi"] .hero-title {
  line-height: 1.25;
  letter-spacing: -0.01em;
}

.hero-highlight-gold {
  background: linear-gradient(120deg, #D97706 0%, #DC2626 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.hero-subtitle {
  font-size: 1.125rem;
  color: var(--color-text-secondary);
  max-width: 580px;
  margin-bottom: 2rem;
  line-height: 1.68;
}

.hero-cta-group {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 1rem;
  margin-bottom: 2.5rem;
}

.hero-metrics-bar {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.25rem;
  padding-top: 1.75rem;
  border-top: 1px solid var(--color-border);
}

.hero-metric-item {
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
}

.hero-metric-val {
  font-size: 1.5rem;
  font-weight: 800;
  color: var(--color-navy);
  font-family: var(--font-mono);
  letter-spacing: -0.02em;
}

.hero-metric-label {
  font-size: 0.8125rem;
  font-weight: 600;
  color: var(--color-text-secondary);
}

@keyframes fadeSlideUp {
  from {
    opacity: 0;
    transform: translateY(6px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.gaddi-header-strip {
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: var(--color-emerald-deep);
  color: #FFFFFF;
  padding: 0.85rem 1rem;
  border-radius: 12px;
  margin-bottom: 0.9rem;
}

.gaddi-firm-name {
  font-size: 0.92rem;
  font-weight: 700;
}

.gaddi-firm-meta {
  font-size: 0.75rem;
  color: #A7F3D0;
}

.gaddi-code-badge {
  background: rgba(245, 158, 11, 0.2);
  border: 1px solid var(--color-primary);
  color: #FDE68A;
  font-family: var(--font-mono);
  font-size: 0.72rem;
  font-weight: 700;
  padding: 0.25rem 0.55rem;
  border-radius: 6px;
}

.bahi-summary-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.6rem;
  margin-bottom: 0.9rem;
}

.bahi-stat-box {
  background: #FFFFFF;
  border: 1px solid var(--color-border);
  border-radius: 10px;
  padding: 0.65rem 0.7rem;
}

.bahi-stat-label {
  font-size: 0.7rem;
  font-weight: 600;
  color: var(--color-text-secondary);
  margin-bottom: 0.2rem;
}

.bahi-stat-value {
  font-family: var(--font-mono);
  font-size: 0.95rem;
  font-weight: 800;
}

.val-crimson { color: var(--color-crimson); }
.val-emerald { color: var(--color-emerald); }
.val-navy { color: var(--color-navy); }

/* Passbook Row Card */
.passbook-entry-card {
  background: #FFFFFF;
  border: 1px solid var(--color-border);
  border-radius: 12px;
  padding: 0.85rem;
  margin-bottom: 0.65rem;
}

.passbook-entry-card:last-child {
  margin-bottom: 0;
}

.passbook-top-row {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 0.5rem;
}

.passbook-party-title {
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--color-navy);
}

.passbook-party-sub {
  font-size: 0.73rem;
  color: var(--color-text-secondary);
}

.passbook-amount-pill {
  font-family: var(--font-mono);
  font-size: 0.82rem;
  font-weight: 800;
  padding: 0.2rem 0.55rem;
  border-radius: 6px;
}

.pill-debit {
  background: var(--color-crimson-light);
  color: var(--color-crimson);
}

.pill-credit {
  background: var(--color-emerald-light);
  color: var(--color-emerald);
}

.passbook-actions-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.45rem 0;
  border-top: 1px dashed var(--color-border);
  font-size: 0.74rem;
}

.vehicle-chip {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  background: #F1F5F9;
  color: var(--color-navy);
  font-family: var(--font-mono);
  font-weight: 600;
  padding: 0.2rem 0.5rem;
  border-radius: 5px;
}

.bilty-tag {
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
  color: var(--color-primary-deep);
  background: var(--color-badge-bg);
  font-weight: 700;
  padding: 0.2rem 0.55rem;
  border-radius: 5px;
}

.running-bal-strip {
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: var(--color-surface-mandi);
  border: 1px solid var(--color-border-mandi);
  border-radius: 8px;
  padding: 0.4rem 0.65rem;
  margin-top: 0.35rem;
  font-size: 0.74rem;
  font-weight: 700;
}

/* Timeline Milestone UI inside Mockup */
.timeline-stage-list {
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
}

.timeline-stage-item {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
  background: #FFFFFF;
  border: 1px solid var(--color-border);
  border-radius: 10px;
  padding: 0.75rem;
}

.stage-icon-badge {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.stage-done {
  background: var(--color-emerald-light);
  color: var(--color-emerald);
}

.stage-transit {
  background: var(--color-badge-bg);
  color: var(--color-primary-deep);
}

/* ==========================================================================
   3. SECTION HEADERS & COMMON LAYOUT
   ========================================================================== */
.section {
  padding: 5.5rem 0;
}

.section-alt {
  background: #FFFFFF;
  border-top: 1px solid var(--color-border);
  border-bottom: 1px solid var(--color-border);
}

.section-parchment {
  background: var(--color-surface-mandi);
  border-top: 1px solid var(--color-border-mandi);
  border-bottom: 1px solid var(--color-border-mandi);
}

.section-header {
  max-width: 720px;
  margin: 0 auto 3.5rem;
  text-align: center;
}

.section-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  font-size: 0.8rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--color-primary-deep);
  background: var(--color-badge-bg);
  border: 1px solid rgba(245, 158, 11, 0.35);
  padding: 0.32rem 0.85rem;
  border-radius: var(--radius-full);
  margin-bottom: 0.9rem;
}

.section-title {
  font-size: clamp(1.85rem, 3vw, 2.6rem);
  font-weight: 800;
  color: var(--color-navy);
  letter-spacing: -0.025em;
  line-height: 1.18;
  margin-bottom: 0.9rem;
}

html[lang="hi"] .section-title {
  line-height: 1.3;
  letter-spacing: 0;
}

.section-desc {
  font-size: 1.0625rem;
  color: var(--color-text-secondary);
  line-height: 1.65;
}

/* ==========================================================================
   4. BENTO BOX GRID — CORE PRODUCT ARCHITECTURE
   ========================================================================== */
.bento-grid {
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  gap: 1.5rem;
}

.bento-card {
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-xl);
  padding: 2rem;
  box-shadow: var(--shadow-sm);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  transition: transform var(--transition-base), box-shadow var(--transition-base), border-color var(--transition-base);
  position: relative;
  overflow: hidden;
}

.bento-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-lg);
  border-color: #CBD5E1;
}

.bento-span-7 { grid-column: span 7; }
.bento-span-5 { grid-column: span 5; }
.bento-span-4 { grid-column: span 4; }
.bento-span-8 { grid-column: span 8; }

.bento-card-dark {
  background: var(--color-navy);
  color: #F8FAFC;
  border-color: var(--color-navy-border);
}

.bento-card-dark .bento-desc {
  color: #CBD5E1;
}

.bento-icon-wrap {
  width: 48px;
  height: 48px;
  border-radius: 14px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 1.25rem;
}

.icon-crimson {
  background: var(--color-crimson-light);
  color: var(--color-crimson);
  border: 1px solid rgba(220, 38, 38, 0.2);
}

.icon-gold {
  background: var(--color-badge-bg);
  color: var(--color-primary-deep);
  border: 1px solid rgba(245, 158, 11, 0.35);
}

.icon-emerald {
  background: var(--color-emerald-light);
  color: var(--color-emerald);
  border: 1px solid rgba(21, 128, 61, 0.25);
}

.icon-navy {
  background: rgba(245, 158, 11, 0.16);
  color: var(--color-primary);
  border: 1px solid rgba(245, 158, 11, 0.35);
}

.bento-tag {
  display: inline-block;
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 0.45rem;
  color: var(--color-text-muted);
}

.bento-card-dark .bento-tag {
  color: var(--color-primary);
}

.bento-title {
  font-size: 1.35rem;
  font-weight: 800;
  margin-bottom: 0.65rem;
  line-height: 1.28;
}

.bento-desc {
  font-size: 0.95rem;
  color: var(--color-text-secondary);
  margin-bottom: 1.5rem;
  line-height: 1.6;
}

/* Micro-visuals inside Bento Cards */
.bento-micro-ui {
  background: var(--color-bg);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  padding: 1rem;
  margin-top: auto;
}

.bento-card-dark .bento-micro-ui {
  background: var(--color-navy-elevated);
  border-color: var(--color-navy-border);
}

.aging-bar-track {
  height: 10px;
  border-radius: 999px;
  background: #E2E8F0;
  display: flex;
  overflow: hidden;
  gap: 2px;
  margin: 0.6rem 0;
}

.aging-seg-green { width: 58%; background: var(--color-emerald); }
.aging-seg-gold  { width: 27%; background: var(--color-primary); }
.aging-seg-red   { width: 15%; background: var(--color-crimson); }

.aging-legend {
  display: flex;
  justify-content: space-between;
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--color-text-secondary);
}

.unit-chip-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
}

.unit-pill {
  background: #FFFFFF;
  border: 1px solid var(--color-border);
  border-radius: 8px;
  padding: 0.35rem 0.65rem;
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--color-navy);
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
}

.unit-pill span.mono {
  color: var(--color-primary-deep);
  background: var(--color-badge-bg);
  padding: 0.1rem 0.35rem;
  border-radius: 4px;
  font-size: 0.72rem;
}

/* ==========================================================================
   5. INTERACTIVE ROLE ECOSYSTEM SWITCHER (3 ROLES)
   ========================================================================== */
.role-tabs-nav {
  display: flex;
  justify-content: center;
  gap: 0.75rem;
  margin-bottom: 2.5rem;
  flex-wrap: wrap;
}

.role-tab-trigger {
  display: inline-flex;
  align-items: center;
  gap: 0.65rem;
  padding: 0.9rem 1.5rem;
  background: #FFFFFF;
  border: 1.5px solid var(--color-border);
  border-radius: var(--radius-lg);
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--color-text-secondary);
  transition: all var(--transition-fast);
  box-shadow: var(--shadow-xs);
}

.role-tab-trigger:hover {
  border-color: var(--color-navy);
  color: var(--color-navy);
}

.role-tab-trigger.active {
  background: var(--color-navy);
  color: #FFFFFF;
  border-color: var(--color-navy);
  box-shadow: var(--shadow-md);
}

.role-tab-trigger.active .role-tab-dot {
  background: var(--color-primary);
}

.role-tab-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: #CBD5E1;
}

.role-panel {
  display: none;
  background: #FFFFFF;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-xl);
  padding: 2.5rem;
  box-shadow: var(--shadow-md);
}

.role-panel.active {
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  gap: 3rem;
  align-items: center;
  animation: fadeSlideUp 250ms ease-out;
}

.role-badge-header {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.35rem 0.8rem;
  border-radius: var(--radius-full);
  font-size: 0.78rem;
  font-weight: 800;
  margin-bottom: 1rem;
}

.role-title {
  font-size: 1.75rem;
  font-weight: 800;
  color: var(--color-navy);
  margin-bottom: 0.75rem;
  line-height: 1.22;
}

.role-lead {
  font-size: 1rem;
  color: var(--color-text-secondary);
  margin-bottom: 1.5rem;
}

.role-feature-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.9rem;
  margin-bottom: 1.75rem;
}

.role-feature-item {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
  font-size: 0.95rem;
  color: var(--color-text);
}

.role-check-icon {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: var(--color-emerald-light);
  color: var(--color-emerald);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  margin-top: 2px;
}

.role-governance-box {
  background: var(--color-surface-mandi);
  border-left: 4px solid var(--color-primary);
  padding: 0.9rem 1.1rem;
  border-radius: 0 10px 10px 0;
  font-size: 0.875rem;
  color: var(--color-navy);
}

.role-preview-card {
  background: var(--color-surface-mandi);
  border: 1px solid var(--color-border-mandi);
  border-radius: var(--radius-lg);
  padding: 1.5rem;
}

/* ==========================================================================
   6. HOW IT WORKS (4-STEP END-TO-END MANDI FLOW)
   ========================================================================== */
.steps-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1.5rem;
}

.step-card {
  background: #FFFFFF;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  padding: 1.75rem 1.5rem;
  position: relative;
  transition: transform var(--transition-base), box-shadow var(--transition-base);
}

.step-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-md);
}

.step-num-badge {
  font-family: var(--font-mono);
  font-size: 0.82rem;
  font-weight: 800;
  color: var(--color-primary-deep);
  background: var(--color-badge-bg);
  border: 1px solid rgba(245, 158, 11, 0.4);
  padding: 0.25rem 0.65rem;
  border-radius: var(--radius-full);
  display: inline-block;
  margin-bottom: 1rem;
}

.step-card-title {
  font-size: 1.125rem;
  font-weight: 800;
  color: var(--color-navy);
  margin-bottom: 0.55rem;
}

.step-card-desc {
  font-size: 0.9rem;
  color: var(--color-text-secondary);
  line-height: 1.6;
}

/* ==========================================================================
   7. APMC MANDI NETWORK (VARANASI PILOT + NATIONAL EXPANSION)
   ========================================================================== */
.mandi-pilot-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
  margin-bottom: 2.25rem;
}

.mandi-card {
  background: #FFFFFF;
  border: 1.5px solid var(--color-border);
  border-radius: var(--radius-lg);
  padding: 1.65rem;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  transition: all var(--transition-base);
}

.mandi-card.pilot-active {
  border-color: rgba(21, 128, 61, 0.35);
  box-shadow: var(--shadow-sm);
}

.mandi-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-md);
}

.mandi-card-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 1rem;
}

.mandi-code-tag {
  font-family: var(--font-mono);
  font-size: 0.8rem;
  font-weight: 800;
  color: var(--color-navy);
  background: #F1F5F9;
  padding: 0.25rem 0.6rem;
  border-radius: 6px;
}

.mandi-status-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  font-size: 0.75rem;
  font-weight: 700;
  background: var(--color-emerald-light);
  color: var(--color-emerald-deep);
  padding: 0.22rem 0.65rem;
  border-radius: var(--radius-full);
}

.mandi-name {
  font-size: 1.18rem;
  font-weight: 800;
  color: var(--color-navy);
  margin-bottom: 0.3rem;
}

.mandi-area {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--color-text-secondary);
  margin-bottom: 1rem;
}

.mandi-specialty-box {
  background: var(--color-surface-mandi);
  border: 1px solid var(--color-border-mandi);
  border-radius: 10px;
  padding: 0.75rem;
  font-size: 0.84rem;
  color: var(--color-navy);
  margin-bottom: 1rem;
}

.mandi-gaddi-lead {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 0.78rem;
  color: var(--color-text-secondary);
  padding-top: 0.75rem;
  border-top: 1px solid var(--color-border);
}

.expansion-strip {
  background: #FFFFFF;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  padding: 1.35rem 1.75rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 1rem;
}

.expansion-hubs-list {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
}

.hub-chip {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  background: #F8FAFC;
  border: 1px solid var(--color-border);
  padding: 0.4rem 0.8rem;
  border-radius: var(--radius-full);
  font-size: 0.8125rem;
  font-weight: 600;
  color: var(--color-text-secondary);
}

.hub-chip strong {
  font-family: var(--font-mono);
  color: var(--color-navy);
  font-size: 0.75rem;
}

/* ==========================================================================
   8. ENTERPRISE CTA BANNER & FOOTER
   ========================================================================== */
.cta-banner {
  background:
    radial-gradient(circle at 85% 20%, rgba(245, 158, 11, 0.22) 0%, transparent 45%),
    radial-gradient(circle at 15% 85%, rgba(21, 128, 61, 0.22) 0%, transparent 45%),
    var(--color-navy);
  color: #FFFFFF;
  border-radius: var(--radius-xl);
  padding: 4rem 3.5rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 2.5rem;
  box-shadow: var(--shadow-xl);
}

.cta-banner-content {
  max-width: 620px;
}

.cta-banner-title {
  font-size: clamp(1.75rem, 2.8vw, 2.35rem);
  font-weight: 800;
  margin-bottom: 0.85rem;
  line-height: 1.2;
}

.cta-banner-sub {
  font-size: 1.05rem;
  color: #CBD5E1;
  line-height: 1.65;
}

.cta-banner-actions {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 0.85rem;
  flex-shrink: 0;
}

.site-footer {
  background: #0B1120;
  color: #94A3B8;
  padding: 4rem 0 2.5rem;
  font-size: 0.9rem;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.5fr 1fr 1fr 1fr;
  gap: 2.5rem;
  padding-bottom: 3rem;
  border-bottom: 1px solid #1E293B;
}

.footer-brand-desc {
  margin-top: 0.85rem;
  max-width: 340px;
  color: #94A3B8;
  line-height: 1.6;
}

.footer-col-title {
  color: #FFFFFF;
  font-size: 0.875rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  margin-bottom: 1rem;
}

.footer-links {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
}

.footer-links a:hover {
  color: var(--color-primary);
}

.footer-bottom {
  padding-top: 2rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 1rem;
  font-size: 0.825rem;
}

/* Hamburger button & slide-down menu (phones and tablets only) */
.nav-toggle {
  display: none;
  width: 44px;
  height: 44px;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius-md);
  border: 1px solid var(--color-border);
  background: #FFFFFF;
  color: var(--color-navy);
  flex-shrink: 0;
}

.nav-toggle-close,
.nav-toggle[aria-expanded="true"] .nav-toggle-open {
  display: none;
}

.nav-toggle[aria-expanded="true"] .nav-toggle-close {
  display: block;
}

.mobile-menu {
  background: #FFFFFF;
  border-top: 1px solid var(--color-border);
  padding: 0.5rem 1.5rem 1.25rem;
  max-height: calc(100svh - 64px);
  overflow-y: auto;
  animation: fadeSlideUp 200ms ease-out;
}

.mobile-menu[hidden] {
  display: none;
}

.mobile-menu-links {
  list-style: none;
  margin-bottom: 1rem;
}

.mobile-menu-links a {
  display: flex;
  align-items: center;
  min-height: 52px;
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--color-navy);
  border-bottom: 1px solid var(--color-border);
}

.mobile-menu-cta {
  width: 100%;
  white-space: normal;
  text-align: center;
}

/* ==========================================================================
   9. RESPONSIVE BREAKPOINTS (1240px nav, 1024px, 768px, 480px) & REDUCED MOTION
   ========================================================================== */
@media (max-width: 1240px) {
  .site-header nav[aria-label="Primary Navigation"],
  .nav-cta-desktop {
    display: none;
  }
  .nav-toggle {
    display: inline-flex;
  }
}

@media (min-width: 1241px) {
  .mobile-menu {
    display: none !important;
  }
}

@media (max-width: 1024px) {
  .hero-grid {
    grid-template-columns: 1fr;
    gap: 2.5rem;
  }
  .hero-showcase-wrap {
    width: 100%;
    max-width: 560px;
    margin: 0 auto;
  }
  .bento-span-7, .bento-span-5, .bento-span-4, .bento-span-8 {
    grid-column: span 6;
  }
  .role-panel.active {
    grid-template-columns: 1fr;
    gap: 2rem;
  }
  .steps-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .mandi-pilot-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .cta-banner {
    flex-direction: column;
    align-items: flex-start;
    padding: 2.75rem 2rem;
  }
  .cta-banner-actions {
    align-items: flex-start;
    width: 100%;
  }
  .footer-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 768px) {
  .container {
    padding: 0 1rem;
  }
  .mobile-menu {
    padding: 0.25rem 1rem 1.25rem;
  }
  .nav-inner {
    height: 64px;
    gap: 0.5rem;
  }
  .section {
    padding: 3.5rem 0;
  }
  .section-header {
    margin-bottom: 2rem;
  }
  .section-desc {
    font-size: 1rem;
  }
  .hero-section {
    padding: 2rem 0 3rem;
  }
  .hero-subtitle {
    font-size: 1.02rem;
    margin-bottom: 1.5rem;
  }
  .hero-cta-group {
    gap: 0.75rem;
    margin-bottom: 2rem;
  }
  .hero-cta-group .btn {
    flex: 1 1 100%;
  }
  .hero-metrics-bar {
    grid-template-columns: 1fr;
    gap: 0.85rem;
    padding-top: 1.25rem;
  }
  .hero-metric-item {
    flex-direction: row;
    align-items: baseline;
    gap: 0.75rem;
  }
  .hero-metric-val {
    font-size: 1.1rem;
    min-width: 7.5rem;
    flex-shrink: 0;
  }
  .bento-grid {
    gap: 1rem;
  }
  .bento-span-7, .bento-span-5, .bento-span-4, .bento-span-8 {
    grid-column: span 12;
  }
  .bento-card {
    padding: 1.4rem;
    border-radius: 20px;
  }
  .bento-title {
    font-size: 1.2rem;
  }
  .bento-micro-ui > div[style*="space-between"],
  .aging-legend {
    flex-wrap: wrap;
    gap: 0.25rem 0.75rem;
  }
  .steps-grid, .mandi-pilot-grid {
    grid-template-columns: 1fr;
    gap: 1rem;
  }
  .bahi-summary-grid {
    grid-template-columns: 1fr;
  }
  /* Role tabs sit side by side as three equal buttons so all roles stay visible */
  .role-tabs-nav {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 0.5rem;
    margin-bottom: 1.5rem;
  }
  .role-tab-trigger {
    justify-content: center;
    text-align: center;
    padding: 0.7rem 0.5rem;
    font-size: 0.8rem;
    line-height: 1.3;
    border-radius: var(--radius-md);
  }
  .role-tab-dot {
    display: none;
  }
  .role-panel {
    padding: 1.35rem;
    border-radius: 20px;
  }
  .role-title {
    font-size: 1.4rem;
  }
  .role-preview-card {
    padding: 1rem;
  }
  .running-bal-strip {
    flex-wrap: wrap;
    gap: 0.15rem 0.75rem;
  }
  .expansion-strip {
    padding: 1.15rem;
  }
  .cta-banner {
    padding: 2rem 1.35rem;
    border-radius: 20px;
  }
  .cta-banner-actions .btn {
    width: 100%;
    white-space: normal;
    text-align: center;
  }
  .site-footer {
    padding: 3rem 0 2rem;
  }
  .footer-grid {
    grid-template-columns: 1fr 1fr;
    gap: 2rem 1.25rem;
    padding-bottom: 2rem;
  }
  .footer-grid > div:first-child {
    grid-column: 1 / -1;
  }
  .footer-bottom {
    flex-direction: column;
    align-items: flex-start;
  }
  .showcase-card {
    --shot-w: clamp(190px, min(60vw, calc((100svh - 300px) * 0.4618)), 236px);
    border-radius: 24px;
  }
}

@media (max-width: 480px) {
  .brand-logo-img {
    width: 38px;
    height: 38px;
    border-radius: 10px;
  }
  .brand-link {
    gap: 0.55rem;
  }
  .brand-title {
    font-size: 1.1rem;
  }
  .brand-sub-pill {
    font-size: 0.56rem;
    letter-spacing: 0.04em;
    white-space: nowrap;
  }
  .nav-actions {
    gap: 0.4rem;
  }
  .lang-btn {
    padding: 0.36rem 0.6rem;
    font-size: 0.78rem;
  }
  .nav-toggle {
    width: 40px;
    height: 40px;
  }
  .btn {
    white-space: normal;
    text-align: center;
  }
  .footer-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 374px) {
  .brand-sub-pill {
    display: none;
  }
}

/* Touch screens swipe the screenshot strip, so the arrow buttons are only for mouse users */
@media (hover: none) {
  .shot-nav {
    display: none;
  }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}

.footer-legal-links {
  display: flex;
  flex-wrap: wrap;
  gap: 1.25rem;
}

.footer-legal-links a:hover {
  color: var(--color-primary);
}

.price-card {
  gap: 0.5rem;
}

.price-value {
  font-size: 1.6rem;
  font-weight: 800;
  color: var(--color-emerald-dark);
  letter-spacing: -0.01em;
}

.price-note {
  margin-top: 1.5rem;
  text-align: center;
  font-size: 0.875rem;
  color: var(--color-text-muted);
}

.price-note a {
  text-decoration: underline;
  text-underline-offset: 2px;
}

/* Hero: real app screenshots, a swipeable strip of phones.
   The active phone sits in the centre; neighbours peek in at the edges so
   visitors on a phone can see there is more to swipe. */
.hero-showcase-wrap {
  position: relative;
  min-width: 0;
}

.showcase-card {
  --shot-w: clamp(196px, calc((100svh - 330px) * 0.4618), 236px);
  position: relative;
  background:
    radial-gradient(circle at 50% 46%, rgba(245, 158, 11, 0.22) 0%, transparent 52%),
    radial-gradient(circle at 18% 90%, rgba(21, 128, 61, 0.12) 0%, transparent 45%),
    rgba(255, 255, 255, 0.72);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid var(--color-border);
  border-radius: 28px;
  padding: 1.25rem 0 1rem;
  box-shadow: var(--shadow-lg);
  overflow: hidden;
}

.showcase-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 0.15rem 0.75rem;
  padding: 0 1.25rem;
  margin-bottom: 0.75rem;
}

.showcase-title {
  font-size: 0.95rem;
  font-weight: 800;
  color: var(--color-navy);
}

.showcase-sub {
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--color-text-muted);
}

.shot-tabs {
  display: flex;
  gap: 0.4rem;
  padding: 0.15rem 1.25rem;
  margin-bottom: 1rem;
  overflow-x: auto;
  scrollbar-width: none;
}

.shot-tabs::-webkit-scrollbar {
  display: none;
}

.shot-tab {
  flex-shrink: 0;
  padding: 0.42rem 0.85rem;
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--color-text-secondary);
  background: #FFFFFF;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-full);
  transition: all var(--transition-fast);
}

.shot-tab:not(.active):hover {
  color: var(--color-navy);
  border-color: #CBD5E1;
}

.shot-tab.active {
  background: var(--color-navy);
  border-color: var(--color-navy);
  color: #FFFFFF;
  box-shadow: 0 2px 8px rgba(15, 23, 42, 0.18);
}

.shot-stage {
  position: relative;
}

.shot-track {
  position: relative;
  display: flex;
  gap: 1rem;
  padding: 0.5rem calc(50% - var(--shot-w) / 2) 0.25rem;
  overflow-x: auto;
  overscroll-behavior-x: contain;
  scroll-snap-type: x mandatory;
  scrollbar-width: none;
  -webkit-mask-image: linear-gradient(90deg, transparent 0, #000 16%, #000 84%, transparent 100%);
  mask-image: linear-gradient(90deg, transparent 0, #000 16%, #000 84%, transparent 100%);
}

.shot-track::-webkit-scrollbar {
  display: none;
}

.shot-track:focus-visible {
  outline: none;
}

.shot-slide {
  flex: 0 0 var(--shot-w);
  margin: 0;
  scroll-snap-align: center;
}

.phone-frame {
  position: relative;
  width: 100%;
  aspect-ratio: 750 / 1624;
  border: 7px solid #020617;
  border-radius: 32px;
  overflow: hidden;
  background: #020617;
  box-shadow: 0 22px 40px -16px rgba(15, 23, 42, 0.5);
  cursor: zoom-in;
  transform: scale(0.88);
  opacity: 0.5;
  transition: transform var(--transition-base), opacity var(--transition-base);
}

.shot-slide.is-active .phone-frame {
  transform: none;
  opacity: 1;
}

.shot-slide:not(.is-active) .phone-frame {
  cursor: pointer;
}

.phone-frame:focus-visible {
  outline: 3px solid var(--color-primary);
  outline-offset: 3px;
}

/* Only one language's screenshot is ever shown (English unless the page is in Hindi). */
.shot-img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.shot-img[data-shot-lang="hi"],
html[lang="hi"] .shot-img[data-shot-lang="en"] {
  display: none;
}

html[lang="hi"] .shot-img[data-shot-lang="hi"] {
  display: block;
}

.shot-caption {
  margin: 0.85rem -1.5rem 0;
  text-align: center;
  font-size: 0.82rem;
  font-weight: 500;
  line-height: 1.5;
  color: var(--color-text-secondary);
  opacity: 0;
  transition: opacity var(--transition-base);
}

.shot-slide.is-active .shot-caption {
  opacity: 1;
}

.shot-nav {
  position: absolute;
  top: calc(0.5rem + var(--shot-w) * 1.083);
  z-index: 2;
  width: 40px;
  height: 40px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: #FFFFFF;
  color: var(--color-navy);
  border: 1px solid var(--color-border);
  box-shadow: var(--shadow-md);
  transform: translateY(-50%);
  transition: all var(--transition-fast);
}

.shot-nav:hover:not(:disabled) {
  background: var(--color-primary);
  border-color: var(--color-primary-dark);
}

.shot-nav:disabled {
  opacity: 0;
  pointer-events: none;
}

.shot-prev { left: 0.85rem; }
.shot-next { right: 0.85rem; }

.shot-zoom-hint {
  margin-top: 0.5rem;
  text-align: center;
  font-size: 0.72rem;
  font-weight: 600;
  color: var(--color-text-muted);
}

.shot-viewer {
  position: fixed;
  inset: 0;
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  background: rgba(2, 6, 23, 0.9);
  cursor: zoom-out;
}

.shot-viewer[hidden] {
  display: none;
}

.shot-viewer img {
  max-width: min(460px, 100%);
  max-height: 100%;
  width: auto;
  height: auto;
  border-radius: 20px;
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.6);
}

.shot-viewer-close {
  position: absolute;
  top: 12px;
  right: 16px;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.12);
  color: #FFFFFF;
  font-size: 1.75rem;
  line-height: 1;
}

/* Demo video section */
.section-demo {
  padding-top: 4rem;
}

.demo-player {
  max-width: 960px;
  margin: 0 auto;
  aspect-ratio: 16 / 9;
  border-radius: var(--radius-xl);
  overflow: hidden;
  background: var(--color-navy);
  border: 1px solid var(--color-border);
  box-shadow: var(--shadow-xl);
}

.demo-player iframe,
.demo-play {
  display: block;
  width: 100%;
  height: 100%;
  border: 0;
}

.demo-play {
  position: relative;
  padding: 0;
  cursor: pointer;
}

.demo-play img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform var(--transition-base);
}

.demo-play-icon {
  position: absolute;
  left: 50%;
  top: 50%;
  width: 84px;
  height: 84px;
  margin: -42px 0 0 -42px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding-left: 5px;
  border-radius: 50%;
  background: #DC2626;
  color: #FFFFFF;
  box-shadow: 0 12px 30px -6px rgba(15, 23, 42, 0.55);
  transition: transform var(--transition-fast);
}

.demo-play:hover .demo-play-icon,
.demo-play:focus-visible .demo-play-icon {
  transform: scale(1.08);
}

.demo-play:hover img {
  transform: scale(1.015);
}

.demo-note a {
  color: var(--color-crimson-dark);
  text-decoration: underline;
  text-underline-offset: 2px;
}

.demo-note {
  margin-top: 1rem;
  text-align: center;
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--color-text-muted);
}

@media (max-width: 768px) {
  .section-demo {
    padding-top: 2.5rem;
  }
  .demo-player {
    border-radius: 16px;
    margin: 0 -0.25rem;
  }
}
