/* ========================================
   FRIES MENU HEADER COMPONENT STYLES
   Complete CSS for Professional Header Component
    Fixed Close Icon Animation
======================================== */

/* Header Layout - Transparent on Desktop/Tablet, White on Mobile */
.site-header {
    position: fixed !important;
    top: 0;
    left: 0;
    right: 0;
    background: transparent !important; /* Transparent on desktop/tablet */
    box-shadow: none !important; /* Remove shadow */
    border: none !important; /* Remove any borders */
    z-index: 1000;
    transition: all 0.3s ease;
}

/* Remove header wrapper background and padding */
.header-wrapper {
    background: transparent !important;
    padding: 0 !important; /* Remove all padding */
    margin: 0 !important; /* Remove all margin */
    height: auto !important; /* Let height be determined by content */
    max-width: none !important; /* Remove width restrictions */
    box-shadow: none !important;
    border: none !important;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

/* Remove container styling if present */
.header-wrapper .container {
    background: transparent !important;
    padding: 0 !important;
    margin: 0 !important;
    max-width: none !important;
    width: 100% !important;
}

/* Mobile Header Layout - Logo Left, Menu Right */
.mobile-header-layout {
    display: flex !important;
    width: 100%;
    align-items: center;
    justify-content: space-between;
    position: relative;
    min-height: 48px;
    background: transparent !important;
    /*padding: 20px 30px !important; /* Minimal padding  */
    margin: 0 !important;
}

/* Hide desktop elements completely */
.header-wrapper > .brand-logo:not(.mobile-header-layout .brand-logo),
.header-wrapper > .breadcrumb-container,
.primary-nav,
.header-actions,
.breadcrumb-container,
.breadcrumb-nav {
    display: none !important;
}

/* Ensure logo takes up space on the left */
.mobile-header-layout .brand-logo {
    flex: 0 0 auto; /* Don't grow or shrink */
    margin-right: auto; /* Push everything else to the right */
    order: 1;
    background: transparent !important;
}

/* Ensure menu stays on the right */
.mobile-header-layout .fries-menu-toggle {
    flex: 0 0 auto; /* Don't grow or shrink */
    margin-left: auto; /* Push to the right */
    order: 2;
    background: transparent !important;
}

/* Logo & Brand */
.brand-logo {
    display: flex;
    align-items: center;
    gap: var(--spacing-sm);
}

.logo-img {
    width: auto;
    height: 60px !important; /* Adjust logo size */
    object-fit: contain;
}

/* Primary Navigation - Hidden */
.primary-nav .nav-menu {
    display: none !important;
}

.nav-link {
    display: none !important;
}

/* Header Actions - Hidden */
.header-actions {
    display: none !important;
}

/* Fries Menu Toggle Wrapper */
.fries-menu-toggle {
    margin-left: 0;
    margin-right: auto;
    display: flex;
    align-items: center;
    justify-content: flex-start;
}

/* ========================================
   FRIES MENU SYSTEM - FIXED CLOSE ICON POSITIONING
======================================== */

.fries-navigation-toggle {
    position: absolute;
    height: 1px;
    width: 1px;
    overflow: hidden;
    clip: rect(1px, 1px, 1px, 1px);
    white-space: nowrap;
}

.fries-menu-button {
    position: relative;
    width: 48px;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    cursor: pointer;
    z-index: 1002;
    transition: all 0.3s ease;
    background: transparent !important;
    border: none !important;
    box-shadow: none !important;
}

/* Custom SVG Menu Icon */
.fries-menu-button .menu-icon-svg {
    width: 48px;
    height: 48px;
    transition: all 0.3s ease;
    position: absolute;
    left: 0;
    top: 0;
}

.fries-menu-button .menu-icon-svg #rectangle {
    fill: #ffffff;
    transition: fill 0.3s ease;
}

.fries-menu-button:hover .menu-icon-svg #rectangle {
    fill: var(--color-primary);
}

