/* =========================================================
   TiraMaison — Styles de pages
   ========================================================= */

/* =========================================================
   ACCUEIL — Hero (reproduction maquette)
   ========================================================= */
.tm-hero {
  position: relative;
  isolation: isolate;
  background: #0a0a0a;
  color: var(--tm-white);
  min-height: 403px;
  display: flex;
  align-items: center;
  overflow: hidden;
}
.tm-hero__bg { position: absolute; inset: 0; z-index: -2; }
.tm-hero__bg img {
  width: 100%; height: 100%;
  object-fit: cover;
  object-position: 72% center;
}
.tm-hero__bg::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, #0b0b0b 0%, rgba(11, 11, 11, 0.94) 24%, rgba(11, 11, 11, 0.55) 42%, rgba(11, 11, 11, 0) 58%);
}
.tm-hero__inner { position: relative; z-index: 1; padding-block: 43px 20px; }
.tm-hero__copy { max-width: 620px; display: grid; gap: 0; }
.tm-hero h1 {
  font-family: var(--tm-font-display);
  font-weight: 800;
  font-size: var(--tm-fs-h1);
  line-height: 0.92;
  letter-spacing: -0.065em;
  margin-top: 7px;
}
.tm-hero h1 em { font-style: normal; color: var(--tm-yellow); display: block; }
.tm-hero__lead {
  margin-top: 14px;
  font-size: clamp(17px, 1.48vw, 19px);
  line-height: 1.3;
  font-weight: 500;
  color: #f1efeb;
}
.tm-hero__price {
  margin-top: 15px;
  font-size: clamp(20px, 1.72vw, 22px);
  line-height: 1.2;
  font-weight: 500;
  letter-spacing: -0.01em;
}
.tm-hero__price b { font-weight: 700; }
.tm-hero__actions { margin-top: 19px; display: grid; justify-items: start; gap: 13px; }
.tm-hero__actions .tm-link { color: #fff; }

.tm-hero__script {
  position: absolute;
  z-index: 2;
  top: 15%;
  left: 79%;
  width: 200px;
  transform: rotate(-6deg);
  font-family: var(--tm-font-hand);
  font-size: 30px;
  line-height: 1.15;
  font-weight: 600;
  color: var(--tm-ink);
  text-align: center;
  pointer-events: none;
}

@media (max-width: 1180px) {
  .tm-hero__script { left: 74%; font-size: 26px; width: 170px; }
}

/* Hero mobile — référence maquette (visuel sous le texte) */
@media (max-width: 900px) {
  .tm-hero {
    display: block;
    min-height: 0;
    background: #0a0a0a;
  }
  .tm-hero__bg { position: absolute; inset: 0; }
  .tm-hero__bg img { object-position: center 68%; }
  .tm-hero__bg::after {
    background: linear-gradient(180deg, #0b0b0b 0%, rgba(11, 11, 11, 0.93) 27%, rgba(11, 11, 11, 0.30) 40%, rgba(11, 11, 11, 0.04) 58%, rgba(11, 11, 11, 0.62) 100%);
  }
  .tm-hero__inner { padding-block: 31px 24px; }
  .tm-hero__copy { max-width: none; }
  .tm-hero__lead { max-width: 24ch; }
  .tm-hero__spacer { height: 331px; }
  .tm-hero__actions { justify-items: stretch; text-align: center; gap: 14px; }
  .tm-hero__actions .tm-btn { width: 100%; }
  .tm-hero__actions .tm-link { justify-self: center; }
  .tm-hero__script {
    top: auto;
    bottom: 44%;
    left: auto;
    right: 7%;
    width: 112px;
    font-size: 18px;
    transform: rotate(-8deg);
  }
}
@media (max-width: 560px) {
  .tm-hero__spacer { height: 270px; }
}

/* =========================================================
   ACCUEIL — Section « Derrière TiraMaison »
   ========================================================= */
.tm-split3 {
  display: grid;
  grid-template-columns: 31.7% 26.7% 41.6%;
  align-items: stretch;
  min-height: 175px;
}
.tm-split3__media { position: relative; overflow: hidden; background: #17130f; }
.tm-split3__media img { width: 100%; height: 100%; object-fit: cover; }
.tm-split3__panel {
  background: var(--tm-cream);
  padding: 26px clamp(20px, 2.7vw, 40px);
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 12px;
}
.tm-split3__panel h2 {
  font-size: clamp(21px, 2.03vw, 26px);
  font-weight: 800;
  letter-spacing: -0.03em;
  line-height: 1.18;
}
.tm-split3__panel--soft { background: var(--tm-yellow-soft); }
.tm-social-line {
  display: flex; align-items: center; gap: 12px;
  font-size: 15px; color: var(--tm-muted);
}
.tm-social-line svg { width: 19px; height: 19px; color: var(--tm-ink); }
.tm-split3__shop {
  display: flex;
  align-items: center;
  gap: clamp(18px, 2.4vw, 34px);
}
.tm-split3__shop > svg { width: 58px; height: 58px; flex: none; stroke-width: 1.4; }
.tm-split3__shop h2 { font-size: clamp(18px, 1.56vw, 20px); }
.tm-split3__shop p { color: var(--tm-muted); margin: 5px 0 12px; max-width: 36ch; font-size: 15px; }

@media (max-width: 980px) {
  .tm-split3 { grid-template-columns: 1fr; }
  .tm-split3__media { aspect-ratio: 16 / 8; }
  .tm-split3__panel { padding: 26px var(--tm-gutter); }
  .tm-split3__shop { flex-direction: column; align-items: flex-start; gap: 14px; }
  .tm-split3__shop > svg { width: 52px; height: 52px; }
}

/* =========================================================
   Bannière de page interne
   ========================================================= */
.tm-pagehead {
  background: var(--tm-ink);
  color: var(--tm-white);
  padding-block: clamp(34px, 4vw, 56px);
}
.tm-pagehead h1 {
  font-family: var(--tm-font-display);
  font-weight: 800;
  font-size: clamp(34px, 3.75vw, 54px);
  line-height: 1;
  letter-spacing: -0.005em;
  max-width: 20ch;
}
.tm-pagehead h1 em { font-style: normal; color: var(--tm-yellow); }
.tm-pagehead p {
  margin-top: 14px;
  color: #ddd9d2;
  font-size: clamp(16px, 1.25vw, 18px);
  max-width: 62ch;
}
.tm-pagehead .tm-crumbs { color: var(--tm-muted-dark); padding-block: 0 14px; }
.tm-pagehead .tm-crumbs a:hover { color: var(--tm-yellow); }
.tm-pagehead .tm-crumbs [aria-current] { color: #fff; }

/* =========================================================
   CATALOGUE
   ========================================================= */
.tm-catalog__bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  flex-wrap: wrap;
  margin-bottom: 22px;
}
.tm-chips { display: flex; gap: 9px; flex-wrap: wrap; }
.tm-chip {
  padding: 9px 16px;
  border-radius: var(--tm-r-pill);
  border: 1px solid var(--tm-line-strong);
  background: var(--tm-white);
  font-size: 14.5px;
  font-weight: 600;
  cursor: pointer;
  transition: background var(--tm-t), border-color var(--tm-t), color var(--tm-t);
}
.tm-chip:hover { border-color: var(--tm-ink); }
.tm-chip[aria-pressed="true"] { background: var(--tm-ink); border-color: var(--tm-ink); color: var(--tm-white); }
/* Filtres du catalogue : cible tactile confortable sur téléphone. */
@media (max-width: 760px) {
  /* En `inline-flex`, l'espace du gabarit entre le nom et le compteur est
     supprimé : c'est `gap` qui doit le rétablir. */
  button.tm-chip { min-height: 44px; display: inline-flex; align-items: center; gap: 6px; }
}

/* =========================================================
   FICHE PRODUIT
   ========================================================= */
.tm-pdp {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr);
  gap: clamp(28px, 3.4vw, 56px);
  align-items: start;
}
.tm-gallery { display: grid; gap: 12px; }
.tm-gallery__main {
  aspect-ratio: 4 / 3;
  border-radius: var(--tm-r-lg);
  overflow: hidden;
  background: #f4efe7;
  border: 1px solid var(--tm-line);
}
.tm-gallery__main img { width: 100%; height: 100%; object-fit: cover; }
.tm-gallery__thumbs { display: flex; gap: 10px; flex-wrap: wrap; }
.tm-gallery__thumb {
  width: 88px;
  aspect-ratio: 1;
  border-radius: var(--tm-r-sm);
  overflow: hidden;
  border: 2px solid var(--tm-line);
  cursor: pointer;
  background: #f4efe7;
  padding: 0;
}
.tm-gallery__thumb img { width: 100%; height: 100%; object-fit: cover; }
.tm-gallery__thumb[aria-current="true"] { border-color: var(--tm-ink); }

.tm-pdp__info { display: grid; gap: 16px; }
.tm-pdp__title {
  font-family: var(--tm-font-display);
  font-weight: 800;
  font-size: clamp(34px, 3.3vw, 48px);
  line-height: 1;
}
.tm-pdp__price {
  display: flex; align-items: baseline; gap: 12px;
  font-size: 30px; font-weight: 800; letter-spacing: -0.03em;
}
.tm-pdp__price span { font-size: 16px; font-weight: 500; color: var(--tm-muted); }
.tm-pdp__buy { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.tm-pdp__buy .tm-btn { flex: 1; min-width: 220px; }
.tm-specs { display: grid; gap: 0; border-top: 1px solid var(--tm-line); }
.tm-specs div {
  display: flex; justify-content: space-between; gap: 20px;
  padding: 12px 2px;
  border-bottom: 1px solid var(--tm-line);
  font-size: 14.5px;
}
.tm-specs dt { color: var(--tm-muted); }
.tm-specs dd { font-weight: 600; text-align: right; }

@media (max-width: 900px) {
  .tm-pdp { grid-template-columns: minmax(0, 1fr); }
}

/* =========================================================
   PANIER / COMMANDE
   ========================================================= */
.tm-checkout {
  display: grid;
  grid-template-columns: minmax(0, 1.55fr) minmax(0, 1fr);
  gap: clamp(24px, 2.8vw, 40px);
  align-items: start;
}
.tm-summary { position: sticky; top: calc(var(--tm-header-h) + 20px); }
.tm-summary__rows { display: grid; gap: 11px; font-size: 15px; }
.tm-summary__row { display: flex; justify-content: space-between; gap: 16px; }
.tm-summary__row span:last-child { font-variant-numeric: tabular-nums; font-weight: 600; }
.tm-summary__row--muted { color: var(--tm-muted); }
.tm-summary__row--free span:last-child { color: var(--tm-success); }
.tm-summary__total {
  display: flex; justify-content: space-between; gap: 16px;
  padding-top: 14px; margin-top: 14px;
  border-top: 1px solid var(--tm-line);
  font-size: 20px; font-weight: 800; letter-spacing: -0.02em;
}

.tm-lines { display: grid; gap: 14px; }
.tm-line {
  display: grid;
  grid-template-columns: 108px minmax(0, 1fr) auto;
  gap: 16px;
  align-items: center;
  padding: 14px;
  background: var(--tm-white);
  border: 1px solid var(--tm-line);
  border-radius: var(--tm-r);
}
.tm-line__media {
  aspect-ratio: 16 / 11;
  border-radius: var(--tm-r-sm);
  overflow: hidden;
  background: #f4efe7;
}
.tm-line__media img { width: 100%; height: 100%; object-fit: cover; }
.tm-line__name { font-size: 17px; font-weight: 800; letter-spacing: -0.02em; }
.tm-line__meta { font-size: 14px; color: var(--tm-muted); margin-top: 2px; }
.tm-line__ctrl { display: flex; align-items: center; gap: 14px; }
.tm-line__price { font-weight: 800; font-variant-numeric: tabular-nums; min-width: 74px; text-align: right; }
.tm-line__del {
  width: 38px; height: 38px;
  display: grid; place-items: center;
  border-radius: var(--tm-r-sm);
  color: var(--tm-muted);
  cursor: pointer;
  transition: background var(--tm-t), color var(--tm-t);
}
.tm-line__del:hover { background: var(--tm-danger-bg); color: var(--tm-danger); }
.tm-line__del svg { width: 19px; height: 19px; }
/* Cible tactile confortable au pouce sur téléphone. */
@media (max-width: 760px) {
  .tm-line__del { width: 44px; height: 44px; }
}

.tm-steps-nav { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 26px; }
.tm-steps-nav li {
  display: flex; align-items: center; gap: 9px;
  font-size: 14px; font-weight: 600; color: var(--tm-muted);
}
.tm-steps-nav li b {
  width: 26px; height: 26px;
  display: grid; place-items: center;
  border-radius: 50%;
  background: #eae3d5;
  font-size: 13px;
}
.tm-steps-nav li[aria-current] { color: var(--tm-ink); }
.tm-steps-nav li[aria-current] b { background: var(--tm-yellow); }
.tm-steps-nav li::after { content: "›"; margin-left: 8px; color: var(--tm-line-strong); }
.tm-steps-nav li:last-child::after { content: none; }

@media (max-width: 980px) {
  .tm-checkout { grid-template-columns: minmax(0, 1fr); }
  .tm-summary { position: static; }
}
@media (max-width: 620px) {
  .tm-line { grid-template-columns: 76px minmax(0, 1fr); }
  .tm-line__ctrl { grid-column: 1 / -1; justify-content: space-between; }
}

/* =========================================================
   LIVRAISON / POINTS DE VENTE
   ========================================================= */
.tm-grid-2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: clamp(16px, 2vw, 26px); }
.tm-grid-3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: clamp(16px, 2vw, 26px); }
.tm-grid-4 { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: clamp(14px, 1.6vw, 20px); }

.tm-city { margin-bottom: 34px; }
.tm-city__head {
  display: flex; align-items: baseline; gap: 12px;
  padding-bottom: 12px; margin-bottom: 18px;
  border-bottom: 2px solid var(--tm-ink);
}
.tm-city__head h2 { font-size: 26px; letter-spacing: -0.03em; font-weight: 800; }
.tm-city__head span { font-size: 14px; color: var(--tm-muted); }

/* ---- Fiches des points de vente ---- */
.tm-store { display: grid; padding: 0; overflow: hidden; align-content: start; }
.tm-store h3 { font-size: 18px; letter-spacing: -0.02em; }
.tm-store address { font-style: normal; font-size: 14.5px; color: var(--tm-muted); line-height: 1.5; }

.tm-store__photo {
  aspect-ratio: 4 / 3;
  background: var(--tm-cream-2);
  display: grid; place-items: center;
  border-bottom: 1px solid var(--tm-line);
}
.tm-store__photo img { width: 100%; height: 100%; object-fit: cover; display: block; }
/* Sans photo : emplacement neutre — jamais le visuel d'un autre commerce. */
.tm-store__photo-empty svg { width: 42px; height: 42px; color: var(--tm-line-strong); }

.tm-store__body { padding: 18px; display: grid; gap: 8px; min-width: 0; }
.tm-store__head { display: flex; gap: 10px; align-items: flex-start; flex-wrap: wrap; }
.tm-store__head h3 { flex: 1; min-width: 0; }
.tm-store__type { font-size: 12.5px; color: var(--tm-muted-2); text-transform: uppercase; letter-spacing: .05em; font-weight: 700; }
.tm-store__desc { font-size: 14px; color: var(--tm-ink-600); line-height: 1.5; }
.tm-store__today { font-size: 14px; line-height: 1.5; }
.tm-store__today em { color: var(--tm-muted); font-style: normal; }
.tm-store__next { font-size: 13px; color: var(--tm-muted); }

.tm-store__week summary { font-size: 14px; font-weight: 700; cursor: pointer; min-height: 44px; display: flex; align-items: center; }
.tm-store__week ul { display: grid; gap: 4px; padding-bottom: 6px; }
.tm-store__week li { display: flex; justify-content: space-between; gap: 12px; font-size: 13.5px; }
.tm-store__week li span { color: var(--tm-muted); }
.tm-store__week li.is-today { font-weight: 700; }
.tm-store__week li.is-today span { color: var(--tm-text); }
.tm-store__exceptions-title { font-size: 12.5px; font-weight: 800; margin-top: 8px; }

.tm-store__links { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 4px; }
.tm-store__links .tm-btn { flex: 1 1 auto; min-width: 130px; justify-content: center; }
.tm-store__links svg { width: 16px; height: 16px; }

.tm-badge--open { background: var(--tm-success-bg); color: var(--tm-success); }
.tm-badge--closed { background: var(--tm-danger-bg); color: var(--tm-danger); }
.tm-badge--muted { background: var(--tm-cream-2); color: var(--tm-muted); }

.tm-store-filters { display: grid; gap: 12px; margin-bottom: 18px; }
.tm-field--search { position: relative; }
.tm-field--search svg { position: absolute; left: 14px; top: 50%; transform: translateY(-50%); width: 18px; height: 18px; color: var(--tm-muted); pointer-events: none; }
.tm-field--search input {
  width: 100%; min-height: 48px; padding: 0 14px 0 42px;
  font: inherit; font-size: 16px;
  border: 1px solid var(--tm-line-strong); border-radius: var(--tm-r);
  background: var(--tm-white); color: var(--tm-text);
}
.tm-field--search input:focus { outline: none; border-color: var(--tm-ink); box-shadow: var(--tm-ring); }
.tm-chip.is-on { background: var(--tm-ink); border-color: var(--tm-ink); color: var(--tm-white); }
.tm-chip.is-on span { color: var(--tm-yellow); }
.tm-store-count { font-size: 14px; color: var(--tm-muted); margin-bottom: 14px; }
.tm-stores { align-items: start; }
.tm-store-note {
  display: flex; gap: 10px; align-items: flex-start;
  margin-top: 22px; font-size: 13.5px; color: var(--tm-muted); line-height: 1.5;
}
.tm-store-note svg { width: 18px; height: 18px; flex: none; margin-top: 2px; }
.tm-store-pro { margin-top: 26px; display: flex; gap: 18px; align-items: center; flex-wrap: wrap; }
.tm-store-pro > svg { width: 34px; height: 34px; flex: none; }
.tm-store-pro > div { flex: 1; min-width: 240px; }
.tm-store-pro h3 { font-size: 18px; }
.tm-store-pro p { color: var(--tm-muted); font-size: 15px; margin-top: 4px; }
.tm-loading { padding: 40px 0; text-align: center; color: var(--tm-muted); font-size: 15px; }
.tm-empty-inline { padding: 26px 0; color: var(--tm-muted); font-size: 15px; }
.tm-linkbtn { text-decoration: underline; text-underline-offset: 3px; font-weight: 700; cursor: pointer; color: inherit; }

.tm-zones { display: grid; gap: 10px; }
.tm-zone {
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  padding: 14px 18px;
  background: var(--tm-white);
  border: 1px solid var(--tm-line);
  border-radius: var(--tm-r-sm);
  font-size: 15px;
}
.tm-zone b { font-variant-numeric: tabular-nums; }

/* =========================================================
   NOTRE HISTOIRE / CONTENU ÉDITORIAL
   ========================================================= */
.tm-prose { max-width: 72ch; }
.tm-prose > * + * { margin-top: 16px; }
.tm-prose h2 { font-size: clamp(24px, 2.2vw, 30px); letter-spacing: -0.03em; margin-top: 38px; font-weight: 800; }
.tm-prose h3 { font-size: 19px; margin-top: 28px; }
.tm-prose p, .tm-prose li { color: #3c3934; line-height: 1.68; }
.tm-prose ul, .tm-prose ol { padding-left: 22px; display: grid; gap: 8px; }
.tm-prose ul { list-style: disc; }
.tm-prose ol { list-style: decimal; }
.tm-prose a { text-decoration: underline; text-underline-offset: 3px; font-weight: 600; }
.tm-prose blockquote {
  border-left: 4px solid var(--tm-yellow);
  padding: 6px 0 6px 20px;
  font-size: 19px;
  font-weight: 600;
  letter-spacing: -0.01em;
}

.tm-story-hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 0.9fr);
  gap: clamp(24px, 3vw, 48px);
  align-items: center;
}
.tm-story-hero img { border-radius: var(--tm-r-lg); width: 100%; }
.tm-signature {
  font-family: var(--tm-font-hand);
  font-size: 34px;
  color: var(--tm-ink);
  transform: rotate(-3deg);
  display: inline-block;
}

