/* MigrantEase Housing Companion - Modern Design System */

/* ===== SYSTEM STABILITY FIXES ===== */
/* Remove only problematic focus indicators that cause system bugs */
*, *:before, *:after {
  outline: none !important;
  -webkit-tap-highlight-color: transparent !important;
}

button:focus, a:focus, input:focus, textarea:focus, select:focus {
  outline: none !important;
}

/* Disable text selection to prevent system issues, but allow in form elements */
*:not(input):not(textarea):not([contenteditable])::selection {
  background: transparent !important;
}

*:not(input):not(textarea):not([contenteditable])::-moz-selection {
  background: transparent !important;
}

/* Enable proper text selection in form elements */
input::selection,
textarea::selection,
[contenteditable]::selection {
  background: #3b82f6 !important;
  color: white !important;
}

input::-moz-selection,
textarea::-moz-selection,
[contenteditable]::-moz-selection {
  background: #3b82f6 !important;
  color: white !important;
}

/* Ensure form elements are fully interactive */
input,
textarea,
select,
[contenteditable] {
  user-select: text !important;
  -webkit-user-select: text !important;
  -moz-user-select: text !important;
  -ms-user-select: text !important;
  pointer-events: auto !important;
  cursor: text !important;
}

input[type="button"],
input[type="submit"],
input[type="reset"],
button,
select {
  cursor: pointer !important;
}

/* Fix any potential conflicts with mobile styles */
@media (max-width: 768px) {
  input,
  textarea,
  select,
  [contenteditable] {
    user-select: text !important;
    -webkit-user-select: text !important;
    -moz-user-select: text !important;
    -ms-user-select: text !important;
    touch-action: manipulation !important;
  }
}

/* ===== TARGETED ANIMATION REMOVAL ===== */
/* Only disable visual animations that cause bouncing, preserve functionality */
/* EXCLUDE loading spinners from animation removal */
#analyze-button:not([class*="spinner"]):not([class*="loading"]), 
#analyze-button *:not([class*="spinner"]):not([class*="loading"]) {
  animation: none !important;
  transition: none !important;
  transform: none !important;
}

#analyze-button:hover:not([class*="spinner"]):not([class*="loading"]), 
#analyze-button:active:not([class*="spinner"]):not([class*="loading"]), 
#analyze-button:focus:not([class*="spinner"]):not([class*="loading"]), 
#analyze-button:disabled:not([class*="spinner"]):not([class*="loading"]) {
  animation: none !important;
  transition: none !important;
  transform: none !important;
}

/* Remove animations from form elements that cause visual movement */
.property-input:not([class*="spinner"]):not([class*="loading"]), 
.property-input:hover:not([class*="spinner"]):not([class*="loading"]), 
.property-input:focus:not([class*="spinner"]):not([class*="loading"]), 
.property-input:active:not([class*="spinner"]):not([class*="loading"]) {
  animation: none !important;
  transition: none !important;
  transform: none !important;
}

/* Remove animations from cards and containers that might bounce */
.unity-card:not([class*="spinner"]):not([class*="loading"]), 
.dashboard-card:not([class*="spinner"]):not([class*="loading"]) {
  animation: none !important;
  transition: none !important;
  transform: none !important;
}

.unity-card:hover:not([class*="spinner"]):not([class*="loading"]), 
.dashboard-card:hover:not([class*="spinner"]):not([class*="loading"]) {
  animation: none !important;
  transition: none !important;
  transform: none !important;
}

/* PRESERVE LOADING SPINNER ANIMATIONS */
.loading-spinner, .loading-spinner *, .spinner, .spinner *, 
[class*="loading-spinner"], [class*="loading-spinner"] *,
.mobile-loading-spinner, .mobile-loading-spinner *,
.dashboard-loading-mobile .loading-icon,
.analysis-loading-mobile .analysis-spinner,
.loading-state .loading-spinner {
  animation: unset !important;
  transition: unset !important;
  transform: unset !important;
}

/* Spinner keyframes */
@keyframes spin {
  0% { transform: rotate(0deg) !important; }
  100% { transform: rotate(360deg) !important; }
}

@keyframes mobile-spin {
  0% { transform: rotate(0deg) !important; }
  100% { transform: rotate(360deg) !important; }
}

/* Apply spinning animations */
.spinner,
.loading-spinner,
.mobile-loading-spinner,
.dashboard-loading-mobile .loading-icon,
.analysis-loading-mobile .analysis-spinner,
.loading-state .loading-spinner,
[class*="loading-spinner"] {
  animation: spin 1s linear infinite !important;
}

/* ===== DESIGN PRINCIPLES FOUNDATION ===== */
/* Unity & Rhythm: Consistent design tokens throughout */
:root {
  /* CONTRAST: Strong brand color relationships */
  --primary: #f97316;
  --primary-50: #fff7ed;
  --primary-100: #ffedd5;
  --primary-200: #fed7aa;
  --primary-light: #fb923c;
  --primary-dark: #ea580c;
  --primary-gradient: linear-gradient(135deg, #f97316 0%, #fb923c 100%);
  
  /* BALANCE: Sophisticated contrasting secondary */
  --secondary: #475569;
  --secondary-light: #64748b;
  --secondary-dark: #334155;
  --secondary-gradient: linear-gradient(135deg, #475569 0%, #64748b 100%);
  
  /* Accent Colors */
  --accent-blue: #3b82f6;
  --accent-green: #10b981;
  --accent-red: #ef4444;
  --accent-yellow: #f59e0b;
  
  /* Clean Background System */
  --bg-base: #ffffff;
  --bg-subtle: #f8fafc;
  --bg-muted: #f1f5f9;
  --bg-warm: #fef7ed;
  --bg-secondary: #f1f5f9;
  
  /* Professional Text System */
  --text-primary: #0f172a;
  --text-secondary: #475569;
  --text-muted: #64748b;
  --text-light: #94a3b8;
  --text-inverse: #ffffff;
  
  /* Enhanced Neutral Palette */
  --neutral-50: #f8fafc;
  --neutral-100: #f1f5f9;
  --neutral-200: #e2e8f0;
  --neutral-300: #cbd5e1;
  --neutral-400: #94a3b8;
  --neutral-500: #64748b;
  --neutral-600: #475569;
  --neutral-700: #334155;
  --neutral-800: #1e293b;
  --neutral-900: #0f172a;
  
  /* PROPORTION & RHYTHM: Harmonious spacing scale */
  --space-0: 0;
  --space-1: 0.25rem;    /* 4px */
  --space-2: 0.5rem;     /* 8px */
  --space-3: 0.75rem;    /* 12px */
  --space-4: 1rem;       /* 16px - Base unit */
  --space-5: 1.25rem;    /* 20px */
  --space-6: 1.5rem;     /* 24px */
  --space-8: 2rem;       /* 32px - 2x base */
  --space-10: 2.5rem;    /* 40px */
  --space-12: 3rem;      /* 48px - 3x base */
  --space-16: 4rem;      /* 64px - 4x base */
  --space-20: 5rem;      /* 80px - 5x base */
  --space-24: 6rem;      /* 96px - 6x base */
  
  /* UNITY: Consistent border radius scale */
  --radius-xs: 6px;
  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 16px;
  --radius-xl: 20px;
  --radius-2xl: 24px;
  --radius-3xl: 28px;
  --radius-full: 9999px;
  
  /* EMPHASIS: Typography scale for hierarchy */
  --font-size-xs: 0.75rem;      /* 12px */
  --font-size-sm: 0.875rem;     /* 14px */
  --font-size-base: 1rem;       /* 16px - Base */
  --font-size-lg: 1.125rem;     /* 18px */
  --font-size-xl: 1.25rem;      /* 20px */
  --font-size-2xl: 1.5rem;      /* 24px */
  --font-size-3xl: 1.875rem;    /* 30px */
  --font-size-4xl: 2.25rem;     /* 36px */
  --font-size-5xl: 3rem;        /* 48px */
  --font-size-6xl: 3.75rem;     /* 60px */
  
  /* MOVEMENT: Z-index layers for depth */
  --z-dropdown: 1000;
  --z-sticky: 1020;
  --z-fixed: 1030;
  --z-modal-backdrop: 1040;
  --z-modal: 1050;
  --z-popover: 1060;
  --z-tooltip: 1070;
  
  /* Modern Shadow System */
  --shadow-xs: 0 1px 2px 0 rgb(0 0 0 / 0.03);
  --shadow-sm: 0 2px 4px 0 rgb(0 0 0 / 0.05);
  --shadow-md: 0 4px 12px 0 rgb(0 0 0 / 0.08);
  --shadow-lg: 0 8px 24px 0 rgb(0 0 0 / 0.12);
  --shadow-xl: 0 16px 48px 0 rgb(0 0 0 / 0.15);
  --shadow-2xl: 0 24px 64px 0 rgb(0 0 0 / 0.2);
  --shadow-inner: inset 0 2px 4px 0 rgb(0 0 0 / 0.03);
  
  /* Brand Shadows */
  --shadow-primary: 0 4px 14px 0 rgba(249, 115, 22, 0.15);
  --shadow-secondary: 0 4px 14px 0 rgba(71, 85, 105, 0.15);
  
  /* Modern Animation System */
  --duration-75: 75ms;
  --duration-100: 100ms;
  --duration-150: 150ms;
  --duration-200: 200ms;
  --duration-300: 300ms;
  --duration-500: 500ms;
  --duration-700: 700ms;
  --duration-1000: 1000ms;
  
  --ease-linear: linear;
  --ease-in: cubic-bezier(0.4, 0, 1, 1);
  --ease-out: cubic-bezier(0, 0, 0.2, 1);
  --ease-in-out: cubic-bezier(0.4, 0, 0.2, 1);
  
  /* Typography Scale */
  --text-xs: 0.75rem;
  --text-sm: 0.875rem;
  --text-base: 1rem;
  --text-lg: 1.125rem;
  --text-xl: 1.25rem;
  --text-2xl: 1.5rem;
  --text-3xl: 1.875rem;
  --text-4xl: 2.25rem;
  --text-5xl: 3rem;
  --text-6xl: 3.75rem;
  --text-7xl: 4.5rem;
  --text-8xl: 6rem;
  --text-9xl: 8rem;
}

/* ===== DESIGN PRINCIPLES: COMPREHENSIVE IMPLEMENTATION ===== */

/* BALANCE: Visual weight distribution */
.balance-center {
  display: flex;
  align-items: center;
  justify-content: center;
}

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

.balance-asymmetric {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: var(--space-6);
}

.balance-symmetric {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-6);
}

/* CONTRAST: High-impact visual differences */
.contrast-high {
  background: var(--neutral-900);
  color: var(--text-inverse);
}

.contrast-medium {
  background: var(--neutral-100);
  color: var(--text-primary);
  border: 1px solid var(--neutral-300);
}

.contrast-subtle {
  background: var(--neutral-50);
  color: var(--text-secondary);
}

.contrast-brand {
  background: var(--primary-gradient);
  color: var(--text-inverse);
}

.contrast-accent {
  background: var(--accent-blue);
  color: var(--text-inverse);
}

/* EMPHASIS: Clear focal points */
.emphasis-primary {
  background: var(--primary-gradient);
  color: var(--text-inverse);
  font-weight: 700;
  font-size: var(--font-size-lg);
  padding: var(--space-4) var(--space-6);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-primary);
  transform: translateY(0);
  transition: all var(--duration-200) var(--ease-out);
}

