:root {
    --sidebar-width: 272px;
    --brand: #5b5bf7;
    --brand-dark: #4545d8;
    --surface: #f5f7fb;
    --ink: #172033;
}

body { background: var(--surface); color: var(--ink); font-family: Inter, system-ui, -apple-system, "Segoe UI", sans-serif; }
.sidebar { width: var(--sidebar-width); min-height: 100vh; position: fixed; inset: 0 auto 0 0; z-index: 1030; background: #111827 !important; }
.main-content { margin-left: var(--sidebar-width); padding: 32px; min-width: 0; }
.brand { display: flex; align-items: center; gap: 12px; padding: 28px 24px; color: white; text-decoration: none; font-size: 1.15rem; font-weight: 800; }
.brand img { width: 42px; height: 42px; object-fit: contain; border-radius: 10px; }
.brand-mark, .auth-logo { display: inline-grid; place-items: center; width: 42px; height: 42px; border-radius: 12px; background: linear-gradient(135deg, #7474ff, #4b35d3); color: white; }
.sidebar .nav-link { color: #aeb7c8; border-radius: 10px; padding: 11px 14px; display: flex; align-items: center; gap: 12px; }
.sidebar .nav-link:hover, .sidebar .nav-link.active { background: rgba(255,255,255,.1); color: white; }
.sidebar .nav-link i { width: 20px; text-align: center; }
.sidebar-user { padding: 22px 24px; border-top: 1px solid rgba(255,255,255,.1); }
.page-header { display: flex; align-items: center; justify-content: space-between; margin-bottom: 28px; gap: 16px; }
.page-header h1 { margin: 0; font-size: clamp(1.5rem, 3vw, 2.15rem); font-weight: 800; }
.btn-primary { --bs-btn-bg: var(--brand); --bs-btn-border-color: var(--brand); --bs-btn-hover-bg: var(--brand-dark); --bs-btn-hover-border-color: var(--brand-dark); }
.card { border: 0; border-radius: 16px; box-shadow: 0 8px 28px rgba(23,32,51,.06); }
.stat-card .icon { width: 48px; height: 48px; display: grid; place-items: center; border-radius: 14px; font-size: 1.2rem; }
.stat-card .number { font-size: 1.8rem; font-weight: 800; }
.table-card { overflow: hidden; }
.table > :not(caption) > * > * { padding: .9rem 1rem; vertical-align: middle; }
.table thead th { background: #f8f9fc; color: #677085; font-size: .75rem; text-transform: uppercase; letter-spacing: .04em; border-bottom: 0; }
.section-title { font-size: .82rem; text-transform: uppercase; letter-spacing: .08em; color: #687085; font-weight: 800; }
.form-control, .form-select { border-radius: 9px; padding: .65rem .8rem; border-color: #dce1ea; }
.form-control:focus, .form-select:focus { border-color: #9696ff; box-shadow: 0 0 0 .2rem rgba(91,91,247,.12); }
.auth-page { min-height: 100vh; background: radial-gradient(circle at top left, #e4e7ff, transparent 36%), #f5f7fb; }
.install-card, .login-card { max-width: 720px; padding: clamp(24px, 5vw, 48px); border-radius: 22px; background: white; box-shadow: 0 24px 70px rgba(23,32,51,.12); }
.login-card { max-width: 430px; }
.auth-logo { margin: auto; width: 58px; height: 58px; font-weight: 800; font-size: 1.2rem; }
.timeline { position: relative; padding-left: 28px; }
.timeline::before { content: ""; position: absolute; left: 7px; top: 8px; bottom: 8px; width: 2px; background: #e2e6ef; }
.timeline-item { position: relative; padding-bottom: 20px; }
.timeline-item::before { content: ""; position: absolute; left: -27px; top: 5px; width: 14px; height: 14px; border: 3px solid white; border-radius: 50%; background: var(--brand); box-shadow: 0 0 0 1px #d8ddea; }
.detail-label { color: #7a8396; font-size: .78rem; text-transform: uppercase; font-weight: 700; }
.empty-state { padding: 48px 20px; text-align: center; color: #7a8396; }
.discovery-card { cursor: pointer; transition: transform .18s ease, box-shadow .18s ease, border-color .18s ease; border: 1px solid transparent; }
.discovery-card:hover { transform: translateY(-2px); box-shadow: 0 12px 32px rgba(23,32,51,.11); border-color: #dfe2ff; }
.discovery-card:has(.discovery-check:checked) { border-color: var(--brand); box-shadow: 0 0 0 3px rgba(91,91,247,.11); }
.discovery-check { width: 1.2rem; height: 1.2rem; flex: 0 0 auto; }
.min-w-0 { min-width: 0; }

@media (max-width: 991.98px) {
    .sidebar { position: fixed; width: min(86vw, 300px); }
    .main-content { margin-left: 0; padding: 22px 16px; }
}

@media (max-width: 575.98px) {
    .page-header { align-items: flex-start; }
    .page-header .btn { white-space: nowrap; }
    .install-card, .login-card { padding: 24px 18px; }
}
