@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800&display=swap');

:root {
    --primary: #0284C7;
    --primary-glow: rgba(2, 132, 199, 0.5);
    --accent: #FF6A00;
    --accent-glow: rgba(255, 106, 0, 0.5);

    /* Base Tokens - Default: Dark (Elite Dark) */
    --bg-main: #020617;
    --bg-card: #0F172A;
    --bg-alt: #1E293B;
    --text-main: #F8FAFC;
    --text-muted: #94A3B8;
    --glass: rgba(15, 23, 42, 0.7);
    --glass-border: rgba(255, 255, 255, 0.08);
    --border: rgba(255, 255, 255, 0.05);

    --neon-blue: 0 0 20px rgba(2, 132, 199, 0.3);
    --neon-purple: 0 0 20px rgba(139, 92, 246, 0.3);
    --shadow-lg: 0 20px 50px rgba(0, 0, 0, 0.5);
    --font-heading: 'Inter', sans-serif;
    --font-body: 'Inter', sans-serif;
    --font-mono: 'JetBrains Mono', monospace;
    --section-padding: 12rem 8%;
}

[data-theme="light"] {
    --bg-main: #F8FAFC;
    --bg-card: #FFFFFF;
    --bg-alt: #F1F5F9;
    --text-main: #0F172A;
    --text-muted: #64748B;
    --glass: rgba(255, 255, 255, 0.7);
    --glass-border: rgba(0, 0, 0, 0.08);
    --border: rgba(0, 0, 0, 0.05);
    --shadow-lg: 0 20px 50px rgba(0, 0, 0, 0.1);
    --mesh-opacity: 0.15;
}

[data-theme="dark"] {
    --bg-main: #020617;
    --bg-card: #0F172A;
    --bg-alt: #1E293B;
    --text-main: #F8FAFC;
    --text-muted: #94A3B8;
    --glass: rgba(15, 23, 42, 0.8);
    --glass-border: rgba(255, 255, 255, 0.1);
    --mesh-opacity: 0.25;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    background-color: var(--bg-main);
    color: var(--text-main);
    font-family: var(--font-body);
    line-height: 1.6;
    overflow-x: hidden;
    transition: background-color 0.5s cubic-bezier(0.4, 0, 0.2, 1), color 0.5s cubic-bezier(0.4, 0, 0.2, 1);
    font-weight: 400;
    -webkit-font-smoothing: antialiased;
}

::selection {
    background: var(--primary);
    color: white;
}

/* Custom Scrollbar */
::-webkit-scrollbar {
    width: 6px;
}

::-webkit-scrollbar-track {
    background: var(--bg-main);
}

::-webkit-scrollbar-thumb {
    background: var(--bg-alt);
    border-radius: 10px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--primary);
}

/* Scroll Progress Bar */
#scroll-progress {
    position: fixed;
    top: 0;
    left: 0;
    width: 0%;
    height: 4px;
    background: linear-gradient(to right, var(--primary), var(--accent));
    z-index: 10001;
    box-shadow: 0 0 10px var(--primary);
    transition: width 0.1s ease-out;
}

/* Custom Tech-Crosshair */
#custom-cursor {
    position: fixed;
    top: 0;
    left: 0;
    width: 24px;
    height: 24px;
    border: 1px solid var(--primary);
    border-radius: 50%;
    /* Smooth circle cursor */
    pointer-events: none;
    z-index: 10005;
    /* transform handled by JS for maximum speed */
    transform: translate(-50%, -50%);
    will-change: transform;
    transition: width 0.3s cubic-bezier(0.19, 1, 0.22, 1),
        height 0.3s cubic-bezier(0.19, 1, 0.22, 1),
        border-color 0.3s ease,
        background 0.3s ease,
        box-shadow 0.3s ease;
    display: none;
    mix-blend-mode: normal;
    box-shadow: 0 0 10px var(--primary-glow);
    background: radial-gradient(circle, var(--primary) 2px, transparent 2px);
    /* Center dot */
}

/* Vertical Line - Minimalist Center */
#custom-cursor::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 1px;
    height: 12px;
    /* Shortened for a cleaner look within the circle */
    background: var(--primary);
    transform: translate(-50%, -50%);
    transition: all 0.3s ease;
    opacity: 0.4;
}

/* Horizontal Line - Minimalist Center */
#custom-cursor::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 12px;
    /* Shortened */
    height: 1px;
    background: var(--primary);
    transform: translate(-50%, -50%);
    transition: all 0.3s ease;
    opacity: 0.4;
}

