/* ==========================================================================
   FAIRE-PART MARIAGE COMPLET - RESPONSIVE & DYNAMIQUE (v3)
   Diecannis & Mathieu
   ========================================================================== */

/* 1. RESET & BASE
   ========================================================================== */
*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
}

body {
    width: 100%;
    min-height: 100vh;
    background-color: #f2efe9;
    font-family: 'Montserrat', sans-serif;
    color: #5d4524;
    display: flex;
    justify-content: center;
    align-items: flex-start;
    padding: 0;
}

/* 2. CONTENEUR CARTE PRINCIPALE
   ========================================================================== */
.card-wrapper, .hero-custom {
    width: 100%;
    max-width: 430px;
    min-height: 100vh;
    margin: 0 auto;
    background: #faf7f0 url('/images/fond_couple.png') no-repeat center top;
    background-size: 100% auto;
    position: relative;
    box-shadow: 0 10px 35px rgba(0, 0, 0, 0.12);
    display: flex;
    flex-direction: column;
}

/* 3. SECTION HERO (PAGE 1 / ACCUEIL)
   ========================================================================== */
.hero-section {
    min-height: 100vh;
	min-height: 100svh;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    align-items: center;
    position: relative;
}

.card-hero-spacer {
    width: 100%;
    height: 52vh;
    max-height: 430px;
    flex-shrink: 0;
}

/* Correctif pour les téléphones avec un écran long / étroit */
@media screen and (max-width: 480px) {
    .card-hero-spacer {
        height: 42vh; /* Remonte encore le texte sur smartphone */
    }
}


.card-bottom-content {
    width: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: space-between;
    flex-grow: 1;
    padding: 10px 15px 20px 15px;
    text-align: center;
}

.hero-welcome {
    font-family: 'Montserrat', sans-serif !important;
    font-size: clamp(0.68rem, 2.5vw, 0.82rem) !important;
    font-weight: 600 !important;
    //color: #5d4524 !important;
	//color: #a88342  !important;
	color:   #2D3A2D !important;
    line-height: 1.35 !important;
    letter-spacing: 0.5px;
    width: 90%;
    margin: 5px auto 15px auto !important;
    text-shadow: 0px 1px 2px rgba(255, 255, 255, 0.9);
}

.hero-welcome strong{
	color: #8C6D3B; /* Doré chaud/bronze plus foncé pour la date */
    font-weight: 700;
}

.guest-name {
    color: #a88342;
    font-weight: 600;
	text-transform: uppercase;

}

/* 4. BARRE DE NAVIGATION (FIXE / STICKY OU ACCUEIL)
   ========================================================================== */
.hero-nav-bar {
    width: 94% !important;
    max-width: 390px;
    background: rgba(255, 253, 248, 0.92) !important;
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border: 1.5px solid #d4af37 !important;
    border-radius: 30px !important;
    padding: 8px 10px !important;
    margin: 0 auto !important;
    box-shadow: 0 6px 20px rgba(93, 69, 36, 0.12) !important;
    
    display: flex !important;
    justify-content: space-around !important;
    align-items: center !important;
}

.hero-nav-item, .nav-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-decoration: none;
    color: #b38e46 !important;
    padding: 4px 6px;
    border-radius: 12px;
    transition: transform 0.2s ease, background 0.2s ease;
}

.hero-nav-item:active, .hero-nav-item:hover,
.nav-item:active, .nav-item:hover {
    transform: translateY(-2px);
    background: rgba(212, 175, 55, 0.12);
}

.hero-nav-item svg, .nav-item svg {
    width: 20px !important;
    height: 20px !important;
    stroke: #b38e46 !important;
    margin-bottom: 2px !important;
}

.hero-nav-item span, .nav-item span {
    font-family: 'Montserrat', sans-serif !important;
    font-size: 0.6rem !important;
    font-weight: 600 !important;
    color: #5d4524 !important;
    letter-spacing: 0.3px;
    text-transform: uppercase;
}

/* 5. SECTIONS DE CONTENU (PROGRAMME, RÉPONSE, CAGNOTTE, INFOS)
   ========================================================================== */
