@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@400;500;600;700&display=swap');

/* === Gaya Dasar === */
body {
    font-family: 'Poppins', sans-serif;
    margin: 0;
    padding: 0;
    background-color: #f8fafc;
    color: #334155;
    line-height: 1.6;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

/* === Navigasi === */
nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.5rem 5%;
    background-color: #1e293b;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

nav img {
    height: 50px;
    width: auto;
    animation: slideInLeft 0.6s ease-out 0.2s both
}

nav ul {
    display: flex;
    list-style: none;
    margin: 0;
    padding: 0;
    animation: slideInRight 0.6s ease-out 0.2s both
}

nav ul li {
    margin-left: 2rem;
}

nav ul li a {
    color: #f8fafc;
    text-decoration: none;
    font-weight: 500;
    transition: color 0.3s ease;
    position: relative;
    padding-bottom: 5px;
}

nav ul li a:hover {
    color: #60a5fa;
}

nav ul li a::after {
    content: '';
    position: absolute;
    width: 0;
    height: 2px;
    bottom: 0;
    left: 0;
    background-color: #60a5fa;
    transition: width 0.3s ease;
}

nav ul li a:hover::after {
    width: 100%;
}

/* === Konten Utama === */
.content {
    display: block;
    justify-content: space-between;
    align-items: center;
    padding: 5rem 10%;
    flex: 1;
}

.content-top {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex: 1;
}

.content-text {
    max-width: 600px;
}

.content-image {
    flex: 0 0 300px;
    text-align: center;
}

.content-image img {
    width: 100%;
    max-width: 250px;
    height: auto;
    animation: slideInRight 1.2s ease-out forwards;
}

.h1 {
    font-size: 3rem;
    color: #1e293b;
    margin-bottom: 1.5rem;
    font-weight: 700;
    animation: slideInLeft 1.2s ease-out forwards;
}

.p1, .p2, .p3, .p4 {
    font-size: 1.1rem;
    color: #64748b;
    margin-bottom: rem;
    line-height: 1;
    animation: slideInLeft 1.2s ease-out forwards;
}

/* === Footer === */
.footer {
    width: 100%;
    padding: 1.5rem 0;
    background-color: #1e293b;
    color: #f8fafc;
    text-align: center;
    margin-top: auto;
    animation: slideInUp 0.6s ease-out 0.2s both
}

@media (max-width: 768px) {
    nav {
        flex-direction: column;
        padding: 1rem;
    }
    
    nav ul {
        margin-top: 1rem;
    }
    
    nav ul li {
        margin: 0 1rem;
    }
    
    .h1 {
        font-size: 2.5rem;
    }
}

@media (max-width: 480px) {
  /* Navigation */
  nav {
    padding: 1rem;
    flex-direction: column;
    text-align: center;
  }
  
  nav ul {
    flex-wrap: wrap;
    justify-content: center;
    margin-top: 1rem;
  }
  
  nav ul li {
    margin: 0.5rem;
  }
  
  nav img {
    height: 40px;
  }
  
  /* Content */
  .content {
    padding: 2rem 1rem;
  }
  
  .content-top {
    gap: 1.5rem;
  }
  
  .h1 {
    font-size: 1.8rem;
    text-align: center;
    margin-bottom: 1rem;
  }
  
  .p1, .p2, .p3, .p4 {
    font-size: 0.9rem;
    text-align: left;
    line-height: 1;
    max-width: 600px; /* Lebar maksimum */
    margin-left: auto; /* Pusatkan blok */
    margin-right: auto; /* Pusatkan blok */
    padding: 0 1rem; /* Padding untuk mobile */
    width: 100%; /* Pastikan tidak melebihi parent */
  }
    
  .content-image img {
    max-width: 90px;
  }
  
  /* Skills Section */
  .skills {
    margin: 2rem 0;
    padding: 1rem;
    border-radius: 8px;
  }
  
  .skill-title {
    font-size: 1.5rem;
    text-align: center;
  }
  
  .skill-name {
    font-size: 0.8rem;
  }
  
  .skill-bar {
    height: 8px;
  }

    .content-top {
    display: block;
    justify-content: space-between;
    align-items: center;
    flex: 1;
    }
  
  /* Animasi di mobile lebih sederhana */
  @media (prefers-reduced-motion: no-preference) {
    .h1, .p1, .p2, .p3, .p4 {
      animation: fadeIn 1s ease-out;
    }
    
    .content-image img {
      animation: fadeIn 1.5s ease-out;
    }
  }
}

/* Animasi khusus mobile */
@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}
/* === Responsif === */
* Tablet (768px ke atas) */
@media (max-width: 768px) {
    .content {
        padding: 4rem 8%;
    }
    
    .h1 {
        font-size: 2.5rem;
    }

    .p1, .p2, .p3, .p4 {
        font-size: 0.9rem;
        text-align: left;
        line-height: 1;
        max-width: 600px; /* Lebar maksimum */
        margin-left: auto; /* Pusatkan blok */
        margin-right: auto; /* Pusatkan blok */
        padding: 0 1rem; /* Padding untuk mobile */
        width: 100%; /* Pastikan tidak melebihi parent */
    }

    .content-top {
    display: block;
    justify-content: space-between;
    align-items: center;
    flex: 1;
    }
}

