/* 7wears & VOID CLUB Luxury Header & Sleek Glass Search Bar */

/* Header Glow & Elevated Frosted Glass */
.site-header {
    background: transparent !important;
    border-bottom: none !important;
    box-shadow: none !important;
    position: fixed !important;
    top: 48px !important;
    left: 0 !important;
    width: 100% !important;
    z-index: 995 !important;
    pointer-events: none !important;
    margin: 0 !important;
    padding: 0 !important;
    transition: all 0.35s cubic-bezier(0.16, 1, 0.3, 1) !important;
}

.site-header.scrolled {
    top: 12px !important;
}

.header-container {
    pointer-events: auto !important;
    background: rgba(18, 18, 26, 0.82) !important;
    backdrop-filter: blur(25px) saturate(180%) !important;
    -webkit-backdrop-filter: blur(25px) saturate(180%) !important;
    border: 1px solid rgba(255, 255, 255, 0.12) !important;
    box-shadow: 0 10px 35px rgba(0, 0, 0, 0.6) !important;
}

/* Nav links with anime cyberpunk hover underline */
.nav-link {
    position: relative;
    font-weight: 700;
    font-size: 14px;
    letter-spacing: 0.02em;
    color: rgba(255, 255, 255, 0.75);
    transition: color 0.25s ease;
    padding: 6px 4px;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 50%;
    width: 0;
    height: 2px;
    background: linear-gradient(90deg, #990000, #00f0ff);
    box-shadow: 0 0 8px #990000;
    transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
    transform: translateX(-50%);
    border-radius: 2px;
}

.nav-link:hover {
    color: #ffffff;
}

.nav-link:hover::after {
    width: 100%;
}

/* Redesigned Search Modal (7wears Luxury Glass Style) */
.search-modal-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    max-width: 100vw;
    box-sizing: border-box;
    background: rgba(8, 8, 12, 0.88);
    backdrop-filter: blur(35px) saturate(200%);
    -webkit-backdrop-filter: blur(35px) saturate(200%);
    z-index: 1100;
    transform: translateY(-100%);
    opacity: 0;
    visibility: hidden;
    transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.3s ease, visibility 0.4s;
    border-bottom: 1px solid rgba(153, 0, 0, 0.3);
    box-shadow: 0 25px 60px rgba(0, 0, 0, 0.9), 0 0 30px rgba(153, 0, 0, 0.15);
    overflow: visible;
}

.search-modal-container.open {
    transform: translateY(0);
    opacity: 1;
    visibility: visible;
}

.search-modal-inner {
    display: flex;
    align-items: center;
    height: 96px;
    gap: 20px;
    position: relative;
}

.search-bar-shell {
    flex: 1;
    display: flex;
    align-items: center;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 12px;
    padding: 6px 18px;
    gap: 14px;
    transition: all 0.3s ease;
}

.search-bar-shell:focus-within {
    background: rgba(255, 255, 255, 0.08);
    border-color: #990000;
    box-shadow: 0 0 20px rgba(153, 0, 0, 0.3);
}

.search-modal-icon {
    font-size: 22px;
    color: #990000;
    filter: drop-shadow(0 0 6px rgba(153, 0, 0, 0.6));
    animation: searchPulse 2s infinite;
}

