/* ========================================
   CompanySearch.store - Main Stylesheet
   ======================================== */

/* Root Variables */
:root {
    /* Brand Colors */
    --gradient-start: #667eea;
    --gradient-end: #764ba2;
    --primary-blue: #0074d4;
    --primary-blue-dark: #005bb5;
    
    /* Semantic Colors */
    --success-green: #28a745;
    --warning-yellow: #ffc107;
    --error-red: #dc3545;
    
    /* Neutral Colors */
    --text-dark: #333333;
    --text-secondary: #666666;
    --text-tertiary: #999999;
    --bg-light: #f5f5f5;
    --bg-white: #ffffff;
    --border-gray: #e0e0e0;
    
    /* Spacing Scale (8px base) */
    --space-xs: 4px;
    --space-sm: 8px;
    --space-md: 16px;
    --space-lg: 24px;
    --space-xl: 32px;
    --space-xxl: 48px;
    --space-xxxl: 64px;
    
    /* Border Radius */
    --radius-sm: 4px;
    --radius-md: 8px;
    --radius-lg: 12px;
    --radius-xl: 16px;
    --radius-full: 999px;
    
    /* Shadows */
    --shadow-sm: 0 2px 10px rgba(0, 0, 0, 0.1);
    --shadow-md: 0 4px 20px rgba(0, 0, 0, 0.15);
    --shadow-lg: 0 20px 60px rgba(0, 0, 0, 0.3);
    --shadow-focus: 0 0 0 3px rgba(0, 116, 212, 0.3);
    
    /* Font Family */
    --font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto,
                   'Helvetica Neue', Arial, sans-serif;
    
    /* Transitions */
    --transition-fast: all 0.1s ease;
    --transition-normal: all 0.2s ease;
    --transition-slow: all 0.3s ease;
}

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

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

body {
    font-family: var(--font-family);
    font-size: 1rem;
    line-height: 1.6;
    color: var(--text-dark);
    background-color: var(--bg-light);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* Typography */
h1, h2, h3, h4, h5, h6 {
    font-weight: 600;
    line-height: 1.2;
    letter-spacing: -0.02em;
    margin-bottom: var(--space-md);
}

h1 { font-size: 2.5rem; font-weight: 700; }
h2 { font-size: 2rem; }
h3 { font-size: 1.5rem; }
h4 { font-size: 1.25rem; font-weight: 500; }

p {
    margin-bottom: var(--space-md);
}

a {
    color: var(--primary-blue);
    text-decoration: none;
    transition: var(--transition-normal);
}

a:hover {
    text-decoration: underline;
}

/* Container */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 var(--space-lg);
}

/* Header */
.header {
    background: var(--bg-white);
    border-bottom: 1px solid var(--border-gray);
    position: sticky;
    top: 0;
    z-index: 100;
    box-shadow: var(--shadow-sm);
}

.nav-wrapper {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: var(--space-md) 0;
}

.logo {
    display: flex;
    align-items: center;
    gap: var(--space-sm);
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--text-dark);
}

.logo-icon {
    font-size: 1.5rem;
}

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

.nav-link {
    color: var(--text-secondary);
    font-weight: 500;
    transition: var(--transition-normal);
}

.nav-link:hover {
    color: var(--primary-blue);
    text-decoration: none;
}

/* Hero Section */
.hero {
    background: linear-gradient(135deg, var(--gradient-start) 0%, var(--gradient-end) 100%);
    padding: var(--space-xxxl) 0;
    position: relative;
    overflow: hidden;
}

.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 1440 320"><path fill="rgba(255,255,255,0.1)" d="M0,96L48,112C96,128,192,160,288,160C384,160,480,128,576,122.7C672,117,768,139,864,144C960,149,1056,139,1152,128C1248,117,1344,107,1392,101.3L1440,96L1440,320L1392,320C1344,320,1248,320,1152,320C1056,320,960,320,864,320C768,320,672,320,576,320C480,320,384,320,288,320C192,320,96,320,48,320L0,320Z"></path></svg>') no-repeat bottom;
    background-size: cover;
}

.hero-content {
    position: relative;
    z-index: 1;
}

