/* ==========================================
   PerfAnalysis Landing Page Styles
   Modern, Premium UI Design
   ========================================== */

:root {
    /* Colors */
    --primary: #6366f1;
    --primary-dark: #4f46e5;
    --primary-light: #818cf8;
    --secondary: #0ea5e9;
    --accent: #f472b6;
    
    --bg-dark: #0f0f23;
    --bg-card: #1a1a2e;
    --bg-elevated: #252540;
    
    --text-primary: #ffffff;
    --text-secondary: #a1a1aa;
    --text-muted: #71717a;
    
    --border: rgba(255, 255, 255, 0.1);
    --border-hover: rgba(255, 255, 255, 0.2);
    
    --gradient-primary: linear-gradient(135deg, #6366f1 0%, #8b5cf6 50%, #d946ef 100%);
    --gradient-hero: radial-gradient(ellipse at top, rgba(99, 102, 241, 0.3) 0%, transparent 60%);
    
    /* Spacing */
    --section-padding: 120px;
    --container-width: 1200px;
    
    /* Transitions */
    --transition-fast: 0.15s ease;
    --transition-base: 0.3s ease;
    --transition-slow: 0.5s ease;
    
    /* Shadows */
    --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.2);
    --shadow-md: 0 8px 24px rgba(0, 0, 0, 0.3);
    --shadow-lg: 0 16px 48px rgba(0, 0, 0, 0.4);
    --shadow-glow: 0 0 40px rgba(99, 102, 241, 0.4);
}

/* Reset & Base */
*, *::before, *::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    background: var(--bg-dark);
    color: var(--text-primary);
    line-height: 1.6;
    overflow-x: hidden;
}

.container {
    max-width: var(--container-width);
    margin: 0 auto;
    padding: 0 24px;
}

a {
    text-decoration: none;
    color: inherit;
}

/* ==========================================
   Typography
   ========================================== */

h1, h2, h3, h4, h5, h6 {
    font-weight: 700;
    line-height: 1.2;
}

h1 { font-size: clamp(2.5rem, 5vw, 4rem); }
h2 { font-size: clamp(2rem, 4vw, 3rem); }
h3 { font-size: 1.5rem; }

.gradient-text {
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* ==========================================
   Buttons
   ========================================== */

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 12px 24px;
    font-size: 0.95rem;
    font-weight: 600;
    border-radius: 12px;
    border: none;
    cursor: pointer;
    transition: all var(--transition-base);
}

.btn-primary {
    background: var(--gradient-primary);
    color: white;
    box-shadow: var(--shadow-glow);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 0 60px rgba(99, 102, 241, 0.6);
}

.btn-ghost {
    background: transparent;
    color: var(--text-secondary);
}

.btn-ghost:hover {
    color: var(--text-primary);
}

.btn-glass {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    border: 1px solid var(--border);
    color: white;
}

.btn-glass:hover {
    background: rgba(255, 255, 255, 0.15);
    border-color: var(--border-hover);
}

.btn-outline {
    background: transparent;
    border: 2px solid var(--border);
    color: var(--text-primary);
}

.btn-outline:hover {
    border-color: var(--primary);
    background: rgba(99, 102, 241, 0.1);
}

.btn-large {
    padding: 16px 32px;
    font-size: 1.05rem;
    border-radius: 14px;
}

.btn-full {
    width: 100%;
}

/* ==========================================
   Navigation
   ========================================== */

.navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    padding: 16px 0;
    background: rgba(15, 15, 35, 0.8);
    backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--border);
}

.nav-container {
    max-width: var(--container-width);
    margin: 0 auto;
    padding: 0 24px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.logo {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 1.4rem;
    font-weight: 700;
}

.logo-icon {
    font-size: 1.6rem;
}

.nav-links {
    display: flex;
    gap: 32px;
}

.nav-links a {
    color: var(--text-secondary);
    font-weight: 500;
    transition: color var(--transition-fast);
}

.nav-links a:hover {
    color: var(--text-primary);
}

.nav-actions {
    display: flex;
    gap: 12px;
}

.mobile-menu-btn {
    display: none;
    flex-direction: column;
    gap: 5px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 8px;
}

.mobile-menu-btn span {
    display: block;
    width: 24px;
    height: 2px;
    background: var(--text-primary);
    transition: var(--transition-base);
}

/* ==========================================
   Hero Section
   ========================================== */

.hero {
    position: relative;
    min-height: 100vh;
    display: flex;
    align-items: center;
    padding: calc(var(--section-padding) + 60px) 0 var(--section-padding);
    overflow: hidden;
}

.hero-bg {
    position: absolute;
    inset: 0;
    background: var(--gradient-hero);
    pointer-events: none;
}

.hero-bg::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 800px;
    height: 800px;
    background: radial-gradient(circle, rgba(99, 102, 241, 0.15) 0%, transparent 70%);
    animation: pulse 8s ease-in-out infinite;
}