#custom-cursor.hover {
    width: 45px;
    height: 45px;
    border-width: 2px;
    border-color: var(--accent);
    box-shadow: 0 0 25px var(--accent-glow);
    transform: translate(-50%, -50%);
    /* Removed rotation for a smoother circle feel */
    background: radial-gradient(circle, var(--accent) 4px, transparent 4px);
}

#custom-cursor.hover::before {
    height: 15px;
    background: var(--accent);
}

#custom-cursor.hover::after {
    width: 15px;
    background: var(--accent);
}

/* Animated Mesh Background */
.mesh-bg {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -2;
    opacity: 0.4;
    filter: blur(80px);
    background:
        radial-gradient(circle at 20% 30%, var(--primary) 0%, transparent 60%),
        radial-gradient(circle at 80% 70%, var(--accent) 0%, transparent 60%),
        var(--bg-main);
    animation: mesh-move 20s infinite alternate ease-in-out;
}

.mesh-bg {
    opacity: var(--mesh-opacity, 0.4);
}

@keyframes mesh-move {
    0% {
        transform: scale(1) translate(0, 0);
    }

    50% {
        transform: scale(1.1) translate(-2%, 3%);
    }

    100% {
        transform: scale(1) translate(2%, -3%);
    }
}

@media (max-width: 768px) {
    body {
        cursor: auto;
    }

    /* Restore cursor on touch devices */
    #custom-cursor {
        display: none !important;
    }
}

h1,
h2,
h3,
.font-heading {
    font-family: var(--font-heading);
    font-weight: 800;
    letter-spacing: -0.02em;
}

a {
    text-decoration: none;
    color: inherit;
    transition: all 0.2s ease;
}

/* Glassmorphism Utility */
.glass {
    background: var(--glass);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid var(--glass-border);
}

/* Navbar & Logo */
.logo {
    cursor: pointer;
    transition: transform 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow: hidden;
    padding: 5px 10px;
    margin-right: 15px;
    gap: 0.4rem;
}

.logo:hover {
    transform: scale(1.05);
}

.logo-text-container {
    display: flex;
    flex-direction: column;
    justify-content: center;
    line-height: 1.1;
    z-index: 2;
    position: relative;
}