@media (max-width: 900px) {
  .tm-grid-3, .tm-grid-4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .tm-story-hero { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 600px) {
  .tm-grid-2, .tm-grid-3, .tm-grid-4 { grid-template-columns: minmax(0, 1fr); }
}

/* =========================================================
   AVIS
   ========================================================= */
.tm-review { display: grid; gap: 10px; padding: 22px; }
.tm-stars { display: flex; gap: 2px; color: var(--tm-yellow); }
.tm-stars svg { width: 17px; height: 17px; }
.tm-review__author { font-size: 14px; color: var(--tm-muted); }
.tm-review__author b { color: var(--tm-ink); }

/* =========================================================
   PROS
   ========================================================= */
.tm-pro-perk { display: grid; gap: 10px; padding: 24px; }
.tm-pro-perk svg { width: 34px; height: 34px; color: var(--tm-ink); }
.tm-pro-perk b { font-size: 26px; letter-spacing: -0.03em; display: block; }
.tm-pro-perk h3 { font-size: 18px; }
.tm-pro-perk p { font-size: 14.5px; color: var(--tm-muted); }

/* =========================================================
   CONNEXION
   ========================================================= */
.tm-auth {
  min-height: calc(100vh - var(--tm-topbar-h) - var(--tm-header-h));
  display: grid;
  place-items: center;
  /* Les zones sûres de l'iPhone s'AJOUTENT aux espacements de la maquette :
     la carte ne passe ni sous la Dynamic Island ni sous la barre d'accueil. */
  padding:
    calc(clamp(32px, 5vw, 72px) + env(safe-area-inset-top, 0px))
    calc(var(--tm-gutter) + env(safe-area-inset-right, 0px))
    calc(clamp(32px, 5vw, 72px) + env(safe-area-inset-bottom, 0px))
    calc(var(--tm-gutter) + env(safe-area-inset-left, 0px));
  background:
    radial-gradient(1000px 380px at 50% -10%, rgba(254, 217, 46, 0.16), transparent 65%),
    var(--tm-ink);
}
.tm-auth__card {
  width: min(100%, 440px);
  background: var(--tm-white);
  border-radius: var(--tm-r-lg);
  padding: clamp(26px, 3vw, 38px);
  box-shadow: var(--tm-shadow-lg);
  display: grid;
  gap: 18px;
}
.tm-auth__card h1 { font-size: 26px; letter-spacing: -0.03em; }
.tm-auth__logo { justify-self: center; height: 58px; width: auto; margin-bottom: 4px; }
.tm-auth__foot { text-align: center; font-size: 14px; color: var(--tm-muted); }
.tm-auth__foot a { text-decoration: underline; text-underline-offset: 3px; font-weight: 600; color: var(--tm-ink); }

/* Panier vide : la colonne récapitulatif passe sous la liste */
.tm-checkout.tm-cart-empty { grid-template-columns: minmax(0, 1fr); max-width: 760px; }

/* Section « comment ça marche » : filet supérieur comme sur la maquette */
.tm-steps { border-top: 1px solid var(--tm-line-strong); }

/* =========================================================
   ACCUEIL — rythme vertical serré, calé sur la maquette
   (27 px au-dessus du titre, aucune marge sous les cartes)
   ========================================================= */
.tm-section--home { padding-block: 20px 0; }
/* Le titre display a un interlignage < 1 : on compense le blanc de la boîte
   de ligne pour retrouver les 27 px titre → cartes de la maquette. */
.tm-section--home .tm-section__head { margin-bottom: -5px; }

@media (max-width: 900px) {
  .tm-section--home { padding-block: 22px 0; }
  .tm-section--home .tm-section__head { margin-bottom: 14px; }
}

/* =========================================================
   ACCUEIL — Premier écran : le best-seller, achetable
   ---------------------------------------------------------
   Sur téléphone, tout ce qui décide de l'achat tient au-dessus
   de la ligne de flottaison : visuel, nom, badge, prix, format,
   bouton d'ajout et repère de livraison.
   ========================================================= */
.tm-star {
  background: var(--tm-ink);
  color: var(--tm-on-dark);
  padding-block: clamp(20px, 2.6vw, 40px) clamp(26px, 3vw, 46px);
}
.tm-star__inner {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr);
  gap: clamp(24px, 3.4vw, 52px);
  align-items: center;
}

