/* ── KijiAx Web Dashboard — Cosmic Premium Dark Theme ── */

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800&family=JetBrains+Mono:wght@400;500;600&display=swap');

:root {
    --bg-primary: #0a0a0f;
    --bg-secondary: #0d0d18;
    --bg-card: rgba(12, 12, 24, 0.85);
    --bg-card-solid: #10101e;
    --bg-hover: #1a1a32;
    --bg-input: #0a0a16;
    --border: rgba(255, 255, 255, 0.06);
    --border-glow: rgba(255, 80, 50, 0.2);
    --text-primary: #ebebf5;
    --text-secondary: #8888a8;
    --text-muted: #55557a;
    --accent: #ff5533;
    --accent-hover: #ff7755;
    --accent-secondary: #cc44ff;
    --gradient-primary: linear-gradient(135deg, #ff5533, #cc44ff);
    --gradient-subtle: linear-gradient(135deg, rgba(255,85,51,0.15), rgba(204,68,255,0.15));
    --gradient-glow: linear-gradient(135deg, rgba(255,85,51,0.4), rgba(204,68,255,0.4));
    --gradient-text: linear-gradient(135deg, #ff8855, #cc44ff);
    --success: #22c55e;
    --warning: #f59e0b;
    --error: #ef4444;
    --info: #7c5cff;
    --sidebar-width: 230px;
    --topbar-height: 56px;
    --radius: 10px;
    --radius-lg: 14px;
    --glass-blur: 20px;
    --shadow-glow: 0 0 30px rgba(255, 85, 51, 0.08);
}

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

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background: var(--bg-primary);
    color: var(--text-primary);
    font-size: 14px;
    line-height: 1.5;
}

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

/* ── Layout ── */

.app-layout {
    display: flex;
    min-height: 100vh;
    position: relative;
    background:
        radial-gradient(ellipse at 20% 0%, rgba(255, 85, 51, 0.06) 0%, transparent 50%),
        radial-gradient(ellipse at 80% 100%, rgba(204, 68, 255, 0.05) 0%, transparent 50%),
        radial-gradient(ellipse at 50% 50%, rgba(255, 60, 40, 0.02) 0%, transparent 60%),
        var(--bg-primary);
}

/* Floating cosmic orbs */
.app-layout::before,
.app-layout::after {
    content: '';
    position: fixed;
    border-radius: 50%;
    pointer-events: none;
    z-index: 0;
    filter: blur(80px);
}

.app-layout::before {
    width: 500px;
    height: 500px;
    top: -100px;
    right: 10%;
    background: radial-gradient(circle, rgba(255, 60, 40, 0.08) 0%, rgba(255, 85, 51, 0.03) 50%, transparent 70%);
    animation: floatOrb1 20s ease-in-out infinite;
}

.app-layout::after {
    width: 400px;
    height: 400px;
    bottom: -50px;
    left: 15%;
    background: radial-gradient(circle, rgba(180, 50, 255, 0.07) 0%, rgba(204, 68, 255, 0.02) 50%, transparent 70%);
    animation: floatOrb2 25s ease-in-out infinite;
}

/* ── Cosmic Particles ── */

.cosmic-particles {
    position: fixed;
    inset: 0;
    pointer-events: none;
    z-index: 0;
    overflow: hidden;
}

.cosmic-particles span {
    position: absolute;
    width: 2px;
    height: 2px;
    border-radius: 50%;
    background: rgba(255, 85, 51, 0.4);
    animation: particleDrift linear infinite;
    opacity: 0;
}

.cosmic-particles span:nth-child(1) { left: 10%; bottom: -10px; animation-duration: 18s; animation-delay: 0s; width: 3px; height: 3px; background: rgba(255, 85, 51, 0.5); }
.cosmic-particles span:nth-child(2) { left: 25%; bottom: -10px; animation-duration: 22s; animation-delay: 3s; background: rgba(204, 68, 255, 0.4); }
.cosmic-particles span:nth-child(3) { left: 40%; bottom: -10px; animation-duration: 16s; animation-delay: 1s; width: 3px; height: 3px; }
.cosmic-particles span:nth-child(4) { left: 55%; bottom: -10px; animation-duration: 20s; animation-delay: 5s; background: rgba(204, 68, 255, 0.5); }
.cosmic-particles span:nth-child(5) { left: 65%; bottom: -10px; animation-duration: 24s; animation-delay: 2s; }
.cosmic-particles span:nth-child(6) { left: 78%; bottom: -10px; animation-duration: 19s; animation-delay: 7s; background: rgba(204, 68, 255, 0.3); width: 3px; height: 3px; }
.cosmic-particles span:nth-child(7) { left: 88%; bottom: -10px; animation-duration: 21s; animation-delay: 4s; }
.cosmic-particles span:nth-child(8) { left: 48%; bottom: -10px; animation-duration: 26s; animation-delay: 8s; background: rgba(255, 120, 80, 0.3); }

.sidebar {
    width: var(--sidebar-width);
    background: var(--bg-secondary);
    border-right: 1px solid var(--border);
    display: flex;
    flex-direction: column;
    position: fixed;
    top: 0;
    left: 0;
    bottom: 0;
    z-index: 100;
    backdrop-filter: blur(20px);
}

.sidebar-brand {
    padding: 18px 16px;
    border-bottom: 1px solid var(--border);
    display: flex;
    align-items: center;
    gap: 10px;
}

.sidebar-logo {
    width: 40px;
    height: 40px;
    border-radius: 8px;
    object-fit: cover;
    filter: drop-shadow(0 0 8px rgba(255, 85, 51, 0.4));
}

.sidebar-brand h2 {
    font-size: 22px;
    font-weight: 800;
    letter-spacing: -0.5px;
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.sidebar-nav {
    flex: 1;
    padding: 10px 8px;
    overflow-y: auto;
}

.nav-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 14px;
    border-radius: 8px;
    color: var(--text-secondary);
    font-size: 13.5px;
    font-weight: 500;
    transition: all 0.2s;
}

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

.nav-item.active {
    background: linear-gradient(135deg, rgba(255, 85, 51, 0.15), rgba(204, 68, 255, 0.1));
    color: var(--accent);
    border: 1px solid rgba(255, 85, 51, 0.2);
}

.nav-icon { font-size: 8px; opacity: 0.4; }

.sidebar-footer {
    padding: 12px 16px;
    border-top: 1px solid var(--border);
    display: flex;
    align-items: center;
    gap: 8px;
}

.logout-link { color: var(--text-muted); font-size: 12px; }
.logout-link:hover { color: var(--error); }

.main-area {
    margin-left: var(--sidebar-width);
    flex: 1;
    display: flex;
    flex-direction: column;
    position: relative;
    z-index: 1;
}

.topbar {
    height: var(--topbar-height);
    padding: 0 24px;
    background: rgba(13, 13, 24, 0.8);
    backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--border);
    display: flex;
    align-items: center;
    justify-content: space-between;
    position: sticky;
    top: 0;
    z-index: 50;
}

