/* DropshipFR - styles du site
   Palette "courrier par avion" : encre, bleu avion, rouge avion, jaune colis. */

:root {
  --encre: #14213d;
  --bleu: #1f4fd8;
  --bleu-fonce: #173ca6;
  --rouge: #e5383b;
  --jaune: #ffc83d;
  --brume: #eef1f6;
  --texte: #3b455a;
  --trait: #d9deea;
  --blanc: #ffffff;
  --titre: "Bricolage Grotesque", "Segoe UI", system-ui, sans-serif;
  --corps: "Instrument Sans", "Segoe UI", system-ui, sans-serif;
  --rayures: repeating-linear-gradient(135deg, var(--rouge) 0 14px, var(--blanc) 14px 28px, var(--bleu) 28px 42px, var(--blanc) 42px 56px);
}

/* ---------- Base ---------- */
body,
button,
input,
select,
textarea {
  font-family: var(--corps);
  color: var(--texte);
}

body {
  font-size: 17px;
  line-height: 1.6;
  background: var(--blanc);
}

h1, h2, h3, h4, h5, h6,
.site-title,
.woocommerce-loop-product__title {
  font-family: var(--titre);
  color: var(--encre);
  letter-spacing: -0.015em;
}

h1 { font-weight: 700; line-height: 1.05; }
h2 { font-weight: 700; line-height: 1.15; }
h3 { font-weight: 600; line-height: 1.25; }

a { color: var(--bleu); }
a:hover { color: var(--bleu-fonce); }

a:focus-visible,
button:focus-visible,
input:focus-visible,
.button:focus-visible {
  outline: 3px solid var(--jaune);
  outline-offset: 2px;
}

/* ---------- Bandeau du haut ---------- */
.dfr-stripe {
  height: 8px;
  background: var(--rayures);
}

.dfr-topbar {
  margin: 0;
  padding: 0.45em 1em;
  background: var(--encre);
  color: var(--blanc);
  font-size: 0.85rem;
  text-align: center;
}

/* ---------- En-tete ---------- */
.site-header {
  background: var(--blanc);
  border-bottom: 1px solid var(--trait);
  padding-top: 1.4em;
}

.home .site-header {
  margin-bottom: 0;
}

.site-header .site-branding .site-title {
  font-size: 1.9rem;
  font-weight: 800;
  letter-spacing: -0.03em;
  line-height: 1;
}

.site-header .site-branding .site-title a {
  color: var(--encre);
  text-decoration: none;
}

.site-header .site-branding .site-title a::after {
  content: "";
  display: inline-block;
  width: 0.34em;
  height: 0.34em;
  margin-left: 0.12em;
  border-radius: 50%;
  background: var(--rouge);
}

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

.site-header .site-search .widget_product_search form::before {
  color: var(--encre);
}

.site-header .site-search .widget_product_search input[type="search"] {
  background: var(--brume);
  border: 1px solid transparent;
  border-radius: 999px;
  box-shadow: none;
  color: var(--encre);
}

.site-header .site-search .widget_product_search input[type="search"]:focus {
  border-color: var(--bleu);
  background: var(--blanc);
}

.main-navigation ul.menu > li > a,
.main-navigation ul.nav-menu > li > a {
  color: var(--encre);
  font-weight: 600;
  font-size: 0.98rem;
  text-decoration: none;
}

.main-navigation ul.menu > li > a:hover,
.main-navigation ul.menu > li.current-menu-item > a {
  color: var(--bleu);
}

.secondary-navigation .menu a {
  color: var(--texte);
  font-size: 0.88rem;
}

.site-header-cart .cart-contents {
  color: var(--encre);
  font-weight: 600;
}

button.menu-toggle {
  border-color: var(--encre);
  color: var(--encre);
  border-radius: 999px;
}

button.menu-toggle::before,
button.menu-toggle::after,
button.menu-toggle span::before {
  background-color: var(--encre);
}