@keyframes pulse {
    0%, 100% { transform: translate(-50%, -50%) scale(1); opacity: 0.5; }
    50% { transform: translate(-50%, -50%) scale(1.2); opacity: 0.8; }
}

.hero .container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    align-items: center;
}

.hero-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 16px;
    background: rgba(99, 102, 241, 0.1);
    border: 1px solid rgba(99, 102, 241, 0.3);
    border-radius: 50px;
    font-size: 0.9rem;
    color: var(--primary-light);
    margin-bottom: 24px;
}

.hero h1 {
    margin-bottom: 24px;
}

.hero-subtitle {
    font-size: 1.25rem;
    color: var(--text-secondary);
    max-width: 500px;
    margin-bottom: 32px;
}

.hero-cta {
    display: flex;
    gap: 16px;
    margin-bottom: 48px;
}

.hero-stats {
    display: flex;
    gap: 48px;
}

.stat {
    display: flex;
    flex-direction: column;
}

.stat-value {
    font-size: 2rem;
    font-weight: 800;
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.stat-label {
    color: var(--text-muted);
    font-size: 0.9rem;
}

/* Dashboard Preview */
.dashboard-preview {
    background: var(--bg-card);
    border-radius: 20px;
    border: 1px solid var(--border);
    overflow: hidden;
    box-shadow: var(--shadow-lg);
    transform: perspective(1000px) rotateY(-5deg) rotateX(5deg);
    transition: transform var(--transition-slow);
}

.dashboard-preview:hover {
    transform: perspective(1000px) rotateY(0deg) rotateX(0deg);
}

.preview-header {
    padding: 12px 16px;
    background: var(--bg-elevated);
    border-bottom: 1px solid var(--border);
}

.preview-dots {
    display: flex;
    gap: 8px;
}

.preview-dots span {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: var(--text-muted);
}

.preview-dots span:nth-child(1) { background: #ef4444; }
.preview-dots span:nth-child(2) { background: #eab308; }
.preview-dots span:nth-child(3) { background: #22c55e; }

.preview-content {
    display: grid;
    grid-template-columns: 60px 1fr;
    min-height: 300px;
}

.preview-sidebar {
    background: var(--bg-elevated);
    padding: 16px 12px;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.preview-menu-item {
    height: 32px;
    border-radius: 8px;
    background: var(--border);
}

.preview-menu-item.active {
    background: var(--primary);
}

.preview-main {
    padding: 20px;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
}

.preview-card {
    height: 80px;
    background: var(--bg-elevated);
    border-radius: 12px;
    border: 1px solid var(--border);
}

.preview-chart {
    grid-column: span 2;
    height: 120px;
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.2), rgba(139, 92, 246, 0.1));
    border-radius: 12px;
    border: 1px solid var(--border);
}

/* ==========================================
   Section Styles
   ========================================== */

.section-header {
    text-align: center;
    max-width: 700px;
    margin: 0 auto 64px;
}

.section-badge {
    display: inline-block;
    padding: 8px 16px;
    background: rgba(99, 102, 241, 0.1);
    border: 1px solid rgba(99, 102, 241, 0.3);
    border-radius: 50px;
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--primary-light);
    margin-bottom: 20px;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.section-header h2 {
    margin-bottom: 16px;
}

.section-header p {
    color: var(--text-secondary);
    font-size: 1.1rem;
}

/* ==========================================
   Features Section
   ========================================== */

.features {
    padding: var(--section-padding) 0;
    background: linear-gradient(180deg, var(--bg-dark) 0%, var(--bg-card) 100%);
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
}

.feature-card {
    padding: 32px;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 20px;
    transition: all var(--transition-base);
}

.feature-card:hover {
    border-color: var(--primary);
    transform: translateY(-4px);
    box-shadow: var(--shadow-md);
}

.feature-icon {
    font-size: 2.5rem;
    margin-bottom: 20px;
}

.feature-card h3 {
    margin-bottom: 12px;
}

.feature-card p {
    color: var(--text-secondary);
    font-size: 0.95rem;
}

/* ==========================================
   How It Works Section
   ========================================== */

.how-it-works {
    padding: var(--section-padding) 0;
}

.steps {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0;
}

.step {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    max-width: 280px;
}

.step-number {
    width: 64px;
    height: 64px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    font-weight: 800;
    background: var(--gradient-primary);
    border-radius: 50%;
    margin-bottom: 24px;
}

.step-content h3 {
    margin-bottom: 12px;
}

.step-content p {
    color: var(--text-secondary);
    font-size: 0.95rem;
}

.step-connector {
    width: 100px;
    height: 2px;
    background: linear-gradient(90deg, var(--primary), var(--primary-light));
    margin: 0 24px;
    margin-bottom: 80px;
}

/* ==========================================
   Pricing Section
   ========================================== */

.pricing {
    padding: var(--section-padding) 0;
    background: linear-gradient(180deg, var(--bg-dark) 0%, var(--bg-card) 50%, var(--bg-dark) 100%);
}

.pricing-toggle {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 16px;
    margin-bottom: 48px;
}

.toggle-label {
    color: var(--text-muted);
    font-weight: 500;
    transition: color var(--transition-fast);
}

.toggle-label.active {
    color: var(--text-primary);
}

.save-badge {
    display: inline-block;
    padding: 4px 8px;
    background: rgba(34, 197, 94, 0.2);
    color: #22c55e;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 600;
}

.toggle-switch {
    position: relative;
    width: 56px;
    height: 28px;
}

.toggle-switch input {
    opacity: 0;
    width: 0;
    height: 0;
}

.toggle-slider {
    position: absolute;
    cursor: pointer;
    inset: 0;
    background: var(--bg-elevated);
    border: 1px solid var(--border);
    border-radius: 28px;
    transition: var(--transition-base);
}

.toggle-slider::before {
    content: '';
    position: absolute;
    height: 20px;
    width: 20px;
    left: 4px;
    bottom: 3px;
    background: var(--primary);
    border-radius: 50%;
    transition: var(--transition-base);
}

.toggle-switch input:checked + .toggle-slider::before {
    transform: translateX(26px);
}

.pricing-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
    align-items: start;
}

.pricing-card {
    padding: 40px 32px;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 24px;
    position: relative;
    transition: all var(--transition-base);
}

.pricing-card:hover {
    border-color: var(--border-hover);
    transform: translateY(-4px);
}

.pricing-card.featured {
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.1), rgba(139, 92, 246, 0.05));
    border-color: var(--primary);
    transform: scale(1.05);
}

