/* ==========================================================================
   STYLE - RESPIRATION DU VEILLEUR DES BRUMES
   Harmonie, Sérénité, Égrégore et Haute Précision Sensorielle
   Inspiré des codes visuels de veilleurdesbrumes.com
   ========================================================================== */

:root {
  color-scheme: dark;
  
  /* Palette Veilleur des Brumes */
  --ink: #101d25;
  --deep: #0c171f;
  --surface: #15232c;
  --surface-hover: #1a2c37;
  --cream: #f2eee5;
  --muted: #b1bac0;
  --gold: #d9bf88;
  --gold-glow: #ffd16b;
  --gold-deep: #b59857;
  --mist-blue: #b5c9d6;
  --sage: #b3c6ab;
  --line: rgba(213, 219, 220, .16);
  --line-strong: rgba(217, 191, 136, .35);

  /* Typographie */
  --serif: Georgia, 'Times New Roman', 'Baskerville', serif;
  --sans: 'Segoe UI', -apple-system, BlinkMacSystemFont, system-ui, Roboto, sans-serif;

  /* Espacements & transitions */
  --radius-sm: 8px;
  --radius-md: 14px;
  --radius-lg: 24px;
  --radius-full: 9999px;
  --transition: all 0.35s cubic-bezier(0.16, 1, 0.3, 1);
  --transition-smooth: all 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

svg {
  fill: none;
}

button svg,
.toggle-title svg,
.settings-subheading svg {
  fill: none;
}

html {
  font-family: var(--sans);
  background: var(--deep);
  color: var(--cream);
  min-height: 100%;
  -webkit-text-size-adjust: 100%;
  -webkit-font-smoothing: antialiased;
}

body {
  position: relative;
  min-height: 100vh;
  background: radial-gradient(circle at 50% 15%, #182b36 0%, var(--ink) 55%, var(--deep) 100%);
  color: var(--cream);
  line-height: 1.6;
  overflow-x: hidden;
  display: flex;
  flex-direction: column;
}

/* Toile de particules et brume de fond */
#mist-canvas {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 0;
  opacity: 0.75;
}

/* Lueur d'ambiance en arrière-plan */
.ambient-glow {
  position: fixed;
  top: -150px;
  left: 50%;
  transform: translateX(-50%);
  width: 700px;
  height: 700px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(217, 191, 136, 0.08) 0%, rgba(181, 201, 214, 0.03) 45%, transparent 70%);
  pointer-events: none;
  z-index: 0;
  transition: opacity 1.2s ease, transform 1.2s ease;
}

/* ==========================================================================
   EN-TÊTE & NAVIGATION
   ========================================================================== */

.site-header {
  position: relative;
  z-index: 10;
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  background: rgba(16, 29, 37, 0.85);
  border-bottom: 1px solid var(--line);
}

.header-container {
  max-width: 1140px;
  margin: 0 auto;
  padding: 16px 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.brand-block {
  display: flex;
  align-items: center;
  gap: 14px;
  text-decoration: none;
  color: var(--cream);
}

.brand-lantern {
  width: 34px;
  height: 44px;
  color: var(--gold);
  flex-shrink: 0;
  filter: drop-shadow(0 0 8px rgba(255, 209, 107, 0.35));
  transition: var(--transition);
}

.brand-text h1 {
  font-family: var(--serif);
  font-size: 1.25rem;
  font-weight: 400;
  letter-spacing: 0.03em;
  color: var(--cream);
  line-height: 1.2;
  white-space: nowrap;
}

.brand-tagline {
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.22em;
  color: var(--gold);
  opacity: 0.9;
  white-space: nowrap;
  display: block;
}

/* Bloc central du header : Égrégore & Devise dorée */
.header-center-block {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 4px;
  text-align: center;
}

.header-submotto {
  font-size: 0.74rem;
  font-family: var(--serif);
  font-style: italic;
  letter-spacing: 0.08em;
  color: var(--gold);
  text-shadow: 0 0 10px rgba(255, 209, 107, 0.28);
  opacity: 0.95;
  white-space: nowrap;
}

/* Indicateur d'égrégore */
.egregore-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 14px;
  background: rgba(21, 35, 44, 0.65);
  border: 1px solid var(--line);
  border-radius: var(--radius-full);
  font-size: 0.8rem;
  color: var(--muted);
  backdrop-filter: blur(8px);
}

.egregore-pulse {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--gold);
  box-shadow: 0 0 8px var(--gold-glow);
  animation: pulse-dot 2.6s infinite ease-in-out;
}

@keyframes pulse-dot {
  0%, 100% { transform: scale(1); opacity: 0.6; }
  50% { transform: scale(1.35); opacity: 1; }
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 10px;
}

/* Boutons icônes d'en-tête */
.btn-icon-header {
  background: rgba(21, 35, 44, 0.8);
  border: 1px solid var(--line);
  color: var(--cream);
  width: 42px;
  height: 42px;
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: var(--transition);
  position: relative;
}

.btn-icon-header svg {
  width: 20px;
  height: 20px;
  stroke: currentColor;
  stroke-width: 1.6;
  fill: none;
}

.btn-icon-header:hover {
  background: var(--surface-hover);
  border-color: var(--gold);
  color: var(--gold);
  transform: translateY(-1px);
}

.btn-icon-header.active {
  background: rgba(217, 191, 136, 0.15);
  border-color: var(--gold);
  color: var(--gold-glow);
  box-shadow: 0 0 12px rgba(255, 209, 107, 0.25);
}

.btn-icon-header.active::after {
  content: '';
  position: absolute;
  bottom: -4px;
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: var(--gold-glow);
  box-shadow: 0 0 4px var(--gold-glow);
}

/* ==========================================================================
   CONTENEUR PRINCIPAL
   ========================================================================== */

.main-content {
  position: relative;
  z-index: 5;
  flex: 1;
  max-width: 980px;
  margin: 0 auto;
  width: 100%;
  padding: 32px 20px 60px;
  display: flex;
  flex-direction: column;
  align-items: center;
}

