/*
Theme Name: BEST-DZ
Theme URI: https://example.com/best-dz
Author: Developer
Author URI: https://example.com
Description: A modern e-commerce WordPress theme inspired by Bestway design.
Version: 1.0.0
Requires at least: 5.0
Tested up to: 6.5
Requires PHP: 7.4
License: GNU General Public License v2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html
Text Domain: best-dz
*/

/* ============================================
   Reset & Base
   ============================================ */
*,
*::before,
*::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    font-size: 14px;
    line-height: 1.5;
    color: #333;
    background: #fff;
}

a {
    text-decoration: none;
    color: inherit;
}

ul, ol {
    list-style: none;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

button, input {
    font-family: inherit;
    font-size: inherit;
    border: none;
    outline: none;
    background: none;
}

/* ============================================
   Layout Container
   ============================================ */
.site-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 20px;
}

/* ============================================
   Header Sticky
   ============================================ */
.site-header {
    position: relative;
    z-index: 1000;
}

.site-header.is-sticky {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.08);
}

.site-header.is-sticky .top-bar {
    display: none;
}

.site-header-placeholder {
    display: none;
}

.site-header-placeholder.is-active {
    display: block;
}

.admin-bar .site-header.is-sticky {
    top: 32px;
}

@media (max-width: 782px) {
    .admin-bar .site-header.is-sticky {
        top: 46px;
    }
}

/* ============================================
   1. Top Announcement Bar
   ============================================ */
.top-bar {
    background: #003DA5;
    color: #fff;
    font-size: 13px;
    line-height: 1;
}

.top-bar .site-container {
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    height: 36px;
}

.top-bar__message {
    text-align: center;
    font-weight: 400;
    letter-spacing: 0.3px;
}

.top-bar__message a {
    color: #fff;
    text-decoration: none;
}

.top-bar__message a:hover {
    text-decoration: underline;
}

.top-bar__locale {
    position: absolute;
    right: 20px;
    display: flex;
    align-items: center;
    gap: 6px;
    cursor: pointer;
    font-size: 13px;
    font-weight: 500;
}

.top-bar__locale svg {
    width: 16px;
    height: 16px;
    fill: #fff;
}

.top-bar__locale-arrow {
    width: 10px;
    height: 10px;
    fill: #fff;
    transition: transform 0.25s;
}

.top-bar__locale:hover .top-bar__locale-arrow {
    transform: rotate(180deg);
}

/* Language Dropdown */

/* Current language trigger */
.language-menu__current {
    display: flex;
    align-items: center;
}

.language-menu__current a {
    display: flex;
    align-items: center;
    gap: 6px;
    color: #fff;
    text-decoration: none;
    font-size: 13px;
    font-weight: 500;
    white-space: nowrap;
}

.language-menu__current a img,
.language-menu__current a .trp-flag-image {
    width: 18px;
    height: 14px;
    border-radius: 2px;
    object-fit: cover;
}

/* ---- Dropdown panel (hidden by default) ---- */
.language-menu__dropdown {
    display: none;
    position: absolute;
    top: 100%;
    right: 0;
    background: #fff;
    border: 1px solid #e8e8e8;
    border-radius: 4px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
    padding: 4px 0;
    min-width: 140px;
    z-index: 10002;
    list-style: none;
    margin: 0;
}

/* Bridge gap between trigger and dropdown */
.language-menu__dropdown::before {
    content: '';
    position: absolute;
    top: -10px;
    left: 0;
    right: 0;
    height: 10px;
}

/* Show dropdown on locale hover */
.top-bar__locale:hover .language-menu__dropdown {
    display: block;
}

.language-menu__dropdown li a {
    display: flex;
    align-items: center;
    gap: 8px;
    color: #333;
    text-decoration: none;
    padding: 7px 14px;
    font-size: 13px;
    font-weight: 400;
    white-space: nowrap;
    transition: background 0.15s;
}

.language-menu__dropdown li a:hover {
    background: #f5f7fa;
    color: #003DA5;
}

.language-menu__dropdown li a img,
.language-menu__dropdown li a .trp-flag-image {
    width: 18px;
    height: 14px;
    border-radius: 2px;
    object-fit: cover;
}

/* Current language highlighted */
.language-menu__dropdown li.current-language-menu-item a,
.language-menu__dropdown li.current-menu-item a {
    font-weight: 600;
    color: #003DA5;
}

