/* ============================================
   NEXUS - AI Game Development Platform
   Design System: Volcanic Glass Gaming Theme
   ============================================ */

/* CSS Variables - Volcanic Glass Palette */
:root {
    /* Core Colors */
    --bg-primary: #0A0A0A;
    --bg-secondary: #141414;
    --bg-tertiary: #1A1A1A;
    --bg-elevated: #1F1F1F;
    --bg-card: #1A1A1A;
    
    /* Surface Colors */
    --surface-hover: #252525;
    --surface-active: #2A2A2A;
    --surface-pressed: #333333;
    
    /* Border Colors */
    --border-subtle: #2A2A2A;
    --border-default: #333333;
    --border-strong: #404040;
    
    /* Text Colors */
    --text-primary: #FFFFFF;
    --text-secondary: #A0A0A0;
    --text-tertiary: #666666;
    --text-muted: #444444;
    
    /* Accent Colors - Volcanic Orange */
    --accent-primary: #FF6B2B;
    --accent-secondary: #FFB088;
    --accent-tertiary: #FF4500;
    --accent-glow: rgba(255, 107, 43, 0.4);
    
    /* Status Colors */
    --success: #00D4AA;
    --warning: #FFB800;
    --error: #FF4757;
    --info: #7B68EE;
    
    /* Gradients */
    --gradient-primary: linear-gradient(135deg, #FF6B2B 0%, #FFB088 100%);
    --gradient-dark: linear-gradient(180deg, #1A1A1A 0%, #0A0A0A 100%);
    --gradient-glow: radial-gradient(ellipse at center, rgba(255, 107, 43, 0.15) 0%, transparent 70%);
    
    /* Typography */
    --font-display: 'Clash Grotesk', sans-serif;
    --font-body: 'Newsreader', Georgia, serif;
    
    /* Spacing */
    --space-xs: 0.25rem;
    --space-sm: 0.5rem;
    --space-md: 1rem;
    --space-lg: 1.5rem;
    --space-xl: 2rem;
    --space-2xl: 3rem;
    --space-3xl: 4rem;
    
    /* Border Radius */
    --radius-sm: 4px;
    --radius-md: 8px;
    --radius-lg: 12px;
    --radius-xl: 16px;
    --radius-full: 9999px;
    
    /* Shadows */
    --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.3);
    --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.4);
    --shadow-lg: 0 8px 24px rgba(0, 0, 0, 0.5);
    --shadow-glow: 0 0 40px rgba(255, 107, 43, 0.3);
    --shadow-glow-sm: 0 0 20px rgba(255, 107, 43, 0.2);
    
    /* Transitions */
    --transition-fast: 150ms ease;
    --transition-base: 250ms ease;
    --transition-slow: 350ms ease;
    --transition-bounce: 400ms cubic-bezier(0.34, 1.56, 0.64, 1);
    
    /* Z-index */
    --z-base: 1;
    --z-dropdown: 100;
    --z-sticky: 200;
    --z-modal: 300;
    --z-toast: 400;
}

/* Reset & 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: var(--font-body);
    background: var(--bg-primary);
    color: var(--text-primary);
    line-height: 1.6;
    min-height: 100vh;
    overflow-x: hidden;
}

/* Typography */
h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-display);
    font-weight: 600;
    line-height: 1.2;
    letter-spacing: -0.02em;
}

h1 { font-size: 2.5rem; }
h2 { font-size: 2rem; }
h3 { font-size: 1.5rem; }
h4 { font-size: 1.25rem; }

/* Layout */
#app {
    display: flex;
    min-height: 100vh;
}

/* Sidebar */
.sidebar {
    width: 280px;
    background: var(--bg-secondary);
    border-right: 1px solid var(--border-subtle);
    display: flex;
    flex-direction: column;
    position: fixed;
    height: 100vh;
    z-index: var(--z-sticky);
    transition: width var(--transition-base);
}

.sidebar.collapsed {
    width: 80px;
}

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

.logo {
    display: flex;
    align-items: center;
    gap: var(--space-sm);
}

.logo-icon {
    font-size: 1.75rem;
    color: var(--accent-primary);
    font-weight: 700;
}

.logo-text {
    font-family: var(--font-display);
    font-size: 1.5rem;
    font-weight: 700;
    letter-spacing: 0.05em;
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.sidebar.collapsed .logo-text {
    display: none;
}

.sidebar-toggle {
    background: transparent;
    border: none;
    color: var(--text-secondary);
    cursor: pointer;
    padding: var(--space-sm);
    border-radius: var(--radius-md);
    transition: all var(--transition-fast);
}

.sidebar-toggle:hover {
    background: var(--surface-hover);
    color: var(--text-primary);
}

/* Navigation */
.sidebar-nav {
    flex: 1;
    padding: var(--space-md);
    overflow-y: auto;
}

.nav-section {
    margin-bottom: var(--space-lg);
}

.nav-label {
    display: block;
    font-family: var(--font-display);
    font-size: 0.7rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--text-tertiary);
    padding: var(--space-sm) var(--space-md);
    margin-bottom: var(--space-xs);
}

.nav-item {
    display: flex;
    align-items: center;
    gap: var(--space-md);
    padding: var(--space-md);
    border-radius: var(--radius-lg);
    color: var(--text-secondary);
    text-decoration: none;
    transition: all var(--transition-fast);
    position: relative;
}

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

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

.nav-item svg {
    flex-shrink: 0;
}

.nav-badge {
    margin-left: auto;
    background: var(--accent-primary);
    color: var(--bg-primary);
    font-family: var(--font-display);
    font-size: 0.7rem;
    font-weight: 700;
    padding: 2px 8px;
    border-radius: var(--radius-full);
}

.sidebar.collapsed .nav-label,
.sidebar.collapsed .nav-item span:not(.nav-badge) {
    display: none;
}

/* Sidebar Footer */
.sidebar-footer {
    padding: var(--space-lg);
    border-top: 1px solid var(--border-subtle);
}

.storage-indicator {
    margin-bottom: var(--space-lg);
}

.storage-header {
    display: flex;
    justify-content: space-between;
    font-family: var(--font-display);
    font-size: 0.8rem;
    margin-bottom: var(--space-sm);
}

.storage-usage {
    color: var(--accent-primary);
    font-weight: 600;
}

.storage-bar {
    height: 4px;
    background: var(--bg-tertiary);
    border-radius: var(--radius-full);
    overflow: hidden;
    margin-bottom: var(--space-xs);
}

.storage-fill {
    height: 100%;
    background: var(--gradient-primary);
    border-radius: var(--radius-full);
    transition: width var(--transition-slow);
}

.storage-text {
    font-size: 0.75rem;
    color: var(--text-tertiary);
}

.user-profile {
    display: flex;
    align-items: center;
    gap: var(--space-md);
}

