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

:root {
    --bg-main: #060813;
    --bg-surface: rgba(16, 20, 38, 0.6);
    --bg-surface-opaque: #101426;
    --border-light: rgba(255, 255, 255, 0.08);
    --border-glow: rgba(99, 102, 241, 0.2);
    
    --primary: #6366f1;
    --primary-glow: rgba(99, 102, 241, 0.35);
    --secondary: #8b5cf6;
    --accent-orange: #ff7a00;
    --accent-blue: #0073e6;
    --accent-emerald: #10b981;
    --accent-rose: #f43f5e;
    
    --text-primary: #f8fafc;
    --text-muted: #94a3b8;
    --text-dark: #0f172a;
    
    --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    --font-display: 'Outfit', sans-serif;
    
    --shadow-sm: 0 2px 8px -1px rgba(0, 0, 0, 0.1);
    --shadow-md: 0 12px 20px -3px rgba(0, 0, 0, 0.25);
    --shadow-lg: 0 20px 25px -5px rgba(0, 0, 0, 0.35);
    --shadow-glow: 0 0 20px 2px rgba(99, 102, 241, 0.15);
    
    --radius-sm: 8px;
    --radius-md: 14px;
    --radius-lg: 24px;
    
    --transition-smooth: all 0.35s cubic-bezier(0.4, 0, 0.2, 1);
}

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

body {
    background-color: var(--bg-main);
    background-image: 
        radial-gradient(at 10% 20%, rgba(99, 102, 241, 0.1) 0px, transparent 50%),
        radial-gradient(at 90% 80%, rgba(139, 92, 246, 0.08) 0px, transparent 50%);
    background-attachment: fixed;
    color: var(--text-primary);
    font-family: var(--font-sans);
    min-height: 100vh;
    overflow-x: hidden;
    line-height: 1.6;
}

/* Scrollbar Style */
::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}
::-webkit-scrollbar-track {
    background: var(--bg-main);
}
::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
    background: rgba(255, 255, 255, 0.2);
}

/* Layout Utilities */
.container {
    max-width: 1440px;
    margin: 0 auto;
    padding: 0 24px;
}

/* Glassmorphism Classes */
.glass-panel {
    background: var(--bg-surface);
    backdrop-filter: blur(16px) saturate(180%);
    -webkit-backdrop-filter: blur(16px) saturate(180%);
    border: 1px solid var(--border-light);
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-md);
    transition: var(--transition-smooth);
}
.glass-panel:hover {
    border-color: rgba(255, 255, 255, 0.15);
}

.glass-panel-glow {
    border-color: var(--border-glow);
    box-shadow: var(--shadow-glow);
}

/* Header & Navbar */
header {
    position: sticky;
    top: 0;
    z-index: 100;
    margin-bottom: 30px;
    background: rgba(6, 8, 19, 0.7);
    backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--border-light);
}

.navbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 70px;
}

.brand {
    display: flex;
    flex-direction: column;
}