/* Citation introductive */
.intro-quote {
  text-align: center;
  max-width: 620px;
  margin-bottom: 28px;
}

.intro-quote p {
  font-family: var(--serif);
  font-style: italic;
  font-size: 1.05rem;
  color: var(--muted);
  line-height: 1.6;
}

.intro-quote em {
  color: var(--gold);
  font-style: normal;
}

/* ==========================================================================
   SÉLECTEUR DE PRÉRÉGLAGES
   ========================================================================== */

.presets-container {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  justify-content: center;
  margin-bottom: 34px;
  width: 100%;
}

.preset-pill {
  background: rgba(21, 35, 44, 0.7);
  border: 1px solid var(--line);
  color: var(--cream);
  padding: 9px 18px;
  border-radius: var(--radius-full);
  font-size: 0.85rem;
  letter-spacing: 0.02em;
  cursor: pointer;
  transition: var(--transition);
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.preset-pill:hover {
  background: var(--surface-hover);
  border-color: rgba(217, 191, 136, 0.4);
  color: var(--cream);
  transform: translateY(-1px);
}

.preset-pill.active {
  background: rgba(217, 191, 136, 0.18);
  border-color: var(--gold);
  color: var(--gold);
  box-shadow: 0 0 14px rgba(217, 191, 136, 0.15);
}

.preset-formula {
  font-size: 0.75rem;
  color: var(--muted);
  opacity: 0.85;
}

.preset-pill.active .preset-formula {
  color: var(--gold-glow);
}

/* Compteur d'égrégore par pilule de méditation */
.preset-egregore {
  font-size: 0.72rem;
  background: rgba(217, 191, 136, 0.12);
  border: 1px solid rgba(217, 191, 136, 0.25);
  color: var(--gold);
  padding: 2px 8px;
  border-radius: var(--radius-full);
  display: inline-flex;
  align-items: center;
  gap: 4px;
  transition: var(--transition);
  white-space: nowrap;
}

.preset-pill:hover .preset-egregore {
  border-color: rgba(217, 191, 136, 0.45);
}

.preset-pill.active .preset-egregore {
  background: rgba(217, 191, 136, 0.24);
  border-color: var(--gold);
  color: var(--gold-glow);
  box-shadow: 0 0 8px rgba(217, 191, 136, 0.2);
}

/* ==========================================================================
   SANCTUAIRE DU SOUFFLE (ORBE & VISUEL CENTRAL)
   ========================================================================== */

.breathing-sanctuary {
  position: relative;
  width: 340px;
  height: 340px;
  margin: 10px auto 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  user-select: none;
  cursor: pointer;
}

@media (min-width: 600px) {
  .breathing-sanctuary {
    width: 380px;
    height: 380px;
  }
}

/* Anneau SVG de progression de phase */
.progress-svg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  transform: rotate(-90deg);
  overflow: visible;
}

.circle-track {
  fill: none;
  stroke: rgba(213, 219, 220, 0.08);
  stroke-width: 4;
}

.circle-progress {
  fill: none;
  stroke: var(--gold);
  stroke-width: 5;
  stroke-linecap: round;
  stroke-dasharray: 1000;
  stroke-dashoffset: 1000;
  filter: drop-shadow(0 0 8px rgba(255, 209, 107, 0.45));
  transition: stroke-dashoffset 0.05s linear;
}

/* Halo respirant externe */
.auric-halo {
  position: absolute;
  width: 250px;
  height: 250px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(217, 191, 136, 0.22) 0%, rgba(181, 201, 214, 0.08) 50%, transparent 75%);
  filter: blur(14px);
  transform: scale(0.75);
  transition: transform 0.15s ease-out, background 0.8s ease, filter 0.8s ease;
  pointer-events: none;
}

