/* Sellauth/Sellhub Inspired Purple Dark Theme */

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    /* Purple Theme Colors */
    --primary: #8b5cf6;
    --primary-dark: #7c3aed;
    --primary-light: #a78bfa;
    --secondary: #6366f1;
    --accent: #ec4899;
    
    /* Dark Theme - Darker backgrounds for cleaner look */
    --bg-primary: #0a0a0f;
    --bg-secondary: #121218;
    --bg-tertiary: #1a1a24;
    --bg-card: #18181f;
    
    /* Text Colors - Improved hierarchy */
    --text-primary: #ffffff;
    --text-secondary: #94a3b8;
    --text-muted: #64748b;
    
    /* UI Colors */
    --border: #1e1e2a;
    --success: #10b981;
    --warning: #f59e0b;
    --error: #ef4444;
    
    /* Gradients */
    --gradient-primary: linear-gradient(135deg, #8b5cf6 0%, #6366f1 100%);
    --gradient-secondary: linear-gradient(135deg, #ec4899 0%, #8b5cf6 100%);
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    background: var(--bg-primary);
    color: var(--text-primary);
    line-height: 1.6;
    min-height: 100vh;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
}

/* Typography */
h1, h2, h3, h4, h5, h6 {
    font-weight: 700;
    line-height: 1.2;
}

h1 { font-size: 3rem; }
h2 { font-size: 2.5rem; }
h3 { font-size: 1.75rem; }

/* Navigation */
.navbar {
    background: var(--bg-secondary);
    border-bottom: 1px solid var(--border);
    padding: 1rem 0;
    position: sticky;
    top: 0;
    z-index: 1000;
    backdrop-filter: blur(10px);
}

.navbar .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.nav-brand {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text-primary);
    text-decoration: none;
}

.nav-brand i {
    color: var(--primary);
}

.nav-links {
    display: flex;
    gap: 1.5rem;
    align-items: center;
}

.nav-links a {
    color: var(--text-secondary);
    text-decoration: none;
    font-weight: 500;
    transition: color 0.3s;
}

.nav-links a:hover {
    color: var(--text-primary);
}

.mobile-menu {
    display: none;
    background: none;
    border: none;
    color: var(--text-primary);
    font-size: 1.5rem;
    cursor: pointer;
}

/* Buttons */
.btn-primary, .btn-secondary {
    padding: 0.65rem 1.25rem;
    border-radius: 0.5rem;
    text-decoration: none;
    font-weight: 500;
    font-size: 0.95rem;
    transition: all 0.2s;
    border: none;
    cursor: pointer;
    display: inline-block;
    letter-spacing: -0.01em;
}

.btn-primary {
    background: var(--gradient-primary);
    color: white;
}

.btn-primary:hover {
    transform: translateY(-1px);
    box-shadow: 0 8px 20px rgba(139, 92, 246, 0.3);
}

.btn-secondary {
    background: var(--bg-tertiary);
    color: var(--text-primary);
    border: 1px solid var(--border);
}

.btn-secondary:hover {
    background: var(--bg-card);
    border-color: rgba(139, 92, 246, 0.5);
}

.btn-lg {
    padding: 0.875rem 1.75rem;
    font-size: 1rem;
}

.btn-block {
    width: 100%;
    text-align: center;
}

/* Hero Section */
.hero {
    padding: 6rem 0;
    text-align: center;
    background: radial-gradient(circle at top, rgba(139, 92, 246, 0.1) 0%, transparent 70%);
}

.hero-content {
    max-width: 800px;
    margin: 0 auto;
}

.hero-icon {
    font-size: 5rem;
    color: var(--primary);
    margin-bottom: 2rem;
    animation: float 3s ease-in-out infinite;
}

@keyframes float {
    0%, 100% { transform: translateY(0px); }
    50% { transform: translateY(-20px); }
}

@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.5; }
}

