<!DOCTYPE html>
<html lang="id">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Profil Kelompok | Polines</title>
    
    <link href="https://cdn.jsdelivr.net/npm/bootstrap@5.2.3/dist/css/bootstrap.min.css" rel="stylesheet">
    <link href="https://fonts.googleapis.com/css2?family=Plus+Jakarta+Sans:wght@400;600;800&display=swap" rel="stylesheet">
    <script src="https://use.fontawesome.com/releases/v6.3.0/js/all.js" crossorigin="anonymous"></script>

    <style>
        /* Smooth Scroll biar pas pindah gak kaget */
        html {
            scroll-behavior: smooth;
        }

        :root {
            --primary-pink: #ff4d94;
            --glass-bg: rgba(255, 255, 255, 0.07);
            --glass-border: rgba(255, 255, 255, 0.15);
        }

        body {
            background: linear-gradient(rgba(30, 0, 15, 0.8), rgba(20, 0, 10, 0.9)), 
                        url('assets/img/gkt.jpeg') no-repeat center center fixed;
            background-size: cover;
            color: white;
            font-family: 'Plus Jakarta Sans', sans-serif;
            margin: 0;
            overflow-x: hidden;
        }

        /* --- ANIMASI REVEAL SAAT SCROLL --- */
        .reveal {
            opacity: 0;
            transform: translateY(30px);
            transition: all 0.8s cubic-bezier(0.175, 0.885, 0.32, 1.275);
        }

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

        section {
            padding: 20px 0; 
        }

        .header-text {
            text-align: center;
            margin-bottom: 30px;
            padding-top: 60px;
        }

        .badge-kelompok {
            background: var(--primary-pink);
            padding: 8px 20px;
            border-radius: 50px;
            font-size: 11px;
            font-weight: 800;
            letter-spacing: 2px;
            text-transform: uppercase;
            box-shadow: 0 0 15px rgba(255, 77, 148, 0.5);
            display: inline-block;
        }

        /* --- KARTU PROFIL UTAMA (Sarah & Tiara) --- */
        .profile-card {
            background: var(--glass-bg);
            backdrop-filter: blur(15px);
            -webkit-backdrop-filter: blur(15px);
            border-radius: 24px;
            border: 1px solid var(--glass-border);
            padding: 40px 30px;
            text-align: center;
            transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
            cursor: pointer;
            position: relative;
        }

        .profile-card:hover {
            transform: translateY(-8px) scale(1.03);
            border-color: var(--primary-pink);
            background: rgba(255, 255, 255, 0.1);
        }

        .profile-img {
            width: 140px; height: 140px;
            border-radius: 50%;
            border: 5px solid rgba(255,255,255,0.1);
            object-fit: cover;
            margin: 0 auto 20px auto; 
            display: block;
        }

        .member-name { font-weight: 800; font-size: 1.4rem; margin-bottom: 8px; }

        .role-badge {
            background: rgba(255, 77, 148, 0.15);
            color: #ff85b3;
            padding: 6px 18px;
            border-radius: 12px;
            font-size: 12px;
            font-weight: 700;
            border: 1px solid rgba(255, 77, 148, 0.3);
            display: inline-block;
        }

        /* --- SECTION ABOUT US GABUNGAN --- */
        .about-us-container {
            display: flex;
            justify-content: center; 
            padding: 100px 15px; /* Kasih padding biar gak mepet banget pas di-scroll */
        }

        .about-us-card {
            background: rgba(255, 255, 255, 0.05);
            backdrop-filter: blur(20px);
            border-radius: 40px;
            border: 1px solid var(--glass-border);
            padding: 50px 40px;
            width: 100%;
            max-width: 850px;
            text-align: center;
            cursor: pointer;
            transition: all 0.5s cubic-bezier(0.175, 0.885, 0.32, 1.275);
            position: relative;
            overflow: hidden;
        }

        .about-us-card:hover {
            transform: translateY(-12px) scale(1.02);
            border-color: var(--primary-pink);
            box-shadow: 0 25px 50px rgba(255, 77, 148, 0.2);
            background: rgba(255, 255, 255, 0.1);
        }

        .single-bubble {
            width: 220px;
            height: 220px;
            border-radius: 50%;
            border: 8px solid white;
            object-fit: cover;
            margin: 0 auto 25px auto;
            box-shadow: 0 15px 35px rgba(0,0,0,0.5);
            display: block;
            transition: 0.5s ease;
        }

        .about-us-card:hover .single-bubble {
            border-color: var(--primary-pink);
            transform: rotate(-3deg) scale(1.05);
        }

        .btn-back {
            position: fixed;
            top: 30px; left: 30px;
            color: #cbd5e1;
            text-decoration: none;
            z-index: 100;
            padding: 10px 20px;
            background: rgba(255,255,255,0.05);
            border-radius: 12px;
            backdrop-filter: blur(5px);
        }

        @media (max-width: 768px) {
            .single-bubble { width: 160px; height: 160px; }
            .about-us-card { padding: 30px 20px; }
        }
    </style>
