/* ============================================================
   Tovarexi — global stylesheet (single global CSS)
   Theme: "Casino Luxe" — emerald felt + champagne gold
   NOTE: library-first, ici seulement les variables de thème
   et les composants décoratifs que Bootstrap ne fournit pas.
   TODO: si on ajoute une 2e police d'affichage, la charger
   dans layout.html et template-*.html en même temps.
   ============================================================ */

/* ---------- 1. Thème (variables Bootstrap surchargées) ---------- */
:root,
[data-bs-theme=dark] {
  --tx-emerald-900: #081f18;
  --tx-emerald-800: #0c2b21;
  --tx-emerald-700: #11362a;
  --tx-emerald-600: #164234;
  --tx-emerald-500: #1d5140;
  --tx-cream: #f2ead8;
  --tx-cream-muted: #aebfae;
  --tx-gold: #d3a94f;
  --tx-gold-soft: #f0d48a;
  --tx-gold-deep: #a97f2c;
  --tx-wine: #8e3b4a;

  --bs-body-bg: var(--tx-emerald-800);
  --bs-body-color: var(--tx-cream);
  --bs-body-font-family: "Manrope", system-ui, -apple-system, "Segoe UI", sans-serif;
  --bs-primary: var(--tx-gold);
  --bs-primary-rgb: 211, 169, 79;
  --bs-link-color: var(--tx-gold-soft);
  --bs-link-hover-color: var(--tx-gold);
  --bs-border-color: rgba(211, 169, 79, .25);
  --bs-secondary-color: rgba(242, 234, 216, .72);
  --bs-tertiary-bg: var(--tx-emerald-700);
}

html{overflow-x: hidden;}

body.tovarexi-theme {
  font-family: var(--bs-body-font-family);
  background-color: var(--tx-emerald-800);
  color: var(--tx-cream);
  overflow-x: hidden;
}

h1, h2, h3, .font-display, .navbar-brand {
  font-family: "Cormorant Garamond", Georgia, serif;
  letter-spacing: .01em;
}

h1 { font-weight: 600; }
::selection { background: var(--tx-gold); color: var(--tx-emerald-900); }

/* ---------- 2. Utilitaires maison (BEM léger) ---------- */
.text-gold { color: var(--tx-gold) !important; }
.text-cream-muted { color: var(--tx-cream-muted) !important; }
.bg-surface { background-color: var(--tx-emerald-700); }
.bg-surface-deep { background-color: var(--tx-emerald-900); }
.bg-gold-gradient {
  background: linear-gradient(135deg, var(--tx-gold-deep) 0%, var(--tx-gold) 45%, var(--tx-gold-soft) 100%);
}
.font-display { font-family: "Cormorant Garamond", Georgia, serif; }
.lh-tight { line-height: 1.25; }
.roundel { border-radius: 50%; }

/* ---------- 3. Boutons ---------- */
.btn-gold {
  --bs-btn-font-weight: 700;
  --bs-btn-color: #241a05;
  --bs-btn-bg: var(--tx-gold);
  --bs-btn-border-color: var(--tx-gold);
  --bs-btn-hover-color: #241a05;
  --bs-btn-hover-bg: var(--tx-gold-soft);
  --bs-btn-hover-border-color: var(--tx-gold-soft);
  --bs-btn-active-bg: var(--tx-gold-deep);
  --bs-btn-active-border-color: var(--tx-gold-deep);
  letter-spacing: .04em;
  text-transform: uppercase;
  font-size: .82rem;
  border-radius: 999px;
  padding: .8rem 1.7rem;
  box-shadow: 0 10px 24px -12px rgba(211, 169, 79, .7);
}
.btn-outline-gold {
  --bs-btn-color: var(--tx-gold-soft);
  --bs-btn-border-color: rgba(211, 169, 79, .6);
  --bs-btn-hover-color: #241a05;
  --bs-btn-hover-bg: var(--tx-gold);
  --bs-btn-hover-border-color: var(--tx-gold);
  --bs-btn-active-bg: var(--tx-gold-deep);
  letter-spacing: .04em;
  text-transform: uppercase;
  font-size: .82rem;
  border-radius: 999px;
  padding: .8rem 1.7rem;
}
/* TODO: vérifier le focus visible sur fond or (accessibilité) */
.btn-gold:focus-visible, .btn-outline-gold:focus-visible {
  outline: 2px solid var(--tx-cream);
  outline-offset: 2px;
}

