/* Pengaturan Awal */
:root {
    --bg-color: #222831;
    --main-text: #00ADB5;
    --desc-text: #FFFFFF;
}

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

html {
    scroll-behavior: smooth; /* Efek scroll halus saat menu diklik */
}

body {
    font-family: 'Inter', sans-serif;
    background-color: var(--bg-color);
    color: var(--desc-text);
    line-height: 1.6;
}

/* Font */
h1, h2, h3 {
    color: var(--main-text);
    margin-bottom: 1rem;
}

p {
    color: var(--desc-text);
    font-weight: 300;
}

/* Navbar */
.navbar {
    display: flex;
    justify-content: space-around;
    align-items: center;
    padding: 1.5rem 5%;
    background-color: rgba(34, 40, 49, 0.95); /* Sedikit transparan */
    position: fixed;
    width: 100%;
    top: 0;
    z-index: 1000;
    box-shadow: 0 2px 10px rgba(0,0,0,0.3);
}

.navbar .logo {
    margin-bottom: 0;
    font-size: 1.8rem;
    font-weight: 700;
}

.nav-links {
    display: flex;
    list-style: none;
    gap: 5rem;
}

.nav-links a {
    color: var(--desc-text);
    text-decoration: none;
    font-weight: 600;
    font-size: 1rem;
    transition: color 0.3s ease;
}

.nav-links a:hover {
    color: var(--main-text);
}

/* Styling Ikon Hamburger */
.menu-toggle {
    display: none;
    flex-direction: column;
    cursor: pointer;
    gap: 5px;
}

.menu-toggle .bar {
    height: 3px;
    width: 25px;
    background-color: var(--main-text); /* Memakai warna #00ADB5 */
    border-radius: 3px;
    transition: all 0.3s ease;
}

/* Styling Tiap Section */
.section {
    min-height: 100vh; /* Tiap section setinggi layar */
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 6rem 5% 2rem; /* Padding atas supaya tidak tertutup navbar */
    text-align: center;
}

.content {
    max-width: 800px;
}

.hero-content {
    display: flex;
    flex-direction: row;
    align-items: center; /* Menyejajarkan gambar dan teks secara vertikal */
    justify-content: center; /* Memusatkan grup gambar & teks di dalam container */
    gap: 20rem;
    max-width: 1200px; /* Lebarkan batas maksimal khusus desktop agar tidak sempit */
}

.hero-content span:last-child {
    text-align: center; /* Membuat teks di dalam span kedua rata kiri */
}

.child-container {
    display: flex;
    flex-direction: column; /* Menyusun item secara vertikal */
    gap: 8rem; /* Jarak antar item (About KO & Our History) */
    max-width: 1200px; /* Samakan dengan hero-content agar lebar */
}

.about-item {
    display: flex;
    align-items: center;
    gap: 5rem; /* Jarak antara gambar dan teks di dalam satu item */
}

.about-item h1 {
    text-align: center;
}

.member-content {
    max-width: 1200px; /* Lebarkan container member agar muat 3 kartu */
    width: 100%;
}

.member-grid {
    display: grid;
    grid-template-columns: 1fr; /* Default mobile: 1 kolom */
    gap: 2rem;
    margin-top: 4rem;
}

.member-card {
    background-color: #2a313c; /* Warna kartu sedikit berbeda dari background */
    padding: 2rem;
    border-radius: 15px;
    text-align: center;
    transition: transform 0.3s ease;
    position: relative; /* Agar overlay bisa diposisikan absolute */
    overflow: hidden; /* Agar overlay tidak keluar dari border-radius */
    cursor: pointer;
}

.member-card:hover {
    transform: translateY(-10px); /* Efek naik saat di-hover */
}

.member-card img {
    width: 150px;
    height: 150px;
    border-radius: 50%; /* Membuat foto jadi bulat */
    object-fit: cover;
    margin-bottom: 1rem;
    border: 4px solid var(--main-text); /* Border warna cyan */
}

.member-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(34, 40, 49, 0.85); /* Background gelap transparan */
    display: flex;
    justify-content: center;
    align-items: center;
    opacity: 0;
    transition: opacity 0.3s ease;
    border-radius: 15px;
}

.member-card:hover .member-overlay {
    opacity: 1;
}

