/* ============================================
   Purchasing Request System - Main Stylesheet
   Monotone Palette (Slate Gray)
   Responsive: 325px to max
   ============================================ */

/* --- CSS Custom Properties --- */
:root {
    /* Monotone Palette - Slate */
    --color-50:  #f8fafc;
    --color-100: #f1f5f9;
    --color-200: #e2e8f0;
    --color-300: #cbd5e1;
    --color-400: #94a3b8;
    --color-500: #64748b;
    --color-600: #475569;
    --color-700: #334155;
    --color-800: #1e293b;
    --color-900: #0f172a;
    --color-950: #020617;

    /* Semantic Colors */
    --bg-primary:    var(--color-50);
    --bg-secondary:  var(--color-100);
    --bg-card:       #ffffff;
    --bg-sidebar:    var(--color-900);
    --bg-header:     #ffffff;

    --text-primary:   var(--color-900);
    --text-secondary: var(--color-600);
    --text-muted:     var(--color-400);
    --text-inverse:   var(--color-50);

    --border-color:   var(--color-200);
    --border-focus:   var(--color-500);

    --accent:         var(--color-700);
    --accent-hover:   var(--color-800);
    --accent-light:   var(--color-200);

    --success: #16a34a;
    --error:   #dc2626;
    --warning: #d97706;
    --info:    var(--color-500);

    /* Spacing */
    --sidebar-width: 260px;
    --sidebar-collapsed: 68px;
    --header-height: 64px;
    --footer-height: 48px;

    /* Typography */
    --font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    --font-mono: 'JetBrains Mono', 'Fira Code', monospace;

    /* Transitions */
    --transition: all 0.2s ease;
    --transition-slow: all 0.3s ease;

    /* Shadows */
    --shadow-sm:  0 1px 2px rgba(0,0,0,0.05);
    --shadow-md:  0 4px 6px -1px rgba(0,0,0,0.07), 0 2px 4px -2px rgba(0,0,0,0.05);
    --shadow-lg:  0 10px 15px -3px rgba(0,0,0,0.08), 0 4px 6px -4px rgba(0,0,0,0.05);
    --shadow-xl:  0 20px 25px -5px rgba(0,0,0,0.1), 0 8px 10px -6px rgba(0,0,0,0.05);

    /* Border Radius */
    --radius-sm: 6px;
    --radius-md: 8px;
    --radius-lg: 12px;
    --radius-xl: 16px;
    --radius-full: 9999px;
}

/* --- Reset & Base --- */
*, *::before, *::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    font-size: 16px;
    -webkit-text-size-adjust: 100%;
    scroll-behavior: smooth;
    overflow-x: hidden;
}

body {
    font-family: var(--font-family);
    color: var(--text-primary);
    background-color: var(--bg-primary);
    line-height: 1.6;
    min-height: 100vh;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

a {
    color: var(--accent);
    text-decoration: none;
    transition: var(--transition);
}

a:hover {
    color: var(--accent-hover);
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

/* --- Utility Classes --- */
.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0,0,0,0);
    white-space: nowrap;
    border: 0;
}

.text-center { text-align: center; }
.text-right { text-align: right; }
.text-muted { color: var(--text-muted); }
.text-secondary { color: var(--text-secondary); }
.text-success { color: var(--success); }
.text-error { color: var(--error); }
.text-warning { color: var(--warning); }

.mt-1 { margin-top: 0.25rem; }
.mt-2 { margin-top: 0.5rem; }
.mt-3 { margin-top: 1rem; }
.mt-4 { margin-top: 1.5rem; }
.mb-1 { margin-bottom: 0.25rem; }
.mb-2 { margin-bottom: 0.5rem; }
.mb-3 { margin-bottom: 1rem; }
.mb-4 { margin-bottom: 1.5rem; }

.d-flex { display: flex; }
.d-none { display: none; }
.flex-column { flex-direction: column; }
.align-center { align-items: center; }
.justify-center { justify-content: center; }
.justify-between { justify-content: space-between; }
.flex-1 { flex: 1; }
.gap-1 { gap: 0.5rem; }
.gap-2 { gap: 1rem; }
.gap-3 { gap: 1.5rem; }

.w-full { width: 100%; }

/* --- Forms --- */
.form-group {
    margin-bottom: 1.25rem;
}

.form-label {
    display: block;
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 0.375rem;
    letter-spacing: 0.01em;
}

.form-control {
    width: 100%;
    padding: 0.625rem 0.875rem;
    font-size: 0.9375rem;
    font-family: var(--font-family);
    color: var(--text-primary);
    background-color: var(--bg-card);
    border: 1.5px solid var(--border-color);
    border-radius: var(--radius-md);
    transition: var(--transition);
    outline: none;
    appearance: none;
}

.form-control:focus {
    border-color: var(--border-focus);
    box-shadow: 0 0 0 3px rgba(100, 116, 139, 0.15);
}

.form-control::placeholder {
    color: var(--text-muted);
}

.form-control.is-invalid {
    border-color: var(--error);
}

.form-control.is-invalid:focus {
    box-shadow: 0 0 0 3px rgba(220, 38, 38, 0.15);
}

.form-hint {
    font-size: 0.8125rem;
    color: var(--text-muted);
    margin-top: 0.25rem;
}

.form-error {
    font-size: 0.8125rem;
    color: var(--error);
    margin-top: 0.25rem;
}

.input-group {
    position: relative;
}

.input-group .form-control {
    padding-right: 2.75rem;
}

.input-group-append {
    position: absolute;
    right: 0;
    top: 0;
    height: 100%;
    display: flex;
    align-items: center;
    padding-right: 0.75rem;
}

.input-toggle-password {
    cursor: pointer;
    background: none;
    border: none;
    color: var(--text-muted);
    padding: 0.25rem;
    display: flex;
    align-items: center;
    transition: var(--transition);
}