.logo-kafe {
    font-size: 1.6rem;
    font-weight: 900;
    background: linear-gradient(to bottom, #FF5100, #C81D77);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    letter-spacing: 1px;
}

.logo-infotech {
    font-size: 0.85rem;
    font-weight: 800;
    background: linear-gradient(to right, #610094, #2124A6);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    letter-spacing: 1.5px;
}

/* Tools Page Specifics */
.tools-library {
    padding: 0 0 80px;
}

/* Base state for custom icon */
.custom-console-icon {
    transition: transform 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
    transform-origin: center;
    animation: gamepad-auto-pop 7s infinite ease-in-out;
}

.custom-console-icon circle {
    transition: filter 0.3s ease;
    animation: gamepad-buttons-glow 7s infinite ease-in-out;
}

@keyframes gamepad-auto-pop {

    0%,
    71.4% {
        transform: scale(1.1) rotate(-3deg);
    }

    /* Active 5s */
    80%,
    100% {
        transform: scale(1) rotate(0deg);
    }

    /* Break 2s */
}

@keyframes gamepad-buttons-glow {

    0%,
    71.4% {
        filter: brightness(1.3) drop-shadow(0 0 5px rgba(255, 255, 255, 0.5));
    }

    80%,
    100% {
        filter: brightness(1) drop-shadow(0 0 0px transparent);
    }
}

.lightning-bolt {
    transition: transform 0.3s ease;
    transform-origin: center;
    animation: bolt-auto-pulse 7s infinite ease-in-out;
}

@keyframes bolt-auto-pulse {

    0%,
    20%,
    40%,
    60% {
        transform: scale(1) translateY(0);
        filter: drop-shadow(2px 2px 2px rgba(0, 0, 0, 0.3));
    }

    10%,
    30%,
    50%,
    71.4% {
        transform: scale(1.2) translateY(-5px);
        filter: drop-shadow(0 0 10px #FFEB3B);
    }

    80%,
    100% {
        transform: scale(1) translateY(0);
        filter: drop-shadow(2px 2px 2px rgba(0, 0, 0, 0.3));
    }
}

.logo-text-container {
    transition: transform 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
    animation: text-auto-shift 7s infinite ease-in-out;
}

@keyframes text-auto-shift {

    0%,
    71.4% {
        transform: translateX(8px) scale(1.05);
    }

    80%,
    100% {
        transform: translateX(0) scale(1);
    }
}


.tyre-track {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    overflow: hidden;
    z-index: 1;
    border-radius: 4px;
}

.moving-tyre-container {
    position: absolute;
    top: 50%;
    left: -60px;
    transform: translateY(-50%);
    display: flex;
    align-items: center;
    opacity: 0;
    transition: opacity 0.3s;
    animation: drive-across-loop 7s linear infinite;
}

@keyframes drive-across-loop {
    0% {
        left: -60px;
        opacity: 1;
    }

    60% {
        left: 110%;
        opacity: 1;
    }

    60.1% {
        left: 110%;
        opacity: 0;
    }

    71.4% {
        left: -60px;
        opacity: 0;
    }

    100% {
        left: -60px;
        opacity: 0;
    }
}

.tyre-icon {
    width: 24px;
    height: 24px;
    filter: drop-shadow(0 0 5px var(--accent));
    animation: tyre-spin-fast 0.5s linear infinite;
}

@keyframes tyre-spin-fast {
    from {
        transform: rotate(0deg);
    }

    to {
        transform: rotate(360deg);
    }
}

/* Smoke Particles */
.smoke {
    position: absolute;
    width: 8px;
    height: 8px;
    background: rgba(255, 255, 255, 0.6);
    border-radius: 50%;
    filter: blur(2px);
    opacity: 0;
    z-index: -1;
}

.smoke-1 {
    left: -10px;
    top: 10px;
    animation: puff-smoke-loop 7s ease-out infinite;
}

.smoke-2 {
    left: -15px;
    top: 5px;
    animation: puff-smoke-loop 7s ease-out infinite 0.2s;
}

.smoke-3 {
    left: -5px;
    top: 15px;
    width: 6px;
    height: 6px;
    animation: puff-smoke-loop 7s ease-out infinite 0.4s;
}

@keyframes puff-smoke-loop {
    0% {
        transform: translate(0, 0) scale(1);
        opacity: 0;
    }

    5% {
        opacity: 0.8;
    }

    60% {
        transform: translate(-30px, -20px) scale(3);
        opacity: 0;
    }

    100% {
        opacity: 0;
    }
}

.moving-logo-text span {
    display: inline-block;
    animation: wave-text 2s infinite ease-in-out;
    animation-delay: calc(0.1s * var(--i));
    text-shadow: 0 0 10px var(--primary-glow);
}

@keyframes wave-text {

    0%,
    100% {
        transform: translateY(0) scale(1);
        color: var(--primary);
        filter: hue-rotate(0deg);
        text-shadow: 0 0 5px var(--primary-glow);
    }

    50% {
        transform: translateY(-8px) scale(1.1);
        color: var(--accent);
        filter: hue-rotate(45deg);
        text-shadow: 0 10px 20px var(--accent-glow);
    }
}

nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.8rem 5%;
    position: fixed;
    top: 0;
    width: 100%;
    z-index: 10000;
    transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
    background: transparent;
    backdrop-filter: blur(0px);
    border-bottom: 1px solid transparent;
    animation: nav-reveal 1s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

@keyframes nav-reveal {
    from {
        transform: translateY(-100%);
        opacity: 0;
    }

    to {
        transform: translateY(0);
        opacity: 1;
    }
}

nav.scrolled {
    padding: 0.8rem 5%;
    background: var(--glass);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--glass-border);
    box-shadow: var(--shadow-lg);
}

.nav-links {
    display: flex;
    gap: 1.5rem;
}

/* Reveal Animations */
.reveal-standard {
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}

.reveal-active,
.reveal-standard.active {
    opacity: 1;
    transform: translateY(0);
}

.mobile-menu-btn {
    display: none;
    font-size: 1.5rem;
    cursor: pointer;
    color: var(--text-main);
    z-index: 10001;
    /* Above the sliding nav menu */
    transition: transform 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.nav-links a {
    font-weight: 600;
    font-size: 0.9rem;
    color: var(--text-main);
    letter-spacing: 0.5px;
    position: relative;
}

.nav-links a:hover {
    color: var(--primary);
    text-shadow: 0 0 10px var(--primary-glow);
}

.nav-links a::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--primary);
    transition: width 0.3s ease;
}

.nav-links a:hover::after {
    width: 100%;
}

/* Button Styles */
.btn {
    display: inline-block;
    padding: 1rem 2.5rem;
    border-radius: 2rem;
    cursor: pointer;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.3s ease;
    border: none;
}

.btn:active {
    transform: scale(0.98);
}

.btn-primary {
    background: var(--primary);
    color: white;
}

.btn-primary:hover {
    background: var(--accent);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(59, 130, 246, 0.3);
}

.btn-outline {
    background: transparent;
    border: 2px solid var(--primary);
    color: var(--primary);
}

/* Theme Toggle */
#theme-toggle {
    background: var(--glass);
    border: 1px solid var(--glass-border);
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    font-size: 1.2rem;
    color: var(--text-main);
    transition: all 0.3s ease;
}

