html,
body {
    overflow: hidden;
    height: 100vh;
    background: #000;
    font-family: 'Montserrat', sans-serif;
}

/* --- EFFECT LOADING CINEMATIC --- */
#preloader {
    position: fixed;
    inset: 0;
    z-index: 999;
    background: #000;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    transition: opacity 1.5s ease, visibility 1.5s;
}

.loading-title-wrapper {
    text-align: center;
    margin-bottom: 2rem;
}

.loading-aion {
    font-family: 'Cinzel', serif;
    font-size: 4rem;
    font-weight: 900;
    letter-spacing: 0.5em;
    background: linear-gradient(to bottom, #fff, #94a3b8);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    display: block;
    line-height: 1;
    text-indent: 0.5em;
    filter: drop-shadow(0 0 15px rgba(255, 255, 255, 0.3));
}

.loading-veylora {
    font-family: 'Cinzel', serif;
    font-size: 1.2rem;
    font-weight: 400;
    letter-spacing: 1.2em;
    color: #2dd4bf;
    display: block;
    margin-top: 10px;
    text-indent: 1.2em;
    opacity: 0.8;
}

.loading-bar-container {
    width: 250px;
    height: 2px;
    background: rgba(255, 255, 255, 0.1);
    position: relative;
    overflow: hidden;
}

.loading-bar-fill {
    position: absolute;
    left: 0;
    top: 0;
    height: 100%;
    width: 0%;
    background: #2dd4bf;
    box-shadow: 0 0 15px #2dd4bf;
    transition: width 0.4s ease;
}

.loading-status {
    font-size: 9px;
    text-transform: uppercase;
    letter-spacing: 0.4em;
    color: rgba(255, 255, 255, 0.4);
    margin-top: 15px;
    font-weight: 600;
}

body.loaded #preloader {
    opacity: 0;
    visibility: hidden;
}

/* 2. Floating Particles System */
.particles-container {
    position: absolute;
    inset: 0;
    z-index: 5;
    overflow: hidden;
    pointer-events: none;
}

.magical-particle {
    position: absolute;
    background: radial-gradient(circle, rgba(255, 255, 255, 0.8) 0%, rgba(45, 212, 191, 0.4) 50%, transparent 100%);
    border-radius: 50%;
    filter: blur(1px);
    animation: float-up var(--duration) linear infinite;
    opacity: 0;
    bottom: -20px;
}

@keyframes float-up {
    0% {
        transform: translateY(0) translateX(0);
        opacity: 0;
    }

    20% {
        opacity: var(--max-opacity);
    }

    80% {
        opacity: var(--max-opacity);
    }

    100% {
        transform: translateY(-110vh) translateX(var(--drift));
        opacity: 0;
    }
}

.font-cinzel {
    font-family: 'Cinzel', serif;
}

/* ULTRA DARK CINEMATIC OVERLAY */
.vignette-ultra {
    background: radial-gradient(circle, transparent 20%, rgba(0, 0, 0, 0.7) 60%, rgba(5, 0, 10, 1) 100%);
}

/* LOGO CORE STYLE */
.main-logo-title {
    font-size: clamp(2.5rem, 8vw, 5rem);
    line-height: 0.9;
    text-transform: uppercase;
    font-weight: 900;
    letter-spacing: 0.2em;
    text-shadow: 0px 1px 0px #ccc, 0px 2px 0px #999, 0px 3px 0px #888, 0px 4px 0px #777, 0px 10px 30px rgba(0, 0, 0, 0.9);
}

/* SHINE SWEEP ANIMATION */
.shine-sweep {
    position: relative;
    overflow: hidden;
}

.shine-sweep::before {
    content: "";
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(120deg, transparent, rgba(255, 255, 255, 0.15), transparent);
    animation: shine-loop 6s infinite;
}

@keyframes shine-loop {
    0% {
        left: -100%;
    }

    15% {
        left: 100%;
    }

    100% {
        left: 100%;
    }
}