.brand-title {
    font-family: var(--font-display);
    font-weight: 800;
    font-size: 24px;
    background: linear-gradient(135deg, #f8fafc 10%, #a5b4fc 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    letter-spacing: -0.5px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.brand-title .badge-flow {
    font-size: 11px;
    padding: 2px 6px;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    color: white;
    border-radius: 6px;
    -webkit-text-fill-color: initial;
    font-weight: 600;
}

.brand-domain {
    font-size: 11px;
    color: var(--text-muted);
    font-weight: 500;
    letter-spacing: 0.5px;
    margin-top: -2px;
}

.nav-tabs {
    display: flex;
    gap: 8px;
    background: rgba(255, 255, 255, 0.04);
    padding: 4px;
    border-radius: 30px;
    border: 1px solid var(--border-light);
}

.nav-tab {
    background: transparent;
    border: none;
    color: var(--text-muted);
    font-family: var(--font-sans);
    font-weight: 600;
    font-size: 14px;
    padding: 8px 18px;
    cursor: pointer;
    border-radius: 20px;
    transition: var(--transition-smooth);
    display: flex;
    align-items: center;
    gap: 6px;
}

.nav-tab:hover {
    color: var(--text-primary);
    background: rgba(255, 255, 255, 0.04);
}

.nav-tab.active {
    color: var(--text-primary);
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    box-shadow: 0 4px 12px rgba(99, 102, 241, 0.3);
}

.nav-meta {
    display: flex;
    align-items: center;
    gap: 16px;
}

.api-status-badge {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 12px;
    font-weight: 600;
    padding: 6px 12px;
    border-radius: 30px;
    cursor: pointer;
    background: rgba(244, 63, 94, 0.1);
    color: var(--accent-rose);
    border: 1px solid rgba(244, 63, 94, 0.2);
    transition: var(--transition-smooth);
}

.api-status-badge.connected {
    background: rgba(16, 185, 129, 0.1);
    color: var(--accent-emerald);
    border: 1px solid rgba(16, 185, 129, 0.2);
}

.api-status-badge:hover {
    transform: translateY(-1px);
}

.btn-settings {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--border-light);
    color: var(--text-primary);
    width: 38px;
    height: 38px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition-smooth);
}

.btn-settings:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: var(--primary);
    transform: rotate(30deg);
}

/* Page Structures */
.app-view {
    display: none;
    animation: fadeIn 0.4s ease;
}

.app-view.active {
    display: block;
}

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

/* Grid Layouts */
.generator-layout {
    display: grid;
    grid-template-columns: 380px 1fr;
    gap: 24px;
    align-items: start;
    margin-bottom: 40px;
}

/* Left Input Sidebar */
.sidebar-panel {
    padding: 24px;
}

.panel-title {
    font-family: var(--font-display);
    font-weight: 700;
    font-size: 18px;
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    gap: 8px;
}

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

.form-label {
    display: block;
    font-size: 13px;
    font-weight: 600;
    color: var(--text-muted);
    margin-bottom: 6px;
}

.form-input, .form-textarea, .form-select {
    width: 100%;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--border-light);
    border-radius: var(--radius-sm);
    color: var(--text-primary);
    font-family: var(--font-sans);
    font-size: 14px;
    padding: 10px 14px;
    transition: var(--transition-smooth);
}

.form-select option {
    background-color: var(--bg-surface-opaque);
    color: var(--text-primary);
}

.form-input:focus, .form-textarea:focus, .form-select:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 10px rgba(99, 102, 241, 0.15);
    background: rgba(255, 255, 255, 0.05);
}

.form-textarea {
    resize: vertical;
    min-height: 80px;
}

.btn-primary {
    width: 100%;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    border: none;
    color: white;
    font-family: var(--font-sans);
    font-weight: 700;
    font-size: 15px;
    padding: 12px;
    border-radius: var(--radius-sm);
    cursor: pointer;
    transition: var(--transition-smooth);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    box-shadow: 0 4px 14px rgba(99, 102, 241, 0.2);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(99, 102, 241, 0.35);
}

.btn-primary:active {
    transform: translateY(0);
}

/* Scraper Override Accordion */
.accordion-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    cursor: pointer;
    padding: 12px 0;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
    margin-top: 15px;
}

.accordion-title {
    font-size: 13px;
    font-weight: 700;
    color: var(--primary);
}

.accordion-icon {
    font-size: 12px;
    transition: var(--transition-smooth);
}

.accordion-content {
    display: none;
    padding-top: 10px;
    border-top: 1px dashed rgba(255, 255, 255, 0.05);
}

.accordion-content.open {
    display: block;
}

.accordion-header.open .accordion-icon {
    transform: rotate(180deg);
}

/* Copywriter Main Hub */
.main-generator-panel {
    padding: 24px;
    min-height: 600px;
}

.panel-header-tabs {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    padding-bottom: 12px;
    margin-bottom: 24px;
}

.copy-tabs {
    display: flex;
    gap: 6px;
}

.copy-tab {
    background: transparent;
    border: none;
    color: var(--text-muted);
    font-weight: 600;
    font-size: 14px;
    padding: 8px 16px;
    cursor: pointer;
    border-radius: 8px;
    transition: var(--transition-smooth);
}

