/* ============================================
   Null Bot - Combined Styles
   ============================================ */

/* ---------- CSS Variables ---------- */
:root {
    /* Backgrounds */
    --bg-primary: #07070a;
    --bg-secondary: #0d0d12;
    --bg-tertiary: #151519;
    --bg-card: #0f0f14;
    --bg-sidebar: #0a0a0f;

    /* Borders */
    --border: #1f1f2a;
    --border-active: #2d2d3d;

    /* Text */
    --text-primary: #e8e8ec;
    --text-secondary: #8888a0;
    --text-muted: #505068;

    /* Accent Colors */
    --accent: #00ffa3;
    --accent-dim: #00ffa315;
    --accent-glow: #00ffa340;
    --purple: #bf5af2;
    --purple-dim: #bf5af215;
    --red: #ff453a;
    --red-dim: #ff453a15;
    --orange: #ff9f0a;
    --orange-dim: #ff9f0a15;
    --yellow: #fbbf24;
    --yellow-dim: #fbbf2415;
    --blue: #0a84ff;

    --sidebar-width: 260px;
}

/* ---------- Base Reset (Layered for Tailwind v4 compat) ---------- */
@layer base {
    *,
    *::before,
    *::after {
        box-sizing: border-box;
    }

    * {
        margin: 0;
        padding: 0;
    }

    html {
        font-size: 16px;
        -webkit-font-smoothing: antialiased;
        -moz-osx-font-smoothing: grayscale;
    }

    body {
        font-family: 'Space Grotesk', -apple-system, BlinkMacSystemFont, sans-serif;
        background: var(--bg-primary);
        color: var(--text-primary);
        min-height: 100vh;
        line-height: 1.6;
    }

    input,
    select,
    button,
    textarea {
        font-family: inherit;
    }
}

/* ---------- Background Effects ---------- */
.bg-grid {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image:
        linear-gradient(var(--border) 1px, transparent 1px),
        linear-gradient(90deg, var(--border) 1px, transparent 1px);
    background-size: 60px 60px;
    opacity: 0.3;
    pointer-events: none;
    z-index: 0;
}

/* ---------- App Layout (Sidebar + Main) ---------- */
.app-layout {
    display: grid;
    grid-template-columns: var(--sidebar-width) 1fr;
    min-height: 100vh;
    position: relative;
    z-index: 1;
}

/* ---------- Sidebar ---------- */
.sidebar {
    background: var(--bg-sidebar);
    border-right: 1px solid var(--border);
    display: flex;
    flex-direction: column;
    height: 100vh;
    position: sticky;
    top: 0;
    overflow-y: auto;
}

.sidebar-brand {
    padding: 24px 20px 20px;
    border-bottom: 1px solid var(--border);
}

.sidebar-brand h1 {
    font-size: 22px;
    font-weight: 700;
    letter-spacing: -0.5px;
    background: linear-gradient(135deg, var(--text-primary) 0%, var(--accent) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 4px;
}

.sidebar-version {
    font-size: 11px;
    color: var(--text-muted);
    font-family: 'JetBrains Mono', monospace;
}

.sidebar-nav {
    flex: 1;
    padding: 12px 10px;
}

.sidebar-section-label {
    font-size: 10px;
    font-weight: 600;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 1px;
    padding: 12px 10px 6px;
}

.nav-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 14px;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.15s;
    border: none;
    background: transparent;
    width: 100%;
    text-align: left;
    color: var(--text-secondary);
    font-size: 14px;
    font-weight: 500;
    font-family: inherit;
}

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

.nav-item.active {
    background: var(--accent-dim);
    color: var(--accent);
}

.nav-icon {
    width: 20px;
    text-align: center;
    font-size: 15px;
    flex-shrink: 0;
}

.nav-label {
    flex: 1;
}

.nav-badge {
    font-size: 10px;
    font-weight: 600;
    padding: 2px 7px;
    border-radius: 10px;
    text-transform: uppercase;
    letter-spacing: 0.3px;
}

