/* YoopixX Core v0.7.111 — visually scoped fixes for Vikinger 1.9.30.
   Page title: only pages tagged by visual_page_body_class().
   Event editor: same selectors for standalone [yoopixx_event_form] and the .yx-app view. */
body.yx-hide-duplicate-page-title .page-open > .page-open-title,
body.yx-hide-duplicate-page-title .vikinger-pmpro-page-wrap > .vikinger-pmpro-page-title {
  display:none !important;
}
body.yx-hide-duplicate-page-title .page-open {
  padding-top:0 !important;
}
body.yx-hide-duplicate-page-title .page-open > .page-open-content {
  margin-top:14px !important;
}

/* On the standalone form, there is no .yx-app ancestor, so the older
   .yx-app .yx-form rules never matched. Limit these corrections to
   our event title and description fields. */
body .yx-form .yx-inline-edit {
  display:grid !important;
  grid-template-columns:minmax(0,1fr) 48px !important;
  align-items:center !important;
  gap:10px !important;
  width:100% !important;
  min-width:0 !important;
  position:relative !important;
}
body .yx-form .yx-inline-edit > input#yx-title {
  display:block !important;
  width:100% !important;
  min-width:0 !important;
  max-width:100% !important;
  height:50px !important;
  box-sizing:border-box !important;
  flex:initial !important;
}
body .yx-form .yx-inline-edit > .yx-emoji-toggle {
  display:inline-flex !important;
  justify-content:center !important;
  align-items:center !important;
  width:48px !important;
  min-width:48px !important;
  max-width:48px !important;
  height:48px !important;
  min-height:48px !important;
  padding:0 !important;
  margin:0 !important;
  flex:none !important;
}
body .yx-form .yx-editor-toolbar {
  display:grid !important;
  grid-template-columns:repeat(4,minmax(0,1fr)) !important;
  gap:8px !important;
  align-items:center !important;
  position:relative !important;
  width:100% !important;
  min-width:0 !important;
}
body .yx-form .yx-editor-toolbar > button {
  display:inline-flex !important;
  justify-content:center !important;
  align-items:center !important;
  width:100% !important;
  min-width:0 !important;
  max-width:100% !important;
  height:40px !important;
  min-height:40px !important;
  padding:4px 8px !important;
  margin:0 !important;
  line-height:1 !important;
  flex:none !important;
}
body .yx-form .yx-inline-edit > .yx-emoji-palette,
body .yx-form .yx-editor-toolbar > .yx-emoji-palette {
  position:absolute !important;
  display:grid !important;
  grid-template-columns:repeat(5,minmax(0,1fr)) !important;
  gap:5px !important;
  z-index:1000 !important;
  right:0 !important;
  left:auto !important;
  top:calc(100% + 8px) !important;
  width:242px !important;
  min-width:0 !important;
  max-width:min(242px,100%) !important;
  max-height:220px !important;
  overflow:auto !important;
  padding:10px !important;
  margin:0 !important;
  background:#fff !important;
  border:1px solid #e1d9ff !important;
  border-radius:12px !important;
  box-sizing:border-box !important;
  box-shadow:0 8px 22px rgba(36,30,66,.12) !important;
}
body .yx-form .yx-inline-edit > .yx-emoji-palette > button,
body .yx-form .yx-editor-toolbar > .yx-emoji-palette > button {
  display:flex !important;
  align-items:center !important;
  justify-content:center !important;
  width:100% !important;
  min-width:0 !important;
  max-width:100% !important;
  height:35px !important;
  min-height:35px !important;
  padding:0 !important;
  margin:0 !important;
  border-radius:8px !important;
  flex:none !important;
}
body .yx-form .yx-rich-editor {
  display:block !important;
  width:100% !important;
  max-width:100% !important;
  min-width:0 !important;
  min-height:180px !important;
  box-sizing:border-box !important;
  white-space:normal !important;
}
@media(max-width:420px) {
  body .yx-form .yx-inline-edit {
    grid-template-columns:minmax(0,1fr) 44px !important;
    gap:6px !important;
  }
  body .yx-form .yx-inline-edit > .yx-emoji-toggle {
    width:44px !important;
    min-width:44px !important;
    max-width:44px !important;
  }
  body .yx-form .yx-inline-edit > .yx-emoji-palette,
  body .yx-form .yx-editor-toolbar > .yx-emoji-palette {width:218px !important;}
}


/* v0.7.112: standalone event publication button. The .yx-app-scoped
   --yx-accent variable was previously missing outside the dashboard. */
