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

:root {
    /* Ringen color scheme */
    --bg-dark: #0b0f14;
    --bg-dark-secondary: #17202b;
    --bg-card: rgba(17, 24, 32, 0.8);
    --text-primary: #e6edf3;
    --text-secondary: #9aa7b3;
    --accent-cyan: #38bdf8;
    --puzzle-amber: #fbbf24;
    --puzzle-cyan: #38bdf8;
    --puzzle-purple: #7c3aed;
    --border-color: #1f2a38;
    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.3);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.4);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.5);
    --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.6);
    --glow: 0 0 20px currentColor;
    --border-radius: 12px;
    --transition: all 0.3s ease;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    line-height: 1.6;
    color: var(--text-primary);
    background: radial-gradient(circle at 50% 0%, var(--bg-dark-secondary), var(--bg-dark));
    min-height: 100vh;
}

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

/* Navbar */
.navbar {
    background-color: rgba(11, 15, 20, 0.9);
    box-shadow: var(--shadow-md);
    position: sticky;
    top: 0;
    z-index: 1000;
    backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--border-color);
}

.navbar .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 20px;
}

.logo {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text-primary);
}

.nav-links {
    display: flex;
    gap: 2rem;
    align-items: center;
}

.nav-links a {
    color: var(--text-secondary);
    text-decoration: none;
    font-weight: 500;
    transition: var(--transition);
}

.nav-links a:hover {
    color: var(--accent-cyan);
}

.nav-links .try-now-link {
    background: var(--accent-cyan);
    color: var(--bg-dark);
    padding: 0.5rem 1.5rem;
    border-radius: 50px;
    transition: var(--transition);
    font-weight: 600;
}

.nav-links .try-now-link:hover {
    transform: translateY(-2px);
    box-shadow: 0 0 20px rgba(56, 189, 248, 0.5);
}

/* Hero Section */
.hero {
    padding: 6rem 0;
    position: relative;
    overflow: hidden;
}

.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: radial-gradient(circle at 20% 50%, rgba(56, 189, 248, 0.05) 0%, transparent 50%),
                radial-gradient(circle at 80% 80%, rgba(124, 58, 237, 0.05) 0%, transparent 50%);
    z-index: 0;
}

.hero .container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
    position: relative;
    z-index: 1;
}

.hero-content h1 {
    font-size: 4rem;
    font-weight: 800;
    line-height: 1.1;
    margin-bottom: 1.5rem;
    color: var(--text-primary);
}

.tagline {
    font-size: 1.5rem;
    color: var(--text-secondary);
    margin-bottom: 1.5rem;
    font-weight: 500;
}

.description {
    font-size: 1.125rem;
    color: var(--text-secondary);
    margin-bottom: 2.5rem;
    line-height: 1.8;
}

.cta-buttons {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
}

.btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 1rem 2rem;
    border-radius: 50px;
    font-weight: 600;
    text-decoration: none;
    transition: var(--transition);
    font-size: 1rem;
    border: none;
    cursor: pointer;
}

.btn-primary {
    background: var(--accent-cyan);
    color: var(--bg-dark);
    box-shadow: var(--shadow-md);
}

.btn-primary:hover {
    transform: translateY(-3px);
    box-shadow: 0 0 30px rgba(56, 189, 248, 0.6);
}

.btn-secondary {
    background: transparent;
    color: var(--text-primary);
    border: 2px solid var(--accent-cyan);
    box-shadow: var(--shadow-sm);
}

.btn-secondary:hover {
    background: var(--accent-cyan);
    color: var(--bg-dark);
    transform: translateY(-3px);
    box-shadow: 0 0 30px rgba(56, 189, 248, 0.4);
}

.btn-large {
    padding: 1.25rem 2.5rem;
    font-size: 1.125rem;
}

/* Hero Visual */
.hero-visual {
    display: flex;
    justify-content: center;
    align-items: center;
}

.puzzle-preview {
    position: relative;
    width: 400px;
    height: 400px;
    display: flex;
    justify-content: center;
    align-items: center;
}

.grid-demo {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
    padding: 40px;
    background: rgba(15, 21, 32, 0.6);
    border-radius: var(--border-radius);
    box-shadow: var(--shadow-xl);
    border: 1px solid var(--border-color);
}

.grid-cell {
    width: 80px;
    height: 80px;
    border-radius: 8px;
    animation: pulse 3s ease-in-out infinite;
    box-shadow: 0 0 20px currentColor;
}

/* 3x3 grid with amber, cyan, purple pattern */
.grid-cell:nth-child(1) { background: var(--puzzle-amber); animation-delay: 0s; }
.grid-cell:nth-child(2) { background: var(--puzzle-cyan); animation-delay: 0.3s; }
.grid-cell:nth-child(3) { background: var(--puzzle-purple); animation-delay: 0.6s; }
.grid-cell:nth-child(4) { background: var(--puzzle-cyan); animation-delay: 0.9s; }
.grid-cell:nth-child(5) { background: var(--puzzle-purple); animation-delay: 1.2s; }
.grid-cell:nth-child(6) { background: var(--puzzle-amber); animation-delay: 1.5s; }
.grid-cell:nth-child(7) { background: var(--puzzle-purple); animation-delay: 1.8s; }
.grid-cell:nth-child(8) { background: var(--puzzle-amber); animation-delay: 2.1s; }
.grid-cell:nth-child(9) { background: var(--puzzle-cyan); animation-delay: 2.4s; }