.user-avatar {
    width: 40px;
    height: 40px;
    background: var(--gradient-primary);
    border-radius: var(--radius-full);
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: var(--font-display);
    font-weight: 700;
    color: var(--bg-primary);
    font-size: 0.9rem;
}

.user-info {
    display: flex;
    flex-direction: column;
}

.user-name {
    font-family: var(--font-display);
    font-weight: 600;
    font-size: 0.9rem;
}

.user-plan {
    font-size: 0.75rem;
    color: var(--accent-primary);
}

.sidebar.collapsed .storage-indicator,
.sidebar.collapsed .user-info {
    display: none;
}

/* Main Content */
.main-content {
    flex: 1;
    margin-left: 280px;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

.sidebar.collapsed + .main-content {
    margin-left: 80px;
}

/* Top Bar */
.top-bar {
    height: 72px;
    background: var(--bg-secondary);
    border-bottom: 1px solid var(--border-subtle);
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 var(--space-xl);
    position: sticky;
    top: 0;
    z-index: var(--z-sticky);
}

.search-bar {
    display: flex;
    align-items: center;
    gap: var(--space-md);
    background: var(--bg-tertiary);
    border-radius: var(--radius-lg);
    padding: var(--space-sm) var(--space-md);
    width: 400px;
    border: 1px solid var(--border-subtle);
    transition: all var(--transition-fast);
}

.search-bar:focus-within {
    border-color: var(--accent-primary);
    box-shadow: 0 0 0 3px var(--accent-glow);
}

.search-bar svg {
    color: var(--text-tertiary);
}

.search-bar input {
    background: transparent;
    border: none;
    color: var(--text-primary);
    font-family: var(--font-body);
    font-size: 0.95rem;
    outline: none;
    width: 100%;
}

.search-bar input::placeholder {
    color: var(--text-tertiary);
}

.top-actions {
    display: flex;
    align-items: center;
    gap: var(--space-md);
}

.action-btn {
    background: transparent;
    border: none;
    color: var(--text-secondary);
    cursor: pointer;
    padding: var(--space-md);
    border-radius: var(--radius-lg);
    position: relative;
    transition: all var(--transition-fast);
}

.action-btn:hover {
    background: var(--surface-hover);
    color: var(--text-primary);
}

.notification-dot {
    position: absolute;
    top: 10px;
    right: 10px;
    width: 8px;
    height: 8px;
    background: var(--accent-primary);
    border-radius: var(--radius-full);
    box-shadow: 0 0 8px var(--accent-primary);
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: var(--space-sm);
    padding: var(--space-md) var(--space-lg);
    border-radius: var(--radius-lg);
    font-family: var(--font-display);
    font-weight: 600;
    font-size: 0.9rem;
    cursor: pointer;
    border: none;
    transition: all var(--transition-fast);
    text-decoration: none;
}

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

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-glow-sm);
}

.btn-primary.btn-glow {
    animation: glow-pulse 2s ease-in-out infinite;
}

@keyframes glow-pulse {
    0%, 100% { box-shadow: 0 0 20px rgba(255, 107, 43, 0.3); }
    50% { box-shadow: 0 0 40px rgba(255, 107, 43, 0.5); }
}

.btn-secondary {
    background: var(--bg-tertiary);
    color: var(--text-primary);
    border: 1px solid var(--border-default);
}

.btn-secondary:hover {
    background: var(--surface-hover);
    border-color: var(--border-strong);
}

.btn-sm {
    padding: var(--space-sm) var(--space-md);
    font-size: 0.8rem;
}

.btn-lg {
    padding: var(--space-lg) var(--space-xl);
    font-size: 1rem;
}

/* Views Container */
.views-container {
    flex: 1;
    padding: var(--space-xl);
    overflow-y: auto;
}

.view {
    display: none;
    animation: fadeIn 0.3s ease;
}

.view.active {
    display: block;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

.view-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: var(--space-xl);
}

.view-title {
    font-size: 2rem;
    margin-bottom: var(--space-xs);
}

.view-subtitle {
    color: var(--text-secondary);
    font-size: 1rem;
}

.view-actions {
    display: flex;
    gap: var(--space-md);
}

/* Stats Grid */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: var(--space-lg);
    margin-bottom: var(--space-2xl);
}

.stat-card {
    background: var(--bg-card);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-xl);
    padding: var(--space-lg);
    display: flex;
    align-items: center;
    gap: var(--space-lg);
    transition: all var(--transition-fast);
}

.stat-card:hover {
    border-color: var(--border-default);
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

.stat-icon {
    width: 56px;
    height: 56px;
    border-radius: var(--radius-lg);
    display: flex;
    align-items: center;
    justify-content: center;
}

.stat-value {
    display: block;
    font-family: var(--font-display);
    font-size: 1.75rem;
    font-weight: 700;
    color: var(--text-primary);
}

.stat-label {
    display: block;
    font-size: 0.85rem;
    color: var(--text-secondary);
    margin-top: 2px;
}

.stat-change {
    display: block;
    font-size: 0.75rem;
    margin-top: 4px;
}

.stat-change.positive {
    color: var(--success);
}

/* Sections */
.section {
    margin-bottom: var(--space-2xl);
}

.section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: var(--space-lg);
}

.section-title {
    font-size: 1.25rem;
}

.section-link {
    color: var(--accent-primary);
    text-decoration: none;
    font-family: var(--font-display);
    font-size: 0.9rem;
    font-weight: 500;
}

.section-link:hover {
    text-decoration: underline;
}

/* Games Grid */
.games-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: var(--space-lg);
}

.game-card {
    background: var(--bg-card);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-xl);
    overflow: hidden;
    transition: all var(--transition-fast);
    cursor: pointer;
}

.game-card:hover {
    border-color: var(--accent-primary);
    transform: translateY(-4px);
    box-shadow: var(--shadow-glow);
}

.game-thumbnail {
    aspect-ratio: 16/10;
    background: var(--gradient-dark);
    position: relative;
    overflow: hidden;
}

.game-thumbnail-placeholder {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 3rem;
}

.game-overlay {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.7);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity var(--transition-fast);
}

.game-card:hover .game-overlay {
    opacity: 1;
}

.game-play-btn {
    width: 60px;
    height: 60px;
    background: var(--gradient-primary);
    border-radius: var(--radius-full);
    display: flex;
    align-items: center;
    justify-content: center;
    transform: scale(0.8);
    transition: transform var(--transition-bounce);
}

.game-card:hover .game-play-btn {
    transform: scale(1);
}

.game-info {
    padding: var(--space-lg);
}

.game-title {
    font-family: var(--font-display);
    font-size: 1.1rem;
    font-weight: 600;
    margin-bottom: var(--space-xs);
}

.game-meta {
    display: flex;
    align-items: center;
    gap: var(--space-md);
    font-size: 0.8rem;
    color: var(--text-secondary);
}

