﻿@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&display=swap');

:root {
    --primary-color: #d32f2f;
    /* HUFLIT red-ish color */
    --secondary-color: #f8f9fa;
}

body {
    font-family: 'Inter', sans-serif;
    background-color: #f5f7fa;
    padding-top: 70px;
    /* Space for sticky navbar */
}

/* Navbar Customization */
.navbar {
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    background-color: white;
}

.navbar-brand {
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 10px;
}

.navbar-brand i {
    font-size: 1.5rem;
    color: var(--primary-color);
}

/* Navigation Tabs */
.nav-pills .nav-link {
    color: #495057;
    border-radius: 20px;
    padding: 8px 16px;
    margin: 0 5px;
    transition: all 0.3s ease;
}

.nav-pills .nav-link.active {
    background-color: var(--primary-color);
    color: white;
}

.nav-pills .nav-link:hover:not(.active) {
    background-color: #e9ecef;
}

/* Optimize Navbar for smaller desktops (992px - 1200px) */
@media (min-width: 992px) and (max-width: 1200px) {

    /* Allow container to use more width */
    .navbar .container {
        max-width: 100%;
        padding-left: 20px;
        padding-right: 20px;
    }

    .nav-pills .nav-link {
        padding: 6px 8px;
        /* Tighter padding */
        margin: 0 1px;
        /* Tighter margin */
        font-size: 0.8rem;
        /* Smaller font */
        white-space: nowrap;
        /* Prevent wrapping */
    }

    /* Hide icons to save space if needed */
    .nav-pills .nav-link i {
        display: none;
    }

    .navbar-brand {
        font-size: 1.05rem;
        /* Compact Brand Text */
        gap: 5px;
        margin-right: 10px;
        /* Reduce margin to menu */
    }

    .navbar-brand i {
        font-size: 1.2rem;
        /* Compact Brand Icon */
    }
}

/* Tab Content */
.tab-content {
    padding: 20px 0;
}

/* Animations & Transitions */
.tab-pane {
    transition: opacity 0.3s ease-in-out, transform 0.3s ease-out;
}

.tab-pane:not(.active) {
    display: none;
    opacity: 0;
    transform: translateY(10px);
}

.tab-pane.active {
    display: block;
    opacity: 1;
    transform: translateY(0);
}

.card {
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.card:hover {
    box-shadow: 0 8px 15px rgba(0, 0, 0, 0.1) !important;
}

.transition-all {
    transition: all 0.2s ease;
}

@keyframes pulse-scale {
    0% {
        transform: scale(1);
        box-shadow: 0 0 0 0 rgba(13, 110, 253, 0.2);
    }

    50% {
        transform: scale(1.02);
        box-shadow: 0 0 0 10px rgba(13, 110, 253, 0);
    }

    100% {
        transform: scale(1);
        box-shadow: 0 0 0 0 rgba(13, 110, 253, 0);
    }
}

.animate-pulse {
    animation: pulse-scale 2s infinite ease-in-out;
}

.table-success.animate-pulse {
    animation-name: pulse-success;
}

.table-primary.animate-pulse {
    animation-name: pulse-primary;
}

.table-info.animate-pulse {
    animation-name: pulse-info;
}

.table-warning.animate-pulse {
    animation-name: pulse-warning;
}

.table-secondary.animate-pulse {
    animation-name: pulse-secondary;
}

.table-danger.animate-pulse {
    animation-name: pulse-danger;
}

@keyframes pulse-danger {
    0% {
        background-color: rgba(220, 53, 69, 0.1);
    }

    50% {
        background-color: rgba(220, 53, 69, 0.2);
    }

    100% {
        background-color: rgba(220, 53, 69, 0.1);
    }
}

/* Base Mobile Overrides & Utilities */
@media (max-width: 576px) {
    .display-1 {
        font-size: 3.5rem !important;
    }

    .display-2 {
        font-size: 2.5rem !important;
    }

    .display-3 {
        font-size: 2rem !important;
    }

    .display-4 {
        font-size: 1.5rem !important;
    }

    .card-header {
        padding: 0.75rem 1rem !important;
    }

    .card-body {
        padding: 1rem !important;
    }

    .input-group-text {
        padding-left: 0.5rem !important;
        padding-right: 0.5rem !important;
        font-size: 0.85rem;
    }

    .form-control,
    .form-select {
        font-size: 0.85rem !important;
        padding: 0.4rem 0.6rem !important;
    }

    /* Small Badge for Mobile */
    .badge {
        font-size: 0.65rem !important;
        padding: 3px 6px !important;
    }

    .semester-header-badges .badge {
        font-size: 0.6rem !important;
        padding: 2px 5px !important;
    }
}


/* News Bento Grid Styles */
.news-bento-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1.5rem;
}

.news-card {
    animation: fadeInScale 0.5s ease backwards;
}

.news-card:nth-child(1) {
    animation-delay: 0.1s;
}

.news-card:nth-child(2) {
    animation-delay: 0.2s;
}

.news-card:nth-child(3) {
    animation-delay: 0.3s;
}

/* Animation Utility Classes */
.hover-translate-y {
    transition: transform 0.4s cubic-bezier(0.34, 1.56, 0.64, 1), box-shadow 0.3s ease, border-color 0.3s ease;
    will-change: transform, box-shadow;
}

.hover-translate-y:hover {
    transform: translateY(-8px);
    box-shadow: 0 12px 24px rgba(0, 0, 0, 0.1) !important;
}

.ani-fade-in-up {
    animation: fadeInScale 0.6s cubic-bezier(0.2, 1, 0.3, 1) backwards;
    will-change: transform, opacity;
}

.delay-100 {
    animation-delay: 0.1s;
}

.delay-200 {
    animation-delay: 0.2s;
}

.delay-300 {
    animation-delay: 0.3s;
}

.delay-400 {
    animation-delay: 0.4s;
}

.delay-500 {
    animation-delay: 0.5s;
}

.pulse-animation {
    animation: pulse-scale 2s infinite;
}

.custom-scrollbar::-webkit-scrollbar {
    width: 4px;
}

.custom-scrollbar::-webkit-scrollbar-track {
    background: #f1f1f1;
}

