
/* ============================================================
   VARIABLES
   ============================================================ */

.apcz-header {
    --apcz-yellow: #ffc515;
    --apcz-yellow-dark: #f5b900;
    --apcz-blue: #087cf0;
    --apcz-blue-dark: #0068d9;
    --apcz-green: #159447;
    --apcz-text: #171717;
    --apcz-muted: #6c7280;
    --apcz-border: #e8e8e8;
    --apcz-white: #ffffff;

    width: 100%;
    position: relative;
    z-index: 1000;

    font-family: Arial, Helvetica, sans-serif;

    width: 100%;
    max-width: 100vw;
    box-sizing: border-box;
}

.apcz-header *,
.apcz-header *::before,
.apcz-header *::after {
    box-sizing: border-box;
}


/* ============================================================
   BARRE JAUNE
   ============================================================ */

.apcz-header-main {
    background: var(--apcz-yellow);
    width: 100%;
}

.apcz-header-container {

    width: 100%;
    max-width: 1500px;

    margin: 0 auto;

    min-height: 105px;

    padding:
        15px 24px;

    display: flex;

    align-items: center;

    gap: 28px;

}


/* ============================================================
   LOGO
   ============================================================ */

.apcz-logo {

    display: flex;

    align-items: center;

    gap: 10px;

    text-decoration: none;

    flex-shrink: 0;

    color: var(--apcz-text);

}

.apcz-logo img {

    width: 58px;
    height: 58px;

    object-fit: contain;

}

.apcz-logo-text {

    display: flex;

    flex-direction: column;

    line-height: 1;

}

.apcz-logo-text strong {

    font-size: 30px;

    font-weight: 800;

    color: #087cf0;

}

.apcz-logo-text strong span {

    color: #159447;

}

.apcz-logo-text small {

    margin-top: 7px;

    font-size: 12px;

    color: #111;

    white-space: nowrap;

}


/* ============================================================
   RECHERCHE
   ============================================================ */

.apcz-search {

    height: 58px;

    flex: 1;

    max-width: 820px;

    margin: 0 auto;

    display: flex;

    align-items: stretch;

    background: #fff;

    border-radius: 8px;

    overflow: hidden;

    border: 1px solid #d9d9d9;

    box-shadow:
        0 2px 5px rgba(0, 0, 0, .08);

}


/* CATÉGORIES */

.apcz-search-category {

    min-width: 235px;

    padding: 0 20px;

    display: flex;

    align-items: center;

    justify-content: space-between;

    gap: 15px;

    font-size: 14px;

    font-weight: 600;

    border-right: 1px solid #ddd;

    white-space: nowrap;

}

.apcz-search-category-label {
    display: flex;
    align-items: center;
    min-width: 0;
}

.apcz-search-category-arrow {
    margin-left: auto;
    margin-right: 2px;
    margin-top: -3px;
}

.apcz-search-category-wrapper {
    position: relative;
    min-width: 235px;
    flex: 0 0 235px;
}

.apcz-search-category {
    width: 100%;
    height: 100%;
    min-width: 0;
    padding: 0 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 15px;
    font-size: 14px;
    font-weight: 600;
    color: #171717;
    background: #fff;
    border: 0;
    border-right: 1px solid #ddd;
    cursor: pointer;
    white-space: nowrap;
    text-align: left;
}

.apcz-search-category:hover {
    background: #fafafa;
}

.apcz-search-category[aria-expanded="true"] .apcz-search-category-arrow {
    transform: rotate(225deg);
    margin-top: 4px;
}

.apcz-search-categories-menu {
    display: none !important;
}


/* ============================================================
   MODAL — CATÉGORIES DE RECHERCHE
   ============================================================ */

body.apcz-search-categories-modal-open {
    overflow: hidden;
}

.apcz-search-categories-modal {
    display: none;
    position: fixed;
    inset: 0;
    z-index: 250000;
}

.apcz-search-categories-modal.show {
    display: block;
}

.apcz-search-categories-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(15, 23, 42, .52);
    backdrop-filter: blur(3px);
}