/* Cœur de l'orbe */
.breathing-orb {
  position: relative;
  width: 210px;
  height: 210px;
  border-radius: 50%;
  background: radial-gradient(circle at 35% 35%, #253946 0%, #15242f 65%, #0d171f 100%);
  border: 1px solid rgba(217, 191, 136, 0.3);
  box-shadow: 
    0 10px 30px rgba(0, 0, 0, 0.6),
    inset 0 0 25px rgba(217, 191, 136, 0.12);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 16px;
  z-index: 2;
  transform: scale(0.85);
  transition: transform 0.15s ease-out, border-color 0.8s ease, box-shadow 0.8s ease;
  cursor: pointer;
}

.breathing-orb:hover {
  border-color: rgba(217, 191, 136, 0.65);
  box-shadow: 
    0 12px 36px rgba(0, 0, 0, 0.65),
    inset 0 0 30px rgba(217, 191, 136, 0.2);
}

/* Mode Géométrie Carrée alternative */
.breathing-sanctuary.mode-square .breathing-orb {
  border-radius: 28px;
  transform: scale(0.85) rotate(0deg);
}

.breathing-sanctuary.mode-square .auric-halo {
  border-radius: 36px;
}

/* Contenu textuel dans l'orbe */
.orb-phase {
  font-family: var(--serif);
  font-size: 1.25rem;
  letter-spacing: 0.04em;
  color: var(--cream);
  min-height: 1.6em;
  transition: color 0.5s ease;
}

.orb-counter {
  font-family: var(--sans);
  font-size: 3.2rem;
  font-weight: 200;
  letter-spacing: -0.03em;
  color: var(--gold-glow);
  line-height: 1.1;
  text-shadow: 0 0 16px rgba(255, 209, 107, 0.4);
}

.orb-seconds-unit {
  font-size: 1.2rem;
  opacity: 0.65;
  margin-left: 2px;
}

.orb-mantra {
  font-size: 0.75rem;
  color: var(--muted);
  max-width: 170px;
  line-height: 1.35;
  margin-top: 4px;
  min-height: 2em;
  opacity: 0.85;
}

/* États colorimétriques de l'orbe selon la phase */
.phase-inspire .auric-halo {
  background: radial-gradient(circle, rgba(255, 209, 107, 0.38) 0%, rgba(217, 191, 136, 0.18) 50%, transparent 75%);
  filter: blur(18px);
}
.phase-inspire .breathing-orb {
  border-color: rgba(255, 209, 107, 0.6);
  box-shadow: 0 0 35px rgba(255, 209, 107, 0.25), inset 0 0 30px rgba(255, 209, 107, 0.2);
}
.phase-inspire .orb-phase {
  color: var(--gold-glow);
}

.phase-retention-pleine .auric-halo {
  background: radial-gradient(circle, rgba(217, 191, 136, 0.4) 0%, rgba(179, 198, 171, 0.2) 50%, transparent 75%);
  filter: blur(20px);
}
.phase-retention-pleine .breathing-orb {
  border-color: var(--gold);
  box-shadow: 0 0 40px rgba(217, 191, 136, 0.3), inset 0 0 30px rgba(217, 191, 136, 0.25);
}

.phase-expire .auric-halo {
  background: radial-gradient(circle, rgba(181, 201, 214, 0.32) 0%, rgba(179, 198, 171, 0.14) 50%, transparent 75%);
  filter: blur(14px);
}
.phase-expire .breathing-orb {
  border-color: rgba(181, 201, 214, 0.5);
  box-shadow: 0 0 30px rgba(181, 201, 214, 0.2), inset 0 0 25px rgba(181, 201, 214, 0.15);
}
.phase-expire .orb-phase {
  color: var(--mist-blue);
}

.phase-retention-vide .auric-halo {
  background: radial-gradient(circle, rgba(133, 101, 58, 0.15) 0%, transparent 60%);
  filter: blur(10px);
}
.phase-retention-vide .breathing-orb {
  border-color: rgba(213, 219, 220, 0.2);
  box-shadow: 0 0 15px rgba(0, 0, 0, 0.7);
}
.phase-retention-vide .orb-phase {
  color: var(--muted);
}

/* ==========================================================================
   STATISTIQUES DE SESSION EN DIRECT
   ========================================================================== */

.session-stats-bar {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 28px;
  background: rgba(21, 35, 44, 0.65);
  border: 1px solid var(--line);
  padding: 10px 24px;
  border-radius: var(--radius-full);
  margin-bottom: 28px;
  backdrop-filter: blur(8px);
}

.stat-item {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.85rem;
  white-space: nowrap;
}

.stat-label {
  color: var(--muted);
  white-space: nowrap;
}

.stat-value {
  color: var(--cream);
  font-weight: 500;
  font-family: var(--serif);
  font-size: 0.95rem;
  white-space: nowrap;
}

.stat-divider {
  width: 1px;
  height: 16px;
  background: var(--line);
}

/* ==========================================================================
   MODULE MANTRA INTÉRIEUR (RÉCITATION SILENCIEUSE)
   ========================================================================== */

.inner-mantra-sanctuary {
  width: 100%;
  max-width: 620px;
  margin: 0 auto 24px;
  background: rgba(18, 32, 42, 0.88);
  border: 1px solid rgba(217, 191, 136, 0.35);
  border-radius: var(--radius-md);
  padding: 16px 20px;
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  text-align: center;
  position: relative;
  transition: var(--transition);
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.45), inset 0 0 20px rgba(217, 191, 136, 0.04);
}

.inner-mantra-sanctuary:hover {
  border-color: rgba(217, 191, 136, 0.55);
}

.inner-mantra-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 8px;
  font-size: 0.74rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--gold);
}

.mantra-badge-left {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.mantra-sparkle {
  color: var(--gold-glow);
  font-size: 0.85rem;
}

.btn-mantra-toggle {
  background: rgba(16, 29, 37, 0.8);
  border: 1px solid var(--line);
  color: var(--muted);
  font-size: 0.72rem;
  padding: 3px 10px;
  border-radius: var(--radius-full);
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  transition: var(--transition);
}

.mantra-toggle-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--muted);
}

.btn-mantra-toggle.active {
  border-color: var(--gold);
  color: var(--gold);
  background: rgba(217, 191, 136, 0.14);
}

.btn-mantra-toggle.active .mantra-toggle-dot {
  background: var(--gold-glow);
  box-shadow: 0 0 6px var(--gold-glow);
}

/* En-tête du mantra actif dans le sanctuaire */
.active-mantra-header {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  font-size: 0.72rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 2px;
  background: rgba(16, 29, 37, 0.6);
  padding: 3px 12px;
  border-radius: var(--radius-full);
  border: 1px solid rgba(217, 191, 136, 0.2);
}

.active-mantra-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 16px;
  height: 16px;
  flex-shrink: 0;
}

.active-mantra-header .mantra-logo,
.active-mantra-icon .mantra-logo,
.active-mantra-icon svg {
  width: 16px !important;
  height: 16px !important;
  max-width: 16px !important;
  max-height: 16px !important;
  stroke: var(--gold-glow);
  stroke-width: 1.8;
  fill: none !important;
  stroke-linecap: round;
  stroke-linejoin: round;
  flex-shrink: 0;
}

.mantra-logo circle,
.mantra-logo path,
.mantra-logo line {
  fill: none !important;
}

.active-mantra-title {
  font-weight: 500;
}

.mantra-phrase-text {
  font-family: var(--serif);
  font-size: 1.15rem;
  font-style: italic;
  color: var(--cream);
  line-height: 1.45;
  transition: var(--transition-smooth);
  cursor: pointer;
  user-select: none;
  padding: 4px 8px;
  border-radius: var(--radius-sm);
}

.mantra-phrase-text:hover {
  color: var(--gold-glow);
  background: rgba(217, 191, 136, 0.08);
}

/* Barre d'activation et compteur des récitants */
.mantra-recitation-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  background: rgba(16, 29, 37, 0.65);
  border: 1px solid var(--line);
  border-radius: var(--radius-full);
  padding: 6px 16px;
  margin: 12px auto 6px;
  max-width: 490px;
  transition: var(--transition);
}