.game-rating {
    display: flex;
    align-items: center;
    gap: 4px;
    color: var(--accent-secondary);
}

/* Quick Actions */
.quick-actions {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: var(--space-lg);
}

.quick-action-card {
    background: var(--bg-card);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-xl);
    padding: var(--space-xl);
    text-align: center;
    cursor: pointer;
    transition: all var(--transition-fast);
}

.quick-action-card:hover {
    border-color: var(--accent-primary);
    background: var(--surface-hover);
    transform: translateY(-4px);
}

.quick-action-icon {
    width: 64px;
    height: 64px;
    background: var(--gradient-primary);
    border-radius: var(--radius-lg);
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto var(--space-md);
    color: var(--bg-primary);
}

.quick-action-title {
    display: block;
    font-family: var(--font-display);
    font-weight: 600;
    margin-bottom: var(--space-xs);
}

.quick-action-desc {
    font-size: 0.85rem;
    color: var(--text-secondary);
}

/* Create Wizard */
.create-wizard {
    background: var(--bg-card);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-xl);
    overflow: hidden;
}

.wizard-steps {
    display: flex;
    border-bottom: 1px solid var(--border-subtle);
    padding: var(--space-lg) var(--space-xl);
    gap: var(--space-xl);
}

.wizard-step {
    display: flex;
    align-items: center;
    gap: var(--space-md);
    color: var(--text-tertiary);
}

.wizard-step.active {
    color: var(--accent-primary);
}

.wizard-step.completed {
    color: var(--success);
}

.step-number {
    width: 32px;
    height: 32px;
    border-radius: var(--radius-full);
    background: var(--bg-tertiary);
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: var(--font-display);
    font-weight: 700;
    font-size: 0.9rem;
}

.wizard-step.active .step-number {
    background: var(--accent-primary);
    color: var(--bg-primary);
}

.wizard-step.completed .step-number {
    background: var(--success);
    color: var(--bg-primary);
}

.step-label {
    font-family: var(--font-display);
    font-weight: 600;
    font-size: 0.9rem;
}

.wizard-content {
    padding: var(--space-xl);
}

.wizard-panel {
    display: none;
}

.wizard-panel.active {
    display: block;
    animation: fadeIn 0.3s ease;
}

/* AI Prompt */
.ai-prompt-container {
    max-width: 800px;
    margin: 0 auto;
}

.ai-prompt-header {
    display: flex;
    align-items: center;
    gap: var(--space-lg);
    margin-bottom: var(--space-xl);
}

.ai-avatar {
    width: 64px;
    height: 64px;
    background: var(--gradient-primary);
    border-radius: var(--radius-lg);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--bg-primary);
}

.ai-prompt-title h3 {
    margin-bottom: var(--space-xs);
}

.ai-prompt-title p {
    color: var(--text-secondary);
}

.prompt-input-container {
    margin-bottom: var(--space-lg);
}

.prompt-input {
    width: 100%;
    min-height: 160px;
    background: var(--bg-tertiary);
    border: 1px solid var(--border-default);
    border-radius: var(--radius-lg);
    padding: var(--space-lg);
    color: var(--text-primary);
    font-family: var(--font-body);
    font-size: 1rem;
    resize: vertical;
    transition: all var(--transition-fast);
}

.prompt-input:focus {
    outline: none;
    border-color: var(--accent-primary);
    box-shadow: 0 0 0 3px var(--accent-glow);
}

.prompt-suggestions {
    display: flex;
    align-items: center;
    gap: var(--space-sm);
    margin-top: var(--space-md);
    flex-wrap: wrap;
}

.suggestion-label {
    font-size: 0.85rem;
    color: var(--text-tertiary);
}

.suggestion-chip {
    background: var(--bg-elevated);
    border: 1px solid var(--border-default);
    border-radius: var(--radius-full);
    padding: var(--space-sm) var(--space-md);
    font-size: 0.85rem;
    color: var(--text-secondary);
    cursor: pointer;
    transition: all var(--transition-fast);
}

.suggestion-chip:hover {
    background: var(--surface-hover);
    border-color: var(--accent-primary);
    color: var(--accent-primary);
}

.prompt-actions {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

/* Config Grid */
.config-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: var(--space-2xl);
    margin-bottom: var(--space-xl);
}

.config-section h4 {
    margin-bottom: var(--space-lg);
    padding-bottom: var(--space-md);
    border-bottom: 1px solid var(--border-subtle);
}

.form-group {
    margin-bottom: var(--space-lg);
}

.form-group label {
    display: block;
    font-family: var(--font-display);
    font-size: 0.85rem;
    font-weight: 600;
    margin-bottom: var(--space-sm);
    color: var(--text-secondary);
}

.form-input,
.form-select {
    width: 100%;
    background: var(--bg-tertiary);
    border: 1px solid var(--border-default);
    border-radius: var(--radius-md);
    padding: var(--space-md);
    color: var(--text-primary);
    font-family: var(--font-body);
    font-size: 0.95rem;
    transition: all var(--transition-fast);
}

.form-input:focus,
.form-select:focus {
    outline: none;
    border-color: var(--accent-primary);
}

.platform-selector {
    display: flex;
    gap: var(--space-md);
}

.platform-option {
    flex: 1;
    cursor: pointer;
}

.platform-option input {
    display: none;
}

.platform-box {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: var(--space-sm);
    padding: var(--space-lg);
    background: var(--bg-tertiary);
    border: 1px solid var(--border-default);
    border-radius: var(--radius-lg);
    transition: all var(--transition-fast);
}

.platform-option input:checked + .platform-box {
    border-color: var(--accent-primary);
    background: var(--surface-hover);
}

.form-range {
    width: 100%;
    height: 6px;
    -webkit-appearance: none;
    background: var(--bg-tertiary);
    border-radius: var(--radius-full);
    outline: none;
}

.form-range::-webkit-slider-thumb {
    -webkit-appearance: none;
    width: 20px;
    height: 20px;
    background: var(--gradient-primary);
    border-radius: var(--radius-full);
    cursor: pointer;
}

.range-labels {
    display: flex;
    justify-content: space-between;
    font-size: 0.8rem;
    color: var(--text-tertiary);
    margin-top: var(--space-xs);
}

.toggle-group {
    display: flex;
    flex-direction: column;
    gap: var(--space-md);
}

.toggle {
    display: flex;
    align-items: center;
    gap: var(--space-md);
    cursor: pointer;
}

.toggle input {
    display: none;
}

.toggle-slider {
    width: 48px;
    height: 24px;
    background: var(--bg-tertiary);
    border-radius: var(--radius-full);
    position: relative;
    transition: all var(--transition-fast);
}

.toggle-slider::after {
    content: '';
    position: absolute;
    top: 2px;
    left: 2px;
    width: 20px;
    height: 20px;
    background: var(--text-secondary);
    border-radius: var(--radius-full);
    transition: all var(--transition-fast);
}

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

