/* ========================================
   KYC SpeedFire Protection - Design System
   White Enterprise Theme
   ======================================== */

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800;900&family=Outfit:wght@400;500;600;700;800;900&display=swap');

/* --- CSS Custom Properties --- */
:root {
  /* Colors - Light Enterprise */
  --bg-primary: #f7f8fa;
  --bg-secondary: #ffffff;
  --bg-tertiary: #f0f1f5;
  --bg-card: #ffffff;
  --bg-card-hover: #fafbfc;
  --bg-glass: rgba(0, 0, 0, 0.02);
  --bg-glass-hover: rgba(0, 0, 0, 0.04);

  --sf-red: #c41e24;
  --sf-red-hover: #d92b32;
  --sf-red-glow: rgba(196, 30, 36, 0.15);
  --sf-red-subtle: rgba(196, 30, 36, 0.06);
  --sf-dark-red: #8b1a1e;

  --sf-orange: #ef8f61;
  --sf-orange-glow: rgba(239, 143, 97, 0.15);

  --white: #ffffff;
  --text-primary: #1a1d26;
  --text-secondary: #5a6070;
  --text-muted: #8e95a5;

  --border-subtle: rgba(0, 0, 0, 0.08);
  --border-red: rgba(196, 30, 36, 0.2);

  --gradient-red: linear-gradient(135deg, #c41e24, #e63946);
  --gradient-red-dark: linear-gradient(135deg, #8b1a1e, #c41e24);
  --gradient-dark: linear-gradient(180deg, #f7f8fa, #ffffff);

  /* Typography */
  --font-heading: 'Outfit', sans-serif;
  --font-body: 'Inter', sans-serif;

  /* Spacing */
  --space-xs: 0.25rem;
  --space-sm: 0.5rem;
  --space-md: 1rem;
  --space-lg: 1.5rem;
  --space-xl: 2rem;
  --space-2xl: 3rem;
  --space-3xl: 4rem;
  --space-4xl: 6rem;

  /* Borders */
  --radius-sm: 6px;
  --radius-md: 10px;
  --radius-lg: 14px;
  --radius-xl: 20px;
  --radius-full: 9999px;

  /* Shadows */
  --shadow-sm: 0 1px 3px rgba(0,0,0,0.06), 0 1px 2px rgba(0,0,0,0.04);
  --shadow-md: 0 4px 12px rgba(0,0,0,0.06), 0 2px 4px rgba(0,0,0,0.04);
  --shadow-lg: 0 8px 30px rgba(0,0,0,0.08), 0 4px 8px rgba(0,0,0,0.04);
  --shadow-red: 0 4px 20px var(--sf-red-glow);

  /* Transitions */
  --ease-smooth: cubic-bezier(0.4, 0, 0.2, 1);
  --ease-spring: cubic-bezier(0.175, 0.885, 0.32, 1.275);
  --duration-fast: 200ms;
  --duration-normal: 350ms;
  --duration-slow: 500ms;
}

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

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

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

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

a {
  color: var(--sf-red);
  text-decoration: none;
  transition: color var(--duration-fast) var(--ease-smooth);
}
a:hover { color: var(--sf-red-hover); }

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-heading);
  font-weight: 700;
  line-height: 1.2;
}

/* --- Background Images (Faded) --- */
.bg-image-section {
  position: relative;
}

.bg-image-section::before {
  content: '';
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  opacity: 0.12;
  pointer-events: none;
  z-index: 0;
}

.bg-image-section > * {
  position: relative;
  z-index: 1;
}

.bg-image-section.bg-hero::before { background-image: url('images/hero.png'); }
.bg-image-section.bg-monitoring::before { background-image: url('images/monitoring.png'); }
.bg-image-section.bg-equipment::before { background-image: url('images/equipment.png'); }
.bg-image-section.bg-audit::before { background-image: url('images/audit.png'); }
.bg-image-section.bg-speedcheck::before { background-image: url('images/speedcheck.png'); }
.bg-image-section.bg-winter::before { background-image: url('images/winter.png'); }

/* --- Utility Classes --- */
.container {
  width: 100%;
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 var(--space-lg);
}

.gradient-text {
  background: var(--gradient-red);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* --- Top Bar (speedfire.ro style) --- */
.topbar {
  background: var(--sf-red);
  padding: 8px 0;
  font-size: 0.8rem;
  font-weight: 500;
  color: white;
  overflow: hidden;
}

.topbar .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.topbar-contact {
  display: flex;
  align-items: center;
  gap: var(--space-xl);
}

.topbar-contact a {
  color: white;
  display: flex;
  align-items: center;
  gap: 6px;
  font-weight: 500;
}
.topbar-contact a:hover {
  color: rgba(255,255,255,0.85);
}

.topbar-ticker {
  display: flex;
  gap: var(--space-xl);
  color: rgba(255,255,255,0.9);
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 1px;
}

.topbar-ticker span {
  white-space: nowrap;
  display: flex;
  align-items: center;
  gap: 6px;
}

.topbar-ticker span::before {
  content: '●';
  font-size: 6px;
  color: rgba(255,255,255,0.5);
}

/* --- Navigation (white bar like speedfire.ro) --- */
.navbar {
  position: sticky;
  top: 0;
  z-index: 1000;
  background: #ffffff;
  border-bottom: 1px solid rgba(0, 0, 0, 0.08);
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.06);
  padding: 0;
}

.navbar .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 68px;
}