.custom-scrollbar::-webkit-scrollbar-thumb {
    background: #ccc;
    border-radius: 10px;
}

.custom-scrollbar::-webkit-scrollbar-thumb:hover {
    background: #999;
}

.letter-spacing-1 {
    letter-spacing: 1px;
}

.transition-all {
    transition: all 0.3s ease;
}

.grade-scenario-card {
    border: 1px solid rgba(0, 0, 0, 0.08);
    background: #fff;
    border-left: 4px solid transparent;
}

.grade-scenario-card.border-A {
    border-left-color: #198754;
}

.grade-scenario-card.border-A- {
    border-left-color: #20c997;
}

.grade-scenario-card.border-B-plus {
    border-left-color: #0dcaf0;
}

.grade-scenario-card.border-B {
    border-left-color: #0d6efd;
}

.grade-scenario-card.border-B- {
    border-left-color: #6610f2;
}

.grade-scenario-card.border-C-plus {
    border-left-color: #6f42c1;
}

.grade-scenario-card.border-C {
    border-left-color: #fd7e14;
}

.grade-scenario-card.border-C- {
    border-left-color: #ffc107;
}

.grade-scenario-card.border-D-plus {
    border-left-color: #adb5bd;
}

.grade-scenario-card.border-D {
    border-left-color: #6c757d;
}

.grade-scenario-card.border-F {
    border-left-color: #dc3545;
}

.news-card:nth-child(4) {
    animation-delay: 0.4s;
}

@keyframes fadeInScale {
    from {
        opacity: 0;
        transform: translateY(20px) scale(0.95);
    }

    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

/* Pulse animations moved to top */

.news-filters .filter-btn {
    transition: all 0.3s ease;
}

.news-filters .filter-btn.active {
    box-shadow: 0 4px 10px rgba(13, 110, 253, 0.3);
}

.bento-item {
    background: #fff;
    border-radius: 1.25rem;
    overflow: hidden;
    position: relative;
    transition: all 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05);
    height: 100%;
    display: flex;
    flex-direction: column;
}

.bento-item:hover {
    transform: translateY(-8px);
    box-shadow: 0 20px 30px rgba(0, 0, 0, 0.1);
}

.bento-item.item-large {
    grid-column: span 2;
}

.bento-img-container {
    width: 100%;
    height: 280px;
    overflow: hidden;
    position: relative;
    background: #f8f9fa;
    display: flex;
    align-items: center;
    justify-content: center;
}

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

/* Special handling for Holiday Card to show full image */
#bento-holiday .bento-img-container {
    height: auto;
    min-height: 200px;
}

#bento-holiday .bento-img-container::after {
    display: none;
    /* Remove dark gradient */
}

#bento-holiday .bento-img-container img {
    object-fit: contain;
    /* Show entire image */
    height: auto;
    max-height: 400px;
}

.bento-item:hover .bento-img-container img {
    transform: scale(1.05);
}

.bento-badge {
    position: absolute;
    top: 1rem;
    left: 1rem;
    z-index: 2;
    -webkit-backdrop-filter: blur(10px);
    backdrop-filter: blur(10px);
    background: rgba(255, 255, 255, 0.8);
    border: 1px solid rgba(0, 0, 0, 0.1) !important;
    padding: 0.4rem 0.7rem !important;
    font-size: 0.75rem;
}

.bento-content {
    padding: 1.25rem 1.5rem;
    position: relative;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}

/* Reset Large Item content to be below the image for clarity */
.bento-item.item-large .bento-content {
    position: relative;
    bottom: auto;
    left: auto;
    right: auto;
    z-index: 2;
    color: #1a1a1a;
    background: #fff;
}

.bento-title {
    font-size: 1.15rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
    color: #1a1a1a;
}

.item-large .bento-title {
    color: #1a1a1a;
    font-size: 1.25rem;
    text-shadow: none;
}

.bento-item:hover .bento-title {
    color: var(--primary-color);
}

.item-large:hover .bento-title {
    color: #fff;
}

.bento-desc {
    color: #666;
    font-size: 0.95rem;
    line-height: 1.6;
}

@media (max-width: 768px) {
    .news-bento-grid {
        grid-template-columns: 1fr;
        gap: 1.25rem;
    }

    .bento-item.item-large {
        grid-column: span 1;
    }

    .bento-img-container {
        height: 220px;
    }

    .item-large .bento-title {
        font-size: 1.3rem;
    }
}

/* Specific item adjustments */
#bento-announcement {
    border-top: 4px solid var(--bs-danger);
}

#bento-handbook {
    border-top: 4px solid var(--bs-info);
}

#bento-calendar {
    border-top: 4px solid var(--bs-success);
}

.btn {
    border-radius: 0.75rem;
}

.form-control,
.form-select,
.input-group-text {
    border-radius: 0.75rem;
}

.input-group .form-control:not(:first-child),
.input-group .form-select:not(:first-child),
.input-group .input-group-text:not(:first-child) {
    border-top-left-radius: 0;
    border-bottom-left-radius: 0;
}

.input-group .form-control:not(:last-child),
.input-group .form-select:not(:last-child),
.input-group .input-group-text:not(:last-child) {
    border-top-right-radius: 0;
    border-bottom-right-radius: 0;
}

/* Custom Scrollbar */
::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}

::-webkit-scrollbar-track {
    background: #f1f1f1;
}

::-webkit-scrollbar-thumb {
    background: #c1c1c1;
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: #a8a8a8;
}

/* Mobile Responsive Header */
@media (max-width: 576px) {
    .navbar .container {
        padding-left: 10px;
        padding-right: 10px;
        flex-wrap: nowrap;
        /* Force no wrap */
    }

    .navbar-brand {
        font-size: 0.95rem !important;
        gap: 5px;
        margin-right: 5px;
    }

    .navbar-brand i {
        font-size: 1.1rem !important;
    }

    .navbar-brand span {
        white-space: nowrap;
    }

    .visit-count-container .badge {
        font-size: 0.65rem;
        padding: 4px 6px !important;
        white-space: nowrap;
    }

    .visit-count-container .small {
        display: none;
        /* Hide text "lượt" to save space */
    }
}