.tm-star__media {
  position: relative;
  border-radius: var(--tm-r-lg);
  overflow: hidden;
  background: #241d17;
  aspect-ratio: 16 / 10;
}
.tm-star__media img { width: 100%; height: 100%; object-fit: cover; display: block; }
.tm-star__badge {
  position: absolute;
  top: 12px; left: 12px;
  z-index: 2;
  max-width: calc(100% - 24px);
}
.tm-star__script {
  position: absolute;
  right: 12px; bottom: 8px;
  z-index: 2;
  font-family: var(--tm-font-hand);
  font-size: clamp(22px, 2.1vw, 30px);
  line-height: 1.05;
  color: var(--tm-yellow);
  text-align: right;
  text-shadow: 0 2px 12px rgba(0, 0, 0, 0.55);
  pointer-events: none;
}

/*
 * Accroche et bouton du premier écran en capitales : c'est la formulation
 * validée. Le style italique de la maquette est conservé, et les autres
 * `.tm-eyebrow` du site ne sont pas touchés.
 */
.tm-star__copy .tm-eyebrow {
  color: var(--tm-yellow);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  font-size: clamp(13px, 1.15vw, 15px);
}
.tm-star__cta {
  text-transform: uppercase;
  letter-spacing: 0.03em;
}
.tm-star h1 {
  font-family: var(--tm-font-display);
  font-weight: 900;
  font-size: clamp(32px, 4.2vw, 58px);
  line-height: 0.98;
  letter-spacing: -0.025em;
  margin-top: 6px;
}
.tm-star h1 em { font-style: normal; color: var(--tm-yellow); }
.tm-star__lead {
  margin-top: 12px;
  color: #d8d3ca;
  font-size: clamp(15px, 1.2vw, 17px);
  line-height: 1.5;
  max-width: 44ch;
}

