/* ============================================================================
   Site Catherine Roquigny — Praticienne EMF Balancing Technique®
   Charte graphique : Constellation bleu nuit + doré chaud
   ============================================================================ */

/* ---- Variables ---- */
:root {
  --night:        #0B1A2E;
  --night-soft:   #16263F;
  --night-deeper: #06101F;
  --cream:        #F5EFE6;
  --cream-warm:   #EFE6D8;
  --gold:         #D4A574;
  --gold-soft:    #E5C9A0;
  --gold-deep:    #B88656;
  --ink:          #2A2520;
  --ink-soft:     #6B6258;
  --star:         rgba(245, 239, 230, 0.6);
  --line-soft:    rgba(212, 165, 116, 0.2);
  --line-strong:  rgba(212, 165, 116, 0.5);
}

/* ---- Reset ---- */
* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  background: var(--night);
  color: var(--cream);
  font-family: 'Inter', sans-serif;
  font-weight: 300;
  line-height: 1.7;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
button { font-family: inherit; cursor: pointer; }

/* ---- Typographie ---- */
h1, h2, h3, h4, h5, .display {
  font-family: 'Tenor Sans', serif;
  font-weight: 400;
  letter-spacing: 0.005em;
}

/* ---- Constellation de fond (canvas) ---- */
.constellation-bg {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
}

/* ---- Navigation principale ---- */
nav.main {
  position: fixed;
  top: 0; left: 0; right: 0;
  padding: 24px 60px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  z-index: 100;
  background: rgba(11, 26, 46, 0.65);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid rgba(212, 165, 116, 0.08);
}
nav.main .logo {
  font-family: 'Tenor Sans', serif;
  font-size: 22px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  display: flex;
  align-items: baseline;
  gap: 8px;
}
nav.main .logo strong {
  font-weight: 400;
  color: var(--cream);
}
nav.main .logo span {
  color: var(--gold);
  font-style: italic;
  text-transform: none;
  font-size: 0.9em;
}
nav.main ul {
  list-style: none;
  display: flex;
  gap: 36px;
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.2em;
  color: rgba(245, 239, 230, 0.8);
}
nav.main ul a {
  transition: color 0.3s;
  position: relative;
}
nav.main ul a:hover, nav.main ul a.active { color: var(--gold); }
nav.main ul a::after {
  content: '';
  position: absolute;
  bottom: -8px; left: 0;
  width: 0; height: 1px;
  background: var(--gold);
  transition: width 0.3s;
}
nav.main ul a:hover::after, nav.main ul a.active::after { width: 100%; }

/* Menu burger mobile */
.nav-toggle {
  display: none;
  background: transparent;
  border: none;
  color: var(--cream);
  font-size: 24px;
  padding: 8px;
}

/* ---- Boutons ---- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  padding: 16px 32px;
  border: 1px solid var(--gold);
  color: var(--cream);
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.25em;
  transition: all 0.3s;
  background: transparent;
  font-family: 'Inter', sans-serif;
  font-weight: 400;
}
.btn:hover {
  background: var(--gold);
  color: var(--night);
}
.btn.primary {
  background: var(--gold);
  color: var(--night);
}
.btn.primary:hover {
  background: var(--gold-soft);
  border-color: var(--gold-soft);
}
.btn::after {
  content: '→';
  transition: transform 0.3s;
}
.btn:hover::after { transform: translateX(4px); }
.btn.no-arrow::after { content: none; }

/* ---- Layout sections ---- */
section {
  padding: 120px 60px;
  position: relative;
  z-index: 1;
}
.container {
  max-width: 1280px;
  margin: 0 auto;
}
.container-narrow {
  max-width: 880px;
  margin: 0 auto;
}

.section-eyebrow {
  font-size: 11px;
  letter-spacing: 0.4em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 24px;
  display: flex;
  align-items: center;
  gap: 16px;
}
.section-eyebrow::before {
  content: '';
  width: 40px; height: 1px;
  background: var(--gold);
  opacity: 0.6;
}
.section-eyebrow.center {
  justify-content: center;
}
.section-eyebrow.center::before {
  content: none;
}

