@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800&display=swap');

:root {
    --primary: #6366f1;
    --primary-dark: #4f46e5;
    --primary-light: #818cf8;
    --secondary: #8b5cf6;
    --accent: #ec4899;
    --success: #10b981;
    --warning: #f59e0b;
    --danger: #ef4444;
    
    --bg-primary: #ffffff;
    --bg-secondary: #fafbfc;
    --bg-tertiary: #f3f4f6;
    --bg-overlay: rgba(0, 0, 0, 0.6);
    --bg-card: rgba(255, 255, 255, 0.98);
    
    --text-primary: #0f172a;
    --text-secondary: #64748b;
    --text-tertiary: #94a3b8;
    
    --border-color: #e2e8f0;
    --border-radius: 16px;
    --border-radius-lg: 20px;
    --border-radius-xl: 28px;
    
    --shadow-sm: 0 1px 3px 0 rgb(0 0 0 / 0.08);
    --shadow-md: 0 4px 12px -2px rgb(0 0 0 / 0.08);
    --shadow-lg: 0 10px 25px -5px rgb(0 0 0 / 0.12), 0 8px 10px -6px rgb(0 0 0 / 0.08);
    --shadow-xl: 0 20px 40px -8px rgb(0 0 0 / 0.15), 0 8px 16px -8px rgb(0 0 0 / 0.1);
    --shadow-2xl: 0 25px 50px -12px rgb(0 0 0 / 0.25);
    
    --glow-primary: 0 0 40px rgba(99, 102, 241, 0.4), 0 0 80px rgba(99, 102, 241, 0.2);
    --glow-secondary: 0 0 40px rgba(139, 92, 246, 0.4), 0 0 80px rgba(139, 92, 246, 0.2);
    --glow-success: 0 0 30px rgba(16, 185, 129, 0.3);
}

[data-theme="dark"] {
    --bg-primary: #0a0f1e;
    --bg-secondary: #111827;
    --bg-tertiary: #1e293b;
    --bg-card: rgba(30, 41, 59, 0.95);
    
    --text-primary: #f8fafc;
    --text-secondary: #cbd5e1;
    --text-tertiary: #94a3b8;
    
    --border-color: #1e293b;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

html, body {
    height: 100%;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    background: #0a0e1a;
    color: var(--text-primary);
    transition: background 0.4s cubic-bezier(0.4, 0, 0.2, 1), color 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

#app {
    height: 100%;
}

/* Gradient Background with Wireframe Grid */
.gradient-bg {
    background: #0a0e1a;
    position: relative;
    overflow: hidden;
}

.gradient-bg::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-image: 
        linear-gradient(90deg, rgba(139, 92, 246, 0.15) 1px, transparent 1px),
        linear-gradient(0deg, rgba(139, 92, 246, 0.15) 1px, transparent 1px);
    background-size: 50px 50px;
    transform: perspective(500px) rotateX(60deg) scale(2);
    transform-origin: center bottom;
    animation: gridFlow 20s linear infinite;
}

.gradient-bg::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: 
        radial-gradient(ellipse at top, rgba(139, 92, 246, 0.15) 0%, transparent 50%),
        radial-gradient(ellipse at bottom right, rgba(236, 72, 153, 0.1) 0%, transparent 50%);
    pointer-events: none;
}

@keyframes gridFlow {
    0% { background-position: 0 0; }
    100% { background-position: 50px 50px; }
}

/* Container */
.container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 1.5rem;
}

/* Button Styles */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.75rem 1.5rem;
    font-size: 0.95rem;
    font-weight: 500;
    border: none;
    border-radius: var(--border-radius);
    cursor: pointer;
    transition: all 0.2s ease;
    text-decoration: none;
    white-space: nowrap;
}

.btn-primary {
    background: linear-gradient(135deg, var(--primary) 0%, var(--secondary) 100%);
    color: white;
    box-shadow: var(--shadow-md);
    position: relative;
    overflow: hidden;
}

.btn-primary::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.2), transparent);
    transition: left 0.5s;
}

.btn-primary:hover::before {
    left: 100%;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-xl), var(--glow-primary);
}

.btn-primary:active {
    transform: translateY(0);
}

.btn-secondary {
    background: var(--bg-tertiary);
    color: var(--text-primary);
}

.btn-secondary:hover {
    background: var(--border-color);
}

.btn-outline {
    background: transparent;
    border: 2px solid var(--border-color);
    color: var(--text-primary);
}

.btn-outline:hover {
    border-color: var(--primary);
    color: var(--primary);
}

.btn-icon {
    padding: 0.75rem;
    width: 44px;
    height: 44px;
}

/* Input Styles */
.input-group {
    margin-bottom: 1.5rem;
}

.input-label {
    display: block;
    margin-bottom: 0.5rem;
    font-size: 0.9rem;
    font-weight: 500;
    color: var(--text-secondary);
}

.input {
    width: 100%;
    padding: 0.875rem 1.125rem;
    font-size: 0.95rem;
    border: 2px solid var(--border-color);
    border-radius: var(--border-radius);
    background: var(--bg-primary);
    color: var(--text-primary);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.input:hover {
    border-color: var(--text-tertiary);
}

.input:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 4px rgba(99, 102, 241, 0.12), 0 4px 12px rgba(99, 102, 241, 0.08);
    transform: translateY(-1px);
}

.textarea {
    resize: vertical;
    min-height: 150px;
    font-family: inherit;
}

.select {
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 24 24' stroke='%236b7280'%3E%3Cpath stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M19 9l-7 7-7-7'%3E%3C/path%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 0.75rem center;
    background-size: 1.25em 1.25em;
    padding-right: 2.5rem;
}

