/* ============================================================
   HEADER — Premium App-Style
   ============================================================ */

/* ---- TOP BAR ---- */
.header-common {
    background: rgba(255,255,255,.92) !important;
    backdrop-filter: blur(18px);
    -webkit-backdrop-filter: blur(18px);
    position: fixed;
    top: 0; width: 100%; z-index: 1000;
    border-bottom: 1px solid #e5e7eb;
    transition: box-shadow .25s ease, height .25s ease;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.nav-wrap {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    padding: 0 20px;
    height: 64px;
}

/* Logo */
.logo-link {
    font-size: 1.15rem;
    font-weight: 800;
    letter-spacing: -.5px;
    text-decoration: none;
    color: #111827 !important;
    display: flex; align-items: center;
}
.logo-link span { color: #CD3442; }

/* Desktop nav */
.desktop-nav ul { gap: 2rem !important; }


.desktop-nav a:hover { color: #CD3442 !important; }
.desktop-nav a:hover::after { width: 100%; }

/* Icon buttons */
.header-icon-btn {
    width: 40px; height: 40px;
    border-radius: 50%;
    background: #f3f4f6;
    border: none;
    display: inline-flex; align-items: center; justify-content: center;
    color: #111827;
    position: relative;
    transition: background .2s, transform .2s;
    cursor: pointer;
}
.header-icon-btn:hover {
    background: #fdf0f1;
    color: #CD3442;
    transform: scale(1.08);
}
.header-icon-btn svg { width: 18px; height: 18px; stroke-width: 2px; }

/* Cart badge */
.cart-badge {
    position: absolute; top: 4px; right: 4px;
    background: #CD3442; color: #fff;
    font-size: 9px; font-weight: 700;
    width: 16px; height: 16px; border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    border: 2px solid #fff;
}

/* Desktop search */
.icon-menu .input-group {
    background: #f3f4f6;
    border-radius: 50px;
    border: 1.5px solid #e5e7eb;
    overflow: hidden;
    min-width: 200px;
    transition: border-color .2s, box-shadow .2s;
}
.icon-menu .input-group:focus-within {
    border-color: #CD3442;
    box-shadow: 0 0 0 3px rgba(205,52,66,.1);
}
.icon-menu .form-control {
    background: transparent; border: none;
    font-size: .82rem; padding: .45rem .75rem;
}
.icon-menu .form-control:focus { box-shadow: none; }

/* Mobile search bar */
.mobile-search-container {
    padding: 0 16px 10px;
    width: 100%;
}
.mobile-search-container .input-group {
    background: #f3f4f6;
    border-radius: 12px;
    border: 1.5px solid #e5e7eb;
    overflow: hidden;
    transition: border-color .2s;
}
.mobile-search-container .input-group:focus-within { border-color: #CD3442; }
.mobile-search-container .form-control {
    background: transparent; border: none;
    height: 42px; font-size: .875rem; padding-left: 12px;
}
.mobile-search-container .form-control:focus { box-shadow: none; }

/* Responsive */
@media (max-width: 991px) {
    .desktop-nav { display: none; }
    .header-common { height: auto; flex-direction: column; padding-top: 0; }
    .nav-wrap { height: 70px; }
}
@media (min-width: 992px) {
    .mobile-search-container { display: none; }
    .header-common { height: 68px; }
    .nav-wrap { padding: 0 48px; }
}

/* Scroll shrink */
.header-common.scrolled {
    box-shadow: 0 4px 20px rgba(0,0,0,.07);
}

/* Dropdown */
.dropdown-menu {
    border: 1.5px solid #e5e7eb !important;
    border-radius: 14px !important;
    box-shadow: 0 8px 24px rgba(0,0,0,.1) !important;
    padding: .5rem !important;
    margin-top: .5rem !important;
}
.dropdown-item {
    border-radius: 8px;
    font-size: .875rem;
    font-weight: 500;
    padding: .5rem .875rem;
    transition: background .2s, color .2s;
}
.dropdown-item:hover { background: #fdf0f1 !important; color: #CD3442 !important; }

/* Offcanvas */
.offcanvas { border-radius: 0 24px 24px 0 !important; }
.offcanvas-body a {
    font-weight: 600; font-size: .9rem;
    color: #111827;
    padding: .5rem .75rem;
    border-radius: 8px;
    display: block;
    transition: background .2s, color .2s;
}
.offcanvas-body a:hover { background: #fdf0f1; color: #CD3442; }

/* Search overlay */
.search-overlay {
    display: none;
    position: fixed; inset: 0;
    background: rgba(0,0,0,.7);
    backdrop-filter: blur(8px);
    z-index: 9999;
    align-items: center; justify-content: center;
}
.search-overlay.active { display: flex; }
.search-container {
    width: 90%; max-width: 600px;
    background: rgba(255,255,255,.1);
    border: 1px solid rgba(255,255,255,.2);
    border-radius: 50px;
    padding: 1rem 1.5rem;
    display: flex; align-items: center;
}
.search-input {
    flex: 1; background: transparent; border: none;
    color: #fff; font-size: 1.1rem; outline: none;
}
.search-input::placeholder { color: rgba(255,255,255,.6); }
.close-search { background: none; border: none; color: #fff; cursor: pointer; }
