/* Marques, retours, factures clients et opérations comptables. */
.brands-list-page .main-product,
.return-articles-page .main-product,
.return-clients-page .main-product,
.return-cart-page .main-product { min-height: 680px; align-items: flex-start; }
.brands-list-page .find-box,
.return-articles-page .find-box,
.return-clients-page .find-box,
.return-cart-page .find-box { width: 100%; max-width: 1180px; padding: clamp(24px,3vw,42px); text-align: center; background: rgba(255,255,255,.94); border: 1px solid rgba(7,32,62,.08); border-radius: 22px; box-shadow: 0 24px 60px rgba(7,32,62,.12); }
.brands-list-page .find-box h1,
.return-articles-page .find-box h1,
.return-clients-page .find-box h1,
.return-cart-page .find-box h1 { margin: 0; padding: 0; font-size: clamp(28px,5vw,44px); }
.brands-list-page .find-box h4,
.return-articles-page .find-box h4,
.return-cart-page .find-box h4 { min-height: 0; margin: 8px 0; color: #e25f16; }

/* Liste des marques. */
.brands-list-page .product-sh { display: block; width: 100%; margin-top: 22px; }
.brands-list-page .product-sh table { display: block; width: 100%; }
.brands-list-page .product-sh tbody { display: block; }
.brands-list-page .product-sh tr { display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); gap: 14px; width: 100%; }
.brands-list-page .product-sh td { display: block; width: auto; min-width: 0; }
.brands-list-page .product-sh td:empty { display: none; }
.brands-list-page .product-sh td .form-sh { width: 100%; height: 100%; margin: 0; }
.brands-list-page .product-sh td .btn { display: flex; flex-direction: column; width: 100%; height: 100%; padding: 10px; color: #173e59; background: #fff; border: 1px solid #d3e0e9; border-radius: 13px; box-shadow: 0 7px 22px rgba(7,32,62,.09); }
.brands-list-page .product-sh td img { width: 100%; aspect-ratio: 16 / 10; object-fit: contain; border-radius: 8px; }
.brands-list-page .product-sh td .btn div { min-height: 38px; padding: 9px 4px 2px; font-weight: 700; }
.brands-list-page .p_art { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 6px; margin: 18px 0; }
.brands-list-page .p_art .num_p { display: inline-flex; align-items: center; justify-content: center; min-width: 34px; min-height: 34px; padding: 4px; color: #435eff; border: 1px solid #b8c4d0; border-radius: 8px; }
.brands-list-page .p_art .num_p1 { color: #fff; background: #147ac1; border-color: #147ac1; }
.brands-list-page .product-sh > div:not(:first-child) .form-sh,
.return-articles-page .find-box > div .form-sh { margin-bottom: 10px; }
.brands-list-page .brands-list-actions { display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); gap: 12px; width: 100%; margin-top: 22px; padding-top: 20px; border-top: 1px solid #d8e3ec; }
.brands-list-page .brands-list-actions .btn { display: flex; align-items: center; justify-content: center; gap: 8px; width: 100%; min-height: 54px; padding: 11px 14px; color: #49657d; font-size: 16px; font-weight: 700; background: #eef3f7; border: 1px solid #d4e0ea; border-radius: 11px; }
.brands-list-page .brands-list-actions .brands-list-cart { color: #075a98; background: #edf6fc; border-color: #bcd9ed; }
.brands-list-page .brands-list-actions .brands-list-logout { color: #a12f35; background: #fff6f6; border-color: #edc8ca; }

/* Cartes des articles retournables. */
.return-articles-page .return-product-card { display: inline-block; width: calc(25% - 14px); margin: 18px 6px 0; vertical-align: top; }
.return-articles-page .return-product-card .btn { display: flex; flex-direction: column; width: 100%; padding: 9px; color: #222; background: #fff; border: 1px solid #d5e1e9; border-radius: 12px; box-shadow: 0 7px 22px rgba(7,32,62,.1); }
.return-articles-page .return-product-card img { width: 100%; aspect-ratio: 1 / 1; object-fit: contain; }
.return-articles-page .return-product-card .btn div:first-of-type { min-height: 42px; padding: 8px 3px; font-size: 14px; }
.return-articles-page .return-product-card .btn div:last-of-type { padding-top: 7px; color: #d7272e; border-top: 1px solid #cbd5dd; }

/* Menus supérieur et inférieur des articles retournables. */
.return-articles-page .return-articles-menu { display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); gap: 12px; width: 100%; margin: 22px 0; }
.return-articles-page .return-articles-menu .btn { display: flex; align-items: center; justify-content: center; gap: 8px; width: 100%; min-height: 54px; padding: 11px 14px; color: #49657d; font-size: 16px; font-weight: 700; background: #eef3f7; border: 1px solid #d4e0ea; border-radius: 11px; transition: background-color .18s ease, border-color .18s ease; }
.return-articles-page .return-articles-menu .btn:hover,
.return-articles-page .return-articles-menu .btn:focus { color: #3c5c76; background: #e5eef5; border-color: #c1d2df; }
.return-articles-page .return-articles-menu .btn i { font-size: 18px; }
.return-articles-page .return-articles-menu .return-menu-cart { color: #075a98; background: #edf6fc; border-color: #bcd9ed; }
.return-articles-page .return-articles-menu .return-menu-logout { color: #a12f35; background: #fff6f6; border-color: #edc8ca; }
.return-articles-page .return-articles-menu-bottom { padding-top: 20px; border-top: 1px solid #d8e3ec; }
.return-articles-page .return-products-grid { width: 100%; }

/* Tableaux des clients et du panier de retour. */
.return-clients-page .find-box > .form-sh,
.return-cart-page .find-box > .form-sh { margin: 24px 0 0; }
.return-clients-page .form-sh > .btn,
.return-cart-page .form-sh > .btn { display: grid; width: 100%; color: #222; background: #fff; border: 1px solid #c7d4dd; border-radius: 9px; }
.return-clients-page .form-sh > .btn { grid-template-columns: minmax(0,1.6fr) minmax(100px,1fr) minmax(100px,1fr); }
.return-cart-page .form-sh > .btn { grid-template-columns: minmax(0,2fr) repeat(3,minmax(90px,1fr)); }
.return-clients-page .form-sh > .btn > *,
.return-cart-page .form-sh > .btn > * { display: flex; align-items: center; justify-content: center; min-width: 0; min-height: 52px; padding: 8px 6px; overflow-wrap: anywhere; border-left: 1px solid rgba(34,34,34,.25); }
.return-clients-page .form-sh > .btn > *:last-child,
.return-cart-page .form-sh > .btn > *:last-child { border-left: 0; }
.return-clients-page .form-sh > .btn.return-table-header,
.return-cart-page .form-sh > .btn.return-table-header { color: #fff; font-weight: 800; background: #5483b4; border-color: #5483b4; }
.return-cart-page .form-sh a[href^="sup_panier"] { display: inline-flex; min-width: 27px; min-height: 27px; margin-left: 6px; align-items: center; justify-content: center; color: #fff; background: #c9383e; border-radius: 6px; }
.return-cart-page .find-box > div > .form-sh:not(:has(.btn)) { margin: 18px 0; padding: 14px; color: #173e59; font-size: 19px; font-weight: 800; background: #edf5fa; border-radius: 10px; }
.return-cart-page .return-cart-table,
.return-cart-page .return-cart-items { width: 100%; margin: 0; }
.return-cart-page .return-cart-items > .form-sh { width: 100%; margin: 7px 0 0; }
.return-cart-page .return-cart-summary { width: 100%; margin: 20px 0; padding: 15px 18px; color: #173e59; font-size: 19px; font-weight: 800; text-align: right; background: #edf5fa; border: 1px solid #d4e0ea; border-radius: 11px; }
.return-cart-page .return-cart-actions { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 12px; width: 100%; margin-top: 20px; }
.return-cart-page .return-cart-actions .btn { display: flex; align-items: center; justify-content: center; gap: 8px; width: 100%; min-height: 54px; padding: 11px 14px; color: #49657d; font-size: 16px; font-weight: 700; background: #eef3f7; border: 1px solid #d4e0ea; border-radius: 11px; }
.return-cart-page .return-cart-actions .return-cart-validate { color: #075a98; background: #edf6fc; border-color: #bcd9ed; }
.return-cart-page .return-cart-actions .return-cart-logout { color: #a12f35; background: #fff6f6; border-color: #edc8ca; }

/* Historique des factures du client. */
.customer-invoice-history-page .invoice-history-content > div:not(.invoice-filter-panel) { min-width: 0; }
.customer-invoice-history-page .invoice-history-content > div:not(.invoice-filter-panel) > .form-sh { display: flex; gap: 8px; width: 100%; margin: 0; }
.customer-invoice-history-page .invoice-history-content > div:not(.invoice-filter-panel) .btn { flex: 1 1 auto; }
.customer-invoice-history-page .invoice-history-content > div:not(.invoice-filter-panel) .btn:last-child:not(:only-child) { flex: 0 0 16%; }

/* Carnet et formulaire de paiement dans konn.php. */
.accounting-workflow-page .ledger-page,
.accounting-workflow-page .payment-page { width: 100%; }
.accounting-workflow-page .ledger-page center h3 { margin: 0 0 16px; color: #173e59; font-size: clamp(22px,4vw,32px); }
.accounting-workflow-page .ledger-page > .form-sh form { display: grid; grid-template-columns: minmax(0,2fr) minmax(130px,.7fr); gap: 10px; width: 100%; margin-bottom: 12px; padding: 14px; background: #f5f9fc; border: 1px solid #d5e2eb; border-radius: 12px; }
.accounting-workflow-page .ledger-page form select,
.accounting-workflow-page .ledger-page form input { width: 100%; min-height: 48px; padding: 9px 11px; text-align: center; background: #fff; border: 1px solid #cbdbe6; border-radius: 9px; }
.accounting-workflow-page .ledger-page form input[type="submit"] { color: #fff; font-weight: 800; background: #147ac1; border-color: #147ac1; }
.accounting-workflow-page .ledger-page > .form-sh > a { display: inline-flex; align-items: center; justify-content: center; width: calc(33.333% - 9px); min-height: 58px; margin: 5px 3px; font-size: 20px; font-weight: 800; border-radius: 10px; }
.accounting-workflow-page .ledger-page > .form-sh > a:nth-of-type(1) { color: #087000; background: #a0ff8d; }
.accounting-workflow-page .ledger-page > .form-sh > a:nth-of-type(2) { color: #b11920; background: #ffaaaa; }
.accounting-workflow-page .ledger-page > .form-sh > a:nth-of-type(3) { color: #0542ad; background: #3fd4f3; }
.accounting-workflow-page .ledger-page .ledger-row,
.accounting-workflow-page .ledger-page .form-sh > .btn { display: grid; grid-template-columns: minmax(0,1.65fr) minmax(100px,1fr) minmax(100px,1fr); width: 100%; margin-top: 5px; color: #222; border: 1px solid #b9c7d1; border-radius: 8px; }
.accounting-workflow-page .ledger-page .form-sh > .btn > div { display: flex; align-items: center; justify-content: center; min-width: 0; min-height: 48px; padding: 7px 5px; overflow-wrap: anywhere; border-left: 1px solid rgba(34,34,34,.3); }
.accounting-workflow-page .ledger-page .form-sh > .btn > div:last-child { border-left: 0; }
.accounting-workflow-page .ledger-page .ledger-op-1 { background: #a0ff8d; }
.accounting-workflow-page .ledger-page .ledger-op-2 { background: #3fd4f3; }
.accounting-workflow-page .ledger-page .ledger-op-3 { background: #fdf14c; }
.accounting-workflow-page .ledger-page .ledger-op-0 { background: #ffaaaa; }
.accounting-workflow-page .ledger-page .ledger-op--1 { background: #fff; }
.accounting-workflow-page .ledger-page > .form-sh:not(:has(form)):not(:has(.btn)) { padding: 8px 12px; color: #173e59; font-size: 19px; font-weight: 800; text-align: left; }
.accounting-workflow-page .payment-page > form > .form-sh { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 11px; padding: 16px; background: #f5f9fc; border: 1px solid #d5e2eb; border-radius: 13px; }
.accounting-workflow-page .payment-page > form input,
.accounting-workflow-page .payment-page > form select { width: 100%; min-height: 50px; margin: 0; padding: 10px 12px; text-align: center; background: #fff; border: 1px solid #cbdbe6; border-radius: 10px; }
.accounting-workflow-page .payment-page > form input[type="submit"] { grid-column: 1 / -1; color: #fff; font-weight: 800; background: #147ac1; border-color: #147ac1; }
.accounting-workflow-page .payment-page > div .form-sh { margin: 10px 0 0; }
.accounting-workflow-page .payment-page > div .btn { display: flex; align-items: center; justify-content: center; width: 100%; min-height: 50px; color: #16415f; background: #f7fafc; border: 1px solid #d4e1ea; border-radius: 10px; }
.accounting-workflow-page .payment-page .form-sh > .btn:not(a) { display: grid; grid-template-columns: minmax(0,1.65fr) minmax(90px,1fr) minmax(100px,1fr); width: 100%; margin-top: 5px; color: #222; background: #ffaaaa; border: 1px solid #c9898c; border-radius: 8px; }
.accounting-workflow-page .payment-page .form-sh > .btn:not(a) > div { display: flex; align-items: center; justify-content: center; min-width: 0; min-height: 48px; padding: 7px 5px; overflow-wrap: anywhere; border-left: 1px solid rgba(34,34,34,.3); }
.accounting-workflow-page .payment-page .form-sh > .btn:not(a) > div:last-child { border-left: 0; }
.accounting-workflow-page .payment-page > .form-sh:not(:has(form)):not(:has(.btn)) { padding: 10px 12px; color: #173e59; font-size: 20px; font-weight: 800; text-align: left; }

@media (max-width: 991px) {
   .brands-list-page .product-sh tr { grid-template-columns: repeat(2,minmax(0,1fr)); }
   .return-articles-page .return-product-card { width: calc(33.333% - 14px); }
}
@media (max-width: 767px) {
   .brands-list-page .find-box,
   .return-articles-page .find-box,
   .return-clients-page .find-box,
   .return-cart-page .find-box { width: 100%; max-width: none; padding: 24px 5px; border-radius: 12px; }
   .brands-list-page .product-sh tr { grid-template-columns: 1fr; gap: 9px; }
   .brands-list-page .brands-list-actions { grid-template-columns: 1fr; gap: 7px; }
   .brands-list-page .brands-list-actions .btn { min-height: 50px; padding: 9px 10px; }
   .return-articles-page .return-product-card { width: calc(50% - 10px); margin: 10px 3px 0; }
   .return-articles-page .return-articles-menu { grid-template-columns: 1fr; gap: 7px; width: 100%; margin: 15px 0; }
   .return-articles-page .return-articles-menu .btn { min-height: 50px; padding: 9px 10px; border-radius: 10px; }
   .return-clients-page .form-sh > .btn { grid-template-columns: minmax(0,1.4fr) minmax(78px,.8fr) minmax(76px,.8fr); font-size: 12px; }
   .return-cart-page .form-sh > .btn { grid-template-columns: minmax(0,1.5fr) repeat(3,minmax(62px,.7fr)); font-size: 11px; }
   .return-cart-page .return-cart-actions { grid-template-columns: 1fr; gap: 7px; }
   .return-cart-page .return-cart-actions .btn { min-height: 50px; padding: 9px 10px; }
   .customer-invoice-history-page .invoice-history-content > div:not(.invoice-filter-panel) > .form-sh { flex-wrap: wrap; }
   .customer-invoice-history-page .invoice-history-content > div:not(.invoice-filter-panel) .btn:last-child:not(:only-child) { flex-basis: 100%; }
   .accounting-workflow-page .ledger-page > .form-sh form { grid-template-columns: 1fr; padding: 10px 6px; }
   .accounting-workflow-page .ledger-page > .form-sh > a { width: 100%; margin: 4px 0; }
   .accounting-workflow-page .ledger-page .ledger-row,
   .accounting-workflow-page .ledger-page .form-sh > .btn { grid-template-columns: minmax(0,1.3fr) minmax(75px,.7fr) minmax(80px,.8fr); font-size: 12px; }
   .accounting-workflow-page .payment-page > form > .form-sh { grid-template-columns: 1fr; padding: 11px 6px; }
   .accounting-workflow-page .payment-page > form input[type="submit"] { grid-column: auto; }
   .accounting-workflow-page .payment-page .form-sh > .btn:not(a) { grid-template-columns: minmax(0,1.3fr) minmax(72px,.7fr) minmax(82px,.8fr); font-size: 12px; }
}