/* ---------- 4. Sections & décorations ---------- */
.tx-section { position: relative; padding: 5.5rem 0; }
.tx-section--tight { padding: 3.5rem 0; }
.tx-section--surface { background-color: var(--tx-emerald-700); }
.tx-section--deep { background-color: var(--tx-emerald-900); }

/* bandeau à image de fond : l'overlay + url() sont posés en inline */
.tx-bg-cover {
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
}

/* numéro de section géant contouré — signature visuelle du site */
.tx-deco-index {
  font-family: "Cormorant Garamond", Georgia, serif;
  font-size: clamp(4.5rem, 9vw, 8rem);
  line-height: 1;
  font-weight: 700;
  color: transparent;
  -webkit-text-stroke: 1px rgba(211, 169, 79, .4);
  user-select: none;
  pointer-events: none;
}

/* halo doré flou derrière les blocs clés */
.tx-deco-glow {
  position: absolute;
  width: 420px;
  height: 420px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(211, 169, 79, .22) 0%, rgba(211, 169, 79, 0) 70%);
  filter: blur(10px);
  pointer-events: none;
}

/* anneau fin décoratif */
.tx-deco-ring {
  position: absolute;
  border: 1px solid rgba(211, 169, 79, .3);
  border-radius: 50%;
  pointer-events: none;
}

/* filet double doré sous les titres */
.tx-rule {
  width: 84px;
  height: 3px;
  border-top: 1px solid var(--tx-gold);
  border-bottom: 1px solid rgba(211, 169, 79, .35);
  padding-top: 2px;
}

/* sur-titre en petites capitales dorées */
.tx-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: .6rem;
  text-transform: uppercase;
  letter-spacing: .28em;
  font-size: .72rem;
  font-weight: 700;
  color: var(--tx-gold);
}
.tx-eyebrow::before {
  content: "";
  width: 26px;
  height: 1px;
  background: var(--tx-gold);
}

/* motif pointillé (remplace une texture image) */
.tx-dots {
  background-image: repeating-linear-gradient(
    45deg,
    rgba(211, 169, 79, .12) 0 1px,
    transparent 1px 9px
  );
}

/* cadre "carte à jouer" : double bordure dorée décalée */
.tx-frame {
  position: relative;
  border: 1px solid rgba(211, 169, 79, .35);
}
.tx-frame::after {
  content: "";
  position: absolute;
  inset: 10px;
  border: 1px solid rgba(211, 169, 79, .18);
  pointer-events: none;
}

/* ---------- 5. Header / topbar ---------- */
.tx-topbar {
  background-color: var(--tx-emerald-900);
  border-bottom: 1px solid rgba(211, 169, 79, .18);
  font-size: .8rem;
}
.tx-topbar a, .tx-topbar .tx-contact-item { color: var(--tx-cream-muted); text-decoration: none; }
.tx-topbar i { color: var(--tx-gold); }

.tx-masthead {
  background-color: var(--tx-emerald-800);
  border-bottom: 1px solid rgba(211, 169, 79, .18);
  transition: box-shadow .25s ease, background-color .25s ease;
}
.tx-masthead.is-stuck {
  box-shadow: 0 12px 30px -18px rgba(0, 0, 0, .8);
  background-color: rgba(8, 31, 24, .97);
}
.tx-masthead .navbar-brand img { height: 44px; width: auto; }
.tx-masthead .nav-link {
  color: var(--tx-cream);
  font-size: .86rem;
  font-weight: 600;
  letter-spacing: .06em;
  text-transform: uppercase;
  position: relative;
  padding: .4rem 0;
  margin: 0 .9rem;
}
.tx-masthead .nav-link::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: 0;
  width: 0;
  height: 2px;
  background: var(--tx-gold);
  transition: width .25s ease;
}
.tx-masthead .nav-link:hover::after,
.tx-masthead .nav-link.active::after { width: 100%; }
.tx-masthead .nav-link:hover, .tx-masthead .nav-link.active { color: var(--tx-gold-soft); }
.tx-masthead .navbar-toggler { border-color: rgba(211, 169, 79, .5); color: var(--tx-gold); }
.tx-masthead .navbar-toggler:focus { box-shadow: 0 0 0 2px rgba(211, 169, 79, .4); }