.topbar h3 { font-size: 16px; font-weight: 600; }

.topbar-left { display: flex; align-items: center; gap: 12px; }
.topbar-right { display: flex; align-items: center; gap: 12px; }

.profile-selector {
    background: var(--bg-input);
    color: var(--text-primary);
    border: 1px solid var(--border);
    padding: 6px 12px;
    border-radius: var(--radius);
    font-size: 13px;
    font-family: inherit;
}

.content {
    padding: 24px;
    flex: 1;
}

/* ── Sync Status Indicator ── */

.sync-indicator {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 11px;
    font-weight: 600;
    letter-spacing: 0.3px;
    color: var(--text-secondary);
}

.sync-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--error);
    transition: background 0.3s;
}

.sync-dot.connected {
    background: var(--success);
    animation: syncPulse 2s ease-in-out infinite;
}

/* ── Auto-Save Indicator ── */

.auto-save-indicator {
    font-size: 11px;
    font-weight: 500;
    margin-left: 10px;
    transition: color 0.3s, opacity 0.3s;
}

.auto-save-indicator.saving {
    color: var(--warning);
}

.auto-save-indicator.saved {
    color: var(--success);
}

.auto-save-indicator.hidden {
    opacity: 0;
}

/* ── Page header ── */

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

.page-header h2 { font-size: 20px; font-weight: 700; }

/* ── Stats cards ── */

.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 16px;
    margin-bottom: 24px;
}