.tm-star__buy {
  margin-top: 18px;
  display: flex;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
}
/*
 * Premier écran : le prix et le format se lisent d'un trait
 * (« 5,90 € la barquette · 180 g »), au-dessus d'un bouton large.
 * Le bouton conduit à la sélection des parfums ; l'ajout au panier se fait
 * ensuite depuis les cartes.
 */
.tm-star__buy {
  margin-top: 18px;
  display: grid;
  gap: 14px;
  justify-items: start;
}
.tm-star__price {
  font-size: 19px;
  font-weight: 700;
  color: #fff;
  letter-spacing: -0.01em;
}
.tm-star__price span[aria-hidden] { color: #8d887f; margin-inline: 4px; }
.tm-star__cta { justify-content: center; }

.tm-star__out {
  flex: 1 1 100%;
  display: grid;
  gap: 12px;
  justify-items: start;
  font-size: 15px;
  color: #e8e3da;
}
.tm-star__out b { color: var(--tm-yellow); }

.tm-star__links { margin-top: 14px; }
.tm-star__links .tm-link { color: #fff; }
.tm-star__closed { margin-top: 14px; }

.tm-star__ship {
  margin-top: 16px;
  padding-top: 15px;
  border-top: 1px solid var(--tm-line-dark);
  display: flex; align-items: center; gap: 10px;
  font-size: 14.5px;
  color: #cfcac1;
}
.tm-star__ship svg { width: 22px; height: 22px; flex: none; color: var(--tm-yellow); }

@media (max-width: 900px) {
  .tm-star { padding-block: 16px 24px; }
  .tm-star__inner { grid-template-columns: 1fr; gap: 18px; }
  /* Le visuel d'abord : c'est lui qui donne envie. */
  .tm-star__media { order: -1; aspect-ratio: 16 / 11; }
  .tm-star h1 { font-size: clamp(30px, 8.6vw, 42px); }
  .tm-star__lead { margin-top: 9px; font-size: 15px; max-width: none; }
  .tm-star__buy { margin-top: 15px; gap: 12px; justify-items: stretch; }
  .tm-star__cta { width: 100%; }
  .tm-star__ship { margin-top: 13px; padding-top: 12px; }
}
@media (max-width: 400px) {
  .tm-star__media { aspect-ratio: 16 / 12; }
  .tm-star__lead { font-size: 14.5px; }
}

/* =========================================================
   ACCUEIL — Les trois textures
   ========================================================= */
.tm-layers { background: var(--tm-white); padding-block: var(--tm-section-y); }
.tm-layers__inner {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr);
  gap: clamp(26px, 3.6vw, 56px);
  align-items: center;
}
.tm-layers h2 {
  font-family: var(--tm-font-display);
  font-weight: 800;
  font-size: var(--tm-fs-h2);
  letter-spacing: -0.02em;
  line-height: 1.05;
  margin-top: 6px;
}
.tm-layers__list {
  margin-top: 20px;
  display: grid;
  gap: 16px;
  counter-reset: layer;
  list-style: none;
}
.tm-layers__list li {
  position: relative;
  padding-left: 40px;
  font-size: 15.5px;
  line-height: 1.55;
  color: var(--tm-muted);
}
.tm-layers__list li::before {
  counter-increment: layer;
  content: counter(layer);
  position: absolute;
  left: 0; top: 1px;
  width: 27px; height: 27px;
  display: grid; place-items: center;
  border-radius: 50%;
  background: var(--tm-yellow);
  color: var(--tm-ink);
  font-weight: 800;
  font-size: 14px;
}
.tm-layers__list b { display: block; color: var(--tm-ink); font-size: 16.5px; letter-spacing: -0.01em; }
.tm-layers__note {
  margin-top: 20px;
  font-size: 14px;
  color: var(--tm-muted-2);
  padding-top: 15px;
  border-top: 1px solid var(--tm-line);
}
.tm-layers__media { border-radius: var(--tm-r-lg); overflow: hidden; aspect-ratio: 16 / 11; }
.tm-layers__media img { width: 100%; height: 100%; object-fit: cover; }

@media (max-width: 900px) {
  .tm-layers__inner { grid-template-columns: 1fr; gap: 22px; }
  .tm-layers__media { order: -1; aspect-ratio: 16 / 9; }
}

/* =========================================================
   ACCUEIL — Packs configurés
   ========================================================= */
.tm-packs .tm-display { margin-bottom: 6px; }
.tm-packs__list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 14px;
  margin: 20px 0 22px;
}
.tm-pack {
  background: var(--tm-white);
  border: 1px solid var(--tm-line);
  border-radius: var(--tm-r);
  padding: 18px 20px;
  box-shadow: var(--tm-shadow-xs);
}
.tm-pack__name { font-weight: 800; font-size: 17px; letter-spacing: -0.02em; }
.tm-pack__deal {
  margin-top: 6px;
  display: inline-block;
  background: var(--tm-yellow);
  border-radius: var(--tm-r-pill);
  padding: 4px 12px;
  font-weight: 700;
  font-size: 14px;
}
.tm-pack__desc { margin-top: 10px; font-size: 14px; color: var(--tm-muted); }