/* Card Styles */
.card {
    background: var(--bg-card);
    border-radius: 16px;
    box-shadow: var(--shadow-lg);
    padding: 1.5rem;
    border: 1px solid var(--border-color);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

@media (min-width: 769px) {
    .card {
        padding: 2rem;
    }
}

.card-glass {
    background: rgba(255, 255, 255, 0.8);
    backdrop-filter: blur(20px) saturate(180%);
    -webkit-backdrop-filter: blur(20px) saturate(180%);
    border: 1px solid rgba(255, 255, 255, 0.3);
    box-shadow: var(--shadow-xl),
                0 0 0 1px rgba(139, 92, 246, 0.05),
                inset 0 1px 0 0 rgba(255, 255, 255, 0.5);
}

[data-theme="dark"] .card-glass {
    background: rgba(15, 23, 42, 0.8);
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: var(--shadow-xl),
                0 0 0 1px rgba(139, 92, 246, 0.1),
                inset 0 1px 0 0 rgba(255, 255, 255, 0.1);
}

/* Badge Styles */
.badge {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.625rem 1.25rem;
    font-size: 0.875rem;
    font-weight: 600;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.25);
    backdrop-filter: blur(10px);
    color: white;
    border: 1px solid rgba(255, 255, 255, 0.3);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
}

.badge:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.15);
    background: rgba(255, 255, 255, 0.35);
}

.badge-success {
    background: rgba(16, 185, 129, 0.15);
    color: #10b981;
    border: 1px solid rgba(16, 185, 129, 0.3);
    box-shadow: 0 4px 12px rgba(16, 185, 129, 0.2);
}

.badge-success:hover {
    box-shadow: 0 8px 20px rgba(16, 185, 129, 0.3), var(--glow-success);
}

.badge-primary {
    background: rgba(99, 102, 241, 0.15);
    color: var(--primary);
    border: 1px solid rgba(99, 102, 241, 0.3);
    box-shadow: 0 4px 12px rgba(99, 102, 241, 0.2);
}

.badge-primary:hover {
    box-shadow: 0 8px 20px rgba(99, 102, 241, 0.3);
}

/* Grid Layouts */
.grid {
    display: grid;
    gap: 1.5rem;
}

.grid-cols-2 {
    grid-template-columns: repeat(2, 1fr);
}

.grid-cols-3 {
    grid-template-columns: repeat(3, 1fr);
}

@media (max-width: 768px) {
    .grid-cols-2,
    .grid-cols-3 {
        grid-template-columns: 1fr;
    }
}

/* Flex Utilities */
.flex {
    display: flex;
}

.flex-col {
    flex-direction: column;
}

.items-center {
    align-items: center;
}

.justify-center {
    justify-content: center;
}

.justify-between {
    justify-content: space-between;
}

.gap-1 { gap: 0.5rem; }
.gap-2 { gap: 1rem; }
.gap-3 { gap: 1.5rem; }
.gap-4 { gap: 2rem; }

/* Spacing */
.mt-1 { margin-top: 0.5rem; }
.mt-2 { margin-top: 1rem; }
.mt-3 { margin-top: 1.5rem; }
.mt-4 { margin-top: 2rem; }

.mb-1 { margin-bottom: 0.5rem; }
.mb-2 { margin-bottom: 1rem; }
.mb-3 { margin-bottom: 1.5rem; }
.mb-4 { margin-bottom: 2rem; }

.p-1 { padding: 0.5rem; }
.p-2 { padding: 1rem; }
.p-3 { padding: 1.5rem; }
.p-4 { padding: 2rem; }

/* Text Utilities */
.text-center { text-align: center; }
.text-sm { font-size: 0.875rem; }
.text-lg { font-size: 1.125rem; }
.text-xl { font-size: 1.25rem; }
.text-2xl { font-size: 1.5rem; }
.text-3xl { font-size: 1.875rem; }
.text-4xl { font-size: 2.25rem; }

.font-light { font-weight: 300; }
.font-normal { font-weight: 400; }
.font-medium { font-weight: 500; }
.font-semibold { font-weight: 600; }
.font-bold { font-weight: 700; }

.text-primary { color: var(--text-primary); }
.text-secondary { color: var(--text-secondary); }
.text-tertiary { color: var(--text-tertiary); }

/* Animations */
@keyframes fadeIn {
    from { 
        opacity: 0; 
        transform: translateY(30px);
    }
    to { 
        opacity: 1; 
        transform: translateY(0);
    }
}

@keyframes fadeInScale {
    from {
        opacity: 0;
        transform: scale(0.95);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.5; }
}