#theme-toggle {
    background: var(--bg-card);
    border: 1px solid var(--border);
    color: var(--text-main);
    width: 45px;
    height: 45px;
    border-radius: 12px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

#theme-toggle:hover {
    transform: rotate(15deg) scale(1.1);
    box-shadow: 0 0 20px var(--primary-glow);
    border-color: var(--primary);
}

/* Stats Section */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 2rem;
    padding: 3rem 6%;
    background: var(--card-bg);
    border-top: 1px solid var(--border);
    border-bottom: 1px solid var(--border);
}

.stat-item {
    text-align: center;
    padding: 1.5rem;
}

.stat-number {
    font-size: 3rem;
    font-weight: 900;
    /* Changed from 800 */
    color: var(--primary);
    font-family: 'Outfit', sans-serif;
    margin-bottom: 0.5rem;
}

.stat-label {
    font-size: 1rem;
    color: var(--text-muted);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
}

/* Hero Section */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 4rem;
    position: relative;
    overflow: hidden;
    padding: 8rem 8% 4rem;
    background: radial-gradient(circle at top left, rgba(59, 130, 246, 0.05) 0%, var(--bg-main) 100%);
}

.hero-content {
    position: relative;
    z-index: 10;
    flex: 1.2;
    text-align: left;
}

.hero-image {
    flex: 1;
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 5;
}

.hero-content h1 {
    font-size: clamp(3rem, 8vw, 6rem);
    font-weight: 800;
    line-height: 1;
    margin-bottom: 2rem;
    background: linear-gradient(to bottom, #FFFFFF 30%, rgba(255, 255, 255, 0.7) 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    letter-spacing: -0.04em;
}

.hero-content p {
    font-size: 1.2rem;
    color: var(--text-muted);
    margin: 0 0 3rem;
    max-width: 550px;
    line-height: 1.8;
}

#canvas-container {
    cursor: grab;
    /* Removed background to eliminate the box effect completely */
}

#canvas-container:active {
    cursor: grabbing;
}

/* Cards & Grids */
.section-padding {
    padding: 5rem 6%;
}

.section-title {
    text-align: center;
    margin-bottom: 3.5rem;
}

.section-title h2 {
    font-size: 2.5rem;
    margin-bottom: 1rem;
}

.section-title p {
    color: var(--text-muted);
}

.grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
}

.card {
    background: var(--bg-card);
    padding: 3rem;
    border-radius: 20px;
    border: 1px solid var(--border);
    transition: all 0.5s cubic-bezier(0.16, 1, 0.3, 1);
    position: relative;
    overflow: hidden;
    backdrop-filter: blur(10px);
}

.card:hover {
    transform: translateY(-10px);
    border-color: var(--primary);
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.4), 0 0 20px var(--primary-glow);
}

.card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(45deg, transparent, rgba(255, 255, 255, 0.03), transparent);
    transform: translateX(-100%);
    transition: transform 0.6s ease;
}

.card:hover::before {
    transform: translateX(100%);
}

.card-accent:hover {
    border-color: var(--accent);
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.4), 0 0 20px var(--accent-glow);
}

.reveal-standard {
    opacity: 0;
    transform: translateY(30px);
    transition: all 1s cubic-bezier(0.16, 1, 0.3, 1);
}

.reveal-active {
    opacity: 1 !important;
    transform: translateY(0) !important;
}

/* Micro-interactions */
.magnetic {
    transition: transform 0.3s cubic-bezier(0.23, 1, 0.32, 1);
}

.magnetic:hover {
    transform: scale(1.05);
}

/* Typing Cursor */
.cursor {
    display: inline-block;
    width: 3px;
    height: 1.2em;
    background: var(--primary);
    margin-left: 2px;
    animation: blink 1s infinite;
    vertical-align: middle;
}

@keyframes blink {

    0%,
    100% {
        opacity: 1;
    }

    50% {
        opacity: 0;
    }
}

/* Learning Roadmap */
.roadmap-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 4rem 2rem;
    position: relative;
    max-width: 1000px;
    margin: 0 auto;
    overflow-x: auto;
    gap: 1.5rem;
}

.roadmap-node {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
    position: relative;
    cursor: pointer;
    min-width: 120px;
    transition: all 0.3s ease;
}

.node-icon {
    width: 70px;
    height: 70px;
    background: var(--card-bg);
    border: 2px solid var(--border);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.8rem;
    box-shadow: var(--shadow);
    transition: all 0.3s ease;
    z-index: 2;
}

.roadmap-node span {
    font-weight: 700;
    font-family: 'Outfit', sans-serif;
    color: var(--text-muted);
    transition: color 0.3s ease;
}

