:root {
    --shell-bg: #f3f6fb;
    --shell-surface: #ffffff;
    --shell-surface-2: #eef3f9;
    --shell-surface-3: #e4ebf4;
    --shell-border: #d7e0ea;
    --shell-border-strong: #c2cfde;
    --shell-text: #14202b;
    --shell-text-dim: #5d6a7d;
    --shell-text-muted: #7f8b9c;
    --shell-accent: #2563eb;
    --shell-accent-strong: #1746a2;
    --shell-accent-soft: #dbe8ff;
    --shell-success: #0f8a5f;
    --shell-success-soft: #d8f4ea;
    --shell-warning: #a55d13;
    --shell-warning-soft: #fdeccf;
    --shell-danger: #bf3148;
    --shell-danger-soft: #f9dbe1;
    --shell-shadow: 0 18px 40px rgba(17, 24, 39, 0.08);
    --shell-radius-sm: 10px;
    --shell-radius-md: 16px;
    --shell-radius-lg: 24px;
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html,
body {
    min-height: 100%;
}

body {
    background: radial-gradient(circle at top, #fbfdff 0%, var(--shell-bg) 55%);
    color: var(--shell-text);
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    line-height: 1.5;
    -webkit-font-smoothing: antialiased;
}

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

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

button {
    cursor: pointer;
}

.shell-app {
    min-height: 100vh;
}

.shell-header {
    position: sticky;
    top: 0;
    z-index: 40;
    border-bottom: 1px solid rgba(215, 224, 234, 0.9);
    background: rgba(9, 15, 27, 0.92);
    backdrop-filter: blur(18px);
}

.shell-main {
    padding: 2rem 0 3rem;
}

.shell-container {
    width: min(100% - 2rem, 1360px);
    margin: 0 auto;
}

.shell-container--wide {
    width: min(100% - 2rem, 1360px);
}

.shell-container--standard {
    width: min(100% - 2rem, 1180px);
}

.shell-container--narrow {
    width: min(100% - 2rem, 960px);
}

.shell-container--full {
    width: min(100% - 2rem, 1500px);
}

.shell-header .shell-container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1.5rem;
    padding: 1rem 0;
}

.shell-brand {
    display: flex;
    flex-direction: column;
    gap: 0.2rem;
    min-width: 0;
}

.shell-brand-title {
    color: #f8fbff;
    font-size: 1.1rem;
    font-weight: 800;
    letter-spacing: -0.03em;
}

.shell-brand-subtitle {
    color: rgba(223, 232, 242, 0.72);
    font-size: 0.84rem;
    font-weight: 500;
}

.shell-nav {
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-end;
    gap: 0.55rem;
}

.shell-nav-link {
    border: 1px solid rgba(215, 224, 234, 0.18);
    border-radius: 999px;
    color: rgba(232, 239, 247, 0.82);
    padding: 0.65rem 0.95rem;
    font-size: 0.92rem;
    font-weight: 600;
    transition: border-color 140ms ease, background 140ms ease, color 140ms ease;
}

.shell-nav-link:hover {
    border-color: rgba(215, 224, 234, 0.38);
    background: rgba(255, 255, 255, 0.06);
    color: #ffffff;
}

.shell-nav-link.is-active {
    border-color: rgba(97, 154, 255, 0.55);
    background: linear-gradient(180deg, rgba(37, 99, 235, 0.3), rgba(37, 99, 235, 0.14));
    color: #ffffff;
}

.page-intro {
    display: flex;
    justify-content: space-between;
    gap: 1.5rem;
    align-items: flex-start;
    margin-bottom: 1.75rem;
}

.page-intro-copy {
    max-width: 780px;
}

.page-eyebrow {
    color: var(--shell-accent);
    font-size: 0.76rem;
    font-weight: 800;
    letter-spacing: 0.12em;
    margin-bottom: 0.75rem;
    text-transform: uppercase;
}

.page-title {
    font-size: clamp(2rem, 3.5vw, 3rem);
    font-weight: 800;
    letter-spacing: -0.04em;
    line-height: 1.05;
}

.page-description {
    margin-top: 0.85rem;
    max-width: 760px;
    color: var(--shell-text-dim);
    font-size: 1rem;
}

.page-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    align-self: center;
}

.shell-panel {
    background: var(--shell-surface);
    border: 1px solid var(--shell-border);
    border-radius: var(--shell-radius-md);
    box-shadow: var(--shell-shadow);
}