/* ---------- Boutons ---------- */
.button,
button,
input[type="button"],
input[type="reset"],
input[type="submit"],
.added_to_cart,
.wc-block-components-button,
.dfr-btn {
  border-radius: 999px;
  font-family: var(--corps);
  font-weight: 600;
  text-decoration: none;
}

.dfr-btn {
  display: inline-block;
  padding: 0.85em 1.7em;
  background: var(--encre);
  color: var(--blanc);
}

.dfr-btn:hover {
  background: var(--bleu);
  color: var(--blanc);
}

.dfr-link {
  font-weight: 600;
  text-underline-offset: 0.2em;
}

/* ---------- Accueil ---------- */
.home .site-content > .col-full {
  max-width: none;
  padding: 0;
  margin: 0;
}

.dfr-wrap {
  max-width: 1180px;
  margin: 0 auto;
  padding: 0 24px;
}

.dfr-hero {
  background: var(--brume);
  padding: 72px 0 84px;
}

.dfr-hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(0, 0.85fr);
  gap: 56px;
  align-items: center;
}

.dfr-hero h1 {
  margin: 0 0 0.45em;
  font-size: clamp(2.3rem, 5.2vw, 4.1rem);
  font-weight: 800;
  letter-spacing: -0.035em;
  text-wrap: balance;
}

.dfr-hero-text > p {
  max-width: 34em;
  margin: 0 0 1.6em;
  font-size: 1.15rem;
}

.dfr-hero-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 16px 28px;
}

/* L'etiquette de colis : l'element signature de la page. */
.dfr-label {
  padding: 12px;
  background: var(--rayures);
  border-radius: 6px;
  transform: rotate(2deg);
  box-shadow: 0 22px 40px -18px rgba(20, 33, 61, 0.45);
}

.dfr-label-inner {
  padding: 26px 28px 22px;
  background: var(--blanc);
  border-radius: 2px;
}

.dfr-label-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  padding-bottom: 16px;
  border-bottom: 2px solid var(--encre);
}

.dfr-label-brand {
  font-family: var(--titre);
  font-size: 1.35rem;
  font-weight: 800;
  letter-spacing: -0.03em;
  color: var(--encre);
}

.dfr-label-stamp {
  padding: 0.2em 0.7em;
  border: 2px solid var(--bleu);
  border-radius: 4px;
  color: var(--bleu);
  font-family: var(--titre);
  font-size: 0.85rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  transform: rotate(-4deg);
}

.dfr-label dl {
  margin: 0;
}

.dfr-label dl > div {
  display: grid;
  grid-template-columns: 7.2em 1fr;
  gap: 12px;
  padding: 12px 0;
  border-bottom: 1px dashed var(--trait);
}

.dfr-label dt {
  font-size: 0.85rem;
  font-weight: 400;
  color: var(--texte);
}

.dfr-label dd {
  margin: 0;
  font-family: var(--titre);
  font-weight: 600;
  color: var(--encre);
  line-height: 1.3;
}

.dfr-label-code {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 16px;
  padding-top: 18px;
}

.dfr-barcode {
  flex: 1;
  height: 44px;
  max-width: 220px;
  background: repeating-linear-gradient(90deg,
    var(--encre) 0 2px, transparent 2px 5px,
    var(--encre) 5px 6px, transparent 6px 8px,
    var(--encre) 8px 12px, transparent 12px 14px,
    var(--encre) 14px 15px, transparent 15px 19px);
}

.dfr-label-num {
  font-size: 0.8rem;
  letter-spacing: 0.06em;
  color: var(--texte);
}

/* Sections */
.dfr-section {
  padding: 72px 0;
}

.dfr-section-tint {
  background: var(--brume);
}

.dfr-section h2 {
  margin: 0 0 1em;
  font-size: clamp(1.6rem, 3vw, 2.2rem);
  letter-spacing: -0.025em;
}