.hero-title {
    margin-bottom: 1.5rem;
    background: linear-gradient(135deg, var(--primary) 0%, var(--accent) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero-subtitle {
    font-size: 1.25rem;
    color: var(--text-secondary);
    margin-bottom: 2.5rem;
    line-height: 1.8;
}

.hero-buttons {
    display: flex;
    gap: 1rem;
    justify-content: center;
    flex-wrap: wrap;
}

/* Features Section */
.features {
    padding: 6rem 0;
    background: var(--bg-secondary);
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
}

.feature-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 1rem;
    padding: 2.5rem;
    text-align: center;
    transition: all 0.3s;
}

.feature-card:hover {
    transform: translateY(-5px);
    border-color: var(--primary);
    box-shadow: 0 20px 40px rgba(139, 92, 246, 0.2);
}

.feature-icon {
    font-size: 3rem;
    color: var(--primary);
    margin-bottom: 1.5rem;
}

.feature-card h3 {
    margin-bottom: 1rem;
    color: var(--text-primary);
}

.feature-card p {
    color: var(--text-secondary);
}

/* CTA Section */
.cta {
    padding: 6rem 0;
    text-align: center;
    background: var(--gradient-primary);
}

.cta h2 {
    margin-bottom: 1rem;
}

.cta p {
    font-size: 1.25rem;
    margin-bottom: 2rem;
    opacity: 0.9;
}

/* Forms */
.form-container {
    max-width: 450px;
    margin: 4rem auto;
    padding: 3rem;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 1rem;
}

.form-header {
    text-align: center;
    margin-bottom: 2rem;
}

.form-header i {
    font-size: 3rem;
    color: var(--primary);
    margin-bottom: 1rem;
}

.form-group {
    margin-bottom: 1.5rem;
}

.form-label {
    display: block;
    margin-bottom: 0.5rem;
    color: var(--text-primary);
    font-weight: 500;
}

.form-input, .form-select, .form-textarea {
    width: 100%;
    padding: 0.75rem 1rem;
    background: var(--bg-tertiary);
    border: 1px solid var(--border);
    border-radius: 0.5rem;
    color: var(--text-primary);
    font-size: 0.95rem;
    transition: all 0.2s;
}

.form-input:focus, .form-select:focus, .form-textarea:focus {
    outline: none;
    border-color: var(--primary);
    background: rgba(139, 92, 246, 0.05);
}

.form-textarea {
    resize: vertical;
    min-height: 100px;
}

.form-help {
    font-size: 0.875rem;
    color: var(--text-muted);
    margin-top: 0.25rem;
}

.alert {
    padding: 1rem;
    border-radius: 0.5rem;
    margin-bottom: 1.5rem;
}

.alert-success {
    background: rgba(16, 185, 129, 0.1);
    border: 1px solid var(--success);
    color: var(--success);
}

.alert-error {
    background: rgba(239, 68, 68, 0.1);
    border: 1px solid var(--error);
    color: var(--error);
}

.alert-warning {
    background: rgba(245, 158, 11, 0.1);
    border: 1px solid var(--warning);
    color: var(--warning);
}

/* Cards */
.card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 0.75rem;
    padding: 1.5rem;
    margin-bottom: 1.5rem;
    transition: all 0.2s;
}

.card:hover {
    border-color: rgba(139, 92, 246, 0.3);
}

.card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.25rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid var(--border);
}

.card-title {
    font-size: 1.25rem;
    font-weight: 600;
    letter-spacing: -0.01em;
}

.card-body {
    color: var(--text-secondary);
    line-height: 1.7;
}

/* Dashboard Layout */
.dashboard-layout {
    display: flex;
    min-height: 100vh;
}

.dashboard-sidebar {
    width: 280px;
    background: var(--bg-secondary);
    border-right: 1px solid var(--border);
    padding: 1rem 0.9rem;
    position: sticky;
    top: 0;
    height: 100vh;
    overflow-y: auto;
}

.sidebar-brand {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.25rem 0.45rem 1rem;
    margin-bottom: 0.5rem;
}

.store-switcher-card {
    background: #121d3d;
    border: 1px solid #22325f;
    border-radius: 12px;
    padding: 0.8rem;
    margin-bottom: 1rem;
}

.store-label { font-size: 0.75rem; color: var(--text-muted); display: block; margin-bottom: 0.45rem; }
.store-row { display: grid; grid-template-columns: 1fr auto; gap: 0.45rem; align-items: center; }
.store-meta { color: var(--text-secondary); font-size: 0.75rem; margin-top: 0.45rem; display: block; }

/* Custom Scrollbar for Sidebar */
.dashboard-sidebar::-webkit-scrollbar {
    width: 8px;
}

.dashboard-sidebar::-webkit-scrollbar-track {
    background: var(--bg-secondary);
}

.dashboard-sidebar::-webkit-scrollbar-thumb {
    background: var(--border);
    border-radius: 4px;
}

.dashboard-sidebar::-webkit-scrollbar-thumb:hover {
    background: var(--primary);
}

.sidebar-section {
    margin-bottom: 0.75rem;
}

.sidebar-category-toggle {
    width: 100%;
    border: none;
    background: transparent;
    color: var(--text-muted);
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.45rem 0.7rem;
    border-radius: 8px;
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    font-weight: 700;
    cursor: pointer;
}

.sidebar-category-toggle i {
    transition: transform 0.2s ease;
}

.sidebar-category-toggle.collapsed i {
    transform: rotate(-90deg);
}

.sidebar-nav {
    list-style: none;
    padding: 0;
    margin-top: 0.2rem;
}

.sidebar-nav.collapsed {
    display: none;
}

.sidebar-nav-item {
    margin: 0;
}

.sidebar-nav-link {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.68rem 0.85rem;
    color: var(--text-secondary);
    text-decoration: none;
    transition: all 0.2s;
    border-left: 3px solid transparent;
}

.sidebar-nav-link:hover {
    background: var(--bg-tertiary);
    color: var(--text-primary);
}

.sidebar-nav-link.active {
    background: var(--bg-tertiary);
    color: var(--primary);
    border-left-color: var(--primary);
}

.sidebar-nav-link i {
    width: 20px;
    text-align: center;
}

.sidebar-subcategory {
    list-style: none;
    padding: 0;
    margin: 0;
}