.apcz-search-categories-dialog {
    position: relative;
    width: min(920px, calc(100vw - 32px));
    max-height: min(760px, calc(100vh - 40px));
    margin: 20px auto;
    background: #fff;
    border-radius: 18px;
    box-shadow: 0 28px 80px rgba(0, 0, 0, .30);
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.apcz-search-categories-header {
    flex: 0 0 auto;
    padding: 22px 24px 18px;
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 20px;
    border-bottom: 1px solid #e9edf2;
}

.apcz-search-categories-kicker {
    display: block;
    margin-bottom: 5px;
    font-size: 10px;
    font-weight: 800;
    letter-spacing: .12em;
    text-transform: uppercase;
    color: var(--apcz-blue);
}

.apcz-search-categories-header h2 {
    margin: 0;
    font-size: 23px;
    line-height: 1.25;
    color: #171717;
}

.apcz-search-categories-header p {
    margin: 6px 0 0;
    font-size: 13px;
    color: #737b87;
}

.apcz-search-categories-close {
    flex: 0 0 42px;
    width: 42px;
    height: 42px;
    border: 0;
    border-radius: 50%;
    background: #f3f5f7;
    color: #222;
    font-size: 29px;
    line-height: 1;
    cursor: pointer;
}

.apcz-search-categories-close:hover {
    background: #e7ebf0;
}

.apcz-search-categories-body {
    min-height: 0;
    overflow-y: auto;
    padding: 20px;
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 15px;
}

.apcz-search-category-group {
    min-width: 0;
    border: 1px solid #e7eaf0;
    border-radius: 14px;
    background: #fff;
    overflow: hidden;
}

.apcz-search-category-group-title {
    min-height: 70px;
    padding: 13px 14px;
    display: flex;
    align-items: center;
    gap: 11px;
    background: #f8fafc;
    border-bottom: 1px solid #e7eaf0;
}

.apcz-search-category-group-icon {
    width: 40px;
    height: 40px;
    flex: 0 0 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 11px;
    background: #fff;
    box-shadow: 0 3px 12px rgba(0, 0, 0, .06);
    font-size: 21px;
}

.apcz-search-category-group-title strong {
    display: block;
    font-size: 15px;
    color: #20242a;
}

.apcz-search-category-group-title small {
    display: block;
    margin-top: 3px;
    font-size: 11px;
    color: #7a828d;
}

.apcz-search-category-options {
    padding: 6px;
}

.apcz-search-modal-option {
    width: 100%;
    min-height: 62px;
    padding: 9px;
    display: grid;
    grid-template-columns: 31px minmax(0, 1fr) 18px;
    align-items: center;
    gap: 8px;
    border: 0;
    border-radius: 10px;
    background: transparent;
    color: #222;
    text-align: left;
    cursor: pointer;
    transition: background .16s ease, transform .16s ease;
}

.apcz-search-modal-option:hover,
.apcz-search-modal-option.is-selected {
    background: #f0f6ff;
}

.apcz-search-modal-option:hover {
    transform: translateX(2px);
}

.apcz-search-modal-option .option-icon {
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 9px;
    background: #f4f6f8;
    font-size: 15px;
}

.apcz-search-modal-option strong {
    display: block;
    font-size: 12px;
    line-height: 1.25;
    color: #252a31;
}

.apcz-search-modal-option small {
    display: block;
    margin-top: 3px;
    font-size: 10px;
    line-height: 1.25;
    color: #858d98;
}

.apcz-search-modal-option.is-selected strong {
    color: var(--apcz-blue);
}

.apcz-search-modal-option .option-arrow {
    font-size: 21px;
    color: #a0a7b1;
    text-align: right;
}

.apcz-search-category-empty {
    padding: 18px 12px;
    color: #7d8590;
    font-size: 11px;
    line-height: 1.4;
    text-align: center;
}



/* ============================================================
   CHEVRONS DROPDOWN
   ============================================================ */

.apcz-dropdown-arrow {
    width: 7px;
    height: 7px;
    border-right: 1.5px solid currentColor;
    border-bottom: 1.5px solid currentColor;
    transform: rotate(45deg);
    display: inline-block;
    margin-left: 5px;
    margin-top: -4px;
    flex-shrink: 0;
    transition: transform .2s ease;
}

.apcz-nav-dropdown-button[aria-expanded="true"] .apcz-dropdown-arrow {
    transform: rotate(225deg);
    margin-top: 4px;
}

.apcz-account-arrow {
    width: 7px;
    height: 7px;
    margin-left: 2px;
    margin-top: -4px;
    flex: 0 0 7px;
    align-self: center;
}

.apcz-account-button {
    min-height: 46px;
}

.apcz-account-button .apcz-account-arrow {
    position: relative;
    top: 0;
}

.apcz-option .apcz-dropdown-arrow {
    margin-left: 3px;
    margin-top: -3px;
}


/* INPUT */

.apcz-search-input-wrapper {

    flex: 1;

    display: flex;

    align-items: center;

}

.apcz-search-icon {

    padding-left: 18px;

    font-size: 25px;

    color: #7d8490;

}

.apcz-search input {

    width: 100%;

    height: 100%;

    border: none;

    outline: none;

    padding: 0 15px;

    font-size: 14px;

    color: #222;

}

.apcz-search input::placeholder {

    color: #858b94;

}


/* BOUTON */

.apcz-search-button {

    border: none;

    background: var(--apcz-blue);

    color: white;

    padding: 0 25px;

    font-size: 14px;

    font-weight: 700;

    cursor: pointer;

    transition: .2s ease;

}

.apcz-search-button:hover {

    background: var(--apcz-blue-dark);

}


/* ============================================================
   ACTIONS
   ============================================================ */

.apcz-header-actions {

    display: flex;

    align-items: center;

    gap: 18px;

    flex-shrink: 0;

}

.apcz-action {

    position: relative;

    min-width: 58px;

    text-decoration: none;

    color: #111;

    display: flex;

    flex-direction: column;

    align-items: center;

    justify-content: center;

    gap: 4px;

}

.apcz-action-icon {

    font-size: 29px;

    line-height: 1;

}

.apcz-action-label {

    font-size: 12px;

    font-weight: 600;

    white-space: nowrap;

}


/* BADGES */

.apcz-badge {

    position: absolute;

    top: -5px;

    right: 3px;

    min-width: 20px;

    height: 20px;

    padding: 0 5px;

    border-radius: 50px;

    background: #e52323;

    color: #fff;

    font-size: 11px;

    font-weight: 700;

    display: flex;

    align-items: center;

    justify-content: center;

    border: 2px solid var(--apcz-yellow);

}

.apcz-action-favorites {
    position: relative;
}

.apcz-action-favorites .apcz-favorites-badge {
    position: absolute;
    top: -5px;
    right: 1px;
    min-width: 20px;
    height: 20px;
    padding: 0 5px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50px;
    font-size: 11px;
    line-height: 1;
    font-weight: 700;
}



/* ============================================================
   COMPTE
   ============================================================ */

.apcz-account {

    position: relative;

}

.apcz-account-button {

    border: none;

    background: transparent;

    cursor: pointer;

    display: flex;

    align-items: center;

    gap: 8px;

    color: #111;

}

.apcz-account-image {

    width: 46px;
    height: 46px;

    border-radius: 50%;

    object-fit: cover;

    border: 2px solid #fff;

    box-shadow:
        0 1px 4px rgba(0, 0, 0, .2);

}

.apcz-account-text {

    font-size: 12px;

    font-weight: 700;

    white-space: nowrap;

}


/* MENU COMPTE */

.apcz-account-menu {

    display: none;

    position: absolute;

    top: calc(100% + 14px);

    right: 0;

    width: 230px;

    background: white;

    border-radius: 10px;

    box-shadow:
        0 10px 35px rgba(0, 0, 0, .18);

    border: 1px solid #eee;

    overflow: hidden;

}

.apcz-account-menu.show {

    display: block;

}

.apcz-account-menu a {

    display: flex;

    align-items: center;

    gap: 10px;

    padding: 12px 16px;

    text-decoration: none;

    color: #222;

    font-size: 14px;

    white-space: nowrap;

}

.apcz-account-menu a:hover {

    background: #f5f7fa;

}

.menu-divider {

    height: 1px;

    background: #eee;

    margin: 4px 0;

}

.menu-logout {

    color: #d92323 !important;

}

.menu-count {

    margin-left: auto;

    background: #e52323;

    color: white;

    border-radius: 20px;

    padding: 2px 7px;

    font-size: 10px;

}


/* CONNEXION */

.apcz-login-link {

    color: #111;

    text-decoration: none;

    font-weight: 700;

    font-size: 14px;

    white-space: nowrap;

}


/* ============================================================
   NAVIGATION BLANCHE
   ============================================================ */

.apcz-navigation {

    background: #fff;

    border-bottom: 1px solid #e5e5e5;

    box-shadow:
        0 2px 7px rgba(0, 0, 0, .05);

}

.apcz-navigation-container {

    max-width: 1500px;

    min-height: 72px;

    margin: 0 auto;

    padding: 0 24px;

    display: flex;

    align-items: center;

}


/* TOUS LES ARTICLES */

.apcz-all-articles {

    border: none;

    background: var(--apcz-blue);

    color: white;

    border-radius: 6px;

    min-height: 48px;

    padding: 0 23px;

    display: flex;

    align-items: center;

    gap: 12px;

    font-size: 15px;

    font-weight: 700;

    cursor: pointer;

    white-space: nowrap;

}

.apcz-all-articles:hover {

    background: var(--apcz-blue-dark);

}

.apcz-menu-icon {

    font-size: 22px;

}


/* NAV PRINCIPALE */

.apcz-main-nav {

    display: flex;

    align-items: center;

    height: 100%;

    margin-left: 30px;

    gap: 5px;

}

.apcz-main-nav>a,
.apcz-nav-dropdown-button {

    height: 72px;

    padding: 0 16px;

    display: flex;

    align-items: center;

    gap: 8px;

    border: none;

    background: transparent;

    text-decoration: none;

    color: #191919;

    font-size: 15px;

    font-weight: 600;

    cursor: pointer;

    position: relative;

}

.apcz-main-nav>a:hover,
.apcz-nav-dropdown-button:hover {

    color: var(--apcz-blue);

}

.apcz-main-nav>a.active {

    color: var(--apcz-blue);

}

.apcz-main-nav>a.active::after {

    content: "";

    position: absolute;

    bottom: 0;

    left: 15px;

    right: 15px;

    height: 3px;

    background: var(--apcz-blue);

    border-radius: 3px 3px 0 0;

}


/* ============================================================
   MENU PAGES
   ============================================================ */

.apcz-pages-wrapper,
.apcz-boutiques-wrapper {
    position: relative;
    z-index: 1002;
}

.apcz-pages-menu {

    display: none;

    position: absolute;

    top: calc(100% - 1px);

    left: 0;

    width: 235px;

    background: white;

    border: 1px solid #e8e8e8;

    border-radius: 0 0 10px 10px;

    box-shadow:
        0 12px 30px rgba(0, 0, 0, .15);

    overflow: hidden;

}

.apcz-pages-menu.show {

    display: block;

}

.apcz-pages-menu a {

    display: block;

    padding: 11px 17px;

    text-decoration: none;

    color: #222;

    font-size: 14px;

}

.apcz-pages-menu a:hover {
    background: #f2f6fb;
    color: var(--apcz-blue);
}


/* ============================================================
   BOUTIQUES
   ============================================================ */

.apcz-boutiques-menu {
    width: 255px;
}

.apcz-create-shop {
    color: var(--apcz-blue) !important;
    font-weight: 700;
}


/* ============================================================
   OPTIONS
   ============================================================ */

.apcz-nav-options {

    margin-left: auto;

    display: flex;

    align-items: center;

    gap: 8px;

    border-left: 1px solid #e5e5e5;

    padding-left: 22px;

}

.apcz-option {

    border: none;

    background: transparent;

    padding: 10px 12px;

    display: flex;

    align-items: center;

    gap: 7px;

    font-size: 14px;

    font-weight: 600;

    cursor: pointer;

    color: #222;

}

.apcz-option:hover {

    color: var(--apcz-blue);

}

.apcz-option small {

    font-size: 16px;

}


/* ============================================================
   MEGA-MENU « TOUS LES ARTICLES »
   ============================================================ */

body.apcz-categories-modal-open {
    overflow: hidden;
}

.apcz-categories-modal {
    display: none;
    position: fixed;
    inset: 0;
    z-index: 200000;
}

.apcz-categories-modal.show {
    display: block;
}

.apcz-categories-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(15, 23, 42, .48);
    backdrop-filter: blur(2px);
}