.navbar-logo {
  display: flex;
  align-items: center;
  text-decoration: none;
}

.navbar-logo .logo-img {
  height: 52px;
  width: auto;
}

.navbar-links {
  display: flex;
  align-items: center;
  gap: var(--space-lg);
  list-style: none;
}

.navbar-links a {
  color: #333;
  font-size: 0.82rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.8px;
  transition: color var(--duration-fast) var(--ease-smooth);
  padding: var(--space-sm) 0;
  position: relative;
}

.navbar-links a::after {
  content: '';
  position: absolute;
  bottom: -2px;
  left: 0;
  width: 0;
  height: 2px;
  background: var(--sf-red);
  transition: width var(--duration-normal) var(--ease-smooth);
}

.navbar-links a:hover { color: var(--sf-red); }
.navbar-links a:hover::after { width: 100%; }

.navbar-cta {
  background: var(--sf-red) !important;
  color: white !important;
  padding: 8px 20px !important;
  border-radius: var(--radius-sm) !important;
  font-weight: 700 !important;
  text-transform: uppercase !important;
  font-size: 0.78rem !important;
  letter-spacing: 1px !important;
  transition: all var(--duration-fast) var(--ease-smooth) !important;
}

.navbar-cta:hover {
  background: var(--sf-red-hover) !important;
  transform: translateY(-1px);
  box-shadow: var(--shadow-red);
  color: white !important;
}

.navbar-cta::after { display: none !important; }

.mobile-menu-btn {
  display: none;
  background: none;
  border: none;
  color: var(--text-primary);
  font-size: 1.8rem;
  cursor: pointer;
  padding: var(--space-sm);
  transition: color var(--duration-fast) var(--ease-smooth);
}

.mobile-menu-btn:hover,
.mobile-menu-btn:focus {
  color: var(--sf-red);
  outline: none;
}

/* --- Page Header (replaces hero) --- */
.page-header {
  padding: var(--space-2xl) 0 var(--space-xl);
  border-bottom: 1px solid var(--border-subtle);
  position: relative;
  overflow: hidden;
  background: #ffffff;
}

.page-header::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image: url('images/hero.png');
  background-size: cover;
  background-position: center;
  opacity: 0.1;
  pointer-events: none;
}

.page-header .container {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-2xl);
}

.page-header-info {
  flex: 1;
}

.page-header-badge {
  display: inline-flex;
  align-items: center;
  gap: var(--space-sm);
  background: var(--sf-red-subtle);
  border: 1px solid var(--border-red);
  padding: 4px 14px;
  border-radius: var(--radius-full);
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--sf-red);
  text-transform: uppercase;
  letter-spacing: 1.5px;
  margin-bottom: var(--space-md);
}

