/* Custom styles for The Hospitality Hub */

/* Housing Progress Bar Styles */
.housing-progress-container {
    padding: 20px !important;
    background: linear-gradient(135deg, #f8f9fa, #e9ecef) !important;
    border-radius: 15px !important;
    margin: 20px 0 !important;
}

.progress-stages {
    display: flex !important;
    align-items: center !important;
    justify-content: space-between !important;
    position: relative !important;
    overflow-x: auto !important;
    padding: 10px 0 !important;
}

.stage-item {
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    min-width: 120px !important;
    cursor: pointer !important;
    transition: all 0.3s ease !important;
    position: relative !important;
}

.stage-item:hover {
    transform: translateY(-5px) !important;
}

.stage-circle {
    width: 50px !important;
    height: 50px !important;
    border-radius: 50% !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15) !important;
    border: 3px solid white !important;
    margin-bottom: 10px !important;
    position: relative !important;
    z-index: 2 !important;
}

.stage-number {
    color: white !important;
    font-weight: bold !important;
    font-size: 18px !important;
}

.stage-info {
    text-align: center !important;
}

.stage-title {
    font-size: 12px !important;
    font-weight: 600 !important;
    color: #2c3e50 !important;
    margin-bottom: 5px !important;
    line-height: 1.2 !important;
    max-width: 100px !important;
}

.stage-count {
    font-size: 24px !important;
    font-weight: bold !important;
    color: #2c3e50 !important;
}

.stage-connector {
    height: 6px !important;
    flex: 1 !important;
    margin: 0 5px !important;
    border-radius: 3px !important;
    position: relative !important;
    top: -25px !important;
    z-index: 1 !important;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1) !important;
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .progress-stages {
        flex-wrap: wrap !important;
        gap: 15px !important;
    }
    
    .stage-connector {
        display: none !important;
    }
    
    .stage-item {
        min-width: auto !important;
        flex: 1 1 calc(25% - 10px) !important;
    }
}

@media (max-width: 480px) {
    .stage-item {
        flex: 1 1 calc(33% - 10px) !important;
    }
}

:root {
    --bs-primary-rgb: 13, 110, 253;
    --bs-success-rgb: 25, 135, 84;
    --bs-info-rgb: 13, 202, 240;
    --bs-warning-rgb: 255, 193, 7;
    --bs-danger-rgb: 220, 53, 69;
    --bs-purple: #6f42c1;
    --bs-purple-rgb: 111, 66, 193;
}

/* Custom purple text color */
.text-purple {
    color: var(--bs-purple) !important;
}

/* Hero section styling */
.hero-section {
    background: linear-gradient(135deg, var(--bs-primary) 0%, var(--bs-info) 100%);
    border-radius: 1rem !important;
}

/* Card hover effects */
.card {
    transition: transform 0.2s ease-in-out, box-shadow 0.2s ease-in-out;
}

.card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

/* Program card specific styling */
.program-card {
    border: 2px solid transparent;
    background: #ffffff;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
}

.program-card:hover {
    border-color: var(--bs-primary);
    background: #ffffff;
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
}

.program-card .card-body {
    padding: 1.5rem;
}

.program-card i {
    transition: transform 0.3s ease;
}

.program-card:hover i {
    transform: scale(1.1);
}

.program-card .card-title {
    color: #212529;
    font-weight: 600;
}

.program-card .text-muted {
    color: #6c757d !important;
    font-size: 0.9rem;
}

.program-description {
    color: #495057 !important;
    font-size: 0.9rem;
    line-height: 1.4;
}

/* Service type badges */
.badge {
    font-size: 0.85em;
    padding: 0.5em 0.75em;
}

/* Mobile optimizations */
@media (max-width: 768px) {
    .container {
        padding-left: 1rem;
        padding-right: 1rem;
    }
    
    .card-body {
        padding: 1rem;
    }
    
    .btn {
        width: 100%;
        margin-bottom: 0.5rem;
    }
    
    .btn:last-child {
        margin-bottom: 0;
    }
    
    /* Stack form elements on mobile */
    .row.g-3 .col-md-6,
    .row.g-3 .col-md-4,
    .row.g-3 .col-md-3 {
        margin-bottom: 1rem;
    }
}

/* Table responsiveness */
.table-responsive {
    border-radius: 0.5rem;
}

/* Form enhancements */
.form-control:focus,
.form-select:focus {
    border-color: var(--bs-primary);
    box-shadow: 0 0 0 0.2rem rgba(var(--bs-primary-rgb), 0.25);
}

/* Loading states */
.spinner-border {
    width: 2rem;
    height: 2rem;
}

/* Chart container */
canvas {
    max-height: 400px;
}

/* Navigation enhancements */
.navbar-brand {
    font-weight: 600;
}

.nav-link {
    transition: color 0.15s ease-in-out;
}

/* Footer styling */
footer {
    margin-top: auto;
}

/* Alert styling */
.alert {
    border: none;
    border-radius: 0.75rem;
}

/* Stats cards */
.card .fa-2x {
    opacity: 0.8;
}

/* Button group spacing */
.btn + .btn {
    margin-left: 0.5rem;
}

@media (max-width: 576px) {
    .btn + .btn {
        margin-left: 0;
        margin-top: 0.5rem;
    }
}

/* Service entry form enhancements */
.form-text {
    font-size: 0.875em;
    color: var(--bs-secondary);
}

/* Admin panel specific styles */
.admin-stat-card {
    background: linear-gradient(135deg, rgba(var(--bs-primary-rgb), 0.1) 0%, rgba(var(--bs-primary-rgb), 0.05) 100%);
}

/* Print styles */
@media print {
    .navbar,
    .btn,
    footer {
        display: none !important;
    }
    
    .card {
        border: 1px solid #dee2e6 !important;
        box-shadow: none !important;
    }
    
    .table {
        font-size: 0.875rem;
    }
}

/* 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,
    .nav-link,
    .btn {
        transition: none;
    }
}

/* Housing Program Stage indicator styles */
.stage-indicator {
    position: relative;
    margin-bottom: 10px;
    text-align: center !important;
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
}

/* Client Intake Stage Numbers - Override all other stage-number styles */
.stage-indicator .stage-number {
    width: 100% !important;
    height: 35px !important;
    border-radius: 10px !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    font-family: 'Barlow', sans-serif !important;
    font-weight: 700 !important;
    font-size: 1.25rem !important;
    margin: 0 auto 8px !important;
    transition: all 0.3s ease !important;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1) !important;
}

.stage-indicator .stage-title {
    font-size: 0.95rem !important;
    color: #495057 !important;
    font-family: 'Barlow', sans-serif !important;
    font-weight: 700 !important;
    line-height: 1.2 !important;
    text-align: center !important;
}

.stage-count {
    font-size: 1.25rem;
    margin-top: 8px;
}

/* Responsive adjustments for smaller screens */
@media (max-width: 768px) {
    .stage-indicator .stage-number {
        width: 100% !important;
        height: 30px !important;
        font-size: 0.75rem !important;
        border-radius: 8px !important;
    }
    
    .stage-indicator .stage-title {
        font-size: 0.6rem !important;
    }
}

@media (max-width: 576px) {
    .stage-indicator .stage-number {
        width: 100% !important;
        height: 25px !important;
        font-size: 0.7rem !important;
        border-radius: 6px !important;
    }
    
    .stage-indicator .stage-title {
        font-size: 0.55rem !important;
        line-height: 1.1 !important;
    }
}
