/* Chrome de la vitrine "site classique" (Story 1.6b) — indépendant d'Oscar, entièrement
   piloté par les variables CSS du thème actif (theme/_theme_injection.html). Ne dépend
   d'aucun framework externe (Bootstrap, etc.) — Oscar garde sa propre feuille de style
   pour le cas "site e-commerce", séparé (voir templates/oscar/layout.html). */

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  background: var(--background-color);
  color: var(--foreground-color);
  font-family: var(--body-font);
  line-height: 1.6;
}

h1, h2, h3 {
  font-family: var(--heading-font);
  line-height: 1.2;
  margin: 0 0 0.5em;
}

a {
  color: var(--primary-color);
}

.site-header {
  border-bottom: 1px solid var(--border-color);
}

.site-header__inner {
  max-width: var(--content-max-width, 72rem);
  margin: 0 auto;
  padding: 1.25rem 1.5rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
  flex-wrap: wrap;
}

/* Header partials contributed by extensions (comptoir.header_actions) — e.g. account, cart. */
.site-header__action {
  display: inline-flex;
  align-items: center;
  color: var(--foreground-color);
  text-decoration: none;
}

.site-header__action:hover,
.site-header__action:focus-visible {
  color: var(--primary-color);
}

.site-header__action svg {
  width: 1.5rem;
  height: 1.5rem;
}

/* Extension icons group together at the header's end (Story 3.6); never shown when empty. */
.site-header__actions {
  display: inline-flex;
  align-items: center;
  gap: 1rem;
}

/* Small count bubble on a header action (e.g. items in a basket). */
.site-header__action--with-badge {
  position: relative;
}

.site-header__badge {
  position: absolute;
  top: -0.4rem;
  right: -0.6rem;
  min-width: 1.1rem;
  padding: 0 0.3rem;
  border-radius: 999px;
  background: var(--primary-color);
  color: var(--background-color);
  font-size: 0.7rem;
  font-weight: 700;
  line-height: 1.1rem;
  text-align: center;
}

.site-nav__list {
  display: flex;
  gap: 1.5rem;
  list-style: none;
  margin: 0;
  padding: 0;
}

.site-nav__item {
  position: relative;
}

.site-nav__item a {
  text-decoration: none;
  color: var(--foreground-color);
  font-weight: 600;
}

.site-nav__item a:hover {
  color: var(--primary-color);
}

/* Revue de code (2026-08-10) : remplace l'ancien survol CSS (:hover/:focus-within), inutilisable
   au tactile — un <a> qui capte le tap navigue avant que quoi que ce soit ne s'affiche. <details>
   natif à la place : taper sur le libellé navigue toujours vers sa page, taper ailleurs dans le
   <summary> (le chevron) déplie/replie — même mécanisme au clic ET au tap, aucun JS. */
.site-nav__dropdown {
  position: relative;
}

.site-nav__dropdown summary {
  display: flex;
  align-items: center;
  gap: 0.35rem;
  cursor: pointer;
  list-style: none;
}

.site-nav__dropdown summary::-webkit-details-marker {
  display: none;
}

.site-nav__caret {
  font-size: 0.7em;
  opacity: 0.6;
  transition: transform 150ms ease;
}

.site-nav__dropdown[open] .site-nav__caret {
  transform: rotate(180deg);
}

.site-nav__submenu {
  position: absolute;
  top: 100%;
  left: 0;
  min-width: 10rem;
  margin: 0;
  padding: 0.5rem 0;
  list-style: none;
  background: var(--background-color);
  border: 1px solid var(--border-color);
  border-radius: 0.375rem;
  z-index: 10;
}

.site-nav__submenu .site-nav__item a {
  display: block;
  padding: 0.4rem 1rem;
  font-weight: 400;
}

.site-footer .site-nav__list {
  flex-wrap: wrap;
}

/* Variantes de design du menu (Navigation.style, choisies par le commerçant) — n'affectent
   que les liens de premier niveau, jamais le sous-menu déplié (.site-nav__submenu garde son
   propre style, plus dense). "classique" (valeur par défaut) n'ajoute aucune règle : c'est le
   rendu ci-dessus, inchangé. */