/* pastille 18+ */
.tx-age-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  border: 1.5px solid var(--tx-wine);
  color: #f6dfe3;
  background: rgba(142, 59, 74, .35);
  font-size: .68rem;
  font-weight: 800;
  letter-spacing: .05em;
}
.tx-age-badge--lg { width: 64px; height: 64px; font-size: 1.05rem; border-width: 2px; }

/* ---------- 6. Hero slider ---------- */
.tx-hero { position: relative; }
.tx-hero .carousel-item {
  min-height: min(88vh, 780px);
  background-size: cover;
  background-position: center;
}
.tx-hero .carousel-caption,
[data-bs-theme=dark] .tx-hero .carousel-caption {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  text-align: left;
  right: auto;
  left: 0;
  bottom: 0;
  padding: 0;
  /* Bootstrap 5.3 force un noir sur les captions en thème sombre —
     on repasse en crème avec une spécificité équivalente ou supérieure */
  color: var(--tx-cream);
}
.tx-hero__content { max-width: 640px; }
.tx-hero__title { font-size: clamp(2.4rem, 5.2vw, 4.2rem); line-height: 1.08; }
.tx-hero__kicker {
  text-transform: uppercase;
  letter-spacing: .34em;
  font-size: .74rem;
  font-weight: 700;
  color: var(--tx-gold-soft);
}
.tx-hero .carousel-indicators { margin-bottom: 1.6rem; }
.tx-hero .carousel-indicators [data-bs-target] {
  width: 34px;
  height: 3px;
  background-color: rgba(242, 234, 216, .4);
  border: 0;
}
.tx-hero .carousel-indicators .active { background-color: var(--tx-gold); }
.tx-hero .carousel-control-prev-icon,
.tx-hero .carousel-control-next-icon { filter: sepia(1) saturate(3) hue-rotate(5deg); }

/* ---------- 7. Bandeau statistiques ---------- */
.tx-stats { border-block: 1px solid rgba(211, 169, 79, .25); }
.tx-stats__value {
  font-family: "Cormorant Garamond", Georgia, serif;
  font-size: clamp(2.2rem, 4vw, 3.2rem);
  font-weight: 700;
  color: var(--tx-gold-soft);
  line-height: 1;
}
.tx-stats__label {
  text-transform: uppercase;
  letter-spacing: .18em;
  font-size: .7rem;
  color: var(--tx-cream-muted);
}

/* ---------- 8. Cartes (services, chambres, articles…) ---------- */
.tx-card {
  background: linear-gradient(160deg, var(--tx-emerald-600) 0%, var(--tx-emerald-700) 100%);
  border: 1px solid rgba(211, 169, 79, .22);
  border-radius: .75rem;
  overflow: hidden;
  height: 100%;
  transition: transform .3s ease, border-color .3s ease, box-shadow .3s ease;
}
.tx-card:hover {
  transform: translateY(-6px);
  border-color: rgba(211, 169, 79, .55);
  box-shadow: 0 24px 44px -24px rgba(0, 0, 0, .85);
}
.tx-card__media { position: relative; aspect-ratio: 16 / 10; overflow: hidden; background: var(--tx-emerald-900); }
.tx-card__media img { width: 100%; height: 100%; object-fit: cover; display: block; }
.tx-card__body { padding: 1.5rem; }
.tx-card__title { font-size: 1.35rem; font-weight: 600; color: var(--tx-cream); }
.tx-card__price { color: var(--tx-gold-soft); font-weight: 800; }
.tx-card__icon {
  width: 52px;
  height: 52px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid rgba(211, 169, 79, .5);
  color: var(--tx-gold);
  font-size: 1.15rem;
  background: rgba(211, 169, 79, .08);
}

/* lien "en savoir plus" avec flèche animée */
.tx-more {
  color: var(--tx-gold-soft);
  text-decoration: none;
  font-weight: 700;
  font-size: .85rem;
  letter-spacing: .08em;
  text-transform: uppercase;
}
.tx-more i { transition: transform .25s ease; }
.tx-more:hover { color: var(--tx-gold); }
.tx-more:hover i { transform: translateX(6px); }

