/* ==========================================================================
   1. CORE VARIABLES & DEFAULT STYLES (TEMA BLUE OCEAN)
   ========================================================================== */
:root {
    --deep-ocean: #04152d;       /* Biru laut dalam untuk background utama */
    --aqua-marine: #0ea5e9;      /* Biru aqua cerah untuk aksen & penanda */
    --sea-foam: #f0fdfa;         /* Putih buih ombak lembut untuk teks terang */
    --coral-gold: #f59e0b;       /* Emas terumbu karang untuk border premium */
    --abyss: #020c1b;            /* Biru gelap pekat (palung laut) */
}

/* Mengunci html dan body agar tidak ada elemen yang bocor ke kanan */
html, body {
    max-width: 480px;             /* Membatasi lebar maksimal halaman (standar layar HP) */
    margin: 0 auto;               /* Membuat body otomatis berada di tengah layar PC/Monitor */
    background-color: var(--deep-ocean); 
    overflow-x: hidden;           /* KUNCI UTAMA: Menghilangkan scroll ke kanan */
    position: relative;
}

body { 
    font-family: 'Plus Jakarta Sans', sans-serif; 
    color: #e2e8f0;               /* Warna teks utama perak kebiruan lembut */
    min-height: 100vh;            /* Memastikan background memenuhi tinggi layar */
    box-shadow: 0 0 50px rgba(14, 165, 233, 0.15); /* Bayangan aura aqua di kanan-kiri body saat di PC */
}

.font-serif { 
    font-family: 'Playfair Display', serif; 
}

.font-cinzel { 
    font-family: 'Cinzel', serif; 
}

/* Custom Scrollbar Bertema Samudra */
::-webkit-scrollbar,
.custom-scrollbar::-webkit-scrollbar { 
    width: 5px; 
}

::-webkit-scrollbar-track,
.custom-scrollbar::-webkit-scrollbar-track { 
    background: var(--abyss); 
}

::-webkit-scrollbar-thumb,
.custom-scrollbar::-webkit-scrollbar-thumb { 
    background: var(--aqua-marine); 
    border-radius: 10px; 
}

/* ==========================================================================
   2. BLUE OCEAN ELEMENTS & LAYOUTS
   ========================================================================== */
.hero-bg { 
    height: 100vh; 
    position: relative; 
    overflow: hidden; 
    display: flex; 
    align-items: center; 
    justify-content: center; 
}

#parallax-bg {
    position: absolute; 
    top: -10%; 
    left: -10%; 
    width: 120%; 
    height: 120%;
    background-size: cover; 
    background-position: center; 
    z-index: -1;
}

/* Underwater Bubbles Effect (Menggantikan Efek Rasi Bintang) */
#star-container { 
    position: fixed; 
    inset: 0; 
    pointer-events: none; 
    z-index: 50; 
}

/* Kelas .star ditransformasikan menjadi Gelembung Udara Laut yang naik ke atas */
.star { 
    position: absolute; 
    background: rgba(14, 165, 233, 0.2); 
    border: 1px solid rgba(255, 255, 255, 0.4);
    border-radius: 50%; 
    animation: bubble-up var(--duration) ease-in-out infinite; 
}

@keyframes bubble-up { 
    0% { 
        transform: translateY(105vh) scale(0.3) translateX(0);
        opacity: 0;
    } 
    50% {
        opacity: 0.7;
        transform: translateY(50vh) scale(1) translateX(20px);
    }
    100% { 
        transform: translateY(-5vh) scale(0.5) translateX(-20px); 
        opacity: 0;
    } 
}

/* Ocean Wave Ornaments (Dekorasi Sudut Ornamen Laut) */
.gold-corner { 
    position: absolute; 
    width: 250px; 
    pointer-events: none; 
    z-index: 20; 
    opacity: 0.5; 
    filter: drop-shadow(0 0 10px rgba(14, 165, 233, 0.3)); 
}

