/* Reset dan Dasar */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Poppins', sans-serif;
    background-color: #f5f9fc;
    color: #333;
}

/* Kontainer Utama */
.container {
    display: grid;
    grid-template-areas:
        "sidebar content"
        "sidebar footer";
    grid-template-columns: auto 1fr;
    grid-template-rows: auto auto;
    min-height: 100vh;
}
/* Sidebar */
.sidebar {
    grid-area: sidebar;
    background: #1c64e3;
    color: white;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    padding: 1rem;
}

nav ul {
    list-style: none;
    text-align: center;
}

.nav-link {
    display: block;
    padding: 1rem 2rem;
    margin: 1rem 0;
    text-decoration: none;
    font-size: 1.2rem;
    color: #a3c4f3;
    border: 2px solid transparent;
    transition: 0.3s ease;
}

.nav-link:hover {
    color: #ffffff;
    border: 2px solid #a3c4f3;
    background: rgba(163, 196, 243, 0.2);
    border-radius: 10px;
}

.sidebar nav li {
    margin: 20px 0;
}

.sidebar nav a {
    color: white;
    text-decoration: none;
    font-weight: bold;
    font-size: 1.5em;
}

.sidebar nav a:hover {
    color: #a8d0ff;
}

/* Styling dasar sidebar */
.sidebar {
    position: fixed;
    top: 0;
    left: -250px; /* Sidebar tersembunyi di sebelah kiri */
    width: 250px;
    height: 100%;
    background-color: #1b253b; /* Warna latar belakang sidebar */
    color: white;
    box-shadow: 2px 0 10px rgba(0, 0, 0, 0.5);
    transition: left 0.3s ease; /* Transisi saat sidebar muncul */
    z-index: 1000;
}

/* Saat sidebar aktif (ditampilkan) */
.sidebar.active {
    left: 0;
}

/* Styling tombol menu */
.menu-toggle {
    position: absolute;
    top: 20px;
    right: -40px; /* Tombol berada di luar sidebar */
    width: 40px;
    height: 40px;
    background-color: #567bfb; /* Warna tombol */
    color: white;
    border: none;
    border-radius: 5px;
    font-size: 1.5rem;
    cursor: pointer;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.3);
    z-index: 1001;
    transition: transform 0.3s ease;
}

.menu-toggle:hover {
    transform: scale(1.1); /* Efek zoom saat tombol di-hover */
}

/* Styling navigasi */
.nav-link {
    display: block;
    padding: 1em;
    text-decoration: none;
    color: #dbe7f5;
    transition: color 0.2s ease;
}

.nav-link:hover {
    color: #ffffff; /* Perubahan warna saat di-hover */
}

/* Content */
.content {
    grid-area: content;
    padding: 20px;
}

.hero {
    text-align: center;
    padding: 20px;
    background: linear-gradient(135deg, #a8d0ff, #eff3fa);
    border-radius: 15px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

.hero img {
    width: 150px;
    border-radius: 50%;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.5);
}

.hero-content h1 {
    font-size: 2.5em;
    color: #1c64e3;
}

.hero-content h2 {
    font-size: 1.5em;
    color: #555;
}

.hero-content p  {
    font-size: 1.2em;
    margin: 15px 0;
}

.action-btn {
    display: inline-block;
    text-decoration: none;
    color: #ffffff;
    background: #457bff;
    padding: 0.8rem 2rem;
    border-radius: 50px;
    margin-top: 1rem;
    font-weight: bold;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.5);
    transition: background 0.3s ease;
}

.action-btn:hover {
    background: #154a9e;
}

/* Footer */
.footer {
    grid-area: footer;
    background: rgba(23, 34, 56, 0.9);
    padding: 1rem;
    text-align: center;
}

.footer ul {
    display: flex;
    justify-content: center;
    gap: 2rem;
    list-style: none;
    margin-bottom: 1rem;
}

.footer ul li a {
    text-decoration: none;
    color: #a3c4f3;
    font-size: 1rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
}

.footer ul li img {
    width: 40px;
}

.footer ul li img:hover {
    filter: none;
}

.footer p {
    font-size: 0.8rem;
    color: #b3c4e3;
}
/* ketikan */
#typing-text {
    font-size: 1.2em;
    margin: 15px 0;
    line-height: 1.6;
    color: #000000;
    display: inline-block;
    border-right: 2px solid #a3c4f3;
    animation: blink-cursor 0.7s steps(2) infinite;
}

@keyframes blink-cursor {
    50% {
        border-color: transparent;
    }
}

/* Carousel */
.carousel {
    position: relative;
    overflow: hidden;
    max-width: 800px;
    margin: 20px auto;
}

.here {
    text-align: center;
    padding: 20px;
    background: linear-gradient(135deg, #a8d0ff, #eff3fa);
    border-radius: 15px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}
.carousel-container {
    overflow: hidden;
    position: relative;
}

.here img {
    width: 70px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.5);
}
.carousel-track {
    display: flex;
    transition: transform 0.3s ease-in-out;
    will-change: transform;
}

