/* ===== DEPARTMENTS PAGE STYLES ===== */

.departments-hero {
    padding: calc(var(--spacing-unit) * 12) 0 calc(var(--spacing-unit) * 8);
    padding-top: 120px;
    background: var(--graphite-black);
}

.hero-subtitle {
    font-size: clamp(1.125rem, 2vw, 1.375rem);
    color: rgba(209, 213, 219, 0.8);
    margin-top: calc(var(--spacing-unit) * 3);
    max-width: 100%;
    text-align: center;
}

.departments-grid-section {
    padding: calc(var(--spacing-unit) * 12) 0;
    background: var(--tungsten-gray);
}

.department-card {
    background: var(--graphite-black);
    border-radius: 24px;
    overflow: hidden;
    transition: var(--transition-smooth);
    box-shadow: 
        8px 8px 16px rgba(0, 0, 0, 0.3),
        -4px -4px 8px rgba(255, 255, 255, 0.02);
    height: 100%;
    display: flex;
    flex-direction: column;
    position: relative;
}

.department-card:hover {
    transform: translateY(-8px);
    box-shadow: 
        12px 12px 24px rgba(0, 0, 0, 0.4),
        -6px -6px 12px rgba(255, 255, 255, 0.03);
}

.dept-header {
    position: relative;
    height: 200px;
    overflow: hidden;
}

.dept-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    filter: brightness(1) contrast(1.05);
    transition: var(--transition-smooth);
    opacity: 1;
}

[data-theme="dark"] .dept-image {
    filter: brightness(0.85) contrast(1.1);
}

.department-card:hover .dept-image {
    filter: brightness(1.05) contrast(1.1);
    transform: scale(1.05);
}

[data-theme="dark"] .department-card:hover .dept-image {
    filter: brightness(0.95) contrast(1.15);
}

.dept-code {
    position: absolute;
    top: calc(var(--spacing-unit) * 2);
    left: calc(var(--spacing-unit) * 2);
    font-family: var(--font-mono);
    font-size: 3rem;
    font-weight: 300;
    color: rgba(184, 115, 51, 0.9);
    line-height: 1;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
    z-index: 1;
}

.dept-body {
    padding: calc(var(--spacing-unit) * 4);
    flex: 1;
    display: flex;
    flex-direction: column;
}

.dept-body h3 {
    font-size: clamp(1.25rem, 2vw, 1.5rem);
    margin-bottom: calc(var(--spacing-unit) * 2);
    color: var(--titanium-silver);
    line-height: 1.2;
}

.dept-description {
    color: rgba(209, 213, 219, 0.8);
    font-size: 0.9375rem;
    line-height: 1.7;
    margin-bottom: calc(var(--spacing-unit) * 3);
    flex-grow: 1;
    max-width: 100%;
}

.dept-features {
    display: flex;
    flex-wrap: wrap;
    gap: calc(var(--spacing-unit) * 1);
    margin-bottom: calc(var(--spacing-unit) * 3);
}

.feature-tag {
    font-family: var(--font-mono);
    font-size: 0.75rem;
    color: rgba(184, 115, 51, 0.8);
    background: rgba(184, 115, 51, 0.1);
    padding: calc(var(--spacing-unit) * 0.5) calc(var(--spacing-unit) * 1.5);
    border-radius: 12px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    border: 1px solid rgba(184, 115, 51, 0.2);
}

.dept-stats {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: calc(var(--spacing-unit) * 2);
    margin-bottom: calc(var(--spacing-unit) * 4);
    padding: calc(var(--spacing-unit) * 3);
    background: rgba(255, 255, 255, 0.02);
    border-radius: 16px;
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.stat-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
}

.stat-number {
    font-family: var(--font-heading);
    font-weight: 700;
    font-size: 1.75rem;
    color: var(--molten-copper);
    line-height: 1;
    margin-bottom: calc(var(--spacing-unit) * 0.5);
}