.section-block {
    width: 100%;
    padding: 35px 20px;
    background: rgba(255, 253, 248, 0.92);
    backdrop-filter: blur(6px);
    border-top: 1px solid rgba(212, 175, 55, 0.3);
    box-sizing: border-box;
}

.section-title {
    font-family: 'Great Vibes', 'Alex Brush', cursive;
    font-size: 2.2rem;
    color: #a88342;
    text-align: center;
    margin-bottom: 25px;
    font-weight: normal;
}

/* --- SECTION PROGRAMME (TIMELINE) --- */
.timeline {
    position: relative;
    padding-left: 20px;
    border-left: 2px solid #d4af37;
    margin: 0 10px;
}

.timeline-item {
    position: relative;
    margin-bottom: 25px;
}

.timeline-item::before {
    content: '';
    position: absolute;
    left: -26px;
    top: 4px;
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: #d4af37;
    border: 2px solid #fff;
}

.timeline-time {
    font-size: 0.75rem;
    font-weight: 700;
    color: #a88342;
    letter-spacing: 1px;
}

.timeline-title {
    font-size: 0.95rem;
    font-weight: 600;
    color: #5d4524;
    margin: 2px 0 4px 0;
}

.timeline-desc {
    font-size: 0.8rem;
    color: #7a6240;
    line-height: 1.3;
}

