/* ============================================================
   GenZPre STUDENT THEME
   Brand palette: #323450 (deep indigo) + #FF0043 (vivid red)
   Applied globally to every student-facing page.
   ============================================================ */

:root {
    --brand-primary: #FF0043;
    --brand-primary-dark: #cc0036;
    --brand-primary-soft: #fff1f4;
    --brand-dark: #323450;
    --brand-dark-2: #26283d;
    --brand-dark-soft: #f6f7ff;
    --brand-border: #e2e8f0;
    --text-main: #1a1a2e;
    --text-muted: #64748b;
    --text-faint: #94a3b8;
}

body {
    color: var(--text-main);
}

h1, h2, h3, h4, h5, h6 {
    color: var(--text-main);
}

/* ------------------------------------------------------------
   SHARED PAGE HERO
   Apply .theme-hero to any student page top banner
   ------------------------------------------------------------ */
.theme-hero {
    background: linear-gradient(135deg, #323450 0%, #26283d 55%, #4a0e2a 100%);
    color: #fff;
    padding: 48px 0 40px;
    position: relative;
    overflow: hidden;
}
.theme-hero::after {
    content: "";
    position: absolute;
    right: -80px;
    top: -80px;
    width: 260px;
    height: 260px;
    border-radius: 50%;
    background: rgba(255, 0, 67, 0.22);
}
.theme-hero::before {
    content: "";
    position: absolute;
    left: -60px;
    bottom: -110px;
    width: 220px;
    height: 220px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.05);
}
.theme-hero > .container,
.theme-hero > div {
    position: relative;
    z-index: 1;
}
.theme-hero .hero-badge {
    background: #FF0043;
    color: #fff;
}
.theme-hero h1, .theme-hero .hero-title {
    color: #fff;
}
.theme-hero p, .theme-hero .hero-desc {
    color: rgba(255, 255, 255, 0.85);
}
.theme-hero a.back-link {
    color: rgba(255, 255, 255, 0.75);
    text-decoration: none;
    font-size: 13px;
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    margin-bottom: 14px;
}
.theme-hero a.back-link:hover {
    color: #fff;
}

/* ------------------------------------------------------------
   SECTION HEADINGS
   ------------------------------------------------------------ */