.sidebar-subcategory .sidebar-nav-link {
    padding-left: 3.25rem;
    font-size: 0.875rem;
}

.dashboard-content {
    flex: 1;
    padding: 1.5rem 2rem;
    overflow-y: auto;
    background: var(--bg-primary);
}

.dashboard {
    padding: 0;
    min-height: auto;
}

.dashboard-header {
    display: none;
}

.dashboard-header h1 {
    margin-bottom: 0.5rem;
}

.dashboard-header p {
    color: var(--text-secondary);
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 1.25rem;
    margin-bottom: 2rem;
}

.stat-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 0.75rem;
    padding: 1.5rem;
    transition: all 0.2s;
}

.stat-card:hover {
    border-color: rgba(139, 92, 246, 0.3);
}

.stat-card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.75rem;
}

.stat-card-title {
    color: var(--text-secondary);
    font-size: 0.85rem;
    font-weight: 500;
    letter-spacing: -0.01em;
}

.stat-card-icon {
    font-size: 1.25rem;
    color: var(--primary);
    opacity: 0.8;
}

.stat-card-value {
    font-size: 2rem;
    font-weight: 700;
    letter-spacing: -0.02em;
}

/* Product List */
.product-list {
    display: flex;
    flex-direction: column;
    gap: 0.875rem;
}

.product-item {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 0.75rem;
    padding: 1.25rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: all 0.2s;
}

.product-item:hover {
    border-color: rgba(139, 92, 246, 0.3);
}

.product-info h3 {
    margin-bottom: 0.5rem;
}

.product-meta {
    display: flex;
    gap: 1.5rem;
    color: var(--text-secondary);
    font-size: 0.875rem;
}

.badge {
    padding: 0.25rem 0.75rem;
    border-radius: 0.25rem;
    font-size: 0.75rem;
    font-weight: 600;
}

.badge-success {
    background: rgba(16, 185, 129, 0.1);
    color: var(--success);
}

.badge-warning {
    background: rgba(245, 158, 11, 0.1);
    color: var(--warning);
}

/* Footer */
.footer {
    background: var(--bg-secondary);
    border-top: 1px solid var(--border);
    padding: 2rem 0;
    margin-top: 4rem;
}

.footer .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.footer-links {
    display: flex;
    gap: 2rem;
}

.footer-links a {
    color: var(--text-secondary);
    text-decoration: none;
    transition: color 0.3s;
}

.footer-links a:hover {
    color: var(--text-primary);
}

/* Responsive */
@media (max-width: 768px) {
    .container {
        padding: 0 1rem;
    }
    
    h1 { font-size: 2rem; }
    h2 { font-size: 1.75rem; }
    
    .nav-links {
        display: none;
    }
    
    .mobile-menu {
        display: block;
    }
    
    .hero {
        padding: 4rem 0;
    }
    
    .hero-buttons {
        flex-direction: column;
    }
    
    .features, .cta {
        padding: 4rem 0;
    }
    
    .footer .container {
        flex-direction: column;
        gap: 1rem;
        text-align: center;
    }
    
    .form-container {
        padding: 2rem;
    }
}

/* Loading Spinner */
.spinner {
    border: 3px solid var(--border);
    border-top: 3px solid var(--primary);
    border-radius: 50%;
    width: 40px;
    height: 40px;
    animation: spin 1s linear infinite;
    margin: 2rem auto;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.hidden {
    display: none !important;
}

/* Page Editor */
.editor-container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
    height: calc(100vh - 250px);
    min-height: 600px;
}

