:root{
    --primary-yellow: #FFD600;
    --navy-blue: #020617;
    --accent-blue: #0f172a;
    --text-white: #ffffff;
    --gray-100: #f3f4f6;
    --card-bg: #1e293b;
}

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

body{
    font-family: system-ui, -apple-system, Segoe UI, Roboto, Arial, sans-serif;
    background-color: var(--gray-100);
    color: var(--navy-blue);
    line-height: 1.6;
    overflow-x: hidden;
}

/* Intro Scene */
.intro-scene{
    position: fixed;
    inset: 0;
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 24px;
    background: radial-gradient(1200px 600px at 50% 40%, rgba(255, 214, 0, 0.18), transparent 55%),
        linear-gradient(135deg, var(--navy-blue), var(--accent-blue));
    color: #fff;
    opacity: 1;
    transform: translateY(0);
    transition: opacity 350ms ease, transform 350ms ease;
}

.intro-scene--hide{
    opacity: 0;
    transform: translateY(-10px);
    pointer-events: none;
}

.intro-scene__content{
    width: min(920px, 100%);
    text-align: center;
}

.intro-scene__kicker{
    color: var(--primary-yellow);
    font-weight: 900;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    margin-bottom: 10px;
}

.intro-scene__title{
    font-size: clamp(1.35rem, 3vw, 2.4rem);
    line-height: 1.15;
    font-weight: 900;
}

.intro-scene__cars{
    position: relative;
    width: min(720px, 100%);
    height: 90px;
    margin: 22px auto 0;
}

.intro-scene__sidewalk{
    position: absolute;
    left: 0;
    right: 0;
    bottom: 48px;
    height: 6px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.10);
}

.intro-scene__road{
    position: absolute;
    left: 0;
    right: 0;
    bottom: 14px;
    height: 10px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.12);
    overflow: hidden;
}

.intro-scene__road::before{
    content: "";
    position: absolute;
    inset: 0;
    background: repeating-linear-gradient(
        90deg,
        rgba(255, 214, 0, 0.9) 0 26px,
        rgba(255, 214, 0, 0.0) 26px 44px
    );
    transform: translateX(-60px);
    opacity: 0.85;
}

.intro-scene--run .intro-scene__road::before{
    animation: introRoad 900ms linear infinite;
}

@keyframes introRoad{
    from{ transform: translateX(-60px); }
    to{ transform: translateX(0px); }
}

.intro-car{
    position: absolute;
    bottom: 22px;
    width: 74px;
    height: 26px;
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.92);
    box-shadow: 0 14px 30px rgba(0,0,0,0.35);
    opacity: 0;
}

.intro-car::before{
    content: "";
    position: absolute;
    left: 10px;
    top: -10px;
    width: 34px;
    height: 16px;
    border-radius: 10px 10px 6px 6px;
    background: rgba(255, 255, 255, 0.8);
}

