body {
    font-family: 'Inter', sans-serif !important;
    background-color: #f4f6f9;
}

h1, h2, h3, h4, h5, h6, .brand-link {
    font-family: 'Outfit', sans-serif !important;
}

/* ══════════════════════════════════════════
   Global Responsive Fixes
   ══════════════════════════════════════════ */

/* Images — never overflow their container */
img {
    max-width: 100% !important;
    height: auto;
}

/* Preview boxes inside modals/cards — scale with container */
.preview-box,
[style*="width:90px"][style*="height:65px"],
[style*="width: 90px"][style*="height: 65px"],
[style*="width:100px"][style*="height:75px"],
[style*="width: 100px"][style*="height: 75px"] {
    width: 90px !important;
    height: 65px !important;
    overflow: hidden !important;
    border-radius: 8px !important;
    flex-shrink: 0 !important;
}

/* Filter rows — stack properly on mobile */
@media (max-width: 767.98px) {
    .card-body .row.mb-4 > [class*="col-"],
    .card-body .row.mb-3 > [class*="col-"],
    .card-body .row.align-items-end > [class*="col-"] {
        margin-bottom: 10px;
    }

    /* Reset / refresh button — full width on mobile */
    .card-body .row > [class*="col-md-1"].d-flex,
    .card-body .row > [class*="col-md-2"].d-flex {
        width: 100% !important;
        flex: 0 0 100% !important;
        max-width: 100% !important;
    }

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

    /* Card header — stack on mobile */
    .card-header.d-flex {
        flex-direction: column !important;
        align-items: flex-start !important;
        gap: 10px !important;
    }

    .card-header.d-flex .admin-btn,
    .card-header.d-flex .btn {
        width: 100% !important;
        text-align: center !important;
    }

    /* Period toggle buttons — wrap on mobile */
    .period-toggle {
        flex-wrap: wrap !important;
        gap: 6px !important;
    }

    .period-btn {
        flex: 1 1 auto !important;
        text-align: center !important;
    }
}

/* Table — always responsive */
.table-responsive {
    overflow-x: auto !important;
    -webkit-overflow-scrolling: touch !important;
}