.apcz-categories-dialog {
    position: relative;
    width: min(1180px, calc(100vw - 32px));
    height: min(700px, calc(100vh - 40px));
    margin: 20px auto;
    background: #fff;
    border-radius: 14px;
    box-shadow: 0 25px 70px rgba(0, 0, 0, .28);
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.apcz-categories-header {
    flex: 0 0 auto;
    min-height: 76px;
    padding: 15px 22px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    border-bottom: 1px solid #e9e9e9;
}

.apcz-categories-kicker,
.apcz-category-products-kicker {
    display: block;
    margin-bottom: 3px;
    font-size: 10px;
    font-weight: 800;
    letter-spacing: .12em;
    text-transform: uppercase;
    color: var(--apcz-blue);
}

.apcz-categories-header h2 {
    margin: 0;
    font-size: 22px;
    line-height: 1.2;
}

.apcz-categories-close {
    width: 42px;
    height: 42px;
    border: 0;
    border-radius: 50%;
    background: #f4f5f7;
    color: #222;
    font-size: 30px;
    line-height: 1;
    cursor: pointer;
}

.apcz-categories-close:hover {
    background: #e9edf3;
}

.apcz-categories-body {
    flex: 1 1 auto;
    min-height: 0;
    display: grid;
    grid-template-columns: 285px minmax(0, 1fr);
}

.apcz-categories-sidebar {
    min-height: 0;
    overflow-y: auto;
    border-right: 1px solid #e5e7eb;
    background: #fafafa;
}

.apcz-categories-sidebar-title {
    position: sticky;
    top: 0;
    z-index: 2;
    padding: 15px 18px 11px;
    background: #fafafa;
    color: #6b7280;
    font-size: 11px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: .08em;
}

.apcz-categories-list {
    padding-bottom: 10px;
}

.apcz-category-item {
    width: 100%;
    min-height: 50px;
    padding: 10px 15px 10px 18px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    border: 0;
    border-left: 3px solid transparent;
    background: transparent;
    color: #262626;
    text-align: left;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
}

.apcz-category-item:hover {
    background: #f0f5fc;
    color: var(--apcz-blue);
}

.apcz-category-item.active {
    background: #fff;
    border-left-color: var(--apcz-blue);
    color: var(--apcz-blue);
    box-shadow: 0 1px 5px rgba(0, 0, 0, .04);
}

.apcz-category-item-name {
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
}

.apcz-category-item-arrow {
    flex: 0 0 auto;
    font-size: 22px;
    line-height: 1;
    color: #9ca3af;
}

.apcz-category-item.active .apcz-category-item-arrow {
    color: var(--apcz-blue);
}

.apcz-category-products-panel {
    min-width: 0;
    min-height: 0;
    overflow-y: auto;
    padding: 22px;
}

.apcz-category-products-heading {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 18px;
    margin-bottom: 18px;
}

.apcz-category-products-heading h3 {
    margin: 0;
    font-size: 24px;
    line-height: 1.2;
}

.apcz-category-see-all {
    flex: 0 0 auto;
    color: var(--apcz-blue);
    text-decoration: none;
    font-size: 12px;
    font-weight: 700;
}

.apcz-category-see-all:hover {
    text-decoration: underline;
}

.apcz-category-products-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 16px;
}