.nav-badge.live {
    background: var(--accent-dim);
    color: var(--accent);
}

.nav-badge.idle {
    background: var(--bg-tertiary);
    color: var(--text-muted);
}

.nav-badge.new {
    background: var(--purple-dim);
    color: var(--purple);
}

/* Sidebar Footer (wallet + settings) */
.sidebar-footer {
    padding: 12px;
    border-top: 1px solid var(--border);
}

.sidebar-wallet-header {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 12px;
    background: var(--bg-tertiary);
    border: 1px solid var(--border);
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.15s;
}

.sidebar-wallet-header:hover {
    border-color: var(--border-active);
}

.sidebar-wallet-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--red);
    flex-shrink: 0;
}

.sidebar-wallet-dot.connected {
    background: var(--accent);
    box-shadow: 0 0 8px var(--accent-glow);
}

.sidebar-wallet-info {
    flex: 1;
    min-width: 0;
}

.sidebar-wallet-addr {
    font-family: 'JetBrains Mono', monospace;
    font-size: 12px;
    color: var(--text-primary);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.sidebar-wallet-bal {
    font-family: 'JetBrains Mono', monospace;
    font-size: 11px;
    color: var(--accent);
}

/* Expandable wallet details */
.sidebar-wallet-details {
    display: none;
    padding: 10px;
    margin-top: 6px;
    background: var(--bg-tertiary);
    border: 1px solid var(--border);
    border-radius: 8px;
}

.sidebar-wallet-details.active {
    display: block;
}

.sidebar-wallet-full-addr {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 6px 8px;
    background: var(--bg-primary);
    border: 1px solid var(--border);
    border-radius: 6px;
    margin-bottom: 8px;
}

.sidebar-wallet-full-addr code {
    flex: 1;
    font-family: 'JetBrains Mono', monospace;
    font-size: 10px;
    color: var(--accent);
    word-break: break-all;
    line-height: 1.4;
}

.sidebar-wallet-actions {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4px;
}

.sidebar-wallet-actions .btn {
    font-size: 11px;
    padding: 6px 4px;
    text-align: center;
    white-space: nowrap;
}

.sidebar-wallet-details .private-key-section {
    margin-top: 8px;
}

.sidebar-wallet-details .private-key-display {
    font-size: 9px;
    padding: 6px 8px;
    background: var(--bg-primary);
    border: 1px solid var(--border);
    border-radius: 6px;
    word-break: break-all;
    color: var(--orange);
    font-family: 'JetBrains Mono', monospace;
    line-height: 1.4;
}

.btn-xs {
    font-size: 11px !important;
    padding: 5px 8px !important;
}

.sidebar-backup-section {
    margin-top: 8px;
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.sidebar-backup-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4px;
}

.btn-backup {
    background: var(--blue);
    color: white;
    border-color: var(--blue);
}

.btn-backup:hover:not(:disabled) {
    opacity: 0.85;
}

.sidebar-backup-status {
    font-size: 10px;
    color: var(--text-muted);
    text-align: center;
    min-height: 14px;
}

.sidebar-api-key {
    margin-top: 8px;
    display: flex;
    align-items: center;
    gap: 6px;
}

.sidebar-api-key input {
    flex: 1;
    padding: 6px 10px;
    background: var(--bg-tertiary);
    border: 1px solid var(--border);
    border-radius: 6px;
    color: var(--text-primary);
    font-family: 'JetBrains Mono', monospace;
    font-size: 11px;
}

.sidebar-api-key input:focus {
    outline: none;
    border-color: var(--accent);
}

.sidebar-api-key label {
    font-size: 10px;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0;
    margin-bottom: 0;
}

/* Mobile hamburger */
.sidebar-toggle {
    display: none;
    position: fixed;
    top: 12px;
    left: 12px;
    z-index: 100;
    padding: 8px 12px;
    background: var(--bg-secondary);
    border: 1px solid var(--border);
    border-radius: 8px;
    color: var(--text-primary);
    font-size: 18px;
    cursor: pointer;
}

/* ---------- Main Content ---------- */
.main-content {
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    overflow-x: hidden;
}

/* ---------- Top Stats Bar ---------- */
.top-stats-bar {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 12px;
    padding: 16px 24px;
    border-bottom: 1px solid var(--border);
    background: var(--bg-secondary);
}

.top-stat {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.top-stat-label {
    font-size: 10px;
    font-weight: 600;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.top-stat-value {
    font-family: 'JetBrains Mono', monospace;
    font-size: 16px;
    font-weight: 600;
    color: var(--accent);
}

.top-stat-value.orange { color: var(--orange); }
.top-stat-value.purple { color: var(--purple); }

/* ---------- Content Area ---------- */
.content-area {
    flex: 1;
    padding: 24px;
    max-width: 1200px;
    margin: 0 auto;
    width: 100%;
}

/* ---------- Legacy: container (removed, kept as safety) ---------- */
.container {
    max-width: 1200px;
    padding: 24px;
    position: relative;
    z-index: 1;
}

.main-grid {
    display: grid;
    grid-template-columns: 1fr 340px;
    gap: 20px;
}

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

/* ---------- Header (hidden in sidebar layout, kept for compat) ---------- */
header {
    text-align: center;
    margin-bottom: 40px;
    display: none;
}

h1 {
    font-size: 36px;
    font-weight: 700;
    letter-spacing: -1px;
    margin-bottom: 8px;
    background: linear-gradient(135deg, var(--text-primary) 0%, var(--accent) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.subtitle {
    color: var(--text-secondary);
    font-size: 15px;
}

/* ---------- Settings Bar (moved to sidebar footer) ---------- */
.settings-bar {
    display: none;
}

/* ---------- Badges ---------- */
.badge-row {
    display: flex;
    justify-content: center;
    gap: 8px;
    margin-bottom: 16px;
}

.badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 5px 10px;
    background: var(--purple-dim);
    border: 1px solid var(--purple);
    border-radius: 6px;
    font-size: 11px;
    font-weight: 600;
    color: var(--purple);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.badge.devnet {
    background: var(--orange-dim);
    border-color: var(--orange);
    color: var(--orange);
}

.badge.mainnet {
    background: var(--accent-dim);
    border-color: var(--accent);
    color: var(--accent);
}

.badge::before {
    content: '';
    width: 6px;
    height: 6px;
    background: currentColor;
    border-radius: 50%;
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.4; }
}

/* ---------- Tabs (hidden — sidebar nav replaces them) ---------- */
.tabs {
    display: none;
}

.tab-btn {
    flex: 1;
    padding: 12px 20px;
    background: transparent;
    border: none;
    border-radius: 8px;
    color: var(--text-muted);
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.15s;
}

.tab-content {
    display: none;
}

.tab-content.active {
    display: block;
}

/* ---------- Cards ---------- */
.card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 24px;
    margin-bottom: 20px;
}

.card-header {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 20px;
}

.card-title {
    font-size: 13px;
    font-weight: 600;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 1px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.card-title::before {
    content: '';
    width: 3px;
    height: 14px;
    background: var(--accent);
    border-radius: 2px;
}

.step-number {
    width: 28px;
    height: 28px;
    background: var(--accent-dim);
    border: 1px solid var(--accent);
    border-radius: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: 'JetBrains Mono', monospace;
    font-weight: 600;
    font-size: 13px;
    color: var(--accent);
}

/* ---------- Wallet Bar (in-page version, now inside sidebar) ---------- */
.wallet-bar {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px 14px;
    background: var(--bg-tertiary);
    border: 1px solid var(--border);
    border-radius: 8px;
    margin-bottom: 18px;
}

.wallet-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--red);
    flex-shrink: 0;
}

.wallet-dot.connected {
    background: var(--accent);
    box-shadow: 0 0 8px var(--accent-glow);
}

.wallet-addr {
    flex: 1;
    font-family: 'JetBrains Mono', monospace;
    font-size: 13px;
    color: var(--text-muted);
}

.wallet-addr.connected {
    color: var(--text-primary);
}

.wallet-bal {
    font-family: 'JetBrains Mono', monospace;
    font-size: 13px;
    color: var(--accent);
}

.btn-icon {
    padding: 6px 12px;
    background: var(--bg-tertiary);
    border: 1px solid var(--border);
    border-radius: 6px;
    color: var(--text-secondary);
    font-size: 11px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.15s;
}

.btn-icon:hover {
    background: var(--border);
    color: var(--text-primary);
}

/* ---------- Legacy wallet panel (removed - now in sidebar) ---------- */

/* ---------- Forms ---------- */
.form-group {
    margin-bottom: 18px;
}

label {
    display: block;
    font-size: 12px;
    font-weight: 500;
    color: var(--text-secondary);
    margin-bottom: 6px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

input,
select,
textarea {
    width: 100%;
    padding: 12px 14px;
    background: var(--bg-tertiary);
    border: 1px solid var(--border);
    border-radius: 8px;
    color: var(--text-primary);
    font-family: 'JetBrains Mono', monospace;
    font-size: 14px;
    transition: all 0.15s;
}

input:focus,
select:focus,
textarea:focus {
    outline: none;
    border-color: var(--accent);
    box-shadow: 0 0 0 3px var(--accent-dim);
}

input::placeholder,
textarea::placeholder {
    color: var(--text-muted);
}

.input-hint {
    font-size: 11px;
    color: var(--text-muted);
    margin-top: 4px;
}

.input-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
}

.input-suffix {
    position: relative;
}

.input-suffix input {
    padding-right: 50px;
}

.input-suffix span {
    position: absolute;
    right: 14px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-muted);
    font-family: 'JetBrains Mono', monospace;
    font-size: 12px;
}

/* Range Slider */
.range-group {
    display: flex;
    align-items: center;
    gap: 12px;
}

.range-group input[type="range"] {
    flex: 1;
    -webkit-appearance: none;
    height: 6px;
    background: var(--border);
    border-radius: 3px;
    border: none;
    padding: 0;
}

.range-group input[type="range"]::-webkit-slider-thumb {
    -webkit-appearance: none;
    width: 18px;
    height: 18px;
    background: var(--accent);
    border-radius: 50%;
    cursor: pointer;
    box-shadow: 0 0 10px var(--accent-glow);
}

.range-value {
    font-family: 'JetBrains Mono', monospace;
    font-size: 14px;
    color: var(--accent);
    min-width: 40px;
    text-align: right;
}

/* ---------- Buttons ---------- */
.btn {
    width: 100%;
    padding: 14px 20px;
    border: none;
    border-radius: 8px;
    font-family: 'Space Grotesk', sans-serif;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.15s;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.btn-primary {
    background: var(--accent);
    color: var(--bg-primary);
}

.btn-primary:hover:not(:disabled) {
    filter: brightness(1.1);
    transform: translateY(-1px);
}

.btn-primary:disabled {
    opacity: 0.4;
    cursor: not-allowed;
}

.btn-accent {
    background: var(--accent-dim);
    color: var(--accent);
}

.btn-accent:hover:not(:disabled) {
    background: var(--accent);
    color: var(--bg-primary);
}

.btn-danger {
    background: var(--red-dim);
    color: var(--red);
    border: 1px solid var(--red);
}

.btn-danger:hover:not(:disabled) {
    background: var(--red);
    color: white;
}

.btn-stop {
    background: var(--red);
    color: white;
}

.btn-stop:hover {
    filter: brightness(1.1);
}

.btn-secondary,
.btn-outline {
    background: transparent;
    color: var(--text-secondary);
    border: 1px solid var(--border);
}

.btn-outline:hover,
.btn-secondary:hover {
    border-color: var(--text-secondary);
    color: var(--text-primary);
}

.btn-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
    margin-top: 16px;
}

/* ---------- Warning Box ---------- */
.warning-box {
    background: var(--yellow-dim);
    border: 1px solid var(--yellow);
    border-radius: 8px;
    padding: 14px;
    margin-bottom: 16px;
    display: flex;
    gap: 10px;
    align-items: flex-start;
}

.warning-icon {
    color: var(--yellow);
    font-size: 16px;
    flex-shrink: 0;
}

.warning-text {
    font-size: 12px;
    color: var(--yellow);
    line-height: 1.5;
}

.warning-text strong {
    font-weight: 600;
}

/* ---------- Progress & Status ---------- */
.status-panel {
    background: var(--bg-tertiary);
    border-radius: 8px;
    padding: 14px;
    margin-top: 16px;
    display: none;
}

.status-panel.active {
    display: block;
}

.status-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 10px;
}