/* Mobile & Tablet Bottom Nav Styles */
@media (max-width: 991.98px) {

    /* Remove default navbar padding to save space */
    .navbar.fixed-bottom {
        padding-top: 0 !important;
        padding-bottom: 0 !important;
        /* We rely on valid safe-area padding if needed via inline style, or just tight fit */
    }

    body {
        padding-bottom: 90px;
        /* Space for bottom nav */
    }

    #mobile-bottom-tab .nav-link {
        border-radius: 0;
        background-color: transparent !important;
        color: #6c757d;
        /* Muted color */
        margin: 0;
        padding: 8px 0 !important;
        /* Reset padding to maximize space */
        border-top: 3px solid transparent;
        width: 100%;
        /* Ensure full width usage */
    }

    #mobile-bottom-tab .nav-link.active {
        color: var(--primary-color) !important;
        font-weight: 600;
        border-top: 3px solid var(--primary-color);
    }

    #mobile-bottom-tab .nav-link i {
        transition: transform 0.2s;
    }

    #mobile-bottom-tab .nav-link.active i {
        transform: translateY(-2px);
    }

    /* Adjust Floating Button on Mobile to avoid overlap with Bottom Nav */
    #contact-floating-wrapper {
        bottom: 65px !important;
    }

    /* Table Mobile Optimizations */
    .table-responsive {
        border: none !important;
        margin: 0 !important;
    }

    .table th {
        font-size: 0.7rem !important;
        padding-top: 0.5rem !important;
        padding-bottom: 0.5rem !important;
    }

    .table td {
        padding-top: 0.5rem !important;
        padding-bottom: 0.5rem !important;
    }
}


/* Segmented Control (Modern Radio Group) */
.btn-check:checked+.btn-segmented {
    background-color: white;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.15);
    font-weight: 700;
    transform: scale(1.02);
    z-index: 1;
    transition: all 0.2s ease;
}

/* Specific Colors for Ratios */
#ratio3070:checked+.btn-segmented {
    color: #dc3545;
    /* Danger Red */
    background-color: #fff5f5;
    border: 1px solid #dc3545;
}

#ratio4060:checked+.btn-segmented {
    color: #0d6efd;
    /* Primary Blue */
    background-color: #f0f7ff;
    border: 1px solid #0d6efd;
}

#ratio5050:checked+.btn-segmented {
    color: #198754;
    /* Success Green */
    background-color: #f0fff4;
    border: 1px solid #198754;
}

.btn-check:not(:checked)+.btn-segmented {
    color: #6c757d;
    border: 1px solid transparent;
    /* Prevent layout shift */
}

.btn-check:not(:checked)+.btn-segmented:hover {
    background-color: rgba(255, 255, 255, 0.5);
}

/* Fainter Placeholders */
.form-control::placeholder {
    color: #adb5bd !important;
    /* Lighter gray */
    opacity: 0.6 !important;
}

/* Floating Contact Button */
.floating-contact-btn {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--primary-color), #ff6b6b);
    border: none;
    box-shadow: 0 4px 15px rgba(211, 47, 47, 0.4);
    transition: transform 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275), box-shadow 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0% {
        box-shadow: 0 4px 15px rgba(211, 47, 47, 0.4);
    }

    50% {
        box-shadow: 0 4px 20px rgba(211, 47, 47, 0.6);
    }

    100% {
        box-shadow: 0 4px 15px rgba(211, 47, 47, 0.4);
    }
}

.floating-contact-btn:hover {
    transform: scale(1.1) rotate(5deg);
    box-shadow: 0 6px 20px rgba(211, 47, 47, 0.6);
}

.floating-contact-btn i {
    font-size: 1.75rem;
    /* Slightly larger icon */
}

/* Floating Feedback Button */
.floating-feedback-btn {
    transition: transform 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275), box-shadow 0.3s ease;
}

.floating-feedback-btn:hover {
    transform: scale(1.1) rotate(-10deg);
    box-shadow: 0 6px 20px rgba(25, 135, 84, 0.4) !important;
}

/* Contact Modal Customization */
.contact-modal-content {
    border: none;
    border-radius: 24px;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.15);
}

.contact-modal-header {
    background: linear-gradient(135deg, #a1c4fd 0%, #c2e9fb 100%);
    height: 130px;
    position: relative;
    border-bottom: none;
    padding: 0;
}

.contact-modal-header .btn-close {
    position: absolute;
    top: 15px;
    right: 15px;
    background-color: rgba(255, 255, 255, 0.9);
    border-radius: 50%;
    padding: 12px;
    opacity: 1;
    transition: all 0.3s ease;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
}

.contact-modal-header .btn-close:hover {
    background-color: white;
    transform: rotate(90deg) scale(1.1);
}

.contact-avatar-container {
    margin-top: -65px;
    /* Pull avatar up to overlap header */
    margin-bottom: 15px;
    position: relative;
    display: inline-block;
}

.contact-avatar {
    width: 130px;
    height: 130px;
    object-fit: cover;
    border-radius: 50%;
    border: 5px solid white;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.15);
    background-color: white;
}