/* --- SECTION FORMULAIRE RÉPONSE (RSVP) --- */
.rsvp-form {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.form-group {
    display: flex;
    flex-direction: column;
    text-align: left;
}

.form-group label {
    font-size: 0.75rem;
    font-weight: 600;
    color: #5d4524;
    margin-bottom: 5px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.form-group input, 
.form-group select, 
.form-group textarea {
    width: 100%;
    padding: 10px 12px;
    border: 1px solid #d4af37;
    border-radius: 10px;
    background: #fff;
    font-family: 'Montserrat', sans-serif;
    font-size: 0.85rem;
    color: #333;
    outline: none;
}

.form-group input:focus, 
.form-group select:focus, 
.form-group textarea:focus {
    border-color: #a88342;
    box-shadow: 0 0 5px rgba(168, 131, 66, 0.3);
}

.radio-group {
    display: flex;
    gap: 15px;
    margin-top: 5px;
}

.radio-label {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 0.8rem;
    cursor: pointer;
}

.btn-submit {
    width: 100%;
    padding: 12px;
    background: #d4af37;
    color: #fff;
    border: none;
    border-radius: 25px;
    font-family: 'Montserrat', sans-serif;
    font-size: 0.85rem;
    font-weight: 600;
    letter-spacing: 1px;
    text-transform: uppercase;
    cursor: pointer;
    box-shadow: 0 4px 12px rgba(212, 175, 55, 0.3);
    transition: background 0.2s ease;
    margin-top: 10px;
}

.btn-submit:hover {
    background: #b38e46;
}

/* --- SECTION CAGNOTTE --- */
.cagnotte-card {
    background: #fff;
    border: 1px solid #e2d3b2;
    border-radius: 15px;
    padding: 20px;
    text-align: center;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.03);
}

.cagnotte-text {
    font-size: 0.85rem;
    line-height: 1.5;
    color: #6e5532;
    margin-bottom: 15px;
}

.btn-cagnotte {
    display: inline-block;
    padding: 10px 20px;
    background: #a88342;
    color: #fff;
    text-decoration: none;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 600;
    letter-spacing: 0.5px;
}

/* --- SECTION INFOS PRATIQUES --- */
.info-item {
    margin-bottom: 18px;
    text-align: left;
}

.info-item h4 {
    font-size: 0.85rem;
    color: #a88342;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 4px;
}

.info-item p {
    font-size: 0.8rem;
    color: #5d4524;
    line-height: 1.4;
}


/* Style du conteneur de liste */
ul.hotel-list {
  list-style: none;
  padding-left: 0;
  margin-top: 15px;
}

/* Style de chaque élément */
ul.hotel-list li {
  margin-bottom: 10px;
}

/* Style des liens */
ul.hotel-list a {
  color: #a37d3f; /* Couleur dorée/marron comme ton titre */
  text-decoration: none;
  font-weight: 500;
  transition: color 0.2s ease, padding-left 0.2s ease;
}

/* Effet au survol (Hover) */
ul.hotel-list a:hover {
  color: #7a5a27;
  padding-left: 5px; /* Décale légèrement le texte vers la droite */
  text-decoration: underline;
}


/* Style de l'élément déclencheur */
.tooltip {
  position: relative;
  display: inline-block;
  cursor: pointer;
  color: #a37d3f; /* Utilise la couleur dorée de tes titres */
  font-weight: bold;
  margin-left: 4px;
}

/* Masquer la bulle par défaut */
.tooltip::after {
  content: attr(data-info);
  position: absolute;
  bottom: 130%;
  left: 50%;
  transform: translateX(-50%);
  background-color: #333333;
  color: #ffffff;
  padding: 8px 12px;
  border-radius: 6px;
  font-size: 0.6rem;
  font-weight: normal;
  
  /* --- Ajustements responsives --- */
  white-space: normal;        /* Autorise le retour à la ligne */
  width: max-content;         /* S'adapte aux textes courts */
  max-width: 75vw;            /* La bulle ne dépassera jamais 75% de l'écran */
  word-wrap: break-word;      /* Coupe les mots très longs si nécessaire */
  box-sizing: border-box;
  text-align: center;
  
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.2s ease, transform 0.2s ease;
  z-index: 10;
}

/* Petite flèche sous la bulle */
.tooltip::before {
  content: "";
  position: absolute;
  bottom: 110%;
  left: 50%;
  transform: translateX(-50%);
  border-width: 5px;
  border-style: solid;
  border-color: #333333 transparent transparent transparent;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.2s ease;
  z-index: 10;
}

/* Affichage au survol ou au clic sur mobile */
.tooltip:hover::after,
.tooltip:hover::before {
  opacity: 1;
  visibility: visible;
}

/* --- FOOTER --- */
.footer-text {
    text-align: center;
    padding: 20px;
    font-size: 0.7rem;
    color: #93733b;
    border-top: 1px solid rgba(212, 175, 55, 0.2);
}


/* ==========================================================================
   ADAPTATION GRAND ÉCRAN (PC / TABLETTE)
   ========================================================================== */
@media screen and (max-height: 750px) {
    .hero-section {
        min-height: 100vh;
        min-height: 100svh;
        padding-bottom: 20px;
    }
    
    /* Réduit légèrement le texte sur mobile pour libérer de l'espace vertical */
    .hero-welcome {
        font-size: 0.75rem !important;
		color: #6e5532;
        padding: 0 15px;
    }
}

/* =========================================================
   CORRECTIF ALIGNEMENT IPHONE / IOS (Safari & Chrome iOS)
   ========================================================= */
@supports (-webkit-touch-callout: none) {

  /* 1. Conteneur principal : aligne les blocs verticalement */
  .radio-group,
  fieldset {
    display: flex !important;
    flex-direction: column !important;
    align-items: flex-start !important;
    gap: 14px !important;
    width: 100% !important;
  }

  /* 2. Le label reserve au moins 40px d'espace a gauche pour la puce */
  .radio-label {
    position: relative !important;
    display: flex !important;
    align-items: center !important;
    padding-left: 40px !important; /* <--- DECALE TOUT LE TEXTE DE 40PX A DROITE */
    min-height: 28px !important;    /* Assure une hauteur suffisante pour la puce */
    width: auto !important;
    text-align: left !important;
    cursor: pointer !important;
  }

  /* 3. La puce est verrouillee tout a gauche dans l'espace reserve */
  .radio-label input[type="radio"] {
    position: absolute !important;
    left: 0 !important;
    top: 50% !important;
    transform: translateY(-50%) !important;
    margin: 0 !important;
    width: 22px !important;        /* Fixe la taille de la puce si besoin */
    height: 22px !important;
    flex-shrink: 0 !important;
  }

  /* 4. On s'assure qu'aucun sous-element ne remet de marge negative */
  .radio-label * {
    margin-left: 0 !important;
  }

}