.apcz-category-product-card {
    min-width: 0;
    border: 1px solid #ececec;
    border-radius: 10px;
    background: #fff;
    overflow: hidden;
    text-decoration: none;
    color: #222;
    transition: transform .15s ease, box-shadow .15s ease, border-color .15s ease;
}

.apcz-category-product-card:hover {
    transform: translateY(-2px);
    border-color: #d8e5f7;
    box-shadow: 0 7px 20px rgba(0, 0, 0, .08);
}

.apcz-category-product-image {
    width: 100%;
    aspect-ratio: 1 / 1;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #f7f7f7;
    overflow: hidden;
}

.apcz-category-product-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.apcz-category-product-placeholder {
    font-size: 34px;
    color: #a5acb7;
}

.apcz-category-product-info {
    padding: 10px 11px 12px;
}

.apcz-category-product-name {
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
    overflow: hidden;
    min-height: 34px;
    font-size: 12px;
    line-height: 1.4;
    font-weight: 600;
}

.apcz-category-product-price {
    margin-top: 7px;
    font-size: 13px;
    font-weight: 800;
    color: var(--apcz-blue);
}

.apcz-category-product-old-price {
    margin-left: 5px;
    color: #9298a3;
    font-size: 10px;
    font-weight: 500;
    text-decoration: line-through;
}

