/* ============================================================
   UNI-KAMPUS — Modern Design System
   ============================================================ */

:root {
    --font: "Plus Jakarta Sans", system-ui, -apple-system, sans-serif;
    --bg-dark: #0a0f1a;
    --bg-dark-2: #111827;
    --surface: rgba(255, 255, 255, 0.04);
    --surface-hover: rgba(255, 255, 255, 0.08);
    --border: rgba(255, 255, 255, 0.08);
    --border-accent: rgba(56, 189, 248, 0.35);
    --text: #f1f5f9;
    --text-muted: #94a3b8;
    --text-dim: #64748b;
    --accent: #38bdf8;
    --accent-2: #818cf8;
    --accent-warm: #fb923c;
    --gradient-brand: linear-gradient(135deg, #38bdf8 0%, #818cf8 50%, #c084fc 100%);
    --gradient-bg: radial-gradient(ellipse 80% 60% at 50% -10%, rgba(56, 189, 248, 0.15), transparent),
                   radial-gradient(ellipse 60% 50% at 100% 50%, rgba(129, 140, 248, 0.1), transparent),
                   radial-gradient(ellipse 50% 40% at 0% 80%, rgba(192, 132, 252, 0.08), transparent);
    --shadow-card: 0 4px 24px rgba(0, 0, 0, 0.25);
    --shadow-card-hover: 0 12px 40px rgba(56, 189, 248, 0.15);
    --radius: 16px;
    --radius-lg: 20px;
    --radius-xl: 24px;
    --transition: 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}

*, *::before, *::after {
    box-sizing: border-box;
}

html, body {
    min-height: 100%;
}

body {
    font-family: var(--font);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* ── Header ─────────────────────────────────────────────── */

.app-header {
    position: sticky;
    top: 0;
    z-index: 100;
    background: rgba(10, 15, 26, 0.85);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border-bottom: 1px solid var(--border);
}

.app-header .navbar {
    padding: 0.65rem 0;
}

.app-header .navbar-brand {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    text-decoration: none;
    color: var(--text);
}

.brand-icon {
    width: 40px;
    height: 40px;
    border-radius: 12px;
    background: var(--gradient-brand);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.15rem;
    color: #fff;
    box-shadow: 0 4px 12px rgba(56, 189, 248, 0.3);
}

.brand-text {
    display: flex;
    flex-direction: column;
    line-height: 1.2;
}

.brand-title {
    font-weight: 700;
    font-size: 1rem;
    letter-spacing: -0.02em;
}

.brand-sub {
    font-size: 0.7rem;
    color: var(--text-muted);
    font-weight: 500;
}

.user-chip {
    display: flex;
    align-items: center;
    gap: 0.65rem;
    padding: 0.35rem 0.85rem 0.35rem 0.35rem;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 999px;
}

.user-avatar {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: var(--gradient-brand);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.8rem;
    font-weight: 700;
    color: #fff;
    text-transform: uppercase;
}

.user-info {
    display: flex;
    flex-direction: column;
    line-height: 1.2;
}

.user-name {
    font-size: 0.82rem;
    font-weight: 600;
    color: var(--text);
}

.user-role {
    font-size: 0.68rem;
    color: var(--accent-warm);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.btn-logout {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.45rem 1rem;
    background: transparent;
    border: 1px solid var(--border);
    border-radius: 10px;
    color: var(--text-muted);
    font-size: 0.85rem;
    font-weight: 500;
    cursor: pointer;
    transition: var(--transition);
}

.btn-logout:hover {
    background: rgba(239, 68, 68, 0.1);
    border-color: rgba(239, 68, 68, 0.3);
    color: #fca5a5;
}

.app-header .navbar-toggler-icon {
    filter: invert(1);
}

/* ── Login Page ─────────────────────────────────────────── */

body.login-page {
    background: #07101c;
    min-height: 100vh;
}

body.login-page main {
    padding: 0;
    margin: 0;
}

.login-scene {
    min-height: 100vh;
    display: grid;
    grid-template-columns: 1.08fr 0.92fr;
    position: relative;
    overflow: hidden;
}

.login-panel {
    position: relative;
    z-index: 1;
    display: flex;
    min-height: 100vh;
}

.login-panel-brand {
    flex-direction: column;
    justify-content: space-between;
    padding: 2.25rem 3rem 1.25rem;
    background:
        radial-gradient(ellipse 70% 50% at 20% 0%, rgba(56, 189, 248, 0.22), transparent 55%),
        radial-gradient(ellipse 50% 40% at 80% 80%, rgba(99, 102, 241, 0.12), transparent 50%),
        linear-gradient(165deg, #0b2744 0%, #0a1a30 55%, #081525 100%);
    border-right: 1px solid rgba(56, 189, 248, 0.12);
}

.login-panel-brand::before {
    content: "";
    position: absolute;
    inset: 0;
    background-image:
        linear-gradient(rgba(56, 189, 248, 0.06) 1px, transparent 1px),
        linear-gradient(90deg, rgba(56, 189, 248, 0.06) 1px, transparent 1px);
    background-size: 56px 56px;
    mask-image: radial-gradient(ellipse 80% 70% at 40% 30%, #000 30%, transparent 75%);
    pointer-events: none;
}

.login-brand-top {
    position: relative;
    z-index: 1;
}

.login-wordmark {
    display: inline-flex;
    align-items: center;
    gap: 0.7rem;
    color: #e2e8f0;
    font-size: 1.05rem;
    font-weight: 800;
    letter-spacing: 0.08em;
}

.login-wordmark-icon {
    width: 36px;
    height: 36px;
    color: #7dd3fc;
}

.login-wordmark-icon svg {
    width: 100%;
    height: 100%;
    display: block;
}

.login-brand-content {
    position: relative;
    z-index: 1;
    max-width: 520px;
    margin-top: 2.5rem;
}

.login-platform-pill {
    display: inline-flex;
    align-items: center;
    padding: 0.38rem 0.9rem;
    border: 1px solid rgba(125, 211, 252, 0.35);
    border-radius: 999px;
    font-size: 0.68rem;
    font-weight: 700;
    letter-spacing: 0.14em;
    color: #7dd3fc;
    background: rgba(14, 165, 233, 0.08);
    margin-bottom: 1.35rem;
}

.login-brand-title {
    font-size: clamp(1.85rem, 3.4vw, 2.55rem);
    font-weight: 800;
    color: #f8fafc;
    letter-spacing: -0.035em;
    line-height: 1.15;
    margin-bottom: 1rem;
}

.login-brand-text {
    color: #94a3b8;
    font-size: 1.02rem;
    line-height: 1.65;
    margin-bottom: 1.75rem;
    max-width: 460px;
}

.login-features {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: 0.85rem;
}

.login-features li {
    display: flex;
    align-items: center;
    gap: 0.7rem;
    color: #cbd5e1;
    font-size: 0.95rem;
}

.login-features li i {
    color: #38bdf8;
    font-size: 1.05rem;
}

.login-hero-art {
    position: relative;
    z-index: 1;
    margin: 1.25rem 0 0 auto;
    max-width: 680px;
    width: 100%;
}

.login-hero-art svg {
    width: 100%;
    height: auto;
    display: block;
}

.login-panel-form {
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 2.5rem 1.5rem 4.5rem;
    background:
        radial-gradient(ellipse 60% 40% at 80% 0%, rgba(99, 102, 241, 0.12), transparent 50%),
        #070e1a;
}

.login-card {
    width: 100%;
    max-width: 420px;
    background: rgba(15, 23, 42, 0.72);
    border: 1px solid rgba(148, 163, 184, 0.16);
    border-radius: 22px;
    padding: 2.15rem 2rem 1.75rem;
    backdrop-filter: blur(22px);
    box-shadow: 0 24px 64px rgba(0, 0, 0, 0.35);
}

.login-card-header {
    text-align: center;
    margin-bottom: 1.65rem;
}

.login-logo {
    width: 58px;
    height: 58px;
    margin: 0 auto 1.1rem;
    border-radius: 16px;
    background: linear-gradient(145deg, #38bdf8 0%, #6366f1 55%, #a855f7 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.45rem;
    color: #fff;
    box-shadow: 0 10px 28px rgba(99, 102, 241, 0.35);
}

.login-card-title {
    font-size: 1.55rem;
    font-weight: 800;
    color: #f8fafc;
    margin: 0 0 0.35rem;
    letter-spacing: -0.03em;
}

.login-card-sub {
    color: #94a3b8;
    font-size: 0.9rem;
    margin: 0;
}

.login-alert {
    font-size: 0.85rem;
    border-radius: 10px;
    margin-bottom: 1rem;
}

.field-group {
    margin-bottom: 1.15rem;
}

.field-label {
    display: block;
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--text-muted);
    margin-bottom: 0.4rem;
}

.field-input {
    display: flex;
    align-items: center;
    gap: 0.65rem;
    background: rgba(2, 6, 23, 0.55);
    border: 1px solid rgba(148, 163, 184, 0.18);
    border-radius: 12px;
    padding: 0 0.85rem 0 1rem;
    transition: var(--transition);
}

.field-input:focus-within {
    border-color: rgba(56, 189, 248, 0.55);
    box-shadow: 0 0 0 3px rgba(56, 189, 248, 0.12);
}

.field-input i {
    color: var(--text-dim);
    font-size: 1rem;
}

.field-input input {
    flex: 1;
    background: transparent;
    border: none;
    outline: none;
    padding: 0.8rem 0;
    color: var(--text);
    font-size: 0.95rem;
    font-family: var(--font);
}

.field-input input::placeholder {
    color: var(--text-dim);
}

.field-toggle {
    border: 0;
    background: transparent;
    color: var(--text-dim);
    padding: 0.35rem;
    display: inline-flex;
    align-items: center;
    cursor: pointer;
}

.field-toggle:hover {
    color: #e2e8f0;
}

.field-error {
    display: block;
    font-size: 0.78rem;
    color: #f87171;
    margin-top: 0.3rem;
}

.remember-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    margin-bottom: 1.35rem;
    font-size: 0.86rem;
    color: var(--text-muted);
}

.remember-check {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    cursor: pointer;
    margin: 0;
}

.remember-check input {
    accent-color: var(--accent);
}

.login-forgot {
    color: #38bdf8;
    text-decoration: none;
    font-weight: 600;
    white-space: nowrap;
}

.login-forgot:hover {
    color: #7dd3fc;
    text-decoration: underline;
}

.btn-login {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.9rem 1.5rem;
    background: linear-gradient(90deg, #22d3ee 0%, #3b82f6 100%);
    border: none;
    border-radius: 12px;
    color: #fff;
    font-size: 0.98rem;
    font-weight: 700;
    font-family: var(--font);
    cursor: pointer;
    text-decoration: none;
    transition: var(--transition);
    box-shadow: 0 8px 22px rgba(34, 211, 238, 0.28);
}

.btn-login:hover {
    transform: translateY(-1px);
    color: #fff;
    box-shadow: 0 12px 28px rgba(59, 130, 246, 0.4);
}

.btn-login i {
    transition: transform var(--transition);
}

.btn-login:hover i {
    transform: translateX(3px);
}

.login-secure {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.4rem;
    margin: 1.15rem 0 0;
    color: #34d399;
    font-size: 0.8rem;
    font-weight: 600;
}

.login-forgot-copy {
    color: #94a3b8;
    font-size: 0.92rem;
    line-height: 1.6;
    margin: 0 0 1.5rem;
    text-align: center;
}

.login-form-footer {
    position: absolute;
    left: 0;
    right: 0;
    bottom: 1.35rem;
    display: flex;
    justify-content: space-between;
    gap: 1rem;
    padding: 0 2.25rem;
    color: #93a4b8;
    font-size: 0.78rem;
    z-index: 2;
}

.login-form-footer strong {
    color: #94a3b8;
    font-weight: 600;
}

/* ── Module Pages (FormModule + Submenus) ──────────────── */

body.form-module-page,
body.module-submenu-page,
body.abacus-menu-page {
    background: #0d1c2f;
    color: #e2e8f0;
}

body.form-module-page .app-header,
body.module-submenu-page .app-header,
body.abacus-menu-page .app-header {
    background: rgba(13, 28, 47, 0.95);
    border-bottom: 1px solid rgba(75, 191, 238, 0.12);
}

.form-module {
    position: relative;
    min-height: calc(100vh - 65px);
    padding: 1.25rem 1.5rem 5.5rem;
}

.form-module-bg {
    position: fixed;
    inset: 0;
    top: 65px;
    background: #0d1c2f;
    pointer-events: none;
    z-index: 0;
}

.abacus-menu-content {
    position: relative;
    z-index: 1;
    max-width: 1060px;
    margin: 0 auto;
}

/* Topbar */
.abacus-menu-topbar {
    position: relative;
    margin-bottom: 1.75rem;
    min-height: 2rem;
}

.abacus-menu-topbar.centered {
    text-align: center;
}

.abacus-btn-back {
    position: absolute;
    left: 0;
    top: 0;
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 1px solid rgba(75, 191, 238, 0.25);
    border-radius: 8px;
    color: #94a3b8;
    text-decoration: none;
    transition: var(--transition);
}

.abacus-btn-back:hover {
    color: #4bbfee;
    border-color: #4bbfee;
    background: rgba(75, 191, 238, 0.08);
}

.abacus-breadcrumb {
    margin: 0;
    padding-top: 0.35rem;
    font-size: 0.8rem;
    font-weight: 600;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: #94a3b8;
}

/* Abacus grid — si desktop FormModule / MainTePergjithshme */
.abacus-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1rem;
    margin-bottom: 1rem;
}

.abacus-grid-4 {
    grid-template-columns: repeat(4, minmax(0, 1fr));
}

.abacus-grid-3 {
    grid-template-columns: repeat(3, minmax(0, 1fr));
}

.abacus-grid-row-3:not(:has(.abacus-tile:nth-child(3))) .abacus-tile:nth-child(1) {
    grid-column: 1;
}

.abacus-grid-row-3:not(:has(.abacus-tile:nth-child(3))) .abacus-tile:nth-child(2) {
    grid-column: 2;
}

.abacus-grid-row-3:has(.abacus-tile:only-child) .abacus-tile {
    grid-column: 2;
}

.abacus-grid-row-4 .abacus-tile {
    grid-column: 2;
}

/* Abacus tile — titull sipër, ikonë qendër, badge poshtë */
.abacus-tile {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
    min-height: 156px;
    padding: 0.75rem 0.65rem 2.15rem;
    background: rgba(13, 28, 47, 0.45);
    border: 1px solid #4bbfee;
    border-radius: 10px;
    text-decoration: none;
    color: inherit;
    position: relative;
    transition: transform 0.18s ease, box-shadow 0.18s ease, border-color 0.18s ease;
    box-shadow: inset 0 0 0 1px rgba(75, 191, 238, 0.06);
}

a.abacus-tile.is-active:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 28px rgba(75, 191, 238, 0.18);
    border-color: #67d4ff;
}

.abacus-tile.is-locked {
    opacity: 0.55;
    border-color: rgba(75, 191, 238, 0.35);
}

.abacus-tile-title {
    font-size: 0.72rem;
    font-weight: 600;
    letter-spacing: 0.03em;
    text-transform: uppercase;
    text-align: center;
    color: #b0c4de;
    line-height: 1.35;
    width: 100%;
    margin-bottom: 0.35rem;
}

.abacus-tile-icon {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 4.5rem;
    color: #4bbfee;
    line-height: 1;
    filter: drop-shadow(0 2px 8px rgba(75, 191, 238, 0.15));
}

.abacus-tile-icon i {
    display: block;
}

.abacus-badge-soon {
    position: absolute;
    bottom: 0.65rem;
    left: 50%;
    transform: translateX(-50%);
    padding: 0.2rem 0.55rem;
    background: #ff8000;
    color: #fff;
    font-size: 0.58rem;
    font-weight: 700;
    letter-spacing: 0.05em;
    border-radius: 3px;
    white-space: nowrap;
}

.abacus-badge-lock {
    position: absolute;
    bottom: 0.75rem;
    left: 50%;
    transform: translateX(-50%);
    font-size: 0.85rem;
    color: #64748b;
}

/* Status bar — si desktop footer panel */
.abacus-statusbar {
    position: fixed;
    left: 50%;
    transform: translateX(-50%);
    bottom: 2.6rem;
    width: min(1060px, calc(100% - 2rem));
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.7rem 1.1rem;
    background: #172b45;
    border-radius: 18px;
    z-index: 10;
    flex-wrap: wrap;
    box-shadow: 0 4px 24px rgba(0, 0, 0, 0.25);
}

.abacus-status-tag {
    color: #ff8000;
    font-weight: 700;
    font-size: 0.82rem;
}

.abacus-status-user {
    color: #fff;
    font-size: 0.82rem;
}

.abacus-status-title {
    margin-left: auto;
    font-size: 1rem;
    font-weight: 600;
    color: #fff;
}

.abacus-empty {
    text-align: center;
    padding: 3rem;
    color: #94a3b8;
    border: 1px dashed rgba(75, 191, 238, 0.3);
    border-radius: 10px;
}

.abacus-empty i {
    font-size: 2rem;
    color: #ff8000;
    display: block;
    margin-bottom: 0.75rem;
}

.form-module-copyright {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    text-align: center;
    padding: 0.45rem;
    font-size: 0.75rem;
    color: #64748b;
    background: #0d1c2f;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
    z-index: 11;
}

/* Footer (non-module pages) */
.app-footer {
    color: var(--text-dim);
    border-top: 1px solid var(--border);
    background: var(--bg-dark-2);
}

/* ── Responsive ─────────────────────────────────────────── */

@media (max-width: 900px) {
    .login-scene {
        grid-template-columns: 1fr;
    }

    .login-panel-brand {
        display: none;
    }

    .login-panel-form {
        min-height: 100vh;
        padding-bottom: 5rem;
    }

    .login-form-footer {
        padding: 0 1.25rem;
    }
}

@media (max-width: 1200px) {
    .abacus-grid-4,
    .abacus-grid-3 {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 768px) {
    .form-module {
        padding: 1rem 0.75rem 5rem;
    }

    .abacus-grid {
        grid-template-columns: 1fr;
    }

    .abacus-grid-4,
    .abacus-grid-3 {
        grid-template-columns: 1fr;
    }

    .abacus-grid-row-3:not(:has(.abacus-tile:nth-child(3))) .abacus-tile:nth-child(2),
    .abacus-grid-row-3:has(.abacus-tile:only-child) .abacus-tile,
    .abacus-grid-row-4 .abacus-tile {
        grid-column: auto;
    }

    .abacus-tile-icon {
        font-size: 3.25rem;
    }

    .abacus-status-title {
        margin-left: 0;
        width: 100%;
    }

    .user-chip .user-info {
        display: none;
    }

    .brand-sub {
        display: none;
    }
}

@media (max-width: 480px) {
    .login-card {
        padding: 1.75rem 1.25rem;
    }

    .abacus-tile {
        min-height: 140px;
    }

    .abacus-tile-icon {
        font-size: 2.75rem;
    }
}

/* ── Abacus Form Pages (CRUD) ──────────────────────────── */

body.abacus-form-page {
    background: #0d1c2f;
    color: #e2e8f0;
}

body.abacus-form-page .app-header {
    background: rgba(13, 28, 47, 0.95);
    border-bottom: 1px solid rgba(75, 191, 238, 0.12);
}

.abacus-form-page.form-module {
    min-height: calc(100vh - 65px);
    padding: 0.75rem 1rem 1.25rem;
}

.abacus-form-content {
    position: relative;
    z-index: 1;
    max-width: 1200px;
    margin: 0 auto;
}

.abacus-form-header {
    position: relative;
    margin-bottom: 0.55rem;
    padding-left: 2.4rem;
}

.abacus-form-title {
    font-size: 1.12rem;
    font-weight: 700;
    margin: 0;
    color: #fff;
}

.abacus-form-panel,
.abacus-table-panel {
    background: rgba(13, 28, 47, 0.55);
    border: 1px solid rgba(75, 191, 238, 0.35);
    border-radius: 10px;
    padding: 0.65rem 0.8rem;
    margin-bottom: 0.6rem;
}

.abacus-input,
.abacus-form-panel .form-select {
    background: rgba(8, 18, 32, 0.85);
    border: 1px solid rgba(75, 191, 238, 0.25);
    color: #e2e8f0;
}

.abacus-input:focus,
.abacus-form-panel .form-select:focus {
    background: rgba(8, 18, 32, 0.95);
    border-color: #4bbfee;
    color: #fff;
    box-shadow: 0 0 0 0.15rem rgba(75, 191, 238, 0.15);
}

.form-control.abacus-input[readonly],
.form-control.abacus-input:disabled,
.abacus-input[readonly],
.abacus-input:disabled {
    background: rgba(8, 18, 32, 0.65);
    background-color: rgba(8, 18, 32, 0.65);
    color: #f8fafc;
    opacity: 1;
}

.abacus-form-panel .form-label {
    color: #94a3b8;
    font-size: 0.68rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    margin-bottom: 0.18rem;
}

.abacus-combo {
    position: relative;
}

.abacus-search-select {
    width: 100%;
}

.abacus-search-select > select {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

.abacus-combo-list {
    position: absolute;
    z-index: 40;
    left: 0;
    right: 0;
    top: calc(100% + 4px);
    max-height: 260px;
    overflow-y: auto;
    background: #0b1726;
    border: 1px solid rgba(75, 191, 238, 0.4);
    border-radius: 8px;
    box-shadow: 0 12px 28px rgba(0, 0, 0, 0.45);
}

.abacus-combo-empty {
    padding: 0.55rem 0.7rem;
    color: #94a3b8;
    font-size: 0.82rem;
}

.abacus-combo-item.is-active {
    background: rgba(75, 191, 238, 0.28);
    color: #fff;
}

.abacus-combo-item {
    display: block;
    width: 100%;
    text-align: left;
    border: 0;
    background: transparent;
    color: #e2e8f0;
    padding: 0.45rem 0.7rem;
    font-size: 0.86rem;
}

.abacus-combo-item:hover,
.abacus-combo-item.is-selected {
    background: rgba(75, 191, 238, 0.18);
    color: #fff;
}

.abacus-form-actions {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.abacus-form-toolbar {
    display: flex;
    gap: 0.35rem;
    flex-wrap: wrap;
    align-items: center;
    padding: 0.35rem 0.65rem;
    margin-top: 0;
    background: rgba(8, 18, 32, 0.9);
    border: 1px solid rgba(75, 191, 238, 0.25);
    border-radius: 10px;
}

.abacus-form-toolbar .btn {
    padding: 0.28rem 0.65rem;
    font-size: 0.8rem;
    line-height: 1.2;
}

.abacus-form-toolbar .btn:disabled {
    opacity: 0.4;
    cursor: not-allowed;
}

.access-assign-list {
    max-height: 62vh;
    overflow: auto;
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
}

.access-assign-group {
    margin-top: 0.65rem;
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: #38bdf8;
}

.access-assign-group:first-child {
    margin-top: 0;
}

.access-assign-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    padding: 0.55rem 0.7rem;
    border-radius: 10px;
    background: rgba(15, 23, 42, 0.65);
    border: 1px solid rgba(56, 189, 248, 0.12);
}

.access-assign-title {
    color: #e2e8f0;
    font-size: 0.86rem;
    font-weight: 600;
}

.abacus-grid-title {
    color: #4bbfee;
    font-size: 0.78rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    margin: 0 0 0.4rem;
}

.abacus-table tbody tr.clickable-row {
    cursor: pointer;
}

.abacus-table tbody tr.clickable-row:hover {
    background: rgba(75, 191, 238, 0.08);
}

.abacus-required {
    color: #f87171;
    margin-left: 0.15rem;
}

.abacus-btn-primary {
    background: #4bbfee;
    border: 1px solid #4bbfee;
    color: #0d1c2f;
    font-weight: 600;
}

.abacus-btn-primary:hover {
    background: #67d4ff;
    border-color: #67d4ff;
    color: #0d1c2f;
}

.abacus-btn-secondary {
    background: transparent;
    border: 1px solid rgba(75, 191, 238, 0.35);
    color: #94a3b8;
}

.abacus-btn-secondary:hover {
    border-color: #4bbfee;
    color: #fff;
}

.abacus-btn-danger {
    background: transparent;
    border: 1px solid rgba(248, 113, 113, 0.45);
    color: #fca5a5;
}

.abacus-delete-form {
    margin-top: 0.75rem;
    padding-top: 0.75rem;
    border-top: 1px dashed rgba(75, 191, 238, 0.15);
}

.abacus-table {
    color: #e2e8f0;
    margin: 0;
}

.abacus-table-scroll {
    max-height: min(70vh, 740px);
    overflow: auto;
}

.abacus-table thead th {
    color: #4bbfee;
    font-size: 0.72rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    border-bottom-color: rgba(75, 191, 238, 0.2);
}

.abacus-table .abacus-filter-row th {
    background: rgba(8, 18, 32, 0.92);
    padding: 0.28rem 0.35rem;
    border-bottom: 1px solid rgba(75, 191, 238, 0.25);
    text-transform: none;
}

.abacus-col-filter-wrap {
    position: relative;
    display: flex;
    align-items: center;
}

.abacus-col-filter-wrap > i {
    position: absolute;
    left: 0.45rem;
    color: #64748b;
    font-size: 0.72rem;
    pointer-events: none;
}

.abacus-col-filter {
    padding-left: 1.45rem;
    min-width: 70px;
    height: 1.7rem;
    font-size: 0.75rem;
    background: rgba(8, 18, 32, 0.9);
    border: 1px solid rgba(75, 191, 238, 0.25);
    color: #e2e8f0;
}

.abacus-col-filter:focus {
    border-color: #4bbfee;
    box-shadow: 0 0 0 0.12rem rgba(75, 191, 238, 0.15);
    background: rgba(8, 18, 32, 0.98);
    color: #fff;
}

.abacus-table td,
.abacus-table th {
    border-color: rgba(75, 191, 238, 0.08);
    vertical-align: middle;
}

.abacus-table tbody tr:hover {
    background: rgba(75, 191, 238, 0.06);
}

.abacus-table tbody tr.selected {
    background: rgba(75, 191, 238, 0.12);
}

.abacus-table a {
    color: #b0d8f0;
    text-decoration: none;
}

.abacus-table a:hover {
    color: #fff;
}

.earnings-edit-table .abacus-input,
.earnings-edit-table .form-select.abacus-input {
    background: rgba(15, 32, 54, 0.95);
    border-color: rgba(75, 191, 238, 0.45);
    color: #fff;
    cursor: text;
}

.earnings-edit-table .form-select.abacus-input {
    cursor: pointer;
}

.earnings-group-scroll {
    max-height: min(70vh, 760px);
    overflow: auto;
}

.earnings-group-table {
    font-size: 0.78rem;
    white-space: nowrap;
}

.earnings-group-table th,
.earnings-group-table td {
    padding: 0.28rem 0.4rem;
}

.earnings-group-table tr.is-shtese {
    background: rgba(75, 191, 238, 0.12);
}

.earnings-group-table tfoot td {
    color: #4bbfee;
    font-weight: 700;
    border-top: 1px solid rgba(75, 191, 238, 0.35);
}

.qendra-form .trn-radios,
.qendra-form .trn-radios label {
    color: #e2e8f0;
}

.exp-layout {
    display: grid;
    grid-template-columns: minmax(0, 1.7fr) minmax(280px, 0.9fr);
    gap: 1rem;
}

.exp-card {
    background: rgba(8, 18, 32, 0.72);
    border: 1px solid rgba(75, 191, 238, 0.18);
    border-radius: 16px;
    padding: 1.1rem 1.2rem 1.25rem;
    margin-bottom: 1rem;
}

.exp-card-head {
    display: flex;
    align-items: center;
    gap: 0.7rem;
    margin-bottom: 1rem;
}

.exp-card-icon {
    width: 2rem;
    height: 2rem;
    border-radius: 8px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: rgba(75, 191, 238, 0.16);
    color: #4bbfee;
}

.exp-card h2 {
    margin: 0;
    font-size: 1.05rem;
    color: #fff;
}

.exp-label {
    display: block;
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: #94a3b8;
    margin-bottom: 0.4rem;
}

.exp-pills {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-bottom: 1rem;
}

.exp-pill {
    border: 1px solid rgba(75, 191, 238, 0.25);
    border-radius: 10px;
    padding: 0.45rem 0.9rem;
    color: #cbd5e1;
    cursor: pointer;
    margin: 0;
}

.exp-pill input {
    display: none;
}

.exp-pill.is-on {
    background: rgba(75, 191, 238, 0.18);
    border-color: #4bbfee;
    color: #fff;
}

.exp-pay {
    display: flex;
    align-items: center;
    gap: 0.7rem;
    border: 1px solid rgba(75, 191, 238, 0.2);
    border-radius: 12px;
    padding: 0.75rem 0.9rem;
    margin-bottom: 0.55rem;
    color: #e2e8f0;
    cursor: pointer;
}

.exp-pay.is-on {
    border-color: #4bbfee;
    background: rgba(75, 191, 238, 0.12);
}

.exp-hint {
    color: #64748b;
    font-size: 0.78rem;
    margin: 0.35rem 0 0;
}

.exp-switch {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    color: #94a3b8;
    margin: 0;
}

.exp-summary-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr)) 180px auto;
    gap: 0.85rem;
    align-items: end;
}

.exp-total {
    background: rgba(34, 197, 94, 0.12);
    border: 1px solid rgba(34, 197, 94, 0.35);
    border-radius: 12px;
    padding: 0.55rem 0.8rem;
    color: #86efac;
}

.exp-total span {
    display: block;
    font-size: 0.7rem;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.exp-total strong {
    font-size: 1.25rem;
    color: #bbf7d0;
}

.exp-summary-actions {
    display: flex;
    gap: 0.5rem;
    justify-content: flex-end;
}

@media (max-width: 1100px) {
    .exp-layout,
    .exp-summary-grid {
        grid-template-columns: 1fr;
    }
}

.abacus-alert {
    border-radius: 8px;
    margin-bottom: 1rem;
}

.abacus-check .form-check-input:checked {
    background-color: #4bbfee;
    border-color: #4bbfee;
}

.abacus-placeholder-panel {
    text-align: center;
    padding: 3rem 1.5rem;
}

.abacus-placeholder-panel i {
    font-size: 2.5rem;
    color: #ff8000;
    display: block;
    margin-bottom: 1rem;
}

.abacus-placeholder-panel h2 {
    font-size: 1.25rem;
    margin-bottom: 0.5rem;
}

.abacus-placeholder-panel p {
    color: #94a3b8;
    margin-bottom: 1.25rem;
}

.abacus-logo-panel {
    border: 1px dashed rgba(75, 191, 238, 0.25);
    border-radius: 10px;
    padding: 1rem;
    height: 100%;
}

.abacus-logo-preview {
    width: 100%;
    max-height: 180px;
    object-fit: contain;
    border-radius: 8px;
    background: rgba(8, 18, 32, 0.85);
    padding: 0.5rem;
}

.abacus-logo-empty {
    height: 140px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 8px;
    background: rgba(8, 18, 32, 0.85);
    color: #4bbfee;
    font-size: 3rem;
}

/* ── Dashboard Layout (UNI-KAMPUS mockup) ─────────────── */

body.dashboard-page {
    background: #070d18;
    color: #e2e8f0;
    min-height: 100vh;
}

.dash-shell {
    display: flex;
    min-height: 100vh;
}

.dash-sidebar {
    width: 250px;
    flex-shrink: 0;
    background: linear-gradient(180deg, #0c1526 0%, #0a1120 100%);
    border-right: 1px solid rgba(255, 255, 255, 0.06);
    display: flex;
    flex-direction: column;
    padding: 1.25rem 1rem;
    position: sticky;
    top: 0;
    height: 100vh;
}

.dash-sidebar-brand {
    margin-bottom: 1.5rem;
}

.dash-brand-link {
    display: flex;
    align-items: center;
    gap: 0.65rem;
    text-decoration: none;
    color: #f8fafc;
    margin-bottom: 0.65rem;
}

.dash-brand-icon {
    width: 36px;
    height: 36px;
    border-radius: 10px;
    background: linear-gradient(135deg, #2563eb, #38bdf8);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1rem;
}

.dash-brand-text {
    font-weight: 800;
    font-size: 0.95rem;
    letter-spacing: 0.02em;
}

.dash-module-badge {
    display: inline-flex;
    padding: 0.2rem 0.55rem;
    border-radius: 999px;
    background: rgba(37, 99, 235, 0.18);
    border: 1px solid rgba(56, 189, 248, 0.35);
    color: #7dd3fc;
    font-size: 0.68rem;
    font-weight: 700;
    letter-spacing: 0.08em;
}

.dash-nav-heading {
    font-size: 0.65rem;
    font-weight: 700;
    letter-spacing: 0.12em;
    color: #64748b;
    margin: 0 0 0.65rem 0.5rem;
}

.dash-nav {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}

.dash-nav-item {
    display: flex;
    align-items: center;
    gap: 0.65rem;
    padding: 0.65rem 0.75rem;
    border-radius: 12px;
    color: #94a3b8;
    text-decoration: none;
    font-size: 0.88rem;
    font-weight: 500;
    transition: var(--transition);
}

.dash-nav-item:hover {
    background: rgba(255, 255, 255, 0.04);
    color: #e2e8f0;
}

.dash-nav-item.is-active {
    background: linear-gradient(135deg, #2563eb, #0284c7);
    color: #fff;
    box-shadow: 0 8px 24px rgba(37, 99, 235, 0.25);
}

.dash-back-modules {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    margin-top: 1rem;
    padding: 0.55rem 0.75rem;
    color: #64748b;
    text-decoration: none;
    font-size: 0.82rem;
}

.dash-back-modules:hover {
    color: #38bdf8;
}

.dash-sidebar-footer {
    margin-top: auto;
    padding-top: 1rem;
    border-top: 1px solid rgba(255, 255, 255, 0.06);
}

.dash-user-card {
    display: flex;
    align-items: center;
    gap: 0.65rem;
    margin-bottom: 0.75rem;
}

.dash-user-avatar {
    width: 38px;
    height: 38px;
    border-radius: 50%;
    background: linear-gradient(135deg, #2563eb, #38bdf8);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.78rem;
    font-weight: 700;
    color: #fff;
}

.dash-user-name {
    margin: 0;
    font-size: 0.85rem;
    font-weight: 600;
    color: #f1f5f9;
}

.dash-user-role {
    margin: 0;
    font-size: 0.72rem;
    color: #64748b;
    display: flex;
    align-items: center;
    gap: 0.35rem;
}

.dash-online-dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: #22c55e;
    box-shadow: 0 0 8px rgba(34, 197, 94, 0.6);
    display: inline-block;
}

.dash-logout-btn {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.45rem;
    padding: 0.55rem;
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 10px;
    background: transparent;
    color: #94a3b8;
    font-size: 0.82rem;
    cursor: pointer;
    transition: var(--transition);
}

.dash-logout-btn:hover {
    background: rgba(239, 68, 68, 0.08);
    border-color: rgba(239, 68, 68, 0.25);
    color: #fca5a5;
}

.dash-main {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    background:
        radial-gradient(ellipse 70% 50% at 50% -20%, rgba(37, 99, 235, 0.12), transparent),
        #070d18;
}

.dash-topbar {
    display: grid;
    grid-template-columns: 1fr minmax(220px, 420px) 1fr;
    align-items: center;
    gap: 1rem;
    padding: 0.85rem 1.5rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.06);
    background: rgba(7, 13, 24, 0.75);
    backdrop-filter: blur(12px);
    position: sticky;
    top: 0;
    z-index: 20;
}

.dash-breadcrumb {
    display: flex;
    align-items: center;
    gap: 0.45rem;
    font-size: 0.82rem;
    color: #94a3b8;
    flex-wrap: wrap;
}

.dash-breadcrumb a {
    color: #cbd5e1;
    text-decoration: none;
}

.dash-crumb-sep {
    opacity: 0.45;
}

.dash-search {
    display: flex;
    align-items: center;
    gap: 0.55rem;
    padding: 0.55rem 0.85rem;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.08);
}

.dash-search i {
    color: #64748b;
}

.dash-search input {
    flex: 1;
    border: none;
    outline: none;
    background: transparent;
    color: #e2e8f0;
    font-size: 0.85rem;
    font-family: var(--font);
}

.dash-topbar-right {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 0.55rem;
}

.dash-icon-btn {
    width: 36px;
    height: 36px;
    border-radius: 10px;
    border: 1px solid rgba(255, 255, 255, 0.08);
    background: rgba(255, 255, 255, 0.03);
    color: #94a3b8;
    cursor: pointer;
}

.dash-icon-btn.dash-notify {
    position: relative;
}

.dash-icon-btn.dash-notify::after {
    content: "";
    position: absolute;
    top: 7px;
    right: 8px;
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: #38bdf8;
}

.dash-status-pill {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.4rem 0.75rem;
    border-radius: 999px;
    background: rgba(34, 197, 94, 0.08);
    border: 1px solid rgba(34, 197, 94, 0.2);
    color: #86efac;
    font-size: 0.75rem;
    font-weight: 600;
}

.dash-content {
    flex: 1;
    padding: 0.85rem 1.15rem 1.15rem;
}

.dash-hero {
    position: relative;
    overflow: hidden;
    border-radius: 16px;
    padding: 1.15rem 1.4rem;
    margin-bottom: 1rem;
    border: 1px solid rgba(255, 255, 255, 0.08);
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1.25rem;
    min-height: 108px;
}

.dash-hero-home {
    background:
        linear-gradient(135deg, rgba(15, 23, 42, 0.95), rgba(30, 58, 138, 0.35)),
        url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='120' height='120' viewBox='0 0 120 120'%3E%3Cpath d='M20 90 L60 30 L100 90 Z' fill='none' stroke='%2338bdf8' stroke-opacity='0.12' stroke-width='2'/%3E%3C/svg%3E");
}

.hero-sems { background: linear-gradient(135deg, #1d4ed8 0%, #0284c7 55%, #0c4a6e 100%); }
.hero-students { background: linear-gradient(135deg, #0f766e 0%, #115e59 55%, #134e4a 100%); }
.hero-teachers { background: linear-gradient(135deg, #6d28d9 0%, #5b21b6 55%, #4c1d95 100%); }
.hero-evidence { background: linear-gradient(135deg, #15803d 0%, #166534 55%, #14532d 100%); }
.hero-evaluation { background: linear-gradient(135deg, #c2410c 0%, #9a3412 55%, #7c2d12 100%); }
.hero-reports { background: linear-gradient(135deg, #334155 0%, #1e293b 55%, #0f172a 100%); }
.hero-general,
.hero-default,
.hero-programs,
.hero-invoices,
.hero-finance,
.hero-payroll,
.hero-books,
.hero-security,
.hero-docs {
    background: linear-gradient(135deg, #1e3a8a 0%, #1e40af 55%, #172554 100%);
}

.dash-hero-copy {
    position: relative;
    z-index: 1;
    max-width: 720px;
}

.dash-hero h1 {
    margin: 0 0 0.3rem;
    font-size: clamp(1.2rem, 2.1vw, 1.65rem);
    font-weight: 800;
    letter-spacing: -0.02em;
    color: #fff;
}

.dash-hero-badge {
    display: inline-flex;
    margin-bottom: 0.65rem;
    padding: 0.25rem 0.65rem;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.12);
    border: 1px solid rgba(255, 255, 255, 0.18);
    font-size: 0.68rem;
    font-weight: 700;
    letter-spacing: 0.1em;
}

.dash-hero-sub {
    margin: 0;
    color: rgba(255, 255, 255, 0.82);
    font-size: 0.95rem;
    line-height: 1.5;
}

.dash-hero-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 0.65rem;
    margin-top: 1rem;
    font-size: 0.82rem;
    color: rgba(255, 255, 255, 0.75);
}

.dash-pill {
    padding: 0.25rem 0.65rem;
    border-radius: 999px;
    background: rgba(56, 189, 248, 0.15);
    border: 1px solid rgba(125, 211, 252, 0.35);
    color: #bae6fd;
}

.dash-hero-art {
    font-size: clamp(4rem, 10vw, 6rem);
    color: rgba(255, 255, 255, 0.12);
    line-height: 1;
}

.dash-hero-art-home {
    position: absolute;
    right: 1.25rem;
    top: 50%;
    transform: translateY(-50%);
    width: min(320px, 38%);
    pointer-events: none;
}

.dash-hero-art-home svg {
    width: 100%;
    height: auto;
    display: block;
}

.dash-hero-home {
    position: relative;
}

.dash-page-head {
    margin: 0 0 0.85rem;
}

.dash-page-head h1 {
    margin: 0 0 0.2rem;
    font-size: clamp(1.25rem, 2vw, 1.6rem);
    font-weight: 800;
    letter-spacing: -0.03em;
    color: #f8fafc;
}

.dash-page-head p {
    margin: 0;
    color: #94a3b8;
    font-size: 0.95rem;
}

.dash-section-label {
    display: inline-flex;
    align-items: center;
    gap: 0.55rem;
    margin: 0 0 1rem;
    color: #38bdf8;
    font-size: 0.92rem;
    font-weight: 600;
}

.dash-section-label i {
    font-size: 1.05rem;
}

.dash-action-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 0.65rem;
}

.dash-action-card {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    min-height: 72px;
    padding: 0.75rem 0.9rem;
    border-radius: 14px;
    background: rgba(15, 23, 42, 0.78);
    border: 1px solid rgba(56, 189, 248, 0.12);
    text-decoration: none;
    color: inherit;
    transition: border-color 0.18s ease, box-shadow 0.18s ease, background 0.18s ease;
}

.dash-action-card:hover:not(.is-locked),
.dash-action-card:focus-visible {
    border-color: rgba(56, 189, 248, 0.55);
    box-shadow: 0 0 0 1px rgba(56, 189, 248, 0.22), 0 10px 28px rgba(2, 8, 23, 0.35);
    background: rgba(15, 23, 42, 0.95);
    outline: none;
}

.dash-action-card.is-locked {
    opacity: 0.58;
    cursor: default;
}

.dash-action-icon {
    flex: 0 0 46px;
    width: 46px;
    height: 46px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.28rem;
    color: #38bdf8;
    background: rgba(14, 165, 233, 0.1);
    border: 1px solid rgba(56, 189, 248, 0.18);
}

.dash-action-copy {
    flex: 1;
    min-width: 0;
}

.dash-action-copy h3 {
    margin: 0 0 0.18rem;
    font-size: 0.9rem;
    font-weight: 700;
    color: #f8fafc;
    line-height: 1.3;
}

.dash-action-copy p {
    margin: 0;
    font-size: 0.75rem;
    color: #64748b;
    line-height: 1.35;
}

.dash-action-chevron {
    flex: 0 0 auto;
    color: #38bdf8;
    font-size: 0.95rem;
    opacity: 0.85;
}

.dash-section-head h2 {
    margin: 0 0 0.15rem;
    font-size: 1.05rem;
    font-weight: 700;
    color: #f8fafc;
}

.dash-section-head p {
    margin: 0 0 0.7rem;
    color: #64748b;
    font-size: 0.82rem;
}

.dash-filter-tabs {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-bottom: 1rem;
}

.dash-filter-tab {
    padding: 0.45rem 0.85rem;
    border-radius: 999px;
    border: 1px solid rgba(255, 255, 255, 0.08);
    background: rgba(255, 255, 255, 0.03);
    color: #94a3b8;
    font-size: 0.8rem;
    font-weight: 500;
    cursor: pointer;
    transition: var(--transition);
}

.dash-filter-tab.is-active,
.dash-filter-tab:hover {
    background: rgba(37, 99, 235, 0.18);
    border-color: rgba(56, 189, 248, 0.35);
    color: #e0f2fe;
}

.dash-card-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
    gap: 0.7rem;
}

.dash-card-grid-modules {
    grid-template-columns: repeat(4, minmax(0, 1fr));
}

.dash-card-grid-compact {
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
}

.dash-card-grid-professor {
    grid-template-columns: repeat(3, minmax(0, 1fr));
}

.dash-subject-list {
    display: flex;
    flex-direction: column;
    gap: 0.55rem;
    max-height: 420px;
    overflow: auto;
    padding-right: 0.15rem;
}

.dash-subject-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    padding: 0.85rem 1rem;
    border-radius: 14px;
    background: rgba(15, 23, 42, 0.78);
    border: 1px solid rgba(56, 189, 248, 0.12);
}

.dash-subject-copy {
    min-width: 0;
}

.dash-subject-copy h3 {
    margin: 0 0 0.2rem;
    font-size: 0.95rem;
    font-weight: 700;
    color: #f8fafc;
}

.dash-subject-copy p {
    margin: 0;
    display: flex;
    flex-wrap: wrap;
    gap: 0.55rem;
    color: #94a3b8;
    font-size: 0.8rem;
}

.dash-subject-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.45rem;
    flex: 0 0 auto;
}

@media (max-width: 900px) {
    .dash-subject-row {
        flex-direction: column;
        align-items: flex-start;
    }
}

.dash-card {
    position: relative;
    display: flex;
    flex-direction: column;
    gap: 0.45rem;
    padding: 0.9rem 1rem;
    border-radius: 14px;
    background: rgba(15, 23, 42, 0.72);
    border: 1px solid rgba(255, 255, 255, 0.08);
    text-decoration: none;
    color: inherit;
    min-height: 132px;
    transition: transform var(--transition), box-shadow var(--transition), border-color var(--transition);
}

.dash-card:hover:not(.is-locked),
.dash-card:focus-visible {
    transform: translateY(-2px);
    border-color: rgba(56, 189, 248, 0.55);
    box-shadow: 0 0 0 1px rgba(56, 189, 248, 0.22), 0 16px 40px rgba(0, 0, 0, 0.25);
    outline: none;
}

.dash-card-status {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    padding: 0.22rem 0.6rem;
    border-radius: 999px;
    background: rgba(34, 197, 94, 0.12);
    border: 1px solid rgba(74, 222, 128, 0.28);
    color: #86efac;
    font-size: 0.72rem;
    font-weight: 600;
}

.dash-card-status.is-locked {
    background: rgba(100, 116, 139, 0.12);
    border-color: rgba(148, 163, 184, 0.25);
    color: #94a3b8;
}

.dash-card.is-locked {
    opacity: 0.62;
}

.dash-card-top {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
}

.dash-card-icon,
.dash-fn-icon {
    width: 42px;
    height: 42px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
}

.dash-card h3,
.dash-card-fn h3 {
    margin: 0;
    font-size: 0.98rem;
    font-weight: 700;
    color: #f8fafc;
    line-height: 1.35;
}

.dash-card p {
    margin: 0;
    font-size: 0.82rem;
    color: #94a3b8;
    line-height: 1.45;
    flex: 1;
}

.dash-card-action {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    font-size: 0.78rem;
    font-weight: 600;
    color: #38bdf8;
}

.dash-card-action.muted {
    color: #64748b;
}

.dash-card-arrow {
    width: 34px;
    height: 34px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, 0.05);
    color: #94a3b8;
}

.dash-card-lock {
    color: #64748b;
}

.dash-card-soon {
    display: inline-flex;
    align-self: flex-start;
    padding: 0.2rem 0.55rem;
    border-radius: 999px;
    background: rgba(251, 146, 60, 0.15);
    color: #fdba74;
    font-size: 0.68rem;
    font-weight: 700;
    letter-spacing: 0.06em;
}

.dash-card-fn {
    min-height: 128px;
    gap: 0.4rem;
}

.dash-card-fn p {
    margin: 0;
    font-size: 0.75rem;
    color: #64748b;
    line-height: 1.35;
    flex: 1;
}

.dash-fn-badge {
    align-self: flex-start;
    padding: 0.18rem 0.5rem;
    border-radius: 999px;
    font-size: 0.58rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    background: rgba(255, 255, 255, 0.06);
    color: #94a3b8;
}

.dash-card-grid-functions {
    grid-template-columns: repeat(5, minmax(0, 1fr));
}

.accent-blue .dash-fn-badge { color: #93c5fd; background: rgba(37, 99, 235, 0.16); }
.accent-purple .dash-fn-badge { color: #d8b4fe; background: rgba(124, 58, 237, 0.16); }
.accent-gold .dash-fn-badge { color: #fde047; background: rgba(202, 138, 4, 0.16); }
.accent-teal .dash-fn-badge { color: #5eead4; background: rgba(13, 148, 136, 0.16); }
.accent-green .dash-fn-badge { color: #86efac; background: rgba(22, 163, 74, 0.16); }

.dash-empty {
    text-align: center;
    padding: 3rem 1rem;
    border: 1px dashed rgba(255, 255, 255, 0.12);
    border-radius: 16px;
    color: #94a3b8;
}

.dash-empty i {
    display: block;
    font-size: 2rem;
    margin-bottom: 0.75rem;
    color: #38bdf8;
}

.dash-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    padding: 0.85rem 1.5rem;
    border-top: 1px solid rgba(255, 255, 255, 0.06);
    color: #64748b;
    font-size: 0.78rem;
    flex-wrap: wrap;
}

.dash-footer-links {
    display: flex;
    gap: 1rem;
}

.dash-footer a {
    color: #64748b;
    text-decoration: none;
}

.dash-footer a:hover {
    color: #94a3b8;
}

/* Accent colors */
.accent-blue .dash-card-icon,
.accent-blue .dash-fn-icon { background: rgba(37, 99, 235, 0.15); color: #60a5fa; border: 1px solid rgba(96, 165, 250, 0.25); }
.accent-purple .dash-card-icon,
.accent-purple .dash-fn-icon { background: rgba(124, 58, 237, 0.15); color: #c4b5fd; border: 1px solid rgba(196, 181, 253, 0.25); }
.accent-green .dash-card-icon,
.accent-green .dash-fn-icon { background: rgba(22, 163, 74, 0.15); color: #86efac; border: 1px solid rgba(134, 239, 172, 0.25); }
.accent-brown .dash-card-icon,
.accent-brown .dash-fn-icon { background: rgba(180, 83, 9, 0.15); color: #fdba74; border: 1px solid rgba(253, 186, 116, 0.25); }
.accent-teal .dash-card-icon,
.accent-teal .dash-fn-icon { background: rgba(13, 148, 136, 0.15); color: #5eead4; border: 1px solid rgba(94, 234, 212, 0.25); }
.accent-red .dash-card-icon,
.accent-red .dash-fn-icon { background: rgba(220, 38, 38, 0.15); color: #fca5a5; border: 1px solid rgba(252, 165, 165, 0.25); }
.accent-gold .dash-card-icon,
.accent-gold .dash-fn-icon { background: rgba(202, 138, 4, 0.15); color: #fde047; border: 1px solid rgba(253, 224, 71, 0.25); }
.accent-orange .dash-card-icon,
.accent-orange .dash-fn-icon { background: rgba(234, 88, 12, 0.15); color: #fdba74; border: 1px solid rgba(253, 186, 116, 0.25); }
.accent-indigo .dash-card-icon,
.accent-indigo .dash-fn-icon { background: rgba(79, 70, 229, 0.15); color: #a5b4fc; border: 1px solid rgba(165, 180, 252, 0.25); }
.accent-slate .dash-card-icon,
.accent-slate .dash-fn-icon { background: rgba(100, 116, 139, 0.15); color: #cbd5e1; border: 1px solid rgba(203, 213, 225, 0.25); }

.accent-blue:hover:not(.is-locked) { border-color: rgba(96, 165, 250, 0.35); }
.accent-purple:hover:not(.is-locked) { border-color: rgba(196, 181, 253, 0.35); }
.accent-green:hover:not(.is-locked) { border-color: rgba(134, 239, 172, 0.35); }
.accent-teal:hover:not(.is-locked) { border-color: rgba(94, 234, 212, 0.35); }
.accent-gold:hover:not(.is-locked) { border-color: rgba(253, 224, 71, 0.35); }

@media (max-width: 1400px) {
    .dash-card-grid-functions {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
}

@media (max-width: 1280px) {
    .dash-action-grid,
    .dash-card-grid-modules,
    .dash-card-grid-professor {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 1100px) {
    .dash-card-grid-functions {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .dash-topbar {
        grid-template-columns: 1fr;
    }

    .dash-topbar-center {
        order: 3;
        grid-column: 1 / -1;
    }
}

@media (max-width: 900px) {
    .dash-shell {
        flex-direction: column;
    }

    .dash-sidebar {
        width: 100%;
        height: auto;
        position: static;
        flex-direction: row;
        flex-wrap: wrap;
        align-items: center;
        gap: 0.75rem;
    }

    .dash-nav {
        flex-direction: row;
        flex-wrap: wrap;
        width: 100%;
    }

    .dash-sidebar-footer {
        width: 100%;
        display: flex;
        align-items: center;
        justify-content: space-between;
    }

    .dash-back-modules {
        width: 100%;
    }
}

@media (max-width: 700px) {
    .dash-action-grid,
    .dash-card-grid-modules,
    .dash-card-grid-functions,
    .dash-card-grid-professor {
        grid-template-columns: 1fr;
    }

    .dash-hero-art-home {
        display: none;
    }
}

@media (max-width: 640px) {
    .dash-content,
    .dash-topbar,
    .dash-footer {
        padding-left: 1rem;
        padding-right: 1rem;
    }

    .dash-hero {
        padding: 1.25rem;
    }

    .dash-status-pill {
        display: none;
    }
}

/* Form pages inside dashboard layout */
.dash-form-page .form-module-bg {
    display: none;
}

.dash-form-page.abacus-form-page {
    min-height: auto;
    padding: 0;
}

.dash-form-page .abacus-form-content {
    max-width: none;
    padding: 0;
}

/* ── Compact density for all CRUD / form pages ─────────── */

body.dashboard-page:has(.dash-form-page) .dash-content {
    padding: 0.65rem 0.95rem 0.9rem;
}

body.dashboard-page:has(.dash-form-page) .dash-topbar {
    padding: 0.55rem 1rem;
}

.dash-form-page .abacus-form-header .abacus-breadcrumb {
    display: none;
}

.abacus-form-page .abacus-btn-back {
    width: 30px;
    height: 30px;
}

.abacus-form-page .abacus-form-toolbar.mb-3,
.abacus-form-page .abacus-form-panel.mb-3,
.abacus-form-page .abacus-table-panel.mb-3,
.abacus-form-page .row.g-3.mb-3 {
    margin-bottom: 0.55rem !important;
}

.abacus-form-page .row.g-3 {
    --bs-gutter-x: 0.6rem;
    --bs-gutter-y: 0.5rem;
}

.abacus-form-page .form-control.abacus-input:not(textarea):not([type="file"]),
.abacus-form-page .form-select.abacus-input,
.abacus-form-page select.abacus-input {
    min-height: 32px;
    height: 32px;
    padding: 0.18rem 0.5rem;
    font-size: 0.82rem;
}

.abacus-form-page textarea.abacus-input {
    min-height: 64px;
    font-size: 0.82rem;
    padding: 0.4rem 0.5rem;
}

.abacus-form-page .abacus-table {
    font-size: 0.78rem;
}

.abacus-form-page .abacus-table th,
.abacus-form-page .abacus-table td {
    padding: 0.3rem 0.45rem;
}

.abacus-form-page .abacus-alert {
    padding: 0.4rem 0.65rem;
    margin-bottom: 0.5rem;
    font-size: 0.8rem;
}

.abacus-form-page .abacus-logo-preview {
    max-height: 110px;
}

.abacus-form-page .abacus-logo-empty {
    height: 88px;
    font-size: 2rem;
}

.abacus-form-page .abacus-logo-panel {
    padding: 0.65rem;
}

.abacus-form-page .form-check {
    min-height: 1.4rem;
    margin-bottom: 0;
}

.student-reg-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 210px;
    gap: 0.7rem;
    align-items: start;
}

.student-reg-fields {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 0.45rem 0.6rem;
}

.student-reg-fields .is-wide {
    grid-column: span 2;
}

.student-reg-fields .is-full {
    grid-column: 1 / -1;
}

.student-reg-media {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.student-reg-media .abacus-form-panel {
    margin-bottom: 0;
    padding: 0.5rem 0.6rem 0.65rem;
}

.student-photo-box,
.student-doc-box {
    height: 112px;
    max-height: 112px;
}

.student-doc-frame {
    height: 112px;
    max-height: 112px;
}

.staff-dense-fields {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 0.45rem 0.6rem;
}

@media (max-width: 1200px) {
    .student-reg-fields,
    .staff-dense-fields {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
}

@media (max-width: 992px) {
    .student-reg-layout {
        grid-template-columns: 1fr;
    }

    .student-reg-media {
        display: grid;
        grid-template-columns: 1fr 1fr;
    }

    .student-reg-fields,
    .staff-dense-fields {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 640px) {
    .student-reg-media,
    .student-reg-fields,
    .staff-dense-fields {
        grid-template-columns: 1fr;
    }
}

.dash-content .form-module {
    width: 100%;
}

a.dash-subject-row,
a.eval-pick-row {
    text-decoration: none;
    color: inherit;
    cursor: pointer;
    transition: border-color var(--transition), box-shadow var(--transition);
}

a.dash-subject-row:hover,
a.eval-pick-row:hover {
    border-color: rgba(56, 189, 248, 0.55);
    box-shadow: 0 0 0 1px rgba(56, 189, 248, 0.18);
}

.eval-pick-list {
    max-height: none;
}

.eval-weight-ok {
    color: #86efac;
}

.eval-weight-warn {
    color: #fbbf24;
}

.eval-student-table tbody tr.is-selected td {
    background: rgba(56, 189, 248, 0.12);
}

.eval-matrix-table {
    min-width: 900px;
}

.eval-matrix-table th,
.eval-matrix-table td {
    white-space: nowrap;
}

.eval-matrix-col {
    min-width: 88px;
    text-align: center;
    vertical-align: bottom;
}

.eval-matrix-weight {
    display: block;
    font-weight: 600;
    color: #7dd3fc;
    font-size: 0.75rem;
}

.eval-matrix-table .js-raw,
.eval-matrix-table .js-total,
.eval-matrix-table .js-grade {
    min-width: 64px;
    text-align: center;
    padding: 0.25rem 0.3rem;
}

body.dashboard-page:has(.invoice-pos) .dash-content {
    padding: 0;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

body.dashboard-page:has(.invoice-pos) .dash-footer {
    display: none;
}

body.dashboard-page:has(.invoice-rent) .dash-topbar {
    display: none;
}

.invoice-pos {
    --pos-navy: #0d1c2f;
    --pos-line: #2a4668;
    --pos-text: #ffffff;
    background: var(--pos-navy);
    color: var(--pos-text);
    flex: 1;
    min-height: 0;
    display: flex;
    flex-direction: column;
    font-family: Tahoma, "Segoe UI", Arial, sans-serif;
}

.invoice-pos-toolbar {
    display: flex;
    align-items: center;
    gap: 0.15rem;
    padding: 0.2rem 0.45rem;
    background: var(--pos-navy);
    flex-wrap: wrap;
}

.invoice-pos-tool {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    background: transparent;
    border: 0;
    color: #fff;
    font-family: Verdana, Tahoma, sans-serif;
    font-weight: 700;
    font-size: 0.95rem;
    padding: 0.4rem 0.55rem;
    text-decoration: none;
    cursor: pointer;
}

.invoice-pos-tool:disabled {
    opacity: 0.45;
    cursor: default;
}
.invoice-pos-tool .bi-receipt-cutoff { color: #8aa3bd; }
.invoice-pos-tool .bi-printer { color: #d9dde3; }
.invoice-pos-tool .bi-arrow-repeat { color: #22c55e; }
.invoice-pos-close .bi-x-circle-fill { color: #ef4444; }
.invoice-pos-company {
    margin-left: auto;
    font-family: "Segoe UI", Tahoma, sans-serif;
    font-weight: 700;
    letter-spacing: 0.03em;
    text-transform: uppercase;
    font-size: 0.88rem;
    padding-right: 0.4rem;
}

.invoice-pos-top {
    display: grid;
    grid-template-columns: minmax(320px, 1.15fr) minmax(300px, 1fr) minmax(260px, 0.95fr);
    gap: 0.45rem;
    padding: 0.35rem 0.45rem 0.5rem;
    background: var(--pos-navy);
}

.invoice-pos-card,
.invoice-pos-actions,
.invoice-pos-total {
    border: 1px solid var(--pos-line);
    background: var(--pos-navy);
    padding: 0.55rem 0.6rem;
}

.invoice-pos-row {
    display: grid;
    grid-template-columns: 128px 1fr;
    align-items: center;
    gap: 0.4rem;
    margin-bottom: 0.35rem;
}

.invoice-pos-label {
    margin: 0;
    font-size: 0.78rem;
    color: #fff;
    white-space: nowrap;
}

.invoice-pos-input,
.invoice-pos-date {
    width: 100%;
    background: #fff;
    color: #111;
    border: 1px solid #9aa8b8;
    border-radius: 0;
    padding: 0.18rem 0.35rem;
    height: 24px;
    font-size: 0.8rem;
}

.invoice-pos-index {
    display: grid;
    grid-template-columns: 1fr 28px;
    gap: 0.2rem;
    align-items: center;
}

.invoice-pos-client {
    position: relative;
}

.invoice-pos-client-search {
    display: grid;
    grid-template-columns: 1fr 34px;
    gap: 0.2rem;
    align-items: center;
}

.invoice-pos-client-search .invoice-pos-input {
    margin: 0;
}

.client-search-drop {
    position: absolute;
    left: 128px;
    right: 0;
    top: calc(100% - 0.15rem);
    z-index: 8;
    background: #fff;
    color: #111;
    border: 1px solid #8ea0b3;
    max-height: 260px;
    overflow: auto;
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.35);
}

.invoice-pos-index .invoice-pos-input {
    margin: 0;
}

.invoice-pos-icon {
    height: 26px;
    border: 1px solid #8ea0b3;
    background: linear-gradient(#f4f7fa, #c5d0db);
    color: #1e293b;
    font-weight: 700;
    font-size: 0.95rem;
    border-radius: 2px;
    cursor: pointer;
}

.invoice-pos-search {
    background: linear-gradient(#eef2f6, #b8c4d0);
}

.invoice-pos-flags {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.15rem 0.8rem;
    font-size: 0.78rem;
    margin-top: 0.45rem;
    color: #fff;
}

.invoice-pos-flags label {
    display: flex;
    align-items: center;
    gap: 0.35rem;
    margin: 0;
}

.invoice-pos-actions {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.32rem 0.4rem;
    align-content: center;
}

.invoice-pos-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    background: linear-gradient(#f3f6f8, #c9d3dd);
    color: #111;
    border: 1px solid #8b9aab;
    border-radius: 2px;
    min-height: 28px;
    font-size: 0.78rem;
    padding: 0.15rem 0.3rem;
    text-decoration: none;
    font-weight: 600;
    cursor: pointer;
}

.invoice-pos-btn:hover {
    background: linear-gradient(#ffffff, #d5dee7);
    color: #111;
}

.invoice-pos-total {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 128px;
    overflow: hidden;
}

.invoice-pos-total span {
    font-family: Tahoma, Arial, sans-serif;
    font-size: 65px;
    font-weight: 700;
    color: #fff;
    line-height: 0.95;
    letter-spacing: -0.02em;
}

.invoice-pos-body {
    display: grid;
    grid-template-columns: 32% 1fr;
    flex: 1;
    min-height: 0;
    background: #fff;
}

.invoice-pos-body.is-catalog {
    grid-template-columns: minmax(260px, 34%) minmax(0, 1fr);
}

.invoice-pos-body.is-catalog .invoice-pos-catalog {
    width: max-content;
    min-width: 100%;
    table-layout: auto;
}

.invoice-pos-items {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.78rem;
    color: #0f172a;
}

.invoice-pos-items th,
.invoice-pos-items td {
    border: 1px solid #c5cdd6;
    padding: 0.28rem 0.45rem;
    text-align: left;
    white-space: nowrap;
}

.invoice-pos-items thead th {
    background: #eef2f6;
    font-weight: 700;
    position: sticky;
    top: 0;
    z-index: 1;
}

.invoice-pos-items .invoice-pos-filter-row th {
    background: #fff;
    padding: 0.15rem;
    top: 28px;
}

.invoice-pos-items .invoice-pos-filter-row input {
    width: 100%;
    border: 1px solid #94a3b8;
    padding: 0.12rem 0.3rem;
    font-size: 0.75rem;
}

.invoice-pos-items tbody tr:nth-child(even) {
    background: #f8fafc;
}

.invoice-pos-items tbody tr:hover {
    background: #dbe7f3;
}

.invoice-pos-items .js-item-row,
.invoice-pos-items .js-client-row,
.invoice-pos-items .js-invoice-row,
.invoice-pos-items .js-line-row {
    cursor: pointer;
}

.invoice-pos-items .js-invoice-row.is-selected,
.invoice-pos-items .js-line-row.is-selected {
    background: #c7ddf0;
}

.invoice-pos-body.is-invoices {
    grid-template-columns: 1fr;
}

.invoice-pos-body.is-invoices .invoice-pos-preview {
    display: none;
}

.invoice-pos-qty,
.invoice-pos-line-input {
    width: 100%;
    min-width: 3.5rem;
    border: 1px solid #94a3b8;
    padding: 0.12rem 0.3rem;
    font-size: 0.75rem;
}

.invoice-pos-line-actions {
    white-space: nowrap;
    width: 1%;
}

.invoice-pos-line-btn {
    border: 0;
    background: transparent;
    cursor: pointer;
    padding: 0.1rem 0.35rem;
    font-weight: 700;
    color: #166534;
}

.invoice-pos-line-btn.is-del {
    color: #b91c1c;
}

.invoice-pos-grid {
    position: relative;
    border-right: 1px solid #c5cdd6;
    overflow: auto;
    background: #fff;
    color: #111;
    min-height: 0;
}

.invoice-pos-preview {
    background: #fff;
    color: #111;
    min-height: 0;
    overflow: auto;
}

.invoice-pos-filter {
    position: sticky;
    top: 0;
    z-index: 2;
    width: 18px;
    height: 18px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #64748b;
    font-size: 0.7rem;
    background: #fff;
}

.invoice-pos-grid table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.8rem;
}

.invoice-pos-grid th,
.invoice-pos-grid td {
    border-bottom: 1px solid #e2e8f0;
    padding: 0.35rem 0.5rem;
    text-align: left;
}

.invoice-pos-grid th {
    background: #f1f5f9;
    position: sticky;
    top: 18px;
}

@media (max-width: 1100px) {
    .invoice-pos-top,
    .invoice-pos-body,
    .invoice-pos-row {
        grid-template-columns: 1fr;
    }

    .invoice-pos-total span {
        font-size: clamp(2.4rem, 8vw, 4rem);
    }
}

@media print {
    .dash-sidebar, .dash-topbar, .dash-footer, .invoice-pos-toolbar, .invoice-pos-top {
        display: none !important;
    }
    .invoice-pos, .invoice-pos-body, .invoice-pos-grid {
        background: #fff;
        color: #000;
        min-height: 0;
    }
}

.invoice-rent {
    min-height: 0;
}

.invoice-rent-caption {
    position: relative;
    display: block;
    padding: 0.35rem 2.2rem 0.15rem;
    color: #fff;
    text-align: center;
}

.invoice-rent-caption span {
    font-family: "Times New Roman", Times, serif;
    font-size: 1.15rem;
    letter-spacing: 0.02em;
}

.invoice-rent-x {
    position: absolute;
    right: 0.55rem;
    top: 0.2rem;
    color: #cfd8e3;
    font-size: 1.35rem;
    line-height: 1;
    text-decoration: none;
    padding: 0 0.2rem;
}

.invoice-rent-toolbar {
    border-bottom: 1px solid var(--pos-line);
}

.invoice-rent-toolbar .bi-floppy-fill { color: #22c55e; }
.invoice-rent-toolbar .bi-pencil-fill { color: #93c5fd; }
.invoice-rent-toolbar .bi-trash-fill { color: #fca5a5; }
.invoice-rent-toolbar .bi-printer-fill { color: #fb923c; }
.invoice-rent-toolbar .bi-search { color: #67e8f9; }

.invoice-rent-msg {
    margin: 0.25rem 0.7rem;
    padding: 0.35rem 0.55rem;
    font-size: 0.82rem;
}

.invoice-rent-msg.is-ok {
    background: #14532d;
    color: #bbf7d0;
}

.invoice-rent-msg.is-err {
    background: #7f1d1d;
    color: #fecaca;
}

.invoice-rent-fields {
    max-width: 760px;
    padding: 0.55rem 0.7rem 0.75rem;
    display: flex;
    flex-direction: column;
    gap: 0.38rem;
}

.invoice-rent .invoice-pos-row {
    display: grid;
    grid-template-columns: 118px minmax(0, 1fr) 14px;
    gap: 0.45rem;
    align-items: center;
}

.invoice-rent-req {
    color: #ef4444;
    font-weight: 700;
}

.invoice-rent-search {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 34px minmax(180px, auto);
    gap: 0.25rem;
    align-items: center;
}

.invoice-rent-find {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.35rem;
    height: 26px;
    padding: 0 0.7rem;
    background: transparent;
    border: 1px solid #1be1d2;
    color: #fff;
    font-size: 0.78rem;
    white-space: nowrap;
    cursor: pointer;
}

.invoice-rent-find:hover {
    background: rgba(27, 225, 210, 0.12);
}

.invoice-rent-split {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.8rem;
}

.invoice-rent-date {
    background: #e85d04;
    color: #fff;
    border-color: #c44e03;
    max-width: 148px;
    font-weight: 700;
}

.invoice-rent-date::-webkit-calendar-picker-indicator {
    filter: invert(1);
}

.invoice-rent-grid {
    flex: 1;
    min-height: 0;
    margin: 0 0.45rem 0.45rem;
    background: #fff;
    color: #111;
    border: 1px solid #9aa8b8;
    display: flex;
    flex-direction: column;
    overflow: auto;
}

.invoice-rent-group {
    background: #f3f4f6;
    color: #9ca3af;
    font-size: 0.72rem;
    padding: 0.28rem 0.55rem;
    border-bottom: 1px solid #d1d5db;
}

.invoice-rent-grid .invoice-pos-items {
    flex: 1;
}

.invoice-rent-grid .js-rent-row {
    cursor: pointer;
}

@media (max-width: 900px) {
    .invoice-rent-search,
    .invoice-rent-split,
    .invoice-rent .invoice-pos-row {
        grid-template-columns: 1fr;
    }

    .invoice-rent-req {
        display: none;
    }
}

body.dashboard-page:has(.exam-pay) .dash-content {
    padding: 0;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

body.dashboard-page:has(.exam-pay) .dash-footer,
body.dashboard-page:has(.exam-pay) .dash-topbar {
    display: none;
}

.exam-pay {
    flex: 1;
    min-height: 0;
    display: flex;
    flex-direction: column;
    background: #f0f0f0;
    color: #111;
    font-family: Tahoma, "Segoe UI", Arial, sans-serif;
}

.exam-pay-caption {
    background: #fff;
    color: #111;
    padding: 0.35rem 0.7rem;
    font-size: 0.92rem;
    border-bottom: 1px solid #cfcfcf;
}

.exam-pay-toolbar {
    display: flex;
    align-items: center;
    gap: 0.35rem;
    padding: 0.35rem 0.55rem;
    background: #f7f7f7;
    border-bottom: 1px solid #ddd;
}

.exam-pay-tool {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    background: transparent;
    border: 0;
    color: #111;
    font-weight: 700;
    font-size: 0.92rem;
    padding: 0.25rem 0.45rem;
    text-decoration: none;
    cursor: pointer;
}

.exam-pay-tool .bi-arrow-repeat { color: #16a34a; font-size: 1.15rem; }
.exam-pay-tool.is-save .bi-check-circle-fill { color: #16a34a; font-size: 1.15rem; }
.exam-pay-tool.is-close .bi-power { color: #dc2626; font-size: 1.15rem; }

.exam-pay-msg {
    margin: 0.35rem 0.7rem 0;
    padding: 0.35rem 0.55rem;
    background: #fee2e2;
    color: #991b1b;
    font-size: 0.82rem;
}

.exam-pay-fields {
    display: grid;
    grid-template-columns: minmax(280px, 1.1fr) minmax(220px, 0.9fr) minmax(280px, 1.2fr);
    gap: 0.8rem 1.2rem;
    padding: 0.7rem 0.8rem 0.5rem;
    align-items: start;
}

.exam-pay-row {
    display: grid;
    grid-template-columns: 118px minmax(0, 1fr);
    gap: 0.4rem;
    align-items: center;
    margin-bottom: 0.28rem;
}

.exam-pay-row.is-service {
    grid-template-columns: 72px minmax(0, 1fr) auto;
}

.exam-pay-row label,
.exam-pay-afati {
    text-align: right;
    font-size: 0.82rem;
}

.exam-pay-afati {
    display: block;
    color: #1d4ed8;
    font-weight: 700;
    text-align: left;
    margin: 0.85rem 0 0.25rem;
}

.exam-pay-row input,
.exam-pay-mid select {
    height: 24px;
    border: 1px solid #7d7d7d;
    background: #fff;
    padding: 0 0.35rem;
    font-size: 0.8rem;
    width: 100%;
}

.exam-pay-find {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    height: 28px;
    padding: 0 0.7rem;
    background: linear-gradient(#f7f7f7, #dcdcdc);
    border: 1px solid #8b8b8b;
    color: #111;
    font-size: 0.78rem;
    cursor: pointer;
    white-space: nowrap;
}

.exam-pay-view {
    margin-top: 1.6rem;
}

.exam-pay-grid {
    flex: 1;
    min-height: 0;
    margin: 0.2rem 0.45rem 0.45rem;
    background: #fff;
    border: 1px solid #b0b0b0;
    display: flex;
    flex-direction: column;
    overflow: auto;
}

.exam-pay-group {
    background: #f3f4f6;
    color: #9ca3af;
    font-size: 0.72rem;
    padding: 0.28rem 0.55rem;
    border-bottom: 1px solid #d1d5db;
}

.exam-pay-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.78rem;
}

.exam-pay-table th,
.exam-pay-table td {
    border-bottom: 1px solid #e5e7eb;
    padding: 0.22rem 0.4rem;
    text-align: left;
}

.exam-pay-table th {
    background: #f8fafc;
    font-weight: 700;
}

.exam-pay-table tbody tr:hover {
    background: #eef4fb;
}

.exam-pay-table .js-exam-row {
    cursor: pointer;
}

.exam-pay-sel {
    text-align: center;
    width: 36px;
}

@media (max-width: 1100px) {
    .exam-pay-fields,
    .exam-pay-row,
    .exam-pay-row.is-service {
        grid-template-columns: 1fr;
    }

    .exam-pay-row label,
    .exam-pay-afati {
        text-align: left;
    }
}

body.dashboard-page:has(.svc-form) .dash-content {
    padding: 0;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

body.dashboard-page:has(.svc-form) .dash-footer,
body.dashboard-page:has(.svc-form) .dash-topbar {
    display: none;
}

.svc-form {
    flex: 1;
    min-height: 0;
    display: flex;
    flex-direction: column;
    background: #b8cce4;
    color: #1f2937;
    font-family: Tahoma, "Segoe UI", Arial, sans-serif;
    padding: 0.85rem 0.9rem 0.6rem;
}

.svc-msg {
    margin-bottom: 0.55rem;
    padding: 0.35rem 0.55rem;
    font-size: 0.82rem;
}

.svc-msg.is-ok { background: #dcfce7; color: #166534; }
.svc-msg.is-err { background: #fee2e2; color: #991b1b; }

.svc-fields {
    display: grid;
    grid-template-columns: 1.15fr 0.85fr;
    gap: 0.8rem 1.6rem;
    max-width: 980px;
}

.svc-row {
    display: grid;
    grid-template-columns: 92px minmax(0, 1fr);
    gap: 0.45rem;
    align-items: center;
    margin-bottom: 0.4rem;
}

.svc-row label {
    color: #6b7280;
    font-size: 0.86rem;
    text-align: right;
}

.svc-req { color: #dc2626; font-weight: 700; }

.svc-row input,
.svc-row select {
    height: 26px;
    border: 1px solid #7d8fa3;
    background: #fff;
    padding: 0 0.4rem;
    font-size: 0.82rem;
    width: 100%;
}

.svc-cat {
    display: grid;
    grid-template-columns: 1fr 34px;
    gap: 0.35rem;
}

.svc-plus {
    height: 26px;
    border: 1px solid #8b9aab;
    background: linear-gradient(#fff, #dfe6ee);
    font-weight: 700;
    cursor: pointer;
}

.svc-actions {
    display: flex;
    gap: 0.45rem;
    margin: 0.7rem 0 0.85rem;
    flex-wrap: wrap;
}

.svc-actions button,
.svc-actions a {
    min-width: 78px;
    height: 30px;
    padding: 0 0.8rem;
    border: 1px solid #8b9aab;
    background: linear-gradient(#fff, #e4e9ef);
    color: #111;
    font-size: 0.82rem;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
}

.svc-actions button:disabled {
    opacity: 0.55;
    cursor: default;
}

.svc-grid-wrap {
    flex: 1;
    min-height: 0;
    display: flex;
    flex-direction: column;
    background: #fff;
    border: 1px solid #9aa8b8;
}

.svc-grid-title {
    background: #e5e7eb;
    padding: 0.28rem 0.55rem;
    font-weight: 700;
    font-size: 0.82rem;
    border-bottom: 1px solid #cbd5e1;
}

.svc-grid {
    flex: 1;
    overflow: auto;
}

.svc-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.78rem;
}

.svc-table th,
.svc-table td {
    border-bottom: 1px solid #e5e7eb;
    padding: 0.22rem 0.4rem;
    text-align: left;
}

.svc-table th { background: #f3f4f6; }
.svc-table .js-svc-row { cursor: pointer; }
.svc-table tbody tr:hover { background: #eef4fb; }

@media (max-width: 900px) {
    .svc-fields,
    .svc-row,
    .svc-cat {
        grid-template-columns: 1fr;
    }

    .svc-row label { text-align: left; }
}

body.dashboard-page:has(.pgf) .dash-content {
    padding: 0;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

body.dashboard-page:has(.pgf) .dash-footer,
body.dashboard-page:has(.pgf) .dash-topbar {
    display: none;
}

.pgf {
    flex: 1;
    min-height: 0;
    display: flex;
    flex-direction: column;
    background: #f0f0f0;
    color: #111;
    font-family: Tahoma, "Segoe UI", Arial, sans-serif;
}

.pgf-caption {
    background: #fff;
    color: #111;
    padding: 0.35rem 0.7rem;
    font-size: 0.92rem;
    border-bottom: 1px solid #cfcfcf;
}

.pgf-msg {
    margin: 0.45rem 1rem 0;
    color: #b91c1c;
    font-weight: 700;
}

.pgf-search {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 0.35rem;
    padding: 0.7rem 1rem 0.2rem;
}

.pgf-search-input {
    width: 220px;
    height: 26px;
    border: 1px solid #7a7a7a;
    background: #fff;
    padding: 0 0.4rem;
}

.pgf-lupa {
    width: 36px;
    height: 26px;
    border: 1px solid #8a8a8a;
    background: #e6e6e6;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: #333;
}

.pgf-fields {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.45rem;
    padding: 0.4rem 1rem 0.2rem;
}

.pgf-row {
    display: grid;
    grid-template-columns: 130px 333px;
    align-items: center;
    gap: 0.8rem;
}

.pgf-row label {
    color: #0000ff;
    font-size: 0.82rem;
    text-align: right;
}

.pgf-row input {
    height: 24px;
    border: 1px solid #7a7a7a;
    background: #fff;
    padding: 0 0.35rem;
}

.pgf-row.is-amount {
    align-items: start;
    padding-top: 0.35rem;
}

.pgf-row.is-amount label {
    padding-top: 1.6rem;
}

.pgf-amount {
    height: 78px !important;
    font-size: 45px;
    font-weight: 700;
    color: #0000ff;
    text-align: right;
    direction: rtl;
    font-family: Tahoma, "Segoe UI", Arial, sans-serif;
    padding: 0 0.5rem !important;
}

.pgf-actions {
    display: flex;
    justify-content: center;
    gap: 0.7rem;
    padding: 0.7rem 1rem 0.5rem;
}

.pgf-btn {
    min-width: 228px;
    height: 39px;
    font-size: 1.25rem;
    font-weight: 700;
    color: #0000ff;
    background: #e8e8e8;
    border: 1px solid #7a9ad6;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.pgf-btn:focus {
    outline: 1px solid #2563eb;
}

.pgf-grid {
    flex: 1;
    min-height: 180px;
    margin: 0.4rem 1.1rem;
    background: #fff;
    border: 1px solid #7a7a7a;
    overflow: auto;
}

.pgf-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.82rem;
}

.pgf-table th,
.pgf-table td {
    border-bottom: 1px solid #e5e7eb;
    padding: 0.28rem 0.45rem;
    text-align: left;
    white-space: nowrap;
}

.pgf-table th {
    background: #f3f4f6;
    font-weight: 700;
}

.pgf-table .js-pgf-row {
    cursor: pointer;
}

.pgf-table tbody tr:hover {
    background: #eef4fb;
}

.pgf-footer {
    display: flex;
    justify-content: center;
    gap: 1.2rem;
    padding: 0.45rem 1rem 0.7rem;
}

.pgf-foot {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    font-size: 0.82rem;
}

.pgf-foot input {
    width: 90px;
    height: 22px;
    border: 1px solid #7a7a7a;
    background: #fff;
    text-align: right;
    padding: 0 0.3rem;
}

@media (max-width: 700px) {
    .pgf-row,
    .pgf-row.is-amount {
        grid-template-columns: 1fr;
        width: min(333px, 100%);
    }

    .pgf-row label,
    .pgf-row.is-amount label {
        text-align: left;
        padding-top: 0;
    }

    .pgf-btn {
        min-width: 140px;
    }
}

.client-search-form {
    position: fixed;
    inset: 0;
    z-index: 40;
    display: flex;
    align-items: flex-start;
    justify-content: center;
    padding: 2.2rem 1rem 1rem;
    background: rgba(8, 16, 28, 0.55);
}

.client-search-form[hidden] {
    display: none;
}

.client-search-form-box {
    width: min(940px, 96vw);
    background: #e8e8e8;
    border: 1px solid #6f6f6f;
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.45);
    font-family: Tahoma, "Segoe UI", Arial, sans-serif;
    color: #111;
}

.client-search-form-title {
    background: linear-gradient(#3a6ea5, #2b5380);
    color: #fff;
    font-weight: 700;
    font-size: 0.95rem;
    padding: 0.35rem 0.7rem;
}

.client-search-form-top {
    display: grid;
    grid-template-columns: 1fr 220px;
    gap: 0.45rem;
    padding: 0.45rem 0.45rem 0.2rem;
}

.client-search-form-group,
.client-search-form-actions {
    background: #f3f3f3;
    border: 1px solid #b7b7b7;
    padding: 0.45rem 0.6rem 0.55rem;
}

.client-search-form-caption {
    font-size: 0.78rem;
    color: #2b5380;
    font-weight: 700;
    margin-bottom: 0.25rem;
}

.client-search-form-label {
    display: block;
    font-size: 0.8rem;
    margin-bottom: 0.15rem;
}

.client-search-form-input {
    width: 100%;
    height: 28px;
    border: 1px solid #7a7a7a;
    background: #fff;
    padding: 0 0.4rem;
}

.client-search-form-actions {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 0.45rem;
}

.client-search-form-plus,
.client-search-form-close {
    min-height: 34px;
    border: 1px solid #8b9aab;
    cursor: pointer;
    font-weight: 700;
}

.client-search-form-plus {
    min-width: 52px;
    background: #fff;
    color: #1d4ed8;
}

.client-search-form-plus:disabled {
    opacity: 0.45;
    cursor: default;
}

.client-search-form-close {
    min-width: 92px;
    background: #b42318;
    color: #fff;
    border-color: #8f1d14;
}

.client-search-form-grid-wrap {
    margin: 0.35rem 0.45rem 0.55rem;
    background: #fff;
    border: 1px solid #b7b7b7;
    min-height: 280px;
    max-height: min(52vh, 420px);
    overflow: auto;
}

.client-search-form-grid {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.82rem;
}

.client-search-form-grid th,
.client-search-form-grid td {
    border-bottom: 1px solid #d9d9d9;
    padding: 0.28rem 0.4rem;
    text-align: left;
    white-space: nowrap;
}

.client-search-form-grid th {
    background: #f2f2f2;
    position: sticky;
    top: 0;
}

.client-search-form-grid tbody tr {
    cursor: pointer;
}

.client-search-form-grid tbody tr:hover {
    background: #dceeff;
}

.client-search-form-empty {
    padding: 1.2rem 0.8rem;
    color: #5b5b5b;
    font-size: 0.85rem;
}

@media (max-width: 700px) {
    .client-search-form-top {
        grid-template-columns: 1fr;
    }
}

.invoice-desk {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    color: #0f172a;
    font-family: "Plus Jakarta Sans", "Segoe UI", sans-serif;
}

.invoice-desk-msg {
    border-radius: 10px;
    padding: 0.7rem 1rem;
    font-size: 0.9rem;
}

.invoice-desk-msg.is-ok {
    background: #ecfdf3;
    color: #067647;
}

.invoice-desk-msg.is-err {
    background: #fef3f2;
    color: #b42318;
}

.invoice-desk-head {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 1rem;
    flex-wrap: wrap;
}

.invoice-desk-head h1 {
    margin: 0;
    font-size: 1.7rem;
    font-weight: 800;
}

.invoice-desk-head p {
    margin: 0.2rem 0 0;
    color: #64748b;
    font-size: 0.92rem;
}

.invoice-desk-head-actions,
.invoice-desk-footer-right,
.invoice-desk-quick {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.invoice-desk-btn,
.invoice-desk-quick-btn,
.invoice-desk-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.35rem;
    border: 1px solid #d0d5dd;
    background: #fff;
    color: #344054;
    border-radius: 10px;
    min-height: 38px;
    padding: 0 0.85rem;
    font-weight: 600;
    font-size: 0.86rem;
    text-decoration: none;
    cursor: pointer;
}

.invoice-desk-btn.is-primary {
    background: #175cd3;
    border-color: #175cd3;
    color: #fff;
}

.invoice-desk-top {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 320px;
    gap: 1rem;
    align-items: stretch;
}

.invoice-desk.is-note .invoice-desk-top {
    grid-template-columns: 1fr;
}

.invoice-desk.is-note .invoice-desk-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
}

.invoice-desk-card {
    background: #fff;
    border: 1px solid #eaecf0;
    border-radius: 16px;
    padding: 1rem 1.1rem;
}

.invoice-desk-actions {
    background: #fff;
    border: 1px solid #eaecf0;
    border-radius: 16px;
    padding: 1rem 1.1rem;
    display: flex;
    flex-direction: column;
    gap: 0.55rem;
}

.invoice-desk-actions h2 {
    margin: 0 0 0.2rem;
    font-size: 1rem;
    font-weight: 700;
}

.invoice-desk-actions-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.5rem;
}

.invoice-desk-quick-btn.is-wide {
    width: 100%;
    flex: 0 0 auto;
}

.invoice-desk-card h2,
.invoice-desk-panel-head h2 {
    margin: 0;
    font-size: 1rem;
    font-weight: 700;
}

.invoice-desk-notes {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.5rem;
    margin: 0.7rem 0 1rem;
    min-width: 0;
}

.invoice-desk-note {
    display: flex;
    align-items: center;
    gap: 0.45rem;
    border: 1px solid #d0d5dd;
    border-radius: 10px;
    padding: 0.55rem 0.75rem;
    font-size: 0.86rem;
    font-weight: 600;
    cursor: pointer;
    margin: 0;
    background: #f8fafc;
    min-width: 0;
    white-space: nowrap;
    line-height: 1.3;
}

.invoice-desk-note input {
    margin: 0;
}

.invoice-desk-note.is-on,
.invoice-desk-note:has(input:checked) {
    background: #eff4ff;
    border-color: #84adff;
    color: #175cd3;
}

.invoice-desk-note-hint {
    font-size: 0.78rem;
    color: #475467;
    margin: 0 0 0.85rem;
    line-height: 1.4;
}

.invoice-desk-vatbox {
    display: flex;
    gap: 1rem;
    align-items: center;
    background: #0b3a82;
    color: #fff;
    border-radius: 12px;
    padding: 0.55rem 0.9rem;
}

.invoice-desk-vatbox div {
    display: flex;
    flex-direction: column;
    gap: 0.1rem;
    min-width: 5.5rem;
}

.invoice-desk-vatbox span {
    font-size: 0.72rem;
    opacity: 0.8;
}

.invoice-desk-vatbox strong {
    font-size: 0.95rem;
}

.svc-note-checks {
    display: flex;
    flex-wrap: wrap;
    gap: 0.85rem 1.2rem;
    align-items: center;
    min-height: 34px;
}

.svc-note-checks label {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    font-weight: 600;
    color: #344054;
}

.invoice-desk-kind {
    display: flex;
    gap: 0.4rem;
    margin: 0.8rem 0 1rem;
}

.invoice-desk-pill {
    border: 1px solid #d0d5dd;
    border-radius: 999px;
    padding: 0.35rem 0.85rem;
    font-size: 0.82rem;
    font-weight: 600;
    cursor: pointer;
    margin: 0;
}

.invoice-desk-pill input {
    display: none;
}

.invoice-desk-pill.is-on,
.invoice-desk-pill:has(input:checked) {
    background: #eff4ff;
    border-color: #84adff;
    color: #175cd3;
}

.invoice-desk-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 0.75rem 1rem;
}

.invoice-desk-field.is-wide {
    grid-column: 1 / -1;
    position: relative;
}

.invoice-desk-label {
    display: block;
    font-size: 0.78rem;
    font-weight: 600;
    color: #475467;
    margin-bottom: 0.3rem;
}

.invoice-desk-input {
    width: 100%;
    height: 40px;
    border: 1px solid #d0d5dd;
    border-radius: 10px;
    padding: 0 0.75rem;
    background: #fff;
}

.invoice-desk-lookup {
    display: grid;
    grid-template-columns: 1fr 38px 38px;
    gap: 0.3rem;
    align-items: center;
    border: 1px solid #d0d5dd;
    border-radius: 10px;
    padding: 0 0.35rem 0 0.7rem;
    background: #fff;
}

.invoice-desk-lookup.is-single {
    grid-template-columns: 1fr 38px;
}

.invoice-desk-lookup .invoice-desk-input {
    border: 0;
    height: 38px;
    padding-left: 0;
    box-shadow: none;
}

.invoice-desk-icon {
    min-width: 34px;
    min-height: 34px;
    padding: 0;
    border-radius: 8px;
}

.invoice-desk .client-search-drop {
    left: 0;
    right: 0;
    top: calc(100% + 4px);
    border-radius: 12px;
}

.invoice-desk-check {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    font-size: 0.82rem;
    font-weight: 600;
    color: #475467;
    margin-bottom: 0.35rem;
}

.invoice-desk-sum {
    background: #102a56;
    color: #fff;
    border-radius: 16px;
    padding: 1.1rem;
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 0.2rem;
}

.invoice-desk-sum strong {
    font-size: 1.8rem;
    font-weight: 800;
}

.invoice-desk-sum span,
.invoice-desk-sum small {
    opacity: 0.8;
    font-size: 0.82rem;
}

.invoice-desk-actions .invoice-desk-quick-btn {
    flex: 0 0 auto;
    min-height: 42px;
    width: 100%;
    text-align: center;
}

.invoice-desk-paybar {
    display: grid;
    grid-template-columns: minmax(140px, auto) 1fr auto;
    align-items: center;
    gap: 0.8rem;
    margin-top: 0.85rem;
    padding-top: 0.85rem;
    border-top: 1px solid #eaecf0;
}

.invoice-desk-paybar > span {
    color: #667085;
    font-size: 0.86rem;
    font-weight: 600;
}

.invoice-desk-paybar-actions {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.invoice-desk-paytotal {
    background: #102a56;
    color: #fff;
    border-radius: 14px;
    min-width: 210px;
    padding: 0.7rem 1rem;
    display: flex;
    flex-direction: column;
    gap: 0.1rem;
}

.invoice-desk-paytotal span {
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    opacity: 0.8;
}

.invoice-desk-paytotal strong {
    font-size: 1.55rem;
    font-weight: 800;
    line-height: 1.1;
}

.invoice-desk-table .js-line-total {
    color: #175cd3;
    font-weight: 700;
}

.invoice-desk-work {
    display: grid;
    grid-template-columns: minmax(240px, 280px) minmax(0, 1fr);
    gap: 1rem;
    align-items: start;
}

.invoice-desk-services,
.invoice-desk-lines {
    background: #fff;
    border: 1px solid #eaecf0;
    border-radius: 16px;
    padding: 1rem;
    display: flex;
    flex-direction: column;
    min-height: 0;
}

.invoice-desk-panel-head {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.75rem;
}

.invoice-desk-tabs {
    display: flex;
    gap: 0.3rem;
    margin: 0.65rem 0;
}

.invoice-desk-tabs button {
    border: 0;
    background: #f2f4f7;
    color: #475467;
    border-radius: 999px;
    padding: 0.28rem 0.7rem;
    font-size: 0.75rem;
    font-weight: 600;
}

.invoice-desk-tabs button.is-on {
    background: #eff4ff;
    color: #175cd3;
}

.invoice-desk-svc-list {
    overflow: auto;
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
    max-height: calc(10 * 2.7rem);
}

.invoice-desk-svc {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
    border: 1px solid #eaecf0;
    background: #fff;
    border-radius: 10px;
    padding: 0.55rem 0.7rem;
    text-align: left;
    cursor: pointer;
}

.invoice-desk-svc:hover {
    border-color: #84adff;
    background: #f8faff;
}

.invoice-desk-svc i {
    color: #175cd3;
}

.invoice-desk-lines-body {
    overflow: auto;
    max-height: calc(42px + 10 * 42px);
}

.invoice-desk-empty {
    min-height: 72px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 0.4rem;
    color: #667085;
    text-align: center;
    padding: 0.6rem 0;
}

.invoice-desk-empty i {
    font-size: 2rem;
    color: #98a2b3;
}

.invoice-desk-table {
    width: 100%;
}

.invoice-desk-foot-totals {
    display: flex;
    justify-content: flex-end;
    gap: 1.4rem;
    padding-top: 0.8rem;
    margin-top: 0.6rem;
    border-top: 1px solid #eaecf0;
    font-size: 0.85rem;
}

.invoice-desk-foot-totals .is-total strong {
    color: #175cd3;
}

.invoice-desk-footer {
    display: flex;
    justify-content: space-between;
    gap: 0.7rem;
    flex-wrap: wrap;
}

.invoice-desk-hint {
    color: #667085;
    font-size: 0.82rem;
    margin: 0.4rem 0;
}

.invoice-desk-link {
    border: 0;
    background: none;
    color: #175cd3;
    font-weight: 700;
}

@media (max-width: 1100px) {
    .invoice-desk-top,
    .invoice-desk.is-note .invoice-desk-top,
    .invoice-desk-work,
    .invoice-desk-grid,
    .invoice-desk.is-note .invoice-desk-grid,
    .invoice-desk-actions-grid,
    .invoice-desk-paybar {
        grid-template-columns: 1fr;
    }
}

.invoice-pagesa {
    position: fixed;
    inset: 0;
    z-index: 80;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(15, 23, 42, 0.35);
}

.invoice-pagesa[hidden] {
    display: none;
}

.invoice-pagesa-box {
    width: min(420px, calc(100vw - 24px));
    background: #d6eaf8;
    border: 1px solid #7aa7c7;
    border-radius: 4px;
    padding: 18px 20px 16px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.25);
}

.invoice-pagesa-row {
    display: grid;
    grid-template-columns: 90px 1fr;
    align-items: center;
    gap: 8px;
    margin-bottom: 8px;
}

.invoice-pagesa-row label {
    font-weight: 700;
    font-size: 0.92rem;
}

.invoice-pagesa-kinds {
    display: flex;
    flex-wrap: wrap;
    gap: 10px 14px;
    margin: 10px 0 12px;
    font-size: 0.86rem;
    font-weight: 600;
}

.invoice-pagesa-box h2 {
    margin: 0 0 12px;
    font-size: 1.05rem;
    color: #0f172a;
}

.invoice-pagesa-box .invoice-desk-input,
.invoice-pagesa-box select.invoice-pagesa-bank {
    background: #fff;
    color: #0f172a;
    border: 1px solid #7aa7c7;
}

.invoice-pagesa-box select.invoice-pagesa-bank option {
    color: #0f172a;
    background: #fff;
}

.invoice-pagesa-box .invoice-desk-check {
    color: #0f172a;
    margin: 4px 0 0;
}

.invoice-pagesa-actions {
    display: flex;
    justify-content: flex-end;
    gap: 8px;
    margin-top: 14px;
}

.book-toolbar {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 16px;
    flex-wrap: wrap;
    margin-bottom: 16px;
}

.book-company {
    margin: 4px 0 0;
    color: #64748b;
    font-size: 0.88rem;
}

.book-toolbar-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.book-table {
    font-size: 0.78rem;
    background: #fff;
}

.book-table thead {
    background: #0f172a;
    color: #fff;
}

.book-table tfoot {
    background: #fef3c7;
    font-weight: 700;
}

.vat-book-table {
    overflow-x: auto;
}

.vat-book-table table {
    min-width: 1800px;
}

@media print {
    .no-print,
    .abacus-btn-back,
    .form-module-bg {
        display: none !important;
    }

    .vat-book-table {
        overflow: visible !important;
    }

    .book-table {
        font-size: 9px;
    }
}

/* Transaction register — light ledger entry (matches new-entry mockup) */
body.dashboard-page:has(.trn-entry-page) .dash-content {
    background: #eef1f5;
}

.trn-entry-page {
    padding: 0;
}

.trn-entry {
    max-width: 1100px;
    margin: 0 auto;
    padding: 0.35rem 0 1.5rem;
    color: #111827;
}

.trn-back {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    color: #2563eb;
    text-decoration: none;
    font-size: 0.92rem;
    font-weight: 600;
    margin-bottom: 0.85rem;
}

.trn-back:hover {
    color: #1d4ed8;
}

.trn-entry-heading {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 1rem;
    margin-bottom: 1rem;
}

.trn-entry-heading h1 {
    margin: 0;
    font-size: 1.7rem;
    font-weight: 800;
    color: #111827;
}

.trn-entry-heading p {
    margin: 0.25rem 0 0;
    color: #6b7280;
    font-size: 0.95rem;
}

.trn-toolbar {
    display: flex;
    flex-wrap: wrap;
    gap: 0.45rem;
    margin-bottom: 1rem;
}

.trn-card {
    background: #fff;
    border: 1px solid #e5e7eb;
    border-radius: 12px;
    padding: 1.15rem 1.25rem 1.25rem;
    margin-bottom: 1rem;
    box-shadow: 0 1px 2px rgba(15, 23, 42, 0.04);
}

.trn-card h2 {
    margin: 0 0 1rem;
    font-size: 1.05rem;
    font-weight: 800;
    color: #111827;
}

.trn-grid {
    display: grid;
    gap: 0.85rem 1rem;
}

.trn-grid-3 {
    grid-template-columns: repeat(3, minmax(0, 1fr));
}

.trn-grid-4 {
    grid-template-columns: repeat(4, minmax(0, 1fr));
}

.trn-field {
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
    min-width: 0;
}

.trn-field label,
.trn-label {
    font-size: 0.82rem;
    font-weight: 600;
    color: #374151;
}

.trn-entry input[type="text"],
.trn-entry input[type="date"],
.trn-entry input[type="number"],
.trn-entry input:not([type]),
.trn-entry select,
.trn-entry textarea {
    width: 100%;
    border: 1px solid #d1d5db;
    border-radius: 8px;
    background: #fff;
    color: #111827;
    padding: 0.5rem 0.7rem;
    min-height: 40px;
}

.trn-entry textarea {
    min-height: 120px;
    resize: vertical;
}

.trn-entry input:focus,
.trn-entry select:focus,
.trn-entry textarea:focus {
    outline: none;
    border-color: #2563eb;
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.15);
}

.trn-entry input[readonly] {
    background: #f9fafb;
    color: #111827;
}

.trn-input-group {
    display: flex;
    min-width: 0;
}

.trn-input-group input {
    border-top-right-radius: 0;
    border-bottom-right-radius: 0;
}

.trn-input-group .trn-btn {
    border-top-left-radius: 0;
    border-bottom-left-radius: 0;
    border-left: 0;
    white-space: nowrap;
}

.trn-radios,
.trn-check {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.85rem 1.1rem;
    color: #111827;
    font-size: 0.9rem;
}

.trn-check {
    margin-bottom: 0.75rem;
    font-weight: 600;
}

.trn-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.35rem;
    border-radius: 8px;
    border: 1px solid #d1d5db;
    background: #fff;
    color: #111827;
    padding: 0.45rem 0.85rem;
    font-weight: 600;
    font-size: 0.88rem;
    text-decoration: none;
    cursor: pointer;
}

.trn-btn:hover {
    background: #f3f4f6;
    color: #111827;
}

.trn-btn:disabled {
    opacity: 0.45;
    cursor: not-allowed;
}

.trn-btn-ghost {
    background: #fff;
}

.trn-btn-primary {
    background: #2563eb;
    border-color: #2563eb;
    color: #fff;
}

.trn-btn-primary:hover:not(:disabled) {
    background: #1d4ed8;
    color: #fff;
}

.trn-btn-lg {
    min-width: 200px;
    min-height: 44px;
}

.trn-footer {
    margin-top: 0.25rem;
}

.trn-empty,
.trn-hint {
    color: #6b7280;
    margin: 0;
}

.trn-hint {
    font-size: 0.85rem;
    margin-bottom: 0.65rem;
}

.trn-table {
    margin: 0;
    color: #111827;
}

.trn-table thead th {
    background: #f3f4f6;
    color: #111827;
    font-size: 0.78rem;
    white-space: nowrap;
}

.trn-table tbody tr {
    cursor: pointer;
}

.trn-table tbody tr:hover {
    background: #eff6ff;
}

.trn-tax {
    margin-top: 0.75rem;
    padding-top: 0.75rem;
    border-top: 1px solid #e5e7eb;
}

@media (max-width: 900px) {
    .trn-grid-3,
    .trn-grid-4 {
        grid-template-columns: 1fr 1fr;
    }
}

@media (max-width: 640px) {
    .trn-entry-heading,
    .trn-grid-3,
    .trn-grid-4 {
        grid-template-columns: 1fr;
        display: grid;
    }

    .trn-entry-heading {
        align-items: stretch;
    }
}