.inner-mantra-sanctuary.reciting-active {
  border-color: rgba(217, 191, 136, 0.55);
  box-shadow: 0 0 24px rgba(217, 191, 136, 0.16), inset 0 0 16px rgba(217, 191, 136, 0.05);
}

.inner-mantra-sanctuary.reciting-active .mantra-recitation-bar {
  border-color: rgba(217, 191, 136, 0.35);
  background: rgba(21, 35, 44, 0.85);
}

.mantra-checkbox-container {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  cursor: pointer;
  user-select: none;
}

.mantra-checkbox-container input {
  position: absolute;
  opacity: 0;
  cursor: pointer;
  height: 0;
  width: 0;
}

.custom-checkbox-mark {
  height: 16px;
  width: 16px;
  background-color: rgba(16, 29, 37, 0.9);
  border: 1px solid var(--line);
  border-radius: 4px;
  display: inline-block;
  position: relative;
  transition: var(--transition);
  flex-shrink: 0;
}

.mantra-checkbox-container:hover input ~ .custom-checkbox-mark {
  border-color: var(--gold);
}

.mantra-checkbox-container input:checked ~ .custom-checkbox-mark {
  background-color: var(--gold);
  border-color: var(--gold);
  box-shadow: 0 0 8px rgba(217, 191, 136, 0.4);
}

.custom-checkbox-mark:after {
  content: "";
  position: absolute;
  display: none;
  left: 5px;
  top: 2px;
  width: 4px;
  height: 8px;
  border: solid var(--deep);
  border-width: 0 2px 2px 0;
  transform: rotate(45deg);
}

.mantra-checkbox-container input:checked ~ .custom-checkbox-mark:after {
  display: block;
}

.mantra-reciting-text {
  font-size: 0.8rem;
  color: var(--cream);
  letter-spacing: 0.01em;
}

.mantra-reciters-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.74rem;
  color: var(--gold);
  background: rgba(217, 191, 136, 0.12);
  border: 1px solid rgba(217, 191, 136, 0.25);
  padding: 3px 10px;
  border-radius: var(--radius-full);
  white-space: nowrap;
  transition: var(--transition);
}

.egregore-pulse-mini {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--gold-glow);
  box-shadow: 0 0 6px var(--gold-glow);
  animation: pulse-dot 2.2s infinite ease-in-out;
}

.mantra-guidance-subtext {
  display: block;
  font-size: 0.73rem;
  color: var(--muted);
  margin-top: 5px;
  opacity: 0.85;
}

.inner-mantra-sanctuary.muted-mode {
  opacity: 0.4;
}

.inner-mantra-sanctuary.muted-mode .mantra-phrase-text {
  font-style: normal;
  color: var(--muted);
  text-decoration: line-through;
}

/* ==========================================================================
   COMMANDES PRINCIPALES
   ========================================================================== */

.main-controls {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  margin-bottom: 36px;
  width: 100%;
}

.btn-primary-action {
  background: linear-gradient(135deg, var(--gold) 0%, #b89c62 100%);
  color: var(--deep);
  border: none;
  font-family: var(--serif);
  font-size: 1.15rem;
  letter-spacing: 0.03em;
  padding: 14px 38px;
  border-radius: var(--radius-full);
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 12px;
  box-shadow: 0 4px 20px rgba(217, 191, 136, 0.35);
  transition: var(--transition);
  min-width: 190px;
  justify-content: center;
}

.btn-primary-action svg {
  width: 22px;
  height: 22px;
  stroke: var(--deep);
  stroke-width: 2.2;
  stroke-linecap: round;
  stroke-linejoin: round;
  fill: none;
}

.btn-primary-action:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 26px rgba(217, 191, 136, 0.5);
  background: linear-gradient(135deg, #ffd782 0%, var(--gold) 100%);
}

.btn-primary-action:active {
  transform: translateY(0);
}

.btn-secondary-action {
  background: rgba(21, 35, 44, 0.7);
  border: 1px solid var(--line);
  color: var(--cream);
  padding: 13px 20px;
  border-radius: var(--radius-full);
  font-size: 0.9rem;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  transition: var(--transition);
}

.btn-secondary-action svg {
  width: 18px;
  height: 18px;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
  fill: none;
}

.btn-secondary-action:hover {
  background: var(--surface-hover);
  border-color: var(--gold);
  color: var(--gold);
}

/* ==========================================================================
   PANNEAU DE CONFIGURATION DES PARAMÈTRES
   ========================================================================== */

.settings-card {
  background: rgba(18, 32, 42, 0.88);
  border: 1px solid rgba(217, 191, 136, 0.28);
  border-radius: var(--radius-lg);
  padding: 26px 28px;
  width: 100%;
  max-width: 760px;
  backdrop-filter: blur(14px);
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.45), inset 0 0 20px rgba(217, 191, 136, 0.03);
}

.settings-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid var(--line);
  padding-bottom: 14px;
  margin-bottom: 22px;
}

.settings-header h2 {
  font-family: var(--serif);
  font-size: 1.15rem;
  font-weight: 400;
  color: var(--gold);
  display: flex;
  align-items: center;
  gap: 10px;
}

.settings-header h2 svg {
  width: 20px;
  height: 20px;
  stroke: var(--gold);
  stroke-width: 1.8;
  fill: none;
}

.square-sync-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.76rem;
  padding: 3px 10px;
  border-radius: var(--radius-full);
  background: rgba(217, 191, 136, 0.16);
  border: 1px solid var(--gold);
  color: var(--gold-glow);
  box-shadow: 0 0 10px rgba(217, 191, 136, 0.2);
  transition: var(--transition);
}

/* Grille des 4 phases de respiration */
.phases-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 16px;
  margin-bottom: 26px;
}

.phase-card {
  background: rgba(16, 29, 37, 0.6);
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  padding: 14px 12px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  transition: var(--transition);
}

.phase-card:hover {
  border-color: rgba(217, 191, 136, 0.3);
}

.phase-card-title {
  font-size: 0.8rem;
  color: var(--muted);
  display: flex;
  align-items: center;
  gap: 6px;
}