.emphasis-primary:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-lg);
}

.emphasis-secondary {
  background: var(--secondary-gradient);
  color: var(--text-inverse);
  font-weight: 600;
  padding: var(--space-3) var(--space-5);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-md);
}

.emphasis-text {
  font-size: var(--font-size-2xl);
  font-weight: 700;
  color: var(--primary);
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.1);
}

.emphasis-icon {
  width: 3rem;
  height: 3rem;
  background: var(--primary-gradient);
  color: var(--text-inverse);
  border-radius: var(--radius-lg);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: var(--font-size-xl);
  box-shadow: var(--shadow-primary);
}

/* MOVEMENT: Guided visual flow */
.movement-flow {
  display: flex;
  flex-direction: column;
  gap: var(--space-8);
}

.movement-horizontal {
  display: flex;
  gap: var(--space-6);
  align-items: center;
}

.movement-cascade {
  display: grid;
  gap: var(--space-4);
  animation: cascadeIn 0.6s ease-out;
}

.movement-zigzag {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-8);
  align-items: center;
}

.movement-zigzag > *:nth-child(even) {
  order: -1;
}

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

.movement-guide {
  position: relative;
}

.movement-guide::after {
  content: '';
  position: absolute;
  bottom: -10px;
  left: 50%;
  transform: translateX(-50%);
  width: 0;
  height: 0;
  border-left: 8px solid transparent;
  border-right: 8px solid transparent;
  border-top: 8px solid var(--primary);
}

/* PROPORTION: Harmonious size relationships */
.proportion-golden {
  aspect-ratio: 1.618 / 1;
}

.proportion-square {
  aspect-ratio: 1 / 1;
}

.proportion-wide {
  aspect-ratio: 16 / 9;
}

.proportion-header {
  font-size: var(--font-size-4xl);
  line-height: 1.2;
  margin-bottom: var(--space-6);
}

.proportion-subheader {
  font-size: var(--font-size-2xl);
  line-height: 1.3;
  margin-bottom: var(--space-4);
}

.proportion-body {
  font-size: var(--font-size-base);
  line-height: 1.6;
  margin-bottom: var(--space-4);
}

.proportion-caption {
  font-size: var(--font-size-sm);
  line-height: 1.4;
  color: var(--text-muted);
}

/* RHYTHM: Consistent patterns and repetition */
.rhythm-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: var(--space-6);
}

.rhythm-list {
  display: flex;
  flex-direction: column;
  gap: var(--space-4);
}

.rhythm-horizontal {
  display: flex;
  gap: var(--space-4);
  flex-wrap: wrap;
}

.rhythm-pattern {
  background-image: 
    linear-gradient(45deg, var(--neutral-100) 25%, transparent 25%),
    linear-gradient(-45deg, var(--neutral-100) 25%, transparent 25%),
    linear-gradient(45deg, transparent 75%, var(--neutral-100) 75%),
    linear-gradient(-45deg, transparent 75%, var(--neutral-100) 75%);
  background-size: 20px 20px;
  background-position: 0 0, 0 10px, 10px -10px, -10px 0px;
}

.rhythm-pulse {
  animation: pulse 2s infinite;
}

@keyframes pulse {
  0%, 100% {
    opacity: 1;
    transform: scale(1);
  }
  50% {
    opacity: 0.8;
    transform: scale(1.02);
  }
}

/* UNITY: Cohesive design language */
.unity-card {
  background: var(--bg-base);
  border: 1px solid var(--neutral-200);
  border-radius: var(--radius-lg);
  padding: var(--space-6);
  box-shadow: var(--shadow-sm);
  transition: all var(--duration-200) var(--ease-out);
}

.unity-card:hover {
  box-shadow: var(--shadow-md);
  transform: translateY(-1px);
  border-color: var(--primary-light);
}

.unity-section {
  margin-bottom: var(--space-12);
  padding-bottom: var(--space-8);
  border-bottom: 1px solid var(--neutral-200);
}

.unity-section:last-child {
  border-bottom: none;
  margin-bottom: 0;
}

.unity-brand {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  font-weight: 600;
  color: var(--primary);
  letter-spacing: -0.025em;
}

.unity-text {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  color: var(--text-secondary);
  line-height: 1.6;
}

/* RESPONSIVE DESIGN PRINCIPLES */
@media (max-width: 768px) {
  .balance-asymmetric,
  .balance-symmetric {
    grid-template-columns: 1fr;
  }
  
  .movement-zigzag {
    grid-template-columns: 1fr;
  }
  
  .movement-zigzag > *:nth-child(even) {
    order: 0;
  }
  
  .proportion-header {
    font-size: var(--font-size-3xl);
  }
  
  .rhythm-grid {
    grid-template-columns: 1fr;
  }
}

/* ===== Base Styles ===== */
*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  font-size: var(--font-size-base);
  line-height: 1.6;
  color: var(--text-primary);
  background: var(--bg-base);
  min-height: 100vh;
  margin: 0;
  padding: 0;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
}

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

/* ===== Universal Font Family & Base Styling ===== */
*, 
*::before, 
*::after {
  box-sizing: border-box;
}