.status-title {
    font-size: 12px;
    font-weight: 500;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.status-count {
    font-family: 'JetBrains Mono', monospace;
    font-size: 12px;
    color: var(--accent);
}

.progress-bar {
    height: 4px;
    background: var(--border);
    border-radius: 2px;
    overflow: hidden;
    margin-bottom: 12px;
}

.progress-fill {
    height: 100%;
    background: var(--accent);
    border-radius: 2px;
    transition: width 0.3s;
    width: 0%;
}

/* ---------- Log Area ---------- */
.log-area {
    font-family: 'JetBrains Mono', monospace;
    font-size: 11px;
    background: var(--bg-primary);
    border-radius: 6px;
    padding: 10px;
    max-height: 180px;
    overflow-y: auto;
    line-height: 1.8;
}

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

.log-entry.success {
    color: var(--accent);
}

.log-entry.error {
    color: var(--red);
}

.log-entry.warning {
    color: var(--yellow);
}

/* ---------- Stats Grid ---------- */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
    margin-top: 16px;
}

.stat-box {
    background: var(--bg-tertiary);
    border-radius: 8px;
    padding: 14px;
    text-align: center;
}

.stat-value {
    font-family: 'JetBrains Mono', monospace;
    font-size: 20px;
    font-weight: 600;
    color: var(--accent);
    margin-bottom: 2px;
}