.phase-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--gold);
}

.phase-card:nth-child(1) .phase-dot { background: var(--gold); }
.phase-card:nth-child(2) .phase-dot { background: var(--gold-glow); }
.phase-card:nth-child(3) .phase-dot { background: var(--mist-blue); }
.phase-card:nth-child(4) .phase-dot { background: var(--sage); }

.phase-value-row {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
}

.phase-num {
  font-family: var(--serif);
  font-size: 1.8rem;
  font-weight: 400;
  color: var(--cream);
  line-height: 1;
}

.phase-unit {
  font-size: 0.75rem;
  color: var(--muted);
  margin-left: 2px;
}

/* Curseur de réglage */
.range-slider {
  -webkit-appearance: none;
  appearance: none;
  width: 100%;
  height: 5px;
  background: rgba(213, 219, 220, 0.15);
  border-radius: var(--radius-full);
  outline: none;
  cursor: pointer;
  margin-top: 4px;
}

.range-slider::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: var(--gold);
  cursor: pointer;
  box-shadow: 0 0 6px rgba(217, 191, 136, 0.5);
  transition: transform 0.15s ease;
}

.range-slider::-webkit-slider-thumb:hover {
  transform: scale(1.2);
}

.range-slider::-moz-range-thumb {
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: var(--gold);
  cursor: pointer;
  border: none;
  box-shadow: 0 0 6px rgba(217, 191, 136, 0.5);
}

/* Paramètres de cycles et options secondaires */
.options-row {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 20px;
  margin-bottom: 22px;
  padding-top: 14px;
  border-top: 1px solid var(--line);
}

.option-group {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.option-label {
  font-size: 0.85rem;
  color: var(--cream);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.cycle-mode-toggle {
  display: flex;
  background: rgba(16, 29, 37, 0.8);
  border: 1px solid var(--line);
  border-radius: var(--radius-full);
  padding: 3px;
  gap: 4px;
}

.cycle-mode-btn {
  flex: 1;
  background: none;
  border: none;
  color: var(--muted);
  padding: 6px 12px;
  border-radius: var(--radius-full);
  font-size: 0.8rem;
  cursor: pointer;
  transition: var(--transition);
  text-align: center;
}

.cycle-mode-btn.active {
  background: var(--surface);
  color: var(--gold);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
}

/* Sélecteur de forme de l'orbe */
.shape-selector {
  display: flex;
  gap: 8px;
}

.shape-btn {
  flex: 1;
  background: rgba(16, 29, 37, 0.8);
  border: 1px solid var(--line);
  color: var(--muted);
  padding: 8px 12px;
  border-radius: var(--radius-md);
  font-size: 0.82rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  cursor: pointer;
  transition: var(--transition);
}

.shape-btn svg {
  width: 16px;
  height: 16px;
  stroke: currentColor;
  stroke-width: 1.8;
  fill: none;
}

.shape-btn.active {
  background: rgba(217, 191, 136, 0.14);
  border-color: var(--gold);
  color: var(--gold);
}

/* Interrupteurs (Toggles) */
.toggle-switch-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 0;
  border-bottom: 1px solid rgba(213, 219, 220, 0.08);
}

.toggle-switch-row:last-child {
  border-bottom: none;
}

.toggle-desc {
  display: flex;
  flex-direction: column;
}

.toggle-title {
  font-size: 0.88rem;
  color: var(--cream);
  display: flex;
  align-items: center;
  gap: 8px;
}

.toggle-title svg {
  width: 18px;
  height: 18px;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
  fill: none;
  flex-shrink: 0;
}

.toggle-subtitle {
  font-size: 0.75rem;
  color: var(--muted);
  margin-top: 2px;
}

.switch {
  position: relative;
  display: inline-block;
  width: 44px;
  height: 24px;
  flex-shrink: 0;
}

.switch input {
  opacity: 0;
  width: 0;
  height: 0;
}

.slider-switch {
  position: absolute;
  cursor: pointer;
  inset: 0;
  background-color: rgba(213, 219, 220, 0.2);
  transition: 0.3s;
  border-radius: 34px;
}

.slider-switch:before {
  position: absolute;
  content: "";
  height: 18px;
  width: 18px;
  left: 3px;
  bottom: 3px;
  background-color: var(--cream);
  transition: 0.3s;
  border-radius: 50%;
}

input:checked + .slider-switch {
  background-color: var(--gold);
}

input:checked + .slider-switch:before {
  transform: translateX(20px);
  background-color: var(--deep);
}

/* ==========================================================================
   SECTION MANTRA & INTENTION SILENCIEUSE (PARAMÈTRES)
   ========================================================================== */

.mantra-settings-section {
  padding-top: 22px;
  margin-top: 20px;
  border-top: 1px solid var(--line);
}

.settings-subheading {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 6px;
}

.settings-subheading svg {
  stroke: var(--gold);
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
  fill: none;
  flex-shrink: 0;
}

.settings-subheading h3 {
  font-family: var(--serif);
  font-size: 1.05rem;
  color: var(--cream);
  font-weight: 400;
}

.coming-soon-pill {
  font-size: 0.7rem;
  padding: 2px 8px;
  border-radius: var(--radius-full);
  background: rgba(181, 201, 214, 0.12);
  color: var(--mist-blue);
  border: 1px solid rgba(181, 201, 214, 0.25);
  letter-spacing: 0.04em;
}

.section-hint {
  font-size: 0.78rem;
  color: var(--muted);
  margin-bottom: 14px;
  line-height: 1.5;
}

.mantra-preset-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 12px;
  margin-bottom: 12px;
}

.mantra-preset-btn {
  background: rgba(18, 32, 42, 0.85);
  border: 1px solid rgba(217, 191, 136, 0.25);
  border-radius: 12px;
  padding: 12px 16px;
  text-align: left;
  cursor: pointer;
  transition: var(--transition);
  display: flex;
  flex-direction: column;
  gap: 6px;
  color: var(--cream);
  text-decoration: none;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.3);
  -webkit-appearance: none;
  appearance: none;
}