/* Sub-menu inside language (standard WP) */
.language-menu .sub-menu {
    display: none;
    list-style: none;
    margin: 0;
    padding: 0;
}

.top-bar__locale:hover .language-menu .sub-menu {
    display: block;
    position: absolute;
    top: 100%;
    right: 0;
    background: #fff;
    border: 1px solid #e8e8e8;
    border-radius: 4px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
    padding: 4px 0;
    min-width: 140px;
    z-index: 10002;
}

.top-bar__locale:hover .language-menu .sub-menu::before {
    content: '';
    position: absolute;
    top: -10px;
    left: 0;
    right: 0;
    height: 10px;
}

.top-bar__locale:hover .language-menu .sub-menu li a {
    display: flex;
    align-items: center;
    gap: 8px;
    color: #333;
    text-decoration: none;
    padding: 7px 14px;
    font-size: 13px;
}

.top-bar__locale:hover .language-menu .sub-menu li a:hover {
    background: #f5f7fa;
    color: #003DA5;
}

/* ============================================
   2. Main Header
   ============================================ */
.main-header {
    background: #fff;
    border-bottom: 1px solid #e8e8e8;
}

.main-header .site-container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 70px;
    gap: 24px;
}

/* Logo */
.site-logo {
    flex-shrink: 0;
}

.site-logo a {
    display: flex;
    align-items: center;
}

.site-logo img {
    height: 32px;
    width: auto;
}

.site-logo__text {
    font-size: 28px;
    font-weight: 900;
    color: #003DA5;
    font-style: italic;
    letter-spacing: -0.5px;
    line-height: 1;
}

/* Search Bar */
.header-search {
    flex: 1;
    max-width: 520px;
}

.header-search__form {
    display: flex;
    align-items: center;
    border: none;
    border-radius: 999px;
    overflow: hidden;
    background: #f0f0f0;
    transition: background 0.2s, box-shadow 0.2s;
}

.header-search__form:focus-within {
    background: #e8e8e8;
    box-shadow: 0 0 0 2px #003DA5;
}

.header-search__input {
    flex: 1;
    padding: 10px 20px;
    font-size: 14px;
    color: #333;
    background: transparent;
}

.header-search__input::placeholder {
    color: #999;
}

.header-search__btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 40px;
    cursor: pointer;
    color: #555;
    transition: color 0.2s;
}

.header-search__btn:hover {
    color: #003DA5;
}

.header-search__btn svg {
    width: 20px;
    height: 20px;
}

/* Header Actions / Utilities */
.header-actions {
    display: flex;
    align-items: center;
    gap: 22px;
    flex-shrink: 0;
    font-family: 'Instrument Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

.header-action {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 13px;
    font-weight: 400;
    color: #333;
    cursor: pointer;
    white-space: nowrap;
    position: relative;
    padding-bottom: 2px;
    transition: color 0.3s;
}

.header-action__label {
    position: relative;
}

.header-action__label::after {
    content: '';
    position: absolute;
    left: 0;
    bottom: 0;
    width: 0;
    height: 2px;
    background: #003DA5;
    transition: width 0.3s ease;
}

.header-action:hover .header-action__label::after {
    width: 100%;
}

.header-action:hover {
    color: #003DA5;
}

.header-action svg {
    width: 20px;
    height: 20px;
    flex-shrink: 0;
}

.header-action--cart {
    position: relative;
}

.header-action--cart svg {
    width: 22px;
    height: 22px;
}

.cart-count {
    position: absolute;
    top: -6px;
    right: -8px;
    background: #d32f2f;
    color: #fff;
    font-size: 10px;
    font-weight: 700;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    line-height: 1;
}

/* ============================================
   3. Navigation Bar
   ============================================ */
.nav-bar {
    background: #fff;
    border-bottom: 2px solid #e8e8e8;
}

.nav-bar .site-container {
    display: flex;
    align-items: center;
    height: 46px;
}

.primary-menu {
    display: flex;
    align-items: center;
    gap: 0;
    height: 100%;
}

.primary-menu > li {
    position: relative;
    height: 100%;
    display: flex;
    align-items: center;
}

.primary-menu > li > a {
    display: flex;
    align-items: center;
    gap: 4px;
    padding: 0 16px;
    height: 100%;
    font-size: 14px;
    font-weight: 600;
    color: #222;
    transition: color 0.2s;
}

.primary-menu > li > a:hover {
    color: #003DA5;
}

.primary-menu > li > a .nav-arrow {
    width: 12px;
    height: 12px;
    fill: #555;
    transition: transform 0.2s;
}

.primary-menu > li:first-child > a {
    padding-left: 0;
}

/* Sale item highlight */
.primary-menu > li.menu-item-sale > a {
    color: #d32f2f;
    font-weight: 700;
}

.primary-menu > li.menu-item-sale > a::after {
    content: "";
    display: inline-block;
    width: 6px;
    height: 6px;
    background: #d32f2f;
    border-radius: 50%;
    margin-left: 2px;
    margin-bottom: 8px;
}

/* Sub Menu */
.sub-menu {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    min-width: 200px;
    background: #fff;
    border: 1px solid #e8e8e8;
    border-top: 2px solid #003DA5;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    z-index: 1000;
    padding: 8px 0;
}

.primary-menu > li:hover > .sub-menu {
    display: block;
}

.sub-menu li a {
    display: block;
    padding: 8px 20px;
    font-size: 13px;
    color: #333;
    transition: background 0.15s, color 0.15s;
}

.sub-menu li a:hover {
    background: #f5f7fa;
    color: #003DA5;
}

/* ============================================
   4. Mega Menu
   ============================================ */
.nav-bar {
    position: relative;
}

.primary-menu > li.menu-item-mega {
    position: static;
}

.mega-menu {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    width: 100%;
    background: #fff;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12);
    z-index: 1000;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-8px);
    transition: opacity 0.3s ease, transform 0.3s ease, visibility 0.3s;
    pointer-events: none;
}