/* Apply Inter font to most elements, but exclude icons */
*:not(.fas):not(.far):not(.fab):not(.fal):not(.fad):not(.fa):not([class^="fa-"]):not([class*=" fa-"]):not(i) {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

/* Ensure FontAwesome icons always use the correct font */
i.fas, i.far, i.fab, i.fa, 
i[class^="fa-"], i[class*=" fa-"],
.fas, .far, .fab, .fa {
  font-family: "Font Awesome 6 Free" !important;
  font-style: normal !important;
  font-variant: normal !important;
  text-rendering: auto !important;
  -webkit-font-smoothing: antialiased !important;
  display: inline-block !important;
  font-weight: 900 !important;
}

/* Ensure all text elements use consistent typography */
h1, h2, h3, h4, h5, h6,
p, span, div, a, button, input, textarea, select, label,
.form-control, .btn, .card, .alert {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

/* Preserve icon fonts - Critical for proper icon display */
.fas, .far, .fab, .fal, .fad, .fa,
[class^="fa-"], [class*=" fa-"],
i.fas, i.far, i.fab, i.fal, i.fad, i.fa,
i[class^="fa"], i[class*=" fa"],
.fa::before, .fas::before, .far::before, .fab::before, .fal::before, .fad::before {
  font-family: "Font Awesome 6 Free" !important;
  font-style: normal !important;
  font-variant: normal !important;
  text-rendering: auto !important;
  -webkit-font-smoothing: antialiased !important;
  display: inline-block !important;
}

/* Specific FontAwesome weights */
.fas, .fa-solid {
  font-weight: 900 !important;
  font-family: "Font Awesome 6 Free" !important;
}

.far, .fa-regular {
  font-weight: 400 !important;
  font-family: "Font Awesome 6 Free" !important;
}

.fab, .fa-brands {
  font-weight: 400 !important;
  font-family: "Font Awesome 6 Brands" !important;
}

/* Override any conflicting styles for icons */
i[class*="fa-"]::before,
i.fas::before,
i.far::before,
i.fab::before {
  font-family: "Font Awesome 6 Free" !important;
  font-weight: 900 !important;
}

/* Lucide icons */
[data-lucide], .lucide {
  font-family: inherit !important;
}

/* ===== Modern Typography ===== */
h1, h2, h3, h4, h5, h6 {
  font-weight: 600;
  line-height: 1.3;
  margin-bottom: var(--space-4);
  color: var(--text-primary);
  letter-spacing: -0.01em;
}

h1 {
  font-size: var(--text-4xl);
  font-weight: 700;
  line-height: 1.2;
  margin-bottom: var(--space-6);
}

h2 {
  font-size: var(--text-4xl);
  font-weight: 700;
  line-height: 1.2;
  margin-bottom: var(--space-5);
  letter-spacing: -0.03em;
}

h3 {
  font-size: var(--text-3xl);
  font-weight: 600;
  line-height: 1.25;
  margin-bottom: var(--space-4);
  letter-spacing: -0.02em;
}

h4 {
  font-size: var(--text-2xl);
  font-weight: 600;
  line-height: 1.3;
  margin-bottom: var(--space-3);
}

h5 {
  font-size: var(--text-xl);
  font-weight: 600;
  line-height: 1.35;
  margin-bottom: var(--space-3);
}

h6 {
  font-size: var(--text-lg);
  font-weight: 600;
  line-height: 1.4;
  margin-bottom: var(--space-2);
}

p {
  color: var(--text-secondary);
  font-size: var(--font-size-base);
  line-height: 1.7;
  margin-bottom: var(--space-4);
  font-weight: 400;
}

.text-lead {
  font-size: var(--font-size-xl);
  line-height: 1.6;
  color: var(--text-secondary);
  font-weight: 400;
}

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

.text-small {
  font-size: var(--font-size-sm);
}

/* ===== Standardized Link Styling ===== */
a {
  color: var(--primary);
  text-decoration: none;
  font-weight: 500;
  transition: all var(--duration-200) var(--ease-out);
}

a:hover {
  color: var(--primary-dark);
  text-decoration: underline;
}

/* ===== Standardized Button Styling ===== */
.btn, button {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  font-size: var(--font-size-base);
  font-weight: 600;
  line-height: 1.5;
  border-radius: var(--radius-lg);
  padding: var(--space-3) var(--space-6);
  border: none;
  cursor: pointer;
  transition: all var(--duration-200) var(--ease-out);
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  text-decoration: none;
}

.btn-primary {
  background: linear-gradient(135deg, #f97316, #ea580c);
  color: white;
  box-shadow: 0 4px 12px rgba(249, 115, 22, 0.25);
  border: none;
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(249, 115, 22, 0.35);
  color: white;
  background: linear-gradient(135deg, #ea580c, #dc2626);
}

.btn-secondary {
  background: var(--neutral-100);
  color: var(--text-primary);
  border: 1px solid var(--neutral-300);
}

.btn-secondary:hover {
  background: var(--neutral-200);
  transform: translateY(-1px);
  color: var(--text-primary);
}

.btn-outline-primary {
  background: white;
  color: #f97316;
  border: 2px solid #f97316;
  box-shadow: 0 2px 8px rgba(249, 115, 22, 0.1);
}

.btn-outline-primary:hover {
  background: linear-gradient(135deg, #f97316, #ea580c);
  color: white;
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(249, 115, 22, 0.25);
  border-color: #ea580c;
}

/* ===== Standardized Form Styling ===== */
.form-control, input, textarea, select {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  font-size: var(--font-size-base);
  line-height: 1.5;
  padding: var(--space-3);
  border: 1px solid var(--neutral-300);
  border-radius: var(--radius-md);
  background: var(--bg-base);
  color: var(--text-primary);
  transition: all var(--duration-200) var(--ease-out);
}

.form-control:focus, input:focus, textarea:focus, select:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(249, 115, 22, 0.1);
  outline: none;
}

label {
  font-size: var(--font-size-sm);
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: var(--space-2);
  display: block;
}

/* ===== Modern Progress Indicator ===== */
.progress-container {
  background: var(--bg-base);
  border-bottom: 1px solid var(--neutral-200);
  padding: var(--space-6) 0;
  margin-bottom: var(--space-8);
  position: sticky;
  top: 0;
  z-index: 50;
}

.progress-steps {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: var(--space-8);
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 var(--space-4);
}

.progress-step {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-2);
  transition: all var(--duration-300) var(--ease-out);
  position: relative;
}



.step-number {
  width: 52px;
  height: 52px;
  border-radius: 50%;
  background: #e5e7eb;
  color: #9ca3af;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 16px;
  transition: all 0.3s ease;
  border: 3px solid #f3f4f6;
  position: relative;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

/* Completed step styling */
.progress-step.completed .step-number {
  background: linear-gradient(135deg, #10b981, #059669);
  color: white;
  border-color: #10b981;
  box-shadow: 0 4px 12px rgba(16, 185, 129, 0.25);
}

.progress-step.completed .step-number::before {
  content: '✓';
  font-size: 18px;
  font-weight: 900;
}

/* Active step styling */
.progress-step.active .step-number {
  background: linear-gradient(135deg, #f97316, #ea580c);
  color: white;
  border-color: #f97316;
  box-shadow: 0 6px 16px rgba(249, 115, 22, 0.3);
  transform: scale(1.08);
}

.step-label {
  font-size: 11px;
  font-weight: 600;
  color: #9ca3af;
  text-align: center;
  transition: all 0.3s ease;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  white-space: nowrap;
  line-height: 1.2;
}

.progress-step.completed .step-label {
  color: #10b981;
  font-weight: 700;
}

.progress-step.active .step-label {
  color: #f97316;
  font-weight: 700;
}

/* ===== Bottom Navigation ===== */
.bottom-nav {
  position: fixed !important;
  bottom: 0 !important;
  left: 0 !important;
  right: 0 !important;
  width: 100% !important;
  background: rgba(255, 255, 255, 0.95) !important;
  border-top: 1px solid #e5e7eb !important;
  z-index: 9999 !important;
  box-shadow: 0 -4px 16px rgba(0, 0, 0, 0.08) !important;
  backdrop-filter: blur(20px) !important;
  padding: 16px 0 !important;
}

.nav-buttons {
  display: flex !important;
  gap: 16px !important;
  align-items: center !important;
  justify-content: space-between !important;
  width: 100% !important;
  max-width: 1200px !important;
  margin: 0 auto !important;
  padding: 0 24px !important;
}

.step-info {
  font-size: 14px;
  color: white;
  font-weight: 600;
  background: linear-gradient(135deg, #f97316, #ea580c);
  padding: 8px 16px;
  border-radius: 20px;
  box-shadow: 0 2px 8px rgba(249, 115, 22, 0.2);
  letter-spacing: 0.025em;
}

/* ===== Progress Tracker ===== */
.progress-container {
  position: sticky;
  top: 0;
  background: rgba(255, 255, 255, 0.95);
  border-bottom: 1px solid #e5e7eb;
  z-index: 50;
  padding: 20px 0;
  transition: all 0.3s ease;
  backdrop-filter: blur(20px);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
}

.progress-steps {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  position: relative;
  max-width: 900px;
  margin: 0 auto;
  padding: 0 24px;
  gap: 16px;
}

.progress-step {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  position: relative;
  flex: 1;
  max-width: 100px;
  min-width: 60px;
}

/* ===== Main Content ===== */
.main-content {
  min-height: calc(100vh - 200px);
  padding-bottom: 120px !important;
}

/* ===== Modern Hero Section ===== */
.hero-section {
  background: var(--primary-gradient);
  color: var(--text-inverse);
  padding: var(--space-20) 0 var(--space-16);
  text-align: center;
  border-radius: 0 0 var(--radius-3xl) var(--radius-3xl);
  margin-bottom: var(--space-16);
  box-shadow: var(--shadow-2xl);
  position: relative;
  overflow: hidden;
}

.hero-section::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(45deg, rgba(255, 255, 255, 0.1) 0%, transparent 50%, rgba(255, 255, 255, 0.05) 100%);
  pointer-events: none;
}

.hero-section::after {
  content: '';
  position: absolute;
  bottom: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background: radial-gradient(circle, rgba(255, 255, 255, 0.1) 0%, transparent 70%);
  pointer-events: none;
  animation: float 6s ease-in-out infinite;
}

@keyframes float {
  0%, 100% { transform: translateY(0px) rotate(0deg); }
  50% { transform: translateY(-20px) rotate(180deg); }
}

.hero-content {
  max-width: 900px;
  margin: 0 auto;
  padding: 0 var(--space-6);
  position: relative;
  z-index: 10;
}

.hero-icon {
  margin-bottom: var(--space-8);
  animation: bounce 2s infinite;
}

@keyframes bounce {
  0%, 20%, 50%, 80%, 100% { transform: translateY(0); }
  40% { transform: translateY(-10px); }
  60% { transform: translateY(-5px); }
}

.hero-icon-svg {
  width: 64px;
  height: 64px;
  color: var(--primary);
  background: var(--bg-warm);
  padding: var(--space-4);
  border-radius: var(--radius-xl);
  border: 2px solid var(--primary);
}

.hero-icon:hover .hero-icon-svg {
  background: var(--primary);
  color: var(--text-inverse);
}

.hero-title {
  font-size: var(--text-4xl);
  font-weight: 700;
  margin-bottom: var(--space-4);
  color: var(--text-primary);
}

.hero-subtitle {
  font-size: var(--text-lg);
  color: var(--text-secondary);
  margin-bottom: var(--space-8);
  max-width: 600px;
  margin-left: auto;
  margin-right: auto;
}

.hero-cta {
  margin-bottom: var(--space-8);
}

.cta-button {
  font-size: var(--text-base);
  font-weight: 600;
  padding: var(--space-4) var(--space-6);
  border-radius: var(--radius-lg);
  border: none;
  background: var(--primary);
  color: var(--text-inverse);
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  transition: background-color var(--duration-200) var(--ease-out);
}

.cta-button::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(45deg, transparent, rgba(255, 255, 255, 0.3), transparent);
  transform: translateX(-100%);
  transition: transform var(--duration-500) var(--ease-out);
}

.cta-button:hover {
  background: var(--primary-dark);
}

.cta-button:hover::before {
  transform: translateX(100%);
}

.cta-button:active {
  transform: translateY(-2px) scale(1.02);
}

/* ===== Modern Features Section ===== */
.features-section {
  padding: var(--space-20) 0;
  background: var(--bg-secondary);
  border-radius: var(--radius-3xl);
  margin: var(--space-16) var(--space-4);
  box-shadow: var(--shadow-lg);
}

.feature-card {
  background: var(--bg-primary);
  border-radius: var(--radius-2xl);
  padding: var(--space-8);
  text-align: center;
  box-shadow: var(--shadow-sm);
  transition: all var(--duration-300) var(--ease-out);
  border: 2px solid var(--neutral-200);
  height: 100%;
  position: relative;
  overflow: hidden;
  backdrop-filter: blur(10px);
}



.feature-card:hover {
  transform: translateY(-8px) scale(1.02);
  box-shadow: var(--shadow-2xl);
  border-color: var(--primary);
}

.feature-card:hover::before {
  opacity: 0.05;
}

.feature-icon {
  margin-bottom: var(--space-6);
  position: relative;
  z-index: 10;
}

.feature-icon-svg {
  width: 64px;
  height: 64px;
  color: white;
  padding: var(--space-4);
  background: var(--primary);
  border-radius: var(--radius-lg);
  border: none;
  transition: all var(--duration-300) var(--ease-out);
  box-shadow: var(--shadow-lg);
}

.feature-card:hover .feature-icon-svg {
  transform: scale(1.1);
  background: var(--primary-light);
  box-shadow: var(--shadow-xl);
}

.feature-title {
  font-size: var(--text-2xl);
  color: var(--text-primary);
  margin-bottom: var(--space-4);
  font-weight: 600;
  letter-spacing: -0.01em;
  position: relative;
  z-index: 10;
}

.feature-description {
  color: var(--text-secondary);
  line-height: 1.7;
  font-size: var(--text-base);
  position: relative;
  z-index: 10;
}

.feature-list {
  list-style: none;
  padding: 0;
  margin: 0;
  position: relative;
  z-index: 10;
}

.feature-list li {
  color: var(--text-secondary);
  font-size: var(--text-sm);
  line-height: 1.6;
  margin-bottom: var(--space-2);
  padding-left: var(--space-6);
  position: relative;
}

.feature-list li::before {
  content: '•';
  color: var(--primary);
  font-weight: 700;
  position: absolute;
  left: 0;
  top: 0;
}

/* ===== Modern How It Works Section ===== */
.how-it-works-section {
  padding: var(--space-20) 0;
  background: var(--bg-warm);
  border-radius: var(--radius-3xl);
  margin: var(--space-16) var(--space-4);
  box-shadow: var(--shadow-lg);
  border: 1px solid var(--neutral-200);
}

.netherlands-market-info {
  margin-top: var(--space-16);
  padding-top: var(--space-16);
  border-top: 2px solid var(--neutral-200);
}

.market-card {
  background: var(--bg-primary);
  border-radius: var(--radius-2xl);
  padding: var(--space-8);
  text-align: center;
  box-shadow: var(--shadow-md);
  border: 2px solid var(--neutral-200);
}

.market-card h3 {
  color: var(--text-primary);
  margin-bottom: var(--space-4);
  font-weight: 600;
}

.market-card p {
  color: var(--text-secondary);
  line-height: 1.7;
  margin-bottom: 0;
}

.netherlands-flag {
  font-size: 3rem;
  margin-bottom: var(--space-4);
  display: block;
}

.section-title {
  text-align: center;
  font-size: var(--text-4xl);
  color: var(--text-primary);
  margin-bottom: var(--space-12);
  font-weight: 700;
  letter-spacing: -0.02em;
}

.step-card {
  text-align: center;
  padding: var(--space-8);
  background: var(--bg-primary);
  border-radius: var(--radius-2xl);
  box-shadow: var(--shadow-sm);
  transition: all var(--duration-300) var(--ease-out);
  border: 2px solid var(--neutral-200);
  height: 100%;
  position: relative;
  overflow: hidden;
}

.step-card::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, var(--primary), var(--primary-light));
  opacity: 0;
  transition: opacity var(--duration-300) var(--ease-out);
}

.step-card:hover {
  box-shadow: var(--shadow-xl);
  transform: translateY(-6px);
  border-color: var(--primary);
}

.step-card:hover::before {
  opacity: 0.03;
}

.step-number {
  width: 72px;
  height: 72px;
  border-radius: var(--radius-lg);
  background: var(--primary-gradient);
  color: var(--text-inverse);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: var(--text-2xl);
  font-weight: 800;
  margin: 0 auto var(--space-6);
  box-shadow: var(--shadow-lg);
  border: 3px solid rgba(255, 255, 255, 0.2);
  transition: all var(--duration-300) var(--ease-out);
  position: relative;
  z-index: 10;
}

.step-card:hover .step-number {
  transform: scale(1.1) rotate(5deg);
  box-shadow: var(--shadow-2xl);
}

.step-title {
  font-size: var(--text-xl);
  margin-bottom: var(--space-3);
  color: var(--text-primary);
  font-weight: 600;
  letter-spacing: -0.01em;
  position: relative;
  z-index: 10;
}

.step-description {
  color: var(--text-secondary);
  line-height: 1.6;
  font-size: var(--text-base);
  position: relative;
  z-index: 10;
}

/* ===== Modern Netherlands Info ===== */
.netherlands-info {
  padding: var(--space-20) 0;
}

.info-card {
  background: var(--bg-primary);
  border-radius: var(--radius-2xl);
  padding: var(--space-10);
  box-shadow: var(--shadow-xl);
  border: 2px solid var(--neutral-200);
  text-align: center;
  position: relative;
  overflow: hidden;
  backdrop-filter: blur(10px);
}

.info-card::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, var(--accent-blue), var(--accent-purple));
  opacity: 0.03;
}

.info-title {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-4);
  font-size: var(--text-2xl);
  margin-bottom: var(--space-6);
  color: var(--text-primary);
  font-weight: 600;
  letter-spacing: -0.01em;
  position: relative;
  z-index: 10;
}