.contact-badge {
    position: absolute;
    bottom: 8px;
    right: 8px;
    background-color: #1da1f2;
    /* Blue checkmark color */
    color: white;
    border-radius: 50%;
    width: 28px;
    height: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 3px solid white;
    font-size: 14px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.contact-name {
    font-weight: 800;
    color: #212529;
    margin-bottom: 4px;
    letter-spacing: -0.5px;
}

.contact-role {
    color: var(--primary-color);
    font-weight: 600;
    font-size: 0.9rem;
    background-color: rgba(211, 47, 47, 0.08);
    padding: 6px 16px;
    border-radius: 20px;
    display: inline-block;
    margin-bottom: 20px;
}

.contact-actions .btn {
    padding: 12px 20px;
    font-weight: 600;
    transition: all 0.2s ease;
    border-width: 2px;
}

.contact-actions .btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.contact-actions .btn-outline-primary:hover {
    background-color: #f8f9fa;
    color: var(--primary-color);
    border-color: var(--primary-color);
}

/* ==========================================
   DARK MODE STYLES
   ========================================== */
[data-bs-theme="dark"] {
    --secondary-color: #2b3035;
}

[data-bs-theme="dark"] body {
    background-color: #212529;
    color: #f8f9fa;
}

[data-bs-theme="dark"] .navbar {
    background-color: #212529 !important;
    box-shadow: 0 2px 4px rgba(255, 255, 255, 0.1);
    border-bottom: 1px solid #373b3e;
}

[data-bs-theme="dark"] .nav-pills .nav-link {
    color: #adb5bd;
}

[data-bs-theme="dark"] .nav-pills .nav-link.active {
    background-color: #0d6efd;
    /* Primary Blue */
    color: #fff;
}

[data-bs-theme="dark"] .nav-pills .nav-link:hover:not(.active) {
    background-color: #343a40;
    color: #fff;
}

[data-bs-theme="dark"] .card {
    background-color: #2b3035;
    border: 1px solid #373b3e;
}

[data-bs-theme="dark"] .text-dark {
    color: #f8f9fa !important;
}

[data-bs-theme="dark"] .bg-light {
    background-color: #343a40 !important;
    color: #f8f9fa !important;
}

/* Form Elements in Dark Mode */
[data-bs-theme="dark"] .form-control,
[data-bs-theme="dark"] .form-select,
[data-bs-theme="dark"] .input-group-text {
    background-color: #212529;
    border-color: #495057;
    color: #f8f9fa;
}

[data-bs-theme="dark"] .form-control:focus,
[data-bs-theme="dark"] .form-select:focus {
    background-color: #212529;
    border-color: #86b7fe;
    color: #f8f9fa;
}

[data-bs-theme="dark"] .form-control::placeholder {
    color: #6c757d !important;
    opacity: 1 !important;
}

/* Segmented Control in Dark Mode */
[data-bs-theme="dark"] .btn-check:checked+.btn-segmented {
    background-color: #343a40;
    color: #fff;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.4);
    font-weight: 700;
    transform: scale(1.02);
}

[data-bs-theme="dark"] #ratio3070:checked+.btn-segmented {
    color: #ea868f;
    border: 1px solid #ea868f;
    background-color: rgba(220, 53, 69, 0.2);
}

[data-bs-theme="dark"] #ratio4060:checked+.btn-segmented {
    color: #6ea8fe;
    border: 1px solid #6ea8fe;
    background-color: rgba(13, 110, 253, 0.2);
}

[data-bs-theme="dark"] #ratio5050:checked+.btn-segmented {
    color: #75b798;
    border: 1px solid #75b798;
    background-color: rgba(25, 135, 84, 0.2);
}

/* Semester Header Badges */
@media (max-width: 576px) {
    .semester-header-badges {
        gap: 0.25rem !important;
    }

    .last-no-border:last-child {
        border-bottom: none !important;
    }
}

/* Ngăn xuống dòng trong bảng Xếp loại học lực */
#classification-table-body td,
#grade-scale-table-body td {
    white-space: nowrap;
}

[data-bs-theme="dark"] .btn-check:not(:checked)+.btn-segmented {
    color: #adb5bd;
    border: 1px solid transparent;
}

[data-bs-theme="dark"] .btn-check:not(:checked)+.btn-segmented:hover {
    background-color: rgba(255, 255, 255, 0.1);
}

/* Modal in Dark Mode */
[data-bs-theme="dark"] .modal-content {
    background-color: #2b3035;
    border-color: #495057;
}

[data-bs-theme="dark"] .modal-header,
[data-bs-theme="dark"] .modal-footer {
    border-color: #495057;
}

[data-bs-theme="dark"] .btn-close {
    filter: invert(1) grayscale(100%) brightness(200%);
}

/* Contact Modal Specifics */
[data-bs-theme="dark"] .contact-modal-header {
    background: linear-gradient(135deg, #1a2a3a 0%, #2c3e50 100%);
}

[data-bs-theme="dark"] .contact-avatar {
    border-color: #2b3035;
    background-color: #2b3035;
}

[data-bs-theme="dark"] .contact-name {
    color: #f8f9fa;
}

[data-bs-theme="dark"] .contact-role {
    background-color: rgba(211, 47, 47, 0.2);
    color: #ff6b6b;
}

/* Mobile Bottom Nav */
[data-bs-theme="dark"] #mobile-bottom-tab {
    background-color: #212529 !important;
    border-top: 1px solid #373b3e !important;
}

[data-bs-theme="dark"] #mobile-bottom-tab .nav-link {
    color: #adb5bd;
}

/* Scrollbar for Dark Mode */
[data-bs-theme="dark"] ::-webkit-scrollbar-track {
    background: #2b3035;
}

[data-bs-theme="dark"] ::-webkit-scrollbar-thumb {
    background: #495057;
}

[data-bs-theme="dark"] ::-webkit-scrollbar-thumb:hover {
    background: #6c757d;
}

/* ==========================================
   ADDITIONAL DARK MODE OVERRIDES
   ========================================== */

/* Override bg-white utility */
[data-bs-theme="dark"] .bg-white {
    background-color: #2b3035 !important;
    color: #f8f9fa !important;
}

/* Override text-muted utility */
[data-bs-theme="dark"] .text-muted {
    color: #adb5bd !important;
}

/* Override btn-light */
[data-bs-theme="dark"] .btn-light {
    background-color: #343a40;
    border-color: #495057;
    color: #e9ecef;
}

[data-bs-theme="dark"] .btn-light:hover {
    background-color: #495057;
    border-color: #6c757d;
}

/* Override border-light-subtle */
[data-bs-theme="dark"] .border-light-subtle {
    border-color: #495057 !important;
}

/* Fix Progress Bar Background */
[data-bs-theme="dark"] .progress {
    background-color: #343a40;
}

/* Subtle Backgrounds & Borders in Dark Mode */
[data-bs-theme="dark"] .bg-primary-subtle {
    background-color: rgba(13, 110, 253, 0.15) !important;
    color: #6ea8fe !important;
}

[data-bs-theme="dark"] .border-primary-subtle {
    border-color: rgba(13, 110, 253, 0.3) !important;
}

[data-bs-theme="dark"] .bg-danger-subtle {
    background-color: rgba(220, 53, 69, 0.15) !important;
    color: #ea868f !important;
}