.stat-text {
    font-size: 0.75rem;
    color: rgba(209, 213, 219, 0.6);
    text-transform: uppercase;
    letter-spacing: 1px;
    font-family: var(--font-mono);
}

.department-card .btn-neo {
    width: 100%;
    text-align: center;
    margin-top: auto;
    padding: calc(var(--spacing-unit) * 1.5) calc(var(--spacing-unit) * 3);
}

@media (max-width: 991px) {
    .dept-header {
        height: 180px;
    }
    
    .dept-code {
        font-size: 2.5rem;
    }
    
    .dept-stats {
        grid-template-columns: repeat(4, 1fr);
        gap: calc(var(--spacing-unit) * 1.5);
    }
    
    .stat-number {
        font-size: 1.5rem;
    }
}

@media (max-width: 768px) {
    .departments-hero {
        padding-top: calc(var(--spacing-unit) * 12);
        padding-bottom: calc(var(--spacing-unit) * 6);
        overflow-x: hidden;
        width: 100%;
        max-width: 100vw;
    }
    
    .departments-hero .container {
        padding-left: calc(var(--spacing-unit) * 2);
        padding-right: calc(var(--spacing-unit) * 2);
        max-width: 100% !important;
        width: 100% !important;
        margin-left: 0 !important;
        margin-right: 0 !important;
    }
    
    .departments-hero .row {
        margin-left: 0 !important;
        margin-right: 0 !important;
        width: 100%;
    }
    
    .departments-hero .row > [class*="col-"] {
        padding-left: 0;
        padding-right: 0;
        width: 100%;
        max-width: 100%;
    }
    
    .departments-hero .page-title {
        font-size: clamp(1.5rem, 8vw, 2.5rem);
        word-wrap: break-word;
        overflow-wrap: break-word;
        white-space: normal !important;
        width: 100%;
        max-width: 100%;
        text-align: center;
        padding-left: calc(var(--spacing-unit) * 2);
        padding-right: calc(var(--spacing-unit) * 2);
    }
    
    .departments-hero .hero-subtitle {
        width: 100%;
        max-width: 100%;
        padding-left: calc(var(--spacing-unit) * 2);
        padding-right: calc(var(--spacing-unit) * 2);
    }
    
    .departments-grid-section {
        padding: calc(var(--spacing-unit) * 8) 0;
        overflow-x: hidden;
        width: 100%;
        max-width: 100vw;
    }
    
    .departments-grid-section .container {
        padding-left: calc(var(--spacing-unit) * 2);
        padding-right: calc(var(--spacing-unit) * 2);
        max-width: 100% !important;
        width: 100% !important;
        margin-left: 0 !important;
        margin-right: 0 !important;
    }
    
    .departments-grid-section .row {
        margin-left: 0 !important;
        margin-right: 0 !important;
        width: 100%;
    }
    
    .departments-grid-section .row > [class*="col-"] {
        padding-left: calc(var(--spacing-unit) * 1);
        padding-right: calc(var(--spacing-unit) * 1);
        width: 100%;
        max-width: 100%;
    }
    
    .department-card {
        width: 100%;
        max-width: 100%;
        margin-left: 0;
        margin-right: 0;
    }
    
    .dept-header {
        height: 160px;
    }
    
    .dept-code {
        font-size: 2rem;
    }
    
    .dept-stats {
        grid-template-columns: repeat(2, 1fr);
        padding: calc(var(--spacing-unit) * 2);
    }
    
    .stat-number {
        font-size: 1.5rem;
    }
    
    .dept-features {
        gap: calc(var(--spacing-unit) * 0.75);
    }
    
    .feature-tag {
        font-size: 0.6875rem;
        padding: calc(var(--spacing-unit) * 0.5) calc(var(--spacing-unit) * 1);
    }
    
    .dept-body h3 {
        word-wrap: break-word;
        overflow-wrap: break-word;
    }
    
    .dept-description {
        word-wrap: break-word;
        overflow-wrap: break-word;
    }
}
