/* Generic overrides on top of Spark (brand colours live in spark/css/brand.css) */
.cursor-pointer { cursor: pointer; }
.table td, .table th { vertical-align: middle; }
.table-hover tbody tr { transition: background-color .1s; }
.empty-state { padding: 3rem 1rem; text-align: center; color: #8A98B0; }
.empty-state i { font-size: 2.5rem; display: block; margin-bottom: .5rem; }
.card-header h5 { margin-bottom: 0; }
.form-label { font-weight: 500; }
.text-right, .text-end { text-align: right; }
.avatar-initial { font-weight: 600; }
.dropdown-menu.show { display: block; }
[x-cloak] { display: none !important; }
.list-group-item a { text-decoration: none; }
.small-muted { font-size: .8125rem; color: #8A98B0; }
.w-8 { width: 8rem; } .w-6 { width: 6rem; } .w-4 { width: 4rem; }
.sticky-actions { position: sticky; bottom: 0; background: #fff; padding: .75rem 0; border-top: 1px solid #eee; }
.prose { max-width: 72ch; }

/* ===================================================================
   Novent CRM
   =================================================================== */
/* Nexa (Novent house font) is used when installed; put Nexa-ExtraLight.woff2 in public/assets/fonts and add an @font-face here to ship it. */

/* Sidebar: tenant logo in white, or the tenant name as word mark */
.sidebar-logo-tenant { height: 40px; filter: brightness(0) invert(1); }
.sidebar-brand-text { color: #fff; font-weight: 800; letter-spacing: .02em; font-size: 1.02rem; line-height: 1.15; text-transform: uppercase; }
.sidebar-brand-mark {
    align-items: center; justify-content: center; border-radius: 8px;
    background: rgba(255, 255, 255, .14); color: #fff; font-weight: 800; font-size: .85rem;
}
body.sidebar-minimized .sidebar-brand-text { display: none; }
body.sidebar-minimized .sidebar-brand-mark { display: inline-flex; }

/* KPI tiles */
.kpi-card { padding: 1rem 1.1rem; height: 100%; margin-bottom: 0; border: 1px solid var(--bs-border-color); display: block; color: inherit; text-decoration: none; }
a.kpi-card:hover { border-color: var(--bs-primary); color: inherit; }
.kpi-label { font-size: .74rem; text-transform: uppercase; letter-spacing: .05em; color: var(--bs-secondary-color); font-weight: 600; }
.kpi-value { font-size: 1.6rem; font-weight: 700; line-height: 1.2; margin-top: .15rem; }
.kpi-value small { font-size: .8rem; font-weight: 500; color: var(--bs-secondary-color); }

/* Status badges coloured by a CSS variable: style="--c: #3E7B8A" */
.badge-color {
    --c: #6A6A6B;
    display: inline-block; padding: .18rem .55rem; font-size: .74rem; font-weight: 600; line-height: 1.4; border-radius: 50rem; white-space: nowrap;
    color: color-mix(in srgb, var(--c) 65%, #14242A); background: color-mix(in srgb, var(--c) 14%, #fff); border: 1px solid color-mix(in srgb, var(--c) 34%, #fff);
}

/* Searchable project picker */
.picker-menu { position: absolute; z-index: 1060; left: 0; right: 0; top: 100%; margin-top: 2px; background: #fff; border: 1px solid var(--bs-border-color); border-radius: 8px; max-height: 300px; overflow-y: auto; }
.picker-item { display: block; width: 100%; text-align: left; background: none; border: 0; padding: .45rem .75rem; border-bottom: 1px solid #F0F3F4; }
.picker-item:last-child { border-bottom: 0; }
.picker-item:hover, .picker-item.active { background: var(--bs-primary-bg-subtle); }

/* Notifications */
.notification-menu { width: 340px; max-height: 420px; overflow-y: auto; }
.notification-item { white-space: normal; border-bottom: 1px solid #F0F3F4; padding: .55rem 1rem; }

/* Hour calendar (FullCalendar) */
.calendar-card { overflow: hidden; }
.calendar-legend { display: flex; flex-wrap: wrap; gap: 1rem; }
.legend-dot { display: inline-block; width: .75rem; height: .75rem; border-radius: 3px; margin-right: .35rem; vertical-align: -1px; }
#hour-calendar, #planning-calendar {
    --fc-border-color: #E8EDEF; --fc-today-bg-color: rgba(169, 213, 222, .16); --fc-now-indicator-color: #E5484D;
    --fc-button-bg-color: #fff; --fc-button-border-color: #D5DEE1; --fc-button-text-color: #26343A;
    --fc-button-hover-bg-color: #E8F1F3; --fc-button-hover-border-color: #C9DFE4;
    --fc-button-active-bg-color: #3E7B8A; --fc-button-active-border-color: #3E7B8A;
    --fc-non-business-color: rgba(31, 69, 78, .035); --fc-event-border-color: transparent;
    font-size: .85rem;
}
#hour-calendar .fc-button, #planning-calendar .fc-button { font-size: .8rem; font-weight: 600; padding: .35rem .7rem; text-transform: none; box-shadow: none !important; }
#hour-calendar .fc-button-active, #planning-calendar .fc-button-active { color: #fff !important; }
#hour-calendar .fc-toolbar-title, #planning-calendar .fc-toolbar-title { font-size: 1.1rem; font-weight: 700; text-transform: capitalize; }
#hour-calendar .fc-col-header-cell-cushion { display: flex; flex-direction: column; align-items: center; padding: .4rem 0; text-decoration: none; color: inherit; }
.fc-day-name { text-transform: capitalize; font-weight: 600; }
.day-total { font-size: .72rem; font-weight: 700; color: #3E7B8A; min-height: 1em; }
#hour-calendar .fc-timegrid-slot { height: 1.7rem; }
.ev { border-radius: 6px !important; box-shadow: 0 1px 2px rgba(31, 69, 78, .12); cursor: pointer; }
.ev .fc-event-main { padding: 2px 5px; overflow: hidden; }
.ev-inner { line-height: 1.2; overflow: hidden; }
.ev-time { font-size: .7rem; opacity: .85; white-space: nowrap; }
.ev-title { font-weight: 700; font-size: .76rem; }
.ev-desc { font-size: .7rem; opacity: .85; overflow: hidden; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; }
.ev-billable, .legend-dot.ev-billable { background: #3E7B8A !important; color: #fff !important; }
.ev-internal, .legend-dot.ev-internal { background: #A9D5DE !important; color: #1F454E !important; }
.ev-invoiced, .legend-dot.ev-invoiced { background: #C9D1D4 !important; color: #3A4A50 !important; }
.ev-pending, .legend-dot.ev-pending { background: #FFF1D6 !important; color: #7A5300 !important; border: 1px dashed #E0A100 !important; }
.ev-rejected { background: #FBE3E4 !important; color: #8A1C22 !important; text-decoration: line-through; }
.ev.fc-list-event { background: transparent !important; color: inherit !important; box-shadow: none; }
.ev.fc-list-event:hover td { background: var(--bs-primary-bg-subtle); }

/* Strip planning (employees x days) */
.strip-table { table-layout: fixed; }
.strip-table th, .strip-table td { font-size: .78rem; padding: .3rem; vertical-align: top; }
.strip-table td.weekend { background: #F7F9FA; }
.strip-item { border-radius: 5px; padding: .15rem .35rem; margin-bottom: 2px; color: #fff; font-weight: 600; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; cursor: pointer; }

/* Tables */
.table-sm-text td, .table-sm-text th { font-size: .84rem; }
.table thead th { font-size: .72rem; text-transform: uppercase; letter-spacing: .04em; color: var(--bs-secondary-color); font-weight: 700; }
.num { text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }
.row-muted td { color: var(--bs-secondary-color); }
.sticky-bar { position: sticky; bottom: 0; z-index: 5; background: #fff; border-top: 1px solid var(--bs-border-color); box-shadow: 0 -4px 12px rgba(31, 69, 78, .06); }
.nav-tabs .nav-link { font-weight: 600; }
.min-w-0 { min-width: 0; }
.form-select.status-select { --c: #6A6A6B; min-width: 150px; font-weight: 600; font-size: .78rem; color: color-mix(in srgb, var(--c) 65%, #14242A) !important; background-color: color-mix(in srgb, var(--c) 13%, #fff) !important; border-color: color-mix(in srgb, var(--c) 40%, #fff) !important; }
.upload-zone { cursor: pointer; border-style: dashed !important; }

/* Options menu on a time block (left/right click) */
.entry-menu { position: fixed; z-index: 1080; width: 260px; max-height: calc(100vh - 16px); overflow-y: auto; background: #fff; border: 1px solid var(--bs-border-color); border-radius: 10px; padding: .35rem 0; }
.entry-menu-head { padding: .35rem .85rem .5rem; border-bottom: 1px solid #EEF2F3; margin-bottom: .25rem; }
.entry-menu-item { display: flex; align-items: center; gap: .6rem; width: 100%; background: none; border: 0; text-align: left; padding: .42rem .85rem; font-size: .84rem; color: var(--bs-body-color); text-decoration: none; font-weight: 500; }
.entry-menu-item:hover { background: var(--bs-primary-bg-subtle); color: var(--bs-body-color); }
.entry-menu-item i { width: 1rem; text-align: center; color: var(--bs-secondary-color); }
.entry-menu-item.text-danger, .entry-menu-item.text-danger i { color: var(--bs-danger) !important; }
.entry-menu-sep { height: 1px; background: #EEF2F3; margin: .3rem 0; }
.entry-menu-label { padding: .1rem .85rem; font-size: .7rem; text-transform: uppercase; letter-spacing: .05em; color: var(--bs-secondary-color); font-weight: 700; }
.entry-menu-types { display: flex; flex-wrap: wrap; gap: .25rem; padding: .25rem .85rem .35rem; }
.entry-menu-type { border: 1px solid var(--bs-border-color); background: #fff; border-radius: 50rem; padding: .1rem .55rem; font-size: .74rem; }
.entry-menu-type:hover { border-color: var(--bs-primary); }
.entry-menu-type.active { background: var(--bs-primary); border-color: var(--bs-primary); color: #fff; }

/* Day and week totals in the all-day row (as in the old calendar) */
.ev-total { background: #E8F1F3 !important; color: #1F454E !important; border: 0 !important; cursor: default; }
.ev-total-week { background: #1F454E !important; color: #fff !important; }
.ev-total-text { font-size: .72rem; font-weight: 700; padding: 0 .3rem; }
#hour-calendar .fc-timegrid-axis-cushion { font-size: .7rem; }
.ev-total .fc-event-main, .ev-total .ev-total-text { color: #1F454E !important; }
.ev-total-week .fc-event-main, .ev-total-week .ev-total-text { color: #fff !important; }

/* Dashboard tiles */
.kpi-tile { display: flex !important; flex-direction: row !important; align-items: center !important; justify-content: flex-start !important; text-align: left; gap: .9rem; padding: 1rem 1.1rem; height: 100%; margin-bottom: 0; border: 1px solid var(--bs-border-color); border-radius: 12px; color: inherit; text-decoration: none; }
a.kpi-tile:hover { border-color: var(--bs-primary); color: inherit; box-shadow: 0 2px 8px rgba(31, 69, 78, .08); }
.kpi-icon { flex: 0 0 44px; height: 44px; border-radius: 10px; display: inline-flex; align-items: center; justify-content: center; background: var(--bs-primary-bg-subtle); color: var(--bs-primary); font-size: 1.25rem; }
.kpi-icon-warn { background: #FDECEC; color: var(--bs-danger); }
.kpi-tile .kpi-label { font-size: .72rem; }
.kpi-tile .kpi-value { font-size: 1.45rem; font-weight: 700; line-height: 1.15; margin-top: .1rem; white-space: nowrap; }
.kpi-tile .kpi-value small { font-size: .8rem; font-weight: 500; color: var(--bs-secondary-color); }
.kpi-sub { font-size: .74rem; color: var(--bs-secondary-color); margin-top: .15rem; }
.kpi-progress { height: 5px; margin-top: .4rem; }
.kpi-tile > .min-w-0 { flex: 1 1 auto; }
.kpi-tile .kpi-icon { margin: 0; }