.game-panel {
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(20px);
    border: 1px solid rgba(45, 212, 191, 0.2);
    box-shadow: 0 0 40px rgba(0, 0, 0, 1);
}

.btn-play {
    background: linear-gradient(135deg, #1e1b4b 0%, #2dd4bf 50%, #1e1b4b 100%);
    border: 1px solid rgba(255, 255, 255, 0.3);
    box-shadow: 0 0 30px rgba(45, 212, 191, 0.3);
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.btn-play:hover {
    transform: scale(1.1) translateY(-5px);
    filter: brightness(1.3);
}

.animate-pulse-slow {
    animation: pulse-slow 4s ease-in-out infinite;
}

@keyframes pulse-slow {

    0%,
    100% {
        opacity: 0.8;
        filter: brightness(1);
    }

    50% {
        opacity: 1;
        filter: brightness(1.2) drop-shadow(0 0 20px rgba(45, 212, 191, 0.5));
    }
}

/* Container Utama */
#about-section {
    background: rgba(0, 0, 0, 0.98);
    /* Lebih gelap dan pekat */
}

#about-section.active {
    opacity: 1;
    pointer-events: auto;
    backdrop-filter: blur(15px);
}

/* Kartu Solid Modern */
.about-card {
    position: relative;
    background: #0a0a0a;
    /* Warna solid hitam pekat */
    border: 1px solid rgba(255, 255, 255, 0.08);
    /* Border tipis tegas */
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
    transition: all 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

.about-card:hover {
    transform: translateY(-8px);
    background: #0f0f0f;
    border-color: #2dd4bf;
    /* Border teal solid saat hover */
    box-shadow: 0 0 30px rgba(45, 212, 191, 0.15);
}

/* Angka Romawi dengan Efek Tekstur */
.card-number {
    font-size: 3rem;
    font-family: 'Cinzel', serif;
    font-weight: 900;
    color: transparent;
    -webkit-text-stroke: 1px rgba(255, 255, 255, 0.2);
    margin-bottom: 1.5rem;
    display: block;
    transition: 0.5s;
}

.about-card:hover .card-number {
    -webkit-text-stroke: 1px #2dd4bf;
    text-shadow: 0 0 15px rgba(45, 212, 191, 0.5);
}

/* Info Grid Solid */
.info-stat-box {
    background: #080808;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
    padding: 2.5rem 0;
}

/* Scrollbar Solid */
.custom-scrollbar::-webkit-scrollbar {
    width: 4px;
}

.custom-scrollbar::-webkit-scrollbar-track {
    background: #000;
}

.custom-scrollbar::-webkit-scrollbar-thumb {
    background: #2dd4bf;
}

/* Styling Baris Pemain Ala MMORPG */
.rank-row {
    background: linear-gradient(90deg, rgba(255, 255, 255, 0.02) 0%, rgba(0, 0, 0, 0.8) 100%);
    border: 1px solid rgba(255, 255, 255, 0.05);
    position: relative;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    margin-bottom: 0.75rem;
    display: grid;
    grid-template-columns: 80px 1fr 180px 180px 200px;
    align-items: center;
}

.rank-row:hover {
    border-color: rgba(45, 212, 191, 0.4);
    background: linear-gradient(90deg, rgba(45, 212, 191, 0.05) 0%, rgba(10, 10, 10, 0.95) 100%);
    transform: scale(1.01) translateX(10px);
    box-shadow: -10px 0 20px rgba(45, 212, 191, 0.1);
}

/* Faction Glow */
.elyos-row:hover {
    border-left: 4px solid #2dd4bf;
}

.asmo-row:hover {
    border-left: 4px solid #a855f7;
}

/* Badge Faksi */
.faction-badge {
    font-size: 8px;
    padding: 2px 10px;
    border-radius: 2px;
    letter-spacing: 2px;
    font-weight: 800;
}

.elyos-badge {
    background: rgba(45, 212, 191, 0.1);
    color: #2dd4bf;
    border: 1px solid #2dd4bf;
}

.asmo-badge {
    background: rgba(168, 85, 247, 0.1);
    color: #a855f7;
    border: 1px solid #a855f7;
}

/* Rank Number Stylized */
.rank-number {
    font-family: 'Cinzel', serif;
    font-size: 1.5rem;
    font-weight: 900;
    text-align: center;
    color: rgba(255, 255, 255, 0.2);
}

.top-1 .rank-number {
    color: #fbbf24;
    text-shadow: 0 0 15px rgba(251, 191, 36, 0.5);
}

.top-2 .rank-number {
    color: #cbd5e1;
}

.top-3 .rank-number {
    color: #fb923c;
}

/* Perkecil Row agar muat 10 list */
.rank-row {
    grid-template-columns: 60px 1fr 140px 120px 160px;
    padding: 0.75rem 1rem;
    margin-bottom: 0.5rem;
}

.rank-number {
    font-size: 1.2rem;
}

.rank-name {
    font-size: 0.9rem;
    letter-spacing: 0.2em;
}

/* Tab Navigation Styling */
.rank-tab {
    position: relative;
    padding: 10px 20px;
    font-size: 10px;
    letter-spacing: 0.3em;
    color: rgba(255, 255, 255, 0.4);
    transition: all 0.3s;
    border-bottom: 2px solid transparent;
}

.rank-tab.active {
    color: #2dd4bf;
    border-bottom: 2px solid #2dd4bf;
    background: linear-gradient(to top, rgba(45, 212, 191, 0.1), transparent);
}

.rank-tab:hover:not(.active) {
    color: white;
}

/* Efek Vignette untuk semua overlay section */
#login-section {
    background: radial-gradient(circle, rgba(0, 0, 0, 0.85) 0%, rgba(0, 0, 0, 0.98) 100%);
    backdrop-filter: blur(8px);
}