/* =========================================================
   ACCUEIL — Comment commander
   ========================================================= */
.tm-how { background: var(--tm-white); }
.tm-how__steps {
  list-style: none;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
  margin: 22px 0 26px;
}
.tm-how__steps li {
  display: grid;
  gap: 5px;
  align-content: start;
  padding: 20px;
  background: var(--tm-cream);
  border-radius: var(--tm-r);
}
.tm-how__num {
  width: 30px; height: 30px;
  display: grid; place-items: center;
  border-radius: 50%;
  background: var(--tm-ink);
  color: var(--tm-yellow);
  font-weight: 800;
  font-size: 14px;
  margin-bottom: 5px;
}
.tm-how__steps b { font-size: 16.5px; letter-spacing: -0.02em; }
.tm-how__steps span:not(.tm-how__num) { font-size: 14.5px; color: var(--tm-muted); line-height: 1.5; }

.tm-how__zones { border-top: 1px solid var(--tm-line); padding-top: 20px; }
.tm-how__zones-label {
  font-size: 12.5px;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  font-weight: 700;
  color: var(--tm-muted-2);
  margin-bottom: 11px;
}
.tm-how__zones .tm-chip { font-size: 14px; padding: 7px 14px; }
.tm-how__zones .tm-chip span { color: var(--tm-muted-2); font-weight: 600; }
.tm-how__zones-note { margin-top: 13px; font-size: 13.5px; color: var(--tm-muted); }

