/* ==========================================================================
   INTERIOR AUTOMATE — MASTER ENTERPRISE DESIGN SYSTEM
   Theme: Luxury Architectural Minimalism, High Contrast, Crystal-Clear Legibility
   Fonts: Cormorant Garamond (Headings) + Plus Jakarta Sans (Body & UI)
   ========================================================================== */

@import url('https://fonts.googleapis.com/css2?family=Cormorant+Garamond:ital,wght@0,500;0,600;0,700;1,500&family=Plus+Jakarta+Sans:wght@400;500;600;700;800&display=swap');

/* ==========================================================================
   GLOBAL DESIGN TOKENS (LIGHT & DARK THEMES)
   ========================================================================== */
:root {
  --bg-primary: #F8FAFC;
  --bg-surface: #FFFFFF;
  --bg-surface-elevated: #F1F5F9;
  --bg-nav: rgba(255, 255, 255, 0.98);
  --bg-hero: radial-gradient(circle at 50% 10%, #FFFFFF 0%, #F1F5F9 100%);
  --bg-hero-card: #FFFFFF;
  --bg-sidebar: #0B0F19;
  --bg-header: rgba(255, 255, 255, 0.98);
  --bg-footer: #0B0F19;

  --text-primary: #0F172A;
  --text-secondary: #334155;
  --text-muted: #64748B;
  --text-inverse: #F8FAFC;
  --text-inverse-muted: #94A3B8;

  --accent-gold: #B48C36;
  --accent-gold-light: #D4AF37;
  --accent-gold-subtle: rgba(180, 140, 54, 0.1);
  --accent-gold-border: rgba(180, 140, 54, 0.35);
  --accent-gold-hover: #967024;

  --accent-emerald: #10B981;
  --status-approved-bg: #ECFDF5;
  --status-approved-text: #047857;
  --status-pending-bg: #FFFBEB;
  --status-pending-text: #B45309;
  --status-draft-bg: #F1F5F9;
  --status-draft-text: #475569;
  --status-exec-bg: #EEF2FF;
  --status-exec-text: #4338CA;

  --doc-header-bg: #E2E8F0;
  --doc-header-text: #0F172A;
  --doc-section-bg: #EDF2F7;
  --doc-total-bg: #F1F5F9;
  --doc-border: #CBD5E1;

  --border-light: #E2E8F0;
  --border-medium: #CBD5E1;
  --border-dark: rgba(255, 255, 255, 0.1);

  --shadow-xs: 0 1px 2px rgba(0, 0, 0, 0.04);
  --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.06), 0 1px 2px rgba(0, 0, 0, 0.04);
  --shadow-md: 0 4px 16px rgba(0, 0, 0, 0.06);
  --shadow-lg: 0 12px 32px rgba(0, 0, 0, 0.08);
  --shadow-dark: 0 16px 40px rgba(0, 0, 0, 0.35);

  --font-serif: 'Cormorant Garamond', Georgia, serif;
  --font-sans: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, sans-serif;
  --radius-xs: 4px;
  --radius-sm: 6px;
  --radius-md: 12px;
  --radius-lg: 16px;
  --radius-pill: 9999px;
  --transition-fast: 0.18s cubic-bezier(0.16, 1, 0.3, 1);
}

