/* assets/css/main.css */

.about-coin-container {
    position: absolute;
    top: 50%;
    right: -30%; /* Digeser ke kiri 20% */
    transform: translateY(-50%);
    width: 350px; /* Ukuran diperbesar */
    height: auto;
    z-index: 5; /* Dimajukan di depan card (z-index: 1) */
    opacity: 0;
    pointer-events: none;
}

.about-coin-gif {
    filter: drop-shadow(0 0 14px rgba(255, 255, 255, 0.56)) drop-shadow(0 0 28px rgba(255, 255, 255, 0.35));
    width: 100%;
    height: auto;
}

/* Slide In Animation */
.about-coin-container.start-animation {
    animation: slide-in-right-bounce 1.2s cubic-bezier(0.68, -0.55, 0.265, 1.55) forwards;
}

@keyframes slide-in-right-bounce {
    0% {
        opacity: 0;
        transform: translateY(-50%) translateX(300px);
    }
    60% {
        opacity: 1;
        transform: translateY(-50%) translateX(-20px);
    }
    80% {
        transform: translateY(-50%) translateX(10px);
    }
    100% {
        opacity: 1;
        transform: translateY(-50%) translateX(0);
    }
}

/* Slide Out Animation */
.about-coin-container.start-exit-animation {
    animation: slide-out-right-fade 0.6s ease-out forwards;
}

@keyframes slide-out-right-fade {
    from {
        opacity: 1;
        transform: translateY(-50%) translateX(0);
    }
    to {
        opacity: 0;
        transform: translateY(-50%) translateX(300px);
    }
}

/* Animasi elemen keluar setelah panning selesai */
.about-coin-container.exit-after-panning {
    animation: coin-exit-right 1s ease-in-out forwards !important;
}

@keyframes coin-exit-right {
    from {
        transform: translateY(-50%) translateX(0);
    }

    to {
        transform: translateY(-50%) translateX(150%);
    }
}

.about-window-card.exit-after-panning {
    animation: window-exit-up 1s ease-in-out forwards !important;
}

@keyframes window-exit-up {
    from {
        transform: translateY(0);
    }

    to {
        transform: translateY(-100vh);
    }
}
/* Responsive */
@media (max-width: 1024px) {
    .about-coin-container {
        display: none; /* Hide on smaller screens to avoid clutter */
    }
}

/* 3D Model Canvas Styling */
#glb-container {
    position: absolute;
    left: -21.6%;
    /* Diperbarui */
    top: 83.6%;
    /* Diperbarui */
    transform: translateY(-50%);
    width: 1200px;
    /* Diperbarui */
    height: 1200px;
    /* Diubah dari 150vh ke 1200px */
    /* Kanvas diperpanjang ke bawah */
    z-index: 5;
    background: transparent;
    /* Hapus background hitam */
    pointer-events: none;
    /* Menonaktifkan semua event mouse */
    opacity: 0;
    /* Sembunyikan secara default */
    transform: translateY(-50%) translateX(-100%);
    /* Geser ke kiri */
    transition: opacity 0.8s ease-out, transform 0.8s ease-out;
    /* Transisi untuk AOS */
}

#glb-container.start-animation {
    opacity: 1;
    transform: translateY(-50%) translateX(0);
}

/* Exit animation untuk glb-container - geser ke kiri */
#glb-container.exit-after-panning {
    /* Menggunakan transition untuk translateX agar efek scrolling 3D masih berfungsi */
    /* Transform CSS hanya menggeser container, tidak mengganggu rotasi/scale Three.js */
    transition: transform 1s ease-in-out !important;
    /* Pastikan translateY tetap ada dan tambahkan translateX untuk exit */
    transform: translateY(-50%) translateX(-100%) !important;
    /* Catatan: Transform CSS ini hanya untuk posisi container */
    /* Rotasi dan scale 3D di Three.js tetap berfungsi karena itu transform berbeda (di canvas) */
    /* Efek scrolling 3D tetap berfungsi karena JavaScript masih update threeJSModel.rotation dan scale */
}
#glb-container:active {
    cursor: default;
}

#glb-canvas {
    width: 100%;
    height: 100%;
    display: block;
}