.mantra-preset-btn:hover {
  border-color: rgba(217, 191, 136, 0.5);
  background: rgba(25, 42, 54, 0.9);
  transform: translateY(-1px);
}

.mantra-preset-btn.active {
  background: rgba(217, 191, 136, 0.16);
  border-color: var(--gold);
  box-shadow: 0 0 16px rgba(255, 209, 107, 0.2), inset 0 0 12px rgba(217, 191, 136, 0.08);
}

.mantra-preset-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  gap: 8px;
}

.mantra-preset-theme {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.76rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--gold);
  font-weight: 500;
}

.mantra-reciters-pill {
  font-size: 0.68rem;
  background: rgba(217, 191, 136, 0.14);
  border: 1px solid rgba(217, 191, 136, 0.35);
  color: var(--gold);
  padding: 2px 8px;
  border-radius: var(--radius-full);
  display: inline-flex;
  align-items: center;
  gap: 4px;
  transition: var(--transition);
  white-space: nowrap;
  font-weight: 400;
  letter-spacing: normal;
  text-transform: none;
}

.mantra-preset-btn:hover .mantra-reciters-pill {
  border-color: rgba(217, 191, 136, 0.6);
  background: rgba(217, 191, 136, 0.22);
}

.mantra-preset-btn.active .mantra-reciters-pill {
  background: rgba(217, 191, 136, 0.28);
  border-color: var(--gold);
  color: var(--gold-glow);
  box-shadow: 0 0 8px rgba(217, 191, 136, 0.25);
}

.mantra-logo {
  width: 16px;
  height: 16px;
  stroke: var(--gold);
  stroke-width: 1.8;
  fill: none;
  stroke-linecap: round;
  stroke-linejoin: round;
  flex-shrink: 0;
  transition: var(--transition);
}

.mantra-preset-btn:hover .mantra-logo,
.mantra-preset-btn.active .mantra-logo {
  stroke: var(--gold-glow);
  filter: drop-shadow(0 0 4px rgba(255, 209, 107, 0.45));
}

.mantra-preset-phrase {
  font-family: var(--serif);
  font-size: 0.86rem;
  color: var(--cream);
  font-style: italic;
  line-height: 1.4;
  opacity: 0.95;
}

.mantra-preset-btn.active .mantra-preset-phrase {
  color: #fff9e6;
  opacity: 1;
}

.text-input-field {
  width: 100%;
  background: rgba(16, 29, 37, 0.85);
  border: 1px solid var(--line);
  color: var(--cream);
  padding: 9px 14px;
  border-radius: var(--radius-sm);
  font-family: var(--serif);
  font-size: 0.9rem;
  font-style: italic;
  outline: none;
  transition: var(--transition);
}

.text-input-field:focus {
  border-color: var(--gold);
  box-shadow: 0 0 10px rgba(217, 191, 136, 0.25);
}

/* ==========================================================================
   MODAL / TIROIR DE CONFIGURATION AUDIO & MATÉRIEL
   ========================================================================== */

.modal-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(12, 23, 31, 0.85);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
}

.modal-backdrop.open {
  opacity: 1;
  pointer-events: auto;
}

.modal-dialog {
  background: var(--surface);
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-lg);
  max-width: 640px;
  width: 100%;
  max-height: 90vh;
  overflow-y: auto;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.7);
  padding: 28px;
  position: relative;
  transform: scale(0.95);
  transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.modal-backdrop.open .modal-dialog {
  transform: scale(1);
}

.modal-close-btn {
  position: absolute;
  top: 20px;
  right: 20px;
  background: none;
  border: none;
  color: var(--muted);
  cursor: pointer;
  padding: 6px;
  border-radius: 50%;
  transition: var(--transition);
}

.modal-close-btn:hover {
  color: var(--cream);
  background: rgba(255, 255, 255, 0.1);
}

.modal-close-btn svg {
  width: 22px;
  height: 22px;
}

.modal-title {
  font-family: var(--serif);
  font-size: 1.35rem;
  color: var(--gold);
  margin-bottom: 6px;
}

.modal-subtitle {
  font-size: 0.85rem;
  color: var(--muted);
  margin-bottom: 24px;
}

/* Onglets du Modal */
.modal-tabs {
  display: flex;
  gap: 12px;
  border-bottom: 1px solid var(--line);
  margin-bottom: 20px;
}

.modal-tab-btn {
  background: none;
  border: none;
  padding: 10px 16px;
  color: var(--muted);
  font-size: 0.9rem;
  cursor: pointer;
  border-bottom: 2px solid transparent;
  transition: var(--transition);
}

.modal-tab-btn:hover {
  color: var(--cream);
}

.modal-tab-btn.active {
  color: var(--gold);
  border-bottom-color: var(--gold);
}

.tab-pane {
  display: none;
}

.tab-pane.active {
  display: block;
}

/* Liste des slots sonores personnalisés */
.audio-slot-list {
  display: flex;
  flex-direction: column;
  gap: 14px;
  margin-bottom: 22px;
}

.audio-slot-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: rgba(16, 29, 37, 0.6);
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  padding: 12px 16px;
  gap: 12px;
}

.audio-slot-info {
  display: flex;
  flex-direction: column;
}

.audio-slot-name {
  font-size: 0.88rem;
  color: var(--cream);
}

.audio-slot-status {
  font-size: 0.72rem;
  color: var(--muted);
}

.audio-slot-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

.btn-file-select {
  background: rgba(217, 191, 136, 0.15);
  border: 1px solid var(--gold);
  color: var(--gold);
  font-size: 0.78rem;
  padding: 6px 12px;
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: var(--transition);
}

.btn-file-select:hover {
  background: var(--gold);
  color: var(--deep);
}

.btn-sound-preview {
  background: none;
  border: 1px solid var(--line);
  color: var(--cream);
  padding: 6px;
  border-radius: var(--radius-sm);
  cursor: pointer;
}

.btn-sound-preview:hover {
  border-color: var(--gold);
  color: var(--gold);
}

