﻿/* ===== GLOBAL RESET ===== */
* {
    box-sizing: border-box;
}

body {
    margin: 0;
    font-family: Arial, Helvetica, sans-serif;
    background: #f4f6f8;
    overflow-x: hidden;
}

/* ===== HEADER ===== */
header {
    background: #fff;
    padding: 8px 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
    position: sticky;
    top: 0;
    z-index: 1000;
}

/* ===== LOGO ===== */
.logo {
    flex: 0 0 auto;
}

    .logo img {
        height: 55px;
        width: auto;
        display: block;
    }

/* ===== NAVIGATION ===== */
.main-nav {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 3px;
    flex: 1;
    flex-wrap: nowrap; /* FORCE SINGLE LINE */
    /*overflow: hidden;*/ /* Prevent layout break */
}

    /* ===== MENU LINKS ===== */
    .main-nav a {
        text-decoration: none;
        font-size: 13px; /* Slightly smaller */
        font-weight: 500;
        color: #333;
        padding: 8px 10px; /* Reduced spacing */
        position: relative;
        transition: all 0.3s ease;
        white-space: nowrap;
    }

        /* Hover color */
        .main-nav a:hover,
        .main-nav a.active {
            color: #c4161c;
        }

        /* Underline animation */
        .main-nav a::after {
            content: "";
            position: absolute;
            left: 0;
            bottom: -3px;
            width: 0;
            height: 2px;
            background: #c4161c;
            transition: width 0.3s ease;
        }

        .main-nav a:hover::after,
        .main-nav a.active::after {
            width: 100%;
        }

/* ===== HAMBURGER MENU ===== */
.hamburger-menu {
    display: none;
    flex-direction: column;
    gap: 4px;
    cursor: pointer;
}

    .hamburger-menu .bar {
        width: 26px;
        height: 3px;
        background: #333;
    }

/* ===== TABLET & MOBILE ===== */
@media (max-width: 768px) {

    header {
        padding: 10px 15px;
    }

    .logo img {
        height: 50px;
    }

    .hamburger-menu {
        display: flex;
    }

    .main-nav {
        display: none; /* Hidden by default */
        flex-direction: column;
        width: 100%;
        background: #fff;
        position: absolute;
        top: 70px; /* Adjust based on header height */
        left: 0;
        z-index: 1000;
    }

        /* This is what the JavaScript triggers */
        .main-nav.show {
            display: flex !important;
        }

        .main-nav a {
            padding: 14px 20px;
            border-bottom: 1px solid #eee;
            width: 100%;
            font-size: 15px;
        }
    /* Style for the dropdown when active on mobile */
    .dropdown.active .dropdown-content {
        display: block !important;
        position: static;
        width: 100%;
        box-shadow: none;
    }
}

/* ===== SMALL MOBILE ===== */
@media (max-width: 480px) {

    header {
        padding: 8px 12px;
    }

    .logo img {
        height: 45px;
    }

    .main-nav {
        top: 65px;
    }
}
/* ===== UPDATED DROPDOWN STYLES ===== */

/* 1. The Container */
.dropdown {
    position: relative;
    display: inline-block;
}

/* 2. The Main Button Link */
.dropbtn {
    cursor: pointer;
    display: block;
    padding: 8px 10px;
    text-decoration: none;
    font-size: 13px;
    font-weight: 500;
    color: #333;
    transition: color 0.3s ease;
}

/* 3. The Hidden Content (Professional Entrance) */
.dropdown-content {
    display: block; /* Kept as block but hidden via opacity */
    visibility: hidden; /* Prevents clicking when hidden */
    opacity: 0; /* Transparent */
    position: absolute;
    top: 100%; /* Right below the nav bar */
    left: 0;
    min-width: 220px;
    background-color: #ffffff;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1); /* Soft, modern shadow */
    border-radius: 0 0 6px 6px; /* Rounded bottom corners */
    border: 1px solid rgba(0, 0, 0, 0.05);
    z-index: 9999;
    /* Smooth Transition Animation */
    transform: translateY(10px);
    transition: opacity 0.3s ease, transform 0.3s ease, visibility 0.3s;
}

    /* 4. The "Hover Bridge" 
   (Prevents menu closing if mouse moves slightly off the gap) */
    .dropdown-content::before {
        content: "";
        position: absolute;
        top: -10px;
        left: 0;
        width: 100%;
        height: 10px;
    }

/* 5. Show State on Hover */
.dropdown:hover .dropdown-content {
    visibility: visible;
    opacity: 1;
    transform: translateY(0); /* Slides up into place */
}

.dropdown:hover .dropbtn {
    color: #c4161c; /* Highlights parent link when menu is open */
}

/* 6. Dropdown Links Styling */
.dropdown-content a {
    display: block;
    padding: 12px 20px;
    color: #444 !important; /* Overriding global nav color */
    text-decoration: none;
    font-size: 14px;
    font-weight: 400;
    border-bottom: 1px solid #f8f8f8;
    transition: all 0.2s ease;
}

    .dropdown-content a:last-child {
        border-bottom: none;
    }

    /* 7. Hover Effect for Dropdown Links */
    .dropdown-content a:hover {
        background-color: #fcfcfc;
        color: #c4161c !important;
        padding-left: 25px; /* Subtle "nudge" effect */
    }

    /* 8. Remove the underline animation for dropdown links */
    .dropdown-content a::after {
        display: none !important;
    }