[data-bs-theme="dark"] .border-danger-subtle {
    border-color: rgba(220, 53, 69, 0.3) !important;
}

[data-bs-theme="dark"] .bg-success-subtle {
    background-color: rgba(25, 135, 84, 0.15) !important;
    color: #75b798 !important;
}

[data-bs-theme="dark"] .border-success-subtle {
    border-color: rgba(25, 135, 84, 0.3) !important;
}

[data-bs-theme="dark"] .bg-warning-subtle {
    background-color: rgba(255, 193, 7, 0.15) !important;
    color: #ffda6a !important;
}

[data-bs-theme="dark"] .border-warning-subtle {
    border-color: rgba(255, 193, 7, 0.3) !important;
}

[data-bs-theme="dark"] .bg-info-subtle {
    background-color: rgba(13, 202, 240, 0.15) !important;
    color: #6edff6 !important;
}

[data-bs-theme="dark"] .border-info-subtle {
    border-color: rgba(13, 202, 240, 0.3) !important;
}

/* Text Colors in Dark Mode */
[data-bs-theme="dark"] .text-primary {
    color: #6ea8fe !important;
    /* Lighter blue for dark mode */
}

[data-bs-theme="dark"] .text-danger {
    color: #ea868f !important;
    /* Lighter red for dark mode */
}

[data-bs-theme="dark"] .text-success {
    color: #75b798 !important;
    /* Lighter green for dark mode */
}

[data-bs-theme="dark"] .text-info {
    color: #6edff6 !important;
    /* Lighter cyan for dark mode */
}

[data-bs-theme="dark"] .text-secondary {
    color: #adb5bd !important;
    /* Lighter gray for dark mode */
}

/* Text Emphasis Colors in Dark Mode */
[data-bs-theme="dark"] .text-primary-emphasis {
    color: #9ec5fe !important;
}

[data-bs-theme="dark"] .text-success-emphasis {
    color: #a3cfbb !important;
}

[data-bs-theme="dark"] .text-danger-emphasis {
    color: #f1aeb5 !important;
}

[data-bs-theme="dark"] .text-warning-emphasis {
    color: #ffe69c !important;
}

[data-bs-theme="dark"] .text-info-emphasis {
    color: #9eeaf9 !important;
}

/* Input Group Fixes */
[data-bs-theme="dark"] .input-group-text {
    border-color: #495057;
}

/* Fix Range Input Visibility in Dark Mode */
[data-bs-theme="dark"] .form-range::-webkit-slider-runnable-track {
    background-color: #495057;
}

[data-bs-theme="dark"] .form-range::-moz-range-track {
    background-color: #495057;
}

[data-bs-theme="dark"] .form-range::-webkit-slider-thumb {
    background-color: #6ea8fe;
    /* Lighter Blue */
    box-shadow: 0 0 0 2px #2b3035;
    /* Ring to separate from track */
}

[data-bs-theme="dark"] .form-range::-moz-range-thumb {
    background-color: #6ea8fe;
    border: none;
}

[data-bs-theme="dark"] .form-range:focus::-webkit-slider-thumb {
    box-shadow: 0 0 0 3px rgba(110, 168, 254, 0.5);
}

/* User Guide Modal Navigation */
.guide-nav-pills {
    background-color: #f8f9fa;
    padding: 0.5rem;
    border-radius: 1rem;
    gap: 0.5rem;
}

.guide-nav-pills .nav-link {
    border-radius: 0.75rem;
    color: #6c757d;
    font-weight: 500;
    padding: 0.6rem 0.8rem;
    transition: all 0.2s ease;
    text-align: center;
    white-space: nowrap;
    font-size: 0.95rem;
}

.guide-nav-pills .nav-link:hover {
    background-color: #e9ecef;
    color: #495057;
}

.guide-nav-pills .nav-link.active {
    background-color: white;
    color: var(--primary-color);
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
    font-weight: 600;
}

/* Dark mode support for guide pills */
[data-bs-theme="dark"] .guide-nav-pills {
    background-color: #2b3035;
}

[data-bs-theme="dark"] .guide-nav-pills .nav-link {
    color: #adb5bd;
}

[data-bs-theme="dark"] .guide-nav-pills .nav-link:hover {
    background-color: #343a40;
    color: #e9ecef;
}

[data-bs-theme="dark"] .guide-nav-pills .nav-link.active {
    background-color: #495057;
    color: #fff;
}

/* Responsive guide tabs (Scrollable on smaller screens) */
@media (max-width: 992px) {
    .guide-nav-pills {
        flex-wrap: nowrap;
        overflow-x: auto;
        justify-content: flex-start !important;
        padding-bottom: 0.5rem;
        -webkit-overflow-scrolling: touch;
        /* Smooth scrolling on iOS */
        scrollbar-width: none;
        /* Firefox */
    }

    .guide-nav-pills::-webkit-scrollbar {
        display: none;
        /* Chrome/Safari/Webkit */
    }

    .guide-nav-pills .nav-item {
        flex: 0 0 auto;
    }

    .guide-nav-pills .nav-link {
        font-size: 0.9rem;
        padding: 0.5rem 0.75rem;
    }
}

/* Mobile Phone Optimization (< 576px) */
@media (max-width: 576px) {
    .guide-nav-pills {
        margin: 0 -1rem 1rem -1rem;
        /* Extend to edges of modal */
        padding: 0.75rem 1rem;
        /* Add padding inside the strip */
        border-radius: 0;
        /* Remove corners for full-width look */
        gap: 0.5rem;
    }

    .guide-nav-pills .nav-link {
        font-size: 0.8rem;
        padding: 0.5rem 0.8rem;
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        min-width: 85px;
        /* Ensure touch target size */
        height: 100%;
    }

    /* Ensure icons are prominent */
    .guide-nav-pills .nav-link i {
        font-size: 1.2rem;
        margin-bottom: 0.25rem !important;
    }

    /* Limit modal body height on mobile to prevent overflow */
    #userGuideModal .modal-body {
        max-height: 55vh;
        overflow-y: auto;
    }
}

/* Dark Mode Overrides */
[data-bs-theme="dark"] body {
    background-color: #212529;
    color: #f8f9fa;
}