.editor-panel {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 1rem;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.editor-header {
    padding: 1rem 1.5rem;
    border-bottom: 1px solid var(--border);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.editor-header h3 {
    font-size: 1rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.editor-body {
    flex: 1;
    overflow: hidden;
}

.code-editor {
    width: 100%;
    height: 100%;
    padding: 1.5rem;
    background: var(--bg-tertiary);
    border: none;
    color: var(--text-primary);
    font-family: 'Courier New', monospace;
    font-size: 0.9rem;
    line-height: 1.6;
    resize: none;
    outline: none;
}

.preview-frame {
    width: 100%;
    height: 100%;
    border: none;
    background: white;
}

.template-selector {
    margin-bottom: 1.5rem;
    padding: 1.5rem;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 0.75rem;
}

.template-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    gap: 1rem;
    margin-top: 1rem;
}

.template-option {
    padding: 1rem;
    background: var(--bg-tertiary);
    border: 2px solid var(--border);
    border-radius: 0.5rem;
    cursor: pointer;
    text-align: center;
    transition: all 0.2s;
}

.template-option:hover {
    border-color: var(--primary);
    transform: translateY(-2px);
}

.template-option.active {
    border-color: var(--primary);
    background: rgba(139, 92, 246, 0.1);
}

.template-option i {
    font-size: 2rem;
    color: var(--primary);
    margin-bottom: 0.5rem;
}

/* Categories */
.category-tree {
    margin-top: 1rem;
}

.category-item {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 0.5rem;
    padding: 1rem;
    margin-bottom: 0.75rem;
}

.category-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.category-actions {
    display: flex;
    gap: 0.5rem;
}

.subcategory-list {
    margin-top: 1rem;
    padding-left: 1.5rem;
    border-left: 2px solid var(--border);
}

.subcategory-item {
    background: var(--bg-tertiary);
    border: 1px solid var(--border);
    border-radius: 0.5rem;
    padding: 0.75rem 1rem;
    margin-bottom: 0.5rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

/* ============================================
   CODE EDITOR LAYOUT
   ============================================ */

.themes-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 2rem;
    padding: 1rem 0;
}

.theme-card {
    background: var(--bg-secondary);
    border-radius: 12px;
    overflow: hidden;
    border: 2px solid var(--border);
    transition: all 0.3s ease;
}

.theme-card:hover {
    transform: translateY(-5px);
    border-color: var(--primary);
    box-shadow: 0 8px 24px rgba(139, 92, 246, 0.2);
}

.theme-card.premium {
    position: relative;
}

.theme-card.premium::before {
    content: 'PREMIUM';
    position: absolute;
    top: 10px;
    right: 10px;
    background: var(--primary);
    color: white;
    padding: 4px 12px;
    border-radius: 6px;
    font-size: 0.75rem;
    font-weight: 700;
    z-index: 10;
}

.theme-preview {
    height: 200px;
    overflow: hidden;
    border-bottom: 2px solid var(--border);
    transform-origin: top left;
    transform: scale(0.8);
    width: 125%;
}

.theme-card-info {
    padding: 1.5rem;
}

.theme-card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.75rem;
}

.theme-card-header h3 {
    margin: 0;
    font-size: 1.25rem;
}

.theme-badge {
    padding: 0.25rem 0.75rem;
    border-radius: 6px;
    font-size: 0.75rem;
    font-weight: 700;
}

.theme-badge.free {
    background: rgba(16, 185, 129, 0.2);
    color: var(--success);
}

.theme-badge.premium {
    background: rgba(139, 92, 246, 0.2);
    color: var(--primary);
}

.theme-card-info p {
    color: var(--text-secondary);
    margin-bottom: 1rem;
    font-size: 0.875rem;
}

.btn-block {
    width: 100%;
    display: block;
}

.code-editor-layout {
    display: flex;
    height: calc(100vh - 60px);
    background: var(--bg-primary);
    overflow: hidden;
}

/* File Sidebar */
.file-sidebar {
    width: 280px;
    background: var(--bg-secondary);
    border-right: 1px solid var(--border);
    display: flex;
    flex-direction: column;
    overflow-y: auto;
}

.file-sidebar-header {
    padding: 1rem 1.25rem;
    border-bottom: 1px solid var(--border);
    background: var(--bg-tertiary);
}

.file-sidebar-header h3 {
    font-size: 0.875rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--text-secondary);
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.file-tree {
    flex: 1;
    padding: 0.5rem 0;
}

.file-section {
    margin-bottom: 0.5rem;
}

.file-section-header {
    padding: 0.5rem 1rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--text-secondary);
    font-size: 0.875rem;
    font-weight: 600;
    cursor: pointer;
    user-select: none;
    transition: all 0.2s;
}

.file-section-header:hover {
    background: var(--bg-tertiary);
    color: var(--text-primary);
}

.file-section-header i:first-child {
    font-size: 0.75rem;
    transition: transform 0.2s;
}

.file-section-content {
    padding-left: 0.5rem;
}

.file-item {
    padding: 0.5rem 1rem 0.5rem 2rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--text-secondary);
    font-size: 0.875rem;
    cursor: pointer;
    transition: all 0.2s;
    position: relative;
}

.file-item:hover {
    background: var(--bg-tertiary);
    color: var(--text-primary);
}

.file-item.active {
    background: var(--bg-tertiary);
    color: var(--primary);
}

.file-item.active::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 3px;
    background: var(--primary);
}

.file-item i {
    font-size: 0.875rem;
    min-width: 16px;
}

.file-badge {
    margin-left: auto;
    padding: 0.125rem 0.5rem;
    border-radius: 4px;
    font-size: 0.75rem;
    font-weight: 600;
}

.file-badge.free {
    background: rgba(16, 185, 129, 0.2);
    color: var(--success);
}

.file-badge.premium {
    background: rgba(139, 92, 246, 0.2);
    color: var(--primary);
}

/* Code Editor Main */
.code-editor-main {
    flex: 1;
    display: flex;
    flex-direction: column;
    background: var(--bg-primary);
    overflow: hidden;
}

.code-editor-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.75rem 1rem;
    background: var(--bg-secondary);
    border-bottom: 1px solid var(--border);
}

.editor-tabs {
    display: flex;
    gap: 0.5rem;
}

.editor-tab {
    padding: 0.5rem 1rem;
    background: var(--bg-tertiary);
    border-radius: 6px 6px 0 0;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.875rem;
    color: var(--text-secondary);
    cursor: pointer;
}

.editor-tab.active {
    background: var(--bg-primary);
    color: var(--primary);
}

.editor-actions {
    display: flex;
    gap: 0.5rem;
}

.code-editor-body {
    flex: 1;
    display: flex;
    background: var(--bg-primary);
    overflow: hidden;
    position: relative;
}

