/* ==========================================================================
   Timesheet — "Quartz" design system
   Loaded after style.css (the old Star Admin template) and restyles every page:
   the app shell, Bootstrap 4 components and the plugins the pages use.
   Pages and controller scripts keep their markup; only the look changes here.
   ========================================================================== */

:root {
    --brand-50: #eef2ff;
    --brand-100: #e0e7ff;
    --brand-200: #c7d2fe;
    --brand-300: #a5b4fc;
    --brand-400: #818cf8;
    --brand-500: #6366f1;
    --brand-600: #4f46e5;
    --brand-700: #4338ca;
    --brand-800: #3730a3;
    --violet-500: #8b5cf6;
    --violet-600: #7c3aed;
    --cyan-400: #22d3ee;
    --brand-gradient: linear-gradient(135deg, #4f46e5 0%, #7c3aed 100%);

    --ink-900: #0f172a;
    --ink-800: #1e293b;
    --ink-700: #334155;
    --ink-600: #475569;
    --ink-500: #64748b;
    --ink-400: #94a3b8;
    --ink-300: #cbd5e1;
    --line: #e7e9f2;
    --line-strong: #d6dae6;
    --bg: #f4f6fb;
    --surface: #ffffff;
    --surface-2: #f8f9fd;
    --surface-3: #f1f3f9;

    --success-600: #059669;
    --success-500: #10b981;
    --success-50: #ecfdf5;
    --success-100: #d1fae5;
    --warning-700: #b45309;
    --warning-500: #f59e0b;
    --warning-50: #fffbeb;
    --warning-100: #fef3c7;
    --danger-600: #dc2626;
    --danger-500: #ef4444;
    --danger-50: #fef2f2;
    --danger-100: #fee2e2;
    --info-600: #0284c7;
    --info-50: #f0f9ff;

    --radius-sm: 8px;
    --radius: 12px;
    --radius-lg: 16px;
    --radius-xl: 22px;

    --shadow-xs: 0 1px 2px rgba(15, 23, 42, .05);
    --shadow-sm: 0 1px 3px rgba(15, 23, 42, .06), 0 1px 2px rgba(15, 23, 42, .04);
    --shadow-md: 0 10px 30px -12px rgba(15, 23, 42, .14), 0 2px 6px rgba(15, 23, 42, .04);
    --shadow-lg: 0 24px 60px -16px rgba(15, 23, 42, .28);
    --ring: 0 0 0 4px rgba(99, 102, 241, .16);

    --font-sans: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    --font-display: "Plus Jakarta Sans", "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;

    --sb-w: 272px;
    --sb-w-mini: 78px;
    --topbar-h: 68px;
    --sb-bg: #0b1024;
    --sb-bg-2: #121a3d;
    --sb-text: #a3abc9;
    --sb-text-strong: #f4f6ff;
    --sb-muted: #5f6890;
    --sb-hover: rgba(255, 255, 255, .06);
    --sb-line: rgba(255, 255, 255, .07);

    --ease: cubic-bezier(.2, .8, .2, 1);
}

/* ------------------------------------------------------------------ base */

html { -webkit-text-size-adjust: 100%; }

body.app-body,
body.auth-body {
    font-family: var(--font-sans);
    font-size: 14px;
    line-height: 1.55;
    color: var(--ink-700);
    background: var(--bg);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    font-feature-settings: "cv11";
}

.app-body h1, .app-body h2, .app-body h3, .app-body h4, .app-body h5, .app-body h6,
.auth-body h1, .auth-body h2, .auth-body h3 {
    font-family: var(--font-display);
    color: var(--ink-900);
    letter-spacing: -.01em;
}

.app-body a { color: var(--brand-600); transition: color .15s; }
.app-body a:hover { color: var(--brand-700); text-decoration: none; }
.app-body ::selection { background: var(--brand-100); color: var(--brand-800); }

.app-body table, .app-body .kpi .val, .app-body time, .tnum { font-variant-numeric: tabular-nums; }

.app-body ::-webkit-scrollbar { width: 10px; height: 10px; }
.app-body ::-webkit-scrollbar-track { background: transparent; }
.app-body ::-webkit-scrollbar-thumb { background: #cfd4e2; border-radius: 10px; border: 2px solid var(--bg); }
.app-body ::-webkit-scrollbar-thumb:hover { background: #b3bacd; }

.text-muted { color: var(--ink-500) !important; }
.text-primary { color: var(--brand-600) !important; }
.text-dark { color: var(--ink-800) !important; }
.font-weight-medium { font-weight: 600 !important; }

/* MDI 7 renamed this icon; followup.js still uses the old name */
.mdi-format-list-numbers::before { content: "\F027B"; }
/* the old template appends these to checkboxes; native inputs are styled instead */
.input-helper { display: none !important; }

/* ------------------------------------------------------------------ shell */

.app-shell { min-height: 100vh; }

.app-main {
    margin-left: var(--sb-w);
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    transition: margin-left .28s var(--ease);
    background:
        radial-gradient(1200px 380px at 85% -120px, rgba(124, 58, 237, .07), transparent 70%),
        radial-gradient(900px 340px at 10% -140px, rgba(79, 70, 229, .08), transparent 70%),
        var(--bg);
}

/* sidebar */
.app-sidebar {
    position: fixed;
    inset: 0 auto 0 0;
    width: var(--sb-w);
    z-index: 1040;
    display: flex;
    flex-direction: column;
    color: var(--sb-text);
    background:
        radial-gradient(420px 260px at -10% -5%, rgba(99, 102, 241, .32), transparent 70%),
        radial-gradient(360px 300px at 120% 105%, rgba(124, 58, 237, .22), transparent 70%),
        linear-gradient(180deg, var(--sb-bg-2) 0%, var(--sb-bg) 55%);
    border-right: 1px solid rgba(255, 255, 255, .04);
    transition: width .28s var(--ease), transform .28s var(--ease);
    overflow: hidden;
}

.sb-brand {
    display: flex;
    align-items: center;
    gap: 12px;
    height: var(--topbar-h);
    padding: 0 20px;
    flex: none;
    text-decoration: none !important;
}
.sb-logo {
    width: 38px;
    height: 38px;
    border-radius: 11px;
    flex: none;
    display: grid;
    place-items: center;
    background: var(--brand-gradient);
    box-shadow: 0 8px 20px -6px rgba(99, 102, 241, .7), inset 0 1px 0 rgba(255, 255, 255, .25);
    color: #fff;
    font-size: 20px;
}
.sb-brand-text { min-width: 0; line-height: 1.15; white-space: nowrap; }
.sb-brand-name { font-family: var(--font-display); font-weight: 800; font-size: 17px; color: #fff; letter-spacing: -.01em; }
.sb-brand-sub { font-size: 12px; color: var(--sb-text); overflow: hidden; text-overflow: ellipsis; max-width: 170px; display: block; }

.sb-scroll {
    flex: 1;
    overflow-y: auto;
    overflow-x: hidden;
    padding: 6px 14px 18px;
    scrollbar-width: thin;
    scrollbar-color: rgba(255, 255, 255, .12) transparent;
    -webkit-mask-image: linear-gradient(180deg, #000 calc(100% - 28px), transparent);
    mask-image: linear-gradient(180deg, #000 calc(100% - 28px), transparent);
}
.sb-scroll::-webkit-scrollbar { width: 6px; }
.sb-scroll::-webkit-scrollbar-thumb { background: rgba(255, 255, 255, .12); border: 0; }

.sb-section { margin-top: 18px; }
.sb-section:first-child { margin-top: 4px; }
.sb-section:not(:has(.sb-item)) { display: none; }
.sb-label {
    font-size: 10.5px;
    font-weight: 700;
    letter-spacing: .12em;
    text-transform: uppercase;
    color: var(--sb-muted);
    padding: 0 12px 8px;
    white-space: nowrap;
}

.sb-nav, .sb-sub { list-style: none; margin: 0; padding: 0; }
.sb-item { margin: 2px 0; }

.sb-link {
    position: relative;
    display: flex;
    align-items: center;
    gap: 12px;
    height: 42px;
    padding: 0 12px;
    border-radius: 11px;
    color: var(--sb-text) !important;
    font-size: 13.5px;
    font-weight: 500;
    white-space: nowrap;
    text-decoration: none !important;
    transition: background .18s, color .18s;
}
.sb-link:hover { background: var(--sb-hover); color: var(--sb-text-strong) !important; }
.sb-link .sb-ico { font-size: 20px; width: 22px; text-align: center; flex: none; opacity: .9; }
.sb-link .sb-text { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; }
.sb-link .sb-caret { font-size: 18px; opacity: .55; transition: transform .25s var(--ease); }
.sb-link[aria-expanded="true"] .sb-caret { transform: rotate(90deg); opacity: .9; }
.sb-link[aria-expanded="true"] { color: var(--sb-text-strong) !important; }

.sb-item.is-active > .sb-link {
    color: #fff !important;
    background: linear-gradient(135deg, rgba(99, 102, 241, .95), rgba(124, 58, 237, .9));
    box-shadow: 0 10px 24px -10px rgba(99, 102, 241, .85), inset 0 1px 0 rgba(255, 255, 255, .18);
}
.sb-item.is-open > .sb-link:not(:hover) { background: rgba(255, 255, 255, .035); }
.sb-item.is-open.is-active > .sb-link { background: rgba(255, 255, 255, .07); box-shadow: none; }
.sb-item.is-open.is-active > .sb-link .sb-ico { color: var(--brand-300); }

.sb-sub { position: relative; padding: 4px 0 6px 22px; }
.sb-sub::before {
    content: "";
    position: absolute;
    left: 22px;
    top: 6px;
    bottom: 10px;
    width: 1px;
    background: var(--sb-line);
}
.sb-sub .sb-item { margin: 1px 0; }
.sb-sub .sb-link {
    height: 36px;
    padding-left: 22px;
    font-size: 13px;
    font-weight: 500;
    border-radius: 9px;
}
.sb-sub .sb-link::before {
    content: "";
    position: absolute;
    left: -3.5px;
    top: 50%;
    width: 7px;
    height: 7px;
    margin-top: -3.5px;
    border-radius: 50%;
    background: var(--sb-bg);
    border: 1.5px solid var(--sb-muted);
    transition: all .18s;
}
.sb-sub .sb-item.is-active > .sb-link {
    background: rgba(99, 102, 241, .16);
    color: #fff !important;
    box-shadow: none;
}
.sb-sub .sb-item.is-active > .sb-link::before {
    background: var(--brand-400);
    border-color: var(--brand-400);
    box-shadow: 0 0 0 4px rgba(129, 140, 248, .18);
}
/* unread chat messages (controllerjs/chat_badge.js) */
.sb-count {
    flex: none;
    min-width: 20px;
    height: 20px;
    padding: 0 6px;
    border-radius: 999px;
    background: var(--brand-500);
    color: #fff;
    font-size: 11px;
    font-weight: 700;
    line-height: 20px;
    text-align: center;
}
.sb-count[hidden] { display: none; }
.sb-tag {
    font-size: 9.5px;
    font-weight: 700;
    letter-spacing: .06em;
    text-transform: uppercase;
    padding: 2px 7px;
    border-radius: 999px;
    color: #c4b5fd;
    background: rgba(139, 92, 246, .16);
    border: 1px solid rgba(139, 92, 246, .25);
    flex: none;
}

.sb-foot {
    flex: none;
    margin: 0 14px 14px;
    padding: 12px;
    border-radius: 14px;
    background: rgba(255, 255, 255, .04);
    border: 1px solid var(--sb-line);
    display: flex;
    align-items: center;
    gap: 10px;
    white-space: nowrap;
    overflow: hidden;
}
.sb-foot .avatar { flex: none; }
.sb-foot-text { min-width: 0; flex: 1; line-height: 1.25; }
.sb-foot-name { color: #fff; font-weight: 600; font-size: 13px; overflow: hidden; text-overflow: ellipsis; }
.sb-foot-role { font-size: 11.5px; color: var(--sb-text); }
.sb-foot-btn {
    flex: none;
    width: 34px;
    height: 34px;
    border-radius: 10px;
    display: grid;
    place-items: center;
    color: var(--sb-text) !important;
    font-size: 18px;
    transition: background .18s, color .18s;
}
.sb-foot-btn:hover { background: rgba(239, 68, 68, .16); color: #fca5a5 !important; }

/* collapsed ("mini") sidebar on desktop: icons only, expands on hover */
@media (min-width: 992px) {
    body.sb-mini .app-main { margin-left: var(--sb-w-mini); }
    body.sb-mini .app-sidebar:not(:hover) { width: var(--sb-w-mini); }
    body.sb-mini .app-sidebar:not(:hover) .sb-brand-text,
    body.sb-mini .app-sidebar:not(:hover) .sb-text,
    body.sb-mini .app-sidebar:not(:hover) .sb-caret,
    body.sb-mini .app-sidebar:not(:hover) .sb-tag,
    body.sb-mini .app-sidebar:not(:hover) .sb-count,
    body.sb-mini .app-sidebar:not(:hover) .sb-foot-text,
    body.sb-mini .app-sidebar:not(:hover) .sb-foot-btn { opacity: 0; pointer-events: none; }
    body.sb-mini .app-sidebar:not(:hover) .sb-label { opacity: 0; height: 10px; padding: 0; }
    body.sb-mini .app-sidebar:not(:hover) .sb-sub { display: none; }
    body.sb-mini .app-sidebar:not(:hover) .sb-foot { padding: 8px; margin: 0 12px 14px; }
    body.sb-mini .app-sidebar:hover { box-shadow: 20px 0 60px -20px rgba(2, 6, 23, .55); }
}

/* backdrop for the off-canvas sidebar on small screens */
.app-backdrop {
    position: fixed;
    inset: 0;
    z-index: 1035;
    background: rgba(15, 23, 42, .45);
    backdrop-filter: blur(2px);
    opacity: 0;
    visibility: hidden;
    transition: opacity .25s, visibility .25s;
}

/* topbar */
.app-topbar {
    position: sticky;
    top: 0;
    z-index: 1020;
    height: var(--topbar-h);
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 0 28px;
    background: rgba(244, 246, 251, .78);
    backdrop-filter: saturate(180%) blur(14px);
    -webkit-backdrop-filter: saturate(180%) blur(14px);
    border-bottom: 1px solid transparent;
    transition: border-color .2s, background .2s, box-shadow .2s;
}
.app-topbar.is-scrolled {
    background: rgba(255, 255, 255, .86);
    border-bottom-color: var(--line);
    box-shadow: 0 6px 20px -16px rgba(15, 23, 42, .35);
}

.tb-btn {
    width: 40px;
    height: 40px;
    flex: none;
    display: inline-grid;
    place-items: center;
    border-radius: 11px;
    border: 1px solid var(--line);
    background: var(--surface);
    color: var(--ink-600) !important;
    font-size: 20px;
    cursor: pointer;
    box-shadow: var(--shadow-xs);
    transition: all .18s;
    position: relative;
    padding: 0;
}
.tb-btn:hover { color: var(--brand-600) !important; border-color: var(--brand-200); background: var(--brand-50); }
.tb-btn:focus { outline: none; box-shadow: var(--ring); }
.tb-btn.tb-menu-mobile { display: none; }

.tb-crumbs {
    display: flex;
    align-items: center;
    gap: 6px;
    min-width: 0;
    font-size: 13px;
    color: var(--ink-500);
    white-space: nowrap;
}
.tb-crumbs .mdi { font-size: 16px; color: var(--ink-300); }
.tb-crumbs .tb-crumb-group { overflow: hidden; text-overflow: ellipsis; }
.tb-crumbs .tb-crumb-page {
    color: var(--ink-900);
    font-weight: 600;
    font-family: var(--font-display);
    font-size: 15px;
    overflow: hidden;
    text-overflow: ellipsis;
}

.tb-spacer { flex: 1; }

.tb-search {
    display: flex;
    align-items: center;
    gap: 10px;
    width: 280px;
    height: 40px;
    padding: 0 8px 0 14px;
    border-radius: 11px;
    border: 1px solid var(--line);
    background: var(--surface);
    color: var(--ink-400);
    font-size: 13.5px;
    cursor: pointer;
    box-shadow: var(--shadow-xs);
    transition: all .18s;
}
.tb-search:hover { border-color: var(--brand-200); color: var(--ink-500); }
.tb-search:focus { outline: none; box-shadow: var(--ring); }
.tb-search .mdi { font-size: 19px; }
.tb-search span { flex: 1; text-align: left; }
kbd, .kbd {
    font-family: var(--font-sans);
    font-size: 11px;
    font-weight: 600;
    color: var(--ink-500);
    background: var(--surface-3);
    border: 1px solid var(--line);
    border-bottom-width: 2px;
    border-radius: 6px;
    padding: 1px 6px;
    box-shadow: none;
}

.tb-clock {
    display: flex;
    align-items: center;
    gap: 8px;
    height: 40px;
    padding: 0 14px;
    border-radius: 11px;
    background: var(--surface);
    border: 1px solid var(--line);
    color: var(--ink-700);
    font-size: 13px;
    font-weight: 600;
    white-space: nowrap;
    box-shadow: var(--shadow-xs);
    font-variant-numeric: tabular-nums;
}
.tb-clock .dot { width: 8px; height: 8px; border-radius: 50%; background: var(--success-500); box-shadow: 0 0 0 3px var(--success-100); }
.tb-clock .tb-clock-date { color: var(--ink-500); font-weight: 500; }

.tb-badge {
    position: absolute;
    top: -6px;
    right: -6px;
    min-width: 20px;
    height: 20px;
    padding: 0 5px;
    border-radius: 999px;
    background: linear-gradient(135deg, #f43f5e, #e11d48);
    color: #fff;
    font-size: 11px;
    font-weight: 700;
    line-height: 20px;
    text-align: center;
    border: 2px solid var(--bg);
    box-shadow: 0 4px 10px -2px rgba(225, 29, 72, .5);
}
.tb-badge:empty, .tb-badge.is-zero { display: none; }

.tb-user {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 4px 10px 4px 4px;
    border-radius: 999px;
    border: 1px solid var(--line);
    background: var(--surface);
    cursor: pointer;
    box-shadow: var(--shadow-xs);
    transition: all .18s;
    text-decoration: none !important;
}
.tb-user:hover { border-color: var(--brand-200); }
.tb-user-name { font-size: 13px; font-weight: 600; color: var(--ink-800); max-width: 140px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; line-height: 1.15; }
.tb-user-role { display: block; font-size: 11px; color: var(--ink-500); font-weight: 500; }
.tb-user .mdi-chevron-down { color: var(--ink-400); font-size: 18px; }

.avatar {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    display: inline-grid;
    place-items: center;
    flex: none;
    font-family: var(--font-display);
    font-weight: 700;
    font-size: 13px;
    color: #fff;
    background: var(--brand-gradient);
    box-shadow: inset 0 0 0 2px rgba(255, 255, 255, .25);
    letter-spacing: .02em;
    text-transform: uppercase;
}
.avatar.avatar-lg { width: 48px; height: 48px; font-size: 16px; }

/* page content */
.app-content.content-wrapper {
    flex: 1;
    width: 100%;
    max-width: 1600px;
    margin: 0 auto;
    padding: 24px 28px 8px;
    background: transparent;
}
.app-page > .row.p-3,
.app-page > .row.p-2 { padding: 0 !important; }
.app-page > .row.p-3 > [class*="col-"] > .card,
.app-page > .row > .col-lg-12 > .card { margin-bottom: 24px; }

/* pages that render straight into the content area (calendars) get a surface */
.app-page:not(:has(.card)):not(:has(.ax)) {
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-sm);
    padding: 22px;
    margin-bottom: 24px;
}

.app-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 8px;
    padding: 18px 28px 24px;
    max-width: 1600px;
    width: 100%;
    margin: 0 auto;
    color: var(--ink-400);
    font-size: 12.5px;
}
.app-footer a { color: var(--ink-500) !important; font-weight: 500; }
.app-footer a:hover { color: var(--brand-600) !important; }

/* ------------------------------------------------------------------ loader */

#loader {
    position: fixed !important;
    inset: 0 !important;
    width: auto !important;
    height: auto !important;
    margin: 0 !important;
    border: 0 !important;
    border-radius: 0 !important;
    animation: none !important;
    z-index: 2000 !important;
    pointer-events: none;
    background: transparent;
}
#loader::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    height: 3px;
    width: 40%;
    border-radius: 0 3px 3px 0;
    background: linear-gradient(90deg, var(--brand-500), var(--violet-500), var(--cyan-400));
    box-shadow: 0 0 12px rgba(99, 102, 241, .6);
    animation: ts-progress 1.1s var(--ease) infinite;
}
#loader::after {
    content: "";
    position: absolute;
    left: 50%;
    top: 50%;
    width: 46px;
    height: 46px;
    margin: -23px 0 0 -23px;
    border-radius: 50%;
    border: 3px solid var(--brand-100);
    border-top-color: var(--brand-600);
    border-right-color: var(--violet-500);
    background: rgba(255, 255, 255, .9);
    box-shadow: var(--shadow-md), 0 0 0 8px rgba(255, 255, 255, .7);
    animation: ts-spin .8s linear infinite;
}
@keyframes ts-progress { 0% { transform: translateX(-100%); } 100% { transform: translateX(260%); } }
@keyframes ts-spin { to { transform: rotate(360deg); } }

/* ------------------------------------------------------------------ cards */

.app-body .card {
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-sm);
    overflow: visible;
}
.app-body .card .card {
    box-shadow: none;
    border-radius: var(--radius);
}
.app-body .card > .card-title,
.app-body .card > .card-title.text-center {
    display: flex;
    align-items: center;
    gap: 12px;
    margin: 0 !important;
    padding: 18px 22px !important;
    text-align: left !important;
    font-family: var(--font-display);
    font-size: 16px;
    font-weight: 700;
    color: var(--ink-900);
    text-transform: none;
    letter-spacing: -.01em;
    border-bottom: 1px solid var(--line);
    background: linear-gradient(180deg, #fff, var(--surface-2));
    border-radius: var(--radius-lg) var(--radius-lg) 0 0;
}
.app-body .card > .card-title::before {
    content: "";
    width: 4px;
    height: 18px;
    border-radius: 4px;
    background: var(--brand-gradient);
    flex: none;
}
.app-body .card > .card-body,
.app-body .card > .card-body.p-2 {
    padding: 22px !important;
}
.app-body .card-body > p:first-child:has(> .btn) {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 18px;
}
.app-body .card-body > p:first-child:has(> .btn) > .btn { margin: 0 !important; }

/* label/value lines such as "Name : ..." on the timesheet page */
.app-body .card-body strong { color: var(--ink-800); font-weight: 600; }
.app-body h5 { font-size: 15px; font-weight: 700; }

/* ------------------------------------------------------------------ buttons */

.app-body .btn,
.auth-body .btn {
    font-family: var(--font-sans);
    font-weight: 600;
    font-size: 13.5px;
    line-height: 1.2;
    border-radius: 10px;
    padding: 10px 18px;
    border: 1px solid transparent;
    box-shadow: var(--shadow-xs);
    transition: transform .12s, box-shadow .18s, background .18s, border-color .18s, color .18s;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 7px;
    text-transform: none;
    letter-spacing: 0;
}
.app-body input.btn, .auth-body input.btn { display: inline-block; }
.app-body .btn .mdi { font-size: 17px; line-height: 1; margin: 0; }
.app-body .btn:focus, .app-body .btn.focus { box-shadow: var(--ring) !important; outline: none; }
.app-body .btn:active { transform: translateY(1px); }
.app-body .btn-sm { padding: 7px 13px; font-size: 12.5px; border-radius: 9px; }
.app-body .btn-lg { padding: 13px 22px; font-size: 15px; }

.app-body .btn-primary,
.app-body .btn-success,
.app-body .form-control.btn-success,
.app-body .form-control.btn-primary,
.auth-body .btn-primary {
    color: #fff !important;
    background: var(--brand-gradient);
    border-color: transparent;
    box-shadow: 0 6px 16px -6px rgba(79, 70, 229, .55), inset 0 1px 0 rgba(255, 255, 255, .15);
}
.app-body .btn-primary:hover,
.app-body .btn-success:hover,
.app-body .form-control.btn-success:hover,
.auth-body .btn-primary:hover {
    background: linear-gradient(135deg, #4338ca 0%, #6d28d9 100%);
    box-shadow: 0 10px 22px -8px rgba(79, 70, 229, .7), inset 0 1px 0 rgba(255, 255, 255, .15);
    color: #fff !important;
}
.app-body .btn-danger {
    color: #fff !important;
    background: linear-gradient(135deg, #ef4444, #dc2626);
    border-color: transparent;
    box-shadow: 0 6px 16px -6px rgba(220, 38, 38, .5);
}
.app-body .btn-danger:hover { background: linear-gradient(135deg, #dc2626, #b91c1c); }
.app-body .btn-warning { color: #78350f !important; background: #fbbf24; border-color: transparent; }
.app-body .btn-info { color: #fff !important; background: #0ea5e9; border-color: transparent; }
.app-body .btn-secondary,
.app-body .btn-light,
.app-body .btn-outline-secondary,
.app-body .btn-outline-primary {
    color: var(--ink-700) !important;
    background: var(--surface);
    border-color: var(--line-strong);
}
.app-body .btn-secondary:hover,
.app-body .btn-light:hover,
.app-body .btn-outline-secondary:hover,
.app-body .btn-outline-primary:hover {
    color: var(--brand-700) !important;
    border-color: var(--brand-300);
    background: var(--brand-50);
}
.app-body .btn-outline-primary { color: var(--brand-700) !important; border-color: var(--brand-200); }
.app-body .btn-link { box-shadow: none; color: var(--brand-600); }

/* secondary page actions next to the main "Add" button */
.app-body a.btn-success[href*="import"],
.app-body a.btn-primary[href*="import"],
.app-body a.btn-success[href*="calendar"],
.app-body a.btn-primary[href*="calendar"] {
    color: var(--ink-700) !important;
    background: var(--surface);
    border-color: var(--line-strong);
    box-shadow: var(--shadow-xs);
}
.app-body a.btn-success[href*="import"]:hover,
.app-body a.btn-primary[href*="import"]:hover,
.app-body a.btn-success[href*="calendar"]:hover,
.app-body a.btn-primary[href*="calendar"]:hover {
    color: var(--brand-700) !important;
    background: var(--brand-50);
    border-color: var(--brand-300);
}

/* a submit rendered as <input class="form-control btn-success"> */
.app-body .form-control.btn-success,
.app-body .form-control.btn-primary,
.app-body .form-control.btn {
    height: 44px;
    font-weight: 600;
    cursor: pointer;
    border-radius: 10px;
}

/* ------------------------------------------------------------------ forms */

.app-body label,
.auth-body label {
    font-size: 13px;
    font-weight: 600;
    color: var(--ink-700);
    margin-bottom: 6px;
}
.app-body .form-group { margin-bottom: 18px; }

.app-body .form-control,
.auth-body .form-control,
.app-body .dataTables_wrapper .dataTables_filter input,
.app-body .dataTables_wrapper .dataTables_length select {
    height: 44px;
    padding: 10px 14px;
    font-family: var(--font-sans);
    font-size: 14px;
    color: var(--ink-900);
    background-color: var(--surface);
    border: 1px solid var(--line-strong);
    border-radius: 10px;
    box-shadow: var(--shadow-xs);
    transition: border-color .15s, box-shadow .15s, background-color .15s;
}
.app-body textarea.form-control { height: auto; min-height: 96px; line-height: 1.5; resize: vertical; }
.app-body select.form-control[multiple] { height: auto; min-height: 120px; }
.app-body .form-control::placeholder, .auth-body .form-control::placeholder { color: var(--ink-400); }
.app-body .form-control:hover { border-color: #c4cad9; }
.app-body .form-control:focus,
.auth-body .form-control:focus {
    border-color: var(--brand-400);
    box-shadow: var(--ring);
    outline: none;
    background-color: #fff;
}
.app-body .form-control:disabled,
.app-body .form-control[readonly] { background-color: var(--surface-3); color: var(--ink-500); }
.app-body .form-control-sm { height: 36px; padding: 6px 11px; font-size: 13px; border-radius: 9px; }

.app-body select.form-control:not([multiple]),
.app-body .dataTables_wrapper .dataTables_length select {
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
    padding-right: 38px;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='20' height='20' viewBox='0 0 24 24' fill='none' stroke='%2364748b' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 12px center;
    background-size: 16px;
}
.app-body input[type="time"].form-control,
.app-body input[type="date"].form-control,
.app-body input[type="month"].form-control { font-variant-numeric: tabular-nums; }
.app-body input[type="file"].form-control { padding: 9px 12px; height: auto; }

.app-body input[type="checkbox"],
.app-body input[type="radio"],
.auth-body input[type="checkbox"] {
    accent-color: var(--brand-600);
    width: 17px;
    height: 17px;
    vertical-align: -3px;
    cursor: pointer;
}
.app-body .form-check { padding-left: 0; display: flex; align-items: center; gap: 8px; }
.app-body .form-check .form-check-input { position: static; margin: 0; }
.app-body .form-check .form-check-label { margin: 0; font-weight: 500; }

.app-body .input-group-text {
    background: var(--surface-2);
    border: 1px solid var(--line-strong);
    color: var(--ink-500);
    border-radius: 10px;
}

.app-body .form-inline { gap: 10px; }
.app-body .form-inline label { margin-bottom: 0; }

.app-body .invalid-feedback, .app-body .text-danger { color: var(--danger-600) !important; }

/* ------------------------------------------------------------------ tables */

.app-body .table {
    color: var(--ink-700);
    font-size: 13.5px;
    margin-bottom: 0;
    border-collapse: separate;
    border-spacing: 0;
    background: var(--surface);
    border: 1px solid var(--line) !important;
    border-radius: var(--radius);
}
.app-body .table-responsive-lg,
.app-body .table-responsive,
.app-body .table-responsive-sm { border-radius: var(--radius); }
.app-body .table-wrap { margin-bottom: 4px; }
.app-body .table-wrap > .table { width: 100%; }

.app-body .table > thead > tr > th,
.app-body .table > thead > tr > td,
.app-body .table > thead th {
    background: var(--surface-2) !important;
    color: var(--ink-500) !important;
    font-size: 11.5px;
    font-weight: 700;
    letter-spacing: .06em;
    text-transform: uppercase;
    padding: 12px 16px;
    border: 0 !important;
    border-bottom: 1px solid var(--line) !important;
    vertical-align: middle;
    white-space: nowrap;
}
.app-body .table > thead > tr:first-child > *:first-child { border-top-left-radius: calc(var(--radius) - 1px); }
.app-body .table > thead > tr:first-child > *:last-child { border-top-right-radius: calc(var(--radius) - 1px); }
.app-body .table thead tr[class*="bg-"],
.app-body .table thead tr.table-active { background: transparent !important; }

.app-body .table td,
.app-body .table th {
    padding: 13px 16px;
    border: 0 !important;
    border-top: 1px solid var(--line) !important;
    vertical-align: middle;
    font-size: 13.5px;
    line-height: 1.5;
}
/* the old template forces nowrap on every cell, which pushes long comments off the card */
.app-body .table tbody td { white-space: normal; }
.app-body .table tbody td.text-nowrap { white-space: nowrap; }
.app-body .table tbody tr:first-child > td,
.app-body .table tbody tr:first-child > th { border-top: 0 !important; }
.app-body .table thead + tbody tr:first-child > td { border-top: 0 !important; }
.app-body .table-sm td, .app-body .table-sm th { padding: 8px 10px; }
.app-body .table-sm > thead > tr > td, .app-body .table-sm > thead > tr > th { padding: 9px 10px; }

.app-body .table-striped tbody tr:nth-of-type(odd) { background: transparent; }
.app-body .table tbody tr { transition: background .12s; }
.app-body .table tbody tr:hover > td { background: rgba(99, 102, 241, .035); }
.app-body .table tbody tr:last-child > td:first-child { border-bottom-left-radius: calc(var(--radius) - 1px); }
.app-body .table tbody tr:last-child > td:last-child { border-bottom-right-radius: calc(var(--radius) - 1px); }
.app-body .table tbody td:first-child { color: var(--ink-500); }
.app-body .table tbody td:nth-child(2) { color: var(--ink-900); font-weight: 500; }

/* rows the scripts tint with inline colours (approved / rejected / priority) */
.app-body tr[style*="BEF7C7" i] > td,
.app-body tr[style*="dff0d8" i] > td { background: var(--success-50) !important; }
.app-body tr[style*="BEF7C7" i] > td:first-child,
.app-body tr[style*="dff0d8" i] > td:first-child { box-shadow: inset 3px 0 0 var(--success-500); }
.app-body tr[style*="F2B1B1" i] > td,
.app-body tr[style*="f2dede" i] > td { background: var(--danger-50) !important; }
.app-body tr[style*="F2B1B1" i] > td:first-child,
.app-body tr[style*="f2dede" i] > td:first-child { box-shadow: inset 3px 0 0 var(--danger-500); }
.app-body tr[style*="fcf8e3" i] > td { background: var(--warning-50) !important; }
.app-body tr[style*="fcf8e3" i] > td:first-child { box-shadow: inset 3px 0 0 var(--warning-500); }
.app-body tr[style] { background: transparent !important; }

/* status words in cells, tagged by theme.js */
.status-chip {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 3px 10px;
    border-radius: 999px;
    font-size: 12px;
    font-weight: 600;
    text-transform: capitalize;
    white-space: nowrap;
    background: var(--surface-3);
    color: var(--ink-600);
}
.status-chip::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
.status-chip.is-success { background: var(--success-50); color: var(--success-600); }
.status-chip.is-warning { background: var(--warning-50); color: var(--warning-700); }
.status-chip.is-danger { background: var(--danger-50); color: var(--danger-600); }
.status-chip.is-info { background: var(--brand-50); color: var(--brand-700); }

/* action cells ("Edit | Delete", icon links), tagged by theme.js */
.app-body td.cell-actions { white-space: nowrap; font-size: 0 !important; }
.app-body td.cell-actions > * { font-size: 13px; }
.app-body .act {
    display: inline-flex !important;
    align-items: center;
    gap: 6px;
    height: 32px;
    padding: 0 11px;
    margin: 2px 6px 2px 0;
    border-radius: 9px;
    border: 1px solid var(--line);
    background: var(--surface);
    color: var(--ink-700) !important;
    font-size: 12.5px !important;
    font-weight: 600;
    line-height: 1 !important;
    text-decoration: none !important;
    vertical-align: middle;
    cursor: pointer;
    transition: all .15s;
}
.app-body .act .mdi,
.app-body .act i { font-size: 16px !important; line-height: 1 !important; margin: 0 !important; width: auto !important; }
.app-body .act.is-icon { width: 32px; padding: 0; justify-content: center; }
.app-body .act.is-icon .act-label { display: none; }
.app-body .act:hover { border-color: var(--brand-200); background: var(--brand-50); color: var(--brand-700) !important; }
.app-body .act.act-danger { color: var(--danger-600) !important; }
.app-body .act.act-danger:hover { border-color: #fecaca; background: var(--danger-50); color: var(--danger-600) !important; }
.app-body .act.act-success { color: var(--success-600) !important; }
.app-body .act.act-success:hover { border-color: #a7f3d0; background: var(--success-50); color: var(--success-600) !important; }

/* totals rows the scripts append without a class */
.app-body .table tbody tr:last-child > td[colspan] { font-weight: 700; color: var(--ink-900); }

/* the freeze-table plugin (attendance sheets) */
.app-body .freeze-table,
.app-body .freeze-table2 { border-radius: var(--radius); border: 1px solid var(--line); background: var(--surface); }
.app-body .freeze-table .table,
.app-body .freeze-table2 .table { border: 0 !important; border-radius: 0; }
.app-body .clone-head-table-wrap .table,
.app-body .clone-column-table-wrap .table { background: var(--surface); }

.app-body .wrapword { white-space: normal !important; word-break: normal !important; overflow-wrap: anywhere; text-align: left !important; line-height: 1.6; color: var(--ink-600); }
.app-body .wrapword h5,
.app-body .wrapword h6 { margin: 0 0 6px; font-size: 15px; font-weight: 700; color: var(--ink-900); }
.app-body .wrapword h5 + br,
.app-body .wrapword h6 + br,
.app-body .wrapword br + br { display: none; }
.app-body .wrapword .text-dark { margin-bottom: 4px; }

/* DataTables */
.app-body .dataTables_wrapper { font-size: 13px; color: var(--ink-500); }
.app-body .dataTables_wrapper .dataTables_filter input { height: 38px; margin-left: 8px; }
.app-body .dataTables_wrapper .dataTables_length select { height: 38px; padding-right: 32px; margin: 0 6px; }
.app-body .dataTables_wrapper .dataTables_info { padding-top: 14px; }
.app-body .dataTables_wrapper .dataTables_paginate { padding-top: 10px; }
.app-body .dataTables_wrapper .dataTables_paginate .paginate_button {
    border-radius: 9px !important;
    border: 1px solid transparent !important;
    padding: 6px 12px !important;
    color: var(--ink-600) !important;
    background: none !important;
}
.app-body .dataTables_wrapper .dataTables_paginate .paginate_button:hover { background: var(--brand-50) !important; color: var(--brand-700) !important; }
.app-body .dataTables_wrapper .dataTables_paginate .paginate_button.current {
    background: var(--brand-gradient) !important;
    color: #fff !important;
    box-shadow: 0 6px 14px -6px rgba(79, 70, 229, .6);
}
.app-body table.dataTable { border-collapse: separate !important; }
.app-body table.dataTable thead th { background-image: none; }

/* ------------------------------------------------------------------ alerts, badges */

.app-body .alert {
    border: 1px solid transparent;
    border-radius: var(--radius);
    padding: 14px 44px 14px 16px;
    font-size: 13.5px;
    position: relative;
    box-shadow: var(--shadow-xs);
}
.app-body .alert .close { position: absolute; top: 10px; right: 14px; padding: 0; opacity: .5; text-shadow: none; font-weight: 400; font-size: 22px; }
.app-body .alert-success { background: var(--success-50); border-color: #a7f3d0; color: #065f46; }
.app-body .alert-danger { background: var(--danger-50); border-color: #fecaca; color: #991b1b; }
.app-body .alert-warning { background: var(--warning-50); border-color: #fde68a; color: #92400e; }
.app-body .alert-info { background: var(--info-50); border-color: #bae6fd; color: #075985; }

.app-body .badge {
    font-weight: 700;
    font-size: 11px;
    padding: 4px 9px;
    border-radius: 999px;
    letter-spacing: .02em;
}
.app-body .badge-warning { background: var(--warning-100); color: var(--warning-700); }
.app-body .badge-success { background: var(--success-100); color: var(--success-600); }
.app-body .badge-danger { background: var(--danger-100); color: var(--danger-600); }
.app-body .badge-primary, .app-body .badge-info { background: var(--brand-100); color: var(--brand-700); }

/* ------------------------------------------------------------------ dropdowns */

.app-body .dropdown-menu {
    border: 1px solid var(--line);
    border-radius: 14px;
    box-shadow: var(--shadow-lg);
    padding: 6px;
    font-size: 13.5px;
    margin-top: 10px;
    animation: ts-pop .16s var(--ease);
}
@keyframes ts-pop { from { opacity: 0; transform: translateY(-4px) scale(.98); } to { opacity: 1; transform: none; } }
.app-body .dropdown-item {
    border-radius: 9px;
    padding: 9px 12px;
    color: var(--ink-700);
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 10px;
}
.app-body .dropdown-item .mdi { font-size: 18px; color: var(--ink-400); }
.app-body .dropdown-item:hover, .app-body .dropdown-item:focus { background: var(--surface-3); color: var(--ink-900); }
.app-body .dropdown-item.text-danger:hover { background: var(--danger-50); }
.app-body .dropdown-item.text-danger .mdi { color: var(--danger-500); }
.app-body .dropdown-divider { margin: 6px 4px; border-top-color: var(--line); }
.app-body .dropdown-header { padding: 10px 12px 6px; font-size: 11px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--ink-400); }

.tb-user-menu { min-width: 250px; }
.tb-user-card { display: flex; align-items: center; gap: 12px; padding: 10px 12px 12px; }
.tb-user-card .nm { font-weight: 700; color: var(--ink-900); font-size: 14px; line-height: 1.2; }
.tb-user-card .em { font-size: 12px; color: var(--ink-500); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 170px; }

/* notification dropdown (items are built by notification.js) */
.app-body #notify-div {
    width: 360px;
    max-width: calc(100vw - 24px);
    max-height: 440px;
    overflow-y: auto;
    padding: 6px;
}
.app-body #notify-div > .dropdown-item:first-child {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 12px;
    font-weight: 600;
    color: var(--ink-900);
}
.app-body #notify-div > .dropdown-item:first-child p { font-size: 13px; color: var(--ink-600); }
.app-body #notify-div .badge { float: none !important; }
.app-body #notify-div .dropdown-divider:last-child { display: none; }
.app-body .preview-item { display: flex; align-items: center; gap: 12px; padding: 10px 12px; white-space: normal; }
.app-body .preview-thumbnail { flex: none; }
.app-body .preview-icon {
    width: 36px;
    height: 36px;
    border-radius: 11px;
    display: grid;
    place-items: center;
    font-size: 18px;
}
.app-body .preview-icon.bg-danger { background: var(--danger-100) !important; color: var(--danger-600); }
.app-body .preview-icon.bg-warning { background: var(--warning-100) !important; color: var(--warning-700); }
.app-body .preview-icon.bg-success { background: var(--success-100) !important; color: var(--success-600); }
.app-body .preview-subject { margin: 0; font-size: 13.5px; font-weight: 600 !important; color: var(--ink-800) !important; font-family: var(--font-sans); line-height: 1.35; }

/* ------------------------------------------------------------------ modals */

.app-body .modal-backdrop.show { opacity: 1; background: rgba(15, 23, 42, .45); backdrop-filter: blur(3px); }
.app-body .modal-content {
    border: 0;
    border-radius: var(--radius-xl);
    box-shadow: var(--shadow-lg);
    overflow: hidden;
}
.app-body .modal-header { padding: 20px 24px 12px; border-bottom: 0; align-items: center; }
.app-body .modal-title { font-family: var(--font-display); font-weight: 700; font-size: 18px; color: var(--ink-900); }
.app-body .modal-header .close {
    width: 34px;
    height: 34px;
    margin: -4px -6px -4px auto;
    padding: 0;
    border-radius: 10px;
    opacity: .6;
    text-shadow: none;
    font-weight: 400;
}
.app-body .modal-header .close:hover { background: var(--surface-3); opacity: 1; }
.app-body .modal-body { padding: 12px 24px 24px; }
.app-body .modal-body > .row > .col-lg-5 { flex: 0 0 100%; max-width: 100%; }
.app-body .modal-footer { border-top: 1px solid var(--line); padding: 14px 24px; }

/* ------------------------------------------------------------------ misc bootstrap */

.app-body .nav-tabs { border-bottom: 1px solid var(--line); gap: 4px; }
.app-body .nav-tabs .nav-link { border: 0; border-bottom: 2px solid transparent; color: var(--ink-500); font-weight: 600; padding: 10px 14px; border-radius: 0; }
.app-body .nav-tabs .nav-link.active { color: var(--brand-700); border-bottom-color: var(--brand-600); background: none; }
.app-body .pagination .page-link { border-radius: 9px !important; margin: 0 2px; border-color: var(--line); color: var(--ink-600); }
.app-body .pagination .page-item.active .page-link { background: var(--brand-600); border-color: var(--brand-600); }
.app-body .progress { height: 8px; border-radius: 999px; background: var(--surface-3); }
.app-body .progress-bar { background: var(--brand-gradient); border-radius: 999px; }
.app-body .tooltip-inner { background: var(--ink-900); border-radius: 8px; padding: 6px 10px; font-size: 12px; }
.app-body hr { border-top-color: var(--line); }

/* ------------------------------------------------------------------ plugins */

/* SweetAlert 2.x ("swal") */
.swal-overlay { background-color: rgba(15, 23, 42, .5); backdrop-filter: blur(3px); }
.swal-modal {
    font-family: var(--font-sans);
    border-radius: var(--radius-xl);
    box-shadow: var(--shadow-lg);
    padding: 8px 6px 4px;
    width: 420px;
}
.swal-title { font-family: var(--font-display); font-size: 20px; font-weight: 700; color: var(--ink-900); padding: 10px 24px 0; line-height: 1.35; }
.swal-title:not(:last-child) { margin-bottom: 6px; }
.swal-text { color: var(--ink-600); font-size: 14px; text-align: center; }
.swal-footer { text-align: center; padding: 16px 20px 20px; margin-top: 6px; }
.swal-button {
    font-family: var(--font-sans);
    border-radius: 10px;
    padding: 11px 26px;
    font-weight: 600;
    font-size: 14px;
    background: var(--brand-gradient);
    box-shadow: 0 6px 16px -6px rgba(79, 70, 229, .55);
}
.swal-button:not([disabled]):hover { background: linear-gradient(135deg, #4338ca 0%, #6d28d9 100%); }
.swal-button:focus { box-shadow: var(--ring); }
.swal-button--cancel { background: var(--surface-3); color: var(--ink-700); box-shadow: none; }
.swal-button--cancel:not([disabled]):hover { background: var(--line); }
.swal-button--danger { background: linear-gradient(135deg, #ef4444, #dc2626); }
.swal-icon--success__ring { border-color: rgba(16, 185, 129, .25); }
.swal-icon--success__line { background-color: var(--success-500); }
.swal-icon--error { border-color: var(--danger-500); }
.swal-icon--error__line { background-color: var(--danger-500); }
.swal-icon--warning { border-color: var(--warning-500); }
.swal-icon--warning__body, .swal-icon--warning__dot { background-color: var(--warning-500); }

/* jQuery UI datepicker (inline on "Register time per day") */
.app-body .ui-datepicker {
    width: 100%;
    max-width: 340px;
    padding: 14px;
    border: 1px solid var(--line) !important;
    border-radius: var(--radius-lg);
    background: var(--surface);
    box-shadow: var(--shadow-md);
    font-family: var(--font-sans);
}
.app-body .ui-datepicker .ui-datepicker-header {
    border: 0;
    background: none;
    padding: 4px 0 10px;
}
.app-body .ui-datepicker .ui-datepicker-title { font-family: var(--font-display); font-weight: 700; font-size: 15px; color: var(--ink-900); line-height: 32px; }
.app-body .ui-datepicker .ui-datepicker-prev,
.app-body .ui-datepicker .ui-datepicker-next {
    top: 4px;
    width: 32px;
    height: 32px;
    border-radius: 9px;
    border: 1px solid var(--line) !important;
    background: var(--surface) !important;
    cursor: pointer;
}
.app-body .ui-datepicker .ui-datepicker-prev { left: 0; }
.app-body .ui-datepicker .ui-datepicker-next { right: 0; }
.app-body .ui-datepicker .ui-datepicker-prev-hover,
.app-body .ui-datepicker .ui-datepicker-next-hover { background: var(--brand-50) !important; border-color: var(--brand-200) !important; }
.app-body .ui-datepicker .ui-datepicker-prev span,
.app-body .ui-datepicker .ui-datepicker-next span { background: none !important; text-indent: 0; overflow: hidden; width: 16px; height: 16px; margin: -8px 0 0 -8px; font-size: 0; }
.app-body .ui-datepicker .ui-datepicker-prev span::before,
.app-body .ui-datepicker .ui-datepicker-next span::before {
    font: normal normal normal 16px/1 "Material Design Icons";
    color: var(--ink-600);
    content: "\F0141";
}
.app-body .ui-datepicker .ui-datepicker-prev span::before { content: "\F0141"; }
.app-body .ui-datepicker .ui-datepicker-next span::before { content: "\F0142"; }
.app-body .ui-datepicker table { font-size: 13px; margin: 0; border-collapse: separate; border-spacing: 3px; }
.app-body .ui-datepicker th { color: var(--ink-400); font-weight: 600; font-size: 11.5px; text-transform: uppercase; padding: 6px 0; }
.app-body .ui-datepicker td { padding: 0; }
.app-body .ui-datepicker td a,
.app-body .ui-datepicker td span {
    text-align: center !important;
    border: 0 !important;
    background: none !important;
    border-radius: 9px;
    padding: 0 !important;
    height: 36px;
    line-height: 36px;
    color: var(--ink-700) !important;
    font-weight: 500;
    transition: background .12s, color .12s;
}
.app-body .ui-datepicker td a:hover { background: var(--brand-50) !important; color: var(--brand-700) !important; }
.app-body .ui-datepicker td.ui-datepicker-today a { box-shadow: inset 0 0 0 1.5px var(--brand-300); color: var(--brand-700) !important; font-weight: 700; }
.app-body .ui-datepicker td.ui-datepicker-current-day a,
.app-body .ui-datepicker td a.ui-state-active {
    background: var(--brand-gradient) !important;
    color: #fff !important;
    font-weight: 700;
    box-shadow: 0 6px 14px -6px rgba(79, 70, 229, .7);
}
.app-body .ui-datepicker td.ui-datepicker-week-end a { color: var(--ink-500) !important; }
.app-body .ui-datepicker-inline { display: block; }
.app-body .ui-widget.ui-widget-content { border: 1px solid var(--line); }

/* select2 */
.app-body .select2-container--default .select2-selection--single,
.app-body .select2-container--default .select2-selection--multiple {
    min-height: 44px;
    border: 1px solid var(--line-strong);
    border-radius: 10px;
    box-shadow: var(--shadow-xs);
}
.app-body .select2-container--default .select2-selection--single .select2-selection__rendered { line-height: 42px; padding-left: 14px; color: var(--ink-900); }
.app-body .select2-container--default .select2-selection--single .select2-selection__arrow { height: 42px; right: 8px; }
.app-body .select2-container--default.select2-container--focus .select2-selection--multiple,
.app-body .select2-container--default.select2-container--open .select2-selection--single { border-color: var(--brand-400); box-shadow: var(--ring); }
.app-body .select2-container--default .select2-selection--multiple .select2-selection__choice {
    background: var(--brand-50);
    border: 1px solid var(--brand-200);
    color: var(--brand-800);
    border-radius: 7px;
    padding: 2px 8px;
    margin-top: 7px;
    font-size: 12.5px;
    font-weight: 600;
}
.app-body .select2-dropdown { border: 1px solid var(--line); border-radius: 12px; box-shadow: var(--shadow-lg); overflow: hidden; }
.app-body .select2-container--default .select2-results__option--highlighted[aria-selected] { background: var(--brand-600); }
.app-body .select2-search--dropdown .select2-search__field { border-radius: 8px; border: 1px solid var(--line-strong); padding: 7px 10px; }

/* daterangepicker */
.daterangepicker { font-family: var(--font-sans); border: 1px solid var(--line); border-radius: 14px; box-shadow: var(--shadow-lg); }
.daterangepicker td.active, .daterangepicker td.active:hover { background: var(--brand-600); }
.daterangepicker td.in-range { background: var(--brand-50); color: var(--brand-800); }
.daterangepicker .ranges li.active { background: var(--brand-600); }

/* FullCalendar 5 */
.app-body .fc {
    --fc-border-color: var(--line);
    --fc-button-bg-color: var(--surface);
    --fc-button-border-color: var(--line-strong);
    --fc-button-text-color: var(--ink-700);
    --fc-button-hover-bg-color: var(--brand-50);
    --fc-button-hover-border-color: var(--brand-200);
    --fc-button-active-bg-color: var(--brand-600);
    --fc-button-active-border-color: var(--brand-600);
    --fc-today-bg-color: rgba(99, 102, 241, .07);
    --fc-neutral-bg-color: var(--surface-2);
    --fc-page-bg-color: var(--surface);
    --fc-event-border-color: transparent;
    font-size: 13px;
    color: var(--ink-700);
}
.app-body .fc .fc-toolbar-title { font-family: var(--font-display); font-size: 20px; font-weight: 700; color: var(--ink-900); }
.app-body .fc .fc-button {
    border-radius: 9px !important;
    padding: 7px 13px;
    font-weight: 600;
    font-size: 13px;
    text-transform: capitalize;
    box-shadow: none !important;
}
.app-body .fc .fc-button-group { gap: 4px; }
.app-body .fc .fc-button-primary:not(:disabled).fc-button-active,
.app-body .fc .fc-button-primary:not(:disabled):active { color: #fff; }
.app-body .fc .fc-button-primary:hover { color: var(--brand-700); }
.app-body .fc .fc-button-primary:disabled { opacity: .5; }
.app-body .fc .fc-scrollgrid { border-radius: var(--radius); overflow: hidden; }
.app-body .fc .fc-col-header-cell { background: var(--surface-2); }
.app-body .fc .fc-col-header-cell-cushion { color: var(--ink-500); font-size: 11.5px; font-weight: 700; text-transform: uppercase; letter-spacing: .06em; padding: 10px 4px; }
.app-body .fc .fc-daygrid-day-number { color: var(--ink-600); font-weight: 600; padding: 8px 10px; }
.app-body .fc .fc-day-today .fc-daygrid-day-number {
    background: var(--brand-gradient);
    color: #fff;
    border-radius: 8px;
    margin: 4px;
    padding: 3px 8px;
}
.app-body .fc .fc-daygrid-event { border-radius: 6px; padding: 2px 6px; font-weight: 600; font-size: 12px; }
.app-body .fc .fc-h-event { border: 0; }
.app-body .fc .fc-daygrid-dot-event:hover { background: var(--surface-3); }
.app-body .fc-theme-standard .fc-list { border-radius: var(--radius); overflow: hidden; }

/* ------------------------------------------------------------------ command palette */

.cmdk {
    position: fixed;
    inset: 0;
    z-index: 3000;
    display: none;
    align-items: flex-start;
    justify-content: center;
    padding: 12vh 16px 16px;
    background: rgba(15, 23, 42, .45);
    backdrop-filter: blur(4px);
}
.cmdk.is-open { display: flex; animation: ts-fade .15s ease; }
@keyframes ts-fade { from { opacity: 0; } to { opacity: 1; } }
.cmdk-box {
    width: 100%;
    max-width: 600px;
    background: var(--surface);
    border-radius: 18px;
    box-shadow: var(--shadow-lg), 0 0 0 1px rgba(15, 23, 42, .06);
    overflow: hidden;
    animation: ts-pop .18s var(--ease);
}
.cmdk-input-wrap { display: flex; align-items: center; gap: 12px; padding: 0 18px; border-bottom: 1px solid var(--line); }
.cmdk-input-wrap .mdi { font-size: 22px; color: var(--ink-400); }
.cmdk-input {
    flex: 1;
    height: 58px;
    border: 0;
    outline: none;
    font-size: 16px;
    font-family: var(--font-sans);
    color: var(--ink-900);
    background: transparent;
}
.cmdk-list { max-height: 380px; overflow-y: auto; padding: 8px; margin: 0; list-style: none; }
.cmdk-group { padding: 10px 12px 4px; font-size: 11px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--ink-400); }
.cmdk-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 12px;
    border-radius: 11px;
    color: var(--ink-700) !important;
    font-weight: 500;
    cursor: pointer;
    text-decoration: none !important;
}
.cmdk-item .ico {
    width: 32px;
    height: 32px;
    border-radius: 9px;
    display: grid;
    place-items: center;
    background: var(--surface-3);
    color: var(--ink-500);
    font-size: 17px;
    flex: none;
}
.cmdk-item .lbl { flex: 1; min-width: 0; }
.cmdk-item .grp { font-size: 12px; color: var(--ink-400); }
.cmdk-item .mdi-keyboard-return { opacity: 0; color: var(--brand-600); font-size: 16px; }
.cmdk-item.is-sel { background: var(--brand-50); color: var(--brand-800) !important; }
.cmdk-item.is-sel .ico { background: var(--brand-gradient); color: #fff; }
.cmdk-item.is-sel .mdi-keyboard-return { opacity: 1; }
.cmdk-empty { padding: 34px 16px; text-align: center; color: var(--ink-400); }
.cmdk-foot { display: flex; gap: 16px; padding: 10px 18px; border-top: 1px solid var(--line); background: var(--surface-2); font-size: 12px; color: var(--ink-500); }
.cmdk-foot span { display: inline-flex; align-items: center; gap: 6px; }

/* ------------------------------------------------------------------ dashboard hero */

.dash-hero {
    position: relative;
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 24px;
    align-items: center;
    padding: 30px 32px;
    margin-bottom: 22px;
    border-radius: var(--radius-xl);
    color: #e0e7ff;
    overflow: hidden;
    background:
        radial-gradient(600px 300px at 100% 0%, rgba(34, 211, 238, .28), transparent 60%),
        radial-gradient(500px 340px at 0% 120%, rgba(139, 92, 246, .55), transparent 60%),
        linear-gradient(120deg, #312e81 0%, #4338ca 45%, #6d28d9 100%);
    box-shadow: 0 24px 50px -24px rgba(67, 56, 202, .7);
}
.dash-hero::before {
    content: "";
    position: absolute;
    inset: 0;
    background-image:
        linear-gradient(rgba(255, 255, 255, .06) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 255, 255, .06) 1px, transparent 1px);
    background-size: 34px 34px;
    -webkit-mask-image: radial-gradient(ellipse at 70% 30%, #000 10%, transparent 70%);
    mask-image: radial-gradient(ellipse at 70% 30%, #000 10%, transparent 70%);
    pointer-events: none;
}
.dash-hero > * { position: relative; }
.dash-hero__date {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-size: 12.5px;
    font-weight: 600;
    letter-spacing: .02em;
    color: #c7d2fe;
    background: rgba(255, 255, 255, .1);
    border: 1px solid rgba(255, 255, 255, .14);
    padding: 5px 12px;
    border-radius: 999px;
    margin-bottom: 14px;
}
.dash-hero__title {
    font-family: var(--font-display);
    font-size: 30px;
    font-weight: 800;
    color: #fff !important;
    margin: 0 0 6px;
    letter-spacing: -.02em;
    line-height: 1.15;
}
.dash-hero .page-sub,
.ax .dash-hero .page-sub { color: #c7d2fe !important; font-size: 14.5px; margin: 0; }
.dash-hero__actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 20px; }
.app-body .dash-hero .btn-hero {
    color: var(--brand-800) !important;
    background: #fff;
    border: 0;
    box-shadow: 0 10px 24px -10px rgba(15, 23, 42, .5);
}
.app-body .dash-hero .btn-hero:hover { background: var(--brand-50); }
.app-body .dash-hero .btn-hero-ghost {
    color: #fff !important;
    background: rgba(255, 255, 255, .1);
    border: 1px solid rgba(255, 255, 255, .22);
    box-shadow: none;
}
.app-body .dash-hero .btn-hero-ghost:hover { background: rgba(255, 255, 255, .18); }

.dash-hero__side { display: flex; flex-direction: column; align-items: stretch; gap: 12px; min-width: 300px; }
.dash-clock {
    padding: 16px 20px;
    border-radius: var(--radius-lg);
    background: rgba(255, 255, 255, .1);
    border: 1px solid rgba(255, 255, 255, .16);
    backdrop-filter: blur(8px);
    text-align: left;
}
.dash-clock__label { font-size: 11px; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; color: #a5b4fc; }
.dash-clock__time {
    font-family: var(--font-display);
    font-size: 40px;
    font-weight: 800;
    color: #fff;
    line-height: 1.1;
    letter-spacing: -.02em;
    font-variant-numeric: tabular-nums;
}
.dash-clock__time small { font-size: 18px; font-weight: 700; color: #c7d2fe; margin-left: 4px; }

/* the punch box sits inside the hero */
.ax .dash-hero .panel.punch {
    background: #fff;
    border: 0;
    border-radius: var(--radius-lg);
    box-shadow: 0 16px 30px -18px rgba(15, 23, 42, .6);
    padding: 12px 12px 12px 16px;
    justify-content: space-between;
}
.ax .dash-hero .punch .btn { padding: 10px 16px; }

/* ------------------------------------------------------------------ login */

body.auth-body { background: #0b1024; min-height: 100vh; }
.auth {
    min-height: 100vh;
    display: grid;
    grid-template-columns: minmax(0, 1.08fr) minmax(0, 1fr);
}
.auth-visual {
    position: relative;
    overflow: hidden;
    padding: 44px 56px;
    display: flex;
    flex-direction: column;
    color: #c7d2fe;
    background:
        radial-gradient(700px 500px at 10% 0%, rgba(99, 102, 241, .55), transparent 60%),
        radial-gradient(600px 500px at 100% 100%, rgba(124, 58, 237, .5), transparent 60%),
        radial-gradient(400px 300px at 90% 10%, rgba(34, 211, 238, .22), transparent 60%),
        #0b1024;
}
.auth-visual::before {
    content: "";
    position: absolute;
    inset: 0;
    background-image:
        linear-gradient(rgba(255, 255, 255, .05) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 255, 255, .05) 1px, transparent 1px);
    background-size: 44px 44px;
    -webkit-mask-image: radial-gradient(ellipse at 50% 40%, #000 20%, transparent 75%);
    mask-image: radial-gradient(ellipse at 50% 40%, #000 20%, transparent 75%);
}
.auth-visual > * { position: relative; }
.auth-brand { display: flex; align-items: center; gap: 12px; color: #fff; font-family: var(--font-display); font-weight: 800; font-size: 19px; }
.auth-brand .sb-logo { width: 42px; height: 42px; font-size: 22px; }
.auth-brand small { display: block; font-family: var(--font-sans); font-weight: 500; font-size: 12px; color: #a5b4fc; }
.auth-copy { max-width: 520px; }
.auth-eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 5px 12px;
    border-radius: 999px;
    background: rgba(255, 255, 255, .08);
    border: 1px solid rgba(255, 255, 255, .14);
    color: #c7d2fe;
    font-size: 12.5px;
    font-weight: 600;
}
.auth-eyebrow .dot { width: 7px; height: 7px; border-radius: 50%; background: #34d399; box-shadow: 0 0 0 4px rgba(52, 211, 153, .2); }
.auth-copy h1 {
    font-size: 46px;
    line-height: 1.08;
    font-weight: 800;
    color: #fff;
    letter-spacing: -.03em;
    margin: 18px 0 14px;
}
.auth-copy h1 span {
    background: linear-gradient(90deg, #a5b4fc, #c4b5fd 40%, #67e8f9);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}
.auth-copy p { font-size: 16px; color: #a5b4fc; margin: 0; max-width: 460px; }
.auth-features { display: flex; flex-wrap: wrap; gap: 10px; margin: 26px 0 0; padding: 0; list-style: none; }
.auth-features li {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 14px;
    border-radius: 12px;
    background: rgba(255, 255, 255, .06);
    border: 1px solid rgba(255, 255, 255, .1);
    color: #e0e7ff;
    font-size: 13px;
    font-weight: 500;
}
.auth-features .mdi { color: #a5b4fc; font-size: 17px; }

/* the floating product preview on the login page */
.auth-mock { position: relative; height: 300px; margin: auto 0 44px; max-width: 540px; width: 100%; }
.mock-card {
    position: absolute;
    border-radius: 18px;
    background: rgba(255, 255, 255, .96);
    box-shadow: 0 30px 60px -20px rgba(2, 6, 23, .7);
    color: var(--ink-700);
    padding: 18px;
}
.mock-main { left: 0; top: 0; width: 340px; animation: ts-float 7s ease-in-out infinite; }
.mock-side { right: 0; top: 96px; width: 210px; animation: ts-float 7s ease-in-out -3.5s infinite; }
.mock-chip { left: 28px; bottom: -8px; padding: 12px 16px; display: flex; align-items: center; gap: 10px; animation: ts-float 6s ease-in-out -2s infinite; }
@keyframes ts-float { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-10px); } }
.mock-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 12px; }
.mock-head .t { font-family: var(--font-display); font-weight: 700; color: var(--ink-900); font-size: 14px; }
.mock-head .s { font-size: 11px; color: var(--ink-400); }
.mock-big { font-family: var(--font-display); font-weight: 800; font-size: 30px; color: var(--ink-900); letter-spacing: -.02em; line-height: 1; }
.mock-big small { font-size: 13px; color: var(--success-600); font-weight: 700; margin-left: 6px; }
.mock-bars { display: flex; align-items: flex-end; gap: 8px; height: 74px; margin-top: 16px; }
.mock-bars span { flex: 1; border-radius: 6px 6px 3px 3px; background: var(--brand-100); }
.mock-bars span.on { background: var(--brand-gradient); }
.mock-days { display: flex; gap: 8px; margin-top: 6px; }
.mock-days span { flex: 1; text-align: center; font-size: 10px; color: var(--ink-400); font-weight: 600; }
.mock-row { display: flex; align-items: center; gap: 10px; padding: 7px 0; font-size: 12px; }
.mock-row + .mock-row { border-top: 1px solid var(--line); }
.mock-row i { width: 26px; height: 26px; border-radius: 8px; display: grid; place-items: center; font-size: 14px; font-style: normal; }
.mock-row b { margin-left: auto; color: var(--ink-900); font-weight: 700; }
.mock-chip .avatar { width: 34px; height: 34px; }
.mock-chip .t { font-weight: 700; color: var(--ink-900); font-size: 13px; line-height: 1.2; }
.mock-chip .s { font-size: 11.5px; color: var(--success-600); font-weight: 600; }
.auth-visual-foot { display: flex; gap: 22px; color: #818cf8; font-size: 12.5px; margin-top: auto; padding-top: 28px; }

.auth-form-side {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    padding: 40px 24px;
    background: var(--bg);
    position: relative;
}
.auth-card { width: 100%; max-width: 420px; }
.auth-card .auth-brand { display: none; color: var(--ink-900); margin-bottom: 26px; }
.auth-card .auth-brand small { color: var(--ink-500); }
.auth-card h2 { font-size: 30px; font-weight: 800; margin: 0 0 6px; letter-spacing: -.02em; }
.auth-card .lead { font-size: 15px; color: var(--ink-500); margin: 0 0 28px; }
.auth-field { margin-bottom: 16px; }
.auth-field label { display: flex; justify-content: space-between; }
.auth-input { position: relative; }
.auth-input > .mdi:first-child {
    position: absolute;
    left: 14px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 20px;
    color: var(--ink-400);
    pointer-events: none;
    transition: color .15s;
}
.auth-body .auth-input .form-control { height: 50px; padding-left: 44px; padding-right: 44px; font-size: 15px; border-radius: 12px; }
.auth-input:focus-within > .mdi:first-child { color: var(--brand-600); }
.auth-eye {
    position: absolute;
    right: 6px;
    top: 50%;
    transform: translateY(-50%);
    width: 38px;
    height: 38px;
    border: 0;
    border-radius: 9px;
    background: none;
    color: var(--ink-400);
    font-size: 20px;
    cursor: pointer;
    display: grid;
    place-items: center;
}
.auth-eye:hover { color: var(--ink-700); background: var(--surface-3); }
.auth-row { display: flex; align-items: center; justify-content: space-between; margin: 4px 0 22px; }
.auth-check { display: inline-flex !important; align-items: center; gap: 9px; font-weight: 500 !important; color: var(--ink-600) !important; cursor: pointer; margin: 0 !important; }
.auth-body .btn-auth {
    width: 100%;
    height: 52px;
    font-size: 15px;
    border-radius: 12px;
    gap: 10px;
}
.auth-body .btn-auth .mdi { font-size: 20px; transition: transform .2s; }
.auth-body .btn-auth:hover .mdi { transform: translateX(3px); }
.auth-alert { margin-top: 18px; border-radius: 12px; font-size: 13.5px; background: var(--danger-50); border: 1px solid #fecaca; color: #991b1b; padding: 12px 14px; }
.auth-alert ul { margin: 0; padding-left: 18px; }
.auth-secure { display: flex; align-items: center; justify-content: center; gap: 8px; margin-top: 26px; color: var(--ink-400); font-size: 12.5px; }
.auth-secure .mdi { color: var(--success-500); font-size: 16px; }
/* forgot password: link on the sign-in form, "back to sign in", and the "check your email" note */
.auth-link { font-size: 13.5px; font-weight: 600; color: var(--brand-600) !important; text-decoration: none !important; }
.auth-link:hover { color: var(--brand-700) !important; text-decoration: underline !important; }
.auth-back { display: inline-flex; align-items: center; gap: 6px; margin-top: 22px; }
.auth-note { display: flex; gap: 12px; border-radius: 12px; font-size: 13.5px; line-height: 1.5; background: var(--success-50); border: 1px solid var(--success-100); color: var(--ink-700); padding: 14px 16px; }
.auth-note[hidden] { display: none; }
.auth-note .mdi { color: var(--success-600); font-size: 22px; line-height: 1; }
.auth-note b { display: block; color: var(--ink-900); font-size: 14.5px; margin-bottom: 2px; }
/* free-trial sign-up (site/register, site/verified) */
.auth-card-wide { max-width: 520px; }
.auth-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 0 14px; }
.auth-switch { margin-top: 22px; font-size: 14px; color: var(--ink-500); }
.auth-gap { margin-top: 20px; }
.auth-check span { line-height: 1.45; }
@media (max-width: 560px) { .auth-grid { grid-template-columns: 1fr; } }

/* ------------------------------------------------------------------ billing page */
.billing { max-width: 1040px; }
.billing-status .card-body { padding: 26px 28px; }
.billing-status h2 { font: 800 24px/1.2 var(--font-display); color: var(--ink-900); margin: 10px 0 8px; }
.billing-status p { color: var(--ink-600); margin: 0; max-width: 720px; }
.billing-badge { display: inline-block; font-size: 12px; font-weight: 700; padding: 4px 10px; border-radius: 999px; background: var(--surface-3); color: var(--ink-600); }
.billing-badge:empty { display: none; }
.billing-badge.is-trial { background: var(--brand-50); color: var(--brand-700); }
.billing-badge.is-active { background: var(--success-50); color: var(--success-600); }
.billing-badge.is-ended { background: var(--danger-50); color: var(--danger-600); }
.billing-actions:not(:empty) { margin-top: 18px; }
.billing-plans-head { display: flex; align-items: center; justify-content: space-between; gap: 16px; margin: 28px 0 6px; flex-wrap: wrap; }
.billing-plans-head h3 { font: 800 20px var(--font-display); color: var(--ink-900); margin: 0; }
.billing-toggle { display: inline-flex; padding: 4px; background: var(--surface-3); border-radius: 999px; }
.billing-toggle button { border: 0; background: none; font-weight: 600; font-size: 13.5px; color: var(--ink-600); padding: 7px 16px; border-radius: 999px; }
.billing-toggle button.on { background: #fff; color: var(--ink-900); box-shadow: var(--shadow-xs); }
.billing-note { color: var(--ink-500); font-size: 14px; margin: 0 0 14px; }
.billing-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 16px; }
.billing-plan .card-body { display: flex; flex-direction: column; padding: 22px; }
.billing-plan h4 { font: 800 19px var(--font-display); color: var(--ink-900); margin: 0; }
.billing-tagline { color: var(--ink-500); font-size: 13.5px; margin: 2px 0 14px; }
.billing-price b { font: 800 30px var(--font-display); color: var(--ink-900); }
.billing-price span { color: var(--ink-500); }
.billing-plan ul { list-style: none; padding: 0; margin: 14px 0 20px; flex: 1; display: grid; gap: 7px; font-size: 14px; }
.billing-plan li::before { content: "\2713"; color: var(--success-600); font-weight: 700; margin-right: 8px; }
.billing-plan.is-off { opacity: .6; }
.billing-fine { margin-top: 18px; font-size: 13px; color: var(--ink-500); }
.billing-coupon { margin: 4px 0 16px; display: grid; gap: 10px; }
.billing-offers { display: grid; gap: 8px; }
.billing-offers:empty { display: none; }
.billing-offer { display: flex; align-items: center; gap: 12px; background: var(--brand-50); border: 1px dashed var(--brand-300); border-radius: 12px; padding: 10px 14px; font-size: 14px; color: var(--ink-700); }
.billing-offer > div { flex: 1; }
.billing-offer.is-applied { border-style: solid; border-color: var(--success-500); background: var(--success-50); }
.billing-offer-code { font: 700 13px ui-monospace, SFMono-Regular, Menlo, monospace; background: var(--brand-600); color: #fff; padding: 3px 8px; border-radius: 7px; white-space: nowrap; }
.billing-offer-desc { font-size: 13px; color: var(--ink-500); }
.billing-code { display: flex; gap: 8px; max-width: 420px; }
.billing-code .form-control { text-transform: uppercase; }
.billing-applied { display: flex; align-items: center; gap: 6px; font-size: 14px; font-weight: 600; color: var(--success-600); }
.billing-applied .btn-link { padding: 0 4px; font-size: 13px; }
.billing-price s { color: var(--ink-400); font-size: 17px; margin-right: 2px; }
.billing-plan.has-offer { border-color: var(--success-500); }
.billing-offer-note { font-size: 13px; font-weight: 600; color: var(--success-600); margin: 6px 0 0; }
.billing-offer-note.is-muted { color: var(--ink-400); font-weight: 500; }
.auth-copyright { position: absolute; bottom: 20px; left: 0; right: 0; text-align: center; color: var(--ink-400); font-size: 12px; }

/* ------------------------------------------------------------------ responsive */

@media (max-width: 1199.98px) {
    .tb-search { width: 220px; }
    .tb-clock .tb-clock-date { display: none; }
    .auth { grid-template-columns: 1fr 1fr; }
    .auth-copy h1 { font-size: 38px; }
    .mock-main { width: 300px; }
    .mock-side { width: 190px; }
    .mock-chip { left: 150px; }
}

@media (max-width: 991.98px) {
    .app-main { margin-left: 0 !important; }
    .app-sidebar { transform: translateX(-100%); width: var(--sb-w) !important; box-shadow: none; }
    body.sb-open .app-sidebar { transform: none; box-shadow: 30px 0 80px -20px rgba(2, 6, 23, .6); }
    body.sb-open .app-backdrop { opacity: 1; visibility: visible; }
    body.sb-open { overflow: hidden; }
    .tb-btn.tb-menu-desktop { display: none; }
    .tb-btn.tb-menu-mobile { display: inline-grid; }
    .app-topbar { padding: 0 18px; gap: 10px; }
    .tb-search { width: 40px; padding: 0; justify-content: center; }
    .tb-search span, .tb-search kbd { display: none; }
    .tb-clock { display: none; }
    .app-content.content-wrapper { padding: 18px 18px 8px; }
    .app-footer { padding: 14px 18px 20px; }
    .dash-hero { grid-template-columns: 1fr; padding: 26px 24px; }
    .dash-hero__side { min-width: 0; flex-direction: row; flex-wrap: wrap; }
    .dash-hero__side > * { flex: 1 1 240px; }

    .auth { grid-template-columns: 1fr; }
    .auth-visual { display: none; }
    .auth-card .auth-brand { display: flex; }
}

@media (max-width: 767.98px) {
    :root { --topbar-h: 60px; }
    .app-topbar { padding: 0 12px; }
    .tb-user { padding: 3px; }
    .tb-user-name, .tb-user .mdi-chevron-down { display: none; }
    .tb-crumbs .tb-crumb-group, .tb-crumbs > .mdi { display: none; }
    .app-content.content-wrapper { padding: 14px 12px 4px; }
    .app-body .card > .card-title { padding: 15px 16px !important; font-size: 15px; }
    .app-body .card > .card-body,
    .app-body .card > .card-body.p-2 { padding: 16px !important; }
    .app-page:not(:has(.card)):not(:has(.ax)) { padding: 14px; }
    .app-body .table td, .app-body .table th { padding: 11px 12px; }
    .dash-hero { padding: 22px 18px; border-radius: 18px; }
    .dash-hero__title { font-size: 24px; }
    .dash-clock__time { font-size: 32px; }
    .dash-hero__actions .btn { flex: 1 1 auto; }
    .ax .dash-hero .panel.punch { flex: 1 1 100%; }
    .app-body .fc .fc-toolbar { flex-direction: column; gap: 10px; align-items: stretch; }
    .app-body .fc .fc-toolbar-chunk { display: flex; justify-content: center; flex-wrap: wrap; gap: 4px; }
    .auth-card h2 { font-size: 26px; }
}

/* dashboard / analytics wrappers carry their own p-3 */
.app-page > .ax.p-3 { padding: 0 !important; }

/* "Register time per day": the name / period / finished lines become a summary strip */
.app-body #registryFinishPost {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 22px;
}
.app-body #registryFinishPost > p {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin: 0;
    padding: 9px 14px;
    border-radius: 11px;
    background: var(--surface-2);
    border: 1px solid var(--line);
    font-size: 13.5px;
    color: var(--ink-900);
    font-weight: 600;
}
.app-body #registryFinishPost > p strong { color: var(--ink-500); font-weight: 500; }
.app-body #registryFinishPost > p:last-of-type { background: var(--brand-50); border-color: var(--brand-100); }

/* spacing fixes for a few page patterns */
.app-body .freeze-table,
.app-body .freeze-table2 { margin-top: 18px; }
.app-body label > input[type="checkbox"],
.app-body label > input[type="radio"] { margin-right: 8px; }
.app-body .card.m-2 { margin: 0 0 24px !important; }
.ax .filters .form-control,
.ax .filters .form-control-sm { height: 38px; }

/* calendar legend: coloured-dot links become pills */
.app-page .row:has(> .col-sm-4 > a > .mdi-checkbox-blank-circle) > .col-sm-8 { display: none; }
.app-page .col-sm-4:has(> a > .mdi-checkbox-blank-circle) {
    flex: 0 0 100%;
    max-width: 100%;
    display: flex;
    flex-wrap: wrap;
    gap: 6px 8px;
    margin-bottom: 16px;
}
.app-page .col-sm-4:has(> a > .mdi-checkbox-blank-circle) > br { display: none; }
.app-page .col-sm-4 > a:has(> .mdi-checkbox-blank-circle) {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 5px 12px 5px 9px;
    border-radius: 999px;
    background: var(--surface-2);
    border: 1px solid var(--line);
    color: var(--ink-600) !important;
    font-size: 12px;
    font-weight: 600;
}
.app-page .col-sm-4 > a > .mdi-checkbox-blank-circle { font-size: 11px; }

/* action buttons stay on one line (beats the wrap rule for body cells) */
.app-body .table tbody td.cell-actions { white-space: nowrap; }

/* notification priority icons: clearer glyphs than the ones notification.js picks */
.app-body .preview-icon.bg-danger .mdi::before { content: "\F05D6"; }
.app-body .preview-icon.bg-warning .mdi::before { content: "\F009C"; }
.app-body .preview-icon.bg-success .mdi::before { content: "\F02FD"; }

/* the collapse button points the other way while the sidebar is collapsed */
body.sb-mini .tb-menu-desktop .mdi::before { content: "\F0D75"; }

/* punch out dialog: time in office vs time registered today (dashboard.js dayCard) */
.swal-modal:has(.swal-day) { width: 460px; }
.swal-day { text-align: left; padding: 4px 6px 0; font-family: var(--font-sans); }
.swal-day .sd-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.swal-day .sd-item { background: var(--surface-2); border: 1px solid var(--line); border-radius: 14px; padding: 12px 14px; }
.swal-day .sd-l { font-size: 11px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--ink-500); }
.swal-day .sd-v { font-family: var(--font-display); font-size: 26px; font-weight: 800; color: var(--ink-900); letter-spacing: -.02em; line-height: 1.2; margin-top: 2px; }
.swal-day .sd-s { font-size: 12px; color: var(--ink-500); margin-top: 2px; }
.swal-day .sd-bar { height: 8px; border-radius: 8px; background: var(--surface-3); overflow: hidden; margin: 14px 0 10px; }
.swal-day .sd-verdict { font-size: 13.5px; color: var(--ink-700); line-height: 1.5; padding: 10px 12px; border-radius: 12px; background: var(--success-50); }
.swal-day .sd-verdict.lvl-warn { background: var(--warning-50); }
.swal-day .sd-verdict.lvl-low { background: var(--danger-50); }
.swal-day .sd-verdict strong { color: var(--ink-900); }
.swal-button--ghost { background: var(--surface); color: var(--brand-700); border: 1px solid var(--brand-200); box-shadow: none; }
.swal-button--ghost:not([disabled]):hover { background: var(--brand-50); }
.swal-footer:has(.swal-button--ghost) { display: flex; flex-wrap: wrap; justify-content: center; gap: 6px; }
.swal-footer:has(.swal-button--ghost) .swal-button-container { margin: 0; }
.swal-footer:has(.swal-button--ghost) .swal-button { padding: 10px 16px; }
