/**
 * TWN Webflow Menu - CSS Styles
 * Extracted and optimized from the live site's Webflow CSS
 * 
 * This stylesheet replicates the Webflow navigation behavior for use in Elementor
 */

/* ==========================================================================
   CSS Variables (matching live site)
   ========================================================================== */
:root {
    --twn-white: #fff;
    --twn-black: #000;
    --twn-nav-width: 500px;
    --twn-transition-speed: 400ms;
}

/* ==========================================================================
   Webflow Core Navigation Styles
   ========================================================================== */

/* Dropdown Container */
.w-dropdown {
    text-align: left;
    z-index: 900;
    margin-left: auto;
    margin-right: auto;
    display: inline-block;
    position: relative;
}

/* Dropdown Button/Toggle/Link base styles */
.w-dropdown-btn,
.w-dropdown-toggle,
.w-dropdown-link {
    vertical-align: top;
    color: #222;
    text-align: left;
    white-space: nowrap;
    margin-left: auto;
    margin-right: auto;
    padding: 20px;
    text-decoration: none;
    position: relative;
}

/* Dropdown Toggle */
.w-dropdown-toggle {
    -webkit-user-select: none;
    user-select: none;
    cursor: pointer;
    padding-right: 40px;
    display: inline-block;
}

.w-dropdown-toggle:focus {
    outline: 0;
}

/* Dropdown Arrow Icon */
.w-icon-dropdown-toggle {
    width: 12px;
    height: 12px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    position: relative;
    margin-left: 5px;
}

.w-icon-dropdown-toggle::before {
    content: "";
    border-style: solid;
    border-width: 5px 5px 0 5px;
    border-color: #222 transparent transparent transparent;
    display: block;
    transition: transform 0.3s ease;
}

/* Rotate arrow when open */
.w-dropdown.w--open .w-icon-dropdown-toggle::before,
.w-dropdown-toggle.w--open .w-icon-dropdown-toggle::before {
    transform: rotate(180deg);
}

/* Dropdown List (submenu) - static in slide-in menu */
.w-dropdown-list {
    background: transparent;
    min-width: 100%;
    display: none;
    position: static;
}

.w-dropdown-list.w--open {
    display: block;
}

/* Dropdown Link */
.w-dropdown-link {
    color: #222;
    padding: 10px 20px;
    display: block;
}

.w-dropdown-link.w--current {
    color: #0082f3;
}

.w-dropdown-link:focus {
    outline: 0;
}

/* ==========================================================================
   Navigation Menu
   ========================================================================== */

.w-nav-menu {
    float: right;
    position: relative;
}

/* Override default webflow nav-menu-open - we handle this in .navigation-items */
[data-nav-menu-open] {
    text-align: center;
}

/* Specific override for our navigation panel */
.twn-webflow-menu-wrapper .navigation-items[data-nav-menu-open] {
    position: fixed !important;
    top: 0 !important;
    right: 0 !important;
    left: auto !important;
    bottom: 0 !important;
    transform: translateX(0) !important;
}
nav.navigation-items.w-nav-menu {
    justify-content: flex-start;
    padding-top: 130px;
}

.w--nav-link-open {
    display: block;
    position: relative;
}

.w-nav-overlay {
    width: 100%;
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    overflow: hidden;
}

.w-nav-overlay [data-nav-menu-open] {
    top: 0;
}

/* Over-right animation (slide from right) */
.w-nav[data-animation="over-right"] .w-nav-overlay {
    width: auto;
}

.w-nav[data-animation="over-right"] .w-nav-overlay,
.w-nav[data-animation="over-right"] [data-nav-menu-open] {
    z-index: 1;
    top: 0;
    left: auto;
}

/* Nav Button (hamburger) */
.w-nav-button {
    float: right;
    cursor: pointer;
    -webkit-tap-highlight-color: transparent;
    tap-highlight-color: transparent;
    -webkit-user-select: none;
    user-select: none;
    padding: 18px;
    font-size: 24px;
    display: none;
    position: relative;
}

.w-nav-button:focus {
    outline: 0;
}

.w-nav-button.w--open {
    color: #fff;
    background-color: #c8c8c8;
}

/* Collapse states */
.w-nav[data-collapse="all"] .w-nav-menu {
    display: none;
}

.w-nav[data-collapse="all"] .w-nav-button,
.w--nav-dropdown-open,
.w--nav-dropdown-toggle-open {
    display: block;
}

.w--nav-dropdown-list-open {
    position: static;
}

/* ==========================================================================
   TWN Custom Navigation Panel (Slide-in from right)
   ========================================================================== */