.hero-title {
    font-size: 3rem;
    color: var(--bg-white);
    text-align: center;
    margin-bottom: var(--space-lg);
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.gradient-text {
    background: linear-gradient(90deg, #fff, #f0f0f0);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.hero-subtitle {
    font-size: 1.25rem;
    color: rgba(255, 255, 255, 0.95);
    text-align: center;
    max-width: 600px;
    margin: 0 auto var(--space-xl);
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.1);
}

/* Trust Signals */
.trust-signals {
    display: flex;
    justify-content: center;
    gap: var(--space-xl);
    margin-bottom: var(--space-xl);
    flex-wrap: wrap;
}

.trust-item {
    display: flex;
    align-items: center;
    gap: var(--space-sm);
    color: var(--bg-white);
    font-size: 0.95rem;
}

.trust-icon {
    width: 24px;
    height: 24px;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Search Card */
.search-card {
    background: var(--bg-white);
    border-radius: var(--radius-xl);
    padding: var(--space-xl);
    max-width: 800px;
    margin: 0 auto;
    box-shadow: var(--shadow-lg);
}

/* Form Styles */
.form-group {
    margin-bottom: var(--space-lg);
}

.form-label {
    display: flex;
    align-items: center;
    gap: var(--space-sm);
    font-weight: 600;
    color: var(--text-dark);
    margin-bottom: var(--space-sm);
}

.label-icon {
    font-size: 1.2rem;
}

.input-wrapper {
    position: relative;
}

.form-input {
    width: 100%;
    padding: var(--space-md) var(--space-md);
    border: 2px solid var(--border-gray);
    border-radius: var(--radius-md);
    font-size: 1rem;
    color: var(--text-dark);
    background: var(--bg-white);
    transition: var(--transition-normal);
}

.form-input:focus {
    outline: none;
    border-color: var(--primary-blue);
    box-shadow: var(--shadow-focus);
}

.form-input::placeholder {
    color: var(--text-tertiary);
}

.form-help {
    font-size: 0.875rem;
    color: var(--text-tertiary);
    margin-top: var(--space-xs);
}

/* Tag Input Styles */
.tag-input-wrapper {
    min-height: 48px;
    padding: var(--space-xs);
    border: 2px solid var(--border-gray);
    border-radius: var(--radius-md);
    background: var(--bg-white);
    display: flex;
    flex-wrap: wrap;
    gap: var(--space-xs);
    align-items: center;
    cursor: text;
    transition: var(--transition-normal);
}

.tag-input-wrapper:focus-within {
    border-color: var(--primary-blue);
    box-shadow: var(--shadow-focus);
}

.tag-input-wrapper .tag {
    display: inline-flex;
    align-items: center;
    gap: var(--space-xs);
    padding: 4px 10px;
    background: linear-gradient(135deg, var(--gradient-start), var(--gradient-end));
    color: white;
    border-radius: var(--radius-full);
    font-size: 0.875rem;
    font-weight: 500;
    animation: tagAppear 0.2s ease;
}

@keyframes tagAppear {
    from {
        opacity: 0;
        transform: scale(0.8);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

.tag-input-wrapper .tag .tag-remove {
    background: rgba(255, 255, 255, 0.3);
    border: none;
    border-radius: 50%;
    width: 16px;
    height: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    font-size: 12px;
    line-height: 1;
    color: white;
    transition: background 0.2s;
    padding: 0;
}

.tag-input-wrapper .tag .tag-remove:hover {
    background: rgba(255, 255, 255, 0.5);
}

.tag-input-wrapper input.tag-input-field {
    flex: 1;
    min-width: 120px;
    border: none;
    outline: none;
    padding: 8px;
    font-size: 1rem;
    background: transparent;
}

.tag-input-wrapper input.tag-input-field::placeholder {
    color: var(--text-tertiary);
}

/* Region Selector */
.region-selector {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
    gap: var(--space-sm);
    padding: var(--space-md);
    background: var(--bg-light);
    border-radius: var(--radius-md);
    max-height: 200px;
    overflow-y: auto;
}

.region-checkbox {
    display: flex;
    align-items: center;
    gap: var(--space-sm);
    padding: var(--space-sm);
    border-radius: var(--radius-sm);
    cursor: pointer;
    transition: var(--transition-normal);
}

.region-checkbox:hover {
    background: var(--bg-white);
}

.region-checkbox input[type="checkbox"] {
    width: 18px;
    height: 18px;
    cursor: pointer;
}

.region-checkbox label {
    cursor: pointer;
    font-size: 0.95rem;
    user-select: none;
}

/* Suggestions Dropdown */
.suggestions-dropdown {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--bg-white);
    border: 1px solid var(--border-gray);
    border-top: none;
    border-radius: 0 0 var(--radius-md) var(--radius-md);
    max-height: 200px;
    overflow-y: auto;
    display: none;
    z-index: 10;
    box-shadow: var(--shadow-sm);
}

.suggestions-dropdown.active {
    display: block;
}

.suggestion-item {
    padding: var(--space-sm) var(--space-md);
    cursor: pointer;
    transition: var(--transition-normal);
}

.suggestion-item:hover {
    background: var(--bg-light);
}

.suggestion-item strong {
    color: var(--primary-blue);
}

/* Radius Slider */
.radius-slider {
    width: 100%;
    height: 8px;
    border-radius: 5px;
    background: linear-gradient(to right, var(--primary-blue) 0%, var(--primary-blue) 40%, var(--border-gray) 40%, var(--border-gray) 100%);
    outline: none;
    -webkit-appearance: none;
    margin: var(--space-sm) 0;
    cursor: pointer;
}

.radius-slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: var(--primary-blue);
    cursor: pointer;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
    transition: var(--transition-normal);
}

.radius-slider::-webkit-slider-thumb:hover {
    background: var(--primary-hover);
    transform: scale(1.1);
}

.radius-slider::-webkit-slider-thumb:active {
    transform: scale(0.95);
}

.radius-slider::-moz-range-thumb {
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: var(--primary-blue);
    cursor: pointer;
    border: none;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
    transition: var(--transition-normal);
}

.radius-slider::-moz-range-thumb:hover {
    background: var(--primary-hover);
    transform: scale(1.1);
}

.radius-slider::-moz-range-thumb:active {
    transform: scale(0.95);
}

.radius-slider::-moz-range-track {
    width: 100%;
    height: 8px;
    background: transparent;
    border: none;
}

#radiusValue {
    font-weight: 600;
    color: var(--primary-blue);
}

/* Inline Radius Control */
.form-label-with-radius {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: var(--space-sm);
    flex-wrap: wrap;
    gap: var(--space-md);
}

.radius-control-inline {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-shrink: 0;
}

.radius-label-text {
    font-size: 0.9rem;
    color: var(--text-secondary);
    font-weight: 500;
    white-space: nowrap;
}

.radius-value {
    font-size: 0.9rem;
    color: var(--text-secondary);
    font-weight: 500;
    white-space: nowrap;
    min-width: 110px;
    display: inline-block;
    text-align: left;
}

.radius-slider-inline {
    width: 120px;
    height: 6px;
    border-radius: 3px;
    background: linear-gradient(to right, #2196F3 0%, #2196F3 40%, #e0e0e0 40%, #e0e0e0 100%);
    outline: none;
    -webkit-appearance: none;
    cursor: pointer;
    flex-shrink: 0;
    -webkit-tap-highlight-color: transparent;
    touch-action: none;
}

.radius-slider-inline::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 16px;
    height: 16px;
    border-radius: 50%;
    background: #2196F3;
    cursor: pointer;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
    transition: all 0.2s ease;
}

.radius-slider-inline::-webkit-slider-thumb:hover {
    background: #1976D2;
    transform: scale(1.1);
}

.radius-slider-inline::-webkit-slider-thumb:active {
    transform: scale(0.95);
}

.radius-slider-inline::-moz-range-thumb {
    width: 16px;
    height: 16px;
    border-radius: 50%;
    background: #2196F3;
    cursor: pointer;
    border: none;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
    transition: all 0.2s ease;
}

.radius-slider-inline::-moz-range-thumb:hover {
    background: #1976D2;
    transform: scale(1.1);
}

.radius-slider-inline::-moz-range-thumb:active {
    transform: scale(0.95);
}

.radius-slider-inline::-moz-range-track {
    width: 100%;
    height: 6px;
    background: transparent;
    border: none;
}

/* Responsive: Stack on mobile */
@media (max-width: 640px) {
    .form-label-with-radius {
        flex-direction: column;
        align-items: flex-start;
    }

    .radius-control-inline {
        width: 100%;
        flex-wrap: wrap;
        gap: 12px;
    }

    .radius-label-text {
        order: 1;
        font-size: 0.85rem;
    }

    .radius-slider-inline {
        width: 100%;
        min-width: 0;
        flex-basis: 100%;
        order: 2;
        /* Increase touch target size on mobile */
    }

    .radius-slider-inline::-webkit-slider-thumb {
        width: 20px;
        height: 20px;
    }

    .radius-slider-inline::-moz-range-thumb {
        width: 20px;
        height: 20px;
    }

    .radius-value {
        order: 3;
        min-width: 0;
        width: auto;
        font-size: 0.85rem;
    }
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: var(--space-sm);
    padding: 12px 24px;
    border: none;
    border-radius: var(--radius-md);
    font-size: 1rem;
    font-weight: 600;
    letter-spacing: 0.02em;
    cursor: pointer;
    transition: var(--transition-normal);
    text-decoration: none;
}

.btn-primary {
    background: var(--primary-blue);
    color: var(--bg-white);
}

.btn-primary:hover {
    background: var(--primary-blue-dark);
    box-shadow: 0 4px 12px rgba(0, 116, 212, 0.3);
    transform: translateY(-1px);
}

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

.btn-primary:disabled {
    background: #cccccc;
    cursor: not-allowed;
    transform: none;
}

.btn-secondary {
    background: transparent;
    color: var(--primary-blue);
    border: 2px solid var(--primary-blue);
}

.btn-secondary:hover {
    background: rgba(0, 116, 212, 0.1);
}

.btn-small {
    padding: 8px 16px;
    font-size: 0.875rem;
}

.btn-large {
    padding: 16px 32px;
    font-size: 1.125rem;
    width: 100%;
}

/* Form Actions */
.form-actions {
    margin-top: var(--space-xl);
}

.price-estimate {
    text-align: center;
    margin-top: var(--space-md);
    font-size: 0.875rem;
    color: var(--text-secondary);
}

.price-estimate span {
    font-weight: 600;
    color: var(--success-green);
}

/* Progress Container */
.progress-container {
    padding: var(--space-lg);
    background: var(--bg-light);
    border-radius: var(--radius-md);
    margin-top: var(--space-lg);
}

.progress-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: var(--space-md);
}

