* { box-sizing: border-box; }

/* Kill every browser's native button chrome (white background, grey
   border, system font) up front so our own classes are the only thing
   that ever paints a <button> — this is what was letting plain white
   buttons slip through wherever a class rule wasn't specific enough. */
button {
    appearance: none;
    -webkit-appearance: none;
    background: none;
    border: none;
    color: inherit;
    font: inherit;
    cursor: pointer;
}

/* Same fix as above but for <select> — without `color-scheme: dark` the
   dropdown's OWN popup list of options renders with the OS/browser's
   light theme no matter what background/color is set on the select
   itself, which is what made every dropdown in the panel look like a
   stray white browser control.

   Every <select> in the app shares this one look — pill-rounded, a
   custom chevron instead of the browser's square native arrow, and a
   soft highlight on hover/focus — so no dropdown anywhere looks like a
   plain boxy browser control next to the rest of the UI. */
select {
    color-scheme: dark;
    appearance: none;
    -webkit-appearance: none;
    background:
        linear-gradient(45deg, transparent 50%, var(--text-dim, #a8a3bd) 50%),
        linear-gradient(135deg, var(--text-dim, #a8a3bd) 50%, transparent 50%),
        var(--card, #14101f);
    background-position: right 15px top 55%, right 10px top 55%, 0 0;
    background-size: 5px 5px, 5px 5px, 100%;
    background-repeat: no-repeat;
    border: 1px solid var(--panel-border, #2a2540);
    color: var(--text, #f2f0f7);
    border-radius: 10px;
    padding: 6px 28px 6px 12px;
    font: inherit;
    cursor: pointer;
    transition: border-color 0.15s ease, background-color 0.15s ease;
}
select:hover { border-color: var(--purple-light, #a78bfa); }
select:focus { outline: none; border-color: var(--purple-light, #a78bfa); }
select option {
    background: #1a1626;
    color: #f2f0f7;
}
/* Chrome's opt-in "Customizable Select" API: where supported, this lets the
   popup list itself (not just the closed box) inherit real border-radius
   instead of the browser's square native popup — a no-op everywhere else. */
@supports (appearance: base-select) {
    select, select::picker(select) {
        appearance: base-select;
    }
    select::picker(select) {
        background: #1a1626;
        border: 1px solid var(--panel-border, #2a2540);
        border-radius: 12px;
        overflow: hidden;
        padding: 4px;
    }
    select option {
        border-radius: 8px;
        padding: 8px 10px;
    }
    select option:hover, select option:focus {
        background: rgba(139, 92, 246, 0.18);
    }
}

:root {
    --bg: #08080f;
    --bg-glow:
        radial-gradient(ellipse 900px 560px at 12% -8%, rgba(139,92,246,0.35), transparent 60%),
        radial-gradient(ellipse 700px 500px at 92% 8%, rgba(124,58,237,0.28), transparent 55%),
        radial-gradient(ellipse 800px 600px at 50% 110%, rgba(76,29,149,0.30), transparent 60%),
        radial-gradient(ellipse 500px 400px at 85% 85%, rgba(167,139,250,0.16), transparent 55%);
    --bg-grid:
        linear-gradient(rgba(139,92,246,0.055) 1px, transparent 1px),
        linear-gradient(90deg, rgba(139,92,246,0.055) 1px, transparent 1px);
    --panel: #0f0f1a;
    --panel-border: #221f33;
    --card: #131320;
    --card-2: #15121f;
    --purple: #8B5CF6;
    --purple-light: #a78bfa;
    --text: #f2f0f7;
    --text-dim: #9a95ad;
    --success: #22C55E;
    --warning: #F59E0B;
    --error: #EF4444;
}

body {
    margin: 0;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background-color: var(--bg);
    background-image: var(--bg-grid), var(--bg-glow);
    background-size: 42px 42px, 42px 42px, auto, auto, auto, auto;
    background-position: center, center, 0 0, 0 0, 0 0, 0 0;
    background-attachment: fixed;
    color: var(--text);
    position: relative;
    min-height: 100vh;
    animation: bg-drift 22s ease-in-out infinite alternate;
}

/* Slow, subtle breathing glow — brings the background to life without ever
   competing with the actual UI (grid + glow only, never the panels/cards). */
@keyframes bg-drift {
    0%   { background-position: center, center, 0% 0%, 100% 0%, 50% 100%, 100% 100%; }
    100% { background-position: center, center, 4% 4%, 96% 4%, 50% 94%, 92% 92%; }
}

@media (prefers-reduced-motion: reduce) {
    body { animation: none; }
}

a { color: var(--purple-light); text-decoration: none; }

/* ---------- Header ---------- */
header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 40px;
    border-bottom: 1px solid var(--panel-border);
    background: rgba(15,15,26,0.6);
}
.brand-group { display: flex; align-items: center; gap: 12px; }
.external-nav { display: flex; align-items: center; gap: 8px; }
.external-link-btn {
    display: inline-flex; align-items: center; gap: 6px;
    padding: 7px 12px; border-radius: 8px; font-size: 13px; font-weight: 500;
    background: var(--card); border: 1px solid var(--panel-border); color: var(--text-dim);
    text-decoration: none; transition: border-color .15s, color .15s, background .15s;
}
.external-link-btn:hover { border-color: var(--purple); color: var(--text); background: rgba(139,92,246,0.1); }
.brand-group h1 {
    font-size: 17px;
    margin: 0;
    display: flex;
    align-items: center;
    gap: 10px;
    font-weight: 700;
}
.logo-img { width: 34px; height: 34px; border-radius: 50%; object-fit: cover; box-shadow: 0 0 14px rgba(139,92,246,0.5); }
.logo-badge {
    width: 30px; height: 30px; border-radius: 50%;
    background: radial-gradient(circle at 35% 30%, #c4b5fd, #8B5CF6 60%, #4c1d95);
    box-shadow: 0 0 14px rgba(139,92,246,0.55);
    display: inline-flex; align-items: center; justify-content: center;
    font-size: 12px; font-weight: 800; color: #fff; flex-shrink: 0;
}
.pill-tag {
    font-size: 10px; font-weight: 700; letter-spacing: 0.06em;
    color: var(--purple-light); background: rgba(139,92,246,0.14);
    border: 1px solid rgba(139,92,246,0.35); padding: 3px 9px; border-radius: 999px;
}
.header-right { display: flex; align-items: center; gap: 14px; }
.guild-chip {
    font-size: 13px; color: var(--text); background: var(--card);
    border: 1px solid var(--panel-border); padding: 7px 14px; border-radius: 999px;
}
.guild-chip:hover { border-color: var(--purple); }
.status-chip {
    font-size: 12px; color: var(--text-dim); display: flex; align-items: center; gap: 6px;
}
.dot-live { width: 7px; height: 7px; border-radius: 50%; background: var(--success); box-shadow: 0 0 6px var(--success); display: inline-block; }
.user-chip { display: flex; gap: 12px; align-items: center; }
.user-chip a { color: var(--text-dim); font-size: 13px; }
.user-chip a:hover { color: var(--text); }
.avatar-circle {
    width: 30px; height: 30px; border-radius: 50%;
    background: linear-gradient(160deg, #7c4dff, #4c1d95);
    display: inline-flex; align-items: center; justify-content: center;
    font-size: 13px; font-weight: 700; color: #fff;
    object-fit: cover;
}

main { padding: 32px 36px; max-width: 1500px; margin: 0 auto; }
/* The modules grid (guild overview page) wants more room than a normal
   config page so 6 cards can actually sit side by side instead of the
   page's usual 1180px reading-width cap squeezing them down to 3-4. Both
   the overview and a single module's config page share the .modules-page
   class, so target only the one that actually contains the grid. */
main.modules-page { max-width: 1760px; padding: 28px 32px; }

.eyebrow {
    display: inline-block;
    font-size: 11px;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--purple-light);
    background: rgba(139,92,246,0.12);
    border: 1px solid rgba(139,92,246,0.35);
    padding: 4px 12px;
    border-radius: 999px;
    margin-bottom: 14px;
}

/* ---------- Login / center card ---------- */
.center-box {
    max-width: 440px;
    margin: 14vh auto;
    text-align: center;
    padding: 40px 36px;
    background: var(--panel);
    border-radius: 16px;
    border: 1px solid var(--panel-border);
}
.center-box h1 { font-size: 28px; margin-bottom: 8px; }
.center-box p { color: var(--text-dim); }

/* ---------- Buttons ---------- */
.btn {
    display: inline-block;
    background: var(--purple);
    color: #fff;
    text-decoration: none;
    padding: 12px 24px;
    border-radius: 10px;
    font-weight: 600;
    border: none;
    cursor: pointer;
    font-size: 14px;
    box-shadow: 0 4px 20px rgba(139,92,246,0.35);
    transition: transform 0.1s ease, box-shadow 0.15s ease, opacity 0.15s ease;
}
.btn:hover { box-shadow: 0 6px 24px rgba(139,92,246,0.5); transform: translateY(-1px); }
.btn:disabled { opacity: 0.4; cursor: not-allowed; box-shadow: none; transform: none; }
.btn.small { padding: 8px 16px; font-size: 13px; box-shadow: none; }
.btn.secondary {
    background: transparent;
    border: 1px solid #3a3550;
    color: var(--text);
    box-shadow: none;
}
.btn.secondary:hover { border-color: var(--purple); box-shadow: none; }

/* ---------- Dashboard server grid ---------- */
main > h2 { font-size: 22px; margin-bottom: 4px; }
.server-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 18px;
    margin-top: 20px;
}
.server-card {
    background: var(--card);
    border: 1px solid var(--panel-border);
    border-radius: 14px;
    padding: 22px 16px;
    text-align: center;
    transition: border-color 0.15s ease;
}
.server-card:hover { border-color: rgba(139,92,246,0.5); }
.server-card img, .server-icon-fallback {
    width: 64px; height: 64px; border-radius: 50%;
    margin: 0 auto 12px;
    display: flex; align-items: center; justify-content: center;
    background: linear-gradient(160deg, #2a2440, #17131f);
    border: 1px solid var(--panel-border);
    font-size: 24px; font-weight: 700; color: var(--purple-light);
}
.server-name { font-weight: 600; margin-bottom: 4px; }

.banner.success {
    background: rgba(34,197,94,0.1);
    border: 1px solid rgba(34,197,94,0.4);
    color: #6ee7a5;
    padding: 12px 18px;
    border-radius: 10px;
    margin-bottom: 22px;
}
.banner.warning {
    background: rgba(234,179,8,0.1);
    border: 1px solid rgba(234,179,8,0.4);
    color: #fbd979;
    padding: 12px 18px;
    border-radius: 10px;
    margin-bottom: 22px;
}

/* ---------- Modules page ---------- */
.modules-page .crumb {
    display: inline-block;
    color: var(--text-dim);
    font-size: 13px;
    margin-bottom: 22px;
}
.modules-page .crumb:hover { color: var(--text); }

.hero-row {
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    gap: 24px;
    flex-wrap: wrap;
    margin-bottom: 30px;
}
.hero-title { font-size: 34px; font-weight: 800; margin: 4px 0 0; line-height: 1.15; }
.hero-title .accent { color: var(--purple-light); }
.stat-row { display: flex; gap: 12px; }
.stat-card {
    background: var(--card);
    border: 1px solid var(--panel-border);
    border-radius: 12px;
    padding: 14px 20px;
    min-width: 110px;
    text-align: center;
}
.stat-num { font-size: 20px; font-weight: 800; }
.stat-label { font-size: 11px; color: var(--text-dim); text-transform: uppercase; letter-spacing: 0.04em; margin-top: 4px; }
/* ---------- Plan chip (header) ---------- */
.plan-chip-form { display: contents; }
.plan-chip {
    display: flex; align-items: center; gap: 8px;
    font-size: 13px; background: var(--card);
    border: 1px solid var(--panel-border); padding: 6px 12px 6px 12px; border-radius: 999px;
}
.plan-chip.plan-free .dot-live { background: var(--text-dim); box-shadow: none; }
.plan-chip.plan-premium .dot-live { background: var(--purple-light); box-shadow: 0 0 6px var(--purple-light); }
.plan-chip.plan-ultra .dot-live { background: #fbbf24; box-shadow: 0 0 6px #fbbf24; }
.plan-chip-select {
    /* `color-scheme: dark` is what actually fixes the native dropdown
       (the popup list of options) on Chromium/Firefox — without it the
       select box itself can be styled dark, but the options popup still
       renders with the OS's light theme regardless of any other CSS here. */
    color-scheme: dark;
    appearance: none;
    -webkit-appearance: none;
    background: transparent;
    border: none;
    color: var(--text);
    font-size: 13px;
    font-weight: 600;
    font-family: inherit;
    cursor: pointer;
    padding-right: 4px;
}
.plan-chip-select:focus { outline: none; }
.plan-chip-readonly { font-size: 13px; font-weight: 600; color: var(--text); }
.plan-chip-select option {
    background: #1a1626;
    color: var(--text);
}

.module-grid {
    display: grid;
    grid-template-columns: repeat(6, 1fr);
    gap: 16px;
}
@media (max-width: 1600px) { .module-grid { grid-template-columns: repeat(5, 1fr); } }
@media (max-width: 1400px) { .module-grid { grid-template-columns: repeat(4, 1fr); } }
@media (max-width: 1100px) { .module-grid { grid-template-columns: repeat(3, 1fr); } }
@media (max-width: 800px) { .module-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 520px) { .module-grid { grid-template-columns: 1fr; } }
.module-card {
    display: block;
    background: var(--card);
    border: 1px solid var(--panel-border);
    border-radius: 14px;
    padding: 20px;
    transition: border-color 0.15s ease, transform 0.1s ease;
    color: var(--text);
}
.module-card:hover { border-color: rgba(139,92,246,0.55); transform: translateY(-2px); }
.module-card.locked { opacity: 0.85; }
.module-top { display: flex; justify-content: space-between; align-items: center; margin-bottom: 12px; }
.module-icon {
    width: 38px; height: 38px; border-radius: 10px;
    background: rgba(139,92,246,0.14); border: 1px solid rgba(139,92,246,0.3);
    display: flex; align-items: center; justify-content: center; font-size: 18px;
}
.module-icon.big { width: 52px; height: 52px; font-size: 24px; border-radius: 14px; }
.toggle-pill {
    font-size: 10px; font-weight: 700; letter-spacing: 0.05em;
    padding: 3px 10px; border-radius: 999px; border: 1px solid transparent;
}
.toggle-pill.on { background: rgba(34,197,94,0.12); color: #6ee7a5; border-color: rgba(34,197,94,0.4); }
.toggle-pill.off { background: transparent; color: var(--text-dim); border-color: #3a3550; }
.module-name { font-weight: 700; font-size: 15px; margin-bottom: 6px; }
.module-desc { font-size: 13px; color: var(--text-dim); line-height: 1.4; min-height: 36px; }
.module-footer {
    display: flex; justify-content: space-between; align-items: center;
    margin-top: 16px; padding-top: 14px; border-top: 1px solid var(--panel-border);
    font-size: 12px; color: var(--text-dim);
}
.module-link { color: var(--purple-light); font-weight: 600; }

/* ---------- Module configure page ---------- */
.crumb-row { display: flex; gap: 10px; margin-bottom: 22px; }
.crumb-pill {
    font-size: 12px; padding: 7px 14px; border-radius: 999px;
    background: var(--card); border: 1px solid var(--panel-border); color: var(--text-dim);
}
.crumb-pill:hover { color: var(--text); }
.crumb-pill.ghost { color: var(--text-dim); }
.crumb-pill b { color: var(--text); font-weight: 700; }

.module-header-card {
    background: var(--card);
    border: 1px solid var(--panel-border);
    border-radius: 16px;
    padding: 22px 26px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 22px;
    flex-wrap: wrap;
    gap: 14px;
}
.module-header-left { display: flex; align-items: center; gap: 16px; }
.module-header-left h2 { margin: 0 0 4px; font-size: 20px; }
.module-header-left p { margin: 0; color: var(--text-dim); font-size: 13px; }
.status-badge {
    font-size: 12px; font-weight: 700; padding: 6px 16px; border-radius: 999px;
    border: 1px solid transparent;
}
.status-badge.on { background: rgba(34,197,94,0.12); color: #6ee7a5; border-color: rgba(34,197,94,0.4); }
.status-badge.off { background: transparent; color: var(--text-dim); border-color: #3a3550; }
.status-badge.locked { background: rgba(245,158,11,0.12); color: #fbbf24; border-color: rgba(245,158,11,0.4); }

.premium-lock {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 13px;
    color: var(--warning);
    background: rgba(245,158,11,0.1);
    border: 1px solid rgba(245,158,11,0.35);
    padding: 10px 16px;
    border-radius: 10px;
    margin-bottom: 22px;
}
.premium-lock.full-note { display: block; }

.config-columns {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(440px, 1fr));
    grid-auto-flow: dense;
    gap: 18px;
    align-items: start;
    margin-bottom: 24px;
}
/* Cards with lots of fields use the full width and lay their fields out in as many columns as fit,
   so a long module (Casino, messages & buttons …) is a short wide block instead of a tall narrow strip. */
.config-columns .group-card.group-wide { grid-column: 1 / -1; }
.group-wide > .group-fields { grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 0 20px; }
@media (max-width: 520px) {
    .config-columns { grid-template-columns: 1fr; }
}

.group-card {
    background: var(--card);
    border: 1px solid var(--panel-border);
    border-radius: 14px;
    padding: 22px 24px;
}
.group-head { margin-bottom: 18px; }
.group-head h3 { margin: 0; font-size: 15px; }
.group-sub { font-size: 11px; color: var(--text-dim); text-transform: uppercase; letter-spacing: 0.06em; }

/* Two fields side by side inside a group card by default (toggles, short
   text/number inputs, pickers) — a field is only forced full-width when it
   genuinely needs the room (a textarea, or a multi-role chip picker that
   can grow to several chips). Keeps modules with just a couple of fields
   (e.g. Invites, Suggestions) from looking like one long empty column. */
.group-fields {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 0 16px;
}
@media (max-width: 480px) {
    .group-fields { grid-template-columns: 1fr; }
}
.field-full { grid-column: 1 / -1; }

.field { margin-bottom: 16px; }
.field:last-child { margin-bottom: 0; }
.field label {
    display: flex; align-items: center; gap: 8px;
    font-size: 13px; color: var(--text-dim); margin-bottom: 6px;
}
.field input[type=text], .field input[type=number], .field textarea, .field select {
    display: block;
    width: 100%;
    padding: 10px 12px;
    background: var(--bg);
    border: 1px solid #2a2540;
    border-radius: 8px;
    color: var(--text);
    font-size: 14px;
    font-family: inherit;
}
.field select {
    cursor: pointer;
    color-scheme: dark;
    appearance: none;
    -webkit-appearance: none;
    padding-right: 30px;
    background:
        linear-gradient(45deg, transparent 50%, var(--text-dim) 50%),
        linear-gradient(135deg, var(--text-dim) 50%, transparent 50%),
        var(--bg);
    background-position: right 15px top 55%, right 10px top 55%, 0 0;
    background-size: 5px 5px, 5px 5px, 100%;
    background-repeat: no-repeat;
}
.field select[multiple] { padding: 6px; }
.field select[multiple] option { padding: 6px 8px; border-radius: 4px; }
.field select option { background: #171225; color: var(--text); }
.chip-picker { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; }
.chip-list { display: flex; flex-wrap: wrap; gap: 6px; }
.chip {
    display: inline-flex; align-items: center; gap: 6px;
    background: rgba(139, 92, 246, 0.16);
    border: 1px solid rgba(139, 92, 246, 0.4);
    color: var(--text);
    font-size: 13px;
    padding: 5px 6px 5px 10px;
    border-radius: 999px;
}
.chip-none { font-size: 13px; color: var(--text-dim); }
.chip-x {
    background: rgba(139, 92, 246, 0.25); border: none; color: var(--purple-light);
    cursor: pointer; font-size: 14px; line-height: 1; width: 18px; height: 18px;
    display: inline-flex; align-items: center; justify-content: center;
    border-radius: 50%;
}
.chip-x:hover { color: #fff; background: var(--purple); }
.chip-add {
    width: auto; min-width: 160px; margin-top: 2px;
    padding: 8px 30px 8px 10px; font-size: 13px;
}
.emoji-quickpick { display: flex; flex-wrap: wrap; gap: 4px; margin-top: 6px; }
.emoji-quickpick-btn {
    background: var(--card-2); border: 1px solid var(--panel-border);
    border-radius: 6px; padding: 4px 8px; font-size: 15px; line-height: 1;
}
.emoji-quickpick-btn:hover { border-color: var(--purple); background: rgba(139, 92, 246, 0.14); }
.emoji-quickpick-server {
    max-height: 140px; overflow-y: auto; padding: 6px;
    background: var(--card-2); border: 1px solid var(--panel-border); border-radius: 8px;
}
.emoji-quickpick-custom { padding: 3px; display: inline-flex; align-items: center; justify-content: center; }
.emoji-quickpick-custom img { width: 22px; height: 22px; display: block; }
.id-badge {
    font-family: 'SFMono-Regular', Consolas, 'Liberation Mono', Menlo, monospace;
    font-size: 11px; font-weight: 400; color: var(--purple-light);
    background: rgba(139, 92, 246, 0.14); border: 1px solid rgba(139, 92, 246, 0.3);
    padding: 2px 7px; border-radius: 6px; margin-left: 6px;
}
.field input:focus, .field textarea:focus, .field select:focus { outline: none; border-color: var(--purple); }
.field textarea { min-height: 80px; resize: vertical; white-space: pre-wrap; }
.field input:disabled, .field textarea:disabled, .field select:disabled { opacity: 0.4; cursor: not-allowed; }

.field-toggle { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.field-toggle label { margin-bottom: 0; }

.color-row { display: flex; gap: 8px; align-items: center; }
.color-row input[type=color] {
    width: 42px; height: 38px; padding: 2px; border-radius: 8px; border: 1px solid #2a2540;
    background: var(--bg); cursor: pointer;
}
.color-row input[type=text] { flex: 1; }

.badge-premium {
    font-size: 10px;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: #1a1424;
    background: linear-gradient(135deg, #fbbf24, #f59e0b);
    padding: 2px 8px;
    border-radius: 999px;
    font-weight: 700;
}

/* Toggle switch */
.switch { position: relative; display: inline-block; width: 42px; height: 24px; flex-shrink: 0; }
.switch input { opacity: 0; width: 0; height: 0; }
.switch .slider {
    position: absolute; cursor: pointer; inset: 0;
    background: #2a2540; border-radius: 999px; transition: 0.15s;
}
.switch .slider::before {
    content: ""; position: absolute; height: 18px; width: 18px; left: 3px; top: 3px;
    background: #fff; border-radius: 50%; transition: 0.15s;
}
.switch input:checked + .slider { background: var(--purple); }
.switch input:checked + .slider::before { transform: translateX(18px); }
.switch input:disabled + .slider { opacity: 0.4; cursor: not-allowed; }

.feature-note {
    font-size: 13px; color: var(--text-dim); background: var(--card-2);
    border: 1px solid var(--panel-border); padding: 12px 16px; border-radius: 10px;
    margin: 0 0 24px;
}

.save-bar {
    position: sticky;
    bottom: 0;
    background: rgba(15,15,26,0.92);
    backdrop-filter: blur(6px);
    border-top: 1px solid var(--panel-border);
    padding: 16px 24px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-radius: 14px;
    margin-top: 24px;
}
.save-hint { font-size: 12px; color: var(--text-dim); }
.save-actions { display: flex; gap: 10px; }

/* ---------- Guild chip with icon (header) ---------- */
.guild-chip {
    display: flex; align-items: center; gap: 10px;
    font-size: 13px; color: var(--text); background: var(--card);
    border: 1px solid var(--panel-border); padding: 6px 16px 6px 6px; border-radius: 999px;
}
.guild-chip:hover { border-color: var(--purple); }
.guild-chip-icon {
    width: 26px; height: 26px; border-radius: 50%; object-fit: cover;
}
.guild-chip-icon.fallback {
    display: flex; align-items: center; justify-content: center;
    background: linear-gradient(160deg, #7c4dff, #4c1d95);
    font-size: 12px; font-weight: 700; color: #fff;
}

/* ---------- Repeatable lists: ticket types / info panels / entries ---------- */
.list-section { margin-bottom: 24px; }
.list-section-head {
    display: flex; justify-content: space-between; align-items: center;
    margin-bottom: 14px;
}
.list-section-head h3 { margin: 0; font-size: 16px; }
.list-section-head.small { margin-bottom: 10px; }
.list-section-head.small h4 { margin: 0; font-size: 13px; color: var(--text-dim); text-transform: uppercase; letter-spacing: 0.05em; }
.list-empty {
    font-size: 13px; color: var(--text-dim); background: var(--card-2);
    border: 1px dashed var(--panel-border); padding: 14px 16px; border-radius: 10px;
}
.field-hint {
    font-size: 12px; color: var(--text-dim); margin: 6px 0 0; line-height: 1.4;
}
.list-item {
    background: var(--card);
    border: 1px solid var(--panel-border);
    border-radius: 14px;
    padding: 20px 22px;
    margin-bottom: 16px;
}
.list-item-head {
    display: flex; justify-content: space-between; align-items: center;
    margin-bottom: 14px;
}
.list-item-title { font-weight: 700; font-size: 14px; }
.field-row-2 {
    display: grid; grid-template-columns: 1fr 1fr; gap: 0 16px;
}
@media (max-width: 600px) { .field-row-2 { grid-template-columns: 1fr; } }
.entries-box {
    margin-top: 16px; padding-top: 16px; border-top: 1px solid var(--panel-border);
}
.entry-item {
    background: var(--card-2);
    border: 1px solid var(--panel-border);
    border-radius: 10px;
    padding: 14px 16px;
    margin-bottom: 12px;
}
.entry-item:last-child { margin-bottom: 0; }

/* ---------- Custom select dropdown (select-enhance.js) ----------
   Every <select> in the panel is replaced with this same button+menu combo
   at runtime — the browser's own dropdown popup can't be reliably rounded
   with CSS in most browsers, so this is what makes every dropdown in the
   app (roles, channels, plan, duration, add-source, everything) look and
   behave identically, instead of some staying square native controls. */
.csel-native { position: absolute; inset: 0; opacity: 0; pointer-events: none; }
.csel-wrap { position: relative; }
.csel-wrap.disabled .csel-btn { opacity: 0.55; cursor: not-allowed; }
.csel-wrap.csel-field { display: block; width: 100%; }
.csel-wrap.csel-chip-add { display: inline-block; }
.csel-wrap.csel-plan { display: inline-flex; }

.csel-btn {
    all: unset;
    box-sizing: border-box;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    cursor: pointer;
    font: inherit;
    color: var(--text);
    background: var(--bg);
    border: 1px solid var(--panel-border);
    border-radius: 10px;
    padding: 10px 12px;
    transition: border-color 0.15s ease;
}
.csel-btn:hover, .csel-btn:focus-visible { border-color: var(--purple-light); }
.csel-field .csel-btn { width: 100%; }
.csel-chip-add .csel-btn { min-width: 160px; padding: 8px 10px; font-size: 13px; border-radius: 8px; }
.csel-plan .csel-btn { background: transparent; border: none; padding: 0; font-size: 13px; font-weight: 600; }
.csel-label { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.csel-arrow {
    width: 7px; height: 7px; flex-shrink: 0;
    border-right: 2px solid currentColor; border-bottom: 2px solid currentColor;
    transform: rotate(45deg); margin-top: -3px; opacity: 0.6;
}

.csel-menu {
    display: none;
    position: absolute;
    top: calc(100% + 6px);
    left: 0;
    min-width: 100%;
    max-height: 260px;
    overflow-y: auto;
    background: #1a1626;
    border: 1px solid var(--panel-border);
    border-radius: 12px;
    padding: 4px;
    z-index: 80;
    box-shadow: 0 16px 40px rgba(0, 0, 0, 0.55);
}
.csel-menu.open { display: block; }
.csel-plan .csel-menu { left: auto; right: 0; min-width: 130px; }
.csel-option {
    padding: 9px 10px;
    border-radius: 8px;
    font-size: 14px;
    color: var(--text);
    cursor: pointer;
    white-space: nowrap;
}
.csel-option:hover { background: rgba(139, 92, 246, 0.18); }
.csel-option.selected { color: var(--purple-light); font-weight: 600; }

/* Public marketing/legal pages (pricing, terms, privacy, refunds) — these
   are logged-out pages so they don't reuse the dashboard header, but keep
   the same look via a lighter header bar and the shared color tokens. */
.public-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 20px 32px;
    border-bottom: 1px solid var(--panel-border);
}
.public-header .brand-group { text-decoration: none; }

.legal-page {
    max-width: 820px;
    margin: 0 auto;
    padding: 48px 24px 80px;
    color: var(--text);
    line-height: 1.7;
}
.legal-page h3 {
    margin: 32px 0 8px;
    font-size: 18px;
    color: var(--purple-light);
}
.legal-page p { color: var(--text-dim); margin: 0 0 4px; }
.legal-page a { color: var(--purple-light); }
.legal-updated, .legal-intro { color: var(--text-dim); margin-bottom: 24px; }
.legal-footnote { margin-top: 40px; font-size: 13px; color: var(--text-dim); }

.pricing-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
    margin-top: 32px;
}
.pricing-card {
    position: relative;
    background: var(--card);
    border: 1px solid var(--panel-border);
    border-radius: 16px;
    padding: 24px;
    display: flex;
    flex-direction: column;
}
.pricing-card.featured {
    border-color: var(--purple);
    box-shadow: 0 0 0 1px var(--purple), 0 16px 40px rgba(139,92,246,0.18);
}
.pricing-badge {
    position: absolute;
    top: -12px;
    left: 20px;
    background: var(--purple);
    color: #fff;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.04em;
    padding: 4px 10px;
    border-radius: 999px;
}
.pricing-name { font-size: 15px; font-weight: 700; color: var(--text); }
.pricing-price { font-size: 30px; font-weight: 800; color: var(--text); margin: 8px 0 4px; }
.pricing-price span { font-size: 13px; font-weight: 500; color: var(--text-dim); }
.pricing-desc { color: var(--text-dim); font-size: 13px; margin: 0 0 16px; }
.pricing-list {
    list-style: none;
    padding: 0;
    margin: 0 0 16px;
    display: flex;
    flex-direction: column;
    gap: 8px;
    flex: 1;
}
.pricing-list li {
    font-size: 13px;
    color: var(--text);
    padding-left: 20px;
    position: relative;
}
.pricing-list li::before {
    content: "✓";
    position: absolute;
    left: 0;
    color: var(--success);
    font-weight: 700;
}
.pricing-terms {
    border-top: 1px solid var(--panel-border);
    padding-top: 12px;
    font-size: 13px;
    color: var(--text-dim);
    display: flex;
    flex-direction: column;
    gap: 4px;
}
.pricing-terms strong { color: var(--text); }
.pricing-terms .save { color: var(--success); }

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

.public-nav {
    display: flex;
    gap: 24px;
}
.public-nav a {
    color: var(--text-dim);
    text-decoration: none;
    font-size: 14px;
    font-weight: 600;
    transition: color 0.15s ease;
}
.public-nav a:hover, .public-nav a.active { color: var(--purple-light); }

.home-footer-links {
    display: flex;
    gap: 18px;
    justify-content: center;
    margin-top: 24px;
}
.home-footer-links a {
    color: var(--text-dim);
    text-decoration: none;
    font-size: 13px;
}
.home-footer-links a:hover { color: var(--purple-light); }

.pricing-cta {
    display: block;
    text-align: center;
    margin-top: 4px;
    text-decoration: none;
}

/* About page — reuses .module-card/.module-grid from the dashboard but the
   page itself is public/read-only, so cards aren't links and always show
   a plain FREE/PREMIUM badge instead of live on/off state. */
.about-page { max-width: 1180px; }
.about-cta {
    display: flex;
    gap: 12px;
    margin: 24px 0 8px;
}
.about-grid { margin-top: 24px; }
.about-card { cursor: default; }
.about-card:hover { transform: none; }

.about-legend {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 8px;
    margin: 20px 0 8px;
    padding: 12px 16px;
    background: var(--card);
    border: 1px solid var(--panel-border);
    border-radius: 12px;
    font-size: 13px;
    color: var(--text-dim);
}
.legend-sep { color: var(--panel-border); margin: 0 4px; }
.about-limit {
    margin-top: 10px;
    padding-top: 10px;
    border-top: 1px solid var(--panel-border);
    font-size: 12px;
    font-weight: 600;
    color: var(--purple-light);
}

.emoji-live-preview { display: inline-flex; vertical-align: middle; margin-left: 6px; }
.emoji-preview-img { width: 22px; height: 22px; vertical-align: middle; }

.image-upload-field { display: flex; flex-direction: column; gap: 10px; }
.image-preview-wrap {
    width: 100%;
    max-width: 260px;
    min-height: 90px;
    border: 1px solid var(--panel-border);
    border-radius: 12px;
    background: var(--card);
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    padding: 8px;
}
.image-preview-wrap.empty { color: var(--text-dim); font-size: 13px; }
.image-preview { max-width: 100%; max-height: 120px; object-fit: contain; border-radius: 8px; }
.image-preview-empty { font-size: 13px; color: var(--text-dim); }
.image-upload-row { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.image-upload-btn { cursor: pointer; }
.image-upload-status { font-size: 12px; color: var(--text-dim); }

/* Universal emoji picker — a small "😊 Browse" toggle next to every
   .emoji-input field, opening a searchable popup with the server's own
   custom emojis plus a large curated set of common unicode emojis, so
   every field with an emoji option has the same full picker, not just a
   handful of shortcuts. */
.emoji-picker-wrap { position: relative; display: inline-block; }
.emoji-picker-toggle {
    margin-top: 6px;
    padding: 5px 10px;
    font-size: 12px;
    border-radius: 8px;
    border: 1px solid var(--panel-border);
    background: var(--card);
    color: var(--text);
    cursor: pointer;
}
.emoji-picker-toggle:hover { border-color: var(--purple); }
.emoji-picker-popup {
    position: absolute;
    z-index: 50;
    top: 100%;
    left: 0;
    margin-top: 4px;
    width: 280px;
    max-height: 320px;
    overflow-y: auto;
    background: var(--card);
    border: 1px solid var(--panel-border);
    border-radius: 12px;
    box-shadow: 0 12px 32px rgba(0,0,0,0.45);
    padding: 10px;
}
.emoji-picker-search {
    width: 100%;
    padding: 6px 10px;
    margin-bottom: 8px;
    border-radius: 8px;
    border: 1px solid var(--panel-border);
    background: var(--bg);
    color: var(--text);
    font-size: 13px;
}
.emoji-picker-section-label {
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    color: var(--text-dim);
    margin: 8px 0 4px;
}
.emoji-picker-grid { display: grid; grid-template-columns: repeat(8, 1fr); gap: 4px; }
.emoji-picker-item {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 4px;
    border-radius: 6px;
    border: none;
    background: transparent;
    font-size: 18px;
    cursor: pointer;
    line-height: 1;
}
.emoji-picker-item:hover { background: rgba(139, 92, 246, 0.16); }
.emoji-picker-item img { width: 20px; height: 20px; }
.emoji-picker-empty { font-size: 12px; color: var(--text-dim); padding: 6px 2px; }

/* Plan comparison table (public /about page) */
.plan-table-wrap { overflow-x: auto; margin-bottom: 24px; }
.plan-table { width: 100%; border-collapse: collapse; font-size: 14px; }
.plan-table th, .plan-table td { text-align: left; padding: 10px 12px; border-bottom: 1px solid rgba(255,255,255,0.08); vertical-align: top; }
.plan-table th { font-size: 12px; letter-spacing: 0.08em; text-transform: uppercase; opacity: 0.7; }
.plan-module { font-weight: 600; white-space: nowrap; }
.plan-yes { color: #86efac; }
.plan-no { opacity: 0.45; }

/* =====================================================================
   NIGHTCODE THEME v2 — matches nightcodestore.com
   Pure visual overrides (colors, fonts, spacing, effects).
   No layout logic or behaviour depends on this block — delete it to
   get the previous look back.
   ===================================================================== */
:root {
    --bg: #07050d;
    --panel: #0d0a17;
    --panel-border: rgba(255,255,255,0.08);
    --card: #120e1f;
    --card-2: #181329;
    --purple: #7c5cff;
    --purple-light: #a993ff;
    --nc-accent2: #b14dff;
    --nc-cyan: #38d6ff;
    --text: #efecf8;
    --text-dim: #9a93b3;
    --success: #3ee08f;
    --nc-grad: linear-gradient(135deg, #7c5cff, #b14dff);
    --nc-line2: rgba(255,255,255,0.14);
    --bg-glow:
        radial-gradient(ellipse 620px 520px at 6% -6%, rgba(91,60,255,0.40), transparent 62%),
        radial-gradient(ellipse 560px 480px at 96% 6%, rgba(161,45,255,0.32), transparent 60%),
        radial-gradient(ellipse 700px 520px at 40% 115%, rgba(26,166,217,0.12), transparent 62%);
    --bg-grid:
        linear-gradient(rgba(255,255,255,0.035) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255,255,255,0.035) 1px, transparent 1px);
}
body {
    font-family: Inter, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    -webkit-font-smoothing: antialiased;
    background-size: 64px 64px, 64px 64px, auto, auto, auto;
}
h1, h2, h3, .hero-title, .module-name, .server-name, .stat-num, .pricing-price, .pricing-name {
    font-family: 'Space Grotesk', Inter, sans-serif;
    letter-spacing: -0.02em;
}
::selection { background: rgba(124,92,255,0.45); }
* { scrollbar-width: thin; scrollbar-color: #2b2445 transparent; }

/* header: glass, sticky, one row */
header, .public-header {
    position: sticky; top: 0; z-index: 50;
    background: rgba(7,5,13,0.72);
    backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px);
    border-bottom: 1px solid var(--panel-border);
    gap: 18px;
}
.brand-group h1 { font-size: 19px; }
.logo-img { width: 38px; height: 38px; box-shadow: none; filter: drop-shadow(0 0 12px rgba(124,92,255,0.55)); }
.pill-tag { background: rgba(124,92,255,0.18); border-color: rgba(124,92,255,0.4); color: #c4b5ff; }
.external-nav { flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; min-width: 0; }
.external-nav::-webkit-scrollbar { display: none; }
.external-link-btn {
    white-space: nowrap; flex-shrink: 0;
    background: transparent; border-color: transparent; border-radius: 10px;
    color: var(--text-dim); font-size: 13.5px; padding: 8px 11px;
}
.external-link-btn:hover { background: rgba(255,255,255,0.05); border-color: var(--panel-border); color: var(--text); }
.guild-chip { background: rgba(255,255,255,0.03); border-color: var(--nc-line2); white-space: nowrap; }
.user-chip { white-space: nowrap; }
.avatar-circle, .guild-chip-icon.fallback { background: var(--nc-grad); }

/* buttons */
.btn {
    background: var(--nc-grad);
    border-radius: 12px;
    box-shadow: 0 8px 28px -8px rgba(124,92,255,0.75);
    transition: transform .2s ease, box-shadow .2s ease, opacity .15s ease, background .2s ease;
}
.btn:hover { transform: translateY(-2px); box-shadow: 0 12px 34px -8px rgba(124,92,255,0.95); }
.btn.small { border-radius: 10px; box-shadow: 0 6px 20px -8px rgba(124,92,255,0.7); }
.btn.secondary {
    background: rgba(255,255,255,0.03);
    border: 1px solid var(--nc-line2);
    box-shadow: none;
}
.btn.secondary:hover { background: rgba(255,255,255,0.07); border-color: rgba(255,255,255,0.25); box-shadow: none; }

/* headings + eyebrow */
.eyebrow {
    color: #a993ff; letter-spacing: 0.14em;
}
.hero-title { font-size: 40px; font-weight: 700; }
.hero-title .accent {
    background: linear-gradient(100deg, #a58bff 0%, #b14dff 45%, #38d6ff 100%);
    -webkit-background-clip: text; background-clip: text; color: transparent;
}
main > h2 { font-size: 30px; font-weight: 700; margin: 6px 0 18px; }

/* cards */
.server-card, .module-card, .group-card, .stat-card, .module-header-card, .pricing-card, .about-card, .list-item, .entries-box {
    background: linear-gradient(180deg, var(--card), rgba(18,14,31,0.75));
    border: 1px solid var(--panel-border);
    border-radius: 18px;
    transition: transform .3s ease, border-color .3s ease, box-shadow .3s ease;
}
.server-card:hover, .module-card:hover, .pricing-card:hover, .about-card:hover {
    transform: translateY(-4px);
    border-color: rgba(124,92,255,0.45);
    box-shadow: 0 24px 60px -24px rgba(124,92,255,0.45);
}
.module-card { position: relative; overflow: hidden; }
.module-card::before {
    content: ""; position: absolute; inset: 0; pointer-events: none;
    background: radial-gradient(420px circle at 50% -20%, rgba(124,92,255,0.16), transparent 55%);
    opacity: 0; transition: opacity .3s;
}
.module-card:hover::before { opacity: 1; }
.module-card.locked:hover { transform: translateY(-2px); }
.module-icon { background: rgba(124,92,255,0.14); border: 1px solid rgba(124,92,255,0.3); border-radius: 14px; }
.stat-card { background: rgba(255,255,255,0.03); }
.stat-num { font-weight: 700; }
.server-card img, .server-icon-fallback { box-shadow: 0 0 0 3px rgba(124,92,255,0.25), 0 10px 30px -10px rgba(124,92,255,0.6); }
.server-icon-fallback { background: var(--nc-grad); color: #fff; }
.group-card { padding: 24px; }
.pricing-card.featured {
    border-color: rgba(124,92,255,0.55);
    background: linear-gradient(180deg, #1d1440, var(--card));
    box-shadow: 0 30px 80px -30px rgba(124,92,255,0.6);
}
.pricing-badge { background: var(--nc-grad); }

/* form controls */
.field input[type=text], .field input[type=number], .field textarea, .field select, .csel-btn {
    background: rgba(7,5,13,0.6);
    border: 1px solid var(--nc-line2);
    border-radius: 12px;
    transition: border-color .2s, box-shadow .2s;
}
.field input:focus, .field textarea:focus, .field select:focus, .csel-btn:focus {
    border-color: var(--purple);
    box-shadow: 0 0 0 4px rgba(124,92,255,0.18);
}
.field label { color: #c9c3de; }
.switch input:checked + .slider { background: var(--nc-grad); box-shadow: 0 0 14px rgba(124,92,255,0.5); }

/* chips / pills */
.crumb-pill, .status-badge, .plan-chip, .chip { border-color: var(--nc-line2); }
.toggle-pill.on, .status-badge.on { color: var(--success); }

/* sticky save bar */
.save-bar {
    background: rgba(13,10,23,0.88);
    backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px);
    border: 1px solid rgba(124,92,255,0.3);
    border-radius: 18px;
    box-shadow: 0 -10px 40px -18px rgba(124,92,255,0.5);
    bottom: 14px;
}

/* home / login box */
.center-box {
    background: linear-gradient(180deg, #1b1238, #120c24);
    border: 1px solid rgba(124,92,255,0.3);
    border-radius: 26px;
    box-shadow: 0 40px 120px -30px rgba(124,92,255,0.5);
}
.center-box h1 { font-family: 'Space Grotesk', Inter, sans-serif; font-size: 34px; }

@media (max-width: 1100px) {
    header { padding-left: 18px; padding-right: 18px; }
}
.pill-tag, .btn, .crumb-pill, .status-badge, .toggle-pill { white-space: nowrap; }
@media (max-width: 1560px) {
    header { flex-wrap: wrap; row-gap: 10px; }
    header .external-nav { order: 3; flex-basis: 100%; justify-content: center; }
}
@media (min-width: 761px) { .pricing-grid { grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); } }
.legal-page a.btn, .legal-page a.btn:hover { color: #fff; }

/* =====================================================================
   SHARED TOP BAR — identical to the bar on nightcodestore.com
   (views/partials/topnav.ejs)
   ===================================================================== */
.nc-top{position:sticky;top:0;z-index:60;backdrop-filter:blur(16px);-webkit-backdrop-filter:blur(16px);background:rgba(7,5,13,.7);border-bottom:1px solid rgba(255,255,255,.08);font-family:Inter,system-ui,sans-serif}
.nc-top .nc-wrap,.nc-sub .nc-wrap{max-width:1180px;margin:0 auto;padding:0 20px;display:flex;align-items:center;gap:28px}
.nc-top .nc-wrap{height:68px}
.nc-logo{display:flex;align-items:center;gap:10px;font-family:'Space Grotesk',Inter,sans-serif;font-weight:700;font-size:19px;color:#efecf8;text-decoration:none;flex-shrink:0;letter-spacing:-.02em}
.nc-logo img{width:38px;height:38px;filter:drop-shadow(0 0 12px rgba(124,92,255,.55))}
.nc-links{display:flex;gap:24px;margin-left:12px}
.nc-links a{color:#9a93b3;font-size:14.5px;font-weight:500;text-decoration:none;transition:.2s;white-space:nowrap}
.nc-links a:hover,.nc-links a.on{color:#efecf8}
.nc-right{margin-left:auto;display:flex;gap:10px;align-items:center}
.nc-btn{display:inline-flex;align-items:center;gap:8px;padding:11px 20px;border-radius:12px;font:600 14.5px Inter,system-ui,sans-serif;transition:.2s;white-space:nowrap;text-decoration:none;color:#efecf8;cursor:pointer;border:0;background:none}
.nc-sm{padding:8px 14px;font-size:13.5px;border-radius:10px}
.nc-ghost{border:1px solid rgba(255,255,255,.14);background:rgba(255,255,255,.03)}
.nc-ghost:hover{background:rgba(255,255,255,.07);border-color:rgba(255,255,255,.25);color:#efecf8}
.nc-primary{background:linear-gradient(135deg,#7c5cff,#b14dff);box-shadow:0 8px 28px -8px rgba(124,92,255,.7);color:#fff}
.nc-primary:hover{transform:translateY(-2px);box-shadow:0 12px 34px -8px rgba(124,92,255,.9);color:#fff}
.nc-lang{position:relative}
.nc-lang-menu{position:absolute;right:0;top:calc(100% + 8px);min-width:170px;background:#0d0a17;border:1px solid rgba(255,255,255,.14);border-radius:14px;padding:6px;display:none;box-shadow:0 20px 50px -10px rgba(0,0,0,.6);z-index:70}
.nc-lang.open .nc-lang-menu{display:grid}
.nc-lang-menu button{text-align:left;padding:9px 12px;border-radius:9px;font-size:14px;color:#9a93b3}
.nc-lang-menu button:hover{background:rgba(255,255,255,.06);color:#efecf8}
.nc-lang-menu button.on{background:rgba(124,92,255,.18);color:#e0d8ff}
.nc-user{display:flex;align-items:center;gap:10px;padding:4px 12px 4px 4px;border-radius:999px;border:1px solid rgba(255,255,255,.14);background:rgba(255,255,255,.03)}
.nc-av{width:30px;height:30px;border-radius:50%;object-fit:cover;background:linear-gradient(135deg,#7c5cff,#b14dff);display:inline-flex;align-items:center;justify-content:center;font-size:13px;font-weight:700;color:#fff}
.nc-uname{font-size:13.5px;font-weight:600;max-width:140px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.nc-logout{font-size:12.5px;color:#9a93b3;text-decoration:none}
.nc-logout:hover{color:#efecf8}
.nc-burger{display:none;width:40px;height:40px;border-radius:10px;border:1px solid rgba(255,255,255,.14);color:#efecf8;font-size:16px}
.nc-sub{border-bottom:1px solid rgba(255,255,255,.06);background:rgba(13,10,23,.55)}
.nc-sub .nc-wrap{height:52px;gap:12px}
.nc-sub .guild-chip{margin:0}
@media (max-width:980px){.nc-links{gap:16px;margin-left:0}.nc-top .nc-wrap{gap:16px}}
@media (max-width:860px){
  .nc-links{display:none;position:absolute;top:68px;left:0;right:0;flex-direction:column;gap:0;background:#0d0a17;border-bottom:1px solid rgba(255,255,255,.08);padding:8px 20px 16px;margin:0}
  .nc-links.open{display:flex}.nc-links a{padding:12px 0;font-size:16px}
  .nc-burger{display:grid;place-items:center}
  .nc-hide-m{display:none}
  .nc-uname{display:none}
}
@media (max-width:440px){.nc-right>.nc-primary{display:none}}
/* same content width as nightcodestore.com and the top bar */
main, main.modules-page { max-width: 1180px; padding: 32px 20px; }
.pricing-terms a{color:inherit;text-decoration:none}.pricing-terms a:hover strong{color:#fff}
