/**
 * Iris Custom Header - Frontend Styles
 * All styles scoped to .iris-custom-header to prevent conflicts
 */

/* ========================================
   HEADER CONTAINER
   ======================================== */
.iris-custom-header {
    background: transparent;
    border-bottom: none;
    padding: 0;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    transition: all 0.3s ease;
}

.iris-custom-header-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 20px 40px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 48px;
}

/* ========================================
   LOGO
   ======================================== */
.iris-header-logo {
    flex-shrink: 0;
}

.iris-header-logo a {
    display: block;
    text-decoration: none;
}

.iris-header-logo img {
    max-height: 78px;
    width: auto;
    display: block;
}

.iris-header-site-title {
    font-size: 28px;
    font-weight: 700;
    color: #86b255;
    text-decoration: none;
}

/* ========================================
   DESKTOP NAVIGATION
   ======================================== */
.iris-header-nav {
    flex: 1;
    display: flex;
    justify-content: center;
    background: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-radius: 50px;
    padding: 12px 32px;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.08);
}

.iris-header-menu {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    gap: 32px;
    align-items: center;
}

.iris-header-menu li {
    margin: 0;
    padding: 0;
}

.iris-header-menu a {
    color: #333333;
    text-decoration: none;
    font-size: 16px;
    font-weight: 500;
    transition: color 0.2s ease;
    padding: 8px 0;
    display: block;
    position: relative;
}

.iris-header-menu a::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background: #86b255;
    transition: width 0.3s ease;
}

.iris-header-menu a:hover {
    color: #86b255;
}

.iris-header-menu a:hover::after {
    width: 100%;
}

.iris-header-menu .current-menu-item a,
.iris-header-menu .current_page_item a {
    color: #86b255;
    font-weight: 600;
}

.iris-header-menu .current-menu-item a::after,
.iris-header-menu .current_page_item a::after {
    width: 100%;
}

/* ========================================
   RIGHT SECTION (Social + Auth)
   ======================================== */
.iris-header-right {
    display: flex;
    align-items: center;
    gap: 20px;
    flex-shrink: 0;
    background: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-radius: 50px;
    padding: 12px 24px;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.08);
}

/* Social Icons */
.iris-header-social {
    display: flex;
    gap: 12px;
    align-items: center;
}

.iris-header-social a {
    color: #666666;
    transition: color 0.2s ease, transform 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
}

.iris-header-social a:hover {
    color: #86b255;
    transform: translateY(-2px);
}

.iris-header-social svg {
    width: 20px;
    height: 20px;
}

/* Auth Button Container */
.iris-header-auth {
    display: flex;
}

/* ========================================
   MOBILE MENU TOGGLE
   ======================================== */
.iris-header-mobile-toggle {
    display: none;
    flex-direction: column;
    gap: 5px;
    background: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-radius: 50px;
    padding: 12px 16px;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.08);
    border: none;
    cursor: pointer;
    z-index: 1001;
    transition: all 0.3s ease;
}

.iris-header-mobile-toggle:hover {
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.12);
}

.iris-hamburger {
    width: 24px;
    height: 2px;
    background: #333333;
    transition: all 0.3s ease;
    display: block;
}

.iris-header-mobile-toggle[aria-expanded="true"] .iris-hamburger:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px);
}

.iris-header-mobile-toggle[aria-expanded="true"] .iris-hamburger:nth-child(2) {
    opacity: 0;
}

.iris-header-mobile-toggle[aria-expanded="true"] .iris-hamburger:nth-child(3) {
    transform: rotate(-45deg) translate(6px, -6px);
}

/* ========================================
   MOBILE MENU DRAWER
   ======================================== */
.iris-header-mobile-menu {
    position: fixed;
    top: 0;
    right: -100%;
    width: 280px;
    height: 100vh;
    background: #ffffff;
    box-shadow: -4px 0 16px rgba(0, 0, 0, 0.1);
    transition: right 0.3s ease;
    z-index: 999;
    overflow-y: auto;
    padding: 80px 24px 24px;
}

.iris-header-mobile-menu[aria-hidden="false"] {
    right: 0;
}

.iris-mobile-nav {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

.iris-mobile-menu-list {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.iris-mobile-menu-list li {
    margin: 0;
    padding: 0;
}

.iris-mobile-menu-list a {
    color: #333333;
    text-decoration: none;
    font-size: 18px;
    font-weight: 500;
    padding: 12px 0;
    display: block;
    border-bottom: 1px solid #f0f0f0;
    transition: color 0.2s ease;
}

.iris-mobile-menu-list a:hover {
    color: #86b255;
}

.iris-mobile-menu-list .current-menu-item a,
.iris-mobile-menu-list .current_page_item a {
    color: #86b255;
    font-weight: 600;
}

/* Mobile Social Icons */
.iris-mobile-social {
    display: flex;
    gap: 16px;
    padding: 16px 0;
    border-top: 1px solid #f0f0f0;
}

.iris-mobile-social a {
    color: #666666;
    transition: color 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
}

.iris-mobile-social a:hover {
    color: #86b255;
}

.iris-mobile-social svg {
    width: 24px;
    height: 24px;
}

/* Mobile Auth Button */
.iris-mobile-auth {
    padding-top: 16px;
}

/* Mobile Overlay */
.iris-header-mobile-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: 998;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
}

.iris-header-mobile-overlay.active {
    opacity: 1;
    visibility: visible;
}

/* ========================================
   RESPONSIVE BREAKPOINTS
   ======================================== */
@media (max-width: 768px) {
    .iris-custom-header-container {
        padding: 16px 20px;
    }

    /* Hide desktop nav and right section completely */
    .iris-header-nav {
        display: none !important;
    }

    .iris-header-right {
        display: none !important;
    }

    /* Show mobile toggle */
    .iris-header-mobile-toggle {
        display: flex !important;
    }
}

@media (min-width: 769px) {

    /* Hide mobile menu on desktop */
    .iris-header-mobile-menu {
        display: none !important;
    }
}

/* ========================================
   ACCESSIBILITY
   ======================================== */
.iris-custom-header a:focus,
.iris-header-mobile-toggle:focus {
    outline: none;
    box-shadow: none;
}

/* Add focus states to match hover */
.iris-header-menu a:focus {
    color: #86b255;
}

.iris-header-menu a:focus::after {
    width: 100%;
}

.iris-header-social a:focus {
    color: #86b255;
    transform: translateY(-2px);
}

/* Skip to content link for screen readers */
.iris-header-skip-link {
    position: absolute;
    top: -40px;
    left: 0;
    background: #86b255;
    color: #ffffff;
    padding: 8px 16px;
    text-decoration: none;
    z-index: 100;
}

.iris-header-skip-link:focus {
    top: 0;
}

/* ========================================
   WOOCOMMERCE COMPATIBILITY
   ======================================== */
/* Add padding to WooCommerce pages to prevent content hiding under fixed header */
body.woocommerce-cart,
body.woocommerce-checkout,
body.woocommerce-account {
    padding-top: 100px;
}

/* Ensure WooCommerce content doesn't overlap with header */
.woocommerce,
.woocommerce-page {
    position: relative;
    z-index: 1;
}

/* Fix WooCommerce notices positioning */
.woocommerce-notices-wrapper {
    margin-top: 20px;
}

/* Mobile WooCommerce adjustments */
@media (max-width: 768px) {

    body.woocommerce-cart,
    body.woocommerce-checkout,
    body.woocommerce-account {
        padding-top: 80px;
    }
}