/* Section 3 - Anatomy */
#section-three {
    z-index: 3;
    min-height: 100vh;
    width: 100%;
    background: transparent;
    /* Diubah */
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 1;
        visibility: visible;
        /* Section 3 terlihat secara default */
    }
    
    /* Section 3 tersembunyi setelah exit animation - tanpa fade */
    #section-three.hide-after-exit {
        opacity: 1;
        visibility: hidden;
        pointer-events: none;
}

.section-three-overlay {
    position: relative;
    width: 100%;
    height: 100%;
    background: transparent;
    /* Diubah */
    backdrop-filter: none;
    /* Dihapus */
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 3rem 1.5rem;
}

#anatomy-container {
    cursor: default;
        /* Mengubah kursor */
    border-radius: 1.5rem;
    background: transparent;
    /* Diubah */
    backdrop-filter: none;
    /* Dihapus */
    border: none;
    /* Dihapus */
}

#anatomy-container:active {
    cursor: default;
        /* Mengubah kursor */
}

#anatomy-canvas {
    width: 100%;
    height: 100%;
    display: block;
}
/* AOS-style animations for Anatomy section */
#anatomy-container,
.anatomy-details-container {
    opacity: 0;
    /* Sembunyikan secara default */
    /* Transisi diganti dengan animasi */
}

/* Pastikan window anatomi memiliki blur effect */
.anatomy-details-container .water-card {
    -webkit-backdrop-filter: blur(10px) saturate(180%) !important;
    backdrop-filter: blur(10px) saturate(180%) !important;
}
#anatomy-container.in-view {
    animation: slide-in-left-bounce 1.2s cubic-bezier(0.68, -0.55, 0.265, 1.55) forwards;
}

.anatomy-details-container.in-view {
    animation: slide-in-right-bounce 1.2s cubic-bezier(0.68, -0.55, 0.265, 1.55) forwards;
}

@keyframes slide-in-left-bounce {
    0% {
        opacity: 0;
        transform: translateX(-100%);
    }

    60% {
        opacity: 1;
        transform: translateX(25px);
        /* Overshoot */
    }

    100% {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes slide-in-right-bounce {
    0% {
        opacity: 0;
        transform: translateX(100%);
    }

    60% {
        opacity: 1;
        transform: translateX(-25px);
        /* Overshoot */
    }

    100% {
        opacity: 1;
        transform: translateX(0);
    }
}

/* Exit animations untuk section 3 ketika section 4 masuk viewport */
#anatomy-container.exit-after-section-four {
    animation: anatomy-exit-left-3d 1s ease-in-out forwards;
    transform-style: preserve-3d;
}

.anatomy-details-container.exit-after-section-four {
    animation: window-exit-right-3d 1s ease-in-out forwards;
    transform-style: preserve-3d;
}

@keyframes anatomy-exit-left-3d {
    0% {
        opacity: 1;
        transform: translateX(0) perspective(1000px) rotateY(0deg);
        visibility: visible;
    }

    100% {
        opacity: 1;
        transform: translateX(-150%) perspective(1000px) rotateY(-45deg);
        visibility: hidden;
        pointer-events: none;
    }
}

@keyframes window-exit-right-3d {
    0% {
        opacity: 1;
        transform: translateX(0) perspective(1000px) rotateY(0deg);
        visibility: visible;
    }

    100% {
        opacity: 1;
        transform: translateX(150%) perspective(1000px) rotateY(45deg);
        visibility: hidden;
        pointer-events: none;
    }
}

/* Hero Background Transition - White Fade */
#hero-white-fade {
    opacity: 0;
    transition: opacity 0.5s ease-in-out;
}

#hero-white-fade.fade-in {
    opacity: 1;
}

#hero-bg-new {
    opacity: 0;
    transition: opacity 0.5s ease-in-out 0.25s;
    /* Delay 0.25s untuk muncul setelah white fade mencapai puncak */
}

#hero-bg-new.fade-in {
    opacity: 1;
}

