/* =========================================
   INDIA INDEPENDENCE DAY ANIMATION
========================================= */

#independence-animation {
    position: fixed;
    inset: 0;
    z-index: 99999;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;

    background:
        linear-gradient(
            to bottom,
            #ff9933 0%,
            #ff9933 33.33%,
            #ffffff 33.33%,
            #ffffff 66.66%,
            #138808 66.66%,
            #138808 100%
        );

    animation: indiaIntro 0.8s ease-out;
}

/* Slight white transparent layer */
#independence-animation::before {
    content: "";
    position: absolute;
    inset: 0;
    background: rgba(255,255,255,0.12);
}

/* Main content */
.india-content {
    position: relative;
    z-index: 2;
    text-align: center;
    padding: 30px;
    animation: indiaContent 1.2s ease-out;
}

/* Ashoka Chakra */
.ashoka-chakra {
    position: relative;
    width: 150px;
    height: 150px;
    margin: 0 auto 25px;

    border: 7px solid #000080;
    border-radius: 50%;

    animation: chakraRotate 8s linear infinite;
}

/* Center */
.chakra-center {
    position: absolute;
    width: 25px;
    height: 25px;
    background: #000080;
    border-radius: 50%;

    top: 50%;
    left: 50%;

    transform: translate(-50%, -50%);
}

/* Chakra spokes */
.spoke {
    position: absolute;
    width: 3px;
    height: 135px;
    background: #000080;

    left: 50%;
    top: 50%;

    transform-origin: center;
    transform: translate(-50%, -50%);
}

/* 12 spokes */
.spoke-1  { transform: translate(-50%, -50%) rotate(0deg); }
.spoke-2  { transform: translate(-50%, -50%) rotate(30deg); }
.spoke-3  { transform: translate(-50%, -50%) rotate(60deg); }
.spoke-4  { transform: translate(-50%, -50%) rotate(90deg); }
.spoke-5  { transform: translate(-50%, -50%) rotate(120deg); }
.spoke-6  { transform: translate(-50%, -50%) rotate(150deg); }
.spoke-7  { transform: translate(-50%, -50%) rotate(180deg); }
.spoke-8  { transform: translate(-50%, -50%) rotate(210deg); }
.spoke-9  { transform: translate(-50%, -50%) rotate(240deg); }
.spoke-10 { transform: translate(-50%, -50%) rotate(270deg); }
.spoke-11 { transform: translate(-50%, -50%) rotate(300deg); }
.spoke-12 { transform: translate(-50%, -50%) rotate(330deg); }

/* Heading */
.india-content h1 {
    margin: 0;

    font-size: clamp(36px, 6vw, 72px);
    font-weight: 800;
    letter-spacing: 2px;

    color: #ffffff;

    text-shadow:
        2px 2px 0 #000080,
        0 4px 15px rgba(0,0,0,0.35);

    animation: indiaText 1.2s ease-out;
}

/* Date */
.india-date {
    margin-top: 12px;

    font-size: clamp(24px, 4vw, 42px);
    font-weight: 800;
    letter-spacing: 8px;

    color: #000080;

    animation: indiaDate 1.5s ease-out;
}

/* Subtitle */
.india-content p {
    margin-top: 15px;

    font-size: clamp(16px, 2vw, 24px);
    font-weight: 600;

    color: #222;

    animation: indiaText 1.8s ease-out;
}

/* Skip button */
.india-skip {
    position: absolute;
    z-index: 5;

    right: 25px;
    top: 25px;

    padding: 8px 18px;

    border: 1px solid rgba(255,255,255,0.8);
    border-radius: 30px;

    background: rgba(0,0,0,0.35);
    color: #fff;

    font-size: 14px;
    cursor: pointer;

    transition: all 0.3s ease;
}

.india-skip:hover {
    background: #000080;
    transform: scale(1.05);
}

/* Fade out */
#independence-animation.hide {
    animation: indiaOutro 1s ease forwards;
    pointer-events: none;
}

/* =========================================
   PARTICLES
========================================= */

.india-particles,
.india-particles::before,
.india-particles::after {
    position: absolute;
    width: 100%;
    height: 100%;
    inset: 0;
}

.india-particles::before,
.india-particles::after {
    content: "✦  ✧  ✦  ✧  ✦  ✧  ✦  ✧";
    font-size: 30px;
    letter-spacing: 80px;

    color: rgba(255,255,255,0.7);

    animation: particlesMove 5s linear infinite;
}

.india-particles::after {
    font-size: 20px;
    letter-spacing: 50px;

    animation-duration: 7s;
    animation-direction: reverse;
}

/* =========================================
   ANIMATIONS
========================================= */

@keyframes indiaIntro {
    from {
        opacity: 0;
        transform: scale(1.05);
    }

    to {
        opacity: 1;
        transform: scale(1);
    }
}

@keyframes indiaContent {
    from {
        opacity: 0;
        transform: translateY(50px) scale(0.8);
    }

    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

@keyframes chakraRotate {
    from {
        transform: rotate(0deg);
    }

    to {
        transform: rotate(360deg);
    }
}

@keyframes indiaText {
    from {
        opacity: 0;
        transform: translateY(25px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes indiaDate {
    from {
        opacity: 0;
        letter-spacing: 30px;
    }

    to {
        opacity: 1;
        letter-spacing: 8px;
    }
}

@keyframes particlesMove {
    from {
        transform: translateY(100%);
        opacity: 0;
    }

    50% {
        opacity: 1;
    }

    to {
        transform: translateY(-100%);
        opacity: 0;
    }
}

@keyframes indiaOutro {
    from {
        opacity: 1;
        transform: scale(1);
    }

    to {
        opacity: 0;
        transform: scale(1.08);
        visibility: hidden;
    }
}

/* =========================================
   MOBILE
========================================= */

@media (max-width: 600px) {

    .ashoka-chakra {
        width: 110px;
        height: 110px;
        border-width: 5px;
        margin-bottom: 20px;
    }

    .spoke {
        height: 98px;
        width: 2px;
    }

    .chakra-center {
        width: 18px;
        height: 18px;
    }

    .india-content {
        padding: 20px;
    }

    .india-content h1 {
        font-size: 38px;
        line-height: 1.2;
    }

    .india-date {
        font-size: 24px;
        letter-spacing: 5px;
    }

    .india-content p {
        font-size: 16px;
    }

    .india-skip {
        right: 15px;
        top: 15px;
    }
}