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

:root {
    --bg:           #0a0a0a;
    --bg-2:         #111111;
    --bg-3:         #1a1a1a;
    --border:       rgba(255,255,255,0.07);
    --border-2:     rgba(255,255,255,0.12);
    --text:         #f0f0f0;
    --text-muted:   #6b7280;
    --primary:      #22c55e;
    --primary-h:    #16a34a;
    --primary-dim:  rgba(34,197,94,0.15);
    --primary-glow: rgba(34,197,94,0.25);
    --success:      #22c55e;
    --warning:      #f59e0b;
    --danger:       #ef4444;
    --cyan:         #06b6d4;
    --purple:       #8b5cf6;
    --orange:       #f97316;
    --pink:         #ec4899;
    --green:        #22c55e;
    --sidebar-w:    240px;
    --radius:       12px;
    --shadow:       0 4px 32px rgba(0,0,0,.6);
}

body {
    font-family: 'Inter', system-ui, sans-serif;
    background: var(--bg);
    color: var(--text);
    line-height: 1.6;
    font-size: 15px;
    -webkit-font-smoothing: antialiased;
}

a { color: var(--primary); text-decoration: none; }
a:hover { text-decoration: underline; }
code { background: var(--bg-3); padding: 2px 6px; border-radius: 4px; font-size: .85em; border: 1px solid var(--border); }

.btn {
    display: inline-flex;
    align-items: center;
    gap: .45rem;
    padding: .55rem 1.1rem;
    border-radius: 8px;
    font-size: .875rem;
    font-weight: 600;
    cursor: pointer;
    border: 1px solid transparent;
    transition: transform .18s cubic-bezier(.4,0,.2,1), box-shadow .18s cubic-bezier(.4,0,.2,1), background .18s, border-color .18s, opacity .18s;
    white-space: nowrap;
    text-decoration: none;
    position: relative;
    overflow: hidden;
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
}
.btn::before {
    content: '';
    position: absolute; inset: 0;
    background: linear-gradient(135deg, rgba(255,255,255,.07) 0%, transparent 55%);
    pointer-events: none;
    border-radius: inherit;
}
.btn:hover  { transform: translateY(-2px); text-decoration: none; }
.btn:active { transform: translateY(0) scale(.98); }