/* Boîte de recommandation technique audio */
.tech-notice-box {
  background: rgba(16, 29, 37, 0.9);
  border-left: 3px solid var(--gold);
  padding: 14px 16px;
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  margin-top: 18px;
  font-size: 0.8rem;
  color: var(--muted);
  line-height: 1.5;
}

.tech-notice-box strong {
  color: var(--cream);
}


/* ==========================================================================
   SECTION LE SOUFFLE, LA VIE (Savoirs Croisés)
   ========================================================================== */

.breath-life-section {
  width: 100%;
  max-width: 760px;
  margin: 0 auto 32px;
  background: rgba(18, 32, 42, 0.88);
  border: 1px solid rgba(217, 191, 136, 0.28);
  border-radius: var(--radius-lg);
  padding: 26px 28px;
  backdrop-filter: blur(14px);
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.45), inset 0 0 20px rgba(217, 191, 136, 0.03);
  transition: var(--transition);
}

.section-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid var(--line);
  padding-bottom: 14px;
  margin-bottom: 22px;
}

.section-header h2 {
  font-family: var(--serif);
  font-size: 1.15rem;
  font-weight: 400;
  color: var(--gold);
}

.view-switch {
  display: flex;
  background: rgba(16, 29, 37, 0.8);
  border: 1px solid var(--line);
  border-radius: var(--radius-full);
  padding: 3px;
  gap: 4px;
}

.switch-btn {
  background: none;
  border: none;
  color: var(--muted);
  padding: 6px 14px;
  border-radius: var(--radius-full);
  font-size: 0.78rem;
  cursor: pointer;
  transition: var(--transition);
}

.switch-btn.active {
  background: var(--surface);
  color: var(--gold);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
}

.view-content {
  display: none;
  animation: fadeIn 0.4s ease-out;
}

.view-content.active {
  display: block;
}

.content-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 20px;
  margin-bottom: 24px;
}

.info-block {
  background: rgba(16, 29, 37, 0.6);
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  padding: 16px;
  transition: var(--transition);
}

.info-block:hover {
  border-color: rgba(217, 191, 136, 0.3);
}

.info-block h3 {
  font-family: var(--serif);
  font-size: 0.95rem;
  color: var(--gold);
  margin-bottom: 8px;
}

.info-block p {
  font-size: 0.85rem;
  color: var(--cream);
  line-height: 1.5;
  opacity: 0.9;
}

.concordance-matrix {
  background: rgba(217, 191, 136, 0.05);
  border: 1px solid rgba(217, 191, 136, 0.15);
  border-radius: var(--radius-md);
  padding: 12px;
}

.matrix-header {
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--gold);
  text-align: center;
  margin-bottom: 10px;
  opacity: 0.8;
}

.matrix-row {
  display: flex;
  justify-content: center;
  gap: 12px;
  flex-wrap: wrap;
}

.matrix-cell {
  background: rgba(16, 29, 37, 0.7);
  border: 1px solid var(--line);
  padding: 6px 12px;
  border-radius: var(--radius-full);
  font-size: 0.75rem;
  color: var(--muted);
  transition: var(--transition);
}

.matrix-cell:hover {
  border-color: var(--gold);
  color: var(--cream);
}

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(4px); }
  to { opacity: 1; transform: translateY(0); }
}

/* ==========================================================================
   PIED DE PAGE
   ========================================================================== */

.site-footer {
  position: relative;
  z-index: 5;
  border-top: 1px solid var(--line);
  background: rgba(12, 23, 31, 0.95);
  padding: 24px 20px;
  text-align: center;
  font-size: 0.8rem;
  color: var(--muted);
}

.footer-inner {
  max-width: 980px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 8px;
  align-items: center;
}

.footer-quote {
  font-family: var(--serif);
  font-style: italic;
  color: var(--gold);
  opacity: 0.85;
}

/* ==========================================================================
   MODE PLEIN ÉCRAN IMMERSIF
   ========================================================================== */

body.fullscreen-mode .site-header,
body.fullscreen-mode .intro-quote,
body.fullscreen-mode .presets-container,
body.fullscreen-mode .settings-card,
body.fullscreen-mode .site-footer {
  display: none !important;
}

body.fullscreen-mode .main-content {
  padding: 0;
  height: 100vh;
  justify-content: center;
}

.exit-fullscreen-btn {
  position: fixed;
  top: 24px;
  right: 24px;
  z-index: 50;
  background: rgba(21, 35, 44, 0.7);
  border: 1px solid var(--line);
  color: var(--cream);
  padding: 8px 16px;
  border-radius: var(--radius-full);
  font-size: 0.85rem;
  cursor: pointer;
  display: none;
}

body.fullscreen-mode .exit-fullscreen-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

/* ==========================================================================
   RESPONSIVE DESIGN (MOBILE & TABLETTE)
   Adaptation fluide, équilibrée et harmonieuse pour smartphones
   Préservation intégrale et stricte du rendu sur grand écran (PC)
   ========================================================================== */