.intro-car::after{
    content: "";
    position: absolute;
    left: 12px;
    right: 12px;
    bottom: -8px;
    height: 12px;
    background:
        radial-gradient(circle at 12px 6px, #0f172a 0 5px, transparent 6px),
        radial-gradient(circle at calc(100% - 12px) 6px, #0f172a 0 5px, transparent 6px);
}

.intro-car--a{ background: rgba(255, 214, 0, 0.95); }
.intro-car--b{ background: rgba(56, 189, 248, 0.95); }
.intro-car--c{ background: rgba(74, 222, 128, 0.95); width: 62px; height: 22px; bottom: 20px; }
.intro-car--d{ background: rgba(248, 113, 113, 0.95); width: 86px; height: 28px; bottom: 23px; }

.intro-scene--run .intro-car--a{ animation: introCarLtr 1.35s ease-in-out infinite; }
.intro-scene--run .intro-car--b{ animation: introCarRtl 1.8s ease-in-out infinite; animation-delay: 220ms; }
.intro-scene--run .intro-car--c{ animation: introCarLtr2 1.55s ease-in-out infinite; animation-delay: 140ms; }
.intro-scene--run .intro-car--d{ animation: introCarRtl2 2.05s ease-in-out infinite; animation-delay: 520ms; }

@keyframes introCarLtr{
    0%{ transform: translateX(-120px) translateY(0); opacity: 0; }
    10%{ opacity: 1; }
    55%{ transform: translateX(calc(50% - 40px)) translateY(-1px); opacity: 1; }
    100%{ transform: translateX(calc(100% + 140px)) translateY(0); opacity: 0; }
}

@keyframes introCarRtl{
    0%{ transform: translateX(calc(100% + 140px)) translateY(0) scaleX(-1); opacity: 0; }
    12%{ opacity: 1; }
    60%{ transform: translateX(calc(50% - 40px)) translateY(-1px) scaleX(-1); opacity: 1; }
    100%{ transform: translateX(-120px) translateY(0) scaleX(-1); opacity: 0; }
}

@keyframes introCarLtr2{
    0%{ transform: translateX(-160px) translateY(0); opacity: 0; }
    14%{ opacity: 1; }
    58%{ transform: translateX(calc(55% - 40px)) translateY(0); opacity: 1; }
    100%{ transform: translateX(calc(100% + 200px)) translateY(0); opacity: 0; }
}

@keyframes introCarRtl2{
    0%{ transform: translateX(calc(100% + 200px)) translateY(0) scaleX(-1); opacity: 0; }
    10%{ opacity: 1; }
    54%{ transform: translateX(calc(45% - 40px)) translateY(0) scaleX(-1); opacity: 1; }
    100%{ transform: translateX(-160px) translateY(0) scaleX(-1); opacity: 0; }
}

.intro-walker{
    position: absolute;
    bottom: 56px;
    width: 16px;
    height: 34px;
    opacity: 0;
    filter: drop-shadow(0 10px 18px rgba(0,0,0,0.35));
}

.intro-walker::before{
    content: "";
    position: absolute;
    left: 4px;
    top: 0;
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.9);
}

.intro-walker::after{
    content: "";
    position: absolute;
    left: 6px;
    top: 9px;
    width: 4px;
    height: 18px;
    border-radius: 3px;
    background: rgba(255, 255, 255, 0.75);
    box-shadow:
        -5px 10px 0 rgba(255, 255, 255, 0.65),
        5px 10px 0 rgba(255, 255, 255, 0.65);
}

.intro-walker--b{ transform: scale(0.95); }
.intro-walker--c{ transform: scale(1.05); }

.intro-scene--run .intro-walker--a{ animation: introWalkLtr 2.2s linear infinite; }
.intro-scene--run .intro-walker--b{ animation: introWalkRtl 2.6s linear infinite; animation-delay: 320ms; }
.intro-scene--run .intro-walker--c{ animation: introWalkLtr 2.9s linear infinite; animation-delay: 760ms; }

@keyframes introWalkLtr{
    0%{ transform: translateX(-40px) translateY(0) scale(1); opacity: 0; }
    8%{ opacity: 1; }
    50%{ transform: translateX(calc(50% - 10px)) translateY(-1px) scale(1); opacity: 1; }
    100%{ transform: translateX(calc(100% + 60px)) translateY(0) scale(1); opacity: 0; }
}

@keyframes introWalkRtl{
    0%{ transform: translateX(calc(100% + 60px)) translateY(0) scaleX(-1); opacity: 0; }
    10%{ opacity: 1; }
    55%{ transform: translateX(calc(50% - 10px)) translateY(-1px) scaleX(-1); opacity: 1; }
    100%{ transform: translateX(-40px) translateY(0) scaleX(-1); opacity: 0; }
}

.intro-scene__bar{
    margin: 18px auto 0;
    width: min(420px, 85%);
    height: 6px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.12);
    overflow: hidden;
}

.intro-scene__bar > span{
    display: block;
    height: 100%;
    width: 0%;
    background: var(--primary-yellow);
    border-radius: 999px;
    animation: none;
}

.intro-scene--run .intro-scene__bar > span{
    animation: introProgress 4s linear forwards;
}

@keyframes introProgress{
    from{ width: 0%; }
    to{ width: 100%; }
}

/* Navigation */
header{
    width: 100%;
    height: 75px;
    background-color: var(--navy-blue);
    display: flex;
    align-items: center;
    padding: 0 5%;
    justify-content: space-between;
    position: sticky;
    top: 0;
    z-index: 1000;
    box-shadow: 0 4px 20px rgba(0,0,0,0.2);
}

.logo{
    color: var(--primary-yellow);
    font-size: 26px;
    font-weight: 900;
    letter-spacing: -1px;
}

nav{
    display: flex;
    gap: 30px;
}

nav li{
    list-style: none;
    color: white;
    font-weight: 500;
    cursor: pointer;
    font-size: 0.95rem;
}

nav li:hover{
    color: var(--primary-yellow);
}

