/* --------------------------------------------------------------
   Global resets & variables
   -------------------------------------------------------------- */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --primary:   #3b82f6;
    --secondary: #8b5cf6;
    --dark:      #0f172a;
    --light:     #f8fafc;
    --accent:    #06b6d4;
}

/* --------------------------------------------------------------
   Base layout
   -------------------------------------------------------------- */
body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI',
                 system-ui, sans-serif;
    background: var(--dark);
    color: var(--light);
    overflow-x: hidden;
}

/* --------------------------------------------------------------
   Hero section
   -------------------------------------------------------------- */
.hero {
    height: 100vh;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}
.particles {
    position: absolute;
    inset: 0;
    z-index: 1;
}
.particle {
    position: absolute;
    width: 2px;
    height: 2px;
    background: var(--primary);
    border-radius: 50%;
    animation: verticalFloat 20s infinite;
    opacity: 0.6;
}
.hero-content {
    text-align: center;
    z-index: 2;
    position: relative;
}
.hero h1 {
    font-size: clamp(2.5rem, 8vw, 5rem);
    font-weight: 800;
    background: linear-gradient(135deg,
                var(--primary), var(--secondary), var(--accent));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 1rem;
    animation: fadeInUp 1s ease-out;
}
.hero p {
    font-size: 1.5rem;
    opacity: 0.9;
    margin-bottom: 2rem;
    animation: fadeInUp 1s ease-out 0.2s both;
}
.cta-buttons {
    display: flex;
    gap: 1rem;
    justify-content: center;
    animation: fadeInUp 1s ease-out 0.4s both;
}

/* --------------------------------------------------------------
   Buttons
   -------------------------------------------------------------- */
.btn {
    padding: 1rem 2.5rem;
    border: none;
    border-radius: 50px;
    font-size: 1.1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    text-decoration: none;
    display: inline-block;
}
.btn-primary {
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    color: #fff;
    box-shadow: 0 10px 30px rgba(59,130,246,.3);
}
.btn-primary:hover {
    transform: translateY(-3px);
    box-shadow: 0 15px 40px rgba(59,130,246,.4);
}
.btn-secondary {
    background: transparent;
    color: var(--light);
    border: 2px solid #60a5fa;
}
.btn-secondary:hover {
    background: var(--primary);
    transform: translateY(-3px);
}

/* --------------------------------------------------------------
   Navigation
   -------------------------------------------------------------- */
nav {
    position: fixed;
    top: 0;
    width: 100%;
    padding: 1.5rem 5%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    z-index: 1000;
    transition: all .3s ease;
}
nav.scrolled {
    background: rgba(15,23,42,.95);
    backdrop-filter: blur(10px);
    box-shadow: 0 5px 30px rgba(0,0,0,.3);
}
.logo {
    font-size: 1.8rem;
    font-weight: 800;
    background: linear-gradient(135deg,var(--primary),var(--accent));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}
.nav-links {
    display: flex;
    gap: 2rem;
    list-style: none;
}
.nav-links a {
    color: var(--light);
    text-decoration: none;
    font-weight: 500;
    transition: color .3s ease;
    position: relative;
}
.nav-links a::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--primary);
    transition: width .3s ease;
}
.nav-links a:hover::after { width: 100%; }

/* --------------------------------------------------------------
   Sections & Titles
   -------------------------------------------------------------- */
.section {
    padding: 6rem 5%;
    position: relative;
}
.section-title {
    text-align: center;
    font-size: 3rem;
    margin-bottom: 3rem;
    background: linear-gradient(135deg,var(--primary),var(--accent));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

/* --------------------------------------------------------------
   Feature cards
   -------------------------------------------------------------- */
.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px,1fr));
    gap: 2rem;
    margin-top: 3rem;
}
.feature-card {
    background: linear-gradient(145deg,
                rgba(59,130,246,.1), rgba(139,92,246,.05));
    padding: 2.5rem;
    border-radius: 20px;
    border: 1px solid rgba(59,130,246,.2);
    transition: all .4s ease;
    cursor: pointer;
    position: relative;
    overflow: hidden;
}
.feature-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg,transparent,
                rgba(59,130,246,.2),transparent);
    transition: left .5s ease;
}
.feature-card:hover::before { left: 100%; }
.feature-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 20px 50px rgba(59,130,246,.3);
    border-color: var(--primary);
}
.feature-icon { font-size: 3rem; margin-bottom: 1rem; }
.feature-card h3 {
    font-size: 1.5rem;
    margin-bottom: 1rem;
    color: var(--primary);
}
.feature-card h2 {
    font-size: 1.5rem;
    margin-bottom: 1rem;
    color: var(--accent);
}
.feature-card p {
    opacity: .8;
    line-height: 1.6;
}

/* --------------------------------------------------------------
   Tech‑stack badges
   -------------------------------------------------------------- */
.tech-stack {
    display: flex;
    flex-wrap: wrap;
    gap: 1.5rem;
    justify-content: center;
    margin-top: 3rem;
}
.tech-badge {
    padding: 1rem 2rem;
    background: rgba(59,130,246,.1);
    border: 2px solid var(--primary);
    border-radius: 50px;
    font-weight: 600;
    transition: all .3s ease;
    cursor: pointer;
}
.tech-badge:hover {
    background: var(--primary);
    transform: scale(1.1);
    box-shadow: 0 10px 30px rgba(59,130,246,.4);
}

/* --------------------------------------------------------------
   About section
   -------------------------------------------------------------- */
.about-content {
    max-width: 900px;
    margin: 0 auto;
    background: linear-gradient(145deg,
                rgba(59,130,246,.05), rgba(139,92,246,.02));
    padding: 3rem;
    border-radius: 20px;
    border: 1px solid rgba(59,130,246,.2);
}
.about-content p {
    font-size: 1.2rem;
    line-height: 1.8;
    opacity: .9;
    margin-bottom: 1.5rem;
}

/* --------------------------------------------------------------
   Footer
   -------------------------------------------------------------- */
footer {
    background: rgba(15,23,42,.95);
    padding: 3rem 5%;
    text-align: center;
    border-top: 1px solid rgba(59,130,246,.2);
}
footer p { opacity: .7; }

/* --------------------------------------------------------------
   Scroll reveal
   -------------------------------------------------------------- */
.reveal {
    opacity: 0;
    transform: translateY(50px);
    transition: all .8s ease;
}
.reveal.active {
    opacity: 1;
    transform: translateY(0);
}

/* --------------------------------------------------------------
   Mobile menu
   -------------------------------------------------------------- */
.menu-toggle {
    display: none;
    flex-direction: column;
    gap: 5px;
    cursor: pointer;
}
.menu-toggle span {
    width: 25px;
    height: 3px;
    background: var(--light);
    transition: all .3s ease;
}

/* --------------------------------------------------------------
   Responsive tweaks
   -------------------------------------------------------------- */
@media (max-width: 768px) {
    .hero h1 { font-size: 3rem; }
    .hero p { font-size: 1.2rem; }
    .cta-buttons { flex-direction: column; align-items: center; }
    .nav-links { display: none; }
    .menu-toggle { display: flex; }
    .section-title { font-size: 2rem; }
}

/* --------------------------------------------------------------
   Animations
   -------------------------------------------------------------- */
@keyframes verticalFloat {
    0%, 100% { transform: translateY(0); }
    50%       { transform: translateY(-20px); }
}
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}
.floating {
    animation: verticalFloat 3s ease-in-out infinite;
}