* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --primary-orange: #ff6600;
    --dark-orange:    #ff6600;
    --black:          #1a1a1a;
    --light-black:    #2d2d2d;
    --white:          #ffffff;
    --light-gray:     #f5f5f5;
    --gray:           #666;
}

/* ─────────────────────────────────────────────
   BASE
───────────────────────────────────────────── */
body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: #0a0a0a;
    min-height: 100vh;
    color: #e0e0e0;
}

/* ─────────────────────────────────────────────
   HEADER
───────────────────────────────────────────── */
.header {
    background: linear-gradient(90deg, #111111 0%, #1a1a1a 100%);
    padding: 0.5rem 0;
    position: sticky;
    top: 0;
    z-index: 1000;
    border-bottom: 2px solid #ff6600;
}

.header-content {
    max-width: 1400px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.75rem;
    padding: 0.75rem 2rem;
}

/* ── Logo row ── */
.logo-section {
    display: grid;
    grid-template-columns: auto 1fr auto;
    align-items: center;
    width: 100%;
    gap: 1rem;
}

.logo {
    width: 90px;
    height: 90px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid #ff6600;
}

.center-text {
    text-align: center;
}

.academy-name {
    font-size: 1.75rem;
    font-weight: 800;
    color: #ffffff;
    text-shadow: 1px 1px 4px rgba(0,0,0,.6);
    line-height: 1.3;
    margin: 0;
    letter-spacing: .5px;
}

.academy-subtext {
    color: #ff6600;
    font-size: 0.9rem;
    font-weight: 600;
    margin: 2px 0;
    letter-spacing: .3px;
}

/* ── Nav container ── */
.nav-container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    gap: 0.75rem;
}

.navbar {
    display: flex;
    gap: 0.4rem;
    flex-wrap: wrap;
    align-items: center;
}

.nav-link {
    padding: 0.5rem 0.9rem;
    background: #2a2a2a;
    color: #e0e0e0;
    text-decoration: none;
    border-radius: 6px;
    transition: all 0.25s ease;
    font-weight: 500;
    font-size: 0.875rem;
    border: 1px solid transparent;
    white-space: nowrap;
}

.nav-link:hover,
.nav-link.active {
    background: #ff6600;
    color: #ffffff;
    border-color: #ff6600;
    transform: translateY(-1px);
    box-shadow: 0 3px 8px rgba(255,102,0,.35);
}

/* ── Right side (Profile + Logout) ── */
.nav-right {
    display: flex;
    gap: 0.4rem;
    align-items: center;
    flex-shrink: 0;
}

.logout-btn {
    background: #dc3545;
    padding: 0.5rem 1rem;
    color: #ffffff;
    text-decoration: none;
    border-radius: 6px;
    transition: all 0.25s ease;
    font-weight: 500;
    font-size: 0.875rem;
    display: inline-block;
    white-space: nowrap;
    border: 1px solid transparent;
}

.logout-btn:hover {
    background: #c82333;
    transform: translateY(-1px);
    box-shadow: 0 3px 8px rgba(220,53,69,.35);
}

/* ── Hamburger toggle (mobile) ── */
.menu-toggle {
    display: none;
    background: #ff6600;
    border: none;
    color: #ffffff;
    font-size: 1.4rem;
    padding: 0.45rem 0.9rem;
    cursor: pointer;
    border-radius: 6px;
    transition: background .25s ease;
}

.menu-toggle:hover {
    background: #ff8533;
}

/* ─────────────────────────────────────────────
   FOOTER
───────────────────────────────────────────── */
.footer {
    background: #111111;
    text-align: center;
    padding: 1.25rem;
    margin-top: auto;
    border-top: 3px solid #ff6600;
    width: 100%;
}

.footer p    { color: #e0e0e0; font-size: 0.9rem; }
.footer span { color: #ff6600; font-weight: bold; }

/* ─────────────────────────────────────────────
   CONTAINER
───────────────────────────────────────────── */
.container {
    max-width: 1400px;
    margin: 2rem auto;
    padding: 0 2rem;
    min-height: calc(100vh - 250px);
}

/* ─────────────────────────────────────────────
   LOGIN PAGE
───────────────────────────────────────────── */
.login-wrapper {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 80vh;
    padding: 2rem;
}

.login-box {
    background: #1a1a1a;
    padding: 2.5rem;
    border-radius: 12px;
    box-shadow: 0 4px 16px rgba(0,0,0,.5);
    width: 100%;
    max-width: 440px;
    border: 2px solid #333;
}

.login-box h2 {
    text-align: center;
    color: #ff6600;
    margin-bottom: 1.5rem;
    font-size: 1.6rem;
    border-bottom: 3px solid #ff6600;
    padding-bottom: 0.65rem;
}

.login-logo { text-align: center; margin-bottom: 1rem; }
.login-logo img { width: 80px; height: 80px; }

/* ─────────────────────────────────────────────
   FORMS (shared)
───────────────────────────────────────────── */
.form-group {
    margin-bottom: 1.25rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    color: #e0e0e0;
    font-weight: 600;
    font-size: 0.875rem;
}

/* .form-control covers legacy pages; bare inputs covered below */
.form-control,
.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 0.75rem 1rem;
    border: 2px solid #333;
    border-radius: 8px;
    background: #2a2a2a;
    color: #e0e0e0;
    font-size: 0.9375rem;
    font-family: inherit;
    transition: border-color .25s ease, box-shadow .25s ease, background .25s ease;
    box-sizing: border-box;
}

.form-control:focus,
.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: #ff6600;
    box-shadow: 0 0 0 3px rgba(255,102,0,.2);
    background: #333;
}

.form-control:disabled,
.form-group input:disabled,
.form-group select:disabled {
    background: #1a1a1a;
    cursor: not-allowed;
    opacity: .6;
}

