@import url('https://fonts.googleapis.com/css2?family=Tiro+Devanagari+Hindi&family=Cinzel:wght@400;600;700&family=Poppins:wght@400;500;600&display=swap');

/* Floating Header */
.main-header {
    position: fixed;
    top: 20px;
    left: 50%;
    transform: translateX(-50%);
    width: 95%;
    max-width: 1400px;
    background: linear-gradient(135deg, #ffffff 0%, #fff9f0 50%, #fff5e6 100%);
    border-radius: 20px;
    box-shadow:
        0 10px 40px rgba(128, 0, 0, 0.15),
        0 0 0 1px rgba(255, 153, 51, 0.2),
        inset 0 1px 0 rgba(255, 255, 255, 0.9);
    z-index: 1000;
    overflow: hidden;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.main-header:hover {
    box-shadow:
        0 15px 50px rgba(128, 0, 0, 0.2),
        0 0 0 2px rgba(255, 153, 51, 0.3),
        inset 0 1px 0 rgba(255, 255, 255, 0.9);
    transform: translateX(-50%) translateY(-2px);
}

/* Decorative Borders */
.header-top-border {
    height: 4px;
    background: linear-gradient(90deg,
            #FF9933, #FF5722, #800000, #FF5722, #FF9933,
            #800000, #FF9933, #FF5722, #800000, #FF5722, #FF9933);
    background-size: 200% 100%;
    animation: headerBorderFlow 8s linear infinite;
}

.header-bottom-border {
    height: 2px;
    background: linear-gradient(90deg,
            transparent, #FF9933, #800000, #FF9933, transparent);
}

@keyframes headerBorderFlow {
    0% {
        background-position: 0% 0%;
    }

    100% {
        background-position: 200% 0%;
    }
}

/* Header Spacer */
.header-spacer {
    height: 120px;
}

/* Container */
.main-header .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 30px;
    position: relative;
}

/* Logo Styling */
.header-logo a {
    text-decoration: none;
    color: inherit;
}

.header-logo-wrapper {
    display: flex;
    align-items: center;
    gap: 15px;
}

/* Logo Image Styles */
.header-logo-img {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    object-fit: cover;
    border: 3px solid #800000;
    box-shadow:
        0 0 15px rgba(255, 153, 51, 0.4),
        0 0 30px rgba(128, 0, 0, 0.2);
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    animation: headerLogoGlow 3s ease-in-out infinite;
}

.header-logo-img:hover {
    transform: scale(1.08) rotate(5deg);
    box-shadow:
        0 0 25px rgba(255, 153, 51, 0.6),
        0 0 40px rgba(128, 0, 0, 0.3);
    border-color: #FF9933;
}

@keyframes headerLogoGlow {

    0%,
    100% {
        box-shadow:
            0 0 15px rgba(255, 153, 51, 0.4),
            0 0 30px rgba(128, 0, 0, 0.2);
    }

    50% {
        box-shadow:
            0 0 25px rgba(255, 153, 51, 0.6),
            0 0 40px rgba(128, 0, 0, 0.3),
            0 0 50px rgba(255, 87, 34, 0.2);
    }
}

.header-logo-text {
    display: flex;
    flex-direction: column;
}

.header-logo-text h1 {
    font-family: 'Cinzel', serif;
    font-size: 1.4rem;
    font-weight: 700;
    color: #800000;
    margin: 0;
    letter-spacing: 1px;
    line-height: 1.2;
}

.header-logo-text .header-tagline {
    font-family: 'Tiro Devanagari Hindi', serif;
    font-size: 0.95rem;
    color: #FF5722;
    letter-spacing: 2px;
}

/* Navigation */
.header-main-nav ul {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    gap: 5px;
    align-items: center;
}

.header-main-nav li {
    position: relative;
}

.header-main-nav a {
    display: flex;
    align-items: center;
    gap: 6px;
    text-decoration: none;
    color: #5a3d3d;
    font-family: 'Poppins', sans-serif;
    font-weight: 500;
    font-size: 0.95rem;
    padding: 12px 18px;
    border-radius: 12px;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.header-main-nav a::before {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 0;
    height: 3px;
    background: linear-gradient(90deg, #FF9933, #800000);
    border-radius: 3px 3px 0 0;
    transition: width 0.3s ease;
}

.header-main-nav a:hover::before {
    width: 80%;
}

.header-main-nav a:hover {
    color: #800000;
    background: rgba(255, 153, 51, 0.1);
}

.header-nav-icon {
    font-size: 1rem;
    opacity: 0.8;
}

/* Donate Button */
.header-donate-btn {
    background: linear-gradient(135deg, #FF9933 0%, #FF5722 100%);
    color: white !important;
    padding: 12px 24px !important;
    border-radius: 25px !important;
    font-weight: 600 !important;
    box-shadow:
        0 4px 15px rgba(255, 87, 34, 0.4),
        inset 0 1px 0 rgba(255, 255, 255, 0.3);
    border: 2px solid transparent;
    position: relative;
    overflow: hidden;
}

.header-donate-btn::before {
    display: none !important;
}

.header-donate-btn::after {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: linear-gradient(45deg,
            transparent 30%,
            rgba(255, 255, 255, 0.3) 50%,
            transparent 70%);
    transform: rotate(45deg);
    animation: headerShimmer 3s infinite;
}

@keyframes headerShimmer {
    0% {
        transform: translateX(-100%) rotate(45deg);
    }

    100% {
        transform: translateX(100%) rotate(45deg);
    }
}

.header-donate-btn:hover {
    background: linear-gradient(135deg, #FF5722 0%, #800000 100%) !important;
    transform: scale(1.05);
    box-shadow:
        0 6px 25px rgba(255, 87, 34, 0.5),
        inset 0 1px 0 rgba(255, 255, 255, 0.3);
}

.header-diya {
    font-size: 1.2rem;
    animation: headerDiyaFlicker 1.5s ease-in-out infinite;
}

@keyframes headerDiyaFlicker {

    0%,
    100% {
        opacity: 1;
        transform: scale(1);
    }

    50% {
        opacity: 0.8;
        transform: scale(1.1);
    }
}

/* Mobile Menu Toggle */
.header-mobile-menu-toggle {
    display: none;
    cursor: pointer;
    padding: 10px;
    border-radius: 10px;
    transition: background 0.3s;
}

.header-mobile-menu-toggle:hover {
    background: rgba(255, 153, 51, 0.1);
}

.header-mandala-menu {
    display: flex;
    flex-direction: column;
    gap: 5px;
    width: 28px;
}

.header-mandala-menu span {
    height: 3px;
    background: linear-gradient(90deg, #800000, #FF9933);
    border-radius: 3px;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    transform-origin: center;
}

.header-mandala-menu span:nth-child(1) {
    width: 100%;
}

.header-mandala-menu span:nth-child(2) {
    width: 70%;
    align-self: center;
}

.header-mandala-menu span:nth-child(3) {
    width: 100%;
}

.header-mobile-menu-toggle.active .header-mandala-menu span:nth-child(1) {
    transform: rotate(45deg) translate(6px, 6px);
}

.header-mobile-menu-toggle.active .header-mandala-menu span:nth-child(2) {
    opacity: 0;
    transform: scale(0);
}

.header-mobile-menu-toggle.active .header-mandala-menu span:nth-child(3) {
    transform: rotate(-45deg) translate(6px, -6px);
}

/* Mobile Navigation */
.header-mobile-nav {
    display: none;
    background: linear-gradient(180deg, #fff9f0 0%, #ffffff 100%);
    border-top: 0 solid rgba(255, 153, 51, 0.2);
    padding: 0;
    max-height: 0;
    overflow: hidden;
    transition: all 0.4s ease;
}

.header-mobile-nav.active {
    max-height: 450px;
    padding: 20px;
    border-top-width: 1px;
}

.header-mobile-nav ul {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.header-mobile-nav a {
    display: block;
    text-decoration: none;
    color: #5a3d3d;
    font-family: 'Poppins', sans-serif;
    font-weight: 500;
    padding: 15px 20px;
    border-radius: 12px;
    background: rgba(255, 153, 51, 0.05);
    border-left: 3px solid transparent;
    transition: all 0.3s ease;
}

.header-mobile-nav a:hover {
    background: rgba(255, 153, 51, 0.15);
    border-left-color: #FF9933;
    color: #800000;
    transform: translateX(5px);
}

.header-donate-btn-mobile {
    background: linear-gradient(135deg, #FF9933 0%, #FF5722 100%) !important;
    color: white !important;
    text-align: center;
    border-radius: 25px !important;
    border-left: none !important;
}

/* Responsive Design */
@media (max-width: 1024px) {
    .main-header {
        width: 98%;
        top: 10px;
    }

    .header-logo-text h1 {
        font-size: 1.2rem;
    }

    .header-main-nav a {
        padding: 10px 12px;
        font-size: 0.9rem;
    }

    .header-logo-img {
        width: 55px;
        height: 55px;
    }
}

@media (max-width: 768px) {
    .main-header {
        top: 10px;
        width: 95%;
        border-radius: 15px;
    }

    .header-spacer {
        height: 100px;
    }

    .main-header .container {
        padding: 12px 20px;
    }

    .header-main-nav {
        display: none;
    }

    .header-mobile-menu-toggle {
        display: block;
    }

    .header-mobile-nav {
        display: block;
    }

    .header-logo-img {
        width: 50px;
        height: 50px;
    }

    .header-logo-text h1 {
        font-size: 1rem;
    }

    .header-logo-text .header-tagline {
        font-size: 0.8rem;
    }
}

@media (max-width: 480px) {
    .main-header {
        top: 5px;
        width: 97%;
        border-radius: 12px;
    }

    .header-logo-wrapper {
        gap: 10px;
    }

    .header-logo-img {
        width: 45px;
        height: 45px;
        border-width: 2px;
    }

    .header-logo-text h1 {
        font-size: 0.85rem;
    }

    .header-logo-text .header-tagline {
        font-size: 0.7rem;
    }
}

/* Scroll Effect */
.main-header.scrolled {
    top: 10px;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
}