/*
Theme Name: twentytwentythree-child
Theme URI: https://alti-mag.com/
Author: Aurelien Antoine
Author URI: https://www.alti-mag.com.com/
Description: Alti-Mag child theme for TT3.
Requires at least: 5.8
Tested up to: 5.9
Requires PHP: 5.6
Version: 0.1
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: twentytwentythree-child
Template: twentytwentythree
Tags: one-column, custom-colors, custom-menu, custom-logo, editor-style, featured-images, full-site-editing, block-patterns, rtl-language-support, sticky-post, threaded-comments

Twenty Twenty-Three Child WordPress Theme, (C) 2023 WordPress.org
Twenty Twenty-Three Child is distributed under the terms of the GNU GPL.
*/

.site-title {
    font-size: 52px;
    font-size: 3.4666666666667rem;
    font-family: "Oswald", sans-serif;
    font-weight: 700;
    color: #3a3a3a;
}
.ast-site-title-wrap {
    text-align: center;
}
figcaption {
    font-style: italic;
    font-size: 80%;
}

/* ================================================
   Moteur de recherche déporté (LVE / Ski Express)
   ================================================ */

/* Conteneur principal */
.moteur {
    background-color: #285E81;
    border-radius: 0.6em;
    padding: 1.2em 1em 1em;
}

/* Supprimer le style natif du fieldset */
#moteur fieldset {
    border: none;
    margin: 0;
    padding: 0;
}

/* Titre h2 généré par le moteur distant — caché */
.moteur h2,
.tiroir_moteur h2 {
    display: none;
}

/* Titre du moteur (h4 dans .tiroir_moteur) */
.tiroir_moteur {
    margin-bottom: 0.6em;
}

.tiroir_moteur h4 {
    color: #fff;
    font-size: 1.3em;
    font-weight: 600;
    margin: 0;
    padding: 0 0 0.4em 0;
    cursor: default;
}

/* Labels accessibilité — masqués visuellement */
#moteur form .acces {
    display: none;
}

/* Espacement entre les blocs de champs */
#moteur .label {
    padding-bottom: 0.7em;
}

/* Selects */
.champform {
    width: 100%;
    border: none;
    border-radius: 0.35em;
    padding: 0.65em 0.8em;
    background-color: #fff;
    color: #222;
    font-size: 0.95em;
    appearance: auto;
    box-sizing: border-box;
}

.champform:focus {
    outline: 2px solid #1596ea;
    outline-offset: 1px;
}

/* Bouton Rechercher — cible .valider (classe réelle du moteur) */
#moteur .valider {
    padding-top: 0.4em;
}

#moteur .valider button {
    display: block;
    width: 100%;
    border: none;
    border-radius: 0.35em;
    padding: 0.75em 1em;
    background-color: #1a1a2e;
    color: #fff;
    font-size: 1em;
    font-weight: 600;
    letter-spacing: 0.03em;
    cursor: pointer;
    transition: background-color 0.2s ease;
}

#moteur .valider button:hover {
    background-color: #1596ea;
}

/* Le <a> à l'intérieur du bouton */
#moteur .valider button a,
#moteur .valider button span,
#moteur .valider button a:hover {
    color: inherit;
    text-decoration: none;
    pointer-events: none;
}

.guide-activite {
    border: 1px solid #CCC;
    padding: 1em;
    border-radius: 0.5em;
    margin: 1em 0 1em 0;
}

.wp-block-latest-posts__post-title {
    font-size: 1.2em;
    font-weight: 600;
    line-height: 0.8em;
}

.wp-block-latest-posts__featured-image {
    margin-bottom: 20px;
}

.container {
    position: relative;
    overflow: hidden;
    width: 100%;
    padding-top: 56.25%; /* 16:9 Aspect Ratio (divide 9 by 16 = 0.5625) */
}

.responsive-iframe {
    position: absolute;
    top: 0;
    left: 0;
    bottom: 0;
    right: 0;
    width: 100%;
    height: 100%;
}

.subalti {
    margin: 0.5em;
}

.wp-element-button:hover, .wp-block-button__link:hover, wp-button__link:visited {
    background-color: #1596ea;
    color: #FFFFFF;
    text-decoration: none;
}

.wp-element-button:visited,
.wp-block-button__link:visited {
    color: #fff;
    text-decoration: none;
}

.tw-link-no-underline a,
.tw-link-no-underline a:hover {
    text-decoration: none !important;
}

