:root {
    --lcp-blue-950: #071a2f;
    --lcp-blue-900: #0b2545;
    --lcp-blue-850: #0e2f56;
    --lcp-blue-800: #12395f;
    --lcp-blue-700: #174b78;

    --lcp-cyan-500: #19c2e6;
    --lcp-cyan-400: #37d2ef;
    --lcp-cyan-300: #7ae3f5;
    --lcp-cyan-100: #e7faff;

    --lcp-green-500: #22c55e;
    --lcp-green-100: #dcfce7;

    --lcp-amber-500: #f59e0b;
    --lcp-amber-100: #fef3c7;

    --lcp-red-500: #ef4444;
    --lcp-red-100: #fee2e2;

    --lcp-slate-950: #0f172a;
    --lcp-slate-900: #172033;
    --lcp-slate-800: #1e293b;
    --lcp-slate-700: #334155;
    --lcp-slate-600: #475569;
    --lcp-slate-500: #64748b;
    --lcp-slate-400: #94a3b8;
    --lcp-slate-300: #cbd5e1;
    --lcp-slate-200: #e2e8f0;
    --lcp-slate-100: #f1f5f9;
    --lcp-slate-50: #f8fafc;

    --lcp-white: #ffffff;

    --lcp-sidebar-width: 280px;
    --lcp-header-height: 88px;

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

    --lcp-shadow-sm:
        0 1px 2px rgba(15, 23, 42, 0.04),
        0 1px 4px rgba(15, 23, 42, 0.06);

    --lcp-shadow-md:
        0 8px 24px rgba(15, 23, 42, 0.08),
        0 2px 8px rgba(15, 23, 42, 0.04);

    --lcp-shadow-lg:
        0 20px 50px rgba(15, 23, 42, 0.12),
        0 8px 20px rgba(15, 23, 42, 0.06);

    --lcp-transition:
        180ms ease;
}

/* --------------------------------------------------------------
   Base
-------------------------------------------------------------- */

*,
*::before,
*::after {
    box-sizing: border-box;
}

html {
    min-height: 100%;
    background: var(--lcp-slate-50);
}

body {
    min-height: 100vh;
    margin: 0;
    color: var(--lcp-slate-800);
    background:
        radial-gradient(
            circle at top right,
            rgba(25, 194, 230, 0.08),
            transparent 26rem
        ),
        var(--lcp-slate-50);
    font-family:
        Inter,
        ui-sans-serif,
        system-ui,
        -apple-system,
        BlinkMacSystemFont,
        "Segoe UI",
        sans-serif;
    font-size: 0.95rem;
    line-height: 1.55;
    -webkit-font-smoothing: antialiased;
    text-rendering: optimizeLegibility;
}

a {
    color: inherit;
    text-decoration: none;
}

button,
input,
select,
textarea {
    font: inherit;
}

button:focus-visible,
a:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible {
    outline: 3px solid rgba(25, 194, 230, 0.28);
    outline-offset: 2px;
}

::selection {
    color: var(--lcp-blue-950);
    background: var(--lcp-cyan-300);
}

/* --------------------------------------------------------------
   Portal structure
-------------------------------------------------------------- */

.portal-body {
    min-height: 100vh;
    overflow-x: hidden;
}

.portal-layout {
    display: flex;
    min-height: 100vh;
}

.portal-main {
    display: flex;
    flex: 1;
    flex-direction: column;
    min-width: 0;
    margin-left: var(--lcp-sidebar-width);
}

/* --------------------------------------------------------------
   Sidebar
-------------------------------------------------------------- */

.portal-sidebar {
    position: fixed;
    z-index: 1035;
    top: 0;
    bottom: 0;
    left: 0;
    display: flex;
    width: var(--lcp-sidebar-width);
    flex-direction: column;
    overflow: hidden;
    color: rgba(255, 255, 255, 0.86);
    background:
        radial-gradient(
            circle at top left,
            rgba(55, 210, 239, 0.18),
            transparent 18rem
        ),
        linear-gradient(
            180deg,
            var(--lcp-blue-900) 0%,
            var(--lcp-blue-950) 100%
        );
    box-shadow:
        12px 0 40px rgba(7, 26, 47, 0.15);
}

.portal-sidebar::after {
    position: absolute;
    right: 0;
    bottom: 0;
    width: 180px;
    height: 180px;
    border-radius: 50%;
    background: rgba(25, 194, 230, 0.05);
    content: "";
    filter: blur(10px);
    transform: translate(45%, 45%);
    pointer-events: none;
}

.sidebar-brand {
    display: flex;
    min-height: var(--lcp-header-height);
    align-items: center;
    padding: 0 24px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.brand-link {
    display: inline-flex;
    align-items: center;
    gap: 13px;
    color: var(--lcp-white);
}

.brand-link:hover {
    color: var(--lcp-white);
}

.brand-mark {
    position: relative;
    display: inline-flex;
    width: 44px;
    height: 44px;
    flex: 0 0 44px;
    align-items: center;
    justify-content: center;
}

.brand-mark > i {
    position: absolute;
    inset: 0;
    color: var(--lcp-cyan-500);
    font-size: 2.75rem;
    line-height: 1;
    filter:
        drop-shadow(0 8px 18px rgba(25, 194, 230, 0.24));
}

.brand-mark-letter {
    position: relative;
    z-index: 1;
    color: var(--lcp-blue-950);
    font-size: 1rem;
    font-weight: 800;
    line-height: 1;
}

.brand-copy {
    display: flex;
    min-width: 0;
    flex-direction: column;
    line-height: 1.12;
}

.brand-copy strong {
    color: var(--lcp-white);
    font-size: 1rem;
    font-weight: 750;
    letter-spacing: -0.01em;
}

.brand-copy small {
    margin-top: 4px;
    color: rgba(255, 255, 255, 0.58);
    font-size: 0.72rem;
    font-weight: 600;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.sidebar-navigation {
    position: relative;
    z-index: 1;
    flex: 1;
    overflow-y: auto;
    padding: 24px 16px;
    scrollbar-color:
        rgba(255, 255, 255, 0.14)
        transparent;
    scrollbar-width: thin;
}

.sidebar-navigation::-webkit-scrollbar {
    width: 5px;
}

.sidebar-navigation::-webkit-scrollbar-track {
    background: transparent;
}

.sidebar-navigation::-webkit-scrollbar-thumb {
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.14);
}

.sidebar-section-label {
    margin: 0 12px 10px;
    color: rgba(255, 255, 255, 0.35);
    font-size: 0.68rem;
    font-weight: 750;
    letter-spacing: 0.13em;
    text-transform: uppercase;
}

.sidebar-section-spaced {
    margin-top: 28px;
}

.sidebar-link {
    position: relative;
    display: flex;
    min-height: 48px;
    align-items: center;
    gap: 13px;
    margin-bottom: 4px;
    padding: 10px 13px;
    overflow: hidden;
    border: 1px solid transparent;
    border-radius: var(--lcp-radius-md);
    color: rgba(255, 255, 255, 0.68);
    font-size: 0.9rem;
    font-weight: 600;
    transition:
        color var(--lcp-transition),
        background var(--lcp-transition),
        border-color var(--lcp-transition),
        transform var(--lcp-transition);
}

.sidebar-link::before {
    position: absolute;
    top: 50%;
    left: 0;
    width: 3px;
    height: 0;
    border-radius: 0 999px 999px 0;
    background: var(--lcp-cyan-400);
    content: "";
    transform: translateY(-50%);
    transition: height var(--lcp-transition);
}

.sidebar-link:hover {
    color: var(--lcp-white);
    background: rgba(255, 255, 255, 0.07);
    transform: translateX(2px);
}

.sidebar-link.active {
    color: var(--lcp-white);
    border-color: rgba(55, 210, 239, 0.12);
    background:
        linear-gradient(
            90deg,
            rgba(25, 194, 230, 0.18),
            rgba(25, 194, 230, 0.07)
        );
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.04);
}

