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

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background: #0a0a0a;
    color: #ffffff;
    line-height: 1.6;
    overflow-x: hidden;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
}

/* Loading Screen */
.loading-screen {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(circle at center, rgba(255, 36, 110, 0.1) 0%, #0a0a0a 70%);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    z-index: 9999;
    transition: opacity 0.5s ease, visibility 0.5s ease;
}

.loading-screen.hidden {
    opacity: 0;
    visibility: hidden;
}

.loading-spinner {
    width: 60px;
    height: 60px;
    border: 3px solid rgba(255, 36, 110, 0.3);
    border-top: 3px solid #ff246e;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

.loading-text {
    margin-top: 2rem;
    font-size: 1.2rem;
    font-weight: 700;
    color: #ff246e;
    text-align: center;
    animation: pulse 2s ease-in-out infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.5; }
}

/* Particle Canvas */
#particle-canvas {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
    pointer-events: none;
}

/* Sticky CTA */
.sticky-cta {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    z-index: 1000;
    opacity: 0;
    transform: translateY(100px);
    transition: all 0.3s ease;
}

.sticky-cta.visible {
    opacity: 1;
    transform: translateY(0);
}

.cta-button {
    position: relative;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 1rem 2rem;
    background: linear-gradient(135deg, var(--primary-color, #ff246e) 0%, var(--accent-color, #ff6a00) 100%);
    color: white;
    text-decoration: none;
    border-radius: 50px;
    font-weight: 700;
    font-size: 1rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    box-shadow: 0 10px 30px rgba(255, 36, 110, 0.3);
    transition: all 0.3s ease;
    overflow: hidden;
}

.cta-button::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 ease;
}

.cta-button:hover::before {
    left: 100%;
}

.cta-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 15px 40px rgba(255, 36, 110, 0.4);
}

.cta-glow {
    position: absolute;
    top: 50%;
    left: 50%;
    width: 100%;
    height: 100%;
    background: radial-gradient(circle, rgba(255, 36, 110, 0.3) 0%, transparent 70%);
    border-radius: 50px;
    transform: translate(-50%, -50%);
    animation: glow 2s ease-in-out infinite alternate;
}

@keyframes glow {
    0% { opacity: 0.5; transform: translate(-50%, -50%) scale(1); }
    100% { opacity: 0.8; transform: translate(-50%, -50%) scale(1.1); }
}

/* Hero Section */
.hero {
    position: relative;
    height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    overflow: hidden;
}

.hero-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: url('https://images.pexels.com/photos/3165335/pexels-photo-3165335.jpeg?auto=compress&cs=tinysrgb&w=1920&h=1080&fit=crop') center/cover;
    z-index: -2;
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, rgba(10, 10, 10, 0.8) 0%, rgba(255, 36, 110, 0.2) 50%, rgba(10, 10, 10, 0.8) 100%);
    z-index: -1;
}

.hero-content {
    position: relative;
    z-index: 2;
    max-width: 800px;
    animation: fadeInUp 1s ease-out 0.5s both;
}