/* Card & Glassmorphism Base (Efek Kaca Transparan Air Laut) */
.glass-card { 
    background: rgba(2, 12, 27, 0.6); /* Transparansi gelap misterius palung laut */
    backdrop-filter: blur(12px); 
    -webkit-backdrop-filter: blur(12px); 
    border: 1px solid rgba(14, 165, 233, 0.2); 
    border-radius: 3rem; 
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.gold-border { 
    border: 1px solid var(--coral-gold); /* Kerangka pembatas menggunakan warna emas terumbu karang */
    box-shadow: inset 0 0 20px rgba(14, 165, 233, 0.1);
}

/* Core Animations (Efek Arus Mengambang Lembut) */
@keyframes floating { 
    0%, 100% { 
        transform: translateY(0) translateX(0) rotate(0deg); 
    } 
    50% { 
        transform: translateY(-12px) translateX(5px) rotate(1deg); 
    } 
}

.animate-celestial { 
    animation: floating 7s ease-in-out infinite; 
}

/* Penyesuaian Pewarnaan Komponen Utama agar Harmonis */
.text-white {
    color: var(--sea-foam) !important;
}
.text-amber-400, .text-amber-500, .text-amber-100 {
    color: var(--aqua-marine) !important; /* Mengubah teks sorotan menjadi warna aqua laut */
}
.bg-amber-500 {
    background-color: var(--aqua-marine) !important; /* Tombol utama menjadi warna aqua kelautan */
    color: var(--abyss) !important;
}
.from-amber-600.to-amber-400 {
    background: linear-gradient(to right, #0284c7, var(--aqua-marine)) !important;
    color: var(--sea-foam) !important;
}
.border-amber-500, .border-amber-500\/30 {
    border-color: rgba(14, 165, 233, 0.3) !important;
}

/* ==========================================================================
   3. FIXED ELEMENTS ADJUSTMENT (OVERLAY & MUSIC BUTTON)
   ========================================================================== */
#overlay {
    max-width: 480px;
    left: 50%;
    transform: translateX(-50%);
    width: 100%;
    background-color: var(--abyss) !important;
}

/* TOMBOL MUSIK: Terkunci presisi di dalam frame samudra */
#music-btn {
    position: fixed;
    bottom: 32px;                  
    left: calc(50% - 215px);       
    z-index: 999;                  
    width: 50px;                   
    height: 50px;
    background-color: var(--aqua-marine) !important;
    color: var(--abyss) !important;
    border: 2px solid rgba(255, 255, 255, 0.3);
}

/* ==========================================================================
   4. MOBILE RESPONSIVE OPTIMIZATION (MEDIA QUERY LAYAR HP)
   ========================================================================== */
@media (max-width: 767px) {
    html, body {
        position: relative;
        overflow-x: hidden !important;
    }

    #overlay {
        left: 0;
        transform: none;
        max-width: 100%;
    }
    
    #music-btn {
        left: 20px !important;     
        bottom: 24px !important;    
    }

    h1, .font-serif {
        line-height: 1.25 !important;
    }
    
    /* Mengubah sistem garis alur timeline */
    .relative.border-l {
        margin-left: 20px !important; 
        left: 0 !important;
        border-color: rgba(14, 165, 233, 0.25) !important;
    }

    .relative.border-l .absolute {
        left: -6px !important; 
        margin-left: 0 !important;
        background-color: var(--aqua-marine) !important;
        box-shadow: 0 0 12px var(--aqua-marine) !important;
    }

    .relative.flex-col {
        width: 100% !important;
        padding-left: 0 !important;
        align-items: flex-start !important;
    }

    /* Penyesuaian kotak kartu cerita di layar HP */
    .glass-card {
        padding: 20px !important;       
        margin-left: 24px !important;     
        margin-right: 12px !important;    
        border-radius: 1.5rem !important; 
        text-align: left !important;      
        width: calc(100% - 36px) !important; 
        box-sizing: border-box !important;   
    }

    .glass-card span.font-cinzel {
        font-size: 1rem !important;
        color: var(--aqua-marine) !important;
    }
    
    .glass-card h4.font-serif {
        font-size: 1.25rem !important;
        margin-bottom: 0.5rem !important;
        color: var(--sea-foam) !important;
    }

    .glass-card p {
        font-size: 0.85rem !important;
        line-height: 1.6 !important;
        color: #cbd5e1 !important;
    }

    .space-y-16 > :not([hidden]) ~ :not([hidden]) {
        margin-top: 2rem !important;
    }
    
    .gold-corner {
        width: 140px !important;
    }
}