.primary-menu > li.menu-item-mega:hover > .mega-menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
    pointer-events: auto;
}

.primary-menu > li.menu-item-mega:hover > a .nav-arrow {
    transform: rotate(180deg);
}

.mega-menu__inner {
    display: flex;
    gap: 0;
    max-width: 1400px;
    margin: 0 auto;
    padding: 32px 20px;
}

.mega-menu__col {
    flex: 1;
    padding: 0 20px;
    border-right: 1px solid #eee;
}

.mega-menu__col:last-child {
    border-right: none;
}

.mega-menu__col--image {
    display: flex;
    align-items: center;
    justify-content: center;
}

.mega-menu__img {
    width: 100%;
    height: 200px;
    background: #f0f0f0;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #999;
    font-size: 13px;
    overflow: hidden;
}

.mega-menu__img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 8px;
}

.mega-menu__heading {
    font-size: 14px;
    font-weight: 700;
    color: #003DA5;
    margin-bottom: 14px;
    padding-bottom: 0;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.mega-menu__col ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.mega-menu__col ul li {
    margin-bottom: 4px;
}

.mega-menu__col ul li a {
    display: block;
    padding: 6px 0;
    font-size: 13px;
    color: #444;
    position: relative;
    transition: color 0.2s, padding-left 0.2s;
}

.mega-menu__col ul li a:hover {
    color: #003DA5;
    padding-left: 8px;
}

.mega-menu__col ul li a::before {
    content: '';
    position: absolute;
    left: 0;
    top: 50%;
    width: 0;
    height: 2px;
    background: #003DA5;
    transform: translateY(-50%);
    transition: width 0.2s;
}

.mega-menu__col ul li a:hover::before {
    width: 4px;
}

/* Tabbed Mega Menu */
.mega-menu__tabbed {
    display: flex;
    gap: 0;
    padding: 0;
}

.mega-tabs__nav {
    width: 220px;
    flex-shrink: 0;
    background: transparent;
    padding: 16px 0;
    display: flex;
    flex-direction: column;
}

.mega-tabs__btn {
    display: block;
    width: 100%;
    text-align: left;
    padding: 10px 20px;
    margin: 2px 8px;
    font-size: 14px;
    font-weight: 500;
    color: #444;
    background: transparent;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    transition: color 0.2s, background 0.2s;
}

.mega-tabs__btn:hover,
.mega-tabs__btn.is-active {
    color: #003DA5;
    background: #f0f0f0;
}

.mega-tabs__viewall {
    display: block;
    margin-top: auto;
    padding: 12px 24px;
    font-size: 13px;
    font-weight: 600;
    color: #003DA5;
    transition: opacity 0.2s;
}

.mega-tabs__viewall:hover {
    opacity: 0.7;
}

.mega-tabs__panels {
    flex: 1;
    position: relative;
}

.mega-tabs__panel {
    display: none;
    padding: 20px 24px;
    flex-wrap: wrap;
    gap: 12px;
    align-items: flex-start;
}

.mega-tabs__panel.is-active {
    display: flex;
}

.mega-tabs__card {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    width: calc((100% - 48px) / 5);
    padding: 0;
    color: #333;
}

.mega-tabs__card:hover {
    color: #003DA5;
}

.mega-tabs__card-img {
    width: 100%;
    aspect-ratio: 1 / 1;
    background: #f0f0f0;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 8px;
    overflow: hidden;
}

.mega-tabs__card-img svg,
.mega-tabs__card-img img {
    transition: transform 0.3s ease;
}

.mega-tabs__card:hover .mega-tabs__card-img svg,
.mega-tabs__card:hover .mega-tabs__card-img img {
    transform: scale(1.1);
}

.mega-tabs__card-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.mega-tabs__card-name {
    font-size: 13px;
    font-weight: 500;
    color: #333;
    line-height: 1.3;
    transition: color 0.2s;
}

.mega-tabs__card:hover .mega-tabs__card-name {
    color: #003DA5;
}

/* Mega Menu Overlay */
.mega-menu-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.3);
    z-index: 999;
}