.sidebar-link.active::before {
    height: 26px;
}

.sidebar-icon {
    display: inline-flex;
    width: 28px;
    height: 28px;
    flex: 0 0 28px;
    align-items: center;
    justify-content: center;
    border-radius: 8px;
    color: rgba(255, 255, 255, 0.5);
    font-size: 1rem;
    transition:
        color var(--lcp-transition),
        background var(--lcp-transition);
}

.sidebar-link:hover .sidebar-icon,
.sidebar-link.active .sidebar-icon {
    color: var(--lcp-cyan-300);
    background: rgba(25, 194, 230, 0.08);
}

.sidebar-count {
    display: inline-flex;
    min-width: 24px;
    height: 24px;
    align-items: center;
    justify-content: center;
    margin-left: auto;
    padding: 0 7px;
    border: 1px solid rgba(55, 210, 239, 0.18);
    border-radius: 999px;
    color: var(--lcp-cyan-300);
    background: rgba(25, 194, 230, 0.1);
    font-size: 0.72rem;
    font-weight: 750;
}

.status-dot {
    display: inline-block;
    width: 8px;
    height: 8px;
    margin-left: auto;
    border-radius: 50%;
    background: var(--lcp-slate-400);
    box-shadow: 0 0 0 4px rgba(148, 163, 184, 0.1);
}

.status-dot-success {
    background: var(--lcp-green-500);
    box-shadow:
        0 0 0 4px rgba(34, 197, 94, 0.12),
        0 0 14px rgba(34, 197, 94, 0.55);
}

.sidebar-footer {
    position: relative;
    z-index: 1;
    padding: 16px;
    border-top: 1px solid rgba(255, 255, 255, 0.07);
}

.sidebar-health-card {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 14px;
    padding: 13px;
    border: 1px solid rgba(34, 197, 94, 0.15);
    border-radius: var(--lcp-radius-md);
    background: rgba(34, 197, 94, 0.08);
}

.sidebar-health-icon {
    display: inline-flex;
    width: 34px;
    height: 34px;
    flex: 0 0 34px;
    align-items: center;
    justify-content: center;
    border-radius: 10px;
    color: #7bf1a8;
    background: rgba(34, 197, 94, 0.12);
    font-size: 0.95rem;
}

.sidebar-health-card div:last-child {
    display: flex;
    min-width: 0;
    flex-direction: column;
}

.sidebar-health-card strong {
    color: rgba(255, 255, 255, 0.88);
    font-size: 0.75rem;
    font-weight: 700;
}

.sidebar-health-card span {
    margin-top: 2px;
    color: rgba(255, 255, 255, 0.42);
    font-size: 0.68rem;
}

.sidebar-version {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 3px;
    color: rgba(255, 255, 255, 0.3);
    font-size: 0.66rem;
}

.sidebar-version strong {
    color: rgba(255, 255, 255, 0.48);
    font-weight: 700;
}

/* --------------------------------------------------------------
   Header
-------------------------------------------------------------- */

.portal-header {
    position: sticky;
    z-index: 1020;
    top: 0;
    display: flex;
    min-height: var(--lcp-header-height);
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    padding: 14px 30px;
    border-bottom: 1px solid rgba(226, 232, 240, 0.8);
    background: rgba(248, 250, 252, 0.86);
    backdrop-filter: blur(18px);
    -webkit-backdrop-filter: blur(18px);
}

.portal-header-left {
    display: flex;
    min-width: 0;
    align-items: center;
    gap: 15px;
}

.portal-page-heading {
    min-width: 0;
}

.portal-page-heading h1 {
    margin: 0;
    overflow: hidden;
    color: var(--lcp-slate-950);
    font-size: clamp(1.35rem, 2vw, 1.75rem);
    font-weight: 750;
    letter-spacing: -0.035em;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.portal-page-heading p {
    margin: 4px 0 0;
    overflow: hidden;
    color: var(--lcp-slate-500);
    font-size: 0.86rem;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.portal-header-actions {
    display: flex;
    flex: 0 0 auto;
    align-items: center;
    gap: 8px;
}

.portal-menu-button,
.portal-icon-button {
    display: inline-flex;
    width: 42px;
    height: 42px;
    align-items: center;
    justify-content: center;
    padding: 0;
    border: 1px solid var(--lcp-slate-200);
    border-radius: 11px;
    color: var(--lcp-slate-600);
    background: rgba(255, 255, 255, 0.86);
    box-shadow: var(--lcp-shadow-sm);
    transition:
        color var(--lcp-transition),
        border-color var(--lcp-transition),
        background var(--lcp-transition),
        box-shadow var(--lcp-transition),
        transform var(--lcp-transition);
}

.portal-menu-button:hover,
.portal-icon-button:hover {
    color: var(--lcp-blue-800);
    border-color: rgba(25, 194, 230, 0.35);
    background: var(--lcp-white);
    box-shadow: var(--lcp-shadow-md);
    transform: translateY(-1px);
}

.portal-menu-button i {
    font-size: 1.45rem;
}

.portal-icon-button i {
    font-size: 1rem;
}

.notification-indicator {
    position: absolute;
    top: 8px;
    right: 8px;
    display: inline-block;
    width: 7px;
    height: 7px;
    border: 2px solid var(--lcp-white);
    border-radius: 50%;
    background: var(--lcp-cyan-500);
    box-sizing: content-box;
}

.portal-user-button {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-left: 3px;
    padding: 5px 11px 5px 5px;
    border: 1px solid transparent;
    border-radius: 14px;
    color: var(--lcp-slate-800);
    background: transparent;
    transition:
        border-color var(--lcp-transition),
        background var(--lcp-transition),
        box-shadow var(--lcp-transition);
}

.portal-user-button:hover,
.portal-user-button.show {
    color: var(--lcp-slate-900);
    border-color: var(--lcp-slate-200);
    background: var(--lcp-white);
    box-shadow: var(--lcp-shadow-sm);
}

.portal-user-button::after {
    margin-left: 2px;
    color: var(--lcp-slate-400);
}

.portal-user-avatar {
    display: inline-flex;
    width: 39px;
    height: 39px;
    flex: 0 0 39px;
    align-items: center;
    justify-content: center;
    border: 1px solid rgba(25, 194, 230, 0.18);
    border-radius: 12px;
    color: var(--lcp-blue-900);
    background:
        linear-gradient(
            145deg,
            var(--lcp-cyan-100),
            #d6f6fc
        );
    font-size: 0.78rem;
    font-weight: 800;
    letter-spacing: 0.03em;
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.8);
}

.portal-user-copy {
    flex-direction: column;
    align-items: flex-start;
    line-height: 1.2;
}

.portal-user-copy strong {
    color: var(--lcp-slate-800);
    font-size: 0.79rem;
    font-weight: 700;
}

.portal-user-copy small {
    margin-top: 3px;
    color: var(--lcp-slate-400);
    font-size: 0.65rem;
}

.portal-user-menu {
    min-width: 230px;
    margin-top: 10px !important;
    padding: 8px;
    border: 1px solid var(--lcp-slate-200);
    border-radius: 14px;
    background: rgba(255, 255, 255, 0.98);
    box-shadow: var(--lcp-shadow-lg);
}

.portal-user-menu-header {
    display: flex;
    flex-direction: column;
    padding: 10px 12px 7px;
}

.portal-user-menu-header strong {
    color: var(--lcp-slate-900);
    font-size: 0.84rem;
}

.portal-user-menu-header span {
    margin-top: 3px;
    color: var(--lcp-slate-500);
    font-size: 0.72rem;
}

.portal-user-menu .dropdown-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 9px 11px;
    border-radius: 9px;
    color: var(--lcp-slate-600);
    font-size: 0.82rem;
    font-weight: 550;
    transition:
        color var(--lcp-transition),
        background var(--lcp-transition);
}