.copy-tab:hover {
    color: var(--text-primary);
    background: rgba(255, 255, 255, 0.03);
}

.copy-tab.active {
    color: var(--primary);
    background: rgba(99, 102, 241, 0.1);
}

/* Tab Views */
.copy-tab-view {
    display: none;
    animation: fadeIn 0.3s ease;
}

.copy-tab-view.active {
    display: block;
}

/* Threads Card Mockup */
.threads-card-mockup {
    background: #000;
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 16px;
    padding: 20px;
    max-width: 560px;
    margin: 0 auto 20px auto;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

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

.mockup-avatar {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: linear-gradient(135deg, #f43f5e, #e11d48);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 800;
    color: white;
    font-size: 14px;
}

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

.mockup-username {
    font-weight: 700;
    font-size: 14px;
    color: #f3f4f6;
}

.mockup-handle {
    font-size: 12px;
    color: #6b7280;
}

.mockup-body {
    font-size: 15px;
    color: #f3f4f6;
    white-space: pre-wrap;
    margin-bottom: 15px;
    line-height: 1.5;
}

.mockup-image-placeholder {
    width: 100%;
    height: 280px;
    background: #111;
    border: 1px solid #222;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #4b5563;
    font-size: 14px;
    margin-bottom: 15px;
    overflow: hidden;
    position: relative;
}

.mockup-image-placeholder img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.mockup-actions {
    display: flex;
    gap: 16px;
    color: #6b7280;
    font-size: 18px;
    border-bottom: 1px solid #1f2937;
    padding-bottom: 12px;
    margin-bottom: 10px;
}

.mockup-action-btn {
    cursor: pointer;
    transition: var(--transition-smooth);
}

.mockup-action-btn:hover {
    color: #f3f4f6;
}

.mockup-stats {
    font-size: 13px;
    color: #6b7280;
}

/* Blogspot Preview */
.blogspot-preview-container {
    background: white;
    color: #222;
    border-radius: 12px;
    border: 1px solid #e2e8f0;
    overflow: hidden;
    box-shadow: var(--shadow-sm);
    margin-bottom: 24px;
}

.blogspot-header {
    background: #ff5722;
    color: white;
    padding: 12px 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.blogspot-logo {
    font-family: var(--font-display);
    font-weight: 800;
    font-size: 18px;
    display: flex;
    align-items: center;
    gap: 6px;
}

.blogspot-window-dot {
    display: flex;
    gap: 6px;
}

.blogspot-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: rgba(255,255,255,0.4);
}

.blogspot-body {
    padding: 24px 30px;
    font-family: 'Malgun Gothic', '맑은 고딕', sans-serif;
    background: #fafafa;
    min-height: 400px;
}

.blogspot-post-title {
    font-size: 24px;
    font-weight: 800;
    color: #1a1a1a;
    border-bottom: 2px solid #ff5722;
    padding-bottom: 10px;
    margin-bottom: 20px;
}

.blogspot-post-content {
    font-size: 15px;
    line-height: 1.8;
    color: #333;
}

.blogspot-post-content h2, .blogspot-post-content h3 {
    color: #ff5722;
    margin-top: 25px;
    margin-bottom: 12px;
    font-weight: 700;
}

.blogspot-post-content ul, .blogspot-post-content ol {
    margin-left: 20px;
    margin-bottom: 18px;
}

.blogspot-post-content li {
    margin-bottom: 6px;
}

.blogspot-table {
    width: 100%;
    border-collapse: collapse;
    margin: 20px 0;
}

.blogspot-table th {
    background: #fff0eb;
    color: #ff5722;
    font-weight: 700;
    border: 1px solid #e2e8f0;
    padding: 10px;
    text-align: left;
}

.blogspot-table td {
    border: 1px solid #e2e8f0;
    padding: 10px;
}

.blogspot-cta-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: linear-gradient(135deg, #ff5722, #ff9800);
    color: white !important;
    text-decoration: none;
    font-weight: 700;
    padding: 12px 28px;
    border-radius: 30px;
    margin: 24px 0;
    box-shadow: 0 4px 10px rgba(255, 87, 34, 0.3);
    transition: var(--transition-smooth);
}

.blogspot-cta-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 14px rgba(255, 87, 34, 0.45);
}

.btn-actions-row {
    display: flex;
    gap: 12px;
    justify-content: flex-end;
    margin-top: 15px;
}

.btn-secondary {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--border-light);
    color: var(--text-primary);
    padding: 8px 16px;
    border-radius: var(--radius-sm);
    cursor: pointer;
    font-weight: 600;
    font-size: 13px;
    display: flex;
    align-items: center;
    gap: 6px;
    transition: var(--transition-smooth);
}