@keyframes pulse {
    0%, 100% {
        opacity: 1;
        transform: scale(1);
    }
    50% {
        opacity: 0.6;
        transform: scale(0.95);
    }
}

.ring-overlay {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 200px;
    height: 200px;
    border: 2px dashed var(--accent-cyan);
    border-radius: 8px;
    animation: rotate 8s linear infinite;
    opacity: 0.4;
    box-shadow: 0 0 15px rgba(56, 189, 248, 0.3);
}

@keyframes rotate {
    from { transform: translate(-50%, -50%) rotate(0deg); }
    to { transform: translate(-50%, -50%) rotate(360deg); }
}

/* Features Section */
.features {
    padding: 6rem 0;
}

.features h2 {
    text-align: center;
    font-size: 3rem;
    font-weight: 800;
    margin-bottom: 4rem;
    color: var(--text-primary);
}

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

.feature-card {
    padding: 2rem;
    background: var(--bg-card);
    border-radius: var(--border-radius);
    box-shadow: var(--shadow-md);
    transition: var(--transition);
    border: 1px solid var(--border-color);
}

.feature-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-xl);
    border-color: var(--accent-cyan);
    background: rgba(17, 24, 32, 0.95);
}

.feature-icon {
    font-size: 3rem;
    margin-bottom: 1rem;
}

.feature-card h3 {
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: 1rem;
    color: var(--text-primary);
}

.feature-card p {
    color: var(--text-secondary);
    line-height: 1.8;
}

/* Download Section */
.download {
    padding: 6rem 0;
    background: rgba(17, 24, 32, 0.4);
}

.download-content {
    text-align: center;
}

.download-content h2 {
    font-size: 3rem;
    font-weight: 800;
    margin-bottom: 1.5rem;
    color: var(--text-primary);
}

.download-content > p {
    font-size: 1.25rem;
    color: var(--text-secondary);
    margin-bottom: 3rem;
    max-width: 700px;
    margin-left: auto;
    margin-right: auto;
}

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

.download-option {
    background: var(--bg-card);
    padding: 3rem 2rem;
    border-radius: var(--border-radius);
    box-shadow: var(--shadow-lg);
    transition: var(--transition);
    border: 1px solid var(--border-color);
}

.download-option:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-xl);
    border-color: var(--accent-cyan);
}

.download-option h3 {
    font-size: 1.75rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
    color: var(--text-primary);
}

.download-option > p {
    color: var(--text-secondary);
    margin-bottom: 2rem;
}

.platform-note {
    margin-top: 1rem;
    font-size: 0.875rem;
    color: var(--text-secondary);
}

/* Footer */
.footer {
    background: rgba(11, 15, 20, 0.95);
    color: var(--text-primary);
    padding: 4rem 0 2rem;
    border-top: 1px solid var(--border-color);
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 3rem;
    margin-bottom: 3rem;
}

.footer-section h4 {
    font-size: 1.25rem;
    font-weight: 700;
    margin-bottom: 1rem;
    color: var(--text-primary);
}

.footer-section p {
    color: var(--text-secondary);
    line-height: 1.8;
}

.footer-section ul {
    list-style: none;
}

.footer-section ul li {
    margin-bottom: 0.5rem;
}

.footer-section a {
    color: var(--text-secondary);
    text-decoration: none;
    transition: var(--transition);
}

.footer-section a:hover {
    color: var(--accent-cyan);
}

.footer-bottom {
    text-align: center;
    padding-top: 2rem;
    border-top: 1px solid var(--border-color);
    color: var(--text-secondary);
}

/* Responsive Design */
@media (max-width: 768px) {
    .hero .container {
        grid-template-columns: 1fr;
        gap: 3rem;
    }

    .hero-content h1 {
        font-size: 2.5rem;
    }

    .tagline {
        font-size: 1.25rem;
    }

    .description {
        font-size: 1rem;
    }

    .puzzle-preview {
        width: 100%;
        height: 350px;
    }

    .grid-demo {
        padding: 20px;
    }

    .grid-cell {
        width: 60px;
        height: 60px;
    }

    .features h2,
    .download-content h2 {
        font-size: 2rem;
    }

    .features-grid {
        grid-template-columns: 1fr;
    }

    .nav-links {
        gap: 1rem;
    }

    .nav-links a {
        font-size: 0.9rem;
    }

    .cta-buttons {
        flex-direction: column;
    }

    .btn {
        width: 100%;
        justify-content: center;
    }
}

@media (max-width: 480px) {
    .hero {
        padding: 3rem 0;
    }

    .hero-content h1 {
        font-size: 2rem;
    }

    .features,
    .download {
        padding: 3rem 0;
    }

    .grid-cell {
        width: 50px;
        height: 50px;
    }
}