.portal-user-menu .dropdown-item:hover {
    color: var(--lcp-blue-900);
    background: var(--lcp-slate-100);
}

.portal-user-menu .dropdown-item i {
    width: 18px;
    color: var(--lcp-slate-400);
}

.portal-user-menu .dropdown-divider {
    margin: 7px 4px;
    border-color: var(--lcp-slate-200);
}

/* --------------------------------------------------------------
   Main content
-------------------------------------------------------------- */

.portal-content {
    width: 100%;
    flex: 1;
    padding: 28px 30px 36px;
}

.portal-content > *:first-child {
    margin-top: 0;
}

.portal-content > *:last-child {
    margin-bottom: 0;
}

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

.portal-card {
    position: relative;
    overflow: hidden;
    border: 1px solid rgba(226, 232, 240, 0.92);
    border-radius: var(--lcp-radius-lg);
    background: rgba(255, 255, 255, 0.94);
    box-shadow: var(--lcp-shadow-sm);
    transition:
        border-color var(--lcp-transition),
        box-shadow var(--lcp-transition),
        transform var(--lcp-transition);
}

.portal-card:hover {
    border-color: rgba(25, 194, 230, 0.2);
    box-shadow: var(--lcp-shadow-md);
}

.portal-card-interactive:hover {
    transform: translateY(-3px);
}

.portal-card-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 18px;
    padding: 21px 22px 17px;
    border-bottom: 1px solid var(--lcp-slate-100);
}

.portal-card-header h2,
.portal-card-header h3 {
    margin: 0;
    color: var(--lcp-slate-900);
    font-weight: 720;
    letter-spacing: -0.025em;
}

.portal-card-header h2 {
    font-size: 1rem;
}

.portal-card-header h3 {
    font-size: 0.92rem;
}

.portal-card-header p {
    margin: 5px 0 0;
    color: var(--lcp-slate-500);
    font-size: 0.78rem;
}

.portal-card-body {
    padding: 22px;
}

.portal-card-footer {
    padding: 15px 22px;
    border-top: 1px solid var(--lcp-slate-100);
    background: rgba(248, 250, 252, 0.7);
}

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

.stat-card {
    position: relative;
    min-height: 150px;
    padding: 22px;
    overflow: hidden;
    border: 1px solid rgba(226, 232, 240, 0.92);
    border-radius: var(--lcp-radius-lg);
    background: rgba(255, 255, 255, 0.96);
    box-shadow: var(--lcp-shadow-sm);
    transition:
        border-color var(--lcp-transition),
        box-shadow var(--lcp-transition),
        transform var(--lcp-transition);
}

.stat-card::after {
    position: absolute;
    top: -44px;
    right: -44px;
    width: 125px;
    height: 125px;
    border-radius: 50%;
    background: rgba(25, 194, 230, 0.06);
    content: "";
}

.stat-card:hover {
    border-color: rgba(25, 194, 230, 0.2);
    box-shadow: var(--lcp-shadow-md);
    transform: translateY(-2px);
}

.stat-card-header {
    position: relative;
    z-index: 1;
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 14px;
}

.stat-card-label {
    color: var(--lcp-slate-500);
    font-size: 0.78rem;
    font-weight: 650;
}

.stat-card-icon {
    display: inline-flex;
    width: 42px;
    height: 42px;
    flex: 0 0 42px;
    align-items: center;
    justify-content: center;
    border-radius: 12px;
    color: var(--lcp-blue-800);
    background: var(--lcp-cyan-100);
    font-size: 1rem;
}

.stat-card-value {
    position: relative;
    z-index: 1;
    margin-top: 14px;
    color: var(--lcp-slate-950);
    font-size: 2rem;
    font-weight: 780;
    letter-spacing: -0.05em;
    line-height: 1;
}

.stat-card-detail {
    position: relative;
    z-index: 1;
    display: flex;
    align-items: center;
    gap: 7px;
    margin-top: 12px;
    color: var(--lcp-slate-500);
    font-size: 0.72rem;
}

.stat-card-detail-success {
    color: #16803b;
}

.stat-card-detail-warning {
    color: #b76c00;
}

/* --------------------------------------------------------------
   Buttons
-------------------------------------------------------------- */

.btn-lcp-primary {
    display: inline-flex;
    min-height: 42px;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 9px 16px;
    border: 1px solid var(--lcp-blue-900);
    border-radius: 11px;
    color: var(--lcp-white);
    background:
        linear-gradient(
            135deg,
            var(--lcp-blue-800),
            var(--lcp-blue-900)
        );
    box-shadow:
        0 8px 18px rgba(11, 37, 69, 0.16);
    font-size: 0.82rem;
    font-weight: 700;
    transition:
        border-color var(--lcp-transition),
        background var(--lcp-transition),
        box-shadow var(--lcp-transition),
        transform var(--lcp-transition);
}

.btn-lcp-primary:hover {
    color: var(--lcp-white);
    border-color: var(--lcp-blue-700);
    background:
        linear-gradient(
            135deg,
            var(--lcp-blue-700),
            var(--lcp-blue-900)
        );
    box-shadow:
        0 12px 24px rgba(11, 37, 69, 0.22);
    transform: translateY(-1px);
}

.btn-lcp-secondary {
    display: inline-flex;
    min-height: 42px;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 9px 16px;
    border: 1px solid var(--lcp-slate-200);
    border-radius: 11px;
    color: var(--lcp-slate-700);
    background: var(--lcp-white);
    box-shadow: var(--lcp-shadow-sm);
    font-size: 0.82rem;
    font-weight: 650;
    transition:
        color var(--lcp-transition),
        border-color var(--lcp-transition),
        background var(--lcp-transition),
        box-shadow var(--lcp-transition),
        transform var(--lcp-transition);
}

.btn-lcp-secondary:hover {
    color: var(--lcp-blue-900);
    border-color: rgba(25, 194, 230, 0.35);
    background: var(--lcp-cyan-100);
    box-shadow: var(--lcp-shadow-md);
    transform: translateY(-1px);
}

.btn-lcp-danger {
    display: inline-flex;
    min-height: 42px;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 9px 16px;
    border: 1px solid rgba(239, 68, 68, 0.22);
    border-radius: 11px;
    color: #b42323;
    background: var(--lcp-red-100);
    font-size: 0.82rem;
    font-weight: 650;
    transition:
        border-color var(--lcp-transition),
        background var(--lcp-transition),
        transform var(--lcp-transition);
}

.btn-lcp-danger:hover {
    color: #8f1515;
    border-color: rgba(239, 68, 68, 0.35);
    background: #fecaca;
    transform: translateY(-1px);
}

/* --------------------------------------------------------------
   Status badges
-------------------------------------------------------------- */