.btn-secondary:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: var(--primary);
}

/* Prompt Helper Style */
.prompt-helper-box {
    background: rgba(255, 255, 255, 0.02);
    border: 1px dashed var(--primary-glow);
    border-radius: var(--radius-md);
    padding: 20px;
    margin-top: 10px;
}

.prompt-content {
    background: #000;
    color: #38bdf8;
    padding: 15px;
    border-radius: 8px;
    font-family: monospace;
    font-size: 13px;
    white-space: pre-wrap;
    max-height: 380px;
    overflow-y: auto;
    border: 1px solid rgba(255,255,255,0.05);
}

.alert-tip {
    background: rgba(99, 102, 241, 0.06);
    border-left: 4px solid var(--primary);
    padding: 12px;
    border-radius: 0 8px 8px 0;
    font-size: 13px;
    color: var(--text-muted);
    margin-bottom: 15px;
}

/* Visual Canvas Editor Styles */
.editor-layout {
    display: grid;
    grid-template-columns: 1fr 380px;
    gap: 24px;
    align-items: start;
    margin-bottom: 40px;
}

.canvas-area-panel {
    padding: 24px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 520px;
}

.canvas-wrapper {
    position: relative;
    border: 1px solid var(--border-light);
    border-radius: 12px;
    overflow: hidden;
    background: radial-gradient(circle, #1a1e35 0%, #0c0e1b 100%);
    box-shadow: var(--shadow-lg);
    cursor: grab;
}

.canvas-wrapper:active {
    cursor: grabbing;
}

canvas {
    display: block;
    max-width: 100%;
}

.canvas-controls {
    display: flex;
    gap: 12px;
    margin-top: 20px;
    width: 100%;
    justify-content: center;
}

.image-upload-zone {
    width: 100%;
    height: 300px;
    border: 2px dashed rgba(255,255,255,0.15);
    border-radius: 12px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: var(--transition-smooth);
}

.image-upload-zone:hover {
    border-color: var(--primary);
    background: rgba(99, 102, 241, 0.02);
}

.upload-icon {
    font-size: 40px;
    color: var(--primary);
    margin-bottom: 12px;
}

/* Sticker / Badge Toolkit Control Panel */
.toolkit-panel {
    padding: 24px;
}

.toolkit-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
    margin-bottom: 20px;
}

.toolkit-badge-card {
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid var(--border-light);
    border-radius: 10px;
    padding: 10px;
    cursor: pointer;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 6px;
    text-align: center;
    transition: var(--transition-smooth);
}

.toolkit-badge-card:hover {
    background: rgba(255, 255, 255, 0.06);
    border-color: var(--primary);
    transform: translateY(-2px);
}

.toolkit-badge-card.active {
    border-color: var(--primary);
    background: rgba(99, 102, 241, 0.08);
}

.badge-preview-icon {
    padding: 4px 8px;
    font-size: 11px;
    font-weight: 700;
    color: white;
    border-radius: 4px;
}

.toolkit-slider-group {
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid var(--border-light);
    border-radius: 10px;
    padding: 14px;
    margin-bottom: 15px;
}

.slider-label-row {
    display: flex;
    justify-content: space-between;
    font-size: 12px;
    font-weight: 600;
    color: var(--text-muted);
    margin-bottom: 6px;
}