.roadmap-node.active .node-icon {
    border-color: var(--primary);
    box-shadow: var(--neon-blue);
    background: rgba(59, 130, 246, 0.1);
}

.roadmap-node.active span {
    color: var(--primary);
}

.roadmap-node:hover .node-icon {
    transform: scale(1.1);
    border-color: var(--accent);
    box-shadow: var(--neon-purple);
}

.roadmap-connector {
    flex-grow: 1;
    height: 3px;
    background: var(--border);
    position: relative;
    margin-top: -30px;
    /* Align with icons */
    min-width: 40px;
}

.roadmap-connector.active {
    background: linear-gradient(to right, var(--primary), var(--border));
}

.node-tooltip {
    position: absolute;
    bottom: 120%;
    left: 50%;
    transform: translateX(-50%) translateY(10px);
    background: var(--secondary);
    color: white;
    padding: 0.75rem 1rem;
    border-radius: 0.5rem;
    font-size: 0.85rem;
    white-space: nowrap;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    pointer-events: none;
    box-shadow: var(--shadow-lg);
    z-index: 10;
}

.node-tooltip::after {
    content: '';
    position: absolute;
    top: 100%;
    left: 50%;
    transform: translateX(-50%);
    border: 6px solid transparent;
    border-top-color: var(--secondary);
}

.roadmap-node:hover .node-tooltip {
    opacity: 1;
    visibility: visible;
    transform: translateX(-50%) translateY(0);
}

/* Testimonial Wall of Love */
.testimonial-track {
    display: flex;
    gap: 2rem;
    padding: 2rem 0;
    width: max-content;
    animation: scroll-track 40s linear infinite;
}

.testimonial-track:hover {
    animation-play-state: paused;
}

.testimonial-card {
    width: 350px;
    padding: 2rem;
    border-radius: 1.5rem;
    border: 1px solid var(--border);
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.testimonial-card p {
    font-style: italic;
    color: var(--text-main);
}

.user-info {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.user-info img {
    width: 45px;
    height: 45px;
    border-radius: 50%;
}

.user-info strong {
    display: block;
    color: var(--text-main);
}

.user-info span {
    font-size: 0.85rem;
    color: var(--text-muted);
}

@keyframes scroll-track {
    0% {
        transform: translateX(0);
    }

    100% {
        transform: translateX(calc(-350px * 3 - 2rem * 3));
    }
}

/* Command Palette */
#command-palette {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 20000;
    display: none;
    /* JS Toggle */
    justify-content: center;
    align-items: flex-start;
    padding-top: 15vh;
    background: var(--modal-overlay);
    backdrop-filter: blur(10px);
}

.palette-inner {
    width: 90%;
    max-width: 600px;
    background: var(--card-bg);
    border-radius: 1rem;
    box-shadow: var(--shadow-lg);
    border: 1px solid var(--border);
    overflow: hidden;
}

#palette-search {
    width: 100%;
    padding: 1.5rem;
    font-size: 1.25rem;
    background: transparent;
    border: none;
    color: var(--text-main);
    border-bottom: 1px solid var(--border);
    outline: none;
}

#palette-results {
    max-height: 300px;
    overflow-y: auto;
}

.palette-item {
    padding: 1rem 1.5rem;
    cursor: pointer;
    transition: background 0.2s;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.palette-item:hover,
.palette-item.selected {
    background: rgba(59, 130, 246, 0.1);
}

.palette-footer {
    padding: 0.75rem 1.5rem;
    background: var(--glass);
    font-size: 0.75rem;
    color: var(--text-muted);
    display: flex;
    gap: 1.5rem;
    border-top: 1px solid var(--border);
}

/* Live Activity Toasts */
#activity-toast-container {
    position: fixed;
    bottom: 2rem;
    left: 2rem;
    z-index: 15000;
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.toast {
    background: var(--card-bg);
    border: 1px solid var(--border);
    padding: 1rem 1.5rem;
    border-radius: 0.75rem;
    box-shadow: var(--shadow);
    display: flex;
    align-items: center;
    gap: 1rem;
    animation: slide-in-toast 0.4s cubic-bezier(0.17, 0.67, 0.83, 0.67) forwards;
    transform: translateX(-120%);
    max-width: 300px;
}

@keyframes slide-in-toast {
    to {
        transform: translateX(0);
    }
}

.toast.fade-out {
    animation: fade-out-toast 0.4s forwards;
}

@keyframes fade-out-toast {
    to {
        opacity: 0;
        transform: translateY(10px);
    }
}

/* Stardust Particles */
.stardust-particle {
    position: fixed;
    pointer-events: none;
    width: 3px;
    height: 3px;
    border-radius: 50%;
    z-index: 10004;
    animation: stardust-fade 0.8s ease-out forwards;
}

@keyframes stardust-fade {
    0% {
        transform: translate(0, 0) scale(1.5);
        opacity: 0.8;
    }

    100% {
        transform: translate(var(--tx), var(--ty)) scale(0);
        opacity: 0;
    }
}




/* Confetti */
.confetti {
    position: fixed;
    width: 10px;
    height: 10px;
    z-index: 30000;
    pointer-events: none;
    animation: confetti-fall 3s forwards;
}

@keyframes confetti-fall {
    0% {
        transform: translateY(-100vh) rotate(0deg);
        opacity: 1;
    }

    100% {
        transform: translateY(100vh) rotate(720deg);
        opacity: 0;
    }
}

/* Aura AI Orb */
#aura-orb {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    width: 65px;
    height: 65px;
    z-index: 10002;
    cursor: pointer;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--bg-card);
    border: 2px solid var(--primary);
    box-shadow: 0 0 30px var(--primary-glow);
    transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