.info-icon {
  color: var(--accent-blue);
  padding: var(--space-3);
  background: rgba(59, 130, 246, 0.1);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
}

.info-description {
  color: var(--text-secondary);
  line-height: 1.7;
  font-size: var(--text-lg);
  position: relative;
  z-index: 10;
  max-width: 600px;
  margin: 0 auto;
}

/* ===== Modern Form Sections ===== */
.form-section {
  max-width: 900px;
  margin: 0 auto;
  padding: var(--space-8);
}

.section-header {
  text-align: center;
  margin-bottom: var(--space-12);
}

.section-icon {
  margin-bottom: var(--space-8);
  animation: pulse 3s infinite;
}

@keyframes pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.8; }
}

.section-icon-svg {
  width: 80px;
  height: 80px;
  color: var(--text-inverse);
  padding: var(--space-5);
  background: var(--primary-gradient);
  border-radius: var(--radius-2xl);
  box-shadow: var(--shadow-lg);
  border: none;
  transition: all var(--duration-300) var(--ease-out);
}

.section-icon:hover .section-icon-svg {
  transform: scale(1.1) rotate(5deg);
  background: var(--primary-hover);
  box-shadow: var(--shadow-2xl);
}

.section-title {
  font-size: var(--text-4xl);
  margin-bottom: var(--space-4);
  letter-spacing: -0.02em;
}