@keyframes searchPulse {
    0%, 100% { transform: scale(1); opacity: 0.9; }
    50% { transform: scale(1.1); opacity: 1; filter: drop-shadow(0 0 10px #990000); }
}

.search-modal-input {
    flex: 1;
    background: transparent;
    border: none;
    outline: none;
    font-size: 18px;
    font-weight: 700;
    color: #ffffff;
    text-align: right;
    font-family: inherit;
    padding: 10px 0;
}

.search-modal-input::placeholder {
    color: rgba(255, 255, 255, 0.4);
    font-weight: 500;
}

.search-modal-close {
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 50%;
    width: 44px;
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #ffffff;
    font-size: 18px;
    cursor: pointer;
    transition: all 0.25s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.search-modal-close:hover {
    background: #990000;
    border-color: #990000;
    transform: rotate(90deg) scale(1.1);
    box-shadow: 0 0 15px rgba(153, 0, 0, 0.6);
}

/* Quick Search Suggestions Tag list */
.search-suggestions-strip {
    display: flex;
    gap: 10px;
    align-items: center;
    padding-bottom: 16px;
    overflow-x: auto;
    max-width: 100%;
    box-sizing: border-box;
}

.search-tag-pill {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    padding: 5px 14px;
    border-radius: 20px;
    font-size: 12px;
    color: rgba(255, 255, 255, 0.7);
    text-decoration: none;
    white-space: nowrap;
    transition: all 0.2s ease;
}

.search-tag-pill:hover {
    background: rgba(153, 0, 0, 0.15);
    border-color: #990000;
    color: #ffffff;
    box-shadow: 0 0 10px rgba(153, 0, 0, 0.2);
}

/* ============ Gooey Search (ported from VengeanceUI gooey-search) ============
   دکمه جمع‌شونده که باز می‌شود + حباب آیکون + نتایج چسبناک که از پشت
   دکمه با stagger بیرون می‌آیند. فیلتر SVG gooey همان فرمول اصلی است:
   blur(5) + color-matrix (18 -15) + composite atop. */
/* ردیف مودال در حالت gooey: باکس سرچ + دکمه بستن کنار هم، بدون هم‌پوشانی */
.gooey-modal-inner {
    display: flex !important;
    align-items: flex-start !important;
    gap: 14px !important;
    height: auto !important;
    padding: 20px 0 10px !important;
}
.gooey-modal-inner .search-modal-close { flex-shrink: 0; margin-top: 2px; }
.gooey-wrap { position: relative; overflow: visible; flex: 1 1 auto; min-width: 0; padding-bottom: 0; transition: padding-bottom 0.35s ease; }
.gooey-filter-defs { position: absolute; width: 0; height: 0; overflow: hidden; }
/* استیج بدون فیلتر + لایه goo فیلتردار فقط برای پس‌زمینه و حباب —
   چیدمان: باکس متن + دایره ذره‌بین جدا کنارش (مثل طرح اصلی gooey-search) */
.gooey-stage { position: relative; width: 100%; display: flex; align-items: center; gap: 12px; }
.gooey-goo {
    position: absolute;
    inset: 0;
    filter: url(#gooey-void);
    -webkit-filter: url(#gooey-void);
    pointer-events: none;
}
.no-gooey .gooey-goo { filter: none; -webkit-filter: none; }
.gooey-blob-btn {
    position: absolute;
    top: 0;
    right: 0;
    height: 100%;
    width: 180px;
    background: #232228;
    border-radius: 14px;
    transition: width 0.75s cubic-bezier(0.34, 1.3, 0.64, 1), background 0.3s ease;
}
.gooey-wrap.expanded .gooey-blob-btn { width: calc(100% - 60px); background: #26262b; animation: gooeyBlobBarIn 0.85s cubic-bezier(0.34, 1.56, 0.64, 1) 0.1s both; }
@keyframes gooeyBlobBarIn {
    from { transform: translateX(30px) scale(0.92); opacity: 0.4; }
    to { transform: translateX(0) scale(1); opacity: 1; }
}

/* لایه رویی (فیلترنشده): لیبل و اینپوت همیشه شارپ.
   پس‌زمینه عمداً شفاف است تا لایه goo پشتی (پل حبابی ذوب‌شونده) دیده شود —
   متن روی لایه شفاف می‌نشیند و زیر فیلتر نیست، پس همیشه خواناست. */
.gooey-button {
    position: relative;
    z-index: 2;
    flex: 1 1 auto;
    min-width: 0;
    background: transparent;
    border: 1px solid transparent;
    border-radius: 14px;
    outline: none !important;
    width: 180px;
    max-width: calc(100% - 60px);
    padding: 12px 22px;
    cursor: pointer;
    letter-spacing: 0;
    overflow: hidden;
    transition: max-width 0.75s cubic-bezier(0.34, 1.3, 0.64, 1), box-shadow 0.3s ease;
}
.gooey-button:focus, .gooey-button:focus-visible, .gooey-button:focus-within,
.gooey-input:focus, .gooey-input:focus-visible,
.gooey-icon-bubble:focus, .gooey-icon-bubble:focus-visible,
.gooey-stage *:focus, .gooey-stage *:focus-visible { outline: none !important; box-shadow: none !important; }
/* نوار تایپ: خودش هیچ کادر/سایه‌ای ندارد — فقط متن روی نوار قرمز پشتی می‌نشیند
   تا هیچ کادر آبی/اضافی داخلش دیده نشود */
.gooey-wrap.expanded .gooey-button { width: 100%; max-width: calc(100% - 60px); cursor: text; background: transparent; border-color: transparent; box-shadow: none !important; outline: none !important; }
.gooey-button-label {
    display: block;
    text-align: right;
    font-size: 15px;
    font-weight: 700;
    color: #ffffff;
    opacity: 0.9;
    pointer-events: none;
    white-space: nowrap;
    font-family: inherit;
}
.gooey-wrap.expanded .gooey-button-label { display: none; }
.gooey-input {
    display: none;
    width: 100%;
    background: transparent;
    border: none;
    outline: none;
    color: #ffffff;
    font-size: 17px;
    font-weight: 700;
    font-family: inherit;
    text-align: right;
    padding: 0;
    box-sizing: border-box;
    caret-color: #ff2a2a;
}
.gooey-wrap.expanded .gooey-input { display: block; }
.gooey-input::placeholder { color: rgba(255, 255, 255, 0.45); opacity: 1; font-weight: 500; }

/* حباب آیکون جدا کنار باکس — هم‌اندازه طرح اصلی، شناور بیرون (overflow visible است)
   پس ۱۲px فاصله هوایی بین باکس متن و دایره دیده می‌شود */
.gooey-icon-bubble {
    position: relative;
    z-index: 3;
    flex: 0 0 auto;
    width: 48px;
    height: 48px;
    border-radius: 9999px;
    background: linear-gradient(135deg, #990000, #cc0000);
    border: 1px solid rgba(255, 255, 255, 0.2);
    box-shadow: 0 0 18px rgba(153, 0, 0, 0.55);
    color: #ffffff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
    transform: scale(0);
    opacity: 0;
    pointer-events: none;
}
/* حباب دومِ هم‌اندازه داخل لایه goo — فقط برای افکت چسبناک ذوب‌شونده */
.gooey-blob-bubble {
    position: absolute;
    top: -3px;
    inset-inline-end: 0;
    width: 48px;
    height: 48px;
    border-radius: 9999px;
    background: linear-gradient(135deg, #990000, #cc0000);
    opacity: 0;
    transform: scale(0.3);
}
.gooey-wrap.expanded .gooey-blob-bubble { animation: gooeyBlobBubbleIn 0.85s cubic-bezier(0.34, 1.56, 0.64, 1) 0.1s forwards; }
@keyframes gooeyBlobBubbleIn {
    from { opacity: 0; transform: translateX(60px) scale(0.3); }
    to { opacity: 1; transform: translateX(0) scale(1); }
}
.gooey-icon-bubble.show { animation: gooeyBubbleIn 0.85s cubic-bezier(0.34, 1.56, 0.64, 1) 0.1s forwards; }
@keyframes gooeyBubbleIn {
    from { transform: translateX(60px) scale(0.3); opacity: 0; }
    to { transform: translateX(0) scale(1); opacity: 1; }
}
.gooey-spinner { animation: gooeySpin 0.5s linear infinite; display: inline-block; }
@keyframes gooeySpin { to { transform: rotate(180deg); } }

/* نتایج: بیرون از کانتینر gooey (شارپ و تمیز) — فقط دکمه و حباب زیر فیلتر gooey هستند
   تا متن فارسی ذوب نشود و هیچ‌وقت روی دکمه بستن نیایند (عرض محدود به باکس سرچ). */
.gooey-results { position: absolute; top: calc(100% + 10px); right: 0; left: 0; z-index: 5; max-height: min(62vh, 430px); overflow-y: auto; overscroll-behavior: contain; -webkit-overflow-scrolling: touch; padding-inline-end: 2px; }
.gooey-results:empty { display: none; }
.gooey-result {
    position: relative;
    display: flex;
    align-items: center;
    gap: 12px;
    background: rgba(24, 24, 33, 0.97);
    color: #ffffff;
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 14px;
    padding: 9px 14px 9px 18px;
    margin-bottom: 10px;
    font-size: 14px;
    font-weight: 700;
    font-family: inherit;
    cursor: pointer;
    text-decoration: none;
    white-space: nowrap;
    overflow: hidden;
    opacity: 0;
    transform: translateY(-18px) scale(0.92);
    filter: blur(8px);
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}
.gooey-result:last-child { margin-bottom: 0; }
.gooey-result.gooey-in {
    animation: gooeyResultIn 0.55s cubic-bezier(0.34, 1.3, 0.64, 1) forwards;
    animation-delay: var(--gooey-delay, 0s);
}
@keyframes gooeyResultIn {
    from { opacity: 0; transform: translateY(-18px) scale(0.92); filter: blur(8px); }
    to { opacity: 1; transform: translateY(0) scale(1); filter: blur(0); }
}
.gooey-result.gooey-in:hover { border-color: #990000; box-shadow: 0 0 14px rgba(153, 0, 0, 0.35); transform: scale(1.015); transition: transform 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease; }
.gooey-result img {
    width: 40px;
    height: 40px;
    border-radius: 10px;
    object-fit: cover;
    flex-shrink: 0;
    background: rgba(255,255,255,0.08);
    border: 1px solid rgba(255,255,255,0.1);
}
.gooey-result .gooey-result-title { flex: 1; overflow: hidden; text-overflow: ellipsis; text-align: right; }
.gooey-result .gooey-result-price { font-size: 12px; opacity: 0.7; flex-shrink: 0; color: #ffd9d9; }
.gooey-result .gooey-result-info { flex-shrink: 0; opacity: 0.55; font-size: 14px; color: var(--color-accent, #ff2a2a); }
.gooey-empty {
    position: relative;
    display: block;
    background: rgba(24, 24, 33, 0.97);
    color: rgba(255,255,255,0.85);
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 14px;
    padding: 12px 20px;
    font-size: 13px;
    font-weight: 700;
    font-family: inherit;
    text-align: center;
    opacity: 0;
}
.gooey-empty.gooey-in { animation: gooeyResultIn 0.45s cubic-bezier(0.34, 1.3, 0.64, 1) forwards; }
/* ردیف پایانی «مشاهده کامل»: هم‌خانواده نتایج ولی متمایز با بوردر قرمز و stagger آخر */
.gooey-more {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    background: rgba(153, 0, 0, 0.12);
    color: #ffffff;
    border: 1px dashed rgba(153, 0, 0, 0.7);
    border-radius: 14px;
    padding: 11px 18px;
    font-size: 13px;
    font-weight: 800;
    font-family: inherit;
    text-decoration: none;
    white-space: nowrap;
    overflow: hidden;
    cursor: pointer;
    opacity: 0;
    transform: translateY(-18px) scale(0.92);
    filter: blur(8px);
    transition: background 0.2s ease;
}
.gooey-more.gooey-in {
    animation: gooeyResultIn 0.55s cubic-bezier(0.34, 1.3, 0.64, 1) forwards;
    animation-delay: var(--gooey-delay, 0s);
}
.gooey-more:hover { background: rgba(153, 0, 0, 0.25); }
.gooey-more i { transform: rotate(-90deg); }
/* فالبک سافاری/مرورگرهای بدون فیلتر SVG: اسلاید ساده بدون blur */
.no-gooey .gooey-result, .no-gooey .gooey-more { filter: none; }
.no-gooey .gooey-result.gooey-in, .no-gooey .gooey-more.gooey-in { animation-name: gooeyResultInFlat; }
@keyframes gooeyResultInFlat {
    from { opacity: 0; transform: translateY(-14px) scale(0.95); }
    to { opacity: 1; transform: translateY(0) scale(1); }
}
@media (max-width: 768px) {
    .gooey-modal-inner { gap: 10px !important; padding: 14px 0 8px !important; align-items: flex-start !important; }
    .gooey-modal-inner .search-modal-close { width: 38px; height: 38px; font-size: 15px; flex-shrink: 0; }
    .gooey-wrap { min-width: 0; }
    .gooey-stage { gap: 8px; }
    .gooey-button { width: 120px; max-width: calc(100% - 48px); padding: 10px 14px; }
    .gooey-blob-btn { width: 120px; }
    .gooey-wrap.expanded .gooey-button { width: 100%; max-width: calc(100% - 48px); }
    .gooey-wrap.expanded .gooey-blob-btn { width: calc(100% - 48px); }
    .gooey-button-label { font-size: 13px; }
    .gooey-input { font-size: 15px; }
    .gooey-input::placeholder { font-size: 12px; }
    .gooey-icon-bubble { width: 40px; height: 40px; font-size: 14px; }
    .gooey-blob-bubble { width: 40px; height: 40px; }
    .gooey-results { top: calc(100% + 8px); max-height: 46vh; }
    .gooey-result { gap: 8px; padding: 8px 10px; font-size: 13px; }
    .gooey-result img { width: 34px; height: 34px; border-radius: 8px; }
    .gooey-result .gooey-result-price { font-size: 11px; }
    .gooey-result .gooey-result-info { font-size: 12px; }
    .gooey-more { font-size: 12px; padding: 10px 14px; }
    .search-tag-pill { font-size: 11px; padding: 4px 10px; }
    .search-suggestions-strip { padding-bottom: 12px; gap: 8px; }
}
@media (max-width: 480px) {
    .gooey-button-label { font-size: 12px; }
    .gooey-result .gooey-result-title { font-size: 12px; }
}
/* FIX search-stacking: the shared .drawer-overlay sits at z-index 100000
   (layout bundle) which buried the search modal (z-1100) beneath it —
   page went dark and the input was unreachable. The overlay stays below
   the modal so the backdrop dims the page but the search box stays on top
   and clickable. */
#search-overlay { z-index: 100000 !important; }
#search-bar-container.search-modal-container { z-index: 100002 !important; }