[data-bs-theme="dark"] .navbar {
    background-color: #343a40 !important;
    border-bottom: 1px solid #495057;
}

[data-bs-theme="dark"] .navbar-brand span {
    color: #f8f9fa;
}

[data-bs-theme="dark"] .card {
    background-color: #2b3035;
    border-color: #495057;
}

[data-bs-theme="dark"] .card-header {
    background-color: #2b3035 !important;
    border-bottom-color: #495057 !important;
}

[data-bs-theme="dark"] .card-title {
    color: #6ea8fe !important;
    /* Light primary */
}

[data-bs-theme="dark"] .bg-white {
    background-color: #2b3035 !important;
}

[data-bs-theme="dark"] .bg-light {
    background-color: #343a40 !important;
}

[data-bs-theme="dark"] .text-dark {
    color: #f8f9fa !important;
}

[data-bs-theme="dark"] .text-muted {
    color: #adb5bd !important;
}

[data-bs-theme="dark"] .table {
    color: #f8f9fa;
    border-color: #495057;
}

[data-bs-theme="dark"] .table-hover tbody tr:hover {
    color: #f8f9fa;
    background-color: #343a40;
}

[data-bs-theme="dark"] .nav-pills .nav-link {
    color: #e9ecef;
}

[data-bs-theme="dark"] .nav-pills .nav-link:hover:not(.active) {
    background-color: #343a40;
}

[data-bs-theme="dark"] .modal-content {
    background-color: #2b3035;
    border-color: #495057;
}

[data-bs-theme="dark"] .modal-header,
[data-bs-theme="dark"] .modal-footer {
    border-color: #495057;
}

[data-bs-theme="dark"] .btn-close {
    filter: invert(1) grayscale(100%) brightness(200%);
}

[data-bs-theme="dark"] .form-control,
[data-bs-theme="dark"] .form-select,
[data-bs-theme="dark"] .input-group-text {
    background-color: #343a40;
    border-color: #495057;
    color: #f8f9fa;
}

[data-bs-theme="dark"] .form-control:focus,
[data-bs-theme="dark"] .form-select:focus {
    background-color: #343a40;
    color: #f8f9fa;
    border-color: #86b7fe;
}

/* Specific overrides for the GPA Classification cards */
[data-bs-theme="dark"] .bg-success-subtle {
    background-color: rgba(25, 135, 84, 0.2) !important;
    border-color: rgba(25, 135, 84, 0.3) !important;
}

[data-bs-theme="dark"] .bg-primary-subtle {
    background-color: rgba(13, 110, 253, 0.2) !important;
    border-color: rgba(13, 110, 253, 0.3) !important;
}

[data-bs-theme="dark"] .bg-info-subtle {
    background-color: rgba(13, 202, 240, 0.2) !important;
    border-color: rgba(13, 202, 240, 0.3) !important;
}

[data-bs-theme="dark"] .bg-warning-subtle {
    background-color: rgba(255, 193, 7, 0.2) !important;
    border-color: rgba(255, 193, 7, 0.3) !important;
}

[data-bs-theme="dark"] .bg-secondary-subtle {
    background-color: rgba(108, 117, 125, 0.2) !important;
    border-color: rgba(108, 117, 125, 0.3) !important;
}

[data-bs-theme="dark"] .bg-danger-subtle {
    background-color: rgba(220, 53, 69, 0.2) !important;
    border-color: rgba(220, 53, 69, 0.3) !important;
}

[data-bs-theme="dark"] .text-success-emphasis {
    color: #75b798 !important;
}

[data-bs-theme="dark"] .text-primary-emphasis {
    color: #6ea8fe !important;
}

[data-bs-theme="dark"] .text-info-emphasis {
    color: #3dd5f3 !important;
}

[data-bs-theme="dark"] .text-warning-emphasis {
    color: #ffda6a !important;
}

[data-bs-theme="dark"] .text-secondary-emphasis {
    color: #a7acb1 !important;
}

[data-bs-theme="dark"] .text-danger-emphasis {
    color: #ea868f !important;
}

/* Pulse Animation for CTA Button */
@keyframes pulse-btn {
    0% {
        transform: scale(1);
        box-shadow: 0 0 0 0 rgba(255, 255, 255, 0.7);
    }

    70% {
        transform: scale(1.05);
        box-shadow: 0 0 0 10px rgba(255, 255, 255, 0);
    }

    100% {
        transform: scale(1);
        box-shadow: 0 0 0 0 rgba(255, 255, 255, 0);
    }
}

.btn-pulse {
    animation: pulse-btn 2s infinite;
}






/* News Filter Styles - Modern Glass Pill Design */
.glass-pill-container {
    background: rgba(255, 255, 255, 0.4);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    border: 1px solid rgba(0, 0, 0, 0.05);
    border-radius: 50rem;
    width: fit-content;
    max-width: 100%;
}

[data-bs-theme="dark"] .glass-pill-container {
    background: rgba(255, 255, 255, 0.05);
    border-color: rgba(255, 255, 255, 0.1);
}

.news-filters {
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    -ms-overflow-style: none;
}

.news-filters::-webkit-scrollbar {
    display: none;
}

.news-filters .filter-btn {
    white-space: nowrap;
    flex-shrink: 0;
    border-radius: 50rem;
    padding: 0.4rem 1.2rem;
    border: none;
    color: #6c757d;
    font-weight: 500;
    font-size: 0.85rem;
    transition: all 0.3s ease;
    background: transparent;
}

.news-filters .filter-btn:hover {
    color: var(--primary-color);
}

.news-filters .filter-btn.active {
    background: #ffffff !important;
    color: var(--primary-color) !important;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.08);
}

[data-bs-theme="dark"] .news-filters .filter-btn {
    color: #ffffff;
}

[data-bs-theme="dark"] .news-filters .filter-btn.active {
    background: rgba(255, 255, 255, 0.2) !important;
    color: #ffffff !important;
}

/* News Tab Styles */
.news-card {
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.news-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1) !important;
}

.clickable-image {
    transition: transform 0.3s ease;
}

.clickable-image:hover {
    transform: scale(1.02);
}

.news-date {
    font-size: 0.85rem;
    color: #6c757d;
}