.section-subtitle {
  font-size: var(--text-xl);
  color: var(--text-secondary);
  max-width: 650px;
  margin: 0 auto;
  line-height: 1.6;
  font-weight: 400;
}

/* ===== Clean Form Design ===== */
.housing-form {
  background: var(--bg-base);
  border-radius: var(--radius-lg);
  padding: var(--space-8);
  border: 1px solid var(--neutral-200);
  max-width: 800px;
  margin: 0 auto;
}

.housing-form::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, var(--primary), var(--primary-light));
  opacity: 0.02;
}

.form-group {
  margin-bottom: var(--space-6);
  position: relative;
  z-index: 10;
}

.form-label {
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: var(--space-3);
  display: block;
  font-size: var(--text-sm);
  letter-spacing: 0.025em;
  text-transform: uppercase;
}

.form-control, .form-select {
  border: 1px solid var(--neutral-300);
  border-radius: var(--radius-md);
  padding: var(--space-3);
  font-size: var(--text-sm);
  background: var(--bg-base);
  width: 100%;
  font-family: inherit;
  transition: border-color var(--duration-200) var(--ease-out);
}

.form-control:focus, .form-select:focus {
  border-color: var(--primary);
  outline: none;
  box-shadow: 0 0 0 3px rgba(249, 115, 22, 0.1);
}

.form-control:hover, .form-select:hover {
  border-color: var(--neutral-300);
  box-shadow: var(--shadow-md);
}

.form-text {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  font-size: var(--text-sm);
  color: var(--text-tertiary);
  margin-top: var(--space-2);
  padding: var(--space-2) var(--space-3);
  background: var(--bg-secondary);
  border-radius: var(--radius-lg);
}

.form-text i {
  color: var(--accent-blue);
  flex-shrink: 0;
}

/* ===== Modern Checkbox Grid ===== */
.checkbox-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: var(--space-4);
  margin-top: var(--space-4);
}

.form-check {
  background: var(--bg-primary);
  border-radius: var(--radius-xl);
  padding: var(--space-5);
  border: 2px solid var(--neutral-200);
  transition: all var(--duration-200) var(--ease-out);
  position: relative;
  overflow: hidden;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: var(--space-3);
  box-shadow: var(--shadow-sm);
}

.form-check::before {
  content: '';
  position: absolute;
  inset: 0;
  background: var(--primary-gradient);
  opacity: 0;
  transition: opacity var(--duration-200) var(--ease-out);
}

.form-check:hover {
  background: var(--primary-50);
  border-color: var(--primary);
  transform: translateY(-2px);
  box-shadow: var(--shadow-lg);
}

.form-check:hover::before {
  opacity: 0.05;
}

/* Complete Checkbox Override - Maximum Specificity */
.checkbox-grid .form-check input[type="checkbox"].form-check-input,
.form-check input[type="checkbox"],
input[type="checkbox"].form-check-input {
  -webkit-appearance: none !important;
  -moz-appearance: none !important;
  appearance: none !important;
  background: #faf8f5 !important;
  background-color: #faf8f5 !important;
  background-image: none !important;
  border: 3px solid #d1d5db !important;
  border-radius: 8px !important;
  width: 24px !important;
  height: 24px !important;
  margin: 0 !important;
  padding: 0 !important;
  position: relative !important;
  cursor: pointer !important;
  outline: none !important;
  box-shadow: none !important;
  transition: all 0.2s ease !important;
  flex-shrink: 0 !important;
  vertical-align: top !important;
}

.checkbox-grid .form-check input[type="checkbox"]:focus,
.form-check input[type="checkbox"]:focus,
input[type="checkbox"].form-check-input:focus {
  outline: none !important;
  box-shadow: 0 0 0 3px rgba(249, 115, 22, 0.2) !important;
  border-color: #f97316 !important;
}

.checkbox-grid .form-check input[type="checkbox"]:checked,
.form-check input[type="checkbox"]:checked,
input[type="checkbox"].form-check-input:checked {
  background: #f97316 !important;
  background-color: #f97316 !important;
  border-color: #f97316 !important;
  background-image: none !important;
}

.checkbox-grid .form-check input[type="checkbox"]:checked::after,
.form-check input[type="checkbox"]:checked::after,
input[type="checkbox"].form-check-input:checked::after {
  content: '✓' !important;
  color: white !important;
  font-size: 14px !important;
  font-weight: bold !important;
  position: absolute !important;
  top: 50% !important;
  left: 50% !important;
  transform: translate(-50%, -50%) !important;
  display: block !important;
  line-height: 1 !important;
}

.checkbox-grid .form-check input[type="checkbox"]:hover,
.form-check input[type="checkbox"]:hover,
input[type="checkbox"].form-check-input:hover {
  border-color: #f97316 !important;
  transform: scale(1.05) !important;
}

.checkbox-grid .form-check input[type="checkbox"]:checked + .form-check-label,
.form-check input[type="checkbox"]:checked + .form-check-label,
input[type="checkbox"].form-check-input:checked + .form-check-label {
  color: #f97316 !important;
  font-weight: 600 !important;
}

.form-check-label {
  font-weight: 500;
  cursor: pointer;
  margin: 0;
  font-size: var(--text-base);
  color: var(--text-secondary);
  transition: color var(--duration-200) var(--ease-out);
  position: relative;
  line-height: 1.5;
  flex: 1;
  user-select: none;
}

/* Override user-select for form elements specifically */
input,
textarea,
select,
[contenteditable],
.form-control {
  user-select: text !important;
  -webkit-user-select: text !important;
  -moz-user-select: text !important;
  -ms-user-select: text !important;
}

/* ===== Modern Form Actions ===== */
.form-actions {
  margin-top: var(--space-10);
  text-align: center;
  position: relative;
  z-index: 10;
}

/* ===== Modern Button System ===== */
.btn {
  border-radius: var(--radius-md);
  font-weight: 500;
  padding: var(--space-3) var(--space-4);
  border: 1px solid transparent;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-2);
  text-decoration: none;
  font-family: inherit;
  cursor: pointer;
  font-size: var(--text-sm);
  transition: all var(--duration-200) var(--ease-out);
  box-shadow: var(--shadow-sm);
}

.btn::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(45deg, transparent, rgba(255, 255, 255, 0.2), transparent);
  transform: translateX(-100%);
  transition: transform var(--duration-300) var(--ease-out);
}

.btn:hover::before {
  transform: translateX(100%);
}

.btn-primary {
  background: var(--primary);
  color: var(--text-inverse);
  border-color: var(--primary);
}

.btn-primary:hover {
  background: var(--primary-dark);
}

.btn-primary:active {
  transform: translateY(-1px) scale(1.01);
}

.btn-secondary {
  background: var(--secondary);
  color: var(--text-inverse);
  border-color: var(--secondary);
  box-shadow: var(--shadow-secondary);
}

.btn-secondary:hover {
  background: var(--secondary-dark);
  transform: translateY(-2px);
  box-shadow: var(--shadow-lg);
}

.btn-success {
  background: var(--accent-green);
  color: var(--text-inverse);
  border-color: var(--accent-green);
  box-shadow: var(--shadow-lg);
}

