/* ==========================================================================
   EAU DE VIGNE — ENCART & PAGE « PRÉSENTATION EAU DE VIGNE »
   Charte « Carnet de vigneron » · Tons pastels aquarelle · Zéro hex hors variables
   ========================================================================== */

:root {
  --eav-pres-ivory: #FAF7F0;
  --eav-pres-cream: #F6F0E4;
  --eav-pres-sand: #F3ECE0;
  --eav-pres-sage: #E8F0E6;
  --eav-pres-blush: #F4E8E6;
  --eav-pres-ink: #262019;
  --eav-pres-ink-2: #524639;
  --eav-pres-ink-3: #766756;
  --eav-pres-line: #8C7D6B;
  --eav-pres-line-soft: #DFD6C5;
  --eav-pres-bordeaux: #731E1A;
  --eav-pres-bordeaux-dark: #521512;
  --eav-pres-teal: #265650;
  --eav-pres-shadow: 0 10px 30px color-mix(in oklab, var(--eav-pres-ink) 9%, transparent);
}

/* Resserre légèrement l'espace supérieur sur /outils/ pour que l'encart soit visible d'emblée */
body.page-id-4869 #contenu > .section {
  padding-top: 1.75rem;
}

.edv-pres-showcase {
  background-color: var(--eav-pres-ivory);
  border: 1px solid var(--eav-pres-line-soft);
  border-radius: 8px;
  padding: clamp(1rem, 2vw, 1.5rem);
  box-shadow: var(--eav-pres-shadow);
  color: var(--eav-pres-ink);
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, system-ui, sans-serif;
}

.edv-pres-showcase--hub {
  margin: 0 auto 1.75rem;
  max-width: 1280px;
}

.edv-pres-showcase--page {
  margin: 0.75rem auto 2.5rem;
  max-width: 1280px;
}

.edv-pres-showcase__head {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 0.9rem 1.5rem;
  padding-bottom: 0.95rem;
  margin-bottom: 0.95rem;
  border-bottom: 1px solid var(--eav-pres-line-soft);
}

.edv-pres-showcase__titles {
  min-width: min(100%, 300px);
  flex: 1 1 420px;
}

.edv-pres-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.65rem;
  font-family: 'JetBrains Mono', ui-monospace, monospace;
  font-size: 0.6875rem;
  font-weight: 500;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--eav-pres-bordeaux);
  margin-bottom: 0.35rem;
}

.edv-pres-eyebrow__rule {
  display: inline-block;
  width: 32px;
  height: 1px;
  background-color: var(--eav-pres-bordeaux);
}

.edv-pres-showcase__title {
  font-family: 'Fraunces', 'EB Garamond', Georgia, serif;
  font-size: clamp(1.45rem, 2.5vw, 2.05rem);
  font-weight: 500;
  line-height: 1.12;
  letter-spacing: -0.015em;
  margin: 0;
  color: var(--eav-pres-ink);
}

.edv-pres-showcase__title--h1 {
  font-size: clamp(1.75rem, 3.2vw, 2.55rem);
}

.edv-pres-showcase__title a {
  color: inherit;
  text-decoration: none;
}

.edv-pres-showcase__title a:hover {
  color: var(--eav-pres-bordeaux);
}

.edv-pres-showcase__sub {
  margin: 0.3rem 0 0;
  font-size: 0.92rem;
  line-height: 1.5;
  color: var(--eav-pres-ink-2);
  max-width: 68ch;
}

.edv-pres-showcase__cta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.55rem;
}

/* Boutons Carnet (pills 44px min) */
.edv-pres-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.45rem;
  min-height: 42px;
  padding: 0.45rem 1.1rem;
  border-radius: 999px;
  font-family: 'Inter', system-ui, sans-serif;
  font-size: 0.82rem;
  font-weight: 700;
  line-height: 1;
  text-decoration: none;
  cursor: pointer;
  border: 1.5px solid transparent;
  transition: background-color 160ms ease, color 160ms ease, border-color 160ms ease, transform 150ms ease;
  white-space: nowrap;
}

.edv-pres-btn:focus-visible,
.edv-pres-step-pill:focus-visible,
.edv-pres-corner-expand:focus-visible {
  outline: 3px solid var(--eav-pres-bordeaux);
  outline-offset: 2px;
}

