/* ═══════════════════════════════════════════════════════════════
   Sticky Header Styles
   ═══════════════════════════════════════════════════════════════ */

.sticky-header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    transition: transform 0.3s ease, opacity 0.3s ease;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    /* Hidden by default - shown on scroll */
    transform: translateY(-100%);
    opacity: 0;
    pointer-events: none;
}

.sticky-header.is-visible {
    transform: translateY(0);
    opacity: 1;
    pointer-events: auto;
}

.sticky-header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.75rem 1.5rem;
    max-width: var(--sf-container, 1320px);
    margin: 0 auto;
}

/* ─── Icons on Left Layout ─── */
.sticky-header.icons-left .sticky-header-inner {
    flex-direction: row;
}

.sticky-header.icons-left .sticky-icons-left {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.sticky-header.icons-left .sticky-nav {
    flex: 1;
    display: flex;
    justify-content: flex-end;
}

/* ─── Icons on Right Layout (Default) ─── */
.sticky-header.icons-right .sticky-left {
    display: flex;
    align-items: center;
    gap: 2rem;
    flex: 1;
}

.sticky-header.icons-right .sticky-icons-right {
    display: flex;
    gap: 1rem;
}

/* ─── No Icons Layout (show_left_icons = false) ─── */
.sticky-left--full {
    display: flex;
    align-items: center;
    gap: 2rem;
    width: 100%;
}

.sticky-left--full .sticky-nav {
    flex: 1;
}

/* ─── Logo Styling ─── */
.sticky-logo {
    display: flex;
    align-items: center;
}

.sticky-logo img {
    display: block;
    object-fit: contain;
}

/* ─── Icon Styling ─── */
.sticky-cart-icon,
.sticky-account-icon {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    transition: background 0.2s ease;
    text-decoration: none;
    color: inherit;
}

.sticky-cart-icon:hover,
.sticky-account-icon:hover {
    background: rgba(0, 0, 0, 0.05);
}

.sticky-cart-icon i,
.sticky-account-icon i {
    font-size: 20px;
}

/* ─── Cart Count Badge ─── */
.cart-count {
    position: absolute;
    top: -4px;
    right: -4px;
    background: #e74c3c;
    color: white;
    font-size: 11px;
    font-weight: 600;
    padding: 2px 6px;
    border-radius: 10px;
    min-width: 18px;
    text-align: center;
    line-height: 1.2;
}

/* ─── Navigation Styling ─── */
.sticky-nav {
    display: flex;
    align-items: center;
    flex: 1;
}

.sticky-nav ul {
    display: flex;
    list-style: none;
    margin: 0;
    padding: 0;
    gap: 0.5rem;
}

.sticky-nav li {
    margin: 0;
    position: relative;
}

.sticky-nav a,
.sticky-nav-link {
    text-decoration: none;
    padding: 0.5rem 1rem;
    border-radius: 4px;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    gap: 0.25rem;
    /* LCNB nav item background from CSS variable, default to transparent */
    background: var(--sticky-nav-item-bg, transparent);
}

/* Hover & Active states using CSS variables */
.sticky-nav a:hover,
.sticky-nav-link:hover {
    background: var(--sticky-nav-hover-bg, rgba(0,0,0,0.05));
    color: var(--sticky-nav-hover, inherit);
}

.sticky-nav li.active > a,
.sticky-nav li.active > .sticky-nav-link,
.sticky-nav li > a.active,
.sticky-nav li > .sticky-nav-link.active {
    background: var(--sticky-nav-active-bg, transparent);
    color: var(--sticky-nav-active, inherit);
}

/* Dropdown support */
.sticky-nav li.has-dropdown {
    position: relative;
}

.sticky-nav li.has-dropdown:hover .sf-nav-dropdown {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.sticky-nav .sf-nav-dropdown {
    position: absolute;
    top: 100%;
    left: 0;
    background: white;
    border: 1px solid #e5e5e5;
    border-radius: 4px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    min-width: 200px;
    padding: 0.5rem 0;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: all 0.2s ease;
    z-index: 1001;
}

.sticky-nav .sf-nav-dropdown a {
    display: block;
    padding: 0.5rem 1rem;
    border-radius: 0;
    color: #333;
}

.sticky-nav .sf-nav-dropdown a:hover {
    background: #f5f5f5;
}

.sticky-nav .sf-nav-badge {
    font-size: 10px;
    padding: 2px 6px;
    border-radius: 10px;
    color: white;
    font-weight: 600;
}

/* ─── Responsive ─── */
@media (max-width: 768px) {
    /* Mobilde sticky header tamamen gizlenir */
    .sticky-header {
        display: none !important;
    }
}

@media (min-width: 769px) {
    .sticky-header-inner {
        padding: 0.5rem 1rem;
    }
    
    .sticky-header.icons-left .sticky-icons-left {
        gap: 1rem;
    }
    
    .sticky-header.icons-right .sticky-left {
        gap: 1rem;
    }
    
    .sticky-cart-icon,
    .sticky-account-icon {
        width: 36px;
        height: 36px;
    }
}
