/*
   KRH Staff Portal – modern shell
   Loaded after bootstrap.min.css / app.min.css. Re-skins Bootstrap with the
   hospital teal and replaces the Skote topbar/sidebar layout with a
   responsive app shell (off-canvas drawer + bottom nav on phones).
*/

/* ---------- Design tokens ---------- */
:root,
[data-bs-theme=light] {
    --sp-brand: #0b7f7d;
    --sp-brand-hover: #096a68;
    --sp-brand-rgb: 11, 127, 125;
    --sp-brand-soft: #e3f3f2;
    --sp-accent: #f59e0b;

    --sp-bg: #f3f6f7;
    --sp-surface: #ffffff;
    --sp-surface-2: #f8fafb;
    --sp-border: #e3e9ec;
    --sp-text: #1d2b32;
    --sp-muted: #66767f;

    --sp-sidebar-bg: #0c3a3d;
    --sp-sidebar-bg-2: #082a2c;
    --sp-sidebar-text: #b9d3d2;
    --sp-sidebar-text-strong: #ffffff;
    --sp-sidebar-hover: rgba(255, 255, 255, .07);
    --sp-sidebar-active: rgba(94, 214, 207, .16);
    --sp-sidebar-active-text: #7fe3dc;

    --sp-radius: 14px;
    --sp-radius-sm: 10px;
    --sp-shadow: 0 1px 2px rgba(16, 40, 48, .04), 0 4px 16px rgba(16, 40, 48, .05);
    --sp-shadow-lg: 0 12px 40px rgba(16, 40, 48, .16);

    --sp-sidebar-w: 268px;
    --sp-topbar-h: 64px;
    --sp-bottomnav-h: 64px;

    /* Bootstrap overrides */
    --bs-primary: var(--sp-brand);
    --bs-primary-rgb: var(--sp-brand-rgb);
    --bs-primary-text-emphasis: #075654;
    --bs-primary-bg-subtle: var(--sp-brand-soft);
    --bs-primary-border-subtle: #a9dbd8;
    --bs-link-color: var(--sp-brand);
    --bs-link-color-rgb: var(--sp-brand-rgb);
    --bs-link-hover-color: var(--sp-brand-hover);
    --bs-link-hover-color-rgb: 9, 106, 104;
    --bs-body-bg: var(--sp-bg);
    --bs-body-color: var(--sp-text);
    --bs-secondary-color: var(--sp-muted);
    --bs-border-color: var(--sp-border);
    --bs-font-sans-serif: "Plus Jakarta Sans", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
    --bs-body-font-family: var(--bs-font-sans-serif);
    --bs-body-font-size: .875rem;
    --bs-card-bg: var(--sp-surface);
}

[data-bs-theme=dark] {
    --sp-brand: #2bb3ad;
    --sp-brand-hover: #3cc7c0;
    --sp-brand-rgb: 43, 179, 173;
    --sp-brand-soft: rgba(43, 179, 173, .14);

    --sp-bg: #0e1517;
    --sp-surface: #152024;
    --sp-surface-2: #1a272b;
    --sp-border: #243338;
    --sp-text: #e3ecee;
    --sp-muted: #94a5ab;

    --sp-sidebar-bg: #0a1315;
    --sp-sidebar-bg-2: #070f10;
    --sp-sidebar-text: #9fb4b6;
    --sp-sidebar-active: rgba(43, 179, 173, .16);

    --sp-shadow: 0 1px 2px rgba(0, 0, 0, .25);
    --sp-shadow-lg: 0 12px 40px rgba(0, 0, 0, .5);

    --bs-primary: var(--sp-brand);
    --bs-primary-rgb: var(--sp-brand-rgb);
    --bs-primary-text-emphasis: #7fe3dc;
    --bs-primary-bg-subtle: var(--sp-brand-soft);
    --bs-primary-border-subtle: #1f5f5c;
    --bs-link-color: var(--sp-brand);
    --bs-link-color-rgb: var(--sp-brand-rgb);
    --bs-link-hover-color: var(--sp-brand-hover);
    --bs-body-bg: var(--sp-bg);
    --bs-body-color: var(--sp-text);
    --bs-secondary-color: var(--sp-muted);
    --bs-border-color: var(--sp-border);
    --bs-secondary-bg: var(--sp-surface);
    --bs-tertiary-bg: var(--sp-surface-2);
    --bs-card-bg: var(--sp-surface);
}