.toggle input:checked + .toggle-slider::after {
    left: 26px;
    background: var(--bg-primary);
}

.toggle-label {
    font-size: 0.9rem;
    color: var(--text-secondary);
}

.wizard-actions {
    display: flex;
    justify-content: space-between;
    padding-top: var(--space-lg);
    border-top: 1px solid var(--border-subtle);
}

/* Generation Status */
.generation-status {
    text-align: center;
    padding: var(--space-3xl);
}

.generation-animation {
    display: flex;
    justify-content: center;
    gap: var(--space-md);
    margin-bottom: var(--space-xl);
}

.gen-cube {
    width: 16px;
    height: 16px;
    background: var(--accent-primary);
    border-radius: var(--radius-sm);
    animation: cube-bounce 1.4s ease-in-out infinite;
}

.gen-cube:nth-child(2) {
    animation-delay: 0.2s;
}

.gen-cube:nth-child(3) {
    animation-delay: 0.4s;
}

@keyframes cube-bounce {
    0%, 80%, 100% { transform: scale(0.6); opacity: 0.5; }
    40% { transform: scale(1); opacity: 1; }
}

.generation-progress-text {
    color: var(--text-secondary);
    margin-bottom: var(--space-xl);
}

.generation-tasks {
    max-width: 400px;
    margin: 0 auto;
}

.gen-task {
    display: flex;
    align-items: center;
    gap: var(--space-md);
    padding: var(--space-md);
    color: var(--text-tertiary);
    transition: all var(--transition-fast);
}

.gen-task.completed {
    color: var(--success);
}

.gen-task.active {
    color: var(--accent-primary);
}

.gen-task svg {
    opacity: 0;
}

.gen-task.completed svg {
    opacity: 1;
}

/* Preview */
.preview-container {
    display: flex;
    flex-direction: column;
    gap: var(--space-lg);
}

.game-preview {
    aspect-ratio: 16/9;
    background: var(--bg-tertiary);
    border-radius: var(--radius-lg);
    display: flex;
    align-items: center;
    justify-content: center;
}

.preview-placeholder {
    text-align: center;
    color: var(--text-tertiary);
}

.preview-placeholder svg {
    margin-bottom: var(--space-md);
}

.preview-actions {
    display: flex;
    justify-content: center;
    gap: var(--space-md);
}

/* Editor Layout */
.editor-layout {
    display: grid;
    grid-template-columns: 240px 1fr 280px;
    gap: var(--space-lg);
    height: calc(100vh - 200px);
}

.editor-sidebar {
    background: var(--bg-card);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-xl);
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.editor-tabs {
    display: flex;
    border-bottom: 1px solid var(--border-subtle);
}

.editor-tab {
    flex: 1;
    padding: var(--space-md);
    background: transparent;
    border: none;
    color: var(--text-secondary);
    font-family: var(--font-display);
    font-size: 0.85rem;
    font-weight: 600;
    cursor: pointer;
    transition: all var(--transition-fast);
}

.editor-tab.active {
    color: var(--accent-primary);
    border-bottom: 2px solid var(--accent-primary);
}

.editor-panel {
    flex: 1;
    padding: var(--space-md);
    display: none;
}

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

.scene-tree {
    display: flex;
    flex-direction: column;
    gap: var(--space-xs);
}

.scene-item {
    display: flex;
    align-items: center;
    gap: var(--space-sm);
    padding: var(--space-sm) var(--space-md);
    border-radius: var(--radius-md);
    color: var(--text-secondary);
    cursor: pointer;
    transition: all var(--transition-fast);
}

.scene-item:hover,
.scene-item.active {
    background: var(--surface-hover);
    color: var(--text-primary);
}

.editor-main {
    background: var(--bg-card);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-xl);
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.editor-toolbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: var(--space-md) var(--space-lg);
    border-bottom: 1px solid var(--border-subtle);
}

.toolbar-group {
    display: flex;
    gap: var(--space-xs);
}

.toolbar-btn {
    background: transparent;
    border: none;
    color: var(--text-secondary);
    padding: var(--space-sm);
    border-radius: var(--radius-md);
    cursor: pointer;
    transition: all var(--transition-fast);
}

.toolbar-btn:hover,
.toolbar-btn.active {
    background: var(--surface-hover);
    color: var(--text-primary);
}

.editor-canvas {
    flex: 1;
    position: relative;
    overflow: hidden;
}

.canvas-grid {
    position: absolute;
    inset: 0;
    background-image: 
        linear-gradient(var(--border-subtle) 1px, transparent 1px),
        linear-gradient(90deg, var(--border-subtle) 1px, transparent 1px);
    background-size: 40px 40px;
    opacity: 0.3;
}

.canvas-content {
    position: relative;
    width: 100%;
    height: 100%;
}

.game-object {
    position: absolute;
    display: flex;
    flex-direction: column;
    align-items: center;
    cursor: move;
}

.object-sprite {
    width: 48px;
    height: 48px;
    background: var(--bg-elevated);
    border: 2px solid var(--accent-primary);
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
}

.object-label {
    margin-top: var(--space-xs);
    font-size: 0.75rem;
    color: var(--text-secondary);
    background: var(--bg-elevated);
    padding: 2px 8px;
    border-radius: var(--radius-sm);
}

.editor-inspector {
    background: var(--bg-card);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-xl);
    padding: var(--space-lg);
}

.editor-inspector h4 {
    margin-bottom: var(--space-lg);
    padding-bottom: var(--space-md);
    border-bottom: 1px solid var(--border-subtle);
}

.inspector-section {
    margin-bottom: var(--space-lg);
}

.inspector-section label {
    display: block;
    font-size: 0.8rem;
    color: var(--text-secondary);
    margin-bottom: var(--space-sm);
}

.input-row {
    display: flex;
    gap: var(--space-md);
}

.input-group {
    flex: 1;
    display: flex;
    align-items: center;
    gap: var(--space-sm);
    background: var(--bg-tertiary);
    border-radius: var(--radius-md);
    padding: var(--space-sm) var(--space-md);
}

.input-group span {
    font-size: 0.8rem;
    color: var(--text-tertiary);
}

.input-group input {
    flex: 1;
    background: transparent;
    border: none;
    color: var(--text-primary);
    font-size: 0.9rem;
    outline: none;
}

.sprite-preview {
    width: 100%;
    aspect-ratio: 1;
    background: var(--bg-tertiary);
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 3rem;
}

/* Builds */
.builds-container {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(360px, 1fr));
    gap: var(--space-lg);
}

.build-card {
    background: var(--bg-card);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-xl);
    padding: var(--space-lg);
    transition: all var(--transition-fast);
}

.build-card:hover {
    border-color: var(--border-default);
}