.carousel-image {
    min-width: 100%;
    height: 100%;
    object-fit: cover;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.5);
    
}

.carousel-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background-color: rgba(0, 0, 0, 0.5);
    border: none;
    color: white;
    font-size: 2rem;
    padding: 10px 20px;
    cursor: pointer;
    z-index: 10;
    border-radius: 50%;
}

.carousel-btn:hover {
    background-color: rgba(0, 0, 0, 0.8);
}

.carousel-btn.prev {
    left: 10px;
}

.carousel-btn.next {
    right: 10px;
}

.trophy,
.top-langs,
.streak-stats,
.github-stats,
.profile-summary {
    margin-bottom: 20px;
    background: #2d2d2d;
    border-radius: 15px;
    padding: 20px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

.hari {
    text-align: center;
    padding: 20px;
    background: linear-gradient(135deg, #2d2d2d, #eff3fa);
    border-radius: 15px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

.hari img {
    max-width: 100%;
    height: auto;
    border-radius: 5px;
    margin-bottom: 20px;
}

.hari-content h1 {
    font-size: 2.5em;
    color: #1c64e3;
}

.hari-content h2 {
    font-size: 1.5em;
    color: #555;
}

.hari-content p  {
    font-size: 1.2em;
    margin: 15px 0;
}

.hati {
    text-align: center;
    padding: 20px;
    background: linear-gradient(135deg, #a8d0ff, #eff3fa);
    border-radius: 15px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

.hati img {
    border-radius: 30%;
    margin-bottom: 20px;
    width: 150px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.5);
}

.hati-content h1 {
    font-size: 2.5em;
    color: #1c64e3;
}

.hati-content h2 {
    font-size: 1.9em;
    color: #555;
}

.hati-content p  {
    font-size: 1.2em;
    margin: 15px 0;
}
.hati ul li a {
    text-decoration: none;
    color: #a3c4f3;
    font-size: 1rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
}
.hati ul li img {
    width: 40px;
    display: flex;
    flex-direction: row;
    justify-content: center;
}

.hati ul li img:hover {
    filter: none;
}

.hati p {
    font-size: 0.8rem;
    color: #b3c4e3;
}

.youtube {
    display: inline-block;
    text-decoration: none;
    color: #ffffff;
    background:linear-gradient(180deg, #ff0000, #cc0c0c);
    padding: 0.8rem 2rem;
    border-radius: 50px;
    margin-top: 1rem;
    font-weight: bold;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.5);
    transition: background 0.3s ease;
}
.github {
    display: inline-block;
    text-decoration: none;
    color: #ffffff;
    background:linear-gradient(45deg, #4078c0, #6e5494, #bd2c00, #c9510c, #6cc644, #fafafa);
    padding: 0.8rem 2rem;
    border-radius: 50px;
    margin-top: 1rem;
    font-weight: bold;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.5);
    transition: background 0.3s ease;
}
.instagram {
    display: inline-block;
    text-decoration: none;
    color: #ffffff;
    background:linear-gradient(45deg, #405de6, #5851db, #833ab4, #c13584, #e1306c, #fd1d1d);
    padding: 0.8rem 2rem;
    border-radius: 50px;
    margin-top: 1rem;
    font-weight: bold;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.5);
    transition: background 0.3s ease;
}
.bluesky {
    display: inline-block;
    text-decoration: none;
    color: #ffffff;
    background: linear-gradient(180deg,#1285fe 0,#0065cf);
    padding: 0.8rem 2rem;
    border-radius: 50px;
    margin-top: 1rem;
    font-weight: bold;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.5);
    transition: background 0.3s ease;
}
.threads {
    display: inline-block;
    text-decoration: none;
    color: #ffffff;
    background: linear-gradient(180deg, #010409, #2c2f35);
    padding: 0.8rem 2rem;
    border-radius: 50px;
    margin-top: 1rem;
    font-weight: bold;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.5);
    transition: background 0.3s ease;
}
.facebook {
    display: inline-block;
    text-decoration: none;
    color: #ffffff;
    background:linear-gradient(180deg, #2265f5, #0244d3);
    padding: 0.8rem 2rem;
    border-radius: 50px;
    margin-top: 1rem;
    font-weight: bold;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.5);
    transition: background 0.3s ease;
}
.x {
    display: inline-block;
    text-decoration: none;
    color: #ffffff;
    background:linear-gradient(45deg, #2960f5, #00ACEE, #36D8FF);
    padding: 0.8rem 2rem;
    border-radius: 50px;
    margin-top: 1rem;
    font-weight: bold;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.5);
    transition: background 0.3s ease;
}
.tiktok {
    display: inline-block;
    text-decoration: none;
    color: #ffffff;
    background: linear-gradient(180deg, #461010, #010409);
    padding: 0.8rem 2rem;
    border-radius: 50px;
    margin-top: 1rem;
    font-weight: bold;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.5);
    transition: background 0.3s ease;
}
.discord {
    display: inline-block;
    text-decoration: none;
    color: #ffffff;
    background:linear-gradient(-120deg, #7289da, #99aab5, #2c2f33, #23272a);
    padding: 0.8rem 2rem;
    border-radius: 50px;
    margin-top: 1rem;
    font-weight: bold;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.5);
    transition: background 0.3s ease;
}
.chat-section {
    margin-top: 2rem;
    padding: 1rem;
    background-color: #ffffff;
    border-radius: 10px;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
}

#chat-form {
    display: flex;
    gap: 10px;
    margin-bottom: 1rem;
}

#chat-form input[type="text"] {
    flex: 1;
    padding: 10px;
    border-radius: 5px;
    border: 1px solid #ccc;
}

#chat-form button {
    padding: 10px 15px;
    background-color: #007bff;
    color: white;
    border: none;
    border-radius: 5px;
    cursor: pointer;
}

#chat-form button:hover {
    background-color: #0056b3;
}