[data-theme="light"], html[data-theme="light"], body[data-theme="light"] {
  --bg-primary: #F8FAFC;
  --bg-surface: #FFFFFF;
  --bg-surface-elevated: #F1F5F9;
  --bg-nav: rgba(255, 255, 255, 0.98);
  --bg-hero: radial-gradient(circle at 50% 10%, #FFFFFF 0%, #F1F5F9 100%);
  --bg-hero-card: #FFFFFF;
  --bg-sidebar: #0B0F19;
  --bg-header: rgba(255, 255, 255, 0.98);
  --bg-footer: #F1F5F9;

  --text-primary: #0F172A;
  --text-secondary: #334155;
  --text-muted: #64748B;
  --text-inverse: #F8FAFC;
  --text-inverse-muted: #94A3B8;

  --border-light: #E2E8F0;
  --border-medium: #CBD5E1;
  --border-dark: rgba(0, 0, 0, 0.1);
}

[data-theme="dark"], html[data-theme="dark"], body[data-theme="dark"] {
  --bg-primary: #090D16;          /* Deep Obsidian Void */
  --bg-surface: #111726;          /* Dark Card Surface */
  --bg-surface-elevated: #1A2234; /* Dark Elevated Surface */
  --bg-nav: rgba(9, 13, 22, 0.98);
  --bg-hero: radial-gradient(circle at 50% 10%, #151D2E 0%, #090D16 100%);
  --bg-hero-card: #111726;
  --bg-sidebar: #06080E;
  --bg-header: rgba(9, 13, 22, 0.98);
  --bg-footer: #06080E;

  --text-primary: #F8FAFC;
  --text-secondary: #CBD5E1;
  --text-muted: #94A3B8;
  --text-inverse: #0F172A;
  --text-inverse-muted: #64748B;

  --border-light: #1E293B;
  --border-medium: #334155;
  --border-dark: rgba(255, 255, 255, 0.12);

  --doc-header-bg: #1E293B;
  --doc-header-text: #F8FAFC;
  --doc-section-bg: #151D2E;
  --doc-total-bg: #1E293B;
  --doc-border: #334155;

  --status-draft-bg: #1E293B;
  --status-draft-text: #94A3B8;
  --status-pending-bg: rgba(245, 158, 11, 0.15);
  --status-pending-text: #FBBF24;
  --status-approved-bg: rgba(16, 185, 129, 0.15);
  --status-approved-text: #34D399;
}

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

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

body {
  font-family: var(--font-sans);
  background-color: var(--bg-primary);
  color: var(--text-primary);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  min-height: 100vh;
  overflow-x: hidden;
  transition: background-color var(--transition-fast), color var(--transition-fast);
}

/* ==========================================================================
   TOAST NOTIFICATION ENGINE (100% VISIBLE & SHARP IN ALL THEMES)
   ========================================================================== */
.toast-container {
  position: fixed;
  top: 24px;
  right: 24px;
  z-index: 99999;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  pointer-events: none;
}

.toast-item {
  pointer-events: auto;
  min-width: 320px;
  max-width: 440px;
  background-color: #0F172A !important;
  color: #FFFFFF !important;
  border-radius: var(--radius-md);
  padding: 1rem 1.25rem;
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.45);
  display: flex;
  align-items: center;
  gap: 0.85rem;
  border: 1px solid rgba(255, 255, 255, 0.15);
  animation: toastSlideIn 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  transition: all var(--transition-fast);
}

.toast-item.toast-success { border-left: 5px solid var(--accent-emerald) !important; }
.toast-item.toast-error { border-left: 5px solid #EF4444 !important; }
.toast-item.toast-info { border-left: 5px solid var(--accent-gold) !important; }

.toast-icon { font-size: 1.35rem; flex-shrink: 0; }
.toast-content { flex: 1; }
.toast-title { font-size: 0.875rem; font-weight: 800; color: #FFFFFF !important; margin-bottom: 2px; }
.toast-msg { font-size: 0.785rem; color: #E2E8F0 !important; line-height: 1.45; font-weight: 500; }
.toast-close { background: transparent; border: none; color: #94A3B8; cursor: pointer; font-size: 1.35rem; line-height: 1; }
.toast-close:hover { color: #FFFFFF; }

@keyframes toastSlideIn {
  from { opacity: 0; transform: translateX(30px) scale(0.95); }
  to { opacity: 1; transform: translateX(0) scale(1); }
}

/* ==========================================================================
   THEME TOGGLE BUTTON
   ========================================================================== */
.theme-toggle-btn {
  background: var(--bg-surface);
  border: 1px solid var(--border-light);
  color: var(--text-primary);
  width: 38px;
  height: 38px;
  border-radius: var(--radius-pill);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-size: 1.1rem;
  transition: all var(--transition-fast);
  box-shadow: var(--shadow-xs);
}

.theme-toggle-btn:hover {
  border-color: var(--accent-gold);
  transform: scale(1.05);
}

/* ==========================================================================
   PAGE WRAPPERS (LANDING VS WORKSPACE VS ADMIN)
   ========================================================================== */
.page-wrapper {
  display: none;
  min-height: 100vh;
  width: 100%;
}

.page-wrapper.active { display: block; }

.workspace-layout {
  display: none;
  min-height: 100vh;
  width: 100%;
}

.workspace-layout.active { display: flex; }

/* ==========================================================================
   PUBLIC LANDING NAVBAR & HERO
   ========================================================================== */
.landing-nav {
  position: sticky;
  top: 0;
  z-index: 150;
  background: var(--bg-nav);
  backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border-light);
  padding: 1.1rem 3.5rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.brand-logo-wrap {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  text-decoration: none;
}

.brand-icon-box {
  width: 40px;
  height: 40px;
  border-radius: var(--radius-sm);
  background: linear-gradient(135deg, #1E293B 0%, #0F172A 100%);
  border: 1px solid var(--accent-gold);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--accent-gold) !important;
  box-shadow: 0 4px 12px rgba(180, 140, 54, 0.2);
  flex-shrink: 0;
}

.brand-title-text {
  display: flex;
  flex-direction: column;
}

.brand-name-main {
  font-family: var(--font-serif);
  font-size: 1.3rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  color: var(--text-primary);
  line-height: 1.1;
  text-transform: uppercase;
}

.app-sidebar .brand-name-main { color: #FFFFFF !important; }
.brand-name-main span { color: var(--accent-gold) !important; }

.brand-tagline-sub {
  font-size: 0.62rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text-muted);
  font-weight: 700;
  margin-top: 2px;
}

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

.nav-link-item {
  color: var(--text-secondary);
  text-decoration: none;
  font-size: 0.85rem;
  font-weight: 700;
  transition: color var(--transition-fast);
}

.nav-link-item:hover { color: var(--accent-gold); }

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

/* HERO SECTION */
.landing-hero-section {
  background: var(--bg-hero);
  color: var(--text-primary);
  padding: 5.5rem 3rem 6rem 3rem;
  text-align: center;
  position: relative;
  overflow: hidden;
  border-bottom: 1px solid var(--border-light);
}

.hero-pill-tag {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  background: var(--accent-gold-subtle);
  border: 1px solid var(--accent-gold-border);
  color: var(--accent-gold-hover);
  font-size: 0.75rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 0.35rem 1.15rem;
  border-radius: var(--radius-pill);
  margin-bottom: 1.5rem;
}

.landing-hero-title {
  font-family: var(--font-serif);
  font-size: 3.6rem;
  font-weight: 600;
  line-height: 1.15;
  max-width: 920px;
  margin: 0 auto 1.25rem auto;
  letter-spacing: 0.01em;
  color: var(--text-primary);
}

.landing-hero-title span {
  background: linear-gradient(135deg, #B48C36 0%, #D4AF37 50%, #967024 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.landing-hero-sub {
  font-size: 1.1rem;
  color: var(--text-secondary);
  max-width: 740px;
  margin: 0 auto 2.5rem auto;
  line-height: 1.65;
}

.hero-cta-group {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1.25rem;
  margin-bottom: 3.5rem;
}

/* INTERACTIVE ESTIMATOR CARD */
.landing-interactive-card {
  max-width: 980px;
  margin: 0 auto;
  background: var(--bg-surface);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-lg);
  padding: 2.25rem;
  box-shadow: var(--shadow-lg);
  text-align: left;
}

.interactive-card-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid var(--border-light);
  padding-bottom: 1.25rem;
  margin-bottom: 1.5rem;
}

.calc-inputs-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.25rem;
  margin-bottom: 1.5rem;
}

.calc-res-banner {
  background: var(--accent-gold-subtle);
  border: 1px solid var(--accent-gold-border);
  border-radius: var(--radius-md);
  padding: 1.25rem 1.5rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

/* FEATURES & SECTIONS */
.landing-section {
  padding: 5.5rem 3.5rem;
  max-width: 1320px;
  margin: 0 auto;
}

.section-head-center {
  text-align: center;
  margin-bottom: 3.5rem;
}

.section-head-center h2 {
  font-family: var(--font-serif);
  font-size: 2.5rem;
  font-weight: 600;
  color: var(--text-primary);
}

.section-head-center p {
  color: var(--text-secondary);
  font-size: 0.95rem;
  max-width: 620px;
  margin: 0.5rem auto 0 auto;
  line-height: 1.6;
}

.features-grid-3col {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2rem;
}

.feature-box-card {
  background: var(--bg-surface);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-lg);
  padding: 2.25rem 2rem;
  box-shadow: var(--shadow-xs);
  transition: all var(--transition-fast);
}

.feature-box-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-md);
  border-color: var(--accent-gold-border);
}

.feature-icon-badge {
  width: 48px;
  height: 48px;
  border-radius: var(--radius-md);
  background: var(--accent-gold-subtle);
  color: var(--accent-gold);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 1.25rem;
  font-size: 1.5rem;
}

.feature-title-h3 {
  font-family: var(--font-serif);
  font-size: 1.35rem;
  font-weight: 700;
  margin-bottom: 0.5rem;
  color: var(--text-primary);
}

.feature-desc-p {
  font-size: 0.85rem;
  color: var(--text-secondary);
  line-height: 1.6;
}

/* ==========================================================================
   SYSTEMATIC STUDIO SIDEBAR
   ========================================================================== */
.app-sidebar {
  width: 290px;
  background-color: var(--bg-sidebar);
  color: var(--text-inverse);
  display: flex;
  flex-direction: column;
  height: 100vh;
  position: sticky;
  top: 0;
  z-index: 100;
  border-right: 1px solid var(--border-dark);
  flex-shrink: 0;
}

.sidebar-brand-box {
  padding: 1.25rem 1.25rem;
  border-bottom: 1px solid var(--border-dark);
  background-color: #06080E;
}

.sidebar-active-studio {
  margin-top: 0.75rem;
  padding: 0.5rem 0.75rem;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(180, 140, 54, 0.25);
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: space-between;
  cursor: pointer;
  transition: all var(--transition-fast);
}

.sidebar-active-studio:hover {
  background: rgba(180, 140, 54, 0.1);
  border-color: var(--accent-gold);
}

.studio-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background-color: var(--accent-emerald);
  box-shadow: 0 0 8px var(--accent-emerald);
}

.studio-name-display {
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--accent-gold-light);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.sidebar-menu {
  padding: 0.85rem 0.75rem;
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
  flex: 1;
  overflow-y: auto;
}

.menu-category-label {
  font-size: 0.62rem;
  font-weight: 800;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--accent-gold);
  padding: 0.75rem 0.65rem 0.25rem 0.65rem;
}

.menu-item-link {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.6rem 0.75rem;
  color: #94A3B8;
  text-decoration: none;
  font-size: 0.825rem;
  font-weight: 600;
  border-radius: var(--radius-sm);
  transition: all var(--transition-fast);
  cursor: pointer;
}