/* ---------- 9. Tarifs ---------- */
.tx-price-card {
  border: 1px solid rgba(211, 169, 79, .22);
  border-radius: .9rem;
  background: var(--tx-emerald-700);
  height: 100%;
  transition: transform .3s ease, box-shadow .3s ease;
}
.tx-price-card:hover { transform: translateY(-6px); box-shadow: 0 26px 48px -26px rgba(0, 0, 0, .85); }
.tx-price-card--featured {
  border-color: var(--tx-gold);
  background: linear-gradient(170deg, rgba(211, 169, 79, .16) 0%, var(--tx-emerald-700) 55%);
  position: relative;
}
.tx-price-card__tag {
  position: absolute;
  top: -14px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--tx-gold);
  color: #241a05;
  font-size: .68rem;
  font-weight: 800;
  letter-spacing: .12em;
  text-transform: uppercase;
  padding: .3rem 1rem;
  border-radius: 999px;
  white-space: nowrap;
}
.tx-price-card__amount {
  font-family: "Cormorant Garamond", Georgia, serif;
  font-size: 2.6rem;
  font-weight: 700;
  color: var(--tx-gold-soft);
}

/* tableau comparatif */
.tx-compare { border-color: rgba(211, 169, 79, .3); }
.tx-compare th, .tx-compare td {
  border-color: rgba(211, 169, 79, .18);
  color: var(--tx-cream);
  vertical-align: middle;
}
.tx-compare thead th {
  background: rgba(211, 169, 79, .14);
  color: var(--tx-gold-soft);
  text-transform: uppercase;
  font-size: .74rem;
  letter-spacing: .14em;
}
.tx-compare .tx-compare__us { background: rgba(211, 169, 79, .1); }

/* ---------- 10. Processus (étapes numérotées) ---------- */
.tx-step {
  position: relative;
  padding-left: 4.4rem;
  min-height: 64px;
}
.tx-step__num {
  position: absolute;
  left: 0;
  top: 0;
  width: 52px;
  height: 52px;
  border-radius: 50%;
  border: 1px solid rgba(211, 169, 79, .5);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: "Cormorant Garamond", Georgia, serif;
  font-size: 1.4rem;
  font-weight: 700;
  color: var(--tx-gold);
  background: rgba(211, 169, 79, .08);
}

/* timeline histoire */
.tx-timeline { position: relative; padding-left: 1.6rem; border-left: 1px solid rgba(211, 169, 79, .35); }
.tx-timeline__year { color: var(--tx-gold); font-weight: 800; letter-spacing: .08em; }

/* ---------- 11. Galerie ---------- */
.tx-gallery__item { position: relative; overflow: hidden; border-radius: .6rem; background: var(--tx-emerald-900); }
.tx-gallery__item img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform .5s ease; }
.tx-gallery__item:hover img { transform: scale(1.06); }
.tx-gallery__caption {
  position: absolute;
  inset: auto 0 0 0;
  padding: 2rem 1rem .9rem;
  background: linear-gradient(transparent, rgba(8, 31, 24, .92));
  font-size: .85rem;
  color: var(--tx-cream);
}

/* ---------- 12. Avis clients ---------- */
.tx-review { background: var(--tx-emerald-700); border: 1px solid rgba(211, 169, 79, .22); border-radius: .75rem; }
.tx-review__avatar { width: 56px; height: 56px; border-radius: 50%; object-fit: cover; border: 2px solid rgba(211, 169, 79, .5); }
.tx-review__stars { color: var(--tx-gold); letter-spacing: .18em; font-size: .85rem; }
.tx-review__name { font-weight: 700; color: var(--tx-cream); }

/* ---------- 13. FAQ (accordion Bootstrap retouché) ---------- */
.accordion {
  --bs-accordion-bg: var(--tx-emerald-700);
  --bs-accordion-color: var(--tx-cream);
  --bs-accordion-border-color: rgba(211, 169, 79, .25);
  --bs-accordion-btn-color: var(--tx-cream);
  --bs-accordion-active-bg: rgba(211, 169, 79, .12);
  --bs-accordion-btn-focus-box-shadow: 0 0 0 3px rgba(211, 169, 79, .25);
}
.accordion-button { font-family: "Manrope", sans-serif; font-weight: 700; font-size: 1rem; }
.accordion-button:not(.collapsed) { color: var(--tx-gold-soft); box-shadow: inset 0 -1px 0 rgba(211, 169, 79, .3); }
.accordion-body { color: var(--tx-cream-muted); }