.primary-menu > li.menu-item-mega:hover ~ .mega-menu-overlay {
    display: block;
}

/* ============================================
   5. Icon Grid Widget
   ============================================ */
.icon-grid {
    padding: 32px 0;
    background: #fff;
}

.icon-grid__row {
    display: flex;
    gap: 0;
}

.icon-grid__item {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    padding: 24px 12px;
    border-radius: 12px;
    transition: background 0.3s, color 0.3s;
    color: #333;
    cursor: pointer;
}

.icon-grid__item:hover {
    background: #003DA5;
    color: #fff;
}

.icon-grid__icon {
    width: 48px;
    height: 48px;
    margin-bottom: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.icon-grid__icon svg {
    width: 36px;
    height: 36px;
    stroke: #003DA5;
    transition: stroke 0.3s;
}

.icon-grid__item:hover .icon-grid__icon svg {
    stroke: #fff;
}

.icon-grid__label {
    font-size: 13px;
    font-weight: 600;
    line-height: 1.3;
    transition: color 0.3s;
    color: #333;
}

.icon-grid__item:hover .icon-grid__label {
    color: #fff;
}

/* ============================================
   Hamburger Toggle (hidden on desktop)
   ============================================ */
.mobile-menu-toggle {
    display: none;
    flex-direction: column;
    justify-content: center;
    gap: 5px;
    width: 36px;
    height: 36px;
    padding: 6px;
    background: none;
    border: none;
    cursor: pointer;
    flex-shrink: 0;
}

.mobile-menu-toggle__bar {
    display: block;
    width: 100%;
    height: 2px;
    background: #333;
    border-radius: 2px;
    transition: transform 0.3s, opacity 0.3s;
}

/* ============================================
   Mobile Drawer (left slide)
   ============================================ */
.mobile-drawer-overlay {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.45);
    z-index: 10000;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.mobile-drawer-overlay.is-open {
    display: block;
    opacity: 1;
}

.mobile-drawer {
    position: fixed;
    top: 0;
    left: 0;
    width: 300px;
    max-width: 85vw;
    height: 100%;
    background: #fff;
    z-index: 10001;
    transform: translateX(-100%);
    transition: transform 0.35s cubic-bezier(0.4, 0, 0.2, 1);
    overflow-y: auto;
    display: flex;
    flex-direction: column;
}

.mobile-drawer.is-open {
    transform: translateX(0);
}

.mobile-drawer__header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px 20px;
    border-bottom: 1px solid #eee;
    flex-shrink: 0;
}

.mobile-drawer__header .site-logo img {
    max-height: 36px;
    width: auto;
}

.mobile-drawer__close {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    background: none;
    border: none;
    cursor: pointer;
    color: #333;
}

.mobile-drawer__close svg {
    width: 22px;
    height: 22px;
}

/* Drawer Navigation */
.mobile-drawer__nav {
    flex: 1;
    overflow-y: auto;
    padding: 8px 0;
}

.mobile-drawer__menu {
    list-style: none;
    margin: 0;
    padding: 0;
}

.mobile-drawer__menu li {
    border-bottom: 1px solid #f2f2f2;
}