.build-header {
    display: flex;
    align-items: center;
    gap: var(--space-md);
    margin-bottom: var(--space-lg);
}

.build-platform {
    color: var(--accent-primary);
}

.build-info h4 {
    margin-bottom: 2px;
}

.build-version {
    font-size: 0.8rem;
    color: var(--text-tertiary);
}

.build-status {
    margin-left: auto;
    padding: var(--space-xs) var(--space-md);
    border-radius: var(--radius-full);
    font-size: 0.75rem;
    font-weight: 600;
    font-family: var(--font-display);
}

.build-status.success {
    background: rgba(0, 212, 170, 0.1);
    color: var(--success);
}

.build-status.building {
    background: rgba(255, 107, 43, 0.1);
    color: var(--accent-primary);
}

.build-details {
    display: flex;
    gap: var(--space-xl);
    margin-bottom: var(--space-lg);
}

.build-stat {
    display: flex;
    flex-direction: column;
}

.build-stat .stat-label {
    font-size: 0.75rem;
    color: var(--text-tertiary);
}

.build-stat .stat-value {
    font-family: var(--font-display);
    font-weight: 600;
    color: var(--text-primary);
}

.build-progress {
    margin-bottom: var(--space-lg);
}

.progress-bar {
    height: 6px;
    background: var(--bg-tertiary);
    border-radius: var(--radius-full);
    overflow: hidden;
    margin-bottom: var(--space-sm);
}

.progress-fill {
    height: 100%;
    background: var(--gradient-primary);
    border-radius: var(--radius-full);
    transition: width var(--transition-slow);
}

.progress-text {
    font-size: 0.8rem;
    color: var(--text-secondary);
}

.build-actions {
    display: flex;
    gap: var(--space-md);
}

/* Downloads */
.downloads-section {
    margin-bottom: var(--space-2xl);
}

.section-subtitle {
    font-size: 1rem;
    margin-bottom: var(--space-lg);
    color: var(--text-secondary);
}

.download-item {
    display: flex;
    align-items: center;
    gap: var(--space-lg);
    background: var(--bg-card);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-lg);
    padding: var(--space-lg);
    margin-bottom: var(--space-md);
    transition: all var(--transition-fast);
}

.download-item:hover {
    border-color: var(--border-default);
}

.download-icon {
    width: 48px;
    height: 48px;
    background: var(--bg-tertiary);
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--accent-primary);
}

.download-info {
    flex: 1;
}

.download-info h4 {
    margin-bottom: 4px;
}

.download-meta {
    font-size: 0.85rem;
    color: var(--text-secondary);
}

.download-progress {
    width: 200px;
}

.download-actions {
    display: flex;
    gap: var(--space-sm);
}

.action-icon {
    width: 40px;
    height: 40px;
    background: transparent;
    border: none;
    color: var(--text-secondary);
    border-radius: var(--radius-md);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all var(--transition-fast);
}

.action-icon:hover {
    background: var(--surface-hover);
    color: var(--text-primary);
}

/* QR Download */
.qr-container {
    display: flex;
    align-items: center;
    gap: var(--space-xl);
    background: var(--bg-card);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-xl);
    padding: var(--space-xl);
}

.qr-code {
    width: 160px;
    height: 160px;
    background: var(--bg-tertiary);
    border-radius: var(--radius-lg);
    display: flex;
    align-items: center;
    justify-content: center;
}

.qr-placeholder {
    font-family: var(--font-display);
    font-size: 2rem;
    font-weight: 700;
    color: var(--text-tertiary);
}

.qr-info p {
    color: var(--text-secondary);
    margin-bottom: var(--space-lg);
    max-width: 300px;
}

/* Testing */
.testing-stats {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: var(--space-lg);
    margin-bottom: var(--space-2xl);
}

.test-stat-card {
    background: var(--bg-card);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-xl);
    padding: var(--space-xl);
    text-align: center;
}

.test-stat-value {
    display: block;
    font-family: var(--font-display);
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--accent-primary);
    margin-bottom: var(--space-xs);
}

.test-stat-label {
    font-size: 0.9rem;
    color: var(--text-secondary);
}

.tester-list {
    background: var(--bg-card);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-xl);
    overflow: hidden;
}

.tester-item {
    display: flex;
    align-items: center;
    gap: var(--space-lg);
    padding: var(--space-lg);
    border-bottom: 1px solid var(--border-subtle);
}

.tester-item:last-child {
    border-bottom: none;
}

.tester-avatar {
    width: 48px;
    height: 48px;
    background: var(--gradient-primary);
    border-radius: var(--radius-full);
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: var(--font-display);
    font-weight: 700;
    color: var(--bg-primary);
}

.tester-info {
    flex: 1;
}

.tester-info h4 {
    margin-bottom: 4px;
}

.tester-meta {
    font-size: 0.85rem;
    color: var(--text-secondary);
}

.tester-status {
    padding: var(--space-xs) var(--space-md);
    border-radius: var(--radius-full);
    font-size: 0.75rem;
    font-weight: 600;
    font-family: var(--font-display);
}

.tester-status.active {
    background: rgba(0, 212, 170, 0.1);
    color: var(--success);
}

/* Publish */
.publish-wizard {
    max-width: 800px;
}

.publish-step {
    background: var(--bg-card);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-xl);
    padding: var(--space-xl);
    margin-bottom: var(--space-xl);
}

.step-indicator {
    width: 40px;
    height: 40px;
    background: var(--accent-primary);
    border-radius: var(--radius-full);
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: var(--font-display);
    font-weight: 700;
    color: var(--bg-primary);
    margin-bottom: var(--space-lg);
}

.publish-platforms h3 {
    margin-bottom: var(--space-lg);
}

.platform-cards {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: var(--space-lg);
}

.platform-card {
    cursor: pointer;
}

.platform-card input {
    display: none;
}

.platform-content {
    background: var(--bg-tertiary);
    border: 2px solid transparent;
    border-radius: var(--radius-xl);
    padding: var(--space-xl);
    text-align: center;
    transition: all var(--transition-fast);
}

.platform-card input:checked + .platform-content {
    border-color: var(--accent-primary);
    background: var(--surface-hover);
}

.platform-content svg {
    color: var(--accent-primary);
    margin-bottom: var(--space-md);
}

.platform-content h4 {
    margin-bottom: var(--space-xs);
}

.platform-content p {
    font-size: 0.85rem;
    color: var(--text-secondary);
}

.publish-actions {
    display: flex;
    justify-content: flex-end;
    gap: var(--space-md);
}

/* Versions */
.version-timeline {
    position: relative;
    padding-left: var(--space-xl);
}

.version-timeline::before {
    content: '';
    position: absolute;
    left: 6px;
    top: 0;
    bottom: 0;
    width: 2px;
    background: var(--border-default);
}

.version-item {
    position: relative;
    padding-bottom: var(--space-xl);
}