/* ===== MOBILE OVERRIDE ===== */
@media (max-width: 768px) {
    /* 1. Make the dropdown container full width */
    .dropdown {
        width: 100%;
    }

    /* 2. Style the button to look like a standard mobile menu item */
    .dropbtn {
        width: 100%;
        padding: 14px 20px; /* Matching your other mobile links */
        border-bottom: 1px solid #eee;
        display: flex;
        justify-content: space-between;
        align-items: center;
    }

    /* 3. The mobile dropdown content (The Accordion) */
    .dropdown-content {
        position: static; /* Moves it into the normal flow of the list */
        display: none; /* Hidden by default */
        visibility: visible;
        opacity: 1;
        transform: none;
        background-color: #fcfcfc; /* Slightly different bg to show it's a sub-menu */
        box-shadow: none;
        width: 100%;
        border: none;
        padding-left: 20px; /* Indent sub-items */
    }

    /* 4. Show the menu when the .active class is added via JS */
    .dropdown.active .dropdown-content {
        display: block;
    }

    /* 5. Rotate the arrow when open */
    .dropdown.active .dropbtn::after {
        transform: rotate(180deg);
    }
}


/* Continuous Pulsing/Flashing Animation */
/* Premium Shimmer Effect */
/* 1. Animations: Professional & Urgent */
@keyframes shimmer {
    0%

{
    left: -100%;
}

100% {
    left: 100%;
}

}

@keyframes red-glow {
    0% {
        box-shadow: 0 0 5px rgba(220, 53, 69, 0.4);
    }

    50% {
        box-shadow: 0 0 15px rgba(220, 53, 69, 0.8);
    }

    100% {
        box-shadow: 0 0 5px rgba(220, 53, 69, 0.4);
    }
}

@keyframes slide-in-fade {
    0% {
        opacity: 0;
        transform: translateX(-20px);
    }

    100% {
        opacity: 1;
        transform: translateX(0);
    }
}

/* 2. Main Banner Container */
.pwa-premium-banner {
    display: none; /* Controlled by JS .show-smooth */
    align-items: center;
    background: rgba(255, 255, 255, 0.98);
    border: 1px solid #dc3545; /* Brand Red */
    border-radius: 50px;
    padding: 5px 8px 5px 5px;
    margin-left: 5px;
    box-shadow: 0 4px 12px rgba(220, 53, 69, 0.15);
    height: 40px;
    z-index: 1001;
}

    .pwa-premium-banner.show-smooth {
        display: flex !important;
        animation: slide-in-fade 0.8s ease-out forwards;
    }

/* 3. Text Styling */
.install-text-premium {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    font-size: 13px;
    color: #333;
    margin-right: 10px;
    white-space: nowrap;
}

/* 4. Button Wrapper (HIDDEN BY DEFAULT FOR FIREFOX) */
.btn-shimmer-wrapper {
    position: relative;
    overflow: hidden;
    border-radius: 20px;
    display: none; /* CRITICAL: Stays hidden in Firefox/Safari */
    animation: red-glow 1.5s infinite ease-in-out;
}

/* This class is added by JS ONLY for Chrome/Edge/Android */
.show-install-btn {
    display: inline-block !important;
}

/* 5. The Red Gradient Button */
.flash-install-btn-red {
    background: linear-gradient(135deg, #e63946, #d62828);
    color: #fff !important;
    border: none;
    padding: 6px 18px;
    font-size: 11px;
    font-weight: 800;
    cursor: pointer;
    text-transform: uppercase;
    display: block;
    position: relative;
    z-index: 1;
}

/* The White Shimmer Streak */
.btn-shimmer-wrapper::after {
    content: "";
    position: absolute;
    top: 0;
    left: -100%;
    width: 60%;
    height: 100%;
    background: linear-gradient(to right, transparent, rgba(255,255,255,0.5), transparent);
    transform: skewX(-25deg);
    animation: shimmer 2s infinite;
    z-index: 2;
}

/* 6. Close Button */
.close-pwa {
    background: none;
    border: none;
    color: #aaa;
    font-size: 16px;
    margin-left: 8px;
    cursor: pointer;
    transition: color 0.2s;
}

    .close-pwa:hover {
        color: #dc3545;
    }

/* 7. Mobile Optimization (Panihati/Kolkata users) */
@media (max-width: 600px) {
    .pwa-premium-banner {
        margin-left: -60px;
        padding: 2px 8px;
        flex-shrink: 1;
        height: 38px;
    }

    .install-text-premium {
        font-size: 10px;
        margin-right: 10px;
    }

    .btn-shimmer-wrapper {
        flex-shrink: 0;
    }

    .flash-install-btn-red {
        padding: 4px 5px;
        font-size: 10px;
        height: 28px;
    }

    .close-pwa {
        margin-left: 5px;
        font-size: 14px;
    }
    
}