</head>
<body>

<audio id="bg-music" loop>
    <source src="assets/img/perunggu.mp3" type="audio/mpeg">
</audio>

<a href="index.php" class="btn-back"><i class="fas fa-arrow-left me-2"></i> Kembali ke Login</a>

<section>
    <div class="container">
        <div class="header-text">
            <span class="badge-kelompok">Our Team</span>
            <h1 class="display-5 fw-extrabold mt-3">Profil Kelompok</h1>
            <p class="text-white-50">Proyek Pemrograman Web & Database — Politeknik Negeri Semarang</p>
        </div>

        <div class="row justify-content-center g-4">
            <div class="col-md-5 col-lg-4">
                <div class="profile-card" onclick="window.location.href='sarah.php'">
                    <img src="assets/img/sarah.jpeg" alt="SARAH" class="profile-img">
                    <h3 class="member-name">SARAH AYU AGUSTINA</h3>
                    <div class="role-badge">4.31.24.0.20</div>
                </div>
            </div>

            <div class="col-md-5 col-lg-4">
                <div class="profile-card" onclick="window.location.href='tiara.php'">
                    <img src="assets/img/ara.jpeg" alt="TIARA" class="profile-img">
                    <h3 class="member-name">TIARA NUR FADILAH</h3>
                    <div class="role-badge">4.31.24.0.21</div>
                </div>
            </div>
        </div>
    </div>
</section>

<section class="about-us-container" id="about-us">
    <div class="container reveal">
        <div class="row justify-content-center">
            <div class="col-12 d-flex justify-content-center">
                <div class="about-us-card" onclick="this.style.transform='scale(0.98)'">
                    <span class="badge-kelompok mb-4">About Us</span>
                    <img src="assets/img/ber2.jpeg" class="single-bubble" alt="Sarah dan Tiara">
                    <div>
                        <h4 class="fw-bold">SARAH AYU AGUSTINA & TIARA NUR FADILAH</h4>
                        <p class="text-white-50 px-md-5 mb-0">Kami berkolaborasi untuk menciptakan sebuah sistem yang tidak hanya fungsional secara database, tetapi juga memiliki antarmuka yang modern dan nyaman digunakan.</p>
                    </div>
                </div>
            </div>
        </div>
    </div>
</section>

<script>
    // --- SCRIPT MUSIK BIAR NYAMBUNG (SAMA DENGAN INDEX) ---
    
    const audio = document.getElementById("bg-music");

    const playMusic = () => {
        audio.play().then(() => {
            sessionStorage.setItem("musicStatus", "playing");
        }).catch(error => {
            console.log("Menunggu interaksi...");
        });
    };

    // Cek pas loading: Kalau di index tadi sudah nyala, di sini otomatis nyala
    window.addEventListener('load', () => {
        if (sessionStorage.getItem("musicStatus") === "playing") {
            audio.play();
        }
        reveal(); // Jalankan fungsi reveal kamu
    });

    // Jaga-jaga kalau user klik di halaman profile, musik tetep aktif
    window.addEventListener('click', playMusic, { once: true });
    window.addEventListener('touchstart', playMusic, { once: true });


    // --- FUNGSI REVEAL ASLI KAMU ---
    function reveal() {
        var reveals = document.querySelectorAll(".reveal");
        for (var i = 0; i < reveals.length; i++) {
            var windowHeight = window.innerHeight;
            var elementTop = reveals[i].getBoundingClientRect().top;
            var elementVisible = 100;

            if (window.location.hash === "#about-us") {
                reveals[i].classList.add("active");
            }

            if (elementTop < windowHeight - elementVisible) {
                reveals[i].classList.add("active");
            }
        }
    }

    window.addEventListener("scroll", reveal);
    setTimeout(reveal, 500);
</script>

<script src="https://cdn.jsdelivr.net/npm/bootstrap@5.2.3/dist/js/bootstrap.bundle.min.js"></script>

</body>
</html>