.slider-input {
    width: 100%;
    accent-color: var(--primary);
    cursor: pointer;
}

/* Campaign Analytics Tab */
.analytics-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
    margin-bottom: 30px;
}

.stat-card {
    padding: 20px;
    display: flex;
    align-items: center;
    gap: 16px;
}

.stat-icon {
    width: 48px;
    height: 48px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 22px;
}

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

.stat-val {
    font-family: var(--font-display);
    font-weight: 800;
    font-size: 24px;
    color: var(--text-primary);
}

.stat-lbl {
    font-size: 12px;
    font-weight: 600;
    color: var(--text-muted);
}

/* Graph simulator */
.graph-container {
    padding: 24px;
    margin-bottom: 30px;
}

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

.graph-bars {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    height: 200px;
    padding-top: 20px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    position: relative;
}

.graph-bar-col {
    display: flex;
    flex-direction: column;
    align-items: center;
    flex: 1;
}

.graph-bar {
    width: 60%;
    max-width: 40px;
    background: linear-gradient(180deg, var(--primary) 0%, var(--secondary) 100%);
    border-radius: 6px 6px 0 0;
    height: 0;
    transition: height 1s ease;
    box-shadow: 0 0 10px rgba(99, 102, 241, 0.2);
}

.graph-bar-label {
    margin-top: 10px;
    font-size: 11px;
    color: var(--text-muted);
    font-weight: 600;
}

/* Settings Modal */
.settings-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(6, 8, 19, 0.85);
    backdrop-filter: blur(8px);
    z-index: 1000;
    display: none;
    align-items: center;
    justify-content: center;
    animation: fadeIn 0.3s ease;
}

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

.settings-content {
    width: 100%;
    max-width: 500px;
    padding: 30px;
    position: relative;
    border-color: var(--primary-glow);
    box-shadow: var(--shadow-lg), var(--shadow-glow);
}

.modal-close {
    position: absolute;
    top: 20px;
    right: 20px;
    background: transparent;
    border: none;
    color: var(--text-muted);
    font-size: 20px;
    cursor: pointer;
    transition: var(--transition-smooth);
}

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

/* Public Portal Template Layout */
.public-portal-mockup {
    background: #0f111e;
    border: 1px solid var(--border-light);
    border-radius: var(--radius-lg);
    padding: 30px;
    margin-bottom: 40px;
}

.adsense-placeholder-banner {
    background: linear-gradient(135deg, rgba(234, 179, 8, 0.08) 0%, rgba(202, 138, 4, 0.04) 100%);
    border: 2px dashed rgba(234, 179, 8, 0.25);
    border-radius: 12px;
    padding: 24px;
    text-align: center;
    color: #eab308;
    margin-bottom: 30px;
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.adsense-placeholder-banner i {
    font-size: 24px;
}

.adsense-badge {
    position: absolute;
    top: 10px;
    left: 10px;
    background: #eab308;
    color: #000;
    font-size: 10px;
    font-weight: 700;
    padding: 2px 6px;
    border-radius: 4px;
}

.public-product-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 24px;
}

.public-product-card {
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid var(--border-light);
    border-radius: 16px;
    overflow: hidden;
    transition: var(--transition-smooth);
}

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

.public-card-image {
    width: 100%;
    height: 180px;
    background: #1e293b;
    position: relative;
    overflow: hidden;
}

.public-card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.public-card-badge {
    position: absolute;
    top: 12px;
    right: 12px;
    background: var(--accent-orange);
    color: white;
    font-size: 11px;
    font-weight: 700;
    padding: 3px 8px;
    border-radius: 20px;
}

.public-card-body {
    padding: 18px;
}

.public-card-title {
    font-weight: 700;
    font-size: 15px;
    margin-bottom: 8px;
    color: var(--text-primary);
    line-height: 1.4;
    height: 42px;
    overflow: hidden;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

.public-card-price-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 12px;
}

.public-card-price {
    font-family: var(--font-display);
    font-weight: 800;
    font-size: 18px;
    color: var(--text-primary);
}