/* ---------- 14. CTA / formulaire / notif ---------- */
.tx-cta-band { border: 1px solid rgba(211, 169, 79, .4); border-radius: 1rem; }

.tx-form .form-control, .tx-form .form-select {
  background-color: rgba(8, 31, 24, .6);
  border-color: rgba(211, 169, 79, .3);
  color: var(--tx-cream);
}
.tx-form .form-control:focus, .tx-form .form-select:focus {
  background-color: rgba(8, 31, 24, .8);
  border-color: var(--tx-gold);
  color: var(--tx-cream);
  box-shadow: 0 0 0 .2rem rgba(211, 169, 79, .25);
}
.tx-form .form-control::placeholder { color: rgba(174, 191, 174, .65); }

/* notification simple (pas d'alert JS natif) */
.tx-toast {
  position: fixed;
  right: 1.25rem;
  bottom: 1.25rem;
  z-index: 1080;
  max-width: 360px;
  background: var(--tx-emerald-600);
  border: 1px solid var(--tx-gold);
  border-left: 4px solid var(--tx-gold);
  color: var(--tx-cream);
  border-radius: .6rem;
  padding: 1rem 1.25rem;
  box-shadow: 0 24px 50px -20px rgba(0, 0, 0, .9);
  opacity: 0;
  transform: translateY(16px);
  transition: opacity .3s ease, transform .3s ease;
  pointer-events: none;
}
.tx-toast.is-visible { opacity: 1; transform: translateY(0); }
.tx-toast--error { border-color: var(--tx-wine); border-left-color: var(--tx-wine); }

/* ---------- 15. Cookie banner (accueil uniquement) ---------- */
.tx-cookie {
  position: fixed;
  left: 1.25rem;
  right: 1.25rem;
  bottom: 1.25rem;
  z-index: 1070;
  max-width: 560px;
  margin: 0 auto;
  background: var(--tx-emerald-900);
  border: 1px solid rgba(211, 169, 79, .45);
  border-radius: .9rem;
  padding: 1.25rem 1.4rem;
  box-shadow: 0 30px 60px -30px rgba(0, 0, 0, .9);
  display: none;
}
.tx-cookie.is-visible { display: block; }

/* ---------- 16. Footer ---------- */
.tx-footer {
  background-color: var(--tx-emerald-900);
  border-top: 1px solid rgba(211, 169, 79, .25);
}
.tx-footer h6 {
  text-transform: uppercase;
  letter-spacing: .2em;
  font-size: .74rem;
  color: var(--tx-gold);
  font-weight: 800;
}
.tx-footer a { color: var(--tx-cream-muted); text-decoration: none; font-size: .9rem; }
.tx-footer a:hover { color: var(--tx-gold-soft); }
.tx-footer .tx-social a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  border: 1px solid rgba(211, 169, 79, .4);
  color: var(--tx-gold-soft);
  transition: background .25s ease, color .25s ease;
}
.tx-footer .tx-social a:hover { background: var(--tx-gold); color: #241a05; }
.tx-footer__legal { border-top: 1px solid rgba(211, 169, 79, .15); font-size: .8rem; color: var(--tx-cream-muted); }

/* ---------- 17. Divers ---------- */
.tx-map-frame { border: 1px solid rgba(211, 169, 79, .35); border-radius: .75rem; filter: grayscale(.2) contrast(1.05); }
.tx-partner-logo {
  background: var(--tx-emerald-700);
  border: 1px solid rgba(211, 169, 79, .25);
  border-radius: .6rem;
  aspect-ratio: 16 / 9;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}
.tx-partner-logo img { max-height: 100%; object-fit: cover; width: 100%; }

/* liens internes dans le texte : soulignement doré discret */
.tx-inline-link {
  color: var(--tx-gold-soft);
  text-decoration: underline;
  text-decoration-color: rgba(211, 169, 79, .5);
  text-underline-offset: 3px;
}
.tx-inline-link:hover { color: var(--tx-gold); text-decoration-color: var(--tx-gold); }

/* responsive : topbar lisible sur mobile aussi */
@media (max-width: 575.98px) {
  .tx-topbar { font-size: .74rem; }
  .tx-section { padding: 3.5rem 0; }
}