.btn-primary {
    background: linear-gradient(135deg, #2dda6d 0%, #16a34a 100%);
    color: #000;
    border-color: rgba(34,197,94,.45);
    box-shadow: 0 2px 12px rgba(34,197,94,.2), inset 0 1px 0 rgba(255,255,255,.12);
}
.btn-primary:hover {
    background: linear-gradient(135deg, #4ade80 0%, #22c55e 100%);
    box-shadow: 0 0 28px rgba(34,197,94,.45), 0 4px 18px rgba(34,197,94,.25);
    border-color: rgba(34,197,94,.75);
}

.btn-success {
    background: linear-gradient(135deg, #2dda6d 0%, #16a34a 100%);
    color: #000;
    border-color: rgba(34,197,94,.45);
    box-shadow: 0 2px 12px rgba(34,197,94,.2), inset 0 1px 0 rgba(255,255,255,.12);
}
.btn-success:hover {
    box-shadow: 0 0 28px rgba(34,197,94,.45), 0 4px 18px rgba(34,197,94,.25);
    border-color: rgba(34,197,94,.75);
}

.btn-warning {
    background: rgba(245,158,11,.18);
    color: #fbbf24;
    border-color: rgba(245,158,11,.35);
    box-shadow: 0 2px 10px rgba(245,158,11,.1);
}
.btn-warning:hover {
    background: rgba(245,158,11,.28);
    border-color: rgba(245,158,11,.65);
    box-shadow: 0 0 24px rgba(245,158,11,.35), 0 4px 16px rgba(245,158,11,.2);
}

.btn-danger {
    background: rgba(239,68,68,.18);
    color: #fca5a5;
    border-color: rgba(239,68,68,.35);
    box-shadow: 0 2px 10px rgba(239,68,68,.1);
}
.btn-danger:hover {
    background: rgba(239,68,68,.28);
    border-color: rgba(239,68,68,.65);
    box-shadow: 0 0 24px rgba(239,68,68,.35), 0 4px 16px rgba(239,68,68,.2);
}

.btn-ghost {
    background: rgba(255,255,255,.04);
    color: var(--text);
    border-color: var(--border-2);
    box-shadow: inset 0 1px 0 rgba(255,255,255,.04);
}
.btn-ghost:hover {
    background: rgba(255,255,255,.09);
    border-color: rgba(255,255,255,.22);
    box-shadow: 0 0 18px rgba(255,255,255,.06), inset 0 1px 0 rgba(255,255,255,.08);
}

.btn-discord {
    background: rgba(88,101,242,.22);
    color: #c7d0ff;
    border-color: rgba(88,101,242,.45);
    box-shadow: 0 2px 12px rgba(88,101,242,.15);
}
.btn-discord:hover {
    background: rgba(88,101,242,.35);
    border-color: rgba(88,101,242,.75);
    box-shadow: 0 0 28px rgba(88,101,242,.45), 0 4px 18px rgba(88,101,242,.25);
}

.btn-lg { padding: .75rem 1.5rem; font-size: 1rem; border-radius: 10px; }
.btn-sm { padding: .35rem .75rem; font-size: .8rem; }

.alert {
    padding: .8rem 1.2rem;
    border-radius: var(--radius);
    margin-bottom: 1.2rem;
    font-size: .9rem;
}
.alert-error   { background: rgba(239,68,68,.1);  border: 1px solid rgba(239,68,68,.3);  color: #fca5a5; }
.alert-success { background: rgba(34,197,94,.1);  border: 1px solid rgba(34,197,94,.3);  color: #86efac; }
.alert-info    { background: rgba(34,197,94,.08); border: 1px solid rgba(34,197,94,.2);  color: #86efac; }

.container { max-width: 1100px; margin: 0 auto; padding: 0 1.5rem; }

body.landing {
    background-color: var(--bg);
    background-image: radial-gradient(circle, rgba(255,255,255,0.055) 1px, transparent 1px);
    background-size: 28px 28px;
}
body.landing::before {
    content: '';
    position: fixed; inset: 0;
    pointer-events: none;
    z-index: 0;
    background: radial-gradient(600px circle at var(--mouse-x, 50%) var(--mouse-y, 50%), rgba(34,197,94,0.07) 0%, transparent 60%);
    transition: background 0.1s;
}

.nav {
    position: fixed; top: 0; left: 0; right: 0; z-index: 100;
    border-bottom: 1px solid var(--border);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    background: rgba(10,10,10,0.85);
}
.nav-container { max-width: 1100px; margin: 0 auto; padding: 0 1.5rem; display: flex; align-items: center; justify-content: space-between; height: 64px; }
.nav-logo { display: flex; align-items: center; gap: .6rem; font-size: 1.1rem; font-weight: 700; color: var(--text); text-decoration: none; }
.nav-links { display: flex; align-items: center; gap: 1.5rem; }
.nav-links a:not(.btn) { color: var(--text-muted); font-size: .9rem; font-weight: 500; text-decoration: none; transition: color .15s; }
.nav-links a:not(.btn):hover { color: var(--text); }

.hero { min-height: 100vh; display: flex; align-items: center; padding-top: 64px; position: relative; overflow: hidden; }
.hero-bg { position: absolute; inset: 0; pointer-events: none; }
.hero-orb { position: absolute; border-radius: 50%; filter: blur(120px); }
.hero-orb-1 { width: 700px; height: 700px; background: rgba(34,197,94,0.12); top: -200px; left: -150px; }
.hero-orb-2 { width: 500px; height: 500px; background: rgba(34,197,94,0.06); bottom: -100px; right: -50px; }
.hero .container { position: relative; z-index: 1; padding: 5rem 1.5rem; }
.hero-badge {
    display: inline-flex; align-items: center; gap: .5rem;
    background: rgba(34,197,94,0.1);
    border: 1px solid rgba(34,197,94,0.25);
    color: #86efac;
    border-radius: 999px; padding: .35rem 1rem; font-size: .8rem; font-weight: 600; margin-bottom: 1.5rem;
}
.badge-dot { width: 6px; height: 6px; border-radius: 50%; background: var(--primary); animation: pulse 2s infinite; }
@keyframes pulse { 0%,100% { opacity: 1; box-shadow: 0 0 0 0 rgba(34,197,94,.4); } 50% { opacity: .7; box-shadow: 0 0 0 4px rgba(34,197,94,0); } }

.hero-title { font-size: clamp(2.5rem, 6vw, 4rem); font-weight: 800; line-height: 1.15; margin-bottom: 1.2rem; letter-spacing: -.02em; }
.gradient-text {
    background: linear-gradient(135deg, #22c55e 0%, #86efac 50%, #4ade80 100%);
    -webkit-background-clip: text; -webkit-text-fill-color: transparent; background-clip: text;
}
.hero-subtitle { font-size: 1.1rem; color: var(--text-muted); max-width: 540px; margin-bottom: 2rem; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 1rem; margin-bottom: 3rem; }

.hero-stats { display: flex; align-items: center; gap: 2rem; }
.stat { display: flex; flex-direction: column; }
.stat-number { font-size: 1.5rem; font-weight: 700; color: var(--primary); }
.stat-label  { font-size: .8rem; color: var(--text-muted); }
.stat-divider { width: 1px; height: 36px; background: var(--border); }

.features { padding: 5rem 0; position: relative; z-index: 1; }
.section-header { text-align: center; margin-bottom: 3rem; }
.section-header h2 { font-size: 2rem; font-weight: 700; margin-bottom: .5rem; }
.section-header p  { color: var(--text-muted); }

.features-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 1.2rem; }
.feature-card {
    background: var(--bg-2);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 1.5rem;
    transition: border-color .2s, transform .2s, box-shadow .2s;
    position: relative;
    overflow: hidden;
}
.feature-card::before {
    content: '';
    position: absolute; inset: 0;
    background: radial-gradient(circle at 50% 0%, rgba(34,197,94,0.05), transparent 70%);
    opacity: 0;
    transition: opacity .3s;
}
.feature-card:hover { border-color: rgba(34,197,94,0.3); transform: translateY(-2px); box-shadow: 0 8px 32px rgba(0,0,0,.4); }
.feature-card:hover::before { opacity: 1; }
.feature-card h3 { font-size: 1rem; font-weight: 600; margin: 1rem 0 .4rem; }
.feature-card p  { font-size: .875rem; color: var(--text-muted); }

.feature-icon { width: 44px; height: 44px; border-radius: 10px; display: flex; align-items: center; justify-content: center; }
.feature-icon-purple { background: rgba(139,92,246,.15); color: #c084fc; }
.feature-icon-blue   { background: rgba(88,101,242,.15);  color: #818cf8; }
.feature-icon-green  { background: rgba(34,197,94,.15);   color: #4ade80; }
.feature-icon-orange { background: rgba(249,115,22,.15);  color: #fb923c; }
.feature-icon-pink   { background: rgba(236,72,153,.15);  color: #f472b6; }
.feature-icon-cyan   { background: rgba(6,182,212,.15);   color: #22d3ee; }

.how-it-works { padding: 5rem 0; background: rgba(255,255,255,0.015); border-top: 1px solid var(--border); border-bottom: 1px solid var(--border); position: relative; z-index: 1; }
.steps { display: flex; align-items: center; justify-content: center; flex-wrap: wrap; gap: 1rem; }
.step { text-align: center; max-width: 240px; }
.step-number {
    width: 52px; height: 52px; border-radius: 50%;
    background: var(--primary-dim);
    border: 1px solid rgba(34,197,94,0.3);
    color: var(--primary);
    font-size: 1.2rem; font-weight: 700;
    display: flex; align-items: center; justify-content: center;
    margin: 0 auto 1rem;
    box-shadow: 0 0 20px rgba(34,197,94,0.1);
}
.step h3 { font-size: 1rem; font-weight: 600; margin-bottom: .4rem; }
.step p  { font-size: .875rem; color: var(--text-muted); }
.step-arrow { font-size: 1.5rem; color: rgba(34,197,94,0.3); }

.cta { padding: 5rem 0; text-align: center; position: relative; z-index: 1; }
.cta h2 { font-size: 2rem; font-weight: 700; margin-bottom: .5rem; }
.cta p  { color: var(--text-muted); margin-bottom: 2rem; }

.footer { border-top: 1px solid var(--border); padding: 1.5rem 0; text-align: center; color: var(--text-muted); font-size: .85rem; position: relative; z-index: 1; }

body.dashboard-body {
    background-color: var(--bg);
    background-image: radial-gradient(circle, rgba(255,255,255,0.04) 1px, transparent 1px);
    background-size: 28px 28px;
}

.dashboard-layout { display: flex; min-height: 100vh; }

.sidebar {
    width: var(--sidebar-w);
    min-height: 100vh;
    background: rgba(10,10,10,0.95);
    border-right: 1px solid var(--border);
    display: flex;
    flex-direction: column;
    position: fixed;
    top: 0; left: 0;
    z-index: 50;
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    transition: transform .25s ease;
}

.sidebar-overlay {
    display: none;
    position: fixed; inset: 0;
    background: rgba(0,0,0,.55);
    z-index: 49;
    backdrop-filter: blur(2px);
    -webkit-backdrop-filter: blur(2px);
}
.sidebar-overlay.open { display: block; }

.sidebar-logo { padding: 1.2rem 1.2rem 1rem; }
.sidebar-logo a { display: flex; align-items: center; gap: .6rem; font-size: 1rem; font-weight: 700; color: var(--text); text-decoration: none; }

.sidebar-nav { flex: 1; padding: .5rem .75rem; display: flex; flex-direction: column; gap: 2px; }
.sidebar-link {
    display: flex; align-items: center; gap: .7rem;
    padding: .6rem .75rem;
    border-radius: 8px;
    color: var(--text-muted);
    text-decoration: none;
    font-size: .875rem;
    font-weight: 500;
    transition: background .15s, color .15s;
}
.sidebar-link:hover  { background: rgba(255,255,255,0.05); color: var(--text); text-decoration: none; }
.sidebar-link.active { background: rgba(34,197,94,0.12); color: #86efac; border: 1px solid rgba(34,197,94,0.15); }
.sidebar-link.active svg { color: var(--primary); }

.sidebar-footer {
    padding: .75rem;
    border-top: 1px solid var(--border);
    display: flex;
    align-items: center;
    gap: .5rem;
}
.sidebar-user { display: flex; align-items: center; gap: .6rem; flex: 1; min-width: 0; }
.sidebar-user-info { min-width: 0; }
.sidebar-username { font-size: .85rem; font-weight: 600; display: block; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.sidebar-avatar { width: 34px; height: 34px; border-radius: 50%; flex-shrink: 0; }
.sidebar-avatar-placeholder { width: 34px; height: 34px; border-radius: 50%; background: var(--primary); color: #000; display: flex; align-items: center; justify-content: center; font-weight: 700; font-size: .85rem; flex-shrink: 0; }
.sidebar-logout { color: var(--text-muted); padding: .4rem; border-radius: 6px; display: flex; transition: color .15s, background .15s; }
.sidebar-logout:hover { color: var(--danger); background: rgba(239,68,68,.1); text-decoration: none; }

.sidebar-rank { font-size: .68rem; font-weight: 600; padding: 1px 7px; border-radius: 999px; display: inline-block; margin-top: 2px; }
.sidebar-rank-admin { background: rgba(139,92,246,.2); color: #c084fc; border: 1px solid rgba(139,92,246,.3); }
.sidebar-rank-user  { background: rgba(107,114,128,.12); color: var(--text-muted); border: 1px solid var(--border); }

.sidebar-toggle {
    display: none;
    align-items: center;
    justify-content: center;
    width: 36px; height: 36px;
    background: transparent;
    border: 1px solid var(--border-2);
    border-radius: 8px;
    color: var(--text);
    cursor: pointer;
    flex-shrink: 0;
    padding: 0;
}

.dashboard-main {
    flex: 1;
    margin-left: var(--sidebar-w);
    padding: 2rem 2.5rem;
    max-width: calc(100vw - var(--sidebar-w));
    position: relative;
    z-index: 1;
}

.mobile-topbar {
    display: none;
    align-items: center;
    gap: .75rem;
    padding-bottom: 1.25rem;
    margin-bottom: .25rem;
    border-bottom: 1px solid var(--border);
    margin-bottom: 1.5rem;
}
.mobile-topbar-logo { display: flex; align-items: center; gap: .5rem; font-size: .95rem; font-weight: 700; color: var(--text); flex: 1; }

.page-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 1rem;
    margin-bottom: 2rem;
}
.page-header h1 { font-size: 1.5rem; font-weight: 700; }
.page-subtitle   { color: var(--text-muted); font-size: .9rem; margin-top: .2rem; }

.card {
    background: var(--bg-2);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 1.5rem;
    margin-bottom: 1.5rem;
}
.card-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 1.2rem;
    padding-bottom: .75rem;
    border-bottom: 1px solid var(--border);
}
.card-header h2 { font-size: 1rem; font-weight: 600; }

.stats-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 1rem; margin-bottom: 1.5rem; }
.stat-card {
    background: var(--bg-2);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 1.2rem 1.5rem;
    display: flex; align-items: center; gap: 1rem;
    transition: border-color .2s;
}
.stat-card:hover { border-color: rgba(34,197,94,0.2); }
.stat-card-icon { width: 44px; height: 44px; border-radius: 10px; display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.stat-icon-purple { background: rgba(139,92,246,.15); color: #c084fc; }
.stat-icon-green  { background: rgba(34,197,94,.15);  color: #4ade80; }
.stat-icon-blue   { background: rgba(88,101,242,.15); color: #818cf8; }
.stat-card-value  { font-size: 1.6rem; font-weight: 700; line-height: 1; display: block; }
.stat-card-label  { font-size: .8rem; color: var(--text-muted); display: block; margin-top: .2rem; }

.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 1.5rem; margin-bottom: 1.5rem; }

.bot-status-badge {
    display: inline-block;
    padding: 2px 8px;
    border-radius: 999px;
    font-size: .75rem;
    font-weight: 600;
}
.status-running  { background: rgba(34,197,94,.15);   color: #4ade80; }
.status-stopped  { background: rgba(107,114,128,.12); color: var(--text-muted); }
.status-starting { background: rgba(245,158,11,.15);  color: #fbbf24; }
.status-error    { background: rgba(239,68,68,.15);   color: #fca5a5; }
.status-lg { padding: 4px 12px; font-size: .85rem; }

.bot-avatar-placeholder, .bot-avatar-placeholder-lg {
    background: var(--primary);
    color: #000;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
}
.bot-avatar-small  { width: 36px; height: 36px; flex-shrink: 0; }
.bot-avatar-small img, .bot-avatar-small .bot-avatar-placeholder { width: 36px; height: 36px; border-radius: 50%; font-size: .9rem; }
.bot-avatar-med    { width: 44px; height: 44px; flex-shrink: 0; }
.bot-avatar-med img, .bot-avatar-med .bot-avatar-placeholder { width: 44px; height: 44px; border-radius: 50%; font-size: 1.1rem; }
.bot-avatar-large  { width: 64px; height: 64px; flex-shrink: 0; }
.bot-avatar-large img { width: 64px; height: 64px; border-radius: 50%; }
.bot-avatar-placeholder-lg { width: 64px; height: 64px; font-size: 1.5rem; }

.bot-list { display: flex; flex-direction: column; gap: .5rem; }
.bot-item { display: flex; align-items: center; justify-content: space-between; padding: .75rem; border-radius: 8px; background: rgba(255,255,255,0.025); border: 1px solid var(--border); transition: border-color .15s; }
.bot-item:hover { border-color: rgba(34,197,94,0.2); }
.bot-item-info { display: flex; align-items: center; gap: .75rem; }
.bot-name { font-weight: 600; font-size: .9rem; }

.bots-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 1rem; }
.bot-card {
    background: var(--bg-2);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 1.2rem;
    transition: border-color .15s, box-shadow .15s;
}
.bot-card:hover { border-color: rgba(34,197,94,0.3); box-shadow: 0 4px 24px rgba(0,0,0,.3); }
.bot-card-header { display: flex; align-items: center; gap: .75rem; margin-bottom: 1rem; }
.bot-card-header h3 { font-size: .95rem; font-weight: 600; }
.bot-card-info { display: flex; flex-direction: column; gap: .3rem; font-size: .8rem; color: var(--text-muted); margin-bottom: 1rem; }
.bot-card-actions { display: flex; gap: .5rem; flex-wrap: wrap; align-items: center; }
.bot-card-actions form { display: contents; }
.store-card-actions form { display: contents; }
.page-header-actions { display: flex; gap: .5rem; flex-wrap: wrap; align-items: center; }
.page-header-actions form { display: contents; }

.info-list { display: flex; flex-direction: column; gap: .75rem; }
.info-row { display: flex; justify-content: space-between; align-items: center; font-size: .875rem; padding: .5rem 0; border-bottom: 1px solid var(--border); }
.info-row:last-child { border-bottom: none; }
.info-row > span:first-child { color: var(--text-muted); }

.module-list { display: flex; flex-wrap: wrap; gap: .5rem; }
.module-tag {
    background: rgba(34,197,94,0.1);
    border: 1px solid rgba(34,197,94,0.2);
    color: #86efac;
    padding: 3px 10px; border-radius: 999px; font-size: .8rem; font-weight: 500;
}

.log-container { background: #050505; border: 1px solid var(--border); border-radius: 8px; padding: 1rem; font-family: 'Courier New', monospace; font-size: .8rem; max-height: 300px; overflow-y: auto; }
.log-line { display: flex; gap: .75rem; padding: 2px 0; }
.log-time  { color: var(--text-muted); flex-shrink: 0; }
.log-level { font-weight: 700; flex-shrink: 0; min-width: 40px; }
.log-msg   { color: #c9d1d9; word-break: break-word; }
.log-info  .log-level { color: #60a5fa; }
.log-warn  .log-level { color: #fbbf24; }
.log-error .log-level { color: #f87171; }
.log-empty { color: var(--text-muted); text-align: center; padding: 1rem 0; font-size: .85rem; }

.empty-state { text-align: center; padding: 3rem 1rem; color: var(--text-muted); display: flex; flex-direction: column; align-items: center; gap: 1rem; }
.empty-state h3 { font-size: 1.1rem; color: var(--text); }
.empty-state p { font-size: .9rem; }

.form { display: flex; flex-direction: column; gap: 1.2rem; }
.form-group { display: flex; flex-direction: column; gap: .4rem; }
.form-group label { font-size: .875rem; font-weight: 600; display: flex; align-items: center; justify-content: space-between; }
.form-hint { font-size: .8rem; font-weight: 400; color: var(--text-muted); }
.form-group input, .form-group select, .select {
    background: var(--bg-3);
    border: 1px solid var(--border);
    color: var(--text);
    padding: .6rem .9rem;
    border-radius: 8px;
    font-size: .9rem;
    width: 100%;
    transition: border-color .15s, box-shadow .15s;
    font-family: inherit;
}
.form-group input:focus, .form-group select:focus, .select:focus {
    outline: none;
    border-color: rgba(34,197,94,0.5);
    box-shadow: 0 0 0 3px rgba(34,197,94,0.08);
}
.form-note { font-size: .78rem; color: var(--text-muted); }
.form-actions { display: flex; gap: .75rem; flex-wrap: wrap; }
.inline-form { display: flex; align-items: center; gap: .5rem; flex-wrap: wrap; }
.inline-form label { font-size: .85rem; color: var(--text-muted); white-space: nowrap; }
.select { width: auto; }

.store-section { margin-bottom: 2.5rem; }
.store-category { font-size: .8rem; font-weight: 700; margin-bottom: 1rem; color: var(--text-muted); text-transform: uppercase; letter-spacing: .06em; }
.store-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 1rem; }
.store-card {
    background: var(--bg-2);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 1.2rem;
    display: flex; flex-direction: column; gap: .75rem;
    transition: border-color .15s, box-shadow .15s;
}
.store-card:hover { border-color: rgba(34,197,94,0.3); box-shadow: 0 4px 24px rgba(0,0,0,.3); }
.store-card-installed { border-color: rgba(34,197,94,0.25); }
.store-card h3 { font-size: .95rem; font-weight: 600; }
.store-card p  { font-size: .83rem; color: var(--text-muted); flex: 1; }
.store-card-header { display: flex; justify-content: space-between; align-items: flex-start; gap: .5rem; min-height: 42px; }
.store-card-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-top: auto;
    gap: .5rem;
    flex-wrap: wrap;
}
.store-card-actions { display: flex; gap: .4rem; align-items: center; flex-wrap: wrap; }
.store-icon { width: 42px; height: 42px; border-radius: 10px; display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.store-icon-moderation { background: rgba(239,68,68,.15);  color: #fca5a5; }
.store-icon-music      { background: rgba(88,101,242,.15); color: #818cf8; }
.store-icon-fun        { background: rgba(245,158,11,.15); color: #fbbf24; }
.store-icon-utility    { background: rgba(6,182,212,.15);  color: #22d3ee; }
.store-icon-economy    { background: rgba(34,197,94,.15);  color: #4ade80; }
.store-icon-leveling   { background: rgba(139,92,246,.15); color: #c084fc; }
.installed-badge   { background: rgba(34,197,94,.15); color: #4ade80; font-size: .72rem; font-weight: 600; padding: 2px 8px; border-radius: 999px; white-space: nowrap; }
.version-badge     { background: var(--bg-3); color: var(--text-muted); font-size: .75rem; padding: 2px 8px; border-radius: 999px; white-space: nowrap; flex-shrink: 0; }

.store-card-active   { border-color: rgba(34,197,94,.3) !important; }
.store-card-inactive { border-color: rgba(245,158,11,.25); }
.store-badge-inactive { background: rgba(245,158,11,.12); border: 1px solid rgba(245,158,11,.3); color: #fbbf24; font-size: .72rem; font-weight: 600; padding: 2px 8px; border-radius: 999px; white-space: nowrap; }

.nodes-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 1rem; }
.node-card { background: var(--bg-2); border: 1px solid var(--border); border-radius: var(--radius); padding: 1.2rem; }
.node-online  { border-color: rgba(34,197,94,.2); }
.node-offline { border-color: rgba(239,68,68,.15); opacity: .75; }
.node-card-header { display: flex; align-items: center; gap: .6rem; margin-bottom: 1rem; }
.node-card-header h3 { flex: 1; font-size: .95rem; font-weight: 600; }
.node-status-dot { width: 8px; height: 8px; border-radius: 50%; flex-shrink: 0; }
.dot-online  { background: var(--primary); box-shadow: 0 0 8px var(--primary); animation: pulse 2s infinite; }
.dot-offline { background: var(--danger); }
.node-status-text { font-size: .8rem; font-weight: 600; }
.node-online  .node-status-text { color: var(--primary); }
.node-offline .node-status-text { color: var(--danger); }
.node-info { margin-bottom: 1rem; }
.node-load-bar { height: 6px; background: var(--bg-3); border-radius: 999px; overflow: hidden; margin-bottom: .3rem; }
.node-load-fill { height: 100%; background: linear-gradient(90deg, var(--primary), #86efac); border-radius: 999px; transition: width .4s; }
.node-load-label { font-size: .78rem; color: var(--text-muted); }

.text-muted { color: var(--text-muted); font-size: .875rem; }

.module-status-badge { display: inline-flex; align-items: center; gap: .35rem; padding: 3px 10px; border-radius: 999px; font-size: .78rem; font-weight: 600; }
.module-status-badge.status-active   { background: rgba(34,197,94,.1);  border: 1px solid rgba(34,197,94,.25); color: #4ade80; }
.module-status-badge.status-inactive { background: rgba(107,114,128,.1); border: 1px solid var(--border); color: var(--text-muted); }
.status-dot-active { width: 6px; height: 6px; border-radius: 50%; background: var(--primary); animation: pulse 2s infinite; }

.color-field { display: flex; align-items: center; gap: .75rem; }
.color-picker { width: 48px; height: 36px; padding: 2px; border-radius: 8px; border: 1px solid var(--border); background: var(--bg-3); cursor: pointer; }
.color-picker::-webkit-color-swatch-wrapper { padding: 0; border-radius: 6px; }
.color-picker::-webkit-color-swatch { border: none; border-radius: 6px; }
.color-preview-hex { font-family: monospace; font-size: .85rem; color: var(--text-muted); }

.required-star { color: var(--danger); margin-left: .2rem; }

.module-config-layout { display: grid; grid-template-columns: 1fr 280px; gap: 1.5rem; align-items: start; }
.module-config-form { margin-bottom: 0; }
.module-config-sidebar { position: sticky; top: 1.5rem; }

.placeholder-list { display: flex; flex-direction: column; gap: .6rem; }
.placeholder-row { display: flex; align-items: baseline; justify-content: space-between; gap: .5rem; font-size: .82rem; }
.placeholder-row code { font-size: .78rem; white-space: nowrap; }
.placeholder-row span { color: var(--text-muted); text-align: right; }

.module-action-bar { display: flex; align-items: center; justify-content: space-between; gap: 1rem; padding-top: 1rem; border-top: 1px solid var(--border); flex-wrap: wrap; }

button:disabled { opacity: .35; cursor: not-allowed; transform: none !important; }

.breadcrumb-link { display: inline-block; font-size: .85rem; color: var(--text-muted); margin-bottom: .3rem; }
.breadcrumb-link:hover { color: var(--text); }

.how-to-token { background: var(--bg-3); border: 1px solid var(--border); border-radius: 8px; padding: 1rem 1.2rem; font-size: .85rem; }
.how-to-token h3 { font-size: .9rem; margin-bottom: .6rem; color: var(--text-muted); }
.how-to-token ol { padding-left: 1.2rem; color: var(--text-muted); }
.how-to-token li { margin-bottom: .3rem; }
.how-to-token strong { color: var(--text); }

.installed-modules-list { display: flex; flex-direction: column; gap: .5rem; }
.installed-module-row { display: flex; align-items: center; justify-content: space-between; padding: .4rem 0; }

.toggle-label { display: flex; align-items: center; justify-content: space-between; cursor: pointer; padding: .4rem 0; }
.toggle-switch { position: relative; flex-shrink: 0; display: flex; align-items: center; }
.toggle-switch input[type="checkbox"] { display: none; }
.toggle-slider {
    display: block; width: 44px; height: 24px;
    background: var(--bg-3); border: 1px solid var(--border);
    border-radius: 999px; cursor: pointer; position: relative; transition: background .2s, border-color .2s;
}
.toggle-slider::after { content: ''; position: absolute; width: 16px; height: 16px; border-radius: 50%; background: white; top: 3px; left: 3px; transition: transform .2s; }
.toggle-switch input[type="checkbox"]:checked ~ .toggle-slider { background: var(--primary); border-color: var(--primary); }
.toggle-switch input[type="checkbox"]:checked ~ .toggle-slider::after { transform: translateX(20px); }

.form-textarea {
    background: var(--bg-3); border: 1px solid var(--border); color: var(--text);
    padding: .6rem .9rem; border-radius: 8px; font-size: .9rem; width: 100%;
    resize: vertical; min-height: 80px; font-family: inherit;
    transition: border-color .15s, box-shadow .15s;
}
.form-textarea:focus { outline: none; border-color: rgba(34,197,94,0.5); box-shadow: 0 0 0 3px rgba(34,197,94,0.08); }

.admin-table-wrap { overflow-x: auto; }
.admin-table { width: 100%; border-collapse: collapse; font-size: .875rem; }
.admin-table th { text-align: left; padding: .6rem .8rem; border-bottom: 1px solid var(--border); color: var(--text-muted); font-weight: 600; font-size: .8rem; text-transform: uppercase; letter-spacing: .04em; }
.admin-table td { padding: .75rem .8rem; border-bottom: 1px solid rgba(255,255,255,.03); vertical-align: middle; }
.admin-table tr:last-child td { border-bottom: none; }
.admin-table tr:hover td { background: rgba(255,255,255,.02); }

@media (max-width: 768px) {
    .sidebar { transform: translateX(-100%); }
    .sidebar.open { transform: translateX(0); }
    .sidebar-toggle { display: flex; }
    .mobile-topbar { display: flex; }
    .dashboard-main { margin-left: 0; padding: 1rem; max-width: 100vw; }
    .module-config-layout { grid-template-columns: 1fr; }
    .grid-2 { grid-template-columns: 1fr; }
    .page-header { flex-direction: column; align-items: stretch; }
    .nav-links a:not(.btn) { display: none; }
    .store-grid { grid-template-columns: repeat(auto-fill, minmax(min(260px, 100%), 1fr)); }
    .bots-grid { grid-template-columns: 1fr; }
}

@media (max-width: 500px) {
    .store-grid { grid-template-columns: 1fr; }
    .stats-grid { grid-template-columns: 1fr; }
    .inline-form { flex-direction: column; align-items: flex-start; }
    .inline-form .select { width: 100%; }
    .store-card-footer { flex-direction: column; align-items: flex-start; }
}