.input-toggle-password:hover {
    color: var(--text-primary);
}

/* Select */
.form-select {
    width: 100%;
    padding: 0.625rem 2.5rem 0.625rem 0.875rem;
    font-size: 0.9375rem;
    font-family: var(--font-family);
    color: var(--text-primary);
    background-color: var(--bg-card);
    border: 1.5px solid var(--border-color);
    border-radius: var(--radius-md);
    transition: var(--transition);
    outline: none;
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%2364748b' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'%3E%3C/polyline%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 0.75rem center;
    cursor: pointer;
}

.form-select:focus {
    border-color: var(--border-focus);
    box-shadow: 0 0 0 3px rgba(100, 116, 139, 0.15);
}

/* --- Buttons --- */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.625rem 1.25rem;
    font-size: 0.9375rem;
    font-weight: 600;
    font-family: var(--font-family);
    border-radius: var(--radius-md);
    border: 1.5px solid transparent;
    cursor: pointer;
    transition: var(--transition);
    text-decoration: none;
    white-space: nowrap;
    line-height: 1.4;
}

.btn:disabled {
    opacity: 0.55;
    cursor: not-allowed;
    pointer-events: none;
}

.btn-primary {
    background-color: var(--color-800);
    color: var(--text-inverse);
    border-color: var(--color-800);
}

.btn-primary:hover {
    background-color: var(--color-900);
    border-color: var(--color-900);
}

.btn-secondary {
    background-color: var(--color-200);
    color: var(--color-800);
    border-color: var(--color-200);
}

.btn-secondary:hover {
    background-color: var(--color-300);
    border-color: var(--color-300);
}

.btn-outline {
    background-color: transparent;
    color: var(--color-700);
    border-color: var(--color-300);
}

.btn-outline:hover {
    background-color: var(--color-100);
    border-color: var(--color-400);
}

.btn-danger {
    background-color: var(--error);
    color: #fff;
    border-color: var(--error);
}

.btn-danger:hover {
    background-color: #b91c1c;
    border-color: #b91c1c;
}

.btn-success {
    background-color: var(--success);
    color: #fff;
    border-color: var(--success);
}

.btn-success:hover {
    background-color: #15803d;
    border-color: #15803d;
}

.btn-sm {
    padding: 0.375rem 0.75rem;
    font-size: 0.8125rem;
}

.btn-lg {
    padding: 0.75rem 1.5rem;
    font-size: 1rem;
}

.btn-block {
    display: flex;
    width: 100%;
}

.btn-icon {
    padding: 0.5rem;
    border-radius: var(--radius-md);
}

/* --- Cards --- */
.card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-sm);
    overflow: hidden;
    min-width: 0;
    max-width: 100%;
}

.card-header {
    padding: 1.25rem 1.5rem;
    border-bottom: 1px solid var(--border-color);
    font-weight: 600;
    font-size: 1rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.card-body {
    padding: 1.5rem;
}

.card-footer {
    padding: 1rem 1.5rem;
    border-top: 1px solid var(--border-color);
    background: var(--color-50);
}

/* --- Alerts --- */
.alert {
    padding: 0.875rem 1rem;
    border-radius: var(--radius-md);
    font-size: 0.875rem;
    font-weight: 500;
    display: flex;
    align-items: flex-start;
    gap: 0.625rem;
    margin-bottom: 1rem;
}

.alert-error {
    background-color: #fef2f2;
    color: #991b1b;
    border: 1px solid #fecaca;
}

.alert-success {
    background-color: #f0fdf4;
    color: #166534;
    border: 1px solid #bbf7d0;
}

.alert-warning {
    background-color: #fffbeb;
    color: #92400e;
    border: 1px solid #fde68a;
}

.alert-info {
    background-color: var(--color-100);
    color: var(--color-700);
    border: 1px solid var(--color-200);
}

.alert svg {
    flex-shrink: 0;
    width: 1.25rem;
    height: 1.25rem;
    margin-top: 0.0625rem;
}

/* --- Badge --- */
.badge {
    display: inline-flex;
    align-items: center;
    padding: 0.1875rem 0.625rem;
    font-size: 0.75rem;
    font-weight: 600;
    border-radius: var(--radius-full);
    letter-spacing: 0.02em;
}

.badge-active {
    background-color: #dcfce7;
    color: #166534;
}

.badge-inactive {
    background-color: #fee2e2;
    color: #991b1b;
}

.badge-role {
    background-color: var(--color-100);
    color: var(--color-700);
}

/* --- Table --- */
.table-responsive {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
}

.table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.875rem;
}

.table th,
.table td {
    padding: 0.75rem 1rem;
    text-align: left;
    border-bottom: 1px solid var(--border-color);
    white-space: nowrap;
}

.table th {
    font-weight: 600;
    color: var(--text-secondary);
    background-color: var(--color-50);
    font-size: 0.8125rem;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.table tbody tr:hover {
    background-color: var(--color-50);
}

.table tbody tr:last-child td {
    border-bottom: none;
}

/* --- Login Page --- */
.login-wrapper {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 100vh;
    padding: 1rem;
    background-color: var(--color-100);
    background-image: 
        radial-gradient(at 20% 50%, var(--color-200) 0, transparent 50%),
        radial-gradient(at 80% 50%, var(--color-200) 0, transparent 50%);
}

.login-card {
    width: 100%;
    max-width: 420px;
    background: var(--bg-card);
    border-radius: var(--radius-xl);
    box-shadow: var(--shadow-xl);
    overflow: hidden;
}

.login-header {
    padding: 2rem 2rem 1.25rem;
    text-align: center;
}

.login-logo {
    width: 56px;
    height: 56px;
    background: var(--color-800);
    border-radius: var(--radius-lg);
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1rem;
}

.login-logo svg {
    width: 28px;
    height: 28px;
    color: var(--text-inverse);
}

.login-header h1 {
    font-size: 1.375rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 0.25rem;
}

.login-header p {
    font-size: 0.875rem;
    color: var(--text-secondary);
}

.login-body {
    padding: 1rem 2rem 2rem;
}

.login-footer {
    padding: 1.25rem 2rem;
    text-align: center;
    background: var(--color-50);
    border-top: 1px solid var(--border-color);
}

.login-footer p {
    font-size: 0.8125rem;
    color: var(--text-muted);
}

.login-lockout-timer {
    text-align: center;
    padding: 1rem;
    background: var(--color-100);
    border-radius: var(--radius-md);
    margin-bottom: 1rem;
}

.login-lockout-timer .timer {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--error);
    font-family: var(--font-mono);
}

