/* ============================================
   Wolfofbey Platform - Custom Styles
   Premium dark + gold theme
   ============================================ */

/* ---- CSS Variables / Design Tokens ---- */
:root {
    --wb-primary: #cb202b;
    --wb-primary-light: #f03e4a;
    --wb-primary-dark: #a11a22;
    --wb-gold: var(--wb-primary);
    --wb-gold-light: var(--wb-primary-light);
    --wb-gold-dark: var(--wb-primary-dark);
    --wb-dark: #0D0D0D;
    --wb-dark-2: #1A1A1A;
    --wb-dark-3: #252525;
    --wb-dark-4: #2F2F2F;
    --wb-gray: #8A8A8A;
    --wb-gray-light: #B3B3B3;
    --wb-white: #F5F5F5;
    --wb-success: #2ECC71;
    --wb-danger: #E74C3C;
    --wb-info: #3498DB;
    --wb-radius: 12px;
    --wb-radius-sm: 8px;
    --wb-radius-lg: 20px;
    --wb-shadow: 0 4px 24px rgba(0,0,0,0.3);
    --wb-shadow-hover: 0 8px 40px rgba(203, 32, 43, 0.2);
    --wb-transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    --font-primary: 'Inter', sans-serif;
    --font-display: 'Outfit', sans-serif;
}

/* ---- Reset / Base ---- */
* { box-sizing: border-box; }

body {
    font-family: var(--font-primary);
    background-color: var(--wb-dark);
    color: var(--wb-white);
    line-height: 1.7;
    overflow-x: hidden;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

main { flex: 1; }

h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-display);
    font-weight: 700;
}

a {
    color: var(--wb-gold);
    text-decoration: none;
    transition: var(--wb-transition);
}
a:hover { color: var(--wb-gold-light); }

img { max-width: 100%; height: auto; }

::selection {
    background: var(--wb-gold);
    color: var(--wb-dark);
}

/* ---- Scrollbar ---- */
::-webkit-scrollbar { width: 8px; }
::-webkit-scrollbar-track { background: var(--wb-dark-2); }
::-webkit-scrollbar-thumb { background: var(--wb-dark-4); border-radius: 4px; }
::-webkit-scrollbar-thumb:hover { background: var(--wb-gold-dark); }

/* ============================================
   NAVBAR
   ============================================ */
#mainNavbar {
    background: rgba(13, 13, 13, 0.85);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid rgba(203, 32, 43, 0.1);
    padding: 0.8rem 0;
    transition: var(--wb-transition);
}

#mainNavbar.scrolled {
    background: rgba(13, 13, 13, 0.97);
    padding: 0.5rem 0;
    box-shadow: 0 2px 20px rgba(0,0,0,0.5);
}

.navbar-brand {
    font-family: var(--font-display);
    font-size: 1.5rem;
    letter-spacing: 2px;
    padding: 0;
    margin: 0;
}

@media (max-width: 767.98px) {
    #mainNavbar .container {
        display: flex !important;
        flex-direction: row !important;
        flex-wrap: wrap !important;
        align-items: center !important;
        justify-content: space-between !important;
    }
    .navbar-brand {
        flex: 1;
        max-width: 70%;
    }
    .navbar-toggler {
        order: 2;
    }
    .site-logo {
        height: 40px !important;
    }
}

.brand-wolf { color: var(--wb-white); font-weight: 800; }
.brand-of { color: var(--wb-gray); font-weight: 400; font-size: 0.85em; margin: 0 2px; }
.brand-bey { color: var(--wb-gold); font-weight: 800; }

.nav-link {
    color: var(--wb-gray-light) !important;
    font-weight: 500;
    font-size: 0.95rem;
    padding: 0.5rem 1rem !important;
    position: relative;
    transition: var(--wb-transition);
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 0;
    height: 2px;
    background: var(--wb-gold);
    transition: var(--wb-transition);
}

.nav-link:hover, .nav-link.active {
    color: var(--wb-white) !important;
}

.nav-link:hover::after, .nav-link.active::after {
    width: 60%;
}