@media (max-width: 768px) {
  /* En-tête mobile en grille 2 rangées : Marque & Actions (L1), Devise centrée (L2) */
  .header-container {
    display: grid;
    grid-template-columns: 1fr auto;
    grid-template-areas:
      "brand actions"
      "center center";
    align-items: center;
    padding: 10px 14px;
    gap: 8px 12px;
  }

  .brand-block {
    grid-area: brand;
    display: flex;
    align-items: center;
    gap: 10px;
    min-width: 0;
  }

  .brand-lantern {
    width: 26px;
    height: 34px;
    flex-shrink: 0;
  }

  .brand-text {
    min-width: 0;
    display: flex;
    flex-direction: column;
  }

  .brand-text h1 {
    font-size: 1.05rem;
    white-space: nowrap;
    letter-spacing: 0.02em;
  }

  .brand-tagline {
    font-size: 0.62rem;
    letter-spacing: 0.14em;
    white-space: nowrap;
  }

  .header-actions {
    grid-area: actions;
    display: flex;
    align-items: center;
    gap: 6px;
    justify-self: end;
  }

  .btn-icon-header {
    width: 34px;
    height: 34px;
  }

  .header-center-block {
    grid-area: center;
    width: 100%;
    margin-top: 2px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 3px;
    text-align: center;
  }

  .egregore-badge {
    display: inline-flex;
    font-size: 0.72rem;
    padding: 3px 10px;
  }

  .header-submotto {
    font-size: 0.72rem;
    letter-spacing: 0.06em;
    white-space: nowrap;
  }

  .main-content {
    padding: 14px 12px 36px;
  }

  .intro-quote {
    font-size: 0.84rem;
    margin: 4px auto 12px;
    line-height: 1.35;
    max-width: 95%;
  }

  /* Préréglages compacts sur mobile */
  .presets-container {
    gap: 6px;
    margin-bottom: 14px;
    justify-content: center;
  }

  .preset-pill {
    padding: 6px 12px;
    font-size: 0.76rem;
  }

  .preset-formula {
    font-size: 0.68rem;
  }

  .preset-egregore {
    font-size: 0.66rem;
    padding: 1px 6px;
  }

  /* Sanctuaire et orbe respiratoire optimisés pour mobile */
  .breathing-sanctuary {
    width: 240px;
    height: 240px;
    margin: 4px auto 14px;
  }

  .breathing-orb {
    width: 155px;
    height: 155px;
    padding: 12px;
  }

  .orb-counter {
    font-size: 2.2rem;
  }

  .orb-phase {
    font-size: 0.98rem;
  }

  .orb-mantra {
    font-size: 0.75rem;
  }

  /* Barre des statistiques fluide et sans saut de ligne */
  .session-stats-bar {
    width: 100%;
    max-width: 340px;
    gap: 8px;
    padding: 8px 12px;
    margin-bottom: 14px;
    justify-content: space-around;
    background: rgba(18, 32, 42, 0.9);
    border: 1px solid rgba(217, 191, 136, 0.3);
  }

  .stat-item {
    gap: 3px;
    font-size: 0.74rem;
    white-space: nowrap;
  }

  .stat-label {
    font-size: 0.70rem;
    white-space: nowrap;
  }

  .stat-value {
    font-size: 0.82rem;
    white-space: nowrap;
  }

  .stat-divider {
    height: 12px;
  }

  /* Cadre du sanctuaire de mantra intérieur bien visible */
  .inner-mantra-sanctuary {
    padding: 12px 14px;
    margin-bottom: 16px;
    background: rgba(18, 32, 42, 0.92);
    border: 1px solid rgba(217, 191, 136, 0.38);
    border-radius: 14px;
    box-shadow: 0 6px 24px rgba(0, 0, 0, 0.5);
  }

  .active-mantra-header {
    margin-bottom: 4px;
    font-size: 0.70rem;
    padding: 3px 10px;
  }

  .mantra-phrase-text {
    font-size: 0.92rem;
    line-height: 1.35;
    padding: 2px 4px;
  }

  .mantra-recitation-bar {
    flex-direction: column;
    gap: 6px;
    padding: 8px 10px;
    border-radius: 10px;
    margin: 8px auto 4px;
  }

  .mantra-reciting-text {
    font-size: 0.80rem;
  }

  .mantra-reciters-badge {
    font-size: 0.70rem;
  }

  .mantra-guidance-subtext {
    font-size: 0.68rem;
  }

  /* Commandes principales */
  .main-controls {
    margin-bottom: 20px;
    gap: 10px;
  }

  .btn-primary-action {
    padding: 11px 24px;
    font-size: 1rem;
    min-width: 160px;
  }

  .btn-secondary-action {
    padding: 10px 16px;
    font-size: 0.85rem;
  }

  /* Grille des réglages et cartes de mantras */
  .phases-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 8px;
  }

  .phase-card {
    padding: 10px 12px;
  }

  .settings-card {
    padding: 16px 14px;
    border-radius: 16px;
  }

  .mantra-preset-list {
    grid-template-columns: 1fr;
    gap: 10px;
  }

  .mantra-preset-btn {
    padding: 10px 14px;
    border-radius: 10px;
  }
}

/* ==========================================================================
   LIEN DOSSIER (header) & CTA — v2.4
   Lien vers dossier.html : la page de contenu distincte du service.
   ========================================================================== */

.btn-dossier-header {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  background: rgba(21, 35, 44, 0.8);
  border: 1px solid var(--line-strong);
  color: var(--gold);
  padding: 0 15px;
  height: 42px;
  border-radius: var(--radius-md);
  font-size: 0.8rem;
  letter-spacing: 0.02em;
  white-space: nowrap;
  text-decoration: none;
  transition: var(--transition);
}

.btn-dossier-header svg {
  width: 17px;
  height: 21px;
  flex-shrink: 0;
  filter: drop-shadow(0 0 6px rgba(255, 209, 107, 0.35));
}

.btn-dossier-header:hover {
  background: rgba(217, 191, 136, 0.14);
  border-color: var(--gold);
  color: var(--gold-glow);
  transform: translateY(-1px);
  box-shadow: 0 0 14px rgba(255, 209, 107, 0.2);
}

/* CTA retiré avec l'encart « Le souffle, la vie » (v2.6) — le lien vit dans le header */

/* Libellé court caché par défaut — n'apparaît que sous 860px */
.btn-dossier-header .label-short {
  display: none;
}

@media (max-width: 860px) {
  .btn-dossier-header .label-long {
    display: none;
  }

  /* Libellé compact empilé sous l'icône : le lien reste identifiable sur mobile */
  .btn-dossier-header .label-short {
    display: block;
    font-size: 0.54rem;
    letter-spacing: 0.05em;
    line-height: 1;
  }

  .btn-dossier-header {
    flex-direction: column;
    gap: 3px;
    padding: 4px 8px;
  }

  .btn-dossier-header svg {
    width: 14px;
    height: 17px;
  }
}

@media (max-width: 640px) {
  .btn-dossier-header {
    height: 34px;
  }
}