#hero-white-fade.fade-out {
    opacity: 0;
    transition: opacity 0.5s ease-in-out 0.25s;
    /* Fade out setelah bg3.png muncul */
}
/* Responsive */
@media (max-width: 1280px) {

    /* Disembunyikan di layar yang lebih kecil */
    .about-coin-container,
    #glb-container {
        display: none;
    }
}
/* Section 4 - Join The Gang */
#section-four {
    position: relative;
    /* min-height dihapus agar section 4 hanya setinggi kontennya (carousel) */
    width: 100%;
    /* background-image dihapus karena bg3.png sudah digunakan di hero section */
        display: block;
        /* display diubah dari flex ke block karena tidak perlu flex centering lagi */
    z-index: 0;
    /* z-index lebih rendah dari semua sticky sections agar tidak mengganggu */
    /* Tidak menggunakan sticky positioning agar tidak mengganggu section 2 */
    clear: both;
    /* Memastikan section 4 berada di bawah sticky sections */
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.8s ease-out 0.3s, visibility 0.8s ease-out 0.3s;
    /* Delay 0.3s untuk muncul setelah section 2 fade out */
    overflow: visible;
}

/* Section 4 muncul setelah section 2 hilang */
#section-four.show-after-section-two {
    opacity: 1;
    visibility: visible;
}

/* bg3overlay.png dihapus karena membuat section 4 terlalu tinggi */

/* 3D Carousel Container - Di tengah halaman */
.carousel-3d-container {
    position: relative;
    width: 100%;
    max-width: 70vw;
    margin: 0 auto;
    padding: 4rem 2rem 1rem 2rem;
    z-index: 10;
    opacity: 1;
    visibility: visible;
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 600px;
}

.carousel-3d-wrapper {
    position: relative;
    width: 100%;
    height: 550px;
    perspective: 1500px;
    perspective-origin: center center;
    overflow: visible;
    margin: 0 auto;
}

.carousel-3d-track {
    position: relative;
    width: 100%;
    height: 100%;
    transform-style: preserve-3d;
    transition: transform 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

.carousel-3d-card {
    position: absolute;
    width: 350px;
        height: 450px;
    left: 50%;
    top: 50%;
        margin-left: -175px;
        margin-top: -225px;
        transform-style: preserve-3d;
        transition: transform 0.6s cubic-bezier(0.4, 0, 0.2, 1), opacity 0.6s ease, visibility 0.6s ease;
        cursor: pointer;
        pointer-events: auto;
    visibility: visible;
    /* Optimasi untuk seamless transition */
        will-change: transform, opacity;
        backface-visibility: hidden;
        -webkit-backface-visibility: hidden;
}
                                /* Window Card Style untuk setiap card */
                                .carousel-card-window {
                                    width: 100%;
                    height: 100%;
                        padding: 1.5rem;
                        display: flex;
                        flex-direction: column;
                        overflow: hidden;
                    }
                                .carousel-card-image-container {
                                    position: relative;
                                    width: 100%;
                                    height: 100%;
                                    flex: 1;
                                    overflow: hidden;
                                    border-radius: 1rem;
                                }
                                .carousel-card-image {
                                    width: 100%;
                                    height: 100%;
                                    object-fit: cover;
                                    display: block;
                                }
                /* Cover Flow Effect - Center Card */
                .carousel-3d-card.active {
                    transform: translateX(0) translateZ(0) rotateY(0deg) scale(1);
                    z-index: 3;
                    opacity: 1;
                }
.carousel-3d-card.active .carousel-3d-card-inner {
    box-shadow:
        0 30px 80px rgba(0, 0, 0, 0.4),
        0 0 0 2px rgba(255, 255, 255, 0.2);
}
/* Left Side Cards - Rotate keluar (hanya prev-1 yang tampil) */
.carousel-3d-card.prev-1 {
    transform: translateX(-350px) translateZ(-200px) rotateY(25deg) scale(0.85);
    z-index: 2;
    opacity: 0.8;
    visibility: visible;
}
/* Right Side Cards - Rotate keluar (hanya next-1 yang tampil) */
.carousel-3d-card.next-1 {
    transform: translateX(350px) translateZ(-200px) rotateY(-25deg) scale(0.85);
    z-index: 2;
    opacity: 0.8;
    visibility: visible;
}

/* Navigation Buttons */
.carousel-nav-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background: linear-gradient(135deg,
            rgba(255, 255, 255, 0.2) 0%,
            rgba(255, 255, 255, 0.1) 100%);
    -webkit-backdrop-filter: blur(10px);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.3);
    color: white;
    cursor: pointer;
    z-index: 10;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    box-shadow:
        0 4px 15px rgba(0, 0, 0, 0.2),
        inset 0 1px 0 rgba(255, 255, 255, 0.3);
}