.shell-panel-muted {
    background: linear-gradient(180deg, #fdfefe, var(--shell-surface-2));
}

.shell-section {
    padding: 1.5rem;
}

.shell-section-title {
    font-size: 1.1rem;
    font-weight: 800;
    letter-spacing: -0.03em;
}

.shell-section-subtitle {
    margin-top: 0.35rem;
    color: var(--shell-text-dim);
    font-size: 0.92rem;
}

.shell-grid {
    display: grid;
    gap: 1.25rem;
}

.shell-grid-2 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.shell-grid-3 {
    grid-template-columns: repeat(3, minmax(0, 1fr));
}

.shell-grid-4 {
    grid-template-columns: repeat(4, minmax(0, 1fr));
}

.shell-stat-card {
    background: linear-gradient(180deg, #ffffff, #f8fbff);
    border: 1px solid var(--shell-border);
    border-radius: var(--shell-radius-md);
    padding: 1.25rem;
}

.shell-stat-label {
    color: var(--shell-text-muted);
    font-size: 0.78rem;
    font-weight: 800;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.shell-stat-value {
    margin-top: 0.75rem;
    font-size: 2rem;
    font-weight: 800;
    letter-spacing: -0.05em;
}

.shell-stat-detail {
    margin-top: 0.55rem;
    color: var(--shell-text-dim);
    font-size: 0.93rem;
}

.shell-kicker {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    padding: 0.42rem 0.7rem;
    border-radius: 999px;
    border: 1px solid var(--shell-border);
    background: var(--shell-surface-2);
    color: var(--shell-text-dim);
    font-size: 0.78rem;
    font-weight: 700;
}

.shell-kicker--success {
    background: var(--shell-success-soft);
    border-color: rgba(15, 138, 95, 0.2);
    color: var(--shell-success);
}

.shell-kicker--warning {
    background: var(--shell-warning-soft);
    border-color: rgba(165, 93, 19, 0.2);
    color: var(--shell-warning);
}

.shell-button,
.shell-button-secondary,
.shell-button-ghost {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.45rem;
    min-height: 2.9rem;
    border-radius: 12px;
    font-size: 0.95rem;
    font-weight: 700;
    padding: 0.75rem 1rem;
    transition: transform 120ms ease, box-shadow 120ms ease, border-color 120ms ease, background 120ms ease;
}

.shell-button {
    background: linear-gradient(180deg, var(--shell-accent), var(--shell-accent-strong));
    border: 1px solid transparent;
    color: #ffffff;
    box-shadow: 0 12px 24px rgba(37, 99, 235, 0.18);
}

.shell-button:hover {
    transform: translateY(-1px);
}

.shell-button-secondary {
    background: var(--shell-surface);
    border: 1px solid var(--shell-border);
    color: var(--shell-text);
}

.shell-button-secondary:hover,
.shell-button-ghost:hover {
    border-color: var(--shell-border-strong);
    background: var(--shell-surface-2);
}

.shell-button-ghost {
    background: transparent;
    border: 1px solid transparent;
    color: var(--shell-text-dim);
}

.shell-info-grid {
    display: grid;
    gap: 0.9rem;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
}

.shell-info-card {
    background: var(--shell-surface-2);
    border: 1px solid var(--shell-border);
    border-radius: 14px;
    padding: 0.95rem 1rem;
}

.shell-info-label {
    color: var(--shell-text-muted);
    font-size: 0.76rem;
    font-weight: 800;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.shell-info-value {
    margin-top: 0.45rem;
    color: var(--shell-text);
    font-size: 0.98rem;
    font-weight: 700;
}

.shell-loading,
.shell-empty {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    padding: 2rem;
    text-align: center;
    color: var(--shell-text-dim);
}

.shell-empty-title {
    color: var(--shell-text);
    font-size: 1.05rem;
    font-weight: 800;
}

.shell-spinner {
    width: 2rem;
    height: 2rem;
    border: 3px solid var(--shell-surface-3);
    border-top-color: var(--shell-accent);
    border-radius: 999px;
    animation: shell-spin 0.75s linear infinite;
}

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

.shell-table {
    width: 100%;
    border-collapse: collapse;
}

.shell-table th,
.shell-table td {
    padding: 0.95rem 1rem;
    border-bottom: 1px solid var(--shell-border);
    text-align: left;
    vertical-align: top;
}

.shell-table th {
    color: var(--shell-text-muted);
    font-size: 0.76rem;
    font-weight: 800;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.shell-table td {
    color: var(--shell-text);
    font-size: 0.94rem;
}

.shell-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    padding: 0.34rem 0.65rem;
    border-radius: 999px;
    border: 1px solid var(--shell-border);
    background: var(--shell-surface-2);
    color: var(--shell-text-dim);
    font-size: 0.76rem;
    font-weight: 700;
}

.shell-badge--success {
    background: var(--shell-success-soft);
    border-color: rgba(15, 138, 95, 0.18);
    color: var(--shell-success);
}

.shell-badge--warning {
    background: var(--shell-warning-soft);
    border-color: rgba(165, 93, 19, 0.18);
    color: var(--shell-warning);
}

.shell-badge--danger {
    background: var(--shell-danger-soft);
    border-color: rgba(191, 49, 72, 0.18);
    color: var(--shell-danger);
}

.mono {
    font-family: 'SFMono-Regular', ui-monospace, 'Cascadia Code', 'Source Code Pro', Menlo, Consolas, monospace;
}

@keyframes shell-spin {
    to {
        transform: rotate(360deg);
    }
}

@media (max-width: 900px) {
    .shell-header .shell-container,
    .page-intro {
        flex-direction: column;
        align-items: flex-start;
    }

    .shell-nav {
        width: 100%;
        justify-content: flex-start;
    }

    .shell-grid-4,
    .shell-grid-3,
    .shell-grid-2 {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 640px) {
    .shell-main {
        padding-top: 1.25rem;
    }

    .shell-nav-link {
        padding: 0.6rem 0.8rem;
    }

    .shell-container,
    .shell-container--wide,
    .shell-container--standard,
    .shell-container--narrow,
    .shell-container--full {
        width: min(100% - 1rem, 1500px);
    }
}