.menu-item-link svg {
  width: 17px;
  height: 17px;
  stroke-width: 1.8;
  flex-shrink: 0;
  transition: transform var(--transition-fast);
}

.menu-item-link:hover {
  color: #FFFFFF;
  background-color: rgba(255, 255, 255, 0.06);
}

.menu-item-link:hover svg { transform: translateX(2px); }

.menu-item-link.active {
  color: #FFFFFF;
  background: linear-gradient(135deg, #B48C36 0%, #8C641E 100%);
  box-shadow: 0 4px 12px rgba(180, 140, 54, 0.25);
}

.menu-item-link.active svg { stroke: #FFFFFF; }

.sidebar-footer {
  padding: 0.85rem 1.15rem;
  border-top: 1px solid var(--border-dark);
  background-color: #05070B;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.plan-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  background: rgba(180, 140, 54, 0.15);
  border: 1px solid var(--accent-gold-border);
  color: var(--accent-gold-light);
  font-size: 0.68rem;
  font-weight: 700;
  padding: 0.25rem 0.55rem;
  border-radius: var(--radius-pill);
  cursor: pointer;
}

/* ==========================================================================
   APP MAIN & HEADER
   ========================================================================== */
.app-main {
  flex: 1;
  display: flex;
  flex-direction: column;
  min-width: 0;
  height: 100vh;
  overflow-y: auto;
}

.app-header {
  position: sticky;
  top: 0;
  z-index: 90;
  background-color: var(--bg-header);
  backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border-light);
  padding: 1rem 2.25rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
}

.header-title-group h1 {
  font-family: var(--font-serif);
  font-size: 1.75rem;
  font-weight: 700;
  color: var(--text-primary);
  line-height: 1.15;
}

.header-title-group p {
  font-size: 0.8rem;
  color: var(--text-secondary);
  margin-top: 2px;
  font-weight: 500;
}

.header-right-actions {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  flex-wrap: wrap;
}

/* ==========================================================================
   BUTTON SYSTEM
   ========================================================================== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.45rem;
  font-family: var(--font-sans);
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  padding: 0.6rem 1.15rem;
  border-radius: var(--radius-sm);
  border: 1px solid transparent;
  cursor: pointer;
  transition: all var(--transition-fast);
  text-decoration: none;
  white-space: nowrap;
}

.btn-sm { padding: 0.4rem 0.8rem; font-size: 0.75rem; }
.btn-xs { padding: 0.25rem 0.55rem; font-size: 0.7rem; }
.btn-lg { padding: 0.85rem 1.75rem; font-size: 0.95rem; }

.btn-gold {
  background: linear-gradient(135deg, #B48C36 0%, #967024 100%) !important;
  color: #FFFFFF !important;
  border: 1px solid #8C641E !important;
  box-shadow: 0 2px 8px rgba(180, 140, 54, 0.25) !important;
}

.btn-gold:hover {
  background: linear-gradient(135deg, #C5A059 0%, #A6833D 100%) !important;
  box-shadow: 0 4px 14px rgba(180, 140, 54, 0.35) !important;
  transform: translateY(-1px);
}

.btn-primary {
  background-color: #0F172A !important;
  color: #FFFFFF !important;
  border-color: #0F172A !important;
}

.btn-primary:hover {
  background-color: #1E293B !important;
  transform: translateY(-1px);
}

.btn-outline {
  background-color: var(--bg-surface) !important;
  color: var(--text-primary) !important;
  border: 1px solid var(--border-medium) !important;
}

.btn-outline:hover {
  background-color: var(--bg-surface-elevated) !important;
  color: #000000 !important;
  border-color: var(--text-primary) !important;
}

.btn-outline-gold {
  background-color: transparent !important;
  color: var(--accent-gold) !important;
  border: 1px solid var(--accent-gold-border) !important;
}

.btn-outline-gold:hover {
  background-color: var(--accent-gold-subtle) !important;
  border-color: var(--accent-gold) !important;
}

.btn-success { background-color: var(--accent-emerald) !important; color: #FFFFFF !important; }
.btn-danger { background-color: #EF4444 !important; color: #FFFFFF !important; }

/* ==========================================================================
   VIEW CONTAINER & DASHBOARD CARDS
   ========================================================================== */
.view-container {
  padding: 2rem 2.25rem 4rem 2.25rem;
  max-width: 1440px;
  width: 100%;
}

.view-pane {
  display: none;
  animation: fadeIn 0.2s ease-out;
}

.view-pane.active { display: block; }

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

.saas-hero-banner {
  background: var(--bg-surface);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  padding: 1.75rem 2rem;
  color: var(--text-primary);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 2rem;
  margin-bottom: 1.75rem;
  box-shadow: var(--shadow-xs);
  position: relative;
  overflow: hidden;
}

.hero-left h2 {
  font-family: var(--font-serif);
  font-size: 1.85rem;
  font-weight: 700;
  color: var(--text-primary);
}

.hero-left h2 span { color: var(--accent-gold); }

.hero-left p {
  font-size: 0.85rem;
  color: var(--text-secondary);
  max-width: 620px;
  margin-top: 0.35rem;
  font-weight: 500;
}

.metrics-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1.25rem;
  margin-bottom: 1.75rem;
}

.metric-card {
  background-color: var(--bg-surface);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  padding: 1.35rem;
  box-shadow: var(--shadow-xs);
  transition: all var(--transition-fast);
}

.metric-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-sm);
  border-color: var(--border-medium);
}

.metric-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 0.65rem;
}

.metric-title {
  font-size: 0.7rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-primary);
}

.metric-icon {
  width: 34px;
  height: 34px;
  border-radius: var(--radius-sm);
  background-color: var(--bg-surface-elevated);
  color: var(--accent-gold);
  display: flex;
  align-items: center;
  justify-content: center;
}

.metric-val {
  font-family: var(--font-serif);
  font-size: 1.85rem;
  font-weight: 700;
  color: var(--text-primary);
  line-height: 1.1;
}

.metric-subtext {
  font-size: 0.75rem;
  color: var(--text-secondary);
  margin-top: 0.35rem;
  font-weight: 600;
}

.dashboard-split-grid {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 1.5rem;
}

.dash-card {
  background-color: var(--bg-surface);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  padding: 1.5rem;
  box-shadow: var(--shadow-xs);
}

.dash-card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 1.25rem;
}

.dash-card-title {
  font-family: var(--font-serif);
  font-size: 1.35rem;
  font-weight: 700;
  color: var(--text-primary);
}

/* ==========================================================================
   DATA TABLES & BADGES
   ========================================================================== */
.table-wrapper {
  overflow-x: auto;
  border: 1px solid var(--border-light);
  border-radius: var(--radius-sm);
  background-color: var(--bg-surface);
}

.app-data-table {
  width: 100%;
  border-collapse: collapse;
  text-align: left;
  font-size: 0.825rem;
}

.app-data-table th {
  background-color: var(--bg-surface-elevated);
  color: var(--text-primary);
  font-size: 0.68rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 0.85rem 1rem;
  border-bottom: 2px solid var(--border-medium);
}

.app-data-table td {
  padding: 0.85rem 1rem;
  border-bottom: 1px solid var(--border-light);
  color: var(--text-primary);
  vertical-align: middle;
}

.app-data-table tbody tr:last-child td { border-bottom: none; }
.app-data-table tbody tr:hover { background-color: rgba(180, 140, 54, 0.03); }

/* BADGES */
.badge {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  padding: 0.25rem 0.6rem;
  border-radius: var(--radius-pill);
  text-transform: uppercase;
}