/* Main navigation panel - slide from RIGHT */
.twn-webflow-menu-wrapper .navigation-items,
.navigation-items.w-nav-menu {
    z-index: 1001;
    gap: 0;
    background-color: #fff !important;
    flex-direction: column;
    flex: none;
    justify-content: center;
    align-items: center;
    width: 320px;
    max-width: 90vw;
    height: 100vh;
    padding-top: 40px;
    padding-bottom: 40px;
    padding-left: 30px;
    padding-right: 30px;
    display: flex;
    position: fixed !important;
    top: 0 !important;
    right: 0 !important;
    bottom: 0 !important;
    left: auto !important;
    transform: translateX(100%);
    transition: transform 400ms ease;
    overflow-y: auto;
    box-shadow: -5px 0 30px rgba(0, 0, 0, 0.15);
}

/* ==========================================================================
   TWN Custom Menu Item Styles
   ========================================================================== */

/* Dropdown parent text */
.text-block-2 {
    font-family: Poppins, sans-serif;
    font-style: normal;
    font-weight: 700;
    font-size: 16px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: #222;
}

/* Dropdown containers */
.dropdown,
.dropdown-2 {
    flex-direction: column;
    display: flex;
    width: 100%;
}

/* Dropdown toggle button */
.dropdown-toggle,
.dropdown-toggle-2,
.w-dropdown-toggle {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px 0;
    cursor: pointer;
    width: 100%;
    text-align: center;
    background: transparent;
    border: none;
    gap: 6px;
    flex-direction: row;
}

/* Put the icon AFTER the text (on the right) */
.w-dropdown-toggle .w-icon-dropdown-toggle {
    order: 2;
}

.w-dropdown-toggle .text-block-2 {
    order: 1;
}

.w-dropdown-toggle:hover .text-block-2 {
    opacity: 0.73;
}

/* Simple link items (non-dropdown) - matching dropdown toggle style */
.link {
    text-transform: uppercase;
    padding: 20px 0;
    font-family: Poppins, sans-serif;
    font-style: normal;
    font-weight: 700;
    font-size: 16px;
    text-decoration: none;
    color: #222;
    display: block;
    text-align: center;
    width: 100%;
    letter-spacing: 0.5px;
    transition: color 0.3s ease, opacity 0.3s ease;
}

.link:hover {
    opacity: 0.73;
    color: #000;
}

/* Dropdown list (submenu) */
.dropdown-list {
    background-color: transparent;
    padding: 0;
    display: none;
    width: 100%;
}

.dropdown-list.w--open {
    display: block;
}

/* Dropdown child links */
.dropdown-link {
    text-align: center;
    display: block;
    padding: 10px 20px;
    font-family: Poppins, sans-serif;
    font-size: 16px;
    font-weight: 300;
	text-transform: uppercase;
    color: #555;
    text-decoration: none;
    transition: color 0.3s ease, opacity 0.3s ease;
}

.dropdown-link:hover {
    opacity: 0.73;
    color: #000;
}

/* ==========================================================================
   Menu Wrapper Styles
   ========================================================================== */

.twn-webflow-menu-wrapper {
    position: static;
}

/* Menu overlay when open */
.twn-menu-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    z-index: 999;
    opacity: 0;
    visibility: hidden;
    transition: opacity var(--twn-transition-speed) ease, visibility var(--twn-transition-speed) ease;
}

body.twn-menu-open .twn-menu-overlay {
    opacity: 1;
    visibility: visible;
}

/* Hamburger button - Circle style like live site */
.twn-menu-button {
    cursor: pointer;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 5px;
    z-index: 1002;
    position: fixed;
    top: 20px;
    right: 20px;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background-color: #fff;
    border: none;
    padding: 0;
    transition: background-color 0.3s ease;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
}

.twn-menu-button:hover {
    background-color: #f5f5f5;
}

/* Default/Closed state: WHITE circle with DARK GRAY lines */
.twn-menu-button span {
    display: block;
    width: 18px;
    height: 2px;
    background-color: #555;
    transition: background-color 0.3s ease;
}

/* Open/Activated state: GRAY circle with WHITE lines */
.twn-menu-button.w--open {
    background-color: #666;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.25);
}

.twn-menu-button.w--open:hover {
    background-color: #777;
}

.twn-menu-button.w--open span {
    background-color: #fff;
}

/* ==========================================================================
   Responsive Styles
   ========================================================================== */

@media screen and (max-width: 991px) {
    .navigation-items {
        width: 100%;
        min-width: 100%;
    }
    
    .w-nav[data-collapse="medium"] .w-nav-menu {
        display: none;
    }

    .w-nav[data-collapse="medium"] .w-nav-button {
        display: block;
    }
}

@media screen and (max-width: 767px) {
    .w-nav[data-collapse="small"] .w-nav-menu {
        display: none;
    }

    .w-nav[data-collapse="small"] .w-nav-button {
        display: block;
    }

    .w-nav-brand {
        padding-left: 10px;
    }
    
    .navigation-items {
        background-color: #fff;
    }
}

@media screen and (max-width: 479px) {
    .w-nav[data-collapse="tiny"] .w-nav-menu {
        display: none;
    }

    .w-nav[data-collapse="tiny"] .w-nav-button {
        display: block;
    }
}