.page-header h1 {
  font-size: clamp(1.6rem, 3.5vw, 2.4rem);
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: -0.5px;
  margin-bottom: var(--space-sm);
  line-height: 1.15;
}

.page-header p {
  color: var(--text-secondary);
  font-size: 0.92rem;
  max-width: 500px;
  line-height: 1.6;
}

.page-header-stats {
  display: flex;
  gap: var(--space-xl);
  flex-shrink: 0;
}

.stat-box {
  text-align: center;
  padding: var(--space-md) var(--space-lg);
  background: #ffffff;
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  min-width: 90px;
  box-shadow: var(--shadow-sm);
}

.stat-box .stat-value {
  font-family: var(--font-heading);
  font-size: 1.6rem;
  font-weight: 800;
  color: var(--sf-red);
}

.stat-box .stat-label {
  font-size: 0.7rem;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 1px;
  margin-top: 2px;
}

/* --- Client Info Form --- */
.client-section {
  padding: var(--space-2xl) 0;
}

.client-info {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: var(--space-xl);
  box-shadow: var(--shadow-md);
}

.client-info h3 {
  font-size: 1.1rem;
  margin-bottom: var(--space-lg);
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  text-transform: uppercase;
  letter-spacing: 1px;
  font-weight: 700;
}

.client-info h3 .section-line {
  width: 24px;
  height: 3px;
  background: var(--sf-red);
  border-radius: 2px;
}

.form-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--space-md);
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.form-group.full-width { grid-column: 1 / -1; }
.form-group.span-2 { grid-column: span 2; }

.form-group label {
  font-size: 0.72rem;
  font-weight: 600;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 1.2px;
}

.form-group input,
.form-group textarea,
.form-group select {
  background: #f7f8fa;
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  padding: 10px 14px;
  color: var(--text-primary);
  font-family: var(--font-body);
  font-size: 0.88rem;
  transition: all var(--duration-fast) var(--ease-smooth);
  outline: none;
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
  border-color: var(--sf-red);
  box-shadow: 0 0 0 3px var(--sf-red-glow);
}

.form-group input::placeholder,
.form-group textarea::placeholder {
  color: var(--text-muted);
}

.form-group textarea {
  min-height: 80px;
  resize: vertical;
}

/* --- Checklist Section --- */
.checklist-section {
  padding: var(--space-lg) 0 var(--space-3xl);
}

.section-heading {
  display: flex;
  align-items: center;
  gap: var(--space-md);
  margin-bottom: var(--space-lg);
}

.section-heading .section-line {
  width: 24px;
  height: 3px;
  background: var(--sf-red);
  border-radius: 2px;
}

.section-heading h2 {
  font-size: 1.1rem;
  text-transform: uppercase;
  letter-spacing: 1px;
  font-weight: 700;
}