/* --- MENU MOBILE : SOLUTION GRID (ALIGNEMENT PARFAIT) --- */
@media (max-width: 599px) {

    /* 1. RESET GLOBAL (Pour avoir toute la largeur) */
    .wp-block-navigation__responsive-container .wp-block-navigation__container,
    .wp-block-navigation__responsive-container ul.wp-block-navigation {
        display: block !important;      /* On désactive le flex global */
        width: 100% !important;
        margin: 0 !important;
        padding: 0 !important;
        gap: 0 !important;
    }

    /* 2. LA LIGNE (LI) : ON CRÉE UNE GRILLE */
    /* C'est ici la magie : on définit 2 colonnes. 
       - 1fr = le reste de la place pour le texte 
       - 44px = place fixe pour le bouton */
    .wp-block-navigation__responsive-container .wp-block-navigation-item {
        display: grid !important;
        grid-template-columns: 1fr 44px !important; /* COLONNE 1 | COLONNE 2 */
        width: 100% !important;
        align-items: center !important;
        border-bottom: 1px solid rgba(0,0,0,0.05); /* Ligne de séparation */
        margin: 0 !important;
        padding: 0 !important;
    }

    /* 3. LE TEXTE (LIEN) -> COLONNE 1 */
    .wp-block-navigation__responsive-container .wp-block-navigation-item > a {
        grid-column: 1 / 2 !important; /* Force la position gauche */
        width: 100% !important;
        max-width: 100% !important;
        text-align: left !important;   /* FORCE L'ALIGNEMENT À GAUCHE (contredit le centrage actuel) */
        padding: 15px 0 !important;
        margin: 0 !important;
    }

    /* 4. LE BOUTON -> COLONNE 2 */
    .wp-block-navigation__submenu-icon,
    .wp-block-navigation-submenu__toggle,
    button.wp-block-navigation__submenu-toggle {
        grid-column: 2 / 3 !important; /* Force la position droite */
        width: 20px !important;
        height: 20px !important;
        
        display: flex !important;
        align-items: center !important;
        justify-content: center !important;
        
        background: transparent !important;
        border: none !important;
        margin: 0 !important;
        padding: 0 !important;
    }

    /* 5. LE SVG (ICÔNE) */
    button.wp-block-navigation__submenu-toggle svg {
        width: 12px !important;
        height: 12px !important;
        /* On empêche l'icône de s'étirer */
        min-width: 12px !important;
        max-width: 12px !important;
        fill: currentColor !important;
    }

    /* 6. LE SOUS-MENU (ACCORDÉON) -> PREND TOUTE LA LARGEUR DESSOUS */
    .wp-block-navigation__responsive-container .wp-block-navigation__submenu-container {
        grid-column: 1 / -1 !important; /* S'étale sur les 2 colonnes */
        width: 100% !important;
        display: none !important;
        padding-left: 20px !important;
		padding-right: 0px !important;
        background-color: rgba(0,0,0,0.02);
        border-top: 1px solid rgba(0,0,0,0.05);
        margin: 0 !important;
    }

    /* 7. OUVERTURE */
    button[aria-expanded="true"] + .wp-block-navigation__submenu-container,
    button[aria-expanded="true"] ~ .wp-block-navigation__submenu-container {
        display: block !important;
    }
}

/* annonce sticky  */

.banner-no-underline a {
    text-decoration: none;
}

.banner-no-underline a:hover {
    text-decoration: none;
}

.map-container {
    position: relative;
    width: 100%;
    padding-bottom: 56.25%; /* Ratio 16:9 (9/16 = 0.5625) */
    height: 0;
    overflow: hidden;
  }

.map-container iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border: 0;
  }

.index-neg{
    z-index: 9;
}

/* Assurez-vous que les annonces ne dépassent pas 100% de la largeur de l'écran */
.ad-slot {
  max-width: 100%;
  height: auto; /* Maintient le ratio hauteur/largeur */
  margin: 0 auto; /* Centre la bannière */
}

@media (max-width: 768px) {
  .ad-slot {
    width: 100%; /* La bannière occupe 100% de la largeur de l'écran sur les petits appareils */
  }
}

.webcam-iframe {
  position: relative;
  width: 100%; 
  max-width: 100%;
  aspect-ratio: 16 / 9 !important; /* Applique directement le ratio 16:9 */
  overflow: hidden;
  display: flex;
  justify-content: center; /* Centre l’iframe */
  align-items: center;
}

.webcam-iframe iframe {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  border: none;
  display: block;
}

/* Contourne les styles injectés par WordPress */
.wp-block-group.webcam-iframe {
  height: auto !important;
  min-height: unset !important;
}

.extlink { 
  background-image: url(https://www.alti-mag.com/wp-content/uploads/2024/09/external-link.svg);
  background-position: top right;
  background-repeat: no-repeat;
  background-size: 0.8em;
  padding-right: 1em;
}

/* Masquer la flèche sur les boutons, images et liens sociaux */
.wp-block-button__link.extlink sup:after,
.wp-block-button__link.extlink:after,
.wp-block-image .extlink sup:after,
.wp-block-image .extlink:after,
.wp-block-social-link-anchor.extlink sup:after,
.wp-block-social-link-anchor.extlink:after,
.wp-block-button__link.extlink:hover sup:after,
.wp-block-image .extlink:hover sup:after {
    content: '' !important;
}

/* Formulaire 7 */
.wpcf7 input[type="text"],
.wpcf7 input[type="email"],
.wpcf7 textarea
{
    background-color: #fff;
    color: #000;
    width: 100%;
font-size: var(--wp--preset--font-size--medium);
  font-style: normal;
  font-weight: 300;
  line-height: 1.6;
}

.wpcf7 input[type="submit"]
{
border-radius: 5px;
background-color: var(--wp--preset--color--blue);
border-width: 0;
color: var(--wp--preset--color--blanc);
font-family: inherit;
font-size: inherit;
line-height: inherit;
padding-top: 0.2em;
  padding-right: var(--wp--preset--spacing--40);
  padding-bottom: 0.2em;
  padding-left: var(--wp--preset--spacing--40);
}

.columns-3.wp-block-post-template {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 1.5rem;
}

.menu-sticky {
    z-index: 1001;
}