.apcz-category-empty {
    min-height: 220px;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    color: #737b88;
    font-size: 14px;
    border: 1px dashed #d9dde4;
    border-radius: 12px;
    padding: 20px;
}

.apcz-categories-empty {
    padding: 20px 18px;
    color: #7b8490;
    font-size: 13px;
}


/* ============================================================
   RESPONSIVE
   ============================================================ */

@media (max-width: 1200px) {

    .apcz-header-container {

        gap: 15px;

    }

    .apcz-logo-text small {

        display: none;

    }

    .apcz-logo-text strong {

        font-size: 25px;

    }

    .apcz-search-category {

        min-width: 190px;

    }

    .apcz-action-label {

        display: none;

    }

    .apcz-main-nav {

        margin-left: 15px;

    }

}


@media (max-width: 991px) {

    .apcz-header-main {

        background: var(--apcz-yellow);

    }

    .apcz-header-container {

        min-height: auto;

        padding: 12px 15px;

        display: grid;

        grid-template-columns: auto 1fr auto;

        gap: 12px;

    }

    .apcz-logo img {

        width: 45px;

        height: 45px;

    }

    .apcz-logo-text strong {

        font-size: 22px;

    }

    .apcz-search {

        grid-column: 1 / -1;

        grid-row: 2;

        width: 100%;

        max-width: none;

        height: 48px;

    }

    .apcz-search-category-wrapper {

        display: block;

    }

    .apcz-search-button {

        padding: 0 17px;

    }

    .apcz-header-actions {

        gap: 7px;

    }

    .apcz-action {

        min-width: 38px;

    }

    .apcz-action-icon {

        font-size: 25px;

    }

    .apcz-account-text {

        display: none;

    }

    .apcz-account-image {

        width: 40px;

        height: 40px;

    }

    .apcz-account-button {

        align-items: center;

        gap: 7px;

    }

    .apcz-account-arrow {

        margin-top: -4px;

    }


    /* NAV MOBILE */

    .apcz-navigation-container {

        min-height: 55px;

        padding: 0 12px;

        position: relative;

        overflow: visible;

    }

    .apcz-pages-wrapper,
    .apcz-boutiques-wrapper {
        position: relative;
    }

    .apcz-pages-menu {
        top: calc(100% - 1px);
        z-index: 9999;
    }

    .apcz-all-articles {

        min-height: 40px;

        padding: 0 13px;

        font-size: 13px;

    }

    .apcz-main-nav {

        margin-left: 5px;

        gap: 0;

    }

    .apcz-main-nav>a,
    .apcz-nav-dropdown-button {

        height: 55px;

        padding: 0 10px;

        font-size: 13px;

    }

    .apcz-nav-options {

        padding-left: 8px;

    }

    .apcz-option {

        padding: 8px;

        font-size: 12px;

    }

}