.edv-pres-btn--primary {
  background-color: var(--eav-pres-bordeaux);
  border-color: var(--eav-pres-bordeaux);
  color: var(--eav-pres-ivory);
}

.edv-pres-btn--primary:hover {
  background-color: var(--eav-pres-bordeaux-dark);
  border-color: var(--eav-pres-bordeaux-dark);
  color: var(--eav-pres-ivory);
  transform: translateY(-1px);
}

.edv-pres-btn--secondary {
  background-color: var(--eav-pres-sand);
  border-color: var(--eav-pres-line);
  color: var(--eav-pres-ink);
}

.edv-pres-btn--secondary:hover {
  background-color: var(--eav-pres-ink);
  border-color: var(--eav-pres-ink);
  color: var(--eav-pres-ivory);
}

.edv-pres-btn--toggle {
  background-color: var(--eav-pres-cream);
  border-color: var(--eav-pres-line);
  color: var(--eav-pres-ink);
}

.edv-pres-btn--toggle:hover {
  background-color: var(--eav-pres-sand);
}

.edv-pres-btn--toggle.is-active {
  background-color: var(--eav-pres-teal);
  border-color: var(--eav-pres-teal);
  color: var(--eav-pres-ivory);
}

.edv-pres-btn--ghost {
  background-color: transparent;
  border-color: var(--eav-pres-line-soft);
  color: var(--eav-pres-ivory);
  min-height: 38px;
  padding: 0.35rem 0.9rem;
  font-weight: 600;
}

.edv-pres-btn--ghost:hover {
  background-color: color-mix(in oklab, var(--eav-pres-ivory) 14%, transparent);
}

.edv-pres-btn--close {
  background-color: var(--eav-pres-ivory);
  border-color: var(--eav-pres-ivory);
  color: var(--eav-pres-ink);
  min-height: 38px;
  padding: 0.35rem 1rem;
}

.edv-pres-btn--close:hover {
  background-color: var(--eav-pres-blush);
  border-color: var(--eav-pres-blush);
}

/* Scène intégrée du diaporama */
.edv-pres-frame-wrap {
  position: relative;
  width: 100%;
  height: clamp(390px, 56vh, 560px);
  background-color: var(--eav-pres-sand);
  border: 1px solid var(--eav-pres-line-soft);
  border-radius: 6px;
  overflow: hidden;
}

.edv-pres-showcase--page .edv-pres-frame-wrap {
  height: clamp(440px, 68vh, 690px);
}

.edv-pres-iframe {
  display: block;
  width: 100%;
  height: 100%;
  border: 0;
  background-color: var(--eav-pres-ivory);
}

/* Bouton flottant discret en haut à droite du cadre */
.edv-pres-corner-expand {
  position: absolute;
  top: 0.7rem;
  right: 0.7rem;
  z-index: 5;
  display: inline-flex;
  align-items: center;
  gap: 0.38rem;
  min-height: 34px;
  padding: 0.28rem 0.72rem;
  border-radius: 999px;
  border: 1px solid var(--eav-pres-line);
  background-color: color-mix(in oklab, var(--eav-pres-ivory) 92%, transparent);
  color: var(--eav-pres-ink);
  font-family: 'JetBrains Mono', ui-monospace, monospace;
  font-size: 0.68rem;
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  cursor: pointer;
  box-shadow: 0 2px 10px color-mix(in oklab, var(--eav-pres-ink) 10%, transparent);
  transition: background-color 160ms ease, color 160ms ease;
}

.edv-pres-corner-expand:hover {
  background-color: var(--eav-pres-bordeaux);
  border-color: var(--eav-pres-bordeaux);
  color: var(--eav-pres-ivory);
}

/* Barre des 7 tableaux sous l'encart */
.edv-pres-nav-strip {
  display: flex;
  flex-wrap: wrap;
  gap: 0.42rem;
  margin-top: 0.8rem;
}