.editor-line-numbers {
    width: 60px;
    background: var(--bg-secondary);
    color: var(--text-muted);
    font-family: 'Fira Code', 'Consolas', monospace;
    font-size: 0.875rem;
    line-height: 1.6;
    padding: 1rem 0.5rem;
    text-align: right;
    user-select: none;
    border-right: 1px solid var(--border);
    overflow-y: auto;
    overflow-x: hidden;
    position: relative;
}

.editor-line-numbers::-webkit-scrollbar {
    width: 0;
    background: transparent;
}

.editor-line-numbers div {
    padding: 0 0.5rem;
    transition: background 0.15s, color 0.15s;
}

.editor-line-numbers div.current-line {
    background: rgba(139, 92, 246, 0.15);
    color: var(--primary);
    font-weight: 600;
}

.code-textarea {
    flex: 1;
    background: var(--bg-primary);
    color: var(--text-primary);
    font-family: 'Fira Code', 'Consolas', monospace;
    font-size: 0.875rem;
    line-height: 1.6;
    padding: 1rem;
    border: none;
    outline: none;
    resize: none;
    overflow-y: auto;
    white-space: pre;
    overflow-x: auto;
}

.code-textarea::-webkit-scrollbar {
    width: 12px;
    height: 12px;
}

.code-textarea::-webkit-scrollbar-track {
    background: var(--bg-secondary);
}

.code-textarea::-webkit-scrollbar-thumb {
    background: var(--primary);
    border-radius: 6px;
}

.code-textarea::-webkit-scrollbar-thumb:hover {
    background: var(--primary-hover);
}

/* Toggle Switch */
.toggle-switch {
    position: relative;
    display: inline-block;
    width: 56px;
    height: 28px;
}

.toggle-switch input {
    opacity: 0;
    width: 0;
    height: 0;
}

.toggle-slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: var(--bg-secondary);
    transition: 0.3s;
    border-radius: 34px;
    border: 2px solid var(--border);
}

.toggle-slider:before {
    position: absolute;
    content: "";
    height: 20px;
    width: 20px;
    left: 2px;
    bottom: 2px;
    background-color: white;
    transition: 0.3s;
    border-radius: 50%;
}

.toggle-switch input:checked + .toggle-slider {
    background-color: var(--primary);
    border-color: var(--primary);
}

.toggle-switch input:checked + .toggle-slider:before {
    transform: translateX(28px);
}

/* Form Row */
.form-row {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1.5rem;
}

/* Image Preview */
.image-preview-container {
    margin-top: 1rem;
    padding: 1rem;
    background: var(--bg-secondary);
    border-radius: 8px;
    text-align: center;
}

/* Data Table */
.data-table {
    width: 100%;
    border-collapse: collapse;
}

.data-table thead {
    background: var(--bg-secondary);
    border-bottom: 2px solid var(--border);
}

.data-table th {
    padding: 1rem;
    text-align: left;
    font-weight: 600;
    color: var(--text-primary);
}

.data-table td {
    padding: 1rem;
    border-bottom: 1px solid var(--border);
}

.data-table tr:hover {
    background: var(--bg-secondary);
}

/* Badge */
.badge {
    display: inline-block;
    padding: 0.25rem 0.75rem;
    background: var(--primary);
    color: white;
    border-radius: 12px;
    font-size: 0.85rem;
    font-weight: 600;
}

/* Button Sizes */
.btn-sm {
    padding: 0.4rem 0.8rem;
    font-size: 0.85rem;
}

/* SellAuth Style Product Cards */
.sellauth-products-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 1.5rem;
    padding: 0.5rem 0;
}

/* SellAuth Style Products Table */
.products-table-wrapper {
    width: 100%;
    overflow-x: auto;
}

.products-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.9rem;
}

.products-table thead {
    background: var(--bg-secondary);
    border-bottom: 1px solid var(--border);
}