/* Modal Image Viewer */
#imageViewerModal .modal-close-btn {
    z-index: 1056;
    /* Higher than modal backdrop */
}

#imageViewerModal img {
    max-width: 100%;
    object-fit: contain;
}


/* News Sorting */
.news-sort-mode .news-sort-controls {
    display: flex !important;
}

.news-sort-mode .news-card {
    border: 1px dashed #0d6efd !important;
    background-color: #f8f9fa;
}

.news-sort-mode #toggle-sort-news-btn {
    background-color: #0d6efd;
    color: white;
}

/* Scale Sorting */
.scale-sort-mode .scale-sort-controls {
    display: flex !important;
}

.scale-sort-mode .scale-card {
    border: 1px dashed #0d6efd !important;
    background-color: #f8f9fa;
}

.scale-sort-mode #toggle-sort-scale-btn {
    background-color: #0d6efd;
    color: white;
}


/* Extra Small Screen Optimization for Bottom Nav */
@media (max-width: 370px) {
    #mobile-bottom-tab .nav-link span {
        font-size: 0.6rem !important;
        letter-spacing: -0.5px;
        /* Condense text slightly */
    }

    #mobile-bottom-tab .nav-link i {
        font-size: 1.2rem !important;
        margin-bottom: 2px !important;
    }

    #mobile-bottom-tab .nav-link {
        padding-top: 6px !important;
        padding-bottom: 6px !important;
    }
}


/* Ultra Wide Screen Optimization (1600px - 2500px) */
@media (min-width: 1600px) and (max-width: 2499px) {
    .container {
        max-width: 1600px;
    }
}

/* Super High Resolution Optimization (2500px+) - e.g. 2800px width */
@media (min-width: 2500px) {
    .container {
        max-width: 2400px;
    }

    body {
        font-size: 1.15rem;
        /* Slight scale up for better readability */
    }

    /* Scale Headings */
    h5,
    .h5 {
        font-size: 1.5rem;
    }

    h6,
    .h6 {
        font-size: 1.2rem;
    }

    /* Scale Inputs & Buttons */
    .form-control,
    .form-select,
    .btn {
        font-size: 1.15rem;
        padding: 0.6rem 1rem;
    }

    .input-group-text {
        font-size: 1.15rem;
    }

    .small,
    small,
    .text-muted.small {
        font-size: 0.95rem !important;
    }

    .display-1 {
        font-size: 6rem;
        /* Bigger GPA number */
    }

    /* Navbar Scaling */
    .navbar-brand {
        font-size: 1.6rem;
    }

    .navbar-brand i {
        font-size: 2rem;
    }

    .nav-pills .nav-link {
        font-size: 1.1rem;
        padding: 10px 20px;
    }

    /* Adjust Sticky Top for taller navbar */
    .sticky-lg-top {
        top: 100px !important;
    }

    /* Card spacing */
    .card-body {
        padding: 2rem !important;
    }
}

/* Standard Desktop Optimization (1200px - 1440px) */
@media (min-width: 1200px) and (max-width: 1439px) {
    .container {
        max-width: 1140px;
    }

    .card-body.p-4 {
        padding: 1.5rem !important;
    }
}

/* Large Desktop Optimization (1440px - 1600px) */
@media (min-width: 1440px) and (max-width: 1599px) {
    .container {
        max-width: 1380px;
    }
}

/* Enhanced Mobile Adjustments */
@media (max-width: 576px) {
    .btn-segmented {
        font-size: 0.8rem;
        padding: 8px 4px;
    }

    .form-text {
        font-size: 0.7rem;
    }

    .display-1 {
        font-size: 3.5rem;
    }
}

/* Roadmap Result & Combinations */
.transition-all:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
}

.custom-scrollbar::-webkit-scrollbar {
    width: 4px;
}

.custom-scrollbar::-webkit-scrollbar-track {
    background: transparent;
}

.custom-scrollbar::-webkit-scrollbar-thumb {
    background: #dee2e6;
    border-radius: 10px;
}

.custom-scrollbar::-webkit-scrollbar-thumb:hover {
    background: #ced4da;
}

@media (max-width: 576px) {
    .font-size-xs {
        font-size: 0.75rem !important;
    }

    /* Semester Header Badges Optimization */
    .semester-header-badges {
        gap: 0.25rem !important;
    }

    .last-no-border:last-child {
        border-bottom: none !important;
    }

    /* Fix action buttons in headers */
    .card-header .d-flex.gap-2 {
        gap: 0.5rem !important;
    }

    .card-header .btn-sm {
        white-space: nowrap !important;
        font-size: 0.7rem !important;
        padding: 0.25rem 0.5rem !important;
    }
}

/*
 * ==========================================
 * MODERN GLASSMORPHISM UI UPGRADES
 * ==========================================
 */

:root {
    /* Gradient Background for Cards */
    --glass-card-bg: linear-gradient(135deg, rgba(255, 255, 255, 0.95), rgba(230, 242, 255, 0.7));
    --glass-card-border: 1px solid rgba(255, 255, 255, 0.8);
    --glass-card-shadow: 0 8px 32px 0 rgba(31, 38, 135, 0.07);
    --glass-blur: blur(10px);
}

[data-bs-theme="dark"] {
    --glass-card-bg: linear-gradient(135deg, rgba(30, 30, 45, 0.8), rgba(20, 20, 30, 0.6));
    --glass-card-border: 1px solid rgba(255, 255, 255, 0.1);
    --glass-card-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.4);
}

/* 1. Body Background Enhancement */
body {
    background: radial-gradient(circle at 10% 20%, rgb(242, 246, 255) 0%, rgb(235, 250, 255) 90%);
    min-height: 100vh;
}

[data-bs-theme="dark"] body {
    background: radial-gradient(circle at 50% 50%, #1a1a2e 0%, #16213e 100%) !important;
}

/* 2. Glass Cards */
.card {
    background: var(--glass-card-bg) !important;
    backdrop-filter: var(--glass-blur);
    -webkit-backdrop-filter: var(--glass-blur);
    border: var(--glass-card-border) !important;
    box-shadow: var(--glass-card-shadow) !important;
}

.card-header {
    background-color: transparent !important;
    border-bottom: 1px solid rgba(0, 0, 0, 0.05) !important;
}

/* 3. Glass Inputs */
.form-control,
.form-select,
.input-group-text,
.input-group-text.bg-light {
    background: rgba(255, 255, 255, 0.85) !important;
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border: 1px solid rgba(0, 0, 0, 0.1) !important;
    box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.01), 0 2px 5px rgba(0, 0, 0, 0.03);
    color: #333;
    font-weight: 500;
}