@media (max-width: 600px) {

    /* ========================================================
       HEADER MOBILE — LARGEUR EXACTE DE L'ÉCRAN
       ======================================================== */

    .apcz-header,
    .apcz-header-main,
    .apcz-navigation {
        width: 100vw;
        max-width: 100vw;
    }

    .apcz-header-container {

        width: 100%;
        max-width: none;

        min-width: 0;

        grid-template-columns: minmax(0, 1fr) auto;

        padding: 10px 10px;

        gap: 8px;

    }

    .apcz-logo {

        min-width: 0;

        gap: 6px;

    }

    .apcz-logo img {

        width: 40px;
        height: 40px;

        flex: 0 0 40px;

    }

    .apcz-logo-text {

        min-width: 0;

    }

    .apcz-logo-text strong {

        font-size: 20px;

        white-space: nowrap;

    }

    .apcz-logo-text small {

        display: none;

    }


    /* ACTIONS : elles restent toujours dans la largeur disponible */

    .apcz-header-actions {

        min-width: 0;

        gap: 3px;

        flex-shrink: 0;

    }

    .apcz-action {

        min-width: 34px;

        width: 34px;

    }

    .apcz-action-icon {

        font-size: 22px;

    }

    .apcz-action-label {

        display: none;

    }

    /* Sur mobile, les favoris sont accessibles dans « Mon compte ». */
    .apcz-action-favorites {
        display: none;
    }

    .apcz-account-button {

        padding: 0;

        gap: 5px;

        min-height: 40px;

    }

    .apcz-account-image {

        width: 38px;
        height: 38px;

    }

    .apcz-account-arrow {

        width: 6px;
        height: 6px;

        flex: 0 0 6px;

        margin-left: 0;

        margin-top: -3px;

    }


    /* RECHERCHE */

    .apcz-search {

        grid-column: 1 / -1;

        grid-row: 2;

        width: 100%;

        max-width: none;

        min-width: 0;

        height: 46px;

    }

    .apcz-search-category-wrapper {

        display: none;

    }

    .apcz-search-input-wrapper {

        min-width: 0;

    }

    .apcz-search input {

        min-width: 0;

        font-size: 12px;

        padding: 0 8px;

    }

    .apcz-search-icon {

        padding-left: 12px;

        font-size: 21px;

    }

    .apcz-search-button {

        flex: 0 0 auto;

        font-size: 12px;

        padding: 0 12px;

    }


    /* ========================================================
       NAVIGATION MOBILE — TOUS LES ÉLÉMENTS TIENNENT
       ======================================================== */

    .apcz-navigation {

        position: relative;

        overflow: visible;

    }

    .apcz-navigation-container {

        width: 100%;

        max-width: none;

        min-width: 0;

        min-height: 52px;

        padding: 0 7px;

        display: flex;

        align-items: center;

        overflow: visible;

        gap: 2px;

    }

    .apcz-all-articles {

        flex: 0 0 auto;

        min-width: 0;

        width: auto;

        min-height: 38px;

        padding: 0 8px;

        gap: 5px;

        font-size: 11px;

    }

    .apcz-menu-icon {

        font-size: 18px;

    }


    .apcz-main-nav {

        flex: 1 1 auto;

        min-width: 0;

        margin-left: 0;

        gap: 0;

        justify-content: space-between;

    }

    .apcz-main-nav>a,
    .apcz-nav-dropdown-button {

        flex: 0 1 auto;

        min-width: 0;

        height: 52px;

        padding: 0 5px;

        gap: 4px;

        font-size: 12px;

        white-space: nowrap;

    }

    .apcz-main-nav>a.active::after {

        left: 5px;

        right: 5px;

    }

    .apcz-nav-icon {

        font-size: 12px;

    }

    .apcz-dropdown-arrow {

        width: 6px;
        height: 6px;

        flex: 0 0 6px;

        margin-left: 2px;

        margin-top: -3px;

    }


    /* Les menus déroulants restent hors du flux et ne sont
       plus coupés par la barre de navigation. */

    .apcz-pages-wrapper,
    .apcz-boutiques-wrapper {

        position: relative;

        flex: 0 1 auto;

        min-width: 0;

    }

    .apcz-pages-menu {

        top: calc(100% - 1px);

        left: 0;

        width: min(235px, calc(100vw - 14px));

        max-width: calc(100vw - 14px);

        z-index: 99999;

    }

    .apcz-boutiques-menu {

        top: calc(100% - 1px);

        left: auto;

        right: 0;

        width: min(255px, calc(100vw - 14px));

        max-width: calc(100vw - 14px);

        z-index: 99999;

    }

    .apcz-pages-menu a {

        max-width: 100%;

        overflow: hidden;

        text-overflow: ellipsis;

    }


    /* OPTIONS FCFA / LANGUE masquées sur très petit écran */

    .apcz-nav-options {

        display: none;

    }


    /* MENU COMPTE */

    .apcz-account-menu {

        right: 0;

        max-width: calc(100vw - 20px);

        z-index: 100000;

    }


    /* ========================================================
       MEGA-MENU CATÉGORIES SUR MOBILE
       ======================================================== */

    .apcz-categories-dialog {

        width: 100vw;

        height: 100vh;

        margin: 0;

        border-radius: 0;

    }

    .apcz-categories-header {

        min-height: 62px;

        padding: 10px 14px;

    }

    .apcz-categories-header h2 {

        font-size: 18px;

    }

    .apcz-categories-close {

        width: 38px;

        height: 38px;

        font-size: 27px;

    }

    .apcz-categories-body {

        grid-template-columns: 40% minmax(0, 60%);

    }

    .apcz-categories-sidebar-title {

        padding: 12px 10px 9px;

        font-size: 9px;

    }

    .apcz-category-item {

        min-height: 48px;

        padding: 9px 7px 9px 10px;

        gap: 5px;

        font-size: 11px;

    }

    .apcz-category-item-arrow {

        font-size: 18px;

    }

    .apcz-category-products-panel {

        padding: 14px 10px;

    }

    .apcz-category-products-heading {

        align-items: flex-start;

        flex-direction: column;

        gap: 7px;

        margin-bottom: 12px;

    }

    .apcz-category-products-heading h3 {

        font-size: 18px;

    }

    .apcz-category-see-all {

        font-size: 10px;

    }

    .apcz-category-products-grid {

        grid-template-columns: repeat(2, minmax(0, 1fr));

        gap: 9px;

    }

    .apcz-category-product-info {

        padding: 8px;

    }

    .apcz-category-product-name {

        font-size: 10px;

        min-height: 29px;

    }

    .apcz-category-product-price {

        font-size: 11px;

    }

}