/* --- Dashboard Layout --- */
.app-layout {
    display: flex;
    min-height: 100vh;
}

/* SIDEBAR */
.sidebar {
    width: var(--sidebar-width);
    background: var(--bg-sidebar);
    color: var(--text-inverse);
    display: flex;
    flex-direction: column;
    position: fixed;
    top: 0;
    left: 0;
    height: 100vh;
    z-index: 1000;
    transition: var(--transition-slow);
    overflow-y: auto;
    overflow-x: hidden;
}

.sidebar-header {
    padding: 1.25rem 1.25rem;
    display: flex;
    align-items: center;
    gap: 0.75rem;
    border-bottom: 1px solid var(--color-700);
    min-height: var(--header-height);
    flex-shrink: 0;
}

.sidebar-logo {
    width: 36px;
    height: 36px;
    background: var(--color-700);
    border-radius: var(--radius-sm);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.sidebar-logo svg {
    width: 20px;
    height: 20px;
    color: var(--color-200);
}

.sidebar-brand {
    font-size: 0.9375rem;
    font-weight: 700;
    letter-spacing: -0.01em;
    line-height: 1.3;
    word-break: break-word;
}

.sidebar-nav {
    flex: 1;
    padding: 0.75rem 0;
}

.nav-section {
    padding: 0.5rem 1.25rem;
    margin-top: 0.5rem;
}

.nav-section-title {
    font-size: 0.6875rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--color-400);
    margin-bottom: 0.5rem;
}

.nav-item {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.625rem 1.25rem;
    color: var(--color-300);
    font-size: 0.875rem;
    font-weight: 500;
    border-radius: 0;
    transition: var(--transition);
    cursor: pointer;
    text-decoration: none;
    border-left: 3px solid transparent;
}

.nav-item:hover {
    color: var(--text-inverse);
    background: var(--color-800);
}

.nav-item.active {
    color: var(--text-inverse);
    background: var(--color-800);
    border-left-color: var(--color-300);
}

.nav-item svg {
    width: 20px;
    height: 20px;
    flex-shrink: 0;
}

.nav-item span {
    white-space: nowrap;
    overflow: hidden;
}

.nav-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 20px;
    height: 20px;
    padding: 0 6px;
    border-radius: 10px;
    background: var(--color-primary);
    color: #fff;
    font-size: 0.7rem;
    font-weight: 700;
    margin-left: auto;
    flex-shrink: 0;
}

.sidebar-footer {
    padding: 1rem 1.25rem;
    border-top: 1px solid var(--color-700);
    flex-shrink: 0;
}

/* MAIN CONTENT */
.main-content {
    flex: 1;
    margin-left: var(--sidebar-width);
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    min-width: 0;
    overflow-x: hidden;
    transition: var(--transition-slow);
}

/* HEADER */
.app-header {
    height: var(--header-height);
    background: var(--bg-header);
    border-bottom: 1px solid var(--border-color);
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 1.5rem;
    position: sticky;
    top: 0;
    z-index: 500;
    box-shadow: var(--shadow-sm);
}

.header-left {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.header-right {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.sidebar-toggle {
    display: none;
    background: none;
    border: none;
    color: var(--text-secondary);
    cursor: pointer;
    padding: 0.5rem;
    border-radius: var(--radius-sm);
    transition: var(--transition);
}

.sidebar-toggle:hover {
    background: var(--color-100);
    color: var(--text-primary);
}

.sidebar-toggle svg {
    width: 24px;
    height: 24px;
}

.page-title {
    font-size: 1.125rem;
    font-weight: 600;
    color: var(--text-primary);
}

/* PROFILE DROPDOWN */
.profile-container {
    position: relative;
}

.profile-trigger {
    display: flex;
    align-items: center;
    gap: 0.625rem;
    padding: 0.375rem 0.625rem;
    border-radius: var(--radius-md);
    cursor: pointer;
    transition: var(--transition);
    background: none;
    border: 1.5px solid transparent;
}

.profile-trigger:hover {
    background: var(--color-100);
    border-color: var(--border-color);
}

.profile-avatar {
    width: 36px;
    height: 36px;
    border-radius: var(--radius-full);
    background: var(--color-700);
    color: var(--text-inverse);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.8125rem;
    font-weight: 700;
    flex-shrink: 0;
}

.profile-info {
    text-align: left;
    line-height: 1.3;
}

.profile-name {
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--text-primary);
    display: block;
}

.profile-role {
    font-size: 0.75rem;
    color: var(--text-muted);
    display: block;
}

.profile-chevron {
    width: 16px;
    height: 16px;
    color: var(--text-muted);
    transition: var(--transition);
}

.profile-trigger.active .profile-chevron {
    transform: rotate(180deg);
}

/* Profile Dropdown Card */
.profile-dropdown {
    position: absolute;
    top: calc(100% + 0.5rem);
    right: 0;
    width: 260px;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-lg);
    z-index: 600;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-8px);
    transition: var(--transition);
}

