/* ===== CSS Custom Properties ===== */

:root {
    --bg-primary: #f0f4ff;
    --bg-secondary: #ffffff;
    --bg-card: rgba(255, 255, 255, 0.8);
    --bg-cta: linear-gradient(135deg, #eff6ff, #f5f3ff);
    --text-primary: #111827;
    --text-secondary: #4b5563;
    --text-muted: #9ca3af;
    --border-color: rgba(59, 130, 246, 0.2);
    --border-cta: #bfdbfe;
    --icon-bg-opacity: 1;
    --toggle-bg: #ffffff;
    --toggle-border: #d1d5db;
    --toggle-color: #4b5563;
    --shadow-card: 0 4px 24px rgba(0, 0, 0, 0.06);
    --shadow-card-hover: 0 12px 40px rgba(0, 0, 0, 0.1);
    --gradient-bg: linear-gradient(135deg, #eff6ff 0%, #ffffff 50%, #f5f3ff 100%);
}

html.dark {
    --bg-primary: #111827;
    --bg-secondary: #1f2937;
    --bg-card: rgba(31, 41, 55, 0.6);
    --bg-cta: linear-gradient(135deg, rgba(30, 58, 138, 0.2), rgba(88, 28, 135, 0.2));
    --text-primary: #f9fafb;
    --text-secondary: #d1d5db;
    --text-muted: #6b7280;
    --border-color: rgba(59, 130, 246, 0.15);
    --border-cta: rgba(59, 130, 246, 0.2);
    --icon-bg-opacity: 0.9;
    --toggle-bg: #1f2937;
    --toggle-border: #4b5563;
    --toggle-color: #facc15;
    --shadow-card: 0 4px 24px rgba(0, 0, 0, 0.2);
    --shadow-card-hover: 0 12px 40px rgba(0, 0, 0, 0.3);
    --gradient-bg: linear-gradient(135deg, #111827 0%, #1a1a2e 50%, #111827 100%);
}

@media (prefers-color-scheme: dark) {
    html:not(.light) {
        --bg-primary: #111827;
        --bg-secondary: #1f2937;
        --bg-card: rgba(31, 41, 55, 0.6);
        --bg-cta: linear-gradient(135deg, rgba(30, 58, 138, 0.2), rgba(88, 28, 135, 0.2));
        --text-primary: #f9fafb;
        --text-secondary: #d1d5db;
        --text-muted: #6b7280;
        --border-color: rgba(59, 130, 246, 0.15);
        --border-cta: rgba(59, 130, 246, 0.2);
        --icon-bg-opacity: 0.9;
        --toggle-bg: #1f2937;
        --toggle-border: #4b5563;
        --toggle-color: #facc15;
        --shadow-card: 0 4px 24px rgba(0, 0, 0, 0.2);
        --shadow-card-hover: 0 12px 40px rgba(0, 0, 0, 0.3);
        --gradient-bg: linear-gradient(135deg, #111827 0%, #1a1a2e 50%, #111827 100%);
    }
}


/* ===== Reset & Base ===== */

*,
*::before,
*::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    color: var(--text-primary);
    background: var(--gradient-bg);
    min-height: 100vh;
    transition: background 0.3s ease, color 0.3s ease;
    line-height: 1.6;
}


/* ===== Dark Mode Toggle ===== */

.theme-toggle {
    position: fixed;
    top: 1.5rem;
    right: 1.5rem;
    z-index: 50;
    background: var(--toggle-bg);
    border: 1px solid var(--toggle-border);
    color: var(--toggle-color);
    width: 2.75rem;
    height: 2.75rem;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
}

.theme-toggle:hover {
    transform: scale(1.1);
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.15);
}

.theme-toggle svg {
    width: 1.25rem;
    height: 1.25rem;
}

.theme-toggle .icon-sun {
    display: none;
}

html.dark .theme-toggle .icon-moon {
    display: none;
}

html.dark .theme-toggle .icon-sun {
    display: block;
}


/* ===== Container ===== */

.container {
    max-width: 1120px;
    margin: 0 auto;
    padding: 0 1.5rem;
}


/* ===== Sections ===== */

section {
    padding: 4rem 0;
}


/* ===== Hero Section ===== */

.hero {
    text-align: center;
    padding-top: 6rem;
    padding-bottom: 4rem;
    animation: fade-in 0.8s ease-out;
}

.hero-badge {
    display: inline-block;
    padding: 0.375rem 1rem;
    border-radius: 9999px;
    font-size: 0.875rem;
    font-weight: 500;
    background: linear-gradient(135deg, rgba(37, 99, 235, 0.1), rgba(147, 51, 234, 0.1));
    color: #2563eb;
    border: 1px solid rgba(37, 99, 235, 0.2);
    margin-bottom: 2rem;
}

html.dark .hero-badge {
    color: #93c5fd;
    background: linear-gradient(135deg, rgba(37, 99, 235, 0.15), rgba(147, 51, 234, 0.15));
    border-color: rgba(59, 130, 246, 0.3);
}

.hero-title-wrapper {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    margin-bottom: 1.5rem;
}

.hero-title {
    font-size: clamp(2.5rem, 6vw, 4.5rem);
    font-weight: 800;
    background: linear-gradient(135deg, #2563eb, #9333ea);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    line-height: 1.1;
}

.sparkle-icon {
    width: 2rem;
    height: 2rem;
    flex-shrink: 0;
    animation: pulse 2s ease-in-out infinite;
}

.sparkle-blue {
    color: #2563eb;
}

html.dark .sparkle-blue {
    color: #60a5fa;
}

.sparkle-purple {
    color: #9333ea;
}

html.dark .sparkle-purple {
    color: #c084fc;
}

.hero-subtitle {
    font-size: clamp(1.125rem, 2.5vw, 1.5rem);
    color: var(--text-secondary);
    max-width: 48rem;
    margin: 0 auto 2.5rem;
}

.hero-buttons {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: 1rem;
}


/* ===== Buttons ===== */

.btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.875rem 2rem;
    border-radius: 0.5rem;
    font-size: 1.125rem;
    font-weight: 500;
    text-decoration: none;
    cursor: pointer;
    border: none;
    transition: all 0.2s ease;
}

.btn-primary {
    background: linear-gradient(135deg, #2563eb, #9333ea);
    color: #ffffff;
    box-shadow: 0 4px 16px rgba(37, 99, 235, 0.3);
}

.btn-primary:hover {
    transform: translateY(-2px) scale(1.02);
    box-shadow: 0 8px 24px rgba(37, 99, 235, 0.4);
}

.btn-secondary {
    background: transparent;
    color: var(--text-secondary);
    border: 1px solid var(--toggle-border);
}

.btn-secondary:hover {
    background: var(--bg-card);
    transform: translateY(-1px);
}

.btn svg {
    width: 1.25rem;
    height: 1.25rem;
}


/* ===== Features Section ===== */

.features {
    animation: fade-in 0.8s ease-out 0.2s both;
}

.section-header {
    text-align: center;
    margin-bottom: 3rem;
}

.section-title {
    font-size: clamp(1.75rem, 4vw, 2.5rem);
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 1rem;
}

.section-subtitle {
    font-size: 1.125rem;
    color: var(--text-secondary);
    max-width: 40rem;
    margin: 0 auto;
}

.features-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1.5rem;
    max-width: 64rem;
    margin: 0 auto;
}

@media (min-width: 768px) {
    .features-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

.feature-card {
    background: var(--bg-card);
    backdrop-filter: blur(8px);
    border: 1px solid var(--border-color);
    border-radius: 1rem;
    padding: 2rem;
    box-shadow: var(--shadow-card);
    transition: all 0.3s ease;
}

.feature-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-card-hover);
}

.feature-icon {
    width: 3rem;
    height: 3rem;
    border-radius: 0.75rem;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1.25rem;
}

.feature-icon svg {
    width: 1.5rem;
    height: 1.5rem;
    color: #ffffff;
}

.icon-blue {
    background: linear-gradient(135deg, #3b82f6, #06b6d4);
}

.icon-purple {
    background: linear-gradient(135deg, #a855f7, #ec4899);
}

.icon-orange {
    background: linear-gradient(135deg, #f97316, #ef4444);
}

.icon-green {
    background: linear-gradient(135deg, #22c55e, #14b8a6);
}

.feature-title {
    font-size: 1.25rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 0.75rem;
}

.feature-description {
    font-size: 1rem;
    color: var(--text-secondary);
    line-height: 1.7;
}


/* ===== News Section ===== */

.news {
    animation: fade-in 0.8s ease-out 0.3s both;
}

.news-list {
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
    max-width: 48rem;
    margin: 0 auto;
}

.news-item {
    background: var(--bg-card);
    backdrop-filter: blur(8px);
    border: 1px solid var(--border-color);
    border-radius: 1rem;
    padding: 1.5rem 2rem;
    box-shadow: var(--shadow-card);
    transition: all 0.3s ease;
}

.news-item:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-card-hover);
}

.news-item-header {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 0.5rem;
    flex-wrap: wrap;
}

.news-date {
    font-size: 0.8125rem;
    color: var(--text-muted);
    font-weight: 500;
}

.news-tag {
    display: inline-block;
    padding: 0.2rem 0.625rem;
    border-radius: 9999px;
    font-size: 0.75rem;
    font-weight: 600;
    background: linear-gradient(135deg, rgba(37, 99, 235, 0.1), rgba(147, 51, 234, 0.1));
    color: #2563eb;
    border: 1px solid rgba(37, 99, 235, 0.2);
}

html.dark .news-tag {
    color: #93c5fd;
    background: linear-gradient(135deg, rgba(37, 99, 235, 0.15), rgba(147, 51, 234, 0.15));
    border-color: rgba(59, 130, 246, 0.3);
}

.news-title {
    font-size: 1.125rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 0.375rem;
}

.news-description {
    font-size: 0.9375rem;
    color: var(--text-secondary);
    line-height: 1.6;
}


/* ===== CTA Section ===== */

.cta {
    animation: fade-in 0.8s ease-out 0.4s both;
}

.cta-divider {
    width: 6rem;
    height: 1px;
    background: var(--border-color);
    margin: 0 auto 3rem;
    border: none;
}

.cta-card {
    max-width: 48rem;
    margin: 0 auto;
    text-align: center;
    padding: 3.5rem 2.5rem;
    border-radius: 1.5rem;
    background: var(--bg-cta);
    border: 1px solid var(--border-cta);
}

.cta-title {
    font-size: clamp(1.5rem, 3.5vw, 2.25rem);
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 1rem;
}

.cta-subtitle {
    font-size: 1.125rem;
    color: var(--text-secondary);
    margin-bottom: 2rem;
}


/* ===== Footer ===== */

.footer {
    text-align: center;
    padding: 2rem 0 3rem;
}

.footer-text {
    font-size: 0.875rem;
    color: var(--text-muted);
}


/* ===== Animations ===== */

@keyframes fade-in {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

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