.edv-pres-step-pill {
  flex: 1 1 auto;
  min-height: 36px;
  padding: 0.3rem 0.68rem;
  border-radius: 999px;
  border: 1px solid var(--eav-pres-line-soft);
  background-color: var(--eav-pres-sand);
  color: var(--eav-pres-ink-2);
  font-family: 'Inter', system-ui, sans-serif;
  font-size: 0.78rem;
  font-weight: 500;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.38rem;
  transition: background-color 160ms ease, color 160ms ease, border-color 160ms ease;
}

.edv-pres-step-pill:hover {
  background-color: var(--eav-pres-blush);
  color: var(--eav-pres-ink);
}

.edv-pres-step-pill__num {
  font-family: 'JetBrains Mono', ui-monospace, monospace;
  font-size: 0.68rem;
  color: var(--eav-pres-bordeaux);
}

.edv-pres-step-pill.is-active {
  background-color: var(--eav-pres-teal);
  border-color: var(--eav-pres-teal);
  color: var(--eav-pres-ivory);
  font-weight: 600;
}

.edv-pres-step-pill.is-active .edv-pres-step-pill__num {
  color: var(--eav-pres-sage);
}

/* ==========================================================================
   MODALE NATIVE <dialog> PLEINE LARGEUR (« METTRE EN GRAND »)
   Conforme aux règles Modern Web Guidance (overscroll-behavior: contain)
   ========================================================================== */
.edv-pres-dialog {
  width: 100vw;
  height: 100dvh;
  max-width: none;
  max-height: none;
  margin: auto;
  padding: 0;
  border: 0;
  border-radius: 0;
  background-color: var(--eav-pres-ink);
  color: var(--eav-pres-ivory);
  box-shadow: 0 24px 64px color-mix(in oklab, var(--eav-pres-ink) 50%, transparent);
  overflow: hidden;
}

.edv-pres-dialog:modal {
  overscroll-behavior: contain;
}

.edv-pres-dialog::backdrop {
  background-color: color-mix(in oklab, var(--eav-pres-ink) 74%, transparent);
  backdrop-filter: blur(4px);
  overflow: hidden;
  overscroll-behavior: contain;
}

.edv-pres-dialog[open] {
  display: flex;
  flex-direction: column;
}

.edv-pres-dialog__shell {
  display: flex;
  flex-direction: column;
  width: 100%;
  height: 100%;
}

.edv-pres-dialog__bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.65rem 1rem;
  padding: 0.6rem 1rem;
  background-color: var(--eav-pres-ink);
  border-bottom: 1px solid color-mix(in oklab, var(--eav-pres-ivory) 16%, transparent);
  flex-shrink: 0;
}

.edv-pres-dialog__brand {
  display: flex;
  align-items: baseline;
  gap: 0.75rem;
  flex-wrap: wrap;
}

.edv-pres-dialog__kicker {
  font-family: 'JetBrains Mono', ui-monospace, monospace;
  font-size: 0.65rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--eav-pres-sage);
}

.edv-pres-dialog__title {
  font-family: 'Fraunces', Georgia, serif;
  font-size: 1.12rem;
  font-weight: 400;
  margin: 0;
  color: var(--eav-pres-ivory);
}

.edv-pres-dialog__actions {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-wrap: wrap;
}

.edv-pres-dialog__close-form {
  margin: 0;
}

.edv-pres-dialog__stage {
  flex: 1;
  min-height: 0;
  width: 100%;
  background-color: var(--eav-pres-ivory);
}

.edv-pres-dialog .edv-pres-btn:focus-visible {
  outline-color: var(--eav-pres-ivory);
}

/* Mobile & Portrait */
@media (max-width: 760px) {
  .edv-pres-frame-wrap {
    height: clamp(460px, 68vh, 580px);
  }

  .edv-pres-step-pill__lbl {
    display: none;
  }

  .edv-pres-step-pill {
    padding: 0.25rem 0.55rem;
  }

  .edv-pres-dialog {
    width: 100vw;
    height: 100dvh;
    border-radius: 0;
    border: 0;
  }

  .edv-pres-dialog__kicker {
    display: none;
  }
}

@media (forced-colors: active) {
  .edv-pres-showcase,
  .edv-pres-frame-wrap,
  .edv-pres-dialog {
    border: 1px solid CanvasText;
  }
  .edv-pres-step-pill.is-active {
    outline: 2px solid Highlight;
  }
}