.stats-card {
    background: var(--bg-card);
    backdrop-filter: blur(var(--glass-blur));
    -webkit-backdrop-filter: blur(var(--glass-blur));
    border: 1px solid transparent;
    border-radius: var(--radius-lg);
    padding: 18px;
    position: relative;
    overflow: hidden;
    transition: all 0.3s ease;
}

/* Always-visible gradient border glow */
.stats-card::before {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: var(--radius-lg);
    padding: 1px;
    background: var(--gradient-primary);
    -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    -webkit-mask-composite: xor;
    mask-composite: exclude;
    opacity: 0.3;
    transition: opacity 0.3s;
    pointer-events: none;
}

.stats-card:hover::before { opacity: 0.8; }
.stats-card:hover { box-shadow: 0 0 40px rgba(255, 85, 51, 0.12); transform: translateY(-2px); }

.stats-card-icon {
    font-size: 18px;
    margin-bottom: 8px;
    opacity: 0.7;
}

.stats-card-label {
    font-size: 11px;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.8px;
    font-weight: 600;
    margin-bottom: 4px;
}

.stats-card-value {
    font-size: 28px;
    font-weight: 800;
    background: var(--gradient-text);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.stats-card-value.counting {
    animation: countPulse 0.4s ease-out;
}

.stats-card-subtitle {
    font-size: 11px;
    color: var(--text-secondary);
    margin-top: 4px;
}

/* ── Ring Chart (Success Rate) ── */

.ring-chart {
    display: flex;
    align-items: center;
    gap: 20px;
    padding: 8px 0;
}

.ring-chart svg {
    width: 100px;
    height: 100px;
    transform: rotate(-90deg);
}

.ring-chart-bg {
    fill: none;
    stroke: rgba(255, 255, 255, 0.06);
    stroke-width: 8;
}

.ring-chart-fill {
    fill: none;
    stroke: url(#ringGradient);
    stroke-width: 8;
    stroke-linecap: round;
    transition: stroke-dashoffset 1s ease-out;
}

.ring-chart-label {
    font-size: 13px;
    color: var(--text-secondary);
    line-height: 1.8;
}

.ring-chart-label strong {
    font-size: 22px;
    font-weight: 800;
    background: var(--gradient-text);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    display: block;
}

/* ── Quick Actions ── */

.quick-actions {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.quick-action-btn {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px 16px;
    background: var(--bg-input);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    color: var(--text-primary);
    font-size: 13px;
    font-weight: 500;
    font-family: inherit;
    cursor: pointer;
    transition: all 0.2s;
    text-decoration: none;
}

.quick-action-btn:hover {
    background: var(--bg-hover);
    border-color: var(--border-glow);
    color: var(--text-primary);
}

/* Premium locked button */
.quick-action-btn.locked {
    opacity: 0.6;
    cursor: not-allowed;
    position: relative;
}

.quick-action-btn.locked:hover {
    background: var(--bg-input);
    border-color: var(--border);
}

.lock-icon {
    font-size: 14px;
    margin-left: auto;
    opacity: 0.5;
}

.premium-tooltip {
    display: none;
    position: absolute;
    right: 10px;
    top: -30px;
    background: var(--bg-card-solid);
    border: 1px solid var(--border-glow);
    padding: 4px 10px;
    border-radius: 6px;
    font-size: 11px;
    color: var(--accent);
    white-space: nowrap;
    pointer-events: none;
}

.quick-action-btn.locked:hover .premium-tooltip {
    display: block;
}

/* ── Panels ── */

.panel {
    background: var(--bg-card);
    backdrop-filter: blur(var(--glass-blur));
    -webkit-backdrop-filter: blur(var(--glass-blur));
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 20px;
    margin-bottom: 16px;
}

.panel h4 {
    font-size: 14px;
    font-weight: 600;
    margin-bottom: 12px;
    color: var(--text-primary);
}

.dashboard-panels {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
}

.dashboard-top-panels {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    gap: 16px;
    margin-bottom: 16px;
}

.settings-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 16px;
}

/* ── Tables ── */

.data-table {
    width: 100%;
    border-collapse: collapse;
    background: var(--bg-card-solid);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    overflow: hidden;
}

.data-table thead { background: rgba(13, 13, 24, 0.9); }

.data-table th {
    padding: 10px 12px;
    text-align: left;
    font-size: 10px;
    font-weight: 700;
    text-transform: uppercase;
    color: var(--text-muted);
    letter-spacing: 0.8px;
    border-bottom: 1px solid var(--border);
}

.data-table td {
    padding: 10px 12px;
    font-size: 13px;
    border-bottom: 1px solid var(--border);
    color: var(--text-secondary);
}

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

/* ── Forms ── */

.form-card {
    background: var(--bg-card);
    backdrop-filter: blur(var(--glass-blur));
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 24px;
    max-width: 800px;
}

.form-row {
    display: flex;
    gap: 16px;
    margin-bottom: 16px;
}

.form-row .form-group { flex: 1; }

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

.form-group label {
    display: block;
    font-size: 12px;
    font-weight: 500;
    color: var(--text-secondary);
    margin-bottom: 4px;
}

.form-control {
    width: 100%;
    padding: 8px 12px;
    background: var(--bg-input);
    border: 1px solid var(--border);
    border-radius: 8px;
    color: var(--text-primary);
    font-size: 13px;
    font-family: inherit;
    transition: border-color 0.2s, box-shadow 0.2s;
}

.form-control:focus {
    outline: none;
    border-color: var(--accent);
    box-shadow: 0 0 0 3px rgba(255, 85, 51, 0.1);
}

textarea.form-control { resize: vertical; }

.form-actions {
    display: flex;
    gap: 8px;
    margin-top: 20px;
    padding-top: 16px;
    border-top: 1px solid var(--border);
}

/* ── Buttons ── */

.btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 8px 16px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: var(--bg-secondary);
    color: var(--text-primary);
    font-size: 13px;
    font-weight: 500;
    font-family: inherit;
    cursor: pointer;
    transition: all 0.2s;
}

.btn:hover { background: var(--bg-hover); }
.btn:disabled { opacity: 0.5; cursor: not-allowed; }

.btn-primary {
    background: var(--accent);
    border-color: var(--accent);
    color: #fff;
    box-shadow: 0 2px 8px rgba(255, 85, 51, 0.25);
}

.btn-primary:hover {
    background: var(--accent-hover);
    box-shadow: 0 4px 16px rgba(255, 85, 51, 0.35);
}

.btn-danger {
    background: transparent;
    border-color: var(--error);
    color: var(--error);
}

.btn-danger:hover { background: var(--error); color: #fff; }

.btn-secondary { background: var(--bg-card-solid); }

.btn-sm { padding: 4px 10px; font-size: 12px; }
.btn-block { width: 100%; justify-content: center; }

/* ── Filters ── */

.filters-bar {
    display: flex;
    gap: 12px;
    margin-bottom: 16px;
    flex-wrap: wrap;
}

.filter-search { max-width: 280px; }
.filter-select { max-width: 180px; }

/* ── Badges ── */

.badge {
    display: inline-block;
    padding: 2px 8px;
    border-radius: 10px;
    font-size: 11px;
    font-weight: 600;
}

.badge-active, .badge-posted, .badge-success { background: rgba(34, 197, 94, 0.12); color: var(--success); }
.badge-suspended, .badge-warning, .badge-scheduled { background: rgba(245, 158, 11, 0.12); color: var(--warning); }
.badge-banned, .badge-failed, .badge-error, .badge-danger { background: rgba(239, 68, 68, 0.12); color: var(--error); }
.badge-inactive, .badge-draft, .badge-default { background: rgba(139, 143, 163, 0.12); color: var(--text-secondary); }
.badge-needsverification, .badge-info { background: rgba(124, 92, 255, 0.12); color: var(--info); }
.badge-category { background: rgba(255, 85, 51, 0.12); color: var(--accent); }
.badge-expired, .badge-deleted { background: rgba(239, 68, 68, 0.08); color: #f87171; }

/* ── Tier badges ── */

.tier-badge {
    padding: 2px 8px;
    border-radius: 10px;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
}

.tier-premium, .tier-full { background: rgba(255, 85, 51, 0.15); color: var(--accent); }
.tier-lite { background: rgba(245, 158, 11, 0.15); color: var(--warning); }
.tier-free { background: rgba(139, 143, 163, 0.15); color: var(--text-secondary); }

/* ── Pagination ── */

.pagination {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    margin-top: 16px;
    padding: 12px 0;
}

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

/* ── Logs ── */

.log-list { display: flex; flex-direction: column; gap: 4px; }

.log-entry {
    display: flex;
    gap: 10px;
    padding: 6px 10px;
    border-radius: 4px;
    font-size: 12px;
    font-family: 'JetBrains Mono', monospace;
}

.log-time { color: var(--text-muted); min-width: 45px; }
.log-level { min-width: 55px; font-weight: 600; }
.log-message { color: var(--text-secondary); flex: 1; }

.log-entry.log-error .log-level { color: var(--error); }
.log-entry.log-warning .log-level { color: var(--warning); }
.log-entry.log-success .log-level { color: var(--success); }
.log-entry.log-info .log-level { color: var(--info); }

.log-row.log-error { background: rgba(239, 68, 68, 0.04); }

/* ── Empty state ── */

.empty-state {
    text-align: center;
    padding: 40px 20px;
    color: var(--text-muted);
    font-size: 14px;
}

/* ── Modal / Dialog ── */

.modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(4px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
}

.modal-dialog {
    background: var(--bg-card-solid);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 24px;
    min-width: 360px;
    max-width: 480px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
}

.modal-dialog h4 { margin-bottom: 8px; }
.modal-dialog p { color: var(--text-secondary); margin-bottom: 20px; }
.modal-actions { display: flex; justify-content: flex-end; gap: 8px; }

/* ── Bulk action bar ── */

.bulk-action-bar {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 16px;
    background: var(--accent);
    border-radius: var(--radius);
    margin-bottom: 12px;
    color: #fff;
    font-size: 13px;
}

/* ── Bulk paste panel ── */

.bulk-paste-panel { margin-bottom: 16px; }
.bulk-message { margin-left: 12px; font-size: 13px; color: var(--success); }

/* ── Settings ── */

.setting-row {
    display: flex;
    gap: 8px;
    padding: 6px 0;
    font-size: 13px;
    color: var(--text-secondary);
}

.setting-row span:first-child {
    color: var(--text-muted);
    min-width: 80px;
}

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

code {
    background: var(--bg-input);
    padding: 2px 6px;
    border-radius: 4px;
    font-size: 12px;
    color: var(--accent);
    font-family: 'JetBrains Mono', monospace;
}

/* ── Alerts ── */

.alert {
    padding: 10px 14px;
    border-radius: 8px;
    font-size: 13px;
}

.alert-error {
    background: rgba(239, 68, 68, 0.1);
    border: 1px solid rgba(239, 68, 68, 0.2);
    color: var(--error);
}

.alert-success {
    background: rgba(34, 197, 94, 0.1);
    border: 1px solid rgba(34, 197, 94, 0.2);
    color: var(--success);
}

/* ── Login page ── */

.login-body {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 100vh;
    position: relative;
    overflow: hidden;
    background:
        radial-gradient(ellipse at 25% 15%, rgba(255, 85, 51, 0.12) 0%, transparent 50%),
        radial-gradient(ellipse at 75% 85%, rgba(204, 68, 255, 0.10) 0%, transparent 50%),
        radial-gradient(circle at 50% 50%, rgba(255, 60, 40, 0.04) 0%, transparent 60%),
        var(--bg-primary);
}

/* Login page floating orbs */
.login-body::before,
.login-body::after {
    content: '';
    position: absolute;
    border-radius: 50%;
    pointer-events: none;
    filter: blur(80px);
}

.login-body::before {
    width: 400px;
    height: 400px;
    top: -80px;
    right: 15%;
    background: radial-gradient(circle, rgba(255, 60, 40, 0.12) 0%, transparent 70%);
    animation: floatOrb1 18s ease-in-out infinite;
}

.login-body::after {
    width: 350px;
    height: 350px;
    bottom: -60px;
    left: 20%;
    background: radial-gradient(circle, rgba(180, 50, 255, 0.10) 0%, transparent 70%);
    animation: floatOrb2 22s ease-in-out infinite;
}

.login-container {
    width: 100%;
    max-width: 420px;
    padding: 20px;
    position: relative;
    z-index: 1;
}

.login-card {
    background: var(--bg-card);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.06);
    border-radius: 16px;
    padding: 36px;
    box-shadow:
        0 20px 60px rgba(0, 0, 0, 0.4),
        0 0 60px rgba(255, 85, 51, 0.08);
}

.login-logo {
    width: 120px;
    height: 120px;
    border-radius: 16px;
    margin-bottom: 12px;
    filter: drop-shadow(0 0 24px rgba(255, 85, 51, 0.5));
}

.login-header {
    text-align: center;
    margin-bottom: 28px;
}

.login-header h1 {
    font-size: 32px;
    font-weight: 800;
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 8px;
}

.login-header p {
    color: var(--text-muted);
    font-size: 14px;
}

/* ── Toast ── */

#toast-container {
    position: fixed;
    top: 16px;
    right: 16px;
    z-index: 2000;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.toast {
    padding: 12px 20px;
    border-radius: 10px;
    font-size: 13px;
    color: #fff;
    animation: slideIn 0.3s ease;
    min-width: 260px;
    backdrop-filter: blur(8px);
}

.toast-success { background: rgba(34, 197, 94, 0.9); }
.toast-error { background: rgba(239, 68, 68, 0.9); }
.toast-info { background: rgba(124, 92, 255, 0.9); }

@keyframes slideIn {
    from { transform: translateX(100%); opacity: 0; }
    to { transform: translateX(0); opacity: 1; }
}

/* ── Checkbox styling ── */

input[type="checkbox"] {
    accent-color: var(--accent);
    width: 16px;
    height: 16px;
}

/* ── Link styling ── */
.link { color: var(--accent); }
.link:hover { text-decoration: underline; }

/* ── File upload ── */
::deep .InputFile { color: var(--text-secondary); }

/* ── VIP / Panel Access ── */

.vip-badge-sidebar {
    display: inline-block;
    padding: 2px 8px;
    border-radius: 4px;
    font-size: 10px;
    font-weight: 800;
    letter-spacing: 1px;
    background: var(--gradient-primary);
    color: #fff;
    margin-left: 8px;
    vertical-align: middle;
}

.vip-badge-login {
    display: inline-block;
    padding: 4px 16px;
    border-radius: 8px;
    font-size: 12px;
    font-weight: 800;
    letter-spacing: 2px;
    background: var(--gradient-primary);
    color: #fff;
    margin: 8px 0 4px;
}

.vip-topbar-badge {
    padding: 4px 12px;
    border-radius: 6px;
    font-size: 10px;
    font-weight: 800;
    letter-spacing: 1.5px;
    background: var(--gradient-subtle);
    border: 1px solid rgba(255, 85, 51, 0.2);
    color: var(--accent);
    margin-right: 12px;
}

.badge-vip {
    background: var(--gradient-subtle);
    color: var(--accent);
    font-weight: 700;
}

.login-footer {
    text-align: center;
    margin-top: 16px;
    padding-top: 16px;
    border-top: 1px solid var(--border);
}

.login-footer p {
    color: var(--text-muted);
    font-size: 12px;
}

.vip-status-card {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 16px;
    background: var(--gradient-subtle);
    border: 1px solid rgba(255, 85, 51, 0.15);
    border-radius: var(--radius);
    margin-bottom: 16px;
}

.vip-icon {
    font-size: 32px;
    color: var(--accent);
}

.vip-info strong {
    color: var(--text-primary);
    font-size: 14px;
}

.vip-info p {
    color: var(--text-secondary);
    font-size: 12px;
    margin-top: 4px;
}

.vip-features {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
}

.vip-feature {
    padding: 8px 12px;
    background: var(--bg-secondary);
    border-radius: 6px;
    font-size: 12px;
    color: var(--text-secondary);
}

.vip-feature::before {
    content: "\2713 ";
    color: var(--success);
    font-weight: bold;
}

/* ── Debug / Live Progress Panel ── */

.debug-panel {
    background: #08080f;
    border: 1px solid rgba(255, 85, 51, 0.1);
    border-radius: var(--radius-lg);
    margin-top: 16px;
    overflow: hidden;
}

.debug-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 20px;
    background: linear-gradient(90deg, rgba(255, 85, 51, 0.06), rgba(204, 68, 255, 0.03), transparent);
    border-bottom: 1px solid rgba(255, 85, 51, 0.08);
}

.debug-header h4 {
    font-size: 13px;
    font-weight: 600;
    color: var(--text-primary);
    margin: 0;
    font-family: 'JetBrains Mono', monospace;
}

.debug-header h4::before {
    content: '> ';
    color: var(--accent);
}

.progress-counters {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1px;
    background: var(--border);
    border-bottom: 1px solid rgba(255, 85, 51, 0.08);
}

.counter {
    text-align: center;
    padding: 14px 10px;
    background: #0a0a14;
}

.counter-value {
    display: block;
    font-size: 26px;
    font-weight: 800;
    font-family: 'JetBrains Mono', monospace;
}

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

.counter-success .counter-value { color: var(--success); text-shadow: 0 0 20px rgba(34, 197, 94, 0.3); }
.counter-info .counter-value { color: var(--info); text-shadow: 0 0 20px rgba(124, 92, 255, 0.3); }
.counter-warning .counter-value { color: var(--warning); text-shadow: 0 0 20px rgba(245, 158, 11, 0.3); }
.counter-error .counter-value { color: var(--error); text-shadow: 0 0 20px rgba(239, 68, 68, 0.3); }

.debug-log {
    max-height: 320px;
    overflow-y: auto;
    padding: 8px 12px;
    background: #060610;
    display: flex;
    flex-direction: column;
    gap: 1px;
    font-family: 'JetBrains Mono', monospace;
}

.debug-log .log-entry {
    padding: 3px 8px;
    border-radius: 2px;
    font-size: 11.5px;
}

.debug-log .log-entry:hover {
    background: rgba(255, 255, 255, 0.02);
}

.debug-log .log-action {
    color: var(--accent);
    font-weight: 500;
    min-width: 90px;
}

.debug-log .log-entry.log-error {
    background: rgba(239, 68, 68, 0.05);
    border-left: 2px solid var(--error);
}

.debug-log .log-entry.log-warning {
    background: rgba(245, 158, 11, 0.04);
    border-left: 2px solid rgba(245, 158, 11, 0.4);
}

.debug-log .log-entry.log-success {
    border-left: 2px solid rgba(34, 197, 94, 0.4);
}

.debug-log .log-entry.log-info {
    border-left: 2px solid rgba(124, 92, 255, 0.3);
}

/* ── Scrollbar ── */

::-webkit-scrollbar { width: 6px; height: 6px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: rgba(255, 255, 255, 0.08); border-radius: 3px; }
::-webkit-scrollbar-thumb:hover { background: rgba(255, 255, 255, 0.15); }

/* ── Mode Toggle (Create Accounts) ── */

.mode-toggle {
    display: flex;
    gap: 0;
    background: var(--bg-input);
    border-radius: var(--radius);
    border: 1px solid var(--border);
    overflow: hidden;
    margin-bottom: 20px;
}

.mode-toggle-btn {
    flex: 1;
    padding: 10px 20px;
    background: transparent;
    border: none;
    color: var(--text-secondary);
    font-size: 13px;
    font-weight: 600;
    font-family: inherit;
    cursor: pointer;
    transition: all 0.2s;
}

.mode-toggle-btn.active {
    background: var(--accent);
    color: #fff;
}

.mode-toggle-btn:hover:not(.active) {
    background: var(--bg-hover);
    color: var(--text-primary);
}

/* ── Job Queue Table ── */

.job-status-queued { color: var(--text-muted); }
.job-status-inprogress { color: var(--warning); }
.job-status-completed { color: var(--success); }
.job-status-failed { color: var(--error); }
.job-status-cancelled { color: var(--text-muted); text-decoration: line-through; }

/* ── Live Task Console ── */

.task-console {
    background: #08080f;
    border: 1px solid rgba(255, 85, 51, 0.1);
    border-radius: var(--radius-lg);
    margin-top: 16px;
    overflow: hidden;
}

.task-console-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 16px;
    background: linear-gradient(90deg, rgba(255, 85, 51, 0.06), rgba(204, 68, 255, 0.03), transparent);
    border-bottom: 1px solid rgba(255, 85, 51, 0.08);
}

