:root {
    --ip-background: #f3f6f8;
    --ip-panel: #fff;
    --ip-border: #dce4ea;
    --ip-muted: #506277;
    --ip-text: #16253a;
    --ip-accent: #076e67;
    --ip-sidebar: #122737;
    --ip-nav: #c5d5de;
    --ip-active: #22475a;
    --ip-sidebar-width: 238px;
    --ip-topbar: 65px;
    --bs-body-font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}
[data-bs-theme="dark"] {
    --ip-background: #101a23;
    --ip-panel: #182734;
    --ip-border: #304251;
    --ip-muted: #a7b8c7;
    --ip-text: #e1edf6;
    --ip-accent: #70d9ca;
    --ip-sidebar: #0d1821;
    --ip-nav: #bfcfda;
    --ip-active: #213b4b;
}
body { background: var(--ip-background); color: var(--ip-text); font-size: .92rem; }
a { color: var(--ip-accent); text-underline-offset: .2em; }
a:hover { color: var(--ip-accent); }
[hidden] { display: none !important; }
.sidebar {
    width: var(--ip-sidebar-width); position: fixed; inset: 0 auto 0 0; z-index: 5;
    background: var(--ip-sidebar); color: var(--ip-nav); display: flex; flex-direction: column;
    padding: 27px 15px 16px; overflow-y: auto; transition: transform .18s ease;
}
.brand { display: flex; gap: 12px; align-items: center; color: #fff; text-decoration: none; font-size: 1.24rem; font-weight: 740; letter-spacing: -.03em; padding: 0 8px; line-height: 1.2; }
.brand:hover { color: #fff; }
.brand small { display: block; color: #b2c6cd; font-size: .59rem; margin-top: 4px; letter-spacing: .095em; }
.brand-mark { display: grid; place-items: center; width: 36px; height: 36px; border-radius: 9px; background: #88e1d1; color: #123d42; font: 800 1.75rem/1 system-ui; }
.sidebar nav { margin-top: 38px; display: grid; gap: 5px; }
.nav-item { display: flex; align-items: center; gap: 11px; color: var(--ip-nav); padding: 10px 11px; border-radius: 8px; text-decoration: none; font-weight: 530; }
.nav-item:hover, .nav-item.selected { color: #fff; background: var(--ip-active); }
.nav-item.selected { box-shadow: inset 3px 0 #80e2d1; }
.nav-icon { font-size: 1.15rem; width: 21px; text-align: center; }
.sidebar-foot { margin-top: auto; padding: 16px 10px 5px; display: flex; gap: 8px; align-items: center; font-size: .78rem; }
.sidebar-foot .state-dot { color: #80e2d1; }
.topbar {
    position: sticky; top: 0; z-index: 4; height: var(--ip-topbar); display: flex; gap: 14px; align-items: center;
    padding: 0 26px; margin-left: var(--ip-sidebar-width); border-bottom: 1px solid var(--ip-border); background: var(--ip-panel);
}
.topbar-label { font-weight: 610; font-size: .86rem; }
.topbar-label span { color: var(--ip-muted); padding: 0 5px; }
.topbar-actions { display: flex; gap: 12px; align-items: center; margin-left: auto; }
.account-name { color: var(--ip-muted); }
.icon-button { display: grid; place-items: center; color: var(--ip-text); background: transparent; border: 1px solid var(--ip-border); border-radius: 8px; width: 36px; height: 36px; font-size: 1rem; }
.icon-button:hover { background: var(--ip-background); }
.main-content { margin-left: var(--ip-sidebar-width); padding: 30px 26px 45px; min-width: 0; max-width: 1820px; }
.sidebar-closed .sidebar { transform: translateX(-100%); }
.sidebar-closed :is(.topbar, .main-content) { margin-left: 0; }
.page-heading { display: flex; justify-content: space-between; gap: 14px; align-items: center; margin-bottom: 22px; }
.page-heading h1 { font-size: clamp(1.45rem, 3.4vw, 2rem); margin: 0 0 5px; font-weight: 740; letter-spacing: -.035em; }
.page-heading p { color: var(--ip-muted); margin: 0; }
.page-heading a.btn { white-space: nowrap; }
.panel { padding: 18px; background: var(--ip-panel); border: 1px solid var(--ip-border); border-radius: 13px; min-width: 0; box-shadow: 0 2px 3px #14263806; }
.panel-heading { display: flex; flex-wrap: wrap; gap: 9px; justify-content: space-between; align-items: center; margin-bottom: 13px; }
.panel-heading h2 { margin: 0; font-size: 1rem; font-weight: 700; }
.panel-heading > a { font-size: .82rem; font-weight: 650; }
.metric-grid, .dashboard-grid { display: grid; gap: 15px; }
.metric-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); margin-bottom: 15px; }
.dashboard-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.metric { display: flex; flex-direction: column; gap: 5px; }
.metric-label, .metric small, .summary-grid small, .activity-list small, .activity-list time { color: var(--ip-muted); }
.metric-label { font-weight: 600; }
.metric strong { font-size: clamp(1.42rem, 3vw, 2rem); font-variant-numeric: tabular-nums; letter-spacing: -.045em; }
progress { accent-color: var(--ip-accent); width: 100%; height: .55rem; margin: 1px 0 3px; }
.operation-progress { height: .9rem; }
.summary-grid { display: grid; gap: 10px; grid-template-columns: repeat(3, minmax(0,1fr)); }
.summary-grid > div { background: var(--ip-background); border-radius: 9px; padding: 12px; }
.summary-grid strong { display: block; font-size: 1.4rem; }
.pill { display: inline-flex; gap: 6px; align-items: center; border: 1px solid var(--ip-border); border-radius: 99px; background: var(--ip-background); color: var(--ip-muted); font-size: .74rem; font-weight: 650; padding: 4px 8px; white-space: nowrap; }
.pill.success { background: #dff4eb; border-color: #b5e8d4; color: #12644b; }
.pill.warning { background: #fcf2d7; border-color: #f1dfac; color: #775509; }
.pill.danger { background: #fbe6e8; border-color: #f0c8ce; color: #8f2733; }
[data-bs-theme="dark"] .pill.success { background: #163f36; border-color: #26554a; color: #a1efcf; }
[data-bs-theme="dark"] .pill.warning { background: #463b24; border-color: #625539; color: #f7da8e; }
[data-bs-theme="dark"] .pill.danger { background: #4b2a35; border-color: #6b3948; color: #ffc1c7; }
.state-dot { width: 7px; height: 7px; border-radius: 50%; background: currentColor; flex: none; }
.empty-state { margin: 14px 0 0; color: var(--ip-muted); }
.activity-list, .diagnostics-list { padding: 0; list-style: none; margin: 0; }
.activity-list li, .diagnostics-list li { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; padding: 9px 0; border-bottom: 1px solid var(--ip-border); }
.activity-list li { justify-content: space-between; }
.activity-list li:last-child, .diagnostics-list li:last-child { border: 0; padding-bottom: 0; }
.activity-list small { display: block; }
.activity-list time { font-size: .78rem; }
.diagnostics-list { margin-top: 16px; }
.diagnostics-list li span:last-child { width: 100%; color: var(--ip-muted); white-space: pre-wrap; overflow-wrap: anywhere; }
.table { margin-bottom: 0; --bs-table-bg: transparent; --bs-table-color: var(--ip-text); --bs-table-border-color: var(--ip-border); }
.table thead th { white-space: nowrap; color: var(--ip-muted); font-size: .79rem; font-weight: 640; }
.table-search { max-width: 230px; }
.action-group { display: flex; flex-wrap: wrap; gap: 6px; }
.log-block { border: 1px solid var(--ip-border); background: var(--ip-background); border-radius: 8px; padding: 12px; margin: 0; max-height: 480px; overflow: auto; color: var(--ip-text); white-space: pre; }
.form-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 13px; }
.form-wide { grid-column: 1 / -1; }
.form-label { font-weight: 590; }
.cron-builder { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 8px; font-size: .78rem; }
.file-path { overflow-wrap: anywhere; }
.btn-primary { --bs-btn-bg: #076e67; --bs-btn-border-color: #076e67; --bs-btn-hover-bg: #095751; --bs-btn-hover-border-color: #095751; --bs-btn-active-bg: #074a44; --bs-btn-active-border-color: #074a44; }
.guest-content { display: grid; min-height: 100dvh; place-items: center; padding: 20px; }
.login-card { width: min(100%, 420px); padding: 27px; }
.login-brand { padding: 0; color: var(--ip-text); }
.dev-login { margin-top: 18px; font-size: .8rem; color: var(--ip-muted); overflow-wrap: anywhere; }
.confirm-dialog { max-width: min(90vw, 420px); border: 1px solid var(--ip-border); border-radius: 12px; padding: 22px; background: var(--ip-panel); color: var(--ip-text); }
.confirm-dialog::backdrop { background: #101a23a8; }
.validation-summary-valid { display: none; }
@media (max-width: 1050px) {
    .metric-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 860px) {
    .sidebar { transform: translateX(-100%); top: var(--ip-topbar); }
    .sidebar-open .sidebar { transform: translateX(0); }
    .main-content, .topbar { margin-left: 0; }
}
@media (max-width: 600px) {
    .main-content { padding: 19px 10px 28px; }
    .topbar { padding: 0 10px; gap: 7px; }
    .topbar-actions { gap: 6px; }
    .topbar-label, .account-name { display: none; }
    .dashboard-grid, .form-grid { grid-template-columns: 1fr; }
    .panel { padding: 13px; }
    .page-heading { flex-wrap: wrap; }
}
@media (prefers-reduced-motion: reduce) { .sidebar { transition: none; } }

.wizard-steps { display: flex; flex-wrap: wrap; gap: 5px 16px; list-style: none; margin: 0 0 19px; padding: 0 0 11px; border-bottom: 1px solid var(--ip-border); color: var(--ip-muted); }
.wizard-steps [aria-current="step"] { color: var(--ip-accent); font-weight: 700; }
.deployment-review { display: grid; grid-template-columns: minmax(90px, 170px) minmax(0, 1fr); gap: 9px; margin: 0 0 8px; }
.deployment-review dd { margin: 0; overflow-wrap: anywhere; }