/* ---- Buttons ---- */
.btn-gold {
    background: linear-gradient(135deg, var(--wb-primary), var(--wb-primary-dark));
    color: var(--wb-white) !important;
    border: none;
    font-weight: 600;
    border-radius: var(--wb-radius-sm);
    transition: var(--wb-transition);
}

.btn-gold:hover {
    background: linear-gradient(135deg, var(--wb-primary-light), var(--wb-primary));
    color: var(--wb-white) !important;
    transform: translateY(-2px);
    box-shadow: 0 4px 20px rgba(203, 32, 43, 0.4);
}

.btn-outline-gold {
    border: 1.5px solid var(--wb-primary);
    color: var(--wb-primary) !important;
    background: transparent;
    font-weight: 600;
    border-radius: var(--wb-radius-sm);
    transition: var(--wb-transition);
}

.btn-outline-gold:hover {
    background: var(--wb-primary);
    color: var(--wb-white) !important;
    transform: translateY(-2px);
}

.btn-dark-custom {
    background: var(--wb-dark-3);
    color: var(--wb-white);
    border: 1px solid var(--wb-dark-4);
    border-radius: var(--wb-radius-sm);
    transition: var(--wb-transition);
}

.btn-dark-custom:hover {
    background: var(--wb-dark-4);
    color: var(--wb-gold);
    border-color: var(--wb-gold);
}

/* ============================================
   HERO SECTION
   ============================================ */
.hero-section {
    min-height: 100vh;
    display: flex;
    align-items: center;
    position: relative;
    overflow: hidden;
    background: linear-gradient(135deg, var(--wb-dark) 0%, var(--wb-dark-2) 50%, rgba(203,32,43,0.05) 100%);
}

.hero-section::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -20%;
    width: 800px;
    height: 800px;
    background: radial-gradient(circle, rgba(203,32,43,0.08) 0%, transparent 70%);
    border-radius: 50%;
    animation: heroGlow 8s ease-in-out infinite alternate;
}

@keyframes heroGlow {
    0% { transform: translate(0, 0) scale(1); opacity: 0.5; }
    100% { transform: translate(-50px, 50px) scale(1.2); opacity: 1; }
}

.hero-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: rgba(203,32,43,0.1);
    border: 1px solid rgba(203,32,43,0.3);
    border-radius: 50px;
    padding: 8px 20px;
    font-size: 0.85rem;
    color: var(--wb-gold);
    font-weight: 500;
    margin-bottom: 1.5rem;
    animation: fadeInUp 0.6s ease;
}

.hero-title {
    font-family: var(--font-display);
    font-size: clamp(2.5rem, 5vw, 4.5rem);
    font-weight: 800;
    line-height: 1.1;
    margin-bottom: 1.5rem;
    animation: fadeInUp 0.8s ease;
}

