/* ==========================================
   1. MAIN HEADER LEH ANIMATIONS (I siam sa kha)
   ========================================== */
/* Header Entrance Animation */
@keyframes headerDrop {
    0% { transform: translateY(-100%); opacity: 0; }
    100% { transform: translateY(0); opacity: 1; }
}

/* Ambient Gradient Shift */
@keyframes ambientBackground {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

.main-header {
    background: linear-gradient(-45deg, rgba(11, 57, 84, 0.9), rgba(15, 23, 42, 0.9), rgba(4, 73, 112, 0.9), rgba(18, 40, 76, 0.9));
    background-size: 300% 300%;
    animation: headerDrop 0.8s cubic-bezier(0.16, 1, 0.3, 1) forwards, ambientBackground 18s ease infinite;
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.4);
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    position: relative;
    z-index: 1030;
}

/* Glowing Animated Bottom Border */
.main-header::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 3px;
    background: linear-gradient(90deg, transparent, #f1c40f, #ff9f43, #f1c40f, transparent);
    background-size: 200% 100%;
    animation: shimmerBorder 3s infinite linear;
    opacity: 0.9;
}

@keyframes shimmerBorder {
    0% { background-position: 100% 0; }
    100% { background-position: -100% 0; }
}

/* Logo 3D Pop & Floating Effect */
@keyframes continuousFloat {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-4px); box-shadow: 0 0 0 2px rgba(241, 196, 15, 0.9), 0 8px 20px rgba(0,0,0,0.4); }
}

.logo-wrapper {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background-color: #ffffff;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    box-shadow: 0 0 0 2px rgba(241, 196, 15, 0.8), 0 5px 15px rgba(0,0,0,0.3);
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    cursor: pointer;
    animation: continuousFloat 4s ease-in-out infinite;
}

