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

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Inter', sans-serif;
    background: radial-gradient(circle at top, #0b1b34, #050b18);
    color: #e6edf3;
    overflow-x: hidden;
}

a {
    text-decoration: none;
    color: inherit;
}

/* ================= NAVBAR ================= */
.navbar {
    position: fixed;
    top: 0;
    width: 100%;
    z-index: 1000;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 20px;
    background: rgba(10, 25, 47, 0.6);
    backdrop-filter: blur(14px);
    border-bottom: 1px solid rgba(100,255,218,0.08);
}

.logo {
    font-weight: 800;
    font-size: 18px;
    background: linear-gradient(90deg, #64ffda, #7c3aed);
    background-clip: text;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.nav-links {
    display: flex;
    gap: 15px;
    list-style: none;
    flex-wrap: wrap;
    justify-content: flex-end;
}

.nav-links a {
    color: #ccd6f6;
    font-size: 13px;
    transition: 0.3s;
}

.nav-links a:hover {
    color: #64ffda;
}

/* ================= CONTAINER ================= */
.container {
    max-width: 1200px;
    margin: auto;
    padding: 0 15px;
}

section {
    padding: 80px 0;
}

h2 {
    font-size: 2rem;
    text-align: center;
    margin-bottom: 40px;
    position: relative;
}

h2::after {
    content: "";
    width: 50px;
    height: 4px;
    background: linear-gradient(90deg, #64ffda, #7c3aed);
    display: block;
    margin: 12px auto 0;
    border-radius: 10px;
}

/* ================= BUTTONS ================= */
.btn-primary {
    display: inline-block;
    padding: 10px 24px;
    border-radius: 10px;
    font-weight: 600;
    background: linear-gradient(90deg, #64ffda, #7c3aed);
    color: #0a192f;
    transition: 0.3s;
    font-size: 14px;
}

.btn-primary:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 30px rgba(100,255,218,0.2);
}

.btn-secondary {
    border: 1px solid #64ffda;
    padding: 10px 24px;
    border-radius: 10px;
    color: #64ffda;
    margin-left: 10px;
    transition: 0.3s;
    font-size: 14px;
}

.btn-secondary:hover {
    background: rgba(100,255,218,0.1);
}

/* ================= CARDS ================= */
.card {
    background: rgba(17, 36, 64, 0.55);
    border: 1px solid rgba(100,255,218,0.08);
    backdrop-filter: blur(12px);
    border-radius: 16px;
    transition: 0.4s;
}

.card:hover {
    transform: translateY(-10px);
    box-shadow: 0 20px 50px rgba(0,0,0,0.4);
    border-color: #64ffda;
}

/* ================= HERO ================= */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    padding: 80px 0 60px 0;
}

.hero h1 {
    font-size: 2.8rem;
    font-weight: 800;
    background: linear-gradient(90deg, #64ffda, #7c3aed);
    background-clip: text;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.hero p {
    color: #a8b2d1;
    font-size: 1.1rem;
    margin-top: 15px;
    line-height: 1.6;
}

.hero-content {
    padding-top: 40px;
    max-width: 100%;
}

.hero-buttons {
    margin-top: 30px;
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.progress {
    height: 100%;
    background: linear-gradient(90deg, #64ffda, #7c3aed);
    transition: 1.2s;
}

/* ================= SERVICES ================= */
.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
}

/* ================= SKILLS ================= */
.skills-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 20px;
}

/* ================= PROJECTS ================= */
.projects-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 20px;
}

.project-image {
    width: 100%;
    height: 200px;
    object-fit: cover;
}

.project-placeholder {
    width: 100%;
    height: 200px;
    background: linear-gradient(135deg, #64ffda, #7c3aed);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 3rem;
}

.project-content {
    padding: 20px;
}

.project-title {
    font-size: 1.2rem;
    margin-bottom: 8px;
}

.project-description {
    color: #a8b2d1;
    font-size: 0.9rem;
    line-height: 1.5;
}

.project-links {
    margin-top: 15px;
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

/* ================= CONTACT ================= */
.contact-card {
    padding: 30px 20px;
    max-width: 700px;
    margin: auto;
    text-align: center;
}

.contact-title {
    color: #64ffda;
    margin-bottom: 15px;
    font-size: 1.3rem;
}

.contact-description {
    color: #a8b2d1;
    margin-bottom: 30px;
    font-size: 0.95rem;
    line-height: 1.6;
}

.contact-info {
    margin-bottom: 20px;
}

.contact-info strong {
    display: block;
    margin-bottom: 5px;
}

.contact-info span {
    color: #ccd6f6;
}

.contact-buttons {
    display: flex;
    justify-content: center;
    gap: 10px;
    flex-wrap: wrap;
}

/* ================= RESPONSIVE - MOBILE FIRST ================= */

/* Small phones (320px - 375px) */
@media (max-width: 375px) {
    .navbar {
        padding: 12px 15px;
        flex-direction: column;
        gap: 8px;
    }
    
    .nav-links {
        gap: 10px;
        justify-content: center;
        flex-wrap: wrap;
    }
    
    .nav-links a {
        font-size: 11px;
    }
    
    .hero h1 {
        font-size: 2.2rem;
    }
    
    .hero p {
        font-size: 1rem;
    }
    
    h2 {
        font-size: 1.6rem;
    }
    
    .btn-primary, .btn-secondary {
        padding: 8px 18px;
        font-size: 12px;
    }
    
    .services-grid {
        grid-template-columns: 1fr;
    }
    
    .skills-grid {
        grid-template-columns: 1fr;
    }
    
    .projects-grid {
        grid-template-columns: 1fr;
    }
}

/* Mobile phones (376px - 480px) */
@media (min-width: 376px) and (max-width: 480px) {
    .navbar {
        padding: 12px 18px;
    }
    
    .nav-links {
        gap: 12px;
    }
    
    .nav-links a {
        font-size: 12px;
    }
    
    .hero h1 {
        font-size: 2.5rem;
    }
    
    .hero p {
        font-size: 1rem;
    }
    
    h2 {
        font-size: 1.8rem;
    }
    
    .services-grid {
        grid-template-columns: 1fr;
        gap: 15px;
    }
    
    .skills-grid {
        grid-template-columns: 1fr;
        gap: 15px;
    }
    
    .projects-grid {
        grid-template-columns: 1fr;
        gap: 15px;
    }
    
    .btn-primary, .btn-secondary {
        padding: 10px 20px;
        font-size: 13px;
    }
    
    .contact-card {
        padding: 20px 15px;
    }
    
    .hero-buttons {
        flex-direction: column;
        align-items: stretch;
    }
    
    .btn-secondary {
        margin-left: 0;
    }
}

/* Tablets and small desktops (481px - 768px) */
@media (min-width: 481px) and (max-width: 768px) {
    .navbar {
        padding: 15px 25px;
    }
    
    .nav-links a {
        font-size: 13px;
    }
    
    .hero h1 {
        font-size: 2.8rem;
    }
    
    .services-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .skills-grid {
        grid-template-columns: 1fr;
    }
    
    .projects-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* Large screens (769px+) */
@media (min-width: 769px) {
    .navbar {
        padding: 18px 50px;
    }
    
    .nav-links {
        gap: 25px;
    }
    
    .nav-links a {
        font-size: 14px;
    }
    
    .hero h1 {
        font-size: 4rem;
    }
    
    .hero p {
        font-size: 1.2rem;
    }
    
    h2 {
        font-size: 2.4rem;
    }
    
    .services-grid {
        grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
        gap: 25px;
    }
    
    .skills-grid {
        grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
        gap: 30px;
    }
    
    .projects-grid {
        grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
        gap: 25px;
    }
    
    .contact-card {
        padding: 40px;
    }
}

/* ================= EXTRA FIXES ================= */

/* Fix for very small screens */
@media (max-width: 320px) {
    .hero h1 {
        font-size: 1.8rem;
    }
    
    .nav-links {
        gap: 8px;
    }
    
    .nav-links a {
        font-size: 10px;
    }
    
    .logo {
        font-size: 14px;
    }
}

/* Fix for 412px width (Pixel 7, etc.) */
@media (max-width: 420px) {
    .hero-content {
        padding-top: 30px;
    }
    
    .hero h1 {
        font-size: 2.3rem;
    }
    
    .hero p {
        font-size: 0.95rem;
    }
    
    .services-grid {
        grid-template-columns: 1fr;
    }
    
    .skills-grid {
        grid-template-columns: 1fr;
    }
    
    .projects-grid {
        grid-template-columns: 1fr;
    }
    
    .project-image, .project-placeholder {
        height: 100px;
    }
    
    .btn-primary, .btn-secondary {
        padding: 10px 18px;
        font-size: 12px;
    }
    
    .hero-buttons {
        flex-direction: column;
        width: 100%;
    }
    
    .hero-buttons a {
        text-align: center;
        margin-left: 0;
        width: 100%;
    }
    
    .contact-card {
        padding: 20px 15px;
    }
    
    .contact-buttons {
        flex-direction: column;
    }
    
    .contact-buttons a {
        width: 100%;
        text-align: center;
    }
}