.task-console-header h4 {
    font-size: 13px;
    font-weight: 600;
    color: var(--text-primary);
    margin: 0;
    font-family: 'JetBrains Mono', monospace;
    display: flex;
    align-items: center;
    gap: 8px;
}

.task-console-header h4::before {
    content: '>';
    color: var(--accent);
}

.task-console-header .console-status {
    font-size: 11px;
    color: var(--text-muted);
    font-family: 'JetBrains Mono', monospace;
}

.task-console-header .console-status.active {
    color: var(--success);
}

/* Job summary strip */
.job-summary-strip {
    display: flex;
    gap: 1px;
    background: var(--border);
    border-bottom: 1px solid rgba(255, 85, 51, 0.08);
}

.job-summary-item {
    flex: 1;
    text-align: center;
    padding: 10px 8px;
    background: #0a0a14;
}

.job-summary-value {
    display: block;
    font-size: 20px;
    font-weight: 800;
    font-family: 'JetBrains Mono', monospace;
}

.job-summary-label {
    display: block;
    font-size: 9px;
    color: var(--text-muted);
    margin-top: 2px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    font-weight: 600;
}

.job-summary-item.queued .job-summary-value { color: var(--text-secondary); }
.job-summary-item.in-progress .job-summary-value { color: var(--warning); text-shadow: 0 0 12px rgba(245, 158, 11, 0.3); }
.job-summary-item.completed .job-summary-value { color: var(--success); text-shadow: 0 0 12px rgba(34, 197, 94, 0.3); }
.job-summary-item.failed .job-summary-value { color: var(--error); text-shadow: 0 0 12px rgba(239, 68, 68, 0.3); }