.progress-header h3 {
    margin: 0;
}

.btn-close {
    background: transparent;
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
    padding: var(--space-xs);
    color: var(--text-tertiary);
}

.progress-bar {
    width: 100%;
    height: 8px;
    background: var(--border-gray);
    border-radius: var(--radius-full);
    overflow: hidden;
    margin-bottom: var(--space-md);
}

.progress-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--gradient-start), var(--gradient-end));
    transition: width 0.3s ease;
}

.progress-status {
    font-weight: 600;
    color: var(--text-dark);
    margin-bottom: var(--space-sm);
}

.progress-details {
    font-size: 0.875rem;
    color: var(--text-secondary);
}

/* ============================================
   PROGRESS MODAL - MOBILE-FIRST APPROACH
   ============================================ */

/* Modal Overlay - Full Screen Dark Background */
.progress-modal-overlay {
    /* Hide by default */
    display: none;

    /* Full screen positioning */
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    width: 100%;
    height: 100%;

    /* iOS-safe z-index (avoid conflicts with native UI) */
    z-index: 999999;

    /* Dark semi-transparent background */
    background-color: rgba(0, 0, 0, 0.90);

    /* Flexbox centering */
    align-items: center;
    justify-content: center;
    flex-direction: column;

    /* Padding for safe areas on iOS */
    padding: max(env(safe-area-inset-top), 20px)
             max(env(safe-area-inset-right), 20px)
             max(env(safe-area-inset-bottom), 20px)
             max(env(safe-area-inset-left), 20px);

    /* Backdrop blur with fallback */
    -webkit-backdrop-filter: blur(8px);
    backdrop-filter: blur(8px);

    /* Smooth fade-in animation */
    animation: fadeIn 0.3s ease;

    /* iOS-specific fixes */
    -webkit-overflow-scrolling: touch;
    -webkit-tap-highlight-color: transparent;

    /* Force hardware acceleration for smooth rendering */
    transform: translateZ(0);
    -webkit-transform: translateZ(0);
    will-change: opacity;
}