#aura-orb:hover {
    transform: scale(1.1) rotate(5deg);
    border-color: var(--accent);
    box-shadow: 0 0 40px var(--accent-glow);
}

.aura-inner {
    width: 25px;
    height: 25px;
    background: linear-gradient(45deg, var(--primary), var(--accent));
    border-radius: 50%;
    filter: blur(4px);
    animation: aura-pulse 2s ease-in-out infinite;
}

.aura-tooltip {
    position: absolute;
    bottom: 130%;
    right: 0;
    background: var(--bg-card);
    padding: 1rem 1.5rem;
    border-radius: 1rem;
    border: 1px solid var(--border);
    font-size: 0.9rem;
    font-weight: 500;
    color: var(--text-main);
    white-space: nowrap;
    opacity: 0;
    visibility: hidden;
    transform: translateY(10px);
    transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
    box-shadow: var(--shadow-lg);
}

#aura-orb:hover .aura-tooltip {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

@keyframes aura-float {

    0%,
    100% {
        transform: translateY(0);
    }

    50% {
        transform: translateY(-10px);
    }
}

@keyframes aura-pulse {

    0%,
    100% {
        transform: scale(1);
        opacity: 0.5;
    }

    50% {
        transform: scale(1.5);
        opacity: 1;
    }
}

/* Dashboard Pulse */
.dashboard-card {
    padding: 2rem;
    text-align: center;
    background: var(--glass);
    border-radius: 1.5rem;
}

.dash-stat h3 {
    font-size: 2.5rem;
    color: var(--primary);
    margin-bottom: 0.5rem;
}

.dash-stat span {
    font-size: 0.85rem;
    color: var(--text-muted);
    font-weight: 600;
}

.dash-chart {
    height: 40px;
    margin-top: 1.5rem;
    background: rgba(59, 130, 246, 0.05);
    border-radius: 0.5rem;
    overflow: hidden;
    position: relative;
}

.chart-line {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 200%;
    height: 100%;
    background: linear-gradient(90deg, transparent, var(--primary), transparent);
    animation: chart-move 3s linear infinite;
    opacity: 0.3;
}

@keyframes chart-move {
    from {
        transform: translateX(-50%);
    }

    to {
        transform: translateX(0);
    }
}

/* Trophy Room */
.trophy-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
    transition: transform 0.3s ease;
    cursor: default;
}

.trophy-item:hover {
    transform: scale(1.1);
}

.trophy-icon {
    font-size: 3rem;
    width: 100px;
    height: 100px;
    background: var(--card-bg);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 2px solid var(--border);
    box-shadow: var(--shadow);
}

.trophy-icon.master {
    border-color: #ffd700;
    box-shadow: 0 0 15px rgba(255, 215, 0, 0.3);
}

.trophy-icon.explorer {
    border-color: #3b82f6;
    box-shadow: 0 0 15px rgba(59, 130, 246, 0.3);
}

.trophy-icon.creative {
    border-color: #a855f7;
    box-shadow: 0 0 15px rgba(168, 85, 247, 0.3);
}

.trophy-icon.fast {
    border-color: #f43f5e;
    box-shadow: 0 0 15px rgba(244, 63, 94, 0.3);
}

/* Smart Quiz */
.tech-label {
    font-family: var(--font-mono);
    font-size: 0.7rem;
    color: var(--primary);
    letter-spacing: 2px;
    margin-bottom: 0.5rem;
    display: block;
    opacity: 0.7;
}

.tech-spec {
    font-family: var(--font-mono);
    font-size: 0.8rem;
    color: var(--text-muted);
    border-left: 2px solid var(--primary);
    padding-left: 1rem;
    margin-top: 1rem;
}