.hero-title .highlight {
    background: linear-gradient(135deg, var(--wb-gold), var(--wb-gold-light));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero-subtitle {
    font-size: 1.15rem;
    color: var(--wb-gray-light);
    max-width: 550px;
    line-height: 1.8;
    margin-bottom: 2rem;
    animation: fadeInUp 1s ease;
}

.hero-stats {
    display: flex;
    gap: 2.5rem;
    margin-top: 3rem;
    animation: fadeInUp 1.2s ease;
}

.hero-stat-number {
    font-family: var(--font-display);
    font-size: 2rem;
    font-weight: 800;
    color: var(--wb-gold);
}

.hero-stat-label {
    font-size: 0.85rem;
    color: var(--wb-gray);
    text-transform: uppercase;
    letter-spacing: 1px;
}

@keyframes fadeInUp {
    from { opacity: 0; transform: translateY(30px); }
    to { opacity: 1; transform: translateY(0); }
}

/* ============================================
   SECTION STYLING
   ============================================ */
.section-padding { padding: 6rem 0; }

.section-header {
    text-align: center;
    margin-bottom: 3.5rem;
}

.section-label {
    display: inline-block;
    font-size: 0.8rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 3px;
    color: var(--wb-gold);
    margin-bottom: 0.75rem;
}

.section-title {
    font-size: clamp(1.8rem, 3vw, 2.8rem);
    font-weight: 800;
    margin-bottom: 1rem;
}

.section-subtitle {
    color: var(--wb-gray-light);
    max-width: 600px;
    margin: 0 auto;
    font-size: 1.05rem;
}

.bg-dark-2 { background-color: var(--wb-dark-2); }
.bg-dark-3 { background-color: var(--wb-dark-3); }

/* ============================================
   COURSE CARDS
   ============================================ */
.course-card {
    background: var(--wb-dark-2);
    border: 1px solid var(--wb-dark-4);
    border-radius: var(--wb-radius);
    overflow: hidden;
    transition: var(--wb-transition);
    height: 100%;
    display: flex;
    flex-direction: column;
    position: relative;
}

.course-card:hover {
    transform: translateY(-8px);
    border-color: rgba(203,32,43,0.3);
    box-shadow: var(--wb-shadow-hover);
}

/* Per-course themed hover — uses --card-accent set inline per card */
.themed-card:hover {
    transform: translateY(-8px);
    border-color: var(--card-accent) !important;
    box-shadow: 0 8px 40px color-mix(in srgb, var(--card-accent) 30%, transparent);
}

.themed-card .course-card-title a:hover {
    color: var(--card-accent) !important;
}

.course-card-img {
    position: relative;
    overflow: hidden;
    aspect-ratio: 16/9;
}

.course-card-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: var(--wb-transition);
}

.course-card:hover .course-card-img img {
    transform: scale(1.05);
}

.course-card-badge {
    position: absolute;
    top: 12px;
    left: 12px;
    background: var(--wb-gold);
    color: var(--wb-dark);
    font-size: 0.75rem;
    font-weight: 700;
    padding: 4px 12px;
    border-radius: 50px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.course-card-body {
    padding: 1.25rem;
    flex: 1;
    display: flex;
    flex-direction: column;
}

.course-card-category {
    font-size: 0.8rem;
    color: var(--wb-gold);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 0.5rem;
}

.course-card-title {
    font-size: 1.1rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
    color: var(--wb-white);
    display: -webkit-box;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.course-card-title a { color: inherit; }
.course-card-title a:hover { color: var(--wb-gold); }

.course-card-meta {
    display: flex;
    align-items: center;
    gap: 1rem;
    font-size: 0.85rem;
    color: var(--wb-gray);
    margin-bottom: 1rem;
}

.course-card-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: 1rem;
    border-top: 1px solid var(--wb-dark-4);
    margin-top: auto;
}

.course-price {
    font-family: var(--font-display);
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--wb-gold);
}

.course-price.free {
    color: var(--wb-success);
}

.course-rating {
    display: flex;
    align-items: center;
    gap: 4px;
    color: var(--wb-gold);
    font-size: 0.85rem;
}

/* ============================================
   CATEGORY CARDS
   ============================================ */
.category-card {
    background: var(--wb-dark-2);
    border: 1px solid var(--wb-dark-4);
    border-radius: var(--wb-radius);
    padding: 2rem 1.5rem;
    text-align: center;
    transition: var(--wb-transition);
    cursor: pointer;
}

.category-card:hover {
    border-color: var(--wb-gold);
    transform: translateY(-4px);
    box-shadow: var(--wb-shadow-hover);
}

.category-card i {
    font-size: 2.5rem;
    color: var(--wb-gold);
    margin-bottom: 1rem;
    display: block;
}

.category-card h5 {
    font-size: 1rem;
    font-weight: 600;
    color: var(--wb-white);
    margin-bottom: 0.25rem;
}

.category-card p {
    font-size: 0.85rem;
    color: var(--wb-gray);
    margin: 0;
}

/* ============================================
   TESTIMONIAL
   ============================================ */
.testimonial-card {
    background: var(--wb-dark-3);
    border: 1px solid var(--wb-dark-4);
    border-radius: var(--wb-radius);
    padding: 2rem;
    position: relative;
    transition: var(--wb-transition);
}

