/* === Murikual Shared Foundation === */

:root {
    /* Colors — core */
    --sidebar-bg: #111827;
    --sidebar-text: #9ca3af;
    --sidebar-text-hover: #f3f4f6;
    --sidebar-active-bg: rgba(255, 255, 255, 0.08);
    --content-bg: #f9fafb;
    --card-bg: #fff;
    --text: #111827;
    --text-secondary: #6b7280;
    --border: #e5e7eb;
    --accent: #2563eb;
    --accent-hover: #1d4ed8;
    --green: #059669;
    --red: #dc2626;
    --yellow: #d97706;

    /* Colors — gray scale */
    --gray-50: #f9fafb;
    --gray-100: #f3f4f6;
    --gray-200: #e5e7eb;
    --gray-300: #d1d5db;
    --gray-400: #9ca3af;
    --gray-500: #6b7280;
    --gray-600: #4b5563;
    --gray-900: #111827;

    /* Colors — semantic (light bg + dark fg for badges) */
    --green-50: #ecfdf5;
    --green-500: #059669;
    --green-700: #047857;
    --red-50: #fef2f2;
    --red-200: #fecaca;
    --red-600: #dc2626;
    --red-700: #b91c1c;
    --blue-50: #eff6ff;
    --blue-100: #dbeafe;
    --blue-700: #1d4ed8;
    --yellow-50: #fffbeb;
    --yellow-100: #fef3c7;
    --yellow-700: #b45309;
    --purple-50: #f5f3ff;
    --purple-100: #ede9fe;
    --purple-700: #6d28d9;
    --indigo-100: #e0e7ff;
    --indigo-700: #4338ca;
    --cyan-100: #cffafe;
    --cyan-700: #0e7490;

    /* Shadows */
    --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.05);
    --shadow: 0 1px 3px rgba(0, 0, 0, 0.1), 0 1px 2px rgba(0, 0, 0, 0.06);

    /* Border radius */
    --radius: 8px;
    --radius-sm: 4px;
    --radius-md: 6px;
    --radius-lg: 8px;
    --radius-full: 9999px;

    /* Spacing scale */
    --space-1: 0.25rem;
    --space-2: 0.5rem;
    --space-3: 0.75rem;
    --space-4: 1rem;
    --space-5: 1.25rem;
    --space-6: 1.5rem;

    /* Typography scale */
    --text-xs: 0.75rem;
    --text-sm: 0.8125rem;
    --text-base: 0.875rem;
    --text-lg: 1.125rem;
}

*, *::before, *::after { box-sizing: border-box; }

html, body {
    overflow-x: hidden;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    color: var(--text);
    background: var(--content-bg);
    margin: 0;
    -webkit-font-smoothing: antialiased;
}

a { color: var(--accent); text-decoration: none; }
a:hover { color: var(--accent-hover); text-decoration: none; }

/* ======================== LAYOUT ======================== */
.app-layout {
    display: flex;
    min-height: 100vh;
}

/* Sidebar */
.sidebar {
    width: 260px;
    background: var(--sidebar-bg);
    display: flex;
    flex-direction: column;
    flex-shrink: 0;
    position: fixed;
    top: 0;
    bottom: 0;
    left: 0;
    z-index: 100;
}