/* Whitespace Audit - Increased Spacing */
.section-padding {
    padding: 12rem 6%;
}

/* Stability - Remove Drift & Magnetic Noise */
.card,
.pricing-card,
.dashboard-card,
.course-card {
    animation: none !important;
}

#aura-orb {
    animation: pulse 4s ease-in-out infinite;
    cursor: pointer;
}

@keyframes pulse {

    0%,
    100% {
        transform: scale(1);
        opacity: 0.8;
    }

    50% {
        transform: scale(1.05);
        opacity: 1;
    }
}

/* Responsive adjustments */
@media (max-width: 1024px) {
    .hero {
        grid-template-columns: 1fr;
        text-align: center;
        padding-top: 4rem;
    }

    .hero-content p {
        margin-left: auto;
        margin-right: auto;
    }

    .hero-content h1 {
        font-size: 3rem;
    }
}

/* Feature Highlight Section */
.feature-highlight {
    background: radial-gradient(circle at center, var(--bg-alt) 0%, var(--bg-main) 100%);
    position: relative;
    overflow: hidden;
    padding: 15rem 8%;
}

.feature-highlight::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: url('https://www.transparenttextures.com/patterns/carbon-fibre.png');
    opacity: 0.03;
    pointer-events: none;
}

.container-split {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 4rem;
    max-width: 1200px;
    margin: 0 auto;
}

.feature-text {
    flex: 1;
}

.feature-visual {
    flex: 1;
    display: flex;
    justify-content: center;
    align-items: center;
    perspective: 1000px;
}

/* Bright Circle Animation */
.bright-circle-container {
    position: relative;
    width: 350px;
    height: 350px;
    display: flex;
    justify-content: center;
    align-items: center;
}

.circle-glow {
    position: absolute;
    width: 300px;
    height: 300px;
    background: radial-gradient(circle, var(--primary) 0%, transparent 70%);
    opacity: 0.15;
    filter: blur(40px);
    animation: glow-pulse 4s ease-in-out infinite;
}

.circle-core {
    width: 120px;
    height: 120px;
    background: var(--bg-main);
    border: 4px solid var(--primary);
    border-radius: 50%;
    z-index: 5;
    box-shadow: 0 0 50px var(--primary-glow), inset 0 0 30px var(--primary-glow);
    position: relative;
}

.circle-core::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 60%;
    height: 60%;
    background: var(--primary);
    border-radius: 50%;
    opacity: 0.1;
    animation: core-breathe 2s ease-in-out infinite;
}

.circle-ring-outer {
    position: absolute;
    width: 280px;
    height: 280px;
    border: 2px dashed var(--primary);
    border-radius: 50%;
    opacity: 0.3;
    animation: rotate-cw 20s linear infinite;
}

.circle-ring-inner {
    position: absolute;
    width: 200px;
    height: 200px;
    border: 1px solid var(--accent);
    border-radius: 50%;
    opacity: 0.5;
    animation: rotate-ccw 15s linear infinite;
}

.circle-ring-inner::before {
    content: '';
    position: absolute;
    top: -5px;
    left: 50%;
    width: 10px;
    height: 10px;
    background: var(--accent);
    border-radius: 50%;
    box-shadow: 0 0 15px var(--accent);
}

.circle-particles span {
    position: absolute;
    width: 4px;
    height: 4px;
    background: var(--primary);
    border-radius: 50%;
    box-shadow: 0 0 10px var(--primary);
}

.circle-particles span:nth-child(1) {
    top: 10%;
    left: 20%;
    animation: p-float 3s infinite;
}

.circle-particles span:nth-child(2) {
    top: 80%;
    left: 15%;
    animation: p-float 4s infinite 1s;
}

.circle-particles span:nth-child(3) {
    top: 30%;
    left: 85%;
    animation: p-float 3.5s infinite 0.5s;
}

.circle-particles span:nth-child(4) {
    top: 70%;
    left: 80%;
    animation: p-float 5s infinite 2s;
}

/* Floating Programming Symbols */
.floating-symbols {
    position: absolute;
    width: 100%;
    height: 100%;
    top: 0;
    left: 0;
    pointer-events: none;
    z-index: 10;
}

.symbol {
    position: absolute;
    display: flex;
    justify-content: center;
    align-items: center;
    width: 40px;
    height: 40px;
    opacity: 0;
    transform: scale(0.5);
    /* Pop-up animation: total 10s loop */
    animation: symbol-pop 10s infinite ease-in-out;
    filter: drop-shadow(0 0 10px var(--primary-glow));
}

.symbol .logo-img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