.carousel-nav-btn:hover {
    background: linear-gradient(135deg,
            rgba(255, 255, 255, 0.3) 0%,
            rgba(255, 255, 255, 0.2) 100%);
    transform: translateY(-50%) scale(1.1);
    box-shadow:
        0 6px 20px rgba(0, 0, 0, 0.3),
        inset 0 1px 0 rgba(255, 255, 255, 0.4);
}

.carousel-nav-btn:active {
    transform: translateY(-50%) scale(0.95);
}

.carousel-prev {
    left: 20px;
}

.carousel-next {
    right: 20px;
}
.carousel-nav-btn svg {
    width: 24px;
    height: 24px;
    stroke-width: 2.5;
}

/* Social Box Container */
.social-box-container {
    position: relative;
    width: fit-content;
    max-width: 70vw;
    margin: 0 auto 2rem;
    z-index: 10;
    opacity: 1;
    visibility: visible;
    display: block;
}

.social-box-card {
    width: fit-content;
    margin: 0 auto;
    padding: 4rem 2rem 2rem 2rem;
}

/* Title bar untuk social box - tengahkan text dan hilangkan controls */
.social-title-bar {
    justify-content: center !important;
    padding: 0 !important;
    margin-top: 0.5rem;
}

.social-title-bar .water-controls {
    display: none !important;
}

.social-pagination {
    margin: 0 auto;
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    width: 80px !important;
    height: 32px !important;
    border-radius: 16px !important;
    margin-bottom: 0 !important;
    transition: none !important;
}

.social-pagination .water-pagination-text {
    font-size: 1rem !important;
    font-weight: 700 !important;
    letter-spacing: 0.08em !important;
    margin-bottom: 0 !important;
}

/* Hilangkan efek hover untuk social pagination */
.social-pagination:hover {
    transform: translateX(-50%) scale(1) !important;
    box-shadow: 
        inset 0 0 20px rgba(255, 255, 255, 0.2),
        inset -3px -3px 10px rgba(0, 0, 0, 0.15),
        0 2px 10px rgba(0, 0, 0, 0.1),
        0 0 0 1px rgba(255, 255, 255, 0.2),
        0 0 20px rgba(173, 216, 230, 0.2) !important;
}

.social-links-container {
    display: flex;
    flex-direction: row;
    justify-content: center;
    align-items: center;
    gap: 1.5rem;
    margin-top: 0.5rem;
}

.social-link {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1.5rem;
    width: 90px;
    height: 90px;
    background: linear-gradient(135deg,
            rgba(255, 255, 255, 0.15) 0%,
                rgba(255, 255, 255, 0.1) 50%,
                rgba(173, 216, 230, 0.15) 100%);
                -webkit-backdrop-filter: blur(10px) saturate(180%);
                backdrop-filter: blur(10px) saturate(180%);
                border: 1px solid rgba(255, 255, 255, 0.4);
    border-radius: 1rem;
    text-decoration: none;
    color: rgba(255, 255, 255, 0.9);
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
    box-shadow:
            0 4px 15px rgba(0, 0, 0, 0.1),
            inset 0 1px 0 rgba(255, 255, 255, 0.3),
            0 0 0 1px rgba(255, 255, 255, 0.2);
}

.social-link::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 50%;
    background: linear-gradient(to bottom,
            rgba(255, 255, 255, 0.3) 0%,
                rgba(255, 255, 255, 0.1) 50%,
            transparent 100%);
    border-radius: 1rem 1rem 0 0;
    pointer-events: none;
}

.social-link:hover {
    background: linear-gradient(135deg,
            rgba(255, 255, 255, 0.2) 0%,
                rgba(255, 255, 255, 0.15) 50%,
                rgba(173, 216, 230, 0.2) 100%);
                border-color: rgba(255, 255, 255, 0.5);
    transform: translateY(-2px);
    box-shadow:
        0 6px 25px rgba(0, 0, 0, 0.15),
            inset 0 1px 0 rgba(255, 255, 255, 0.4),
            0 0 0 1px rgba(255, 255, 255, 0.3),
            0 0 20px rgba(255, 255, 255, 0.2);
}

.social-link-icon {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    z-index: 1;
}

.social-icon-img {
    width: 48px;
    height: 48px;
    object-fit: contain;
    opacity: 0.9;
    transition: all 0.3s ease;
}