.sidebar-brand {
    padding: 1.25rem 1.5rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.sidebar-brand a {
    color: #fff;
    font-size: 1.125rem;
    font-weight: 600;
    letter-spacing: -0.01em;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.sidebar-collapse-btn {
    background: none;
    border: none;
    color: var(--sidebar-text);
    cursor: pointer;
    padding: 0.25rem;
    border-radius: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: color 0.15s ease, background 0.15s ease;
    flex-shrink: 0;
}

.sidebar-collapse-btn:hover {
    color: var(--sidebar-text-hover);
    background: var(--sidebar-active-bg);
}

.sidebar-collapse-btn svg {
    width: 18px;
    height: 18px;
}

.sidebar-logo {
    width: 28px;
    height: 28px;
}

.sidebar-brand a:hover { color: #fff; }

.sidebar-nav {
    padding: 0.75rem 0.75rem;
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.sidebar-section-label {
    padding: 0.5rem 0.75rem 0.25rem;
    font-size: 0.6875rem;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: rgba(255, 255, 255, 0.3);
}

.nav-item {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.5rem 0.75rem;
    border-radius: 6px;
    font-size: 0.875rem;
    color: var(--sidebar-text);
    transition: all 0.15s ease;
    font-weight: 400;
}

.nav-item:hover {
    color: var(--sidebar-text-hover);
    background: var(--sidebar-active-bg);
}

.nav-item.active {
    color: #fff;
    background: var(--sidebar-active-bg);
    font-weight: 500;
}

.nav-item .nav-icon {
    width: 20px;
    height: 20px;
    opacity: 0.5;
    flex-shrink: 0;
}

.nav-item.active .nav-icon,
.nav-item:hover .nav-icon {
    opacity: 0.8;
}

.sidebar-footer {
    padding: 1rem 1.5rem;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.sidebar-footer a,
.sidebar-footer button {
    color: var(--sidebar-text);
    font-size: 0.8125rem;
    background: none;
    border: none;
    padding: 0;
    cursor: pointer;
    font-family: inherit;
}

.sidebar-footer a:hover,
.sidebar-footer button:hover {
    color: var(--sidebar-text-hover);
}

/* Main content */
.main-content {
    margin-left: 0;
    flex: 1;
    min-width: 0;
    min-height: 100vh;
    overflow-x: hidden;
    background: var(--content-bg);
}

.content-header {
    background: var(--card-bg);
    border-bottom: 1px solid var(--border);
    padding: 1.25rem 2rem;
    position: sticky;
    top: 0;
    z-index: 50;
}

.content-header h1 {
    font-size: 1.25rem;
    font-weight: 600;
    margin: 0;
    color: var(--text);
}

.content-header .subtitle {
    font-size: 0.8125rem;
    color: var(--text-secondary);
    margin: 0.125rem 0 0;
}

.content-body {
    padding: 1.5rem 2rem 2rem;
    max-width: 1200px;
}

/* ======================== CARDS ======================== */
.card {
    background: var(--card-bg);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    box-shadow: var(--shadow-sm);
}

.card-header {
    padding: 1rem 1.25rem;
    background: var(--card-bg);
    border-bottom: 1px solid var(--border);
    font-weight: 600;
    font-size: 0.875rem;
}

.card-body { padding: 1.25rem; }
.card-body.p-0 { padding: 0; }

/* ======================== STAT CARDS ======================== */
.stat-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 1rem;
    margin-bottom: 1.5rem;
}

.stat-card {
    background: var(--card-bg);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    box-shadow: var(--shadow-sm);
    padding: 1.25rem;
}

.stat-value {
    font-size: 1.75rem;
    font-weight: 600;
    line-height: 1;
    color: var(--text);
}

.stat-label {
    font-size: 0.8125rem;
    color: var(--text-secondary);
    margin-top: 0.375rem;
}

/* ======================== TABLES ======================== */
.table-card {
    background: var(--card-bg);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    box-shadow: var(--shadow-sm);
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
}

.table-card-header {
    padding: 1rem 1.25rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid var(--border);
}

.table-card-header h2 {
    font-size: 0.875rem;
    font-weight: 600;
    margin: 0;
}

.data-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.875rem;
}

.data-table thead th {
    padding: 0.75rem 1.25rem;
    text-align: left;
    font-weight: 500;
    font-size: 0.75rem;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 0.04em;
    border-bottom: 1px solid var(--border);
    background: var(--gray-50);
    white-space: nowrap;
}

.data-table tbody td {
    padding: 0.75rem 1.25rem;
    border-bottom: 1px solid var(--gray-100);
    vertical-align: middle;
}

.data-table .col-nowrap {
    white-space: nowrap;
}

.data-table tbody tr:last-child td {
    border-bottom: none;
}

.data-table tbody tr:hover {
    background: var(--gray-50);
}

.data-table .text-end { text-align: right; }

/* ======================== BADGES ======================== */
.badge {
    display: inline-flex;
    align-items: center;
    padding: 0.2em 0.6em;
    border-radius: 9999px;
    font-size: 0.75rem;
    font-weight: 500;
    line-height: 1;
}

.badge-proxy { background: #dbeafe; color: #1e40af; }
.badge-static { background: #dcfce7; color: #166534; }

/* ======================== STATUS ======================== */
.status {
    display: inline-flex;
    align-items: center;
    gap: 0.375rem;
    font-size: 0.8125rem;
}

.status-dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    flex-shrink: 0;
}

.status-active .status-dot { background: var(--green); }
.status-active { color: var(--green); }
.status-disabled .status-dot { background: var(--gray-400); }
.status-disabled { color: var(--text-secondary); }

/* ======================== BUTTONS ======================== */
.btn {
    display: inline-flex;
    align-items: center;
    gap: 0.375rem;
    padding: 0.5rem 1rem;
    border-radius: 6px;
    font-size: 0.875rem;
    font-weight: 500;
    border: 1px solid transparent;
    cursor: pointer;
    transition: all 0.15s ease;
    text-decoration: none;
    line-height: 1.25;
}

.btn-primary {
    background: var(--accent);
    border-color: var(--accent);
    color: #fff;
}

.btn-primary:hover {
    background: var(--accent-hover);
    border-color: var(--accent-hover);
    color: #fff;
}

.btn-primary:focus-visible {
    outline: 2px solid var(--accent);
    outline-offset: 2px;
}

.btn-primary:active {
    transform: translateY(1px);
}

.btn-secondary {
    background: var(--card-bg);
    border-color: var(--border);
    color: var(--text);
}

.btn-secondary:hover {
    background: var(--gray-100);
    color: var(--text);
}

.btn-secondary:focus-visible {
    outline: 2px solid var(--accent);
    outline-offset: 2px;
}

.btn-secondary:active {
    transform: translateY(1px);
}

.btn-danger {
    background: var(--card-bg);
    border-color: var(--border);
    color: var(--red);
}

.btn-danger:hover {
    background: var(--red-50);
    border-color: var(--red-200);
    color: var(--red);
}

.btn-danger:focus-visible {
    outline: 2px solid var(--red);
    outline-offset: 2px;
}

.btn-danger:active {
    transform: translateY(1px);
}

.btn-sm {
    padding: 0.375rem 0.75rem;
    font-size: 0.8125rem;
}

.btn-group {
    display: inline-flex;
    gap: 0.5rem;
}

/* ======================== FORMS ======================== */
.form-group {
    margin-bottom: 1.25rem;
}

.form-label {
    display: block;
    font-weight: 500;
    font-size: 0.875rem;
    color: var(--text);
    margin-bottom: 0.375rem;
}

.form-hint {
    font-weight: 400;
    color: var(--text-secondary);
    font-size: 0.8125rem;
}

.form-control,
.form-select {
    width: 100%;
    padding: 0.5rem 0.75rem;
    border: 1px solid var(--border);
    border-radius: 6px;
    font-size: 0.875rem;
    color: var(--text);
    background: var(--card-bg);
    transition: border-color 0.15s ease, box-shadow 0.15s ease;
    font-family: inherit;
}

.form-control:focus,
.form-select:focus {
    outline: none;
    border-color: var(--accent);
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}

.form-control::placeholder { color: var(--gray-400); }

.form-card {
    max-width: 640px;
}

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

.form-actions {
    margin-top: var(--space-6);
}

.btn:disabled,
.btn[disabled] {
    opacity: 0.5;
    cursor: not-allowed;
    transform: none;
}

/* ======================== PAGE HEADERS ======================== */
.page-actions {
    display: flex;
    gap: 0.5rem;
    align-items: center;
}

/* ======================== DETAIL VIEW ======================== */
.detail-grid {
    display: grid;
    gap: 0;
}

.detail-row {
    display: grid;
    grid-template-columns: 160px 1fr;
    border-bottom: 1px solid var(--gray-100);
    padding: 0.75rem 0;
}

.detail-row:last-child { border-bottom: none; }

.detail-label {
    font-size: 0.8125rem;
    color: var(--text-secondary);
    font-weight: 500;
}

.detail-value {
    font-size: 0.875rem;
    color: var(--text);
}

.detail-value code {
    background: var(--gray-100);
    padding: 0.15em 0.4em;
    border-radius: 4px;
    font-size: 0.8125rem;
    color: var(--text);
}

/* ======================== EMPTY STATE ======================== */
.empty-state {
    text-align: center;
    padding: 3rem 1rem;
}

.empty-state h3 {
    font-size: 1rem;
    font-weight: 600;
    margin: 0 0 0.375rem;
}

.empty-state p {
    color: var(--text-secondary);
    font-size: 0.875rem;
    margin: 0 0 1.25rem;
}

/* ======================== AUTH PAGES ======================== */
.auth-layout {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--content-bg);
}

.auth-container {
    width: 100%;
    max-width: 400px;
    padding: 0 1rem;
}

.auth-brand {
    text-align: center;
    margin-bottom: 2rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
}

.auth-logo {
    width: 48px;
    height: 48px;
}

.auth-brand span {
    font-size: 1.25rem;
    font-weight: 600;
    color: var(--text);
}

.auth-card {
    background: var(--card-bg);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    padding: 2rem;
}

.auth-card h2 {
    font-size: 1.25rem;
    font-weight: 600;
    text-align: center;
    margin: 0 0 0.25rem;
}

.auth-card .auth-subtitle {
    text-align: center;
    color: var(--text-secondary);
    font-size: 0.875rem;
    margin: 0 0 1.5rem;
}

.auth-footer {
    text-align: center;
    margin-top: 1.5rem;
    font-size: 0.8125rem;
    color: var(--text-secondary);
}

.auth-footer a { font-weight: 500; }

/* ======================== ALERTS ======================== */
.alert-error {
    background: var(--red-50);
    border: 1px solid var(--red-200);
    color: var(--red-700);
    padding: 0.75rem 1rem;
    border-radius: var(--radius-md);
    font-size: var(--text-base);
    margin-bottom: var(--space-4);
}

/* ======================== BREADCRUMB ======================== */
.breadcrumb {
    display: flex;
    align-items: center;
    gap: 0.375rem;
    font-size: 0.8125rem;
    color: var(--text-secondary);
    margin: 0;
    padding: 0;
    list-style: none;
}

.breadcrumb a { color: var(--text-secondary); }
.breadcrumb a:hover { color: var(--text); }
.breadcrumb .separator { color: var(--gray-400); }

/* ======================== SPINNER ======================== */
.spinner {
    display: flex;
    justify-content: center;
    padding: 3rem 0;
}

.spinner::after {
    content: "";
    width: 24px;
    height: 24px;
    border: 2px solid var(--border);
    border-top-color: var(--accent);
    border-radius: 50%;
    animation: spin 0.6s linear infinite;
}

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

/* ======================== MISC ======================== */
.form-switch {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.text-muted { color: var(--text-secondary); }

code {
    background: var(--gray-100);
    padding: 0.15em 0.4em;
    border-radius: 4px;
    font-size: 0.8125rem;
}

/* ======================== MODAL ======================== */
.modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.4);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 200;
}

.modal-dialog {
    background: var(--card-bg);
    border-radius: var(--radius);
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.15);
    width: 100%;
    max-width: 400px;
}

.modal-header {
    padding: 1rem 1.25rem;
    font-weight: 600;
    font-size: 0.9375rem;
    border-bottom: 1px solid var(--border);
}

.modal-body { padding: 1.25rem; }

.modal-footer {
    padding: 0.75rem 1.25rem;
    border-top: 1px solid var(--border);
    display: flex;
    gap: 0.5rem;
    justify-content: flex-end;
}

/* ======================== MOBILE HEADER ======================== */
.mobile-header {
    display: none;
    align-items: center;
    gap: 0.75rem;
    padding: 0.75rem 1rem;
    background: var(--card-bg);
    border-bottom: 1px solid var(--border);
    position: sticky;
    top: 0;
    z-index: 50;
}

.mobile-logo {
    width: 24px;
    height: 24px;
}

.mobile-brand {
    font-weight: 600;
    font-size: 1rem;
}

.hamburger-btn {
    background: none;
    border: none;
    cursor: pointer;
    padding: 0.25rem;
    color: var(--text);
    display: flex;
    align-items: center;
}

/* ======================== SIDEBAR TOGGLE (CSS-only, no JS needed) ======================== */
.sidebar-checkbox {
    display: none;
}

/* Desktop: sidebar open by default, checkbox toggles closed */
.sidebar {
    transition: transform 0.25s ease;
}

.main-content {
    transition: margin-left 0.25s ease;
}

/* Desktop: unchecked = open (default), checked = closed */
@media (min-width: 769px) {
    .sidebar-checkbox:checked ~ .app-layout .sidebar {
        transform: translateX(-100%);
    }

    .sidebar-checkbox:not(:checked) ~ .app-layout .main-content {
        margin-left: 260px;
    }

    .sidebar-checkbox:checked ~ .app-layout .main-content {
        margin-left: 0;
    }

    .sidebar-checkbox:not(:checked) ~ .app-layout .desktop-expand-tab {
        display: none;
    }

    .sidebar-checkbox:checked ~ .app-layout .desktop-expand-tab {
        display: flex;
    }
}

/* Mobile: unchecked = closed (default), checked = open */
@media (max-width: 768px) {
    .sidebar {
        transform: translateX(-100%);
    }

    .sidebar-checkbox:checked ~ .app-layout .sidebar {
        transform: translateX(0);
    }
}

/* Expand tab: visible when sidebar is closed on desktop */
.desktop-expand-tab {
    position: fixed;
    top: 50%;
    left: 0;
    transform: translateY(-50%);
    z-index: 101;
    background: var(--sidebar-bg);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-left: none;
    border-radius: 0 6px 6px 0;
    width: 20px;
    height: 48px;
    display: none;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    color: var(--sidebar-text);
    transition: background 0.15s ease;
}

.desktop-expand-tab:hover {
    background: rgba(255, 255, 255, 0.12);
    color: var(--sidebar-text-hover);
}

.desktop-expand-tab svg {
    width: 14px;
    height: 14px;
}

.sidebar-overlay {
    display: none;
}

/* ======================== CONTENT HEADER SPLIT ======================== */
.content-header-split {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
}

.search-bar {
    margin-bottom: 1rem;
    max-width: 400px;
}

/* ======================== MOBILE CARDS (hidden on desktop) ======================== */
.mobile-cards {
    display: none;
}

/* ======================== RESPONSIVE ======================== */
@media (max-width: 768px) {
    /* On mobile: no margin shift, sidebar overlays content */
    .sidebar-checkbox:checked ~ .app-layout .main-content {
        margin-left: 0;
    }

    .sidebar-overlay {
        display: block;
        position: fixed;
        inset: 0;
        background: rgba(0, 0, 0, 0.4);
        z-index: 99;
        opacity: 0;
        pointer-events: none;
        transition: opacity 0.25s ease;
        cursor: default;
    }

    .sidebar-checkbox:checked ~ .app-layout .sidebar-overlay {
        opacity: 1;
        pointer-events: auto;
    }

    .main-content {
        margin-left: 0;
    }

    .mobile-header {
        display: flex;
    }

    /* Hide desktop expand tab on mobile */
    .desktop-expand-tab {
        display: none !important;
    }

    .content-header {
        padding: 1rem;
        position: static;
    }

    .content-header-split {
        flex-direction: column;
        gap: 0.75rem;
    }

    .content-body {
        padding: 1rem;
    }

    /* Hide desktop tables, show mobile cards */
    .desktop-table {
        display: none;
    }

    .mobile-cards {
        display: flex;
        flex-direction: column;
        gap: 0.75rem;
    }

    .mobile-card {
        background: var(--card-bg);
        border: 1px solid var(--border);
        border-radius: var(--radius);
        box-shadow: var(--shadow-sm);
        padding: 1rem;
    }

    .mobile-card-header {
        display: flex;
        justify-content: space-between;
        align-items: flex-start;
        margin-bottom: 0.5rem;
    }

    .mobile-card-title {
        font-weight: 500;
        font-size: 0.9375rem;
        color: var(--text);
    }

    .mobile-card-title a {
        color: var(--text);
    }

    .mobile-card-meta {
        display: flex;
        flex-wrap: wrap;
        gap: 0.5rem 1rem;
        font-size: 0.8125rem;
        color: var(--text-secondary);
        margin-bottom: 0.75rem;
    }

    .mobile-card-meta-item {
        display: flex;
        align-items: center;
        gap: 0.25rem;
    }

    .mobile-card-actions {
        display: flex;
        gap: 0.5rem;
        flex-wrap: wrap;
        padding-top: 0.75rem;
        border-top: 1px solid var(--border);
    }

    /* Tables that remain on mobile: ensure minimum readable width */
    .data-table {
        min-width: 500px;
    }

    /* Detail grid: stack on mobile */
    .detail-row {
        grid-template-columns: 1fr;
        gap: 0.25rem;
    }

    /* Stat grid: full width on small screens */
    .stat-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    /* Button groups: wrap */
    .btn-group {
        flex-wrap: wrap;
    }

    /* Page actions */
    .page-actions {
        flex-wrap: wrap;
    }

    /* Modal: nearly full width */
    .modal-dialog {
        max-width: calc(100% - 2rem);
        margin: 1rem;
    }

    /* Cards: no max-width constraint on mobile */
    .card[style*="max-width"] {
        max-width: 100% !important;
    }

    /* Breadcrumbs: allow wrapping */
    .breadcrumb {
        flex-wrap: wrap;
    }

    /* Code: prevent horizontal overflow */
    code {
        word-break: break-all;
    }

    /* Full-width buttons on mobile */
    .btn-group .btn {
        flex: 1;
        justify-content: center;
        text-align: center;
    }
}

@media (max-width: 400px) {
    .stat-grid {
        grid-template-columns: 1fr;
    }

    .content-body {
        padding: 0.75rem;
    }

    .content-header {
        padding: 0.75rem;
    }
}

/* Setting info icon + tooltip */
.setting-info {
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 1rem;
    height: 1rem;
    margin-left: 0.375rem;
    font-size: 0.6875rem;
    font-weight: 600;
    line-height: 1;
    color: var(--accent);
    border: 1.5px solid var(--accent);
    border-radius: 50%;
    cursor: help;
    vertical-align: middle;
    flex-shrink: 0;
    user-select: none;
}

.setting-info .setting-tooltip {
    display: none;
    position: absolute;
    bottom: calc(100% + 6px);
    left: 50%;
    transform: translateX(-50%);
    background: var(--text);
    color: #fff;
    font-size: 0.75rem;
    font-weight: 400;
    line-height: 1.4;
    padding: 0.5rem 0.625rem;
    border-radius: 6px;
    white-space: normal;
    width: max-content;
    max-width: 280px;
    z-index: 100;
    pointer-events: none;
    text-align: left;
}

.setting-info .setting-tooltip::after {
    content: '';
    position: absolute;
    top: 100%;
    left: 50%;
    transform: translateX(-50%);
    border: 5px solid transparent;
    border-top-color: var(--text);
}

.setting-info:hover .setting-tooltip {
    display: block;
}