.form-control::placeholder,
.form-group input::placeholder { color: #555; }

select.form-control,
.form-group select { cursor: pointer; }

.form-group textarea { resize: vertical; }

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
}

/* readonly */
input[readonly] {
    background: #1a1a1a !important;
    cursor: not-allowed !important;
    color: #666 !important;
}

/* required asterisk */
.required { color: #ff4444; font-weight: bold; }

/* ─────────────────────────────────────────────
   BUTTONS
───────────────────────────────────────────── */
.btn {
    padding: 0.75rem 1.75rem;
    border: none;
    border-radius: 8px;
    font-size: 0.9375rem;
    font-weight: 600;
    font-family: inherit;
    cursor: pointer;
    transition: all .25s ease;
    text-decoration: none;
    display: inline-block;
    text-align: center;
}

.btn-primary {
    background: #ff6600;
    color: #ffffff;
    width: 100%;
}
.btn-primary:hover {
    background: #ff8533;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(255,102,0,.4);
}
.btn-primary:disabled {
    background: #555;
    cursor: not-allowed;
    opacity: .5;
    transform: none;
    box-shadow: none;
}

.btn-secondary {
    background: #2a2a2a;
    color: #e0e0e0;
    border: 2px solid #ff6600;
}
.btn-secondary:hover {
    background: #ff6600;
    color: #ffffff;
}

.btn-danger {
    background: #dc3545;
    color: #ffffff;
}
.btn-danger:hover { background: #c82333; }

.btn-login {
    width: 100%;
    padding: 0.8rem 1.75rem;
    border: none;
    border-radius: 8px;
    font-size: 0.9375rem;
    font-weight: 600;
    cursor: pointer;
    font-family: inherit;
    background: #ff6600;
    color: #ffffff;
    transition: all .25s ease;
    margin-top: 6px;
}
.btn-login:hover {
    background: #ff8533;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(255,102,0,.4);
}

.btn-filter {
    background: #ff6600;
    color: #ffffff;
    padding: 0.7rem 1.4rem;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-weight: 600;
    font-family: inherit;
    font-size: 0.875rem;
    transition: all .25s ease;
    display: inline-block;
    text-align: center;
    text-decoration: none;
}
.btn-filter:hover {
    background: #ff8533;
    transform: translateY(-1px);
}

.btn-clear {
    background: #555;
    color: #ffffff;
    padding: 0.7rem 1.4rem;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-weight: 600;
    font-family: inherit;
    font-size: 0.875rem;
    transition: all .25s ease;
    display: inline-block;
    text-align: center;
    text-decoration: none;
}
.btn-clear:hover { background: #666; }

.btn-export {
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
    color: #ffffff;
    padding: 0.65rem 1.25rem;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    font-weight: 600;
    font-size: 0.875rem;
    transition: all .25s ease;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    text-decoration: none;
}
.btn-export:hover {
    background: linear-gradient(135deg, #059669 0%, #047857 100%);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(16,185,129,.3);
}

/* ─────────────────────────────────────────────
   ALERTS
───────────────────────────────────────────── */
.alert {
    padding: 0.9rem 1rem;
    border-radius: 8px;
    margin-bottom: 1.25rem;
    border-left: 4px solid;
    font-size: 0.9rem;
    font-weight: 500;
}
.alert-success {
    background: #0f2a18;
    border-color: #198754;
    color: #75e6a0;
}
.alert-error {
    background: #2a1010;
    border-color: #dc3545;
    color: #ff7070;
}
.alert-info {
    background: #0f1e2a;
    border-color: #0d6efd;
    color: #6baed6;
}

/* branch-info-notice (used across all pages) */
.branch-info-notice {
    background: #2a2a2a;
    border-left: 4px solid #ff6600;
    padding: 14px 16px;
    margin-bottom: 20px;
    border-radius: 8px;
    color: #e0e0e0;
    font-size: 0.875rem;
}
.branch-info-notice strong { color: #ff6600; }

/* ─────────────────────────────────────────────
   DASHBOARD
───────────────────────────────────────────── */
.dashboard-header {
    background: #1a1a1a;
    border-radius: 12px;
    box-shadow: 0 4px 16px rgba(0,0,0,.5);
    padding: 28px;
    margin-bottom: 28px;
    border: 2px solid #333;
}
.dashboard-header h1 {
    color: #ff6600;
    font-size: 1.6rem;
    margin: 0 0 6px;
}
.dashboard-header p {
    color: #999;
    font-size: 0.875rem;
    margin: 0;
}

.dashboard-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 1.25rem;
    margin-bottom: 1.75rem;
}

.stat-card {
    background: #1a1a1a;
    padding: 1.5rem 1.25rem;
    border-radius: 12px;
    text-align: center;
    border: 2px solid #333;
    box-shadow: 0 4px 16px rgba(0,0,0,.5);
    transition: transform .2s ease, box-shadow .2s ease, border-color .2s ease;
}
.stat-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 24px rgba(0,0,0,.5);
    border-color: #ff6600;
}
.stat-card h3 {
    color: #ff6600;
    font-size: 2.2rem;
    font-weight: 800;
    margin: 0 0 6px;
}
.stat-card p {
    color: #999;
    font-size: 0.8rem;
    margin: 0;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: .5px;
}

/* ─────────────────────────────────────────────
   TABLES
───────────────────────────────────────────── */
.table-container {
    background: #1a1a1a;
    padding: 1.75rem;
    border-radius: 12px;
    border: 2px solid #333;
    box-shadow: 0 4px 16px rgba(0,0,0,.5);
    overflow-x: auto;
    margin-top: 1.5rem;
    margin-bottom: 1.75rem;
}
.table-container h2 {
    color: #ff6600;
    margin-bottom: 1.25rem;
    font-size: 1.4rem;
    border-bottom: 3px solid #ff6600;
    padding-bottom: 0.6rem;
}

.table-responsive { overflow-x: auto; }

.data-table,
.fee-table,
.report-table,
.exams-table {
    width: 100%;
    border-collapse: collapse;
    background: #1a1a1a;
}

.data-table thead,
.fee-table thead,
.report-table thead,
.exams-table thead {
    background: #ff6600;
    color: #ffffff;
}

.data-table th,
.fee-table th,
.report-table th,
.exams-table th {
    padding: 11px 14px;
    text-align: left;
    font-weight: 600;
    font-size: 0.8125rem;
    text-transform: uppercase;
    letter-spacing: .3px;
}

.data-table td,
.fee-table td,
.report-table td,
.exams-table td {
    padding: 11px 14px;
    border-bottom: 1px solid #2a2a2a;
    color: #e0e0e0;
    font-size: 0.875rem;
}

.data-table tbody tr:hover,
.fee-table tbody tr:hover,
.report-table tbody tr:hover,
.exams-table tbody tr:hover {
    background: #222;
}

.no-data {
    text-align: center !important;
    color: #555;
    font-style: italic;
    padding: 2rem !important;
}

/* Table header / info row */
.table-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
    flex-wrap: wrap;
    gap: 0.75rem;
}
.table-header h2 { color: #ff6600; margin: 0; }

.table-info {
    color: #e0e0e0;
    background: #2a2a2a;
    padding: 0.4rem 0.9rem;
    border-radius: 8px;
    font-size: 0.875rem;
    font-weight: 500;
}

/* ─────────────────────────────────────────────
   STUDENT PHOTOS
───────────────────────────────────────────── */
.student-photo-thumb {
    width: 46px;
    height: 46px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid #ff6600;
    cursor: pointer;
    transition: transform .25s ease;
    display: block;
}
.student-photo-thumb:hover { transform: scale(1.12); }

.no-photo {
    width: 46px;
    height: 46px;
    border-radius: 50%;
    background: #2a2a2a;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #555;
    font-size: 0.65rem;
    border: 2px solid #333;
    text-align: center;
    line-height: 1.2;
}

/* ─────────────────────────────────────────────
   MODAL (image viewer)
───────────────────────────────────────────── */
.modal {
    display: none;
    position: fixed;
    z-index: 9999;
    left: 0; top: 0;
    width: 100%; height: 100%;
    background-color: rgba(0,0,0,.88);
    justify-content: center;
    align-items: center;
}
.modal.show { display: flex; }

.modal-content {
    max-width: 90%;
    max-height: 88%;
    border-radius: 10px;
    border: 3px solid #ff6600;
}

.modal-close {
    position: absolute;
    top: 18px; right: 36px;
    color: #ffffff;
    font-size: 2.4rem;
    font-weight: bold;
    cursor: pointer;
    z-index: 10000;
    transition: color .2s ease;
}
.modal-close:hover { color: #ff6600; }

.modal-student-name {
    position: absolute;
    bottom: 28px;
    left: 50%;
    transform: translateX(-50%);
    color: #ffffff;
    background: rgba(0,0,0,.7);
    padding: 0.4rem 1.25rem;
    border-radius: 8px;
    font-size: 1.1rem;
    font-weight: bold;
}

/* ─────────────────────────────────────────────
   PROFILE
───────────────────────────────────────────── */
.profile-container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
}
.profile-card {
    background: #1a1a1a;
    padding: 1.75rem;
    border-radius: 12px;
    border: 2px solid #333;
    box-shadow: 0 4px 16px rgba(0,0,0,.5);
}
.profile-card h2 {
    color: #ff6600;
    margin-bottom: 1.25rem;
    border-bottom: 2px solid #ff6600;
    padding-bottom: 0.5rem;
    font-size: 1.25rem;
}

/* ─────────────────────────────────────────────
   REGISTRATION FORM
───────────────────────────────────────────── */
.registration-form {
    background: #1a1a1a;
    padding: 2rem;
    border-radius: 12px;
    border: 2px solid #333;
    box-shadow: 0 4px 16px rgba(0,0,0,.5);
}
.registration-form h2 {
    color: #ff6600;
    margin-bottom: 1.5rem;
    text-align: center;
    font-size: 1.5rem;
    border-bottom: 3px solid #ff6600;
    padding-bottom: 0.6rem;
}

/* Photo upload */
.photo-upload-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.75rem;
    padding: 1rem;
    background: #111;
    border: 2px dashed #ff6600;
    border-radius: 10px;
    text-align: center;
}
.photo-preview {
    width: 140px; height: 140px;
    border-radius: 50%; object-fit: cover;
    border: 3px solid #ff6600;
    display: none;
}
.photo-preview.show { display: block; }
.photo-upload-label {
    padding: 0.65rem 1.25rem;
    background: #ff6600;
    color: #ffffff;
    border-radius: 8px;
    cursor: pointer;
    transition: all .25s ease;
    font-weight: 500;
    font-size: 0.875rem;
}
.photo-upload-label:hover { background: #ff8533; transform: translateY(-1px); }
.photo-upload-input { display: none; }
.photo-info { color: #666; font-size: 0.8rem; }

/* ─────────────────────────────────────────────
   ATTENDANCE
───────────────────────────────────────────── */
.tab-navigation {
    display: flex;
    gap: 0.5rem;
    margin-bottom: 1.5rem;
    justify-content: center;
    flex-wrap: wrap;
}
.tab-btn {
    padding: 0.65rem 1.5rem;
    background: #1a1a1a;
    color: #e0e0e0;
    border: 2px solid #333;
    border-radius: 8px;
    cursor: pointer;
    font-size: 0.9rem;
    font-weight: 500;
    font-family: inherit;
    transition: all .25s ease;
}
.tab-btn:hover  { border-color: #ff6600; }
.tab-btn.active { background: #ff6600; border-color: #ff6600; color: #ffffff; }
.tab-content        { display: none; }
.tab-content.active { display: block; }

.attendance-filter {
    background: #1a1a1a;
    padding: 1.75rem;
    border-radius: 12px;
    border: 2px solid #333;
    box-shadow: 0 4px 16px rgba(0,0,0,.5);
    margin-bottom: 1.75rem;
}
.attendance-filter h2 {
    color: #ff6600;
    margin-bottom: 1.25rem;
    font-size: 1.4rem;
    border-bottom: 3px solid #ff6600;
    padding-bottom: 0.6rem;
}

.filter-form { max-width: 800px; margin: 0 auto; }

.attendance-form {
    background: #1a1a1a;
    padding: 1.75rem;
    border-radius: 12px;
    border: 2px solid #333;
}

.attendance-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 1.25rem;
    margin-top: 1rem;
}
.attendance-card {
    background: #111;
    padding: 1.25rem;
    border-radius: 10px;
    border: 2px solid #333;
    transition: all .25s ease;
}
.attendance-card:hover { border-color: #ff6600; transform: translateY(-2px); }

.student-info h4 { color: #ff6600; margin-bottom: 0.4rem; font-size: 1rem; }
.student-info p  { color: #e0e0e0; font-size: 0.85rem; margin: 0.25rem 0; }

.attendance-options {
    display: flex;
    gap: 0.75rem;
    margin-top: 0.9rem;
    justify-content: center;
}
.radio-label { cursor: pointer; display: flex; align-items: center; }
.radio-label input[type="radio"] { display: none; }
.radio-custom {
    padding: 0.6rem 1.25rem;
    border-radius: 8px;
    font-weight: bold;
    font-size: 0.875rem;
    transition: all .25s ease;
    border: 2px solid;
}
.radio-custom.present { background: rgba(40,167,69,.15); border-color: #28a745; color: #28a745; }
.radio-custom.absent  { background: rgba(220,53,69,.15); border-color: #dc3545; color: #dc3545; }
.radio-label input[type="radio"]:checked + .radio-custom.present {
    background: #28a745; color: #fff; box-shadow: 0 0 12px rgba(40,167,69,.4);
}
.radio-label input[type="radio"]:checked + .radio-custom.absent {
    background: #dc3545; color: #fff; box-shadow: 0 0 12px rgba(220,53,69,.4);
}

/* ─────────────────────────────────────────────
   FEE MANAGEMENT
───────────────────────────────────────────── */
.fee-header {
    background: #ff6600;
    padding: 1.5rem;
    border-radius: 12px;
    text-align: center;
    margin-bottom: 1.75rem;
}
.fee-header h1 { color: #ffffff; font-size: 1.4rem; margin: 0; }

.fee-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 1.25rem;
    margin-bottom: 1.75rem;
}
.fee-stat-card {
    background: #1a1a1a;
    padding: 1.4rem 1.25rem;
    border-radius: 12px;
    border: 2px solid #333;
    text-align: center;
    transition: transform .2s ease, border-color .2s ease;
    box-shadow: 0 4px 16px rgba(0,0,0,.5);
}
.fee-stat-card:hover { transform: translateY(-3px); border-color: #ff6600; }
.fee-stat-card h3 { font-size: 1.9rem; color: #ff6600; font-weight: 800; margin: 0 0 6px; }
.fee-stat-card p  { color: #999; font-size: 0.8125rem; margin: 0; }

.filter-section {
    background: #1a1a1a;
    padding: 1.75rem;
    border-radius: 12px;
    border: 2px solid #333;
    box-shadow: 0 4px 16px rgba(0,0,0,.5);
    margin-bottom: 1.75rem;
}
.filter-section h3 {
    color: #ff6600;
    margin-bottom: 1.25rem;
    font-size: 1.4rem;
    border-bottom: 3px solid #ff6600;
    padding-bottom: 0.6rem;
}
.filter-controls {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 0.9rem;
    align-items: end;
}

.fee-form-section {
    background: #1a1a1a;
    padding: 1.75rem;
    border-radius: 12px;
    border: 2px solid #333;
    box-shadow: 0 4px 16px rgba(0,0,0,.5);
    margin-bottom: 1.75rem;
}
.fee-form-section h3 {
    color: #ff6600;
    margin-bottom: 1.25rem;
    font-size: 1.4rem;
    border-bottom: 3px solid #ff6600;
    padding-bottom: 0.6rem;
}

.student-info-preview {
    background: #2a2a2a;
    border-left: 4px solid #ff6600;
    padding: 14px;
    border-radius: 8px;
    margin-bottom: 1rem;
    display: none;
    align-items: center;
    gap: 1rem;
}
.student-info-preview.show { display: flex; }

.student-preview-photo {
    width: 58px; height: 58px;
    border-radius: 50%; object-fit: cover;
    border: 2px solid #ff6600;
}
.student-preview-details h4 { color: #ff6600; margin: 0 0 3px; font-size: 0.9rem; }
.student-preview-details p  { color: #999; font-size: 0.8125rem; margin: 0; }

/* Fee record list items */
.fee-record-item {
    background: #111;
    padding: 1.25rem;
    border-radius: 10px;
    border: 2px solid #2a2a2a;
    margin-bottom: 0.75rem;
    display: flex;
    align-items: center;
    gap: 1.25rem;
    transition: all .25s ease;
}
.fee-record-item:hover { border-color: #ff6600; transform: translateX(4px); }

.fee-student-photo {
    width: 64px; height: 64px;
    border-radius: 50%; object-fit: cover;
    border: 3px solid #ff6600; flex-shrink: 0; cursor: pointer;
}
.fee-student-photo:hover { transform: scale(1.08); }

.no-photo-fee {
    width: 64px; height: 64px;
    border-radius: 50%;
    background: #2a2a2a;
    display: flex; align-items: center; justify-content: center;
    color: #555; font-size: 0.75rem;
    border: 3px solid #333; flex-shrink: 0; text-align: center;
}

.fee-record-details {
    flex: 1;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
    gap: 0.75rem;
}
.fee-detail-item { display: flex; flex-direction: column; }
.fee-detail-label { color: #555; font-size: 0.78rem; margin-bottom: 0.2rem; }
.fee-detail-value { color: #e0e0e0; font-weight: 500; font-size: 0.9rem; }
.fee-student-name { color: #ff6600; font-size: 1.1rem; font-weight: bold; }
.fee-amount       { color: #4ade80; font-size: 1.15rem; font-weight: bold; }

/* Status badges */
.status-badge {
    padding: 4px 11px;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 600;
    display: inline-block;
    text-transform: uppercase;
}
.status-paid    { background: #d4edda; color: #155724; }
.status-pending { background: #f8d7da; color: #721c24; }
.status-partial { background: #cfe2ff; color: #084298; }

/* ─────────────────────────────────────────────
   VIEW STUDENTS
───────────────────────────────────────────── */
.page-header {
    background: #ff6600;
    text-align: center;
    margin-bottom: 1.75rem;
    padding: 1.75rem;
    border-radius: 12px;
}
.page-header h1 { color: #ffffff; font-size: 1.4rem; margin: 0 0 4px; }
.page-header p  { color: rgba(255,255,255,.9); font-size: 0.95rem; margin: 0; }
.highlight-count { color: #ffffff; font-weight: bold; }

.filter-row {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 1.25rem;
    margin-bottom: 1.25rem;
}
.filter-group { display: flex; flex-direction: column; }
.filter-group label { color: #e0e0e0; font-weight: 500; margin-bottom: 0.4rem; font-size: 0.875rem; }
.filter-actions { display: flex; gap: 0.75rem; justify-content: center; flex-wrap: wrap; }

.blood-badge {
    display: inline-block; padding: 0.25rem 0.7rem;
    background: rgba(220,53,69,.15); color: #f87171;
    border: 1px solid #dc3545; border-radius: 20px;
    font-weight: 600; font-size: 0.78rem;
}
.branch-badge {
    display: inline-block; padding: 0.25rem 0.7rem;
    background: rgba(255,102,0,.15); color: #ff6600;
    border: 1px solid #ff6600; border-radius: 20px;
    font-weight: 600; font-size: 0.78rem;
}

.address-cell { max-width: 180px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.address-cell:hover { white-space: normal; overflow: visible; position: relative; z-index: 10; }

.no-results { text-align: center; padding: 3rem 2rem; background: #111; border-radius: 10px; }
.no-results-icon { font-size: 4rem; margin-bottom: 0.75rem; }
.no-results h3 { color: #ff6600; font-size: 1.6rem; margin-bottom: 0.75rem; }
.no-results p  { color: #999; font-size: 1rem; margin-bottom: 1.25rem; }

.data-table tbody tr { transition: background .2s ease; }

/* ─────────────────────────────────────────────
   BIRTHDAY / NOTIFICATION PAGE
───────────────────────────────────────────── */
.birthday-page-header {
    background: #ff6600;
    padding: 2rem;
    border-radius: 12px;
    text-align: center;
    margin-bottom: 1.75rem;
}
.birthday-page-header h1 { color: #ffffff; font-size: 1.5rem; margin: 0 0 4px; }
.birthday-page-header p  { color: rgba(255,255,255,.9); font-size: 1.05rem; margin: 0; }

.birthday-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 1.25rem;
    margin-bottom: 1.75rem;
}
.birthday-stat-card {
    background: #1a1a1a;
    padding: 1rem;
    border-radius: 12px;
    border: 2px solid #333;
    text-align: center;
    transition: all .25s ease;
}
.birthday-stat-card:hover { transform: translateY(-4px); border-color: #ff6600; }
.birthday-stat-card.today    { background: linear-gradient(135deg, #ff6600, #ff8533); border-color: #FFD700; }
.birthday-stat-card.tomorrow { background: linear-gradient(135deg, #667eea, #764ba2); border-color: #9D7BDB; }
.birthday-stat-card .stat-icon { font-size: 1.4rem; margin-bottom: 4px; }
.birthday-stat-card h3 { color: #ffffff; font-size: 1.4rem; margin-bottom: 4px; }
.birthday-stat-card p  { color: rgba(255,255,255,.9); font-size: 0.9rem; }

.birthday-calendar {
    background: #1a1a1a;
    padding: 1.75rem;
    border-radius: 12px;
    border: 2px solid #333;
    margin-bottom: 1.75rem;
    box-shadow: 0 4px 16px rgba(0,0,0,.5);
}
.birthday-calendar h2 {
    color: #ff6600;
    margin-bottom: 1.25rem;
    font-size: 1.4rem;
    border-bottom: 3px solid #ff6600;
    padding-bottom: 0.6rem;
}

.birthday-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px,1fr)); gap: 1.25rem; }

.birthday-item {
    background: #111;
    padding: 1.25rem;
    border-radius: 12px;
    border: 2px solid #2a2a2a;
    display: flex;
    gap: 1.25rem;
    transition: all .25s ease;
    position: relative;
}
.birthday-item:hover   { transform: translateY(-2px); border-color: #ff6600; }
.birthday-item.today   { background: linear-gradient(135deg, #ff6600, #ff8533); border-color: #FFD700; }
.birthday-item.tomorrow{ background: linear-gradient(135deg, #667eea, #764ba2); border-color: #9D7BDB; }
.birthday-item.passed  { opacity: .55; }

.birthday-date-badge {
    width: 64px; height: 64px;
    background: rgba(255,102,0,.15); border: 2px solid #ff6600;
    border-radius: 10px;
    display: flex; flex-direction: column; align-items: center; justify-content: center;
    flex-shrink: 0;
}
.birthday-item.today .birthday-date-badge,
.birthday-item.tomorrow .birthday-date-badge {
    background: rgba(255,255,255,.2); border-color: rgba(255,255,255,.5);
}
.birthday-date-badge .day   { font-size: 1.8rem; font-weight: bold; color: #ffffff; line-height: 1; }
.birthday-date-badge .month { font-size: 0.7rem; color: #ffffff; text-transform: uppercase; }

.birthday-photo {
    width: 64px; height: 64px;
    border-radius: 50%; overflow: hidden;
    border: 3px solid #ff6600; flex-shrink: 0;
}
.birthday-item.today .birthday-photo,
.birthday-item.tomorrow .birthday-photo { border-color: rgba(255,255,255,.8); }
.birthday-photo img { width: 100%; height: 100%; object-fit: cover; }
.birthday-no-photo {
    width: 100%; height: 100%;
    background: linear-gradient(135deg, #ff6600, #ff8533);
    display: flex; align-items: center; justify-content: center; font-size: 1.75rem;
}

.birthday-details { flex: 1; }
.birthday-details h4 { color: #ffffff; font-size: 1.05rem; margin: 0 0 0.4rem; }
.birthday-details p  { color: #777; font-size: 0.84rem; margin: 0.25rem 0; }
.birthday-item.today .birthday-details p,
.birthday-item.tomorrow .birthday-details p { color: rgba(255,255,255,.88); }

.birthday-status {
    position: absolute; top: 8px; right: 8px;
    padding: 0.25rem 0.65rem; border-radius: 20px; font-size: 0.7rem; font-weight: bold;
}
.status-today    { background: #FFD700; color: #1a1a1a; }
.status-tomorrow { background: #9D7BDB; color: #ffffff; }
.status-upcoming { background: rgba(40,167,69,.18); color: #4ade80; border: 1px solid #28a745; }
.status-passed   { background: rgba(108,117,125,.2); color: #6c757d; border: 1px solid #6c757d; }

/* Birthday popup */
.birthday-popup {
    display: none; position: fixed; z-index: 10000;
    left: 0; top: 0; width: 100%; height: 100%;
    background: rgba(0,0,0,.8);
}
.birthday-popup.show { display: flex; justify-content: center; align-items: center; }

.popup-content {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    padding: 2.5rem; border-radius: 16px;
    max-width: 580px; width: 92%; max-height: 80vh; overflow-y: auto;
    position: relative;
    box-shadow: 0 20px 60px rgba(0,0,0,.5);
    animation: slideUp .4s ease;
}
@keyframes slideUp {
    from { opacity: 0; transform: translateY(80px); }
    to   { opacity: 1; transform: translateY(0); }
}
.popup-close {
    position: absolute; top: 12px; right: 16px;
    font-size: 2.2rem; color: #ffffff; cursor: pointer;
    background: rgba(255,255,255,.18); width: 42px; height: 42px;
    border-radius: 50%; display: flex; align-items: center; justify-content: center;
    transition: all .25s ease;
}
.popup-close:hover { background: rgba(255,255,255,.3); transform: rotate(90deg); }

.popup-header { text-align: center; margin-bottom: 1.5rem; }
.popup-header h2 { color: #ffffff; font-size: 1.75rem; margin-bottom: 0.4rem; }
.popup-header .popup-icon { font-size: 3.5rem; }

.popup-student-list { display: flex; flex-direction: column; gap: 1.25rem; }
.popup-student-card {
    background: rgba(255,255,255,.94);
    padding: 1.25rem; border-radius: 12px;
    display: flex; align-items: center; gap: 1.25rem;
    box-shadow: 0 4px 14px rgba(0,0,0,.2);
}
.popup-student-photo {
    width: 74px; height: 74px; border-radius: 50%; overflow: hidden;
    border: 4px solid #ff6600; flex-shrink: 0;
}
.popup-student-photo img { width: 100%; height: 100%; object-fit: cover; }
.popup-student-info h4 { color: #1a1a1a; font-size: 1.15rem; margin: 0 0 0.4rem; }
.popup-student-info p  { color: #555; margin: 0.2rem 0; font-size: 0.875rem; }

.popup-actions { text-align: center; margin-top: 1.5rem; }
.popup-btn {
    background: #ffffff; color: #667eea;
    padding: 0.75rem 1.75rem; border: none; border-radius: 8px;
    font-weight: bold; cursor: pointer; font-family: inherit;
    transition: all .25s ease;
}
.popup-btn:hover { background: #ff6600; color: #ffffff; transform: translateY(-2px); }

.no-birthdays { text-align: center; padding: 3rem 2rem; background: #111; border-radius: 12px; }
.no-birthdays-icon { font-size: 4rem; margin-bottom: 0.75rem; opacity: .5; }
.no-birthdays h3 { color: #ff6600; font-size: 1.6rem; margin-bottom: 0.75rem; }
.no-birthdays p  { color: #777; font-size: 1rem; }

/* ─────────────────────────────────────────────
   RULES & REGULATIONS
───────────────────────────────────────────── */
.rules-section {
    background: #111;
    padding: 1.75rem;
    border-radius: 10px;
    border: 2px solid #ff6600;
    margin: 1.75rem 0;
}
.rules-section h3 {
    color: #ff6600;
    margin-bottom: 1.25rem;
    text-align: center;
    font-size: 1.3rem;
    border-bottom: 2px solid #ff6600;
    padding-bottom: 0.5rem;
}
.rules-content {
    background: #1a1a1a;
    padding: 1.25rem; border-radius: 8px;
    max-height: 380px; overflow-y: auto; margin-bottom: 1.25rem;
}
.rules-list { list-style: none; padding: 0; margin: 0; }
.rules-list li {
    color: #e0e0e0; padding: 0.7rem 0 0.7rem 1.4rem;
    border-bottom: 1px solid #2a2a2a; line-height: 1.6;
    position: relative;
}
.rules-list li:before { content: "✓"; position: absolute; left: 0; color: #ff6600; font-weight: bold; }
.rules-list li:last-child { border-bottom: none; }

.consent-checkbox { display: flex; justify-content: center; align-items: center; padding: 0.75rem; }
.checkbox-label { display: flex; align-items: center; cursor: pointer; gap: 0.75rem; }
.checkbox-label input[type="checkbox"] { width: 20px; height: 20px; cursor: pointer; accent-color: #ff6600; }
.checkbox-text { color: #e0e0e0; font-size: 0.95rem; font-weight: 500; user-select: none; }
.checkbox-label:hover .checkbox-text { color: #ff6600; }

.rules-content::-webkit-scrollbar { width: 7px; }
.rules-content::-webkit-scrollbar-track { background: #111; border-radius: 10px; }
.rules-content::-webkit-scrollbar-thumb { background: #ff6600; border-radius: 10px; }

/* ─────────────────────────────────────────────
   EXAM SECTION
───────────────────────────────────────────── */
.exam-form-container,
.scheduled-exams-container {
    background: #1a1a1a;
    border-radius: 12px;
    box-shadow: 0 4px 16px rgba(0,0,0,.5);
    padding: 28px;
    margin-bottom: 28px;
    border: 2px solid #333;
}
.exam-form-container h2,
.scheduled-exams-container h2 {
    color: #ff6600;
    margin-bottom: 1.25rem;
    font-size: 1.4rem;
    border-bottom: 3px solid #ff6600;
    padding-bottom: 0.6rem;
}

/* Belt badges */
.belt-badge {
    padding: 5px 13px; border-radius: 20px;
    font-size: 0.78rem; font-weight: 700;
    display: inline-block; text-transform: uppercase; letter-spacing: .4px;
}
.belt-white  { background: #f8f9fa; color: #495057; border: 2px solid #dee2e6; }
.belt-yellow { background: #fff3cd; color: #856404; border: 2px solid #ffc107; }
.belt-orange { background: #ffe5d0; color: #d63384; border: 2px solid #fd7e14; }
.belt-green  { background: #d1e7dd; color: #0f5132; border: 2px solid #198754; }
.belt-blue   { background: #cfe2ff; color: #084298; border: 2px solid #0d6efd; }
.belt-purple { background: #e0cffc; color: #6f42c1; border: 2px solid #6f42c1; }
.belt-brown  { background: #d4a373; color: #4a3023; border: 2px solid #8b4513; }
.belt-black  { background: #212529; color: #ffffff; border: 2px solid #000; font-weight: 800; }

/* Exam status badges */
.status-upcoming  { background: #fff3cd; color: #856404; }
.status-near      { background: #f8d7da; color: #721c24; }
.status-completed { background: #d4edda; color: #155724; }

/* Notification popup (exam) */
.notification-popup {
    display: none; position: fixed; z-index: 1000;
    left: 0; top: 0; width: 100%; height: 100%;
    background: rgba(0,0,0,.8);
}
.notification-popup .popup-content {
    background: #1a1a1a; margin: 5% auto; padding: 28px;
    border-radius: 12px; width: 92%; max-width: 580px;
    box-shadow: 0 5px 25px rgba(0,0,0,.5);
    border: 2px solid #333;
    animation: slideDown .3s ease;
}
@keyframes slideDown {
    from { transform: translateY(-50px); opacity: 0; }
    to   { transform: translateY(0); opacity: 1; }
}
.notification-popup .popup-content h3 {
    color: #ff6600; margin-bottom: 1.1rem;
    font-size: 1.3rem; border-bottom: 2px solid #ff6600; padding-bottom: 0.5rem;
}
.close-popup { color: #888; float: right; font-size: 2rem; font-weight: bold; cursor: pointer; line-height: 18px; }
.close-popup:hover { color: #ff6600; }
.notification-item {
    background: #2a2a2a; border-left: 4px solid #ff6600;
    padding: 13px; margin-bottom: 12px; border-radius: 6px;
}
.notification-item h4 { color: #ff6600; margin-bottom: 6px; font-size: 0.95rem; }
.notification-item p  { color: #e0e0e0; margin: 4px 0; font-size: 0.84rem; }

/* Action buttons in exam table */
.action-btns { display: flex; gap: 6px; }
.btn-action  { padding: 5px 11px; border: none; border-radius: 5px; font-size: 0.75rem; cursor: pointer; transition: all .25s ease; font-family: inherit; }
.btn-edit    { background: #ff6600; color: #ffffff; }
.btn-edit:hover   { background: #ff8533; }
.btn-delete  { background: #dc3545; color: #ffffff; }
.btn-delete:hover { background: #c82333; }

/* ─────────────────────────────────────────────
   CHARTS
───────────────────────────────────────────── */
.report-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 1.25rem;
    margin-bottom: 1.75rem;
}
.chart-container {
    display: grid;
    grid-template-columns: 1fr 2fr;
    gap: 1.5rem;
    margin-top: 1.5rem;
}
.chart-box {
    background: #1a1a1a;
    padding: 1.75rem;
    border-radius: 12px;
    border: 2px solid #333;
}
.chart-box h3 { color: #ff6600; margin-bottom: 1.25rem; text-align: center; font-size: 1.1rem; }
.chart-box canvas { max-height: 380px; }

/* ─────────────────────────────────────────────
   MODAL (edit forms)
───────────────────────────────────────────── */
.modal-dialog {
    display: flex; justify-content: center; align-items: center; min-height: 100vh; padding: 1.5rem;
}
.modal-content-custom {
    background: #1a1a1a;
    padding: 2rem;
    border-radius: 12px;
    border: 2px solid #333;
    max-width: 500px; width: 100%; position: relative;
}
.modal-content-custom .modal-close { position: absolute; top: 12px; right: 16px; font-size: 1.8rem; cursor: pointer; color: #e0e0e0; }
.modal-content-custom .modal-close:hover { color: #ff6600; }

/* ─────────────────────────────────────────────
   SCROLLBAR (global)
───────────────────────────────────────────── */
::-webkit-scrollbar { width: 7px; }
::-webkit-scrollbar-track { background: #111; }
::-webkit-scrollbar-thumb { background: #333; border-radius: 4px; }
::-webkit-scrollbar-thumb:hover { background: #ff6600; }
.table-responsive::-webkit-scrollbar { height: 7px; }
.table-responsive::-webkit-scrollbar-track { background: #1a1a1a; border-radius: 4px; }
.table-responsive::-webkit-scrollbar-thumb { background: #ff6600; border-radius: 4px; }

/* ─────────────────────────────────────────────
   RESPONSIVE — 1024px
───────────────────────────────────────────── */
@media (max-width: 1024px) {
    .profile-container  { grid-template-columns: 1fr; }
    .form-row           { grid-template-columns: 1fr; }
    .chart-container    { grid-template-columns: 1fr; }
    .filter-row         { grid-template-columns: repeat(2, 1fr); }
}

/* ─────────────────────────────────────────────
   RESPONSIVE — 768px
───────────────────────────────────────────── */
@media (max-width: 768px) {
    /* Header */
    .header-content { position: relative; padding: 0.75rem 1rem; }
    .academy-name   { font-size: 1.2rem; }
    .logo           { width: 54px; height: 54px; }
    .academy-subtext{ font-size: 0.78rem; }

    /* Nav */
    .nav-container { flex-direction: column; align-items: stretch; }
    .navbar {
        display: none; width: 100%;
        flex-direction: column; gap: 0.3rem;
    }
    .navbar.active  { display: flex; }
    .menu-toggle    {
        display: flex; align-items: center; justify-content: center;
        position: static; transform: none;
        width: 100%; margin-bottom: 0.3rem;
    }
    .nav-link       { width: 100%; text-align: center; font-size: 0.9rem; }
    .nav-right      { flex-direction: column; width: 100%; gap: 0.3rem; }
    .nav-right .nav-link,
    .nav-right .logout-btn { width: 100%; text-align: center; }

    /* Layout */
    .container          { padding: 0 1rem; }
    .table-container    { padding: 1rem; }
    .fee-form-section,
    .filter-section,
    .attendance-filter,
    .exam-form-container,
    .scheduled-exams-container { padding: 1.1rem; }

    .data-table th, .data-table td,
    .fee-table th,  .fee-table td  { padding: 0.5rem; font-size: 0.8rem; }

    /* Stats */
    .dashboard-stats  { grid-template-columns: 1fr 1fr; gap: 0.75rem; }
    .fee-stats        { grid-template-columns: 1fr 1fr; }
    .birthday-stats   { grid-template-columns: repeat(2, 1fr); }

    /* Misc */
    .fee-record-item    { flex-direction: column; text-align: center; }
    .fee-record-details { grid-template-columns: 1fr; }
    .filter-controls    { grid-template-columns: 1fr; }
    .attendance-grid    { grid-template-columns: 1fr; }
    .attendance-options { flex-direction: column; }
    .radio-custom       { text-align: center; width: 100%; }
    .birthday-grid      { grid-template-columns: 1fr; }
    .birthday-item      { flex-direction: column; text-align: center; }
    .filter-row         { grid-template-columns: 1fr; }
    .filter-actions     { flex-direction: column; }
    .btn-filter, .btn-clear, .btn-export { width: 100%; }
    .tab-btn            { flex: 1; min-width: 130px; }
    .popup-student-card { flex-direction: column; text-align: center; }
    .rules-section h3   { font-size: 1.05rem; }
    .rules-content      { max-height: 280px; padding: 0.9rem; }
    .rules-list li      { font-size: 0.84rem; padding: 0.55rem 0 0.55rem 1.3rem; }
    .checkbox-label     { flex-direction: column; text-align: center; gap: 0.4rem; }
    .checkbox-text      { font-size: 0.84rem; }
}

/* ─────────────────────────────────────────────
   RESPONSIVE — 480px
───────────────────────────────────────────── */
@media (max-width: 480px) {
    .academy-name       { font-size: 1rem; }
    .logo               { width: 42px; height: 42px; }
    .dashboard-stats    { grid-template-columns: 1fr 1fr; }
    .fee-stats          { grid-template-columns: 1fr 1fr; }
    .birthday-stats     { grid-template-columns: 1fr; }
    .login-box          { padding: 1.5rem; }
    .login-box h2       { font-size: 1.3rem; }
    .registration-form h2 { font-size: 1.25rem; }
    .birthday-page-header h1 { font-size: 1.25rem; }
    .no-results-icon    { font-size: 3rem; }
    .no-results h3      { font-size: 1.3rem; }
    .rules-content      { max-height: 240px; }
    .rules-list li      { font-size: 0.8rem; }
    .page-header h1     { font-size: 1.15rem; }
    .popup-header h2    { font-size: 1.35rem; }
    .popup-content      { padding: 1.5rem; width: 96%; }
}

/* ─────────────────────────────────────────────
   PRINT
───────────────────────────────────────────── */
@media print {
    .header, .footer, .menu-toggle,
    .nav-container, button, .btn,
    .filter-section, .fee-form-section,
    .attendance-filter, .exam-form-container { display: none !important; }

    body { background: #ffffff; color: #000000; }
    .data-table, .fee-table, .report-table, .exams-table { border: 1px solid #000; }
    .data-table th, .data-table td,
    .fee-table th,  .fee-table td,
    .report-table th, .report-table td { border: 1px solid #000; color: #000; }
}