.fries-menu-button .menu-icon-svg path {
    fill: #000000;
    transition: fill 0.3s ease;
}

.fries-menu-button:hover .menu-icon-svg path {
    fill: #ffffff;
}

/* Close Icon Styles - FIXED POSITIONING */
.fries-menu-button .close-icon-svg {
    position: absolute;
    left: 0; /* Exactly aligned with menu icon */
    top: 0;  /* Exactly aligned with menu icon */
    width: 48px;
    height: 48px;
    transition: all 0.3s cubic-bezier(0.215, 0.61, 0.355, 1);
    opacity: 0;
    transform: scale(0.8) rotate(-90deg); /* Start rotated for better animation */
}

.fries-menu-button .close-icon-svg circle {
    stroke: #BFBFBF;
    transition: stroke 0.3s ease;
}

.fries-menu-button:hover .close-icon-svg circle {
    stroke: var(--color-primary);
}

.fries-menu-button .close-icon-svg path {
    stroke: #1C274C;
    transition: stroke 0.3s ease;
}

.fries-menu-button:hover .close-icon-svg path {
    stroke: var(--color-primary);
}

/* Active state - SINGLE BUTTON BEHAVIOR */
.fries-navigation-toggle:checked ~ .fries-menu-button .menu-icon-svg {
    opacity: 0;
    transform: scale(0.8) rotate(90deg);
    pointer-events: none;
}

.fries-navigation-toggle:checked ~ .fries-menu-button .close-icon-svg {
    opacity: 1;
    transform: scale(1) rotate(0deg);
    pointer-events: auto;
}

/* Fries Navigation Overlay */
.fries-navigation {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: #ededed;
    transform: translateY(-100%);
    transition: transform 0.4s cubic-bezier(0.215, 0.61, 0.355, 1);
    z-index: 1001;
    overflow-y: auto;
}

