/*
|==========================================================================
| TEMA "GRAFIT + PORTOKALLI"  —  Sistemi i Orarit
|==========================================================================
| Ngarkohet pas stileve të çdo faqeje dhe i mbishkruan ato.
| Për ta çaktivizuar, hiqni rreshtin <link ... tema.css> nga faqet
| ose zbrazni këtë skedar.
|==========================================================================
*/

@import url("https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700&family=Manrope:wght@600;700;800&display=swap");

:root {
    --t-bg: #f6f4f1;
    --t-surface: #ffffff;
    --t-surface-2: #faf8f5;
    --t-ink: #0f1210;
    --t-ink-2: #2b2f2c;
    --t-muted: #6b716b;
    --t-line: #e9e4dd;
    --t-line-2: #ddd6cc;

    --t-side: #0d0f0e;
    --t-side-2: #161a17;
    --t-side-text: #a7ada6;

    --t-accent: #fb923c;
    --t-accent-2: #fdba74;
    --t-accent-soft: #fff4e8;
    --t-accent-ink: #9a3412;
    --t-accent-ink-2: #c2410c;
    /* Butonat kryesorë: portokalli i çelur (jo i zi) */
    --t-primary: #fb923c;
    --t-primary-hover: #f97316;
    --t-primary-text: #431407;

    --t-ok: #047857;
    --t-ok-soft: #ecfdf5;
    --t-ok-line: #a7f3d0;

    --t-red: #dc2626;
    --t-red-soft: #fef2f2;
    --t-amber: #b45309;
    --t-amber-soft: #fffbeb;
    --t-blue: #1d4ed8;
    --t-blue-soft: #eff6ff;

    --t-radius: 16px;
    --t-radius-sm: 10px;
    --t-shadow: 0 1px 2px rgba(16, 20, 17, .04), 0 4px 16px -6px rgba(16, 20, 17, .08);
    --t-shadow-lg: 0 2px 4px rgba(16, 20, 17, .04), 0 18px 40px -16px rgba(16, 20, 17, .22);

    --t-font: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
    --t-font-head: "Manrope", "Inter", system-ui, sans-serif;
}

/* -------------------------------------------------------------------------
   BAZA
------------------------------------------------------------------------- */

html body {
    font-family: var(--t-font);
    background: var(--t-bg);
    color: var(--t-ink);
    -webkit-font-smoothing: antialiased;
    font-feature-settings: "cv11", "ss01";
}

body ::selection {
    background: var(--t-accent);
    color: var(--t-ink);
}

body h1, body h2, body h3,
body .page-title, body .title, body .card-title, body .section-title,
body .form-title, body .filter-title, body .summary-title {
    font-family: var(--t-font-head);
    letter-spacing: -0.02em;
    color: var(--t-ink);
}

body h1, body .header h1, body .top h1, body .page-header h1 {
    font-weight: 800;
    font-size: clamp(24px, 2.4vw, 32px);
}

body a { color: var(--t-accent-ink-2); }

body .main a:not([class]):hover { color: var(--t-ink); }