.stat-label {
    font-size: 11px;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* Live Stats Panel */
.stats-panel {
    margin-bottom: 20px;
}

.stats-row {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
}

.stat-card {
    background: var(--bg-tertiary);
    border-radius: 8px;
    padding: 14px;
}

.stat-value.green { color: var(--accent); }
.stat-value.orange { color: var(--orange); }
.stat-value.purple { color: var(--purple); }
.stat-value.red { color: var(--red); }

/* ---------- Activity Feed ---------- */
.feed {
    background: var(--bg-primary);
    border: 1px solid var(--border);
    border-radius: 8px;
    height: 300px;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.feed-header {
    padding: 10px 14px;
    border-bottom: 1px solid var(--border);
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.feed-title {
    font-size: 12px;
    font-weight: 500;
    color: var(--text-secondary);
}

.feed-status {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 11px;
    color: var(--text-muted);
}

.feed-status.running {
    color: var(--accent);
}

.feed-status .dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: currentColor;
    animation: blink 1s infinite;
}

.feed-status .dot.warning {
    background: #f59e0b;
    animation: none;
}

@keyframes blink {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.3; }
}

.feed-content {
    flex: 1;
    overflow-y: auto;
    padding: 8px;
    font-family: 'JetBrains Mono', monospace;
    font-size: 11px;
    line-height: 1.8;
}

.feed-entry {
    padding: 4px 8px;
    border-radius: 4px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.feed-entry:hover {
    background: var(--bg-tertiary);
}

.feed-time {
    color: var(--text-muted);
    min-width: 65px;
}

.feed-type {
    padding: 2px 6px;
    border-radius: 4px;
    font-size: 10px;
    font-weight: 600;
    text-transform: uppercase;
}

.feed-type.buy {
    background: var(--accent-dim);
    color: var(--accent);
}

.feed-type.sell {
    background: var(--red-dim);
    color: var(--red);
}

.feed-type.setup {
    background: var(--purple-dim);
    color: var(--purple);
}

.feed-msg {
    color: var(--text-secondary);
    flex: 1;
}

.feed-amount {
    color: var(--text-primary);
}

.feed-sig {
    font-family: 'SF Mono', monospace;
    font-size: 10px;
    color: var(--accent);
    text-decoration: none;
    opacity: 0.7;
    transition: opacity 0.2s;
}

.feed-sig:hover {
    opacity: 1;
    text-decoration: underline;
}

/* ---------- Wallet Grid ---------- */
.wallets-grid {
    display: grid;
    grid-template-columns: repeat(10, 1fr);
    gap: 4px;
    margin-top: 12px;
}

.wallet-cell {
    aspect-ratio: 1;
    background: var(--border);
    border-radius: 3px;
    transition: all 0.2s;
}

.wallet-cell.active {
    background: var(--accent);
    box-shadow: 0 0 8px var(--accent-glow);
}

.wallet-cell.has-tokens {
    background: var(--purple);
}

/* ---------- Info Box ---------- */
.info-box {
    background: var(--bg-tertiary);
    border-radius: 8px;
    padding: 14px;
    margin-top: 16px;
}

.info-box h4 {
    font-size: 12px;
    font-weight: 600;
    color: var(--text-secondary);
    margin-bottom: 8px;
}

.info-box p {
    font-size: 12px;
    color: var(--text-muted);
    line-height: 1.6;
}

.info-box code {
    background: var(--bg-primary);
    padding: 2px 6px;
    border-radius: 4px;
    font-family: 'JetBrains Mono', monospace;
    font-size: 11px;
    color: var(--purple);
}

/* ---------- Token Creation Form ---------- */
.image-upload {
    border: 2px dashed var(--border);
    border-radius: 8px;
    padding: 24px;
    text-align: center;
    cursor: pointer;
    transition: all 0.15s;
}

.image-upload:hover {
    border-color: var(--accent);
    background: var(--accent-dim);
}

.image-upload.has-image {
    border-style: solid;
    border-color: var(--accent);
}

.image-upload input {
    display: none;
}

.image-upload-icon {
    font-size: 32px;
    color: var(--text-muted);
    margin-bottom: 8px;
}

.image-upload-text {
    font-size: 13px;
    color: var(--text-secondary);
}

.image-preview {
    width: 80px;
    height: 80px;
    object-fit: cover;
    border-radius: 8px;
    margin: 0 auto;
}

/* Optional Fields Toggle */
.optional-toggle {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 0;
    cursor: pointer;
    color: var(--text-secondary);
    font-size: 13px;
}

.optional-toggle:hover {
    color: var(--text-primary);
}

.optional-fields {
    display: none;
    padding-top: 8px;
}

.optional-fields.open {
    display: block;
}

/* ---------- Confirmation Modal ---------- */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.8);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    opacity: 0;
    visibility: hidden;
    transition: all 0.2s;
}