.mobile-drawer__menu li a {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 14px 20px;
    font-size: 15px;
    font-weight: 600;
    color: #222;
    text-decoration: none;
    transition: background 0.15s, color 0.15s;
}

.mobile-drawer__menu li a:hover,
.mobile-drawer__menu li a:active {
    background: #f5f7fa;
    color: #003DA5;
}

.mobile-drawer__menu li a .nav-arrow {
    width: 16px;
    height: 16px;
    fill: #999;
    transition: transform 0.25s;
}

.mobile-drawer__menu li.is-sub-open > a .nav-arrow {
    transform: rotate(180deg);
}

/* Sub-menu inside drawer */
.mobile-drawer__menu .sub-menu,
.mobile-drawer__menu .mega-menu {
    display: none;
    list-style: none;
    margin: 0;
    padding: 0;
    background: #fafafa;
    position: static;
    width: 100%;
    border: none;
    box-shadow: none;
    border-top: 1px solid #eee;
    z-index: auto;
    opacity: 1;
    visibility: visible;
    transform: none;
    pointer-events: auto;
    min-width: 0;
}

.mobile-drawer__menu li.is-sub-open > .sub-menu,
.mobile-drawer__menu li.is-sub-open > .mega-menu {
    display: block;
}

.mobile-drawer__menu .sub-menu li a,
.mobile-drawer__menu .mega-menu a {
    padding: 10px 20px 10px 36px;
    font-size: 14px;
    font-weight: 400;
    color: #555;
}

/* Reset mega-menu desktop styles inside drawer */
.mobile-drawer__menu .mega-menu {
    position: static;
    width: 100%;
    box-shadow: none;
    border: none;
    border-top: 1px solid #eee;
    transform: none;
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
}

.mobile-drawer__menu .mega-menu__inner {
    flex-direction: column;
    padding: 12px 0;
    gap: 0;
}

.mobile-drawer__menu .mega-menu__col {
    padding: 0;
    border-right: none;
    border-bottom: 1px solid #f2f2f2;
    padding-bottom: 8px;
    margin-bottom: 8px;
}

.mobile-drawer__menu .mega-menu__col:last-child {
    border-bottom: none;
    margin-bottom: 0;
}

.mobile-drawer__menu .mega-menu__heading {
    padding: 8px 20px 4px 36px;
    font-size: 13px;
    font-weight: 700;
    color: #222;
}

.mobile-drawer__menu .mega-menu__col ul {
    list-style: none;
    margin: 0;
    padding: 0;
}

.mobile-drawer__menu .mega-menu__col ul li a {
    display: block;
    padding: 6px 20px 6px 48px;
    font-size: 13px;
    font-weight: 400;
    color: #555;
}

.mobile-drawer__menu .mega-menu__col ul li a:hover {
    color: #003DA5;
    background: #f5f7fa;
}

/* Tabbed mega menu in drawer: stack vertically */
.mobile-drawer__menu .mega-menu__tabbed {
    flex-direction: column;
}

.mobile-drawer__menu .mega-tabs__nav {
    display: flex;
    flex-direction: column;
    border-right: none;
    border-bottom: none;
    width: 100%;
    min-width: 0;
}

.mobile-drawer__menu .mega-tabs__btn {
    text-align: left;
    padding: 10px 20px 10px 36px;
    font-size: 14px;
    border-bottom: 1px solid #f2f2f2;
}

.mobile-drawer__menu .mega-tabs__panels {
    display: none;
}

.mobile-drawer__menu .mega-tabs__viewall {
    padding: 10px 20px 10px 36px;
    font-size: 13px;
}

/* Drawer Actions (bottom) */
.mobile-drawer__actions {
    border-top: 1px solid #eee;
    padding: 12px 20px;
    display: flex;
    flex-direction: column;
    gap: 2px;
    flex-shrink: 0;
}

.mobile-drawer__link {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 0;
    font-size: 14px;
    font-weight: 500;
    color: #333;
    text-decoration: none;
    transition: color 0.15s;
}

.mobile-drawer__link:hover {
    color: #003DA5;
}

.mobile-drawer__link svg {
    width: 20px;
    height: 20px;
    flex-shrink: 0;
}

/* Language switcher in drawer */
.mobile-drawer__lang {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 14px 20px;
    border-top: 1px solid #eee;
    flex-shrink: 0;
}

.mobile-drawer__lang-icon {
    width: 20px;
    height: 20px;
    flex-shrink: 0;
    color: #555;
}