.btn-success:hover {
  background: #059669;
  transform: translateY(-3px) scale(1.02);
  box-shadow: var(--shadow-2xl);
}

.btn-outline-primary {
  background: var(--bg-primary);
  color: var(--primary);
  border-color: var(--primary);
  backdrop-filter: blur(10px);
}

.btn-outline-primary:hover {
  background: var(--primary);
  color: var(--text-inverse);
  transform: translateY(-2px);
  box-shadow: var(--shadow-lg);
}

.btn-outline-secondary {
  background: var(--bg-base);
  color: var(--secondary);
  border-color: var(--secondary);
  box-shadow: var(--shadow-secondary);
}

.btn-outline-secondary:hover {
  background: var(--secondary);
  color: var(--text-inverse);
  border-color: var(--secondary-dark);
  transform: translateY(-2px);
  box-shadow: var(--shadow-lg);
}

.btn-lg {
  padding: var(--space-5) var(--space-8);
  font-size: var(--text-lg);
  border-radius: var(--radius-lg);
  font-weight: 700;
  box-shadow: var(--shadow-md);
}

.btn-sm {
  padding: var(--space-2) var(--space-4);
  font-size: var(--text-sm);
  font-weight: 500;
}

/* Button loading state */
.btn:disabled {
  opacity: 0.6;
  cursor: not-allowed;
  transform: none !important;
}

.btn:disabled:hover {
  transform: none !important;
}

/* ===== Modern Search Layout ===== */
.search-layout {
  display: grid;
  grid-template-columns: 380px 1fr;
  gap: var(--space-6);
  max-width: 1400px;
  margin: 0 auto;
  padding: var(--space-4);
}

.search-sidebar {
  display: flex;
  flex-direction: column;
  gap: var(--space-4);
}

.search-content {
  min-height: 600px;
  background: var(--bg-primary);
  border-radius: var(--radius-2xl);
  padding: var(--space-8);
  box-shadow: var(--shadow-lg);
  border: 2px solid var(--neutral-200);
}

/* ===== Modern Tool Cards ===== */
.tool-card {
  background: var(--bg-primary);
  border-radius: var(--radius-2xl);
  padding: var(--space-6);
  box-shadow: var(--shadow-lg);
  border: 2px solid var(--neutral-200);
  transition: all var(--duration-200) var(--ease-out);
}

.tool-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-xl);
  border-color: var(--primary);
}

.ai-analysis-card {
  border-left: 4px solid var(--accent-green);
  background: linear-gradient(135deg, var(--bg-primary) 0%, rgba(34, 197, 94, 0.02) 100%);
}

@media (max-width: 768px) {
  .search-layout {
    grid-template-columns: 1fr;
    gap: var(--space-4);
  }
}

.tool-header {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  margin-bottom: var(--space-4);
}

.tool-icon {
  color: var(--accent-green);
  width: 28px;
  height: 28px;
  padding: var(--space-2);
  background: rgba(34, 197, 94, 0.1);
  border-radius: var(--radius-lg);
}

.tool-title {
  font-size: var(--text-xl);
  margin: 0;
  color: var(--text-primary);
  font-weight: 600;
}

.tool-description {
  color: var(--text-secondary);
  margin-bottom: var(--space-4);
  font-size: var(--text-sm);
  line-height: 1.5;
}

.tool-form {
  display: flex;
  flex-direction: column;
  gap: var(--space-4);
}

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

.tool-form .btn {
  margin-top: var(--space-2);
}

/* ===== Analysis Results ===== */
.analysis-results {
  margin-top: var(--space-8);
  background: var(--bg-secondary);
  border-radius: var(--radius-2xl);
  padding: var(--space-6);
  border: 2px solid var(--neutral-200);
}

.results-title {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  color: var(--text-primary);
  font-size: var(--text-2xl);
  margin-bottom: var(--space-6);
  font-weight: 600;
}

.analysis-card {
  background: var(--bg-primary);
  border-radius: var(--radius-xl);
  padding: var(--space-6);
  border: 2px solid var(--neutral-200);
  box-shadow: var(--shadow-md);
}

.analysis-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: var(--space-4);
  padding-bottom: var(--space-4);
  border-bottom: 1px solid var(--neutral-200);
}

.analysis-property-title {
  font-size: var(--text-lg);
  font-weight: 600;
  margin: 0;
}

.analysis-property-title a {
  color: var(--primary);
  text-decoration: none;
}

.analysis-property-title a:hover {
  text-decoration: underline;
}

.analysis-timestamp {
  font-size: var(--text-sm);
  color: var(--text-tertiary);
  font-weight: 400;
}

.analysis-content {
  display: flex;
  flex-direction: column;
  gap: var(--space-6);
}

.analysis-section {
  background: var(--bg-secondary);
  border-radius: var(--radius-lg);
  padding: var(--space-5);
  border: 1px solid var(--neutral-200);
}

.analysis-section h5 {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  color: var(--text-primary);
  font-size: var(--text-lg);
  font-weight: 600;
  margin-bottom: var(--space-4);
}

.ai-output {
  color: var(--text-secondary);
  line-height: 1.7;
  font-size: var(--text-base);
  white-space: pre-wrap;
  background: var(--bg-primary);
  padding: var(--space-4);
  border-radius: var(--radius-lg);
  border: 1px solid var(--neutral-200);
}

.suitability-score {
  font-size: var(--text-3xl);
  font-weight: 700;
  color: var(--primary);
  text-align: center;
  padding: var(--space-4);
  background: var(--primary-50);
  border-radius: var(--radius-lg);
  border: 2px solid var(--primary);
}

.pros-list, .cons-list, .recommendations-list, .next-steps-list {
  list-style: none;
  padding: 0;
  margin: 0;
}

.pros-list li, .cons-list li, .recommendations-list li, .next-steps-list li {
  padding: var(--space-2) 0;
  padding-left: var(--space-6);
  position: relative;
  color: var(--text-secondary);
  line-height: 1.6;
}

.pros-list li::before {
  content: '✓';
  position: absolute;
  left: 0;
  color: var(--accent-green);
  font-weight: 700;
}

.cons-list li::before {
  content: '⚠';
  position: absolute;
  left: 0;
  color: var(--primary);
  font-weight: 700;
}

.recommendations-list li::before, .next-steps-list li::before {
  content: '→';
  position: absolute;
  left: 0;
  color: var(--accent-blue);
  font-weight: 700;
}

.pros-title, .cons-title {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  font-size: var(--text-base);
  font-weight: 600;
  margin-bottom: var(--space-3);
}

.text-success {
  color: var(--accent-green);
}

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

/* ===== Platform Links ===== */
.platform-links {
  border-left: 4px solid var(--accent-blue);
}

.platform-links .tool-icon {
  color: var(--accent-blue);
}

.platform-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: var(--spacing-sm);
}

/* ===== Saved Properties ===== */
.saved-properties {
  border-left: 4px solid var(--accent-purple);
}

.saved-properties .tool-icon {
  color: var(--accent-purple);
}

.saved-list {
  max-height: 200px;
  overflow-y: auto;
  margin-bottom: var(--spacing-md);
}

.saved-item {
  padding: var(--spacing-sm);
  border-bottom: 1px solid var(--gray-200);
}

.saved-link {
  color: var(--text-medium);
  text-decoration: none;
  font-size: 0.875rem;
}

.saved-link:hover {
  color: var(--primary);
}

/* ===== Analysis Results ===== */
.analysis-results {
  margin-bottom: var(--spacing-2xl);
}

.results-title {
  display: flex;
  align-items: center;
  gap: var(--spacing-md);
  margin-bottom: var(--spacing-xl);
  color: var(--text-dark);
}

.analysis-card {
  background: var(--white);
  border-radius: var(--radius-xl);
  padding: var(--spacing-xl);
  margin-bottom: var(--spacing-xl);
  box-shadow: var(--shadow-md);
  border: 1px solid var(--gray-200);
}

.analysis-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: var(--spacing-lg);
  padding-bottom: var(--spacing-md);
  border-bottom: 1px solid var(--gray-200);
}

.analysis-property-title a {
  color: var(--accent-blue);
  text-decoration: none;
  font-weight: 600;
}

.analysis-timestamp {
  font-size: 0.875rem;
  color: var(--text-medium);
}

.analysis-content {
  display: flex;
  flex-direction: column;
  gap: var(--spacing-lg);
}

.analysis-section h5 {
  color: var(--text-dark);
  margin-bottom: var(--spacing-md);
  font-size: 1.125rem;
}

.suitability-score {
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--accent-green);
  padding: var(--spacing-md);
  background: var(--primary-50);
  border-radius: var(--radius-lg);
  text-align: center;
}

