:root {
    --utm-maroon: #7d0101;
    --utm-maroon-dark: #4a0000;
    --utm-maroon-light: #9b1a1a;
    --accent-gold: #c5a059;
    --bg-light: #f8f9fc;
    --white: #ffffff;
    --text-main: #1a1f36;
    --text-muted: #697386;
    --glass-bg: rgba(255, 255, 255, 0.75);
    --glass-border: rgba(255, 255, 255, 0.5);
    --card-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
    --hover-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
    --transition-smooth: all 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);
}

body {
    background-color: var(--bg-light);
    color: var(--text-main);
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    -webkit-font-smoothing: antialiased;
    overflow-x: hidden;
}

h1,
h2,
h3,
h4,
.navbar-brand {
    font-family: 'Outfit', sans-serif;
    font-weight: 700;
    letter-spacing: -0.01em;
}

/* Header & Navbar */
header {
    background: var(--glass-bg);
    backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--glass-border);
    position: sticky;
    top: 0;
    z-index: 1000;
}

.navbar-brand {
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 1.25rem;
    color: var(--utm-maroon) !important;
}

.nav-link {
    font-weight: 500;
    color: var(--text-muted) !important;
    transition: var(--transition-smooth);
    padding: 0.5rem 1rem !important;
    border-radius: 8px;
}

.nav-link:hover {
    color: var(--utm-maroon) !important;
    background: rgba(125, 1, 1, 0.05);
}

/* Hero Section */
.hero-section {
    position: relative;
    background: linear-gradient(rgba(125, 1, 1, 0.8), rgba(125, 1, 1, 0.9)), url('/directory/hero-image.png');
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
    /* Parallax effect */
    padding: 120px 0 160px;
    margin-bottom: 0;
    color: white;
    text-align: center;
    overflow: hidden;
}

.hero-section::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -10%;
    width: 120%;
    height: 200%;
    background: url('https://www.transparenttextures.com/patterns/cubes.png');
    opacity: 0.03;
    /* Reduced opacity for cleaner feel */
    transform: rotate(-5deg);
}

.hero-content h1 {
    font-size: 4rem;
    font-weight: 800;
    margin-bottom: 1.5rem;
    background: linear-gradient(to bottom, #ffffff, #f0f0f0);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    text-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
}

.hero-content p {
    font-size: 1.4rem;
    opacity: 0.9;
    font-weight: 300;
    max-width: 600px;
    margin: 0 auto;
    /* Ensure centering */
    line-height: 1.6;
}

/* Hero Search Bar */
.hero-search {
    max-width: 760px;
    margin: 0 auto;
    position: relative;
    padding: 0 15px;
}

.hero-search .form-control {
    height: 72px;
    padding: 0 180px 0 32px;
    font-size: 1.2rem;
    border-radius: 20px;
    border: none;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.2);
    transition: var(--transition-smooth);
}

.hero-search .form-control:focus {
    box-shadow: 0 25px 50px rgba(0, 0, 0, 0.3);
    transform: translateY(-2px);
}

.hero-search .btn-search {
    position: absolute;
    right: 25px;
    top: 8px;
    bottom: 8px;
    width: 140px;
    background: var(--utm-maroon);
    color: white;
    border: none;
    border-radius: 14px;
    font-weight: 600;
    font-size: 1.1rem;
    transition: var(--transition-smooth);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.hero-search .btn-search:hover {
    background: var(--utm-maroon-dark);
    transform: scale(1.02);
}

/* Statistics */
.stat-item {
    padding: 1.5rem;
}

.stat-item .count {
    font-size: 3rem;
    font-weight: 800;
    font-family: 'Outfit', sans-serif;
    color: var(--white);
    display: block;
}

.stat-item .label {
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 0.2em;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.7);
}

/* Category Grid */
.category-grid {
    margin-top: -80px;
    padding-bottom: 80px;
}

.category-card {
    background: var(--white);
    border-radius: 24px;
    padding: 2.5rem 2rem;
    text-align: center;
    text-decoration: none !important;
    transition: var(--transition-smooth);
    border: 1px solid rgba(0, 0, 0, 0.05);
    /* Softer border */
    box-shadow: var(--card-shadow);
    height: 100%;
    overflow: hidden;
    /* Prevent leaking design elements */
    position: relative;
    display: block;
}

.category-card:hover {
    transform: translateY(-12px);
    box-shadow: var(--hover-shadow);
}

.category-icon {
    width: 72px;
    height: 72px;
    background: #fff5f5;
    border-radius: 20px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 2rem;
    color: var(--utm-maroon);
    margin-bottom: 2rem;
    transition: var(--transition-smooth);
}

.category-card:hover .category-icon {
    background: var(--utm-maroon);
    color: white;
    transform: rotate(-8deg);
}

.category-card h3 {
    font-size: 1.4rem;
    color: var(--text-main);
    margin-bottom: 1rem;
}

.category-card p {
    color: var(--text-muted);
    font-size: 0.95rem;
    line-height: 1.5;
}

/* Section Title */
.section-title {
    font-size: 2rem;
    margin-bottom: 3rem;
    color: var(--text-main);
    display: flex;
    align-items: center;
    gap: 15px;
}