/* Active state - show modal */
.progress-modal-overlay.active {
    display: flex !important;
}

/* Progress Container - Content holder (NO BACKGROUND BOX) */
.progress-modal-overlay .progress-container {
    /* Remove ALL backgrounds */
    background: none !important;
    background-color: transparent !important;

    /* Remove shadows */
    box-shadow: none !important;

    /* Sizing */
    max-width: 480px;
    width: 100%;

    /* Spacing */
    margin: 0;
    padding: 20px;

    /* Slide up animation */
    animation: slideUpModal 0.4s cubic-bezier(0.16, 1, 0.3, 1);

    /* Force transparency */
    opacity: 1;
}

/* Header Title - Large, White, Readable */
.progress-modal-overlay .progress-header {
    margin-bottom: 32px;
    text-align: center;
}

.progress-modal-overlay .progress-header h3 {
    color: #ffffff !important;
    font-size: clamp(1.25rem, 4vw, 1.75rem); /* Responsive sizing: 20px - 28px */
    font-weight: 600;
    line-height: 1.3;
    margin: 0;
    padding: 0;
    text-align: center;

    /* Improve readability on mobile */
    text-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
    letter-spacing: -0.01em;
}

/* Progress Bar - Visible on dark background */
.progress-modal-overlay .progress-bar {
    width: 100%;
    height: 8px;
    background: rgba(255, 255, 255, 0.25);
    border-radius: 999px;
    overflow: hidden;
    margin-bottom: 24px;

    /* Add subtle border for definition */
    border: 1px solid rgba(255, 255, 255, 0.3);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
}