.products-table th {
    padding: 1rem 1.25rem;
    text-align: left;
    font-weight: 600;
    font-size: 0.85rem;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.products-table tbody tr {
    border-bottom: 1px solid var(--border);
    transition: all 0.2s;
}

.products-table tbody tr:hover {
    background: rgba(139, 92, 246, 0.03);
}

.products-table td {
    padding: 1rem 1.25rem;
    color: var(--text-primary);
    vertical-align: middle;
}

.product-id-badge {
    background: var(--bg-tertiary);
    padding: 0.25rem 0.5rem;
    border-radius: 0.25rem;
    font-size: 0.75rem;
    font-family: 'Courier New', monospace;
    color: var(--text-secondary);
}

.product-name-cell {
    font-weight: 500;
}

.visibility-badge {
    padding: 0.35rem 0.75rem;
    border-radius: 0.375rem;
    font-size: 0.8rem;
    font-weight: 500;
}

.visibility-public {
    background: rgba(16, 185, 129, 0.1);
    color: var(--success);
}

.visibility-private {
    background: rgba(245, 158, 11, 0.1);
    color: var(--warning);
}

.actions-cell {
    display: flex;
    gap: 0.5rem;
    justify-content: flex-end;
}

.action-btn {
    padding: 0.5rem 0.875rem;
    border-radius: 0.375rem;
    border: 1px solid var(--border);
    background: var(--bg-tertiary);
    color: var(--text-primary);
    font-size: 0.85rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s;
    display: inline-flex;
    align-items: center;
    gap: 0.375rem;
    text-decoration: none;
}

.action-btn:hover {
    background: var(--bg-card);
    border-color: rgba(139, 92, 246, 0.4);
    color: var(--primary);
}

.action-btn i {
    font-size: 0.8rem;
}

.action-edit:hover {
    border-color: rgba(139, 92, 246, 0.5);
    color: var(--primary);
}

.action-clone:hover {
    border-color: rgba(99, 102, 241, 0.5);
    color: var(--secondary);
}

.action-delete:hover {
    border-color: rgba(239, 68, 68, 0.5);
    color: var(--error);
}

.action-view:hover {
    border-color: rgba(16, 185, 129, 0.5);
    color: var(--success);
}

.action-btn-icon {
    width: 36px;
    height: 36px;
    padding: 0;
    border-radius: 0.375rem;
    border: 1px solid var(--border);
    background: var(--bg-tertiary);
    color: var(--text-primary);
    font-size: 0.875rem;
    cursor: pointer;
    transition: all 0.2s;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
}

.action-btn-icon:hover {
    background: var(--bg-card);
    border-color: rgba(139, 92, 246, 0.4);
    transform: translateY(-1px);
}

.action-btn-icon.action-edit:hover {
    border-color: rgba(139, 92, 246, 0.6);
    background: rgba(139, 92, 246, 0.1);
    color: var(--primary);
}

.action-btn-icon.action-clone:hover {
    border-color: rgba(99, 102, 241, 0.6);
    background: rgba(99, 102, 241, 0.1);
    color: var(--secondary);
}

.action-btn-icon.action-delete:hover {
    border-color: rgba(239, 68, 68, 0.6);
    background: rgba(239, 68, 68, 0.1);
    color: var(--error);
}

.action-btn-icon.action-view:hover {
    border-color: rgba(16, 185, 129, 0.6);
    background: rgba(16, 185, 129, 0.1);
    color: var(--success);
}

.table-footer {
    padding: 1rem 1.25rem;
    border-top: 1px solid var(--border);
    background: var(--bg-secondary);
}

.sellauth-product-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 12px;
    overflow: hidden;
    transition: all 0.3s ease;
    cursor: pointer;
    position: relative;
    display: flex;
    flex-direction: column;
}

.sellauth-product-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(139, 92, 246, 0.15);
    border-color: rgba(139, 92, 246, 0.3);
}

.sellauth-product-card.has-badge {
    border-color: #ff4444;
}