/* Animasi Fade In */
.active {
    opacity: 1 !important;
    pointer-events: auto !important;
}

#register-section.active {
    opacity: 1 !important;
    pointer-events: auto !important;
}

/* Efek teks gradasi untuk judul */
.text-gradient {
    background: linear-gradient(to bottom, #fff 0%, #9ca3af 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

/* Penajaman About Card */
.about-card {
    background: linear-gradient(145deg, rgba(15, 15, 15, 0.9) 0%, rgba(5, 5, 5, 0.95) 100%);
    border: 1px solid rgba(255, 255, 255, 0.05);
    position: relative;
    overflow: hidden;
}

/* Dekorasi garis bercahaya di bagian atas kartu saat hover */
.about-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 2px;
    background: linear-gradient(90deg, transparent, #2dd4bf, transparent);
    transform: translateX(-100%);
    transition: 0.5s;
}

.about-card:hover::before {
    transform: translateX(100%);
}

/* List styling agar lebih rapi */
.about-card ul li {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 10px;
    transition: 0.3s;
}

.about-card ul li:hover {
    color: white;
    transform: translateX(5px);
}

/* Styling untuk Tab yang Aktif */
.rank-tab {
    padding: 12px 24px;
    font-family: 'Cinzel', serif;
    font-size: 10px;
    letter-spacing: 0.3em;
    color: rgba(255, 255, 255, 0.3);
    transition: all 0.4s ease;
    border-bottom: 2px solid transparent;
    text-transform: uppercase;
}

.rank-tab.active {
    color: #2dd4bf;
    border-bottom: 2px solid #2dd4bf;
    background: linear-gradient(to top, rgba(45, 212, 191, 0.05), transparent);
}

/* Styling Baris List */
.rank-item {
    background: linear-gradient(90deg, rgba(255, 255, 255, 0.02) 0%, transparent 100%);
    border: 1px solid rgba(255, 255, 255, 0.05);
    transition: all 0.3s ease;
}

.rank-item:hover {
    border-color: rgba(45, 212, 191, 0.3);
    background: rgba(45, 212, 191, 0.02);
    transform: translateX(5px);
}

/* Identitas Faksi */
.faction-dot-elyos {
    box-shadow: 0 0 10px #2dd4bf;
    background-color: #2dd4bf;
}

.faction-dot-asmo {
    box-shadow: 0 0 10px #a855f7;
    background-color: #a855f7;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.animate-fadeIn {
    animation: fadeIn 0.4s ease forwards;
}

@keyframes shake {

    0%,
    100% {
        transform: translateX(0);
    }

    25% {
        transform: translateX(-5px);
    }

    75% {
        transform: translateX(5px);
    }
}

.animate-shake {
    animation: shake 0.4s cubic-bezier(.36, .07, .19, .97) both;
}

/* Menggelapkan tombol jika tidak bisa diklik */
button:disabled {
    opacity: 0.3;
    cursor: not-allowed;
    pointer-events: none;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(5px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.animate-fadeIn {
    animation: fadeIn 0.4s ease-out forwards;
}

/* Efek Cahaya Membara (Pulse) */
@keyframes fire-pulse {
    0%, 100% { transform: scale(1); opacity: 0.4; filter: blur(100px); }
    50% { transform: scale(1.15); opacity: 0.7; filter: blur(80px); }
}

/* Efek Getaran Api (Flicker) */
@keyframes fire-flicker {
    0%, 100% { transform: scale(1.1) translate(0, 0); opacity: 0.3; }
    25% { transform: scale(1.05) translate(-5px, -5px); opacity: 0.5; }
    75% { transform: scale(1.1) translate(5px, 2px); opacity: 0.4; }
}

/* Efek Heat Haze pada Logo (Membara) */
@keyframes burning {
    0%, 100% { filter: drop-shadow(0 0 15px rgba(34,211,238,0.5)) brightness(1); }
    50% { filter: drop-shadow(0 0 35px rgba(168,85,247,0.7)) brightness(1.2); }
}

.animate-fire-pulse {
    animation: fire-pulse 4s ease-in-out infinite;
}

.animate-fire-flicker {
    animation: fire-flicker 0.2s ease-in-out infinite;
    filter: contrast(150%) brightness(120%);
}

.animate-burning {
    animation: burning 3s ease-in-out infinite;
}

.nav-starter-text-glow {
    /* Gradasi: Cyan, Hijau Neon, Biru, Cyan */
    background: linear-gradient(to right,
            #00ffff,
            /* Cyan */
            #3fff00,
            /* Neon Green */
            #0066ff,
            /* Blue */
            #00ffff
            /* Cyan (kembali ke awal untuk loop halus) */
        );
    background-size: 200% auto;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    font-weight: 900;

    /* Double Drop Shadow untuk efek Neon yang sangat terang */
    filter: drop-shadow(0 0 8px rgba(63, 255, 0, 0.6)) drop-shadow(0 0 2px rgba(0, 255, 255, 1));

    animation: textGradientMove 2s linear infinite;
    display: inline-block;
}

/* Animasi Pergerakan Warna (dipercepat jadi 2 detik agar lebih dinamis) */
@keyframes textGradientMove {
    to {
        background-position: 200% center;
    }
}

/* Hover Effect: Glow "Meledak" */
.nav-starter-text-glow:hover {
    filter: drop-shadow(0 0 15px rgba(63, 255, 0, 1)) drop-shadow(0 0 25px rgba(0, 255, 255, 0.8));
    transform: scale(1.1) rotate(-2deg);
    /* Sedikit miring saat hover agar modern */
    transition: all 0.2s ease-in-out;
}

/* Mobile Menu Animation */
#mobile-menu {
    transition: all 0.3s ease-in-out;
    opacity: 0;
    pointer-events: none;
    transform: translateY(-10px);
}

#mobile-menu.active {
    opacity: 1;
    pointer-events: auto;
    transform: translateY(0);
}

@supports (-webkit-touch-callout: none) {
  body {
    overscroll-behavior-y: contain;
  }
}