/* Category Accordion */
.categories-wrapper {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.category-card {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  overflow: hidden;
  transition: all var(--duration-normal) var(--ease-smooth);
  box-shadow: var(--shadow-sm);
}

.category-card.active {
  border-color: var(--border-red);
  box-shadow: 0 0 15px rgba(196, 30, 36, 0.06);
}

.category-card.has-checked {
  border-color: rgba(196, 30, 36, 0.2);
}

.category-header {
  display: flex;
  align-items: center;
  gap: var(--space-md);
  padding: 14px 20px;
  cursor: pointer;
  transition: background var(--duration-fast) var(--ease-smooth);
  user-select: none;
}

.category-header:hover {
  background: var(--bg-glass-hover);
}

.category-number {
  width: 32px;
  height: 32px;
  background: var(--sf-red-subtle);
  border: 1px solid var(--border-red);
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 0.8rem;
  color: var(--sf-red);
  flex-shrink: 0;
  transition: all var(--duration-normal) var(--ease-smooth);
}

.category-card.active .category-number {
  background: var(--sf-red);
  border-color: transparent;
  color: white;
}

.category-title {
  flex: 1;
  font-family: var(--font-heading);
  font-weight: 600;
  font-size: 0.88rem;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.category-count {
  font-size: 0.72rem;
  color: var(--text-muted);
  background: var(--bg-tertiary);
  padding: 2px 10px;
  border-radius: var(--radius-full);
  font-weight: 500;
  font-family: var(--font-heading);
  transition: all var(--duration-fast) var(--ease-smooth);
}

.category-card.has-checked .category-count {
  color: var(--sf-red);
  background: var(--sf-red-subtle);
}

.category-toggle {
  width: 24px;
  height: 24px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-muted);
  transition: transform var(--duration-normal) var(--ease-smooth);
  font-size: 0.8rem;
}

.category-card.active .category-toggle {
  transform: rotate(180deg);
  color: var(--sf-red);
}

.category-body {
  max-height: 0;
  overflow: hidden;
  transition: max-height var(--duration-slow) var(--ease-smooth);
}

.category-card.active .category-body {
  max-height: 2000px;
}

.category-items {
  padding: 0 20px 16px;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

/* Sub-sections (category 17) */
.category-subsection {
  margin-top: var(--space-md);
  padding: var(--space-md);
  background: #f7f8fa;
  border-radius: var(--radius-sm);
  border-left: 3px solid var(--sf-red);
}

.category-subsection-title {
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 0.78rem;
  color: var(--sf-red);
  margin-bottom: var(--space-sm);
  text-transform: uppercase;
  letter-spacing: 1px;
  display: flex;
  align-items: center;
  gap: var(--space-sm);
}

/* Checkbox Items */
.checkbox-item {
  display: flex;
  align-items: flex-start;
  gap: var(--space-sm);
  padding: 8px 10px;
  border-radius: var(--radius-sm);
  transition: background var(--duration-fast) var(--ease-smooth);
  cursor: pointer;
}

.checkbox-item:hover {
  background: rgba(0, 0, 0, 0.02);
}

.checkbox-item input[type="checkbox"] {
  display: none;
}

.checkbox-custom {
  flex-shrink: 0;
  width: 20px;
  height: 20px;
  border: 2px solid rgba(0, 0, 0, 0.15);
  border-radius: 4px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all var(--duration-fast) var(--ease-smooth);
  margin-top: 1px;
}

.checkbox-item input[type="checkbox"]:checked + .checkbox-custom {
  background: var(--sf-red);
  border-color: transparent;
  box-shadow: 0 0 8px var(--sf-red-glow);
}

.checkbox-item input[type="checkbox"]:checked + .checkbox-custom::after {
  content: '✓';
  color: white;
  font-size: 0.7rem;
  font-weight: 700;
}

.checkbox-label {
  font-size: 0.85rem;
  color: var(--text-secondary);
  line-height: 1.5;
  transition: color var(--duration-fast) var(--ease-smooth);
}

.checkbox-item:hover .checkbox-label { color: var(--text-primary); }
.checkbox-item input[type="checkbox"]:checked ~ .checkbox-label { color: var(--text-primary); }

.checkbox-note {
  font-size: 0.75rem;
  color: var(--text-muted);
  font-style: italic;
  padding-left: calc(20px + var(--space-sm) + 10px);
  margin-top: 2px;
}

/* Select All Toggle */
.select-all-toggle {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  padding: 4px 10px;
  margin-bottom: 4px;
  font-size: 0.72rem;
  font-weight: 600;
  color: var(--sf-red);
  cursor: pointer;
  border-radius: var(--radius-sm);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  transition: background var(--duration-fast) var(--ease-smooth);
}

.select-all-toggle:hover {
  background: var(--sf-red-subtle);
}

/* --- SpeedCheck Banner --- */
.speedcheck-banner {
  margin: var(--space-xl) 0;
  background: #ffffff;
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  overflow: hidden;
  position: relative;
  box-shadow: var(--shadow-md);
}

.speedcheck-banner::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image: url('images/speedcheck.png');
  background-size: cover;
  background-position: center;
  opacity: 0.06;
  pointer-events: none;
}

.speedcheck-banner-inner {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  padding: var(--space-xl) var(--space-2xl);
  gap: var(--space-2xl);
}

.speedcheck-badge {
  flex-shrink: 0;
  width: 56px;
  height: 56px;
  background: var(--gradient-red);
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.6rem;
}

.speedcheck-text {
  flex: 1;
}

.speedcheck-text h3 {
  font-size: 1rem;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 4px;
}

.speedcheck-text p {
  font-size: 0.85rem;
  color: var(--text-secondary);
  line-height: 1.5;
  max-width: 550px;
}

.speedcheck-features-row {
  display: flex;
  gap: var(--space-lg);
  margin-top: var(--space-md);
  flex-wrap: wrap;
}

.speedcheck-feature {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 0.78rem;
  color: var(--text-secondary);
}

.speedcheck-feature span:first-child {
  color: var(--sf-red);
  font-size: 0.85rem;
}

.speedcheck-cta {
  flex-shrink: 0;
}

.btn-sf {
  display: inline-flex;
  align-items: center;
  gap: var(--space-sm);
  background: var(--sf-red);
  color: white;
  padding: 10px 22px;
  border-radius: var(--radius-sm);
  font-family: var(--font-heading);
  font-size: 0.78rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
  cursor: pointer;
  border: none;
  transition: all var(--duration-fast) var(--ease-smooth);
  text-decoration: none;
}

.btn-sf:hover {
  background: var(--sf-red-hover);
  color: white;
  transform: translateY(-1px);
  box-shadow: var(--shadow-red);
}

.btn-sf-outline {
  background: transparent;
  border: 1px solid var(--border-red);
  color: var(--sf-red);
}

.btn-sf-outline:hover {
  background: var(--sf-red-subtle);
  color: var(--sf-red-hover);
}

/* --- Submit Area --- */
.submit-area {
  padding: var(--space-2xl) 0;
  border-top: 1px solid var(--border-subtle);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-xl);
}