.badge-approved { background-color: var(--status-approved-bg); color: var(--status-approved-text); font-weight: 800; }
.badge-pending { background-color: var(--status-pending-bg); color: var(--status-pending-text); font-weight: 800; }
.badge-draft { background-color: var(--status-draft-bg); color: var(--status-draft-text); font-weight: 800; }
.badge-exec { background-color: var(--status-exec-bg); color: var(--status-exec-text); font-weight: 800; }
.badge-gold {
  background-color: var(--accent-gold-subtle);
  color: var(--accent-gold);
  border: 1px solid var(--accent-gold-border);
  font-weight: 800;
}

/* ==========================================================================
   CRM KANBAN
   ========================================================================== */
.crm-kanban-board {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1.25rem;
  margin-top: 1.5rem;
  overflow-x: auto;
  padding-bottom: 1rem;
}

.kanban-col {
  background-color: var(--bg-surface-elevated);
  border-radius: var(--radius-md);
  border: 1px solid var(--border-light);
  padding: 1rem;
  display: flex;
  flex-direction: column;
  min-height: 420px;
}

.kanban-col-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-bottom: 0.75rem;
  margin-bottom: 0.75rem;
  border-bottom: 1px solid var(--border-light);
}

.kanban-col-title {
  font-size: 0.75rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-primary);
}

.kanban-count-pill {
  background: var(--bg-surface);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-pill);
  padding: 0.1rem 0.5rem;
  font-size: 0.68rem;
  font-weight: 700;
  color: var(--text-secondary);
}

.kanban-cards-list {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  flex: 1;
}

.lead-kanban-card {
  background-color: var(--bg-surface);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-sm);
  padding: 0.85rem;
  box-shadow: var(--shadow-xs);
  transition: all var(--transition-fast);
}

.lead-kanban-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-sm);
  border-color: var(--border-medium);
}

.lead-card-name { font-weight: 800; font-size: 0.875rem; color: var(--text-primary); }
.lead-card-scope { font-size: 0.75rem; color: var(--text-secondary); margin: 0.25rem 0 0.5rem 0; font-weight: 500; }

.lead-card-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-top: 1px solid var(--border-light);
  padding-top: 0.5rem;
  margin-top: 0.5rem;
}

/* ==========================================================================
   QUOTATION EDITOR & ROOM CARDS
   ========================================================================== */
.editor-header-bar {
  background-color: var(--bg-surface);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  padding: 1.25rem 1.75rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 1.5rem;
}

.room-section-card {
  background-color: var(--bg-surface);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  margin-bottom: 1.5rem;
  overflow: hidden;
  box-shadow: var(--shadow-xs);
}

.room-section-header {
  background-color: var(--bg-surface-elevated);
  padding: 0.85rem 1.25rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid var(--border-light);
}

.room-title-input {
  font-family: var(--font-serif);
  font-size: 1.25rem;
  font-weight: 700;
  background: transparent;
  border: 1px solid transparent;
  padding: 0.2rem 0.4rem;
  border-radius: var(--radius-xs);
  color: var(--text-primary);
}

.room-title-input:focus {
  background-color: var(--bg-surface);
  border-color: var(--accent-gold);
  outline: none;
}

.room-items-table { width: 100%; border-collapse: collapse; }

.room-items-table th {
  background-color: var(--bg-surface-elevated);
  font-size: 0.65rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-primary);
  padding: 0.65rem 0.85rem;
  border-bottom: 1px solid var(--border-light);
}

.room-items-table td {
  padding: 0.5rem 0.85rem;
  border-bottom: 1px solid var(--border-light);
  color: var(--text-primary);
}

.table-input {
  width: 100%;
  padding: 0.35rem 0.5rem;
  font-size: 0.8rem;
  border: 1px solid transparent;
  border-radius: var(--radius-xs);
  background: transparent;
  color: var(--text-primary);
  font-family: var(--font-sans);
}

.table-input:hover { border-color: var(--border-medium); }
.table-input:focus {
  background-color: var(--bg-surface);
  border-color: var(--accent-gold);
  outline: none;
  box-shadow: 0 0 0 2px var(--accent-gold-subtle);
}

.room-section-footer {
  padding: 0.75rem 1.25rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  background-color: var(--bg-surface);
}

/* ==========================================================================
   MILESTONES & PAYMENTS ANALYTICS
   ========================================================================== */
.analytics-summary-box {
  background: var(--bg-surface);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  padding: 1.5rem 1.75rem;
  margin-bottom: 1.5rem;
  box-shadow: var(--shadow-xs);
}

.analytics-kpi-card {
  padding: 1rem 1.25rem;
  background: var(--bg-surface);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-sm);
}

.analytics-kpi-card.kpi-total { border-top: 3px solid #64748B; }
.analytics-kpi-card.kpi-collected { border-top: 3px solid var(--accent-emerald); }
.analytics-kpi-card.kpi-pending { border-top: 3px solid #EF4444; }

.progress-bar-container {
  width: 100%;
  height: 8px;
  background: var(--bg-surface-elevated);
  border-radius: var(--radius-pill);
  overflow: hidden;
  margin: 0.75rem 0 0.5rem 0;
}

.progress-bar-fill {
  height: 100%;
  background: linear-gradient(90deg, #B48C36 0%, #10B981 100%);
  border-radius: var(--radius-pill);
  transition: width 0.4s ease-out;
}

.milestone-stepper {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 0.75rem;
  margin: 1.5rem 0;
}

.milestone-step-card {
  background-color: var(--bg-surface);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  padding: 1rem;
  position: relative;
  transition: all var(--transition-fast);
}

.milestone-step-card.completed {
  border-color: var(--accent-emerald);
  background-color: rgba(16, 185, 129, 0.03);
}

.milestone-step-card.current {
  border-color: var(--accent-gold);
  background-color: rgba(180, 140, 54, 0.04);
}

.milestone-percent-badge {
  font-size: 0.85rem;
  font-weight: 800;
  color: var(--accent-gold);
}

.milestone-title-text {
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--text-primary);
  margin: 0.35rem 0 0.5rem 0;
  min-height: 2.2rem;
}

.milestone-amount-text {
  font-size: 0.875rem;
  font-weight: 800;
  color: var(--text-secondary);
}

/* ==========================================================================
   MODALS & FORMS
   ========================================================================== */
.doc-modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: rgba(15, 23, 42, 0.75);
  backdrop-filter: blur(6px);
  z-index: 1000;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 1.5rem;
  overflow-y: auto;
}

.doc-modal-overlay.active { display: flex; }

.doc-modal-container {
  background-color: var(--bg-surface);
  border-radius: var(--radius-md);
  max-width: 900px;
  width: 100%;
  max-height: 90vh;
  display: flex;
  flex-direction: column;
  box-shadow: var(--shadow-dark);
  overflow: hidden;
  animation: modalPop 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}

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

.doc-modal-bar {
  background-color: #0F172A !important;
  color: #FFFFFF !important;
  padding: 1rem 1.5rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid var(--border-dark);
}

.doc-modal-title {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  font-family: var(--font-serif);
  font-size: 1.15rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  color: #FFFFFF !important;
}

.close-btn {
  background: transparent;
  border: none;
  color: #94A3B8;
  font-size: 1.4rem;
  cursor: pointer;
  line-height: 1;
}

.close-btn:hover { color: #FFFFFF; }
.doc-modal-body { padding: 1.75rem; overflow-y: auto; flex: 1; }

.modal-form-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1.25rem;
}

.form-group { display: flex; flex-direction: column; gap: 0.35rem; }
.form-group.full-width { grid-column: span 2; }

.form-label {
  font-size: 0.7rem;
  font-weight: 800;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--text-primary);
}