.member-overlay span {
    color: var(--main-text);
    font-size: 1.2rem;
    font-weight: 700;
    transform: translateY(20px); /* Posisi awal teks sedikit di bawah */
    transition: transform 0.3s ease;
}

.member-card:hover .member-overlay span {
    transform: translateY(0); /* Teks naik ke posisi normal saat hover */
}

.gallery-content {
    max-width: 1200px;
    width: 100%;
    display: flex;
    flex-direction: column; /* Container utama vertikal */
    gap: 6rem; /* Jarak antara bagian Project dan Gallery */
}

.gallery-subsection {
    width: 100%;
    display: flex;
    flex-direction: column;
    gap: 2rem;
}

.gallery-row {
    display: flex;
    flex-direction: row; /* Isi konten horizontal */
    gap: 2rem;
    flex-wrap: wrap; /* Agar responsif di layar kecil */
    justify-content: center;
}

.gallery-item {
    flex: 1 1 300px; /* Lebar fleksibel, minimal 300px */
    background-color: #2a313c;
    padding: 0; /* Hapus padding agar gambar full */
    border-radius: 15px;
    text-align: center;
    transition: transform 0.3s ease;
    position: relative; /* Untuk overlay */
    overflow: hidden; /* Agar gambar tidak keluar border */
    height: 300px; /* Tinggi tetap untuk kartu */
}

.gallery-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 0;
    margin-bottom: 0;
    transition: transform 0.5s ease;
}

.gallery-item:hover img {
    transform: scale(1.1); /* Efek zoom saat hover */
}

.gallery-item .overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(34, 40, 49, 0.9); /* Background semi-transparan */
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    opacity: 0; /* Sembunyikan default */
    transition: opacity 0.3s ease;
    padding: 1rem;
}

.gallery-item:hover .overlay {
    opacity: 1; /* Munculkan saat hover */
}

.section h2 {
    font-size: 3.5rem;
    font-weight: 700;
}

.section p {
    font-size: 1.1rem;
}


#about, #gallery {
    background-color: #2a313c;
}

/* Footer */
footer {
    padding: 2rem 5%;
    background-color: #1a1e24;
    color: var(--desc-text);
}

.footer-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    max-width: 1200px;
    margin: 0 auto;
}

.footer-left, .footer-center, .footer-right {
    flex: 1;
}

.footer-left {
    display: flex;
    gap: 1.5rem;
}

.footer-left a {
    color: var(--desc-text);
    text-decoration: none;
    font-weight: 600;
    transition: color 0.3s ease;
}

.footer-left a:hover {
    color: var(--main-text);
}

.footer-center {
    justify-content: center;
    align-items: center;
    text-align: center;
}

.footer-center p {
    color: var(--desc-text);
    text-decoration: none;
    font-weight: 500;
}

.footer-right {
    display: flex;
    justify-content: flex-end;
}

.footer-right .logo {
    margin-bottom: 0;
    font-size: 1.8rem;
}

/* Penyesuaian Layout Desktop */
@media (min-width: 769px) {
    #about, #member, #gallery {
        align-items: flex-start;
        padding-top: 10rem;
    }

    .member-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

/* Responsif HP dan Tablet */
@media (max-width: 768px) {
    .navbar {
        flex-direction: row; 
        justify-content: space-between;
        padding: 1.5rem 5%;
    }

    .menu-toggle {
        display: flex;
    }

    .nav-links {
        position: absolute;
        top: 70px;
        left: -100%;
        flex-direction: column;
        background-color: rgba(34, 40, 49, 0.98);
        width: 100%;
        text-align: center;
        transition: 0.3s ease;
        padding: 2rem 0;
        box-shadow: 0 10px 10px rgba(0,0,0,0.3);
    }

    .section h2 {
        font-size: 2rem;
    }

    .section p {
        font-size: 1rem;
    }

    .hero-content {
        flex-direction: column;
        gap: 3rem;
    }

    .about-container {
        gap: 4rem;
    }
    .about-item, .about-item:nth-child(even) {
        flex-direction: column;
    }

    .nav-links.active {
        left: 0;
    }

    .nav-links li {
        margin: 1.5rem 0;
    }

    .footer-container {
        flex-direction: column;
        gap: 1.5rem;
        text-align: center;
    }

    .footer-left, .footer-right {
        justify-content: center;
    }
}