/* Staggered Timings and Positions */
.symbol-1 {
    top: 15%;
    left: 25%;
    animation-delay: 0s;
}

.symbol-2 {
    top: 70%;
    left: 15%;
    width: 60px;
    height: 60px;
    animation-delay: 2s;
}

.symbol-3 {
    top: 20%;
    left: 75%;
    width: 45px;
    height: 45px;
    animation-delay: 4s;
}

.symbol-4 {
    top: 65%;
    left: 80%;
    width: 55px;
    height: 55px;
    animation-delay: 6s;
}

.symbol-5 {
    top: 10%;
    left: 50%;
    width: 35px;
    height: 35px;
    animation-delay: 8s;
}

/* Keyframes */
@keyframes rotate-cw {
    from {
        transform: rotate(0deg);
    }

    to {
        transform: rotate(360deg);
    }
}

@keyframes rotate-ccw {
    from {
        transform: rotate(360deg);
    }

    to {
        transform: rotate(0deg);
    }
}

@keyframes glow-pulse {

    0%,
    100% {
        transform: scale(1);
        opacity: 0.15;
    }

    50% {
        transform: scale(1.2);
        opacity: 0.25;
    }
}

@keyframes core-breathe {

    0%,
    100% {
        transform: translate(-50%, -50%) scale(1);
        opacity: 0.1;
    }

    50% {
        transform: translate(-50%, -50%) scale(1.2);
        opacity: 0.3;
    }
}

@keyframes p-float {

    0%,
    100% {
        transform: translate(0, 0);
        opacity: 0.2;
    }

    50% {
        transform: translate(10px, -20px);
        opacity: 0.8;
    }
}

@keyframes symbol-pop {

    0%,
    15%,
    100% {
        opacity: 0;
        transform: scale(0.5) translateY(10px);
    }

    5%,
    10% {
        opacity: 1;
        transform: scale(1) translateY(0);
    }
}

@media (max-width: 1024px) {

    .hero,
    .container-split {
        flex-direction: column;
        text-align: center;
        gap: 4rem;
    }

    .hero-content {
        display: flex;
        flex-direction: column;
        align-items: center;
    }

    .feature-text p {
        margin: 1.5rem auto !important;
    }

    .feature-stats {
        justify-content: center;
    }

    .hero h1 {
        font-size: 3rem;
    }
}

@media (max-width: 768px) {
    .mobile-menu-btn {
        display: block;
        z-index: 10001;
        /* Ensure it stays above the side menu (z-index: 10000) */
        position: relative;
        color: var(--text-main);
    }

    .nav-links {
        display: flex;
        flex-direction: column;
        position: fixed;
        top: 0;
        right: -100%;
        width: 80%;
        max-width: 300px;
        height: 100vh;
        background: var(--bg-card);
        padding: 6rem 2rem 2rem 2rem;
        border-left: 1px solid var(--border);
        box-shadow: -10px 0 30px rgba(0, 0, 0, 0.5);
        text-align: center;
        transition: right 0.4s cubic-bezier(0.16, 1, 0.3, 1);
        z-index: 10000;
    }

    .nav-links.active {
        right: 0;
    }

    .nav-actions {
        display: flex;
        align-items: center;
        gap: 1rem;
    }

    .nav-actions .btn {
        display: none;
    }

    .hero {
        padding-top: 8rem;
    }

    .hero h1 {
        font-size: 2.2rem;
        line-height: 1.2;
    }

    .hero p {
        font-size: 1rem;
        padding: 0 10px;
    }

    .hero-image {
        width: 100%;
        max-width: 100%;
        margin-top: 2rem;
    }

    #canvas-container {
        height: 350px !important;
    }

    .section-padding {
        padding: 4rem 6%;
    }

    .grid {
        grid-template-columns: 1fr;
        gap: 2rem;
    }

    .container-split {
        gap: 2.5rem;
    }

    /* Keep theme toggle visible and looking nice */
    #theme-toggle {
        width: 40px;
        height: 40px;
    }
}

/* --- Global Utility Animations --- */
.reveal-standard {
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}

.reveal-standard.active {
    opacity: 1;
    transform: translateY(0);
}

.reveal-delay-1 {
    transition-delay: 0.1s;
}

.reveal-delay-2 {
    transition-delay: 0.2s;
}

.reveal-delay-3 {
    transition-delay: 0.3s;
}

.reveal-delay-4 {
    transition-delay: 0.4s;
}

/* --- Global Footer --- */
footer {
    text-align: center;
    padding: 40px 15px;
    background: var(--glass);
    color: var(--text-muted);
    border-top: 1px solid var(--glass-border);
    margin-top: 60px;
    backdrop-filter: blur(10px);
    width: 100%;
}