.testimonial-card:hover {
    border-color: rgba(203,32,43,0.3);
}

.testimonial-quote {
    font-size: 2rem;
    color: var(--wb-gold);
    opacity: 0.3;
    position: absolute;
    top: 1rem;
    right: 1.5rem;
}

.testimonial-text {
    font-size: 1rem;
    color: var(--wb-gray-light);
    line-height: 1.8;
    font-style: italic;
    margin-bottom: 1.5rem;
}

.testimonial-author {
    display: flex;
    align-items: center;
    gap: 12px;
}

.testimonial-avatar {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--wb-primary), var(--wb-primary-dark));
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--wb-white);
    font-weight: 700;
    font-size: 1.1rem;
}

.testimonial-name { font-weight: 600; font-size: 0.95rem; }
.testimonial-role { font-size: 0.8rem; color: var(--wb-gray); }

/* ============================================
   FORMS
   ============================================ */
.form-control, .form-select {
    background-color: var(--wb-dark-3);
    border: 1px solid var(--wb-dark-4);
    color: var(--wb-white);
    border-radius: var(--wb-radius-sm);
    padding: 0.75rem 1rem;
    transition: var(--wb-transition);
}

.form-control:focus, .form-select:focus {
    background-color: var(--wb-dark-2);
    border-color: var(--wb-gold);
    color: var(--wb-white);
    box-shadow: 0 0 0 3px rgba(203,32,43,0.15);
}

.form-control::placeholder { color: var(--wb-gray); }

.form-label {
    font-weight: 500;
    font-size: 0.9rem;
    color: var(--wb-gray-light);
    margin-bottom: 0.4rem;
}

.auth-card {
    background: var(--wb-dark-2);
    border: 1px solid var(--wb-dark-4);
    border-radius: var(--wb-radius-lg);
    padding: 2.5rem;
    max-width: 480px;
    margin: 0 auto;
    box-shadow: var(--wb-shadow);
}

.auth-card .auth-title {
    font-size: 1.8rem;
    font-weight: 700;
    text-align: center;
    margin-bottom: 0.5rem;
}

.auth-card .auth-subtitle {
    text-align: center;
    color: var(--wb-gray);
    margin-bottom: 2rem;
    font-size: 0.95rem;
}

/* ============================================
   DASHBOARD
   ============================================ */
.dashboard-wrapper {
    display: flex;
    min-height: 100vh;
    padding-top: 76px;
}

.dashboard-sidebar {
    width: 280px;
    background: var(--wb-dark-2);
    border-right: 1px solid var(--wb-dark-4);
    padding: 2rem 0;
    position: fixed;
    top: 76px;
    left: 0;
    bottom: 0;
    overflow-y: auto;
    transition: var(--wb-transition);
    z-index: 100;
}

.dashboard-content {
    flex: 1;
    margin-left: 280px;
    padding: 2rem;
}

.sidebar-nav .nav-link {
    padding: 0.75rem 1.5rem !important;
    color: var(--wb-gray-light) !important;
    font-weight: 500;
    border-left: 3px solid transparent;
    transition: var(--wb-transition);
}

.sidebar-nav .nav-link:hover,
.sidebar-nav .nav-link.active {
    color: var(--wb-gold) !important;
    background: rgba(203,32,43,0.05);
    border-left-color: var(--wb-gold);
}

.sidebar-nav .nav-link.active::after { display: none; }

.sidebar-nav .nav-link i {
    width: 24px;
    margin-right: 10px;
    text-align: center;
}

.sidebar-section-title {
    font-size: 0.7rem;
    text-transform: uppercase;
    letter-spacing: 2px;
    color: var(--wb-gray);
    padding: 1.5rem 1.5rem 0.5rem;
    font-weight: 600;
}

/* ---- Stats Cards ---- */
.stat-card {
    background: var(--wb-dark-2);
    border: 1px solid var(--wb-dark-4);
    border-radius: var(--wb-radius);
    padding: 1.5rem;
    transition: var(--wb-transition);
}

.stat-card:hover {
    border-color: rgba(203,32,43,0.3);
    transform: translateY(-2px);
}