.modal-overlay.active {
    opacity: 1;
    visibility: visible;
}

.modal {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 24px;
    max-width: 400px;
    width: 90%;
}

.modal-title {
    font-size: 18px;
    font-weight: 600;
    margin-bottom: 12px;
}

.modal-body {
    color: var(--text-secondary);
    font-size: 14px;
    margin-bottom: 20px;
    line-height: 1.6;
}

.modal-amount {
    font-family: 'JetBrains Mono', monospace;
    font-size: 24px;
    color: var(--accent);
    margin: 16px 0;
}

.modal-buttons {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
}

/* ---------- Checklist ---------- */
.checklist {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.check-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 12px;
    background: var(--bg-tertiary);
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.15s;
}

.check-item:hover {
    background: var(--border);
}

.check-item input[type="checkbox"] {
    width: 18px;
    height: 18px;
    accent-color: var(--accent);
    cursor: pointer;
}

.check-item span {
    font-size: 13px;
    color: var(--text-secondary);
}

.check-item input:checked + span {
    color: var(--accent);
    text-decoration: line-through;
}

/* ---------- Toggle Switch ---------- */
.toggle-row {
    display: flex;
    align-items: center;
    gap: 12px;
}

.toggle-switch {
    position: relative;
    width: 44px;
    height: 24px;
    flex-shrink: 0;
}