.mobile-drawer__lang-list {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    align-items: center;
    gap: 4px;
    flex-wrap: wrap;
}

.mobile-drawer__lang-list li a {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 4px 10px;
    font-size: 13px;
    font-weight: 500;
    color: #555;
    text-decoration: none;
    border-radius: 4px;
    transition: background 0.15s, color 0.15s;
}

.mobile-drawer__lang-list li a:hover,
.mobile-drawer__lang-list li.current-language-menu-item a,
.mobile-drawer__lang-list li.current-menu-item a {
    background: #f0f4ff;
    color: #003DA5;
    font-weight: 600;
}

.mobile-drawer__lang-list li a img,
.mobile-drawer__lang-list li a .trp-flag-image {
    width: 18px;
    height: 14px;
    border-radius: 2px;
    object-fit: cover;
}

/* Body scroll lock when drawer open */
body.mobile-drawer-open {
    overflow: hidden;
}

/* ============================================
   Responsive: Mobile
   ============================================ */
@media (max-width: 768px) {
    .mobile-menu-toggle {
        display: flex;
        order: 0;
    }

    .top-bar__locale {
        position: static;
    }

    .top-bar .site-container {
        justify-content: space-between;
        padding: 0 16px;
    }

    .main-header .site-container {
        flex-wrap: wrap;
        height: auto;
        padding: 12px 16px;
        gap: 12px;
    }

    .site-logo {
        order: 1;
        flex: 1;
    }

    .header-actions {
        order: 2;
        gap: 12px;
    }

    .header-action--text {
        display: none;
    }

    .header-search {
        order: 3;
        max-width: 100%;
        width: 100%;
    }

    .header-action__label {
        display: none;
    }

    /* Hide desktop nav bar on mobile */
    .nav-bar {
        display: none;
    }

    .icon-grid__row {
        flex-wrap: wrap;
    }

    .icon-grid__item {
        flex: 0 0 25%;
        padding: 16px 8px;
    }
}

/* ============================================
   Right Floating Sidebar
   ============================================ */
.bdz-sidebar {
    position: fixed;
    right: 0;
    top: 50%;
    transform: translateY(-50%);
    z-index: 9999;
    display: flex;
    flex-direction: column;
    width: 58px;
    overflow: visible;
}

.bdz-sidebar__item {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    width: 58px;
    padding: 10px 4px;
    background-color: #4a4a4a;
    color: #fff;
    text-decoration: none;
    border: none;
    cursor: pointer;
    transition: background-color 0.3s ease;
    gap: 4px;
}

