/* ══════════════════════════════════════════════════════════════════════════════
   ShiftHR — Layout
   ──────────────────────────────────────────────────────────────────────────────
   App shell structure: sidebar, main content area, page headers, dev banner,
   and nav-level UI (lock icons, etc.). Not feature-specific.
   ══════════════════════════════════════════════════════════════════════════════ */

/* ── Dev Banner ────────────────────────────────────────────────────────────── */
.dev-banner {
    background: var(--color-dev-bg); border-top: 2px solid var(--color-dev-border);
    padding: 12px 24px; font-size: .875rem; text-align: center; color: var(--color-dev-text);
}
.dev-banner a { color: var(--color-brand); font-weight: 600; text-decoration: underline; }

/* ── App Shell Layout ──────────────────────────────────────────────────────── */
.app-shell { display: flex; min-height: 100vh; }

.app-sidebar {
    width: var(--sidebar-width); flex-shrink: 0;
    background: var(--color-neutral-900); color: #fff;
    display: flex; flex-direction: column;
    position: sticky; top: 0; height: 100vh; overflow-y: auto;
}
.sidebar-brand {
    display: flex; flex-direction: column; gap: 4px;
    padding: 20px 16px 16px; border-bottom: 1px solid rgba(255,255,255,.1);
}
.sidebar-brand a { font-size: 1.2rem; font-weight: 800; }
.sidebar-tenant-tier {
    font-size: .7rem; font-weight: 600; text-transform: uppercase; letter-spacing: .05em;
    color: var(--color-accent); opacity: .9;
}

.sidebar-nav { flex: 1; padding: 12px 8px; display: flex; flex-direction: column; gap: 2px; }
.sidebar-nav a {
    display: flex; align-items: center; gap: 10px;
    padding: 9px 10px; border-radius: var(--radius-sm);
    font-size: .875rem; font-weight: 500; color: rgba(255,255,255,.7);
    transition: all .15s;
}
.sidebar-nav a:hover, .sidebar-nav a.active {
    background: rgba(255,255,255,.1); color: #fff;
}
.nav-icon { font-size: 1rem; opacity: .8; width: 18px; text-align: center; }
.nav-section-label {
    font-size: .7rem; font-weight: 700; text-transform: uppercase; letter-spacing: .08em;
    color: rgba(255,255,255,.35); padding: 16px 10px 4px;
}

.sidebar-user {
    padding: 14px 12px;
    border-top: 1px solid rgba(255,255,255,.1);
    display: flex; flex-direction: column; gap: 6px;
}
.user-name { font-size: .8rem; color: rgba(255,255,255,.6); font-weight: 500; }

.app-main { flex: 1; background: var(--color-neutral-50); overflow-y: auto; }
.app-content { max-width: var(--content-max-width); margin: 0 auto; padding: var(--content-padding) var(--content-padding); }

/* ── Page Headers ──────────────────────────────────────────────────────────── */
.page-header { margin-bottom: 28px; }
.page-header h1 { font-size: 1.6rem; font-weight: 700; }
.page-sub { color: var(--color-neutral-500); font-size: .9rem; margin-top: 4px; }

/* ── Nav Lock Icon (tier-gated features) ───────────────────────────────────── */
.nav-lock-icon {
    margin-left: auto;
    font-size: .65rem;
    opacity: 0.4;
    filter: grayscale(100%);
    line-height: 1;
}

/* ── Access Denied Page ────────────────────────────────────────────────────── */
.access-denied-page {
    display: flex; align-items: center; justify-content: center;
    min-height: 100vh;
    background: var(--color-surface-50, #f8f9fa);
    padding: 20px;
}
.access-denied-card {
    max-width: 480px; width: 100%;
    background: var(--color-surface-0, #fff);
    border-radius: 12px;
    padding: 40px;
    box-shadow: 0 2px 12px rgba(0,0,0,.08);
    text-align: center;
}
.access-denied-card .sidebar-brand {
    justify-content: center; margin-bottom: 24px;
}
.access-denied-card h1 {
    font-size: 1.4rem; font-weight: 700; margin-bottom: 12px;
    color: var(--color-neutral-900, #1a1a2e);
}
.access-denied-card p {
    color: var(--color-neutral-600, #555);
    font-size: .95rem; line-height: 1.5; margin-bottom: 24px;
}
.access-denied-actions {
    display: flex; gap: 12px; justify-content: center;
}
.access-denied-actions .btn-primary,
.access-denied-actions .btn-outline {
    padding: 8px 20px; border-radius: 6px; font-size: .9rem;
    text-decoration: none; font-weight: 500;
}

/* ── Error Page ────────────────────────────────────────────────────────────── */
.error-details { margin-top: 16px; }
.error-details summary { cursor: pointer; color: var(--color-neutral-500, #888); font-size: .85rem; }
.error-details pre {
    margin-top: 8px; padding: 12px; background: var(--color-surface-50, #f5f5f5);
    border-radius: 6px; font-size: .8rem; overflow-x: auto; white-space: pre-wrap;
    max-height: 400px; overflow-y: auto;
}