.header-logo {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.logo-wrapper:hover {
    animation-play-state: paused; 
    transform: translateY(-2px) scale(1.12) !important;
    box-shadow: 0 0 0 3px #f1c40f, 0 10px 25px rgba(241, 196, 15, 0.6);
}

.logo-wrapper:hover .header-logo {
    transform: scale(1.15) rotate(8deg);
}

/* Thuziak Metallic Shine Animation */
@keyframes textShimmer {
    0% { background-position: -200% center; }
    100% { background-position: 200% center; }
}

.header-text h1 {
    font-size: 1.1rem;
    font-weight: 800;
    letter-spacing: 0.5px;
    margin-bottom: 2px;
    background: linear-gradient(to right, #ffffff 20%, #94a3b8 40%, #94a3b8 60%, #ffffff 80%);
    background-size: 200% auto;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    animation: textShimmer 5s linear infinite;
    text-shadow: 0px 4px 12px rgba(0,0,0,0.4);
}

.header-text p {
    font-size: 0.75rem;
    font-weight: 700;
    color: #f1c40f;
    letter-spacing: 1px;
    text-transform: uppercase;
    margin-top: -2px;
    text-shadow: 0px 2px 4px rgba(0,0,0,0.3);
}

/* Admin Button */
@keyframes adminPulse {
    0% { box-shadow: 0 0 0 0 rgba(241, 196, 15, 0.5); }
    70% { box-shadow: 0 0 0 12px rgba(241, 196, 15, 0); }
    100% { box-shadow: 0 0 0 0 rgba(241, 196, 15, 0); }
}

.admin-btn {
    border-radius: 50%;
    transition: all 0.3s ease;
}

.admin-btn:hover {
    animation: adminPulse 1.5s infinite;
    transform: scale(1.1);
    color: #f1c40f !important;
}

/* Share Button */
.btn-share-header {
    background: rgba(255, 255, 255, 0.2);
    border: 1px solid rgba(255, 255, 255, 0.4);
    color: #fff;
    border-radius: 50px;
    padding: 6px 14px;
    font-size: 0.9rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 5px;
    backdrop-filter: blur(5px);
    -webkit-backdrop-filter: blur(5px);
    transition: all 0.3s ease;
    cursor: pointer;
}

.btn-share-header:hover, .btn-share-header:active {
    background: rgba(255, 255, 255, 0.35);
    transform: scale(0.95);
    box-shadow: 0 4px 12px rgba(0,0,0,0.2);
}

.btn-share-header i {
    font-size: 1.1rem;
}


/* ==========================================
   2. NOTICE BAR (A bo palh mi kha)
   ========================================== */
.notice-bar {
    background-color: rgba(0, 0, 0, 0.6);
    color: white;
    font-size: 0.8rem;
    padding: 6px 15px;
    overflow: hidden;
    white-space: nowrap;
}

.notice-text {
    display: inline-block;
    animation: scroll-left 15s linear infinite;
}

@keyframes scroll-left {
    0%   { transform: translateX(100vw); }
    100% { transform: translateX(-100%); }
}


/* ==========================================
   3. WELCOME MODAL (PRO & MOTION EFFECTS)
   ========================================== */

/* Modal Rawn Zuang Chhuak Animation */
@keyframes modalBounceIn {
    0% { transform: scale(0.8) translateY(30px); opacity: 0; }
    100% { transform: scale(1) translateY(0); opacity: 1; }
}

#welcomeModal .modal-content {
    background: linear-gradient(135deg, #ffffff 0%, #f8f9fa 100%);
    border: 1px solid rgba(255, 193, 7, 0.4);
    border-radius: 28px !important;
    box-shadow: 0 25px 50px rgba(0,0,0,0.25), 0 0 0 8px rgba(255, 255, 255, 0.5);
    animation: modalBounceIn 0.6s cubic-bezier(0.68, -0.55, 0.265, 1.55) forwards;
}

/* Logo Bawm (Ring Vir Char Char Animation) */
@keyframes spinGradient {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

@keyframes floatLogo {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-8px); }
}

.welcome-logo-wrapper {
    position: relative;
    display: inline-flex;
    padding: 18px;
    background: #ffffff;
    border-radius: 50%;
    margin-bottom: 15px;
    z-index: 1;
    box-shadow: 0 10px 25px rgba(241, 196, 15, 0.25);
    /* Boruaka a kan (float) theih nan */
    animation: floatLogo 3s ease-in-out infinite;
}

/* Ring Tle Vir kual tuam tu */
.welcome-logo-wrapper::before {
    content: '';
    position: absolute;
    top: -4px; left: -4px; right: -4px; bottom: -4px;
    border-radius: 50%;
    background: linear-gradient(45deg, #ffc107, #ff9f43, #e52d27, #ffc107);
    background-size: 200% 200%;
    z-index: -1;
    animation: spinGradient 3s linear infinite;
}

/* Logo Hnunga Var lang theih nan */
.welcome-logo-wrapper::after {
    content: '';
    position: absolute;
    top: 2px; left: 2px; right: 2px; bottom: 2px;
    border-radius: 50%;
    background: #ffffff;
    z-index: -1;
}

/* Logo Lungphu Animation */
@keyframes heartbeat {
    0%, 100% { transform: scale(1); }
    15% { transform: scale(1.15); }
    30% { transform: scale(1); }
    45% { transform: scale(1.15); }
    60% { transform: scale(1); }
}

.welcome-logo {
    width: 85px;
    height: 85px;
    object-fit: contain;
    animation: heartbeat 2.5s infinite;
}

/* ==========================================
   LUT RAWH LE - BUTTON MAWI LEH TLE
   ========================================== */
@keyframes gradientMove {
    0% { background-position: 0% center; }
    100% { background-position: 200% center; }
}

@keyframes btnShine {
    0% { left: -100%; }
    20% { left: 200%; }
    100% { left: 200%; }
}

.btn-welcome {
    position: relative;
    overflow: hidden;
    background: linear-gradient(45deg, #09ec7b, #622cb8, #12054d);
    background-size: 200% auto;
    color: white !important;
    border: none;
    letter-spacing: 1px;
    font-size: 1.05rem;
    box-shadow: 0 8px 20px rgba(229, 45, 39, 0.4);
    transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    z-index: 1;
    /* Rawng inthlak riai riai nan */
    animation: gradientMove 3s linear infinite;
}

/* Button Tle phei fua fua tur */
.btn-welcome::after {
    content: '';
    position: absolute;
    top: 0; left: -100%;
    width: 50%; height: 100%;
    background: linear-gradient(to right, rgba(255,255,255,0), rgba(255,255,255,0.4), rgba(255,255,255,0));
    transform: skewX(-25deg);
    animation: btnShine 3s infinite 1s; /* Second 1 nghak phawtin a tle ang */
}

/* Button hmeh (Hover) huna rawn lian */
.btn-welcome:hover {
    transform: translateY(-4px) scale(1.05);
    box-shadow: 0 12px 25px rgba(229, 45, 39, 0.6);
}

.btn-welcome:active {
    transform: scale(0.95);
}