/* Custom styles for Sparkles & Suds Cleaning App */

/* Global Styles */
:root {
    --cleaning-blue: #007bff;
    --cleaning-green: #28a745;
    --cleaning-teal: #17a2b8;
    --sparkle-gold: #ffc107;
    --clean-white: #ffffff;
    --soft-gray: #6c757d;
}

/* Hero Section */
.hero-section {
    background: linear-gradient(135deg, var(--brand-primary), var(--brand-secondary));
    position: relative;
    overflow: hidden;
}

.hero-section::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 100 100"><circle cx="20" cy="20" r="2" fill="rgba(255,255,255,0.1)"/><circle cx="80" cy="40" r="1" fill="rgba(255,255,255,0.1)"/><circle cx="40" cy="80" r="1.5" fill="rgba(255,255,255,0.1)"/><circle cx="90" cy="90" r="1" fill="rgba(255,255,255,0.1)"/><circle cx="10" cy="60" r="1" fill="rgba(255,255,255,0.1)"/></svg>') repeat;
    opacity: 0.3;
}

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

/* Card Enhancements */
.card {
    border: none;
    box-shadow: 0 0.125rem 0.25rem rgba(0, 0, 0, 0.075);
    transition: box-shadow 0.15s ease-in-out;
}

.card:hover {
    box-shadow: 0 0.5rem 1rem rgba(0, 0, 0, 0.15);
}

/* Custom Form Check Cards */
.form-check-label .card {
    cursor: pointer;
    transition: all 0.2s ease;
    border: 2px solid transparent;
}

.form-check-input:checked + .form-check-label .card {
    border-color: var(--brand-primary);
    background-color: rgba(var(--bs-primary-rgb), 0.1);
}

.form-check-label .card:hover {
    border-color: var(--brand-primary);
    transform: translateY(-2px);
}

/* Status Badges */
.badge {
    font-size: 0.75em;
    padding: 0.35em 0.65em;
}

/* Dashboard Cards */
.dashboard-stat-card {
    background: linear-gradient(135deg, #f8f9fa, #e9ecef);
    border-left: 4px solid var(--brand-primary);
}

.dashboard-stat-card .card-body {
    padding: 1.5rem;
}

.dashboard-stat-card h3 {
    font-size: 2rem;
    font-weight: bold;
    margin-bottom: 0.5rem;
}

/* Progress Bars */
.progress {
    height: 8px;
    border-radius: 4px;
}

.progress-bar {
    transition: width 0.6s ease;
}

/* Timeline Styles */
.timeline {
    position: relative;
    padding: 20px 0;
}

.timeline::before {
    content: '';
    position: absolute;
    top: 0;
    left: 30px;
    height: 100%;
    width: 2px;
    background: var(--bs-border-color);
}

.timeline-item {
    position: relative;
    margin-bottom: 30px;
    padding-left: 70px;
}

.timeline-item::before {
    content: '';
    position: absolute;
    left: 24px;
    top: 10px;
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: var(--brand-primary);
    border: 2px solid var(--bs-body-bg);
    box-shadow: 0 0 0 2px var(--brand-primary);
}

/* Appointment Cards */
.appointment-card {
    border-left: 4px solid var(--brand-primary);
    transition: all 0.2s ease;
}

.appointment-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 0.5rem 1rem rgba(0, 0, 0, 0.15);
}

.appointment-card.status-completed {
    border-left-color: var(--bs-success);
}

.appointment-card.status-on-way,
.appointment-card.status-arrived {
    border-left-color: var(--bs-warning);
}

.appointment-card.status-cancelled {
    border-left-color: var(--bs-danger);
}

/* Service Type Icons */
.service-icon {
    width: 48px;
    height: 48px;
    margin-bottom: 1rem;
    color: var(--brand-primary);
}

/* Referral Code Display */
.referral-code-display {
    background: linear-gradient(135deg, var(--brand-primary), var(--brand-secondary));
    color: white;
    padding: 20px;
    border-radius: 10px;
    text-align: center;
    margin: 20px 0;
}