/* Focus State for Inputs */
.form-control:focus,
.form-select:focus {
    background: #ffffff !important;
    border-color: #8bb9fe !important;
    box-shadow: 0 0 0 0.25rem rgba(13, 110, 253, 0.15), 0 4px 10px rgba(13, 110, 253, 0.1) !important;
}

/* Adjust Input Group Text */
.input-group-text {
    background: rgba(240, 248, 255, 0.9) !important;
    border-right: 1px solid rgba(0, 0, 0, 0.1) !important;
    color: var(--primary-color) !important;
    font-weight: 600;
}

[data-bs-theme="dark"] .form-control,
[data-bs-theme="dark"] .form-select,
[data-bs-theme="dark"] .input-group-text {
    background: rgba(255, 255, 255, 0.05) !important;
    border-color: rgba(255, 255, 255, 0.1) !important;
    color: #e1e1e1 !important;
}

[data-bs-theme="dark"] .form-control:focus,
[data-bs-theme="dark"] .form-select:focus {
    background: rgba(255, 255, 255, 0.1) !important;
    color: #ffffff !important;
    border-color: var(--primary-color) !important;
}

/* Navbar Glass Effect */
.navbar.fixed-top,
.navbar.fixed-bottom {
    background: rgba(255, 255, 255, 0.85) !important;
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.8);
}

[data-bs-theme="dark"] .navbar.fixed-top,
[data-bs-theme="dark"] .navbar.fixed-bottom {
    background: rgba(15, 15, 25, 0.85) !important;
    border-color: rgba(255, 255, 255, 0.05);
}

/* Interactive Grade Scale Cards */
.grade-scale-card {
    transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
    border: 1px solid rgba(0, 0, 0, 0.05);
    background: rgba(255, 255, 255, 0.4);
}

.grade-scale-card:hover {
    transform: translateX(5px);
    background: rgba(255, 255, 255, 0.7);
}

/* Base Active State */
.grade-scale-card.active-scale {
    background: white !important;
    border-width: 2px;
    transform: scale(1.02);
    z-index: 10;
}

/* Color-specific Glows */
.grade-scale-card.active-scale.glow-success {
    border-color: var(--bs-success);
    box-shadow: 0 0 20px rgba(25, 135, 84, 0.3), inset 0 0 10px rgba(25, 135, 84, 0.1);
}

.grade-scale-card.active-scale.glow-primary {
    border-color: var(--bs-primary);
    box-shadow: 0 0 20px rgba(13, 110, 253, 0.3), inset 0 0 10px rgba(13, 110, 253, 0.1);
}

.grade-scale-card.active-scale.glow-info {
    border-color: var(--bs-info);
    box-shadow: 0 0 20px rgba(13, 202, 240, 0.3), inset 0 0 10px rgba(13, 202, 240, 0.1);
}

.grade-scale-card.active-scale.glow-warning {
    border-color: var(--bs-warning);
    box-shadow: 0 0 20px rgba(255, 193, 7, 0.3), inset 0 0 10px rgba(255, 193, 7, 0.1);
}

.grade-scale-card.active-scale.glow-danger {
    border-color: var(--bs-danger);
    box-shadow: 0 0 20px rgba(220, 53, 69, 0.3), inset 0 0 10px rgba(220, 53, 69, 0.1);
}

.grade-scale-card.active-scale.glow-secondary {
    border-color: var(--bs-secondary);
    box-shadow: 0 0 20px rgba(108, 117, 125, 0.3), inset 0 0 10px rgba(108, 117, 125, 0.1);
}

/* 4. Glass Navigation Menu (Desktop) */
.nav-pills .nav-link {
    color: #6c757d;
    background: transparent;
    border: 1px solid transparent;
    transition: all 0.3s ease;
    border-radius: 50rem;
    /* Pill shape */
    font-weight: 500;
    padding: 0.5rem 1rem;
}

.nav-pills .nav-link:hover {
    color: var(--primary-color);
    background: rgba(255, 255, 255, 0.4);
    backdrop-filter: blur(5px);
    -webkit-backdrop-filter: blur(5px);
}

.nav-pills .nav-link.active {
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.9), rgba(230, 242, 255, 0.8)) !important;
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    border: 1px solid rgba(255, 255, 255, 0.9) !important;
    color: var(--primary-color) !important;
    box-shadow: 0 4px 12px rgba(13, 110, 253, 0.15);
    font-weight: 600;
}

/* Theme Toggle Glass Style */
#theme-toggle-desktop {
    background: rgba(255, 255, 255, 0.4);
    border: 1px solid rgba(255, 255, 255, 0.6);
    backdrop-filter: blur(5px);
    -webkit-backdrop-filter: blur(5px);
    color: #6c757d;
    transition: all 0.3s ease;
}

#theme-toggle-desktop:hover {
    background: rgba(255, 255, 255, 0.8);
    color: var(--primary-color);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
}

/* Dark Mode Navigation Overrides */
[data-bs-theme="dark"] .nav-pills .nav-link {
    color: #a0a0a0;
}

[data-bs-theme="dark"] .nav-pills .nav-link:hover {
    background: rgba(255, 255, 255, 0.1);
    color: #ffffff;
}

[data-bs-theme="dark"] .nav-pills .nav-link.active {
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.15), rgba(255, 255, 255, 0.05)) !important;
    border-color: rgba(255, 255, 255, 0.2) !important;
    color: #ffffff !important;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
}

[data-bs-theme="dark"] #theme-toggle-desktop {
    background: rgba(255, 255, 255, 0.1);
    border-color: rgba(255, 255, 255, 0.1);
    color: #a0a0a0;
}

[data-bs-theme="dark"] #theme-toggle-desktop:hover {
    background: rgba(255, 255, 255, 0.2);
    color: #ffffff;
}