.stat-card-icon {
    width: 48px;
    height: 48px;
    border-radius: var(--wb-radius-sm);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.3rem;
    margin-bottom: 1rem;
}

.stat-card-icon.gold { background: rgba(203,32,43,0.15); color: var(--wb-gold); }
.stat-card-icon.blue { background: rgba(52,152,219,0.15); color: var(--wb-info); }
.stat-card-icon.green { background: rgba(46,204,113,0.15); color: var(--wb-success); }
.stat-card-icon.red { background: rgba(231,76,60,0.15); color: var(--wb-danger); }

.stat-card-value {
    font-family: var(--font-display);
    font-size: 1.8rem;
    font-weight: 700;
}

.stat-card-label {
    font-size: 0.85rem;
    color: var(--wb-gray);
}

/* ---- Progress Bar ---- */
.progress-custom {
    height: 6px;
    background: var(--wb-dark-4);
    border-radius: 3px;
    overflow: hidden;
}

.progress-custom-bar {
    height: 100%;
    background: linear-gradient(90deg, var(--wb-gold-dark), var(--wb-gold));
    border-radius: 3px;
    transition: width 0.6s ease;
}

/* ============================================
   LESSON PLAYER
   ============================================ */
.lesson-player-wrapper {
    background: #000;
    border-radius: var(--wb-radius);
    overflow: hidden;
    aspect-ratio: 16/9;
    margin-bottom: 1.5rem;
}

.lesson-player-wrapper iframe,
.lesson-player-wrapper video {
    width: 100%;
    height: 100%;
    border: none;
}

/* ============================================
   COURSE DETAIL
   ============================================ */
.course-hero {
    background: linear-gradient(180deg, var(--wb-dark-2) 0%, var(--wb-dark) 100%);
    padding: 7rem 0 5rem;
}

.curriculum-item {
    background: var(--wb-dark-3);
    border: 1px solid var(--wb-dark-4);
    border-radius: var(--wb-radius-sm);
    padding: 1rem 1.25rem;
    margin-bottom: 0.5rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    transition: var(--wb-transition);
}

.curriculum-item:hover {
    border-color: rgba(203,32,43,0.3);
    background: var(--wb-dark-4);
}

.curriculum-item.locked {
    opacity: 0.6;
}

.curriculum-item .lesson-info {
    display: flex;
    align-items: center;
    gap: 12px;
}

.curriculum-item .lesson-number {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: var(--wb-dark-4);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--wb-gray-light);
}

.curriculum-item .badge-free {
    background: rgba(46,204,113,0.15);
    color: var(--wb-success);
    font-size: 0.7rem;
    padding: 3px 10px;
    border-radius: 50px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* ============================================
   ADMIN PANEL
   ============================================ */
.admin-table {
    background: var(--wb-dark-2);
    border-radius: var(--wb-radius);
    overflow: hidden;
}

.admin-table .table {
    color: var(--wb-white);
    margin: 0;
}

.admin-table .table thead th {
    background: var(--wb-dark-3);
    border-bottom: 1px solid var(--wb-dark-4);
    font-weight: 600;
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: var(--wb-gray-light);
    padding: 1rem;
}

.admin-table .table td {
    padding: 1rem;
    border-bottom: 1px solid var(--wb-dark-4);
    vertical-align: middle;
}

.admin-table .table tbody tr:hover {
    background: rgba(203,32,43,0.03);
}

/* ---- Admin Modal ---- */
.modal-content {
    background: var(--wb-dark-2);
    border: 1px solid var(--wb-dark-4);
    border-radius: var(--wb-radius);
}

.modal-header {
    border-bottom: 1px solid var(--wb-dark-4);
    padding: 1.25rem 1.5rem;
}

.modal-footer {
    border-top: 1px solid var(--wb-dark-4);
    padding: 1rem 1.5rem;
}

.modal-title { font-weight: 700; }

/* ============================================
   FOOTER
   ============================================ */
.site-footer {
    background: var(--wb-dark-2);
    border-top: 1px solid var(--wb-dark-4);
    padding: 4rem 0 0;
}

.footer-brand {
    font-family: var(--font-display);
    font-size: 1.4rem;
    letter-spacing: 2px;
}

.footer-desc {
    color: var(--wb-gray);
    font-size: 0.9rem;
    line-height: 1.8;
}

.footer-heading {
    font-weight: 700;
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    color: var(--wb-white);
    margin-bottom: 1.25rem;
}

.footer-links {
    list-style: none;
    padding: 0;
    margin: 0;
}

.footer-links li { margin-bottom: 0.6rem; }

.footer-links a {
    color: var(--wb-gray);
    font-size: 0.9rem;
    transition: var(--wb-transition);
}

.footer-links a:hover {
    color: var(--wb-gold);
    padding-left: 4px;
}

.footer-contact li {
    color: var(--wb-gray);
    font-size: 0.9rem;
    display: flex;
    align-items: center;
}

.social-links {
    display: flex;
    gap: 12px;
}

.social-link {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: var(--wb-dark-3);
    border: 1px solid var(--wb-dark-4);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--wb-gray-light);
    font-size: 1.1rem;
    transition: var(--wb-transition);
}