.section-title {
  font-size: clamp(36px, 4.5vw, 64px);
  line-height: 1.1;
  margin-bottom: 40px;
  max-width: 800px;
}
.section-title.center { margin: 0 auto 40px; text-align: center; }
.section-title em, .section-title .gold {
  color: var(--gold);
  font-style: italic;
}

.section-light {
  background: var(--cream);
  color: var(--ink);
}
.section-light .section-title { color: var(--ink); }
.section-light .section-eyebrow { color: var(--gold-deep); }
.section-light .section-eyebrow::before { background: var(--gold-deep); }

/* ---- Hero générique (réutilisable) ---- */
.hero {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  text-align: center;
  padding: 140px 40px 100px;
  position: relative;
  z-index: 1;
}
.hero-eyebrow {
  font-size: 11px;
  letter-spacing: 0.5em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 32px;
  display: inline-flex;
  align-items: center;
  gap: 16px;
}
.hero-eyebrow::before,
.hero-eyebrow::after {
  content: '';
  width: 40px; height: 1px;
  background: var(--gold);
  opacity: 0.5;
}
.hero h1 {
  font-size: clamp(44px, 6.5vw, 96px);
  line-height: 1.08;
  margin-bottom: 32px;
  max-width: 1000px;
  font-weight: 400;
}
.hero h1 .gold {
  color: var(--gold);
  font-style: italic;
}
.hero p.lead {
  font-size: 18px;
  color: rgba(245, 239, 230, 0.78);
  max-width: 600px;
  margin-bottom: 48px;
  font-weight: 300;
}
.hero-actions {
  display: flex;
  gap: 20px;
  flex-wrap: wrap;
  justify-content: center;
}

/* ---- Hero compact (pour pages internes) ---- */
.hero.compact {
  min-height: 60vh;
}

/* ---- Footer ---- */
footer.main {
  background: var(--night-deeper);
  color: rgba(245, 239, 230, 0.65);
  padding: 80px 60px 30px;
  position: relative;
  z-index: 1;
}
footer.main .footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr;
  gap: 60px;
  max-width: 1280px;
  margin: 0 auto;
  padding-bottom: 40px;
  border-bottom: 1px solid rgba(212, 165, 116, 0.1);
}
footer.main .logo {
  font-family: 'Tenor Sans', serif;
  font-size: 22px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  margin-bottom: 16px;
  color: var(--cream);
}
footer.main .logo span { color: var(--gold); font-style: italic; text-transform: none; }
footer.main p { font-size: 14px; line-height: 1.6; }
footer.main h5 {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.25em;
  color: var(--gold);
  margin-bottom: 16px;
}
footer.main ul { list-style: none; }
footer.main ul li {
  margin-bottom: 8px;
  font-size: 14px;
}
footer.main ul li a:hover { color: var(--gold); }
footer.main .footer-bottom {
  max-width: 1280px;
  margin: 24px auto 0;
  text-align: center;
  font-size: 12px;
  letter-spacing: 0.15em;
  color: rgba(245, 239, 230, 0.4);
}

/* ---- Cartes / panneaux ---- */
.card-panel {
  background: var(--night-soft);
  border: 1px solid rgba(212, 165, 116, 0.15);
  padding: 32px;
  transition: border-color 0.3s, transform 0.3s;
}
.card-panel:hover {
  border-color: rgba(212, 165, 116, 0.4);
  transform: translateY(-2px);
}

/* ---- Formulaire ---- */
.form-field { margin-bottom: 24px; }
.form-field label {
  display: block;
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.2em;
  color: rgba(245, 239, 230, 0.7);
  margin-bottom: 10px;
}
.form-field input,
.form-field textarea,
.form-field select {
  width: 100%;
  padding: 14px 16px;
  border: 1px solid rgba(212, 165, 116, 0.25);
  background: rgba(11, 26, 46, 0.4);
  font-family: 'Inter', sans-serif;
  font-size: 15px;
  color: var(--cream);
  transition: border-color 0.3s, background 0.3s;
}
.form-field input:focus,
.form-field textarea:focus,
.form-field select:focus {
  outline: none;
  border-color: var(--gold);
  background: rgba(11, 26, 46, 0.7);
}
.form-field textarea { min-height: 120px; resize: vertical; }