.status-badge {
    display: inline-flex;
    min-height: 28px;
    align-items: center;
    gap: 7px;
    padding: 5px 10px;
    border-radius: 999px;
    font-size: 0.7rem;
    font-weight: 750;
    letter-spacing: 0.01em;
}

.status-badge::before {
    display: inline-block;
    width: 7px;
    height: 7px;
    border-radius: 50%;
    content: "";
}

.status-badge-success {
    color: #15753a;
    background: var(--lcp-green-100);
}

.status-badge-success::before {
    background: var(--lcp-green-500);
    box-shadow: 0 0 0 3px rgba(34, 197, 94, 0.13);
}

.status-badge-warning {
    color: #9a5b00;
    background: var(--lcp-amber-100);
}

.status-badge-warning::before {
    background: var(--lcp-amber-500);
}

.status-badge-danger {
    color: #a72323;
    background: var(--lcp-red-100);
}

.status-badge-danger::before {
    background: var(--lcp-red-500);
}

.status-badge-neutral {
    color: var(--lcp-slate-600);
    background: var(--lcp-slate-100);
}

.status-badge-neutral::before {
    background: var(--lcp-slate-400);
}

/* --------------------------------------------------------------
   Forms
-------------------------------------------------------------- */

.form-label {
    margin-bottom: 7px;
    color: var(--lcp-slate-700);
    font-size: 0.78rem;
    font-weight: 700;
}

.form-control,
.form-select {
    min-height: 44px;
    border: 1px solid var(--lcp-slate-200);
    border-radius: 11px;
    color: var(--lcp-slate-800);
    background-color: var(--lcp-white);
    box-shadow: none;
    font-size: 0.86rem;
    transition:
        border-color var(--lcp-transition),
        box-shadow var(--lcp-transition);
}

.form-control::placeholder {
    color: var(--lcp-slate-400);
}

.form-control:focus,
.form-select:focus {
    border-color: var(--lcp-cyan-500);
    box-shadow:
        0 0 0 4px rgba(25, 194, 230, 0.11);
}

.form-text {
    margin-top: 7px;
    color: var(--lcp-slate-500);
    font-size: 0.72rem;
}

/* --------------------------------------------------------------
   Tables
-------------------------------------------------------------- */

.portal-table-wrapper {
    overflow: hidden;
    border: 1px solid var(--lcp-slate-200);
    border-radius: var(--lcp-radius-lg);
    background: var(--lcp-white);
    box-shadow: var(--lcp-shadow-sm);
}

.portal-table {
    width: 100%;
    margin: 0;
    border-collapse: collapse;
}

.portal-table thead th {
    padding: 13px 18px;
    border-bottom: 1px solid var(--lcp-slate-200);
    color: var(--lcp-slate-500);
    background: var(--lcp-slate-50);
    font-size: 0.68rem;
    font-weight: 750;
    letter-spacing: 0.07em;
    text-transform: uppercase;
    white-space: nowrap;
}

.portal-table tbody td {
    padding: 15px 18px;
    border-bottom: 1px solid var(--lcp-slate-100);
    color: var(--lcp-slate-700);
    font-size: 0.8rem;
    vertical-align: middle;
}

.portal-table tbody tr:last-child td {
    border-bottom: 0;
}

.portal-table tbody tr {
    transition: background var(--lcp-transition);
}

.portal-table tbody tr:hover {
    background: rgba(231, 250, 255, 0.42);
}

/* --------------------------------------------------------------
   Empty states
-------------------------------------------------------------- */

.portal-empty-state {
    display: flex;
    min-height: 320px;
    align-items: center;
    justify-content: center;
    padding: 42px 24px;
    text-align: center;
}

.portal-empty-state-inner {
    max-width: 430px;
}

.portal-empty-state-icon {
    display: inline-flex;
    width: 72px;
    height: 72px;
    align-items: center;
    justify-content: center;
    margin-bottom: 20px;
    border: 1px solid rgba(25, 194, 230, 0.16);
    border-radius: 22px;
    color: var(--lcp-blue-800);
    background:
        linear-gradient(
            145deg,
            var(--lcp-cyan-100),
            rgba(255, 255, 255, 0.8)
        );
    box-shadow: var(--lcp-shadow-md);
    font-size: 1.6rem;
}

.portal-empty-state h2,
.portal-empty-state h3 {
    margin: 0;
    color: var(--lcp-slate-900);
    font-size: 1.1rem;
    font-weight: 750;
    letter-spacing: -0.025em;
}

.portal-empty-state p {
    margin: 10px auto 20px;
    color: var(--lcp-slate-500);
    font-size: 0.84rem;
    line-height: 1.65;
}

/* --------------------------------------------------------------
   Alerts
-------------------------------------------------------------- */

.portal-alert {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    padding: 15px 17px;
    border: 1px solid transparent;
    border-radius: var(--lcp-radius-md);
    font-size: 0.8rem;
}

.portal-alert i {
    margin-top: 1px;
    font-size: 1rem;
}

.portal-alert strong {
    display: block;
    margin-bottom: 2px;
    font-weight: 750;
}

.portal-alert-success {
    color: #166534;
    border-color: rgba(34, 197, 94, 0.18);
    background: var(--lcp-green-100);
}

.portal-alert-warning {
    color: #8a5200;
    border-color: rgba(245, 158, 11, 0.2);
    background: var(--lcp-amber-100);
}

.portal-alert-danger {
    color: #991b1b;
    border-color: rgba(239, 68, 68, 0.2);
    background: var(--lcp-red-100);
}

.portal-alert-info {
    color: var(--lcp-blue-800);
    border-color: rgba(25, 194, 230, 0.2);
    background: var(--lcp-cyan-100);
}

/* --------------------------------------------------------------
   Footer
-------------------------------------------------------------- */

.portal-footer {
    display: flex;
    min-height: 62px;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    padding: 18px 30px;
    border-top: 1px solid var(--lcp-slate-200);
    color: var(--lcp-slate-400);
    background: rgba(255, 255, 255, 0.55);
    font-size: 0.7rem;
}

.portal-footer strong {
    color: var(--lcp-slate-500);
}

/* --------------------------------------------------------------
   Mobile offcanvas navigation
-------------------------------------------------------------- */

.portal-mobile-navigation {
    width: min(86vw, 310px) !important;
    color: rgba(255, 255, 255, 0.86);
    background:
        radial-gradient(
            circle at top left,
            rgba(55, 210, 239, 0.18),
            transparent 18rem
        ),
        linear-gradient(
            180deg,
            var(--lcp-blue-900) 0%,
            var(--lcp-blue-950) 100%
        );
}