/* ============================================================
   APCZANDO — LISTING PRODUITS COMPACT DU MEGA-MENU
   ============================================================ */

/*
 * Les produits ne sont volontairement PAS présentés comme de
 * grosses cartes. Le panneau droit fonctionne comme une petite
 * liste/catalogue : miniature + titre + prix.
 */

.apcz-category-products-grid {
    display: flex !important;
    flex-direction: column !important;
    gap: 7px !important;
}

.apcz-category-product-card {
    width: 100%;
    min-width: 0;
    height: 70px;
    min-height: 70px;

    display: grid !important;
    grid-template-columns: 58px minmax(0, 1fr) !important;
    align-items: center;

    gap: 12px;

    padding: 5px 12px 5px 5px;

    border: 1px solid #edf0f4;
    border-radius: 9px;

    background: #fff;

    overflow: hidden;

    text-decoration: none;
    color: #222;

    box-sizing: border-box;

    transition:
        background .15s ease,
        border-color .15s ease,
        box-shadow .15s ease,
        transform .15s ease;
}

.apcz-category-product-card:hover {
    transform: translateX(2px);

    background: #fbfdff;

    border-color: #d8e5f5;

    box-shadow:
        0 4px 14px rgba(20, 50, 90, .07);
}


/* Petite miniature */

.apcz-category-product-image {
    width: 58px !important;
    height: 58px !important;

    min-width: 58px;

    aspect-ratio: auto !important;

    display: flex;

    align-items: center;
    justify-content: center;

    background: #f6f7f9;

    border-radius: 7px;

    overflow: hidden;
}

.apcz-category-product-image img {
    width: 100%;
    height: 100%;

    object-fit: cover;

    transition: transform .18s ease;
}

.apcz-category-product-card:hover .apcz-category-product-image img {
    transform: scale(1.04);
}

.apcz-category-product-placeholder {
    font-size: 22px;
    color: #a5acb7;
}


/* Informations compactes */

.apcz-category-product-info {
    min-width: 0;

    padding: 0 !important;

    display: flex;

    flex-direction: column;

    justify-content: center;
}

.apcz-category-product-name {
    display: -webkit-box;

    -webkit-box-orient: vertical;

    -webkit-line-clamp: 2;

    overflow: hidden;

    max-height: 32px;

    min-height: 0 !important;

    font-size: 12px;

    line-height: 1.35;

    font-weight: 650;

    color: #252a31;
}

.apcz-category-product-price {
    margin-top: 5px !important;

    font-size: 12px;

    line-height: 1.2;

    font-weight: 800;

    color: var(--apcz-blue);

    white-space: nowrap;
}

.apcz-category-product-old-price {
    margin-left: 6px;

    color: #9ca2ab;

    font-size: 9px;

    font-weight: 500;

    text-decoration: line-through;

    white-space: nowrap;
}


/* Petite ligne visuelle dans le panneau */

.apcz-category-products-heading {
    margin-bottom: 12px;

    padding-bottom: 11px;

    border-bottom: 1px solid #eef0f3;
}


/* ============================================================
   MOBILE — LISTING ENCORE PLUS FIN
   ============================================================ */

@media (max-width: 600px) {

    .apcz-category-products-grid {
        gap: 6px !important;
    }

    .apcz-category-product-card {
        height: 58px;

        min-height: 58px;

        grid-template-columns: 46px minmax(0, 1fr) !important;

        gap: 8px;

        padding: 4px 7px 4px 4px;

        border-radius: 7px;
    }

    .apcz-category-product-image {
        width: 46px !important;
        height: 46px !important;

        min-width: 46px;

        border-radius: 6px;
    }

    .apcz-category-product-placeholder {
        font-size: 18px;
    }

    .apcz-category-product-name {
        font-size: 10px;

        line-height: 1.3;

        max-height: 26px;
    }

    .apcz-category-product-price {
        margin-top: 3px !important;

        font-size: 9px;
    }

    .apcz-category-product-old-price {
        font-size: 7px;

        margin-left: 4px;
    }

    .apcz-category-products-heading {
        margin-bottom: 9px;

        padding-bottom: 8px;
    }

}