.profile-dropdown.show {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.profile-dropdown-header {
    padding: 1rem 1rem;
    border-bottom: 1px solid var(--border-color);
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.profile-dropdown-avatar {
    width: 44px;
    height: 44px;
    border-radius: var(--radius-full);
    background: var(--color-700);
    color: var(--text-inverse);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1rem;
    font-weight: 700;
    flex-shrink: 0;
}

.profile-dropdown-name {
    font-size: 0.9375rem;
    font-weight: 600;
    color: var(--text-primary);
}

.profile-dropdown-email {
    font-size: 0.8125rem;
    color: var(--text-muted);
}

.profile-dropdown-menu {
    padding: 0.5rem 0;
}

.profile-dropdown-item {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.625rem 1rem;
    font-size: 0.875rem;
    color: var(--text-secondary);
    text-decoration: none;
    transition: var(--transition);
    cursor: pointer;
    border: none;
    background: none;
    width: 100%;
    font-family: var(--font-family);
}

.profile-dropdown-item:hover {
    background: var(--color-50);
    color: var(--text-primary);
}

.profile-dropdown-item svg {
    width: 18px;
    height: 18px;
    flex-shrink: 0;
}

.profile-dropdown-divider {
    height: 1px;
    background: var(--border-color);
    margin: 0.25rem 0;
}

.profile-dropdown-item.logout {
    color: var(--error);
}

.profile-dropdown-item.logout:hover {
    background: #fef2f2;
}

/* MAIN PAGE CONTENT */
.page-content {
    flex: 1;
    padding: 1.5rem;
    min-width: 0;
    overflow-x: hidden;
}

/* FOOTER */
.app-footer {
    height: var(--footer-height);
    background: var(--bg-header);
    border-top: 1px solid var(--border-color);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0 1.5rem;
    font-size: 0.8125rem;
    color: var(--text-muted);
}

/* OVERLAY (mobile sidebar) */
.sidebar-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.4);
    z-index: 999;
    opacity: 0;
    visibility: hidden;
    transition: var(--transition-slow);
}

.sidebar-overlay.active {
    opacity: 1;
    visibility: visible;
}

/* --- Stats Cards --- */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1rem;
    margin-bottom: 1.5rem;
    max-width: 100%;
    overflow: hidden;
}

.stat-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 1.25rem;
    display: flex;
    align-items: flex-start;
    gap: 1rem;
}

.stat-icon {
    width: 44px;
    height: 44px;
    border-radius: var(--radius-md);
    background: var(--color-100);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.stat-icon svg {
    width: 22px;
    height: 22px;
    color: var(--color-600);
}

.stat-value {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text-primary);
    line-height: 1.2;
}

.stat-label {
    font-size: 0.8125rem;
    color: var(--text-muted);
    margin-top: 0.125rem;
    word-break: break-word;
    overflow-wrap: break-word;
}

/* --- Modal --- */
.modal-backdrop {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.5);
    z-index: 2000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1rem;
    opacity: 0;
    visibility: hidden;
    transition: var(--transition);
}

.modal-backdrop.show {
    opacity: 1;
    visibility: visible;
}

.modal {
    background: var(--bg-card);
    border-radius: var(--radius-xl);
    box-shadow: var(--shadow-xl);
    width: 100%;
    max-width: 540px;
    max-height: 90vh;
    overflow-y: auto;
    transform: scale(0.95);
    transition: var(--transition);
}

.modal-backdrop.show .modal {
    transform: scale(1);
}

.modal-header {
    padding: 1.25rem 1.5rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    border-bottom: 1px solid var(--border-color);
}

.modal-title {
    font-size: 1.125rem;
    font-weight: 600;
}

.modal-close {
    background: none;
    border: none;
    color: var(--text-muted);
    cursor: pointer;
    padding: 0.25rem;
    border-radius: var(--radius-sm);
    transition: var(--transition);
}

.modal-close:hover {
    background: var(--color-100);
    color: var(--text-primary);
}

.modal-close svg {
    width: 20px;
    height: 20px;
}

.modal-body {
    padding: 1.5rem;
}

.modal-footer {
    padding: 1rem 1.5rem;
    border-top: 1px solid var(--border-color);
    display: flex;
    gap: 0.5rem;
    justify-content: flex-end;
}

/* --- Spinner --- */
.spinner {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 2.5px solid var(--color-200);
    border-top-color: var(--color-600);
    border-radius: 50%;
    animation: spin 0.6s linear infinite;
}

.spinner-sm {
    width: 16px;
    height: 16px;
    border-width: 2px;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* --- Empty State --- */
.empty-state {
    text-align: center;
    padding: 3rem 1.5rem;
}

.empty-state svg {
    width: 48px;
    height: 48px;
    color: var(--text-muted);
    margin-bottom: 1rem;
}

.empty-state h3 {
    font-size: 1rem;
    color: var(--text-secondary);
    margin-bottom: 0.5rem;
}

.empty-state p {
    font-size: 0.875rem;
    color: var(--text-muted);
}

/* --- Scrollable Table Container --- */
.table-scroll-container {
    max-height: 420px;
    overflow-y: auto;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    width: 100%;
    max-width: 100%;
}

.table-scroll-container.paginated {
    max-height: none;
    overflow-y: visible;
    border-bottom: none;
    border-radius: var(--radius-md) var(--radius-md) 0 0;
}

.table-scroll-container .table {
    margin: 0;
}

.table-scroll-container .table thead th {
    position: sticky;
    top: 0;
    z-index: 10;
    background-color: var(--bg-card);
    box-shadow: inset 0 -1px 0 var(--border-color);
}

/* --- Pagination --- */
.pagination-wrapper {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 0.75rem;
    padding: 0.75rem 1rem;
    border-top: 1px solid var(--border-color);
    background: var(--bg-card);
    font-size: 0.8125rem;
    color: var(--text-secondary);
}

.pagination-info {
    white-space: nowrap;
}

.pagination-controls {
    display: flex;
    align-items: center;
    gap: 0.25rem;
}

.pagination-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 32px;
    height: 32px;
    padding: 0 0.5rem;
    font-size: 0.8125rem;
    font-family: var(--font-family);
    font-weight: 500;
    color: var(--text-secondary);
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    cursor: pointer;
    transition: var(--transition);
    text-decoration: none;
    line-height: 1;
}