.submit-info {
  display: flex;
  align-items: center;
  gap: var(--space-lg);
}

.submit-counter {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  font-size: 0.9rem;
  color: var(--text-secondary);
}

.submit-counter .count {
  font-family: var(--font-heading);
  font-weight: 800;
  font-size: 1.4rem;
  color: var(--sf-red);
  transition: transform var(--duration-fast) var(--ease-smooth);
  display: inline-block;
}

.submit-note {
  font-size: 0.75rem;
  color: var(--text-muted);
  max-width: 300px;
}

.btn-submit {
  padding: 14px 40px;
  font-size: 0.85rem;
  font-weight: 700;
  border-radius: var(--radius-sm);
  background: var(--sf-red);
  color: white;
  border: none;
  cursor: pointer;
  transition: all var(--duration-normal) var(--ease-smooth);
  font-family: var(--font-heading);
  text-transform: uppercase;
  letter-spacing: 1.5px;
  display: flex;
  align-items: center;
  gap: var(--space-sm);
}

.btn-submit:hover {
  background: var(--sf-red-hover);
  transform: translateY(-2px);
  box-shadow: var(--shadow-red);
}

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

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

/* --- Footer --- */
.footer {
  background: #1a1d26;
  color: #d0d3db;
  border-top: none;
  padding: var(--space-2xl) 0 var(--space-lg);
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: var(--space-2xl);
  margin-bottom: var(--space-xl);
}

.footer-brand p {
  color: #8e95a5;
  font-size: 0.85rem;
  line-height: 1.7;
  max-width: 280px;
  margin-top: var(--space-md);
}

.footer-col h4 {
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 2px;
  color: #6b7280;
  margin-bottom: var(--space-md);
}