.pricing-card.featured:hover {
    transform: scale(1.05) translateY(-4px);
}

.featured-badge {
    position: absolute;
    top: -12px;
    left: 50%;
    transform: translateX(-50%);
    padding: 6px 16px;
    background: var(--gradient-primary);
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 600;
}

.pricing-header h3 {
    font-size: 1.4rem;
    margin-bottom: 8px;
}

.pricing-header p {
    color: var(--text-muted);
    font-size: 0.9rem;
}

.pricing-price {
    margin: 32px 0;
    display: flex;
    align-items: baseline;
    gap: 4px;
}

.currency {
    font-size: 1.5rem;
    font-weight: 600;
    color: var(--text-secondary);
}

.amount {
    font-size: 3.5rem;
    font-weight: 800;
    line-height: 1;
}

.period {
    color: var(--text-muted);
    font-size: 0.95rem;
}

.pricing-features {
    list-style: none;
    margin-bottom: 32px;
}

.pricing-features li {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 0;
    border-bottom: 1px solid var(--border);
    color: var(--text-secondary);
    font-size: 0.95rem;
}

.pricing-features li:last-child {
    border-bottom: none;
}

.pricing-features svg {
    width: 20px;
    height: 20px;
    stroke: var(--primary);
    stroke-width: 3;
    fill: none;
}

/* ==========================================
   Signup Section
   ========================================== */

.signup {
    padding: var(--section-padding) 0;
}

.signup-wrapper {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 80px;
    align-items: center;
}

.signup-info h2 {
    margin-bottom: 20px;
}

.signup-info p {
    color: var(--text-secondary);
    font-size: 1.1rem;
    margin-bottom: 32px;
}

.signup-benefits {
    list-style: none;
}

.signup-benefits li {
    color: var(--text-secondary);
    padding: 8px 0;
    font-size: 1rem;
}

.signup-form-container {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 24px;
    padding: 40px;
}

.signup-form h3 {
    text-align: center;
    margin-bottom: 32px;
    font-size: 1.5rem;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 500;
    font-size: 0.9rem;
    color: var(--text-secondary);
}