.pagination-btn:hover:not(:disabled):not(.active) {
    background: var(--color-100);
    color: var(--text-primary);
    border-color: var(--color-300);
}

.pagination-btn.active {
    background: var(--accent);
    color: var(--text-inverse);
    border-color: var(--accent);
    font-weight: 600;
}

.pagination-btn:disabled {
    opacity: 0.4;
    cursor: not-allowed;
}

.pagination-ellipsis {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 32px;
    height: 32px;
    font-size: 0.8125rem;
    color: var(--text-muted);
    user-select: none;
}

.pagination-size {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.pagination-size select {
    padding: 0.25rem 0.5rem;
    font-size: 0.8125rem;
    font-family: var(--font-family);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    background: var(--bg-card);
    color: var(--text-primary);
    cursor: pointer;
}

@media (max-width: 767px) {
    .pagination-wrapper {
        padding: 0.625rem 0.75rem;
        gap: 0.5rem;
    }
    .pagination-controls {
        justify-content: center;
        flex-wrap: wrap;
    }
    .pagination-size {
        justify-content: center;
    }
}

/* --- PR Form Grid (multi-column) --- */
.pr-form-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1rem 1.25rem;
}
.pr-form-grid .full-width {
    grid-column: 1 / -1;
}
.pr-form-grid .span-2 {
    grid-column: span 2;
}

/* ------------------------------------------
   RESPONSIVE BREAKPOINTS
   325px -> 480px -> 768px -> 1024px -> max
   ------------------------------------------ */

/* Mobile: 325px to 767px */
@media (max-width: 767px) {
    :root {
        --sidebar-width: 260px;
    }

    .sidebar {
        transform: translateX(-100%);
    }

    .sidebar.open {
        transform: translateX(0);
    }

    .main-content {
        margin-left: 0;
    }

    .sidebar-toggle {
        display: flex;
    }

    .page-content {
        padding: 1rem;
    }

    .app-header {
        padding: 0 1rem;
    }

    .page-title {
        font-size: 0.9375rem;
    }

    .profile-info {
        display: none;
    }

    .profile-dropdown {
        position: fixed;
        top: auto;
        bottom: 0;
        left: 0;
        right: 0;
        width: 100%;
        border-radius: var(--radius-xl) var(--radius-xl) 0 0;
        transform: translateY(100%);
    }

    .profile-dropdown.show {
        transform: translateY(0);
    }

    .login-card {
        max-width: 100%;
        border-radius: var(--radius-lg);
    }

    .login-header {
        padding: 1.5rem 1.25rem 1rem;
    }

    .login-body {
        padding: 0.75rem 1.25rem 1.5rem;
    }

    .login-header h1 {
        font-size: 1.1875rem;
    }

    .stats-grid {
        grid-template-columns: 1fr;
    }

    .modal {
        max-width: 100%;
        margin: 0.5rem;
        max-height: 95vh;
    }

    .modal-footer {
        flex-direction: column;
    }

    .modal-footer .btn {
        width: 100%;
    }

    .table th,
    .table td {
        padding: 0.5rem 0.625rem;
        font-size: 0.8125rem;
    }

    .table-responsive {
        margin: 0 -1px;
    }

    /* PR form: 1 column on mobile */
    .pr-form-grid {
        grid-template-columns: 1fr;
    }
    .pr-form-grid .span-2 {
        grid-column: 1 / -1;
    }

    /* Scrollable tables shorter on mobile */
    .table-scroll-container {
        max-height: 320px;
    }

    .card-header {
        flex-wrap: wrap;
        gap: 0.5rem;
    }
}

/* Small mobile: 325px - 479px */
@media (max-width: 479px) {
    html {
        font-size: 14px;
    }

    .login-wrapper {
        padding: 0.5rem;
    }

    .login-header {
        padding: 1.25rem 1rem 0.75rem;
    }

    .login-body {
        padding: 0.5rem 1rem 1.25rem;
    }

    .login-logo {
        width: 48px;
        height: 48px;
    }

    .login-logo svg {
        width: 24px;
        height: 24px;
    }

    .page-content {
        padding: 0.75rem;
    }

    .card-body {
        padding: 1rem;
    }

    .card-header {
        padding: 1rem;
        gap: 0.5rem;
    }

    .table-scroll-container {
        max-height: 280px;
    }

    .page-title {
        font-size: 0.875rem;
    }
}

/* Tablet: 768px to 1023px */
@media (min-width: 768px) and (max-width: 1023px) {
    :root {
        --sidebar-width: 68px;
    }

    .sidebar-brand,
    .nav-item span,
    .nav-section-title {
        display: none;
    }

    .sidebar-header {
        justify-content: center;
        padding: 1.25rem 0.5rem;
    }

    .nav-item {
        justify-content: center;
        padding: 0.75rem;
        border-left: none;
    }

    .nav-item.active {
        border-left: none;
        background: var(--color-700);
        border-radius: var(--radius-sm);
        margin: 0.125rem 0.5rem;
    }

    .nav-section {
        padding: 0.5rem 0;
    }

    .sidebar-footer {
        display: flex;
        justify-content: center;
    }

    .sidebar-toggle {
        display: flex;
    }

    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    /* PR form: 2 columns on tablet */
    .pr-form-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    .pr-form-grid .span-2 {
        grid-column: 1 / -1;
    }
}