.progress-modal-overlay .progress-fill {
    height: 100%;
    background: linear-gradient(90deg, #667eea, #764ba2);
    border-radius: 999px;
    transition: width 0.3s ease;

    /* Add glow effect */
    box-shadow: 0 0 10px rgba(102, 126, 234, 0.5);
}

/* Status Text - White, Clear, Readable */
.progress-modal-overlay .progress-status {
    color: rgba(255, 255, 255, 0.95) !important;
    font-size: clamp(1rem, 3.5vw, 1.125rem); /* 16px - 18px */
    font-weight: 600;
    text-align: center;
    margin-bottom: 16px;
    line-height: 1.5;

    /* Readability enhancement */
    text-shadow: 0 1px 4px rgba(0, 0, 0, 0.3);
}

/* Details Text - Lighter white, smaller */
.progress-modal-overlay .progress-details {
    color: rgba(255, 255, 255, 0.8) !important;
    font-size: clamp(0.875rem, 3vw, 1rem); /* 14px - 16px */
    text-align: center;
    line-height: 1.6;
    margin-bottom: 24px;

    /* Readability enhancement */
    text-shadow: 0 1px 3px rgba(0, 0, 0, 0.3);
}

/* Close Button - Top Right Corner */
.progress-modal-close {
    position: absolute;
    top: max(env(safe-area-inset-top), 16px);
    right: max(env(safe-area-inset-right), 16px);

    /* Size - iOS minimum touch target */
    width: 48px;
    height: 48px;
    min-width: 48px;
    min-height: 48px;

    /* Styling */
    background: rgba(255, 255, 255, 0.15);
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-radius: 8px;

    /* Text */
    color: rgba(255, 255, 255, 0.95);
    font-size: 28px;
    font-weight: 300;
    line-height: 1;

    /* Layout */
    display: flex;
    align-items: center;
    justify-content: center;

    /* Interaction */
    cursor: pointer;
    -webkit-tap-highlight-color: transparent;
    touch-action: manipulation;

    /* Smooth transitions */
    transition: all 0.2s ease;

    /* Ensure clickability */
    z-index: 10;
}

.progress-modal-close:hover,
.progress-modal-close:active {
    background: rgba(255, 255, 255, 0.25);
    border-color: rgba(255, 255, 255, 0.5);
    transform: scale(1.05);
}

/* Cancel Button - Bottom of modal */
.progress-modal-overlay .btn-secondary {
    background: rgba(255, 255, 255, 0.15);
    border: 2px solid rgba(255, 255, 255, 0.3);
    color: #ffffff;
    font-size: clamp(0.9rem, 3.5vw, 1rem);
    padding: 14px 28px;

    /* iOS minimum touch target */
    min-height: 44px;

    /* Smooth interaction */
    transition: all 0.2s ease;
    -webkit-tap-highlight-color: transparent;
    touch-action: manipulation;
}

.progress-modal-overlay .btn-secondary:hover,
.progress-modal-overlay .btn-secondary:active {
    background: rgba(255, 255, 255, 0.25);
    border-color: rgba(255, 255, 255, 0.5);
    transform: translateY(-1px);
}

/* Animations */
@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

@keyframes slideUpModal {
    from {
        transform: translateY(30px) translateZ(0);
        opacity: 0;
    }
    to {
        transform: translateY(0) translateZ(0);
        opacity: 1;
    }
}

/* Body scroll lock when modal is open */
body.modal-open {
    overflow: hidden;
    position: fixed;
    width: 100%;
    height: 100%;

    /* iOS-specific scroll lock */
    -webkit-overflow-scrolling: none;
}

/* Mobile-specific adjustments */
@media (max-width: 768px) {
    .progress-modal-overlay {
        padding: 16px;
    }

    .progress-modal-overlay .progress-container {
        max-width: 100%;
        padding: 16px;
    }

    .progress-modal-close {
        top: 12px;
        right: 12px;
        width: 44px;
        height: 44px;
        font-size: 24px;
    }

    .progress-modal-overlay .progress-header h3 {
        font-size: 1.25rem;
    }

    .progress-modal-overlay .progress-bar {
        height: 10px; /* Slightly thicker on mobile for visibility */
    }
}

/* Extra small mobile phones */
@media (max-width: 375px) {
    .progress-modal-overlay .progress-container {
        padding: 12px;
    }

    .progress-modal-overlay .progress-header h3 {
        font-size: 1.125rem;
    }
}

/* Landscape mobile orientation */
@media (max-width: 768px) and (orientation: landscape) {
    .progress-modal-overlay {
        padding: 12px;
    }

    .progress-modal-overlay .progress-container {
        max-height: 90vh;
        overflow-y: auto;
        -webkit-overflow-scrolling: touch;
    }
}

/* Demo Banner */
.demo-banner {
    background: var(--warning-yellow);
    padding: var(--space-md);
    text-align: center;
    position: sticky;
    top: 60px;
    z-index: 90;
}

.demo-badge {
    background: rgba(0, 0, 0, 0.2);
    color: white;
    padding: 4px 8px;
    border-radius: var(--radius-sm);
    font-weight: 600;
    font-size: 0.875rem;
    margin-right: var(--space-md);
}

.btn-close-demo {
    background: transparent;
    border: 1px solid rgba(0, 0, 0, 0.3);
    padding: 4px 12px;
    border-radius: var(--radius-sm);
    cursor: pointer;
    margin-left: var(--space-md);
}

/* How It Works Section */
.how-it-works {
    padding: var(--space-xxxl) 0;
    background: var(--bg-white);
}

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

.steps-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: var(--space-xl);
    margin-bottom: var(--space-xxl);
}