.site-nav--souligne .site-nav__list > .site-nav__item > a,
.site-nav--souligne .site-nav__list > .site-nav__item > .site-nav__dropdown > summary {
  padding-bottom: 0.3rem;
  border-bottom: 2px solid transparent;
  transition: border-color 150ms ease;
}

.site-nav--souligne .site-nav__list > .site-nav__item > a:hover,
.site-nav--souligne .site-nav__list > .site-nav__item > .site-nav__dropdown > summary:hover,
.site-nav--souligne .site-nav__list > .site-nav__item > .site-nav__dropdown[open] > summary {
  border-bottom-color: var(--primary-color);
}

.site-nav--pastille .site-nav__list > .site-nav__item > a,
.site-nav--pastille .site-nav__list > .site-nav__item > .site-nav__dropdown > summary {
  padding: 0.4rem 0.9rem;
  border-radius: 9999px;
  transition: background-color 150ms ease, color 150ms ease;
}

.site-nav--pastille .site-nav__list > .site-nav__item > a:hover,
.site-nav--pastille .site-nav__list > .site-nav__item > .site-nav__dropdown > summary:hover,
.site-nav--pastille .site-nav__list > .site-nav__item > .site-nav__dropdown[open] > summary {
  background: var(--primary-color);
  color: var(--background-color);
}

.site-brand {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  text-decoration: none;
  color: var(--foreground-color);
}

.site-brand__logo {
  max-height: 2.5rem;
}

.site-brand__name {
  font-family: var(--heading-font);
  font-size: 1.25rem;
  font-weight: 700;
}

main {
  max-width: var(--content-max-width, 72rem);
  margin: 0 auto;
  padding: 0 1.5rem;
}

.section {
  padding: 3.5rem 0;
  border-bottom: 1px solid var(--border-color);
}

.section:last-child {
  border-bottom: none;
}

.section__title {
  font-size: 1.5rem;
  margin-bottom: 1.5rem;
}

.section--bandeau {
  text-align: center;
  padding: 5rem 0;
}

.section--bandeau__image {
  max-width: 100%;
  border-radius: var(--radius);
  margin-bottom: 1.5rem;
}

.section--bandeau__title {
  font-size: 2.25rem;
}

.section--bandeau__subtitle {
  color: var(--muted-color, var(--foreground-color));
  opacity: 0.75;
  font-size: 1.1rem;
  max-width: 40rem;
  margin: 0 auto 1.5rem;
}

.btn {
  display: inline-block;
  padding: 0.75rem 1.5rem;
  border-radius: var(--radius);
  font-weight: 600;
  text-decoration: none;
}

.btn--primary {
  background: var(--primary-color);
  color: var(--background-color);
}

.btn--secondary {
  background: var(--secondary-color);
  color: var(--background-color);
}

.btn--text {
  background: transparent;
  color: var(--primary-color);
  padding-left: 0;
  padding-right: 0;
}

.section--produits__grid,
.section--temoignages__grid,
.section--reassurance__grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(15rem, 1fr));
  gap: 1.5rem;
}

.product-card,
.reassurance-point {
  border: 1px solid var(--border-color);
  border-radius: var(--radius);
  padding: 1.25rem;
  background: var(--background-color);
}

.reassurance-point__icon {
  display: inline-block;
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  color: var(--primary-color);
  background: var(--muted-color, var(--foreground-color));
  border-radius: var(--radius);
  padding: 0.15rem 0.5rem;
  margin-bottom: 0.5rem;
}

.reassurance-point__title {
  font-family: var(--heading-font);
  font-weight: 700;
  margin-bottom: 0.35rem;
}

.reassurance-point__text {
  opacity: 0.75;
  font-size: 0.95rem;
}

.testimonial {
  border: 1px solid var(--border-color);
  border-radius: var(--radius);
  padding: 1.25rem;
  margin: 0;
  background: var(--background-color);
}

.testimonial__photo {
  width: 3rem;
  height: 3rem;
  border-radius: 50%;
  object-fit: cover;
  margin-bottom: 0.75rem;
}

.testimonial__quote {
  font-style: italic;
  margin: 0 0 0.75rem;
}

.testimonial__author {
  font-size: 0.9rem;
  opacity: 0.7;
}

.site-footer {
  border-top: 1px solid var(--border-color);
  margin-top: 3rem;
}