.version-marker {
    position: absolute;
    left: -18px;
    width: 14px;
    height: 14px;
    background: var(--border-default);
    border-radius: var(--radius-full);
    border: 3px solid var(--bg-primary);
}

.version-item.current .version-marker {
    background: var(--accent-primary);
    box-shadow: 0 0 0 4px rgba(255, 107, 43, 0.2);
}

.version-card {
    background: var(--bg-card);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-xl);
    padding: var(--space-lg);
}

.version-header {
    display: flex;
    align-items: center;
    gap: var(--space-md);
    margin-bottom: var(--space-sm);
}

.version-badge {
    padding: var(--space-xs) var(--space-md);
    border-radius: var(--radius-full);
    font-size: 0.7rem;
    font-weight: 600;
    font-family: var(--font-display);
    text-transform: uppercase;
}

.version-badge.current {
    background: var(--accent-primary);
    color: var(--bg-primary);
}

.version-badge:not(.current) {
    background: var(--bg-tertiary);
    color: var(--text-secondary);
}

.version-desc {
    color: var(--text-secondary);
    margin-bottom: var(--space-sm);
}

.version-date {
    font-size: 0.8rem;
    color: var(--text-tertiary);
}

/* Store */
.store-header {
    margin: calc(var(--space-xl) * -1);
    margin-bottom: var(--space-xl);
    padding: var(--space-3xl) var(--space-xl);
    background: var(--gradient-glow), var(--bg-secondary);
    border-bottom: 1px solid var(--border-subtle);
}

.store-hero {
    text-align: center;
    max-width: 600px;
    margin: 0 auto;
}

.store-title {
    font-size: 3rem;
    margin-bottom: var(--space-md);
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.store-subtitle {
    color: var(--text-secondary);
    margin-bottom: var(--space-xl);
}

.store-search {
    display: flex;
    align-items: center;
    gap: var(--space-md);
    background: var(--bg-card);
    border: 1px solid var(--border-default);
    border-radius: var(--radius-lg);
    padding: var(--space-md) var(--space-lg);
    max-width: 500px;
    margin: 0 auto;
}

.store-search svg {
    color: var(--text-tertiary);
}

.store-search input {
    flex: 1;
    background: transparent;
    border: none;
    color: var(--text-primary);
    font-size: 1rem;
    outline: none;
}

.store-categories {
    display: flex;
    gap: var(--space-md);
    margin-bottom: var(--space-xl);
    flex-wrap: wrap;
}

.category-btn {
    background: var(--bg-card);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-full);
    padding: var(--space-sm) var(--space-lg);
    color: var(--text-secondary);
    font-family: var(--font-display);
    font-size: 0.9rem;
    cursor: pointer;
    transition: all var(--transition-fast);
}

.category-btn:hover,
.category-btn.active {
    background: var(--accent-primary);
    border-color: var(--accent-primary);
    color: var(--bg-primary);
}

.store-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: var(--space-lg);
}

/* Analytics */
.analytics-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: var(--space-lg);
}

.analytics-card {
    background: var(--bg-card);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-xl);
    padding: var(--space-xl);
}

.analytics-card.wide {
    grid-column: span 2;
}

.analytics-card h4 {
    margin-bottom: var(--space-lg);
    padding-bottom: var(--space-md);
    border-bottom: 1px solid var(--border-subtle);
}

.metric-large {
    font-family: var(--font-display);
    font-size: 3rem;
    font-weight: 700;
    color: var(--accent-primary);
}

.metric-change {
    font-size: 0.9rem;
}

.metric-change.positive {
    color: var(--success);
}

.chart-container {
    height: 200px;
}

.chart-placeholder {
    height: 100%;
    display: flex;
    align-items: flex-end;
    justify-content: space-around;
    padding: var(--space-lg) 0;
}

.chart-bars {
    display: flex;
    align-items: flex-end;
    gap: var(--space-md);
    width: 100%;
    height: 100%;
}

.bar {
    flex: 1;
    background: var(--gradient-primary);
    border-radius: var(--radius-sm) var(--radius-sm) 0 0;
    min-height: 20px;
    opacity: 0.8;
    transition: opacity var(--transition-fast);
}

.bar:hover {
    opacity: 1;
}

.platform-chart {
    display: flex;
    height: 40px;
    border-radius: var(--radius-md);
    overflow: hidden;
}

.platform-segment {
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--bg-primary);
}

.platform-segment.web {
    background: var(--accent-primary);
}

.platform-segment.mobile {
    background: var(--accent-secondary);
}

.platform-segment.desktop {
    background: var(--accent-tertiary);
}

/* Reviews */
.reviews-summary {
    display: flex;
    align-items: center;
    gap: var(--space-xl);
    background: var(--bg-card);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-xl);
    padding: var(--space-xl);
    margin-bottom: var(--space-xl);
}

.rating-big {
    font-family: var(--font-display);
    font-size: 4rem;
    font-weight: 700;
    color: var(--accent-primary);
}

.rating-stars {
    display: flex;
    gap: 4px;
    color: var(--accent-secondary);
}

.reviews-count {
    color: var(--text-secondary);
}

.reviews-list {
    display: flex;
    flex-direction: column;
    gap: var(--space-lg);
}

.review-item {
    background: var(--bg-card);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-xl);
    padding: var(--space-xl);
}

.review-header {
    display: flex;
    align-items: center;
    gap: var(--space-md);
    margin-bottom: var(--space-md);
}

.reviewer-avatar {
    width: 48px;
    height: 48px;
    background: var(--gradient-primary);
    border-radius: var(--radius-full);
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: var(--font-display);
    font-weight: 700;
    color: var(--bg-primary);
}

.reviewer-info {
    flex: 1;
}

.reviewer-info h4 {
    margin-bottom: 4px;
}

.review-rating {
    display: flex;
    gap: 2px;
    color: var(--accent-secondary);
}

.review-date {
    font-size: 0.85rem;
    color: var(--text-tertiary);
}

.review-text {
    color: var(--text-secondary);
    line-height: 1.7;
}

/* Toast Notifications */
.toast-container {
    position: fixed;
    bottom: var(--space-xl);
    right: var(--space-xl);
    z-index: var(--z-toast);
    display: flex;
    flex-direction: column;
    gap: var(--space-md);
}

.toast {
    background: var(--bg-card);
    border: 1px solid var(--border-default);
    border-radius: var(--radius-lg);
    padding: var(--space-lg);
    display: flex;
    align-items: center;
    gap: var(--space-md);
    box-shadow: var(--shadow-lg);
    animation: slideIn 0.3s ease;
}

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

.toast.success {
    border-color: var(--success);
}

.toast.error {
    border-color: var(--error);
}

/* Modal */
.modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.8);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: var(--z-modal);
    backdrop-filter: blur(8px);
}

.modal-overlay.active {
    display: flex;
}