.hero-title {
    font-size: clamp(2.5rem, 5vw, 4rem);
    font-weight: 900;
    line-height: 1.1;
    margin-bottom: 1.5rem;
    background: linear-gradient(135deg, #ffffff 0%, var(--primary-color, #ff246e) 50%, var(--accent-color, #ff6a00) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    text-shadow: 0 0 30px rgba(255, 36, 110, 0.3);
}

.hero-subtitle {
    font-size: 1.25rem;
    color: #cccccc;
    margin-bottom: 3rem;
    font-weight: 400;
}

.hero-stats {
    display: flex;
    justify-content: center;
    gap: 3rem;
    margin-bottom: 3rem;
}

.stat-item {
    text-align: center;
}

.stat-number {
    font-size: 3rem;
    font-weight: 900;
    color: var(--primary-color, #ff246e);
    line-height: 1;
    margin-bottom: 0.5rem;
}

.stat-label {
    font-size: 0.9rem;
    color: #999999;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.hero-cta {
    display: inline-flex;
    align-items: center;
    gap: 1rem;
    padding: 1.5rem 3rem;
    background: linear-gradient(135deg, var(--primary-color, #ff246e) 0%, var(--accent-color, #ff6a00) 100%);
    color: white;
    text-decoration: none;
    border-radius: 50px;
    font-weight: 700;
    font-size: 1.1rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    box-shadow: 0 15px 40px rgba(255, 36, 110, 0.3);
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.hero-cta::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 ease;
}

.hero-cta:hover::before {
    left: 100%;
}

.hero-cta:hover {
    transform: translateY(-3px);
    box-shadow: 0 20px 50px rgba(255, 36, 110, 0.4);
}

.cta-arrow {
    font-size: 1.5rem;
    transition: transform 0.3s ease;
}

.hero-cta:hover .cta-arrow {
    transform: translateX(5px);
}

@keyframes fadeInUp {
    0% {
        opacity: 0;
        transform: translateY(30px);
    }
    100% {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Features Section */
.features-section {
    padding: 4rem 0;
    background: linear-gradient(135deg, #0a0a0a 0%, #1a0a1a 100%);
}

.section-title {
    font-size: clamp(2rem, 4vw, 3rem);
    font-weight: 900;
    text-align: center;
    margin-bottom: 3rem;
    background: linear-gradient(135deg, #ffffff 0%, var(--primary-color, #ff246e) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    margin-top: 3rem;
}

.feature-card {
    background: rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 20px;
    padding: 2rem;
    text-align: center;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.feature-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, rgba(255, 36, 110, 0.1) 0%, transparent 50%);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.feature-card:hover::before {
    opacity: 1;
}

.feature-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 20px 40px rgba(255, 36, 110, 0.2);
}

.feature-icon {
    width: 80px;
    height: 80px;
    margin: 0 auto 1.5rem;
    background: linear-gradient(135deg, var(--primary-color, #ff246e) 0%, var(--accent-color, #ff6a00) 100%);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
}

.feature-icon svg {
    width: 40px;
    height: 40px;
}

.feature-card h3 {
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: 1rem;
    color: #ffffff;
}

.feature-card p {
    color: #cccccc;
    line-height: 1.6;
}

/* Performance Section */
.performance-section {
    padding: 4rem 0;
    background: linear-gradient(135deg, #1a0a1a 0%, #0a0a0a 100%);
    position: relative;
}

.performance-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 2rem;
    max-width: 900px;
    margin: 0 auto 3rem;
}

.performance-card {
    background: rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 20px;
    padding: 2rem;
    transition: all 0.3s ease;
}

.performance-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 20px 40px rgba(255, 36, 110, 0.2);
}

.performance-card h3 {
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: 2rem;
    text-align: center;
}

.before-card h3 {
    color: #ff6b6b;
}

.after-card h3 {
    color: #51cf66;
}

.performance-bars {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.performance-bar {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.performance-bar span {
    font-size: 0.9rem;
    color: #cccccc;
    font-weight: 600;
}

.bar-container {
    position: relative;
    height: 12px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 10px;
    overflow: hidden;
}

.bar-fill {
    height: 100%;
    border-radius: 10px;
    transition: width 2s ease;
    position: relative;
}

.before-cpu, .before-ram {
    background: linear-gradient(135deg, #ff6b6b 0%, #ee5a24 100%);
}

.after-cpu, .after-ram {
    background: linear-gradient(135deg, #51cf66 0%, #40c057 100%);
}

.bar-value {
    position: absolute;
    right: 10px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 0.8rem;
    font-weight: 700;
    color: white;
}

.cta-center {
    text-align: center;
    margin-top: 2rem;
}

/* Footer */
.footer {
    background: #000000;
    padding: 2rem 0 1rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.footer-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
}

.footer-logo {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--primary-color, #ff246e);
}

.footer-logo svg {
    width: 30px;
    height: 30px;
}

.footer-links {
    display: flex;
    gap: 2rem;
}

.footer-links a {
    color: #cccccc;
    text-decoration: none;
    transition: color 0.3s ease;
}

.footer-links a:hover {
    color: var(--primary-color, #ff246e);
}

.footer-bottom {
    text-align: center;
    padding-top: 1rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    color: #999999;
}

/* Theme-specific styles */
.theme-a {
    --primary-color: #ff246e;
    --accent-color: #ff6a00;
}

.theme-b {
    --primary-color: #8a2be2;
    --accent-color: #87f0ff;
}

.theme-c {
    --primary-color: #00ff88;
    --accent-color: #00d4ff;
}

.theme-d {
    --primary-color: #ff0080;
    --accent-color: #ffff00;
}

.theme-e {
    --primary-color: #ff4500;
    --accent-color: #32cd32;
}

.theme-f {
    --primary-color: #00ffff;
    --accent-color: #ff1493;
}

/* RTL Support */
[dir="rtl"] .hero-stats {
    flex-direction: row-reverse;
}

[dir="rtl"] .features-grid {
    direction: rtl;
}

[dir="rtl"] .footer-content {
    flex-direction: row-reverse;
}

/* Responsive Design */
@media (max-width: 768px) {
    .container {
        padding: 0 1rem;
    }
    
    .hero-stats {
        flex-direction: column;
        gap: 2rem;
    }
    
    .performance-grid {
        grid-template-columns: 1fr;
    }
    
    .features-grid {
        grid-template-columns: 1fr;
    }
    
    .footer-content {
        flex-direction: column;
        gap: 2rem;
        text-align: center;
    }
    
    .footer-links {
        flex-direction: column;
        gap: 1rem;
    }
    
    .sticky-cta {
        bottom: 1rem;
        right: 1rem;
    }
    
    .cta-button {
        padding: 0.8rem 1.5rem;
        font-size: 0.9rem;
    }
    
    .features-section {
        padding: 3rem 0;
    }
    
    .performance-section {
        padding: 3rem 0;
    }
}

@media (max-width: 480px) {
    .hero-title {
        font-size: 2rem;
    }
    
    .hero-subtitle {
        font-size: 1rem;
    }
    
    .hero-cta {
        padding: 1rem 2rem;
        font-size: 1rem;
    }
    
    .performance-card,
    .feature-card {
        padding: 1.5rem;
    }
    
    .section-title {
        font-size: 1.8rem;
    }
}

/* Accessibility */
@media (prefers-reduced-motion: reduce) {
    * {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}

/* High contrast mode */
@media (prefers-contrast: high) {
    .hero-title {
        color: #ffffff;
        -webkit-text-fill-color: #ffffff;
    }
    
    .cta-button {
        border: 2px solid #ffffff;
    }
}