@font-face {
    font-family: "Bender";
    src: url("../fonts/bender.woff2") format("woff2");
    font-weight: 400;
    font-display: swap;
}

@font-face {
    font-family: "Bender";
    src: url("../fonts/bender-bold.woff2") format("woff2");
    font-weight: 700;
    font-display: swap;
}

html { scrollbar-gutter: stable; }

body { font-family: "Bender", sans-serif; }

*:focus, *:focus-visible { outline: none !important; box-shadow: none !important; }

:root {
    --nav-height: 60px;
    --glass-bg: rgba(18, 18, 18, 0.85);
    --glass-border: rgba(210, 175, 120, 0.15);
    --accent-gold: #d2af78;
    --accent-gold-hover: #e6c58c;
    --text-main: #f0f0f0;
    --text-muted: #a0a0a0;
    --bg-dark: #0a0a0a;
    --panel-shadow: 0 20px 50px rgba(0, 0, 0, 0.35);
}

.app-body {
    background: var(--bg-dark);
    color: var(--text-main);
    min-height: 100vh;
}

.app-shell {
    position: relative;
    min-height: 100vh;
    overflow: hidden;
}

.app-shell::before {
    content: "";
    position: fixed;
    inset: 0;
    background:
        radial-gradient(65% 55% at 10% 10%, rgba(210, 175, 120, 0.08), transparent 60%),
        radial-gradient(45% 40% at 85% 20%, rgba(210, 175, 120, 0.06), transparent 62%),
        linear-gradient(180deg, rgba(12, 12, 12, 0.95), rgba(5, 5, 5, 0.98));
    pointer-events: none;
    z-index: 0;
}

.app-shell::after {
    content: "";
    position: fixed;
    inset: 0;
    background-image:
        linear-gradient(rgba(210, 175, 120, 0.05) 1px, transparent 1px),
        linear-gradient(90deg, rgba(210, 175, 120, 0.04) 1px, transparent 1px);
    background-size: 120px 120px;
    opacity: 0.18;
    pointer-events: none;
    z-index: 0;
}

.app-topbar {
    position: relative;
    z-index: 10;
    min-height: var(--nav-height);
    background: rgba(10, 10, 10, 0.92);
    border-bottom: 1px solid rgba(210, 175, 120, 0.12);
    backdrop-filter: blur(10px);
}

.glass-panel {
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    box-shadow: var(--panel-shadow);
}

.btn-gold {
    background: var(--accent-gold);
    color: #1b1308;
    border: 1px solid rgba(210, 175, 120, 0.6);
    font-weight: 700;
    transition: background 0.2s ease, box-shadow 0.2s ease;
    cursor: pointer;
}
.btn-gold:hover:not(:disabled) { background: var(--accent-gold-hover); }
.btn-gold:disabled { opacity: 0.5; cursor: not-allowed; }

.btn-ghost {
    background: rgba(12, 12, 12, 0.6);
    border: 1px solid rgba(210, 175, 120, 0.2);
    color: var(--text-main);
    transition: border 0.2s ease, color 0.2s ease, background 0.2s ease;
    cursor: pointer;
}
.btn-ghost:hover { border-color: rgba(210, 175, 120, 0.5); color: var(--accent-gold); }

.input-dark {
    background: rgba(8, 8, 8, 0.7);
    border: 1px solid rgba(210, 175, 120, 0.2);
    color: var(--text-main);
}
.input-dark::placeholder { color: rgba(240, 240, 240, 0.35); }
.input-dark:focus { border-color: rgba(210, 175, 120, 0.4); }

.chip {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    border-radius: 999px;
    border: 1px solid rgba(210, 175, 120, 0.25);
    padding: 0.2rem 0.6rem;
    font-size: 0.65rem;
    font-weight: 600;
    color: var(--accent-gold);
}
.chip-muted { border-color: rgba(210, 175, 120, 0.14); color: var(--text-muted); }

.dropdown-menu {
    position: absolute;
    top: calc(100% + 4px);
    left: 0; right: 0;
    z-index: 30;
    background: rgba(14, 14, 14, 0.97);
    border: 1px solid rgba(210, 175, 120, 0.2);
    border-radius: 12px;
    padding: 4px;
    box-shadow: 0 16px 40px rgba(0, 0, 0, 0.5);
    opacity: 0;
    transform: translateY(-4px);
    transition: opacity 150ms ease, transform 150ms ease;
    pointer-events: none;
    max-height: 200px;
    overflow-y: auto;
    scrollbar-width: thin;
    scrollbar-color: rgba(210, 175, 120, 0.4) rgba(10, 10, 10, 0.5);
}
.dropdown-menu::-webkit-scrollbar { width: 6px; }
.dropdown-menu::-webkit-scrollbar-track { background: rgba(10, 10, 10, 0.5); border-radius: 999px; }
.dropdown-menu::-webkit-scrollbar-thumb { background: rgba(210, 175, 120, 0.4); border-radius: 999px; }
.dropdown-menu.open { opacity: 1; transform: translateY(0); pointer-events: auto; }

.dropdown-option {
    display: flex;
    align-items: center;
    gap: 8px;
    width: 100%;
    padding: 8px 12px;
    border-radius: 8px;
    font-size: 0.875rem;
    color: var(--text-main);
    background: transparent;
    border: none;
    cursor: pointer;
    text-align: left;
    transition: background 150ms ease;
}
.dropdown-option:hover { background: rgba(255, 255, 255, 0.05); }
.dropdown-option.selected { background: rgba(210, 175, 120, 0.1); color: var(--accent-gold); }