.modal {
    background: var(--bg-card);
    border: 1px solid var(--border-default);
    border-radius: var(--radius-xl);
    width: 90%;
    max-width: 500px;
    animation: modalIn 0.3s ease;
}

@keyframes modalIn {
    from {
        transform: scale(0.9);
        opacity: 0;
    }
    to {
        transform: scale(1);
        opacity: 1;
    }
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: var(--space-lg) var(--space-xl);
    border-bottom: 1px solid var(--border-subtle);
}

.modal-close {
    background: transparent;
    border: none;
    color: var(--text-secondary);
    cursor: pointer;
    padding: var(--space-sm);
    border-radius: var(--radius-md);
    transition: all var(--transition-fast);
}

.modal-close:hover {
    background: var(--surface-hover);
    color: var(--text-primary);
}

.modal-body {
    padding: var(--space-xl);
}

.share-link-container {
    display: flex;
    gap: var(--space-md);
    margin-bottom: var(--space-xl);
}

.share-input {
    flex: 1;
    background: var(--bg-tertiary);
    border: 1px solid var(--border-default);
    border-radius: var(--radius-md);
    padding: var(--space-md);
    color: var(--text-primary);
    font-size: 0.9rem;
}

.share-options {
    display: flex;
    gap: var(--space-md);
}

.share-option {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: var(--space-sm);
    padding: var(--space-lg);
    background: var(--bg-tertiary);
    border: 1px solid var(--border-default);
    border-radius: var(--radius-lg);
    color: var(--text-secondary);
    cursor: pointer;
    transition: all var(--transition-fast);
}

.share-option:hover {
    border-color: var(--accent-primary);
    color: var(--text-primary);
}

/* Branding & Customization Styles */
.branding-layout {
    display: grid;
    grid-template-columns: 1fr 400px;
    gap: var(--space-xl);
    height: calc(100vh - 200px);
}

.branding-settings {
    overflow-y: auto;
    padding-right: var(--space-md);
}

.branding-section {
    background: var(--bg-card);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-xl);
    margin-bottom: var(--space-lg);
    overflow: hidden;
}

.section-header-collapsible {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: var(--space-lg);
    cursor: pointer;
    transition: background var(--transition-fast);
}

.section-header-collapsible:hover {
    background: var(--surface-hover);
}

.section-header-collapsible h3 {
    font-size: 1rem;
    margin: 0;
}

.section-header-collapsible svg {
    transition: transform var(--transition-fast);
}

.section-header-collapsible.collapsed svg {
    transform: rotate(-90deg);
}

.section-content {
    padding: 0 var(--space-lg) var(--space-lg);
    display: block;
}

.section-content.collapsed {
    display: none;
}

/* Logo Upload */
.logo-upload-area {
    display: flex;
    align-items: center;
    gap: var(--space-lg);
    padding: var(--space-lg);
    background: var(--bg-tertiary);
    border: 2px dashed var(--border-default);
    border-radius: var(--radius-lg);
    margin-bottom: var(--space-lg);
    transition: all var(--transition-fast);
}

.logo-upload-area:hover {
    border-color: var(--accent-primary);
}

.logo-preview {
    width: 80px;
    height: 80px;
    background: var(--bg-card);
    border-radius: var(--radius-lg);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--accent-primary);
}

.logo-upload-info h4 {
    margin-bottom: var(--space-xs);
    font-size: 0.95rem;
}

.logo-upload-info p {
    font-size: 0.8rem;
    color: var(--text-secondary);
    margin-bottom: var(--space-sm);
}

/* Icon Sizes Grid */
.icon-sizes-grid {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: var(--space-md);
    margin-bottom: var(--space-lg);
}

.icon-size-item {
    text-align: center;
}

.icon-preview {
    width: 48px;
    height: 48px;
    background: var(--bg-tertiary);
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto var(--space-sm);
    font-family: var(--font-display);
    font-weight: 700;
    font-size: 0.8rem;
    color: var(--text-primary);
}

.icon-size-item span {
    font-size: 0.7rem;
    color: var(--text-tertiary);
}

/* Color Presets */
.color-presets {
    display: flex;
    align-items: center;
    gap: var(--space-sm);
    margin-bottom: var(--space-lg);
    flex-wrap: wrap;
}

.preset-label {
    font-size: 0.85rem;
    color: var(--text-secondary);
}

.color-preset {
    width: 32px;
    height: 32px;
    border-radius: var(--radius-full);
    border: 2px solid transparent;
    cursor: pointer;
    transition: all var(--transition-fast);
}

.color-preset:hover {
    transform: scale(1.1);
    border-color: var(--text-primary);
}

/* Color Custom Grid */
.color-custom-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: var(--space-md);
}

.color-picker-item label {
    display: block;
    font-size: 0.8rem;
    color: var(--text-secondary);
    margin-bottom: var(--space-sm);
}

.color-input-wrapper {
    display: flex;
    align-items: center;
    gap: var(--space-md);
    background: var(--bg-tertiary);
    border-radius: var(--radius-md);
    padding: var(--space-sm);
}

.color-input-wrapper input[type="color"] {
    width: 40px;
    height: 40px;
    border: none;
    border-radius: var(--radius-sm);
    cursor: pointer;
    background: transparent;
}

.color-value {
    font-family: monospace;
    font-size: 0.85rem;
    color: var(--text-secondary);
}

/* Splash Options */
.splash-options {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: var(--space-md);
    margin-bottom: var(--space-lg);
}

.splash-option {
    cursor: pointer;
}

.splash-option input {
    display: none;
}

.splash-option-content {
    background: var(--bg-tertiary);
    border: 2px solid transparent;
    border-radius: var(--radius-lg);
    padding: var(--space-lg);
    text-align: center;
    transition: all var(--transition-fast);
}

.splash-option input:checked + .splash-option-content {
    border-color: var(--accent-primary);
    background: var(--surface-hover);
}

.splash-preview-mini {
    width: 64px;
    height: 64px;
    background: var(--bg-card);
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto var(--space-sm);
    color: var(--accent-primary);
}

.splash-option-content span {
    font-size: 0.8rem;
    color: var(--text-secondary);
}

/* Upload Area */
.upload-area {
    border: 2px dashed var(--border-default);
    border-radius: var(--radius-lg);
    padding: var(--space-xl);
    text-align: center;
    cursor: pointer;
    transition: all var(--transition-fast);
}

.upload-area:hover {
    border-color: var(--accent-primary);
    background: var(--surface-hover);
}

.upload-area svg {
    color: var(--text-tertiary);
    margin-bottom: var(--space-md);
}

.upload-area span {
    display: block;
    color: var(--text-secondary);
    margin-bottom: var(--space-xs);
}

.upload-hint {
    font-size: 0.75rem;
    color: var(--text-tertiary);
}

/* Range with Value */
.range-with-value {
    display: flex;
    align-items: center;
    gap: var(--space-md);
}