.site-footer__inner {
  max-width: var(--content-max-width, 72rem);
  margin: 0 auto;
  padding: 2rem 1.5rem;
  font-size: 0.9rem;
  opacity: 0.7;
}

.site-footer__inner p {
  margin: 0.2rem 0;
}

.tb-geo-summary {
  font-style: italic;
  border-left: 3px solid var(--border-color);
  padding: 0.75rem 1rem;
  margin: 0 0 1.5rem;
  background: var(--muted-color, var(--foreground-color));
  border-radius: var(--radius);
}

/* Story 1.6p (2026-08-16) — bug pré-existant hors Bloc 7 : columns_count (LigneBlocForm, choix
   fermé 1-4) n'avait jamais produit de disposition en grille côté rendu public — grid-template-
   columns lui-même est posé en style inline par le templatetag grid_style (dynamique par bloc,
   theme_builder_design.py) ; ce bloc CSS ne fournit que l'espacement commun et le repli mobile.
   Pas de repeat(auto-fit,...) comme .section--produits__grid ci-dessus : columns_count est un
   choix délibéré du commerçant (toujours N colonnes), pas un nombre dérivé de la largeur. */
.tb-block--ligne {
  gap: 1.5rem;
}

@media (max-width: 768px) {
  .tb-block--ligne {
    grid-template-columns: 1fr !important;
  }
}

/* Collapsible sidebar (hidden by default via the [hidden] attribute, toggled by
   #tb-layers-toggle) — same dark chrome as the canvas toolbar, never seen by a real visitor
   (gated server-side by tb_edit_mode, not just CSS). */
.tb-layers-panel {
  position: fixed;
  top: 3.25rem;
  right: 0.75rem;
  z-index: 1000;
  width: 15rem;
  max-height: calc(100vh - 4rem);
  overflow-y: auto;
  background: #1E2433;
  border-radius: 0.375rem;
  padding: 0.6rem 0.5rem;
  /* Keep in sync with tokens.css --color-tb-role-* / CANVAS_CSS; colonne is lightened (#0E6873 is 2.4:1 here). */
  --tb-layers-role-ligne: #3DA35D;
  --tb-layers-role-colonne: #3BB3C1;
  --tb-layers-role-bloc: #FE7F3C;
}

.tb-layers-panel__title {
  color: rgba(255, 255, 255, 0.6);
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  margin: 0 0 0.4rem 0.35rem;
}

.tb-layers-children {
  list-style: none;
  margin: 0;
  padding: 0;
}

.tb-layers-children--root {
  padding: 0;
}

.tb-layers-node > .tb-layers-children {
  padding-left: 1rem;
}

.tb-layers-row {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  width: 100%;
  background: transparent;
  border: none;
  border-radius: 0.25rem;
  padding: 0.3rem 0.35rem;
  color: #E5E7EB;
  font-size: 0.8rem;
  text-align: left;
  cursor: pointer;
}

.tb-layers-row:hover {
  background: rgba(255, 255, 255, 0.08);
}

.tb-layers-row--selected {
  background: rgba(255, 255, 255, 0.16);
  color: #fff;
}

.tb-layers-row__icon svg {
  width: 0.9rem;
  height: 0.9rem;
  flex-shrink: 0;
}

/* Story 1.6s, AC 4 — collapsible tree: chevron beside the row, spacer keeps leaves aligned. */
.tb-layers-line {
  display: flex;
  align-items: center;
  gap: 0.1rem;
}

.tb-layers-toggle,
.tb-layers-toggle-spacer {
  flex: none;
  width: 1rem;
  height: 1.4rem;
}

.tb-layers-toggle {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  background: transparent;
  border: none;
  border-radius: 0.2rem;
  color: rgba(255, 255, 255, 0.6);
  cursor: pointer;
}

.tb-layers-toggle::before {
  content: "▾";
  font-size: 0.75rem;
  line-height: 1;
  transition: transform 120ms ease;
}

.tb-layers-toggle[aria-expanded="false"]::before {
  transform: rotate(-90deg);
}

.tb-layers-toggle:hover,
.tb-layers-toggle:focus-visible {
  background: rgba(255, 255, 255, 0.08);
  color: #fff;
}

.tb-layers-node--collapsed > .tb-layers-children {
  display: none;
}