/* ============================================================
   APCZANDO — MEGA-MENU PRODUITS : CATALOGUE HORIZONTAL
   ============================================================ */

/*
 * Chaque article est une petite fiche horizontale :
 * [ image ] [ nom / prix ]
 *
 * Le panneau droit utilise plusieurs colonnes afin de montrer
 * davantage de produits sans agrandir inutilement les cartes.
 */

.apcz-category-products-grid {
    display: grid !important;
    grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
    gap: 12px 18px !important;
    align-items: start;
}

.apcz-category-product-card {
    width: 100%;
    min-width: 0;
    height: 82px;
    min-height: 82px;

    display: grid !important;
    grid-template-columns: 76px minmax(0, 1fr) !important;
    align-items: center;

    gap: 11px;

    padding: 5px 8px 5px 5px;

    border: 1px solid #edf0f4;
    border-radius: 10px;

    background: #fff;

    overflow: hidden;

    box-sizing: border-box;

    text-decoration: none;
    color: #222;

    transition:
        transform .15s ease,
        border-color .15s ease,
        background .15s ease,
        box-shadow .15s ease;
}

.apcz-category-product-card:hover {
    transform: translateY(-1px);

    background: #fbfdff;

    border-color: #d7e5f7;

    box-shadow:
        0 5px 15px rgba(20, 50, 90, .07);
}


/* IMAGE — légèrement plus grande */

.apcz-category-product-image {
    width: 76px !important;
    height: 70px !important;

    min-width: 76px;

    aspect-ratio: auto !important;

    display: flex;
    align-items: center;
    justify-content: center;

    background: #f7f8fa;

    border-radius: 8px;

    overflow: hidden;
}

.apcz-category-product-image img {
    width: 100%;
    height: 100%;

    object-fit: cover;

    transition: transform .18s ease;
}

.apcz-category-product-card:hover .apcz-category-product-image img {
    transform: scale(1.04);
}

.apcz-category-product-placeholder {
    font-size: 24px;
    color: #a5acb7;
}


/* CONTENU */

.apcz-category-product-info {
    min-width: 0;

    height: 100%;

    padding: 0 !important;

    display: flex;
    flex-direction: column;
    justify-content: center;

    overflow: hidden;
}


/*
 * Tous les noms occupent exactement la même hauteur.
 * 2 lignes maximum : les noms trop longs sont coupés
 * automatiquement avec « … ».
 */

.apcz-category-product-name {
    display: -webkit-box;

    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;

    overflow: hidden;

    height: 32px;
    min-height: 32px;
    max-height: 32px;

    font-size: 13px;
    line-height: 16px;

    font-weight: 500;

    color: #252a31;
}


/* PRIX toujours au même niveau */

.apcz-category-product-price {
    height: 16px;

    margin-top: 6px !important;

    overflow: hidden;

    font-size: 12px;
    line-height: 16px;

    font-weight: 800;

    color: #d50808;

    white-space: nowrap;
}

.apcz-category-product-old-price {
    margin-left: 5px;

    color: #9ca2ab;

    font-size: 9px;
    font-weight: 500;

    text-decoration: line-through;

    white-space: nowrap;
}


/* ============================================================
   TABLETTES / PETITS ÉCRANS
   ============================================================ */

@media (max-width: 1100px) {

    .apcz-category-products-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
        gap: 10px 12px !important;
    }

}


/* ============================================================
   MOBILE
   ============================================================ */

@media (max-width: 600px) {

    .apcz-category-products-grid {
        display: grid !important;

        grid-template-columns: 1fr !important;

        gap: 7px !important;
    }

    .apcz-category-product-card {
        height: 66px;
        min-height: 66px;

        grid-template-columns: 58px minmax(0, 1fr) !important;

        gap: 9px;

        padding: 4px 7px 4px 4px;

        border-radius: 8px;
    }

    .apcz-category-product-image {
        width: 58px !important;
        height: 58px !important;

        min-width: 58px;

        border-radius: 7px;
    }

    .apcz-category-product-placeholder {
        font-size: 20px;
    }

    .apcz-category-product-name {
        height: 28px;
        min-height: 28px;
        max-height: 28px;

        font-size: 10px;
        line-height: 14px;
    }

    .apcz-category-product-price {
        height: 14px;

        margin-top: 3px !important;

        font-size: 10px;
        line-height: 14px;
    }

    .apcz-category-product-old-price {
        font-size: 8px;
    }

}

@media (max-width: 600px) {

    .apcz-search-categories-dialog {
        width: calc(100vw - 20px);
        max-height: calc(100vh - 20px);
        margin: 10px auto;
        border-radius: 14px;
    }

    .apcz-search-categories-header {
        padding: 17px 17px 14px;
    }

    .apcz-search-categories-header h2 {
        font-size: 19px;
    }

    .apcz-search-categories-body {
        grid-template-columns: 1fr;
        padding: 12px;
        gap: 10px;
    }

}