/* Shiriti i rrëshqitjes */
body ::-webkit-scrollbar { width: 10px; height: 10px; }
body ::-webkit-scrollbar-thumb { background: #d6cec4; border-radius: 10px; border: 2px solid var(--t-bg); }
body ::-webkit-scrollbar-track { background: transparent; }

/* -------------------------------------------------------------------------
   SIDEBAR
------------------------------------------------------------------------- */

body .sidebar {
    background:
        radial-gradient(120% 60% at 0% 0%, rgba(251, 146, 60, .10), transparent 60%),
        linear-gradient(180deg, var(--t-side-2) 0%, var(--t-side) 100%);
    color: #fff;
    border-right: 1px solid rgba(255, 255, 255, .05);
}

body .sidebar .logo {
    font-family: var(--t-font-head);
    font-weight: 800;
    letter-spacing: -0.02em;
    color: #fff;
    border-bottom: 1px solid rgba(255, 255, 255, .06);
}

body .sidebar .logo-icon {
    width: 36px;
    height: 36px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex: 0 0 36px;
    border-radius: 11px;
    background: var(--t-accent);
    color: var(--t-ink) !important;
    font-size: 17px;
    box-shadow: 0 0 0 4px rgba(251, 146, 60, .14), 0 8px 24px -6px rgba(251, 146, 60, .55);
}

body .sidebar .menu a,
body .sidebar nav a {
    color: var(--t-side-text);
    border-radius: 12px;
    font-weight: 500;
    transition: background .18s ease, color .18s ease, transform .18s ease;
}

body .sidebar .menu a:hover,
body .sidebar nav a:hover {
    background: rgba(255, 255, 255, .06);
    color: #fff;
    transform: translateX(2px);
}

body .sidebar .menu a.active,
body .sidebar nav a.active {
    background: var(--t-accent) !important;
    color: var(--t-ink) !important;
    font-weight: 700;
    box-shadow: 0 10px 24px -12px rgba(251, 146, 60, .8);
}

body .sidebar .menu a.active .menu-icon,
body .sidebar nav a.active .menu-icon {
    color: var(--t-ink);
    filter: grayscale(1) brightness(.2);
}

body .sidebar .menu-icon {
    opacity: .9;
}

body .notification-badge {
    background: #ff5a4e !important;
    color: #fff !important;
    font-weight: 700;
    box-shadow: 0 0 0 3px rgba(255, 90, 78, .18);
}

body .sidebar a.active .notification-badge {
    background: var(--t-accent) !important;
    color: var(--t-primary-text) !important;
    box-shadow: none;
}

body .sidebar .logout {
    border-top: 1px solid rgba(255, 255, 255, .06);
}

body .sidebar .logout a {
    color: #ff8a80;
    border-radius: 12px;
}

body .sidebar .logout a:hover {
    background: rgba(255, 90, 78, .1);
}

body .sidebar-user {
    background: rgba(255, 255, 255, .04) !important;
    border: 1px solid rgba(255, 255, 255, .06);
    border-radius: 14px !important;
}

body .sidebar-user-icon {
    background: linear-gradient(135deg, var(--t-accent), #f97316) !important;
    color: var(--t-ink) !important;
}

body .sidebar-user-name { color: #fff; font-weight: 600; }
body .sidebar-user-role { color: var(--t-accent-2) !important; opacity: .85; }

/* -------------------------------------------------------------------------
   KARTAT
------------------------------------------------------------------------- */

body .card, body .stat, body .summary-card, body .balance-card,
body .filter-card, body .table-card, body .form-card, body .info-box,
body .header-card, body .worker-card, body .section, body .box,
body .login-card, body .notification {
    background: var(--t-surface);
    border: 1px solid var(--t-line) !important;
    border-radius: var(--t-radius) !important;
    box-shadow: var(--t-shadow);
}

body .card:hover, body .stat:hover, body .summary-card:hover {
    box-shadow: var(--t-shadow-lg);
}

/* Kartat statistikore: shirit lime + numra të mëdhenj */
body .cards > .card,
body .stats > .stat,
body .summary-grid > .summary-card,
body .balance-grid > .balance-card {
    position: relative;
    overflow: hidden;
    transition: box-shadow .2s ease, transform .2s ease;
}

body .cards > .card::before,
body .stats > .stat::before,
body .summary-grid > .summary-card::before,
body .balance-grid > .balance-card::before {
    content: "";
    position: absolute;
    left: 0; top: 0; right: 0;
    height: 3px;
    background: linear-gradient(90deg, var(--t-accent), rgba(251, 146, 60, 0));
}

/* Kartela e parë theksohet me portokalli të çelët (jo e zezë) */
body .cards > .card:first-child,
body .stats > .stat:first-child {
    background: linear-gradient(135deg, var(--t-accent-soft), #fff 80%) !important;
    border-color: #fed7aa !important;
}

body .cards > .card:first-child .card-label,
body .cards > .card:first-child .card-info,
body .stats > .stat:first-child .stat-title,
body .stats > .stat:first-child .stat-label,
body .stats > .stat:first-child .stat-sub {
    color: var(--t-accent-ink) !important;
}

body .cards > .card:first-child .card-value,
body .cards > .card:first-child .card-number,
body .stats > .stat:first-child .stat-value {
    color: var(--t-accent-ink-2) !important;
}

body .card-value, body .card-number, body .stat-value,
body .summary-value, body .balance-value, body .info-value.big {
    font-family: var(--t-font-head);
    font-weight: 800;
    letter-spacing: -0.03em;
    color: var(--t-ink);
}

body .card-label, body .stat-title, body .stat-label, body .summary-label,
body .info-label, body .label {
    color: var(--t-muted);
    font-weight: 500;
}

/* Lidhjet e shpejta në panel */
body .quick-link {
    background: var(--t-surface-2) !important;
    border: 1px solid var(--t-line) !important;
    border-radius: 14px !important;
    transition: border-color .18s ease, background .18s ease, transform .18s ease;
}

body .quick-link:hover {
    background: var(--t-accent-soft) !important;
    border-color: var(--t-accent) !important;
    transform: translateY(-2px);
}

body .quick-link-title { color: var(--t-ink) !important; font-weight: 700; }
body .quick-link-text { color: var(--t-muted) !important; }

/* -------------------------------------------------------------------------
   BUTONAT
------------------------------------------------------------------------- */

body .btn, body button, body .action-btn,
body input[type="submit"], body input[type="button"] {
    font-family: var(--t-font);
    font-weight: 600;
    border-radius: 11px;
    transition: background .16s ease, color .16s ease, border-color .16s ease, box-shadow .16s ease, transform .1s ease;
}

body .btn:active, body button:active { transform: translateY(1px); }

body .btn-primary, body .btn-filter, body .btn-save, body .btn-add,
body .btn-send, body .btn-success, body .save,
body button[type="submit"]:not(.t-act):not([class*="danger"]):not([class*="delete"]):not([class*="reset"]):not([class*="secondary"]):not([class*="light"]):not([class*="cancel"]),
body input[type="submit"] {
    background: var(--t-primary) !important;
    color: var(--t-primary-text) !important;
    border: 1px solid var(--t-primary) !important;
    box-shadow: 0 6px 16px -8px rgba(249, 115, 22, .6);
}

body .btn-primary:hover, body .btn-filter:hover, body .btn-save:hover, body .btn-add:hover,
body .btn-send:hover, body .btn-success:hover, body .save:hover,
body button[type="submit"]:not(.t-act):not([class*="danger"]):not([class*="delete"]):not([class*="reset"]):not([class*="secondary"]):not([class*="light"]):not([class*="cancel"]):hover,
body input[type="submit"]:hover {
    background: var(--t-primary-hover) !important;
    color: #fff !important;
    border-color: var(--t-primary-hover) !important;
}

body .btn-secondary, body .btn-light, body .btn-back, body .back,
body .btn-reset, body .cancel, body .btn-view, body .btn-excel, body .btn-pdf {
    background: var(--t-surface) !important;
    color: var(--t-ink-2) !important;
    border: 1px solid var(--t-line-2) !important;
}

body .btn-secondary:hover, body .btn-light:hover, body .btn-back:hover, body .back:hover,
body .btn-reset:hover, body .cancel:hover, body .btn-view:hover, body .btn-excel:hover, body .btn-pdf:hover {
    border-color: var(--t-ink) !important;
    color: var(--t-ink) !important;
}

body .btn-danger, body .btn-delete, body .danger {
    background: var(--t-red-soft) !important;
    color: var(--t-red) !important;
    border: 1px solid #fecaca !important;
}

body .btn-danger:hover, body .btn-delete:hover, body .danger:hover {
    background: var(--t-red) !important;
    color: #fff !important;
    border-color: var(--t-red) !important;
}

body .btn-warning, body .btn-edit, body .action-edit {
    background: var(--t-amber-soft) !important;
    color: var(--t-amber) !important;
    border: 1px solid #fde68a !important;
}

body .btn-warning:hover, body .btn-edit:hover, body .action-edit:hover {
    background: #f59e0b !important;
    color: #fff !important;
    border-color: #f59e0b !important;
}

/* -------------------------------------------------------------------------
   FORMAT
------------------------------------------------------------------------- */

body input[type="text"], body input[type="email"], body input[type="password"],
body input[type="number"], body input[type="date"], body input[type="time"],
body input[type="datetime-local"], body input[type="month"], body input[type="search"],
body input[type="tel"], body input:not([type]), body select, body textarea {
    font-family: var(--t-font);
    background-color: var(--t-surface);
    border: 1px solid var(--t-line-2);
    border-radius: var(--t-radius-sm);
    color: var(--t-ink);
    transition: border-color .15s ease, box-shadow .15s ease;
}

body input:hover, body select:hover, body textarea:hover {
    border-color: #c4bbb0;
}

body input:focus, body select:focus, body textarea:focus {
    outline: none !important;
    border-color: var(--t-ink) !important;
    box-shadow: 0 0 0 4px rgba(251, 146, 60, .35) !important;
}

body input[type="checkbox"], body input[type="radio"] {
    accent-color: #f97316;
}

body label, body .field label, body .form-group label {
    color: var(--t-ink-2);
    font-weight: 600;
}

/* -------------------------------------------------------------------------
   TABELAT
------------------------------------------------------------------------- */

body .table-wrapper {
    border-radius: var(--t-radius);
}

body table th {
    background: var(--t-surface-2) !important;
    color: var(--t-muted) !important;
    font-size: 11.5px;
    font-weight: 700;
    letter-spacing: .06em;
    text-transform: uppercase;
    border-bottom: 1px solid var(--t-line) !important;
}

body table td {
    border-bottom: 1px solid var(--t-line);
}

body table tbody tr {
    transition: background .12s ease;
}

body table tbody tr:hover td {
    background: var(--t-accent-soft);
}

body table tfoot td,
body table tr.total td, body table tr.totali td {
    background: var(--t-surface-2);
    font-weight: 700;
}

/* -------------------------------------------------------------------------
   BADGE / STATUSE / MESAZHE
------------------------------------------------------------------------- */

body .badge, body .status {
    border-radius: 999px;
    font-weight: 600;
    letter-spacing: .01em;
}

body .badge-green, body .status-active, body .status.active, body .status-trajtuar,
body .green, body .status-mbyllur {
    background: var(--t-ok-soft) !important;
    color: var(--t-ok) !important;
    border: 1px solid var(--t-ok-line) !important;
}

body .badge-blue {
    background: #f1ede8 !important;
    color: var(--t-ink-2) !important;
    border: 1px solid var(--t-line-2) !important;
}

body .status-pritje, body .pending {
    background: var(--t-amber-soft) !important;
    color: var(--t-amber) !important;
}

body .status-inactive, body .status.inactive, body .rejected {
    background: var(--t-red-soft) !important;
    color: var(--t-red) !important;
}

body .alert, body .message {
    border-radius: 12px;
}

body .alert-success, body .success, body .message.success {
    background: var(--t-ok-soft) !important;
    color: var(--t-ok) !important;
    border: 1px solid var(--t-ok-line) !important;
}

body .alert-error, body .error, body .message.error {
    background: var(--t-red-soft) !important;
    color: #991b1b !important;
    border: 1px solid #fecaca !important;
}

body .empty {
    color: var(--t-muted);
}

/* Koka e faqes (përdoruesi lart djathtas) */
body .user-box, body .header-right > a, body .header .user,
body .top .user {
    border-radius: 999px !important;
    border: 1px solid var(--t-line) !important;
    background: var(--t-surface) !important;
}

/* Avatarë */
body .avatar, body .user-avatar, body .profile-avatar, body .photo-placeholder {
    background: linear-gradient(135deg, var(--t-ink), #3a2f28) !important;
    color: var(--t-accent) !important;
}

/* Modale */
body .modal-content {
    border-radius: 20px !important;
    box-shadow: 0 30px 80px -20px rgba(0, 0, 0, .45) !important;
}

/* -------------------------------------------------------------------------
   LOGIN
------------------------------------------------------------------------- */

body.t-login {
    background:
        radial-gradient(60% 50% at 15% 10%, rgba(251, 146, 60, .22), transparent 70%),
        radial-gradient(50% 50% at 90% 90%, rgba(249, 115, 22, .18), transparent 70%),
        var(--t-side) !important;
    min-height: 100vh;
}

body.t-login::before {
    content: "";
    position: fixed;
    inset: 0;
    background-image:
        linear-gradient(rgba(255,255,255,.035) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255,255,255,.035) 1px, transparent 1px);
    background-size: 44px 44px;
    mask-image: radial-gradient(70% 70% at 50% 50%, #000 30%, transparent 100%);
    -webkit-mask-image: radial-gradient(70% 70% at 50% 50%, #000 30%, transparent 100%);
    pointer-events: none;
}

body.t-login .login-card,
body.t-login form,
body.t-login .card,
body.t-login .container > div:first-child {
    position: relative;
}

body.t-login .login-card,
body.t-login .card {
    border: 1px solid rgba(255, 255, 255, .08) !important;
    border-radius: 24px !important;
    box-shadow: 0 40px 100px -30px rgba(0, 0, 0, .7), 0 0 0 1px rgba(251, 146, 60, .06) !important;
}

body.t-login .logo, body.t-login .login-logo, body.t-login .logo-box {
    background: var(--t-accent) !important;
    color: var(--t-ink) !important;
    box-shadow: 0 12px 30px -8px rgba(251, 146, 60, .6);
}

/* -------------------------------------------------------------------------
   TERMINALI (kiosk)
------------------------------------------------------------------------- */

body.t-terminal {
    background:
        radial-gradient(50% 40% at 50% 0%, rgba(251, 146, 60, .16), transparent 70%),
        var(--t-side) !important;
    color: #e8ebe6;
}

body.t-terminal h1, body.t-terminal h2 {
    color: #fff !important;
}

body.t-terminal .container > div,
body.t-terminal .terminal,
body.t-terminal .card,
body.t-terminal .box,
body.t-terminal .rfid-box {
    background: var(--t-side-2) !important;
    border: 1px solid rgba(255, 255, 255, .07) !important;
    color: #e8ebe6;
    box-shadow: 0 30px 80px -30px rgba(0, 0, 0, .7) !important;
}

body.t-terminal button {
    background: var(--t-side-2) !important;
    color: #e8ebe6 !important;
    border: 1px solid rgba(255, 255, 255, .1) !important;
    border-radius: 14px !important;
}

body.t-terminal button:hover,
body.t-terminal button.active,
body.t-terminal button.selected {
    background: var(--t-accent) !important;
    color: var(--t-ink) !important;
    border-color: var(--t-accent) !important;
}

body.t-terminal button:hover *, body.t-terminal button.active *, body.t-terminal button.selected * {
    color: var(--t-ink) !important;
}

body.t-terminal kbd, body.t-terminal .key {
    background: rgba(251, 146, 60, .14) !important;
    color: var(--t-accent) !important;
    border-color: rgba(251, 146, 60, .3) !important;
}

body.t-terminal input {
    background: #0a0c0b !important;
    color: var(--t-accent) !important;
    border: 1px solid rgba(251, 146, 60, .35) !important;
    border-radius: 14px !important;
    letter-spacing: .1em;
}

/* -------------------------------------------------------------------------
   PRINTIMI: pa efekte
------------------------------------------------------------------------- */

@media print {
    html body { background: #fff !important; }
    body .card, body .stat, body .table-card { box-shadow: none !important; }
    body .cards > .card:first-child, body .stats > .stat:first-child { background: #fff !important; }
    body .cards > .card:first-child *, body .stats > .stat:first-child * { color: #000 !important; }
}

@media (prefers-reduced-motion: reduce) {
    body * { transition: none !important; }
}

/* Terminali: elementet specifike */
body.t-terminal .terminal { background: var(--t-side-2) !important; border: 1px solid rgba(255,255,255,.07) !important; border-radius: 24px !important; box-shadow: 0 30px 80px -30px rgba(0,0,0,.7) !important; }
body.t-terminal .camera-box { border: 1px solid rgba(255,255,255,.08) !important; border-radius: 18px !important; overflow: hidden; background: #000 !important; }
body.t-terminal .camera-label { background: #0a0c0b !important; color: var(--t-side-text) !important; border-top: 1px solid rgba(255,255,255,.06) !important; }
body.t-terminal .result, body.t-terminal .waiting { color: #e8ebe6 !important; }
body.t-terminal .status-text, body.t-terminal .message, body.t-terminal .info { color: var(--t-side-text) !important; }
body.t-terminal .person-name { color: #fff !important; font-family: var(--t-font-head); }
body.t-terminal .action-btn { background: var(--t-side-2) !important; color: #e8ebe6 !important; border: 1px solid rgba(255,255,255,.1) !important; border-radius: 16px !important; }
body.t-terminal .action-btn:hover { border-color: var(--t-accent) !important; background: #1d221e !important; }
body.t-terminal .action-btn.selected { background: var(--t-accent) !important; color: var(--t-ink) !important; border-color: var(--t-accent) !important; box-shadow: 0 12px 30px -10px rgba(251, 146, 60,.6) !important; }
body.t-terminal .key-label { background: rgba(251, 146, 60,.14) !important; color: var(--t-accent) !important; border-color: rgba(251, 146, 60,.35) !important; }
body.t-terminal .action-btn.selected .key-label { background: #fff !important; color: var(--t-accent-ink) !important; border-color: #fff !important; }
body.t-terminal .rfid-area label { color: var(--t-side-text) !important; }

/* Login: elementet specifike */
body.t-login .login-wrapper { position: relative; z-index: 1; }
body.t-login .login-card .subtitle, body.t-login .login-card .footer { color: var(--t-muted) !important; }
body.t-login .btn-login { background: var(--t-primary) !important; color: var(--t-primary-text) !important; border-radius: 12px !important; font-weight: 700; letter-spacing: .01em; }
body.t-login .btn-login:hover { background: var(--t-accent) !important; color: var(--t-ink) !important; }

/* Faqja hyrëse (index.php në rrënjë) */
body.t-home { background: radial-gradient(60% 50% at 10% 0%, rgba(251, 146, 60,.18), transparent 70%), var(--t-bg) !important; }
body.t-terminal .main { background: transparent !important; border: 1px solid rgba(255,255,255,.06) !important; border-radius: 20px !important; box-shadow: none !important; }
body.t-terminal .result { background: #101311 !important; border-radius: 18px !important; }
body.t-terminal .waiting { color: #fff !important; font-family: var(--t-font-head); font-weight: 700; }

/* Mbetjet blu -> tema */
body .btn-open-send, body .btn-kthim-top, body .btn-read, body .filter.active {
    background: var(--t-primary) !important; color: var(--t-primary-text) !important; border-color: var(--t-primary) !important;
}
body .btn-open-send:hover, body .btn-kthim-top:hover, body .btn-read:hover, body .filter:hover {
    background: var(--t-primary-hover) !important; color: #fff !important; border-color: var(--t-primary-hover) !important;
}
body .send-toggle-wrap { background: var(--t-surface-2) !important; border-color: var(--t-line) !important; }
body .blue, body .unread-status, body .notification-icon { background: var(--t-accent-soft) !important; color: var(--t-accent-ink) !important; }
body .section-header a, body .card-header a, body .table-header a:not([class*="btn"]) { color: var(--t-accent-ink-2) !important; font-weight: 600; }
body .section-header a:hover, body .card-header a:hover { color: var(--t-ink) !important; }
body .sidebar .logout, body .layout { background: transparent; }
body .sidebar .logout { background: transparent !important; }
body .user-info { border-radius: var(--t-radius) !important; }

/* =========================================================================
   TERMINALI — version i çelët (mbishkruan stilet e errëta më sipër)
========================================================================= */
body.t-terminal {
    background:
        radial-gradient(60% 45% at 50% 0%, rgba(251, 146, 60, .18), transparent 70%),
        var(--t-bg) !important;
    color: var(--t-ink) !important;
}
body.t-terminal h1, body.t-terminal h2 { color: var(--t-ink) !important; }
body.t-terminal .terminal {
    background: #fff !important;
    border: 1px solid var(--t-line) !important;
    box-shadow: 0 30px 70px -35px rgba(120, 72, 30, .35) !important;
    color: var(--t-ink) !important;
}
body.t-terminal .main { background: transparent !important; border: 1px solid var(--t-line) !important; }
body.t-terminal .camera-box { border: 1px solid var(--t-line) !important; }
body.t-terminal .camera-label { background: var(--t-surface-2) !important; color: var(--t-muted) !important; border-top: 1px solid var(--t-line) !important; }
body.t-terminal .result { background: var(--t-surface-2) !important; color: var(--t-ink) !important; }
body.t-terminal .waiting, body.t-terminal .person-name { color: var(--t-ink) !important; }
body.t-terminal .status-text, body.t-terminal .message, body.t-terminal .info,
body.t-terminal .rfid-area label { color: var(--t-muted) !important; }
body.t-terminal .action-btn {
    background: #fff !important; color: var(--t-ink-2) !important;
    border: 1px solid var(--t-line-2) !important;
    box-shadow: 0 4px 14px -10px rgba(120, 72, 30, .4) !important;
}
body.t-terminal .action-btn:hover { background: var(--t-accent-soft) !important; border-color: var(--t-accent) !important; }
body.t-terminal .action-btn.selected {
    background: var(--t-accent) !important; color: #1c1917 !important; border-color: var(--t-accent) !important;
    box-shadow: 0 12px 28px -12px rgba(249, 115, 22, .7) !important;
}
body.t-terminal .key-label { background: var(--t-accent-soft) !important; color: var(--t-accent-ink-2) !important; border-color: #fed7aa !important; }
body.t-terminal .action-btn.selected .key-label { background: #fff !important; color: var(--t-accent-ink) !important; border-color: #fff !important; }
body.t-terminal input {
    background: #fff !important; color: var(--t-ink) !important;
    border: 2px solid var(--t-accent-2) !important;
}
body.t-terminal input:focus { border-color: var(--t-accent) !important; box-shadow: 0 0 0 4px rgba(251, 146, 60, .25) !important; }

/* =========================================================================
   TABELAT & BADGE-AT – sistemi i unifikuar (v2)
   Vlen për të gjitha faqet: tabela kompakte, kokë e qetë, badge të vegjël.
   ========================================================================= */

/* --- Koka e tabelës --- */
body table th {
    padding: 9px 14px !important;
    font-size: 10.5px !important;
    font-weight: 700 !important;
    letter-spacing: .07em !important;
    line-height: 1.3 !important;
    color: #8a8178 !important;
    background: #faf8f5 !important;
    border-top: 0 !important;
    border-bottom: 1px solid var(--t-line) !important;
    white-space: nowrap;
    vertical-align: middle;
}

/* --- Qelizat --- */
body table td {
    padding: 10px 14px !important;
    font-size: 13.5px;
    line-height: 1.45;
    color: var(--t-ink-2);
    vertical-align: middle;
    border-bottom: 1px solid #f1ece6 !important;
    font-variant-numeric: tabular-nums;
}
body table td strong, body table td b { color: var(--t-ink); font-weight: 650; }
body table td small { font-size: 11.5px; color: var(--t-muted); }
body table tbody tr:last-child td { border-bottom: 0 !important; }
body table tbody tr:hover td { background: #fffaf5 !important; }

/* Rreshtat e totalit */
body table tfoot td,
body table tr.total td, body table tr.totali td {
    background: #faf8f5 !important;
    color: var(--t-ink) !important;
    font-weight: 700;
    border-top: 1px solid var(--t-line-2) !important;
    border-bottom: 0 !important;
}

/* Kokat e grupeve (ditët) mbeten të qeta edhe kur kalon miu */
body table tr[class*="day-row"] td,
body table tr[class*="day-row"]:hover td {
    padding: 7px 14px !important;
    font-size: 12.5px !important;
    background: #faf8f5 !important;
}

/* --- Badge-at: të vegjël, me pikë ngjyre ---
   Forma dhe madhësia unifikohen; ngjyrat mbeten ato të çdo faqeje. */
body .badge,
body span.status,
body table span[class*="-tag"]:not(.av-tag),
body table span[class*="-badge"],
body table span[class*="-pill"],
body table span[class*="-type"],
body table span.rf-none {
    display: inline-flex !important;
    align-items: center;
    gap: 5px !important;
    height: 20px;
    padding: 0 7px !important;
    border-radius: 6px !important;
    font-size: 11px !important;
    font-weight: 600 !important;
    letter-spacing: 0 !important;
    line-height: 1 !important;
    text-transform: none !important;
    white-space: nowrap;
    vertical-align: middle;
    box-shadow: none !important;
}
body .badge::before,
body span.status::before,
body table span[class*="-badge"]::before,
body table span[class*="-tag"].live::before,
body table span[class*="-tag"].pushim::before,
body table span[class*="-pill"]::before {
    content: "" !important;
    display: block !important;
    width: 6px !important;
    height: 6px !important;
    margin: 0 !important;
    flex: none;
    border-radius: 50%;
    background: currentColor !important;
    box-shadow: none !important;
    opacity: .8;
}

/* Ngjyrat për klasat e përgjithshme (.badge / .status) */
body .badge { background: #f4f1ec; color: #57534e; border: 1px solid #e9e3dc; }
body .badge.green, body .badge-green, body .badge.approved, body .badge.ok,
body span.status.active, body span.status-active, body span.status-closed, body span.status-mbyllur {
    background: #f0fdf4 !important; color: #15803d !important; border: 1px solid #bbf7d0 !important;
}
body .badge.pending, body .badge-yellow, body .badge.yellow,
body span.status-open, body span.status-pritje, body span.status.pending {
    background: #fffbeb !important; color: #b45309 !important; border: 1px solid #fde68a !important;
}
body .badge.rejected, body .badge.red, body .badge-red,
body span.status.inactive, body span.status-inactive {
    background: #fef2f2 !important; color: #b91c1c !important; border: 1px solid #fecaca !important;
}
body .badge.blue, body .badge-blue {
    background: #eff6ff !important; color: #1d4ed8 !important; border: 1px solid #bfdbfe !important;
}
body .badge.gray, body .badge-gray { background: #f4f1ec !important; color: #78716c !important; border: 1px solid #e9e3dc !important; }

/* --- Numrat +/− (shtesë / mangu): pa pikë, kompakt --- */
body table .bo-pm, body table .hd-pm {
    display: inline-block !important;
    height: auto;
    padding: 1px 6px !important;
    margin: 0 !important;
    border-radius: 5px !important;
    font-size: 11.5px !important;
    font-weight: 700 !important;
    line-height: 16px !important;
    border: 0 !important;
}
body table .bo-pm::before, body table .hd-pm::before { content: none !important; }

/* Kartat që mbajnë tabelat */
body .table-card, body [class$="-card"]:has(> table), body [class$="-card"]:has(> div > table) {
    border-radius: 14px;
}

/* --- Butonat brenda tabelave: kompaktë --- */
body table td .btn,
body table td a.btn,
body table td button.btn {
    display: inline-flex !important;
    align-items: center;
    justify-content: center;
    gap: 5px;
    height: 30px !important;
    min-height: 0 !important;
    padding: 0 11px !important;
    border-radius: 8px !important;
    font-size: 12.5px !important;
    font-weight: 600 !important;
    line-height: 1 !important;
    box-shadow: none !important;
    white-space: nowrap;
}


/* =========================================================================
   VEPRIMET NË TABELA — një model i vetëm për të gjithë programin
   (ikona pa kornizë; ngjyrë vetëm kur kalon miu; fshirja me të kuqe)
   ========================================================================= */
body .t-acts { display: inline-flex; align-items: center; justify-content: flex-end; gap: 2px; white-space: nowrap; }
body .t-acts form { display: inline-flex; margin: 0; }
body table tr .t-acts { opacity: .45; transition: opacity .15s; }
body table tr:hover .t-acts, body table tr:focus-within .t-acts { opacity: 1; }
body .t-act,
body button.t-act,
body button[type="submit"].t-act {
    display: inline-flex !important; align-items: center; justify-content: center;
    width: 28px !important; height: 28px !important; min-width: 0 !important; padding: 0 !important; margin: 0 !important;
    border: 0 !important; border-radius: 7px !important;
    background: transparent !important; color: #57534e !important;
    box-shadow: none !important; cursor: pointer; text-decoration: none !important;
    transform: none !important; transition: background .12s, color .12s;
}
body .t-act:hover, body button.t-act:hover { background: #f1ede8 !important; color: var(--t-ink) !important; }
body .t-act.del:hover, body button.t-act.del:hover { background: #fef2f2 !important; color: #dc2626 !important; }
body .t-act.ok, body button.t-act.ok { color: #15803d !important; }
body .t-act.ok:hover, body button.t-act.ok:hover { background: #f0fdf4 !important; color: #15803d !important; }
body .t-act.no, body button.t-act.no { color: #dc2626 !important; }
body .t-act.no:hover, body button.t-act.no:hover { background: #fef2f2 !important; }
body .t-act.hl, body button.t-act.hl { color: var(--t-accent-ink-2) !important; }
body .t-act.hl:hover { background: #fff7ed !important; }
body .t-act svg { width: 15px; height: 15px; flex: none; }
body table tr.t-urgent .t-acts, body .t-acts.t-gjithmone { opacity: 1; }