.portal-mobile-navigation .offcanvas-header {
    min-height: 78px;
    padding: 16px 20px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.portal-mobile-navigation .offcanvas-body {
    padding: 0;
}

.portal-mobile-navigation .sidebar-navigation {
    padding-top: 20px;
}

/* --------------------------------------------------------------
   Utility helpers
-------------------------------------------------------------- */

.text-lcp-primary {
    color: var(--lcp-blue-800) !important;
}

.text-lcp-cyan {
    color: var(--lcp-cyan-500) !important;
}

.bg-lcp-soft {
    background: var(--lcp-cyan-100) !important;
}

.border-lcp-soft {
    border-color: rgba(25, 194, 230, 0.18) !important;
}

.font-weight-semibold {
    font-weight: 650 !important;
}

.font-weight-bold {
    font-weight: 750 !important;
}

/* --------------------------------------------------------------
   Responsive behaviour
-------------------------------------------------------------- */

@media (max-width: 1199.98px) {
    :root {
        --lcp-sidebar-width: 260px;
    }

    .portal-header,
    .portal-content,
    .portal-footer {
        padding-right: 24px;
        padding-left: 24px;
    }
}

@media (max-width: 991.98px) {
    .portal-main {
        margin-left: 0;
    }

    .portal-header {
        min-height: 76px;
        padding-top: 11px;
        padding-bottom: 11px;
    }

    .portal-content {
        padding-top: 22px;
    }
}

@media (max-width: 767.98px) {
    .portal-header {
        gap: 12px;
        padding-right: 16px;
        padding-left: 16px;
    }

    .portal-header-left {
        gap: 10px;
    }

    .portal-header-actions {
        gap: 5px;
    }

    .portal-page-heading h1 {
        max-width: 46vw;
        font-size: 1.25rem;
    }

    .portal-page-heading p {
        display: none;
    }

    .portal-icon-button {
        display: none;
    }

    .portal-user-button {
        margin-left: 0;
        padding-right: 6px;
    }

    .portal-user-button::after {
        display: none;
    }

    .portal-content {
        padding: 18px 16px 28px;
    }

    .portal-footer {
        flex-direction: column;
        align-items: flex-start;
        gap: 5px;
        padding: 16px;
    }

    .portal-card-header,
    .portal-card-body,
    .portal-card-footer {
        padding-right: 18px;
        padding-left: 18px;
    }

    .stat-card {
        min-height: 136px;
        padding: 18px;
    }
}

@media (max-width: 575.98px) {
    .portal-page-heading h1 {
        max-width: 40vw;
    }

    .portal-user-avatar {
        width: 38px;
        height: 38px;
        flex-basis: 38px;
    }

    .portal-table-wrapper {
        overflow-x: auto;
    }

    .portal-table {
        min-width: 680px;
    }
}

/* --------------------------------------------------------------
   Reduced motion
-------------------------------------------------------------- */

@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        scroll-behavior: auto !important;
        transition-duration: 0.01ms !important;
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
    }
}

/* --------------------------------------------------------------
   Print
-------------------------------------------------------------- */

@media print {
    .portal-sidebar,
    .portal-header,
    .portal-footer,
    .portal-mobile-navigation {
        display: none !important;
    }

    .portal-main {
        margin-left: 0;
    }

    .portal-content {
        padding: 0;
    }

    .portal-card,
    .portal-table-wrapper {
        box-shadow: none;
    }
}
/* --------------------------------------------------------------
   Dashboard
-------------------------------------------------------------- */

.dashboard-welcome {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 28px;
    margin-bottom: 24px;
    padding: 28px 30px;
    overflow: hidden;
    border: 1px solid rgba(25, 194, 230, 0.16);
    border-radius: var(--lcp-radius-xl);
    background:
        radial-gradient(
            circle at top right,
            rgba(55, 210, 239, 0.22),
            transparent 20rem
        ),
        linear-gradient(
            135deg,
            var(--lcp-blue-900),
            var(--lcp-blue-800)
        );
    box-shadow:
        0 18px 45px rgba(11, 37, 69, 0.16);
}

.dashboard-welcome::after {
    position: absolute;
    right: -70px;
    bottom: -100px;
    width: 280px;
    height: 280px;
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 50%;
    content: "";
}

.dashboard-welcome-copy {
    position: relative;
    z-index: 1;
    max-width: 680px;
}

.dashboard-eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 12px;
    color: var(--lcp-cyan-300);
    font-size: 0.72rem;
    font-weight: 750;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.dashboard-welcome h2 {
    margin: 0;
    color: var(--lcp-white);
    font-size: clamp(1.6rem, 3vw, 2.15rem);
    font-weight: 760;
    letter-spacing: -0.04em;
}

.dashboard-welcome p {
    max-width: 620px;
    margin: 10px 0 0;
    color: rgba(255, 255, 255, 0.65);
    font-size: 0.9rem;
}

.dashboard-welcome-actions {
    position: relative;
    z-index: 1;
    display: flex;
    flex: 0 0 auto;
    flex-wrap: wrap;
    gap: 10px;
}

.dashboard-welcome .btn-lcp-primary {
    color: var(--lcp-blue-950);
    border-color: var(--lcp-cyan-400);
    background: var(--lcp-cyan-400);
}

.dashboard-welcome .btn-lcp-primary:hover {
    color: var(--lcp-blue-950);
    border-color: var(--lcp-cyan-300);
    background: var(--lcp-cyan-300);
}

.dashboard-welcome .btn-lcp-secondary {
    color: var(--lcp-white);
    border-color: rgba(255, 255, 255, 0.18);
    background: rgba(255, 255, 255, 0.08);
    box-shadow: none;
}

.dashboard-welcome .btn-lcp-secondary:hover {
    color: var(--lcp-white);
    border-color: rgba(255, 255, 255, 0.3);
    background: rgba(255, 255, 255, 0.14);
}

.stat-card-icon-success {
    color: #16803b;
    background: var(--lcp-green-100);
}

.stat-card-value-status {
    font-size: 1.55rem;
    letter-spacing: -0.035em;
}

.dashboard-pulse-dot {
    display: inline-block;
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--lcp-green-500);
    box-shadow:
        0 0 0 4px rgba(34, 197, 94, 0.12),
        0 0 14px rgba(34, 197, 94, 0.45);
    animation: dashboardPulse 2s ease-in-out infinite;
}

.dashboard-text-link {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    color: var(--lcp-blue-700);
    font-size: 0.75rem;
    font-weight: 700;
}

.dashboard-text-link:hover {
    color: var(--lcp-cyan-500);
}

.dashboard-activity-body {
    padding-top: 8px;
    padding-bottom: 8px;
}

.activity-timeline {
    position: relative;
}

.activity-item {
    position: relative;
    display: flex;
    gap: 14px;
    padding: 18px 0;
}

.activity-item:not(:last-child) {
    border-bottom: 1px solid var(--lcp-slate-100);
}

.activity-icon {
    display: inline-flex;
    width: 42px;
    height: 42px;
    flex: 0 0 42px;
    align-items: center;
    justify-content: center;
    border-radius: 12px;
    font-size: 1rem;
}

.activity-icon-success {
    color: #16803b;
    background: var(--lcp-green-100);
}

.activity-icon-warning {
    color: #9a5b00;
    background: var(--lcp-amber-100);
}

.activity-icon-danger {
    color: #a72323;
    background: var(--lcp-red-100);
}

.activity-icon-neutral {
    color: var(--lcp-slate-600);
    background: var(--lcp-slate-100);
}

.activity-content {
    min-width: 0;
    flex: 1;
}

.activity-heading {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 16px;
}

.activity-heading h3 {
    margin: 0;
    color: var(--lcp-slate-800);
    font-size: 0.84rem;
    font-weight: 700;
}

.activity-heading time {
    flex: 0 0 auto;
    color: var(--lcp-slate-400);
    font-size: 0.68rem;
}

.activity-content p {
    margin: 5px 0 0;
    color: var(--lcp-slate-500);
    font-size: 0.76rem;
}

.dashboard-activity-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    color: var(--lcp-slate-400);
    font-size: 0.68rem;
}

.dashboard-activity-footer span:first-child {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    color: #16803b;
}

.dashboard-activity-empty {
    padding: 42px 20px;
    text-align: center;
}