.social-link:hover .social-icon-img {
    opacity: 1;
    transform: scale(1.15);
}

/* Responsive untuk Social Box */
@media (max-width: 768px) {
    .social-box-container {
        max-width: 90vw;
        margin: 2rem auto 1.5rem;
    }
    
    .social-box-card {
        padding: 2.5rem 1.5rem 1.5rem 1.5rem;
        width: fit-content;
    }

    .social-links-container {
        gap: 1rem;
    }

    .social-link {
        width: 75px;
        height: 75px;
        padding: 1.25rem;
    }

    .social-icon-img {
        width: 40px;
        height: 40px;
    }

    .social-link-icon svg.social-icon-img {
        width: 40px;
        height: 40px;
    }
}
/* Footer dengan Box Style seperti Navbar */
.site-footer {
    position: relative;
    width: 100%;
    padding: 1.5rem 1rem;
    z-index: 1;
    display: flex;
    align-items: center;
    justify-content: center;
}

.footer-content {
    background: linear-gradient(135deg,
                rgba(255, 255, 255, 0.1) 0%,
                rgba(255, 255, 255, 0.05) 50%,
                rgba(173, 216, 230, 0.1) 100%);
        -webkit-backdrop-filter: blur(4px) saturate(180%);
        backdrop-filter: blur(4px) saturate(180%);
        border: 1px solid rgba(255, 255, 255, 0.3);
        border-top: 1px solid rgba(255, 255, 255, 0.5);
        border-left: 1px solid rgba(255, 255, 255, 0.4);
        border-radius: 1.5rem;
        padding: 0.75rem 1.5rem;
        box-shadow:
            0 4px 20px rgba(0, 0, 0, 0.15),
            inset 0 1px 0 rgba(255, 255, 255, 0.3),
            inset 0 -1px 0 rgba(0, 0, 0, 0.1),
            0 0 0 1px rgba(255, 255, 255, 0.1);
    text-align: center;
    position: relative;
        overflow: hidden;
    }
    
    .footer-content::before {
        content: '';
        position: absolute;
        top: 0;
        left: 0;
        right: 0;
        height: 50%;
        background: linear-gradient(to bottom,
                rgba(255, 255, 255, 0.2) 0%,
                rgba(255, 255, 255, 0.1) 50%,
                transparent 100%);
        border-radius: 1.5rem 1.5rem 0 0;
        pointer-events: none;
        z-index: 1;
}

.footer-copyright {
    color: #3b82f6 !important; /* Warna biru */
    font-size: 0.875rem;
    font-weight: 400;
    margin: 0;
    letter-spacing: 0.05em;
    position: relative;
        z-index: 2;
}

/* Responsive untuk Section 4 */
@media (max-width: 768px) {
    .site-footer {
        padding: 1.5rem 1rem;
    }

    .footer-copyright {
        font-size: 0.75rem;
    }
}
/* About Section Text Styling - Border Biru Tipis dan Shadow */
#about-section .about-window-card .water-card h2,
#about-section .about-window-card .water-card p {
    /* Text stroke biru tipis */
    -webkit-text-stroke: 1px #3b82f6;
    -webkit-text-fill-color: white;

    /* Text shadow untuk efek glow dan depth */
    text-shadow:
        0 0 10px rgba(59, 130, 246, 0.5),
        0 0 20px rgba(59, 130, 246, 0.3),
        0 0 30px rgba(59, 130, 246, 0.2),
        2px 2px 4px rgba(0, 0, 0, 0.3);

    /* Pastikan text tetap terlihat */
    color: white;
}

/* Fallback untuk browser yang tidak support text-stroke */
@supports not (-webkit-text-stroke: 1px #3b82f6) {

    #about-section .about-window-card .water-card h2,
    #about-section .about-window-card .water-card p {
        /* Fallback: gunakan text-shadow untuk efek border */
        text-shadow:
            -1px -1px 0 #3b82f6,
            1px -1px 0 #3b82f6,
            -1px 1px 0 #3b82f6,
            1px 1px 0 #3b82f6,
            0 0 10px rgba(59, 130, 246, 0.5),
            0 0 20px rgba(59, 130, 246, 0.3),
            0 0 30px rgba(59, 130, 246, 0.2),
            2px 2px 4px rgba(0, 0, 0, 0.3);
    }
}