.footer-col ul {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.footer-col a {
  color: #9ca3af;
  font-size: 0.85rem;
  transition: color var(--duration-fast) var(--ease-smooth);
}
.footer-col a:hover { color: #ef4444; }

.footer-bottom {
  padding-top: var(--space-lg);
  border-top: 1px solid rgba(255,255,255,0.08);
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 0.78rem;
  color: #6b7280;
}

.footer-social {
  display: flex;
  gap: var(--space-sm);
}

.footer-social a {
  width: 34px;
  height: 34px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(255,255,255,0.05);
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: var(--radius-sm);
  color: #9ca3af;
  font-size: 0.9rem;
  transition: all var(--duration-fast) var(--ease-smooth);
}

.footer-social a:hover {
  background: var(--sf-red);
  border-color: transparent;
  color: white;
}

/* --- Toast --- */
.toast {
  position: fixed;
  bottom: -100px;
  left: 50%;
  transform: translateX(-50%);
  background: #ffffff;
  border: 1px solid var(--border-subtle);
  padding: 14px 28px;
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  gap: var(--space-md);
  z-index: 10000;
  transition: bottom var(--duration-slow) var(--ease-spring);
  box-shadow: var(--shadow-lg);
  color: var(--text-primary);
}

.toast.show { bottom: var(--space-xl); }
.toast-icon { font-size: 1.3rem; }
.toast-text { font-size: 0.88rem; font-weight: 500; }

/* --- Animations --- */
@keyframes fadeInUp {
  from { opacity: 0; transform: translateY(20px); }
  to { opacity: 1; transform: translateY(0); }
}

.reveal {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.5s var(--ease-smooth), transform 0.5s var(--ease-smooth);
}

.reveal.revealed {
  opacity: 1;
  transform: translateY(0);
}

/* --- Loading overlay --- */
.loading-overlay {
  position: fixed;
  inset: 0;
  background: var(--bg-primary);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 99999;
  transition: opacity 0.4s var(--ease-smooth);
}

.loading-overlay.hidden {
  opacity: 0;
  pointer-events: none;
}

.loading-spinner {
  width: 40px;
  height: 40px;
  border: 3px solid var(--border-subtle);
  border-top-color: var(--sf-red);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}

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

/* --- Responsive --- */
@media (max-width: 1024px) {
  .footer-grid {
    grid-template-columns: 1fr 1fr;
    gap: var(--space-xl);
  }
  .topbar-ticker { display: none; }
  .speedcheck-banner-inner { flex-direction: column; align-items: flex-start; }
  .speedcheck-cta { align-self: flex-start; }
}

@media (max-width: 768px) {
  .navbar-links {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(255, 255, 255, 0.98);
    backdrop-filter: blur(20px);
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: var(--space-xl);
    z-index: 999;
  }

  .navbar-links.active { display: flex; }
  .navbar-links a {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--text-primary);
    letter-spacing: 1px;
  }
  .mobile-menu-btn { display: block; z-index: 1001; }

  .form-grid { grid-template-columns: 1fr; }
  .form-group.span-2 { grid-column: span 1; }

  .page-header .container { flex-direction: column; gap: var(--space-lg); }
  .page-header-stats {
    width: 100%;
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: var(--space-sm);
  }
  .stat-box {
    min-width: 0;
    padding: var(--space-sm) var(--space-xs);
  }
  .stat-box .stat-value {
    font-size: 1.3rem;
  }
  .stat-box .stat-label {
    font-size: 0.65rem;
    letter-spacing: 0.5px;
  }

  .submit-area {
    flex-direction: column;
    align-items: stretch;
    text-align: center;
  }

  .submit-info { flex-direction: column; }

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

  .footer-bottom {
    flex-direction: column;
    gap: var(--space-md);
    text-align: center;
  }

  .category-header { padding: 12px 14px; }
  .category-items { padding: 0 14px 14px; }
}

@media (max-width: 480px) {
  .container { padding: 0 var(--space-md); }
  .client-info { padding: var(--space-lg); }
  .stat-box {
    padding: var(--space-xs) 2px;
  }
  .stat-box .stat-value {
    font-size: 1.15rem;
  }
  .stat-box .stat-label {
    font-size: 0.58rem;
    letter-spacing: 0.2px;
  }
}

/* --- Print styles --- */
@media print {
  .topbar, .navbar, .speedcheck-banner, .footer,
  .submit-area, .category-toggle, .select-all-toggle,
  .page-header-stats { display: none !important; }

  body { background: white; color: #1a1a1a; }
  .category-card { border: 1px solid #ddd; break-inside: avoid; }
  .category-body { max-height: none !important; }
  .checkbox-custom { border-color: #999; }
}