/* ---------- Base ---------- */
body {
    font-family: var(--bs-body-font-family);
    background: var(--sp-bg);
    color: var(--sp-text);
    -webkit-font-smoothing: antialiased;
    margin: 0;
}
h1, h2, h3, h4, h5, h6, .h1, .h2, .h3, .h4, .h5, .h6 {
    color: var(--sp-text);
    font-weight: 700;
    letter-spacing: -.01em;
}
a { color: var(--sp-brand); }
a:hover { color: var(--sp-brand-hover); }
.text-muted { color: var(--sp-muted) !important; }
.text-dark { color: var(--sp-text) !important; }

/* ---------- App shell ---------- */
.sp-shell { min-height: 100vh; }

.sp-sidebar {
    position: fixed;
    inset: 0 auto 0 0;
    width: var(--sp-sidebar-w);
    z-index: 1040;
    display: flex;
    flex-direction: column;
    background: linear-gradient(180deg, var(--sp-sidebar-bg) 0%, var(--sp-sidebar-bg-2) 100%);
    color: var(--sp-sidebar-text);
    transition: transform .25s ease;
}

.sp-sidebar__brand {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: .5rem;
    padding: 1.1rem 1.1rem .9rem 1.25rem;
    border-bottom: 1px solid rgba(255, 255, 255, .06);
}
.sp-sidebar__brand img { height: 58px; width: auto; display: block; }
.sp-sidebar__close {
    display: none;
    border: 0;
    background: rgba(255, 255, 255, .08);
    color: #fff;
    width: 36px;
    height: 36px;
    border-radius: 10px;
    font-size: 1.3rem;
    line-height: 1;
}

.sp-nav {
    flex: 1 1 auto;
    overflow-y: auto;
    padding: .75rem .75rem 1rem;
    scrollbar-width: thin;
    scrollbar-color: rgba(255, 255, 255, .15) transparent;
}
.sp-nav ul { list-style: none; margin: 0; padding: 0; }
.sp-nav__title {
    font-size: .68rem;
    font-weight: 700;
    letter-spacing: .09em;
    text-transform: uppercase;
    color: rgba(185, 211, 210, .55);
    padding: 1.1rem .75rem .45rem;
}
.sp-nav__link {
    display: flex;
    align-items: center;
    gap: .75rem;
    width: 100%;
    padding: .62rem .75rem;
    margin-bottom: 2px;
    border: 0;
    border-radius: var(--sp-radius-sm);
    background: transparent;
    color: var(--sp-sidebar-text);
    font-size: .92rem;
    font-weight: 500;
    text-align: left;
    text-decoration: none;
    transition: background-color .15s, color .15s;
}
.sp-nav__link > i:first-child { font-size: 1.25rem; width: 1.4rem; text-align: center; opacity: .9; }
.sp-nav__link:hover,
.sp-nav__link:focus-visible { background: var(--sp-sidebar-hover); color: var(--sp-sidebar-text-strong); }
.sp-nav__link.active { background: var(--sp-sidebar-active); color: var(--sp-sidebar-active-text); font-weight: 600; }
.sp-nav__caret { margin-left: auto; font-size: 1.05rem; transition: transform .2s; opacity: .7; }
.sp-nav__link[aria-expanded=true] { color: var(--sp-sidebar-text-strong); }
.sp-nav__link[aria-expanded=true] .sp-nav__caret { transform: rotate(180deg); }