.dfr-cats {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.dfr-cats a {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  min-height: 150px;
  padding: 22px 24px;
  border: 2px solid var(--encre);
  border-radius: 6px;
  background: var(--blanc);
  color: var(--encre);
  text-decoration: none;
  transition: background-color 0.15s, color 0.15s;
}

.dfr-cats li:nth-child(3n + 1) a { border-left: 10px solid var(--bleu); }
.dfr-cats li:nth-child(3n + 2) a { border-left: 10px solid var(--rouge); }
.dfr-cats li:nth-child(3n + 3) a { border-left: 10px solid var(--jaune); }

.dfr-cats a:hover {
  background: var(--encre);
  color: var(--blanc);
}

.dfr-cat-name {
  font-family: var(--titre);
  font-size: 1.45rem;
  font-weight: 700;
  line-height: 1.15;
  letter-spacing: -0.02em;
}

.dfr-cat-count {
  font-size: 0.9rem;
  opacity: 0.75;
}

.dfr-empty {
  max-width: 36em;
  margin: 0;
  padding: 28px 30px;
  border: 2px dashed var(--encre);
  border-radius: 6px;
  background: var(--blanc);
  color: var(--encre);
  font-size: 1.05rem;
}

.dfr-promises {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 32px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.dfr-promises li {
  padding-top: 18px;
  border-top: 3px solid var(--encre);
}

.dfr-promises h3 {
  margin: 0 0 0.4em;
  font-size: 1.15rem;
}

.dfr-promises p {
  margin: 0;
  font-size: 0.97rem;
}

/* ---------- Boutique et fiches produit ---------- */
.storefront-breadcrumb {
  background: var(--brume);
  font-size: 0.88rem;
}

ul.products li.product {
  text-align: left;
}

ul.products li.product img {
  border-radius: 6px;
  background: var(--brume);
}

ul.products li.product .woocommerce-loop-product__title {
  font-size: 1.02rem;
  font-weight: 600;
  line-height: 1.3;
  letter-spacing: -0.01em;
}

ul.products li.product .price,
.single-product div.product p.price {
  color: var(--encre);
  font-family: var(--titre);
  font-weight: 700;
}

ul.products li.product .price del,
.single-product div.product p.price del {
  color: var(--texte);
  font-weight: 400;
  opacity: 0.7;
}

ul.products li.product .price ins,
.single-product div.product p.price ins {
  color: var(--rouge);
}

.onsale {
  border: 0;
  border-radius: 4px;
  background: var(--jaune);
  color: var(--encre);
  font-weight: 700;
  text-transform: none;
}

.single-product div.product .product_title {
  font-size: clamp(1.7rem, 3vw, 2.4rem);
  letter-spacing: -0.025em;
}

.woocommerce-tabs ul.tabs li a {
  font-family: var(--titre);
  font-weight: 600;
}

.woocommerce-message,
.woocommerce-info,
.woocommerce-error,
.woocommerce-noreviews,
p.no-comments {
  border-radius: 6px;
}

/* ---------- Pages de contenu ---------- */
.page:not(.home) .entry-header .entry-title {
  font-size: clamp(2rem, 4vw, 2.9rem);
  letter-spacing: -0.03em;
}

.page:not(.home) .entry-content {
  max-width: 44em;
}

.woocommerce-cart .entry-content,
.woocommerce-checkout .entry-content,
.woocommerce-account .entry-content {
  max-width: none;
}

/* ---------- Pied de page ---------- */
.site-footer {
  background: var(--encre);
  color: #c9d2e3;
  padding-top: 0;
  border-top: 8px solid transparent;
  border-image: var(--rayures) 8;
}

.site-footer a:not(.button) {
  color: var(--blanc);
  text-decoration: none;
}

.site-footer a:not(.button):hover {
  text-decoration: underline;
  text-underline-offset: 0.2em;
}

.dfr-footer {
  display: grid;
  grid-template-columns: 1.6fr 1fr 1fr;
  gap: 48px;
  padding: 56px 0 40px;
}

.dfr-footer-name {
  margin: 0 0 0.4em;
  font-family: var(--titre);
  font-size: 1.7rem;
  font-weight: 800;
  letter-spacing: -0.03em;
  color: var(--blanc);
}

.dfr-footer-brand p:last-child {
  max-width: 26em;
  margin: 0;
}

.dfr-footer-col h2 {
  margin: 0 0 0.8em;
  font-size: 1.05rem;
  color: var(--blanc);
}

.dfr-footer-col ul {
  margin: 0;
  list-style: none;
}

.dfr-footer-col li {
  margin-bottom: 0.45em;
}

.dfr-footer-legal {
  margin: 0;
  padding: 20px 0 28px;
  border-top: 1px solid rgba(255, 255, 255, 0.16);
  font-size: 0.85rem;
}

/* ---------- Mobile ---------- */
@media (max-width: 900px) {
  .dfr-hero { padding: 44px 0 56px; }
  .dfr-hero-grid { grid-template-columns: 1fr; gap: 40px; }
  .dfr-label { max-width: 440px; transform: rotate(1deg); }
  .dfr-section { padding: 52px 0; }
  .dfr-cats { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .dfr-promises { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .dfr-footer { grid-template-columns: 1fr 1fr; gap: 32px; }
  .dfr-footer-brand { grid-column: 1 / -1; }
}

@media (max-width: 520px) {
  .dfr-wrap { padding: 0 16px; }
  .dfr-cats { grid-template-columns: 1fr; }
  .dfr-cats a { min-height: 104px; }
  .dfr-promises { grid-template-columns: 1fr; gap: 24px; }
  .dfr-label-inner { padding: 20px 18px 18px; }
  .dfr-label dl > div { grid-template-columns: 6.4em 1fr; }
  .dfr-footer { grid-template-columns: 1fr; }
}

@media (prefers-reduced-motion: reduce) {
  * { transition: none !important; }
}

/* ---------- Ajustements en-tete ---------- */
.home.page .site-header,
.home .site-header {
  margin-bottom: 0 !important;
}

@media (min-width: 768px) {
  .main-navigation ul.menu > li > a,
  .main-navigation ul.nav-menu > li > a {
    padding: 1.1em 0.62em;
    font-size: 0.95rem;
  }
  .site-header-cart .cart-contents {
    padding: 1.1em 0;
  }
}

/* Le lieu d expedition n est pas un choix pour le client. */
table.variations tr:has(select[name="attribute_ships-from"]) {
  display: none;
}

/* Panier et commande : le lieu d expedition du fournisseur reste masque. */
[class*="product-details__expedie-depuis"],
[class*="product-details__ships-from"] {
  display: none !important;
}

/* Panier et commande : pas de debordement hors de la page. */
.woocommerce-cart .entry-content .alignwide,
.woocommerce-checkout .entry-content .alignwide,
.woocommerce-cart .entry-content .alignfull,
.woocommerce-checkout .entry-content .alignfull {
  margin-left: 0;
  margin-right: 0;
  width: auto;
  max-width: 100%;
}

body.storefront-full-width-content .hentry .entry-content .alignwide,
body.storefront-full-width-content .hentry .entry-content .alignfull {
  margin-left: 0 !important;
  margin-right: 0 !important;
  padding-left: 0 !important;
  padding-right: 0 !important;
  max-width: 100% !important;
}

body.woocommerce-cart.page .entry-content,
body.woocommerce-checkout.page .entry-content,
body.woocommerce-account.page .entry-content {
  max-width: none;
}

/* Accueil : grille des derniers arrivages (le gabarit de Storefront ne la pose que dans .site-main). */
.dfr-home ul.products { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 28px 16px; margin: 0 0 28px; padding: 0; }
.dfr-home ul.products::before, .dfr-home ul.products::after { display: none; }
.dfr-home ul.products li.product { width: auto; float: none; margin: 0; }
@media (min-width: 768px) { .dfr-home ul.products { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 36px 24px; } }