.step-card {
    text-align: center;
    position: relative;
}

.step-number {
    position: absolute;
    top: -10px;
    left: 50%;
    transform: translateX(-50%);
    width: 32px;
    height: 32px;
    background: var(--gradient-start);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 0.875rem;
}

.step-icon {
    font-size: 3rem;
    margin-bottom: var(--space-md);
    display: block;
}

.step-card h3 {
    color: var(--text-dark);
    margin-bottom: var(--space-sm);
}

.step-card p {
    color: var(--text-secondary);
    font-size: 0.95rem;
}

/* Sample Preview */
.sample-preview {
    text-align: center;
    padding: var(--space-xl);
    background: var(--bg-light);
    border-radius: var(--radius-lg);
}

.sample-preview h3 {
    margin-bottom: var(--space-lg);
}

.preview-wrapper {
    position: relative;
    display: inline-block;
    cursor: pointer;
    border-radius: var(--radius-md);
    overflow: hidden;
    box-shadow: var(--shadow-md);
    transition: var(--transition-normal);
}

.preview-wrapper:hover {
    transform: scale(1.02);
    box-shadow: var(--shadow-lg);
}

.preview-image {
    max-width: 100%;
    height: auto;
    display: block;
}

.preview-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.7);
    color: white;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: var(--transition-normal);
}

.preview-wrapper:hover .preview-overlay {
    opacity: 1;
}

.preview-icon {
    font-size: 2rem;
    margin-bottom: var(--space-sm);
}

/* Pricing Section */
.pricing {
    padding: var(--space-xxxl) 0;
    background: var(--bg-light);
}

.pricing-card {
    background: var(--bg-white);
    border-radius: var(--radius-lg);
    padding: var(--space-xl);
    max-width: 600px;
    margin: 0 auto;
    box-shadow: var(--shadow-md);
}

.pricing-header {
    text-align: center;
    padding-bottom: var(--space-xl);
    border-bottom: 1px solid var(--border-gray);
}

.pricing-title {
    font-size: 1.5rem;
    margin-bottom: var(--space-md);
}

.pricing-amount {
    display: flex;
    align-items: baseline;
    justify-content: center;
    gap: var(--space-xs);
}

.pricing-amount .currency {
    font-size: 1.5rem;
    color: var(--text-secondary);
}

.pricing-amount .amount {
    font-size: 3rem;
    font-weight: 700;
    color: var(--primary-blue);
}

.pricing-amount .per {
    font-size: 1.2rem;
    color: var(--text-secondary);
}

.pricing-minimum {
    font-size: 0.875rem;
    color: var(--text-tertiary);
    margin-top: var(--space-sm);
}

.pricing-features {
    padding: var(--space-xl) 0;
}

.pricing-features h4 {
    margin-bottom: var(--space-md);
}

.features-list {
    list-style: none;
}

