:root {
    --app-shell-bg: rgba(18, 18, 18, 0.96);
    --app-shell-panel: #202226;
    --app-shell-border: #383c43;
    --app-shell-text: #f3f4f6;
    --app-shell-muted: #8b949e;
    --app-shell-accent: #007acc;
}

.app-header {
    width: 100%;
    background: linear-gradient(135deg, var(--app-shell-panel), var(--app-shell-bg));
    border: 1px solid var(--app-shell-border);
    border-top: 3px solid var(--app-shell-accent);
    border-radius: 12px;
    box-shadow: 0 14px 34px rgba(0, 0, 0, 0.24);
    position: relative;
    z-index: 30;
}

.app-header-inner {
    min-height: 76px;
    padding: 14px 16px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 14px;
}

.app-header-brand {
    min-width: 0;
    display: flex;
    align-items: center;
    gap: 12px;
}

.app-header-icon {
    width: 44px;
    height: 44px;
    flex: 0 0 44px;
    border: 1px solid rgba(0, 122, 204, 0.5);
    border-radius: 11px;
    background: rgba(0, 122, 204, 0.12);
    color: #59b8f2;
    display: grid;
    place-items: center;
    font-size: 18px;
}

.app-header-kicker {
    margin: 0 0 2px;
    color: #60a5fa;
    font-size: 9px;
    font-weight: 800;
    letter-spacing: 0.18em;
    line-height: 1.2;
    text-transform: uppercase;
}

.app-header-title {
    margin: 0;
    color: var(--app-shell-text);
    font-size: 18px;
    font-weight: 850;
    letter-spacing: 0.1em;
    line-height: 1.25;
    text-transform: uppercase;
}

.app-header-subtitle {
    margin: 3px 0 0;
    color: var(--app-shell-muted);
    font-size: 11px;
    line-height: 1.35;
}

.app-header-actions {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    flex-wrap: wrap;
    gap: 8px;
}

.app-header-link,
.app-header-button,
.app-header-signout {
    min-height: 36px;
    padding: 8px 12px;
    border: 1px solid #454a52;
    border-radius: 8px;
    background: #292c31;
    color: #d1d5db;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 7px;
    font-size: 10px;
    font-weight: 800;
    letter-spacing: 0.06em;
    line-height: 1;
    text-decoration: none;
    text-transform: uppercase;
    cursor: pointer;
    transition: border-color 0.16s ease, background 0.16s ease, color 0.16s ease, transform 0.16s ease;
}

.app-header-link:hover,
.app-header-button:hover,
.app-header-signout:hover {
    border-color: #69717d;
    background: #33373d;
    color: #fff;
    transform: translateY(-1px);
}

.app-header-link.primary {
    border-color: #2388ca;
    background: #0874b8;
    color: #fff;
    box-shadow: 0 7px 18px rgba(0, 122, 204, 0.2);
}

.app-header-link.primary:hover {
    border-color: #5cbcf7;
    background: #0b84ce;
}

.app-header-signout {
    width: 36px;
    padding-inline: 0;
    color: #9ca3af;
    cursor: pointer;
}

.app-header-status {
    color: #6b7280;
    font-size: 9px;
    font-weight: 800;
    letter-spacing: 0.12em;
    text-transform: uppercase;
}

@media (max-width: 720px) {
    .app-header-inner,
    .app-header-actions {
        align-items: stretch;
    }

    .app-header-brand,
    .app-header-actions {
        width: 100%;
    }

    .app-header-actions > a,
    .app-header-actions > button:not(.app-header-signout) {
        flex: 1 1 auto;
    }

    .app-header-subtitle {
        display: none;
    }
}

@media print {
    .app-header.no-print {
        display: none !important;
    }
}