.form-control {
  font-family: var(--font-sans);
  font-size: 0.85rem;
  padding: 0.6rem 0.85rem;
  border: 1px solid var(--border-medium);
  border-radius: var(--radius-sm);
  background-color: var(--bg-surface);
  color: var(--text-primary);
  transition: all var(--transition-fast);
}

.form-control:focus {
  border-color: var(--accent-gold);
  outline: none;
  box-shadow: 0 0 0 3px var(--accent-gold-subtle);
}

.form-control.is-invalid {
  border-color: #EF4444 !important;
  background-color: rgba(239, 68, 68, 0.03) !important;
  box-shadow: 0 0 0 3px rgba(239, 68, 68, 0.12) !important;
}

/* ==========================================================================
   SWITCH TOGGLE & COUPON APPLY CARD STYLES
   ========================================================================== */
.switch-toggle {
  position: relative;
  display: inline-block;
  width: 48px;
  height: 26px;
}

.switch-toggle input {
  opacity: 0;
  width: 0;
  height: 0;
}

.slider {
  position: absolute;
  cursor: pointer;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: #CBD5E1;
  transition: .25s;
  border-radius: 26px;
}

.slider:before {
  position: absolute;
  content: "";
  height: 20px;
  width: 20px;
  left: 3px;
  bottom: 3px;
  background-color: white;
  transition: .25s;
  border-radius: 50%;
  box-shadow: 0 1px 3px rgba(0,0,0,0.2);
}

input:checked + .slider {
  background-color: #B48C36;
}

input:checked + .slider:before {
  transform: translateX(22px);
}

.coupon-apply-card {
  background: var(--bg-surface);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  padding: 1.25rem 1.5rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 1.5rem;
  flex-wrap: wrap;
  gap: 1rem;
}

.wa-client-badge {
  background: var(--bg-surface-elevated);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-sm);
  padding: 0.85rem 1.15rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 1rem;
}

.wa-template-pills {
  display: flex;
  gap: 0.5rem;
  overflow-x: auto;
  padding-bottom: 0.5rem;
  margin-bottom: 1rem;
}

.wa-tab-pill {
  padding: 0.45rem 0.85rem;
  font-size: 0.75rem;
  font-weight: 700;
  border-radius: var(--radius-pill);
  border: 1px solid var(--border-light);
  background: var(--bg-surface);
  color: var(--text-secondary);
  cursor: pointer;
  white-space: nowrap;
  transition: all var(--transition-fast);
}

.wa-tab-pill:hover {
  border-color: var(--accent-gold);
  color: var(--text-primary);
}

.wa-tab-pill.active {
  background: #10B981;
  color: #FFFFFF;
  border-color: #10B981;
}

.wa-preview-textarea {
  width: 100%;
  height: 210px;
  padding: 1rem;
  border: 1px solid var(--border-medium);
  border-radius: var(--radius-sm);
  background: var(--bg-surface);
  color: var(--text-primary);
  font-family: var(--font-sans);
  font-size: 0.825rem;
  line-height: 1.5;
  resize: vertical;
  margin-bottom: 1.25rem;
}

/* ==========================================================================
   AI ASSISTANT DRAWER (FLOATING SLIDING POPUP)
   ========================================================================== */
.ai-drawer {
  position: fixed !important;
  bottom: 24px !important;
  right: 24px !important;
  width: 400px !important;
  max-width: calc(100vw - 32px) !important;
  height: 540px !important;
  max-height: calc(100vh - 48px) !important;
  background: #0F172A !important;
  border: 1px solid rgba(255, 255, 255, 0.15) !important;
  border-radius: var(--radius-lg) !important;
  box-shadow: 0 20px 48px rgba(0, 0, 0, 0.45) !important;
  z-index: 10000 !important;
  display: none;
  flex-direction: column !important;
  overflow: hidden !important;
  animation: slideUp 0.25s cubic-bezier(0.16, 1, 0.3, 1) !important;
}

.ai-drawer.active {
  display: flex !important;
}

.ai-drawer-header {
  padding: 1rem 1.25rem;
  background: #0B0F19;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.ai-prompt-chips-wrap {
  padding: 0.75rem 1rem;
  background: #111726;
  display: flex;
  gap: 0.5rem;
  overflow-x: auto;
  white-space: nowrap;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.ai-prompt-chip {
  background: rgba(255, 255, 255, 0.08);
  color: #E2E8F0;
  font-size: 0.7rem;
  font-weight: 700;
  padding: 0.3rem 0.65rem;
  border-radius: var(--radius-pill);
  cursor: pointer;
  transition: all var(--transition-fast);
  flex-shrink: 0;
}

.ai-prompt-chip:hover {
  background: var(--accent-gold);
  color: #FFFFFF;
}

.ai-chat-body {
  flex: 1;
  padding: 1.25rem 1rem;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
  background: #0F172A;
}

.chat-msg {
  padding: 0.75rem 1rem;
  border-radius: var(--radius-md);
  font-size: 0.825rem;
  line-height: 1.5;
  max-width: 90%;
}

.chat-msg.bot {
  background: #1E293B;
  color: #F8FAFC !important;
  align-self: flex-start;
  border: 1px solid rgba(255, 255, 255, 0.08);
}

.chat-msg.user {
  background: linear-gradient(135deg, #B48C36 0%, #967024 100%);
  color: #FFFFFF !important;
  align-self: flex-end;
}

.ai-chat-footer {
  padding: 0.85rem 1rem;
  background: #0B0F19;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  display: flex;
  gap: 0.5rem;
}

/* ==========================================================================
   PRICING PLANS GRID & CARDS
   ========================================================================== */
.pricing-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
  margin-top: 1.5rem;
}

.pricing-card {
  background: var(--bg-surface);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  padding: 2rem;
  display: flex;
  flex-direction: column;
  transition: all var(--transition-fast);
  box-shadow: var(--shadow-xs);
}

.pricing-card.featured {
  border: 2px solid var(--accent-gold) !important;
  box-shadow: 0 8px 24px rgba(180, 140, 54, 0.15) !important;
  position: relative;
}

.plan-name {
  font-family: var(--font-serif);
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 0.25rem;
}

.plan-price {
  font-size: 2rem;
  font-weight: 800;
  color: var(--text-primary);
  margin: 1rem 0;
}

.plan-price span {
  font-size: 0.85rem;
  font-weight: 500;
  color: var(--text-secondary);
}

.plan-features-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  margin-bottom: 2rem;
  flex: 1;
}

.plan-features-list li {
  font-size: 0.85rem;
  color: var(--text-secondary);
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-weight: 500;
}

/* ==========================================================================
   DIGITAL SIGNATURE TABS & CANVAS
   ========================================================================== */
.signature-tabs {
  display: flex;
  gap: 0.5rem;
  margin-bottom: 1.25rem;
  border-bottom: 1px solid var(--border-light);
  padding-bottom: 0.5rem;
}

.sig-tab-btn {
  padding: 0.5rem 1rem;
  font-size: 0.8rem;
  font-weight: 700;
  border-radius: var(--radius-sm);
  border: 1px solid transparent;
  background: transparent;
  color: var(--text-secondary);
  cursor: pointer;
  transition: all var(--transition-fast);
}

.sig-tab-btn.active {
  background: var(--bg-surface-elevated);
  color: var(--text-primary);
  border-color: var(--border-medium);
}