.sp-nav__sub { padding: .15rem 0 .4rem 2.15rem !important; position: relative; }
.sp-nav__sub::before {
    content: "";
    position: absolute;
    left: 1.45rem;
    top: .3rem;
    bottom: .6rem;
    width: 1px;
    background: rgba(255, 255, 255, .1);
}
.sp-nav__sub a {
    display: block;
    padding: .45rem .75rem;
    border-radius: 8px;
    color: var(--sp-sidebar-text);
    font-size: .875rem;
    text-decoration: none;
}
.sp-nav__sub a:hover { color: #fff; background: var(--sp-sidebar-hover); }
.sp-nav__sub a.active { color: var(--sp-sidebar-active-text); font-weight: 600; }

.sp-sidebar__footer {
    padding: .85rem;
    border-top: 1px solid rgba(255, 255, 255, .06);
}
.sp-usercard {
    display: flex;
    align-items: center;
    gap: .7rem;
    padding: .6rem;
    border-radius: 12px;
    background: rgba(255, 255, 255, .05);
}
.sp-usercard__meta { min-width: 0; flex: 1; line-height: 1.25; }
.sp-usercard__name { color: #fff; font-weight: 600; font-size: .88rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.sp-usercard__role { font-size: .74rem; color: var(--sp-sidebar-text); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.sp-usercard form { margin: 0; }
.sp-usercard .sp-iconbtn { color: #fda4a4; background: rgba(255, 255, 255, .06); }
.sp-usercard .sp-iconbtn:hover { background: rgba(239, 68, 68, .2); color: #fff; }

.sp-avatar {
    flex: 0 0 auto;
    width: 38px;
    height: 38px;
    border-radius: 50%;
    display: inline-grid;
    place-items: center;
    background: linear-gradient(135deg, #2bb3ad, #0b7f7d);
    color: #fff;
    font-weight: 700;
    font-size: .85rem;
    letter-spacing: .02em;
    text-transform: uppercase;
}
.sp-avatar--sm { width: 34px; height: 34px; font-size: .78rem; }

.sp-backdrop {
    position: fixed;
    inset: 0;
    z-index: 1035;
    background: rgba(5, 20, 22, .5);
    backdrop-filter: blur(2px);
    opacity: 0;
    visibility: hidden;
    transition: opacity .25s, visibility .25s;
}

.sp-main {
    margin-left: var(--sp-sidebar-w);
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    transition: margin-left .25s ease;
}

/* Desktop: collapse hides the sidebar completely */
@media (min-width: 992px) {
    html.sp-collapsed .sp-sidebar { transform: translateX(-100%); }
    html.sp-collapsed .sp-main { margin-left: 0; }
}

/* ---------- Topbar ---------- */
.sp-topbar {
    position: sticky;
    top: 0;
    z-index: 1020;
    height: var(--sp-topbar-h);
    display: flex;
    align-items: center;
    gap: .75rem;
    padding: 0 1.5rem;
    background: color-mix(in srgb, var(--sp-surface) 85%, transparent);
    backdrop-filter: saturate(1.4) blur(10px);
    border-bottom: 1px solid var(--sp-border);
}
.sp-topbar__title {
    font-size: 1.02rem;
    font-weight: 700;
    margin: 0;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    min-width: 0;
}
.sp-topbar__actions { margin-left: auto; display: flex; align-items: center; gap: .35rem; }

.sp-iconbtn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    flex: 0 0 auto;
    border: 0;
    border-radius: 10px;
    background: transparent;
    color: var(--sp-muted);
    font-size: 1.3rem;
    transition: background-color .15s, color .15s;
}
.sp-iconbtn:hover, .sp-iconbtn:focus-visible { background: var(--sp-surface-2); color: var(--sp-text); }

.sp-theme-toggle .bx-sun { display: none; }
[data-bs-theme=dark] .sp-theme-toggle .bx-sun { display: inline-block; }
[data-bs-theme=dark] .sp-theme-toggle .bx-moon { display: none; }

.sp-userbtn {
    display: flex;
    align-items: center;
    gap: .6rem;
    padding: .25rem .5rem .25rem .25rem;
    border: 1px solid var(--sp-border);
    border-radius: 999px;
    background: var(--sp-surface);
    color: var(--sp-text);
    margin-left: .25rem;
}
.sp-userbtn:hover { border-color: rgba(var(--sp-brand-rgb), .4); }
.sp-userbtn__name { font-size: .85rem; font-weight: 600; max-width: 160px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

.sp-topbar .dropdown-menu {
    border: 1px solid var(--sp-border);
    border-radius: var(--sp-radius);
    box-shadow: var(--sp-shadow-lg);
    padding: .4rem;
    min-width: 240px;
    background: var(--sp-surface);
}
.sp-topbar .dropdown-item {
    border-radius: 8px;
    padding: .55rem .7rem;
    display: flex;
    align-items: center;
    gap: .6rem;
    font-size: .9rem;
    color: var(--sp-text);
    width: 100%;
}
.sp-topbar .dropdown-item i { font-size: 1.15rem; color: var(--sp-muted); }
.sp-topbar .dropdown-item:hover { background: var(--sp-surface-2); }
.sp-topbar .dropdown-item.text-danger i { color: inherit; }
.sp-dropdown-head { padding: .6rem .7rem .7rem; display: flex; gap: .7rem; align-items: center; }
.sp-dropdown-head .small { line-height: 1.3; }

/* ---------- Content ---------- */
.sp-content {
    flex: 1 0 auto;
    width: 100%;
    max-width: 1440px;
    margin: 0 auto;
    padding: 1.5rem 1.5rem 2rem;
}

.sp-pagehead {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-end;
    justify-content: space-between;
    gap: .5rem 1rem;
    margin-bottom: 1.25rem;
}
.sp-pagehead h1 { font-size: 1.45rem; margin: 0; }
.sp-pagehead .breadcrumb { margin: 0; font-size: .82rem; --bs-breadcrumb-divider-color: var(--sp-muted); }
.sp-pagehead .breadcrumb-item, .sp-pagehead .breadcrumb-item a { color: var(--sp-muted); text-decoration: none; }
.sp-pagehead .breadcrumb-item a:hover { color: var(--sp-brand); }
.sp-pagehead .breadcrumb-item.active { color: var(--sp-text); }

.sp-footer {
    padding: 1rem 1.5rem;
    border-top: 1px solid var(--sp-border);
    color: var(--sp-muted);
    font-size: .82rem;
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    gap: .25rem 1rem;
}

/* ---------- Mobile bottom nav ---------- */
.sp-bottomnav {
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 1030;
    display: none;
    height: calc(var(--sp-bottomnav-h) + env(safe-area-inset-bottom));
    padding-bottom: env(safe-area-inset-bottom);
    background: color-mix(in srgb, var(--sp-surface) 92%, transparent);
    backdrop-filter: saturate(1.4) blur(12px);
    border-top: 1px solid var(--sp-border);
}
.sp-bottomnav a, .sp-bottomnav button {
    flex: 1 1 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 2px;
    border: 0;
    background: none;
    color: var(--sp-muted);
    font-size: .68rem;
    font-weight: 600;
    text-decoration: none;
}
.sp-bottomnav i { font-size: 1.4rem; }
.sp-bottomnav .active { color: var(--sp-brand); }

/* ---------- Responsive shell ---------- */
@media (max-width: 991.98px) {
    .sp-sidebar {
        transform: translateX(-100%);
        width: min(86vw, 300px);
        box-shadow: var(--sp-shadow-lg);
    }
    .sp-sidebar__close { display: inline-grid; place-items: center; }
    body.sp-drawer-open { overflow: hidden; }
    body.sp-drawer-open .sp-sidebar { transform: none; }
    body.sp-drawer-open .sp-backdrop { opacity: 1; visibility: visible; }
    .sp-main { margin-left: 0; }
    .sp-bottomnav { display: flex; }
    .sp-main { padding-bottom: calc(var(--sp-bottomnav-h) + env(safe-area-inset-bottom)); }
}

@media (max-width: 767.98px) {
    /* 16px stops iOS zooming into focused fields */
    .form-control, .form-select, .dataTables_wrapper .dataTables_filter input { font-size: 16px; }
    .sp-topbar { padding: 0 .75rem; gap: .35rem; }
    .sp-content { padding: 1rem 1rem 1.5rem; }
    .sp-footer { padding: .9rem 1rem; justify-content: center; text-align: center; }
    .sp-pagehead { flex-direction: column; align-items: flex-start; }
    .sp-pagehead h1 { font-size: 1.25rem; }
    .sp-userbtn { padding: 2px; border-color: transparent; }
}

/* ---------- Components (apply to every existing view) ---------- */
.card {
    background: var(--sp-surface);
    border: 1px solid var(--sp-border);
    border-radius: var(--sp-radius);
    box-shadow: var(--sp-shadow);
    margin-bottom: 1.5rem;
}
.card-header {
    background: transparent;
    border-bottom: 1px solid var(--sp-border);
    padding: 1rem 1.25rem;
}
.card-body { padding: 1.35rem; }
.card-title { font-size: 1.05rem; font-weight: 700; margin-bottom: .35rem; }
.card-title-desc { color: var(--sp-muted); margin-bottom: 1.25rem; }
@media (max-width: 575.98px) {
    .card-body { padding: 1rem; }
}

/* Bootstrap 5 removed .form-group – many views still use it */
.form-group { margin-bottom: 1rem; }
.form-label, .control-label, label { font-weight: 600; font-size: .86rem; color: var(--sp-text); margin-bottom: .35rem; }
.form-control, .form-select {
    min-height: 42px;
    border-radius: var(--sp-radius-sm);
    border-color: var(--sp-border);
    background-color: var(--sp-surface);
    color: var(--sp-text);
}
textarea.form-control { min-height: 90px; }
.form-control:focus, .form-select:focus {
    border-color: rgba(var(--sp-brand-rgb), .6);
    box-shadow: 0 0 0 .2rem rgba(var(--sp-brand-rgb), .15);
}
.form-check-input:checked { background-color: var(--sp-brand); border-color: var(--sp-brand); }
.form-check-input:focus { box-shadow: 0 0 0 .2rem rgba(var(--sp-brand-rgb), .15); border-color: rgba(var(--sp-brand-rgb), .6); }
.input-group > .btn { border-radius: 0 var(--sp-radius-sm) var(--sp-radius-sm) 0; }

.btn { border-radius: var(--sp-radius-sm); font-weight: 600; padding: .55rem 1.05rem; }
.btn-sm { padding: .35rem .7rem; border-radius: 8px; }
.btn-primary {
    --bs-btn-bg: var(--sp-brand);
    --bs-btn-border-color: var(--sp-brand);
    --bs-btn-hover-bg: var(--sp-brand-hover);
    --bs-btn-hover-border-color: var(--sp-brand-hover);
    --bs-btn-active-bg: var(--sp-brand-hover);
    --bs-btn-active-border-color: var(--sp-brand-hover);
    --bs-btn-disabled-bg: var(--sp-brand);
    --bs-btn-disabled-border-color: var(--sp-brand);
    --bs-btn-focus-shadow-rgb: var(--sp-brand-rgb);
}
.btn-outline-primary {
    --bs-btn-color: var(--sp-brand);
    --bs-btn-border-color: var(--sp-brand);
    --bs-btn-hover-bg: var(--sp-brand);
    --bs-btn-hover-border-color: var(--sp-brand);
    --bs-btn-active-bg: var(--sp-brand);
    --bs-btn-active-border-color: var(--sp-brand);
}
.btn:focus-visible { box-shadow: 0 0 0 .2rem rgba(var(--sp-brand-rgb), .25); }

.table { --bs-table-bg: transparent; --bs-table-color: var(--sp-text); color: var(--sp-text); margin-bottom: 0; }
.table > thead th {
    background: var(--sp-surface-2);
    color: var(--sp-muted);
    font-size: .74rem;
    font-weight: 700;
    letter-spacing: .05em;
    text-transform: uppercase;
    white-space: nowrap;
    border-bottom-width: 1px;
}
.table > :not(caption) > * > * { padding: .8rem .9rem; border-color: var(--sp-border); vertical-align: middle; }
.table-bordered > :not(caption) > * > * { border-width: 0 0 1px 0; }
.table-bordered > :not(caption) > * { border-width: 0; }
.table tbody tr { transition: background-color .12s; }
.table tbody tr:hover { background: rgba(var(--sp-brand-rgb), .04); }
.table-responsive { border-radius: var(--sp-radius-sm); }

/* DataTables (bs4 skin on Bootstrap 5) */
.dataTables_wrapper .row { row-gap: .75rem; }
.dataTables_wrapper .dataTables_filter input,
.dataTables_wrapper .dataTables_length select {
    border: 1px solid var(--sp-border);
    border-radius: var(--sp-radius-sm);
    min-height: 38px;
    padding: .35rem .7rem;
    background: var(--sp-surface);
    color: var(--sp-text);
}
.dataTables_wrapper .dataTables_info { color: var(--sp-muted); font-size: .85rem; }
.page-item.active .page-link { background-color: var(--sp-brand); border-color: var(--sp-brand); }
.page-link { color: var(--sp-brand); border-radius: 8px !important; margin: 0 2px; border-color: var(--sp-border); background: var(--sp-surface); }
.dt-buttons .btn { margin-bottom: .25rem; }
table.dataTable.dtr-inline.collapsed > tbody > tr > td.dtr-control::before,
table.dataTable.dtr-inline.collapsed > tbody > tr > th.dtr-control::before { background-color: var(--sp-brand) !important; box-shadow: none; }
@media (max-width: 767.98px) {
    .dataTables_wrapper .dataTables_filter,
    .dataTables_wrapper .dataTables_length,
    .dataTables_wrapper .dataTables_info,
    .dataTables_wrapper .dataTables_paginate { text-align: left !important; }
    .dataTables_wrapper .dataTables_filter label { display: block; width: 100%; white-space: normal !important; }
    .dataTables_wrapper .dataTables_filter input { display: block !important; width: 100% !important; margin: .35rem 0 0 !important; }
    .dataTables_wrapper .dataTables_paginate .pagination { justify-content: flex-start !important; flex-wrap: wrap; }
}

.badge { font-weight: 600; border-radius: 6px; padding: .38em .6em; }
.alert { border-radius: var(--sp-radius-sm); border: 0; }
.modal-content { border: 0; border-radius: var(--sp-radius); box-shadow: var(--sp-shadow-lg); background: var(--sp-surface); }
.dropdown-menu { border-color: var(--sp-border); border-radius: var(--sp-radius-sm); }
.nav-pills .nav-link.active, .nav-pills .show > .nav-link { background-color: var(--sp-brand); }
.bg-primary { background-color: var(--sp-brand) !important; }
.text-primary { color: var(--sp-brand) !important; }
.select2-container--default .select2-selection--single,
.select2-container--default .select2-selection--multiple { border-color: var(--sp-border) !important; border-radius: var(--sp-radius-sm) !important; min-height: 42px; }
.select2-container--default .select2-results__option--highlighted[aria-selected] { background-color: var(--sp-brand) !important; }

/* ---------- Dashboard ---------- */
.sp-hero {
    position: relative;
    overflow: hidden;
    border-radius: calc(var(--sp-radius) + 4px);
    padding: 1.75rem 1.75rem;
    margin-bottom: 1.5rem;
    color: #fff;
    background:
        radial-gradient(1200px 300px at 100% 0%, rgba(127, 227, 220, .35), transparent 60%),
        linear-gradient(120deg, #0b7f7d 0%, #0c5d60 55%, #0c3a3d 100%);
    box-shadow: var(--sp-shadow);
}
.sp-hero::after {
    content: "";
    position: absolute;
    right: -60px;
    bottom: -80px;
    width: 280px;
    height: 280px;
    border-radius: 50%;
    border: 40px solid rgba(255, 255, 255, .06);
}
.sp-hero h1, .sp-hero h2 { color: #fff; }
.sp-hero__salam { display: inline-block; font-size: 1.05rem; opacity: .9; margin-bottom: .35rem; font-weight: 500; }
.sp-hero__title { font-size: 1.7rem; margin: 0 0 .35rem; }
.sp-hero__sub { opacity: .85; margin: 0; max-width: 560px; }
.sp-hero__date {
    display: inline-flex;
    align-items: center;
    gap: .4rem;
    padding: .4rem .8rem;
    border-radius: 999px;
    background: rgba(255, 255, 255, .14);
    font-size: .82rem;
    font-weight: 600;
    position: relative;
    z-index: 1;
}
.sp-hero .btn-light { background: #fff; border-color: #fff; color: #0b5f5d; font-weight: 700; }
.sp-hero .btn-light:hover { background: #e9f6f5; border-color: #e9f6f5; color: #0b5f5d; }
.sp-hero .btn-ghost { color: #fff; border: 1px solid rgba(255, 255, 255, .35); background: transparent; }
.sp-hero .btn-ghost:hover { background: rgba(255, 255, 255, .12); color: #fff; }
.sp-hero > * { position: relative; z-index: 1; }

.sp-stat {
    display: flex;
    align-items: center;
    gap: 1rem;
    height: 100%;
    padding: 1.15rem 1.2rem;
    background: var(--sp-surface);
    border: 1px solid var(--sp-border);
    border-radius: var(--sp-radius);
    box-shadow: var(--sp-shadow);
}
.sp-stat__icon {
    flex: 0 0 auto;
    width: 48px;
    height: 48px;
    border-radius: 12px;
    display: grid;
    place-items: center;
    font-size: 1.5rem;
    background: var(--sp-brand-soft);
    color: var(--sp-brand);
}
.sp-stat__icon--amber { background: rgba(245, 158, 11, .14); color: #c27803; }
.sp-stat__icon--blue { background: rgba(59, 130, 246, .13); color: #2f6fd6; }
.sp-stat__icon--violet { background: rgba(139, 92, 246, .13); color: #7c4ddb; }
.sp-stat__icon--rose { background: rgba(244, 63, 94, .12); color: #d33656; }
[data-bs-theme=dark] .sp-stat__icon--amber { color: #fbbf24; }
[data-bs-theme=dark] .sp-stat__icon--blue { color: #7aa7f5; }
[data-bs-theme=dark] .sp-stat__icon--violet { color: #b69cf7; }
[data-bs-theme=dark] .sp-stat__icon--rose { color: #f58aa0; }
.sp-stat__label { color: var(--sp-muted); font-size: .82rem; font-weight: 500; margin: 0 0 .15rem; line-height: 1.3; }
.sp-stat__value { font-size: 1.65rem; font-weight: 800; margin: 0; line-height: 1.1; letter-spacing: -.02em; }

.sp-booking { position: relative; }
.sp-booking:hover { background: rgba(var(--sp-brand-rgb), .04); }
.sp-booking__date { width: 52px; padding: .35rem 0; text-align: center; border-radius: 10px; background: var(--sp-brand-soft); color: var(--sp-brand); flex-shrink: 0; }
.sp-booking__month { font-size: .68rem; font-weight: 700; text-transform: uppercase; }
.sp-booking__day { font-size: 1.25rem; font-weight: 800; line-height: 1; }

.sp-section-title { font-size: 1rem; font-weight: 700; margin: .5rem 0 .9rem; }

.sp-action {
    display: flex;
    align-items: center;
    gap: .9rem;
    height: 100%;
    padding: 1rem 1.1rem;
    border: 1px solid var(--sp-border);
    border-radius: var(--sp-radius);
    background: var(--sp-surface);
    color: var(--sp-text);
    text-decoration: none;
    box-shadow: var(--sp-shadow);
    transition: transform .15s, border-color .15s, box-shadow .15s;
}
.sp-action:hover {
    color: var(--sp-text);
    transform: translateY(-2px);
    border-color: rgba(var(--sp-brand-rgb), .45);
    box-shadow: 0 8px 24px rgba(16, 40, 48, .08);
}
.sp-action__icon {
    flex: 0 0 auto;
    width: 42px;
    height: 42px;
    border-radius: 11px;
    display: grid;
    place-items: center;
    font-size: 1.3rem;
    background: var(--sp-brand-soft);
    color: var(--sp-brand);
}
.sp-action__title { font-weight: 700; font-size: .92rem; margin: 0; }
.sp-action__desc { font-size: .8rem; color: var(--sp-muted); margin: 0; }
.sp-action__go { margin-left: auto; color: var(--sp-muted); font-size: 1.25rem; }

@media (max-width: 575.98px) {
    .sp-hero { padding: 1.35rem 1.2rem; }
    .sp-hero__title { font-size: 1.35rem; }
    .sp-stat { padding: .9rem; gap: .75rem; }
    .sp-stat__icon { width: 42px; height: 42px; font-size: 1.3rem; }
    .sp-stat__value { font-size: 1.4rem; }
}

/* ---------- Auth (login) ---------- */
.sp-auth { min-height: 100vh; display: grid; grid-template-columns: 1.05fr 1fr; background: var(--sp-surface); }
.sp-auth__aside {
    position: relative;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    padding: 2.5rem 3rem;
    color: #fff;
    background:
        radial-gradient(900px 420px at 0% 100%, rgba(127, 227, 220, .28), transparent 60%),
        linear-gradient(150deg, #0b7f7d 0%, #0c4c50 50%, #082a2c 100%);
}
.sp-auth__aside::after {
    content: "";
    position: absolute;
    right: -120px;
    top: -120px;
    width: 420px;
    height: 420px;
    border-radius: 50%;
    border: 60px solid rgba(255, 255, 255, .05);
}
.sp-auth__aside img { height: 84px; width: auto; align-self: flex-start; position: relative; z-index: 1; }
.sp-auth__pitch { position: relative; z-index: 1; max-width: 460px; }
.sp-auth__pitch h1 { color: #fff; font-size: 2.2rem; line-height: 1.15; margin-bottom: 1rem; }
.sp-auth__pitch p { opacity: .85; font-size: 1.02rem; }
.sp-auth__features { list-style: none; padding: 0; margin: 1.5rem 0 0; display: grid; gap: .7rem; }
.sp-auth__features li { display: flex; align-items: center; gap: .7rem; opacity: .95; }
.sp-auth__features i { width: 34px; height: 34px; border-radius: 10px; display: grid; place-items: center; background: rgba(255, 255, 255, .12); font-size: 1.15rem; }
.sp-auth__legal { position: relative; z-index: 1; font-size: .8rem; opacity: .7; }

.sp-auth__main { display: flex; align-items: center; justify-content: center; padding: 2rem 1.25rem; }
.sp-auth__wrap { width: 100%; max-width: 420px; }
.sp-auth__card { width: 100%; max-width: 420px; }
.sp-auth__mobilebrand { display: none; }
.sp-auth__card h2 { font-size: 1.6rem; margin-bottom: .35rem; }
.sp-auth__card .form-control { min-height: 46px; }
.sp-auth__card .btn-primary { min-height: 46px; }
.sp-auth__links { font-size: .86rem; }

@media (max-width: 991.98px) {
    .sp-auth { grid-template-columns: 1fr; background: var(--sp-bg); }
    .sp-auth__aside { display: none; }
    .sp-auth__main { align-items: flex-start; padding-top: 0; }
    .sp-auth__card {
        background: var(--sp-surface);
        border: 1px solid var(--sp-border);
        border-radius: calc(var(--sp-radius) + 4px);
        box-shadow: var(--sp-shadow);
        padding: 1.5rem 1.25rem;
        margin-top: -2.25rem;
        position: relative;
    }
    .sp-auth__mobilebrand {
        display: flex;
        justify-content: center;
        padding: 1.75rem 1rem 3.25rem;
        margin: 0 -1.25rem;
        background: linear-gradient(150deg, #0b7f7d 0%, #0c4c50 60%, #082a2c 100%);
    }
    .sp-auth__mobilebrand img { height: 54px; width: auto; }
    .sp-auth__wrap { max-width: none; }
}

/* Blank layout pages that still use the Skote .account-pages markup */
.account-pages .card { border-radius: calc(var(--sp-radius) + 4px); }

/* ---------- Print ---------- */
@media print {
    .sp-sidebar, .sp-topbar, .sp-bottomnav, .sp-backdrop, .sp-footer { display: none !important; }
    .sp-main { margin: 0 !important; padding: 0 !important; }
}