.features-list li {
    padding: var(--space-sm) 0;
    display: flex;
    align-items: center;
    gap: var(--space-md);
}

.features-list .check {
    color: var(--success-green);
    font-weight: 700;
}

.pricing-calculator {
    background: var(--bg-light);
    padding: var(--space-lg);
    border-radius: var(--radius-md);
}

.pricing-calculator h4 {
    margin-bottom: var(--space-md);
}

.calculator-input {
    margin-bottom: var(--space-md);
}

.calculator-input label {
    display: block;
    margin-bottom: var(--space-sm);
    color: var(--text-secondary);
}

.calculator-input input {
    width: 100%;
    padding: var(--space-sm) var(--space-md);
    border: 1px solid var(--border-gray);
    border-radius: var(--radius-sm);
    font-size: 1rem;
}

.calculator-result {
    font-size: 1.125rem;
    color: var(--text-dark);
}

.calculator-result strong {
    color: var(--success-green);
}

/* Testimonials */
.testimonials {
    padding: var(--space-xxxl) 0;
    background: var(--bg-white);
}

.testimonials-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: var(--space-xl);
}

.testimonial-card {
    background: var(--bg-light);
    padding: var(--space-xl);
    border-radius: var(--radius-lg);
    position: relative;
}

.testimonial-card::before {
    content: '"';
    font-size: 4rem;
    color: var(--gradient-start);
    opacity: 0.2;
    position: absolute;
    top: var(--space-md);
    left: var(--space-lg);
}

.testimonial-content {
    font-style: italic;
    margin-bottom: var(--space-lg);
    position: relative;
    z-index: 1;
    line-height: 1.8;
}

.testimonial-author {
    display: flex;
    flex-direction: column;
    gap: var(--space-xs);
}

.testimonial-author strong {
    color: var(--text-dark);
}

.testimonial-author span {
    font-size: 0.875rem;
    color: var(--text-secondary);
}

/* FAQ Section */
.faq {
    padding: var(--space-xxxl) 0;
    background: var(--bg-light);
}

.faq-list {
    max-width: 800px;
    margin: 0 auto;
}

.faq-item {
    background: var(--bg-white);
    border-radius: var(--radius-md);
    margin-bottom: var(--space-md);
    overflow: hidden;
}

.faq-question {
    width: 100%;
    padding: var(--space-lg);
    background: var(--bg-white);
    border: none;
    text-align: left;
    font-size: 1.1rem;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: var(--transition-normal);
}

.faq-question:hover {
    background: var(--bg-light);
}

.faq-arrow {
    transition: transform 0.3s ease;
    font-size: 0.875rem;
}

.faq-item.active .faq-arrow {
    transform: rotate(180deg);
}

.faq-answer {
    padding: 0 var(--space-lg);
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease, padding 0.3s ease;
}

.faq-item.active .faq-answer {
    padding: 0 var(--space-lg) var(--space-lg);
    max-height: 500px;
}

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

/* Footer */
.footer {
    background: var(--text-dark);
    color: var(--bg-white);
    padding: var(--space-xxl) 0;
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: var(--space-xl);
    margin-bottom: var(--space-xl);
}

.footer-section h4 {
    color: var(--bg-white);
    margin-bottom: var(--space-md);
}

.footer-section p,
.footer-section a {
    color: rgba(255, 255, 255, 0.8);
    line-height: 1.8;
}

.footer-section a {
    display: block;
    margin-bottom: var(--space-sm);
}

.footer-section a:hover {
    color: var(--bg-white);
    text-decoration: none;
}

.footer-bottom {
    padding-top: var(--space-xl);
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
}

.payment-badges {
    display: flex;
    gap: var(--space-lg);
}

.badge {
    font-size: 0.875rem;
    opacity: 0.8;
}

/* Lightbox Modal */
.lightbox-modal {
    display: none;
    position: fixed;
    z-index: 9999;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.9);
}

.lightbox-modal.show {
    display: flex;
    justify-content: center;
    align-items: center;
    animation: fadeIn 0.3s ease;
}

.lightbox-content {
    position: relative;
    max-width: 90%;
    max-height: 90%;
    animation: zoomIn 0.3s ease;
}

.lightbox-image {
    width: 100%;
    height: auto;
    border-radius: var(--radius-md);
    box-shadow: 0 0 50px rgba(0, 0, 0, 0.5);
}

.lightbox-close {
    position: absolute;
    top: -40px;
    right: 0;
    color: white;
    font-size: 35px;
    font-weight: bold;
    cursor: pointer;
    background: none;
    border: none;
    width: 40px;
    height: 40px;
    line-height: 40px;
    text-align: center;
    transition: transform 0.2s;
}