.dashboard-quick-actions {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.dashboard-quick-action {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px;
    border: 1px solid transparent;
    border-radius: 12px;
    transition:
        border-color var(--lcp-transition),
        background var(--lcp-transition),
        transform var(--lcp-transition);
}

.dashboard-quick-action:hover {
    border-color: rgba(25, 194, 230, 0.18);
    background: var(--lcp-cyan-100);
    transform: translateX(2px);
}

.dashboard-quick-action-icon {
    display: inline-flex;
    width: 38px;
    height: 38px;
    flex: 0 0 38px;
    align-items: center;
    justify-content: center;
    border-radius: 11px;
    color: var(--lcp-blue-800);
    background: var(--lcp-slate-100);
}

.dashboard-quick-action > span:nth-child(2) {
    display: flex;
    min-width: 0;
    flex: 1;
    flex-direction: column;
}

.dashboard-quick-action strong {
    color: var(--lcp-slate-800);
    font-size: 0.78rem;
    font-weight: 700;
}

.dashboard-quick-action small {
    margin-top: 3px;
    color: var(--lcp-slate-500);
    font-size: 0.68rem;
}

.dashboard-quick-action > i {
    color: var(--lcp-slate-300);
    font-size: 0.75rem;
}

.dashboard-platform-card {
    background:
        radial-gradient(
            circle at top right,
            rgba(25, 194, 230, 0.08),
            transparent 14rem
        ),
        var(--lcp-white);
}

.dashboard-platform-heading {
    display: flex;
    align-items: center;
    gap: 13px;
    margin-bottom: 22px;
}

.dashboard-platform-logo {
    position: relative;
    display: inline-flex;
    width: 48px;
    height: 48px;
    flex: 0 0 48px;
    align-items: center;
    justify-content: center;
}

.dashboard-platform-logo i {
    position: absolute;
    color: var(--lcp-cyan-500);
    font-size: 3rem;
}

.dashboard-platform-logo strong {
    position: relative;
    z-index: 1;
    color: var(--lcp-blue-950);
    font-size: 1rem;
}

.dashboard-platform-heading h2 {
    margin: 0;
    color: var(--lcp-slate-900);
    font-size: 0.92rem;
    font-weight: 750;
}

.dashboard-platform-heading p {
    margin: 4px 0 0;
    color: var(--lcp-slate-500);
    font-size: 0.7rem;
}

.dashboard-platform-status {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 15px;
}

.dashboard-platform-status div {
    display: flex;
    flex-direction: column;
    padding: 12px;
    border: 1px solid var(--lcp-slate-100);
    border-radius: 11px;
    background: rgba(248, 250, 252, 0.76);
}

.dashboard-platform-status span {
    color: var(--lcp-slate-400);
    font-size: 0.64rem;
}

.dashboard-platform-status strong {
    margin-top: 4px;
    color: var(--lcp-slate-700);
    font-size: 0.76rem;
    font-weight: 700;
}

.dashboard-platform-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-top: 20px;
    padding-top: 17px;
    border-top: 1px solid var(--lcp-slate-100);
}

.dashboard-platform-footer a {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    color: var(--lcp-blue-700);
    font-size: 0.68rem;
    font-weight: 700;
}

@keyframes dashboardPulse {
    0%,
    100% {
        box-shadow:
            0 0 0 4px rgba(34, 197, 94, 0.12),
            0 0 10px rgba(34, 197, 94, 0.3);
    }

    50% {
        box-shadow:
            0 0 0 7px rgba(34, 197, 94, 0.05),
            0 0 18px rgba(34, 197, 94, 0.55);
    }
}

@media (max-width: 991.98px) {
    .dashboard-welcome {
        align-items: flex-start;
        flex-direction: column;
    }
}

@media (max-width: 575.98px) {
    .dashboard-welcome {
        padding: 22px 20px;
    }

    .dashboard-welcome-actions {
        width: 100%;
        flex-direction: column;
    }

    .dashboard-welcome-actions a {
        width: 100%;
    }

    .activity-heading {
        flex-direction: column;
        gap: 4px;
    }

    .dashboard-activity-footer,
    .dashboard-platform-footer {
        align-items: flex-start;
        flex-direction: column;
    }

    .dashboard-platform-status {
        grid-template-columns: 1fr;
    }
}
/* --------------------------------------------------------------
   Framework core: command palette and notifications
-------------------------------------------------------------- */

body.command-palette-open { overflow: hidden; }

.portal-command-palette {
    position: fixed;
    z-index: 2000;
    inset: 0;
    display: grid;
    place-items: start center;
    padding: min(14vh, 120px) 20px 20px;
}

.portal-command-palette[hidden] { display: none; }

.portal-command-backdrop {
    position: absolute;
    inset: 0;
    border: 0;
    background: rgba(7, 26, 47, 0.62);
    backdrop-filter: blur(7px);
}

.portal-command-dialog {
    position: relative;
    width: min(660px, 100%);
    overflow: hidden;
    border: 1px solid rgba(203, 213, 225, 0.9);
    border-radius: 18px;
    background: var(--lcp-white);
    box-shadow: 0 30px 80px rgba(7, 26, 47, 0.3);
    animation: portalCommandEnter 160ms ease-out;
}

.portal-command-search {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 15px 18px;
    border-bottom: 1px solid var(--lcp-slate-200);
}

.portal-command-search > i { color: var(--lcp-cyan-500); font-size: 1.15rem; }
.portal-command-search input { flex: 1; min-width: 0; border: 0; outline: 0; color: var(--lcp-slate-900); background: transparent; font-size: 1rem; }
.portal-command-search input::placeholder { color: var(--lcp-slate-400); }
.portal-command-search kbd,
.portal-command-footer kbd { border: 1px solid var(--lcp-slate-200); border-bottom-width: 2px; border-radius: 6px; color: var(--lcp-slate-500); background: var(--lcp-slate-50); box-shadow: none; font-family: inherit; font-size: 0.66rem; }

.portal-command-results { max-height: min(52vh, 430px); overflow-y: auto; padding: 10px; }
.portal-command-label { margin: 4px 8px 8px; color: var(--lcp-slate-400); font-size: 0.67rem; font-weight: 750; letter-spacing: 0.08em; text-transform: uppercase; }
.portal-command-item { display: flex; align-items: center; gap: 12px; padding: 10px 11px; border-radius: 11px; }
.portal-command-item:hover,
.portal-command-item.is-active { color: var(--lcp-slate-900); background: var(--lcp-cyan-100); }
.portal-command-item > span { display: grid; width: 38px; height: 38px; flex: 0 0 38px; place-items: center; border-radius: 10px; color: var(--lcp-blue-700); background: var(--lcp-slate-100); }
.portal-command-item > div { display: flex; min-width: 0; flex: 1; flex-direction: column; }
.portal-command-item strong { font-size: 0.82rem; }
.portal-command-item small { margin-top: 2px; color: var(--lcp-slate-500); font-size: 0.69rem; }
.portal-command-item > i { color: var(--lcp-slate-400); }
.portal-command-empty { display: flex; align-items: center; flex-direction: column; padding: 34px 20px; color: var(--lcp-slate-500); text-align: center; }
.portal-command-empty[hidden] { display: none; }
.portal-command-empty i { margin-bottom: 8px; font-size: 1.5rem; }
.portal-command-empty span { margin-top: 3px; font-size: 0.75rem; }
.portal-command-footer { display: flex; align-items: center; gap: 18px; padding: 10px 18px; border-top: 1px solid var(--lcp-slate-200); color: var(--lcp-slate-500); background: var(--lcp-slate-50); font-size: 0.66rem; }
.portal-command-footer span { display: inline-flex; align-items: center; gap: 4px; }