.social-link:hover {
    background: var(--wb-gold);
    border-color: var(--wb-gold);
    color: var(--wb-dark);
    transform: translateY(-3px);
}

.footer-divider {
    border-color: var(--wb-dark-4);
    margin: 2rem 0 0;
}

.footer-bottom {
    text-align: center;
    padding: 1.5rem 0;
    font-size: 0.85rem;
    color: var(--wb-gray);
}

/* ============================================
   ALERTS (Bootstrap override)
   ============================================ */
.alert {
    border-radius: var(--wb-radius-sm);
    border: none;
    font-size: 0.9rem;
}

/* ============================================
   DROPDOWN (dark theme)
   ============================================ */
.dropdown-menu-dark {
    background: var(--wb-dark-3);
    border: 1px solid var(--wb-dark-4);
    border-radius: var(--wb-radius-sm);
}

.dropdown-menu-dark .dropdown-item:hover {
    background: rgba(203,32,43,0.1);
    color: var(--wb-gold);
}

/* ============================================
   RESPONSIVE
   ============================================ */
@media (max-width: 991.98px) {
    .dashboard-sidebar {
        transform: translateX(-100%);
    }
    .dashboard-sidebar.show {
        transform: translateX(0);
    }
    .dashboard-content {
        margin-left: 0;
    }
    .hero-stats {
        gap: 1.5rem;
    }
}

@media (max-width: 767.98px) {
    .section-padding { padding: 4rem 0; }
    
    .hero-section {
        min-height: auto;
        padding: 2rem 0 3rem;
        text-align: center;
    }

    .hero-title {
        font-size: 2.5rem !important;
        margin-bottom: 2rem;
    }
    
    .hero-subtitle {
        font-size: 1rem;
        margin: 0 auto 2.5rem;
    }

    .hero-stats {
        justify-content: center;
        gap: 2rem;
        margin-top: 2rem;
    }

    .hero-section .d-flex.gap-3 {
        justify-content: center;
    }

    .site-logo {
        height: 40px !important;
    }
    
    .hero-stat-number { font-size: 1.5rem; }
    


    .section-title {
        font-size: 1.8rem !important;
    }

    .navbar > .container {
        flex-direction: column !important;
        align-items: center !important;
        gap: 15px;
    }

    .navbar-brand {
        margin-right: 0 !important;
    }

    .navbar-toggler {
        margin: 0 auto !important;
        padding: 5px;
    }

    .navbar-collapse {
        width: 100%;
        margin-top: 10px;
        padding: 1.2rem !important;
        text-align: center;
    }

    .navbar-nav {
        margin-bottom: 1rem;
    }

    .nav-link {
        font-size: 1rem;
        padding: 0.6rem !important;
    }

    .navbar-actions {
        margin-top: 1rem;
        padding-top: 1rem;
        border-top: 1px solid var(--wb-dark-4);
        flex-direction: column !important;
        display: flex !important;
        gap: 12px !important;
    }

    .mobile-utils {
        width: 100%;
        justify-content: center !important;
        margin-bottom: 5px;
    }

    .navbar-actions .btn {
        width: 100% !important;
        padding: 0.6rem !important;
        font-size: 0.9rem;
    }

    /* Footer mobile fixes */
    .site-footer {
        text-align: center;
        padding-top: 3rem;
    }

    .footer-brand {
        display: flex;
        justify-content: center;
    }

    .footer-brand, .social-links, .footer-contact li {
        justify-content: center;
    }

    .footer-links li {
        margin-bottom: 0.8rem;
    }

    .footer-desc {
        max-width: 350px;
        margin-left: auto;
        margin-right: auto;
    }

    .footer-heading {
        margin-top: 1rem;
    }

    /* Course detail mobile fixes */
    .course-hero {
        padding-top: 6rem;
        text-align: center;
    }

    .breadcrumb {
        justify-content: center;
    }

    .course-hero .d-flex.flex-wrap {
        justify-content: center;
    }
}