/* min-width:0 lets the row shrink beside the chevron, so long labels still ellipsize. */
.tb-layers-line > .tb-layers-row {
  flex: 1;
  min-width: 0;
}

/* Story 1.6s, AC 2 — role marker: 3px left bar + tinted icon, same colors as the canvas outlines. */
.tb-layers-row--ligne { --tb-layers-role: var(--tb-layers-role-ligne); }
.tb-layers-row--colonne { --tb-layers-role: var(--tb-layers-role-colonne); }
.tb-layers-row--bloc { --tb-layers-role: var(--tb-layers-role-bloc); }

.tb-layers-row--ligne,
.tb-layers-row--colonne,
.tb-layers-row--bloc {
  box-shadow: inset 3px 0 0 var(--tb-layers-role);
  padding-left: 0.6rem;
}

.tb-layers-row--ligne .tb-layers-row__icon,
.tb-layers-row--colonne .tb-layers-row__icon,
.tb-layers-row--bloc .tb-layers-row__icon {
  display: flex;
  color: var(--tb-layers-role);
}

.tb-layers-row__label {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

/* Same collapsible-sidebar chrome as .tb-layers-panel, positioned further left so both panels
   can be open together without overlapping. */
.tb-history-panel {
  position: fixed;
  top: 3.25rem;
  right: 16.25rem;
  z-index: 1000;
  width: 15rem;
  max-height: calc(100vh - 4rem);
  overflow-y: auto;
  background: #1E2433;
  border-radius: 0.375rem;
  padding: 0.6rem 0.5rem;
}

.tb-history-panel__title {
  color: rgba(255, 255, 255, 0.6);
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  margin: 0 0 0.4rem 0.35rem;
}

.tb-history-list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.tb-history-row {
  border-radius: 0.25rem;
  padding: 0.3rem 0.35rem;
  color: #E5E7EB;
  font-size: 0.8rem;
  cursor: pointer;
}

.tb-history-row:hover {
  background: rgba(255, 255, 255, 0.08);
}

.tb-history-row--current {
  background: rgba(255, 255, 255, 0.16);
  color: #fff;
  font-weight: 600;
}

/* Historique sits left of Calques only when both are open; alone it takes the right edge. */
body:has(#tb-layers-panel-host[hidden]) .tb-history-panel {
  right: 0.75rem;
}

/* Story 1.6s — shared title + ✕ header of the Calques and Historique panels. */
.tb-side-panel__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  margin: 0 0 0.4rem 0.35rem;
}

.tb-side-panel__header .tb-layers-panel__title,
.tb-side-panel__header .tb-history-panel__title {
  margin: 0;
}

.tb-side-panel__close {
  background: transparent;
  border: none;
  border-radius: 0.25rem;
  padding: 0.15rem 0.35rem;
  color: rgba(255, 255, 255, 0.6);
  font-size: 0.8rem;
  line-height: 1;
  cursor: pointer;
}

.tb-side-panel__close:hover,
.tb-side-panel__close:focus-visible {
  background: rgba(255, 255, 255, 0.08);
  color: #fff;
}

/* Not-yet-discarded "redo" entries, ahead of the current cursor — dimmed rather than hidden,
   same reasoning as Divi: they're still there, just not the active state. */
.tb-history-row--future {
  opacity: 0.55;
}

/* Read-only preview frame (mobile/tablette); top padding is extra clearance below the admin bar. */
.tb-viewport-frame-host {
  display: flex;
  justify-content: center;
  padding: 2rem 1rem 2rem;
}

/* display:flex above beats the UA [hidden] rule — without this an empty box stays under the canvas. */
.tb-viewport-frame-host[hidden] {
  display: none;
}