.fries-nav-content {
    padding: 90px var(--spacing-xl) var(--spacing-xl);
    max-width: 1200px;
    margin: 0 auto;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

.fries-nav-grid {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    gap: 78px;
    flex: 1;
}

.fries-nav-column {
    display: flex;
    flex-direction: column;
}

.fries-nav-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.fries-nav-item {
    margin-bottom: 8px;
    position: relative;
}

.fries-nav-link {
    font-family: 'Helvetica Now Text', 'Helvetica Neue', Helvetica, Arial, sans-serif;
    font-size: 48px;
    font-weight: var(--font-weight-medium);
    color: #c6c6c6;
    text-decoration: none;
    line-height: auto;
    letter-spacing: 0%;
    transition: color 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: flex-start;
    gap: 12px;
    transform: translateY(100%);
    opacity: 0;
}

.fries-nav-link:hover,
.fries-nav-link.active {
    color: var(--color-primary);
}

.fries-nav-link.has-dropdown {
    cursor: pointer;
}

/* Dropdown Arrow */
.dropdown-arrow {
    transition: transform 0.3s ease;
    justify-content: center;
    display: flex;
    align-items: center;
}

.dropdown-arrow svg {
    width: 46px;
    height: 46px;
    fill: #c6c6c6;
    transition: all 0.4s ease;
    transform-origin: center center;
}

.fries-nav-link.has-dropdown:hover .dropdown-arrow {
    transform: rotate(45deg);
}

.fries-nav-link.has-dropdown:hover .dropdown-arrow svg {
    fill: var(--color-primary);
}

.fries-nav-link .dropdown-arrow svg {
    justify-content: center;
}

/* Dropdown System */
.fries-dropdown {
    margin-left: var(--spacing-xl);
    margin-top: var(--spacing-lg);
    opacity: 0;
    max-height: 0;
    overflow: hidden;
    transition: all 0.3s ease;
}

.fries-dropdown.active {
    opacity: 1;
    max-height: 300px;
}

.fries-dropdown-item {
    display: block;
    font-family: 'Helvetica Now Text', 'Helvetica Neue', Helvetica, Arial, sans-serif;
    font-size: 36px;
    font-weight: var(--font-weight-medium);
    color: #c6c6c6;
    text-decoration: none;
    padding: var(--spacing-md) 0;
    transition: color 0.3s ease;
    line-height: 1.2;
}

.fries-dropdown-item:hover,
.fries-dropdown-item.active {
    color: var(--color-primary);
}

/* Social Media Section */
.fries-social-section {
    margin-top: auto;
    padding-top: var(--spacing-xl);
}

.fries-social-divider {
    width: 100%;
    height: 2px;
    background: var(--color-primary);
    margin-bottom: var(--spacing-lg);
}

.fries-social-title {
    font-family: 'Helvetica Now Text', 'Helvetica Neue', Helvetica, Arial, sans-serif;
    font-size: 28px;
    font-weight: var(--font-weight-medium);
    line-height: 34px;
    letter-spacing: -0.68%;
    color: var(--color-primary);
    margin-bottom: var(--spacing-md);
}

.fries-social-icons {
    display: flex;
    gap: var(--spacing-lg);
    margin-bottom: var(--spacing-lg);
    flex-wrap: wrap;
    align-items: center;
}

.fries-social-link {
    transition: transform 0.3s ease;
    display: block;
}

.fries-social-link svg {
    width: 34px;
    height: 34px;
    transition: all 0.3s ease;
}

.fries-social-link:hover {
    transform: translateY(-3px);
}

.fries-social-link:hover svg path {
    fill: var(--color-primary);
}

.fries-contact-info p {
    color: var(--color-text-secondary);
    font-size: 1rem;
    margin: 0;
}

/* Active States */
.fries-navigation-toggle:checked ~ .fries-navigation {
    transform: translateY(0);
}

.fries-navigation-toggle:checked ~ .fries-navigation .fries-nav-link {
    animation: friesLinkAppear 0.6s cubic-bezier(0.215, 0.61, 0.355, 1) forwards;
}

.fries-navigation-toggle:checked ~ .fries-navigation .fries-nav-item:nth-child(1) .fries-nav-link {
    animation-delay: 0.1s;
}

.fries-navigation-toggle:checked ~ .fries-navigation .fries-nav-item:nth-child(2) .fries-nav-link {
    animation-delay: 0.2s;
}

.fries-navigation-toggle:checked ~ .fries-navigation .fries-nav-item:nth-child(3) .fries-nav-link {
    animation-delay: 0.3s;
}

.fries-navigation-toggle:checked ~ .fries-navigation .fries-nav-item:nth-child(4) .fries-nav-link {
    animation-delay: 0.4s;
}

/* Right column animation delays */
.fries-nav-column:nth-child(2) .fries-nav-item:nth-child(1) .fries-nav-link {
    animation-delay: 0.15s !important;
}

.fries-nav-column:nth-child(2) .fries-nav-item:nth-child(2) .fries-nav-link {
    animation-delay: 0.25s !important;
}

.fries-nav-column:nth-child(2) .fries-nav-item:nth-child(3) .fries-nav-link {
    animation-delay: 0.35s !important;
}

.fries-nav-column:nth-child(2) .fries-nav-item:nth-child(4) .fries-nav-link {
    animation-delay: 0.45s !important;
}

@keyframes friesLinkAppear {
    0% {
        transform: translateY(100%);
        opacity: 0;
    }
    100% {
        transform: translateY(0);
        opacity: 1;
    }
}

/* Back to Top Button */
.scroll-top-btn {
    position: fixed;
    bottom: 120px;
    right: 20px;
    width: 50px;
    height: 50px;
    background: transparent;
    color: var(--color-primary);
    border: 2px solid var(--color-primary);
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    opacity: 0;
    visibility: hidden;
    transform: translateY(20px) scale(0.8);
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: 1000;
}

.scroll-top-btn.visible {
    opacity: 1;
    visibility: visible;
    transform: translateY(0) scale(1);
}

.scroll-top-btn:hover {
    background: var(--color-primary);
    color: var(--color-text-white);
    transform: translateY(-3px) scale(1.1);
    box-shadow: 0 8px 25px rgba(227, 0, 27, 0.3);
    animation: pulse 1.5s infinite;
}

@keyframes pulse {
    0% { box-shadow: 0 0 0 0 rgba(227, 0, 27, 0.7); }
    70% { box-shadow: 0 0 0 10px rgba(227, 0, 27, 0); }
    100% { box-shadow: 0 0 0 0 rgba(227, 0, 27, 0); }
}

/* Chat Placeholder */
.chat-placeholder {
    position: fixed;
    bottom: 20px;
    right: 20px;
    width: 60px;
    height: 60px;
    pointer-events: none;
}

/* Utility Classes */
.desktop-only { display: none !important; }
.mobile-only { display: block !important; }

/* Remove any body padding that might be added for fixed header */
body {
    padding-top: 0 !important;
}

/* If your content needs spacing from the header, add it to your main content instead */
.main-content,
.page-content,
main {
    padding-top: 80px; /* Adjust based on your header height */
}

/* ========================================
   RESPONSIVE DESIGN 
======================================== */

/* Desktop (1024px and above) - FORCED Right Alignment Fix */
@media screen and (min-width: 1024px) {
    /* Remove header wrapper constraints */
    .site-header {
        padding: 0 !important;
        width: 100% !important;
    }
    
    .header-wrapper {
        max-width: none !important;
        padding: 0 !important;
        width: 100% !important;
        margin: 0 !important;
    }
    
    /* Force mobile layout to match content container */
    .mobile-header-layout {
        max-width: 1400px !important; /* Match your content width */
        margin: 0 auto !important; /* Center the container */
        padding: 25px 10px !important; /* Content padding */
        width: calc(100% - 100px) !important; /* Account for padding */
        box-sizing: border-box !important;
        position: relative !important;
        display: flex !important;
        justify-content: space-between !important;
        align-items: center !important;
    }
    
    /* Force logo to left */
    .mobile-header-layout .brand-logo {
        flex: 0 0 auto !important;
        order: 1 !important;
        margin: 0 !important;
        position: relative !important;
        left: 0 !important;
    }
    
    /* Force fries menu to right */
    .mobile-header-layout .fries-menu-toggle {
        flex: 0 0 auto !important;
        order: 2 !important;
        margin: 0 !important;
        margin-left: auto !important;
        position: relative !important;
        right: 0 !important;
    }
    
    .logo-img {
        height: 60px !important;
    }
    
    /* Override any existing positioning */
    .fries-menu-button {
        position: relative !important;
        right: 0 !important;
        margin: 0 !important;
    }
    
    /* Alternative: If content container is different width, try these values */
    /* Uncomment and adjust the max-width value to match your content */
    /*
    .mobile-header-layout {
        max-width: 1140px !important;
        max-width: 1320px !important;
        max-width: 100% !important;
    }
    */
}

/* Tablet Styles (768px - 1023px) */
@media screen and (min-width: 768px) and (max-width: 1023px) {
    .mobile-header-layout {
        padding: 22px 40px !important;
        gap: 580px; /* Add gap between logo and menu */
    }

    .logo-img {
        height: 42px !important;
        width: 100px;
    }
    /*Modification for better alignment*/
     .fries-nav-item {
        margin-bottom: 8px !important; /* Equal spacing between all nav items */
    }

    .fries-nav-link {
        font-size: 38px !important;
        line-height: 44px !important;
        padding: 8px 0 !important; /* Equal padding for all nav links */
    }

    

    /* Equal spacing between navigation sections */
    .fries-nav-column {
        margin-bottom: 8px !important; /* Equal space between sections */
    }
    /*End of modification*/

    /* Navigation grid for tablet */
    .fries-nav-grid {
        grid-template-columns: 1fr;
        gap: 0px;
    }

    .fries-nav-content {
        padding: 80px 20px 20px 80px;
    }

    .fries-nav-link {
        font-size: 36px;
        line-height: 43px;
    }

    .fries-dropdown-item {
        font-size: 24px;
        line-height: 1.3;
    }

    .fries-social-title {
        font-size: 20px;
        line-height: 24px;
    }

    .fries-social-link svg {
        width: 24px !important;
        height: 24px !important;
    }

    .scroll-top-btn {
        bottom: 90px;
        width: 40px;
        height: 40px;
        font-size: 14px;
        right: 15px;
    }

    .dropdown-arrow svg {
        width: 20px !important;
        height: 20px !important;
    }
}

/* Mobile (max-width: 767px) - WHITE BACKGROUND ON MOBILE */
@media screen and (max-width: 767px) {
    /* Add white background on mobile only */
    .site-header {
        background: #ffffff !important; /* White background on mobile */
        box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1) !important; /* Subtle shadow on mobile */
    }
    
    .mobile-header-layout {
        padding: 15px 20px !important;
        background: #ffffff !important; /* Ensure white background */
        gap: 280px; /* Add gap between logo and menu */
    }

    .logo-img {
        width: 70px;
        height: 35px !important; /* Smaller on mobile */
    }


    /*Modification for better alignment*/
    .fries-nav-item {
        margin-bottom: 8px !important; /* Equal spacing between all nav items */
    }

    .fries-nav-link {
        padding: 8px 0 !important; /* Equal padding for all nav links */
    }

    .fries-dropdown-item {
        padding: 10px 0 !important; /* Equal padding for dropdown items */
        margin-bottom: 8px !important; /* Equal spacing between dropdown items */
    }

    /* Equal spacing between navigation sections */
    .fries-nav-column {
        margin-bottom: 8px !important; /* Equal space between sections */
    }
    /*End of modification*/

    /* Navigation grid for mobile */
    .fries-nav-grid {
        grid-template-columns: 1fr;
        gap: 0px;
    }

    .fries-nav-content {
        padding: 80px var(--spacing-md) var(--spacing-md);
    }

    .fries-nav-link {
        font-size: 36px;
        line-height: 43px;
    }

    .fries-dropdown-item {
        font-size: 24px;
        line-height: 1.3;
    }

    .fries-social-title {
        font-size: 20px;
        line-height: 24px;
    }

    .fries-social-link svg {
        width: 24px !important;
        height: 24px !important;
    }

    .scroll-top-btn {
        bottom: 90px;
        width: 40px;
        height: 40px;
        font-size: 14px;
        right: 15px;
    }

    .dropdown-arrow svg {
        width: 20px !important;
        height: 20px !important;
    }

    /* Mobile icon sizing */
    .fries-menu-button .menu-icon-svg,
    .fries-menu-button .close-icon-svg {
        width: 34px;
        height: 34px;
    }
    
    .fries-menu-button {
        width: 40px;
        height: 40px;
    }
}

/* Extra Small Mobile (max-width: 480px) */
@media screen and (max-width: 480px) {
    .logo-img {
        width: 60px;
    }

    .fries-menu-button .menu-icon-svg,
    .fries-menu-button .close-icon-svg {
        width: 32px;
        height: 32px;
    }
    
    .fries-menu-button {
        width: 36px;
        height: 36px;
    }
    .mobile-header-layout .fries-menu-toggle {
        margin-right: 15px !important; /* More space on very small screens */
    }
}

@media screen and (max-width: 390px) {
    .mobile-header-layout {
        gap: 245px; /* Add gap between logo and menu */
    }
    .mobile-header-layout .fries-menu-toggle {
        margin-right: 10px !important; /* More space on very small screens */
    }
}