.range-with-value .form-range {
    flex: 1;
}

.range-value {
    font-family: var(--font-display);
    font-size: 0.9rem;
    color: var(--text-primary);
    min-width: 40px;
    text-align: right;
}

/* Export Options */
.export-options {
    display: flex;
    flex-direction: column;
    gap: var(--space-md);
}

.export-option {
    display: block;
    cursor: pointer;
}

.export-option-header {
    display: flex;
    align-items: flex-start;
    gap: var(--space-md);
    padding: var(--space-md);
    background: var(--bg-tertiary);
    border-radius: var(--radius-md);
    transition: all var(--transition-fast);
}

.export-option-header:hover {
    background: var(--surface-hover);
}

.export-option-header input[type="checkbox"] {
    margin-top: 2px;
}

.export-option-info h4 {
    font-size: 0.9rem;
    margin-bottom: 2px;
}

.export-option-info p {
    font-size: 0.8rem;
    color: var(--text-secondary);
}

/* Branding Preview */
.branding-preview {
    display: flex;
    flex-direction: column;
    background: var(--bg-card);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-xl);
    overflow: hidden;
}

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

.preview-header h3 {
    font-size: 1rem;
}

.preview-device-toggle {
    display: flex;
    gap: var(--space-xs);
    background: var(--bg-tertiary);
    border-radius: var(--radius-md);
    padding: var(--space-xs);
}

.device-btn {
    background: transparent;
    border: none;
    color: var(--text-secondary);
    padding: var(--space-sm);
    border-radius: var(--radius-sm);
    cursor: pointer;
    transition: all var(--transition-fast);
}

.device-btn:hover,
.device-btn.active {
    background: var(--surface-hover);
    color: var(--text-primary);
}

.preview-container {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: var(--space-xl);
    background: var(--bg-tertiary);
}

.device-frame {
    background: var(--bg-primary);
    border-radius: var(--radius-xl);
    padding: var(--space-md);
    box-shadow: var(--shadow-lg);
    transition: all var(--transition-base);
}

.device-frame.phone {
    width: 280px;
    height: 560px;
}

.device-frame.tablet {
    width: 400px;
    height: 560px;
}

.device-frame.desktop {
    width: 500px;
    height: 350px;
}

.device-screen {
    width: 100%;
    height: 100%;
    background: var(--bg-primary);
    border-radius: var(--radius-lg);
    overflow: hidden;
    position: relative;
}

/* Preview Splash */
.preview-splash {
    position: absolute;
    inset: 0;
    background: var(--bg-primary);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    z-index: 10;
    transition: opacity 0.5s ease;
}

.preview-splash.hidden {
    opacity: 0;
    pointer-events: none;
}

.splash-logo {
    color: var(--accent-primary);
    margin-bottom: var(--space-lg);
}

.splash-app-name {
    font-family: var(--font-display);
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: var(--space-xl);
}

.splash-loading {
    width: 120px;
    height: 4px;
    background: var(--bg-tertiary);
    border-radius: var(--radius-full);
    overflow: hidden;
}

.loading-bar {
    height: 100%;
    width: 0%;
    background: var(--gradient-primary);
    border-radius: var(--radius-full);
    animation: loading 2s ease-in-out infinite;
}

@keyframes loading {
    0% { width: 0%; margin-left: 0; }
    50% { width: 100%; margin-left: 0; }
    100% { width: 0%; margin-left: 100%; }
}

/* Preview App */
.preview-app {
    height: 100%;
    display: flex;
    flex-direction: column;
}

.preview-nav {
    display: flex;
    align-items: center;
    gap: var(--space-md);
    padding: var(--space-md);
    border-bottom: 1px solid var(--border-subtle);
}

.nav-logo {
    width: 32px;
    height: 32px;
    background: var(--accent-primary);
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: var(--font-display);
    font-weight: 700;
    font-size: 0.7rem;
    color: var(--bg-primary);
}

.nav-title {
    font-family: var(--font-display);
    font-weight: 600;
    font-size: 0.9rem;
}

.preview-content-area {
    flex: 1;
    padding: var(--space-md);
    display: flex;
    flex-direction: column;
    gap: var(--space-md);
    overflow-y: auto;
}

.preview-card {
    display: flex;
    align-items: center;
    gap: var(--space-md);
    padding: var(--space-md);
    background: var(--bg-tertiary);
    border-radius: var(--radius-md);
}

.card-icon {
    width: 40px;
    height: 40px;
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
}

.card-content h4 {
    font-size: 0.9rem;
    margin-bottom: 2px;
}

.card-content p {
    font-size: 0.75rem;
    color: var(--text-secondary);
}

.preview-button {
    margin-top: auto;
    padding: var(--space-md);
    background: var(--gradient-primary);
    border-radius: var(--radius-md);
    text-align: center;
    font-family: var(--font-display);
    font-weight: 600;
    color: var(--bg-primary);
    cursor: pointer;
}

.preview-actions-bottom {
    display: flex;
    gap: var(--space-md);
    padding: var(--space-lg);
    border-top: 1px solid var(--border-subtle);
}

/* Form Row */
.form-row {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: var(--space-md);
}

.form-hint {
    display: block;
    font-size: 0.75rem;
    color: var(--text-tertiary);
    margin-top: var(--space-xs);
}

/* Responsive */
@media (max-width: 1200px) {
    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .quick-actions {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .editor-layout {
        grid-template-columns: 200px 1fr 240px;
    }
    
    .branding-layout {
        grid-template-columns: 1fr;
    }
    
    .branding-preview {
        height: 400px;
    }
}

@media (max-width: 768px) {
    .sidebar {
        transform: translateX(-100%);
    }
    
    .sidebar.open {
        transform: translateX(0);
    }
    
    .main-content {
        margin-left: 0;
    }
    
    .stats-grid,
    .quick-actions {
        grid-template-columns: 1fr;
    }
    
    .editor-layout {
        grid-template-columns: 1fr;
    }
    
    .editor-sidebar,
    .editor-inspector {
        display: none;
    }
    
    .platform-cards {
        grid-template-columns: 1fr;
    }
    
    .analytics-grid,
    .analytics-card.wide {
        grid-column: span 1;
    }
    
    .testing-stats {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .color-custom-grid {
        grid-template-columns: 1fr;
    }
    
    .splash-options {
        grid-template-columns: 1fr;
    }
    
    .icon-sizes-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

/* Scrollbar */
::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}

::-webkit-scrollbar-track {
    background: var(--bg-secondary);
}

::-webkit-scrollbar-thumb {
    background: var(--border-default);
    border-radius: var(--radius-full);
}

::-webkit-scrollbar-thumb:hover {
    background: var(--border-strong);
}

/* Selection */
::selection {
    background: var(--accent-primary);
    color: var(--bg-primary);
}