/* Desktop: 1024px - 1399px */
@media (min-width: 1024px) {
    .stats-grid {
        grid-template-columns: repeat(4, 1fr);
    }

    /* PR form: 3 columns on desktop */
    .pr-form-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

/* Large desktop: 1400px+ */
@media (min-width: 1400px) {
    .page-content {
        padding: 2rem;
    }

    /* PR form: 4 columns on large desktop */
    .pr-form-grid {
        grid-template-columns: repeat(4, 1fr);
    }

    .table-scroll-container {
        max-height: 520px;
    }
}

/* --- Print Styles --- */
@media print {
    .sidebar, .app-header, .app-footer, .sidebar-overlay {
        display: none !important;
    }

    .main-content {
        margin: 0 !important;
    }

    .page-content {
        padding: 0;
    }
}

/* ============================================
   THEME SYSTEM
   Applied via data-theme attribute on <html>
   ============================================ */

/* --- Purchasing Blue --- */
[data-theme="purchasing-blue"] {
    --color-50:  #eff6ff;
    --color-100: #dbeafe;
    --color-200: #bfdbfe;
    --color-300: #93c5fd;
    --color-400: #60a5fa;
    --color-500: #3b82f6;
    --color-600: #2563eb;
    --color-700: #1d4ed8;
    --color-800: #1e40af;
    --color-900: #1e3a5f;
    --color-950: #172554;
    --success: #16a34a;
    --error:   #dc2626;
    --warning: #d97706;
}

/* --- Executive Indigo --- */
[data-theme="executive-indigo"] {
    --color-50:  #eef2ff;
    --color-100: #e0e7ff;
    --color-200: #c7d2fe;
    --color-300: #a5b4fc;
    --color-400: #818cf8;
    --color-500: #6366f1;
    --color-600: #4f46e5;
    --color-700: #4338ca;
    --color-800: #3730a3;
    --color-900: #312e81;
    --color-950: #1e1b4b;
    --success: #16a34a;
    --error:   #dc2626;
    --warning: #d97706;
}

/* --- Dark Mode --- */
[data-theme="dark"] {
    --color-50:  #1e293b;
    --color-100: #1e293b;
    --color-200: #334155;
    --color-300: #475569;
    --color-400: #64748b;
    --color-500: #94a3b8;
    --color-600: #cbd5e1;
    --color-700: #e2e8f0;
    --color-800: #f1f5f9;
    --color-900: #0f172a;
    --color-950: #020617;
    --bg-primary:    #0f172a;
    --bg-secondary:  #1e293b;
    --bg-card:       #1e293b;
    --bg-header:     #1e293b;
    --bg-sidebar:    #0f172a;
    --text-primary:   #f1f5f9;
    --text-secondary: #94a3b8;
    --text-muted:     #64748b;
    --text-inverse:   #f8fafc;
    --border-color:   #334155;
    --border-focus:   #64748b;
    --accent:         #60a5fa;
    --accent-hover:   #93c5fd;
    --accent-light:   #334155;
    --success: #4ade80;
    --error:   #f87171;
    --warning: #fbbf24;
    --info:    #94a3b8;
    --shadow-sm:  0 1px 2px rgba(0,0,0,0.3);
    --shadow-md:  0 4px 6px -1px rgba(0,0,0,0.4), 0 2px 4px -2px rgba(0,0,0,0.3);
    --shadow-lg:  0 10px 15px -3px rgba(0,0,0,0.5), 0 4px 6px -4px rgba(0,0,0,0.4);
    --shadow-xl:  0 20px 25px -5px rgba(0,0,0,0.6), 0 8px 10px -6px rgba(0,0,0,0.5);
}

/* ── Dark: Sidebar ── */
[data-theme="dark"] .sidebar {
    background: #0c1322;
}

[data-theme="dark"] .sidebar-header {
    border-bottom-color: #1e293b;
}

[data-theme="dark"] .sidebar-logo {
    background: #1e293b;
}

[data-theme="dark"] .sidebar-logo svg {
    color: #60a5fa;
}

[data-theme="dark"] .nav-item {
    color: #94a3b8;
}

[data-theme="dark"] .nav-item:hover {
    color: #f1f5f9;
    background: #1e293b;
}

[data-theme="dark"] .nav-item.active {
    color: #f1f5f9;
    background: #1e293b;
    border-left-color: #60a5fa;
}

[data-theme="dark"] .nav-section-title {
    color: #475569;
}

[data-theme="dark"] .nav-badge {
    background: #60a5fa;
    color: #0f172a;
}

[data-theme="dark"] .sidebar-footer {
    border-top-color: #1e293b;
}

/* ── Dark: Header ── */
[data-theme="dark"] .app-header {
    box-shadow: 0 1px 3px rgba(0,0,0,0.4);
}

[data-theme="dark"] .sidebar-toggle:hover {
    background: #334155;
    color: #f1f5f9;
}

[data-theme="dark"] .profile-trigger:hover {
    background: #334155;
    border-color: #475569;
}

[data-theme="dark"] .profile-dropdown {
    background: #1e293b;
    border-color: #334155;
    box-shadow: 0 10px 40px rgba(0,0,0,0.6);
}

[data-theme="dark"] .profile-dropdown-item:hover {
    background: #334155;
    color: #f1f5f9;
}

[data-theme="dark"] .profile-dropdown-item.logout {
    color: #f87171;
}

[data-theme="dark"] .profile-dropdown-item.logout:hover {
    background: rgba(248,113,113,0.1);
    color: #fca5a5;
}

/* ── Dark: Tables ── */
[data-theme="dark"] .table thead th {
    background-color: #0f172a;
    color: #94a3b8;
}

[data-theme="dark"] .table-scroll-container .table thead th {
    background-color: #162032;
}

[data-theme="dark"] .table tbody tr:hover {
    background-color: rgba(51,65,85,0.5);
}

[data-theme="dark"] .table td {
    color: #e2e8f0;
}

/* ── Dark: Cards ── */
[data-theme="dark"] .card {
    box-shadow: 0 1px 3px rgba(0,0,0,0.3);
}

[data-theme="dark"] .card-footer {
    background: #0f172a;
}

[data-theme="dark"] .stat-icon {
    background: #334155;
}

/* ── Dark: Stat-icon color override (inline bg) ── */
[data-theme="dark"] .stat-icon[style*="background:#dcfce7"],
[data-theme="dark"] .stat-icon[style*="background: #dcfce7"] {
    background: rgba(74,222,128,0.15) !important;
}

[data-theme="dark"] .stat-icon[style*="background:#fee2e2"],
[data-theme="dark"] .stat-icon[style*="background: #fee2e2"] {
    background: rgba(248,113,113,0.15) !important;
}

[data-theme="dark"] .stat-icon[style*="background:#fef3c7"],
[data-theme="dark"] .stat-icon[style*="background: #fef3c7"] {
    background: rgba(251,191,36,0.15) !important;
}

[data-theme="dark"] .stat-icon[style*="background:#ede9fe"],
[data-theme="dark"] .stat-icon[style*="background: #ede9fe"] {
    background: rgba(139,92,246,0.15) !important;
}

[data-theme="dark"] .stat-icon[style*="background:#cffafe"],
[data-theme="dark"] .stat-icon[style*="background: #cffafe"] {
    background: rgba(6,182,212,0.15) !important;
}

/* ── Dark: Buttons ── */
[data-theme="dark"] .btn-primary {
    background-color: #60a5fa;
    border-color: #60a5fa;
    color: #0f172a;
    font-weight: 700;
}

[data-theme="dark"] .btn-primary:hover {
    background-color: #93c5fd;
    border-color: #93c5fd;
    color: #0f172a;
}

[data-theme="dark"] .btn-secondary {
    background-color: #334155;
    color: #e2e8f0;
    border-color: #475569;
}

[data-theme="dark"] .btn-secondary:hover {
    background-color: #475569;
    color: #f1f5f9;
    border-color: #64748b;
}

[data-theme="dark"] .btn-outline {
    color: #e2e8f0;
    border-color: #475569;
}

[data-theme="dark"] .btn-outline:hover {
    background-color: #334155;
    color: #f1f5f9;
    border-color: #64748b;
}

[data-theme="dark"] .btn-danger {
    background-color: #ef4444;
    border-color: #ef4444;
}

[data-theme="dark"] .btn-danger:hover {
    background-color: #f87171;
    border-color: #f87171;
}

[data-theme="dark"] .btn-success {
    background-color: #22c55e;
    border-color: #22c55e;
}

[data-theme="dark"] .btn-success:hover {
    background-color: #4ade80;
    border-color: #4ade80;
}

/* ── Dark: Form Controls ── */
[data-theme="dark"] .form-control,
[data-theme="dark"] .form-select {
    background-color: #0f172a;
    color: #f1f5f9;
    border-color: #475569;
}

[data-theme="dark"] .form-control:focus,
[data-theme="dark"] .form-select:focus {
    border-color: #60a5fa;
    box-shadow: 0 0 0 3px rgba(96,165,250,0.2);
}

[data-theme="dark"] .form-control::placeholder {
    color: #64748b;
}

[data-theme="dark"] .form-label {
    color: #e2e8f0;
}

/* ── Dark: Badges ── */
[data-theme="dark"] .badge-role {
    background: #334155;
    color: #e2e8f0;
}

[data-theme="dark"] .badge-active {
    background: rgba(74,222,128,0.15);
    color: #4ade80;
}

[data-theme="dark"] .badge-inactive {
    background: rgba(248,113,113,0.15);
    color: #f87171;
}

/* ── Dark: Alerts ── */
[data-theme="dark"] .alert-error {
    background-color: rgba(248,113,113,0.1);
    color: #fca5a5;
    border-color: rgba(248,113,113,0.25);
}

[data-theme="dark"] .alert-success {
    background-color: rgba(74,222,128,0.1);
    color: #86efac;
    border-color: rgba(74,222,128,0.25);
}

[data-theme="dark"] .alert-warning {
    background-color: rgba(251,191,36,0.1);
    color: #fde68a;
    border-color: rgba(251,191,36,0.25);
}

[data-theme="dark"] .alert-info {
    background-color: rgba(96,165,250,0.1);
    color: #93c5fd;
    border-color: rgba(96,165,250,0.25);
}

/* Override hardcoded inline alert styles */
[data-theme="dark"] .alert[style*="background:#dbeafe"] {
    background: rgba(96,165,250,0.1) !important;
    color: #93c5fd !important;
    border-color: rgba(96,165,250,0.25) !important;
}

[data-theme="dark"] .alert[style*="background:#fff3cd"],
[data-theme="dark"] .alert-warning[style*="background:#fff3cd"] {
    background: rgba(251,191,36,0.1) !important;
    color: #fde68a !important;
    border-color: rgba(251,191,36,0.25) !important;
}

/* ── Dark: Modals ── */
[data-theme="dark"] .modal-backdrop {
    background: rgba(0,0,0,0.7);
}

[data-theme="dark"] .modal {
    box-shadow: 0 20px 60px rgba(0,0,0,0.8);
}

[data-theme="dark"] .modal-close:hover {
    background: #334155;
    color: #f1f5f9;
}

/* ── Dark: Pagination ── */
[data-theme="dark"] .pagination-wrapper {
    background: #0f172a;
}

[data-theme="dark"] .pagination-btn {
    background: #1e293b;
    border-color: #334155;
    color: #94a3b8;
}

[data-theme="dark"] .pagination-btn:hover:not(:disabled):not(.active) {
    background: #334155;
    color: #f1f5f9;
    border-color: #475569;
}

[data-theme="dark"] .pagination-btn.active {
    background: #60a5fa;
    border-color: #60a5fa;
    color: #0f172a;
}

[data-theme="dark"] .pagination-size select {
    background-color: #0f172a;
    color: #f1f5f9;
    border-color: #475569;
}

/* ── Dark: Footer ── */
[data-theme="dark"] .app-footer {
    color: #64748b;
    background: #0f172a;
}

/* ── Dark: Login ── */
[data-theme="dark"] .login-wrapper {
    background-color: #020617;
}

/* ── Dark: Loading overlay ── */
[data-theme="dark"] .loading-overlay {
    background: rgba(15,23,42,0.85);
}

/* ── Dark: Tooltip ── */
[data-theme="dark"] [data-tooltip]::after {
    background: #f1f5f9;
    color: #0f172a;
}

/* ── Dark: Scrollbar ── */
[data-theme="dark"] ::-webkit-scrollbar-thumb {
    background: #475569;
}

[data-theme="dark"] ::-webkit-scrollbar-thumb:hover {
    background: #64748b;
}

/* ── Dark: Status colors (semantic classes) ── */
.text-stat-pending   { color: #92400e; }
.text-stat-approved  { color: #166534; }
.text-stat-disapproved { color: #991b1b; }
.text-stat-cancelled { color: #475569; }
.text-stat-spending  { color: #166534; }

[data-theme="dark"] .text-stat-pending   { color: #fbbf24; }
[data-theme="dark"] .text-stat-approved  { color: #4ade80; }
[data-theme="dark"] .text-stat-disapproved { color: #f87171; }
[data-theme="dark"] .text-stat-cancelled { color: #94a3b8; }
[data-theme="dark"] .text-stat-spending  { color: #4ade80; }

/* Status pill badges (inline in tables) */
[data-theme="dark"] .status-approved   { background: rgba(74,222,128,0.15) !important; color: #4ade80 !important; }
[data-theme="dark"] .status-pending    { background: rgba(251,191,36,0.15) !important; color: #fbbf24 !important; }
[data-theme="dark"] .status-in_progress { background: rgba(96,165,250,0.15) !important; color: #60a5fa !important; }
[data-theme="dark"] .status-disapproved { background: rgba(248,113,113,0.15) !important; color: #f87171 !important; }
[data-theme="dark"] .status-cancelled  { background: rgba(148,163,184,0.15) !important; color: #94a3b8 !important; }

/* ── Dark: Analytics stat cards ── */
[data-theme="dark"] .analytics-stat {
    background: #1e293b;
    border-color: #334155;
}

/* ── Dark: Summary stat cards ── */
[data-theme="dark"] .stat-card {
    background: #1e293b;
    border-color: #334155;
}

/* ── Dark: Permission toggles (RBAC) ── */
[data-theme="dark"] .perm-group-header {
    background: #0f172a;
}

[data-theme="dark"] .perm-group-items {
    background: #1e293b;
}

[data-theme="dark"] .perm-item:hover {
    background: #334155;
}

/* ── Dark: Signature preview ── */
[data-theme="dark"] .signature-preview {
    background: #0f172a;
    border-color: #334155;
}

/* ── Dark: Profile card ── */
[data-theme="dark"] .profile-avatar-large {
    background: #60a5fa;
    color: #0f172a;
}

/* ── Dark: Export modal ── */
[data-theme="dark"] .export-modal-overlay {
    background: rgba(0,0,0,0.7);
}

[data-theme="dark"] .export-modal {
    background: #1e293b;
    border: 1px solid #334155;
    box-shadow: 0 20px 60px rgba(0,0,0,0.8);
}

[data-theme="dark"] .export-modal select,
[data-theme="dark"] .export-modal input {
    background: #0f172a;
    color: #f1f5f9;
    border-color: #475569;
}

/* ── Dark: Chart.js canvas context ── */
[data-theme="dark"] .chart-container {
    color: #e2e8f0;
}

/* ── Dark: Text helpers ── */
[data-theme="dark"] .text-muted {
    color: #64748b;
}

[data-theme="dark"] .text-secondary {
    color: #94a3b8;
}

/* --- Scrollbar --- */
::-webkit-scrollbar {
    width: 6px;
    height: 6px;
}

::-webkit-scrollbar-track {
    background: transparent;
}

::-webkit-scrollbar-thumb {
    background: var(--color-300);
    border-radius: 3px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--color-400);
}

/* --- Animations --- */
@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes slideInUp {
    from { opacity: 0; transform: translateY(16px); }
    to { opacity: 1; transform: translateY(0); }
}

.animate-fade-in {
    animation: fadeIn 0.3s ease;
}

.animate-slide-in {
    animation: slideInUp 0.3s ease;
}

/* --- Loading Overlay --- */
.loading-overlay {
    position: fixed;
    inset: 0;
    background: rgba(255,255,255,0.8);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
}

/* --- Tooltip --- */
[data-tooltip] {
    position: relative;
}

[data-tooltip]::after {
    content: attr(data-tooltip);
    position: absolute;
    bottom: 100%;
    left: 50%;
    transform: translateX(-50%);
    padding: 0.375rem 0.625rem;
    background: var(--color-800);
    color: var(--text-inverse);
    font-size: 0.75rem;
    border-radius: var(--radius-sm);
    white-space: nowrap;
    opacity: 0;
    visibility: hidden;
    transition: var(--transition);
    pointer-events: none;
    margin-bottom: 0.5rem;
}

[data-tooltip]:hover::after {
    opacity: 1;
    visibility: visible;
}