.pros-title, .cons-title {
  display: flex;
  align-items: center;
  gap: var(--spacing-sm);
  margin-bottom: var(--spacing-md);
}

.pros-list, .cons-list, .recommendations-list, .next-steps-list {
  padding-left: var(--spacing-lg);
}

.pros-list li {
  color: var(--accent-green);
  margin-bottom: var(--spacing-sm);
}

.cons-list li {
  color: var(--text-medium);
  margin-bottom: var(--spacing-sm);
}

/* ===== Search Tips ===== */
.search-tips {
  background: var(--white);
  border-radius: var(--radius-xl);
  padding: var(--spacing-2xl);
  margin-bottom: var(--spacing-2xl);
  box-shadow: var(--shadow-md);
  border: 1px solid var(--gray-200);
}

.tips-title {
  display: flex;
  align-items: center;
  gap: var(--spacing-md);
  margin-bottom: var(--spacing-xl);
  color: var(--text-dark);
}

.tip-card {
  background: var(--gray-50);
  border-radius: var(--radius-lg);
  padding: var(--spacing-lg);
  height: 100%;
}

.tip-card h5 {
  color: var(--text-dark);
  margin-bottom: var(--spacing-md);
}

.tip-card ul {
  padding-left: var(--spacing-lg);
  margin: 0;
}

.tip-card li {
  margin-bottom: var(--spacing-sm);
  color: var(--text-medium);
}

/* ===== Visit Checklist ===== */
.visit-checklist {
  background: var(--white);
  border-radius: var(--radius-xl);
  padding: var(--spacing-2xl);
  margin: var(--spacing-2xl) 0;
  box-shadow: var(--shadow-md);
  border: 1px solid var(--gray-200);
}

.checklist-title {
  display: flex;
  align-items: center;
  gap: var(--spacing-md);
  margin-bottom: var(--spacing-xl);
  color: var(--text-dark);
}

.checklist-card {
  background: var(--gray-50);
  border-radius: var(--radius-lg);
  padding: var(--spacing-lg);
  height: 100%;
}

.checklist-list {
  padding-left: var(--spacing-lg);
  margin: 0;
}

.checklist-list li {
  margin-bottom: var(--spacing-sm);
  color: var(--text-medium);
}

/* ===== Template Toggle ===== */
.template-toggle {
  margin-bottom: var(--spacing-2xl);
}

.template-toggle .btn-group {
  box-shadow: var(--shadow-md);
  border-radius: var(--radius-lg);
  overflow: hidden;
}

.template-toggle .btn {
  border-radius: 0;
  padding: var(--spacing-lg);
}

.template-toggle .btn:first-child {
  border-radius: var(--radius-lg) 0 0 var(--radius-lg);
}

.template-toggle .btn:last-child {
  border-radius: 0 var(--radius-lg) var(--radius-lg) 0;
}

/* ===== Template Section ===== */
.template-section {
  margin-bottom: var(--spacing-2xl);
}

.template-card {
  background: var(--white);
  border-radius: var(--radius-xl);
  padding: var(--spacing-2xl);
  box-shadow: var(--shadow-md);
  border: 1px solid var(--gray-200);
}

.template-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: var(--spacing-lg);
  padding-bottom: var(--spacing-md);
  border-bottom: 1px solid var(--gray-200);
}

.template-title {
  display: flex;
  align-items: center;
  gap: var(--spacing-md);
  margin: 0;
  color: var(--text-dark);
}

.template-textarea {
  font-family: 'Courier New', monospace;
  font-size: 0.9rem;
  line-height: 1.6;
  min-height: 400px;
}

/* ===== Communication Tips ===== */
.communication-tips {
  background: var(--white);
  border-radius: var(--radius-xl);
  padding: var(--spacing-2xl);
  margin: var(--spacing-2xl) 0;
  box-shadow: var(--shadow-md);
  border: 1px solid var(--gray-200);
}

/* ===== Upload Section ===== */
.upload-section {
  margin-bottom: var(--spacing-2xl);
}

.upload-area {
  background: var(--white);
  border: 3px dashed var(--gray-300);
  border-radius: var(--radius-xl);
  padding: var(--spacing-3xl);
  text-align: center;
  transition: all var(--transition-fast);
  margin-bottom: var(--spacing-lg);
}

.upload-area:hover, .upload-area.drag-over {
  border-color: var(--primary);
  background: var(--primary-50);
}

.upload-content {
  margin-bottom: var(--spacing-xl);
}

.upload-icon {
  width: 64px;
  height: 64px;
  color: var(--primary);
  margin-bottom: var(--spacing-lg);
}

.upload-title {
  font-size: 1.5rem;
  color: var(--text-dark);
  margin-bottom: var(--spacing-md);
}

.upload-subtitle {
  color: var(--text-medium);
  margin-bottom: var(--spacing-lg);
}

.upload-info {
  color: var(--text-medium);
  font-size: 0.875rem;
}

.upload-actions {
  text-align: center;
}

/* ===== Document Analysis ===== */
.document-card {
  background: var(--white);
  border-radius: var(--radius-xl);
  padding: var(--spacing-xl);
  margin-bottom: var(--spacing-xl);
  box-shadow: var(--shadow-md);
  border: 1px solid var(--gray-200);
}

.document-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: var(--spacing-lg);
  padding-bottom: var(--spacing-md);
  border-bottom: 1px solid var(--gray-200);
}

.document-name {
  display: flex;
  align-items: center;
  gap: var(--spacing-md);
  margin: 0;
  color: var(--text-dark);
}

.document-type {
  background: var(--primary-50);
  color: var(--primary);
  padding: var(--spacing-xs) var(--spacing-md);
  border-radius: var(--radius-lg);
  font-size: 0.875rem;
  font-weight: 600;
}

.document-analysis {
  display: flex;
  flex-direction: column;
  gap: var(--spacing-lg);
}

.findings-list, .action-items-list {
  padding-left: var(--spacing-lg);
  margin: 0;
}

.compliance-check {
  padding: var(--spacing-md);
  background: var(--gray-50);
  border-radius: var(--radius-lg);
}

.compliance-status {
  font-weight: 600;
  padding: var(--spacing-sm) var(--spacing-md);
  border-radius: var(--radius-md);
  font-size: 0.875rem;
  display: inline-block;
  margin-bottom: var(--spacing-sm);
}

.status-review-required {
  background: var(--bg-amber-50);
  color: #d97706;
}

.status-verification-needed {
  background: var(--primary-50);
  color: var(--primary);
}

.status-pending-review {
  background: var(--gray-100);
  color: var(--text-medium);
}

.compliance-message {
  margin: 0;
  color: var(--text-medium);
}

/* ===== Document Guide ===== */
.document-guide {
  background: var(--white);
  border-radius: var(--radius-xl);
  padding: var(--spacing-2xl);
  margin: var(--spacing-2xl) 0;
  box-shadow: var(--shadow-md);
  border: 1px solid var(--gray-200);
}

.guide-title {
  display: flex;
  align-items: center;
  gap: var(--spacing-md);
  margin-bottom: var(--spacing-xl);
  color: var(--text-dark);
}

.guide-card {
  background: var(--gray-50);
  border-radius: var(--radius-lg);
  padding: var(--spacing-lg);
  height: 100%;
}

.guide-card h5 {
  color: var(--text-dark);
  margin-bottom: var(--spacing-md);
}

.guide-card ul {
  padding-left: var(--spacing-lg);
  margin: 0;
}

.guide-card li {
  margin-bottom: var(--spacing-sm);
  color: var(--text-medium);
}

/* ===== Completion Section ===== */
.completion-section {
  max-width: 1000px;
  margin: 0 auto;
  padding: var(--spacing-xl);
}

.success-header {
  text-align: center;
  margin-bottom: var(--spacing-3xl);
}

.success-icon {
  margin-bottom: var(--spacing-xl);
}

.success-icon-svg {
  width: 80px;
  height: 80px;
  color: var(--accent-green);
  padding: var(--spacing-lg);
  background: rgba(22, 163, 74, 0.1);
  border-radius: 50%;
  box-shadow: var(--shadow-lg);
}

.success-title {
  font-size: 3rem;
  color: var(--accent-green);
  margin-bottom: var(--spacing-md);
}

.success-subtitle {
  font-size: 1.25rem;
  color: var(--text-medium);
}

/* ===== Journey Summary ===== */
.journey-summary {
  margin-bottom: var(--spacing-3xl);
}

.summary-card {
  background: var(--white);
  border-radius: var(--radius-xl);
  padding: var(--spacing-2xl);
  box-shadow: var(--shadow-md);
  border: 1px solid var(--gray-200);
  height: 100%;
}