/* ---- Utilitaires ---- */
.text-center { text-align: center; }
.gold { color: var(--gold); }
.italic { font-style: italic; }
.mt-40 { margin-top: 40px; }
.mt-60 { margin-top: 60px; }
.mb-40 { margin-bottom: 40px; }
.divider {
  height: 1px;
  background: linear-gradient(to right, transparent, var(--gold), transparent);
  opacity: 0.3;
  margin: 60px auto;
  max-width: 200px;
}

/* ============================================================================
   Composants spécifiques
   ============================================================================ */

/* ---- Treillis SVG animé ---- */
.treillis-svg .ring {
  fill: none;
  stroke: var(--gold);
  stroke-width: 0.6;
  opacity: 0.4;
}
.treillis-svg .axis {
  stroke: var(--gold);
  stroke-width: 0.8;
  opacity: 0.6;
  stroke-dasharray: 3,5;
}
.treillis-svg .star-dot {
  fill: var(--gold);
}
.treillis-svg .star-soft {
  fill: var(--cream);
  opacity: 0.7;
}

@keyframes pulse-soft {
  0%, 100% { opacity: 0.5; transform: scale(1); }
  50% { opacity: 1; transform: scale(1.15); }
}
.treillis-svg .pulse { animation: pulse-soft 4s ease-in-out infinite; transform-origin: center; transform-box: fill-box; }
.treillis-svg .pulse-2 { animation-delay: 1s; }
.treillis-svg .pulse-3 { animation-delay: 2s; }

@keyframes draw-ring {
  from { stroke-dashoffset: 1200; }
  to { stroke-dashoffset: 0; }
}
.treillis-svg .draw {
  stroke-dasharray: 1200;
  animation: draw-ring 3s ease-out forwards;
}

@keyframes twinkle {
  0%, 100% { opacity: 0.3; }
  50% { opacity: 1; }
}
.twinkle { animation: twinkle 4s ease-in-out infinite; }

/* ---- Tirage de carte (humeur du jour) ---- */
.tirage {
  padding: 100px 40px;
  position: relative;
  z-index: 1;
  background: linear-gradient(180deg, var(--night) 0%, var(--night-soft) 50%, var(--night) 100%);
}
.tirage-content {
  max-width: 880px;
  margin: 0 auto;
  text-align: center;
}
.tirage-deck {
  position: relative;
  height: 380px;
  margin: 60px auto 40px;
  display: flex;
  justify-content: center;
  align-items: center;
}
.tirage-card-back {
  position: absolute;
  width: 220px; height: 320px;
  background: linear-gradient(135deg, var(--night-soft), var(--night-deeper));
  border: 1px solid var(--gold);
  border-radius: 12px;
  cursor: pointer;
  transition: transform 0.5s cubic-bezier(0.4, 0, 0.2, 1), box-shadow 0.3s;
  box-shadow: 0 10px 40px rgba(0,0,0,0.4);
  display: flex;
  align-items: center;
  justify-content: center;
  user-select: none;
}
.tirage-card-back::before,
.tirage-card-back::after {
  content: '';
  position: absolute;
  inset: 12px;
  border: 1px solid rgba(212, 165, 116, 0.4);
  border-radius: 8px;
  pointer-events: none;
}
.tirage-card-back::after {
  inset: 20px;
  border-color: rgba(212, 165, 116, 0.2);
}
.tirage-card-back .back-symbol {
  font-family: 'Tenor Sans', serif;
  font-size: 48px;
  color: var(--gold);
  letter-spacing: 0.1em;
  z-index: 1;
}
/* 3 cartes empilées effet de pile */
.tirage-card-back.stack-1 { transform: translate(-8px, -6px) rotate(-4deg); z-index: 1; opacity: 0.7; }
.tirage-card-back.stack-2 { transform: translate(0, 0) rotate(-1deg); z-index: 2; opacity: 0.85; }
.tirage-card-back.stack-3 { transform: translate(8px, 6px) rotate(3deg); z-index: 3; }
.tirage-deck:hover .tirage-card-back.stack-3:not(.flipping) {
  transform: translate(12px, -10px) rotate(5deg);
  box-shadow: 0 20px 50px rgba(212, 165, 116, 0.2);
}