.theme-section-title {
    font-weight: 800;
    color: var(--text-main);
    position: relative;
    padding-left: 16px;
    margin-bottom: 24px;
}
.theme-section-title::before {
    content: "";
    position: absolute;
    left: 0;
    top: 4px;
    bottom: 4px;
    width: 5px;
    border-radius: 4px;
    background: linear-gradient(180deg, #FF0043, #ff6b91);
}

/* ------------------------------------------------------------
   CARDS
   ------------------------------------------------------------ */
.theme-card,
.stat-card,
.card-an,
.dpp-card,
.lb-table-card {
    background: #fff;
    border: 2px solid var(--brand-border);
    border-radius: 16px;
}
.stat-card {
    padding: 18px 20px;
    display: flex;
    align-items: center;
    gap: 14px;
}
.stat-card .h4, .stat-card .h5 {
    color: var(--text-main);
}
.stat-card small {
    color: var(--text-muted);
}

/* ------------------------------------------------------------
   BUTTONS
   ------------------------------------------------------------ */
.btn-theme,
.btn-dpp,
.btn-primary {
    background: var(--brand-primary);
    border-color: var(--brand-primary);
    color: #fff;
}
.btn-theme:hover,
.btn-dpp:hover,
.btn-primary:hover {
    background: var(--brand-primary-dark);
    border-color: var(--brand-primary-dark);
    color: #fff;
}
.btn-outline-theme,
.btn-outline-dpp {
    color: var(--brand-primary);
    border: 2px solid var(--brand-primary);
    background: transparent;
}
.btn-outline-theme:hover,
.btn-outline-dpp:hover {
    background: var(--brand-primary-soft);
    color: var(--brand-primary-dark);
}
a {
    color: inherit;
}
a:hover {
    color: var(--brand-primary);
}

/* ------------------------------------------------------------
   BADGES
   ------------------------------------------------------------ */
.badge.bg-primary, .badge-primary { background-color: var(--brand-primary) !important; }

/* ------------------------------------------------------------
   TABLES (plain + DataTables) — brand theme & responsive
   ------------------------------------------------------------ */
.table-responsive {
    border-radius: 14px;
    border: 2px solid var(--brand-border);
    background: #fff;
}

table.theme-table,
table.table,
table.dataTable {
    width: 100% !important;
    margin: 0;
    border-collapse: collapse;
}

table.theme-table thead th,
table.dataTable thead th,
.table thead th {
    background: var(--brand-dark);
    color: #fff;
    font-size: 12.5px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.6px;
    border: none;
    padding: 13px 16px;
    white-space: nowrap;
}
table.theme-table thead th:first-child,
table.dataTable thead th:first-child,
.table thead th:first-child {
    border-top-left-radius: 12px;
}
table.theme-table thead th:last-child,
table.dataTable thead th:last-child,
.table thead th:last-child {
    border-top-right-radius: 12px;
}
table.theme-table tbody td,
table.dataTable tbody td,
.table tbody td {
    padding: 12px 16px;
    font-size: 14px;
    vertical-align: middle;
    border-top: 1px solid #eef2f7;
}
table.theme-table tbody tr,
table.dataTable tbody tr,
.table tbody tr {
    transition: background 0.15s ease;
}
table.theme-table tbody tr:hover,
table.dataTable tbody tr:hover,
.table tbody tr:hover {
    background: var(--brand-dark-soft);
}
table.theme-table tbody tr:nth-of-type(even),
table.dataTable.display tbody > tr:nth-of-type(even) > .sorting_1 {
    background: #fbfcff;
}

/* DataTables specific */
table.dataTable.no-footer {
    border-bottom: 0;
}
table.dataTable tbody tr.child td.child {
    background: #fff;
    padding: 10px 16px;
}
table.dataTable > tbody > tr.child ul.dtr-details {
    width: 100%;
}
table.dataTable > tbody > tr.child ul.dtr-details > li {
    border-top: 1px solid #eef2f7;
    padding: 8px 4px;
    font-size: 13.5px;
}
table.dataTable > tbody > tr.child ul.dtr-details > li:first-child {
    border-top: 0;
}
table.dataTable > tbody > tr.child ul.dtr-details > li > span.dtr-title {
    font-weight: 700;
    color: var(--brand-dark);
    min-width: 130px;
    display: inline-block;
}

/* DataTables controls */
.dataTables_wrapper .dataTables_filter input,
.dataTables_wrapper .dataTables_length select {
    border: 1px solid var(--brand-border);
    border-radius: 8px;
    padding: 6px 10px;
    font-size: 14px;
    color: var(--text-main);
}
.dataTables_wrapper .dataTables_filter input:focus,
.dataTables_wrapper .dataTables_length select:focus {
    outline: none;
    border-color: var(--brand-primary);
    box-shadow: 0 0 0 3px rgba(255, 0, 67, 0.12);
}
.dataTables_wrapper .dataTables_filter label,
.dataTables_wrapper .dataTables_length label {
    font-weight: 500;
    color: var(--text-muted);
}
.dataTables_wrapper .dataTables_info {
    color: var(--text-muted);
    font-size: 13.5px;
    padding-top: 12px;
}

/* DataTables pagination */
.dataTables_wrapper .dataTables_paginate .paginate_button,
.page-item .page-link {
    border-radius: 8px !important;
    margin: 0 2px;
    color: var(--brand-dark);
    border: 1px solid var(--brand-border);
    font-size: 14px;
    padding: 6px 12px;
}
.dataTables_wrapper .dataTables_paginate .paginate_button:hover,
.page-item .page-link:hover {
    color: #fff;
    background: var(--brand-primary);
    border-color: var(--brand-primary);
}
.dataTables_wrapper .dataTables_paginate .paginate_button.current,
.page-item.active .page-link {
    background: var(--brand-primary) !important;
    border-color: var(--brand-primary) !important;
    color: #fff !important;
    font-weight: 700;
}
.dataTables_wrapper .dataTables_paginate .paginate_button.disabled,
.page-item.disabled .page-link {
    color: var(--text-faint) !important;
    background: #f8fafc !important;
}

/* Responsive control button */
table.dataTable.dtr-inline.collapsed > tbody > tr > td.dtr-control,
table.dataTable.dtr-inline.collapsed > tbody > tr > th.dtr-control {
    position: relative;
    padding-left: 34px;
}
table.dataTable.dtr-inline.collapsed > tbody > tr > td.dtr-control::before,
table.dataTable.dtr-inline.collapsed > tbody > tr > th.dtr-control::before {
    left: 10px;
    top: 50%;
    transform: translateY(-50%);
    width: 18px;
    height: 18px;
    line-height: 18px;
    text-align: center;
    font-size: 12px;
    border: none;
    background: var(--brand-dark);
    color: #fff;
    box-shadow: none;
}
table.dataTable.dtr-inline.collapsed > tbody > tr.parent > td.dtr-control::before,
table.dataTable.dtr-inline.collapsed > tbody > tr.parent > th.dtr-control::before {
    background: var(--brand-primary);
}

/* ------------------------------------------------------------
   LARAVEL PAGINATION
   ------------------------------------------------------------ */
.pagination {
    flex-wrap: wrap;
    justify-content: center;
    margin-top: 24px;
    gap: 4px;
}

/* ------------------------------------------------------------
   MOBILE — priority-first column behavior
   ------------------------------------------------------------ */
@media (max-width: 767.98px) {
    .theme-hero { padding: 34px 0 30px; }
    .theme-hero h1 { font-size: 24px; }
    .stat-card { padding: 14px 14px; }
    .stat-card .stat-icon { width: 40px; height: 40px; font-size: 16px; }

    table.theme-table thead th,
    table.dataTable thead th,
    .table thead th {
        padding: 10px 10px;
        font-size: 11.5px;
    }
    table.theme-table tbody td,
    table.dataTable tbody td,
    .table tbody td {
        padding: 9px 10px;
        font-size: 13px;
    }

    .dataTables_wrapper .dataTables_length,
    .dataTables_wrapper .dataTables_filter {
        text-align: left;
        width: 100%;
        margin-bottom: 10px;
    }
    .dataTables_wrapper .dataTables_length select,
    .dataTables_wrapper .dataTables_filter input {
        max-width: 140px;
    }
    .dataTables_wrapper .dataTables_paginate .paginate_button,
    .page-item .page-link {
        padding: 5px 9px;
        font-size: 13px;
    }
}