.bdz-sidebar__item + .bdz-sidebar__item {
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.bdz-sidebar__item:hover {
    background-color: #003DA5;
    color: #fff;
}

.bdz-sidebar__icon {
    width: 24px;
    height: 24px;
    flex-shrink: 0;
    object-fit: contain;
}

.bdz-sidebar__text {
    font-size: 11px;
    line-height: 1.2;
    text-align: center;
    white-space: nowrap;
}

/* WhatsApp hover */
.bdz-sidebar__item--whatsapp:hover {
    background-color: #25D366;
}

/* LinkedIn hover */
.bdz-sidebar__item--linkedin:hover {
    background-color: #0077B5;
}

/* Facebook hover */
.bdz-sidebar__item--facebook:hover {
    background-color: #1877F2;
}

/* TikTok hover */
.bdz-sidebar__item--tiktok:hover {
    background-color: #000000;
}

/* Email hover */
.bdz-sidebar__item--email:hover {
    background-color: #003DA5;
}

/* WeChat hover + QR popup */
.bdz-sidebar__item--wechat:hover {
    background-color: #07C160;
}

.bdz-sidebar__qr {
    display: none;
    position: absolute;
    right: 100%;
    top: 50%;
    transform: translateY(-50%);
    background: #fff;
    border-radius: 8px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
    padding: 16px;
    text-align: center;
    min-width: 160px;
    margin-right: 8px;
}

.bdz-sidebar__item--wechat:hover .bdz-sidebar__qr {
    display: block;
}

.bdz-sidebar__qr p {
    margin: 0 0 8px;
    font-size: 13px;
    color: #333;
    font-weight: 600;
}

.bdz-sidebar__qr-placeholder {
    width: 130px;
    height: 130px;
    background: #f5f5f5;
    border: 1px dashed #ccc;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    color: #999;
    border-radius: 4px;
}

.bdz-sidebar__qr::after {
    content: '';
    position: absolute;
    right: -6px;
    top: 50%;
    transform: translateY(-50%);
    border: 6px solid transparent;
    border-left-color: #fff;
}

/* Back to top */
.bdz-sidebar__item--top {
    background-color: #c62828;
}

.bdz-sidebar__item--top:hover {
    background-color: #e53935;
}

/* Mobile */
@media (max-width: 768px) {
    .bdz-sidebar {
        width: 42px;
        top: auto;
        bottom: 16px;
        transform: none;
    }
    .bdz-sidebar__item {
        width: 42px;
        padding: 6px 2px;
    }
    .bdz-sidebar__icon {
        width: 18px;
        height: 18px;
    }
    .bdz-sidebar__text {
        font-size: 8px;
    }
    .bdz-sidebar__item--wechat .bdz-sidebar__qr {
        right: 100%;
        bottom: 0;
        top: auto;
    }
}

/* ============================================
   Content Typography — scoped to article pages
   body.single-post  = 文章详情页
   body.blog         = 博客首页
   body.category     = 文章分类页
   body.single-product .woocommerce-Tabs-panel = 产品描述Tab
   .entry-content    = 传统文章正文
   ============================================ */
body.single-post .elementor-widget-text-editor,
body.single-post .elementor-widget-theme-post-content,
body.blog .elementor-widget-text-editor,
body.category .elementor-widget-text-editor,
.woocommerce-product-details__short-description,
.woocommerce-Tabs-panel,
.entry-content {
    line-height: 1.7;
    color: #333;
    word-wrap: break-word;
    overflow-wrap: break-word;
}

/* Paragraphs */
body.single-post .elementor-widget-text-editor p,
body.single-post .elementor-widget-theme-post-content p,
body.blog .elementor-widget-text-editor p,
body.category .elementor-widget-text-editor p,
.woocommerce-Tabs-panel p,
.entry-content p {
    margin: 0 0 1em;
}

/* Headings inside content */
body.single-post .elementor-widget-text-editor h1,
body.single-post .elementor-widget-text-editor h2,
body.single-post .elementor-widget-text-editor h3,
body.single-post .elementor-widget-text-editor h4,
body.single-post .elementor-widget-text-editor h5,
body.single-post .elementor-widget-text-editor h6,
body.single-post .elementor-widget-heading .elementor-heading-title,
body.blog .elementor-widget-text-editor h1,
body.blog .elementor-widget-text-editor h2,
body.blog .elementor-widget-text-editor h3,
body.blog .elementor-widget-text-editor h4,
body.blog .elementor-widget-heading .elementor-heading-title,
body.category .elementor-widget-text-editor h1,
body.category .elementor-widget-text-editor h2,
body.category .elementor-widget-text-editor h3,
body.category .elementor-widget-text-editor h4,
body.category .elementor-widget-heading .elementor-heading-title,
.woocommerce-Tabs-panel h1,
.woocommerce-Tabs-panel h2,
.woocommerce-Tabs-panel h3,
.woocommerce-Tabs-panel h4,
.woocommerce-Tabs-panel h5,
.woocommerce-Tabs-panel h6,
.entry-content h1,
.entry-content h2,
.entry-content h3,
.entry-content h4,
.entry-content h5,
.entry-content h6 {
    margin: 1.2em 0 0.6em;
    line-height: 1.3;
    font-weight: 600;
}

/* First heading should not have extra top margin */
body.single-post .elementor-widget-heading:first-child .elementor-heading-title,
body.blog .elementor-widget-heading:first-child .elementor-heading-title,
body.category .elementor-widget-heading:first-child .elementor-heading-title {
    margin-top: 0;
}

/* Unordered lists */
body.single-post .elementor-widget-text-editor ul,
body.single-post .elementor-widget-theme-post-content ul,
body.blog .elementor-widget-text-editor ul,
body.category .elementor-widget-text-editor ul,
.woocommerce-Tabs-panel ul,
.entry-content ul {
    list-style: disc;
    margin: 0 0 1em;
    padding-left: 1.5em;
}

/* Ordered lists */
body.single-post .elementor-widget-text-editor ol,
body.single-post .elementor-widget-theme-post-content ol,
body.blog .elementor-widget-text-editor ol,
body.category .elementor-widget-text-editor ol,
.woocommerce-Tabs-panel ol,
.entry-content ol {
    list-style: decimal;
    margin: 0 0 1em;
    padding-left: 1.5em;
}

/* List items */
body.single-post .elementor-widget-text-editor li,
body.single-post .elementor-widget-theme-post-content li,
body.blog .elementor-widget-text-editor li,
body.category .elementor-widget-text-editor li,
.woocommerce-Tabs-panel li,
.entry-content li {
    margin-bottom: 0.35em;
    line-height: 1.6;
}

/* Nested lists */
body.single-post .elementor-widget-text-editor ul ul,
body.single-post .elementor-widget-text-editor ol ul,
body.blog .elementor-widget-text-editor ul ul,
body.category .elementor-widget-text-editor ul ul,
.woocommerce-Tabs-panel ul ul,
.entry-content ul ul {
    list-style: circle;
    margin: 0.35em 0 0.35em;
}

body.single-post .elementor-widget-text-editor ul ul ul,
.woocommerce-Tabs-panel ul ul ul,
.entry-content ul ul ul {
    list-style: square;
}

body.single-post .elementor-widget-text-editor ol ol,
body.single-post .elementor-widget-text-editor ul ol,
.woocommerce-Tabs-panel ol ol,
.entry-content ol ol {
    list-style: lower-alpha;
    margin: 0.35em 0 0.35em;
}

/* Bold / Strong */
body.single-post .elementor-widget-text-editor strong,
body.single-post .elementor-widget-text-editor b,
body.blog .elementor-widget-text-editor strong,
body.category .elementor-widget-text-editor strong,
.woocommerce-Tabs-panel strong,
.entry-content strong {
    font-weight: 600;
}

/* Blockquote */
body.single-post .elementor-widget-text-editor blockquote,
body.blog .elementor-widget-text-editor blockquote,
body.category .elementor-widget-text-editor blockquote,
.woocommerce-Tabs-panel blockquote,
.entry-content blockquote {
    margin: 1em 0;
    padding: 12px 20px;
    border-left: 4px solid #003DA5;
    background: #f8f9fb;
    font-style: italic;
    color: #555;
}

/* Tables */
body.single-post .elementor-widget-text-editor table,
.woocommerce-Tabs-panel table,
.entry-content table {
    width: 100%;
    border-collapse: collapse;
    margin: 1em 0;
}

body.single-post .elementor-widget-text-editor th,
body.single-post .elementor-widget-text-editor td,
.woocommerce-Tabs-panel th,
.woocommerce-Tabs-panel td,
.entry-content th,
.entry-content td {
    padding: 8px 12px;
    border: 1px solid #e0e0e0;
    text-align: left;
}

body.single-post .elementor-widget-text-editor th,
.woocommerce-Tabs-panel th,
.entry-content th {
    background: #f5f5f5;
    font-weight: 600;
}

/* Images inside content */
body.single-post .elementor-widget-text-editor img,
.woocommerce-Tabs-panel img,
.entry-content img {
    max-width: 100%;
    height: auto;
    border-radius: 4px;
}

/* Links inside content */
body.single-post .elementor-widget-text-editor a,
body.blog .elementor-widget-text-editor a,
body.category .elementor-widget-text-editor a,
.woocommerce-Tabs-panel a,
.entry-content a {
    color: #003DA5;
    text-decoration: underline;
    text-decoration-thickness: 1px;
    text-underline-offset: 2px;
}

body.single-post .elementor-widget-text-editor a:hover,
body.blog .elementor-widget-text-editor a:hover,
body.category .elementor-widget-text-editor a:hover,
.woocommerce-Tabs-panel a:hover,
.entry-content a:hover {
    color: #0052cc;
}

/* Horizontal rule */
body.single-post .elementor-widget-text-editor hr,
.woocommerce-Tabs-panel hr,
.entry-content hr {
    border: none;
    border-top: 1px solid #e0e0e0;
    margin: 1.5em 0;
}

/* Code */
body.single-post .elementor-widget-text-editor code,
.entry-content code {
    background: #f5f5f5;
    padding: 2px 6px;
    border-radius: 3px;
    font-size: 0.9em;
    font-family: Consolas, Monaco, "Courier New", monospace;
}

body.single-post .elementor-widget-text-editor pre,
.entry-content pre {
    background: #f5f5f5;
    padding: 16px;
    border-radius: 6px;
    overflow-x: auto;
    margin: 1em 0;
}