.portal-notifications { width: min(420px, 100vw) !important; }
.portal-notifications .offcanvas-header { align-items: flex-start; padding: 24px; border-bottom: 1px solid var(--lcp-slate-200); }
.portal-notifications .offcanvas-header h2 { margin: 0; color: var(--lcp-slate-900); font-size: 1.1rem; font-weight: 750; }
.portal-notifications .offcanvas-header p { margin: 4px 0 0; color: var(--lcp-slate-500); font-size: 0.75rem; }
.portal-notifications .offcanvas-body { padding: 12px; }
.portal-notification-list { display: flex; flex-direction: column; gap: 6px; }
.portal-notification-item { position: relative; display: flex; gap: 12px; padding: 14px; border-radius: 12px; }
.portal-notification-item:hover { background: var(--lcp-slate-50); }
.portal-notification-item.is-unread::after { position: absolute; top: 18px; right: 15px; width: 7px; height: 7px; border-radius: 50%; background: var(--lcp-cyan-500); content: ''; }
.portal-notification-icon { display: grid; width: 38px; height: 38px; flex: 0 0 38px; place-items: center; border-radius: 10px; color: var(--lcp-blue-700); background: var(--lcp-cyan-100); }
.portal-notification-icon.portal-notification-success { color: #16803b; background: var(--lcp-green-100); }
.portal-notification-item div { min-width: 0; padding-right: 12px; }
.portal-notification-item strong { display: block; color: var(--lcp-slate-800); font-size: 0.78rem; }
.portal-notification-item p { margin: 3px 0; color: var(--lcp-slate-500); font-size: 0.7rem; }
.portal-notification-item time { color: var(--lcp-slate-400); font-size: 0.64rem; }

@keyframes portalCommandEnter {
    from { opacity: 0; transform: translateY(-10px) scale(0.985); }
    to { opacity: 1; transform: translateY(0) scale(1); }
}

@media (max-width: 575.98px) {
    .portal-command-palette { padding: 12px; place-items: start center; }
    .portal-command-dialog { border-radius: 14px; }
    .portal-command-results { max-height: calc(100vh - 160px); }
    .portal-command-footer { display: none; }
}

@media (prefers-reduced-motion: reduce) {
    .portal-command-dialog { animation: none; }
}

/* =========================================================
   Sprint 2: theme, toast and shared modal components
   ========================================================= */

.lcp-toast-region {
    position: fixed;
    z-index: 1090;
    top: 22px;
    right: 22px;
    display: flex;
    width: min(390px, calc(100vw - 32px));
    flex-direction: column;
    gap: 10px;
    pointer-events: none;
}

.lcp-toast {
    display: grid;
    grid-template-columns: 38px minmax(0, 1fr) 30px;
    align-items: start;
    gap: 11px;
    padding: 14px;
    border: 1px solid var(--lcp-slate-200);
    border-radius: 14px;
    opacity: 0;
    color: var(--lcp-slate-800);
    background: #fff;
    box-shadow: 0 18px 45px rgba(15, 35, 58, 0.18);
    transform: translateY(-10px) scale(0.98);
    transition: opacity 180ms ease, transform 180ms ease;
    pointer-events: auto;
}

.lcp-toast.is-visible { opacity: 1; transform: translateY(0) scale(1); }
.lcp-toast.is-leaving { opacity: 0; transform: translateX(12px); }
.lcp-toast > i { display: grid; width: 38px; height: 38px; place-items: center; border-radius: 10px; font-size: 1rem; }
.lcp-toast > div { min-width: 0; }
.lcp-toast strong { display: block; margin-bottom: 2px; font-size: 0.78rem; }
.lcp-toast p { margin: 0; color: var(--lcp-slate-500); font-size: 0.72rem; line-height: 1.45; }
.lcp-toast button { display: grid; width: 30px; height: 30px; padding: 0; border: 0; place-items: center; color: var(--lcp-slate-400); background: transparent; }
.lcp-toast-success > i { color: #16803b; background: var(--lcp-green-100); }
.lcp-toast-warning > i { color: #9a6700; background: #fff4cf; }
.lcp-toast-danger > i { color: #b42318; background: #fee4e2; }
.lcp-toast-info > i { color: var(--lcp-blue-700); background: var(--lcp-cyan-100); }

.lcp-confirm-modal { overflow: hidden; border: 0; border-radius: 18px; box-shadow: 0 28px 80px rgba(15, 35, 58, 0.24); }
.lcp-confirm-modal .modal-header,
.lcp-confirm-modal .modal-footer { border-color: var(--lcp-slate-200); }
.lcp-confirm-modal .modal-title { color: var(--lcp-slate-900); font-weight: 760; }
.lcp-confirm-modal .modal-body { color: var(--lcp-slate-600); }

/* Dark theme is token-based so existing pages inherit it automatically. */
html[data-theme="dark"] {
    --lcp-slate-50: #101c2b;
    --lcp-slate-100: #152438;
    --lcp-slate-200: #26384e;
    --lcp-slate-300: #3b4d63;
    --lcp-slate-400: #8fa1b5;
    --lcp-slate-500: #a7b6c7;
    --lcp-slate-600: #c0ccd8;
    --lcp-slate-700: #d7e0e8;
    --lcp-slate-800: #edf3f8;
    --lcp-slate-900: #ffffff;
}

html[data-theme="dark"] body,
html[data-theme="dark"] .portal-main,
html[data-theme="dark"] .portal-content { background: #0c1624; }
html[data-theme="dark"] .portal-header,
html[data-theme="dark"] .portal-card,
html[data-theme="dark"] .stat-card,
html[data-theme="dark"] .dashboard-quick-actions,
html[data-theme="dark"] .portal-command-dialog,
html[data-theme="dark"] .portal-notifications,
html[data-theme="dark"] .dropdown-menu,
html[data-theme="dark"] .modal-content,
html[data-theme="dark"] .lcp-toast { background: #132235; }
html[data-theme="dark"] .portal-header,
html[data-theme="dark"] .portal-card,
html[data-theme="dark"] .stat-card,
html[data-theme="dark"] .dropdown-menu,
html[data-theme="dark"] .modal-content { border-color: #26384e; }
html[data-theme="dark"] .portal-user-button:hover,
html[data-theme="dark"] .portal-icon-button:hover,
html[data-theme="dark"] .dropdown-item:hover,
html[data-theme="dark"] .portal-notification-item:hover { background: #1b2e44; }
html[data-theme="dark"] .dropdown-item,
html[data-theme="dark"] .portal-user-menu-header strong { color: #edf3f8; }
html[data-theme="dark"] .dashboard-welcome { box-shadow: 0 24px 60px rgba(0, 0, 0, 0.26); }
html[data-theme="dark"] .portal-command-footer,
html[data-theme="dark"] .portal-command-search { background: #101c2b; }
html[data-theme="dark"] .btn-close { filter: invert(1) grayscale(100%) brightness(180%); }

@media (max-width: 575.98px) {
    .lcp-toast-region { top: 12px; right: 12px; width: calc(100vw - 24px); }
}

/* =========================================================
   Sprint 3: collapsible navigation, clock and notifications
   ========================================================= */

:root { --lcp-sidebar-collapsed-width: 86px; }

.portal-sidebar,
.portal-main,
.sidebar-brand,
.sidebar-link,
.sidebar-health-card,
.sidebar-version,
.brand-copy,
.sidebar-section-label {
    transition: width 220ms ease, margin 220ms ease, padding 220ms ease, opacity 150ms ease, transform 220ms ease;
}

.sidebar-brand { justify-content: space-between; gap: 10px; }
.sidebar-collapse-button {
    display: grid;
    width: 34px;
    height: 34px;
    flex: 0 0 34px;
    padding: 0;
    border: 1px solid rgba(255,255,255,.14);
    border-radius: 10px;
    place-items: center;
    color: rgba(255,255,255,.72);
    background: rgba(255,255,255,.06);
}
.sidebar-collapse-button:hover { color: #fff; background: rgba(255,255,255,.12); }
.sidebar-collapse-button i { font-size: .95rem; }

@media (min-width: 992px) {
    html.sidebar-collapsed .portal-sidebar { width: var(--lcp-sidebar-collapsed-width); }
    html.sidebar-collapsed .portal-main { margin-left: var(--lcp-sidebar-collapsed-width); }
    html.sidebar-collapsed .sidebar-brand { padding-right: 14px; padding-left: 14px; justify-content: center; }
    html.sidebar-collapsed .sidebar-brand .brand-copy,
    html.sidebar-collapsed .sidebar-section-label,
    html.sidebar-collapsed .sidebar-link > span:not(.sidebar-icon):not(.status-dot),
    html.sidebar-collapsed .sidebar-health-card > div:not(.sidebar-health-icon),
    html.sidebar-collapsed .sidebar-version span,
    html.sidebar-collapsed .sidebar-version strong { display: none; }
    html.sidebar-collapsed .sidebar-brand .brand-link { gap: 0; }
    html.sidebar-collapsed .sidebar-collapse-button { position: absolute; top: 72px; right: 8px; z-index: 3; width: 28px; height: 28px; border-radius: 8px; }
    html.sidebar-collapsed .sidebar-navigation { padding-right: 11px; padding-left: 11px; }
    html.sidebar-collapsed .sidebar-link { justify-content: center; min-height: 50px; padding: 8px; }
    html.sidebar-collapsed .sidebar-link .sidebar-icon { margin: 0; }
    html.sidebar-collapsed .sidebar-link::before { display: none; }
    html.sidebar-collapsed .sidebar-health-card { justify-content: center; padding: 12px 8px; }
    html.sidebar-collapsed .sidebar-version { justify-content: center; min-height: 28px; }
    html.sidebar-collapsed .sidebar-link:hover::after {
        position: fixed;
        left: calc(var(--lcp-sidebar-collapsed-width) + 10px);
        padding: 7px 10px;
        border-radius: 8px;
        color: #fff;
        background: #071a2f;
        box-shadow: 0 8px 24px rgba(0,0,0,.24);
        content: attr(aria-label);
        font-size: .72rem;
        font-weight: 650;
        white-space: nowrap;
    }
}

.portal-clock {
    align-items: center;
    gap: 9px;
    min-width: 132px;
    padding: 7px 12px;
    border: 1px solid var(--lcp-slate-200);
    border-radius: 12px;
    color: var(--lcp-slate-600);
    background: var(--lcp-white);
}
.portal-clock > i { color: var(--lcp-cyan-500); }
.portal-clock > span { display: flex; flex-direction: column; line-height: 1.15; }
.portal-clock strong { color: var(--lcp-slate-900); font-size: .78rem; font-variant-numeric: tabular-nums; letter-spacing: .02em; }
.portal-clock small { margin-top: 3px; color: var(--lcp-slate-500); font-size: .62rem; }

.portal-notification-toolbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 5px 4px 12px;
    color: var(--lcp-slate-500);
    font-size: .7rem;
}
.portal-notification-toolbar strong { color: var(--lcp-slate-900); }
.portal-notification-toolbar button {
    padding: 5px 8px;
    border: 0;
    border-radius: 7px;
    color: var(--lcp-blue-700);
    background: transparent;
    font-size: .68rem;
    font-weight: 700;
}
.portal-notification-toolbar button:hover { background: var(--lcp-cyan-100); }
.portal-notification-read {
    position: absolute;
    top: 35px;
    right: 9px;
    display: grid;
    width: 27px;
    height: 27px;
    padding: 0;
    border: 0;
    border-radius: 8px;
    place-items: center;
    opacity: 0;
    color: var(--lcp-blue-700);
    background: var(--lcp-cyan-100);
    transition: opacity 150ms ease;
}
.portal-notification-item:hover .portal-notification-read,
.portal-notification-read:focus-visible { opacity: 1; }
.portal-notification-item:not(.is-unread) .portal-notification-read { display: none; }
.portal-notification-footer-link {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 7px;
    margin-top: 12px;
    padding: 12px;
    border-top: 1px solid var(--lcp-slate-200);
    color: var(--lcp-blue-700);
    font-size: .72rem;
    font-weight: 700;
}

html[data-theme="dark"] .portal-clock { border-color: #26384e; background: #132235; }
html[data-theme="dark"] .portal-notification-toolbar button:hover,
html[data-theme="dark"] .portal-notification-read { background: #1b2e44; }

/* Sprint 4: navigation feedback and shortcut guide */
.portal-navigation-progress {
    position: fixed;
    inset: 0 0 auto 0;
    z-index: 9999;
    height: 3px;
    pointer-events: none;
    opacity: 0;
    overflow: hidden;
}

.portal-navigation-progress span {
    display: block;
    width: 18%;
    height: 100%;
    background: linear-gradient(90deg, #14b8d4, #38d9f5);
    box-shadow: 0 0 12px rgba(56, 217, 245, .65);
    transform: translateX(-110%);
}

.portal-navigation-progress.is-active { opacity: 1; }
.portal-navigation-progress.is-active span { animation: lcp-navigation-progress 1.15s ease-in-out infinite; }
.portal-navigation-progress.is-complete span { width: 100%; transform: translateX(0); animation: none; transition: width .18s ease, transform .18s ease; }

@keyframes lcp-navigation-progress {
    0% { transform: translateX(-110%); }
    55% { transform: translateX(260%); }
    100% { transform: translateX(620%); }
}

.portal-shortcuts-modal { border: 0; border-radius: 20px; overflow: hidden; }
.portal-shortcuts-modal .modal-header { align-items: flex-start; padding: 1.4rem 1.5rem 1rem; }
.portal-shortcuts-modal .modal-title { font-size: 1.15rem; font-weight: 800; }
.portal-shortcuts-modal .modal-header p { margin: .2rem 0 0; color: var(--portal-muted, #718096); font-size: .88rem; }
.portal-shortcuts-modal .modal-body { padding: .4rem 1.5rem 1.5rem; }
.portal-shortcut-row { display: flex; align-items: center; gap: .42rem; min-height: 48px; border-bottom: 1px solid rgba(148, 163, 184, .18); }
.portal-shortcut-row:last-child { border-bottom: 0; }
.portal-shortcut-row span { margin-right: auto; font-weight: 650; }
.portal-shortcut-row kbd { min-width: 29px; padding: .28rem .48rem; border: 1px solid rgba(148, 163, 184, .35); border-radius: 7px; background: rgba(148, 163, 184, .12); color: inherit; box-shadow: 0 1px 0 rgba(15, 23, 42, .12); text-align: center; font-size: .76rem; }

@media (prefers-reduced-motion: reduce) {
    .portal-navigation-progress.is-active span { animation: none; width: 70%; transform: translateX(0); }
}