.signature-canvas-box {
  border: 2px dashed var(--border-medium);
  border-radius: var(--radius-md);
  background: #FFFFFF;
  padding: 1rem;
  text-align: center;
  margin-bottom: 1rem;
}

.signature-pad-canvas {
  width: 100%;
  height: 180px;
  background: #FFFFFF;
  cursor: crosshair;
  touch-action: none;
}

/* ==========================================================================
   SUPER ADMIN KPIS & RECORD
   ========================================================================== */
.admin-kpi-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1.25rem;
  margin-bottom: 2rem;
}

.admin-card {
  background: var(--bg-surface);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  padding: 1.5rem;
  box-shadow: var(--shadow-xs);
}

/* ==========================================================================
   DYNAMIC THEMED FOOTER
   ========================================================================== */
.saas-footer {
  background: #0B0F19;
  color: #94A3B8;
  padding: 5rem 3.5rem 2rem 3.5rem;
  border-top: 1px solid var(--border-dark);
}

.footer-grid-4col {
  max-width: 1300px;
  margin: 0 auto 3.5rem auto;
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 3rem;
}

.footer-col-title {
  font-family: var(--font-serif);
  font-size: 1.15rem;
  font-weight: 700;
  color: #FFFFFF;
  letter-spacing: 0.05em;
  margin-bottom: 1.25rem;
  text-transform: uppercase;
}

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

.footer-link-item {
  color: #94A3B8;
  text-decoration: none;
  font-size: 0.825rem;
  transition: color var(--transition-fast);
  cursor: pointer;
}

.footer-link-item:hover {
  color: #D4AF37;
  transform: translateX(2px);
}

.footer-bottom-bar {
  max-width: 1300px;
  margin: 0 auto;
  padding-top: 2rem;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 0.75rem;
  color: #64748B;
  flex-wrap: wrap;
  gap: 1rem;
}

/* ==========================================================================
   ARCHITECTURAL PRINT & PDF
   ========================================================================== */
.quotation-paper {
  background-color: #FFFFFF;
  color: #0F172A;
  font-family: var(--font-sans);
  padding: 2.5rem;
  box-shadow: var(--shadow-md);
  border: 1px solid var(--border-light);
  line-height: 1.4;
}

.doc-top-grid {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 1.5rem;
  border-bottom: 2px solid #0F172A;
  padding-bottom: 1.5rem;
  margin-bottom: 1.5rem;
}

.doc-brand-title {
  font-family: var(--font-serif);
  font-size: 2rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  color: #0F172A;
}

.doc-meta-table { width: 100%; font-size: 0.8rem; border-collapse: collapse; }
.doc-meta-table td { padding: 0.35rem 0.55rem; border: 1px solid #CBD5E1; }
.doc-meta-table td.label { background-color: #F8FAFC; font-weight: 700; color: #475569; width: 35%; }

.doc-section-head {
  background-color: #1E293B;
  color: #FFFFFF;
  font-weight: 800;
  font-size: 0.85rem;
  letter-spacing: 0.05em;
  padding: 0.6rem 0.85rem;
  margin: 1.25rem 0 0.5rem 0;
  border: 1px solid #0F172A;
}

.doc-items-table { width: 100%; border-collapse: collapse; font-size: 0.775rem; margin-bottom: 1rem; }
.doc-items-table th {
  background-color: #F1F5F9;
  color: #0F172A;
  font-weight: 700;
  padding: 0.5rem 0.65rem;
  border: 1px solid var(--doc-border);
  text-align: left;
}
.doc-items-table td { padding: 0.45rem 0.65rem; border: 1px solid var(--doc-border); color: #0F172A; }

.doc-total-box {
  background-color: var(--doc-total-bg);
  border: 1px solid var(--doc-border);
  padding: 1rem 1.25rem;
  margin-top: 1.5rem;
}

.doc-signature-img {
  max-height: 55px;
  max-width: 160px;
  object-fit: contain;
  display: block;
  margin: 0 auto 0.25rem auto;
}

/* ==========================================================================
   RESPONSIVENESS
   ========================================================================== */
@media (max-width: 1024px) {
  .landing-hero-title { font-size: 2.6rem; }
  .features-grid-3col { grid-template-columns: repeat(2, 1fr); }
  .metrics-grid { grid-template-columns: repeat(2, 1fr); }
  .dashboard-split-grid { grid-template-columns: 1fr; }
  .crm-kanban-board { grid-template-columns: repeat(2, 1fr); }
  .milestone-stepper { grid-template-columns: repeat(3, 1fr); }
  .pricing-grid { grid-template-columns: 1fr; }
  .footer-grid-4col { grid-template-columns: 1fr 1fr; }
  .landing-section > div[style*="grid-template-columns: repeat(4, 1fr)"] {
    grid-template-columns: repeat(2, 1fr) !important;
  }
}

@media (max-width: 768px) {
  .landing-nav { padding: 1rem 1.5rem; }
  .nav-links { display: none; }
  .landing-hero-section { padding: 3.5rem 1.5rem; }
  .landing-hero-title { font-size: 2.1rem; }
  .calc-inputs-grid { grid-template-columns: 1fr; }
  .features-grid-3col { grid-template-columns: 1fr; }
  .workspace-layout.active { flex-direction: column; }
  .app-sidebar { width: 100%; height: auto; position: static; }
  .view-container { padding: 1.25rem; }
  .metrics-grid { grid-template-columns: 1fr; }
  .crm-kanban-board { grid-template-columns: 1fr; }
  .milestone-stepper { grid-template-columns: 1fr; }
  .modal-form-grid { grid-template-columns: 1fr; }
  .form-group.full-width { grid-column: span 1; }
  .footer-grid-4col { grid-template-columns: 1fr; }
  .landing-section > div[style*="grid-template-columns: repeat(4, 1fr)"] {
    grid-template-columns: 1fr !important;
  }
}



/* ==========================================================================
   SUPER ADMIN CONSOLE LIGHT THEME STYLES
   ========================================================================== */
.admin-view-wrap {
  max-width: 1440px;
  margin: 0 auto;
  padding: 2.5rem 3rem 5rem 3rem;
  background-color: var(--bg-primary);
  min-height: 100vh;
}

.admin-header-bar {
  background-color: var(--bg-surface);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  padding: 1.75rem 2.25rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 2rem;
  margin-bottom: 2rem;
  box-shadow: var(--shadow-xs);
  flex-wrap: wrap;
}

.admin-kpi-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1.25rem;
  margin-bottom: 2rem;
}

.admin-card {
  background-color: var(--bg-surface);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  padding: 1.5rem 1.75rem;
  box-shadow: var(--shadow-xs);
  transition: all var(--transition-fast);
}

.admin-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-sm);
  border-color: var(--border-medium);
}



/* ==========================================================================
   FAQ ACCORDION STYLES
   ========================================================================== */
.faq-card {
  background-color: var(--bg-surface);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  padding: 1.25rem 1.5rem;
  box-shadow: var(--shadow-xs);
  cursor: pointer;
  transition: all var(--transition-fast);
}

.faq-card:hover {
  border-color: var(--accent-gold-border);
  box-shadow: var(--shadow-sm);
}

.faq-question {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-family: var(--font-sans);
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--text-primary);
}

.faq-icon {
  font-size: 1.4rem;
  font-weight: 700;
  color: var(--accent-gold);
  line-height: 1;
  transition: transform var(--transition-fast);
}

.faq-card.active .faq-icon {
  transform: rotate(45deg);
}