/* Laptop (1024px ke atas) */
@media (min-width: 1024px) {
    .content-top {
        flex-direction: row;
        justify-content: space-between;
        gap: 4rem;
    }
    
    .content-text {
        max-width: 55%;
        order: 1;
    }
    
    .content-image {
        order: 2;
        flex: 0 0 40%;
    }
    
    .h1 {
        font-size: 3rem;
    }
    
    .content-image img {
        max-width: 300px;
    }
}

/* Layar Lebar (1200px ke atas) */
@media (min-width: 1200px) {
    .content {
        padding: 5rem 10%;
    }
    
    .content-text {
        max-width: 600px;
    }
}


@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes slideInLeft {
    from { 
        transform: translateX(-50px);
        opacity: 0;
    }
    to { 
        transform: translateX(0);
        opacity: 1;
    }
}

@keyframes slideInRight {
    from { 
        transform: translateX(50px);
        opacity: 0;
    }
    to { 
        transform: translateX(0);
        opacity: 1;
    }
}

@keyframes slideInUp {
    from { 
        transform: translateY(30px);
        opacity: 0;
    }
    to { 
        transform: translateY(0);
        opacity: 1;
    }
}

.clickable-image {
    position: relative;
    display: inline-block;
    transition: all 0.3s ease;
    cursor: pointer;
}

.clickable-image img {
    width: auto;
    height: 50px;
    border-radius: 10px;
    transition: all 0.3s ease;
    display: block;
}

.clickable-image:hover {
    transform: translateY(-5px);
}

.clickable-image:hover img {
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.2);
}

.clickable-image::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.3);
    border-radius: 10px;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.clickable-image:hover::after {
    opacity: 1;
}

.skills {
    margin: 3rem 0;
    padding: 1.5rem;
    border: 1px solid var(--border);
    border-radius: 12px;
    background-color: rgb(233, 233, 233);
    box-shadow: 0 1px 3px rgba(0,0,0,0.05);
}

.skill-title {
    font-size: 2rem;
    color: #1e293b;
    margin-bottom: 1.5rem;
    font-weight: 700;
}

.skill-item {
    margin-bottom: 1rem;
}

.skill-name {
    display: flex;
    justify-content: space-between;
    margin-bottom: 0.5rem;
}

.skill-bar {
    height: 10px;
    background-color: #ecf0f1;
    border-radius: 5px;
    overflow: hidden;
}

.skill-progress {
    height: 100%;
    background-color: #3498db;
    border-radius: 5px;
}