body .yx-form.yx-surface {
  --yx-accent:#6d55e8;
  --yx-ink:#272b43;
  --yx-sub:#777b96;
  --yx-line:#e8e8f3;
}
body .yx-form.yx-surface .yx-form-footer > button.yx-btn.yx-btn-primary[type="submit"] {
  display:inline-flex !important;
  position:relative !important;
  flex:0 0 auto !important;
  width:auto !important;
  min-width:190px !important;
  max-width:100% !important;
  height:auto !important;
  min-height:46px !important;
  padding:12px 22px !important;
  margin:0 !important;
  background:#6d55e8 !important;
  background-image:none !important;
  color:#fff !important;
  opacity:1 !important;
  visibility:visible !important;
  font-size:14px !important;
  font-weight:800 !important;
  line-height:1.35 !important;
  text-align:center !important;
  border:1px solid #6d55e8 !important;
  border-radius:11px !important;
  box-shadow:0 4px 12px rgba(109,85,232,.2) !important;
}
body .yx-form.yx-surface .yx-form-footer > button.yx-btn.yx-btn-primary[type="submit"]:hover,
body .yx-form.yx-surface .yx-form-footer > button.yx-btn.yx-btn-primary[type="submit"]:focus-visible {
  background:#5540ce !important;
  border-color:#5540ce !important;
}
@media(max-width:700px) {
  body .yx-form.yx-surface .yx-form-footer > button.yx-btn.yx-btn-primary[type="submit"] {
    width:100% !important;
    min-width:0 !important;
  }
}

/* Small decorative emblem, limited to the five explicitly requested page
   banners. No duplicated text and no changes to other headings. */
body.yx-page-icon-events .yx-events-hero h2::before,
body.yx-page-icon-mes-evenements .yx-hero:not(.yx-events-hero) h2::before,
body.yx-page-icon-mes-albums .yx-albums-hero h2::before,
body.yx-page-icon-petites-annonces .yx-ads-hero h2::before,
body.yx-page-icon-sondages .yx-polls-hero h2::before {
  display:inline-flex !important;
  align-items:center !important;
  justify-content:center !important;
  vertical-align:middle !important;
  width:1.65em !important;
  height:1.65em !important;
  flex:0 0 auto !important;
  margin:0 .38em .12em 0 !important;
  background:rgba(255,255,255,.15) !important;
  border:1px solid rgba(255,255,255,.24) !important;
  border-radius:12px !important;
  font-size:.68em !important;
  line-height:1 !important;
  box-shadow:0 3px 12px rgba(38,25,89,.08) !important;
}
body.yx-page-icon-events .yx-events-hero h2::before{content:"📅" !important}
body.yx-page-icon-mes-evenements .yx-hero:not(.yx-events-hero) h2::before{content:"🗓️" !important}
body.yx-page-icon-mes-albums .yx-albums-hero h2::before{content:"🖼️" !important}
body.yx-page-icon-petites-annonces .yx-ads-hero h2::before{content:"📣" !important}
body.yx-page-icon-sondages .yx-polls-hero h2::before{content:"📊" !important}

/* Vikinger 1.9.30: annuaires Membres / Groupes.
   IconSVG utilise un SVG avec <use href="#svg-magnifying-glass">.
   Le theme impose fill:#fff a .icon-magnifying-glass.
   Remplacer exclusivement la couleur de l'icone : aucune regle de boite.
   Selecteurs fondes sur les champs natifs des deux filtres React. */
#member-name ~ button svg.icon-magnifying-glass,
#group-name ~ button svg.icon-magnifying-glass {
  fill: #7651b8 !important;
}


/* YoopixX Lives: camera silhouette ONLY for the Lives navigation link.
   Unlike Vikinger's videos filmstrip, the camera is an independent SVG mask. */
a.menu-item-link[href*="/lives/"]{position:relative}
a.menu-item-link[href*="/lives/"] > svg.menu-item-link-icon{visibility:hidden!important}
a.menu-item-link[href*="/lives/"]::before{
  content:"";position:absolute;top:50%;left:50%;transform:translate(-50%,-50%);
  width:25px;height:25px;background:#a9aecb;
  -webkit-mask:url('yx-live-camera.svg') center / contain no-repeat;
  mask:url('yx-live-camera.svg') center / contain no-repeat;
  pointer-events:none
}
a.menu-item-link[href*="/lives/"]:hover::before,
.menu-item.active > a.menu-item-link[href*="/lives/"]::before{background:#7651b8}
/* Lives navigation: use exactly the same native menu spacing as other entries.
   The SVG is masked with our camera silhouette; only its paint is replaced. */
a.menu-item-link[href*="/lives/"]::before {
  top:14px!important;
  left:14px!important;
  transform:none!important;
}
@media(max-width:960px){
  .menu .menu-item a.menu-item-link[href*="/lives/"] {
    display:flex!important;
    align-items:center!important;
    justify-content:flex-start!important;
    padding-left:62px!important;
    height:48px!important;
    min-height:48px!important;
  }
  .menu .menu-item a.menu-item-link[href*="/lives/"]:hover,
  .menu .menu-item a.menu-item-link[href*="/lives/"]:focus {
    padding-left:70px!important;
  }
}

/* Profile Lives: use Vikinger's native section-menu-item hover states.
   No pseudo icon or forced visibility: the theme swaps label and SVG itself. */
.section-navigation .section-menu-item > svg.icon-yx-live-camera.section-menu-item-icon {
  width: 26px; height: 26px;
}