#chat-output {
    font-size: 14px;
    line-height: 1.6;
    max-height: 400px;
    overflow-y: auto;
}
/* Wadah untuk setiap slide */
.carousel-slide {
    /* GANTI min-width DENGAN flex */
    flex: 0 0 100%; 
    position: relative;
    overflow: hidden;
    aspect-ratio: 1 / 1; 
    background-color: #f0f0f0;
    border-radius: 15px; 
}

/* Memastikan gambar mengisi slide dengan benar */
.carousel-slide .carousel-image {
    width: 100%;
    height: 100%; /* <-- PENTING: Agar gambar mengisi seluruh tinggi wadah */
    display: block;
    object-fit: cover; /* <-- KUNCI KEDUA: Mencegah gambar penyok */
}
/* Styling untuk teks caption */
.carousel-caption {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(to top, rgba(0,0,0,0.8), rgba(0,0,0,0)); /* Gradien hitam transparan dari bawah */
    color: white;
    padding: 40px 20px 20px 20px; /* Padding atas lebih besar untuk gradien */
    text-align: left;
    transition: opacity 0.3s ease-in-out;
}

/* Styling untuk judul dan deskripsi di dalam caption */
.carousel-caption h3 {
    margin: 0 0 5px 0;
    font-size: 1.4rem;
    font-weight: bold;
    text-shadow: 1px 1px 3px rgba(0,0,0,0.7);
}

.carousel-caption p {
    margin: 0;
    font-size: 0.9rem;
    line-height: 1.4;
    text-shadow: 1px 1px 2px rgba(0,0,0,0.7);
}

/* OPSI: Jika ingin caption muncul hanya saat di-hover */
/* Hapus/komentari blok kode ini jika ingin caption selalu terlihat */
/*.carousel-caption {
    opacity: 0;
}
.carousel-slide:hover .carousel-caption {
    opacity: 1;
}*/
/* ========================================= */
/*         ATURAN RESPONSIVE (MEDIA QUERIES)   */
/* ========================================= */

/* Untuk Tablet dan Ponsel (Layar di bawah 768px) */
@media (max-width: 768px) {

    /* Ubah layout utama menjadi satu kolom */
    .container {
        grid-template-areas:
            "content"
            "footer";
        grid-template-columns: 1fr; /* Hanya satu kolom */
    }

    /* Sidebar akan tetap fixed, tidak mengubah layout utama */
    .sidebar {
        z-index: 2000; /* Pastikan sidebar di atas segalanya saat terbuka */
    }
    
    /* Tombol menu mungkin perlu sedikit penyesuaian posisi */
    .menu-toggle {
        right: -50px; /* Sedikit lebih jauh agar mudah disentuh */
        top: 15px;
    }

    /* Beri sedikit ruang agar konten tidak menempel di tepi */
    .content {
        padding: 15px;
    }

    /* Kecilkan ukuran font di bagian hero */
    .hero-content h1 {
        font-size: 2em;
    }
    .hero-content h2 {
        font-size: 1.2em;
    }
    .hero-content p {
        font-size: 1em;
    }

    /* Atur ulang footer agar ikon lebih rapi di layar kecil */
    .footer ul {
        flex-wrap: wrap; /* Izinkan ikon turun ke baris baru jika tidak muat */
        gap: 1.5rem;
    }
}

/* Untuk Ponsel Kecil (Layar di bawah 480px) */
@media (max-width: 480px) {

    /* Kecilkan tombol navigasi carousel agar tidak terlalu besar */
    .carousel-btn {
        font-size: 1.5rem;
        padding: 5px 10px;
    }
    
    /* Kecilkan ukuran font caption di carousel */
    .carousel-caption h3 {
        font-size: 1.1rem;
    }
    .carousel-caption p {
        font-size: 0.8rem;
    }
    
    /* Atur ulang tombol sosial media custom */
    .hati .buttons-container { /* Anda mungkin perlu menambahkan class ini di HTML */
        display: flex;
        flex-direction: column; /* Buat tombol jadi satu kolom */
        align-items: center;
        gap: 10px;
    }
    
    .hati .buttons-container a {
        width: 80%; /* Beri lebar yang konsisten */
        text-align: center;
    }
}