.boost-gradient {
    background: linear-gradient(135deg, var(--color-primary), var(--color-secondary));
}

.page-hero {
    position: relative;
    min-height: 132px;
    display: flex;
    align-items: center;
    overflow: hidden;
    padding: var(--space-6);
    margin-bottom: var(--space-5);
    background: linear-gradient(135deg, rgba(11, 28, 48, 0.82), rgba(18, 37, 58, 0.7));
    border: 1px solid var(--color-border);
    border-top: 3px solid var(--color-primary-soft);
    border-radius: var(--radius-xl);
}

.page-hero::after {
    content: "";
    position: absolute;
    inset: 0 0 0 auto;
    width: 52%;
    background:
        radial-gradient(circle at 70% 72%, rgba(253, 212, 0, 0.14), transparent 22%),
        linear-gradient(90deg, transparent, rgba(0, 200, 83, 0.13));
    pointer-events: none;
}

.page-hero h1 {
    position: relative;
    z-index: 1;
    display: flex;
    align-items: center;
    gap: var(--space-3);
    margin: 0 0 var(--space-2);
    font-family: Sora, Inter, sans-serif;
    font-size: 32px;
    line-height: 1.15;
    color: var(--color-text);
}

.page-hero p {
    position: relative;
    z-index: 1;
    max-width: 720px;
    margin: 0;
    color: var(--color-muted);
    font-weight: 600;
}

.page-hero .material-symbols-outlined {
    color: var(--color-primary-soft);
    font-size: 34px;
}

.card {
    position: relative;
    overflow: hidden;
    background: rgba(11, 28, 48, 0.72);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-xl);
}

.modal-panel {
    background: #0b1c30;
    box-shadow: 0 26px 70px rgba(0, 0, 0, 0.42);
}

.card-accent {
    border-top: 3px solid var(--color-primary-soft);
}

.card-body {
    padding: var(--space-5);
}

.card-header {
    min-height: 68px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: var(--space-4);
    padding: 0 var(--space-5);
    background: rgba(255, 255, 255, 0.035);
    border-bottom: 1px solid var(--color-border);
}

.card-title {
    display: flex;
    align-items: center;
    gap: var(--space-2);
    margin: 0;
    font-family: Sora, Inter, sans-serif;
    font-size: 18px;
    line-height: 1.25;
}

.card-help {
    position: relative;
    width: 34px;
    height: 34px;
    display: inline-grid;
    place-items: center;
    padding: 0;
    color: var(--color-primary-soft);
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--color-border);
    border-radius: 999px;
    cursor: pointer;
}

.card-help .material-symbols-outlined {
    font-size: 18px;
}

.card-help-tooltip {
    position: absolute;
    right: 0;
    top: calc(100% + 10px);
    width: 240px;
    padding: 10px 12px;
    color: var(--color-text);
    background: rgba(6, 18, 31, 0.98);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-md);
    box-shadow: 0 18px 48px rgba(0, 0, 0, 0.32);
    font-size: 12px;
    font-weight: 700;
    line-height: 1.45;
    text-align: left;
    opacity: 0;
    pointer-events: none;
    transform: translateY(-4px);
    transition: opacity 140ms ease, transform 140ms ease;
    z-index: 50;
}

.card-help:hover .card-help-tooltip,
.card-help:focus-visible .card-help-tooltip {
    opacity: 1;
    transform: translateY(0);
}

.stat-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: var(--space-5);
    margin-bottom: var(--space-5);
}

.stat-card {
    position: relative;
    overflow: visible;
    min-height: 122px;
    padding: var(--space-5);
}

.stat-help {
    position: absolute;
    top: 18px;
    left: 18px;
    width: 28px;
    height: 28px;
    display: inline-grid;
    place-items: center;
    padding: 0;
    color: var(--color-text);
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--color-border);
    border-radius: 999px;
    cursor: pointer;
    z-index: 3;
}

.stat-help-mark {
    font-size: 15px;
    font-weight: 900;
    line-height: 1;
}

.stat-tooltip {
    position: absolute;
    left: 0;
    top: calc(100% + 10px);
    width: 220px;
    padding: 10px 12px;
    color: var(--color-text);
    background: rgba(6, 18, 31, 0.98);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-md);
    box-shadow: 0 18px 48px rgba(0, 0, 0, 0.32);
    font-size: 12px;
    font-weight: 700;
    line-height: 1.45;
    text-align: left;
    opacity: 0;
    pointer-events: none;
    transform: translateY(-4px);
    transition: opacity 140ms ease, transform 140ms ease;
    z-index: 20;
}

.stat-help:hover .stat-tooltip,
.stat-help:focus-visible .stat-tooltip {
    opacity: 1;
    transform: translateY(0);
}

.stat-card small {
    display: block;
    margin-bottom: var(--space-5);
    color: var(--color-muted);
    font-weight: 800;
}

.stat-card strong {
    display: block;
    font-family: Sora, Inter, sans-serif;
    font-size: 30px;
    line-height: 1;
}

.stat-card .stat-icon {
    position: absolute;
    top: 18px;
    right: 18px;
    width: 34px;
    height: 34px;
    display: grid;
    place-items: center;
    color: var(--color-primary-soft);
    background: rgba(0, 200, 83, 0.12);
    border-radius: 999px;
}

.button {
    min-height: 42px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: var(--space-2);
    padding: 0 18px;
    border: 1px solid transparent;
    border-radius: var(--radius-md);
    font-weight: 800;
    color: var(--color-text);
    transition: transform 150ms ease, filter 150ms ease, background 150ms ease, border-color 150ms ease;
}