@media (max-width: 575.98px) {
    .hero-title {
        font-size: 2rem !important;
    }
    
    .hero-stats {
        flex-direction: column;
        gap: 1.5rem;
    }

    .category-card {
        padding: 1.5rem 1rem;
    }

    .hero-badge {
        font-size: 0.75rem;
        padding: 6px 15px;
        line-height: 1.4;
        text-wrap: balance;
    }

    .hero-section .d-flex.gap-3 {
        flex-direction: column;
        width: 100%;
        padding: 0 1rem;
    }

    .hero-section .btn {
        width: 100% !important;
    }
}

/* ============================================
   MISC UTILITIES
   ============================================ */
.text-gold { color: var(--wb-gold) !important; }
.bg-gold-subtle { background: rgba(203,32,43,0.1); }
.border-gold { border-color: var(--wb-gold) !important; }

.empty-state {
    text-align: center;
    padding: 4rem 2rem;
    color: var(--wb-gray);
}

.empty-state i { font-size: 3rem; margin-bottom: 1rem; display: block; opacity: 0.5; }
.empty-state h5 { color: var(--wb-white); margin-bottom: 0.5rem; }

/* ---- Thumbnail placeholder ---- */
.thumb-placeholder {
    aspect-ratio: 16/9;
    background: linear-gradient(135deg, var(--wb-dark-3), var(--wb-dark-4));
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--wb-gray);
    font-size: 2rem;
    border-radius: var(--wb-radius-sm);
}

/* ============================================
   LIGHT THEME 
   ============================================ */
[data-theme="light"] {
    --wb-dark: #FFFFFF;
    --wb-dark-2: #F8FAFC;
    --wb-dark-3: #F1F5F9;
    --wb-dark-4: #E2E8F0;
    --wb-white: #0F172A;
    --wb-gray: #64748B;
    --wb-gray-light: #475569;
    --wb-shadow: 0 4px 20px rgba(15, 23, 42, 0.05);
}

[data-theme="light"] .dashboard-sidebar {
    background: #FFFFFF !important;
    border-right: 1px solid #F1F5F9 !important;
}

[data-theme="light"] .sidebar-nav .nav-link {
    color: #64748B !important;
}

[data-theme="light"] .sidebar-nav .nav-link:hover,
[data-theme="light"] .sidebar-nav .nav-link.active {
    color: var(--wb-gold) !important;
    background: rgba(203, 32, 43, 0.04) !important;
    border-left-color: var(--wb-gold) !important;
}

[data-theme="light"] .sidebar-section-title {
    color: #94A3B8 !important;
}

[data-theme="light"] body {
    background-color: var(--wb-dark);
    color: var(--wb-white);
}

[data-theme="light"] #mainNavbar {
    background: rgba(255, 255, 255, 0.85);
}

[data-theme="light"] #mainNavbar.scrolled {
    background: rgba(255, 255, 255, 0.98);
    box-shadow: 0 2px 20px rgba(0,0,0,0.1);
}

