* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: "Poppins", sans-serif;
}

body {
    background: #fff;
    color: #111;
}

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

/* HEADER --------------------------------------------------- */
header {
    width: 100%;
    padding: 20px 8%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    position: fixed;
    top: 0;
    background: #fff;
    z-index: 100;
    box-shadow: 0 2px 10px rgba(0,0,0,0.06);
}

header .logo {
    font-size: 20px;
    font-weight: 700;
}

header nav a {
    margin: 0 15px;
    color: #222;
    font-weight: 500;
}

.btn-primary {
    padding: 12px 28px;
    border: none;
    border-radius: 8px;
    background: #111;
    color: #fff;
    font-weight: 600;
    font-size: 16px;
    cursor: pointer;
    transition: 0.25s ease;
}

.btn-primary:hover {
    transform: translateY(-2px);
    opacity: 0.9;
}


/* HERO ------------------------------------------------------ */
.hero {
    padding: 140px 8% 80px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 60px;
}

.hero-text {
    max-width: 500px;
}

.hero-text h1 {
    font-size: 56px;
    line-height: 1.1;
    margin-bottom: 15px;
}

.hero-text h1 span {
    color: #3b82f6;
}

.hero-text .desc {
    margin: 10px 0 25px;
    font-size: 18px;
    color: #555;
}

.hero-buttons {
    display: flex;
    gap: 15px;
}

.hero-img img {
    width: 420px;
    animation: float 4s ease-in-out infinite;
}

@keyframes float {
    0% { transform: translateY(0); }
    50% { transform: translateY(-10px); }
    100% { transform: translateY(0); }
}

.cv-btn {     
    font-weight: 600;         
    padding: 10px 18px;           
    display: inline-block;
    padding: 12px 28px;
    border-radius: 8px;
    border: 2px solid #111;
    background: transparent;
    transition: 0.25s ease;
    color: #111; 
}

.cv-btn:hover {
    background: #111;
    color: #fff;
    transform: translateY(-2px);
}


/* ABOUT ----------------------------------------------------- */
.about {
    padding: 100px 8%;
    display: flex;
    align-items: center;
    gap: 60px;
}

.about-img img {
    width: 360px;
}

.skills .skill {
    margin-bottom: 18px;
}

.skills .bar {
    width: 100%;
    height: 10px;
    background: #eee;
    border-radius: 6px;
    margin-top: 6px;
}

.skills .bar div {
    height: 100%;
    background: #3b82f6;
    border-radius: 6px;
}

/* SERVICES ----------------------------------------------------- */
.services {
    padding: 100px 8%;
    text-align: center;
}

.services .grid {
    margin-top: 40px;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 25px;
}

.card {
    padding: 25px;
    border-radius: 12px;
    background: #f8f8f8;
    transition: 0.25s;
}

.card:hover {
    transform: translateY(-6px);
    background: #eee;
}

/* PORTOFOLIO ---------------------------------------------------- */
.portofolio {
    padding: 100px 8%;
    text-align: center;
}

.portofolio-grid {
    margin-top: 35px;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 25px;
    justify-items: center;
}

.p-card {
    width: 100%;
    max-width: 350px;
    background: #f8f8f8;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 3px 10px rgba(0,0,0,0.08);
    transition: 0.3s;
    text-align: left;
    position: relative;
    padding-bottom: 65px;
}

.p-card:hover {
    transform: translateY(-6px);
}

.p-card img {
    width: 90%;
    height: 160px;
    object-fit: cover;
    margin: 13px auto 0;
    border-radius: 12px;
    display: block;
}

.p-content {
    padding: 18px;
}

.p-content h3 {
    font-size: 20px;
    font-weight: 600;
    margin-bottom: 8px;
}

.p-content p {
    font-size: 14px;
    color: #555;
    margin-bottom: 12px;
}

.btn-view {
    display: inline-block;
    padding: 10px 18px;
    background: #111;
    color: #fff;
    border-radius: 6px;
    transition: 0.25s;
    font-size: 14px;
    font-weight: 500;
    position: absolute;
    bottom: 20px;
    left: 20px;
}

.btn-view:hover {
    opacity: 0.85;
}

/* SCROLL REVEAL ------------------------------------------------ */
.reveal {
    opacity: 0;
    transform: translateY(40px);
    transition: 0.8s ease;
}

.reveal.active {
    opacity: 1;
    transform: translateY(0);
}


/* RESPONSIVE (TABLET) ---------------------------------------- */
@media (max-width: 900px) {
    .hero {
        flex-direction: column-reverse;
        text-align: center;
    }

    .hero-buttons {
        justify-content: center;
    }

    .about {
        flex-direction: column;
        text-align: center;
    }

    header nav {
        display: none;
    }
}

/* RESPONSIVE (HP) --------------------------------------------- */
@media (max-width: 600px) {
    body {
        overflow-x: hidden;
    }

    header {
        padding: 15px 5%;
    }

    header .logo {
        font-size: 18px;
    }

    .btn-primary {
        padding: 9px 20px;
        font-size: 14px;
    }

    /* HERO */
    .hero {
        padding: 120px 5% 50px;
        gap: 30px;
    }

    .hero-text h1 {
        font-size: 36px;
    }

    .hero-text .desc {
        font-size: 16px;
    }

    .hero-img img {
        width: 260px;
    }

    /* ABOUT */
    .about {
        padding: 70px 5%;
        gap: 25px;
    }

    .about-img img {
        width: 240px;
    }

    /* SERVICES */
    .card {
        width: 100%;
    }

    /* PORTOFOLIO */
    .p-card {
        max-width: 100%;
    }

    .p-card img {
        height: 130px;
        width: 92%;
    }
}