.referral-code-display h3 {
    font-family: 'Courier New', monospace;
    letter-spacing: 2px;
    margin-bottom: 10px;
}

/* Loading Animations */
.loading-spinner {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 3px solid rgba(var(--bs-primary-rgb), 0.3);
    border-radius: 50%;
    border-top-color: var(--brand-primary);
    animation: spin 1s ease-in-out infinite;
}

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

/* Map Container */
.map-container {
    height: 300px;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 0.125rem 0.25rem rgba(0, 0, 0, 0.075);
}

/* Cleaner Status Indicators */
.status-indicator {
    display: inline-block;
    width: 12px;
    height: 12px;
    border-radius: 50%;
    margin-right: 8px;
}

.status-indicator.on-way {
    background-color: var(--bs-warning);
    animation: pulse 2s infinite;
}

.status-indicator.arrived {
    background-color: var(--bs-info);
}

.status-indicator.completed {
    background-color: var(--bs-success);
}

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

/* FAQ Accordion Enhancements */
.accordion-button:not(.collapsed) {
    background-color: rgba(var(--bs-primary-rgb), 0.1);
    color: var(--brand-primary);
}

.accordion-button:focus {
    border-color: var(--brand-primary);
    box-shadow: 0 0 0 0.25rem rgba(var(--bs-primary-rgb), 0.25);
}

/* Mobile Responsiveness */
@media (max-width: 768px) {
    .hero-section h1 {
        font-size: 2rem;
    }
    
    .hero-section .lead {
        font-size: 1rem;
    }
    
    .dashboard-stat-card h3 {
        font-size: 1.5rem;
    }
    
    .timeline {
        padding-left: 20px;
    }
    
    .timeline-item {
        padding-left: 50px;
    }
    
    .timeline::before {
        left: 20px;
    }
    
    .timeline-item::before {
        left: 14px;
    }
}

/* Print Styles */
@media print {
    .navbar,
    .btn,
    .modal,
    footer {
        display: none !important;
    }
    
    .card {
        border: 1px solid #000 !important;
        break-inside: avoid;
    }
    
    .container {
        max-width: none !important;
    }
}

/* Dark Mode Adjustments */
[data-bs-theme="dark"] .hero-section {
    background: linear-gradient(135deg, #1a365d, #2d5a87);
}

[data-bs-theme="dark"] .card {
    background-color: var(--bs-dark);
    border: 1px solid var(--bs-border-color);
}

[data-bs-theme="dark"] .dashboard-stat-card {
    background: linear-gradient(135deg, #2d3748, #4a5568);
    border-left-color: var(--brand-primary);
}

[data-bs-theme="dark"] .appointment-card {
    background-color: var(--bs-dark);
}

[data-bs-theme="dark"] .referral-code-display {
    background: linear-gradient(135deg, #2b6cb0, #3182ce);
}

/* Accessibility Improvements */
.btn:focus,
.form-control:focus,
.form-select:focus {
    box-shadow: 0 0 0 0.25rem rgba(var(--bs-primary-rgb), 0.25);
}

/* High contrast mode support */
@media (prefers-contrast: high) {
    .card {
        border: 2px solid var(--bs-border-color);
    }
    
    .btn {
        border-width: 2px;
    }
}

/* Reduced motion support */
@media (prefers-reduced-motion: reduce) {
    .card,
    .btn,
    .appointment-card {
        transition: none;
    }
    
    .loading-spinner,
    .status-indicator.on-way {
        animation: none;
    }
}

/* Custom utility classes */
.text-brand {
    color: var(--brand-primary) !important;
}

.bg-brand {
    background-color: var(--brand-primary) !important;
}

.border-brand {
    border-color: var(--brand-primary) !important;
}

.shadow-sm-brand {
    box-shadow: 0 0.125rem 0.25rem rgba(var(--bs-primary-rgb), 0.075) !important;
}

.shadow-brand {
    box-shadow: 0 0.5rem 1rem rgba(var(--bs-primary-rgb), 0.15) !important;
}