.faq-answer {
  display: none;
  font-size: 0.85rem;
  color: var(--text-secondary);
  line-height: 1.65;
  margin-top: 0.85rem;
  padding-top: 0.85rem;
  border-top: 1px solid var(--border-light);
}

.faq-card.active .faq-answer {
  display: block;
  animation: fadeIn 0.25s ease-out;
}



/* ==========================================================================
   LIGHT MODE FOOTER (100% READABLE & CRISP)
   ========================================================================== */
[data-theme="light"] .saas-footer,
html[data-theme="light"] .saas-footer,
body[data-theme="light"] .saas-footer {
  background-color: #F1F5F9 !important;
  color: #334155 !important;
  border-top: 1px solid #CBD5E1 !important;
}

[data-theme="light"] .saas-footer .footer-col-title {
  color: #0F172A !important;
  font-weight: 800 !important;
}

[data-theme="light"] .saas-footer .footer-link-item {
  color: #334155 !important;
  font-weight: 600 !important;
}

[data-theme="light"] .saas-footer .footer-link-item:hover {
  color: #B48C36 !important;
}

[data-theme="light"] .saas-footer .brand-name-main {
  color: #0F172A !important;
}

[data-theme="light"] .saas-footer p,
[data-theme="light"] .saas-footer div {
  color: #334155 !important;
}

[data-theme="light"] .saas-footer strong {
  color: #0F172A !important;
}

[data-theme="light"] .footer-bottom-bar {
  border-top: 1px solid #CBD5E1 !important;
  color: #64748B !important;
}

[data-theme="light"] .footer-bottom-bar span {
  color: #64748B !important;
}



/* ==========================================================================
   ADVANCED MOBILE & LAPTOP RESPONSIVE STYLES
   ========================================================================== */
/* LAPTOP / DESKTOP (1025px - 1440px) */
@media (min-width: 1025px) {
  .landing-nav {
    padding: 1.25rem 3.5rem;
  }
  .features-grid-3col {
    grid-template-columns: repeat(3, 1fr);
  }
  .admin-kpi-grid {
    grid-template-columns: repeat(5, 1fr);
  }
}

/* TABLET (769px - 1024px) */
@media (max-width: 1024px) {
  .landing-nav {
    padding: 1rem 2rem;
  }
  .nav-links {
    gap: 1.25rem;
  }
  .landing-hero-title {
    font-size: 2.75rem;
  }
  .features-grid-3col {
    grid-template-columns: repeat(2, 1fr);
  }
  .admin-kpi-grid {
    grid-template-columns: repeat(3, 1fr);
  }
  .admin-view-wrap {
    padding: 2rem 2rem 4rem 2rem;
  }
  .footer-grid-4col {
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
  }
  #contact > div[style*="grid-template-columns"] {
    grid-template-columns: 1fr !important;
    gap: 1.5rem !important;
  }
}

/* MOBILE PHONES (Up to 768px) */
@media (max-width: 768px) {
  .landing-nav {
    padding: 0.85rem 1rem;
    flex-wrap: wrap;
    gap: 0.75rem;
  }
  .brand-title-text .brand-tagline-sub {
    display: none;
  }
  .nav-links {
    display: flex;
    width: 100%;
    overflow-x: auto;
    padding-bottom: 0.25rem;
    gap: 1rem;
    order: 3;
    -webkit-overflow-scrolling: touch;
  }
  .nav-link-item {
    font-size: 0.8rem;
    white-space: nowrap;
  }
  .landing-nav-actions {
    margin-left: auto;
  }
  .landing-nav-actions .btn {
    padding: 0.4rem 0.65rem;
    font-size: 0.75rem;
  }
  .landing-hero-section {
    padding: 3rem 1.25rem 2.5rem 1.25rem;
  }
  .landing-hero-title {
    font-size: 2rem;
    line-height: 1.2;
  }
  .landing-hero-sub {
    font-size: 0.875rem;
  }
  .hero-cta-group {
    flex-direction: column;
    width: 100%;
    gap: 0.75rem;
  }
  .hero-cta-group .btn,
  .hero-cta-group a.btn {
    width: 100%;
    justify-content: center;
  }
  .landing-section {
    padding: 3.5rem 1.25rem;
  }
  .features-grid-3col {
    grid-template-columns: 1fr;
  }
  .pricing-grid {
    grid-template-columns: 1fr;
  }
  .footer-grid-4col {
    grid-template-columns: 1fr;
    gap: 2rem;
  }
  .saas-footer {
    padding: 3.5rem 1.25rem 1.5rem 1.25rem;
  }
  #contact > div[style*="grid-template-columns"] {
    grid-template-columns: 1fr !important;
    gap: 1.5rem !important;
  }

  /* ADMIN CONSOLE MOBILE */
  .admin-view-wrap {
    padding: 1.25rem 1rem 3rem 1rem;
  }
  .admin-header-bar {
    padding: 1.25rem 1rem;
    flex-direction: column;
    align-items: flex-start;
    gap: 1.25rem;
  }
  .admin-header-bar > div:last-child {
    width: 100%;
    justify-content: space-between;
  }
  .admin-kpi-grid {
    grid-template-columns: 1fr;
    gap: 0.85rem;
  }

  /* WORKSPACE MOBILE */
  .workspace-layout.active {
    flex-direction: column;
  }
  .app-sidebar {
    width: 100%;
    height: auto;
    position: static;
    border-right: none;
    border-bottom: 1px solid var(--border-medium);
  }
  .view-container {
    padding: 1rem 0.85rem;
  }
  .metrics-grid {
    grid-template-columns: 1fr;
  }
  .dashboard-split-grid {
    grid-template-columns: 1fr;
  }
  .crm-kanban-board {
    grid-template-columns: 1fr;
  }

  /* MODALS MOBILE */
  .doc-modal-container {
    width: 95% !important;
    max-width: 95% !important;
    margin: 1rem auto !important;
    max-height: 90vh !important;
  }
  .modal-form-grid {
    grid-template-columns: 1fr !important;
  }
}



/* ==========================================================================
   MOBILE 3-LINE HAMBURGER & DRAWER STYLES
   ========================================================================== */
.mobile-menu-btn {
  display: none;
  flex-direction: column;
  justify-content: space-between;
  width: 28px;
  height: 20px;
  background: transparent;
  border: none;
  cursor: pointer;
  padding: 0;
  z-index: 1001;
}