.button:hover {
    filter: brightness(1.08);
}

.button:active {
    transform: translateY(1px);
}

.button-primary {
    color: #071625;
    background: var(--color-primary);
    box-shadow: var(--shadow-glow);
}

.button-boost {
    color: #071625;
    background: linear-gradient(135deg, var(--color-primary), var(--color-secondary));
    box-shadow: var(--shadow-glow);
}

.button-outline {
    color: var(--color-primary-soft);
    background: transparent;
    border-color: var(--color-primary-soft);
}

.button-danger {
    color: #fff;
    background: var(--color-danger);
}

.button-ghost {
    color: var(--color-muted);
    background: var(--color-surface-2);
    border-color: var(--color-border);
}

.profile-trigger {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 0;
    color: var(--color-text);
    background: transparent;
    border: 0;
    font: inherit;
    font-weight: 800;
    text-align: left;
    cursor: pointer;
}

.profile-trigger:hover,
.profile-trigger:focus-visible {
    color: var(--color-primary-soft);
    text-decoration: underline;
}

.profile-trigger-inline {
    font-weight: 700;
}

.profile-modal {
    display: grid;
    gap: var(--space-4);
}

.profile-modal-header {
    display: grid;
    grid-template-columns: auto 1fr;
    gap: var(--space-4);
    align-items: center;
}

.profile-modal-avatar {
    width: 60px;
    height: 60px;
}

.profile-modal-title-row {
    display: flex;
    align-items: center;
    gap: var(--space-3);
    flex-wrap: wrap;
    margin-bottom: 6px;
}

.profile-modal-title-row strong {
    font-family: Sora, Inter, sans-serif;
    font-size: 24px;
}

.profile-modal-header p {
    margin: 0;
    color: var(--color-muted);
    font-weight: 600;
}

.profile-modal .badge,
.profile-modal .badge-yellow {
    backdrop-filter: none;
}

.profile-modal-grid {
    display: grid;
    gap: 10px;
}

.profile-modal-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: var(--space-4);
    padding: 12px 14px;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-md);
}

.profile-modal-row span {
    color: var(--color-muted);
    font-size: 13px;
    font-weight: 700;
}

.profile-modal-row strong {
    text-align: right;
}

.profile-modal-link-row {
    display: flex;
    justify-content: flex-start;
}

.profile-link-anchor {
    text-decoration: none;
}

.badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    min-height: 24px;
    padding: 0 10px;
    border-radius: 999px;
    color: var(--color-primary-soft);
    background: rgba(0, 200, 83, 0.14);
    border: 1px solid rgba(105, 255, 135, 0.25);
    font-size: 12px;
    font-weight: 800;
}

.badge-yellow {
    color: var(--color-secondary);
    background: rgba(253, 212, 0, 0.13);
    border-color: rgba(253, 212, 0, 0.3);
}

.form-grid {
    display: grid;
    gap: var(--space-4);
}

.field {
    display: grid;
    gap: 7px;
}

.field label {
    color: var(--color-muted);
    font-size: 14px;
    font-weight: 800;
}

.field input,
.field select,
.field textarea {
    width: 100%;
    min-height: 44px;
    padding: 10px 12px;
    color: var(--color-text);
    background: var(--color-surface-2);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-md);
    outline: 0;
}

.field textarea {
    min-height: 120px;
    resize: vertical;
}

.field input:focus,
.field select:focus,
.field textarea:focus {
    border-color: var(--color-primary-soft);
    box-shadow: var(--shadow-glow);
}

.table-wrap {
    overflow-x: auto;
}

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

.data-table th,
.data-table td {
    padding: 13px 12px;
    text-align: left;
    border-bottom: 1px solid var(--color-border);
    white-space: nowrap;
}

.data-table th {
    color: var(--color-muted);
    background: rgba(255, 255, 255, 0.035);
    font-size: 13px;
    font-weight: 800;
}

.data-table tr:hover td {
    background: rgba(255, 255, 255, 0.025);
}

.progress {
    height: 10px;
    overflow: hidden;
    background: var(--color-surface-3);
    border: 1px solid var(--color-border);
    border-radius: 999px;
}

.progress > span {
    display: block;
    height: 100%;
    background: var(--color-primary-soft);
    border-radius: inherit;
    box-shadow: var(--shadow-glow);
}

.toast-stack {
    position: fixed;
    right: var(--space-5);
    bottom: var(--space-5);
    z-index: 100;
    display: grid;
    gap: var(--space-3);
}

.toast {
    width: min(380px, calc(100vw - 32px));
    padding: var(--space-4);
    border-radius: var(--radius-lg);
    color: var(--color-text);
    background: var(--color-surface);
    border: 1px solid var(--color-border);
    box-shadow: 0 18px 50px rgba(0, 0, 0, 0.28);
}

.toast.is-success {
    border-color: rgba(105, 255, 135, 0.45);
}

.toast.is-error {
    border-color: rgba(255, 75, 106, 0.55);
}

.skeleton {
    min-height: 18px;
    border-radius: var(--radius-sm);
    background: linear-gradient(90deg, rgba(255,255,255,0.04), rgba(255,255,255,0.1), rgba(255,255,255,0.04));
    background-size: 220% 100%;
    animation: skeleton 1.4s infinite;
}

@keyframes skeleton {
    to {
        background-position: -220% 0;
    }
}

@media (max-width: 1180px) {
    .stat-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 680px) {
    .page-hero {
        padding: var(--space-5);
    }

    .page-hero h1 {
        font-size: 25px;
    }

    .stat-grid {
        grid-template-columns: 1fr;
    }
}