.cta-h{
    padding: 10px 24px;
    border-radius: 50px;
    background: var(--primary-yellow);
    color: var(--navy-blue);
    border: none;
    font-weight: 800;
    cursor: pointer;
}

/* Hero */
.hero{
    height: 85vh;
    background: linear-gradient(rgba(2, 6, 23, 0.7), rgba(2, 6, 23, 0.7)),
        url('https://images.unsplash.com/photo-1555066931-4365d14bab8c?auto=format&fit=crop&w=1600&q=80');
    background-size: cover;
    background-position: center;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    color: white;
    padding: 0 20px;
}

.hero-content h1{
    font-size: clamp(2.5rem, 8vw, 5rem);
    color: var(--primary-yellow);
    line-height: 1.1;
    margin-bottom: 20px;
}

.hero-content p{
    font-size: 1.25rem;
    max-width: 700px;
    margin: 0 auto 30px;
    opacity: 0.9;
}

.cta-button{
    padding: 14px 34px;
    font-size: 1.05rem;
    background-color: var(--primary-yellow);
    color: var(--navy-blue);
    border: none;
    border-radius: 999px;
    cursor: pointer;
    font-weight: 900;
    transition: transform 0.3s ease, background-color 0.3s ease;
}

.cta-button:hover{
    transform: scale(1.06);
    background-color: #e5c100;
}

/* Sections */
section{
    padding: 100px 10% 60px;
}

.section-title{
    font-size: 2.5rem;
    margin-bottom: 50px;
    position: relative;
    display: inline-block;
}

.section-title::after{
    content: '';
    position: absolute;
    bottom: -10px;
    left: 0;
    width: 60px;
    height: 5px;
    background: var(--primary-yellow);
}

.grid-2{
    display: grid;
    grid-template-columns: 1.2fr 0.8fr;
    gap: 60px;
}

.stack-card{
    background: var(--navy-blue);
    color: white;
    padding: 40px;
    border-radius: 20px;
    box-shadow: 0 20px 40px rgba(0,0,0,0.1);
}

.stack-group{
    margin-bottom: 25px;
}

.stack-group h4{
    color: var(--primary-yellow);
    margin-bottom: 10px;
    text-transform: uppercase;
    font-size: 0.8rem;
    letter-spacing: 2px;
}

.stack-tags{
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.tag{
    background: rgba(255,255,255,0.1);
    padding: 5px 15px;
    border-radius: 6px;
    font-size: 0.9rem;
}

.link{
    color: #1d4ed8;
    font-weight: 800;
    text-decoration: none;
}

/* Projects */
.projects-grid{
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
}

.project-card{
    background: white;
    border-radius: 15px;
    padding: 35px;
    border-bottom: 4px solid transparent;
    transition: all 0.3s;
    box-shadow: 0 10px 30px rgba(0,0,0,0.05);
}

.project-card:hover{
    transform: translateY(-10px);
    border-bottom-color: var(--primary-yellow);
}

.project-card h3{
    font-size: 1.5rem;
    margin-bottom: 15px;
}

.project-card p{
    font-size: 0.95rem;
    color: #64748b;
    margin-bottom: 20px;
}

.project-link{
    color: var(--navy-blue);
    font-weight: 900;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

/* Footer */
footer{
    background: var(--navy-blue);
    color: white;
    padding: 80px 10% 40px;
    text-align: center;
}

.footer-content h2{
    font-size: 2.5rem;
    margin-bottom: 20px;
    color: var(--primary-yellow);
}

.contact-info{
    margin: 30px 0;
    font-size: 1.1rem;
}

.contact-info p{
    margin: 10px 0;
}

.social-links{
    display: flex;
    justify-content: center;
    gap: 20px;
    margin-top: 40px;
    flex-wrap: wrap;
}

.social-links a{
    color: white;
    text-decoration: none;
    font-weight: 900;
    border: 1px solid rgba(255,255,255,0.2);
    padding: 10px 20px;
    border-radius: 8px;
    transition: background-color 0.25s ease, color 0.25s ease, border-color 0.25s ease;
}

.social-links a:hover{
    background: var(--primary-yellow);
    color: var(--navy-blue);
    border-color: var(--primary-yellow);
}

.footer-link{
    color: white;
    text-decoration: none;
    font-weight: 800;
}

@media (max-width: 900px){
    .grid-2{ grid-template-columns: 1fr; }
    nav{ display: none; }
    section{ padding: 80px 7% 50px; }
}