.mobile-menu-btn span {
  display: block;
  width: 100%;
  height: 2.5px;
  background-color: var(--text-primary);
  border-radius: 2px;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.mobile-menu-btn.active span:nth-child(1) {
  transform: translateY(8.5px) rotate(45deg);
}

.mobile-menu-btn.active span:nth-child(2) {
  opacity: 0;
  transform: translateX(-10px);
}

.mobile-menu-btn.active span:nth-child(3) {
  transform: translateY(-8.5px) rotate(-45deg);
}

.mobile-nav-drawer {
  display: none;
  position: absolute;
  top: 100%;
  left: 0;
  width: 100%;
  background-color: var(--bg-surface);
  border-bottom: 1px solid var(--border-medium);
  box-shadow: var(--shadow-lg);
  padding: 1.25rem 1.5rem 1.5rem 1.5rem;
  z-index: 1000;
  flex-direction: column;
  gap: 0.85rem;
  animation: slideDown 0.25s ease-out;
}

.mobile-nav-drawer.active {
  display: flex;
}

.mobile-nav-item {
  color: var(--text-primary);
  text-decoration: none;
  font-size: 0.95rem;
  font-weight: 700;
  padding: 0.5rem 0.25rem;
  border-bottom: 1px solid var(--border-light);
  display: flex;
  align-items: center;
  gap: 0.5rem;
  transition: color var(--transition-fast);
}

.mobile-nav-item:hover {
  color: var(--accent-gold);
}

@keyframes slideDown {
  from {
    opacity: 0;
    transform: translateY(-10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@media (max-width: 768px) {
  .mobile-menu-btn {
    display: flex;
  }
  .nav-links {
    display: none !important;
  }
  .landing-nav-actions .btn {
    display: none;
  }
  .landing-nav {
    position: sticky;
    top: 0;
    background: var(--bg-surface);
    z-index: 999;
  }
}



/* ==========================================================================
   INFINITE AUTO-SWITCHING REVIEWS MARQUEE / CAROUSEL STYLES
   ========================================================================== */
.reviews-marquee-container {
  width: 100%;
  overflow: hidden;
  position: relative;
  padding: 1.5rem 0 2rem 0;
  mask-image: linear-gradient(to right, transparent, black 8%, black 92%, transparent);
  -webkit-mask-image: linear-gradient(to right, transparent, black 8%, black 92%, transparent);
}

.reviews-marquee-track {
  display: flex;
  gap: 1.5rem;
  width: max-content;
  animation: scrollReviews 40s linear infinite;
}

.reviews-marquee-container:hover .reviews-marquee-track {
  animation-play-state: paused;
}

.review-slide-card {
  width: 380px;
  max-width: 85vw;
  background-color: var(--bg-surface);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  padding: 1.75rem 1.75rem 1.5rem 1.75rem;
  box-shadow: var(--shadow-xs);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  transition: transform var(--transition-fast), border-color var(--transition-fast), box-shadow var(--transition-fast);
  flex-shrink: 0;
}

.review-slide-card:hover {
  transform: translateY(-4px);
  border-color: var(--accent-gold-border);
  box-shadow: var(--shadow-md);
}

@keyframes scrollReviews {
  0% {
    transform: translateX(0);
  }
  100% {
    transform: translateX(-50%);
  }
}

.reviews-nav-controls {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 1rem;
  margin-top: 1rem;
}

.review-ctrl-btn {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: var(--bg-surface);
  border: 1px solid var(--border-medium);
  color: var(--text-primary);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-size: 1rem;
  transition: all var(--transition-fast);
}

.review-ctrl-btn:hover {
  background: var(--accent-gold);
  color: #0F172A;
  border-color: var(--accent-gold);
}



/* THEME ADAPTIVE INPUTS & CARDS */
[data-theme="dark"] .form-control,
[data-theme="dark"] input[type="text"],
[data-theme="dark"] input[type="email"],
[data-theme="dark"] input[type="tel"],
[data-theme="dark"] input[type="password"],
[data-theme="dark"] input[type="number"],
[data-theme="dark"] select,
[data-theme="dark"] textarea {
  background-color: #1A2234 !important;
  color: #F8FAFC !important;
  border-color: #334155 !important;
}

[data-theme="dark"] .form-control::placeholder {
  color: #64748B !important;
}

[data-theme="dark"] .doc-modal-container {
  background-color: #111726 !important;
  color: #F8FAFC !important;
  border-color: #334155 !important;
}

[data-theme="dark"] .admin-view-wrap {
  background-color: #090D16 !important;
}


/* ==========================================================================
   ULTRA-LUXURY ATTRACTIVE PRICING & SUBSCRIPTION COUNTDOWN STYLES
   ========================================================================== */
.pricing-grid {
  display: grid;
  gap: 1.5rem;
}

.pricing-card {
  position: relative;
  background: var(--bg-surface);
  border-radius: var(--radius-md);
  padding: 2rem 1.75rem;
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.04);
}

.pricing-card:hover {
  transform: translateY(-8px);
  box-shadow: 0 16px 36px rgba(0, 0, 0, 0.1);
}

.pricing-card.tier-silver {
  border: 2px solid #94A3B8;
  background: linear-gradient(180deg, rgba(241, 245, 249, 0.6) 0%, rgba(255, 255, 255, 1) 100%);
}

.pricing-card.tier-gold {
  border: 2px solid var(--accent-gold);
  background: linear-gradient(180deg, rgba(255, 251, 235, 0.7) 0%, rgba(255, 255, 255, 1) 100%);
  box-shadow: 0 8px 30px rgba(180, 140, 54, 0.12);
}

.pricing-card.tier-platinum {
  border: 2px solid #0EA5E9;
  background: linear-gradient(180deg, rgba(240, 249, 255, 0.8) 0%, rgba(255, 255, 255, 1) 100%);
  box-shadow: 0 8px 30px rgba(14, 165, 233, 0.12);
}

.pricing-card.tier-diamond {
  border: 2px solid #A855F7;
  background: linear-gradient(180deg, rgba(250, 245, 255, 0.85) 0%, rgba(255, 255, 255, 1) 100%);
  box-shadow: 0 10px 35px rgba(168, 85, 247, 0.18);
}

[data-theme="dark"] .pricing-card.tier-silver {
  background: linear-gradient(180deg, #1A2234 0%, #111726 100%);
  border-color: #475569;
}
[data-theme="dark"] .pricing-card.tier-gold {
  background: linear-gradient(180deg, rgba(180, 140, 54, 0.12) 0%, #111726 100%);
}
[data-theme="dark"] .pricing-card.tier-platinum {
  background: linear-gradient(180deg, rgba(14, 165, 233, 0.12) 0%, #111726 100%);
}
[data-theme="dark"] .pricing-card.tier-diamond {
  background: linear-gradient(180deg, rgba(168, 85, 247, 0.14) 0%, #111726 100%);
}

.plan-price-display {
  font-family: var(--font-serif);
  font-size: 2.2rem;
  font-weight: 800;
  line-height: 1.1;
  margin-bottom: 0.25rem;
}

.plan-sub-rate {
  font-size: 0.75rem;
  font-weight: 700;
  margin-bottom: 1.25rem;
}

/* Subscription Expiry Progress Meter */
.license-progress-track {
  width: 100%;
  height: 8px;
  background: rgba(0, 0, 0, 0.08);
  border-radius: 9999px;
  overflow: hidden;
  margin: 0.75rem 0 0.25rem 0;
}

[data-theme="dark"] .license-progress-track {
  background: rgba(255, 255, 255, 0.1);
}

.license-progress-fill {
  height: 100%;
  background: linear-gradient(90deg, #10B981 0%, #F59E0B 70%, #EF4444 100%);
  border-radius: 9999px;
  transition: width 0.6s ease-in-out;
}


/* 4-COLUMN UNIFIED HORIZONTAL ROW FOR PRICING */
.pricing-grid-4col {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 1.25rem;
  width: 100%;
}

@media (min-width: 1100px) {
  .pricing-grid-4col {
    grid-template-columns: repeat(4, 1fr) !important;
  }
}


/* ==========================================================================
   2x2 BALANCED LUXURY PRICING GRID (2 IN TOP ROW, 2 IN BOTTOM ROW)
   ========================================================================== */
.pricing-grid-2x2 {
  display: grid;
  grid-template-columns: 1fr;
  gap: 2rem;
  max-width: 1040px;
  margin: 0 auto;
  width: 100%;
}

@media (min-width: 768px) {
  .pricing-grid-2x2 {
    grid-template-columns: repeat(2, 1fr) !important;
    gap: 2rem !important;
  }
}

.admin-section-card {
  background: var(--bg-surface);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  padding: 1.75rem;
  margin-bottom: 2rem;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.04);
}