.section-title::after {
    content: '';
    flex: 1;
    height: 1px;
    background: linear-gradient(to right, #e0e0e0, transparent);
}

/* Staff Cards */
.staff-card-v2 {
    background: var(--white);
    border-radius: 20px;
    border: 1px solid rgba(0, 0, 0, 0.03);
    box-shadow: var(--card-shadow);
    transition: var(--transition-smooth);
    overflow: hidden;
    height: 100%;
}

.staff-card-v2:hover {
    transform: translateY(-5px);
    box-shadow: var(--hover-shadow);
}

.staff-card-content {
    padding: 24px;
    display: flex;
    flex-direction: column;
}

.staff-header {
    display: flex;
    gap: 16px;
    margin-bottom: 20px;
}

.staff-img-wrapper {
    width: 80px;
    height: 80px;
    overflow: hidden;
    border-radius: 16px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    background: #f0f0f0;
}

.staff-img-wrapper img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s ease;
}

.staff-card-v2:hover .staff-img-wrapper img {
    transform: scale(1.1);
}

.staff-info-wrapper {
    flex: 1;
}

.faculty-tag {
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--utm-maroon);
    background: rgba(125, 1, 1, 0.06);
    padding: 4px 10px;
    border-radius: 6px;
    display: inline-block;
    margin-bottom: 8px;
}

.staff-name {
    font-size: 1.2rem;
    font-weight: 700;
    line-height: 1.25;
    margin-bottom: 6px;
    color: var(--text-main);
}

.staff-title {
    font-size: 0.9rem;
    color: var(--text-muted);
}

.view-profile-btn {
    margin-top: auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding-top: 16px;
    border-top: 1px solid #f0f0f0;
    color: var(--utm-maroon);
    font-weight: 600;
    text-decoration: none !important;
    font-size: 0.9rem;
}

.view-profile-btn i {
    transition: transform 0.3s ease;
}

.view-profile-btn:hover i {
    transform: translateX(5px);
}

/* Footer Overlay */
.footer-overlay {
    background: white;
    padding: 60px 0;
    text-align: center;
    border-top: 1px solid #eee;
}

.footer-overlay img {
    max-height: 40px;
    opacity: 0.8;
    margin-bottom: 20px;
}

/* Staff Profile Refinements */
.img-cover {
    object-fit: cover !important;
    object-position: center !important;
}

.staff-hero-avatar img {
    object-fit: cover !important;
    width: 100% !important;
    height: 100% !important;
}

.contact-item .icon-box {
    width: 48px !important;
    height: 48px !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    flex: 0 0 48px !important;
    border-radius: 12px !important;
    padding: 0 !important;
    margin: 0 !important;
}

.contact-item .icon-box i {
    font-size: 1.25rem !important;
    width: 24px !important;
    text-align: center !important;
    line-height: 1 !important;
    margin: 0 !important;
}

.contact-item .small {
    font-size: 0.7rem !important;
    letter-spacing: 0.05em !important;
    margin-bottom: 0px !important;
    font-weight: 700 !important;
    opacity: 0.8 !important;
}

.contact-item .contact-data {
    font-size: 1rem !important;
    line-height: 1.3 !important;
    letter-spacing: -0.01em !important;
}

.navbar-brand-text {
    font-size: 1.1rem;
    letter-spacing: -0.02em;
}

@media (max-width: 576px) {
    .navbar-brand-text {
        font-size: 1rem;
    }
}

@media (max-width: 768px) {
    .staff-hero-avatar {
        width: 180px !important;
        height: 180px !important;
    }

    .profile-hero h1 {
        font-size: 2rem;
    }
}

@media (max-width: 992px) {
    .hero-content h1 {
        font-size: 3rem;
    }

    .hero-content p {
        font-size: 1.2rem;
    }
}

@media (max-width: 576px) {
    .hero-content h1 {
        font-size: 2.5rem;
    }

    .hero-search .btn-search {
        position: static;
        width: 100%;
        height: 56px;
        margin-top: 10px;
    }

    .hero-search .form-control {
        height: 60px;
        padding: 0 20px;
    }

    .hero-section {
        padding: 80px 0 120px;
    }
}

/* Utilities */
.text-maroon {
    color: var(--utm-maroon) !important;
}

.bg-maroon {
    background-color: var(--utm-maroon) !important;
}

.bg-maroon-subtle {
    background-color: rgba(125, 1, 1, 0.05) !important;
}

.btn-maroon {
    background: var(--utm-maroon);
    color: white;
    border: none;
    transition: var(--transition-smooth);
}

.btn-maroon:hover {
    background: var(--utm-maroon-dark);
    color: white;
    transform: translateY(-2px);
}

.btn-outline-maroon {
    background: transparent;
    color: var(--utm-maroon);
    border: 1px solid var(--utm-maroon);
    transition: var(--transition-smooth);
}

.btn-outline-maroon:hover {
    background: var(--utm-maroon);
    color: white;
}

.rounded-4 {
    border-radius: 1rem !important;
}