.public-card-stars {
    color: #f59e0b;
    font-size: 12px;
}

.public-card-btn {
    width: 100%;
    padding: 10px;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    color: white;
    border: none;
    border-radius: 8px;
    font-weight: 700;
    font-size: 13px;
    cursor: pointer;
    text-align: center;
    display: block;
    text-decoration: none;
    transition: var(--transition-smooth);
}

.public-card-btn:hover {
    opacity: 0.9;
}

/* History Campaign list styling */
.history-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.history-item {
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid var(--border-light);
    border-radius: var(--radius-sm);
    padding: 14px 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: var(--transition-smooth);
}

.history-item:hover {
    background: rgba(255, 255, 255, 0.04);
    border-color: var(--primary-glow);
}

.history-details {
    display: flex;
    flex-direction: column;
}

.history-title {
    font-weight: 700;
    font-size: 14px;
}

.history-subtitle {
    font-size: 11px;
    color: var(--text-muted);
}

.history-actions {
    display: flex;
    gap: 8px;
}

.toast-container {
    position: fixed;
    bottom: 24px;
    right: 24px;
    z-index: 1100;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.toast {
    background: #101426;
    color: white;
    border-left: 4px solid var(--accent-emerald);
    padding: 14px 24px;
    border-radius: 4px;
    box-shadow: var(--shadow-lg);
    font-size: 14px;
    font-weight: 600;
    min-width: 250px;
    animation: slideIn 0.3s ease, fadeOut 0.3s ease 2.7s forwards;
    border-top: 1px solid rgba(255,255,255,0.05);
    border-right: 1px solid rgba(255,255,255,0.05);
    border-bottom: 1px solid rgba(255,255,255,0.05);
}

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

@keyframes fadeOut {
    to { opacity: 0; transform: translateY(-10px); }
}

/* Responsiveness */
@media (max-width: 1024px) {
    .generator-layout, .editor-layout {
        grid-template-columns: 1fr;
    }
    
    .analytics-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 640px) {
    .navbar {
        flex-direction: column;
        height: auto;
        padding: 15px 0;
        gap: 12px;
    }
    .analytics-grid {
        grid-template-columns: 1fr;
    }
}

/* Theme Toggle Button Style */
.btn-theme-toggle {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--border-light);
    color: var(--text-primary);
    width: 38px;
    height: 38px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition-smooth);
}
.btn-theme-toggle:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: var(--primary);
    transform: scale(1.05);
}

/* Light Mode Theme Overrides */
body.light-mode {
    --bg-main: #f1f5f9;
    --bg-surface: rgba(255, 255, 255, 0.7);
    --bg-surface-opaque: #ffffff;
    --border-light: rgba(15, 23, 42, 0.08);
    --border-glow: rgba(99, 102, 241, 0.15);
    
    --text-primary: #0f172a;
    --text-muted: #64748b;
}

body.light-mode {
    background-image: 
        radial-gradient(at 10% 20%, rgba(99, 102, 241, 0.05) 0px, transparent 50%),
        radial-gradient(at 90% 80%, rgba(139, 92, 246, 0.04) 0px, transparent 50%);
}