/* Active job indicator */
.active-job-bar {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 16px;
    background: rgba(245, 158, 11, 0.06);
    border-bottom: 1px solid rgba(245, 158, 11, 0.1);
    font-size: 12px;
    font-family: 'JetBrains Mono', monospace;
}

.active-job-bar .spinner {
    display: inline-block;
    width: 10px;
    height: 10px;
    border: 2px solid var(--warning);
    border-top-color: transparent;
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

.active-job-bar .job-email {
    color: var(--warning);
    font-weight: 600;
}

.active-job-bar .job-step {
    color: var(--text-secondary);
    flex: 1;
}

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

/* Console log feed */
.task-console-log {
    max-height: 280px;
    overflow-y: auto;
    padding: 6px 10px;
    background: #060610;
    display: flex;
    flex-direction: column;
    gap: 1px;
    font-family: 'JetBrains Mono', monospace;
}

.task-console-log .log-entry {
    padding: 2px 6px;
    border-radius: 2px;
    font-size: 11px;
}

.task-console-log .log-entry:hover {
    background: rgba(255, 255, 255, 0.02);
}

.task-console-log .log-entry.log-error {
    background: rgba(239, 68, 68, 0.05);
    border-left: 2px solid var(--error);
}

.task-console-log .log-entry.log-warning {
    background: rgba(245, 158, 11, 0.04);
    border-left: 2px solid rgba(245, 158, 11, 0.4);
}

.task-console-log .log-entry.log-success {
    border-left: 2px solid rgba(34, 197, 94, 0.4);
}

.task-console-log .log-entry.log-info {
    border-left: 2px solid rgba(124, 92, 255, 0.2);
}

/* ── Keyframes ── */

@keyframes floatOrb1 {
    0%, 100% { transform: translate(0, 0) scale(1); }
    33% { transform: translate(30px, 20px) scale(1.05); }
    66% { transform: translate(-20px, -10px) scale(0.95); }
}

@keyframes floatOrb2 {
    0%, 100% { transform: translate(0, 0) scale(1); }
    33% { transform: translate(-25px, -15px) scale(1.08); }
    66% { transform: translate(15px, 25px) scale(0.92); }
}

@keyframes particleDrift {
    0% { transform: translateY(0); opacity: 0; }
    10% { opacity: 0.6; }
    90% { opacity: 0.3; }
    100% { transform: translateY(-100vh); opacity: 0; }
}

@keyframes syncPulse {
    0%, 100% { box-shadow: 0 0 0 0 rgba(34, 197, 94, 0.4); }
    50% { box-shadow: 0 0 0 4px rgba(34, 197, 94, 0); }
}

@keyframes countPulse {
    0% { transform: scale(1.15); opacity: 0.7; }
    100% { transform: scale(1); opacity: 1; }
}

/* ── Responsive ── */

@media (max-width: 768px) {
    .sidebar { display: none; }
    .main-area { margin-left: 0; }
    .dashboard-panels { grid-template-columns: 1fr; }
    .dashboard-top-panels { grid-template-columns: 1fr; }
    .form-row { flex-direction: column; }
    .settings-grid { grid-template-columns: 1fr; }
    .progress-counters { grid-template-columns: repeat(2, 1fr); }
    .vip-features { grid-template-columns: 1fr; }
}