.product-badge {
    position: absolute;
    top: 12px;
    right: 12px;
    background: linear-gradient(135deg, #ff4444, #ff6b6b);
    color: white;
    padding: 0.35rem 0.75rem;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 700;
    z-index: 10;
    box-shadow: 0 2px 8px rgba(255, 68, 68, 0.4);
}

.product-delete-btn {
    position: absolute;
    top: 12px;
    left: 12px;
    width: 34px;
    height: 34px;
    border-radius: 10px;
    border: 1px solid rgba(239, 68, 68, 0.45);
    background: rgba(20, 20, 30, 0.85);
    color: #ef4444;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    z-index: 11;
    transition: all 0.2s ease;
}

.product-delete-btn:hover {
    background: #ef4444;
    color: #fff;
    border-color: #ef4444;
}

.product-card-image {
    width: 100%;
    height: 160px;
    background: linear-gradient(135deg, #1a1f3a 0%, #0f1525 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    position: relative;
    border-radius: 12px 12px 0 0;
}

.product-card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.sellauth-product-card:hover .product-card-image img {
    transform: scale(1.05);
}

.product-no-image {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, rgba(139, 92, 246, 0.08), rgba(124, 58, 237, 0.04));
}

.product-no-image i {
    font-size: 3rem;
    color: var(--primary);
    opacity: 0.25;
}

.group-image {
    background: linear-gradient(135deg, var(--primary), #7c3aed);
}

.group-icon {
    font-size: 3rem;
    color: white;
    opacity: 0.9;
}

.product-card-content {
    padding: 1rem 1.25rem 1.25rem;
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 0.4rem;
}

.product-card-title {
    font-size: 1.05rem;
    font-weight: 600;
    margin: 0;
    color: var(--text-primary);
    line-height: 1.3;
    overflow: hidden;
    text-overflow: ellipsis;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

.product-card-stock {
    font-size: 0.825rem;
    color: var(--text-secondary);
    margin: 0;
    font-weight: 500;
    opacity: 0.9;
}

.product-card-stock.out-of-stock {
    color: var(--error);
}

.product-card-price {
    font-size: 1.35rem;
    font-weight: 700;
    color: var(--primary);
    margin-top: auto;
    padding-top: 0.5rem;
}

.price-compare-strike {
    font-size: 0.875rem;
    color: var(--text-muted);
    text-decoration: line-through;
    margin-left: 0.5rem;
    font-weight: 500;
}

.group-card {
    background: linear-gradient(135deg, rgba(139, 92, 246, 0.05), rgba(124, 58, 237, 0.05));
    border-color: var(--primary);
}

.group-card:hover {
    background: linear-gradient(135deg, rgba(139, 92, 246, 0.1), rgba(124, 58, 237, 0.1));
}

.code-textarea::-webkit-scrollbar-thumb {
    background: var(--bg-tertiary);
    border-radius: 6px;
}

.code-textarea::-webkit-scrollbar-thumb:hover {
    background: var(--primary);
}

.code-editor-footer {
    padding: 0.5rem 1rem;
    background: var(--bg-secondary);
    border-top: 1px solid var(--border);
}

.editor-status {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.75rem;
    color: var(--text-muted);
}

.editor-status span {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

@media (max-width: 1200px) {
    .editor-container {
        grid-template-columns: 1fr;
        height: auto;
    }
    
    .editor-panel {
        min-height: 400px;
    }
    
    .code-editor-layout {
        height: auto;
        flex-direction: column;
    }
    
    .file-sidebar {
        width: 100%;
        max-height: 300px;
    }
}

@media (max-width: 768px) {
    .dashboard-layout {
        flex-direction: column;
    }
    
    .dashboard-sidebar {
        width: 100%;
        height: auto;
        position: relative;
        top: 0;
    }
}

/* Discord Widget */
.discord-widget {
    position: fixed;
    bottom: 1.5rem;
    right: 1.5rem;
    z-index: 50;
    background: #5865F2;
    color: white;
    width: 56px;
    height: 56px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    box-shadow: 0 10px 25px rgba(88, 101, 242, 0.4), 0 4px 6px rgba(0, 0, 0, 0.3);
    transition: all 0.3s ease;
    text-decoration: none;
}

.discord-widget:hover {
    background: #4752C4;
    transform: scale(1.1);
    box-shadow: 0 15px 35px rgba(88, 101, 242, 0.6), 0 6px 10px rgba(0, 0, 0, 0.4);
}

.discord-widget i {
    color: white;
}

@media (max-width: 640px) {
    .discord-widget {
        bottom: 1rem;
        right: 1rem;
        width: 48px;
        height: 48px;
        font-size: 1.25rem;
    }
}
/* New Homepage Sections */
.trust-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    background: rgba(139, 92, 246, 0.1);
    border: 1px solid rgba(139, 92, 246, 0.3);
    padding: 0.5rem 1.25rem;
    border-radius: 2rem;
    margin-bottom: 2rem;
    font-size: 0.9rem;
    color: var(--primary-light);
}

.trust-badge i {
    color: var(--success);
}

.gradient-text {
    background: var(--gradient-secondary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero-subtitle strong {
    color: var(--primary-light);
    font-weight: 600;
}

.hero-stats {
    display: flex;
    justify-content: center;
    gap: 3rem;
    flex-wrap: wrap;
    padding-top: 2rem;
    border-top: 1px solid var(--border);
    max-width: 800px;
    margin: 3rem auto 0;
}

.stat {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.stat i {
    font-size: 2rem;
    color: var(--primary);
}

.stat div {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
}

.stat strong {
    font-size: 1.5rem;
    color: var(--text-primary);
    font-weight: 700;
}

.stat span {
    font-size: 0.875rem;
    color: var(--text-secondary);
}

.section-header {
    text-align: center;
    margin-bottom: 4rem;
}

.section-header h2 {
    font-size: 2.5rem;
    font-weight: 800;
    margin-bottom: 1rem;
}

.section-header p {
    font-size: 1.25rem;
    color: var(--text-secondary);
}

.feature-icon.green {
    background: rgba(16, 185, 129, 0.1);
    color: var(--success);
    width: 80px;
    height: 80px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 1rem;
    margin: 0 auto 1.5rem;
}

.feature-icon.blue {
    background: rgba(59, 130, 246, 0.1);
    color: #3b82f6;
    width: 80px;
    height: 80px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 1rem;
    margin: 0 auto 1.5rem;
}

.feature-icon.purple {
    background: rgba(139, 92, 246, 0.1);
    color: var(--primary);
    width: 80px;
    height: 80px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 1rem;
    margin: 0 auto 1.5rem;
}

.feature-icon.orange {
    background: rgba(245, 158, 11, 0.1);
    color: var(--warning);
    width: 80px;
    height: 80px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 1rem;
    margin: 0 auto 1.5rem;
}

.feature-icon.pink {
    background: rgba(236, 72, 153, 0.1);
    color: var(--accent);
    width: 80px;
    height: 80px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 1rem;
    margin: 0 auto 1.5rem;
}

.feature-icon.cyan {
    background: rgba(6, 182, 212, 0.1);
    color: #06b6d4;
    width: 80px;
    height: 80px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 1rem;
    margin: 0 auto 1.5rem;
}

/* How It Works */
.how-it-works {
    padding: 6rem 0;
    background: var(--bg-primary);
}

.steps-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 3rem;
    margin-top: 3rem;
}

.step-card {
    position: relative;
    text-align: center;
    padding: 2rem;
}

.step-number {
    position: absolute;
    top: -20px;
    left: 50%;
    transform: translateX(-50%);
    width: 50px;
    height: 50px;
    background: var(--gradient-primary);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    font-weight: 800;
    box-shadow: 0 4px 12px rgba(139, 92, 246, 0.4);
}

.step-icon {
    font-size: 3rem;
    color: var(--primary);
    margin: 3rem 0 1.5rem;
}

.step-card h3 {
    font-size: 1.5rem;
    margin-bottom: 1rem;
    font-weight: 700;
}

.step-card p {
    color: var(--text-secondary);
}

/* Pricing */
.pricing {
    padding: 6rem 0;
    background: var(--bg-secondary);
}

.pricing-card {
    max-width: 500px;
    margin: 0 auto;
    background: var(--bg-card);
    border: 2px solid var(--border);
    border-radius: 1.5rem;
    padding: 3rem;
    position: relative;
}

.pricing-card.featured {
    border-color: var(--primary);
    box-shadow: 0 20px 60px rgba(139, 92, 246, 0.3);
}

.pricing-badge {
    position: absolute;
    top: -15px;
    left: 50%;
    transform: translateX(-50%);
    background: var(--gradient-primary);
    padding: 0.5rem 1.5rem;
    border-radius: 2rem;
    font-weight: 600;
    font-size: 0.875rem;
}

.pricing-header {
    text-align: center;
    margin-bottom: 2rem;
}

.pricing-header h3 {
    font-size: 2rem;
    margin-bottom: 1rem;
    font-weight: 800;
}

.price {
    display: flex;
    align-items: baseline;
    justify-content: center;
    gap: 0.5rem;
}

.price .amount {
    font-size: 4rem;
    font-weight: 900;
    background: var(--gradient-secondary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.price .period {
    font-size: 1.25rem;
    color: var(--text-secondary);
}

.pricing-features {
    list-style: none;
    margin: 2rem 0;
    padding: 0;
}

.pricing-features li {
    padding: 0.75rem 0;
    display: flex;
    align-items: center;
    gap: 1rem;
    font-size: 1.05rem;
}

.pricing-features i {
    color: var(--success);
    font-size: 1.25rem;
}

.pricing-note {
    text-align: center;
    margin-top: 1.5rem;
    font-size: 0.875rem;
    color: var(--text-secondary);
}

.btn-block {
    width: 100%;
    justify-content: center;
}

/* Trust Section */
.trust-section {
    padding: 4rem 0;
    background: var(--bg-primary);
    border-top: 1px solid var(--border);
    border-bottom: 1px solid var(--border);
}

.trust-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
}

.trust-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1.5rem;
    background: var(--bg-card);
    border-radius: 0.75rem;
    border: 1px solid var(--border);
}

.trust-item i {
    font-size: 2rem;
    color: var(--primary);
}

.trust-item div {
    display: flex;
    flex-direction: column;
}

.trust-item strong {
    font-size: 1.05rem;
    font-weight: 600;
    margin-bottom: 0.25rem;
}

.trust-item span {
    font-size: 0.875rem;
    color: var(--text-secondary);
}

.cta-subtext {
    margin-top: 1rem;
    font-size: 0.95rem;
    opacity: 0.8;
}

/* Footer Improvements */
.footer-content {
    display: grid;
    grid-template-columns: 1.5fr 1fr;
    gap: 4rem;
    padding: 3rem 0;
}

.footer-brand {
    max-width: 300px;
}

.footer-brand p {
    margin: 1rem 0 1.5rem;
    color: var(--text-secondary);
}

.footer-social {
    display: flex;
    gap: 1rem;
}

.footer-social a {
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(139, 92, 246, 0.1);
    border-radius: 0.5rem;
    color: var(--primary);
    transition: all 0.3s;
}

.footer-social a:hover {
    background: var(--primary);
    color: white;
    transform: translateY(-3px);
}

.footer-links-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
}

.footer-column h4 {
    font-size: 1rem;
    font-weight: 600;
    margin-bottom: 1rem;
    color: var(--text-primary);
}

.footer-column a {
    display: block;
    padding: 0.5rem 0;
    color: var(--text-secondary);
    transition: color 0.3s;
}

.footer-column a:hover {
    color: var(--primary-light);
}

.footer-bottom {
    text-align: center;
    padding-top: 2rem;
    border-top: 1px solid var(--border);
}

.footer-bottom p {
    color: var(--text-secondary);
    font-size: 0.9rem;
}

.footer-bottom p:first-child {
    margin-bottom: 0.5rem;
}

@media (max-width: 768px) {
    .hero-stats {
        gap: 1.5rem;
    }
    
    .stat {
        flex-direction: column;
        text-align: center;
    }
    
    .stat div {
        align-items: center;
    }
    
    .steps-grid {
        gap: 2rem;
    }
    
    .footer-content {
        grid-template-columns: 1fr;
        gap: 2rem;
    }
    
    .footer-links-grid {
        grid-template-columns: 1fr;
    }
}