[data-theme="light"] .brand-wolf {
    color: var(--wb-white);
}

[data-theme="light"] .navbar-toggler-icon {
    filter: invert(1);
}

[data-theme="light"] .text-white { color: #1A1A1A !important; }
[data-theme="light"] .text-white-50 { color: #495057 !important; }

/* Invert PDF/Embed background blocks on light mode if needed */
[data-theme="light"] .lesson-player-wrapper {
    background: #E9ECEF;
}

[data-theme="light"] .admin-table .table {
    color: #1A1A1A;
}
[data-theme="light"] .btn-outline-light { color: #1A1A1A; border-color: #1A1A1A; } [data-theme="light"] .btn-outline-light:hover { background: #1A1A1A; color: #fff !important; }

/* Light mode dropdown override */
[data-theme="light"] .dropdown-menu-dark {
    background-color: var(--wb-dark) !important;
    border-color: var(--wb-dark-4) !important;
}

[data-theme="light"] .dropdown-menu-dark .dropdown-item {
    color: var(--wb-white) !important;
}

[data-theme="light"] .dropdown-menu-dark .dropdown-item:hover {
    background-color: var(--wb-dark-2) !important;
    color: var(--wb-gold) !important;
}

[data-theme="light"] .dropdown-menu-dark .dropdown-divider {
    border-top: 1px solid var(--wb-dark-4) !important;
}

/* ============================================
   RTL SUPPORT
   ============================================ */
[dir="rtl"] {
    text-align: right;
}

[dir="rtl"] .navbar-nav {
    padding-right: 0;
}

[dir="rtl"] .ms-auto {
    margin-right: auto !important;
    margin-left: 0 !important;
}

[dir="rtl"] .me-2 {
    margin-left: 0.5rem !important;
    margin-right: 0 !important;
}

[dir="rtl"] .me-1 {
    margin-left: 0.25rem !important;
    margin-right: 0 !important;
}

[dir="rtl"] .ms-2 {
    margin-right: 0.5rem !important;
    margin-left: 0 !important;
}

[dir="rtl"] .dropdown-menu {
    text-align: right;
}

[dir="rtl"] .sidebar-nav .nav-link i {
    margin-left: 10px;
    margin-right: 0;
}

[dir="rtl"] .dashboard-sidebar {
    left: auto;
    right: 0;
    border-left: 1px solid var(--wb-dark-4);
    border-right: none;
}

[dir="rtl"] .dashboard-content {
    margin-left: 0;
    margin-right: 280px;
}

@media (max-width: 991.98px) {
    [dir="rtl"] .dashboard-sidebar {
        right: -280px;
        left: auto;
        transform: none;
    }
    [dir="rtl"] .dashboard-sidebar.show {
        right: 0;
    }
    [dir="rtl"] .dashboard-content {
        margin-right: 0;
    }
}

/* Logo Styling */
.site-logo {
    height: 55px !important;
    width: auto !important;
    display: block;
    max-width: 300px;
}

.footer-logo {
    height: 30px !important;
    width: auto !important;
    display: block;
    max-width: 180px;
}

/* ============================================
   PORTAL CAROUSEL
   ============================================ */
.portal-carousel .carousel-indicators {
    margin-bottom: 1rem;
}
.portal-carousel .carousel-indicators [data-bs-target] {
    width: 30px;
    height: 4px;
    border-radius: 2px;
    background-color: var(--wb-white);
    opacity: 0.5;
    border: none;
    transition: var(--wb-transition);
}
.portal-carousel .carousel-indicators .active {
    width: 60px;
    opacity: 1;
    background-color: var(--wb-gold);
}
.portal-carousel .carousel-item {
    transition: transform 0.8s ease-in-out;
}

/* ============================================
   SAFETY NET: prevent stuck Bootstrap backdrops
   from ever greying out / blocking the page
   ============================================ */
.modal-backdrop {
    display: none !important;
}

/* Re-enable ONLY when a modal is genuinely open */
.modal.show ~ .modal-backdrop,
body.modal-open .modal-backdrop {
    display: block !important;
}