@media (max-width: 900px) {
  .tm-how__steps { grid-template-columns: 1fr; gap: 10px; }
  .tm-how__steps li { padding: 15px 17px; }
}

/* =========================================================
   ACCUEIL — Elias
   ========================================================= */
.tm-maker {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  background: var(--tm-cream);
}
.tm-maker__media { background: #17130f; }
.tm-maker__media img { width: 100%; height: 100%; object-fit: cover; display: block; }
.tm-maker__panel {
  padding: clamp(28px, 3.4vw, 56px) clamp(24px, 3vw, 56px);
  display: grid;
  align-content: center;
  gap: 14px;
}
.tm-maker__panel h2 {
  font-family: var(--tm-font-display);
  font-weight: 800;
  font-size: var(--tm-fs-h2);
  line-height: 1.02;
  letter-spacing: -0.02em;
}
.tm-maker__panel p { color: var(--tm-muted); font-size: 15.5px; line-height: 1.6; max-width: 52ch; }
.tm-maker__stat {
  background: var(--tm-white);
  border-left: 3px solid var(--tm-yellow);
  border-radius: var(--tm-r-sm);
  padding: 13px 16px;
  font-size: 14.5px !important;
  color: var(--tm-ink) !important;
}
.tm-maker__stat b { font-weight: 800; }

@media (max-width: 900px) {
  .tm-maker { grid-template-columns: 1fr; }
  .tm-maker__media { aspect-ratio: 16 / 9; }
}

/* =========================================================
   ACCUEIL — Points de vente et professionnels
   ========================================================= */
.tm-elsewhere {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
}
.tm-elsewhere__card {
  background: var(--tm-white);
  border: 1px solid var(--tm-line);
  border-radius: var(--tm-r-lg);
  padding: clamp(22px, 2.4vw, 32px);
  display: grid;
  gap: 10px;
  align-content: start;
}
.tm-elsewhere__card--soft { background: var(--tm-yellow-soft); border-color: #f1e4c8; }
.tm-elsewhere__card > svg { width: 42px; height: 42px; }
.tm-elsewhere__card h2 { font-size: var(--tm-fs-h3); letter-spacing: -0.02em; font-weight: 800; }
.tm-elsewhere__card p { color: var(--tm-muted); font-size: 15px; }
.tm-elsewhere__card .tm-btn { justify-self: start; margin-top: 4px; }

@media (max-width: 760px) {
  .tm-elsewhere { grid-template-columns: 1fr; }
}

/* =========================================================
   ACCUEIL — FAQ et avis
   ========================================================= */
.tm-faq-home { background: var(--tm-cream); }
.tm-faq-home .tm-acc { margin-top: 20px; }
.tm-faq-home__more { margin-top: 20px; }

.tm-reviews {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 16px;
  margin: 20px 0;
}
.tm-review {
  background: var(--tm-white);
  border-radius: var(--tm-r);
  padding: 20px;
  border: 1px solid var(--tm-line);
}
.tm-review p { font-size: 15.5px; line-height: 1.55; }
.tm-review footer { margin-top: 12px; font-size: 13.5px; color: var(--tm-muted); font-weight: 600; }

.tm-section__lead { color: var(--tm-muted); font-size: 15.5px; margin-bottom: 4px; max-width: 60ch; }

/* =========================================================
   Références sans photo
   ---------------------------------------------------------
   Une référence peut exister avant son visuel. On affiche un
   cadre neutre aux mêmes proportions : pas d'image cassée, et
   aucun décalage de mise en page quand la photo arrive.
   ========================================================= */
.tm-gallery__main.is-empty {
  display: grid;
  place-items: center;
  background: repeating-linear-gradient(45deg, #f4efe7, #f4efe7 10px, #ece5d8 10px, #ece5d8 20px);
  aspect-ratio: 4 / 3;
}
.tm-gallery__ph {
  display: grid;
  justify-items: center;
  gap: 8px;
  color: var(--tm-muted-2);
  font-size: 14px;
  font-weight: 600;
}
.tm-gallery__ph svg { width: 34px; height: 34px; }

/* Détail sous le résultat du vérificateur de code postal. */
.tm-zip-ok__detail {
  display: block;
  margin-top: 3px;
  font-size: 13.5px;
  font-weight: 600;
  opacity: 0.85;
}