.toggle-switch input {
    opacity: 0;
    width: 0;
    height: 0;
}

.toggle-slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: var(--border);
    border-radius: 24px;
    transition: 0.2s;
}

.toggle-slider::before {
    position: absolute;
    content: "";
    height: 18px;
    width: 18px;
    left: 3px;
    bottom: 3px;
    background: var(--text-muted);
    border-radius: 50%;
    transition: 0.2s;
}

.toggle-switch input:checked + .toggle-slider {
    background: var(--accent);
}

.toggle-switch input:checked + .toggle-slider::before {
    transform: translateX(20px);
    background: var(--bg-primary);
}

.toggle-info {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.toggle-label {
    font-size: 14px;
    font-weight: 500;
    color: var(--text-primary);
}

.toggle-desc {
    font-size: 12px;
    color: var(--text-muted);
}

/* Auto Config Panel */
.auto-config {
    margin-top: 12px;
    padding: 12px;
    background: var(--bg-primary);
    border-radius: 8px;
    border: 1px solid var(--border);
}

.auto-config .form-group {
    margin-bottom: 12px;
}

.auto-config .form-group:last-child {
    margin-bottom: 0;
}

.auto-config .input-row {
    margin-bottom: 12px;
}

.auto-config .input-row:last-child {
    margin-bottom: 0;
}

.cost-display {
    padding: 12px 14px;
    background: var(--bg-tertiary);
    border: 1px solid var(--border);
    border-radius: 8px;
    font-family: 'JetBrains Mono', monospace;
    font-size: 14px;
    color: var(--accent);
}

/* ---------- Utility Classes ---------- */
.hidden {
    display: none !important;
}

.text-accent { color: var(--accent); }
.text-red { color: var(--red); }
.text-orange { color: var(--orange); }
.text-muted { color: var(--text-muted); }

.mt-4 { margin-top: 16px; }
.mb-4 { margin-bottom: 16px; }

/* ---------- Responsive ---------- */
@media (max-width: 900px) {
    .app-layout {
        grid-template-columns: 1fr;
    }

    .sidebar {
        position: fixed;
        left: -280px;
        top: 0;
        width: 280px;
        z-index: 50;
        transition: left 0.3s;
    }

    .sidebar.open {
        left: 0;
    }

    .sidebar-toggle {
        display: block;
    }

    .sidebar-overlay {
        display: none;
        position: fixed;
        top: 0;
        left: 0;
        right: 0;
        bottom: 0;
        background: rgba(0,0,0,0.6);
        z-index: 49;
    }

    .sidebar-overlay.open {
        display: block;
    }

    .top-stats-bar {
        grid-template-columns: repeat(2, 1fr);
        padding: 12px 16px;
    }

    .content-area {
        padding: 16px;
    }
}

@media (max-width: 600px) {
    .input-row {
        grid-template-columns: 1fr;
    }

    .btn-row {
        grid-template-columns: 1fr;
    }

    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .wallets-grid {
        grid-template-columns: repeat(8, 1fr);
    }

    .top-stats-bar {
        grid-template-columns: 1fr 1fr;
        gap: 8px;
    }
}