/* Modal — full width on small screens */
@media (max-width: 575.98px) {
    .modal-dialog {
        margin: 0.75rem !important;
        max-width: calc(100vw - 1.5rem) !important;
    }

    .modal-dialog.modal-lg,
    .modal-dialog.modal-xl {
        max-width: calc(100vw - 1.5rem) !important;
    }

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

/* Input groups — don't overflow on mobile */
@media (max-width: 575.98px) {
    .input-group {
        flex-wrap: nowrap !important;
    }

    .input-group .form-control {
        min-width: 0 !important;
    }

    /* Date range picker — full width on mobile */
    .search-group[style*="width"] {
        width: 100% !important;
    }
}

/* Admin two-column settings — stack on mobile */
@media (max-width: 767.98px) {
    .col-lg-7, .col-lg-5 {
        margin-bottom: 1.5rem;
    }
}

/* Admin Theme Base */
.active1, .nav-link.active {
    background: linear-gradient(90deg, #FF8331 0%, #F05123 100%) !important;
    color: #fff !important;
    box-shadow: 0 4px 8px rgba(240, 81, 35, 0.3);
    border: none !important;
    border-radius: 8px !important;
}

.bg-light a.active1 {
    color: #fff !important;
    font-weight: 700;
}

.main-header {
    /* background: linear-gradient(90deg, #FF8331 0%, #F05123 100%) !important; */
    background: #ec6c25  !important;
    box-shadow: 0 2px 12px rgba(240, 81, 35, 0.25) !important;
}

/* ════════════════════════════════════════
   NAVBAR — Hamburger Button
════════════════════════════════════════ */
.navbar-pushmenu-btn {
    width: 38px;
    height: 38px;
    display: flex !important;
    align-items: center;
    justify-content: center;
    border-radius: 10px !important;
    color: rgba(255, 255, 255, 0.9) !important;
    transition: all 0.2s ease;
    font-size: 16px;
    margin-left: 4px;
}

.navbar-pushmenu-btn:hover {
    background: rgba(255, 255, 255, 0.18) !important;
    color: #fff !important;
}

/* ════════════════════════════════════════
   NAVBAR — User Toggle (right side)
════════════════════════════════════════ */
.user-nav-toggle {
    display: flex !important;
    align-items: center;
    gap: 10px;
    padding: 6px 10px !important;
    border-radius: 12px !important;
    transition: background 0.2s;
    text-decoration: none !important;
}

.user-nav-toggle:hover { background: rgba(255, 255, 255, 0.18) !important; }

.user-nav-avatar-box {
    position: relative;
    flex-shrink: 0;
}

.user-nav-avatar {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid rgba(255, 255, 255, 0.5);
}

.user-online-dot {
    position: absolute;
    bottom: 1px;
    right: 1px;
    width: 9px;
    height: 9px;
    background: #a3e635;
    border-radius: 50%;
    border: 2px solid #F05123;
}

.user-nav-info {
    flex-direction: column;
    line-height: 1.2;
}

.user-nav-name {
    display: block;
    font-size: 13px;
    font-weight: 700;
    color: #fff;
}

.user-nav-role {
    display: block;
    font-size: 11px;
    color: rgba(255, 255, 255, 0.72);
    font-weight: 500;
}

.user-nav-caret {
    font-size: 10px;
    color: rgba(255, 255, 255, 0.72);
    margin-left: 2px;
    transition: transform 0.2s;
}

.user-nav-toggle[aria-expanded="true"] .user-nav-caret {
    transform: rotate(180deg);
}

/* ════════════════════════════════════════
   NAVBAR — User Dropdown Card
════════════════════════════════════════ */
.user-dropdown-card {
    min-width: 260px !important;
    border: 1px solid #e2e8f0 !important;
    border-radius: 14px !important;
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.12) !important;
    margin-top: 8px !important;
    overflow: hidden;
}

/* Profile header */
.udc-header {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 18px 18px 16px;
    background: linear-gradient(135deg, rgba(255,131,49,0.06) 0%, rgba(240,81,35,0.04) 100%);
}

.udc-avatar-wrap { position: relative; flex-shrink: 0; }

.udc-avatar {
    width: 52px;
    height: 52px;
    border-radius: 50%;
    object-fit: cover;
    border: 2.5px solid rgba(240, 81, 35, 0.2);
}

.udc-online-dot {
    position: absolute;
    bottom: 2px;
    right: 2px;
    width: 11px;
    height: 11px;
    background: #22c55e;
    border-radius: 50%;
    border: 2px solid #fff;
}

.udc-name {
    font-size: 14px;
    font-weight: 700;
    color: #1e293b;
    line-height: 1.3;
}

.udc-email {
    font-size: 11.5px;
    color: #64748b;
    margin-top: 2px;
    word-break: break-all;
}

.udc-badge {
    display: inline-block;
    margin-top: 5px;
    padding: 2px 10px;
    background: rgba(240, 81, 35, 0.1);
    color: #F05123;
    border: 1px solid rgba(240, 81, 35, 0.2);
    border-radius: 20px;
    font-size: 10.5px;
    font-weight: 700;
    letter-spacing: 0.04em;
}

/* Divider */
.udc-divider {
    height: 1px;
    background: #f1f5f9;
    margin: 0;
}

/* Links */
.udc-link {
    display: flex !important;
    align-items: center;
    gap: 11px;
    padding: 11px 18px !important;
    font-size: 13px;
    font-weight: 500;
    color: #374151 !important;
    text-decoration: none !important;
    transition: background 0.18s;
}

.udc-link:hover {
    background: #f8fafc !important;
    color: #F05123 !important;
}

.udc-link:hover .udc-link-icon { color: #F05123; }

.udc-link-icon {
    width: 30px;
    height: 30px;
    background: #f1f5f9;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 13px;
    color: #64748b;
    flex-shrink: 0;
    transition: background 0.18s, color 0.18s;
}

/* Sign out link */
.udc-logout { color: #dc2626 !important; }
.udc-logout .udc-link-icon { background: rgba(239,68,68,0.08); color: #dc2626; }
.udc-logout:hover { background: rgba(239,68,68,0.05) !important; color: #dc2626 !important; }
.udc-logout:hover .udc-link-icon { background: rgba(239,68,68,0.15); }

.main-sidebar {
    background-color: #f8f9fa !important;
}

/* ── Sidebar width: 300px (override AdminLTE default 250px) ── */
.main-sidebar,
.main-sidebar:before {
    width: 300px !important;
}

/* Fix: AdminLTE's global sidebar-collapse uses -250px; override for our 300px sidebar */
.sidebar-collapse .main-sidebar,
.sidebar-collapse .main-sidebar:before {
    margin-left: -300px !important;
}

/* ── Mobile (< 992px): sidebar slides off-screen completely ── */
@media (max-width: 991.98px) {
    .main-sidebar,
    .main-sidebar:before {
        margin-left: -300px !important;
    }

    .sidebar-open .main-sidebar,
    .sidebar-open .main-sidebar:before {
        margin-left: 0 !important;
    }

    /* Content takes full width on mobile */
    .content-wrapper,
    .main-footer,
    .main-header {
        margin-left: 0 !important;
    }
}

/* ── Desktop (>= 992px) ── */
@media (min-width: 992px) {
    /* Default: sidebar expanded at 300px */
    .content-wrapper,
    .main-footer,
    .main-header {
        margin-left: 300px !important;
    }

    /* Non-mini collapse: completely hide sidebar off-screen */
    .sidebar-collapse:not(.sidebar-mini) .main-sidebar,
    .sidebar-collapse:not(.sidebar-mini) .main-sidebar:before {
        margin-left: -300px !important;
    }

    .sidebar-collapse:not(.sidebar-mini) .content-wrapper,
    .sidebar-collapse:not(.sidebar-mini) .main-footer,
    .sidebar-collapse:not(.sidebar-mini) .main-header {
        margin-left: 0 !important;
    }

    /* sidebar-mini collapse: icon-only strip (4.6rem) */
    .sidebar-mini.sidebar-collapse .main-sidebar,
    .sidebar-mini.sidebar-collapse .main-sidebar:before {
        margin-left: 0 !important;
        width: 4.6rem !important;
    }

    /* On hover, expand mini sidebar to full 300px (prevent text overflow) */
    .sidebar-mini.sidebar-collapse .main-sidebar:hover,
    .sidebar-mini.sidebar-collapse .main-sidebar:hover:before {
        width: 300px !important;
    }

    .sidebar-mini.sidebar-collapse .content-wrapper,
    .sidebar-mini.sidebar-collapse .main-footer,
    .sidebar-mini.sidebar-collapse .main-header {
        margin-left: 4.6rem !important;
    }
}

/* ── Content wrapper right spacing & overflow fix ── */
.content-wrapper {
    overflow-x: hidden;
}

/* Give consistent horizontal padding to content area */
.content-wrapper > .content-header .container-fluid,
.content-wrapper > section.content > .container-fluid {
    padding-right: 1.25rem;
    padding-left: 1.25rem;
}

/* Ensure wrapper doesn't create horizontal scroll */
.wrapper {
    overflow-x: hidden;
}

/* ── Global Form Submit Button Loader ── */
.btn-loading {
    pointer-events: none !important;
    opacity: 0.85 !important;
    display: inline-flex !important;
    align-items: center !important;
    gap: 8px !important;
}

.btn-submit-spinner {
    display: inline-block;
    width: 15px;
    height: 15px;
    border: 2px solid rgba(255, 255, 255, 0.35);
    border-top-color: #fff;
    border-radius: 50%;
    animation: btn-global-spin 0.7s linear infinite;
    flex-shrink: 0;
}

/* For dark/outline buttons — spinner uses current color */
.btn-outline-secondary.btn-loading .btn-submit-spinner,
.btn-white.btn-loading .btn-submit-spinner,
.btn-modal-close.btn-loading .btn-submit-spinner {
    border-color: rgba(0, 0, 0, 0.2);
    border-top-color: #495057;
}

.btn-submit-text {
    display: inline-block;
}

@keyframes btn-global-spin {
    to { transform: rotate(360deg); }
}

/* Premium Branding Area */
.brand-link {
    background-color: #ec6c25 !important;
    color: white !important;
    border-bottom: 1px solid rgba(0,0,0,.1);
    text-align: left !important;
    padding: 10px 15px !important;
    display: flex;
    align-items: center;
    font-weight: 600;
}

.brand-link img {
    filter: brightness(0) invert(1) !important;
    margin-right: 12px;
    max-height: 35px;
}

/* Premium Card Design */
.card {
    border: none !important;
    border-radius: 15px !important;
    box-shadow: 0 5px 20px rgba(0,0,0,0.05) !important;
    overflow: hidden;
    margin-bottom: 2rem;
}

.card-header {
    background-color: #fff !important;
    border-bottom: 1px solid #f0f0f0 !important;
    padding: 1.25rem 1.5rem !important;
}

.card-title {
    font-weight: 600 !important;
    color: #333 !important;
    font-size: 1.1rem !important;
    margin-bottom: 0 !important;
}

/* Updated Form & Filters */
.form-control {
    border-radius: 10px !important;
    border: 1.5px solid #e2e8f0 !important;
    padding: 0.6rem 1rem !important;
    height: auto !important;
    font-size: 0.9rem !important;
    color: #2d3748 !important;
    background-color: #f8fafc !important;
    transition: border-color 0.2s ease, box-shadow 0.2s ease !important;
}

.form-control:focus {
    border-color: #ec6c25 !important;
    background-color: #fff !important;
    box-shadow: 0 0 0 3px rgba(236, 108, 37, 0.12) !important;
    outline: none !important;
}

/* ── Native Select / Dropdown ── */
/* Target all selects globally — class-based + element-based */
select,
select.form-control,
select.custom-select-premium,
.custom-select-premium,
.form-group select,
.filter-group select,
.card-body select,
.content-wrapper select,
td select,
th select {
    -webkit-appearance: none !important;
    -moz-appearance: none !important;
    appearance: none !important;
    background: #f8fafc url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23ec6c25' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'/%3E%3C/svg%3E") no-repeat right 14px center !important;
    background-size: 14px 14px !important;
    border-radius: 10px !important;
    border: 1.5px solid #e2e8f0 !important;
    padding: 0.55rem 2.5rem 0.55rem 0.9rem !important;
    font-size: 0.9rem !important;
    color: #2d3748 !important;
    height: auto !important;
    cursor: pointer !important;
    transition: border-color 0.2s ease, box-shadow 0.2s ease !important;
}

select:focus,
select.form-control:focus,
select.custom-select-premium:focus,
.custom-select-premium:focus {
    border-color: #ec6c25 !important;
    background-color: #fff !important;
    box-shadow: 0 0 0 3px rgba(236, 108, 37, 0.12) !important;
    outline: none !important;
}

select:disabled,
select.form-control:disabled {
    background-color: #f1f5f9 !important;
    color: #94a3b8 !important;
    cursor: not-allowed !important;
    opacity: 1 !important;
}

/* Disabled state for all form-controls */
.form-control:disabled,
.form-control[readonly] {
    background-color: #f1f5f9 !important;
    color: #94a3b8 !important;
    cursor: not-allowed !important;
    opacity: 1 !important;
}

/* DataTables length select */
.dataTables_length select {
    -webkit-appearance: none !important;
    -moz-appearance: none !important;
    appearance: none !important;
    background: #f8fafc url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23ec6c25' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'/%3E%3C/svg%3E") no-repeat right 10px center !important;
    background-size: 12px 12px !important;
    border: 1.5px solid #e2e8f0 !important;
    border-radius: 8px !important;
    padding: 0.35rem 2rem 0.35rem 0.65rem !important;
    font-size: 0.85rem !important;
    color: #2d3748 !important;
    cursor: pointer !important;
}

.dataTables_length select:focus {
    border-color: #ec6c25 !important;
    box-shadow: 0 0 0 3px rgba(236, 108, 37, 0.1) !important;
    outline: none !important;
    background-color: #fff !important;
}

/* DataTables search input */
.dataTables_filter input {
    border-radius: 8px !important;
    border: 1.5px solid #e2e8f0 !important;
    padding: 0.35rem 0.75rem !important;
    font-size: 0.85rem !important;
    color: #2d3748 !important;
    background-color: #f8fafc !important;
    transition: border-color 0.2s ease, box-shadow 0.2s ease !important;
}

.dataTables_filter input:focus {
    border-color: #ec6c25 !important;
    box-shadow: 0 0 0 3px rgba(236, 108, 37, 0.1) !important;
    outline: none !important;
    background-color: #fff !important;
}

.input-group-text {
    border-radius: 10px 0 0 10px !important;
    background-color: #f8fafc !important;
    border: 1px solid #e2e8f0 !important;
    color: #64748b !important;
    font-weight: 500 !important;
}

.input-group .form-control {
    border-radius: 0 10px 10px 0 !important;
}

/* Modern Tables */
.table {
    margin-bottom: 0 !important;
}

.table thead th {
    background-color: #f8fafc !important;
    color: #64748b !important;
    font-weight: 600 !important;
    text-transform: uppercase;
    font-size: 0.72rem !important;
    letter-spacing: 0.05em;
    padding: 12px 15px !important;
    border-top: none !important;
    border-bottom: 2px solid #f1f5f9 !important;
}

.table tbody td {
    padding: 10px 15px !important;
    vertical-align: middle !important;
    color: #475569;
    font-size: 0.88rem !important;
    border-bottom: 1px solid #f1f5f9 !important;
}

.table tbody tr:hover {
    background-color: #fcfcfc !important;
}
.input-group-custom {
    position: relative;
    width: 100%;
    margin: 1.2em auto;
}

.input-group-custom i:first-child {
    position: absolute;
    left: 20px;
    top: 50%;
    transform: translateY(-50%);
    color: #333;
    font-size: 22px;
    z-index: 10;
}

.input-group-custom .toggle-password {
    position: absolute;
    right: 20px;
    top: 50%;
    transform: translateY(-50%);
    color: #aaa;
    font-size: 18px;
    z-index: 10;
    cursor: pointer;
}

.form__input {
    width: 100%;
    border: 1px solid #fce8d5;
    border-radius: 15px;
    padding: 1.2em 1.2em 1.2em 4em;
    outline: none;
    transition: all .3s ease;
    background: #fff;
    color: #555;
    font-size: 16px;
}

.form__input:focus {
    border-color: #ec6c25;
    box-shadow: 0 0 10px rgba(236, 108, 37, 0.15);
}

.btn-custom-gradient {
    transition: all .5s ease;
    width: 70%;
    border-radius: 30px;
    color: #fff !important;
    font-weight: 600;
    background: linear-gradient(90deg, #FF8331 0%, #F05123 100%);
    border: none;
    margin-top: 1.5em;
    margin-bottom: 1em;
    box-shadow: 0 4px 15px rgba(240, 81, 35, 0.4);
    text-transform: uppercase;
}

.btn-custom-gradient:hover,
.btn-custom-gradient:focus {
    background: linear-gradient(90deg, #F05123 0%, #FF8331 100%);
    color: #fff !important;
    box-shadow: 0 6px 20px rgba(240, 81, 35, 0.5);
    outline: none;
}

ul.nav.nav-pills.nav-sidebar
{
    padding: 0px 8px !important;
}
/* Brand link styles integrated above */
/* New */
.nav-sidebar .nav-item>.nav-link:hover{
    background: linear-gradient(90deg, #FF8331 0%, #F05123 100%) !important;
    box-shadow: 0 4px 12px rgba(240, 81, 35, 0.4) !important;
    color: #fff !important;
    border-radius: 8px !important;
}
.sidebar-collapse .nav-sidebar .nav-item>.nav-link.active1{
    width: 50px !important;
    height: 40px !important;
    border-radius: 8px !important;
    margin: 7px 0 !important;
    display: flex !important;
    align-items: center !important;
    background: linear-gradient(90deg, #FF8331 0%, #F05123 100%) !important;
    box-shadow: 0 4px 12px rgba(240, 81, 35, 0.4) !important;
}
.sidebar-collapse .nav-sidebar:hover>.nav-item>.nav-link.active1{
    width: auto !important;
    height: auto !important;
}
/* Action Buttons Styling */
.btn-action {
    width: 32px;
    height: 32px;
    border-radius: 8px !important;
    display: inline-flex !important;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
    border: none !important;
    margin: 0 4px;
    padding: 0 !important;
    cursor: pointer !important;
}

.btn-action.remove-track,
.btn-action.remove-course
{
    color: #ef4444 !important;
    background-color: rgba(239, 68, 68, 0.1) !important;
}

.btn-action.remove-track:hover,
.btn-action.remove-course:hover
{
    color: #fff !important;
    background-color: #ef4444 !important;
}

.btn-action i {
    font-size: 14px;
}

.btn-action.view {
    background-color: rgba(59, 130, 246, 0.1) !important;
    color: #3b82f6 !important;
}

.btn-action.view:hover {
    background-color: #3b82f6 !important;
    color: #fff !important;
}

.btn-action.delete {
    background-color: rgba(239, 68, 68, 0.1) !important;
    color: #ef4444 !important;
}

.btn-action.delete:hover {
    background-color: #ef4444 !important;
    color: #fff !important;
}

.btn-action.freeSubscription {
    background-color: rgba(236, 108, 37, 0.1) !important;
    color: #ec6c25 !important;
}

.btn-action.freeSubscription:hover {
    background-color: #ec6c25 !important;
    color: #fff !important;
}

.btn-action.play {
    background-color: rgba(22, 163, 74, 0.12) !important;
    color: #16a34a !important;
}

.btn-action.play:hover {
    background-color: #16a34a !important;
    color: #fff !important;
}

/* DataTable Pagination Premium Box Style */
.dataTables_wrapper .dataTables_paginate {
    padding-top: 2rem !important;
    padding-bottom: 1rem !important;
}

.dataTables_wrapper .dataTables_paginate .paginate_button {
    width: 34px !important;
    height: 34px !important;
    border-radius: 8px !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    border: none !important;
    background: #f1f5f9 !important;
    color: #475569 !important;
    font-size: 0.8rem !important;
    margin: 0 3px !important;
    cursor: pointer !important;
    transition: all 0.2s ease;
    padding: 0 !important;
    box-shadow: none !important;
}

.dataTables_wrapper .dataTables_paginate .paginate_button:hover {
    background-color: #e2e8f0 !important;
    color: #1e293b !important;
}

.dataTables_wrapper .dataTables_paginate .paginate_button.current,
.dataTables_wrapper .dataTables_paginate .paginate_button.current:hover {
    background: linear-gradient(90deg, #FF8331 0%, #F05123 100%) !important;
    color: #fff !important;
    font-weight: 600 !important;
    box-shadow: 0 4px 12px rgba(240, 81, 35, 0.25) !important;
}

.dataTables_wrapper .dataTables_paginate .paginate_button.disabled,
.dataTables_wrapper .dataTables_paginate .paginate_button.disabled:hover {
    background: #f8fafc !important;
    color: #cbd5e1 !important;
    cursor: not-allowed !important;
    opacity: 0.6;
}

.dataTables_wrapper .dataTables_paginate .paginate_button.previous {
    margin-right: 15px !important;
}

.dataTables_wrapper .dataTables_paginate .paginate_button.next {
    margin-left: 15px !important;
}

.dataTables_wrapper .dataTables_info {
    font-size: 0.8rem !important;
    color: #64748b !important;
    padding-top: 1.8rem !important;
}

.refresh-btn {
    background-color: #f1f5f9 !important;
    color: #64748b !important;
    border-radius: 8px !important;
    padding: 0 !important;
    display: flex;
    align-items: center;
    justify-content: center;
    height: 38px;
    width: 38px;
    border: 1px solid #e2e8f0 !important;
}

.refresh-btn:hover {
    background-color: #e2e8f0 !important;
    color: #334155 !important;
}

/* Badge Enhancements */
.badge {
    padding: 5px 10px;
    border-radius: 6px;
    font-weight: 500;
    font-size: 0.7rem;
    letter-spacing: 0.02em;
}

.badge-success   { background-color: rgba(34, 197, 94, 0.12)  !important; color: #16a34a !important; border: 1px solid rgba(34, 197, 94, 0.25)  !important; }
.badge-warning   { background-color: rgba(245, 158, 11, 0.12) !important; color: #d97706 !important; border: 1px solid rgba(245, 158, 11, 0.25) !important; }
.badge-danger    { background-color: rgba(239, 68, 68, 0.12)  !important; color: #dc2626 !important; border: 1px solid rgba(239, 68, 68, 0.25)  !important; }
.badge-info      { background-color: rgba(6, 182, 212, 0.12)  !important; color: #0891b2 !important; border: 1px solid rgba(6, 182, 212, 0.25)  !important; }
.badge-primary   { background-color: rgba(99, 102, 241, 0.12) !important; color: #4f46e5 !important; border: 1px solid rgba(99, 102, 241, 0.25) !important; }
.badge-secondary { background-color: rgba(100, 116, 139, 0.12)!important; color: #475569 !important; border: 1px solid rgba(100, 116, 139, 0.25)!important; }

/* Page Header Spacing */
.breadcrumb-item a {
    color: #64748b !important;
    text-decoration: none !important;
    transition: all 0.2s ease;
    font-weight: 500;
}

.breadcrumb-item a:hover {
    color: #ec6c25 !important;
}

.breadcrumb-item + .breadcrumb-item::before {
    color: #cbd5e1 !important;
}

.breadcrumb-item.active {
    color: #ec6c25 !important;
    font-weight: 600;
}
/* Premium Toggle/Switch */
.switch {
    position: relative;
    display: inline-block;
    width: 38px;
    height: 20px;
}

.switch input {
    opacity: 0;
    width: 0;
    height: 0;
}

.slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: #cbd5e1;
    transition: .4s;
}

.slider:before {
    position: absolute;
    content: "";
    height: 14px;
    width: 14px;
    left: 3px;
    bottom: 3px;
    background-color: white;
    transition: .4s;
    box-shadow: 0 1px 3px rgba(0,0,0,0.2);
}

input:checked + .slider {
    background-color: #ec6c25;
}

input:checked + .slider:before {
    transform: translateX(18px);
}

.slider.round {
    border-radius: 20px;
}

.slider.round:before {
    border-radius: 50%;
}

/* Modal Layout Fix (Right Spacing/Shift) */
body.modal-open {
    padding-right: 0 !important;
    overflow: hidden;
}

.modal-open .main-header,
.modal-open .main-sidebar {
    padding-right: 0 !important;
}

/* Fix: AdminLTE sidebar z-index (1100) > Bootstrap modal z-index (1050)
   Raise backdrop above sidebar, raise modal above backdrop */
.modal-backdrop {
    z-index: 1110 !important;
}

.modal {
    z-index: 1120 !important;
}

/* On mobile: modal takes full width, not offset by sidebar */
@media (max-width: 991.98px) {
    .modal-dialog {
        margin: 1rem auto !important;
        max-width: calc(100vw - 2rem) !important;
    }

    .modal-dialog.modal-lg,
    .modal-dialog.modal-xl {
        max-width: calc(100vw - 2rem) !important;
    }
}

/* Modal Enhancements */
.modal-content {
    border: none !important;
    border-radius: 18px !important;
    box-shadow: 0 10px 40px rgba(0,0,0,0.12) !important;
}

.modal-header {
    border-bottom: 1px solid #f1f5f9 !important;
    padding: 1.2rem 1.5rem !important;
}

.modal-title {
    font-weight: 700 !important;
    font-family: 'Outfit', sans-serif !important;
    color: #1e293b !important;
    font-size: 1.25rem !important;
}

.modal-body {
    padding: 1.25rem 1.5rem !important;
}

.modal-footer {
    border-top: 1px solid #f1f5f9 !important;
    padding: 1rem 1.5rem !important;
}

.btn-modal-close {
    background-color: #f1f5f9 !important;
    color: #475569 !important;
    border: none !important;
    border-radius: 10px !important;
    padding: 0.6rem 1.5rem !important;
    font-weight: 600 !important;
    font-size: 0.9rem !important;
    transition: all 0.3s ease !important;
    cursor: pointer;
}

.btn-modal-close:hover {
    background-color: #e2e8f0 !important;
    color: #1e293b !important;
}

.modal label {
    font-weight: 600 !important;
    color: #475569 !important;
    font-size: 0.9rem !important;
    margin-bottom: 0.5rem !important;
}

/* Bootstrap Pagination Gap Fix */
.pagination .page-item:first-child .page-link {
    margin-right: 20px !important;
    border-radius: 8px !important;
    width: 80px !important;
}

.pagination .page-item:last-child .page-link {
    margin-left: 20px !important;
    border-radius: 8px !important;
    width: 80px !important;
}

.pagination .page-item .page-link {
    margin: 0 3px !important;
    border: none !important;
    background: #f1f5f9 !important;
    color: #475569 !important;
    width: 34px !important;
    height: 34px !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    border-radius: 8px !important;
    transition: all 0.3s ease;
}

.pagination .page-item.active .page-link {
    background: linear-gradient(90deg, #FF8331 0%, #F05123 100%) !important;
    color: #fff !important;
    box-shadow: 0 4px 12px rgba(240, 81, 35, 0.25) !important;
}
div.dataTables_wrapper div.dataTables_paginate
{
    margin-right: 15px !important;
}

@media (max-width: 768px) {
    div.dataTables_wrapper div.dataTables_paginate
    {
        margin-right: 0px !important;
    }
}

/* Premium Admin Button */
.admin-btn {
    background: linear-gradient(90deg, #FF8331 0%, #F05123 100%) !important;
    color: #fff !important;
    border: none !important;
    border-radius: 10px !important;
    padding: 0.65rem 1.5rem !important;
    font-weight: 600 !important;
    font-size: 0.9rem !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    transition: all 0.3s ease !important;
    box-shadow: 0 4px 12px rgba(240, 81, 35, 0.3) !important;
    cursor: pointer !important;
}

.admin-btn:hover {
    background: linear-gradient(90deg, #F05123 0%, #FF8331 100%) !important;
    color: #fff !important;
    transform: translateY(-2px);
    box-shadow: 0 6px 15px rgba(240, 81, 35, 0.5) !important;
}

.admin-btn:active {
    transform: translateY(0);
}

.admin-btn i {
    margin-right: 8px;
    font-size: 0.95rem;
}

.admin-btn-secondary {
    background-color: #fff !important;
    color: #ec6c25 !important;
    border: 1px solid #ec6c25 !important;
    border-radius: 10px !important;
    padding: 0.6rem 1.4rem !important;
    font-weight: 600 !important;
    font-size: 0.88rem !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    transition: all 0.3s ease !important;
    cursor: pointer !important;
}

.admin-btn-secondary:hover {
    background-color: rgba(236, 108, 37, 0.05) !important;
    box-shadow: 0 4px 10px rgba(236, 108, 37, 0.1) !important;
    transform: translateY(-1px);
}

/* User Info List in Modals */
.user-info-list {
    background: #fdfdfd;
    border: 1px solid #f1f5f9;
    border-radius: 15px;
    padding: 10px;
}

.info-item {
    padding: 12px 15px;
    border-bottom: 1px solid #f1f5f9;
    transition: all 0.2s ease;
    border-radius: 10px;
}

.info-item:last-child {
    border-bottom: none;
}

.info-item:hover {
    background: #f8fafc;
}

.info-icon {
    min-width: 42px;
    height: 42px;
    background: rgba(236, 108, 37, 0.08);
    color: #ec6c25;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.1rem;
}

.info-content label {
    margin-bottom: 2px !important;
    display: block;
    letter-spacing: 0.03em;
    font-size: 0.7rem !important;
}

.info-text {
    font-size: 0.95rem;
    color: #1e293b;
    word-break: break-all;
}

/* Dashboard Stat Cards */
.stat-card {
    background: #fff;
    border-radius: 20px;
    padding: 1.5rem;
    display: flex;
    align-items: center;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    border: 1px solid rgba(241, 245, 249, 0.8);
    position: relative;
    overflow: hidden;
    /* margin-bottom: 1.5rem; */
    text-decoration: none !important;
}

.stat-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 12px 25px rgba(0, 0, 0, 0.08);
}

.stat-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 4px;
    height: 100%;
    background: linear-gradient(to bottom, #FF8331, #F05123);
    border-radius: 4px 0 0 4px;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.stat-card:hover::before {
    opacity: 1;
}

.stat-icon {
    width: 55px;
    height: 55px;
    background: linear-gradient(135deg, rgba(255, 131, 49, 0.1) 0%, rgba(240, 81, 35, 0.1) 100%);
    color: #ec6c25;
    border-radius: 15px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.4rem;
    margin-right: 1.25rem;
    transition: all 0.3s ease;
}

.stat-card:hover .stat-icon {
    background: linear-gradient(135deg, #FF8331 0%, #F05123 100%);
    color: #fff;
    transform: rotate(-5deg) scale(1.1);
}

.stat-info .stat-label {
    display: block;
    color: #64748b;
    font-size: 0.85rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 4px;
}

.stat-info .stat-value {
    display: block;
    color: #1e293b;
    font-size: 1.5rem;
    font-weight: 800;
    font-family: 'Outfit', sans-serif;
    line-height: 1;
}

.dashboard-welcome {
    margin-bottom: 2rem;
}

.dashboard-welcome h2 {
    font-weight: 800;
    color: #1e293b;
    margin-bottom: 0.5rem;
}

.dashboard-welcome p {
    color: #64748b;
    font-size: 1rem;
}

.btn-modal-close:focus,
button:focus {
    outline: none !important;
}

/* Course Management Specific Styles */
.badge-soft-orange {
    background-color: rgba(236, 108, 37, 0.1) !important;
    color: #ec6c25 !important;
    border: 1px solid rgba(236, 108, 37, 0.2) !important;
}

.badge-soft-success {
    background-color: rgba(40, 167, 69, 0.1) !important;
    color: #28a745 !important;
    border: 1px solid rgba(40, 167, 69, 0.2) !important;
}

/* ══════════════════════════════════════════
   Select2 — Orange Premium Theme (Global)
   ══════════════════════════════════════════ */

/* Single select — closed box */
.select2-container--default .select2-selection--single {
    height: auto !important;
    min-height: 38px !important;
    border: 1.5px solid #e2e8f0 !important;
    border-radius: 10px !important;
    background-color: #f8fafc !important;
    padding: 0 !important;
    transition: border-color 0.2s ease, box-shadow 0.2s ease !important;
}

.select2-container--default .select2-selection--single .select2-selection__rendered {
    color: #2d3748 !important;
    line-height: 36px !important;
    padding-left: 12px !important;
    padding-right: 36px !important;
    font-size: 0.9rem !important;
    padding-top: 3px !important;
}

/* Custom orange arrow */
.select2-container--default .select2-selection--single .select2-selection__arrow {
    height: 36px !important;
    width: 32px !important;
    right: 6px !important;
}

.select2-container--default .select2-selection--single .select2-selection__arrow b {
    border-color: #ec6c25 transparent transparent transparent !important;
    border-width: 6px 5px 0 5px !important;
    margin-top: -3px !important;
}

.select2-container--default.select2-container--open .select2-selection--single .select2-selection__arrow b {
    border-color: transparent transparent #ec6c25 transparent !important;
    border-width: 0 5px 6px 5px !important;
}

/* Focus state */
.select2-container--default.select2-container--focus .select2-selection--single,
.select2-container--default.select2-container--open .select2-selection--single {
    border-color: #ec6c25 !important;
    background-color: #fff !important;
    box-shadow: 0 0 0 3px rgba(236, 108, 37, 0.12) !important;
    outline: none !important;
}

/* Dropdown panel */
.select2-dropdown {
    border: 1.5px solid #e2e8f0 !important;
    /* border-bottom-left-radius: 10px !important;
    border-bottom-right-radius: 10px !important; */
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12) !important;
    background: #fff !important;
    overflow: hidden !important;
    z-index: 9999 !important;
}
.select2-dropdown--below {
    border-bottom-left-radius: 10px !important;
    border-bottom-right-radius: 10px !important;
}

.select2-dropdown--above {
    border-top-left-radius: 10px !important;
    border-top-right-radius: 10px !important;
}
/* Dropdown opens BELOW — seamless join */
.select2-container--default.select2-container--open.select2-container--below .select2-selection--single {
    border-bottom-left-radius: 0 !important;
    border-bottom-right-radius: 0 !important;
    border-bottom-color: #ec6c25 !important;
}

.select2-container--default.select2-container--open.select2-container--below .select2-dropdown {
    border-top: none !important;
    border-top-left-radius: 0 !important;
    border-top-right-radius: 0 !important;
    border-bottom-left-radius: 10px !important;
    border-bottom-right-radius: 10px !important;
    margin-top: 0 !important;
}

/* Dropdown opens ABOVE — seamless join */
.select2-container--default.select2-container--open.select2-container--above .select2-selection--single {
    border-top-left-radius: 0 !important;
    border-top-right-radius: 0 !important;
    border-top-color: #ec6c25 !important;
}

.select2-container--default.select2-container--open.select2-container--above .select2-dropdown {
    border-bottom: none !important;
    border-bottom-left-radius: 0 !important;
    border-bottom-right-radius: 0 !important;
    border-top-left-radius: 10px !important;
    border-top-right-radius: 10px !important;
    margin-bottom: 0 !important;
}

/* Dropdown options */
.select2-results__options {
    padding: 4px !important;
    max-height: 220px !important;
}

.select2-results__option {
    padding: 8px 12px !important;
    border-radius: 7px !important;
    font-size: 0.88rem !important;
    color: #374151 !important;
    transition: background 0.15s ease, color 0.15s ease !important;
    cursor: pointer !important;
}

/* Hover */
.select2-container--default .select2-results__option--highlighted[aria-selected] {
    background-color: rgba(236, 108, 37, 0.1) !important;
    color: #ec6c25 !important;
}

/* Selected active option */
.select2-container--default .select2-results__option[aria-selected="true"] {
    background-color: #ec6c25 !important;
    color: #fff !important;
    font-weight: 600 !important;
}

/* Search box inside dropdown (if present) */
.select2-search--dropdown {
    padding: 8px !important;
    border-bottom: 1px solid #f1f5f9 !important;
}

.select2-search--dropdown .select2-search__field {
    border: 1.5px solid #e2e8f0 !important;
    border-radius: 8px !important;
    padding: 6px 10px !important;
    font-size: 0.875rem !important;
    outline: none !important;
}

.select2-search--dropdown .select2-search__field:focus {
    border-color: #ec6c25 !important;
    box-shadow: 0 0 0 3px rgba(236, 108, 37, 0.1) !important;
}

/* "No results" message */
.select2-results__option.select2-results__message {
    color: #94a3b8 !important;
    font-style: italic !important;
    text-align: center !important;
    padding: 12px !important;
}

/* ── Multi select ── */
.select2-container--default .select2-selection--multiple {
    min-height: calc(2.25rem + 2px);
    border: 1.5px solid #e2e8f0 !important;
    border-radius: 10px !important;
    background-color: #f8fafc !important;
    padding: 3px 6px !important;
}

.select2-container--default.select2-container--focus .select2-selection--multiple {
    border-color: #ec6c25 !important;
    box-shadow: 0 0 0 3px rgba(236, 108, 37, 0.12) !important;
}

.select2-container--default .select2-selection--multiple .select2-selection__choice {
    background: #fff3eb !important;
    border: 1px solid #f8c9a8 !important;
    color: #c05621 !important;
    border-radius: 6px !important;
    padding: 2px 8px !important;
    margin-top: 5px !important;
    font-size: 0.82rem !important;
    font-weight: 500 !important;
}

.select2-container--default .select2-selection--multiple .select2-selection__choice__remove {
    color: #ec6c25 !important;
    margin-right: 5px !important;
    font-weight: 700 !important;
}

.track-assign-table td,
.track-assign-table th {
    vertical-align: middle !important;
}

.track-assign-card {
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    padding: 15px;
    background: #fff;
}

.drag-handle {
    cursor: move;
}

.track-thumb {
    width: 60px;
    height: 45px;
    object-fit: cover;
    border-radius: 8px;
    border: 1px solid #e2e8f0;
}

.assign-loader {
    display: none;
    padding: 14px 0;
}

#datatable_course td {
    vertical-align: middle !important;
}

.assigned-scroll {
    max-height: 420px;
    overflow-y: auto;
}

.message {
    text-align: left;
    padding-left: 30px;
}

/* ================================================
   Discount Coupons — Modal Input Group Fixes
   ================================================ */

/* Hide number input spinners */
input::-webkit-outer-spin-button,
input::-webkit-inner-spin-button {
    -webkit-appearance: none;
    margin: 0;
}
input[type=number] {
    -moz-appearance: textfield;
    appearance: textfield;
}

/* Input with append suffix: left side gets left-radius, no right-radius */
.input-group .form-control:not(:last-child) {
    border-radius: 10px 0 0 10px !important;
}

/* Input with no append: keep full radius */
.input-group .form-control:last-child {
    border-radius: 0 10px 10px 0 !important;
}

/* Append text badges (%, calendar icon, etc.) */
.input-group-append .input-group-text {
    border-radius: 0 10px 10px 0 !important;
    background: #f8fafc !important;
    border: 1px solid #e2e8f0 !important;
    border-left: none !important;
    color: #64748b !important;
    font-weight: 600;
}

/* ── Settings / Profile Page ── */

.settings-section-header {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-size: 0.78rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.07em;
    color: #F05123;
    background: rgba(240, 81, 35, 0.07);
    border: 1px solid rgba(240, 81, 35, 0.18);
    border-radius: 7px;
    padding: 6px 14px;
}

.settings-label {
    font-size: 0.82rem;
    font-weight: 600;
    color: #374151;
    margin-bottom: 6px;
    display: block;
}

.settings-input {
    border-radius: 8px !important;
    border: 1.5px solid #e2e8f0 !important;
    padding: 9px 13px !important;
    font-size: 0.875rem !important;
    color: #1e293b !important;
    background: #fafbfc !important;
    transition: border-color 0.2s, box-shadow 0.2s;
}

.settings-input:focus {
    border-color: #F05123 !important;
    box-shadow: 0 0 0 3px rgba(240, 81, 35, 0.1) !important;
    background: #fff !important;
}

.input-group .settings-input { border-radius: 8px 0 0 8px !important; }

.input-group-append .input-group-text {
    border-radius: 0 8px 8px 0 !important;
    border: 1.5px solid #e2e8f0 !important;
    border-left: none !important;
}

.smtp-hint {
    font-size: 0.78rem;
    color: #64748b;
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-left: 3px solid #F05123;
    border-radius: 6px;
    padding: 10px 14px;
    line-height: 1.5;
}

.smtp-hint i { color: #F05123; }

/* ── Admin Profile Avatar ── */

.profile-hero {
    background: linear-gradient(135deg, rgba(255, 131, 49, 0.06) 0%, rgba(240, 81, 35, 0.04) 100%);
    border: 1px solid rgba(240, 81, 35, 0.12);
    border-radius: 12px;
    padding: 20px 22px;
}

.avatar-wrap {
    display: flex;
    align-items: center;
    gap: 20px;
}

.avatar-img-box {
    position: relative;
    flex-shrink: 0;
}

.avatar-photo {
    width: 84px;
    height: 84px;
    border-radius: 50%;
    object-fit: cover;
    border: 3px solid #fff;
    box-shadow: 0 4px 16px rgba(240, 81, 35, 0.2);
}

.avatar-camera-btn {
    position: absolute;
    bottom: 2px;
    right: 2px;
    width: 26px;
    height: 26px;
    background: linear-gradient(135deg, #FF8331, #F05123);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    color: #fff;
    font-size: 11px;
    box-shadow: 0 2px 8px rgba(240, 81, 35, 0.35);
    transition: transform 0.2s;
}

.avatar-camera-btn:hover { transform: scale(1.1); }

.avatar-name {
    font-size: 16px;
    font-weight: 700;
    color: #1e293b;
    line-height: 1.3;
}

.avatar-username {
    font-size: 13px;
    color: #F05123;
    font-weight: 600;
    margin-top: 2px;
}

.avatar-email {
    font-size: 12px;
    color: #64748b;
    margin-top: 2px;
}

/* Auto-generate gradient button */
.btn-auto-generate {
    background: linear-gradient(90deg, #FF8331, #F05123) !important;
    color: #fff !important;
    border: none !important;
    padding: 0 1.1rem !important;
    font-weight: 600 !important;
    font-size: 0.82rem !important;
    border-radius: 0 10px 10px 0 !important;
    cursor: pointer;
    white-space: nowrap;
    letter-spacing: 0.03em;
    transition: opacity 0.2s;
}
.btn-auto-generate:hover {
    opacity: 0.88;
}

/* ── SOS Management ── */
.sos-card {
    background: #fff;
    border: 1px solid #e2e8f0;
    border-radius: 14px;
    overflow: hidden;
    transition: box-shadow 0.25s, transform 0.25s;
    height: 100%;
}

.sos-card:hover {
    box-shadow: 0 8px 28px rgba(240, 81, 35, 0.1);
    transform: translateY(-3px);
}

.sos-card-top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    padding: 14px 16px 10px;
}

.sos-icon-badge {
    width: 38px;
    height: 38px;
    background: linear-gradient(135deg, rgba(255, 131, 49, 0.12), rgba(240, 81, 35, 0.12));
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 15px;
    color: #F05123;
    flex-shrink: 0;
}

.sos-title-text {
    font-size: 14px;
    font-weight: 700;
    color: #1e293b;
    flex: 1;
    line-height: 1.3;
    word-break: break-word;
}

.sos-card-actions {
    display: flex;
    gap: 4px;
    flex-shrink: 0;
}

.sos-player-wrap {
    padding: 0 12px 14px;
}

.sos-player-wrap video {
    width: 100%;
    border-radius: 10px;
    background: #0a0a0a;
    display: block;
    max-height: 160px;
}

.sos-empty {
    text-align: center;
    padding: 60px 20px;
    color: #64748b;
}

.sos-empty-icon {
    width: 72px;
    height: 72px;
    background: rgba(240, 81, 35, 0.07);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 28px;
    color: #F05123;
    margin: 0 auto 16px;
}

.sos-empty h5 { font-size: 16px; font-weight: 700; color: #1e293b; margin-bottom: 6px; }
.sos-empty p  { font-size: 13px; margin: 0; }

/* ── Track Reports — Period Toggle ── */
.period-toggle {
    display: inline-flex;
    background: #f1f5f9;
    border-radius: 10px;
    padding: 4px;
    gap: 3px;
}

.period-btn {
    border: none;
    background: transparent;
    color: #64748b;
    font-size: 0.82rem;
    font-weight: 600;
    padding: 7px 16px;
    border-radius: 7px;
    cursor: pointer;
    transition: all 0.2s ease;
    white-space: nowrap;
}

.period-btn:hover { background: rgba(240, 81, 35, 0.08); color: #F05123; }

.period-btn.active-period {
    background: linear-gradient(135deg, #FF8331, #F05123);
    color: #fff;
    box-shadow: 0 3px 10px rgba(240, 81, 35, 0.3);
}

/* ── Chart external legend ── */
.chart-legend-wrap {
    display: flex;
    flex-wrap: wrap;
    gap: 8px 16px;
    padding: 18px 4px 4px;
    border-top: 1px solid #f1f5f9;
    margin-top: 16px;
}

.chart-legend-item {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 12px;
    font-weight: 500;
    color: #374151;
    cursor: pointer;
    user-select: none;
    transition: opacity 0.2s;
}

.chart-legend-item:hover { opacity: 0.75; }

.chart-legend-item.chart-legend-disabled {
    opacity: 0.35;
}

.chart-legend-item.chart-legend-disabled .chart-legend-label {
    text-decoration: line-through;
}

.chart-legend-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    flex-shrink: 0;
}
.card-header::after
{
    display: none;
}

/* ══════════════════════════════════════════
   Course / Track Table — Tags & Category Cell
   ══════════════════════════════════════════ */

/* Tags/category columns — wrap all badges, no height limit */
.course-tags-cell .d-flex,
.course-cat-cell .d-flex {
    display: flex !important;
    flex-wrap: wrap !important;
    gap: 4px !important;
    align-content: flex-start !important;
}

/* Make individual badges smaller & compact */
.course-tags-cell .badge,
.course-cat-cell .badge {
    font-size: 0.7rem !important;
    padding: 3px 7px !important;
    white-space: nowrap !important;
    border-radius: 20px !important;
    line-height: 1.4 !important;
}

/* Course details column — prevent image+title from wrapping */
#datatable_course td:nth-child(2) .d-flex {
    flex-wrap: nowrap !important;
    align-items: center !important;
}

#datatable_course td:nth-child(2) img {
    flex-shrink: 0 !important;
    width: 56px !important;
    height: 42px !important;
    object-fit: cover !important;
}

#datatable_course td:nth-child(2) .font-weight-bold {
    white-space: normal !important;
    word-break: break-word !important;
    font-size: 0.875rem !important;
    line-height: 1.4 !important;
}

/* ══════════════════════════════════════════
   SweetAlert v1 — Premium Orange Theme
   ══════════════════════════════════════════ */

/* Overlay */
.sweet-overlay {
    background: rgba(15, 23, 42, 0.55) !important;
    backdrop-filter: blur(3px) !important;
}

/* Dialog box */
.sweet-alert {
    border-radius: 20px !important;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.15) !important;
    padding: 36px 32px 28px !important;
    font-family: 'Inter', sans-serif !important;
    max-width: 420px !important;
}

/* Title */
.sweet-alert h2 {
    font-family: 'Outfit', sans-serif !important;
    font-size: 1.5rem !important;
    font-weight: 800 !important;
    color: #1e293b !important;
    margin-bottom: 10px !important;
}

/* Message text */
.sweet-alert p {
    font-size: 0.92rem !important;
    color: #64748b !important;
    line-height: 1.6 !important;
}

/* ── Buttons ── */
.sweet-alert button {
    border-radius: 10px !important;
    font-family: 'Inter', sans-serif !important;
    font-size: 0.9rem !important;
    font-weight: 600 !important;
    padding: 10px 28px !important;
    letter-spacing: 0.02em !important;
    transition: all 0.25s ease !important;
    border: none !important;
    box-shadow: none !important;
}

/* Confirm button — orange gradient */
.sweet-alert button.confirm {
    background: linear-gradient(135deg, #FF8331 0%, #F05123 100%) !important;
    color: #fff !important;
    box-shadow: 0 4px 15px rgba(240, 81, 35, 0.35) !important;
}

.sweet-alert button.confirm:hover {
    background: linear-gradient(135deg, #e8722a 0%, #d94015 100%) !important;
    box-shadow: 0 6px 20px rgba(240, 81, 35, 0.45) !important;
    transform: translateY(-1px) !important;
}

.sweet-alert button.confirm:active {
    transform: translateY(0) !important;
}

/* Cancel button — neutral */
.sweet-alert button.cancel {
    background: #f1f5f9 !important;
    color: #475569 !important;
    box-shadow: none !important;
}

.sweet-alert button.cancel:hover {
    background: #e2e8f0 !important;
    color: #1e293b !important;
}

/* ── Warning icon — orange ── */
.sweet-alert .sa-icon.sa-warning {
    border-color: #ec6c25 !important;
}

.sweet-alert .sa-icon.sa-warning .sa-body,
.sweet-alert .sa-icon.sa-warning .sa-dot {
    background-color: #ec6c25 !important;
}

/* ── Success icon — green ── */
.sweet-alert .sa-icon.sa-success {
    border-color: #22c55e !important;
}

.sweet-alert .sa-icon.sa-success::before,
.sweet-alert .sa-icon.sa-success::after {
    background: #fff !important;
}

.sweet-alert .sa-icon.sa-success .sa-line {
    background-color: #22c55e !important;
}

/* ── Error icon — red ── */
.sweet-alert .sa-icon.sa-error {
    border-color: #ef4444 !important;
}

.sweet-alert .sa-icon.sa-error .sa-line {
    background-color: #ef4444 !important;
}

/* ── Info icon — blue ── */
.sweet-alert .sa-icon.sa-info {
    border-color: #3b82f6 !important;
    color: #3b82f6 !important;
}

.sweet-alert .sa-icon.sa-info::before,
.sweet-alert .sa-icon.sa-info::after {
    background-color: #3b82f6 !important;
}