.lightbox-close:hover {
    transform: scale(1.2);
}

/* Demo Modal */
.demo-modal {
    display: none;
    position: fixed;
    z-index: 9999;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.7);
}

.demo-modal.show {
    display: flex;
    justify-content: center;
    align-items: center;
    animation: fadeIn 0.3s ease;
}

.demo-modal-content {
    background: var(--bg-white);
    border-radius: var(--radius-xl);
    max-width: 800px;
    width: 90%;
    max-height: 80%;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    animation: slideUp 0.3s ease;
}

.demo-modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: var(--space-lg);
    border-bottom: 1px solid var(--border-gray);
}

.demo-modal-body {
    flex: 1;
    overflow-y: auto;
    padding: var(--space-lg);
}

.demo-notice {
    background: var(--warning-yellow);
    color: #856404;
    padding: var(--space-md);
    border-radius: var(--radius-md);
    margin-bottom: var(--space-lg);
    text-align: center;
}

.demo-results {
    display: grid;
    gap: var(--space-md);
}

.demo-result-card {
    padding: var(--space-md);
    background: var(--bg-light);
    border-radius: var(--radius-md);
    border-left: 4px solid var(--gradient-start);
}

.demo-modal-footer {
    padding: var(--space-lg);
    border-top: 1px solid var(--border-gray);
    text-align: center;
}

/* Animations */
@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes zoomIn {
    from {
        transform: scale(0.8);
        opacity: 0;
    }
    to {
        transform: scale(1);
        opacity: 1;
    }
}

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

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

@keyframes shake {
    0%, 100% { transform: translateX(0); }
    10%, 30%, 50%, 70%, 90% { transform: translateX(-5px); }
    20%, 40%, 60%, 80% { transform: translateX(5px); }
}

.tag-input-wrapper.shake {
    animation: shake 0.5s;
}

/* Loading Spinner */
.loading-spinner {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 3px solid rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    border-top-color: white;
    animation: spin 0.8s linear infinite;
    margin-right: var(--space-sm);
}

/* Responsive Design */
@media (max-width: 768px) {
    /* Typography adjustments */
    h1 { font-size: 2rem; }
    h2 { font-size: 1.5rem; }
    h3 { font-size: 1.25rem; }
    
    .hero-title { font-size: 2rem; }
    .hero-subtitle { font-size: 1rem; }
    
    /* Container padding */
    .container {
        padding: 0 var(--space-md);
    }
    
    /* Hero adjustments */
    .hero {
        padding: var(--space-xl) 0;
    }
    
    /* Trust signals stack */
    .trust-signals {
        flex-direction: column;
        align-items: center;
        gap: var(--space-md);
    }
    
    /* Search card adjustments */
    .search-card {
        padding: var(--space-lg);
    }
    
    /* Region selector adjustments */
    .region-selector {
        grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
    }
    
    /* Steps grid stack */
    .steps-grid {
        grid-template-columns: 1fr;
    }
    
    /* Testimonials stack */
    .testimonials-grid {
        grid-template-columns: 1fr;
    }
    
    /* Footer adjustments */
    .footer-content {
        grid-template-columns: 1fr;
        text-align: center;
    }
    
    .footer-bottom {
        flex-direction: column;
        gap: var(--space-md);
        text-align: center;
    }
    
    /* Hide desktop nav, show mobile menu */
    .nav-menu {
        display: none; /* Will be replaced with hamburger menu */
    }
    
    /* Form button full width */
    .btn-large {
        padding: 14px 20px;
    }
}

@media (max-width: 480px) {
    /* Even smaller adjustments for mobile phones */
    .hero-title { font-size: 1.75rem; }
    
    .pricing-amount .amount {
        font-size: 2.5rem;
    }
    
    .region-selector {
        grid-template-columns: 1fr;
    }
}

/* Accessibility - Focus States */
:focus-visible {
    outline: 2px solid var(--primary-blue);
    outline-offset: 2px;
}

/* Reduced Motion */
@media (prefers-reduced-motion: reduce) {
    * {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}

/* High Contrast Mode Support */
@media (prefers-contrast: high) {
    .form-input {
        border-width: 3px;
    }
    
    .btn {
        border: 2px solid currentColor;
    }
}

/* Print Styles */
@media print {
    .header, .footer, .hero, .demo-banner {
        display: none;
    }
    
    .container {
        max-width: 100%;
    }
}