@keyframes flip-card {
  0% { transform: translate(8px, 6px) rotate(3deg) scale(1) rotateY(0deg); opacity: 1; }
  40% { transform: translate(0, -40px) rotate(0) scale(1.1) rotateY(90deg); opacity: 1; }
  41% { opacity: 0; }
  100% { transform: translate(0, -40px) rotate(0) scale(1.1); opacity: 0; }
}
.tirage-card-back.flipping {
  animation: flip-card 0.9s forwards;
}

.tirage-result {
  display: none;
  text-align: center;
  animation: result-in 0.6s ease-out forwards;
  margin-top: 20px;
}
@keyframes result-in {
  from { opacity: 0; transform: translateY(20px); }
  to   { opacity: 1; transform: translateY(0); }
}
.tirage-result.shown { display: block; }
.tirage-card-img {
  width: 240px;
  margin: 0 auto 24px;
  display: block;
  border-radius: 12px;
  box-shadow: 0 20px 60px rgba(0,0,0,0.5);
}
.tirage-card-name {
  font-family: 'Tenor Sans', serif;
  font-size: 36px;
  color: var(--gold);
  font-style: italic;
  margin-bottom: 8px;
}
.tirage-card-phase {
  font-size: 11px;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: rgba(245, 239, 230, 0.6);
  margin-bottom: 20px;
}
.tirage-card-message {
  font-family: 'Tenor Sans', serif;
  font-size: 18px;
  line-height: 1.5;
  max-width: 560px;
  margin: 0 auto 24px;
  color: rgba(245, 239, 230, 0.85);
  font-style: italic;
}
.tirage-card-message::before { content: '« '; color: var(--gold); }
.tirage-card-message::after  { content: ' »'; color: var(--gold); }
.tirage-hint {
  margin-top: 24px;
  font-size: 13px;
  color: rgba(245, 239, 230, 0.5);
  font-style: italic;
}

/* Historique des derniers tirages */
.tirage-history {
  margin-top: 60px;
  padding-top: 40px;
  border-top: 1px solid var(--line-soft);
  text-align: center;
}
.tirage-history h3 {
  font-size: 11px;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 28px;
  font-family: 'Inter', sans-serif;
  font-weight: 400;
}
.tirage-history-list {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  justify-content: center;
  align-items: flex-start;
}
.tirage-history-item {
  width: 88px;
  text-align: center;
  opacity: 0.7;
  transition: opacity 0.3s, transform 0.3s;
}
.tirage-history-item:hover {
  opacity: 1;
  transform: translateY(-4px);
}
.tirage-history-item img {
  width: 88px;
  height: 128px;
  object-fit: cover;
  border-radius: 6px;
  border: 1px solid var(--line-soft);
  display: block;
  margin: 0 auto 10px;
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.3);
}
.tirage-history-meta {
  font-size: 11px;
}
.tirage-history-day {
  color: rgba(245, 239, 230, 0.5);
  letter-spacing: 0.05em;
  margin-bottom: 2px;
}
.tirage-history-name {
  color: var(--gold);
  font-family: 'Tenor Sans', serif;
  font-style: italic;
  font-size: 12px;
}
@media (max-width: 600px) {
  .tirage-history-item { width: 72px; }
  .tirage-history-item img { width: 72px; height: 104px; }
}

/* ---- Responsive ---- */
@media (max-width: 900px) {
  nav.main { padding: 16px 20px; }
  nav.main ul {
    display: none;
    position: fixed;
    top: 60px; left: 0; right: 0;
    background: rgba(11, 26, 46, 0.98);
    flex-direction: column;
    padding: 30px;
    gap: 20px;
    text-align: center;
  }
  nav.main ul.open { display: flex; }
  .nav-toggle { display: block; }
  section, .hero { padding: 80px 20px; }
  footer.main { padding: 50px 20px 20px; }
  footer.main .footer-grid { grid-template-columns: 1fr; gap: 40px; }
  .hero-actions { flex-direction: column; width: 100%; padding: 0 30px; }
  .hero-actions .btn { width: 100%; justify-content: center; }
  .hero-eyebrow { font-size: 10px; gap: 10px; }
  .hero-eyebrow::before, .hero-eyebrow::after { width: 20px; }
  .tirage-deck { height: 340px; }
  .tirage-card-back { width: 180px; height: 260px; }
  .tirage-card-img { width: 200px; }
}
