@import url('https://fonts.googleapis.com/css2?family=Cinzel:wght@600;700;800;900&family=Inter:wght@400;500;600;700;800&family=Libre+Barcode+39&family=Libre+Barcode+39+Text&display=swap');

@font-face {
    font-family: "Stack Sans Headline Local";
    src:
        local("Stack Sans Headline"),
        local("StackSans Headline"),
        local("Stack Sans Headline Bold"),
        local("Stack Sans Headline Black");
    font-style: normal;
    font-weight: 700 900;
    font-display: swap;
}

:root {
    --bg: #f4f7fb;
    --panel: #ffffff;
    --panel-alt: #0e1930;
    --text: #172033;
    --muted: #60708f;
    --line: #d6deeb;
    --primary: #0d6efd;
    --primary-deep: #0a4fb3;
    --accent: #ffd76a;
    --success: #157347;
    --warning: #b96c00;
    --danger: #c9314b;
    --shadow: 0 20px 60px rgba(15, 23, 42, 0.08);
    --radius: 18px;
    --hero-surface:
        linear-gradient(135deg, rgba(255, 255, 255, 0.96) 0%, rgba(242, 248, 255, 0.98) 32%, rgba(227, 246, 255, 0.96) 66%, rgba(255, 247, 222, 0.94) 100%);
    --hero-highlight: linear-gradient(90deg, #0ea5e9 0%, #14b8a6 48%, #f6ad3c 100%);
    --hero-border: rgba(175, 201, 225, 0.96);
    --hero-shadow: 0 24px 58px rgba(15, 23, 42, 0.08);
    --panel-header-surface:
        linear-gradient(135deg, rgba(14, 165, 233, 0.09) 0%, rgba(52, 211, 153, 0.08) 52%, rgba(251, 191, 36, 0.12) 100%);
    --title-strong: #133b62;
    --title-accent: #0d769f;
    --title-soft: #5c718c;
    --module-hero-surface: var(--hero-surface);
    --module-hero-highlight: var(--hero-highlight);
    --module-hero-border: var(--hero-border);
    --module-hero-shadow: var(--hero-shadow);
    --module-hero-radial-top: rgba(56, 189, 248, 0.18);
    --module-hero-radial-bottom: rgba(251, 191, 36, 0.16);
    --module-title-strong: var(--title-strong);
    --module-title-soft: #58708b;
    --module-section-surface: linear-gradient(135deg, rgba(255, 255, 255, 0.96), rgba(244, 249, 255, 0.95), rgba(255, 248, 231, 0.92));
    --module-section-border: rgba(216, 228, 242, 0.98);
    font-family: "Inter", "Segoe UI", sans-serif;
}

.dashboard-body.module-academics {
    --module-hero-surface: linear-gradient(135deg, rgba(243, 250, 255, 0.98) 0%, rgba(233, 248, 247, 0.97) 52%, rgba(239, 253, 250, 0.95) 100%);
    --module-hero-highlight: linear-gradient(90deg, #0284c7 0%, #0f766e 52%, #14b8a6 100%);
    --module-hero-border: rgba(153, 221, 235, 0.92);
    --module-hero-shadow: 0 24px 56px rgba(8, 47, 73, 0.08);
    --module-hero-radial-top: rgba(56, 189, 248, 0.22);
    --module-hero-radial-bottom: rgba(45, 212, 191, 0.18);
    --module-title-strong: #0f3d63;
    --module-title-soft: #4f6c85;
    --module-section-surface: linear-gradient(135deg, rgba(249, 253, 255, 0.99), rgba(237, 252, 249, 0.96));
    --module-section-border: rgba(186, 230, 253, 0.9);
}

.dashboard-body.module-students {
    --module-hero-surface: linear-gradient(135deg, rgba(244, 245, 255, 0.98) 0%, rgba(235, 244, 255, 0.97) 48%, rgba(255, 246, 230, 0.95) 100%);
    --module-hero-highlight: linear-gradient(90deg, #4f46e5 0%, #0ea5e9 54%, #f59e0b 100%);
    --module-hero-border: rgba(196, 181, 253, 0.92);
    --module-hero-shadow: 0 24px 56px rgba(49, 46, 129, 0.08);
    --module-hero-radial-top: rgba(129, 140, 248, 0.2);
    --module-hero-radial-bottom: rgba(251, 191, 36, 0.18);
    --module-title-strong: #26367a;
    --module-title-soft: #5f6f97;
    --module-section-surface: linear-gradient(135deg, rgba(250, 250, 255, 0.99), rgba(239, 246, 255, 0.96));
    --module-section-border: rgba(199, 210, 254, 0.94);
}

.dashboard-body.module-examinations {
    --module-hero-surface: linear-gradient(135deg, rgba(255, 247, 248, 0.99) 0%, rgba(255, 241, 233, 0.97) 54%, rgba(255, 251, 235, 0.95) 100%);
    --module-hero-highlight: linear-gradient(90deg, #be123c 0%, #ea580c 54%, #d97706 100%);
    --module-hero-border: rgba(253, 164, 175, 0.88);
    --module-hero-shadow: 0 24px 56px rgba(127, 29, 29, 0.08);
    --module-hero-radial-top: rgba(251, 113, 133, 0.22);
    --module-hero-radial-bottom: rgba(245, 158, 11, 0.16);
    --module-title-strong: #7c2236;
    --module-title-soft: #8c6270;
    --module-section-surface: linear-gradient(135deg, rgba(255, 251, 252, 0.99), rgba(255, 245, 238, 0.96));
    --module-section-border: rgba(253, 205, 211, 0.92);
}

.dashboard-body.module-fees {
    --module-hero-surface: linear-gradient(135deg, rgba(239, 246, 255, 0.99) 0%, rgba(232, 244, 255, 0.97) 48%, rgba(236, 253, 245, 0.95) 100%);
    --module-hero-highlight: linear-gradient(90deg, #1d4ed8 0%, #0f766e 54%, #38bdf8 100%);
    --module-hero-border: rgba(147, 197, 253, 0.9);
    --module-hero-shadow: 0 24px 56px rgba(30, 64, 175, 0.08);
    --module-hero-radial-top: rgba(59, 130, 246, 0.2);
    --module-hero-radial-bottom: rgba(16, 185, 129, 0.16);
    --module-title-strong: #173b7a;
    --module-title-soft: #51709a;
    --module-section-surface: linear-gradient(135deg, rgba(248, 251, 255, 0.99), rgba(239, 253, 250, 0.96));
    --module-section-border: rgba(191, 219, 254, 0.94);
}

.dashboard-body.module-hr {
    --module-hero-surface: linear-gradient(135deg, rgba(246, 250, 255, 0.99) 0%, rgba(243, 244, 246, 0.97) 48%, rgba(255, 247, 237, 0.95) 100%);
    --module-hero-highlight: linear-gradient(90deg, #334155 0%, #0f766e 52%, #f97316 100%);
    --module-hero-border: rgba(203, 213, 225, 0.94);
    --module-hero-shadow: 0 24px 56px rgba(51, 65, 85, 0.08);
    --module-hero-radial-top: rgba(148, 163, 184, 0.2);
    --module-hero-radial-bottom: rgba(249, 115, 22, 0.14);
    --module-title-strong: #243447;
    --module-title-soft: #66768a;
    --module-section-surface: linear-gradient(135deg, rgba(250, 252, 255, 0.99), rgba(248, 250, 252, 0.96));
    --module-section-border: rgba(226, 232, 240, 0.96);
}

.dashboard-body.module-library {
    --module-hero-surface: linear-gradient(135deg, rgba(241, 247, 255, 0.99) 0%, rgba(236, 253, 245, 0.97) 52%, rgba(255, 251, 235, 0.95) 100%);
    --module-hero-highlight: linear-gradient(90deg, #1e40af 0%, #047857 54%, #ca8a04 100%);
    --module-hero-border: rgba(147, 197, 253, 0.88);
    --module-hero-shadow: 0 24px 56px rgba(30, 58, 138, 0.09);
    --module-hero-radial-top: rgba(59, 130, 246, 0.2);
    --module-hero-radial-bottom: rgba(16, 185, 129, 0.16);
    --module-title-strong: #183153;
    --module-title-soft: #5a6f80;
    --module-section-surface: linear-gradient(135deg, rgba(248, 251, 255, 0.99), rgba(240, 253, 244, 0.96));
    --module-section-border: rgba(186, 230, 253, 0.92);
}

.dashboard-body.module-transport {
    --module-hero-surface: linear-gradient(135deg, rgba(241, 249, 255, 0.99) 0%, rgba(232, 248, 255, 0.97) 48%, rgba(255, 248, 230, 0.95) 100%);
    --module-hero-highlight: linear-gradient(90deg, #0369a1 0%, #2563eb 52%, #f59e0b 100%);
    --module-hero-border: rgba(125, 211, 252, 0.9);
    --module-hero-shadow: 0 24px 56px rgba(3, 105, 161, 0.08);
    --module-hero-radial-top: rgba(14, 165, 233, 0.22);
    --module-hero-radial-bottom: rgba(251, 191, 36, 0.16);
    --module-title-strong: #11446c;
    --module-title-soft: #57758f;
    --module-section-surface: linear-gradient(135deg, rgba(249, 252, 255, 0.99), rgba(255, 251, 235, 0.96));
    --module-section-border: rgba(186, 230, 253, 0.92);
}

.dashboard-body.module-settings {
    --module-hero-surface: linear-gradient(135deg, rgba(248, 250, 252, 0.99) 0%, rgba(239, 246, 255, 0.97) 48%, rgba(236, 253, 245, 0.95) 100%);
    --module-hero-highlight: linear-gradient(90deg, #475569 0%, #0f766e 56%, #0891b2 100%);
    --module-hero-border: rgba(203, 213, 225, 0.96);
    --module-hero-shadow: 0 24px 56px rgba(71, 85, 105, 0.08);
    --module-hero-radial-top: rgba(148, 163, 184, 0.18);
    --module-hero-radial-bottom: rgba(20, 184, 166, 0.14);
    --module-title-strong: #304255;
    --module-title-soft: #68788b;
    --module-section-surface: linear-gradient(135deg, rgba(252, 253, 255, 0.99), rgba(240, 249, 255, 0.96));
    --module-section-border: rgba(226, 232, 240, 0.98);
}

.dashboard-body.module-profile {
    --module-hero-surface: linear-gradient(135deg, rgba(249, 245, 255, 0.99) 0%, rgba(255, 241, 242, 0.97) 48%, rgba(239, 246, 255, 0.95) 100%);
    --module-hero-highlight: linear-gradient(90deg, #7c3aed 0%, #db2777 54%, #2563eb 100%);
    --module-hero-border: rgba(216, 180, 254, 0.9);
    --module-hero-shadow: 0 24px 56px rgba(109, 40, 217, 0.08);
    --module-hero-radial-top: rgba(167, 139, 250, 0.2);
    --module-hero-radial-bottom: rgba(244, 114, 182, 0.14);
    --module-title-strong: #4c2f7f;
    --module-title-soft: #75628f;
    --module-section-surface: linear-gradient(135deg, rgba(252, 248, 255, 0.99), rgba(255, 245, 247, 0.96));
    --module-section-border: rgba(233, 213, 255, 0.94);
}

.dashboard-body.module-setup {
    --module-hero-surface: linear-gradient(135deg, rgba(240, 253, 244, 0.99) 0%, rgba(236, 253, 245, 0.97) 48%, rgba(255, 251, 235, 0.95) 100%);
    --module-hero-highlight: linear-gradient(90deg, #15803d 0%, #0ea5e9 52%, #d97706 100%);
    --module-hero-border: rgba(187, 247, 208, 0.94);
    --module-hero-shadow: 0 24px 56px rgba(21, 128, 61, 0.08);
    --module-hero-radial-top: rgba(74, 222, 128, 0.18);
    --module-hero-radial-bottom: rgba(251, 191, 36, 0.14);
    --module-title-strong: #185f38;
    --module-title-soft: #5b7a61;
    --module-section-surface: linear-gradient(135deg, rgba(247, 254, 250, 0.99), rgba(255, 251, 235, 0.96));
    --module-section-border: rgba(187, 247, 208, 0.92);
}

* {
    box-sizing: border-box;
}

html {
    font-size: 14px;
}

body {
    margin: 0;
    background:
        radial-gradient(circle at top left, rgba(13, 110, 253, 0.15), transparent 30%),
        radial-gradient(circle at top right, rgba(56, 189, 248, 0.1), transparent 24%),
        radial-gradient(circle at bottom left, rgba(255, 215, 106, 0.11), transparent 26%),
        linear-gradient(180deg, #f8fbff 0%, #f3f7fc 52%, #eef5fb 100%);
    color: var(--text);
    font-family: "Inter", "Segoe UI", sans-serif;
    font-size: 0.95rem;
    font-weight: 700;
    line-height: 1.45;
}

a {
    color: inherit;
    text-decoration: none;
}

input,
select,
textarea,
button,
table,
th,
td {
    font-family: inherit;
    font-weight: inherit;
}

.auth-body {
    min-height: 100vh;
    padding: 24px;
}

.auth-page {
    min-height: calc(100vh - 48px);
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 16px;
}

.auth-shell {
    width: min(1100px, 100%);
    display: grid;
    grid-template-columns: 1.1fr 1fr;
    background: rgba(255, 255, 255, 0.7);
    backdrop-filter: blur(12px);
    border-radius: 28px;
    overflow: hidden;
    box-shadow: var(--shadow);
}

.auth-brand {
    padding: 48px;
    background: linear-gradient(160deg, #0d1b34 0%, #17386b 100%);
    color: #fff;
}

.auth-brand h1 {
    margin: 16px 0 12px;
    font-size: clamp(2rem, 3vw, 3.2rem);
}

.auth-brand p {
    color: #d8e4ff;
    line-height: 1.6;
}

.auth-checklist {
    padding-left: 18px;
    line-height: 1.8;
    color: #e9efff;
}

.auth-card {
    padding: 36px;
    background: #fff;
}

.dashboard-shell {
    display: grid;
    grid-template-columns: 280px 1fr;
    min-height: 100vh;
}

.sidebar {
    padding: 28px 22px;
    background: linear-gradient(180deg, #0f1830 0%, #112347 100%);
    color: #dfe8ff;
}

.sidebar-top h2,
.topbar h1,
.section-header h2,
.section-header h3 {
    margin: 0;
}

.sidebar-top p,
.section-note,
.hint {
    color: var(--muted);
}

.sidebar-top p {
    color: #bdd0ff;
}

.sidebar-nav {
    margin-top: 28px;
    display: grid;
    gap: 8px;
}

.sidebar-nav a {
    padding: 12px 14px;
    border-radius: 12px;
    color: #edf3ff;
    transition: background 0.2s ease, transform 0.2s ease;
}

.sidebar-nav a:hover {
    background: rgba(255, 255, 255, 0.08);
    transform: translateX(4px);
}

.page-shell {
    padding: 28px;
    display: flex;
    flex-direction: column;
}

.topbar {
    display: flex;
    justify-content: space-between;
    align-items: start;
    gap: 16px;
    margin-bottom: 24px;
}

.topbar p {
    margin: 6px 0 0;
    color: var(--muted);
}

.topbar-actions {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.badge,
.brand-pill,
.eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    width: fit-content;
    border-radius: 999px;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    font-size: 0.72rem;
    font-weight: 700;
}

.brand-pill {
    padding: 8px 12px;
    background: rgba(255, 215, 106, 0.18);
    color: var(--accent);
}

.eyebrow {
    color: var(--primary-deep);
    margin-bottom: 8px;
}

.badge {
    padding: 8px 12px;
    background: #eaf2ff;
    color: var(--primary-deep);
}

.badge-ghost {
    background: #fff3d7;
    color: #8a5a00;
}

.alert {
    border-radius: 16px;
    padding: 14px 16px;
    margin-bottom: 18px;
    border: 1px solid transparent;
}

.alert-dismissible {
    display: flex;
    align-items: start;
    justify-content: space-between;
    gap: 12px;
}

.alert-close {
    width: 28px;
    height: 28px;
    flex: 0 0 28px;
    border: 0;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.5);
    color: inherit;
    font-size: 1.15rem;
    line-height: 1;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.alert-close:hover {
    background: rgba(255, 255, 255, 0.82);
}

.alert-success {
    background: #eaf7ef;
    border-color: #cbead5;
    color: var(--success);
}

.alert-error {
    background: #fff0f2;
    border-color: #ffd1d9;
    color: var(--danger);
}

.alert-warning {
    background: #fff7e8;
    border-color: #f4d6a1;
    color: var(--warning);
}

.section-header {
    position: relative;
    display: flex;
    justify-content: space-between;
    align-items: end;
    gap: 16px;
    margin-bottom: 18px;
    padding: 14px 18px 14px 20px;
    border: 1px solid var(--module-section-border);
    border-radius: 16px;
    background: var(--module-section-surface);
    box-shadow: 0 12px 32px rgba(15, 23, 42, 0.04);
}

.section-header::before {
    content: "";
    position: absolute;
    left: 0;
    top: 14px;
    bottom: 14px;
    width: 5px;
    border-radius: 999px;
    background: var(--module-hero-highlight);
}

.section-header.compact {
    margin-bottom: 12px;
}

.section-header h2,
.section-header h3 {
    color: var(--module-title-strong);
}

.section-header .section-note,
.section-header p {
    color: var(--module-title-soft);
}

.form-grid,
.stats-grid,
.module-grid {
    display: grid;
}

.form-grid {
    gap: 10px;
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.stats-grid {
    gap: 12px;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    margin-bottom: 22px;
}

.module-grid {
    gap: 12px;
    grid-template-columns: repeat(4, minmax(0, 1fr));
}

.field,
.stat-card,
.module-card,
.license-card,
.table-card {
    background: var(--panel);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
}

.field {
    padding: 0;
    border: 0;
    border-radius: 0;
    background: transparent;
    box-shadow: none;
}

.field-span-2 {
    grid-column: span 2;
}

.field-span-4 {
    grid-column: span 4;
}

.field label {
    display: block;
    font-weight: 600;
    margin-bottom: 4px;
    color: #334155;
    letter-spacing: 0.01em;
    font-size: 0.88rem;
}

.field input,
.field select,
.field textarea {
    width: 100%;
    border: 1px solid #d7e3f1;
    background: #ffffff;
    border-radius: 10px;
    padding: 10px 12px;
    font: inherit;
    color: #1b314f;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.75);
    transition: border-color 0.2s ease, box-shadow 0.2s ease, background 0.2s ease, transform 0.2s ease;
}

.field textarea {
    resize: vertical;
    min-height: 44px;
}

.field input::placeholder,
.field textarea::placeholder {
    color: #94a3b8;
}

.field input:focus,
.field select:focus,
.field textarea:focus {
    outline: none;
    border-color: #94a3b8;
    box-shadow: 0 0 0 3px rgba(148, 163, 184, 0.16);
    transform: none;
}

.button {
    border: 0;
    border-radius: 12px;
    padding: 12px 18px;
    font: inherit;
    font-weight: 700;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    transition: transform 0.18s ease, box-shadow 0.18s ease, background 0.18s ease, border-color 0.18s ease, color 0.18s ease;
}

.button-primary {
    background: linear-gradient(135deg, var(--primary), var(--primary-deep));
    color: #fff;
    box-shadow: 0 12px 24px rgba(13, 110, 253, 0.18);
}

.button-secondary {
    background: #eef4ff;
    color: var(--primary-deep);
}

.button-primary:hover {
    transform: translateY(-1px);
    box-shadow: 0 16px 30px rgba(13, 110, 253, 0.22);
}

.button-small {
    padding: 9px 14px;
    font-size: 0.85rem;
}

.button:disabled {
    cursor: not-allowed;
    opacity: 0.6;
    box-shadow: none;
}

.button:disabled:hover {
    transform: none;
}

.actions-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.text-link {
    color: var(--primary-deep);
    font-weight: 700;
}

.error-text {
    display: block;
    color: var(--danger);
    min-height: 18px;
    margin-top: 6px;
}

.hint {
    display: block;
    margin-top: 6px;
    font-weight: 500;
    color: #64748b;
}

.academic-inline-error {
    padding: 0 18px 18px;
    color: var(--danger);
    font-weight: 700;
}

.academic-filter-panel {
    margin: 0;
}

.academic-static-value {
    min-height: 48px;
    display: flex;
    align-items: center;
    padding: 12px 14px;
    border-radius: 12px;
    border: 1px solid #cfd8e3;
    background: #fff;
    color: #1f3147;
    font-weight: 600;
}

.academic-panel-empty {
    padding: 22px 18px;
}

.academic-chip-list {
    display: inline-block;
    color: #516a89;
    line-height: 1.6;
    overflow-wrap: anywhere;
}

.selection-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 14px;
    padding: 18px;
}

.selection-grid-subjects {
    grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
    align-items: stretch;
}

.selection-option {
    position: relative;
    display: grid;
    gap: 8px;
    padding: 16px;
    border: 1px solid #dbe5f2;
    border-radius: 12px;
    background: #fff;
    box-shadow: none;
    cursor: pointer;
    min-width: 0;
    align-content: start;
}

.selection-option:nth-child(3n + 1) {
    background: #fff;
    border-color: #dbe5f2;
}

.selection-option:nth-child(3n + 2) {
    background: #fff;
    border-color: #dbe5f2;
}

.selection-option:nth-child(3n + 3) {
    background: #fff;
    border-color: #dbe5f2;
}

.selection-option input {
    width: 18px;
    height: 18px;
    margin: 0;
}

.selection-option-title {
    display: block;
    color: #1f3147;
    font-weight: 600;
    overflow-wrap: anywhere;
}

.selection-option-meta {
    display: block;
    color: #64748b;
    font-size: 0.82rem;
    overflow-wrap: anywhere;
}

.academic-mark-input {
    width: 100%;
    min-width: 140px;
    border: 1px solid #cfd8e3;
    background: #fff;
    border-radius: 12px;
    padding: 11px 14px;
    font: inherit;
    color: #1f2937;
    box-shadow: none;
    transition: border-color 0.2s ease, box-shadow 0.2s ease, background 0.2s ease, transform 0.2s ease;
    appearance: textfield;
}

.academic-mark-input:focus {
    outline: none;
    border-color: #94a3b8;
    box-shadow: 0 0 0 3px rgba(148, 163, 184, 0.16);
    transform: none;
}

.academic-mark-input::-webkit-outer-spin-button,
.academic-mark-input::-webkit-inner-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

.data-table td .academic-mark-input + .error-text {
    min-height: 0;
    margin-top: 8px;
}

.captcha-wrap {
    display: flex;
    flex-direction: column;
    align-items: start;
    justify-content: end;
    gap: 10px;
}

.captcha-image {
    height: 48px;
    width: 150px;
    border-radius: 12px;
    border: 1px solid var(--line);
}

.stat-card {
    padding: 22px;
}

.stat-card span {
    color: var(--muted);
}

.stat-card strong {
    display: block;
    font-size: 2rem;
    margin-top: 8px;
}

.license-card {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 18px;
    padding: 22px;
    margin-bottom: 22px;
}

.license-meta {
    display: grid;
    gap: 10px;
    color: var(--muted);
}

.module-card {
    padding: 20px;
}

.module-card h3 {
    margin-top: 0;
    margin-bottom: 12px;
}

.module-card ul {
    margin: 0;
    padding-left: 18px;
    color: var(--muted);
    line-height: 1.7;
}

.table-card {
    overflow: hidden;
}

.otp-preview-card {
    background: #fff;
    border: 1px solid #dbe3ee;
    border-radius: 14px;
    padding: 16px 18px;
    margin-bottom: 14px;
}

.otp-preview-card strong {
    display: block;
    font-size: 2rem;
    letter-spacing: 0.14em;
    color: #1f3147;
    margin: 8px 0;
}

.data-table {
    width: 100%;
    border-collapse: collapse;
}

.data-table th,
.data-table td {
    padding: 14px 16px;
    border-bottom: 1px solid var(--line);
    text-align: left;
}

.data-table th {
    background: #f8fbff;
    color: var(--muted);
    font-size: 0.85rem;
    text-transform: uppercase;
}

.data-table th.datatable-sortable,
.superadmin-table th.datatable-sortable {
    padding: 0;
}

.datatable-sort-button {
    width: 100%;
    display: inline-flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    padding: 14px 16px;
    border: 0;
    background: transparent;
    color: inherit;
    font: inherit;
    text-transform: inherit;
    letter-spacing: inherit;
    cursor: pointer;
}

.datatable-sort-button:focus-visible {
    outline: 2px solid rgba(37, 99, 235, 0.32);
    outline-offset: -2px;
}

.datatable-sort-indicator {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 14px;
    color: #8b98ac;
    font-size: 0.74rem;
    font-weight: 900;
}

.datatable-sortable[aria-sort="none"] .datatable-sort-indicator::before {
    content: "+";
}

.datatable-sortable[aria-sort="ascending"] .datatable-sort-indicator::before {
    content: "^";
}

.datatable-sortable[aria-sort="descending"] .datatable-sort-indicator::before {
    content: "v";
}

.datatable-toolbar {
    display: flex;
    align-items: end;
    justify-content: space-between;
    gap: 14px;
    flex-wrap: wrap;
    padding: 16px 0 14px;
}

.datatable-search,
.datatable-page-size {
    display: grid;
    gap: 6px;
}

.datatable-search span,
.datatable-page-size span {
    color: #60708f;
    font-size: 0.72rem;
    font-weight: 800;
    letter-spacing: 0.06em;
    text-transform: uppercase;
}

.datatable-search input,
.datatable-page-size select {
    min-height: 42px;
    border: 1px solid #dce3ee;
    border-radius: 12px;
    background: #f8fbff;
    color: #1f3147;
    font: inherit;
}

.datatable-search input {
    width: min(320px, 100%);
    padding: 10px 14px;
}

.datatable-page-size select {
    min-width: 110px;
    padding: 10px 12px;
}

.datatable-toolbar-actions {
    display: flex;
    align-items: end;
    gap: 12px;
    flex-wrap: wrap;
}

.datatable-export-group {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}

.datatable-export-button {
    min-height: 42px;
    padding: 10px 14px;
    border: 1px solid transparent;
    border-radius: 12px;
    color: #ffffff;
    font: inherit;
    font-size: 0.78rem;
    font-weight: 800;
    letter-spacing: 0.02em;
    cursor: pointer;
    box-shadow: 0 10px 20px rgba(15, 23, 42, 0.08);
    transition: transform 0.18s ease, box-shadow 0.18s ease, filter 0.18s ease;
}

.datatable-export-button:hover {
    transform: translateY(-1px);
    filter: brightness(1.03);
    box-shadow: 0 12px 24px rgba(15, 23, 42, 0.12);
}

.datatable-export-button[data-export-type="copy"] {
    background: linear-gradient(135deg, #8b5cf6, #6d28d9);
}

.datatable-export-button[data-export-type="csv"] {
    background: linear-gradient(135deg, #10b981, #0f766e);
}

.datatable-export-button[data-export-type="excel"] {
    background: linear-gradient(135deg, #f59e0b, #d97706);
}

.datatable-export-button[data-export-type="pdf"] {
    background: linear-gradient(135deg, #ef4444, #dc2626);
}

.datatable-summary {
    padding: 12px 0 0;
    color: #60708f;
    font-size: 0.82rem;
    font-weight: 700;
}

.datatable-pagination {
    display: flex;
    justify-content: flex-end;
    gap: 8px;
    flex-wrap: wrap;
    padding: 14px 0 0;
}

.datatable-host-contained > .datatable-toolbar {
    padding: 16px 16px 14px;
}

.datatable-host-contained > .datatable-summary {
    padding: 12px 16px 0;
}

.datatable-host-contained > .datatable-pagination {
    padding: 14px 16px 16px;
}

.datatable-page-button.is-active {
    background: linear-gradient(135deg, var(--primary), var(--primary-deep));
    color: #fff;
    box-shadow: 0 10px 20px rgba(13, 110, 253, 0.16);
}

.datatable-empty-row td {
    background: #fff;
}

.document-rows {
    display: grid;
    gap: 12px;
}

.document-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
}

.admission-compact-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
}

.admission-toggle-field {
    min-height: auto;
}

.admission-toggle-field label,
.admission-copy-toggle {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-weight: 700;
}

.admission-doc-note {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 12px;
}

.field textarea.is-readonly,
.field input.is-readonly {
    background: #f4f7fc;
    color: #61708e;
}

.student-entry-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
}

.student-entry-form .erp-form-grid .field label {
    color: #334155;
    font-size: 0.9rem;
}

.student-entry-form .erp-form-grid {
    gap: 6px 12px;
}

.student-entry-form .erp-form-grid .field {
    min-width: 0;
    padding: 0;
    border: 0;
    border-radius: 0;
    background: transparent;
    box-shadow: none;
}

.student-entry-form .erp-form-grid .field label {
    margin-bottom: 2px;
    color: #284667;
    font-size: 0.82rem;
    letter-spacing: 0.01em;
}

.student-entry-form .erp-form-grid .field input,
.student-entry-form .erp-form-grid .field select,
.student-entry-form .erp-form-grid .field textarea {
    padding: 10px 12px;
    border-radius: 10px;
    border-color: #cfd9e6;
    background: #ffffff;
    box-shadow: none;
}

.student-entry-form .erp-form-grid .field .hint {
    display: block;
    margin-top: 6px;
}

.student-entry-check {
    display: flex;
    align-items: end;
}

.student-entry-inline {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    min-height: 42px;
    margin: 0;
    color: #284667;
}

.student-entry-inline input {
    width: auto;
    margin: 0;
}

.student-entry-upload-box {
    border: 1px dashed #d6e2f0;
    border-radius: 12px;
    padding: 14px 16px;
    background: #fbfdff;
}

.student-entry-upload-box h3 {
    margin: 0;
    font-size: 1rem;
    color: #173c72;
}

.student-entry-upload-box p {
    margin: 6px 0 0;
    color: #667892;
    font-size: 0.88rem;
}

.student-entry-inline-alert {
    margin: 0 0 12px;
}

@media screen and (max-width: 1180px) {
    .admission-compact-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .student-entry-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .field-span-4 {
        grid-column: span 2;
    }
}

.checkbox-field {
    display: flex;
    align-items: center;
}

.checkbox-field label {
    margin: 0;
}

.checkbox-field input {
    width: auto;
    margin-right: 8px;
}

.error-state {
    background: #fff;
    padding: 28px;
    border-radius: 20px;
    box-shadow: var(--shadow);
}

.app-footer {
    margin-top: 24px;
    padding: 16px 18px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;
    gap: 14px;
    text-align: left;
    color: #f8fbff;
    font-size: 0.95rem;
    font-weight: 600;
    border-radius: 18px;
    background: linear-gradient(135deg, #0d2352, #103a7a 52%, #10b6df);
    box-shadow: 0 18px 36px rgba(16, 43, 83, 0.2);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.auth-footer {
    width: min(1100px, 100%);
    align-self: center;
}

.dashboard-footer {
    margin-top: 30px;
}

.footer-brand-wordmark {
    max-width: min(100%, 290px);
    height: 56px;
    width: auto;
    display: block;
    border-radius: 16px;
    background: rgba(255, 255, 255, 0.96);
    padding: 6px 10px;
    box-shadow: 0 14px 30px rgba(8, 23, 53, 0.18);
}

.footer-badge {
    width: 52px;
    height: 52px;
    border-radius: 16px;
    display: grid;
    place-items: center;
    background: linear-gradient(135deg, #ffe2a1, #ffab64);
    color: #103463;
    font-size: 1rem;
    font-weight: 800;
    letter-spacing: 0.08em;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.5);
}

.footer-copy {
    display: grid;
    gap: 4px;
    justify-items: start;
}

.footer-copy strong {
    color: #ffffff;
    letter-spacing: 0.02em;
}

.footer-support {
    color: rgba(255, 255, 255, 0.82);
    font-size: 0.88rem;
}

.dashboard-body {
    background: #eef2f7;
}

.erp-shell {
    --erp-sidebar-width: 272px;
    display: grid;
    grid-template-columns: var(--erp-sidebar-width) minmax(0, 1fr);
    min-height: 100vh;
}

.erp-sidebar {
    position: sticky;
    top: 0;
    display: flex;
    flex-direction: column;
    height: 100vh;
    width: 272px;
    min-width: 0;
    background: #fff;
    border-right: 1px solid #dde5ef;
    overflow: hidden;
    transition: transform 0.24s ease, opacity 0.24s ease, visibility 0.24s ease, border-color 0.24s ease;
    z-index: 22;
}

body.sidebar-collapsed .erp-shell {
    --erp-sidebar-width: 0px;
}

body.sidebar-collapsed .erp-sidebar {
    transform: translateX(-100%);
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    border-right-color: transparent;
}

.erp-brand-wrap {
    padding: 10px 8px;
    border-bottom: 1px solid #e5ebf3;
}

.erp-brand {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 10px;
    border-radius: 14px;
    background: linear-gradient(135deg, #081e48, #123f86 56%, #14b8dc);
    color: #fff;
    font-weight: 800;
    box-shadow: 0 14px 28px rgba(12, 31, 68, 0.18);
}

.erp-brand-logo {
    width: 28px;
    height: 28px;
    display: grid;
    place-items: center;
    border-radius: 8px;
    background: linear-gradient(135deg, #f6b63f, #f08e1a);
    color: #0f1830;
    font-size: 0.75rem;
}

.erp-brand-image {
    width: 42px;
    height: 42px;
    flex: 0 0 42px;
    border-radius: 12px;
    object-fit: contain;
    background: rgba(255, 255, 255, 0.96);
    padding: 4px;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.6);
}

.erp-brand-copy {
    min-width: 0;
    display: grid;
    gap: 2px;
}

.erp-brand-name {
    display: block;
    color: #ffffff;
    font-size: 0.96rem;
    letter-spacing: 0.04em;
    line-height: 1.1;
}

.erp-brand-tagline {
    display: block;
    color: rgba(231, 244, 255, 0.82);
    font-size: 0.64rem;
    font-weight: 700;
    line-height: 1.2;
}

.erp-session-panel {
    padding: 10px 10px 14px;
    border-bottom: 1px solid #e5ebf3;
}

.erp-session-panel p {
    margin: 0 0 10px;
    color: #344055;
    font-weight: 600;
}

.erp-quicklinks-button {
    width: 100%;
    border: 1px solid #dfe6ef;
    background: #f7faff;
    color: #344055;
    border-radius: 10px;
    padding: 12px 14px;
    font: inherit;
    font-weight: 700;
    font-size: 1rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    cursor: pointer;
}

.erp-nav {
    --nav-accent: #2563eb;
    --nav-soft: #eef4ff;
    --nav-soft-strong: #cfe0ff;
    --nav-glow: rgba(37, 99, 235, 0.18);
    --nav-card-start: #fbfdff;
    --nav-card-end: #eef4ff;
    --nav-sub-card: #f4f8ff;
    display: grid;
    gap: 8px;
    padding: 10px 10px 14px;
    overflow: auto;
}

.erp-nav-group {
    --nav-accent: #2563eb;
    --nav-soft: rgba(37, 99, 235, 0.14);
    --nav-soft-strong: rgba(37, 99, 235, 0.24);
    --nav-glow: rgba(37, 99, 235, 0.18);
    --nav-card-start: #fbfdff;
    --nav-card-end: #eef4ff;
    --nav-sub-card: #f4f8ff;
    position: relative;
    overflow: visible;
    border: 0;
    border-radius: 0;
    background: transparent;
    box-shadow: none;
    transition: background 0.2s ease, color 0.2s ease;
}

.erp-nav-group::before {
    display: none;
}

details.erp-nav-group:nth-of-type(4n + 1) {
    --nav-accent: #2563eb;
    --nav-soft: #eef4ff;
    --nav-soft-strong: #cfe0ff;
    --nav-glow: rgba(37, 99, 235, 0.18);
    --nav-card-start: #fdfefe;
    --nav-card-end: #eaf2ff;
    --nav-sub-card: #f2f7ff;
}

details.erp-nav-group:nth-of-type(4n + 2) {
    --nav-accent: #0f766e;
    --nav-soft: #edf9f6;
    --nav-soft-strong: #c9eee8;
    --nav-glow: rgba(15, 118, 110, 0.18);
    --nav-card-start: #fcfffe;
    --nav-card-end: #e7f8f2;
    --nav-sub-card: #eefaf6;
}

details.erp-nav-group:nth-of-type(4n + 3) {
    --nav-accent: #d97706;
    --nav-soft: #fff6ea;
    --nav-soft-strong: #f6ddbb;
    --nav-glow: rgba(217, 119, 6, 0.2);
    --nav-card-start: #fffdf8;
    --nav-card-end: #fff1db;
    --nav-sub-card: #fff7eb;
}

details.erp-nav-group:nth-of-type(4n + 4) {
    --nav-accent: #e11d48;
    --nav-soft: #ffeff4;
    --nav-soft-strong: #f8c9d7;
    --nav-glow: rgba(225, 29, 72, 0.18);
    --nav-card-start: #fffafd;
    --nav-card-end: #ffe8ef;
    --nav-sub-card: #fff2f6;
}

.erp-nav-group:hover {
    transform: none;
    border-color: transparent;
    background: transparent;
    box-shadow: none;
}

.erp-nav-group[open] {
    border-color: transparent;
    background: transparent;
    box-shadow: none;
}

.erp-nav-group:hover::before,
.erp-nav-group[open]::before,
.erp-nav-group.is-active::before {
    display: none;
}

.erp-nav-group summary {
    list-style: none;
}

.erp-nav-group summary::-webkit-details-marker {
    display: none;
}

.erp-nav-item {
    position: relative;
    display: grid;
    grid-template-columns: auto minmax(0, 1fr) auto;
    align-items: center;
    justify-content: flex-start;
    gap: 9px;
    min-height: 42px;
    padding: 6px 11px;
    border-radius: 16px;
    border: 1px solid #e5ebf3;
    background: linear-gradient(135deg, var(--nav-card-start) 0%, var(--nav-card-end) 100%);
    color: #334055;
    font-weight: 700;
    font-size: 0.9rem;
    line-height: 1.1;
    overflow: hidden;
    isolation: isolate;
    box-shadow: none;
    transition: color 0.18s ease, transform 0.18s ease, box-shadow 0.18s ease, background 0.18s ease, border-color 0.18s ease;
}

.erp-nav-item::before,
.erp-subnav-item::before {
    display: none;
}

.erp-nav-item > *,
.erp-subnav-item > * {
    position: relative;
    z-index: 1;
}

.erp-nav-item:hover {
    color: var(--nav-accent);
    transform: translateX(1px);
    background: var(--nav-soft);
    border-color: var(--nav-soft-strong);
    box-shadow: none;
}

.erp-nav-summary {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr) auto;
    align-items: center;
    gap: 9px;
    width: 100%;
    box-sizing: border-box;
    cursor: pointer;
    background: linear-gradient(135deg, var(--nav-card-start) 0%, var(--nav-card-end) 100%);
    border: 1px solid #e5ebf3;
    box-shadow: none;
}

.erp-nav-group[open] .erp-nav-summary,
.erp-nav-group.is-active .erp-nav-summary,
.erp-nav-group[open] .erp-nav-summary:hover,
.erp-nav-group.is-active .erp-nav-summary:hover {
    color: #ffffff;
    background: var(--nav-accent);
    border-color: transparent;
    box-shadow: none;
}

.erp-nav-summary:hover {
    color: var(--nav-accent);
    background: var(--nav-soft);
    border-color: var(--nav-soft-strong);
    box-shadow: none;
}

.erp-nav-group[open] .erp-nav-summary .erp-nav-icon,
.erp-nav-group.is-active .erp-nav-summary .erp-nav-icon {
    background: transparent;
    color: #ffffff;
    border-color: transparent;
    box-shadow: none;
    transform: none;
}

.erp-nav-item:hover .erp-nav-icon,
.erp-nav-item.is-active .erp-nav-icon {
    background: transparent;
    color: var(--nav-accent);
    border-color: transparent;
    box-shadow: none;
    transform: none;
}

.erp-nav-item.is-active {
    color: var(--nav-accent);
    background: var(--nav-soft);
    border-color: var(--nav-soft-strong);
    box-shadow: none;
}

.erp-nav-icon {
    width: 22px;
    height: 22px;
    flex: 0 0 22px;
    display: grid;
    place-items: center;
    border-radius: 0;
    border: 1px solid transparent;
    background: transparent;
    color: var(--nav-accent);
    font-size: 0.8rem;
    font-weight: 800;
    box-shadow: none;
    transition: transform 0.18s ease, background 0.18s ease, color 0.18s ease, border-color 0.18s ease;
}

.erp-nav-icon svg {
    width: 18px;
    height: 18px;
    display: block;
}

.erp-nav-label {
    flex: 1 1 auto;
    display: block;
    min-width: 0;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    line-height: 1.1;
    color: inherit;
    opacity: 1;
    letter-spacing: 0;
    font-size: 0.9rem;
    font-weight: 700;
}

.erp-nav-arrow {
    margin-left: auto;
    color: #8c98ad;
    font-size: 0.92rem;
    opacity: 0.92;
    transition: transform 0.18s ease, color 0.18s ease, opacity 0.18s ease;
    justify-self: end;
    flex: 0 0 auto;
    transform: rotate(-90deg);
}

.erp-nav-item:hover .erp-nav-arrow,
.erp-nav-item.is-active .erp-nav-arrow {
    color: var(--nav-accent);
    opacity: 1;
}

.erp-nav-group[open] .erp-nav-summary .erp-nav-arrow,
.erp-nav-group.is-active .erp-nav-summary .erp-nav-arrow {
    color: #ffffff;
    opacity: 1;
}

.erp-nav-group[open] .erp-nav-summary .erp-nav-arrow {
    transform: rotate(90deg);
}

.erp-main {
    display: flex;
    flex-direction: column;
    min-width: 0;
}

.erp-subnav {
    position: relative;
    display: grid;
    gap: 3px;
    padding: 3px 0 3px 16px;
    margin: 2px 0 2px 8px;
}

.erp-subnav::before {
    content: "";
    position: absolute;
    left: 6px;
    top: 3px;
    bottom: 4px;
    width: 1px;
    background: #d5dfeb;
}

.erp-subnav-item {
    position: relative;
    display: grid;
    grid-template-columns: auto minmax(0, 1fr);
    align-items: center;
    gap: 8px;
    min-height: 34px;
    margin-left: 2px;
    padding: 5px 9px;
    border-radius: 14px;
    background: linear-gradient(135deg, #ffffff 0%, var(--nav-sub-card) 100%);
    border: 1px solid #eef2f6;
    color: #334055;
    font-size: 0.86rem;
    font-weight: 700;
    line-height: 1.1;
    overflow: hidden;
    isolation: isolate;
    box-shadow: none;
    transition: background 0.18s ease, color 0.18s ease, transform 0.18s ease, box-shadow 0.18s ease, border-color 0.18s ease;
}

.erp-subnav-item::after {
    content: "";
    position: absolute;
    left: -8px;
    top: 50%;
    width: 7px;
    height: 1px;
    background: #d5dfeb;
    transform: translateY(-50%);
}

.erp-subnav-item span:last-child {
    flex: 1;
    min-width: 0;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.erp-subnav-item:hover {
    color: var(--nav-accent);
    background: var(--nav-soft);
    transform: translateX(2px);
    border-color: var(--nav-soft-strong);
    box-shadow: none;
}

.erp-subnav-item.is-active {
    color: #ffffff;
    font-weight: 800;
    background: var(--nav-accent);
    border-color: transparent;
    box-shadow: none;
}

.erp-subnav-item.is-active::after {
    background: var(--nav-accent);
}

.erp-subnav-item.is-placeholder {
    color: #54647b;
    opacity: 1;
}

.erp-subnav-bullet {
    color: var(--nav-accent);
    font-size: 0.84rem;
    transition: transform 0.22s ease, color 0.22s ease;
}

.erp-subnav-icon {
    width: 18px;
    height: 18px;
    flex: 0 0 18px;
    display: grid;
    place-items: center;
    color: currentColor;
    transition: transform 0.18s ease, color 0.18s ease;
}

.erp-subnav-icon svg {
    width: 16px;
    height: 16px;
    display: block;
}

.erp-subnav-item:hover .erp-subnav-bullet,
.erp-subnav-item.is-active .erp-subnav-bullet {
    transform: translateX(2px);
}

.erp-subnav-item:hover .erp-subnav-icon,
.erp-subnav-item.is-active .erp-subnav-icon {
    transform: translateX(2px);
}

.erp-topbar {
    position: sticky;
    top: 0;
    z-index: 18;
    height: 56px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding: 0 16px;
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.97) 0%, rgba(247, 250, 255, 0.95) 100%);
    border-bottom: 1px solid #d9e4f0;
    backdrop-filter: blur(8px);
    box-shadow: 0 12px 30px rgba(15, 23, 42, 0.04);
}

.erp-topbar-left,
.erp-topbar-right {
    display: flex;
    align-items: center;
    gap: 10px;
    min-width: 0;
}

.erp-topbar-left h1 {
    margin: 0;
    font-size: clamp(1.1rem, 1.6vw, 1.7rem);
    letter-spacing: 0.04em;
    color: var(--title-strong);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.erp-topbar-school {
    min-width: 0;
    display: flex;
    align-items: baseline;
    gap: 8px;
    white-space: nowrap;
    overflow: hidden;
}

.erp-topbar-school-label {
    color: #60708f;
    font-size: 0.78rem;
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    flex: 0 0 auto;
}

.erp-topbar-school-name {
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    color: var(--title-strong);
    font-size: 0.92rem;
    font-weight: 800;
}

.erp-topbar-right {
    justify-content: flex-end;
}

.erp-current-session-chip {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    min-height: 30px;
    padding: 5px 12px;
    border: 1px solid #bbf7d0;
    border-radius: 999px;
    background: linear-gradient(135deg, #ecfdf5 0%, #dcfce7 100%);
    color: #047857;
    font-size: 0.72rem;
    font-weight: 900;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    white-space: nowrap;
}

.erp-current-session-chip strong {
    color: #065f46;
    font-size: 0.76rem;
}

.erp-profile-menu {
    position: relative;
}

.erp-profile-trigger {
    width: 38px;
    height: 38px;
    padding: 0;
    border: 1px solid #dce3ee;
    border-radius: 999px;
    background: #fff;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    overflow: hidden;
}

.erp-profile-trigger-avatar,
.profile-card-avatar,
.erp-profile-dropdown-avatar {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    background: linear-gradient(135deg, #17386b, #0d6efd);
    color: #fff;
    font-weight: 800;
}

.profile-card-avatar {
    background: #f1f5f9;
    color: #334155;
}

.erp-profile-trigger-avatar {
    width: 100%;
    height: 100%;
    font-size: 0.78rem;
}

.erp-profile-trigger-image,
.erp-profile-dropdown-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.erp-profile-dropdown {
    position: absolute;
    top: calc(100% + 10px);
    right: 0;
    width: 280px;
    opacity: 0;
    pointer-events: none;
    transform: translateY(-8px);
    transition: opacity 0.18s ease, transform 0.18s ease;
    z-index: 40;
}

body.profile-menu-open .erp-profile-dropdown {
    opacity: 1;
    pointer-events: auto;
    transform: translateY(0);
}

.erp-profile-dropdown-card {
    background: #fff;
    border: 1px solid #dde5ef;
    border-radius: 16px;
    box-shadow: 0 22px 50px rgba(17, 31, 54, 0.12);
    overflow: hidden;
}

.erp-profile-dropdown-head {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 16px;
    background: linear-gradient(135deg, #f7fbff, #eef5ff);
}

.erp-profile-dropdown-avatar,
.erp-profile-dropdown-image {
    width: 54px;
    height: 54px;
    flex: 0 0 54px;
    font-size: 1rem;
}

.erp-profile-dropdown-meta strong,
.profile-card h3 {
    display: block;
    font-size: 0.98rem;
}

.erp-profile-dropdown-meta span,
.profile-card p {
    display: block;
    margin-top: 4px;
    color: #6f7f97;
    font-size: 0.84rem;
}

.erp-profile-dropdown-meta small {
    display: inline-flex;
    margin-top: 8px;
    color: #0a4fb3;
    background: #e7f0ff;
    padding: 4px 8px;
    border-radius: 999px;
    font-size: 0.74rem;
    font-weight: 700;
}

.erp-profile-dropdown-actions {
    display: grid;
    padding: 10px;
    gap: 6px;
}

.erp-profile-action {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 12px;
    border-radius: 10px;
    color: #334055;
    font-weight: 600;
    transition: background 0.18s ease, color 0.18s ease;
}

.erp-profile-action:hover {
    background: #f4f8fe;
    color: #0a4fb3;
}

.erp-profile-action-danger:hover {
    background: #fff1f3;
    color: #c9314b;
}

.erp-profile-action-icon {
    width: 28px;
    height: 28px;
    flex: 0 0 28px;
    display: grid;
    place-items: center;
    border-radius: 8px;
    background: #eef4ff;
    color: #0a4fb3;
    font-size: 0.7rem;
    font-weight: 800;
}

.erp-search {
    position: relative;
    display: block;
}

.erp-search input {
    width: 260px;
    padding: 10px 34px 10px 14px;
    border: 1px solid #dce3ee;
    border-radius: 999px;
    background: #f8fbff;
    font: inherit;
}

.erp-search-icon {
    position: absolute;
    top: 50%;
    right: 12px;
    transform: translateY(-50%);
    color: #6f7f97;
    font-size: 0.9rem;
}

.erp-topbar-text {
    font-weight: 700;
    color: #334055;
}

.erp-icon-chip,
.erp-icon-button {
    min-width: 34px;
    height: 34px;
    border: 1px solid #dce3ee;
    border-radius: 999px;
    background: #fff;
    color: #334055;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font: inherit;
    font-size: 0.7rem;
    font-weight: 800;
    cursor: pointer;
}

.erp-icon-chip {
    padding: 0 10px;
    background: #f8fbff;
}

.erp-sidebar-desktop-toggle {
    display: inline-flex;
}

.erp-sidebar-desktop-toggle-bars {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 3px;
    width: 16px;
    height: 16px;
}

.erp-sidebar-desktop-toggle-bars span {
    width: 3px;
    height: 14px;
    border-radius: 999px;
    background: currentColor;
    display: block;
}

.erp-mobile-toggle {
    display: none;
}

.erp-content {
    position: relative;
    flex: 1;
    padding: 12px;
}

.page-body {
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.quicklinks-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(232, 238, 247, 0.72);
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.22s ease;
    z-index: 25;
}

.quicklinks-panel {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    z-index: 26;
    background: #fff;
    border: 1px solid #dde5ef;
    border-radius: 16px;
    padding: 16px;
    box-shadow: 0 24px 70px rgba(17, 31, 54, 0.12);
    opacity: 0;
    pointer-events: none;
    transform: translateY(-10px) scale(0.99);
    transition: opacity 0.22s ease, transform 0.22s ease;
    max-height: calc(100vh - 110px);
    overflow: auto;
}

body.quicklinks-open .quicklinks-backdrop {
    opacity: 1;
    pointer-events: auto;
}

body.quicklinks-open .quicklinks-panel {
    opacity: 1;
    pointer-events: auto;
    transform: translateY(0) scale(1);
}

.quicklinks-panel-header {
    display: flex;
    align-items: start;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 18px;
}

.quicklinks-panel-header h2 {
    margin: 0;
}

.quicklinks-grid {
    display: grid;
    grid-template-columns: repeat(5, minmax(180px, 1fr));
    gap: 20px;
}

.quicklinks-card {
    padding-right: 8px;
    border-right: 1px solid #eef2f7;
}

.quicklinks-card h3 {
    margin: 0 0 12px;
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 1rem;
}

.quicklinks-card-icon {
    width: 28px;
    height: 28px;
    display: grid;
    place-items: center;
    border-radius: 8px;
    background: #eef4ff;
    color: #0a4fb3;
    font-size: 0.72rem;
}

.quicklinks-card ul {
    margin: 0;
    padding-left: 18px;
    color: #5a6780;
    line-height: 1.6;
    font-size: 0.92rem;
}

.dashboard-ribbon {
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 12px;
}

.dashboard-ribbon-item {
    background: #fff;
    border: 1px solid #dde5ef;
    border-radius: 12px;
    padding: 12px 14px;
    box-shadow: 0 14px 34px rgba(19, 32, 57, 0.05);
    position: relative;
    overflow: hidden;
}

.dashboard-ribbon-item::after {
    content: "";
    position: absolute;
    inset: auto -18px -18px auto;
    width: 88px;
    height: 88px;
    border-radius: 50%;
    opacity: 0.18;
}

.dashboard-ribbon-item:nth-child(5n + 1) {
    background: linear-gradient(135deg, #eef5ff, #ffffff);
    border-color: #c9dcff;
}

.dashboard-ribbon-item:nth-child(5n + 1)::after {
    background: #4a8cff;
}

.dashboard-ribbon-item:nth-child(5n + 1) span {
    color: #3569c9;
}

.dashboard-ribbon-item:nth-child(5n + 1) strong {
    color: #173d7a;
}

.dashboard-ribbon-item:nth-child(5n + 2) {
    background: linear-gradient(135deg, #eefcf6, #ffffff);
    border-color: #c6ead9;
}

.dashboard-ribbon-item:nth-child(5n + 2)::after {
    background: #33b07a;
}

.dashboard-ribbon-item:nth-child(5n + 2) span {
    color: #1b8a67;
}

.dashboard-ribbon-item:nth-child(5n + 2) strong {
    color: #10624a;
}

.dashboard-ribbon-item:nth-child(5n + 3) {
    background: linear-gradient(135deg, #fff8ee, #ffffff);
    border-color: #ffdba9;
}

.dashboard-ribbon-item:nth-child(5n + 3)::after {
    background: #ffb347;
}

.dashboard-ribbon-item:nth-child(5n + 3) span {
    color: #b26b0f;
}

.dashboard-ribbon-item:nth-child(5n + 3) strong {
    color: #8c5300;
}

.dashboard-ribbon-item:nth-child(5n + 4) {
    background: linear-gradient(135deg, #fff1ef, #ffffff);
    border-color: #ffc9c1;
}

.dashboard-ribbon-item:nth-child(5n + 4)::after {
    background: #ef6b61;
}

.dashboard-ribbon-item:nth-child(5n + 4) span {
    color: #bf5448;
}

.dashboard-ribbon-item:nth-child(5n + 4) strong {
    color: #8a352c;
}

.dashboard-ribbon-item:nth-child(5n + 5) {
    background: linear-gradient(135deg, #effbff, #ffffff);
    border-color: #c4ebf4;
}

.dashboard-ribbon-item:nth-child(5n + 5)::after {
    background: #35a7b8;
}

.dashboard-ribbon-item:nth-child(5n + 5) span {
    color: #2d8290;
}

.dashboard-ribbon-item:nth-child(5n + 5) strong {
    color: #165660;
}

.dashboard-ribbon-item span {
    display: block;
    color: #6f7f97;
    font-size: 0.82rem;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.dashboard-ribbon-item strong {
    display: block;
    margin-top: 8px;
    font-size: 1rem;
}

.dashboard-summary-row {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 12px;
}

.dashboard-summary-card {
    background: #fff;
    border: 1px solid #dde5ef;
    border-radius: 14px;
    padding: 12px 14px;
    box-shadow: 0 16px 34px rgba(19, 32, 57, 0.05);
}

.dashboard-summary-head {
    display: flex;
    justify-content: space-between;
    align-items: start;
    gap: 12px;
}

.dashboard-summary-title {
    display: flex;
    gap: 10px;
    min-width: 0;
}

.dashboard-summary-title h3 {
    margin: 0;
    font-size: 0.92rem;
    text-transform: uppercase;
    letter-spacing: 0.02em;
}

.dashboard-summary-head strong {
    white-space: nowrap;
}

.dashboard-summary-icon {
    width: 30px;
    height: 30px;
    flex: 0 0 30px;
    display: grid;
    place-items: center;
    border-radius: 8px;
    font-size: 0.72rem;
    font-weight: 800;
}

.dashboard-summary-card--teal .dashboard-summary-icon,
.dashboard-summary-card--teal .dashboard-summary-track span {
    background: #d9f5fb;
    color: #0d9cbe;
}

.dashboard-summary-card--slate .dashboard-summary-icon,
.dashboard-summary-card--slate .dashboard-summary-track span {
    background: #eef2f7;
    color: #60708f;
}

.dashboard-summary-card--indigo .dashboard-summary-icon,
.dashboard-summary-card--indigo .dashboard-summary-track span {
    background: #e5e9ff;
    color: #5968f2;
}

.dashboard-summary-card--amber .dashboard-summary-icon,
.dashboard-summary-card--amber .dashboard-summary-track span {
    background: #fff1cf;
    color: #cf8600;
}

.dashboard-summary-track {
    height: 6px;
    margin-top: 12px;
    background: #edf2f7;
    border-radius: 999px;
    overflow: hidden;
}

.dashboard-summary-track span {
    display: block;
    height: 100%;
    border-radius: 999px;
}

.dashboard-layout-grid {
    display: grid;
    grid-template-columns: minmax(0, 1.7fr) minmax(320px, 1fr);
    gap: 12px;
}

.dashboard-panel {
    background: linear-gradient(180deg, #ffffff 0%, #fbfdff 100%);
    border: 1px solid #d7e3ef;
    border-radius: 14px;
    overflow: hidden;
    box-shadow: 0 18px 42px rgba(19, 32, 57, 0.06);
    min-width: 0;
}

.dashboard-panel-wide {
    min-height: 360px;
}

.dashboard-panel-header {
    position: relative;
    display: flex;
    justify-content: space-between;
    align-items: start;
    gap: 16px;
    padding: 18px 20px 14px;
    border-bottom: 1px solid rgba(216, 228, 242, 0.98);
    background: var(--panel-header-surface);
    overflow: hidden;
}

.dashboard-panel-header::before {
    content: "";
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 6px;
    background: var(--hero-highlight);
}

.dashboard-panel-header > div {
    position: relative;
    z-index: 1;
    min-width: 0;
}

.dashboard-panel-header h2 {
    margin: 0;
    font-size: 1.05rem;
    color: var(--title-strong);
    letter-spacing: 0.01em;
}

.dashboard-panel-header p {
    margin: 6px 0 0;
    color: var(--title-soft);
    font-size: 0.88rem;
    max-width: 100%;
    white-space: normal;
    overflow-wrap: anywhere;
}

.dashboard-panel-total {
    text-align: right;
}

.dashboard-panel-total span {
    display: block;
    color: #69839d;
    font-size: 0.78rem;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.dashboard-panel-total strong {
    display: block;
    margin-top: 6px;
    font-size: 1.06rem;
    color: var(--title-accent);
}

.bars-chart {
    display: flex;
    align-items: end;
    gap: 7px;
    min-height: 300px;
    padding: 18px 18px 12px;
    overflow-x: auto;
    background-image: repeating-linear-gradient(to top, #f4f7fb 0, #f4f7fb 1px, transparent 1px, transparent 52px);
}

.bars-chart-column {
    flex: 1 0 24px;
    min-width: 24px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
}

.bars-chart-stack {
    height: 240px;
    width: 100%;
    display: flex;
    align-items: end;
    justify-content: center;
    gap: 3px;
}

.bars-chart-bar {
    width: 9px;
    min-height: 2px;
    border-radius: 6px 6px 0 0;
}

.bars-chart-bar-collection {
    background: linear-gradient(180deg, #a1d36c, #86c24d);
}

.bars-chart-bar-expense {
    background: linear-gradient(180deg, #ff8ea5, #ef5a6f);
}

.bars-chart-label {
    color: #6f7f97;
    font-size: 0.76rem;
}

.dashboard-legend {
    display: flex;
    gap: 18px;
    padding: 0 18px 18px;
    color: #5f6c84;
    font-size: 0.86rem;
}

.legend-dot {
    display: inline-block;
    width: 10px;
    height: 10px;
    border-radius: 999px;
    margin-right: 8px;
    vertical-align: middle;
}

.legend-dot-collection {
    background: #8dc452;
}

.legend-dot-expense {
    background: #ef5a6f;
}

.breakdown-card {
    display: flex;
    align-items: center;
    gap: 18px;
    padding: 18px;
}

.breakdown-card-stack {
    flex-direction: column;
    align-items: stretch;
}

.breakdown-donut {
    position: relative;
    width: 180px;
    height: 180px;
    flex: 0 0 180px;
    border-radius: 50%;
    margin: 0 auto;
}

.breakdown-donut-center {
    position: absolute;
    inset: 24px;
    border-radius: 50%;
    background: #fff;
    box-shadow: inset 0 0 0 1px #e6edf6;
    display: grid;
    place-items: center;
    text-align: center;
}

.breakdown-donut-center span {
    display: block;
    color: #6f7f97;
    font-size: 0.84rem;
}

.breakdown-donut-center strong {
    display: block;
    margin-top: 6px;
    font-size: 1.06rem;
}

.breakdown-list {
    display: grid;
    gap: 10px;
    width: 100%;
}

.breakdown-list-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
    padding: 10px 12px;
    border-radius: 10px;
    border: 1px solid #e7edf6;
    background: #f8fbff;
}

.breakdown-list-label {
    display: flex;
    align-items: center;
    gap: 8px;
    color: #344055;
    font-weight: 600;
}

.session-chart {
    padding: 16px 18px 18px;
}

.session-chart svg {
    width: 100%;
    height: 260px;
    display: block;
}

.session-chart-grid-line {
    stroke: #e7edf6;
    stroke-width: 1;
}

.session-chart-line {
    fill: none;
    stroke-width: 4;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.session-chart-line-collection {
    stroke: #98cc63;
}

.session-chart-line-expense {
    stroke: #ef5a6f;
}

.session-chart-labels {
    display: grid;
    grid-template-columns: repeat(12, minmax(0, 1fr));
    gap: 6px;
    padding-top: 8px;
    color: #6f7f97;
    font-size: 0.76rem;
}

.insight-stack {
    display: grid;
    gap: 12px;
}

.insight-card {
    padding: 14px;
    border: 1px solid #e7edf6;
    border-radius: 12px;
    background: linear-gradient(180deg, #ffffff, #f7fbff);
}

.insight-card span {
    display: block;
    color: #6f7f97;
    font-size: 0.78rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.insight-card strong {
    display: block;
    margin-top: 8px;
    font-size: 0.94rem;
    line-height: 1.55;
    font-weight: 600;
}

.erp-page-hero {
    display: flex;
    justify-content: space-between;
    align-items: start;
    gap: 16px;
    padding: 18px 20px;
    background:
        radial-gradient(circle at top right, rgba(255, 203, 113, 0.24), transparent 34%),
        linear-gradient(135deg, #f7fbff, #fff6ef 52%, #eff9f5);
    border: 1px solid #d9e6f4;
    border-radius: 14px;
    box-shadow: 0 18px 40px rgba(19, 32, 57, 0.07);
}

.erp-page-hero > div {
    min-width: 0;
}

.erp-page-hero h2 {
    margin: 0;
    font-size: 1.35rem;
    color: #123867;
}

.erp-page-hero p {
    margin: 8px 0 0;
    color: #526c8b;
    max-width: 720px;
    overflow-wrap: anywhere;
}

.erp-page-hero-actions {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.erp-table-wrap {
    border: 0;
    border-radius: 0;
    box-shadow: none;
}

.erp-student-table td {
    vertical-align: middle;
}

.erp-student-cell {
    display: flex;
    align-items: center;
    gap: 12px;
}

.erp-student-avatar {
    width: 38px;
    height: 38px;
    flex: 0 0 38px;
    display: grid;
    place-items: center;
    border-radius: 12px;
    background: linear-gradient(135deg, #17386b, #0d6efd);
    color: #fff;
    font-size: 0.86rem;
    font-weight: 800;
}

.erp-student-cell strong,
.erp-student-meta strong {
    display: block;
    font-size: 0.94rem;
    overflow-wrap: anywhere;
    word-break: break-word;
}

.erp-student-cell span,
.erp-student-meta span {
    display: block;
    margin-top: 4px;
    color: #6f7f97;
    font-size: 0.82rem;
    overflow-wrap: anywhere;
    word-break: break-word;
}

.erp-tag-row {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.erp-tag {
    display: inline-flex;
    align-items: center;
    padding: 5px 9px;
    border-radius: 999px;
    background: #eaf4ff;
    color: #0a4fb3;
    font-size: 0.8rem;
    font-weight: 700;
}

.erp-tag-muted {
    background: #edf2f7;
    color: #60708f;
}

.erp-count-pill {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 28px;
    height: 28px;
    padding: 0 10px;
    border-radius: 999px;
    background: #eef4ff;
    color: #0a4fb3;
    font-weight: 800;
}

.erp-empty-state {
    display: grid;
    gap: 6px;
    padding: 24px 12px;
    text-align: center;
}

.erp-empty-state strong {
    font-size: 1rem;
}

.erp-empty-state span {
    color: #6f7f97;
}

.erp-form-stack {
    display: grid;
    gap: 14px;
}

.erp-form-grid {
    padding: 14px;
}

.erp-checkbox-field {
    min-height: 54px;
    justify-content: center;
}

.erp-form-actions {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    justify-content: flex-end;
}

.erp-form-actions-left {
    justify-content: flex-start;
}

.profile-password-panel {
    overflow: visible;
}

.profile-password-layout {
    display: grid;
    grid-template-columns: 280px minmax(0, 1fr);
    gap: 14px;
    padding: 18px;
}

.profile-card {
    border: 1px solid #e7edf6;
    border-radius: 14px;
    background: #fff;
    padding: 20px;
    display: grid;
    justify-items: center;
    text-align: center;
    gap: 8px;
}

.profile-card-avatar {
    width: 88px;
    height: 88px;
    font-size: 1.55rem;
}

.school-settings-layout {
    display: grid;
    grid-template-columns: 280px minmax(0, 1fr);
    gap: 14px;
    padding: 18px;
}

.session-settings-layout {
    display: grid;
    grid-template-columns: 280px minmax(0, 1fr);
    gap: 14px;
    padding: 18px;
}

.session-settings-layout > * {
    min-width: 0;
}

.school-brand-card {
    border: 1px solid #e7edf6;
    border-radius: 14px;
    background: #fff;
    padding: 20px;
    display: grid;
    justify-items: center;
    text-align: center;
    gap: 10px;
}

.school-brand-logo,
.school-brand-placeholder {
    width: 104px;
    height: 104px;
    border-radius: 18px;
}

.school-brand-logo {
    object-fit: cover;
    border: 1px solid #dfe7f2;
    background: #fff;
}

.school-brand-placeholder {
    display: grid;
    place-items: center;
    background: #f1f5f9;
    color: #334155;
    font-size: 1.65rem;
    font-weight: 800;
}

.school-brand-card h3 {
    margin: 0;
    font-size: 1.05rem;
}

.school-brand-card p {
    margin: 0;
    color: #6f7f97;
    line-height: 1.6;
}

.school-signature-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 16px;
}

.school-signature-grid .student-file-preview {
    width: 180px;
    height: 72px;
}

.session-summary-card {
    border: 1px solid #dbe3ee;
    border-radius: 14px;
    background: #fff;
    padding: 20px;
    display: grid;
    gap: 12px;
    align-content: start;
    color: #f8fbff;
}

.session-summary-card h3 {
    margin: 0;
    font-size: 1.15rem;
    color: #1f3147;
    overflow-wrap: anywhere;
    word-break: break-word;
}

.session-summary-card p {
    margin: 0;
    color: #64748b;
    line-height: 1.6;
    overflow-wrap: anywhere;
}

.session-summary-card .eyebrow {
    color: #64748b;
}

.session-summary-list {
    display: grid;
    gap: 10px;
}

.session-summary-list > * {
    min-width: 0;
}

.session-summary-item {
    padding: 12px;
    border: 1px solid #dbe3ee;
    border-radius: 12px;
    background: #fff;
}

.session-summary-item:nth-child(3n + 1) {
    background: #fff;
    border-color: #dbe3ee;
}

.session-summary-item:nth-child(3n + 2) {
    background: #fff;
    border-color: #dbe3ee;
}

.session-summary-item:nth-child(3n + 3) {
    background: #fff;
    border-color: #dbe3ee;
}

.session-summary-item span {
    display: block;
    color: #6f7f97;
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.session-summary-item strong {
    display: block;
    margin-top: 8px;
    font-size: 0.96rem;
    overflow-wrap: anywhere;
    word-break: break-word;
}

.session-table-action {
    margin: 0;
}

.session-summary-card .hint code,
.erp-form-grid .hint code {
    font-family: inherit;
    font-weight: 700;
    color: inherit;
}

.backup-inline-form,
.backup-restore-form {
    margin: 0;
}

.backup-overview-grid {
    display: grid;
    gap: 14px;
    min-width: 0;
}

.backup-callout {
    border: 1px solid #dbe3ee;
    border-radius: 12px;
    background: #fff;
    padding: 14px 16px;
    display: grid;
    gap: 8px;
    min-width: 0;
    overflow: hidden;
}

.backup-callout:nth-child(3n + 1) {
    background: #fff;
    border-color: #dbe3ee;
}

.backup-callout:nth-child(3n + 2) {
    background: #fff;
    border-color: #dbe3ee;
}

.backup-callout:nth-child(3n + 3) {
    background: #fff;
    border-color: #dbe3ee;
}

.backup-callout strong {
    color: #1f3147;
    overflow-wrap: anywhere;
    word-break: break-word;
}

.backup-callout span {
    color: #64748b;
    line-height: 1.6;
    overflow-wrap: anywhere;
    word-break: break-word;
}

.backup-file-path {
    display: block;
    width: 100%;
    max-width: 100%;
    font-family: "Courier New", monospace;
    font-size: 0.82rem;
    color: #244a87;
    background: #eef4ff;
    border: 1px solid #d7e5ff;
    border-radius: 10px;
    padding: 6px 9px;
    overflow-wrap: anywhere;
    word-break: break-word;
}

.backup-callout code {
    color: inherit;
    font-weight: 700;
}

pre {
    white-space: pre-wrap;
    overflow-wrap: anywhere;
}

@media (max-width: 1400px) {
    .quicklinks-grid {
        grid-template-columns: repeat(4, minmax(180px, 1fr));
    }

    .dashboard-ribbon {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }

    .dashboard-summary-row {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media screen and (max-width: 1180px) {
    .dashboard-layout-grid {
        grid-template-columns: 1fr;
    }

    .breakdown-card {
        flex-direction: column;
        align-items: stretch;
    }

    .erp-search input {
        width: 210px;
    }

    .profile-password-layout {
        grid-template-columns: 1fr;
    }

    .school-settings-layout {
        grid-template-columns: 1fr;
    }

    .session-settings-layout {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 1080px) {
    .stats-grid,
    .module-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .quicklinks-grid {
        grid-template-columns: repeat(3, minmax(180px, 1fr));
    }
}

@media (max-width: 900px) {
    .auth-shell,
    .dashboard-shell,
    .license-card,
    .form-grid {
        grid-template-columns: 1fr;
    }

    .field-span-2 {
        grid-column: span 1;
    }

    .field-span-4 {
        grid-column: span 1;
    }

    .app-footer {
        flex-direction: column;
        text-align: center;
    }

    .erp-shell {
        grid-template-columns: 1fr;
    }

    .erp-sidebar {
        position: fixed;
        left: 0;
        top: 0;
        bottom: 0;
        width: 320px;
        max-width: calc(100vw - 24px);
        transform: translateX(-100%);
        transition: transform 0.24s ease;
        box-shadow: 0 20px 60px rgba(17, 31, 54, 0.18);
    }

    body.sidebar-open .erp-sidebar {
        transform: translateX(0);
        opacity: 1;
        visibility: visible;
        pointer-events: auto;
    }

    .erp-mobile-toggle {
        display: inline-flex;
    }

    .erp-sidebar-desktop-toggle {
        display: none;
    }

    .erp-topbar {
        flex-wrap: wrap;
        height: auto;
        padding: 10px 14px;
    }

    .erp-topbar-right {
        width: 100%;
        justify-content: flex-start;
        flex-wrap: wrap;
    }

    .erp-profile-dropdown {
        right: auto;
        left: 0;
        width: min(280px, calc(100vw - 40px));
    }

    .erp-search {
        width: min(100%, 320px);
    }

    .erp-search input {
        width: 100%;
    }

    .datatable-toolbar,
    .datatable-toolbar-actions,
    .datatable-pagination {
        justify-content: flex-start;
    }

    .datatable-search,
    .datatable-page-size {
        width: 100%;
    }

    .datatable-search input,
    .datatable-page-size select {
        width: 100%;
    }

    .quicklinks-grid {
        grid-template-columns: repeat(2, minmax(180px, 1fr));
    }

    .dashboard-ribbon,
    .dashboard-summary-row,
    .form-grid {
        grid-template-columns: 1fr;
    }

    .breakdown-donut {
        width: 160px;
        height: 160px;
        flex-basis: 160px;
    }

    .sidebar {
        display: none;
    }

    .topbar,
    .section-header,
    .actions-row {
        flex-direction: column;
        align-items: start;
    }
}

@media (max-width: 640px) {
    .stats-grid,
    .module-grid,
    .document-row {
        grid-template-columns: 1fr;
    }

    .admission-compact-grid {
        grid-template-columns: 1fr;
    }

    .student-entry-grid {
        grid-template-columns: 1fr;
    }

    .student-entry-form .field-span-2,
    .student-entry-form .field-span-4 {
        grid-column: span 1;
    }

    .quicklinks-grid {
        grid-template-columns: 1fr;
    }

    .erp-content {
        padding: 10px;
    }

    .bars-chart {
        gap: 5px;
        padding: 16px 12px 12px;
    }

    .dashboard-panel-header,
    .quicklinks-panel-header,
    .section-header,
    .actions-row {
        flex-direction: column;
        align-items: start;
    }

    .session-chart-labels {
        grid-template-columns: repeat(6, minmax(0, 1fr));
    }

    .auth-brand,
    .auth-card,
    .page-shell {
        padding: 22px;
    }
}

.form-page-header {
    position: relative;
    display: flex;
    justify-content: space-between;
    align-items: start;
    gap: 16px;
    padding: 20px 22px;
    margin-bottom: 16px;
    background:
        radial-gradient(circle at top right, var(--module-hero-radial-top), transparent 30%),
        radial-gradient(circle at bottom left, var(--module-hero-radial-bottom), transparent 34%),
        var(--module-hero-surface);
    border: 1px solid var(--module-hero-border);
    border-radius: 18px;
    box-shadow: var(--module-hero-shadow);
    overflow: hidden;
}

.form-page-header::before {
    content: "";
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 7px;
    background: var(--module-hero-highlight);
}

.form-page-header::after {
    content: "";
    position: absolute;
    top: -78px;
    right: -46px;
    width: 220px;
    height: 220px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(255, 255, 255, 0.74) 0%, rgba(255, 255, 255, 0.16) 46%, transparent 72%);
}

.form-page-header-main {
    display: flex;
    align-items: start;
    gap: 18px;
    min-width: 0;
    position: relative;
    z-index: 1;
}

.form-page-header-main > div {
    min-width: 0;
    flex: 1 1 auto;
}

.form-page-header h2 {
    margin: 0;
    font-size: clamp(1.32rem, 1.8vw, 1.64rem);
    color: var(--module-title-strong);
    letter-spacing: -0.02em;
}

.form-page-header p {
    margin: 8px 0 0;
    color: var(--module-title-soft);
    max-width: 880px;
}

.form-page-header-actions {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
    justify-content: flex-end;
    align-content: flex-start;
    position: relative;
    z-index: 1;
}

.form-page-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 14px;
}

.form-page-meta span,
.form-section-tag {
    display: inline-flex;
    align-items: center;
    min-height: 32px;
    padding: 6px 12px;
    border: 1px solid rgba(181, 203, 226, 0.92);
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.76);
    color: #22486f;
    font-size: 0.78rem;
    font-weight: 600;
    white-space: nowrap;
    box-shadow: 0 10px 18px rgba(15, 23, 42, 0.05);
    backdrop-filter: blur(10px);
}

.form-page-meta span:nth-child(4n + 1) {
    background: linear-gradient(135deg, rgba(224, 242, 254, 0.96), rgba(219, 234, 254, 0.9));
}

.form-page-meta span:nth-child(4n + 2) {
    background: linear-gradient(135deg, rgba(220, 252, 231, 0.95), rgba(204, 251, 241, 0.88));
}

.form-page-meta span:nth-child(4n + 3) {
    background: linear-gradient(135deg, rgba(254, 243, 199, 0.96), rgba(255, 236, 179, 0.9));
}

.form-page-meta span:nth-child(4n + 4) {
    background: linear-gradient(135deg, rgba(243, 232, 255, 0.96), rgba(224, 231, 255, 0.9));
}

.erp-form-stack {
    gap: 12px;
}

.erp-form-stack > .dashboard-panel,
form.dashboard-panel {
    border: 1px solid #dbe3ee;
    border-radius: 14px;
    background: #fff;
    box-shadow: none;
    overflow: hidden;
}

.dashboard-panel > form.erp-form-stack {
    padding: 12px 14px 16px;
}

.dashboard-panel > .alert {
    margin: 12px 14px 16px;
}

.erp-form-stack > .dashboard-panel .dashboard-panel-header,
form.dashboard-panel .dashboard-panel-header {
    padding: 14px 16px 10px;
    border-bottom: 1px dashed #d5e2ef;
    background: linear-gradient(135deg, rgba(14, 165, 233, 0.06), rgba(255, 255, 255, 0.95), rgba(251, 191, 36, 0.08));
}

.erp-form-stack > .dashboard-panel .dashboard-panel-header h2,
form.dashboard-panel .dashboard-panel-header h2 {
    font-size: 1rem;
    color: #1f3147;
}

.erp-form-stack > .dashboard-panel .dashboard-panel-header p,
form.dashboard-panel .dashboard-panel-header p {
    margin-top: 4px;
    color: #64748b;
    font-size: 0.88rem;
}

.erp-form-stack .erp-form-grid,
form.dashboard-panel .erp-form-grid {
    padding: 8px 14px 9px;
    gap: 6px 12px;
}

.erp-form-stack .field,
form.dashboard-panel .field {
    min-width: 0;
    padding: 0;
    border: 0;
    background: transparent;
    box-shadow: none;
}

.erp-form-stack .field label,
form.dashboard-panel .field label {
    margin-bottom: 2px;
    color: #334155;
    font-size: 0.9rem;
    font-weight: 600;
}

.erp-form-stack .field input,
.erp-form-stack .field select,
.erp-form-stack .field textarea,
form.dashboard-panel .field input,
form.dashboard-panel .field select,
form.dashboard-panel .field textarea,
.erp-form-stack .academic-static-value {
    width: 100%;
    min-height: 42px;
    padding: 10px 12px;
    border: 1px solid #cfd8e3;
    border-radius: 12px;
    background: #fff;
    color: #1f2937;
    box-shadow: none;
}

.erp-form-stack .field textarea,
form.dashboard-panel .field textarea {
    min-height: 76px;
}

.erp-form-stack .field input:focus,
.erp-form-stack .field select:focus,
.erp-form-stack .field textarea:focus,
form.dashboard-panel .field input:focus,
form.dashboard-panel .field select:focus,
form.dashboard-panel .field textarea:focus {
    border-color: #94a3b8;
    box-shadow: 0 0 0 3px rgba(148, 163, 184, 0.16);
}

.erp-form-stack .hint,
form.dashboard-panel .hint {
    margin-top: 5px;
    font-size: 0.82rem;
    font-weight: 500;
    color: #64748b;
}

.erp-form-stack .error-text,
form.dashboard-panel .error-text {
    min-height: 16px;
    margin-top: 4px;
    font-size: 0.82rem;
}

.erp-form-stack .hint code,
form.dashboard-panel .hint code {
    color: inherit;
}

.erp-form-stack .checkbox-field,
form.dashboard-panel .checkbox-field,
.erp-form-stack .student-entry-check {
    display: flex;
    align-items: end;
    min-height: 0;
}

.erp-form-stack .checkbox-field label,
form.dashboard-panel .checkbox-field label,
.student-entry-inline {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    margin: 0;
    min-height: 42px;
    color: #334155;
    font-size: 0.9rem;
}

.erp-form-stack .checkbox-field input,
form.dashboard-panel .checkbox-field input,
.student-entry-inline input {
    width: auto;
    min-height: 0;
    margin: 0;
}

.erp-form-stack input[type="checkbox"],
form.dashboard-panel input[type="checkbox"],
.student-entry-inline input[type="checkbox"] {
    width: 16px;
    height: 16px;
    min-height: 16px;
    padding: 0;
    margin: 0;
    flex: 0 0 16px;
}

.erp-form-stack .dashboard-panel-total,
form.dashboard-panel .dashboard-panel-total {
    text-align: right;
}

.student-entry-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
}

.student-entry-form .field-span-2 {
    grid-column: span 2;
}

.student-entry-form .field-span-4 {
    grid-column: 1 / -1;
}

.student-entry-upload-box {
    border: 1px solid #dbe3ee;
    border-radius: 12px;
    padding: 14px;
    background: #fff;
}

.student-entry-upload-box h3 {
    margin: 0;
    font-size: 1rem;
    color: #1f3147;
}

.student-entry-upload-box p {
    margin: 6px 0 0;
    color: #64748b;
    font-size: 0.88rem;
}

.student-entry-inline-alert {
    margin: 0 0 12px;
}

.student-file-preview {
    width: 96px;
    height: 96px;
    margin-top: 10px;
    border: 1px solid #dbe3ee;
    border-radius: 12px;
    background: #f8fafc;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.student-file-preview img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.student-file-preview-signature img {
    object-fit: contain;
    background: #fff;
}

.student-file-preview-empty {
    padding: 10px;
    color: #64748b;
    font-size: 0.78rem;
    text-align: center;
}

.student-directory-filter-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 12px;
}

.student-directory-filter-search {
    grid-column: 1 / -1;
}

.student-directory-toolbar-actions {
    display: flex;
    align-items: end;
    justify-content: space-between;
    gap: 12px;
    padding: 0 18px 18px;
}

.student-directory-page-size {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    min-height: 42px;
    padding: 6px 8px 6px 12px;
    border: 1px solid #dbe3ee;
    border-radius: 14px;
    background: #fff;
    color: #475569;
    font-weight: 600;
}

.student-directory-page-size label {
    margin: 0;
    white-space: nowrap;
}

.student-directory-page-size select {
    min-width: 90px;
    min-height: 34px;
    padding: 7px 32px 7px 10px;
    border: 1px solid #cfd8e3;
    border-radius: 10px;
    background: #f8fafc;
    color: #1f3147;
    font-weight: 700;
}

.student-directory-wrap {
    overflow-x: auto;
}

.student-directory-table {
    min-width: 1320px;
}

.student-directory-sort {
    border: 0;
    background: transparent;
    color: inherit;
    font: inherit;
    font-weight: 700;
    padding: 0;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.student-directory-sort::after {
    content: "↕";
    color: #94a3b8;
    font-size: 0.85rem;
}

.student-directory-sort[data-sort-direction="asc"]::after {
    content: "↑";
    color: #0a4fb3;
}

.student-directory-sort[data-sort-direction="desc"]::after {
    content: "↓";
    color: #0a4fb3;
}

.student-directory-column-search-row th {
    background: #ffffff;
    padding-top: 10px;
    padding-bottom: 10px;
}

.student-directory-column-search-row input {
    width: 100%;
    min-height: 38px;
    padding: 8px 10px;
    border: 1px solid #d7e0ea;
    border-radius: 10px;
    background: #fff;
}

.student-directory-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.student-directory-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    padding: 14px 16px 16px;
    border-top: 1px solid #e5ebf3;
}

.student-directory-info {
    color: #64748b;
    font-weight: 600;
}

.student-directory-pagination {
    display: flex;
    align-items: center;
    gap: 10px;
}

.button-danger-soft {
    border: 1px solid #f2c8d0;
    color: #b4233e;
    background: #fff5f7;
}

.erp-tag-success {
    background: #e9f8ef;
    color: #157347;
}

.erp-tag-danger {
    background: #fff0f2;
    color: #b4233e;
}

body.erp-modal-open {
    overflow: hidden;
}

.erp-modal {
    position: fixed;
    inset: 0;
    z-index: 70;
    display: grid;
    place-items: center;
    padding: 20px;
}

.erp-modal[hidden] {
    display: none;
}

.erp-modal-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(15, 23, 42, 0.48);
    backdrop-filter: blur(2px);
}

.erp-modal-dialog {
    position: relative;
    z-index: 1;
    width: min(1100px, 100%);
    max-height: calc(100vh - 40px);
    overflow: auto;
    border: 1px solid #dbe3ee;
    border-radius: 18px;
    background: #ffffff;
    box-shadow: 0 24px 60px rgba(15, 23, 42, 0.22);
}

.student-directory-modal-dialog {
    width: min(1180px, 100%);
}

.student-disable-modal-dialog {
    width: min(720px, 100%);
}

.erp-modal-header,
.erp-modal-footer {
    display: flex;
    align-items: start;
    justify-content: space-between;
    gap: 14px;
    padding: 18px 20px;
}

.erp-modal-header {
    position: relative;
    border-bottom: 1px solid #e5ebf3;
    background: var(--panel-header-surface);
    overflow: hidden;
}

.erp-modal-header::before {
    content: "";
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 6px;
    background: var(--hero-highlight);
}

.erp-modal-footer {
    border-top: 1px solid #e5ebf3;
    justify-content: flex-end;
    background: linear-gradient(180deg, #ffffff 0%, #f9fbff 100%);
}

.erp-modal-header h2 {
    margin: 0;
    font-size: 1.2rem;
    color: var(--title-strong);
}

.erp-modal-header p {
    margin: 6px 0 0;
    color: var(--title-soft);
}

.erp-modal-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.erp-modal-body {
    padding: 20px;
}

.student-disable-form {
    gap: 0;
}

.student-disable-grid {
    padding: 18px 20px 20px;
}

.student-profile-card {
    display: grid;
    gap: 16px;
}

.student-profile-card-header {
    display: flex;
    align-items: start;
    justify-content: space-between;
    gap: 16px;
    padding-bottom: 16px;
    border-bottom: 1px solid #e5ebf3;
}

.student-profile-identity {
    display: flex;
    align-items: start;
    gap: 16px;
    min-width: 0;
}

.student-profile-identity h3 {
    margin: 0;
    font-size: 1.25rem;
    color: #1f3147;
}

.student-profile-identity p {
    margin: 6px 0 0;
    color: #64748b;
}

.student-profile-photo,
.student-profile-photo-placeholder {
    width: 84px;
    height: 84px;
    border-radius: 20px;
    flex: 0 0 84px;
}

.student-profile-photo {
    object-fit: cover;
    border: 1px solid #dbe3ee;
    background: #fff;
}

.student-profile-photo-placeholder {
    font-size: 1.2rem;
}

.student-profile-signature-block {
    display: grid;
    gap: 8px;
    justify-items: end;
    color: #64748b;
    font-size: 0.82rem;
    font-weight: 700;
}

.student-profile-signature {
    width: 140px;
    height: 56px;
    object-fit: contain;
    border: 1px solid #dbe3ee;
    border-radius: 12px;
    background: #fff;
    padding: 6px;
}

.student-profile-section-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
}

.student-profile-section {
    border: 1px solid #dbe3ee;
    border-radius: 16px;
    padding: 16px;
    background: #fff;
}

.student-profile-section-wide {
    grid-column: 1 / -1;
}

.student-profile-section h4 {
    margin: 0 0 12px;
    font-size: 1rem;
    color: #1f3147;
}

.student-profile-detail-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px 14px;
}

.student-profile-detail-grid > div {
    min-width: 0;
    border: 1px solid #e6edf5;
    border-radius: 12px;
    padding: 11px 12px;
    background: #fbfdff;
}

.student-profile-detail-grid span {
    display: block;
    color: #64748b;
    font-size: 0.78rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.03em;
}

.student-profile-detail-grid strong {
    display: block;
    margin-top: 6px;
    color: #1f3147;
    overflow-wrap: anywhere;
}

.student-family-photo-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 14px;
}

.student-family-photo-card {
    display: grid;
    gap: 10px;
    padding: 12px;
    border: 1px solid #e6edf5;
    border-radius: 14px;
    background: #fbfdff;
}

.student-family-photo-card span {
    color: #64748b;
    font-size: 0.78rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.03em;
}

.student-family-photo-card img,
.student-family-photo-placeholder {
    width: 100%;
    aspect-ratio: 1 / 1;
    border-radius: 14px;
    border: 1px solid #dbe3ee;
    background: #fff;
}

.student-family-photo-card img {
    object-fit: cover;
}

.student-family-photo-placeholder {
    display: grid;
    place-items: center;
    padding: 12px;
    color: #64748b;
    font-size: 0.9rem;
    font-weight: 600;
    text-align: center;
}

.bonafide-certificate-print-sheet {
    display: grid;
    place-items: center;
    min-height: 100vh;
    padding: 24px;
    background: #f8f2e7;
}

.bonafide-certificate {
    position: relative;
    width: min(1120px, 100%);
    min-height: 790px;
    padding: 56px 66px 52px;
    display: flex;
    flex-direction: column;
    gap: 20px;
    overflow: hidden;
    background: #fffdf9;
    color: #5b3413;
    box-shadow: 0 24px 48px rgba(90, 52, 19, 0.12);
    font-family: "Georgia", "Times New Roman", serif;
}

.bonafide-certificate > :not(.bonafide-certificate-border) {
    position: relative;
    z-index: 1;
}

.bonafide-certificate-border {
    position: absolute;
    inset: 0;
    z-index: 0;
    width: 100%;
    height: 100%;
    object-fit: fill;
    pointer-events: none;
}

.bonafide-certificate-header {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 24px;
    align-items: start;
}

.bonafide-certificate-school-brand {
    display: grid;
    grid-template-columns: 86px minmax(0, 1fr);
    gap: 16px;
    align-items: center;
}

.bonafide-certificate-logo {
    width: 86px;
    height: 86px;
    display: grid;
    place-items: center;
    border: 1px solid rgba(212, 146, 54, 0.5);
    background: rgba(255, 248, 237, 0.86);
    color: #b86a14;
    font-size: 1.15rem;
    font-weight: 800;
}

.bonafide-certificate-logo img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.bonafide-certificate-school-copy h2 {
    margin: 0;
    color: #8d4d14;
    font-size: clamp(1.7rem, 3vw, 2.4rem);
    font-weight: 800;
    line-height: 1.12;
    text-transform: uppercase;
    letter-spacing: 0.03em;
}

.bonafide-certificate-school-copy p {
    margin: 5px 0 0;
    color: #6d4820;
    font-size: 0.95rem;
    font-weight: 600;
    line-height: 1.45;
}

.bonafide-certificate-meta {
    display: grid;
    gap: 4px;
    justify-items: end;
    align-content: start;
    padding-top: 8px;
}

.bonafide-certificate-meta span {
    color: #9f6a2e;
    font-size: 0.78rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.08em;
}

.bonafide-certificate-meta strong {
    color: #5b3413;
    font-size: 1rem;
    font-weight: 700;
}

.bonafide-certificate-title {
    display: grid;
    justify-items: center;
    gap: 6px;
    text-align: center;
}

.bonafide-certificate-title h1 {
    margin: 0;
    color: #9a5a19;
    font-size: clamp(1.6rem, 3vw, 2.3rem);
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.16em;
}

.bonafide-certificate-title p {
    margin: 0;
    color: #836145;
    font-size: 0.92rem;
    font-weight: 600;
}

.bonafide-certificate-body {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 158px;
    gap: 26px;
    align-items: start;
}

.bonafide-certificate-copy p {
    margin: 0;
    color: #5b3413;
    font-size: 1.08rem;
    line-height: 1.85;
    text-align: justify;
}

.bonafide-certificate-copy strong {
    color: #8b4d12;
    font-weight: 800;
}

.bonafide-certificate-photo-block {
    display: grid;
    gap: 8px;
    justify-items: center;
}

.bonafide-certificate-photo {
    width: 158px;
    height: 188px;
    border: 1px solid rgba(195, 134, 48, 0.55);
    background: rgba(255, 248, 239, 0.96);
    object-fit: cover;
}

.bonafide-certificate-photo-placeholder {
    display: grid;
    place-items: center;
    padding: 12px;
    color: #9b6325;
    font-size: 0.92rem;
    font-weight: 700;
    text-align: center;
}

.bonafide-certificate-facts {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 12px;
}

.bonafide-certificate-facts > div {
    min-width: 0;
    padding: 12px 14px;
    border: 1px solid rgba(208, 145, 56, 0.32);
    background: rgba(255, 250, 243, 0.9);
}

.bonafide-certificate-facts span {
    display: block;
    color: #9a6930;
    font-size: 0.73rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.08em;
}

.bonafide-certificate-facts strong {
    display: block;
    margin-top: 6px;
    color: #5b3413;
    font-size: 1rem;
    font-weight: 700;
    line-height: 1.4;
    overflow-wrap: anywhere;
}

.bonafide-certificate-fact-wide {
    grid-column: span 2;
}

.bonafide-certificate-footer {
    margin-top: auto;
    display: flex;
    justify-content: flex-end;
    padding-top: 18px;
}

.bonafide-certificate-signature {
    width: 240px;
    text-align: center;
}

.bonafide-certificate-signature span {
    display: block;
    height: 36px;
    border-bottom: 1px solid #9d6328;
}

.bonafide-certificate-signature strong,
.bonafide-certificate-signature small {
    display: block;
    margin-top: 6px;
}

.bonafide-certificate-signature strong {
    color: #5b3413;
    font-size: 1rem;
    font-weight: 700;
}

.bonafide-certificate-signature small {
    color: #8c683f;
    font-size: 0.85rem;
    font-weight: 600;
}

.erp-form-stack .erp-form-actions {
    padding-top: 4px;
}

.erp-form-stack .button-secondary,
form.dashboard-panel .button-secondary,
.form-page-header .button-secondary,
.auth-card .button-secondary {
    background: rgba(255, 255, 255, 0.82);
    border: 1px solid rgba(176, 198, 223, 0.96);
    color: var(--title-strong);
    box-shadow: 0 10px 22px rgba(15, 23, 42, 0.06);
    backdrop-filter: blur(10px);
}

.form-page-header .button-secondary:hover,
.form-page-header .button-primary:hover {
    transform: translateY(-1px);
    box-shadow: 0 14px 26px rgba(15, 23, 42, 0.09);
}

.form-page-header .button-secondary:hover {
    background: #ffffff;
    border-color: rgba(134, 173, 211, 0.96);
}

.erp-form-stack .erp-tag,
.auth-card .erp-tag {
    background: #f8fafc;
    color: #475569;
    border: 1px solid #dbe3ee;
}

.erp-form-stack .erp-tag-muted,
.auth-card .erp-tag-muted {
    background: #f8fafc;
    color: #64748b;
}

.erp-form-stack .text-link,
.auth-card .text-link {
    color: #475569;
}

.auth-form-stack {
    gap: 12px;
}

.auth-form-grid {
    padding: 0;
    gap: 12px 16px;
}

.auth-form-panel {
    border: 1px solid #dbe3ee;
    border-radius: 14px;
    padding: 14px 16px 16px;
    background: #fff;
}

.auth-form-panel .section-header {
    margin-bottom: 12px;
}

.auth-form-panel .section-header h3 {
    font-size: 1rem;
    color: #1f3147;
}

.auth-inline-actions {
    padding-top: 2px;
}

.auth-card .captcha-wrap {
    align-items: start;
    justify-content: flex-start;
}

.erp-form-stack .selection-grid {
    padding: 14px 18px 18px;
    gap: 12px;
}

.erp-form-stack .selection-option {
    border: 1px solid #dbe3ee;
    border-radius: 12px;
    background: #fff;
    box-shadow: none;
}

.erp-form-stack .selection-option:nth-child(3n + 1),
.erp-form-stack .selection-option:nth-child(3n + 2),
.erp-form-stack .selection-option:nth-child(3n + 3) {
    border-color: #dbe3ee;
    background: #fff;
}

.erp-form-stack .selection-option-title {
    color: #1f3147;
}

.erp-form-stack .selection-option-meta {
    color: #64748b;
}

.erp-form-stack .academic-mark-input {
    border: 1px solid #cfd8e3;
    background: #fff;
    color: #1f2937;
    box-shadow: none;
}

.erp-form-stack .academic-mark-input:focus {
    border-color: #94a3b8;
    box-shadow: 0 0 0 3px rgba(148, 163, 184, 0.16);
    transform: none;
}

.erp-form-stack .session-summary-card {
    border: 1px solid #dbe3ee;
    background: #fff;
    color: #1f3147;
}

.erp-form-stack .session-summary-card h3 {
    color: #1f3147;
}

.erp-form-stack .session-summary-card p,
.erp-form-stack .session-summary-card .eyebrow {
    color: #64748b;
}

.erp-form-stack .session-summary-item,
.erp-form-stack .session-summary-item:nth-child(3n + 1),
.erp-form-stack .session-summary-item:nth-child(3n + 2),
.erp-form-stack .session-summary-item:nth-child(3n + 3) {
    border-color: #dbe3ee;
    background: #fff;
}

.erp-form-stack .session-summary-item span,
.erp-form-stack .session-summary-item strong {
    color: #475569;
}

.exam-schedule-wrap {
    padding: 0;
}

.exam-schedule-table input[type="date"],
.exam-schedule-table input[type="time"] {
    width: 100%;
    min-height: 38px;
    padding: 8px 10px;
    border: 1px solid #cfd8e3;
    border-radius: 10px;
    background: #fff;
}

.marks-grade-layout {
    display: grid;
    grid-template-columns: minmax(0, 1.7fr) minmax(320px, 1fr);
    gap: 14px;
    align-items: start;
}

.marks-grade-panel-body {
    display: grid;
    gap: 14px;
    padding: 14px 18px 18px;
}

.marks-grade-section-error {
    min-height: 0;
    margin-top: 0;
}

.marks-grade-table,
.marks-grade-result-table {
    table-layout: fixed;
}

.marks-grade-table th:nth-child(1) {
    width: 34%;
}

.marks-grade-table th:nth-child(2) {
    width: 18%;
}

.marks-grade-table th:nth-child(3) {
    width: 48%;
}

.marks-grade-result-table th:nth-child(1) {
    width: 28%;
}

.marks-grade-result-table th:nth-child(2) {
    width: 72%;
}

.marks-grade-table td,
.marks-grade-result-table td {
    vertical-align: top;
}

.marks-grade-table .academic-mark-input,
.marks-grade-result-table .academic-mark-input {
    min-width: 0;
}

.marks-grade-range-fields {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
    align-items: center;
    gap: 8px;
}

.marks-grade-range-divider {
    color: #64748b;
    font-size: 0.82rem;
    font-weight: 700;
    text-transform: uppercase;
}

.marks-grade-grade-cell,
.marks-grade-code-cell {
    min-width: 0;
}

.marks-grade-grade-input,
.marks-grade-code-input {
    text-align: center;
    font-weight: 700;
}

.marks-grade-legend {
    display: grid;
    gap: 10px;
}

.marks-grade-legend-item {
    display: grid;
    grid-template-columns: 78px minmax(0, 1fr);
    gap: 10px;
    align-items: center;
    padding: 12px 14px;
    border: 1px solid #dbe3ee;
    border-radius: 12px;
    background: #fff;
}

.marks-grade-legend-item strong {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 38px;
    padding: 0 10px;
    border-radius: 10px;
    background: #f8fafc;
    border: 1px solid #dbe3ee;
    color: #1f3147;
}

.marks-grade-legend-item span {
    color: #475569;
    overflow-wrap: anywhere;
}

.marks-grade-legend-empty strong {
    justify-content: flex-start;
    background: transparent;
    border: 0;
    padding: 0;
}

.exam-result-entry-wrap,
.exam-result-generation-wrap {
    padding: 0;
}

.exam-result-entry-actions {
    padding-inline: 18px;
}

.exam-result-entry-actions-top {
    padding-bottom: 14px;
    border-bottom: 1px dashed #dbe3ee;
}

.exam-result-entry-actions-bottom {
    padding-top: 16px;
    padding-bottom: 18px;
    border-top: 1px solid #edf1f6;
}

.exam-result-entry-table {
    min-width: 1400px;
}

.exam-result-generation-table {
    min-width: 1180px;
}

.exam-result-entry-table th,
.exam-result-entry-table td,
.exam-result-generation-table th,
.exam-result-generation-table td {
    vertical-align: top;
}

.exam-result-subject-head {
    display: grid;
    gap: 4px;
    min-width: 88px;
}

.exam-result-subject-head strong {
    color: #1f3147;
    overflow-wrap: anywhere;
}

.exam-result-subject-head span,
.exam-result-subject-head small {
    color: #64748b;
    font-size: 0.78rem;
    overflow-wrap: anywhere;
}

.exam-result-mark-input {
    width: 100%;
    min-width: 0;
    text-align: center;
}

.exam-result-mark-stack {
    display: grid;
    gap: 6px;
    min-width: 152px;
}

.exam-result-mark-field {
    display: grid;
    gap: 4px;
}

.exam-result-mark-field > span {
    color: #475569;
    font-size: 0.72rem;
    font-weight: 800;
    line-height: 1.2;
    text-transform: uppercase;
}

.exam-result-mark-limit {
    color: #64748b;
    font-size: 0.72rem;
    line-height: 1.25;
}

.exam-result-mark-field.is-disabled .exam-result-mark-input {
    background: #f8fafc;
    color: #94a3b8;
    cursor: not-allowed;
}

.exam-result-mark-stack .error-text {
    min-height: 0;
    margin-top: 0;
}

.exam-result-generation-body {
    display: grid;
    gap: 14px;
    padding: 14px 18px 18px;
}

.exam-result-summary-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 12px;
}

.exam-result-summary-card {
    padding: 16px 18px;
}

.exam-result-summary-card h3 {
    font-size: 1.45rem;
}

.exam-result-config-note {
    display: flex;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
    padding: 14px 16px;
    border: 1px solid #dbe3ee;
    border-radius: 12px;
    background: #fff;
}

.exam-result-config-note strong {
    color: #1f3147;
}

.exam-result-config-note span {
    color: #64748b;
}

.exam-result-generation-table select,
.exam-result-generation-table input {
    width: 100%;
    min-width: 140px;
    min-height: 40px;
    padding: 9px 11px;
    border: 1px solid #cfd8e3;
    border-radius: 10px;
    background: #fff;
}

.exam-result-generation-table select:focus,
.exam-result-generation-table input:focus {
    outline: none;
    border-color: #94a3b8;
    box-shadow: 0 0 0 3px rgba(148, 163, 184, 0.16);
}

.exam-result-generation-table select:disabled,
.exam-result-generation-table input:disabled {
    background: #f8fafc;
    color: #94a3b8;
    cursor: not-allowed;
}

.exam-result-status-text {
    display: block;
    margin-top: 8px;
    color: #64748b;
    font-size: 0.79rem;
    line-height: 1.4;
}

.exam-result-section-error {
    min-height: 0;
    margin-top: 0;
}

.admit-card-filter-grid {
    grid-template-columns: repeat(5, minmax(0, 1fr));
}

.admit-card-print-panel {
    background: #fff;
}

.admit-card-print-area {
    display: grid;
    gap: 14px;
    padding: 16px;
}

.exam-admit-card {
    position: relative;
    width: 100%;
    max-width: 930px;
    min-height: 520px;
    margin: 0 auto;
    padding: 18px;
    border: 2px solid #020617;
    outline: 4px double #0f172a;
    outline-offset: -8px;
    background: #fff;
    box-shadow: inset 0 0 0 2px #fff, inset 0 0 0 5px rgba(15, 23, 42, 0.22);
    color: #0f172a;
    font-family: "Inter", "Segoe UI", sans-serif;
    break-inside: avoid;
    page-break-inside: avoid;
    overflow: hidden;
}

.exam-admit-card > :not(.exam-admit-card-watermark) {
    position: relative;
    z-index: 1;
}

.exam-admit-card-watermark {
    position: absolute;
    left: 50%;
    top: 53%;
    z-index: 0;
    width: min(330px, 48%);
    max-height: 78%;
    object-fit: contain;
    opacity: 0.055;
    transform: translate(-50%, -50%);
    pointer-events: none;
}

.exam-admit-card-school {
    display: grid;
    grid-template-columns: 88px 1fr 88px;
    gap: 14px;
    align-items: center;
    padding: 6px 8px 10px;
    border-bottom: 2px solid #0f172a;
    text-align: center;
}

.exam-admit-card-logo {
    width: 78px;
    height: 78px;
    display: grid;
    place-items: center;
    border: 0;
    background: transparent;
    font-weight: 800;
}

.exam-admit-card-logo img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.exam-admit-card-school-info h2 {
    margin: 0;
    color: #06142d;
    font-size: clamp(1.1rem, 2.4vw, 1.6rem);
    font-weight: 900;
    line-height: 1.08;
    text-transform: uppercase;
    letter-spacing: 0.045em;
    white-space: nowrap;
}

.exam-admit-card-school-info p {
    margin: 3px 0;
    color: #111827;
    font-size: 0.86rem;
    font-weight: 600;
    line-height: 1.3;
}

.exam-admit-card-title {
    display: grid;
    justify-items: center;
    gap: 2px;
    padding: 8px 0;
}

.exam-admit-card-title h1 {
    margin: 0;
    padding: 5px 34px;
    border: 2px solid #0f172a;
    background: rgba(255, 255, 255, 0.9);
    font-size: 1.05rem;
    font-weight: 900;
    letter-spacing: 0.14em;
}

.exam-admit-card-title p {
    margin: 0;
    color: #0f172a;
    font-size: 0.95rem;
    font-weight: 800;
}

.exam-admit-card-title .exam-admit-card-no {
    font-size: 0.72rem;
    font-weight: 800;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.exam-admit-card-qr {
    display: grid;
    justify-items: center;
    align-content: center;
    gap: 3px;
    min-width: 78px;
}

.exam-admit-card-qr .qr-code-svg {
    width: 70px;
    height: 70px;
    display: block;
    border: 1px solid #e2e8f0;
}

.exam-admit-card-qr small {
    max-width: 86px;
    color: #0f172a;
    font-size: 0.54rem;
    font-weight: 900;
    line-height: 1.1;
    text-align: center;
    overflow-wrap: anywhere;
}

.exam-admit-card-student {
    display: grid;
    grid-template-columns: 1fr 92px;
    gap: 12px;
    align-items: start;
    margin-bottom: 8px;
}

.exam-admit-card-details {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    border: 1px solid #0f172a;
    background: rgba(255, 255, 255, 0.88);
}

.exam-admit-card-details > div {
    min-height: 42px;
    padding: 5px 7px;
    border-right: 1px solid #0f172a;
    border-bottom: 1px solid #0f172a;
}

.exam-admit-card-details > div:nth-child(3n) {
    border-right: 0;
}

.exam-admit-card-details > div:nth-last-child(-n + 3) {
    border-bottom: 0;
}

.exam-admit-card-details span {
    display: block;
    font-size: 0.62rem;
    font-weight: 800;
    text-transform: uppercase;
}

.exam-admit-card-details strong {
    display: block;
    margin-top: 3px;
    font-size: 1.08rem;
    font-weight: 900;
    line-height: 1.18;
    overflow-wrap: anywhere;
}

.exam-admit-card-detail-primary strong {
    font-size: 1.2rem;
    font-weight: 900;
}

.exam-admit-card-photo {
    width: 92px;
    height: 104px;
    display: grid;
    place-items: center;
    border: 1px solid #0f172a;
    background: rgba(255, 255, 255, 0.9);
    font-size: 0.72rem;
    font-weight: 800;
}

.exam-admit-card-photo img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.exam-admit-card-routine {
    width: 100%;
    border-collapse: collapse;
    background: rgba(255, 255, 255, 0.9);
    font-size: 0.9rem;
}

.exam-admit-card-schedule-title {
    margin: 8px 0 5px;
    color: #0f172a;
    font-size: 0.76rem;
    font-weight: 900;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.exam-admit-card-routine th,
.exam-admit-card-routine td {
    padding: 5px 7px;
    border: 1px solid #0f172a;
    text-align: left;
}

.exam-admit-card-routine th {
    background: rgba(248, 250, 252, 0.96);
    font-size: 0.68rem;
    font-weight: 900;
    text-transform: uppercase;
}

.exam-admit-card-routine td:first-child {
    font-size: 0.98rem;
    font-weight: 900;
}

.exam-admit-card-footer {
    display: grid;
    grid-template-columns: 1fr 1fr;
    align-items: end;
    gap: 24px;
    width: 100%;
    margin-top: 20px;
}

.exam-admit-card-footer > div {
    width: 190px;
    text-align: center;
}

.exam-admit-card-footer > div:first-child {
    justify-self: start;
}

.exam-admit-card-footer > div:last-child {
    justify-self: end;
    width: 240px;
}

.exam-admit-card-footer span {
    display: block;
    height: 22px;
    border-bottom: 1px solid #0f172a;
}

.exam-admit-card-footer strong,
.exam-admit-card-footer small {
    display: block;
    margin-top: 4px;
    font-size: 0.72rem;
    font-weight: 800;
    line-height: 1.25;
}

.exam-admit-card-footer small {
    color: #334155;
    font-size: 0.62rem;
    font-weight: 700;
}

.exam-admit-card-school-name {
    white-space: nowrap;
}

.marksheet-print-panel {
    background: #f8f2e7;
}

.marksheet-print-area {
    display: grid;
    gap: 28px;
    padding: 24px;
}

.exam-marksheet-note {
    display: flex;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
    padding: 14px 16px;
    border: 1px solid #dbe3ee;
    border-radius: 12px;
    background: #fff;
}

.exam-marksheet-note strong {
    color: #1f3147;
}

.exam-marksheet-note span {
    color: #64748b;
}

.exam-marksheet {
    position: relative;
    display: flex;
    flex-direction: column;
    width: min(210mm, 100%);
    min-height: 297mm;
    margin: 0 auto;
    padding: 14mm 12mm 10mm;
    box-sizing: border-box;
    background: #fffdf9;
    color: #0f172a;
    font-family: "Inter", "Segoe UI", sans-serif;
    break-inside: avoid;
    page-break-inside: avoid;
    overflow: hidden;
    box-shadow: 0 18px 38px rgba(90, 52, 19, 0.12);
}

.exam-marksheet::before,
.exam-marksheet::after {
    content: "";
    position: absolute;
    pointer-events: none;
    z-index: 0;
}

.exam-marksheet::before {
    inset: 4mm;
    border: 1.2px solid rgba(234, 88, 12, 0.28);
}

.exam-marksheet::after {
    inset: 7mm;
    border: 1px solid rgba(233, 179, 123, 0.72);
}

.exam-marksheet > :not(.exam-marksheet-watermark):not(.exam-marksheet-border) {
    position: relative;
    z-index: 1;
}

.exam-marksheet-border {
    position: absolute;
    inset: 1.6mm;
    z-index: 0;
    width: auto;
    height: auto;
    object-fit: fill;
    pointer-events: none;
}

.exam-marksheet-watermark {
    position: absolute;
    left: 50%;
    top: 48%;
    z-index: 0;
    width: min(520px, 82%);
    max-height: 72%;
    object-fit: contain;
    opacity: 0.06;
    transform: translate(-50%, -50%);
    pointer-events: none;
}

.exam-marksheet-header {
    position: relative;
    display: block;
    min-height: 184px;
    margin-bottom: 2px;
}

.exam-marksheet-school-copy {
    display: grid;
    justify-items: center;
    width: 100%;
    gap: 4px;
    box-sizing: border-box;
    padding: 0 26px;
    text-align: center;
}

.exam-marksheet-school-copy h1 {
    margin: 0;
    color: #0f3f7f;
    width: 100%;
    max-width: 100%;
    font-family: "Stack Sans Headline Local", "Stack Sans Headline", "Arial Narrow", "Franklin Gothic Demi Cond", "Arial Black", "Helvetica Neue", Arial, sans-serif;
    font-size: clamp(0.98rem, 1.12vw + 0.42rem, 1.72rem);
    font-weight: 950;
    line-height: 0.94;
    letter-spacing: 0.018em;
    font-stretch: condensed;
    text-transform: uppercase;
    text-align: center;
    white-space: nowrap;
    text-wrap: nowrap;
}

.exam-marksheet-school-details {
    display: grid;
    justify-items: center;
    gap: 2px;
    width: 100%;
    padding: 0 26px;
    box-sizing: border-box;
}

.exam-marksheet-school-copy p {
    margin: 0;
    width: 100%;
    max-width: 100%;
    color: #2563eb;
    font-size: 0.85rem;
    font-weight: 700;
    line-height: 1.35;
    text-align: center;
}

.exam-marksheet-school-recognition {
    font-size: 0.8rem;
}

.exam-marksheet-school-estd {
    color: #475569;
    font-size: 0.8rem;
    font-weight: 800;
    text-transform: uppercase;
}

.exam-marksheet-school-logo {
    display: grid;
    place-items: center;
    width: 100%;
    margin-top: 6px;
}

.exam-marksheet-school-logo img {
    width: 72px;
    height: 72px;
    object-fit: contain;
}

.exam-marksheet-student-photo {
    position: absolute;
    top: 94px;
    right: 8px;
    width: 78px;
    height: 88px;
    display: grid;
    place-items: center;
    border: 1px solid #cbd5e1;
    background: rgba(255, 255, 255, 0.92);
    font-size: 0.74rem;
    font-weight: 800;
}

.exam-marksheet-student-photo img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.exam-marksheet-title {
    margin-bottom: 12px;
    text-align: center;
}

.exam-marksheet-title h2 {
    margin: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 8px 24px;
    border: 2px solid #ea580c;
    border-radius: 16px;
    background: #fff0df;
    color: #1f3147;
    font-family: "Stack Sans Headline Local", "Stack Sans Headline", "Arial Black", "Helvetica Neue", Arial, sans-serif;
    font-size: 1.14rem;
    font-weight: 900;
    line-height: 1;
    letter-spacing: 0.03em;
    text-transform: uppercase;
}

.exam-marksheet-meta {
    display: grid;
    grid-template-columns: minmax(0, 1.2fr) minmax(0, 0.8fr);
    gap: 14px;
    margin-bottom: 10px;
}

.exam-marksheet-meta-list {
    display: grid;
    gap: 4px;
}

.exam-marksheet-meta-line {
    display: grid;
    grid-template-columns: 136px minmax(0, 1fr);
    gap: 10px;
    align-items: start;
}

.exam-marksheet-meta-line span,
.exam-marksheet-meta-line strong {
    display: block;
    line-height: 1.3;
}

.exam-marksheet-meta-line span {
    position: relative;
    padding-right: 12px;
    color: #334155;
    font-size: 0.86rem;
    font-weight: 600;
}

.exam-marksheet-meta-line span::after {
    content: ":";
    position: absolute;
    right: 0;
    top: 0;
}

.exam-marksheet-meta-line strong {
    color: #111827;
    font-size: 0.9rem;
    font-weight: 700;
    overflow-wrap: anywhere;
}

.exam-marksheet-table,
.exam-marksheet-legend-table,
.exam-marksheet-result-table {
    width: 100%;
    border-collapse: collapse;
    background: rgba(255, 255, 255, 0.92);
}

.exam-marksheet-table {
    table-layout: fixed;
    font-size: 0.74rem;
}

.exam-marksheet-table th,
.exam-marksheet-table td,
.exam-marksheet-legend-table th,
.exam-marksheet-legend-table td,
.exam-marksheet-result-table td {
    border: 1px solid #1f2937;
    padding: 3px 4px;
    text-align: center;
    vertical-align: middle;
}

.exam-marksheet-table thead th,
.exam-marksheet-legend-table thead th {
    background: rgba(248, 250, 252, 0.96);
    font-weight: 800;
}

.exam-marksheet-table .exam-marksheet-subject-col {
    width: 20%;
    text-align: left;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.exam-marksheet-table .exam-marksheet-fullmarks-col {
    width: 8%;
}

.exam-marksheet-table .exam-marksheet-obtained-col {
    width: 9.5%;
}

.exam-marksheet-table .exam-marksheet-percentage-col {
    width: 10.5%;
}

.exam-marksheet-table .exam-marksheet-grade-col {
    width: 7%;
}

.exam-marksheet-table th.exam-marksheet-percentage-col,
.exam-marksheet-table th.exam-marksheet-grade-col {
    font-size: 0.72rem;
    line-height: 1.12;
    padding-left: 4px;
    padding-right: 4px;
}

.exam-marksheet-table td.exam-marksheet-percentage-col,
.exam-marksheet-table td.exam-marksheet-grade-col {
    white-space: nowrap;
    overflow-wrap: normal;
    word-break: keep-all;
}

.exam-marksheet-table .exam-marksheet-component-col {
    font-size: 0.7rem;
    line-height: 1.15;
}

.exam-marksheet-table thead tr:first-child th:first-child,
.exam-marksheet-table tbody th:first-child,
.exam-marksheet-table tbody td:first-child {
    width: 20%;
    text-align: left;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.exam-marksheet-table td:first-child,
.exam-marksheet-table tbody th:first-child {
    font-weight: 700;
}

.exam-marksheet-total-row th,
.exam-marksheet-total-row td {
    background: rgba(241, 245, 249, 0.9);
    font-weight: 800;
}

.exam-marksheet-grand-total-row th,
.exam-marksheet-summary-row th {
    text-align: left;
    background: rgba(248, 250, 252, 0.96);
    font-weight: 800;
}

.exam-marksheet-grand-total-row td,
.exam-marksheet-summary-row td {
    text-align: left;
    font-weight: 700;
}

.exam-marksheet-footer-grid {
    display: grid;
    grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr) 110px;
    gap: 12px;
    align-items: start;
    margin-top: 14px;
}

.exam-marksheet-legend h3,
.exam-marksheet-result-legend h3 {
    margin: 0 0 6px;
    color: #334155;
    font-size: 0.88rem;
    font-weight: 800;
}

.exam-marksheet-result-legend {
    align-self: start;
    margin-top: 0;
}

.exam-marksheet-legend-table,
.exam-marksheet-result-table {
    font-size: 0.64rem;
}

.exam-marksheet-legend-table th:first-child {
    width: 28%;
}

.exam-marksheet-legend-table th:nth-child(2) {
    width: 18%;
}

.exam-marksheet-result-code {
    width: 36px;
    font-weight: 900;
}

.exam-marksheet-qr {
    display: grid;
    justify-items: end;
    align-content: end;
    align-self: end;
}

.exam-marksheet-qr .qr-code-svg {
    width: 86px;
    height: 86px;
    display: block;
    border: 1px solid #cbd5e1;
    background: #fff;
}

.exam-marksheet-signatures {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 14px;
    margin-top: auto;
    padding-top: 8px;
    padding-bottom: 0;
}

.exam-marksheet-signatures > div {
    text-align: center;
}

.exam-marksheet-signature-line {
    display: flex;
    align-items: flex-end;
    justify-content: center;
    height: 30px;
    padding-bottom: 2px;
    border-bottom: 1px solid #0f172a;
}

.exam-marksheet-signature-image {
    display: block;
    max-width: 120px;
    max-height: 24px;
    object-fit: contain;
}

.exam-marksheet-signatures strong,
.exam-marksheet-signatures small {
    display: block;
    margin-top: 4px;
    font-size: 0.72rem;
    font-weight: 700;
    line-height: 1.25;
}

.exam-marksheet-signatures small {
    color: #475569;
    font-size: 0.64rem;
}

.rank-list-print-area {
    gap: 24px;
}

.exam-rank-sheet {
    position: relative;
    display: flex;
    flex-direction: column;
    width: min(210mm, 100%);
    min-height: 297mm;
    padding: 14mm 9mm 10mm;
    box-sizing: border-box;
    margin: 0 auto;
    background: #fff;
    border: 1px solid #d7e3ef;
    box-shadow: 0 18px 40px rgba(15, 23, 42, 0.08);
    color: #111827;
    font-family: "Inter", "Segoe UI", sans-serif;
    font-weight: 800;
    break-inside: avoid;
    page-break-inside: avoid;
}

.exam-rank-sheet-header {
    display: grid;
    gap: 10px;
}

.exam-rank-sheet-school {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    row-gap: 6px;
    justify-items: center;
    min-height: 42mm;
    text-align: center;
}

.exam-rank-sheet-school-copy {
    display: grid;
    gap: 4px;
    width: 100%;
    min-width: 0;
    align-content: start;
    justify-items: center;
    text-align: center;
}

.exam-rank-sheet-school-copy h1 {
    margin: 0;
    width: 100%;
    max-width: 100%;
    color: #0f3f7f;
    font-family: "Stack Sans Headline Local", "Stack Sans Headline", "Arial Narrow", "Franklin Gothic Demi Cond", "Arial Black", "Helvetica Neue", Arial, sans-serif;
    font-size: clamp(1rem, 1.1vw + 0.48rem, 1.68rem);
    font-weight: 950;
    line-height: 0.94;
    letter-spacing: 0.02em;
    font-stretch: condensed;
    text-transform: uppercase;
    white-space: nowrap;
    text-wrap: nowrap;
}

.exam-rank-sheet-school-copy p {
    margin: 0;
    width: 100%;
    max-width: 100%;
    color: #10294d;
    font-size: 0.98rem;
    font-weight: 900;
    line-height: 1.22;
    overflow-wrap: anywhere;
}

.exam-rank-sheet-school-address {
    font-size: 1.02rem;
    font-weight: 900;
}

.exam-rank-sheet-school-logo {
    display: grid;
    place-items: center;
    width: 24mm;
    height: 24mm;
    overflow: hidden;
    background: #fff;
}

.exam-rank-sheet-school-logo img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.exam-rank-sheet-title {
    text-align: center;
}

.exam-rank-sheet-title h2 {
    margin: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 38px;
    padding: 0 20px;
    border: 2px solid #0f172a;
    border-radius: 999px;
    color: #0f172a;
    font-size: 1.08rem;
    font-weight: 900;
    letter-spacing: 0.06em;
}

.exam-rank-sheet-meta {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
    width: 100%;
    margin-top: 8px;
    padding-bottom: 4px;
}

.exam-rank-sheet-meta-item {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    margin: 0;
    font-weight: 900;
    white-space: nowrap;
}

.exam-rank-sheet-meta-right {
    margin-left: auto;
}

.exam-rank-sheet-meta span {
    color: #475569;
    font-size: 0.92rem;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.exam-rank-sheet-meta strong {
    color: #111827;
    font-size: 0.94rem;
    font-weight: 900;
}

.exam-rank-sheet-included {
    margin: 0;
    color: #1e3a8a;
    font-size: 0.8rem;
    font-weight: 700;
    text-align: center;
}

.exam-rank-sheet-table-wrap {
    margin-top: 12px;
    margin-bottom: 8px;
}

.exam-rank-sheet-table {
    width: 100%;
    border-collapse: collapse;
    table-layout: fixed;
    background: #fff;
    font-size: 0.76rem;
}

.exam-rank-sheet-table th,
.exam-rank-sheet-table td {
    border: 1px solid #111827;
    padding: 4px 3px;
    text-align: center;
    vertical-align: middle;
    line-height: 1.2;
    color: #111827;
    font-weight: 800;
    white-space: normal;
    overflow-wrap: anywhere;
    word-break: break-word;
}

.exam-rank-sheet-table thead th {
    background: #f8fafc;
    color: #0f172a;
    font-weight: 900;
}

.exam-rank-sheet-table th small {
    display: block;
    margin-top: 2px;
    color: #475569;
    font-size: 0.62rem;
    font-weight: 700;
    line-height: 1.2;
}

.exam-rank-col-rank {
    width: 4%;
}

.exam-rank-col-roll {
    width: 5%;
}

.exam-rank-col-section {
    width: 4%;
}

.exam-rank-col-name {
    width: 13%;
    text-align: left;
}

.exam-rank-col-guardian {
    width: 13%;
    text-align: left;
}

.exam-rank-sheet-table td.exam-rank-col-name,
.exam-rank-sheet-table td.exam-rank-col-guardian {
    font-weight: 900;
    text-align: left;
}

.exam-rank-col-subject {
    width: 6%;
}

.exam-rank-col-total {
    width: 7%;
}

.exam-rank-col-grade {
    width: 7%;
}

.exam-rank-col-percentage {
    width: 8%;
}

.exam-rank-col-performance {
    width: 12%;
}

.exam-rank-col-percent {
    width: 8%;
}

.exam-rank-sheet-signature {
    margin-top: auto;
    padding-top: 10px;
    padding-bottom: 0;
    display: flex;
    justify-content: flex-end;
}

.exam-rank-sheet-signature > div {
    width: 220px;
    text-align: center;
}

.exam-rank-sheet-signature span {
    display: block;
    height: 26px;
    border-bottom: 1px solid #0f172a;
}

.exam-rank-sheet-signature strong,
.exam-rank-sheet-signature small {
    display: block;
    margin-top: 4px;
    color: #0f172a;
    font-size: 0.88rem;
    font-weight: 900;
}

.exam-rank-sheet-signature small {
    color: #475569;
    font-size: 0.7rem;
}

@media screen and (max-width: 1180px) {
    .student-directory-filter-grid,
    .student-profile-section-grid,
    .admit-card-filter-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .student-entry-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .bonafide-certificate-header,
    .bonafide-certificate-body {
        grid-template-columns: 1fr;
    }

    .bonafide-certificate-meta,
    .bonafide-certificate-photo-block {
        justify-items: start;
    }

    .bonafide-certificate-facts {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .bonafide-certificate-fact-wide {
        grid-column: span 2;
    }

    .exam-marksheet-meta,
    .exam-marksheet-footer-grid {
        grid-template-columns: 1fr;
    }

    .exam-rank-sheet-school,
    .exam-rank-sheet-meta {
        grid-template-columns: 1fr;
    }

    .exam-marksheet-qr {
        justify-items: start;
    }
}

@media screen and (max-width: 820px) {
    .form-page-header,
    .form-page-header-main,
    .form-page-header-actions {
        flex-direction: column;
        align-items: start;
    }

    .student-directory-toolbar-actions,
    .student-directory-footer,
    .erp-modal-header,
    .erp-modal-footer,
    .student-profile-card-header {
        flex-direction: column;
        align-items: start;
    }

    .student-profile-detail-grid,
    .student-profile-section-grid {
        grid-template-columns: 1fr;
    }

    .exam-admit-card-school,
    .exam-admit-card-student {
        grid-template-columns: 1fr;
    }

    .marks-grade-layout {
        grid-template-columns: 1fr;
    }

    .marks-grade-legend-item {
        grid-template-columns: 1fr;
    }

    .marks-grade-range-fields {
        grid-template-columns: 1fr;
    }

    .marks-grade-range-divider {
        justify-self: start;
    }

    .exam-result-summary-grid {
        grid-template-columns: 1fr;
    }

    .exam-result-config-note {
        align-items: start;
    }

    .exam-marksheet {
        min-height: 0;
        padding: 38px 24px 30px;
    }

    .exam-marksheet-header {
        min-height: 0;
    }

    .exam-marksheet-school-copy {
        padding: 0;
    }

    .exam-marksheet-student-photo {
        position: static;
        margin: 0 auto 10px;
    }

    .exam-marksheet-meta {
        grid-template-columns: 1fr;
    }

    .exam-marksheet-signatures {
        grid-template-columns: 1fr;
    }

    .exam-rank-sheet {
        padding: 24px 16px;
    }

    .exam-rank-sheet-table {
        min-width: 920px;
    }

    .bonafide-certificate {
        min-height: 0;
        padding: 42px 34px 36px;
    }

    .bonafide-certificate-school-brand {
        grid-template-columns: 1fr;
        justify-items: start;
    }

    .bonafide-certificate-title h1 {
        letter-spacing: 0.08em;
    }

    .bonafide-certificate-facts {
        grid-template-columns: 1fr;
    }

    .bonafide-certificate-fact-wide {
        grid-column: span 1;
    }

    .student-entry-form .field-span-2,
    .student-entry-form .field-span-4 {
        grid-column: span 1;
    }
}

@media screen and (max-width: 640px) {
    .student-directory-filter-grid,
    .admit-card-filter-grid {
        grid-template-columns: 1fr;
    }

    .student-entry-grid {
        grid-template-columns: 1fr;
    }

    .student-directory-table,
    .exam-result-entry-table,
    .exam-result-generation-table {
        min-width: 1080px;
    }

    .exam-marksheet-table {
        min-width: 980px;
    }

    .bonafide-certificate-print-sheet {
        padding: 12px;
    }
}

@media print {
    @page {
        size: A4 portrait;
        margin: 0;
    }

    body.admit-card-print-mode {
        background: #fff;
    }

    body.admit-card-print-mode .erp-sidebar,
    body.admit-card-print-mode .erp-topbar,
    body.admit-card-print-mode .quicklinks-backdrop,
    body.admit-card-print-mode .quicklinks-panel,
    body.admit-card-print-mode .admit-card-screen-only,
    body.admit-card-print-mode .app-footer {
        display: none !important;
    }

    body.admit-card-print-mode .erp-shell,
    body.admit-card-print-mode .erp-main,
    body.admit-card-print-mode .erp-content,
    body.admit-card-print-mode .page-body {
        display: block;
        width: auto;
        min-height: 0;
        padding: 0;
        margin: 0;
        background: #fff;
    }

    body.admit-card-print-mode .admit-card-print-panel {
        padding: 0;
        margin: 0;
        border: 0;
        box-shadow: none;
        background: #fff;
    }

    body.admit-card-print-mode .admit-card-print-area {
        display: grid;
        gap: 4mm;
        padding: 0;
    }

    body.admit-card-print-mode .exam-admit-card {
        width: 194mm;
        max-width: none;
        height: 135mm;
        min-height: 135mm;
        margin: 0;
        padding: 5mm;
        border: 0.45mm solid #000;
        outline: 0.75mm double #000;
        outline-offset: -2mm;
        box-shadow: none;
        overflow: hidden;
    }

    body.admit-card-print-mode .exam-admit-card-watermark {
        width: 72mm;
        max-height: 88mm;
        opacity: 0.055;
    }

    body.admit-card-print-mode .exam-admit-card:nth-child(2n):not(:last-child) {
        break-after: page;
        page-break-after: always;
    }

    body.admit-card-print-mode .exam-admit-card-school {
        grid-template-columns: 22mm 1fr 22mm;
        gap: 3mm;
        padding-bottom: 2mm;
    }

    body.admit-card-print-mode .exam-admit-card-logo {
        width: 18mm;
        height: 18mm;
    }

    body.admit-card-print-mode .exam-admit-card-qr .qr-code-svg {
        width: 18mm;
        height: 18mm;
    }

    body.admit-card-print-mode .exam-admit-card-qr small {
        max-width: 22mm;
        font-size: 5.2pt;
    }

    body.admit-card-print-mode .exam-admit-card-school-info h2 {
        font-size: 14pt;
        letter-spacing: 0.035em;
        white-space: nowrap;
    }

    body.admit-card-print-mode .exam-admit-card-school-info p {
        font-size: 8pt;
        font-weight: 600;
    }

    body.admit-card-print-mode .exam-admit-card-title {
        padding: 2mm 0;
    }

    body.admit-card-print-mode .exam-admit-card-title h1 {
        font-size: 10pt;
    }

    body.admit-card-print-mode .exam-admit-card-title p {
        font-size: 8.5pt;
    }

    body.admit-card-print-mode .exam-admit-card-title .exam-admit-card-no,
    body.admit-card-print-mode .exam-admit-card-schedule-title {
        font-size: 6.6pt;
    }

    body.admit-card-print-mode .exam-admit-card-student {
        grid-template-columns: 1fr 24mm;
        gap: 3mm;
        margin-bottom: 2mm;
    }

    body.admit-card-print-mode .exam-admit-card-photo {
        width: 24mm;
        height: 27mm;
    }

    body.admit-card-print-mode .exam-admit-card-details > div {
        min-height: 10mm;
        padding: 1.5mm 2mm;
    }

    body.admit-card-print-mode .exam-admit-card-details span {
        font-size: 6pt;
    }

    body.admit-card-print-mode .exam-admit-card-details strong,
    body.admit-card-print-mode .exam-admit-card-routine {
        font-size: 8.3pt;
    }

    body.admit-card-print-mode .exam-admit-card-detail-primary strong {
        font-size: 9.4pt;
        font-weight: 900;
    }

    body.admit-card-print-mode .exam-admit-card-routine td:first-child {
        font-size: 9pt;
        font-weight: 900;
    }

    body.admit-card-print-mode .exam-admit-card-routine th,
    body.admit-card-print-mode .exam-admit-card-routine td {
        padding: 1.4mm 2mm;
    }

    body.admit-card-print-mode .exam-admit-card-footer {
        display: grid;
        grid-template-columns: 1fr 1fr;
        width: 100%;
        margin-top: 5mm;
    }

    body.admit-card-print-mode .exam-admit-card-footer > div:first-child {
        justify-self: start;
    }

    body.admit-card-print-mode .exam-admit-card-footer > div:last-child {
        justify-self: end;
        width: 62mm;
    }

    body.admit-card-print-mode .exam-admit-card-school-name {
        font-size: 6pt;
        white-space: nowrap;
    }
}

/* School-facing portal */
.portal-body {
    min-height: 100vh;
    padding: clamp(14px, 2vw, 24px);
    background:
        radial-gradient(circle at 10% 14%, rgba(255, 214, 102, 0.34), transparent 24%),
        radial-gradient(circle at 90% 12%, rgba(56, 189, 248, 0.26), transparent 26%),
        linear-gradient(145deg, #f8fbff 0%, #eef6ff 48%, #fff8ed 100%);
}

.portal-shell {
    width: min(1280px, 100%);
    margin: 0 auto;
    display: grid;
    gap: 18px;
}

.portal-topbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    flex-wrap: wrap;
    padding: 18px 22px;
    border: 1px solid rgba(191, 219, 254, 0.8);
    border-radius: 28px;
    background: rgba(255, 255, 255, 0.9);
    box-shadow: 0 18px 40px rgba(15, 23, 42, 0.08);
}

.portal-topbar-brand {
    display: flex;
    align-items: center;
    gap: 14px;
    color: inherit;
    text-decoration: none;
}

.portal-school-logo {
    width: 62px;
    height: 62px;
    flex: 0 0 62px;
    border-radius: 18px;
    border: 1px solid #bfdbfe;
    background: #fff;
    object-fit: contain;
    padding: 4px;
    box-shadow: 0 12px 26px rgba(37, 99, 235, 0.12);
}

.portal-school-logo-mark {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: #0f2f57;
    font-size: 1rem;
    font-weight: 900;
}

.portal-school-lockup {
    display: grid;
    gap: 3px;
}

.portal-school-lockup small,
.portal-school-lockup span {
    color: #64748b;
    font-size: 0.8rem;
    font-weight: 800;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.portal-school-lockup strong {
    color: #0f2f57;
    font-size: clamp(1.05rem, 1.4vw, 1.35rem);
    line-height: 1.2;
}

.portal-topbar-actions,
.portal-chip-row,
.portal-inline-actions,
.portal-switch-row {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}

.portal-switch-row {
    margin: 6px 0 14px;
}

.portal-chip {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 14px;
    border-radius: 999px;
    border: 1px solid #bfdbfe;
    background: #eff6ff;
    color: #0f2f57;
    font-size: 0.82rem;
    font-weight: 800;
}

.portal-chip span {
    color: #64748b;
    text-transform: uppercase;
    letter-spacing: 0.08em;
}

.portal-chip-soft {
    background: #f8fafc;
}

.portal-main {
    display: grid;
    gap: 18px;
}

.portal-hero,
.portal-note-card,
.portal-entry-card,
.portal-summary-card {
    border: 1px solid rgba(191, 219, 254, 0.8);
    background: rgba(255, 255, 255, 0.92);
    box-shadow: 0 18px 42px rgba(15, 23, 42, 0.08);
}

.portal-hero {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: center;
    gap: 18px;
    padding: 24px 28px;
    border-radius: 30px;
    background:
        linear-gradient(135deg, rgba(15, 47, 87, 0.98), rgba(3, 105, 161, 0.9)),
        radial-gradient(circle at 15% 20%, rgba(255, 214, 102, 0.2), transparent 30%);
    color: #fff;
}

.portal-kicker,
.portal-entry-helper {
    display: inline-flex;
    align-items: center;
    width: fit-content;
    padding: 8px 12px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.16);
    color: rgba(236, 249, 255, 0.86);
    font-size: 0.74rem;
    font-weight: 900;
    letter-spacing: 0.12em;
    text-transform: uppercase;
}

.portal-hero h1 {
    margin: 12px 0 6px;
    color: #fff;
    font-size: clamp(1.9rem, 3vw, 2.7rem);
    line-height: 1.08;
}

.portal-hero p {
    margin: 0;
    color: rgba(236, 249, 255, 0.88);
}

.portal-avatar-card,
.portal-child-avatar {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 106px;
    height: 106px;
    border-radius: 30px;
    background: rgba(255, 255, 255, 0.14);
    border: 1px solid rgba(255, 255, 255, 0.18);
    overflow: hidden;
}

.portal-avatar-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.portal-avatar-fallback {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 100%;
    color: #fff;
    font-size: 1.35rem;
    font-weight: 900;
}

.portal-summary-grid,
.portal-entry-grid,
.portal-dashboard-grid,
.portal-children-grid {
    display: grid;
    gap: 16px;
}

.portal-summary-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
}

.portal-summary-card {
    display: grid;
    gap: 10px;
    padding: 18px 20px;
    border-radius: 24px;
}

.portal-summary-card span {
    color: #64748b;
    font-size: 0.78rem;
    font-weight: 900;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.portal-summary-card strong {
    color: #0f2f57;
    font-size: 1.16rem;
    line-height: 1.2;
}

.portal-dashboard-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.portal-children-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.portal-data-list {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px 16px;
}

.portal-data-list > div {
    display: grid;
    gap: 5px;
    padding: 14px 16px;
    border: 1px solid #e2e8f0;
    border-radius: 18px;
    background: linear-gradient(180deg, #ffffff, #f8fbff);
}

.portal-data-list span {
    color: #64748b;
    font-size: 0.76rem;
    font-weight: 800;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.portal-data-list strong {
    color: #0f172a;
    line-height: 1.45;
    overflow-wrap: anywhere;
}

.portal-data-list-wide {
    grid-column: 1 / -1;
}

.portal-document-list {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
}

.portal-document-card,
.portal-entry-card,
.portal-switch-link {
    text-decoration: none;
}

.portal-document-card {
    display: grid;
    gap: 6px;
    padding: 16px 18px;
    border: 1px solid #dbeafe;
    border-radius: 18px;
    background: linear-gradient(180deg, #ffffff, #f8fbff);
    color: #0f172a;
}

.portal-document-card span,
.portal-inline-note {
    color: #64748b;
    font-size: 0.8rem;
}

.portal-document-card strong {
    color: #0f2f57;
    overflow-wrap: anywhere;
}

.portal-entry-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
}

.portal-entry-card {
    display: grid;
    gap: 14px;
    padding: 22px;
    border-radius: 28px;
}

.portal-entry-card h3 {
    margin: 0;
    color: #0f2f57;
    font-size: 1.34rem;
}

.portal-entry-card p,
.portal-note-card p {
    margin: 0;
    color: #475569;
    line-height: 1.65;
}

.portal-note-card {
    display: grid;
    gap: 10px;
    padding: 18px 20px;
    border-radius: 24px;
}

.portal-note-card strong {
    color: #0f2f57;
}

.portal-switch-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 42px;
    padding: 10px 16px;
    border: 1px solid #dbeafe;
    border-radius: 999px;
    background: #fff;
    color: #0f2f57;
    font-weight: 800;
}

.portal-switch-link.is-active {
    border-color: #f97316;
    background: #fff7ed;
    color: #c2410c;
}

.portal-child-card {
    display: grid;
    gap: 16px;
}

.portal-child-header {
    display: flex;
    align-items: center;
    gap: 14px;
}

.portal-child-header h2 {
    margin: 0 0 5px;
}

.portal-child-header p {
    margin: 0;
    color: #475569;
}

.portal-footer {
    width: min(1280px, 100%);
    margin: 0 auto;
    color: #475569;
}

@media (max-width: 1080px) {
    .portal-summary-grid,
    .portal-entry-grid,
    .portal-dashboard-grid,
    .portal-children-grid,
    .portal-document-list {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .portal-hero {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 760px) {
    .portal-body {
        padding: 10px;
    }

    .portal-topbar,
    .portal-hero {
        padding: 18px;
        border-radius: 22px;
    }

    .portal-summary-grid,
    .portal-entry-grid,
    .portal-dashboard-grid,
    .portal-children-grid,
    .portal-data-list,
    .portal-document-list {
        grid-template-columns: 1fr;
    }

    .portal-topbar-actions {
        width: 100%;
    }

    .portal-topbar-actions .button {
        width: 100%;
    }
}

@media print {
    body.marksheet-print-mode {
        background: #fff;
    }

    body.marksheet-print-mode .erp-sidebar,
    body.marksheet-print-mode .erp-topbar,
    body.marksheet-print-mode .quicklinks-backdrop,
    body.marksheet-print-mode .quicklinks-panel,
    body.marksheet-print-mode .marksheet-screen-only,
    body.marksheet-print-mode .app-footer {
        display: none !important;
    }

    body.marksheet-print-mode .erp-shell,
    body.marksheet-print-mode .erp-main,
    body.marksheet-print-mode .erp-content,
    body.marksheet-print-mode .page-body {
        display: block;
        width: auto;
        min-height: 0;
        padding: 0;
        margin: 0;
        background: #fff;
    }

    body.marksheet-print-mode .marksheet-print-panel {
        border: 0;
        border-radius: 0;
        box-shadow: none;
        padding: 0;
        margin: 0;
        background: #fff;
    }

    body.marksheet-print-mode .marksheet-print-area {
        gap: 0;
        padding: 0;
    }

    body.marksheet-print-mode .exam-marksheet {
        width: 204mm;
        max-width: none;
        min-height: 291mm;
        height: 291mm;
        max-height: 291mm;
        margin: 3mm auto;
        padding: 10mm;
        box-shadow: none;
        overflow: hidden;
    }

    body.marksheet-print-mode .exam-marksheet::before {
        inset: 3mm;
        border-width: 0.35mm;
    }

    body.marksheet-print-mode .exam-marksheet::after {
        inset: 6mm;
        border-width: 0.28mm;
    }

    body.marksheet-print-mode .exam-marksheet-border {
        inset: 1.6mm;
    }

    body.marksheet-print-mode .exam-marksheet:not(:last-child) {
        page-break-after: always;
    }

    body.marksheet-print-mode .exam-marksheet-table {
        font-size: 0.71rem;
    }

    body.marksheet-print-mode .exam-marksheet-legend-table,
    body.marksheet-print-mode .exam-marksheet-result-table {
        font-size: 0.61rem;
    }

    body.marksheet-print-mode .exam-marksheet-school-copy h1 {
        color: #0f3f7f;
        font-family: "Stack Sans Headline Local", "Stack Sans Headline", "Arial Narrow", "Franklin Gothic Demi Cond", "Arial Black", "Helvetica Neue", Arial, sans-serif;
        font-size: 1.56rem;
        font-weight: 950;
        line-height: 0.94;
        letter-spacing: 0.018em;
        font-stretch: condensed;
        white-space: nowrap;
        text-wrap: nowrap;
    }

    body.marksheet-print-mode .exam-marksheet-title h2 {
        padding: 7px 22px;
        border-width: 2px;
        border-radius: 16px;
        font-size: 1.08rem;
        letter-spacing: 0.03em;
    }

    body.marksheet-print-mode .exam-marksheet-title {
        margin-bottom: 12px;
    }

    body.marksheet-print-mode .exam-marksheet-header {
        min-height: 170px;
        margin-bottom: 2px;
    }

    body.marksheet-print-mode .exam-marksheet-student-photo {
        position: absolute;
        margin: 0;
    }

    body.marksheet-print-mode .exam-marksheet-school-copy {
        padding: 0 14px;
    }

    body.marksheet-print-mode .exam-marksheet-school-copy p {
        font-size: 0.8rem;
        text-align: center;
    }

    body.marksheet-print-mode .exam-marksheet-school-details {
        padding: 0 14px;
    }

    body.marksheet-print-mode .exam-marksheet-school-logo {
        margin-top: 4px;
    }

    body.marksheet-print-mode .exam-marksheet-school-logo img {
        width: 66px;
        height: 66px;
    }

    body.marksheet-print-mode .exam-marksheet-student-photo {
        top: 78px;
        right: 8px;
        width: 70px;
        height: 80px;
    }

    body.marksheet-print-mode .exam-marksheet-result-legend {
        margin-top: 0;
    }

    body.marksheet-print-mode .exam-marksheet-signatures {
        grid-template-columns: repeat(3, minmax(0, 1fr));
        margin-top: auto;
        padding-top: 6px;
        padding-bottom: 0;
    }

    body.marksheet-print-mode .exam-marksheet-meta {
        grid-template-columns: minmax(0, 1.2fr) minmax(0, 0.8fr);
        align-items: start;
        gap: 12px;
        margin-bottom: 8px;
    }

    body.marksheet-print-mode .exam-marksheet-meta-line {
        grid-template-columns: 136px minmax(0, 1fr);
        gap: 10px;
    }

    body.marksheet-print-mode .exam-marksheet-meta-line span {
        font-size: 0.86rem;
    }

    body.marksheet-print-mode .exam-marksheet-meta-line strong {
        font-size: 0.9rem;
    }

    body.marksheet-print-mode .exam-marksheet-table th,
    body.marksheet-print-mode .exam-marksheet-table td,
    body.marksheet-print-mode .exam-marksheet-legend-table th,
    body.marksheet-print-mode .exam-marksheet-legend-table td,
    body.marksheet-print-mode .exam-marksheet-result-table td {
        padding: 3px 4px;
    }

    body.marksheet-print-mode .exam-marksheet-footer-grid {
        grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr) 110px;
        gap: 10px;
        margin-top: 12px;
    }

    body.marksheet-print-mode .exam-marksheet-legend h3,
    body.marksheet-print-mode .exam-marksheet-result-legend h3 {
        margin-bottom: 6px;
        font-size: 0.88rem;
    }

    body.marksheet-print-mode .exam-marksheet-qr .qr-code-svg {
        width: 80px;
        height: 80px;
    }

    body.marksheet-print-mode .exam-marksheet-signature-line {
        height: 30px;
    }

    body.marksheet-print-mode .exam-marksheet-signatures strong {
        font-size: 0.7rem;
    }

    body.marksheet-print-mode .exam-marksheet-signatures small {
        font-size: 0.62rem;
    }

    body.marksheet-print-mode .exam-marksheet-signatures {
        gap: 14px;
    }

    body.marksheet-print-mode .rank-list-print-area {
        gap: 0;
        padding: 0;
    }

    body.marksheet-print-mode .exam-rank-sheet {
        width: 210mm;
        max-width: none;
        min-height: 297mm;
        margin: 0 auto;
        padding: 10mm 9mm 10mm;
        box-sizing: border-box;
        border: 0;
        box-shadow: none;
        break-inside: avoid;
        page-break-inside: avoid;
    }

    body.marksheet-print-mode .exam-rank-sheet:not(:last-child) {
        break-after: page;
        page-break-after: always;
    }

    body.marksheet-print-mode .exam-rank-sheet-school {
        grid-template-columns: minmax(0, 1fr);
        justify-items: center;
        row-gap: 5px;
        min-height: 40mm;
        text-align: center;
    }

    body.marksheet-print-mode .exam-rank-sheet-school-copy {
        width: 100%;
        min-width: 0;
        align-content: start;
        justify-items: center;
    }

    body.marksheet-print-mode .exam-rank-sheet-school-copy h1 {
        width: 100%;
        max-width: 100%;
        color: #0f3f7f;
        font-family: "Stack Sans Headline Local", "Stack Sans Headline", "Arial Narrow", "Franklin Gothic Demi Cond", "Arial Black", "Helvetica Neue", Arial, sans-serif;
        font-size: 1.46rem;
        font-weight: 950;
        line-height: 0.94;
        letter-spacing: 0.02em;
        font-stretch: condensed;
        white-space: nowrap;
        text-wrap: nowrap;
    }

    body.marksheet-print-mode .exam-rank-sheet-school-copy p {
        width: 100%;
        max-width: 100%;
        color: #10294d;
        font-size: 0.9rem;
        font-weight: 900;
        line-height: 1.22;
        overflow-wrap: anywhere;
    }

    body.marksheet-print-mode .exam-rank-sheet-school-address {
        font-size: 0.94rem;
    }

    body.marksheet-print-mode .exam-rank-sheet-school-logo {
        width: 22mm;
        height: 22mm;
    }

    body.marksheet-print-mode .exam-rank-sheet-school-logo img {
        width: 100%;
        height: 100%;
    }

    body.marksheet-print-mode .exam-rank-sheet-title h2 {
        min-height: 34px;
        font-size: 1.08rem;
    }

    body.marksheet-print-mode .exam-rank-sheet-meta {
        display: flex;
        align-items: center;
        justify-content: space-between;
        gap: 18px;
        width: 100%;
        margin-top: 8px;
        padding-bottom: 4px;
    }

    body.marksheet-print-mode .exam-rank-sheet-meta-item {
        display: inline-flex;
        align-items: center;
        gap: 6px;
        margin: 0;
        white-space: nowrap;
    }

    body.marksheet-print-mode .exam-rank-sheet-meta-right {
        margin-left: auto;
    }

    body.marksheet-print-mode .exam-rank-sheet-meta span {
        font-size: 0.82rem;
        font-weight: 900;
    }

    body.marksheet-print-mode .exam-rank-sheet-meta strong {
        font-size: 0.86rem;
        font-weight: 900;
    }

    body.marksheet-print-mode .exam-rank-sheet-included {
        font-size: 0.74rem;
    }

    body.marksheet-print-mode .exam-rank-sheet-table {
        font-size: 0.72rem;
    }

    body.marksheet-print-mode .exam-rank-sheet-table-wrap {
        margin-bottom: 8px;
    }

    body.marksheet-print-mode .exam-rank-sheet-table th,
    body.marksheet-print-mode .exam-rank-sheet-table td {
        padding: 4px 3px;
        font-size: 0.72rem;
        font-weight: 800;
        white-space: normal;
        overflow-wrap: anywhere;
        word-break: break-word;
    }

    body.marksheet-print-mode .exam-rank-sheet-table th small {
        font-size: 0.56rem;
    }

    body.marksheet-print-mode .exam-rank-sheet-signature {
        margin-top: auto;
        padding-top: 10px;
        padding-bottom: 0;
    }
}

@media print {
    body.bonafide-certificate-print-mode {
        background: #fff !important;
    }

    body.bonafide-certificate-print-mode .bonafide-certificate-print-sheet {
        min-height: auto;
        padding: 0;
        background: #fff;
    }

    body.bonafide-certificate-print-mode .bonafide-certificate {
        width: 297mm;
        min-height: 210mm;
        padding: 16mm 20mm 14mm;
        margin: 0;
        box-shadow: none;
        background: #fffdf9;
        break-inside: avoid;
        page-break-inside: avoid;
    }

    body.bonafide-certificate-print-mode .bonafide-certificate-header {
        grid-template-columns: 1fr auto;
        gap: 8mm;
    }

    body.bonafide-certificate-print-mode .bonafide-certificate-school-brand {
        grid-template-columns: 22mm 1fr;
        gap: 4mm;
    }

    body.bonafide-certificate-print-mode .bonafide-certificate-logo {
        width: 22mm;
        height: 22mm;
    }

    body.bonafide-certificate-print-mode .bonafide-certificate-school-copy h2 {
        font-size: 18pt;
    }

    body.bonafide-certificate-print-mode .bonafide-certificate-school-copy p,
    body.bonafide-certificate-print-mode .bonafide-certificate-meta strong {
        font-size: 9pt;
    }

    body.bonafide-certificate-print-mode .bonafide-certificate-meta span,
    body.bonafide-certificate-print-mode .bonafide-certificate-facts span {
        font-size: 6.4pt;
    }

    body.bonafide-certificate-print-mode .bonafide-certificate-title h1 {
        font-size: 17pt;
    }

    body.bonafide-certificate-print-mode .bonafide-certificate-title p {
        font-size: 8.4pt;
    }

    body.bonafide-certificate-print-mode .bonafide-certificate-body {
        grid-template-columns: 1fr 31mm;
        gap: 7mm;
    }

    body.bonafide-certificate-print-mode .bonafide-certificate-copy p {
        font-size: 11.4pt;
        line-height: 1.75;
    }

    body.bonafide-certificate-print-mode .bonafide-certificate-photo {
        width: 31mm;
        height: 37mm;
    }

    body.bonafide-certificate-print-mode .bonafide-certificate-photo-placeholder {
        font-size: 8pt;
    }

    body.bonafide-certificate-print-mode .bonafide-certificate-facts {
        gap: 3mm;
    }

    body.bonafide-certificate-print-mode .bonafide-certificate-facts > div {
        padding: 3mm;
    }

    body.bonafide-certificate-print-mode .bonafide-certificate-facts strong {
        font-size: 9.4pt;
    }

    body.bonafide-certificate-print-mode .bonafide-certificate-signature {
        width: 52mm;
    }

    body.bonafide-certificate-print-mode .bonafide-certificate-signature span {
        height: 10mm;
    }

    body.bonafide-certificate-print-mode .bonafide-certificate-signature strong {
        font-size: 9.5pt;
    }

    body.bonafide-certificate-print-mode .bonafide-certificate-signature small {
        font-size: 8pt;
    }
}

.fees-page {
    --fees-hero-start: #0f172a;
    --fees-hero-mid: #173b7a;
    --fees-hero-end: #0f766e;
    --fees-accent-sky: #38bdf8;
    --fees-accent-violet: #7c3aed;
    --fees-accent-sun: #f59e0b;
    --fees-accent-rose: #ef476f;
    display: grid;
    gap: 18px;
}

.fees-page > .form-page-header {
    margin-bottom: 0;
    padding: 20px 22px;
    border-color: rgba(59, 130, 246, 0.18);
    background:
        radial-gradient(circle at top right, rgba(56, 189, 248, 0.26), transparent 28%),
        radial-gradient(circle at bottom left, rgba(245, 158, 11, 0.22), transparent 34%),
        linear-gradient(135deg, var(--fees-hero-start) 0%, var(--fees-hero-mid) 46%, var(--fees-hero-end) 100%);
    box-shadow: 0 24px 56px rgba(15, 23, 42, 0.16);
}

.fees-page > .form-page-header .form-page-header-main {
    gap: 18px;
}

.fees-page > .form-page-header h2 {
    color: #f8fbff;
    font-size: 1.42rem;
    letter-spacing: 0.02em;
}

.fees-page > .form-page-header p {
    color: rgba(226, 232, 240, 0.88);
}

.fees-page > .form-page-header .form-page-meta span {
    border-color: rgba(255, 255, 255, 0.1);
    color: #f8fbff;
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(12px);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.14);
}

.fees-page > .form-page-header .form-page-meta span:nth-child(1) {
    background: linear-gradient(135deg, rgba(56, 189, 248, 0.24), rgba(59, 130, 246, 0.18));
}

.fees-page > .form-page-header .form-page-meta span:nth-child(2) {
    background: linear-gradient(135deg, rgba(167, 139, 250, 0.24), rgba(124, 58, 237, 0.18));
}

.fees-page > .form-page-header .form-page-meta span:nth-child(3) {
    background: linear-gradient(135deg, rgba(251, 191, 36, 0.26), rgba(245, 158, 11, 0.18));
}

.fees-page > .form-page-header .form-page-meta span:nth-child(4) {
    background: linear-gradient(135deg, rgba(244, 114, 182, 0.24), rgba(239, 71, 111, 0.18));
}

.fees-page .button {
    transition: transform 0.18s ease, box-shadow 0.18s ease, background 0.18s ease, border-color 0.18s ease;
}

.fees-page .button:hover {
    transform: translateY(-1px);
}

.fees-page .button-primary {
    background: linear-gradient(135deg, #ff9f1c 0%, #ff4d6d 100%);
    box-shadow: 0 14px 30px rgba(255, 77, 109, 0.24);
}

.fees-page .button-secondary {
    background: linear-gradient(135deg, #ffffff 0%, #eef6ff 100%);
    border: 1px solid #c9ddff;
    color: #123e6b;
    box-shadow: 0 10px 22px rgba(15, 23, 42, 0.06);
}

.fees-page > .form-page-header .button-secondary {
    background: rgba(255, 255, 255, 0.12);
    border-color: rgba(255, 255, 255, 0.22);
    color: #fff;
    box-shadow: none;
}

.fees-page > .form-page-header .button-secondary:hover {
    background: rgba(255, 255, 255, 0.18);
}

.fees-page .form-page-header-actions form {
    margin: 0;
}

.fees-page .dashboard-panel {
    border-color: #d6e3f1;
    box-shadow: 0 18px 36px rgba(15, 23, 42, 0.08);
}

.fees-page .dashboard-panel-header {
    background: linear-gradient(135deg, rgba(56, 189, 248, 0.08), rgba(167, 139, 250, 0.08), rgba(255, 184, 77, 0.08));
    border-bottom: 1px solid rgba(215, 226, 240, 0.95);
}

.fees-page .dashboard-panel-header h2 {
    color: #0e2f57;
    letter-spacing: 0.01em;
}

.fees-page .dashboard-panel-header p {
    color: #5b6f8b;
}

.fees-page .dashboard-panel-total strong {
    color: var(--fees-accent-violet);
}

.fees-page .dashboard-panel > .table-card {
    margin: 16px 18px 18px;
    border-radius: 16px;
    box-shadow: 0 12px 28px rgba(15, 23, 42, 0.05);
}

.fees-page .dashboard-panel > .erp-empty-state {
    margin: 16px 18px 18px;
    border: 1px dashed #d2dded;
    border-radius: 16px;
    background: linear-gradient(135deg, #fbfdff 0%, #f6faff 100%);
}

.fees-page .dashboard-panel > .fees-receipt-grid {
    padding: 16px 18px 14px;
}

.fees-page .dashboard-panel > .fees-receipt-balance {
    padding: 0 18px 18px;
}

.fees-page .dashboard-panel > .fees-assignment-pool {
    padding: 2px 18px 18px;
}

.fees-page .fees-assignment-pool > .dashboard-panel-header {
    padding: 0 0 12px;
    background: transparent;
    border-bottom: 1px dashed #dbe3ee;
}

.fees-page .erp-form-stack {
    gap: 18px;
}

.fees-page .erp-form-stack > .dashboard-panel .erp-form-actions {
    padding: 16px 18px 18px;
    border-top: 1px solid #edf1f6;
}

.fees-page .fees-filter-panel .erp-form-grid {
    gap: 14px 18px;
}

.fees-master-layout,
.fees-collection-layout,
.fees-statement-layout {
    display: grid;
    gap: 18px;
    align-items: start;
}

.fees-master-layout {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.fees-collection-layout {
    grid-template-columns: minmax(0, 1fr);
}

.fees-filter-panel .fees-filter-grid {
    grid-template-columns: repeat(12, minmax(0, 1fr));
    gap: 14px 18px;
    align-items: end;
}

.fees-filter-field-session,
.fees-filter-field-class,
.fees-filter-field-section,
.fees-filter-field-date {
    grid-column: span 3;
}

.fees-filter-actions {
    grid-column: 1 / -1;
    display: flex;
    justify-content: flex-end;
    padding-top: 8px;
    border-top: 1px dashed #dbe3ee;
}

.fees-filter-actions .button {
    min-width: 170px;
}

.fees-collection-panel {
    overflow: hidden;
    min-width: 0;
}

.fees-payment-panel {
    display: flex;
    flex-direction: column;
}

.fees-due-register-panel .fees-table-card {
    max-height: min(50vh, 520px);
    overflow: auto;
}

.fees-due-register-panel .data-table thead th {
    position: sticky;
    top: 0;
    z-index: 2;
}

.fees-search-toolbar {
    display: grid;
    grid-template-columns: minmax(260px, 460px) minmax(0, 1fr);
    gap: 12px;
    align-items: end;
    padding: 16px 18px 0;
}

.fees-search-field {
    margin: 0;
}

.fees-search-field input {
    border-color: #bad7ff;
    background: linear-gradient(135deg, #ffffff 0%, #f4f9ff 100%);
    box-shadow: 0 10px 22px rgba(15, 23, 42, 0.05);
}

.fees-search-caption {
    align-self: center;
    color: #64748b;
    font-size: 0.82rem;
    line-height: 1.5;
}

.fees-table-card {
    overflow-x: auto;
    background: #fff;
}

.fees-page .table-card .data-table th {
    background: linear-gradient(180deg, #f7fbff 0%, #eef6ff 100%);
    color: #5f7090;
    border-bottom: 1px solid #dbe7f4;
}

.fees-page .table-card .data-table td {
    border-bottom-color: #edf2f8;
}

.fees-register-table,
.fees-ledger-table {
    min-width: 760px;
    table-layout: auto;
}

.fees-register-table td,
.fees-ledger-table td {
    vertical-align: middle;
}

.fees-table-card .data-table th {
    white-space: nowrap;
}

.fees-table-card .data-table tbody tr:hover td {
    background: #fbfdff;
}

.fees-register-row.is-selected:hover td {
    background: rgba(8, 145, 178, 0.08);
}

.fees-ledger-row.is-cleared:hover td {
    background: rgba(148, 163, 184, 0.08);
}

.fees-register-table th:nth-child(1) {
    width: 26%;
}

.fees-register-table th:nth-child(2) {
    width: 15%;
}

.fees-register-table th:nth-child(3) {
    width: 9%;
}

.fees-register-table th:nth-child(4),
.fees-register-table th:nth-child(5),
.fees-register-table th:nth-child(6) {
    width: 12%;
}

.fees-register-table th:nth-child(7) {
    width: 14%;
}

.fees-ledger-table th:nth-child(1) {
    width: 26%;
}

.fees-ledger-table th:nth-child(2) {
    width: 14%;
}

.fees-ledger-table th:nth-child(3),
.fees-ledger-table th:nth-child(4),
.fees-ledger-table th:nth-child(5) {
    width: 12%;
}

.fees-ledger-table th:nth-child(6) {
    width: 24%;
}

.fees-money-cell {
    text-align: right;
    font-variant-numeric: tabular-nums;
    white-space: nowrap;
}

.fees-money-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 34px;
    padding: 6px 12px;
    border: 1px solid transparent;
    border-radius: 999px;
    font-weight: 800;
    letter-spacing: 0.01em;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.34);
}

.fees-tone-payable {
    background: linear-gradient(135deg, #fff7d6 0%, #ffe39a 100%);
    border-color: #f5cf78;
    color: #8a5700;
}

.fees-tone-paid {
    background: linear-gradient(135deg, #dcfce7 0%, #b8f5d2 100%);
    border-color: #8fddb0;
    color: #13653a;
}

.fees-tone-due {
    background: linear-gradient(135deg, #ffe0e8 0%, #ffc2d1 100%);
    border-color: #ff9db4;
    color: #a12748;
}

.fees-tone-collected {
    background: linear-gradient(135deg, #ede9fe 0%, #d7c8ff 100%);
    border-color: #c0aaf9;
    color: #5b2aa8;
}

.fees-tone-discount {
    background: linear-gradient(135deg, #ccfbf1 0%, #99f6e4 100%);
    border-color: #5eead4;
    color: #0f766e;
}

.fees-tone-fine {
    background: linear-gradient(135deg, #ffedd5 0%, #fed7aa 100%);
    border-color: #fdba74;
    color: #c2410c;
}

.fees-tone-neutral {
    background: linear-gradient(135deg, #f8fafc 0%, #e2e8f0 100%);
    border-color: #d5dde7;
    color: #60708a;
}

.fees-col-payable {
    color: #9a6700 !important;
}

.fees-col-paid {
    color: #177245 !important;
}

.fees-col-due {
    color: #b42354 !important;
}

.fees-col-collected {
    color: #6d28d9 !important;
}

.fees-col-discount {
    color: #0f766e !important;
}

.fees-col-fine {
    color: #c2410c !important;
}

.fees-action-cell {
    text-align: right;
    white-space: nowrap;
}

.fees-register-row.is-selected td {
    background: rgba(8, 145, 178, 0.06);
}

.fees-register-row.is-selected td:first-child {
    box-shadow: inset 3px 0 0 #0891b2;
}

.fees-assignment-pool {
    display: grid;
    gap: 14px;
    padding-top: 6px;
}

.fees-assignment-option {
    gap: 8px;
}

.fees-page .selection-option {
    border-radius: 14px;
    border-color: #d8e3f0;
    box-shadow: 0 10px 20px rgba(15, 23, 42, 0.04);
}

.fees-page .selection-option:nth-child(3n + 1) {
    background: linear-gradient(135deg, #f8fbff 0%, #eef6ff 100%);
}

.fees-page .selection-option:nth-child(3n + 2) {
    background: linear-gradient(135deg, #fffaf1 0%, #fff3d8 100%);
}

.fees-page .selection-option:nth-child(3n + 3) {
    background: linear-gradient(135deg, #faf5ff 0%, #f2e8ff 100%);
}

.fees-assignment-option input[type="checkbox"] {
    width: 18px;
    height: 18px;
}

.fees-student-summary,
.fees-receipt-balance {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 12px;
}

.fees-payment-header-side {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 10px;
    flex-wrap: wrap;
}

.fees-student-summary {
    padding: 16px 18px 0;
    grid-template-columns: repeat(6, minmax(0, 1fr));
}

.fees-summary-card {
    border-width: 1px;
    box-shadow: 0 12px 24px rgba(15, 23, 42, 0.05);
}

.fees-summary-count {
    background: linear-gradient(135deg, #eff6ff 0%, #dbeafe 100%);
    border-color: #bfd8fb;
}

.fees-summary-student,
.fees-summary-identity {
    background: linear-gradient(135deg, #f8fbff 0%, #edf5ff 100%);
    border-color: #d4e3f6;
}

.fees-summary-payable {
    background: linear-gradient(135deg, #fff8dd 0%, #ffecb4 100%);
    border-color: #f4d27d;
}

.fees-summary-paid {
    background: linear-gradient(135deg, #e8fff1 0%, #c6f5d7 100%);
    border-color: #9edbb8;
}

.fees-summary-discount {
    background: linear-gradient(135deg, #e0fffb 0%, #b8fff3 100%);
    border-color: #83e8d9;
}

.fees-summary-fine {
    background: linear-gradient(135deg, #fff3e4 0%, #ffd8ac 100%);
    border-color: #ffc17e;
}

.fees-summary-due {
    background: linear-gradient(135deg, #ffe8ef 0%, #ffc8d5 100%);
    border-color: #f3a7bb;
}

.fees-summary-card span {
    color: #576b88;
}

.fees-summary-payable span,
.fees-summary-payable strong {
    color: #8a5700;
}

.fees-summary-paid span,
.fees-summary-paid strong {
    color: #13653a;
}

.fees-summary-discount span,
.fees-summary-discount strong {
    color: #0f766e;
}

.fees-summary-fine span,
.fees-summary-fine strong {
    color: #c2410c;
}

.fees-summary-due span,
.fees-summary-due strong {
    color: #a12748;
}

.fees-summary-count span,
.fees-summary-count strong {
    color: #3730a3;
}

.fees-selected-banner {
    margin: 14px 18px 0;
    padding: 14px 16px;
    border: 1px solid #d4e0f1;
    border-radius: 14px;
    background: linear-gradient(135deg, rgba(56, 189, 248, 0.12) 0%, rgba(167, 139, 250, 0.1) 48%, rgba(255, 184, 77, 0.12) 100%);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.35);
}

.fees-selected-copy {
    display: grid;
    gap: 4px;
    min-width: 0;
}

.fees-selected-copy strong {
    color: #1f3147;
    font-size: 0.98rem;
}

.fees-selected-copy span {
    color: #64748b;
    font-size: 0.85rem;
    line-height: 1.5;
    overflow-wrap: anywhere;
}

.fees-payment-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.fees-collection-form > .error-text {
    display: block;
    padding: 0 18px;
}

.fees-ledger-header {
    display: flex;
    align-items: start;
    justify-content: space-between;
    gap: 12px;
    padding: 0 18px;
}

.fees-ledger-header h3 {
    margin: 0;
    color: #0f2c54;
    font-size: 0.96rem;
}

.fees-ledger-header p {
    margin: 4px 0 0;
    color: #64748b;
    font-size: 0.82rem;
    line-height: 1.5;
}

.fees-ledger-header-badges {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    justify-content: flex-end;
}

.fees-ledger-cards {
    display: grid;
    gap: 14px;
    padding: 0 18px 18px;
}

.fees-ledger-card {
    display: grid;
    gap: 14px;
    padding: 16px;
    border: 1px solid #d7e4f2;
    border-radius: 18px;
    background:
        radial-gradient(circle at top right, rgba(56, 189, 248, 0.13), transparent 26%),
        linear-gradient(135deg, #ffffff 0%, #f8fbff 100%);
    box-shadow: 0 14px 30px rgba(15, 23, 42, 0.07);
    transition: border-color 0.18s ease, box-shadow 0.18s ease, transform 0.18s ease;
}

.fees-ledger-card.is-selected {
    border-color: #38bdf8;
    box-shadow: 0 18px 36px rgba(14, 165, 233, 0.16);
}

.fees-ledger-card.has-error {
    border-color: #fb7185;
    box-shadow: 0 16px 34px rgba(225, 29, 72, 0.12);
}

.fees-ledger-card.is-cleared {
    background: linear-gradient(135deg, #f8fafc 0%, #eef4fb 100%);
    opacity: 0.88;
}

.fees-ledger-card-top {
    display: flex;
    justify-content: space-between;
    gap: 16px;
    align-items: flex-start;
}

.fees-ledger-card-identity {
    display: grid;
    gap: 8px;
    min-width: 0;
}

.fees-ledger-card-action {
    display: flex;
    justify-content: flex-end;
}

.fees-ledger-title-row {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}

.fees-ledger-title-row h4 {
    margin: 0;
    color: #0f2c54;
    font-size: 1rem;
}

.fees-ledger-meta {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.fees-ledger-meta span {
    display: inline-flex;
    align-items: center;
    min-height: 28px;
    padding: 5px 10px;
    border: 1px solid #dbeafe;
    border-radius: 999px;
    background: #f8fbff;
    color: #52677f;
    font-size: 0.76rem;
    font-weight: 700;
}

.fees-ledger-toggle {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    min-height: 36px;
    padding: 8px 12px;
    border: 1px solid #bfdbfe;
    border-radius: 999px;
    background: linear-gradient(135deg, #eff6ff 0%, #dbeafe 100%);
    color: #1e3a8a;
    font-weight: 800;
    white-space: nowrap;
    cursor: pointer;
}

.fees-ledger-toggle input {
    width: 17px;
    height: 17px;
}

.fees-ledger-card-stats {
    display: grid;
    grid-template-columns: repeat(6, minmax(0, 1fr));
    gap: 10px;
}

.fees-ledger-stat {
    display: grid;
    gap: 7px;
    min-width: 0;
}

.fees-ledger-stat > span {
    color: #64748b;
    font-size: 0.72rem;
    font-weight: 800;
    letter-spacing: 0.06em;
    text-transform: uppercase;
}

.fees-ledger-stat .fees-money-badge {
    width: 100%;
    min-width: 0;
}

.fees-ledger-card-inputs {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
    padding: 12px;
    border: 1px dashed #cbdff7;
    border-radius: 14px;
    background: linear-gradient(135deg, rgba(239, 246, 255, 0.72), rgba(255, 251, 235, 0.55));
}

.fees-inline-field {
    margin: 0;
}

.fees-ledger-cleared-note {
    display: flex;
    justify-content: space-between;
    gap: 10px;
    padding: 12px 14px;
    border: 1px dashed #cbd5e1;
    border-radius: 14px;
    background: rgba(248, 250, 252, 0.82);
    color: #64748b;
}

.fees-ledger-cleared-note strong {
    color: #334155;
}

.fees-amount-input {
    width: 100%;
    max-width: none;
}

.fees-amount-stack {
    display: grid;
    justify-items: end;
    gap: 6px;
}

.fees-input-hint {
    color: #64748b;
    font-size: 0.74rem;
    line-height: 1.2;
}

.fees-amount-stack .error-text {
    min-height: 0;
    margin-top: 0;
    text-align: right;
}

.fees-ledger-row.is-cleared td {
    background: rgba(148, 163, 184, 0.05);
}

.fees-submit-actions {
    padding: 18px;
    border-top: 1px solid #edf1f6;
    align-items: center;
    justify-content: space-between;
}

.fees-submit-caption {
    color: #5b6f8b;
    font-size: 0.84rem;
    line-height: 1.5;
    max-width: 460px;
}

.fees-table-actions {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.fees-print-surface {
    overflow: visible;
    background: transparent;
}

.fees-revert-alert {
    margin: 16px 0 0;
}

.money-receipt-note-reverted {
    color: #9a3412;
}

.fees-table-actions {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}

.fees-table-actions form {
    margin: 0;
}

.button-danger {
    background: linear-gradient(135deg, #ef4444 0%, #b91c1c 100%);
    color: #fff;
    border-color: #b91c1c;
    box-shadow: 0 10px 22px rgba(185, 28, 28, 0.22);
}

.button-danger:hover {
    transform: translateY(-1px);
    box-shadow: 0 14px 28px rgba(185, 28, 28, 0.28);
}

.hr-master-form {
    align-items: start;
}

.hr-master-form-triple {
    grid-template-columns: minmax(0, 1.15fr) minmax(0, 1.15fr) minmax(180px, 0.55fr);
}

.hr-master-form-triple .hr-master-description {
    grid-column: 1 / -1;
}

.hr-master-active {
    align-self: center;
}

.hr-master-form > .button {
    align-self: center;
}

.hr-master-row-form {
    display: grid;
    grid-template-columns: minmax(160px, 1.1fr) minmax(100px, 0.6fr) minmax(220px, 1.5fr) auto 72px auto;
    gap: 10px;
    align-items: center;
}

.hr-master-row-form-designation {
    grid-template-columns: minmax(150px, 1fr) minmax(150px, 1fr) minmax(90px, 0.55fr) minmax(190px, 1.25fr) auto 72px auto;
}

.hr-master-row-shell {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 8px;
    align-items: center;
}

.hr-master-row-form input:not([type="checkbox"]):not([type="hidden"]),
.hr-master-row-form select {
    width: 100%;
    min-height: 38px;
    padding: 8px 10px;
    border: 1px solid #cfd8e3;
    border-radius: 10px;
    background: #ffffff;
    color: #1f2937;
    font: inherit;
    box-shadow: none;
}

.hr-master-row-form input:not([type="checkbox"]):not([type="hidden"]):focus,
.hr-master-row-form select:focus {
    outline: none;
    border-color: #94a3b8;
    box-shadow: 0 0 0 3px rgba(148, 163, 184, 0.16);
}

.hr-master-delete-form {
    display: inline-flex;
    margin-top: 0;
    align-self: center;
}

.hr-master-icon-button {
    width: 42px;
    min-width: 42px;
    height: 38px;
    padding: 0;
    border-radius: 12px;
}

.hr-master-icon-button svg {
    width: 18px;
    height: 18px;
    fill: none;
    stroke: currentColor;
    stroke-width: 2.2;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.hr-master-count {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 36px;
    border-radius: 999px;
    background: #eef6ff;
    color: #0f4c81;
    font-weight: 900;
}

.hr-directory-toolbar {
    grid-template-columns: minmax(220px, 280px) minmax(260px, 1fr) auto;
    margin-bottom: 16px;
}

.hr-directory-actions {
    display: flex;
    gap: 8px;
    align-items: center;
    justify-content: flex-start;
    align-self: end;
}

.hr-staff-cell {
    display: flex;
    align-items: center;
    gap: 12px;
    min-width: 220px;
}

.hr-staff-cell img,
.hr-staff-cell > span {
    width: 46px;
    height: 46px;
    flex: 0 0 46px;
    border-radius: 14px;
    display: grid;
    place-items: center;
    object-fit: cover;
    background: linear-gradient(135deg, #e0f2fe 0%, #bae6fd 100%);
    color: #075985;
    font-weight: 900;
}

.hr-staff-cell small {
    display: block;
    margin-top: 3px;
    color: #64748b;
    font-weight: 700;
}

.status-pill {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 6px 10px;
    border-radius: 999px;
    font-size: 0.78rem;
    font-weight: 900;
}

.status-pill-active {
    background: #dcfce7;
    color: #166534;
}

.status-pill-disabled {
    background: #fee2e2;
    color: #991b1b;
}

.hr-inline-disable,
.hr-profile-disable {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}

.hr-inline-disable input,
.hr-profile-disable input {
    min-height: 34px;
    max-width: 180px;
}

.hr-inline-disable-input {
    width: 180px;
    min-height: 38px;
    padding: 8px 12px;
    border: 1px solid #cfd8e3;
    border-radius: 12px;
    background: linear-gradient(135deg, #ffffff 0%, #f8fbff 100%);
    color: #1f2937;
    font: inherit;
    box-shadow: none;
}

.hr-inline-disable-input::placeholder {
    color: #94a3b8;
}

.hr-inline-disable-input:focus {
    outline: none;
    border-color: #94a3b8;
    box-shadow: 0 0 0 3px rgba(148, 163, 184, 0.16);
}

.hr-existing-documents {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin: 10px 0 14px;
}

.hr-existing-documents a,
.hr-document-card {
    display: inline-flex;
    flex-direction: column;
    gap: 3px;
    padding: 10px 12px;
    border: 1px solid #dbe3ee;
    border-radius: 12px;
    background: #f8fafc;
    color: #0f172a;
    text-decoration: none;
    font-weight: 800;
}

.hr-profile-card {
    overflow: hidden;
}

.hr-profile-hero {
    display: grid;
    grid-template-columns: 132px minmax(0, 1fr) 190px;
    gap: 22px;
    align-items: center;
}

.hr-profile-photo {
    width: 132px;
    height: 152px;
    display: grid;
    place-items: center;
    border: 1px solid #dbe3ee;
    border-radius: 22px;
    overflow: hidden;
    background: linear-gradient(135deg, #e0f2fe 0%, #ecfeff 100%);
    color: #075985;
    font-size: 1.6rem;
    font-weight: 900;
}

.hr-profile-photo img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.hr-profile-title h2 {
    margin: 4px 0;
    color: #10294d;
    font-size: clamp(1.6rem, 2.2vw, 2.35rem);
    line-height: 1.05;
}

.hr-profile-title p {
    margin: 0 0 12px;
    color: #475569;
    font-weight: 800;
}

.hr-profile-signature {
    display: grid;
    gap: 8px;
    justify-items: center;
    padding: 14px;
    border: 1px dashed #cbd5e1;
    border-radius: 16px;
    background: #fff;
}

.hr-profile-signature span {
    color: #64748b;
    font-size: 0.78rem;
    font-weight: 900;
    text-transform: uppercase;
}

.hr-profile-signature img {
    max-width: 160px;
    max-height: 70px;
    object-fit: contain;
}

.hr-profile-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 20px;
}

.hr-profile-facts {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
}

.hr-profile-facts > div {
    display: grid;
    gap: 4px;
    padding: 12px;
    border: 1px solid #e2e8f0;
    border-radius: 14px;
    background: #fff;
}

.hr-profile-facts span {
    color: #64748b;
    font-size: 0.76rem;
    font-weight: 900;
    text-transform: uppercase;
}

.hr-profile-facts strong {
    color: #111827;
    font-weight: 900;
    overflow-wrap: anywhere;
}

.hr-profile-wide {
    grid-column: 1 / -1;
}

.hr-qualification-list {
    display: grid;
    gap: 10px;
    margin: 0;
    padding-left: 20px;
}

.hr-qualification-list li {
    font-weight: 800;
}

.hr-document-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 12px;
}

.hr-document-card span {
    color: #64748b;
    font-size: 0.76rem;
    font-weight: 900;
    text-transform: uppercase;
}

.hr-document-card strong {
    overflow-wrap: anywhere;
}

@media (max-width: 1180px) {
    .hr-master-form-triple,
    .hr-master-row-form,
    .hr-master-row-form-designation,
    .hr-profile-hero,
    .hr-profile-grid {
        grid-template-columns: 1fr;
    }

    .hr-directory-toolbar {
        grid-template-columns: 1fr;
    }

    .hr-profile-signature {
        justify-items: start;
    }

    .hr-inline-disable,
    .hr-profile-disable,
    .hr-directory-actions {
        width: 100%;
    }
}

@media (max-width: 640px) {
    .hr-profile-facts {
        grid-template-columns: 1fr;
    }

    .hr-profile-photo {
        width: 108px;
        height: 128px;
    }
}

.fees-receipt-sheet {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 32px minmax(0, 1fr);
    gap: 12px;
    padding: 18px;
    align-items: stretch;
}

.fees-receipt-card {
    display: grid;
    gap: 12px;
    padding: 14px;
    border: 1px solid #dbe3ee;
    border-radius: 0;
    background: #fff;
    box-shadow: none;
    break-inside: avoid;
    page-break-inside: avoid;
}

.fees-receipt-cutline {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    align-self: stretch;
    break-inside: avoid;
    page-break-inside: avoid;
}

.fees-receipt-cutline::before {
    content: "";
    position: absolute;
    top: 0;
    bottom: 0;
    left: 50%;
    border-left: 2px dotted #94a3b8;
    transform: translateX(-50%);
}

.fees-receipt-cutline-icon {
    position: relative;
    z-index: 1;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 34px;
    height: 34px;
    border: 1px solid #cbd5e1;
    border-radius: 999px;
    background: #fff;
    color: #475569;
    font-size: 1rem;
    box-shadow: 0 10px 22px rgba(15, 23, 42, 0.06);
}

.money-receipt-card {
    color: #1f2937;
    font-size: 0.84rem;
}

.money-receipt-header {
    padding-bottom: 8px;
    border-bottom: 1px solid #111827;
}

.money-receipt-school {
    display: grid;
    grid-template-columns: 46px minmax(0, 1fr);
    gap: 12px;
    align-items: start;
}

.money-receipt-school-logo {
    width: 40px;
    height: 40px;
    border: 2px solid #1d4f91;
    border-radius: 999px;
    overflow: hidden;
    display: grid;
    place-items: center;
    background: #fff;
    color: #1d4f91;
    font-size: 0.72rem;
    font-weight: 900;
}

.money-receipt-school-logo img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.money-receipt-school-copy {
    text-align: center;
}

.money-receipt-school-copy h2 {
    margin: 0 0 6px;
    color: #374151;
    font-size: 1rem;
    font-weight: 800;
    letter-spacing: 0.02em;
}

.money-receipt-school-copy p {
    margin: 2px 0;
    color: #4b5563;
    font-size: 0.72rem;
    line-height: 1.35;
}

.money-receipt-title-row {
    position: relative;
    display: flex;
    justify-content: center;
    margin-top: -1px;
    padding-top: 2px;
}

.money-receipt-title-row::before {
    content: "";
    position: absolute;
    left: -14px;
    right: -14px;
    top: 50%;
    border-top: 1px solid #111827;
    transform: translateY(-50%);
}

.money-receipt-title-row span {
    position: relative;
    z-index: 1;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 28px;
    padding: 4px 12px;
    border: 2px solid #374151;
    border-radius: 999px;
    background: #fff;
    color: #374151;
    font-size: 0.82rem;
    font-weight: 800;
    white-space: nowrap;
}

.money-receipt-meta-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 6px 22px;
}

.money-receipt-meta-item {
    display: grid;
    grid-template-columns: auto 1fr;
    gap: 6px;
    align-items: baseline;
}

.money-receipt-meta-item-wide {
    grid-column: 1 / -1;
}

.money-receipt-meta-item span {
    color: #1d4f91;
    font-size: 0.74rem;
    font-weight: 800;
}

.money-receipt-meta-item strong {
    color: #374151;
    font-size: 0.74rem;
    font-weight: 500;
}

.money-receipt-table-wrap {
    overflow: hidden;
}

.money-receipt-table {
    width: 100%;
    border-collapse: collapse;
    table-layout: fixed;
}

.money-receipt-table th,
.money-receipt-table td {
    padding: 4px 6px;
    border: 1px solid #111827;
    color: #374151;
    font-size: 0.76rem;
    line-height: 1.25;
}

.money-receipt-table thead th,
.money-receipt-table tfoot th {
    color: #1d4f91;
    font-weight: 800;
    background: #fff;
}

.money-receipt-slno {
    width: 44px;
}

.money-receipt-amount {
    width: 82px;
}

.money-receipt-table td:last-child,
.money-receipt-table th:last-child {
    text-align: right;
}

.money-receipt-table tfoot th:first-child {
    text-align: right;
}

.money-receipt-words,
.money-receipt-note {
    color: #374151;
    font-size: 0.74rem;
    line-height: 1.35;
}

.money-receipt-words strong,
.money-receipt-note strong {
    color: #1d4f91;
}

.money-receipt-footer {
    margin-top: 14px;
    display: grid;
    justify-items: end;
    gap: 4px;
    color: #374151;
    font-size: 0.74rem;
}

.money-receipt-signature-line {
    width: 140px;
    border-top: 1px solid #111827;
}

.fees-collect-screen {
    gap: 24px;
}

.fees-collect-screen > .form-page-header {
    padding: 20px 22px;
    border: 1px solid rgba(59, 130, 246, 0.18);
    background:
        radial-gradient(circle at top right, rgba(56, 189, 248, 0.28), transparent 30%),
        radial-gradient(circle at bottom left, rgba(16, 185, 129, 0.26), transparent 34%),
        linear-gradient(135deg, #0f172a 0%, #1d4ed8 50%, #0f766e 100%);
    box-shadow: 0 24px 56px rgba(15, 23, 42, 0.16);
}

.fees-collect-screen > .form-page-header h2 {
    color: #f8fbff;
    font-size: 1.45rem;
}

.fees-collect-screen > .form-page-header p {
    color: rgba(226, 232, 240, 0.9);
}

.fees-collect-screen > .form-page-header .form-page-meta span {
    color: #f8fbff;
    background: rgba(255, 255, 255, 0.12);
    border-color: rgba(255, 255, 255, 0.14);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.12);
}

.fees-search-hero,
.fees-student-select-panel,
.fees-due-register-panel,
.fees-scholar-dossier,
.fees-payment-panel {
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 14px 32px rgba(15, 23, 42, 0.08);
}

.fees-search-hero {
    display: grid;
    gap: 12px;
    padding: 20px;
    border-top: 3px solid #3b82f6;
}

.fees-search-hero-title {
    display: flex;
    align-items: center;
    gap: 10px;
}

.fees-search-hero-title h2 {
    margin: 0;
    color: #111827;
    font-size: 0.82rem;
    letter-spacing: 0.14em;
    text-transform: uppercase;
}

.fees-search-hero-title p {
    margin: 4px 0 0;
    color: #64748b;
    font-size: 0.78rem;
}

.fees-panel-icon {
    display: inline-grid;
    place-items: center;
    width: 28px;
    height: 28px;
    border-radius: 8px;
    background: #eff6ff;
    color: #2563eb;
    font-size: 0.78rem;
    font-weight: 900;
}

.fees-search-hero-control {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr);
    align-items: center;
    gap: 10px;
    min-height: 46px;
    padding: 0 16px;
    border: 1px solid #d9e2ef;
    border-radius: 10px;
    background: #f8fafc;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.8);
}

.fees-search-hero-control span {
    color: #3b82f6;
    font-size: 0.78rem;
    font-weight: 800;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.fees-search-hero-control input {
    width: 100%;
    border: 0;
    background: transparent;
    box-shadow: none;
    font-weight: 700;
}

.fees-search-hero-control input:focus {
    outline: none;
}

.fees-student-select-panel,
.fees-payment-panel {
    border-top: 3px solid #10b981;
}

.fees-scholar-dossier {
    border-top: 3px solid #6366f1;
}

.fees-session-pill {
    border: 1px solid #bbf7d0;
    background: #ecfdf5;
}

.fees-session-pill strong {
    color: #047857 !important;
}

.fees-filter-field-student {
    grid-column: span 6;
}

.fees-due-register-panel {
    border-top: 3px solid #14b8a6;
}

.fees-due-register-panel .dashboard-panel-header {
    padding-top: 14px;
    padding-bottom: 12px;
}

.fees-due-register-panel .fees-table-card {
    max-height: 260px;
}

.fees-payment-workspace {
    display: grid;
    grid-template-columns: minmax(280px, 0.62fr) minmax(0, 1.38fr);
    gap: 24px;
    align-items: start;
}

.fees-payment-workspace > .fees-payment-panel:only-child {
    grid-column: 1 / -1;
}

.fees-scholar-cover {
    display: grid;
    place-items: center;
    min-height: 84px;
    background:
        radial-gradient(circle at center, rgba(99, 102, 241, 0.16), transparent 34%),
        linear-gradient(135deg, #eef2ff 0%, #f8fafc 100%);
}

.fees-scholar-avatar {
    display: grid;
    place-items: center;
    width: 70px;
    height: 70px;
    margin-top: 34px;
    border: 4px solid #fff;
    border-radius: 999px;
    background: linear-gradient(135deg, #1d4ed8 0%, #0f766e 100%);
    color: #fff;
    font-size: 1.4rem;
    font-weight: 900;
    box-shadow: 0 14px 30px rgba(15, 23, 42, 0.18);
    overflow: hidden;
}

.fees-scholar-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.fees-scholar-name {
    display: grid;
    gap: 8px;
    justify-items: center;
    padding: 42px 18px 18px;
    border-bottom: 1px solid #edf2f7;
    text-align: center;
}

.fees-scholar-name strong {
    color: #0f172a;
    font-size: 1rem;
    letter-spacing: 0.03em;
    text-transform: uppercase;
}

.fees-scholar-name span {
    display: inline-flex;
    align-items: center;
    min-height: 22px;
    padding: 3px 10px;
    border-radius: 999px;
    background: #e0e7ff;
    color: #3730a3;
    font-size: 0.75rem;
    font-weight: 800;
    letter-spacing: 0.08em;
}

.fees-scholar-details {
    display: grid;
}

.fees-scholar-details > div {
    display: flex;
    justify-content: space-between;
    gap: 16px;
    padding: 14px 18px;
    border-bottom: 1px solid #edf2f7;
}

.fees-scholar-details span {
    color: #64748b;
    font-size: 0.78rem;
    font-weight: 800;
}

.fees-scholar-details strong {
    color: #0f172a;
    text-align: right;
}

.fees-dues-alert {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    border-color: #fde68a;
    background: linear-gradient(135deg, #fffbeb 0%, #fff7d6 100%);
}

.fees-dues-alert-total {
    display: grid;
    gap: 4px;
    justify-items: end;
    min-width: 130px;
}

.fees-dues-alert-total span {
    color: #92400e;
    font-size: 0.72rem;
    font-weight: 900;
    letter-spacing: 0.12em;
    text-transform: uppercase;
}

.fees-dues-alert-total strong {
    color: #9a3412;
    font-size: 1.18rem;
}

.fees-payment-tools {
    display: flex;
    justify-content: flex-end;
    gap: 8px;
    padding: 0 18px 12px;
}

.fees-collect-screen .fees-ledger-card {
    grid-template-columns: minmax(210px, 0.95fr) minmax(300px, 1.2fr) minmax(360px, 1fr);
    align-items: center;
    gap: 12px;
    padding: 10px 12px;
    border-radius: 10px;
    box-shadow: none;
}

.fees-collect-screen .fees-ledger-card-top {
    min-width: 0;
}

.fees-collect-screen .fees-ledger-title-row h4 {
    font-size: 0.9rem;
}

.fees-collect-screen .fees-ledger-meta span {
    min-height: 22px;
    padding: 3px 7px;
    font-size: 0.68rem;
}

.fees-collect-screen .fees-ledger-card-stats {
    grid-template-columns: repeat(4, minmax(0, 1fr));
}

.fees-collect-screen .fees-ledger-stat:nth-child(3),
.fees-collect-screen .fees-ledger-stat:nth-child(4) {
    display: none;
}

.fees-collect-screen .fees-ledger-stat > span {
    font-size: 0.66rem;
}

.fees-collect-screen .fees-ledger-stat .fees-money-badge {
    min-height: 28px;
    padding: 4px 8px;
    font-size: 0.82rem;
}

.fees-collect-screen .fees-ledger-card-inputs {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px;
    padding: 0;
    border: 0;
    background: transparent;
}

.fees-collect-screen .fees-inline-field {
    gap: 4px;
}

.fees-collect-screen .fees-inline-field label {
    font-size: 0.7rem;
    line-height: 1.1;
}

.fees-collect-screen .fees-inline-field input {
    min-height: 34px;
    padding: 6px 8px;
    font-size: 0.86rem;
}

.fees-collect-screen .fees-inline-field .fees-input-hint {
    display: none;
}

.fees-collect-screen .fees-ledger-toggle {
    min-height: 30px;
    padding: 6px 10px;
    font-size: 0.76rem;
}

@media (max-width: 1180px) {
    .fees-master-layout,
    .fees-collection-layout,
    .fees-statement-layout,
    .fees-receipt-student {
        grid-template-columns: minmax(0, 1fr);
    }

    .fees-payment-workspace {
        grid-template-columns: minmax(0, 1fr);
    }

    .fees-filter-panel .fees-filter-grid {
        grid-template-columns: repeat(6, minmax(0, 1fr));
    }

    .fees-filter-field-session,
    .fees-filter-field-class {
        grid-column: span 3;
    }

    .fees-filter-field-section,
    .fees-filter-field-date {
        grid-column: span 3;
    }

    .fees-payment-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .fees-receipt-sheet {
        grid-template-columns: minmax(0, 1fr);
    }

    .fees-receipt-cutline {
        min-height: 24px;
    }

    .fees-receipt-cutline::before {
        top: 50%;
        bottom: auto;
        left: 0;
        right: 0;
        border-left: 0;
        border-top: 2px dotted #94a3b8;
        transform: translateY(-50%);
    }

    .money-receipt-meta-grid,
    .fees-student-summary,
    .fees-receipt-balance {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .fees-ledger-card-stats {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }

    .fees-collect-screen .fees-ledger-card {
        grid-template-columns: minmax(0, 1fr);
    }

    .fees-collect-screen .fees-ledger-card-stats {
        grid-template-columns: repeat(4, minmax(0, 1fr));
    }
}

@media (max-width: 720px) {
    .fees-filter-panel .fees-filter-grid,
    .fees-payment-grid,
    .fees-search-toolbar,
    .fees-ledger-card-inputs {
        grid-template-columns: minmax(0, 1fr);
    }

    .money-receipt-school,
    .fees-payment-header-side,
    .fees-ledger-header,
    .fees-submit-actions,
    .fees-ledger-card-top,
    .fees-ledger-cleared-note {
        flex-direction: column;
        align-items: stretch;
    }

    .fees-filter-field-session,
    .fees-filter-field-class,
    .fees-filter-field-section,
    .fees-filter-field-date,
    .fees-filter-field-student,
    .fees-filter-actions {
        grid-column: 1 / -1;
    }

    .money-receipt-meta-grid,
    .fees-student-summary,
    .fees-receipt-balance {
        grid-template-columns: minmax(0, 1fr);
    }

    .money-receipt-meta-item,
    .money-receipt-meta-item-wide {
        grid-column: auto;
    }

    .money-receipt-title-row span {
        white-space: normal;
        text-align: center;
    }

    .fees-table-actions {
        flex-direction: column;
    }

    .fees-filter-actions .button,
    .fees-amount-input {
        max-width: none;
        width: 100%;
    }

    .fees-ledger-card-stats {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .fees-ledger-header-badges {
        justify-content: stretch;
    }

    .fees-ledger-header-badges .fees-money-badge {
        width: 100%;
    }

    .fees-dues-alert,
    .fees-payment-tools {
        flex-direction: column;
        align-items: stretch;
    }

    .fees-dues-alert-total {
        justify-items: start;
    }

    .fees-collect-screen .fees-ledger-card-stats,
    .fees-collect-screen .fees-ledger-card-inputs {
        grid-template-columns: minmax(0, 1fr);
    }

    .fees-action-cell,
    .fees-money-cell,
    .fees-amount-stack .error-text {
        text-align: left;
    }
}

@media print {
    .fees-page {
        display: block;
    }

    .fees-print-toolbar,
    .erp-sidebar,
    .erp-topbar,
    .quicklinks-panel,
    .quicklinks-backdrop,
    .dashboard-footer {
        display: none !important;
    }

    .erp-main,
    .erp-content,
    .page-body {
        padding: 0 !important;
        margin: 0 !important;
    }

    .fees-print-surface,
    .dashboard-panel {
        box-shadow: none !important;
        border: 0 !important;
    }

    .fees-print-surface {
        padding: 0 !important;
        background: transparent !important;
    }

    .fees-receipt-sheet {
        grid-template-columns: minmax(0, 1fr) 18px minmax(0, 1fr);
        gap: 4mm;
        padding: 0;
    }

    .fees-page .dashboard-panel > .table-card,
    .fees-page .dashboard-panel > .fees-receipt-grid,
    .fees-page .dashboard-panel > .fees-receipt-balance,
    .fees-page .dashboard-panel > .fees-assignment-pool {
        margin: 0 !important;
        padding: 0 !important;
    }

    .fees-receipt-card {
        gap: 10px;
        padding: 8px;
        border: 1px solid #cbd5e1;
        border-radius: 0;
        background: #fff;
        box-shadow: none;
    }

    .fees-receipt-cutline {
        min-height: auto;
    }

    .fees-receipt-cutline-icon {
        width: 18px;
        height: 18px;
        font-size: 0.7rem;
        box-shadow: none;
    }

    .money-receipt-card {
        font-size: 0.74rem;
    }

    .money-receipt-school {
        grid-template-columns: 30px minmax(0, 1fr);
        gap: 8px;
    }

    .money-receipt-school-logo {
        width: 28px;
        height: 28px;
        border-width: 1px;
        font-size: 0.58rem;
    }

    .money-receipt-school-copy h2 {
        margin-bottom: 3px;
        font-size: 0.82rem;
    }

    .money-receipt-school-copy p,
    .money-receipt-meta-item span,
    .money-receipt-meta-item strong,
    .money-receipt-table th,
    .money-receipt-table td,
    .money-receipt-words,
    .money-receipt-note,
    .money-receipt-footer {
        font-size: 0.62rem;
    }

    .money-receipt-title-row span {
        min-height: 22px;
        padding: 2px 10px;
        font-size: 0.68rem;
        border-width: 1px;
    }

    .money-receipt-meta-grid {
        gap: 4px 12px;
    }

    .money-receipt-table th,
    .money-receipt-table td {
        padding: 3px 5px;
    }

    .money-receipt-slno {
        width: 30px;
    }

    .money-receipt-amount {
        width: 54px;
    }

    .money-receipt-signature-line {
        width: 88px;
    }
}

/* Modern branded authentication gateway */
.auth-body {
    min-height: 100vh;
    padding: clamp(14px, 2vw, 28px);
    background:
        radial-gradient(circle at 9% 12%, rgba(255, 199, 89, 0.5), transparent 28%),
        radial-gradient(circle at 92% 18%, rgba(20, 184, 166, 0.35), transparent 28%),
        radial-gradient(circle at 52% 92%, rgba(59, 130, 246, 0.28), transparent 32%),
        linear-gradient(135deg, #f9fbff 0%, #eef6ff 44%, #fff7ed 100%);
}

.auth-page {
    min-height: calc(100vh - clamp(28px, 4vw, 56px));
    justify-content: center;
}

.auth-shell {
    width: min(1240px, 100%);
    min-height: min(760px, calc(100vh - 76px));
    grid-template-columns: minmax(380px, 0.92fr) minmax(440px, 1.08fr);
    border: 1px solid rgba(255, 255, 255, 0.82);
    border-radius: 34px;
    background: rgba(255, 255, 255, 0.62);
    box-shadow: 0 30px 90px rgba(15, 23, 42, 0.16);
    backdrop-filter: blur(24px);
}

.auth-brand {
    position: relative;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    gap: 30px;
    min-height: 100%;
    padding: clamp(30px, 4vw, 58px);
    overflow: hidden;
    background:
        linear-gradient(150deg, rgba(7, 21, 48, 0.98), rgba(13, 80, 122, 0.94)),
        radial-gradient(circle at 20% 20%, rgba(255, 214, 102, 0.28), transparent 28%);
}

.auth-brand::before,
.auth-brand::after {
    content: "";
    position: absolute;
    border-radius: 999px;
    pointer-events: none;
}

.auth-brand::before {
    width: 280px;
    height: 280px;
    right: -90px;
    top: -70px;
    background: rgba(255, 214, 102, 0.22);
}

.auth-brand::after {
    width: 190px;
    height: 190px;
    left: -60px;
    bottom: 130px;
    background: rgba(45, 212, 191, 0.2);
}

.auth-brand > * {
    position: relative;
    z-index: 1;
}

.auth-brand-top {
    display: flex;
    align-items: center;
    gap: 12px;
}

.auth-platform-mark,
.auth-school-context-logo-image,
.auth-school-context-logo-mark {
    width: 68px;
    height: 68px;
    flex: 0 0 68px;
    border: 4px solid rgba(255, 255, 255, 0.72);
    border-radius: 22px;
    background: #fff;
    box-shadow: 0 16px 34px rgba(0, 0, 0, 0.24);
}

.auth-platform-mark,
.auth-school-context-logo-image {
    object-fit: contain;
    padding: 4px;
}

.auth-school-context-logo-mark {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: #0f2f57;
    font-size: 1.15rem;
    font-weight: 900;
}

.auth-brand-top span,
.auth-brand-footer-card span {
    display: block;
    color: rgba(232, 244, 255, 0.74);
    font-size: 0.72rem;
    font-weight: 800;
    letter-spacing: 0.16em;
    text-transform: uppercase;
}

.auth-brand-top strong {
    display: block;
    margin-top: 3px;
    color: #fff;
    font-size: 1rem;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.auth-platform-wordmark {
    width: min(100%, 470px);
    display: block;
    margin: 16px 0 12px;
    border-radius: 18px;
    background: rgba(255, 255, 255, 0.96);
    padding: 4px;
    box-shadow: 0 14px 26px rgba(8, 20, 44, 0.18);
}

.auth-brand-copy p {
    max-width: 500px;
    color: rgba(236, 249, 255, 0.86);
    font-size: 1rem;
}

.auth-school-context {
    display: grid;
    gap: 10px;
}

.auth-school-context-card {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 16px 18px;
    border-radius: 22px;
    border: 1px solid rgba(255, 255, 255, 0.22);
    background: rgba(255, 255, 255, 0.14);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.16);
}

.auth-school-context-meta {
    min-width: 0;
    display: grid;
    gap: 4px;
}

.auth-school-context-meta strong,
.auth-school-context-meta span,
.auth-school-context-meta small {
    display: block;
    overflow-wrap: anywhere;
}

.auth-school-context-meta strong {
    color: #ffffff;
    font-size: 1rem;
}

.auth-school-context-meta span {
    color: rgba(234, 247, 255, 0.82);
    font-size: 0.82rem;
    font-weight: 800;
    letter-spacing: 0.08em;
}

.auth-school-context-meta small {
    color: rgba(234, 247, 255, 0.74);
    font-size: 0.86rem;
}

.auth-portal-badges {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.auth-portal-badges span,
.auth-brand-footer-card {
    border: 1px solid rgba(255, 255, 255, 0.18);
    background: rgba(255, 255, 255, 0.12);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.18);
}

.auth-portal-badges span {
    padding: 10px 13px;
    border-radius: 999px;
    color: #fff;
    font-weight: 800;
}

.auth-brand-footer-card {
    display: grid;
    gap: 7px;
    padding: 16px 18px;
    border-radius: 22px;
    color: #fff;
}

.auth-brand-footer-card strong {
    overflow-wrap: anywhere;
}

.auth-brand-footer-card small {
    color: rgba(232, 244, 255, 0.72);
    line-height: 1.6;
}

.auth-card {
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: clamp(28px, 4vw, 56px);
    background:
        linear-gradient(180deg, rgba(255, 255, 255, 0.96), rgba(248, 252, 255, 0.92)),
        radial-gradient(circle at 88% 12%, rgba(255, 214, 102, 0.18), transparent 30%);
}

.auth-panel-heading {
    margin-bottom: 22px;
}

.auth-kicker {
    display: inline-flex;
    align-items: center;
    width: fit-content;
    padding: 8px 12px;
    border-radius: 999px;
    background: #e0f2fe;
    color: #0369a1;
    font-size: 0.72rem;
    font-weight: 900;
    letter-spacing: 0.16em;
    text-transform: uppercase;
}

.auth-panel-heading h2 {
    margin: 13px 0 8px;
    color: var(--title-strong);
    font-size: clamp(1.65rem, 2.4vw, 2.55rem);
    line-height: 1.1;
}

.auth-panel-heading p {
    max-width: 640px;
    margin: 0;
    color: var(--title-soft);
}

.auth-modern-form {
    gap: 16px;
}

.auth-role-grid {
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 10px;
}

.auth-role-card {
    display: grid;
    gap: 9px;
    justify-items: start;
    min-height: 112px;
    padding: 13px;
    border: 1px solid #dbeafe;
    border-radius: 20px;
    background: linear-gradient(180deg, #ffffff, #f8fbff);
    color: #1e293b;
    text-align: left;
    cursor: pointer;
    transition: border-color 0.2s ease, box-shadow 0.2s ease, transform 0.2s ease, background 0.2s ease;
}

.auth-role-card:hover {
    transform: translateY(-2px);
    border-color: #93c5fd;
    box-shadow: 0 16px 36px rgba(37, 99, 235, 0.13);
}

.auth-role-card.is-active {
    border-color: #f97316;
    background: linear-gradient(145deg, #fff7ed, #eff6ff);
    box-shadow: 0 18px 42px rgba(249, 115, 22, 0.16);
}

.auth-role-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 38px;
    height: 38px;
    border-radius: 14px;
    background: #0f172a;
    color: #fff;
    font-size: 0.78rem;
    font-weight: 900;
}

.auth-role-card:nth-child(2) .auth-role-icon {
    background: #2563eb;
}

.auth-role-card:nth-child(3) .auth-role-icon {
    background: #0f766e;
}

.auth-role-card:nth-child(4) .auth-role-icon {
    background: #be123c;
}

.auth-role-card:nth-child(5) .auth-role-icon {
    background: #7c3aed;
}

.auth-role-card strong,
.auth-role-card small {
    display: block;
}

.auth-role-card strong {
    font-size: 0.92rem;
    line-height: 1.15;
}

.auth-role-card small {
    margin-top: 3px;
    color: #64748b;
    font-size: 0.72rem;
    font-weight: 700;
}

.auth-portal-shortcuts {
    display: grid;
    gap: 14px;
    margin-top: 22px;
    padding-top: 20px;
    border-top: 1px solid rgba(203, 213, 225, 0.72);
}

.auth-portal-shortcuts-heading h3 {
    margin: 10px 0 6px;
    color: #0f2f57;
    font-size: 1.24rem;
}

.auth-portal-shortcuts-heading p {
    margin: 0;
    color: #64748b;
}

.auth-portal-shortcuts-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 12px;
}

.auth-portal-link-card {
    display: grid;
    grid-template-columns: auto 1fr;
    gap: 12px;
    align-items: start;
    padding: 15px;
    border: 1px solid #dbeafe;
    border-radius: 20px;
    background: linear-gradient(180deg, #ffffff, #f8fbff);
    color: inherit;
    text-decoration: none;
    transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}

.auth-portal-link-card:hover {
    transform: translateY(-2px);
    border-color: #93c5fd;
    box-shadow: 0 16px 34px rgba(37, 99, 235, 0.12);
}

.auth-portal-link-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 42px;
    height: 42px;
    border-radius: 15px;
    background: linear-gradient(135deg, #0f766e, #2563eb);
    color: #fff;
    font-size: 0.82rem;
    font-weight: 900;
}

.auth-portal-link-card strong,
.auth-portal-link-card small,
.auth-portal-link-card em {
    display: block;
}

.auth-portal-link-card strong {
    color: #0f172a;
    font-size: 0.98rem;
    line-height: 1.2;
}

.auth-portal-link-card small {
    margin-top: 3px;
    color: #2563eb;
    font-size: 0.74rem;
    font-weight: 800;
}

.auth-portal-link-card em {
    margin-top: 7px;
    color: #64748b;
    font-size: 0.76rem;
    font-style: normal;
    line-height: 1.5;
}

.auth-input-grid,
.auth-captcha-panel {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
}

.auth-field label {
    color: #0f172a;
    font-weight: 800;
}

.auth-field input {
    min-height: 46px;
    padding: 10px 12px;
    border-color: #cbd5e1;
    border-radius: 14px;
    background: #fff;
    font-weight: 700;
}

.auth-field input:focus {
    border-color: #38bdf8;
    box-shadow: 0 0 0 4px rgba(56, 189, 248, 0.18);
}

.auth-captcha-panel {
    align-items: stretch;
}

.auth-captcha-card {
    display: grid;
    grid-template-columns: 1fr auto;
    grid-template-rows: auto 1fr;
    align-items: center;
    gap: 8px 12px;
    padding: 13px;
    border: 1px solid #fed7aa;
    border-radius: 20px;
    background: linear-gradient(135deg, #fff7ed, #ecfeff);
}

.auth-captcha-card span {
    color: #9a3412;
    font-size: 0.72rem;
    font-weight: 900;
    letter-spacing: 0.12em;
    text-transform: uppercase;
}

.auth-captcha-card .captcha-image {
    grid-column: 1 / -1;
    width: 100%;
    height: 58px;
    border: 1px solid rgba(249, 115, 22, 0.22);
    border-radius: 16px;
    object-fit: cover;
    background: #fff;
    box-shadow: 0 10px 24px rgba(251, 146, 60, 0.12);
}

.auth-captcha-refresh,
.auth-link-button {
    border: 0;
    background: transparent;
    font: inherit;
    cursor: pointer;
}

.auth-captcha-refresh {
    justify-self: end;
    color: #2563eb;
    font-size: 0.8rem;
    font-weight: 900;
}

.auth-action-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    flex-wrap: wrap;
    padding-top: 4px;
}

.auth-submit-button {
    min-height: 48px;
    min-width: 190px;
    border-radius: 16px;
    background: linear-gradient(135deg, #f97316, #ef4444 48%, #2563eb);
    box-shadow: 0 18px 38px rgba(239, 68, 68, 0.18);
}

.auth-link-actions {
    display: flex;
    align-items: center;
    gap: 14px;
    flex-wrap: wrap;
}

.auth-card .text-link,
.auth-link-button {
    color: #0f766e;
    font-weight: 900;
}

.auth-hidden-form {
    display: none;
}

.auth-otp-input {
    text-align: center;
    letter-spacing: 0.52em;
    font-size: 1.45rem !important;
}

.auth-otp-preview {
    border: 1px solid #fde68a;
    background: linear-gradient(135deg, #fffbeb, #eff6ff);
}

.auth-otp-preview strong {
    color: #b45309;
}

.auth-footer {
    width: min(1240px, 100%);
    justify-content: center;
    color: #475569;
}

@media (max-width: 1080px) {
    .auth-shell {
        grid-template-columns: 1fr;
        min-height: 0;
    }

    .auth-brand {
        min-height: 420px;
    }
}

@media (max-width: 760px) {
    .auth-body {
        padding: 10px;
    }

    .auth-shell {
        border-radius: 24px;
    }

    .auth-brand,
    .auth-card {
        padding: 24px;
    }

    .auth-role-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .auth-portal-shortcuts-grid {
        grid-template-columns: 1fr;
    }

    .auth-input-grid,
    .auth-captcha-panel {
        grid-template-columns: 1fr;
    }

    .auth-action-row {
        align-items: stretch;
    }

    .auth-submit-button,
    .auth-action-row .text-link {
        width: 100%;
        justify-content: center;
        text-align: center;
    }
}

@media (max-width: 480px) {
    .auth-brand-top {
        align-items: flex-start;
    }

    .auth-role-grid {
        grid-template-columns: 1fr;
    }

    .auth-role-card {
        min-height: 88px;
        grid-template-columns: auto 1fr;
        align-items: center;
    }
}

.dashboard-body-superadmin {
    background:
        radial-gradient(circle at top right, rgba(34, 197, 94, 0.14), transparent 26%),
        radial-gradient(circle at top left, rgba(14, 165, 233, 0.12), transparent 32%),
        linear-gradient(180deg, #eef6ff 0%, #f7fbff 48%, #f9fbff 100%);
}

.erp-sidebar-superadmin {
    background: linear-gradient(180deg, #f8fbff 0%, #ffffff 100%);
}

.erp-session-panel-superadmin {
    background: linear-gradient(180deg, #f3f8ff 0%, #ffffff 100%);
}

.erp-session-panel-note {
    display: block;
    color: #61738d;
    font-size: 0.82rem;
    line-height: 1.45;
}

.erp-nav-superadmin {
    gap: 8px;
}

.erp-nav-superadmin .erp-nav-item {
    border: 1px solid #e2eaf5;
    background: #ffffff;
    box-shadow: 0 10px 24px rgba(15, 23, 42, 0.04);
}

.erp-nav-superadmin .erp-nav-item:hover {
    background: linear-gradient(135deg, #f3f8ff, #ffffff);
}

.erp-nav-superadmin .erp-nav-icon {
    background: linear-gradient(135deg, #d9ebff, #eef7ff);
    color: #0a4fb3;
}

.erp-topbar-superadmin {
    background: rgba(250, 253, 255, 0.94);
}

.erp-topbar-title-stack {
    min-width: 0;
    display: grid;
    gap: 2px;
}

.erp-topbar-title-stack h1 {
    margin: 0;
    font-size: clamp(1.08rem, 1.7vw, 1.55rem);
    letter-spacing: 0.06em;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.erp-topbar-title-stack p {
    margin: 0;
    color: var(--title-accent);
    font-size: 0.83rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.erp-platform-chip {
    display: inline-flex;
    align-items: center;
    min-height: 34px;
    padding: 0 14px;
    border-radius: 999px;
    border: 1px solid #8fd7eb;
    background: linear-gradient(135deg, #f6feff 0%, #dcf3ff 100%);
    color: #0a4b73;
    font-size: 0.76rem;
    font-weight: 900;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    white-space: nowrap;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.82), 0 10px 22px rgba(13, 74, 129, 0.08);
}

.erp-platform-chip-soft {
    border-color: #c6d7f3;
    background: linear-gradient(135deg, #ffffff 0%, #f1f7ff 100%);
    color: #173b63;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.9), 0 10px 20px rgba(15, 23, 42, 0.05);
}

.page-body-superadmin {
    gap: 18px;
}

.dashboard-footer-superadmin {
    border: 1px solid #d8e4f2;
    background: linear-gradient(135deg, #ffffff 0%, #f4f9ff 52%, #e7f6ff 100%);
    box-shadow: 0 16px 40px rgba(15, 23, 42, 0.06);
    color: #163a64;
}

.dashboard-footer-superadmin .footer-copy strong {
    color: #123b67;
}

.dashboard-footer-superadmin .footer-support {
    color: #5b7391;
}

.dashboard-footer-superadmin .footer-brand-wordmark {
    border: 1px solid #dbe5f1;
    box-shadow: 0 16px 32px rgba(15, 23, 42, 0.1);
}

.superadmin-dashboard {
    display: grid;
    gap: 18px;
}

.superadmin-hero {
    position: relative;
    display: grid;
    grid-template-columns: 1fr;
    gap: 12px;
    padding: 22px 24px;
    border-radius: 24px;
    overflow: hidden;
    background: linear-gradient(135deg, #091a3d 0%, #0b4f75 48%, #14b8dc 100%);
    color: #ffffff;
    box-shadow: 0 28px 64px rgba(15, 23, 42, 0.18);
}

.superadmin-hero::before,
.superadmin-hero::after {
    content: "";
    position: absolute;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.08);
}

.superadmin-hero::before {
    width: 240px;
    height: 240px;
    top: -120px;
    right: -30px;
}

.superadmin-hero::after {
    width: 180px;
    height: 180px;
    bottom: -90px;
    left: -20px;
}

.superadmin-hero-copy,
.superadmin-hero-note {
    position: relative;
    z-index: 1;
}

.superadmin-hero h2 {
    margin: 8px 0 10px;
    font-size: clamp(1.8rem, 2.8vw, 2.5rem);
    line-height: 1.05;
    text-shadow: 0 10px 24px rgba(4, 20, 43, 0.18);
}

.superadmin-hero p {
    margin: 0;
    color: rgba(234, 245, 255, 0.9);
    line-height: 1.65;
    max-width: 980px;
}

.superadmin-hero-note {
    align-self: end;
    padding: 18px 20px;
    border: 1px solid rgba(255, 255, 255, 0.18);
    border-radius: 20px;
    background: rgba(9, 25, 52, 0.28);
    backdrop-filter: blur(8px);
}

.superadmin-pill {
    display: inline-flex;
    align-items: center;
    min-height: 32px;
    padding: 0 14px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.16);
    color: #ffffff;
    font-size: 0.74rem;
    font-weight: 900;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.superadmin-hero .eyebrow {
    padding: 8px 12px;
    margin-bottom: 12px;
    border: 1px solid rgba(191, 235, 255, 0.32);
    background: rgba(255, 255, 255, 0.12);
    color: #dff8ff;
    box-shadow: 0 12px 28px rgba(4, 18, 44, 0.16);
}

.superadmin-summary-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
    gap: 14px;
}

.superadmin-metric {
    padding: 18px 18px 16px;
    border-radius: 20px;
    border: 1px solid #d9e6f4;
    background: #ffffff;
    box-shadow: 0 18px 38px rgba(15, 23, 42, 0.05);
}

.superadmin-metric--indigo {
    background: linear-gradient(135deg, #eef3ff 0%, #ffffff 100%);
    border-color: #cad9ff;
}

.superadmin-metric--emerald {
    background: linear-gradient(135deg, #ecfdf5 0%, #ffffff 100%);
    border-color: #bde8d0;
}

.superadmin-metric--amber {
    background: linear-gradient(135deg, #fff8eb 0%, #ffffff 100%);
    border-color: #f3d69d;
}

.superadmin-metric--rose {
    background: linear-gradient(135deg, #fff1f4 0%, #ffffff 100%);
    border-color: #f4c3cf;
}

.superadmin-metric--sky {
    background: linear-gradient(135deg, #eefaff 0%, #ffffff 100%);
    border-color: #bde7f3;
}

.superadmin-metric-label {
    display: block;
    color: #607089;
    font-size: 0.8rem;
    font-weight: 800;
    letter-spacing: 0.06em;
    text-transform: uppercase;
}

.superadmin-metric strong {
    display: block;
    margin-top: 10px;
    color: #112c52;
    font-size: 2rem;
    line-height: 1;
}

.superadmin-metric p {
    margin: 10px 0 0;
    color: #61738d;
    font-size: 0.87rem;
    line-height: 1.55;
}

.superadmin-workspace {
    display: grid;
    grid-template-columns: minmax(0, 1.55fr) minmax(320px, 0.9fr);
    gap: 18px;
    align-items: start;
}

.superadmin-form-panel .dashboard-panel-header,
.superadmin-info-panel .dashboard-panel-header,
.superadmin-license-panel .dashboard-panel-header {
    background: linear-gradient(135deg, rgba(8, 30, 72, 0.03), rgba(20, 184, 220, 0.08), rgba(34, 197, 94, 0.04));
}

.superadmin-form-grid {
    padding: 12px 14px 10px;
    gap: 10px 12px;
}

.superadmin-form-panel .field textarea {
    min-height: 90px;
}

.library-page .dashboard-panel {
    border-color: #d8e4ef;
    box-shadow: 0 18px 38px rgba(15, 23, 42, 0.07);
}

.library-page .dashboard-panel-header {
    background: linear-gradient(135deg, rgba(8, 145, 178, 0.08), rgba(16, 185, 129, 0.08), rgba(245, 158, 11, 0.08));
}

.library-dashboard-grid,
.library-bulk-actions,
.library-rule-grid {
    display: grid;
    gap: 18px;
}

.library-dashboard-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    margin: 18px 0;
}

.library-bulk-actions {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    margin: 18px 0;
    align-items: start;
}

.library-bulk-actions form {
    margin: 0;
}

.library-rule-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    padding: 16px 18px 6px;
}

.library-rule-card {
    border: 1px solid #dbe7f0;
    border-radius: 16px;
    overflow: hidden;
}

.library-books-layout {
    margin-top: 18px;
}

.library-import-panel,
.library-filter-panel {
    margin-top: 18px;
}

.library-table-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.library-edit-patron-panel {
    grid-column: 1 / -1;
}

.library-stats-grid {
    margin-top: 18px;
}

.library-barcode-text {
    display: block;
    width: 100%;
    font-family: "Libre Barcode 39", "Libre Barcode 39 Text", cursive;
    font-size: 3.9rem;
    font-weight: 400;
    line-height: 0.9;
    letter-spacing: 0.04em;
    white-space: nowrap;
    text-align: center;
}

.library-barcode-block {
    display: grid;
    width: 100%;
    gap: 6px;
    padding: 6px 10px 0;
    justify-items: center;
    overflow: visible;
}

.library-barcode-block small {
    font-size: 0.78rem;
    font-weight: 700;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    color: #334155;
    text-align: center;
    word-break: break-word;
}

.library-card-print-sheet {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(330px, 1fr));
    gap: 18px;
    align-items: start;
    justify-items: center;
}

.library-card {
    width: 86.36mm;
    min-height: 53.34mm;
    height: 53.34mm;
    background: linear-gradient(135deg, #ffffff 0%, #f4fbff 55%, #fef9ec 100%);
    border: 1px solid #d6e2ed;
    border-radius: 14px;
    padding: 8px 9px;
    box-shadow: 0 16px 36px rgba(15, 23, 42, 0.08);
    display: grid;
    grid-template-rows: auto minmax(0, 1fr) auto;
    gap: 6px;
    overflow: hidden;
}

.library-card-head {
    display: grid;
    grid-template-columns: 13mm minmax(0, 1fr);
    gap: 7px;
    align-items: center;
}

.library-card-head strong,
.library-card-head span,
.library-card-meta h3,
.library-card-meta p {
    margin: 0;
}

.library-card-head div,
.library-card-meta {
    min-width: 0;
}

.library-card-head strong {
    display: -webkit-box;
    overflow: hidden;
    font-size: 0.72rem;
    line-height: 1.2;
    color: #0f2742;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
}

.library-card-head span {
    display: block;
    font-size: 0.58rem;
    line-height: 1.2;
    color: #475569;
    letter-spacing: 0.05em;
    text-transform: uppercase;
}

.library-card-logo,
.library-card-logo-fallback {
    width: 13mm;
    height: 13mm;
    border-radius: 8px;
}

.library-card-logo-fallback {
    display: grid;
    place-items: center;
    background: linear-gradient(135deg, #0f766e, #0891b2);
    color: #fff;
    font-weight: 800;
}

.library-card-body {
    display: grid;
    grid-template-columns: 16mm minmax(0, 1fr);
    gap: 7px;
    align-items: start;
    min-height: 0;
}

.library-card-photo {
    width: 16mm;
    height: 19mm;
    border-radius: 8px;
    overflow: hidden;
    border: 1px solid #d6deeb;
    background: #f8fbff;
    display: grid;
    place-items: center;
}

.library-card-photo img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.library-card-photo span {
    font-weight: 800;
    color: #0f4b6f;
}

.library-card-meta {
    display: grid;
    align-content: start;
    gap: 1px;
}

.library-card-meta h3 {
    display: -webkit-box;
    overflow: hidden;
    font-size: 0.8rem;
    line-height: 1.2;
    color: #0f2742;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
}

.library-card-meta p {
    font-size: 0.63rem;
    line-height: 1.25;
    color: #475569;
    word-break: break-word;
}

.library-card-foot {
    margin-top: auto;
    padding-top: 3px;
    border-top: 1px dashed #d8e4ef;
}

.library-barcode-sheet {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 18px;
}

.library-barcode-label {
    background: #fff;
    border: 1px solid #d8e3ed;
    border-radius: 12px;
    min-height: 138px;
    padding: 16px 18px 14px;
    display: grid;
    gap: 6px;
}

.library-barcode-label strong {
    color: #102a43;
    font-size: 1.12rem;
}

.library-barcode-title {
    display: block;
    overflow: hidden;
    white-space: nowrap;
    text-overflow: ellipsis;
}

.library-barcode-label > span {
    color: #243b53;
    font-size: 0.98rem;
}

.library-print-toolbar {
    margin-bottom: 18px;
}

@media (max-width: 960px) {
    .library-dashboard-grid,
    .library-bulk-actions,
    .library-rule-grid {
        grid-template-columns: 1fr;
    }
}

@media print {
    body.library-card-print-mode,
    body.library-barcode-print-mode {
        background: #fff;
    }

    body.library-card-print-mode .erp-sidebar,
    body.library-card-print-mode .erp-topbar,
    body.library-card-print-mode .quicklinks-panel,
    body.library-card-print-mode .quicklinks-backdrop,
    body.library-card-print-mode .app-footer,
    body.library-card-print-mode .library-print-toolbar,
    body.library-barcode-print-mode .erp-sidebar,
    body.library-barcode-print-mode .erp-topbar,
    body.library-barcode-print-mode .quicklinks-panel,
    body.library-barcode-print-mode .quicklinks-backdrop,
    body.library-barcode-print-mode .app-footer,
    body.library-barcode-print-mode .library-print-toolbar {
        display: none !important;
    }

    body.library-card-print-mode .erp-shell,
    body.library-card-print-mode .erp-main,
    body.library-card-print-mode .erp-content,
    body.library-card-print-mode .page-body,
    body.library-barcode-print-mode .erp-shell,
    body.library-barcode-print-mode .erp-main,
    body.library-barcode-print-mode .erp-content,
    body.library-barcode-print-mode .page-body {
        display: block;
        width: auto;
        min-height: auto;
        padding: 0;
        margin: 0;
    }

    body.library-card-print-mode .library-card-print-sheet {
        grid-template-columns: repeat(3, 86.36mm);
        gap: 5mm;
        justify-content: center;
        align-content: start;
    }

    body.library-barcode-print-mode .library-barcode-sheet {
        width: 200mm;
        grid-template-columns: repeat(5, 39.2mm);
        grid-auto-rows: 18.2mm;
        gap: 1mm;
        justify-content: center;
        align-content: start;
    }

    body.library-card-print-mode .library-card,
    body.library-barcode-print-mode .library-barcode-label {
        box-shadow: none;
        break-inside: avoid;
        page-break-inside: avoid;
    }

    body.library-barcode-print-mode .library-barcode-label {
        width: 39.2mm;
        min-height: 18.2mm;
        height: 18.2mm;
        padding: 1.2mm 1.4mm 0.9mm;
        gap: 0.45mm;
        border-radius: 0;
        overflow: hidden;
        align-content: start;
    }

    body.library-barcode-print-mode .library-barcode-title {
        font-size: 5pt;
        line-height: 1.08;
    }

    body.library-barcode-print-mode .library-barcode-label > span {
        font-size: 4.7pt;
        line-height: 1.05;
    }

    body.library-barcode-print-mode .library-barcode-block {
        gap: 0.3mm;
        padding: 0.3mm 0 0;
    }

    body.library-barcode-print-mode .library-barcode-text {
        font-size: 6.8mm;
        line-height: 0.82;
        letter-spacing: 0.01em;
    }

    body.library-barcode-print-mode .library-barcode-block small {
        font-size: 4.8pt;
        letter-spacing: 0.08em;
    }
}

.superadmin-form-actions {
    padding: 12px 18px 18px;
    border-top: 1px solid #ebf1f7;
}

.superadmin-info-body {
    display: grid;
    gap: 8px;
    padding: 0 18px 18px;
}

.superadmin-info-step {
    display: grid;
    grid-template-columns: auto 1fr;
    gap: 12px;
    align-items: start;
    padding: 14px 0;
    border-bottom: 1px solid #edf2f7;
}

.superadmin-info-step:last-of-type {
    border-bottom: 0;
    padding-bottom: 6px;
}

.superadmin-info-step-index {
    width: 34px;
    height: 34px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 12px;
    background: linear-gradient(135deg, #0a4fb3, #14b8dc);
    color: #ffffff;
    font-size: 0.88rem;
    font-weight: 900;
}

.superadmin-info-step strong,
.superadmin-mini-card strong {
    display: block;
    color: #15345e;
}

.superadmin-info-step p,
.superadmin-mini-card p {
    margin: 6px 0 0;
    color: #61738d;
    font-size: 0.87rem;
    line-height: 1.58;
}

.superadmin-mini-grid {
    display: grid;
    gap: 12px;
    margin-top: 8px;
}

.superadmin-mini-card {
    padding: 16px;
    border: 1px solid #dfe8f4;
    border-radius: 18px;
    background: linear-gradient(135deg, #f8fbff 0%, #ffffff 100%);
}

.superadmin-mini-card span {
    display: block;
    color: #607089;
    font-size: 0.76rem;
    font-weight: 800;
    letter-spacing: 0.06em;
    text-transform: uppercase;
}

.superadmin-mini-card strong {
    margin-top: 8px;
}

.superadmin-empty {
    padding: 20px 18px 24px;
}

.superadmin-empty strong {
    display: block;
    color: #15345e;
}

.superadmin-empty p {
    margin: 8px 0 0;
    color: #61738d;
}

.superadmin-table-wrap {
    margin: 0 14px 14px;
    padding: 12px;
    overflow: auto;
    border: 1px solid #e4ebf5;
    border-radius: 20px;
    background: linear-gradient(180deg, #f9fbff 0%, #ffffff 100%);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.9);
}

.superadmin-table {
    width: 100%;
    min-width: 980px;
    border-collapse: collapse;
    background: #ffffff;
    border-radius: 16px;
    overflow: hidden;
}

.superadmin-table thead th {
    padding: 14px 16px;
    border-bottom: 1px solid #e8eef6;
    background: linear-gradient(180deg, #f8fbff 0%, #f3f7fd 100%);
    color: #5f718a;
    font-size: 0.78rem;
    font-weight: 900;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    text-align: left;
}

.superadmin-table tbody td {
    padding: 16px;
    border-bottom: 1px solid #edf2f7;
    vertical-align: top;
}

.superadmin-table tbody tr:nth-child(even) {
    background: #fbfdff;
}

.superadmin-table tbody tr:last-child td {
    border-bottom: 0;
}

.superadmin-table-action {
    min-width: 84px;
    justify-content: center;
}

.superadmin-school-cell strong {
    display: block;
    color: #112c52;
}

.superadmin-school-cell span,
.superadmin-school-cell small,
.superadmin-period span,
.superadmin-usage span,
.superadmin-days {
    display: block;
    margin-top: 5px;
    color: #61738d;
    font-size: 0.84rem;
    line-height: 1.45;
}

.superadmin-code {
    display: inline-flex;
    align-items: center;
    min-height: 34px;
    padding: 0 12px;
    border-radius: 999px;
    background: #eef4ff;
    color: #0a4fb3;
    font-size: 0.82rem;
    font-weight: 800;
}

.superadmin-status {
    display: inline-flex;
    align-items: center;
    min-height: 32px;
    padding: 0 12px;
    border-radius: 999px;
    border: 1px solid transparent;
    font-size: 0.78rem;
    font-weight: 900;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

.superadmin-status--active {
    background: #ecfdf5;
    border-color: #bde8d0;
    color: #047857;
}

.superadmin-status--warning {
    background: #fff7e6;
    border-color: #f2d39d;
    color: #b26b0f;
}

.superadmin-status--expired {
    background: #fff1f3;
    border-color: #f4c3cf;
    color: #c4314c;
}

@media (max-width: 1280px) {
    .superadmin-workspace {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 960px) {
    .superadmin-hero {
        grid-template-columns: 1fr;
        padding: 22px;
    }

    .erp-platform-chip-soft {
        display: none;
    }
}

@media (max-width: 760px) {
    .erp-topbar-title-stack p,
    .erp-platform-chip {
        display: none;
    }

    .superadmin-form-grid {
        grid-template-columns: 1fr;
    }

    .superadmin-hero,
    .superadmin-table-wrap {
        border-radius: 18px;
    }
}

.transport-form-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    align-items: center;
}

.transport-photo-preview {
    min-height: 180px;
}

.transport-checkbox-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 16px;
    margin-top: 16px;
}

.transport-checkbox-card {
    display: grid;
    gap: 6px;
    padding: 16px;
    border: 1px solid rgba(148, 163, 184, 0.28);
    border-radius: 18px;
    background: #f8fafc;
    cursor: pointer;
}

.transport-checkbox-card input {
    justify-self: start;
}

.transport-checkbox-title {
    font-weight: 700;
    color: #0f172a;
}

.transport-checkbox-copy {
    color: #475569;
    font-size: 0.92rem;
}

.transport-route-pickup-rows {
    display: grid;
    gap: 16px;
}

.transport-route-pickup-row {
    padding: 18px;
    border: 1px solid rgba(148, 163, 184, 0.24);
    border-radius: 20px;
    background: #f8fafc;
}

.transport-row-remove-wrap {
    display: flex;
    align-items: flex-end;
}

.transport-month-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
    gap: 14px;
}

.transport-route-filter-form {
    margin-bottom: 18px;
}