.tb-viewport-frame {
  max-width: 100%;
  height: 80vh;
  border: 1px solid var(--border-color, #E2E5E9);
  border-radius: 0.5rem;
  background: var(--background-color, #fff);
}

/* Story 1.6q — public rendering for the 16 new block types (Galerie/Témoignage/FAQ/Horaires/
   Icône/Icon Box/Liste à puces/Réseaux sociaux/Carrousel/Compte à rebours/Ancre/Tableau de
   prix/Personne/Barre de progression/Onglets/Accordéon), all consuming the same theme CSS
   variables as the rest of the storefront (_theme_injection.html). */

.tb-galerie {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 1.5rem;
}

.tb-galerie__item img {
  width: 100%;
  border-radius: var(--radius);
}

.tb-galerie__prix {
  color: var(--accent-color);
  font-weight: 600;
}

.tb-faq__item {
  border-bottom: 1px solid var(--border-color);
  padding: 0.75rem 0;
}

.tb-faq__item summary {
  cursor: pointer;
  font-weight: 600;
}

.tb-temoignage {
  text-align: center;
  max-width: 40rem;
  margin: 0 auto;
}

.tb-temoignage__photo {
  width: 4rem;
  height: 4rem;
  border-radius: 50%;
  object-fit: cover;
}

.tb-temoignage blockquote {
  font-style: italic;
  margin: 1rem 0;
}

.tb-horaires {
  list-style: none;
  padding: 0;
  max-width: 24rem;
}

.tb-horaires__jour {
  display: flex;
  justify-content: space-between;
  padding: 0.35rem 0;
  border-bottom: 1px solid var(--border-color);
}

.tb-horaires__jour--ferme {
  opacity: 0.6;
}

/* Contact block (Story 1.6t): 12-column grid, each field spans its fraction, one column on mobile.
   --tb-contact-fond/bordure/arrondi come from the block's own field style, theme values otherwise. */
.tb-contact__formulaire {
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  gap: 1rem 1.25rem;
  max-width: 40rem;
}

.tb-contact__champ {
  grid-column: 1 / -1;
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  margin: 0;
  padding: 0;
  border: 0;
  font-weight: 600;
}

.tb-contact__champ--w6 {
  grid-column: span 6;
}

.tb-contact__champ--w4 {
  grid-column: span 4;
}

.tb-contact__champ--w8 {
  grid-column: span 8;
}

.tb-contact__champ--w3 {
  grid-column: span 3;
}

.tb-contact__champ--w9 {
  grid-column: span 9;
}


.tb-contact__champ input:not([type="checkbox"]):not([type="radio"]),
.tb-contact__champ textarea,
.tb-contact__champ select {
  width: 100%;
  padding: 0.6rem 0.75rem;
  border: 1px solid var(--tb-contact-bordure, var(--border-color));
  border-radius: var(--tb-contact-arrondi, var(--radius));
  background: var(--tb-contact-fond, var(--background-color));
  color: var(--foreground-color);
  font: inherit;
  font-weight: 400;
}

.tb-contact__champ input:focus,
.tb-contact__champ textarea:focus,
.tb-contact__champ select:focus {
  outline: 2px solid var(--primary-color);
  outline-offset: 1px;
}

.tb-contact__champ--case {
  flex-direction: row;
  align-items: center;
  gap: 0.5rem;
  font-weight: 400;
}

.tb-contact__champ legend {
  padding: 0;
  margin-bottom: 0.35rem;
}

.tb-contact__option {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-weight: 400;
}

.tb-contact__champ--calcul input {
  max-width: 6rem;
}

/* Editor only: the form isn't live until the site's address can send. */
.tb-contact__formulaire--masque {
  opacity: 0.5;
}

.tb-contact__formulaire .btn {
  grid-column: 1 / -1;
  justify-self: start;
}

@media (max-width: 640px) {
  .tb-contact__formulaire .tb-contact__champ {
    grid-column: 1 / -1;
  }
}

/* Off-screen rather than display:none, which some bots skip. */
.tb-contact__piege {
  position: absolute;
  left: -10000px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

.tb-contact__confirmation,
.tb-contact__erreur,
.tb-contact__avertissement {
  padding: 0.75rem 1rem;
  border: 1px solid var(--border-color);
  border-radius: var(--radius);
}

.tb-contact__erreur {
  border-color: currentColor;
}

.tb-icone svg {
  width: 2rem;
  height: 2rem;
  color: var(--accent-color);
}

.tb-icon-box {
  text-align: center;
}

.tb-icon-box__icon svg {
  width: 2.5rem;
  height: 2.5rem;
  color: var(--accent-color);
}

.tb-liste-icones {
  list-style: none;
  padding: 0;
}

.tb-liste-icones li {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.35rem 0;
}

.tb-liste-icones__icon svg {
  width: 1.25rem;
  height: 1.25rem;
  color: var(--accent-color);
}

.tb-reseaux-sociaux {
  display: flex;
  gap: 0.75rem;
}

.tb-reseaux-sociaux__lien svg {
  width: 1.5rem;
  height: 1.5rem;
}

.tb-carrousel {
  display: flex;
  gap: 1rem;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
}

.tb-carrousel__item {
  flex: 0 0 80%;
  scroll-snap-align: start;
}

.tb-carrousel__item img {
  width: 100%;
  border-radius: var(--radius);
}

.tb-compte-a-rebours {
  text-align: center;
}

.tb-compte-a-rebours__chiffres {
  font-size: 1.5rem;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
}

.tb-tableau-prix {
  border: 1px solid var(--border-color);
  border-radius: var(--radius);
  padding: 1.5rem;
  text-align: center;
}

.tb-tableau-prix--mise-en-avant {
  border-color: var(--accent-color);
  border-width: 2px;
}

.tb-tableau-prix__prix {
  font-size: 2rem;
  font-weight: 700;
  color: var(--accent-color);
}

.tb-tableau-prix ul {
  list-style: none;
  padding: 0;
  text-align: left;
}

.tb-personne {
  text-align: center;
}

.tb-personne__photo {
  width: 6rem;
  height: 6rem;
  border-radius: 50%;
  object-fit: cover;
}

.tb-personne__role {
  color: var(--secondary-color);
}

.tb-personne__liens {
  display: flex;
  justify-content: center;
  gap: 1rem;
}

.tb-barre-progression__titre {
  display: flex;
  justify-content: space-between;
}

.tb-barre-progression__piste {
  background: var(--muted-color);
  border-radius: var(--radius);
  height: 0.6rem;
  overflow: hidden;
}

.tb-barre-progression__remplissage {
  background: var(--accent-color);
  height: 100%;
  transition: width 0.3s ease;
}

.tb-barre-progression__cercle {
  width: 5rem;
  height: 5rem;
  border-radius: 50%;
  background: conic-gradient(var(--accent-color) calc(var(--tb-progress-valeur, 0) * 1%), var(--muted-color) 0);
}

.tb-html-libre {
  width: 100%;
}

.tb-html-libre__cadre {
  display: block;
  width: 100%;
  height: 100%;
  border: 0;
}

.tb-onglets__barre {
  display: flex;
  gap: 0.5rem;
  border-bottom: 1px solid var(--border-color);
}

.tb-onglets__onglet-btn {
  background: none;
  border: none;
  padding: 0.6rem 1rem;
  cursor: pointer;
  font-weight: 600;
  color: var(--foreground-color);
  border-bottom: 2px solid transparent;
}

.tb-onglets__onglet-btn.is-active {
  color: var(--accent-color);
  border-bottom-color: var(--accent-color);
}

.tb-onglets__panneau {
  display: none;
  padding-top: 1.5rem;
}

.tb-onglets__panneau.is-active {
  display: block;
}

.tb-accordeon__item {
  border-bottom: 1px solid var(--border-color);
  padding: 0.75rem 0;
}

.tb-accordeon__item summary {
  cursor: pointer;
  font-weight: 600;
}

/* Story 1.6r, Task 6 — shared "no media selected yet" placeholder (ImageBlock/EmbedVideoBlock/
   CarrouselBlock default content can't fake a real image/video) — dashed box, same visual
   language as the dashboard's own MediaPickerWidget empty state (_picker_field.html). */
.tb-media-placeholder {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 8rem;
  border: 1px dashed var(--border-color);
  border-radius: var(--radius);
  color: var(--secondary-color);
  font-size: 0.9rem;
  text-align: center;
  padding: 1rem;
}

/* Story 2.4 — is_staff admin bar, hardcoded navy tokens (DESIGN.md), never the theme vars above. */

/* Independent of theme/_theme_injection.html: a client theme may not load Manrope at all. */
@font-face {
  font-family: "Manrope";
  src: url("../fonts/manrope/Manrope-Medium.618d840e7ffc.woff2") format("woff2");
  font-weight: 500;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "Manrope";
  src: url("../fonts/manrope/Manrope-SemiBold.e27660b0e5e4.woff2") format("woff2");
  font-weight: 600;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "Manrope";
  src: url("../fonts/manrope/Manrope-Bold.88c54efb78fd.woff2") format("woff2");
  font-weight: 700;
  font-style: normal;
  font-display: swap;
}

.admin-bar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  height: 3rem;
  padding-inline: 1rem;
  background: #101828;
  border-bottom: 1px solid #1D2939;
  font-family: "Manrope", ui-sans-serif, system-ui, sans-serif;
}

.admin-bar__items {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

/* Logo replaces the old "Tableau de bord" text link. */
.admin-bar__logo {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  margin-right: 0.5rem;
  padding: 0.5rem 0.25rem;
  color: #F9FAFB;
  font-weight: 700;
  font-size: 0.75rem;
  letter-spacing: 0.01em;
  text-decoration: none;
  white-space: nowrap;
}

.admin-bar__logo-dot {
  width: 7px;
  height: 7px;
  border-radius: 9999px;
  background: #F9FAFB;
  opacity: 0.55;
  flex: none;
}

.admin-bar__item {
  background: transparent;
  border: none;
  font: inherit;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 0.4rem;
  color: #98A2B3;
  border-radius: 0.25rem;
  padding: 0.5rem 0.75rem;
  font-size: 0.8125rem;
  font-weight: 500;
  text-decoration: none;
  white-space: nowrap;
}

/* Task 8 — icons loaded via {% icon %} (dashboard_icons), stroke="currentColor" already baked
   into each SVG file so they pick up .admin-bar__item's own color (DESIGN.md#icon-default,
   #text-primary on .admin-bar__item--primary) without a separate override. */
.admin-bar__item svg,
.admin-bar__toggle svg {
  width: 15px;
  height: 15px;
  flex: none;
}

.admin-bar__item:hover {
  color: #F9FAFB;
}

.admin-bar__item--primary {
  color: #F9FAFB;
  font-weight: 600;
}

/* Reserves the bar's own height so it never overlaps the page content it sits above. */
body.has-admin-bar {
  padding-top: 3rem;
}

/* Canvas state (Task 3) — Annuler/Refaire/Historique/Calques/Enregistrer/viewport/exit-link.
   Text-labelled by default: Task 8 adds real icons and turns each into --icon (32x32, no text). */
.admin-bar__tool svg {
  width: 17px;
  height: 17px;
  flex: none;
}

.admin-bar__tool {
  display: flex;
  align-items: center;
  gap: 0.35rem;
  background: transparent;
  border: none;
  border-radius: 0.375rem;
  padding: 0.4rem 0.6rem;
  color: #CBD5E1;
  font-size: 0.8125rem;
  font-weight: 500;
  cursor: pointer;
  text-decoration: none;
}

.admin-bar__tool--icon {
  width: 2rem;
  height: 2rem;
  padding: 0;
  justify-content: center;
}

.admin-bar__tool--label {
  color: #F9FAFB;
  font-weight: 600;
}

.admin-bar__tool[aria-expanded="true"] {
  background: rgba(83, 177, 253, 0.14);
  color: #53B1FD;
}

.admin-bar__tool:disabled {
  opacity: 0.4;
  cursor: default;
}

.admin-bar__sep {
  width: 1px;
  height: 1.375rem;
  background: #1D2939;
  margin-inline: 0.25rem;
  flex: none;
}

.admin-bar__viewport-select {
  background: transparent;
  color: #F9FAFB;
  border: 1px solid #1D2939;
  border-radius: 0.25rem;
  padding: 0.25rem 0.4rem;
  font-size: 0.8rem;
}

/* Task 4 — Assistant item + HITL notification badge (DESIGN.md#components.assistant-badge). */
.admin-bar__item--assistant {
  position: relative;
}

.admin-bar__badge {
  position: absolute;
  top: 6px;
  right: 6px;
  width: 7px;
  height: 7px;
  border-radius: 9999px;
  background: #F04438;
  border: 1.5px solid #101828;
}

/* Task 5 — avatar circle (DESIGN.md#components.avatar), now a dropdown trigger, not a drawer. */
.admin-bar__avatar {
  border: none;
  font: inherit;
  cursor: pointer;
  padding: 0;
  width: 1.625rem;
  height: 1.625rem;
  border-radius: 9999px;
  background: #53B1FD;
  color: #101828;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.6875rem;
  font-weight: 700;
  overflow: hidden;
  flex: none;
}

.admin-bar__avatar-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* Dropdown menu (Mon profil / Se déconnecter) replaces the old profile drawer — same pattern as _topbar.html. */
.admin-bar__avatar-menu {
  position: relative;
}

/* Unlayered rules always beat @layer utilities (Tailwind's .hidden/.block), so :not(.hidden) below handles show/hide itself. */
.admin-bar__avatar-dropdown {
  display: none;
  position: absolute;
  top: calc(100% + 0.5rem);
  right: 0;
  min-width: 10rem;
  background: #101828;
  border: 1px solid #1D2939;
  border-radius: 0.375rem;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.28);
  padding: 0.25rem;
  z-index: 1000;
  flex-direction: column;
}

.admin-bar__avatar-dropdown:not(.hidden) {
  display: flex;
}

.admin-bar__avatar-dropdown-item {
  display: block;
  width: 100%;
  text-align: left;
  background: transparent;
  border: none;
  font: inherit;
  cursor: pointer;
  color: #98A2B3;
  padding: 0.5rem 0.75rem;
  border-radius: 0.25rem;
  font-size: 0.8125rem;
  text-decoration: none;
}

.admin-bar__avatar-dropdown-item:hover {
  color: #F9FAFB;
  background: rgba(255, 255, 255, 0.05);
}

/* Task 6 — "voir comme un visiteur" toggle (DESIGN.md#components.visitor-toggle) + persistent
   restore affordance. [hidden] already means display:none per the UA stylesheet — this rule is
   just defensive, in case a client theme's own CSS ever overrides that for nav/button. */
.admin-bar[hidden],
.admin-bar__restore[hidden] {
  display: none;
}

.admin-bar__toggle {
  background: transparent;
  border: none;
  font: inherit;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 0.4rem;
  color: #98A2B3;
  font-size: 0.75rem;
  padding: 0.4rem;
}

/* Track/knob contrast reworked against the navy bar — deviates from DESIGN.md's original token values. */
.admin-bar__toggle-track {
  width: 1.75rem;
  height: 1rem;
  border-radius: 9999px;
  background: #1D2939;
  border: 1px solid #3A4C63;
  position: relative;
  flex: none;
}

.admin-bar__toggle-knob {
  position: absolute;
  top: 1px;
  left: 1px;
  width: 0.75rem;
  height: 0.75rem;
  border-radius: 9999px;
  background: #98A2B3;
}

.admin-bar__toggle[aria-pressed="true"] .admin-bar__toggle-track {
  background: #53B1FD;
  border-color: #53B1FD;
}

.admin-bar__toggle[aria-pressed="true"] .admin-bar__toggle-knob {
  left: 0.875rem;
  background: #F9FAFB;
}

.admin-bar__restore {
  position: fixed;
  bottom: 1rem;
  right: 1rem;
  z-index: 1000;
  width: 0.75rem;
  height: 0.75rem;
  padding: 0;
  border-radius: 9999px;
  background: #101828;
  border: 1.5px solid #53B1FD;
  color: transparent;
  cursor: pointer;
  font-size: 0;
}

/* Task 7 — mobile/tablette collapse. 768px reuses the breakpoint already established for
   .tb-block--ligne above, rather than inventing a new one (no Tailwind breakpoint convention
   exists for the storefront). "Modifier cette page" and the avatar are never in
   .admin-bar__collapsible — EXPERIENCE.md#State Patterns names them as always-visible. */
.admin-bar__menu-toggle {
  display: none;
  background: transparent;
  border: none;
  color: #CBD5E1;
  font-size: 1rem;
  line-height: 1;
  padding: 0.5rem;
  cursor: pointer;
}

.admin-bar__menu {
  display: none;
}

@media (max-width: 768px) {
  .admin-bar__menu-toggle {
    display: flex;
    align-items: center;
  }

  .admin-bar__collapsible {
    display: none;
  }

  .admin-bar__menu:not([hidden]) {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    gap: 0.25rem;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    padding: 0.5rem;
    background: #101828;
    border-bottom: 1px solid #1D2939;
  }
}