@keyframes spin {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

@keyframes shimmer {
    0% { background-position: -1000px 0; }
    100% { background-position: 1000px 0; }
}

.animate-fade-in {
    animation: fadeIn 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

.animate-fade-in-scale {
    animation: fadeInScale 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

.animate-pulse {
    animation: pulse 2s cubic-bezier(0.4, 0, 0.6, 1) infinite;
}

.animate-spin {
    animation: spin 1s linear infinite;
}

/* Loading Spinner */
.spinner {
    width: 28px;
    height: 28px;
    border: 3px solid var(--border-color);
    border-top-color: var(--primary);
    border-right-color: var(--secondary);
    border-radius: 50%;
    animation: spin 0.7s cubic-bezier(0.68, -0.55, 0.265, 1.55) infinite;
    box-shadow: 0 0 20px rgba(99, 102, 241, 0.3);
}

/* Transitions */
.transition {
    transition: all 0.2s ease;
}

/* Hide scrollbar but keep functionality */
.hide-scrollbar {
    -ms-overflow-style: none;
    scrollbar-width: none;
}

.hide-scrollbar::-webkit-scrollbar {
    display: none;
}

/* Custom scrollbar */
.custom-scrollbar::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}

.custom-scrollbar::-webkit-scrollbar-track {
    background: var(--bg-tertiary);
    border-radius: 4px;
}

.custom-scrollbar::-webkit-scrollbar-thumb {
    background: var(--text-tertiary);
    border-radius: 4px;
}

.custom-scrollbar::-webkit-scrollbar-thumb:hover {
    background: var(--text-secondary);
}

/* ===== Home Page Styles ===== */
.home-page {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    scroll-behavior: smooth;
}

/* Navigation Bar */
.navbar {
    position: sticky;
    top: 0;
    z-index: 100;
    background: rgba(10, 14, 26, 0.95);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-bottom: 1px solid rgba(139, 92, 246, 0.2);
}

.nav-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0.875rem 1.5rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 2rem;
}

.nav-brand {
    font-size: 1.25rem;
    font-weight: 700;
    background: linear-gradient(90deg, #a78bfa 0%, #60a5fa 50%, #34d399 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    white-space: nowrap;
}

.nav-menu {
    display: flex;
    gap: 2rem;
    align-items: center;
}

.nav-link {
    color: #cbd5e1;
    text-decoration: none;
    font-size: 0.9rem;
    font-weight: 500;
    transition: color 0.2s ease;
    white-space: nowrap;
}

.nav-link:hover {
    color: #a78bfa;
}

.nav-actions {
    display: flex;
    gap: 0.75rem;
    align-items: center;
}

.nav-btn {
    padding: 0.5rem 1.25rem;
    font-size: 0.875rem;
    font-weight: 600;
    border-radius: 8px;
    border: none;
    cursor: pointer;
    transition: all 0.2s ease;
    white-space: nowrap;
}

.nav-btn-secondary {
    background: transparent;
    color: #cbd5e1;
    border: 1.5px solid rgba(203, 213, 225, 0.3);
}

.nav-btn-secondary:hover {
    background: rgba(203, 213, 225, 0.1);
    border-color: #cbd5e1;
}

.nav-btn-primary {
    background: linear-gradient(135deg, #8b5cf6 0%, #6366f1 100%);
    color: white;
}

.nav-btn-primary:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(139, 92, 246, 0.4);
}

.theme-toggle-nav {
    width: 36px;
    height: 36px;
    border: none;
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.1);
    cursor: pointer;
    font-size: 1.125rem;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.theme-toggle-nav:hover {
    background: rgba(255, 255, 255, 0.15);
    transform: scale(1.05);
}

/* Profile Dropdown */
.profile-dropdown {
    position: relative;
}

.profile-icon-btn {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 1rem;
    background: rgba(255, 255, 255, 0.1);
    border: 1.5px solid rgba(203, 213, 225, 0.3);
    border-radius: 8px;
    color: #cbd5e1;
    cursor: pointer;
    transition: all 0.2s ease;
    font-size: 0.875rem;
    font-weight: 600;
}

.profile-icon-btn:hover {
    background: rgba(255, 255, 255, 0.15);
    border-color: #cbd5e1;
    transform: translateY(-1px);
}

.profile-icon {
    font-size: 1.125rem;
}

.profile-name {
    max-width: 100px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.profile-dropdown-menu {
    position: absolute;
    top: calc(100% + 0.5rem);
    right: 0;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    box-shadow: var(--shadow-xl);
    min-width: 240px;
    z-index: 1000;
    overflow: hidden;
    animation: slideDown 0.2s ease;
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.profile-info {
    padding: 1rem;
    border-bottom: 1px solid var(--border-color);
}

.profile-email {
    font-size: 0.875rem;
    color: var(--text-secondary);
    margin-bottom: 0.25rem;
}

.profile-account-type {
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--primary);
    text-transform: uppercase;
    margin-bottom: 0.5rem;
}

.profile-words-used {
    font-size: 0.75rem;
    color: var(--text-tertiary);
    margin-top: 0.5rem;
}

.profile-divider {
    height: 1px;
    background: var(--border-color);
    margin: 0.5rem 0;
}

.profile-menu-item {
    width: 100%;
    padding: 0.75rem 1rem;
    background: none;
    border: none;
    text-align: left;
    color: var(--text-primary);
    cursor: pointer;
    transition: background 0.2s ease;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.875rem;
}

.profile-menu-item:hover {
    background: var(--bg-tertiary);
}

@media (max-width: 768px) {
    .nav-menu {
        display: none;
    }
    
    .nav-container {
        padding: 0.75rem 1rem;
    }
    
    .nav-brand {
        font-size: 1.125rem;
    }
    
    .nav-btn {
        padding: 0.5rem 1rem;
        font-size: 0.8rem;
    }
}

/* Hero Section */
.hero {
    padding: 3rem 0 2.5rem;
    text-align: center;
    position: relative;
    color: white;
}

.hero-content {
    position: relative;
    z-index: 1;
}

.theme-toggle {
    position: absolute;
    top: 2rem;
    right: 2rem;
    width: 52px;
    height: 52px;
    border: none;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    cursor: pointer;
    font-size: 1.5rem;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: 10;
    border: 1px solid rgba(255, 255, 255, 0.3);
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.15);
}

.theme-toggle:hover {
    transform: scale(1.1) rotate(20deg);
    background: rgba(255, 255, 255, 0.35);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.2);
}

.theme-toggle:active {
    transform: scale(0.95) rotate(0deg);
}

.hero-title {
    font-size: clamp(1.75rem, 4vw, 2.5rem);
    font-weight: 700;
    line-height: 1.2;
    margin-bottom: 0.875rem;
    animation: fadeIn 0.8s cubic-bezier(0.4, 0, 0.2, 1);
    letter-spacing: -0.01em;
}

.gradient-text {
    background: linear-gradient(90deg, #a78bfa 0%, #60a5fa 30%, #34d399 60%, #10b981 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    animation: shimmer 4s ease-in-out infinite;
    background-size: 200% auto;
}

.hero-subtitle {
    font-size: clamp(0.875rem, 1.5vw, 1rem);
    line-height: 1.5;
    max-width: 600px;
    margin: 0 auto;
    opacity: 0.75;
    animation: fadeIn 0.8s ease-out 0.2s backwards;
    color: #cbd5e1;
}

.trust-badges {
    display: none;
}

/* Main Interface */
.main-interface {
    padding: 2rem 0 3rem;
    background: transparent;
}

.interface-card {
    margin-top: -1rem;
    animation: fadeInScale 0.6s cubic-bezier(0.4, 0, 0.2, 1) 0.3s backwards;
    background: white !important;
    max-width: 1200px;
    margin-left: auto;
    margin-right: auto;
    position: relative;
    overflow: hidden;
}

.interface-card::before {
    display: none;
}

@media (max-width: 1280px) {
    .interface-card {
        max-width: 95%;
    }
}

.controls-bar {
    display: none;
}

.control-label {
    display: block;
    font-size: 0.8125rem;
    font-weight: 600;
    color: var(--text-secondary);
    margin-bottom: 0.5rem;
}

.mode-selector {
    display: flex;
    gap: 0.5rem;
    background: var(--bg-secondary);
    padding: 0.25rem;
    border-radius: var(--border-radius);
}

.mode-btn {
    flex: 1;
    padding: 0.625rem 1.25rem;
    border: none;
    background: transparent;
    color: var(--text-secondary);
    font-weight: 500;
    font-size: 0.875rem;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.mode-btn:hover {
    color: var(--text-primary);
}

.mode-btn.active {
    background: white;
    color: var(--primary);
    box-shadow: var(--shadow-md);
    position: relative;
}

.mode-btn.active::after {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: calc(var(--border-radius) - 0.25rem);
    padding: 2px;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    -webkit-mask-composite: xor;
    mask-composite: exclude;
    opacity: 0.5;
}

[data-theme="dark"] .mode-btn.active {
    background: var(--bg-tertiary);
}

.purpose-select {
    margin-bottom: 0;
}

/* IO Area */
.io-area {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 0;
    margin-bottom: 2rem;
    border-radius: var(--border-radius);
    overflow: hidden;
}

@media (max-width: 1024px) {
    .io-area {
        grid-template-columns: 1fr;
    }
}

.input-section,
.output-section {
    display: flex;
    flex-direction: column;
    padding: 0;
    position: relative;
}

.input-section {
    background: white;
    border-right: 1px solid var(--border-color);
}

.output-section {
    background: white;
}

.textarea-container {
    position: relative;
    width: 100%;
}

.input-actions-center {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    display: flex;
    gap: 1rem;
    z-index: 10;
    pointer-events: none;
}

.input-actions-center .input-action-btn {
    pointer-events: auto;
    width: auto;
    padding: 0.875rem 1.5rem;
}

.section-content {
    padding: 1.25rem;
    display: flex;
    flex-direction: column;
    flex: 1;
}

@media (max-width: 1024px) {
    .input-section {
        border-right: none;
        border-bottom: 1px solid var(--border-color);
    }
}

.section-header-colored {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 1rem 1.25rem;
    border-bottom: 1px solid var(--border-color);
}

.section-header-colored.left {
    background: linear-gradient(135deg, #e9d5ff 0%, #ddd6fe 100%);
}

.section-header-colored.right {
    background: linear-gradient(135deg, #bfdbfe 0%, #dbeafe 100%);
    justify-content: space-between;
}

.section-header-colored .header-icon {
    font-size: 1.25rem;
}

.section-header-colored h3 {
    font-size: 1rem;
    font-weight: 600;
    color: #1e293b;
    margin: 0;
}

.action-buttons {
    display: flex;
    gap: 0.5rem;
}

/* Input Action Buttons */
.input-actions {
    display: flex;
    flex-direction: column;
    gap: 0.625rem;
    margin-top: auto;
    padding-top: 1rem;
}

.input-action-btn {
    width: 100%;
    padding: 0.875rem 1rem;
    font-size: 0.9375rem;
    background: #f1f0fb;
    border: none;
    border-radius: 10px;
    color: #8b5cf6;
    cursor: pointer;
    transition: all 0.2s ease;
    font-weight: 500;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}

.input-action-btn:hover {
    background: #e9d5ff;
    transform: translateY(-1px);
}

.vibe-input-container {
    margin-bottom: 0.75rem;
}

.vibe-input {
    width: 100%;
    padding: 0.625rem 0.875rem;
    border: 1.5px solid var(--border-color);
    border-radius: 8px;
    font-size: 0.875rem;
    font-family: 'Inter', sans-serif;
    background: white;
    color: var(--text-primary);
    transition: all 0.2s ease;
}

.vibe-input:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.1);
}

.vibe-input::placeholder {
    color: var(--text-tertiary);
}

.btn-icon {
    font-size: 1rem;
}

.action-btn-small {
    padding: 0.5rem 0.75rem;
    font-size: 0.875rem;
    background: white;
    border: 1px solid var(--border-color);
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.action-btn-small:hover {
    background: var(--bg-secondary);
    border-color: var(--primary);
}

.io-textarea {
    flex: 1;
    min-height: 250px;
    font-family: 'Inter', sans-serif;
    font-size: 0.9375rem;
    background: white !important;
    border: none !important;
    line-height: 1.6;
    resize: none;
}

@media (max-width: 768px) {
    .io-textarea {
        min-height: 200px;
    }
}

.text-stats {
    display: none;
}

.output-placeholder {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 250px;
    border: none;
    border-radius: 0;
    text-align: center;
    padding: 2rem;
    transition: all 0.3s ease;
    background: white;
}

.output-placeholder p {
    font-size: 0.9375rem;
    color: #94a3b8;
    margin: 0;
}

.output-placeholder small {
    display: none;
}

.output-placeholder.processing {
    background: white;
    animation: pulse 2s ease-in-out infinite;
}

@media (max-width: 768px) {
    .output-placeholder {
        min-height: 200px;
    }
}

.placeholder-icon {
    display: none;
}

.output-placeholder p {
    font-size: 1.125rem;
    font-weight: 500;
    color: var(--text-primary);
    margin-bottom: 0.5rem;
}

.output-placeholder small {
    color: var(--text-secondary);
}

.output-content {
    flex: 1;
    min-height: 250px;
    max-height: 400px;
    overflow-y: auto;
    padding: 0;
    background: white;
    border-radius: 0;
    border: none;
    line-height: 1.7;
    white-space: pre-wrap;
    font-size: 0.9375rem;
}

@media (max-width: 768px) {
    .output-content {
        min-height: 200px;
    }
}

.analysis-stats {
    display: flex;
    gap: 2rem;
    margin-top: 1rem;
    padding: 1rem;
    background: var(--bg-secondary);
    border-radius: var(--border-radius);
}

.stat-item {
    display: flex;
    gap: 0.5rem;
    align-items: center;
}

.stat-label {
    font-size: 0.875rem;
    color: var(--text-secondary);
}

.stat-value {
    font-weight: 600;
    color: var(--text-primary);
}

.stat-value.success {
    color: var(--success);
}

.stat-value.warning {
    color: var(--warning);
}

.stat-value.danger {
    color: var(--danger);
}

/* Main Actions - Hidden (using bottom bar now) */
.main-actions {
    display: none;
}

/* Bottom Bar */
.bottom-bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1.25rem;
    border-top: 1px solid var(--border-color);
    background: white;
    gap: 1.5rem;
}

.mode-section {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.mode-label {
    font-size: 0.9375rem;
    font-weight: 500;
    color: var(--text-primary);
    white-space: nowrap;
}

.mode-select-bottom {
    margin-bottom: 0;
}

.mode-select-bottom .input {
    min-width: 180px;
    padding: 0.625rem 1rem;
}

.humanize-btn-bottom {
    padding: 0.75rem 2.5rem;
    font-size: 1rem;
    font-weight: 600;
    border-radius: 10px;
    white-space: nowrap;
}

@media (max-width: 768px) {
    .bottom-bar {
        flex-direction: column;
        gap: 1rem;
    }
    
    .mode-section {
        width: 100%;
        justify-content: space-between;
    }
    
    .humanize-btn-bottom {
        width: 100%;
    }
}

/* Analysis Section */
.analysis-section {
    margin-top: 1.5rem;
    padding-top: 1.5rem;
    border-top: 1px solid var(--border-color);
}

/* History Section */
.history-section {
    margin-top: 2rem;
    background: white;
    max-width: 1400px;
    margin-left: auto;
    margin-right: auto;
}

.history-list {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.history-item {
    padding: 1rem;
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 10px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.history-item:hover {
    background: rgba(99, 102, 241, 0.05);
    border-color: var(--primary);
    transform: translateX(4px);
}

.history-text {
    font-size: 0.95rem;
    color: var(--text-primary);
    margin-bottom: 0.5rem;
    line-height: 1.5;
}

.history-meta {
    display: flex;
    gap: 1rem;
    font-size: 0.8rem;
    color: var(--text-tertiary);
}

/* Section Scroll Offset for Sticky Nav */
section[id] {
    scroll-margin-top: 80px;
}

/* Features Section */
.features-section {
    padding: 5rem 0;
    background: white;
}

.section-title-block {
    text-align: center;
    margin-bottom: 3rem;
}

.section-title {
    font-size: clamp(1.75rem, 3vw, 2.25rem);
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 0.75rem;
    line-height: 1.2;
}

.section-subtitle {
    font-size: clamp(0.9375rem, 1.5vw, 1.0625rem);
    color: var(--text-secondary);
    max-width: 700px;
    margin: 0 auto;
    line-height: 1.6;
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
    max-width: 1200px;
    margin: 0 auto;
}

@media (max-width: 1024px) {
    .features-grid {
        grid-template-columns: repeat(3, 1fr);
        gap: 1.5rem;
    }
}

@media (max-width: 768px) {
    .features-grid {
        grid-template-columns: repeat(3, 1fr);
        gap: 1rem;
    }
}

.feature-card {
    padding: 2rem;
    background: white;
    border: 1.5px solid var(--border-color);
    border-radius: 16px;
    transition: all 0.3s ease;
}

.feature-card:hover {
    border-color: #8b5cf6;
    transform: translateY(-4px);
    box-shadow: 0 8px 24px rgba(139, 92, 246, 0.15);
}

.feature-number {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    background: linear-gradient(135deg, #8b5cf6, #6366f1);
    color: white;
    border-radius: 8px;
    font-weight: 600;
    font-size: 1.125rem;
    margin-bottom: 1.25rem;
}

.feature-title {
    font-size: 1.125rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 0.75rem;
}

.feature-description {
    font-size: 0.9375rem;
    color: var(--text-secondary);
    line-height: 1.6;
    margin: 0;
}

/* How It Works Section */
.how-it-works-section {
    padding: 5rem 0;
}

.how-it-works-section .section-title {
    color: #ffffff !important;
}

.how-it-works-section .section-subtitle {
    color: rgba(255, 255, 255, 0.9) !important;
}

.detectors-list {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 1rem;
    max-width: 800px;
    margin: 2rem auto 0;
}

.detector-badge {
    padding: 0.625rem 1.5rem;
    background: rgba(255, 255, 255, 0.15);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 999px;
    color: white;
    font-size: 0.9375rem;
    font-weight: 500;
}

/* Pricing Section */
.pricing-section {
    padding: 5rem 0;
    background: #fafbfc;
}

.billing-toggle-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
    margin-bottom: 3rem;
}

.billing-toggle {
    display: flex;
    background: white;
    border: 1.5px solid var(--border-color);
    border-radius: 12px;
    padding: 0.25rem;
    gap: 0.25rem;
}

.billing-toggle-btn {
    padding: 0.625rem 1.5rem;
    border: none;
    background: transparent;
    color: var(--text-secondary);
    font-weight: 600;
    font-size: 0.9375rem;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.billing-toggle-btn.active {
    background: linear-gradient(135deg, #8b5cf6, #6366f1);
    color: white;
}

.billing-toggle-btn:hover:not(.active) {
    background: #f9fafb;
    color: var(--text-primary);
}

.billing-savings {
    color: #10b981;
    font-size: 0.875rem;
    font-weight: 600;
    margin: 0;
}

.pricing-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 2rem;
    max-width: 900px;
    margin: 0 auto;
}

@media (max-width: 768px) {
    .pricing-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 1rem;
    }
}

.pricing-card {
    padding: 2.5rem 2rem;
    background: white;
    border: 1.5px solid var(--border-color);
    border-radius: 20px;
    position: relative;
    transition: all 0.3s ease;
}

.pricing-card:hover {
    border-color: #8b5cf6;
    transform: translateY(-6px);
    box-shadow: 0 12px 32px rgba(139, 92, 246, 0.15);
}

.pricing-card.featured {
    border-color: #8b5cf6;
    border-width: 2px;
    box-shadow: 0 8px 24px rgba(139, 92, 246, 0.15);
}

.popular-badge {
    position: absolute;
    top: -12px;
    left: 50%;
    transform: translateX(-50%);
    padding: 0.375rem 1rem;
    background: linear-gradient(135deg, #8b5cf6, #6366f1);
    color: white;
    border-radius: 999px;
    font-size: 0.8125rem;
    font-weight: 600;
}

.pricing-title {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 1rem;
}

.pricing-price {
    margin-bottom: 2rem;
}

.price-amount {
    font-size: 2.5rem;
    font-weight: 800;
    color: var(--text-primary);
}

.price-period {
    font-size: 1rem;
    color: var(--text-secondary);
}

.price-billed {
    display: block;
    font-size: 0.875rem;
    color: var(--text-secondary);
    margin-top: 0.25rem;
    font-weight: 500;
}

.pricing-features {
    list-style: none;
    padding: 0;
    margin: 0 0 2rem 0;
}

.pricing-features li {
    padding: 0.625rem 0;
    color: var(--text-secondary);
    font-size: 0.9375rem;
}

.pricing-btn {
    width: 100%;
    padding: 0.875rem 1.5rem;
    background: white;
    border: 1.5px solid var(--border-color);
    border-radius: 10px;
    color: var(--text-primary);
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
}

.pricing-btn:hover {
    background: #f9fafb;
    border-color: #8b5cf6;
}

.pricing-btn.primary {
    background: linear-gradient(135deg, #8b5cf6, #6366f1);
    border: none;
    color: white;
}

.pricing-btn.primary:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(139, 92, 246, 0.3);
}

/* Affiliate Section */
.affiliate-section {
    padding: 5rem 0;
}

.affiliate-content {
    max-width: 800px;
    margin: 0 auto;
    text-align: center;
    color: white;
    position: relative;
    z-index: 1;
}

.affiliate-text {
    position: relative;
    z-index: 2;
}

.affiliate-benefits {
    list-style: none;
    padding: 0;
    margin: 2rem 0;
    display: flex;
    flex-wrap: nowrap;
    justify-content: center;
    gap: 1rem;
}

@media (max-width: 768px) {
    .affiliate-benefits {
        flex-wrap: wrap;
        gap: 0.75rem;
    }
}

.affiliate-benefits li {
    padding: 1rem;
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    border-radius: 12px;
    font-size: 1rem;
    font-weight: 500;
}

.cta-button {
    padding: 1rem 3rem;
    background: white;
    color: #8b5cf6;
    border: none;
    border-radius: 10px;
    font-size: 1.0625rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    position: relative;
    z-index: 10;
    pointer-events: auto;
}

.cta-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(255, 255, 255, 0.3);
}

.cta-button:active {
    transform: translateY(0);
}

/* FAQ Section */
.faq-section {
    padding: 5rem 0;
    background: white;
}

.faq-container {
    max-width: 800px;
    margin: 0 auto;
}

.faq-item {
    padding: 1.75rem 0;
    border-bottom: 1px solid var(--border-color);
}

.faq-item:first-child {
    padding-top: 0;
}

.faq-question-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    cursor: pointer;
    user-select: none;
}

.faq-question-header:hover {
    opacity: 0.8;
}

.faq-question {
    font-size: 1.125rem;
    font-weight: 600;
    color: var(--text-primary);
    margin: 0;
    flex: 1;
}

.faq-arrow {
    font-size: 0.875rem;
    color: var(--text-secondary);
    margin-left: 1rem;
    transition: transform 0.3s ease;
}

.faq-answer {
    font-size: 0.9375rem;
    color: var(--text-secondary);
    line-height: 1.7;
    margin: 0.75rem 0 0 0;
    padding-top: 0.75rem;
    animation: fadeIn 0.3s ease;
}

/* Footer */
.footer {
    background: #0a0e1a;
    border-top: 1px solid rgba(139, 92, 246, 0.2);
    padding: 3.5rem 0 1.5rem;
}

.footer-grid {
    display: grid;
    grid-template-columns: 2fr repeat(3, 1fr);
    gap: 3rem;
    margin-bottom: 3rem;
}

@media (max-width: 768px) {
    .footer-grid {
        grid-template-columns: 1fr;
        gap: 2rem;
    }
}

.footer-brand h3 {
    font-size: 1.5rem;
    font-weight: 700;
    background: linear-gradient(90deg, #a78bfa 0%, #60a5fa 50%, #34d399 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 0.5rem;
}

.footer-brand p {
    color: #94a3b8;
    font-size: 0.95rem;
}

.footer-column h4 {
    color: white;
    font-size: 0.9375rem;
    font-weight: 600;
    margin-bottom: 1rem;
}

.footer-column {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.footer-column a {
    color: #94a3b8;
    text-decoration: none;
    font-size: 0.9375rem;
    transition: color 0.2s ease;
}

.footer-column a:hover {
    color: #a78bfa;
}

.footer-bottom {
    text-align: center;
    padding-top: 1.5rem;
    border-top: 1px solid rgba(139, 92, 246, 0.2);
}

.footer-bottom p {
    color: #64748b;
    font-size: 0.875rem;
}

/* Comparison Modal */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: var(--bg-overlay);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
    justify-content: center;
    z-index: 1000;
    padding: 1rem;
    animation: fadeIn 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.modal-content {
    background: #ffffff !important;
    border-radius: var(--border-radius-xl);
    box-shadow: var(--shadow-2xl);
    max-width: 1200px;
    width: 100%;
    max-height: 90vh;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    animation: slideUp 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    border: 1px solid var(--border-color);
    opacity: 1;
}

.modal-body {
    background: #ffffff !important;
    padding: 2rem;
}

.modal-header {
    background: #ffffff !important;
}

.modal-footer {
    background: #ffffff !important;
}

@media (prefers-color-scheme: dark) {
    .modal-content {
        background: #1e293b !important;
    }
    
    .modal-body {
        background: #1e293b !important;
    }
    
    .modal-header {
        background: #1e293b !important;
    }
    
    .modal-footer {
        background: #1e293b !important;
    }
}

@keyframes slideUp {
    from {
        transform: translateY(20px);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.5rem 2rem;
    border-bottom: 1px solid var(--border-color);
}

.modal-header h2 {
    font-size: 1.5rem;
    font-weight: 600;
}

.modal-close {
    width: 32px;
    height: 32px;
    border: none;
    background: var(--bg-tertiary);
    border-radius: 50%;
    font-size: 1.25rem;
    cursor: pointer;
    transition: all 0.2s ease;
}

.modal-close:hover {
    background: var(--border-color);
    transform: rotate(90deg);
}

.comparison-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 2rem;
    padding: 2rem;
    overflow-y: auto;
}

@media (max-width: 768px) {
    .comparison-grid {
        grid-template-columns: 1fr;
    }
}

.comparison-panel h3 {
    font-size: 1.125rem;
    font-weight: 600;
    margin-bottom: 1rem;
}

.comparison-text {
    padding: 1.5rem;
    background: var(--bg-secondary);
    border-radius: var(--border-radius);
    border: 1px solid var(--border-color);
    min-height: 300px;
    max-height: 400px;
    overflow-y: auto;
    line-height: 1.8;
    white-space: pre-wrap;
    margin-bottom: 1rem;
}

.comparison-stats {
    display: flex;
    gap: 1.5rem;
    font-size: 0.875rem;
    color: var(--text-secondary);
}

.comparison-stats.success {
    color: var(--success);
}

/* Modal Styles */
.modal-body {
    padding: 2rem;
}

.modal-footer {
    display: flex;
    justify-content: flex-end;
    gap: 1rem;
    padding: 1.5rem 2rem;
    border-top: 1px solid var(--border-color);
}

.modal-btn {
    padding: 0.75rem 1.5rem;
    border: none;
    border-radius: 8px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
}

.modal-btn-primary {
    background: linear-gradient(135deg, #8b5cf6, #6366f1);
    color: white;
}

.modal-btn-primary:hover:not(:disabled) {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(139, 92, 246, 0.3);
}

.modal-btn-secondary {
    background: var(--bg-secondary);
    color: var(--text-primary);
    border: 1px solid var(--border-color);
}

.modal-btn-secondary:hover:not(:disabled) {
    background: var(--bg-tertiary);
}

.modal-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

/* Affiliate Modal Styles */
.affiliate-info {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.affiliate-field {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.affiliate-field label {
    font-weight: 600;
    color: var(--text-primary);
    font-size: 0.9375rem;
}

.affiliate-code-display,
.affiliate-link-display {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.affiliate-code-display code {
    flex: 1;
    padding: 0.75rem 1rem;
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    font-family: 'Courier New', monospace;
    font-size: 1rem;
    font-weight: 600;
    color: var(--text-primary);
}

.affiliate-link-input {
    flex: 1;
    padding: 0.75rem 1rem;
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    font-size: 0.9375rem;
    color: var(--text-primary);
}

.copy-btn {
    padding: 0.75rem 1rem;
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    cursor: pointer;
    font-size: 1.125rem;
    transition: all 0.2s ease;
}

.copy-btn:hover {
    background: var(--bg-tertiary);
    transform: scale(1.05);
}

.affiliate-note {
    margin-top: 1rem;
    padding: 1rem;
    background: rgba(139, 92, 246, 0.1);
    border-left: 3px solid #8b5cf6;
    border-radius: 8px;
    color: var(--text-secondary);
    font-size: 0.9375rem;
}

/* Word Limit Modal Styles */
.word-limit-modal {
    max-width: 500px;
}

.word-limit-content {
    text-align: center;
    padding: 1rem 0;
}

.word-limit-icon {
    font-size: 4rem;
    margin-bottom: 1.5rem;
    animation: pulse 2s ease-in-out infinite;
}

@keyframes pulse {
    0%, 100% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.1);
    }
}

.word-limit-content h4 {
    font-size: 1.5rem;
    font-weight: 600;
    margin-bottom: 1rem;
    color: var(--text-primary);
}

.word-limit-message {
    font-size: 1.125rem;
    color: var(--text-primary);
    margin-bottom: 1rem;
    line-height: 1.6;
}

.word-limit-message strong {
    color: #8b5cf6;
    font-weight: 600;
}

.word-limit-description {
    font-size: 1rem;
    color: var(--text-secondary);
    margin-bottom: 1.5rem;
    line-height: 1.6;
}

.word-usage-stats {
    margin-top: 1.5rem;
    padding: 1.5rem;
    background: var(--bg-secondary);
    border-radius: var(--border-radius);
    border: 1px solid var(--border-color);
}

.usage-stat {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.75rem 0;
}

.usage-label {
    font-size: 0.875rem;
    color: var(--text-secondary);
    font-weight: 500;
}

.usage-value {
    font-size: 1.125rem;
    font-weight: 600;
    color: var(--text-primary);
}

.word-limit-modal .modal-footer {
    justify-content: space-between;
}

.word-limit-modal .modal-btn-primary {
    flex: 1;
    max-width: 200px;
}

/* Responsive */
@media (max-width: 768px) {
    .hero {
        padding: 3rem 0 4rem;
    }

    .controls-bar {
        flex-direction: column;
        gap: 1.5rem;
    }

    .trust-badges {
        flex-direction: column;
        align-items: center;
    }

    .section-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.75rem;
    }

    .action-buttons {
        flex-wrap: wrap;
    }
}

/* Payment Success & Cancel Pages */
.payment-success-page,
.payment-cancel-page {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem;
    background: var(--bg-secondary);
}

.payment-success-container,
.payment-cancel-container {
    max-width: 500px;
    width: 100%;
    text-align: center;
    padding: 3rem 2rem;
    background: var(--bg-card);
    border-radius: var(--border-radius-xl);
    box-shadow: var(--shadow-xl);
}

.success-icon {
    width: 80px;
    height: 80px;
    margin: 0 auto 2rem;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--success);
    color: white;
    border-radius: 50%;
    font-size: 3rem;
    font-weight: bold;
    animation: scaleIn 0.5s ease;
}

.cancel-icon {
    width: 80px;
    height: 80px;
    margin: 0 auto 2rem;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--danger);
    color: white;
    border-radius: 50%;
    font-size: 3rem;
    font-weight: bold;
    animation: scaleIn 0.5s ease;
}

@keyframes scaleIn {
    from {
        transform: scale(0);
        opacity: 0;
    }
    to {
        transform: scale(1);
        opacity: 1;
    }
}

.payment-success-container h1,
.payment-cancel-container h1 {
    font-size: 2rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 1rem;
}

.success-message,
.cancel-message {
    font-size: 1.125rem;
    color: var(--text-secondary);
    margin-bottom: 0.5rem;
}

.success-details,
.cancel-details {
    font-size: 1rem;
    color: var(--text-tertiary);
    margin-bottom: 2rem;
}

.success-actions,
.cancel-actions {
    margin-top: 2rem;
}

.success-actions .cta-button,
.cancel-actions .cta-button {
    min-width: 200px;
}

/* Keep sections horizontal - removed stacking for features, pricing, and affiliate */
@media (max-width: 768px) {
    .input-actions-center {
        flex-direction: column;
        gap: 0.75rem;
    }
}

@media (max-width: 1024px) {
    .features-section,
    .pricing-section,
    .faq-section,
    .how-it-works-section,
    .affiliate-section {
        padding: 3rem 0;
    }
}

/* Style Wizard Styles */
.style-wizard-content {
    max-width: 700px;
    width: 90%;
}

.wizard-progress {
    margin-bottom: 2rem;
}

.progress-bar {
    width: 100%;
    height: 8px;
    background: var(--bg-tertiary);
    border-radius: 4px;
    overflow: hidden;
    margin-bottom: 0.5rem;
}

.progress-fill {
    height: 100%;
    background: linear-gradient(135deg, #8b5cf6, #6366f1);
    transition: width 0.3s ease;
    border-radius: 4px;
}

.progress-text {
    text-align: center;
    font-size: 0.875rem;
    color: var(--text-secondary);
    font-weight: 500;
}

.wizard-question {
    margin-bottom: 1.5rem;
}

.question-title {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 0.5rem;
}

.question-description {
    font-size: 1rem;
    color: var(--text-secondary);
    line-height: 1.6;
}

.word-count-indicator {
    margin-bottom: 1rem;
    padding: 0.75rem 1rem;
    background: var(--bg-secondary);
    border-radius: 8px;
    font-size: 0.9375rem;
    color: var(--text-secondary);
    text-align: center;
    border: 2px solid var(--border-color);
    transition: all 0.2s ease;
}

.word-count-indicator.sufficient {
    background: rgba(16, 185, 129, 0.1);
    border-color: var(--success);
    color: var(--success);
    font-weight: 600;
}

.word-count-indicator strong {
    font-size: 1.125rem;
    font-weight: 700;
}

.style-textarea {
    width: 100%;
    padding: 1rem;
    border: 2px solid var(--border-color);
    border-radius: 12px;
    font-size: 1rem;
    font-family: inherit;
    line-height: 1.6;
    color: var(--text-primary);
    background: var(--bg-primary);
    resize: vertical;
    min-height: 200px;
    transition: all 0.2s ease;
    margin-bottom: 1.5rem;
}

.style-textarea:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.1);
}

.wizard-navigation {
    display: flex;
    justify-content: space-between;
    gap: 1rem;
    margin-top: 1.5rem;
}

.analyzing-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 3rem 2rem;
    text-align: center;
}

.analyzing-spinner {
    width: 60px;
    height: 60px;
    border: 4px solid var(--bg-tertiary);
    border-top-color: var(--primary);
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin-bottom: 1.5rem;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

.analyzing-text {
    font-size: 1.125rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 0.5rem;
}

.analyzing-subtext {
    font-size: 0.9375rem;
    color: var(--text-secondary);
}

/* Affiliate Dashboard Styles */
.affiliate-dashboard-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 2rem;
    min-height: 100vh;
}

.dashboard-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
    padding-bottom: 1rem;
    border-bottom: 2px solid var(--border-color);
}

.dashboard-header h1 {
    font-size: 2rem;
    font-weight: 700;
    color: var(--text-primary);
    margin: 0;
}

.back-btn {
    padding: 0.75rem 1.5rem;
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    color: var(--text-primary);
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
}

.back-btn:hover {
    background: var(--bg-tertiary);
    transform: translateY(-1px);
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1.5rem;
    margin-bottom: 3rem;
}

.stat-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 16px;
    padding: 1.5rem;
    display: flex;
    align-items: center;
    gap: 1rem;
    box-shadow: var(--shadow-md);
    transition: all 0.2s ease;
}

.stat-card:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

.stat-card.earnings {
    border-left: 4px solid var(--success);
}

.stat-card.pending {
    border-left: 4px solid var(--warning);
}

.stat-card.paid {
    border-left: 4px solid var(--primary);
}

.stat-icon {
    font-size: 2.5rem;
    width: 60px;
    height: 60px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--bg-secondary);
    border-radius: 12px;
}

.stat-content {
    flex: 1;
}

.stat-label {
    font-size: 0.875rem;
    color: var(--text-secondary);
    margin-bottom: 0.5rem;
    font-weight: 500;
}

.stat-value {
    font-size: 1.75rem;
    font-weight: 700;
    color: var(--text-primary);
}

.affiliate-info-section {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 16px;
    padding: 2rem;
    box-shadow: var(--shadow-md);
}

.affiliate-info-section h2 {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 1.5rem;
}

.code-display {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 1rem;
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 8px;
}

.code-display code {
    flex: 1;
    font-family: 'Courier New', monospace;
    font-size: 1rem;
    font-weight: 600;
    color: var(--text-primary);
}

.link-display {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.link-input {
    flex: 1;
    padding: 1rem;
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    font-size: 0.9375rem;
    color: var(--text-primary);
    font-family: inherit;
}

.copy-btn {
    padding: 0.75rem 1rem;
    background: var(--primary);
    color: white;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-size: 1.125rem;
    transition: all 0.2s ease;
    min-width: 50px;
}

.copy-btn:hover {
    background: var(--primary-dark);
    transform: scale(1.05);
}

.loading-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 4rem 2rem;
    text-align: center;
}

.error-container {
    background: var(--bg-card);
    border: 1px solid var(--danger);
    border-radius: 12px;
    padding: 2rem;
    text-align: center;
    color: var(--text-primary);
}

.retry-btn {
    margin-top: 1rem;
    padding: 0.75rem 1.5rem;
    background: var(--primary);
    color: white;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-weight: 600;
    transition: all 0.2s ease;
}

.retry-btn:hover {
    background: var(--primary-dark);
    transform: translateY(-1px);
}

/* Typewriter/Streaming Effect */
.streaming-text {
    white-space: pre-wrap;
    word-wrap: break-word;
}

.cursor {
    display: inline-block;
    width: 2px;
    height: 1.2em;
    background: var(--primary);
    margin-left: 2px;
    animation: blink 1s infinite;
    vertical-align: baseline;
}

@keyframes blink {
    0%, 50% {
        opacity: 1;
    }
    51%, 100% {
        opacity: 0;
    }
}