.summary-header {
  display: flex;
  align-items: center;
  gap: var(--spacing-md);
  margin-bottom: var(--spacing-lg);
  padding-bottom: var(--spacing-md);
  border-bottom: 1px solid var(--gray-200);
}

.summary-icon {
  color: var(--primary);
  width: 24px;
  height: 24px;
}

.summary-title {
  margin: 0;
  color: var(--text-dark);
}

.summary-content {
  display: flex;
  flex-direction: column;
  gap: var(--spacing-md);
}

.summary-item {
  color: var(--text-medium);
}

.summary-item strong {
  color: var(--text-dark);
}

/* ===== Stats Summary ===== */
.stats-summary .summary-content {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: var(--spacing-lg);
}

.stat-item {
  text-align: center;
  padding: var(--spacing-lg);
  background: var(--gray-50);
  border-radius: var(--radius-lg);
}

.stat-number {
  font-size: 2rem;
  font-weight: 700;
  color: var(--primary);
  margin-bottom: var(--spacing-sm);
}

.stat-label {
  font-size: 0.875rem;
  color: var(--text-medium);
  font-weight: 600;
}

/* ===== Next Steps ===== */
.next-steps {
  margin-bottom: var(--spacing-3xl);
}

.next-steps-title {
  display: flex;
  align-items: center;
  gap: var(--spacing-md);
  margin-bottom: var(--spacing-xl);
  color: var(--text-dark);
  text-align: center;
  justify-content: center;
}

.next-step-card {
  background: var(--white);
  border-radius: var(--radius-xl);
  padding: var(--spacing-xl);
  text-align: center;
  box-shadow: var(--shadow-md);
  border: 1px solid var(--gray-200);
  height: 100%;
  transition: all var(--transition-fast);
}

.next-step-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
}

.next-step-card .step-icon {
  margin-bottom: var(--spacing-lg);
}

.next-step-card .step-icon i {
  width: 48px;
  height: 48px;
  color: var(--accent-blue);
  padding: var(--spacing-md);
  background: rgba(37, 99, 235, 0.1);
  border-radius: var(--radius-lg);
}

.next-step-card .step-title {
  font-size: 1.25rem;
  margin-bottom: var(--spacing-md);
  color: var(--text-dark);
}

.next-step-card .step-description {
  color: var(--text-medium);
  line-height: 1.6;
}

/* ===== Completion Actions ===== */
.completion-actions {
  margin-bottom: var(--spacing-3xl);
}

/* ===== Resources Section ===== */
.resources-section {
  margin-bottom: var(--spacing-3xl);
}

.resources-title {
  display: flex;
  align-items: center;
  gap: var(--spacing-md);
  margin-bottom: var(--spacing-xl);
  color: var(--text-dark);
  text-align: center;
  justify-content: center;
}

.resource-card {
  background: var(--white);
  border-radius: var(--radius-lg);
  padding: var(--spacing-lg);
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--gray-200);
  height: 100%;
}

.resource-card h5 {
  color: var(--text-dark);
  margin-bottom: var(--spacing-md);
}

.resource-list {
  padding-left: var(--spacing-lg);
  margin: 0;
}

.resource-list li {
  margin-bottom: var(--spacing-sm);
}

.resource-list a {
  color: var(--accent-blue);
  text-decoration: none;
}

.resource-list a:hover {
  text-decoration: underline;
}

/* ===== New Journey ===== */
.new-journey {
  text-align: center;
}

.new-journey-card {
  background: var(--white);
  border-radius: var(--radius-xl);
  padding: var(--spacing-2xl);
  box-shadow: var(--shadow-md);
  border: 1px solid var(--gray-200);
  max-width: 500px;
  margin: 0 auto;
}

.new-journey-title {
  color: var(--text-dark);
  margin-bottom: var(--spacing-md);
}

.new-journey-description {
  color: var(--text-medium);
  margin-bottom: var(--spacing-xl);
  line-height: 1.6;
}

/* ===== Bottom Navigation ===== */
.bottom-nav {
  background: #ffffff;
  border-top: 1px solid #e2e8f0;
  padding: 1rem 0;
  box-shadow: 0 -2px 10px rgba(0, 0, 0, 0.1);
  position: sticky;
  bottom: 0;
  z-index: 100;
  backdrop-filter: blur(10px);
}

.nav-buttons {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.step-info {
  font-weight: 600;
  color: #1e293b;
  padding: 0.75rem;
  background: #f8fafc;
  border-radius: 0.5rem;
  border: 1px solid #e2e8f0;
}

/* ===== Responsive Design ===== */
@media (max-width: 1200px) {
  .search-layout {
    grid-template-columns: 300px 1fr;
    gap: var(--spacing-lg);
  }
}

@media (max-width: 992px) {
  .search-layout {
    grid-template-columns: 1fr;
    gap: var(--spacing-lg);
  }
  
  .search-sidebar {
    order: 2;
  }
  
  .search-content {
    order: 1;
  }
  
  .hero-title {
    font-size: 2.5rem;
  }
  
  .section-title {
    font-size: 2rem;
  }
}

@media (max-width: 768px) {
  .progress-steps {
    flex-wrap: wrap;
    gap: var(--spacing-sm);
  }
  
  .progress-step {
    flex: 0 0 calc(25% - var(--spacing-sm));
  }
  
  .step-label {
    font-size: 0.6rem;
  }
  
  .hero-title {
    font-size: 2rem;
  }
  
  .hero-subtitle {
    font-size: 1rem;
  }
  
  .form-section {
    padding: var(--spacing-md);
  }
  
  .housing-form {
    padding: var(--spacing-lg);
  }
  
  .checkbox-grid {
    grid-template-columns: 1fr;
  }
  
  .platform-buttons {
    flex-direction: column;
  }
  
  .platform-buttons .btn {
    width: 100%;
  }
  
  .analysis-header {
    flex-direction: column;
    align-items: flex-start;
    gap: var(--spacing-sm);
  }
  
  .template-header {
    flex-direction: column;
    align-items: flex-start;
    gap: var(--spacing-md);
  }
  
  .stats-summary .summary-content {
    grid-template-columns: 1fr;
    gap: var(--spacing-md);
  }
  
  .nav-buttons {
    flex-direction: column;
    gap: var(--spacing-md);
  }
}

@media (max-width: 480px) {
  .progress-step {
    flex: 0 0 calc(50% - var(--spacing-sm));
  }
  
  .step-number {
    width: 32px;
    height: 32px;
    font-size: 0.75rem;
  }
  
  .hero-icon-svg {
    width: 60px;
    height: 60px;
  }
  
  .hero-title {
    font-size: 1.75rem;
  }
  
  .section-icon-svg {
    width: 48px;
    height: 48px;
  }
  
  .section-title {
    font-size: 1.75rem;
  }
  
  .upload-area {
    padding: var(--spacing-xl);
  }
  
  .upload-icon {
    width: 48px;
    height: 48px;
  }
  
  .upload-title {
    font-size: 1.25rem;
  }
}

/* ===== Utility Classes ===== */
.text-center {
  text-align: center;
}

.text-left {
  text-align: left;
}

.text-right {
  text-align: right;
}

.d-flex {
  display: flex;
}

.align-items-center {
  align-items: center;
}

.justify-content-center {
  justify-content: center;
}

.justify-content-between {
  justify-content: space-between;
}

.gap-1 {
  gap: var(--spacing-sm);
}

.gap-2 {
  gap: var(--spacing-md);
}

.gap-3 {
  gap: var(--spacing-lg);
}

.w-100 {
  width: 100%;
}

.mb-0 {
  margin-bottom: 0;
}

.mb-1 {
  margin-bottom: var(--spacing-sm);
}

.mb-2 {
  margin-bottom: var(--spacing-md);
}

.mb-3 {
  margin-bottom: var(--spacing-lg);
}

.mt-0 {
  margin-top: 0;
}

.mt-1 {
  margin-top: var(--spacing-sm);
}

.mt-2 {
  margin-top: var(--spacing-md);
}

.mt-3 {
  margin-top: var(--spacing-lg);
}

/* ===== Animation Classes ===== */
.fade-in {
  animation: fadeIn 0.5s ease-in-out;
}

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

.slide-in {
  animation: slideIn 0.3s ease-out;
}

@keyframes slideIn {
  from {
    transform: translateX(-100%);
  }
  to {
    transform: translateX(0);
  }
}

/* ===== Print Styles ===== */
@media print {
  .progress-container,
  .bottom-nav,
  .btn,
  .upload-area {
    display: none;
  }
  
  body {
    background: white;
  }
  
  .form-section,
  .housing-form,
  .analysis-card,
  .document-card {
    box-shadow: none;
    border: 1px solid #000;
  }
}