.form-group input,
.form-group select {
    width: 100%;
    padding: 14px 16px;
    background: var(--bg-elevated);
    border: 1px solid var(--border);
    border-radius: 12px;
    color: var(--text-primary);
    font-size: 1rem;
    font-family: inherit;
    transition: border-color var(--transition-fast);
}

.form-group input:focus,
.form-group select:focus {
    outline: none;
    border-color: var(--primary);
}

.form-group input::placeholder {
    color: var(--text-muted);
}

.form-checkbox {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    margin-bottom: 24px;
}

.form-checkbox input[type="checkbox"] {
    width: 20px;
    height: 20px;
    accent-color: var(--primary);
    margin-top: 2px;
}

.form-checkbox label {
    font-size: 0.9rem;
    color: var(--text-secondary);
}

.form-checkbox label a {
    color: var(--primary-light);
}

.signin-link {
    text-align: center;
    margin-top: 20px;
    color: var(--text-muted);
    font-size: 0.9rem;
}

.signin-link a {
    color: var(--primary-light);
    font-weight: 500;
}

/* ==========================================
   Footer
   ========================================== */

.footer {
    padding: 80px 0 40px;
    background: var(--bg-card);
    border-top: 1px solid var(--border);
}

.footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr;
    gap: 48px;
    margin-bottom: 48px;
}

.footer-brand p {
    color: var(--text-muted);
    margin: 16px 0 24px;
    max-width: 280px;
}

.social-links {
    display: flex;
    gap: 12px;
}

.social-links a {
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--bg-elevated);
    border: 1px solid var(--border);
    border-radius: 10px;
    font-size: 1.1rem;
    transition: all var(--transition-fast);
}

.social-links a:hover {
    border-color: var(--primary);
    background: rgba(99, 102, 241, 0.1);
}

.footer-links h4 {
    font-size: 1rem;
    margin-bottom: 20px;
}

.footer-links a {
    display: block;
    color: var(--text-muted);
    padding: 8px 0;
    font-size: 0.9rem;
    transition: color var(--transition-fast);
}

.footer-links a:hover {
    color: var(--text-primary);
}

.footer-bottom {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: 32px;
    border-top: 1px solid var(--border);
}

.footer-bottom p {
    color: var(--text-muted);
    font-size: 0.9rem;
}

.footer-legal {
    display: flex;
    gap: 24px;
}

.footer-legal a {
    color: var(--text-muted);
    font-size: 0.9rem;
    transition: color var(--transition-fast);
}

.footer-legal a:hover {
    color: var(--text-primary);
}

/* ==========================================
   Responsive Design
   ========================================== */

@media (max-width: 1024px) {
    .hero .container {
        grid-template-columns: 1fr;
        text-align: center;
    }
    
    .hero-subtitle {
        margin: 0 auto 32px;
    }
    
    .hero-cta {
        justify-content: center;
    }
    
    .hero-stats {
        justify-content: center;
    }
    
    .hero-image {
        display: none;
    }
    
    .features-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .pricing-grid {
        grid-template-columns: 1fr;
        max-width: 400px;
        margin: 0 auto;
    }
    
    .pricing-card.featured {
        transform: none;
    }
    
    .signup-wrapper {
        grid-template-columns: 1fr;
        gap: 48px;
        text-align: center;
    }
    
    .footer-grid {
        grid-template-columns: 1fr 1fr;
    }
}

@media (max-width: 768px) {
    :root {
        --section-padding: 80px;
    }
    
    .nav-links,
    .nav-actions {
        display: none;
    }
    
    .mobile-menu-btn {
        display: flex;
    }
    
    .features-grid {
        grid-template-columns: 1fr;
    }
    
    .steps {
        flex-direction: column;
        gap: 24px;
    }
    
    .step-connector {
        width: 2px;
        height: 40px;
        margin: 0;
    }
    
    .form-row {
        grid-template-columns: 1fr;
    }
    
    .footer-grid {
        grid-template-columns: 1fr;
        text-align: center;
    }
    
    .footer-brand {
        display: flex;
        flex-direction: column;
        align-items: center;
    }
    
    .social-links {
        justify-content: center;
    }
    
    .footer-bottom {
        flex-direction: column;
        gap: 16px;
        text-align: center;
    }
}

@media (max-width: 480px) {
    .hero-cta {
        flex-direction: column;
    }
    
    .hero-stats {
        flex-direction: column;
        gap: 24px;
    }
    
    .signup-form-container {
        padding: 24px;
    }
}