body.light-mode .brand-title {
    background: linear-gradient(135deg, #0f172a 10%, #4338ca 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

body.light-mode .nav-tabs {
    background: rgba(15, 23, 42, 0.03);
}

body.light-mode .nav-tab:hover {
    background: rgba(15, 23, 42, 0.04);
}

body.light-mode .btn-theme-toggle {
    background: rgba(0, 0, 0, 0.03);
    color: #0f172a;
}
body.light-mode .btn-theme-toggle:hover {
    background: rgba(0, 0, 0, 0.06);
}

body.light-mode .btn-settings {
    background: rgba(0, 0, 0, 0.03);
    color: #0f172a;
}
body.light-mode .btn-settings:hover {
    background: rgba(0, 0, 0, 0.06);
}

body.light-mode .form-input, 
body.light-mode .form-textarea, 
body.light-mode .form-select {
    background: rgba(255, 255, 255, 0.9);
    border-color: rgba(15, 23, 42, 0.12);
    color: #0f172a;
}
body.light-mode .form-input:focus, 
body.light-mode .form-textarea:focus, 
body.light-mode .form-select:focus {
    background: #ffffff;
    border-color: var(--primary);
}

body.light-mode .form-select option {
    background-color: #ffffff;
    color: #0f172a;
}

body.light-mode .prompt-content {
    background: #f8fafc;
    color: #0369a1;
    border-color: rgba(15, 23, 42, 0.08);
}

body.light-mode .settings-content {
    background: #ffffff;
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
}

body.light-mode .modal-close {
    color: #64748b;
}

body.light-mode .threads-card-mockup {
    background: #ffffff;
    border-color: #e5e7eb;
}
body.light-mode .mockup-username {
    color: #111827;
}
body.light-mode .mockup-body {
    color: #1f2937;
}
body.light-mode .mockup-image-placeholder {
    background: #f3f4f6;
    border-color: #e5e7eb;
    color: #9ca3af;
}
body.light-mode .mockup-actions {
    color: #9ca3af;
    border-bottom-color: #f3f4f6;
}
body.light-mode .mockup-action-btn:hover {
    color: #111827;
}
body.light-mode .mockup-stats {
    color: #9ca3af;
}

/* Light Mode Overrides for UI Elements */
body.light-mode header {
    background: rgba(255, 255, 255, 0.8) !important;
    border-bottom: 1px solid rgba(15, 23, 42, 0.08) !important;
}

body.light-mode .panel-title {
    color: #0f172a !important;
}

body.light-mode .form-label {
    color: #334155 !important;
}

body.light-mode .panel-header-tabs {
    border-bottom-color: rgba(15, 23, 42, 0.08) !important;
}

body.light-mode .copy-tab:hover {
    color: #0f172a !important;
    background: rgba(15, 23, 42, 0.04) !important;
}

body.light-mode .copy-tab.active {
    color: var(--primary) !important;
    background: rgba(99, 102, 241, 0.08) !important;
}

body.light-mode .accordion-toggle {
    background: rgba(15, 23, 42, 0.02) !important;
    border-color: rgba(15, 23, 42, 0.08) !important;
    color: #0f172a !important;
}

body.light-mode .accordion-toggle:hover {
    background: rgba(15, 23, 42, 0.04) !important;
}

body.light-mode .alert-tip {
    background: rgba(99, 102, 241, 0.05) !important;
    border-color: rgba(99, 102, 241, 0.15) !important;
    color: #4f46e5 !important;
}

body.light-mode .toolkit-badge-card {
    background: rgba(15, 23, 42, 0.02) !important;
    border-color: rgba(15, 23, 42, 0.08) !important;
    color: #0f172a !important;
}

body.light-mode .toolkit-badge-card:hover {
    background: rgba(15, 23, 42, 0.04) !important;
    border-color: var(--primary) !important;
}

body.light-mode .toolkit-badge-card.active {
    border-color: var(--primary) !important;
    background: rgba(99, 102, 241, 0.05) !important;
    box-shadow: 0 4px 12px rgba(99, 102, 241, 0.08) !important;
}

body.light-mode #badge-edit-inputs {
    background: rgba(15, 23, 42, 0.02) !important;
    border-color: rgba(15, 23, 42, 0.08) !important;
}

body.light-mode .toolkit-slider-group {
    background: rgba(15, 23, 42, 0.02) !important;
    border-color: rgba(15, 23, 42, 0.08) !important;
}

body.light-mode .btn-secondary {
    background: #ffffff !important;
    border: 1px solid rgba(15, 23, 42, 0.12) !important;
    color: #334155 !important;
}

body.light-mode .btn-secondary:hover {
    background: #f8fafc !important;
    color: #0f172a !important;
    border-color: rgba(15, 23, 42, 0.2) !important;
}

/* contenteditable placeholder */
[contenteditable=true]:empty:before{
  content: attr(data-placeholder);
  color: var(--text-muted);
  cursor: text;
}
