/*
Theme Name: HAAL Events
Theme URI: https://haal.mx
Author: HAAL
Description: Tema para haal.mx y haal.com.mx. Landing con enlaces a redes sociales (Instagram y Facebook), botón flotante de WhatsApp, y galería de eventos administrable desde WordPress (tipo de contenido "Eventos").
Version: 1.0.0
Requires at least: 6.0
Requires PHP: 7.4
Text Domain: haal
*/

/* ==========================================================================
   Variables y reset
   ========================================================================== */
:root{
  --haal-bg: #0b0b0c;
  --haal-bg-alt: #141416;
  --haal-fg: #f5f3ee;
  --haal-fg-muted: #b9b6ae;
  --haal-gold: #c9a24b;
  --haal-gold-soft: #e6cf95;
  --haal-line: rgba(245,243,238,0.12);
  --haal-radius: 14px;
  --haal-max: 1180px;
  --haal-ig: #d6284a;
  --haal-fb: #1877f2;
  --haal-wa: #25d366;
}

*, *::before, *::after{ box-sizing: border-box; }

html{ scroll-behavior: smooth; }

body{
  margin:0;
  background: var(--haal-bg);
  color: var(--haal-fg);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
}

img{ max-width:100%; display:block; }

a{ color: inherit; text-decoration: none; }

.haal-container{
  max-width: var(--haal-max);
  margin: 0 auto;
  padding: 0 24px;
}

h1,h2,h3{
  font-family: Georgia, 'Times New Roman', serif;
  letter-spacing: .01em;
  margin: 0 0 .4em;
}

.haal-eyebrow{
  text-transform: uppercase;
  letter-spacing: .22em;
  font-size: .72rem;
  color: var(--haal-gold);
  font-weight: 600;
}

/* ==========================================================================
   Header
   ========================================================================== */
.haal-header{
  position: sticky;
  top:0;
  z-index: 40;
  background: rgba(11,11,12,0.86);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--haal-line);
}
.haal-header-inner{
  display:flex;
  align-items:center;
  justify-content: space-between;
  padding: 16px 24px;
}
.haal-logo{
  font-family: Georgia, serif;
  font-size: 1.3rem;
  letter-spacing: .06em;
  font-weight: 700;
  color: var(--haal-fg);
}
.haal-logo img{ max-height: 44px; width:auto; }
.haal-nav ul{
  list-style:none;
  display:flex;
  gap: 28px;
  margin:0; padding:0;
}
.haal-nav a{
  font-size:.92rem;
  color: var(--haal-fg-muted);
  transition: color .2s ease;
}
.haal-nav a:hover{ color: var(--haal-gold-soft); }

.haal-header-social{ display:flex; align-items:center; gap:14px; }
.haal-icon-btn{
  width:38px; height:38px;
  border-radius:50%;
  display:flex; align-items:center; justify-content:center;
  border:1px solid var(--haal-line);
  color: var(--haal-fg);
  transition: transform .2s ease, border-color .2s ease, background .2s ease;
}
.haal-icon-btn:hover{ transform: translateY(-2px); border-color: var(--haal-gold); }
.haal-icon-btn svg{ width:18px; height:18px; fill:currentColor; }

.haal-menu-toggle{
  display:none;
  background:none; border:none; color:var(--haal-fg);
  font-size:1.6rem; cursor:pointer;
}

@media (max-width: 780px){
  .haal-nav{
    position:absolute; top:100%; left:0; right:0;
    background: var(--haal-bg-alt);
    border-bottom: 1px solid var(--haal-line);
    display:none;
  }
  .haal-nav.is-open{ display:block; }
  .haal-nav ul{ flex-direction:column; gap:0; padding: 8px 24px 18px; }
  .haal-nav li{ border-top: 1px solid var(--haal-line); }
  .haal-nav a{ display:block; padding: 14px 0; }
  .haal-menu-toggle{ display:block; }
}

/* ==========================================================================
   Hero
   ========================================================================== */
.haal-hero{
  position:relative;
  min-height: 78vh;
  display:flex; align-items:center;
  overflow:hidden;
  background: radial-gradient(1200px 600px at 50% -10%, rgba(201,162,75,0.18), transparent 60%), var(--haal-bg);
}
.haal-hero-media{
  position:absolute; inset:0;
  background-size: cover; background-position:center;
  opacity:.32;
}
.haal-hero-media::after{
  content:"";
  position:absolute; inset:0;
  background: linear-gradient(180deg, rgba(11,11,12,.55), rgba(11,11,12,.92));
}
.haal-hero-content{
  position:relative; z-index:2;
  max-width: 720px;
  padding: 0 24px;
  margin: 0 auto;
  text-align:center;
}
.haal-hero-content h1{
  font-size: clamp(2.2rem, 5vw, 3.6rem);
  color: var(--haal-fg);
}
.haal-hero-content p{
  color: var(--haal-fg-muted);
  font-size: 1.08rem;
  max-width: 560px;
  margin: 0 auto 30px;
}
.haal-hero-ctas{
  display:flex; flex-wrap:wrap; gap:14px; justify-content:center;
  margin-top: 8px;
}

.haal-btn{
  display:inline-flex; align-items:center; gap:10px;
  padding: 14px 26px;
  border-radius: 999px;
  font-size: .95rem; font-weight:600;
  border: 1px solid transparent;
  transition: transform .2s ease, box-shadow .2s ease, opacity .2s ease;
}
.haal-btn:hover{ transform: translateY(-2px); }
.haal-btn svg{ width:19px; height:19px; fill:currentColor; }

.haal-btn-primary{
  background: linear-gradient(135deg, var(--haal-gold), var(--haal-gold-soft));
  color: #17140c;
  box-shadow: 0 10px 30px -12px rgba(201,162,75,.65);
}
.haal-btn-outline{
  border-color: var(--haal-line);
  color: var(--haal-fg);
  background: rgba(255,255,255,0.03);
}
.haal-btn-outline:hover{ border-color: var(--haal-gold); }

.haal-btn-instagram{ background: linear-gradient(135deg,#feda75,#d62976,#962fbf); color:#fff; }
.haal-btn-facebook{ background: var(--haal-fb); color:#fff; }
.haal-btn-whatsapp{ background: var(--haal-wa); color:#08210f; }

.haal-hero-secondary-links{
  margin-top: 22px;
  display:flex; gap:10px; justify-content:center; flex-wrap:wrap;
}
.haal-chip{
  display:inline-flex; align-items:center; gap:8px;
  padding: 8px 16px;
  border-radius: 999px;
  border: 1px solid var(--haal-line);
  font-size: .82rem;
  color: var(--haal-fg-muted);
}
.haal-chip:hover{ color: var(--haal-fg); border-color: var(--haal-gold); }
.haal-chip svg{ width:14px; height:14px; fill:currentColor; }

/* ==========================================================================
   Secciones generales
   ========================================================================== */
.haal-section{ padding: 84px 0; }
.haal-section-alt{ background: var(--haal-bg-alt); }
.haal-section-head{ text-align:center; max-width:640px; margin: 0 auto 48px; }
.haal-section-head p{ color: var(--haal-fg-muted); }

/* Galería de eventos */
.haal-grid{
  display:grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 22px;
}
@media (max-width: 900px){ .haal-grid{ grid-template-columns: repeat(2,1fr); } }
@media (max-width: 600px){ .haal-grid{ grid-template-columns: 1fr; } }

.haal-card{
  position:relative;
  border-radius: var(--haal-radius);
  overflow:hidden;
  aspect-ratio: 4/5;
  background: #1c1c1f;
  display:block;
}
.haal-card img{
  width:100%; height:100%; object-fit:cover;
  transition: transform .5s ease;
}
.haal-card:hover img{ transform: scale(1.06); }
.haal-card-overlay{
  position:absolute; inset:0;
  background: linear-gradient(180deg, transparent 40%, rgba(0,0,0,.85) 100%);
  display:flex; align-items:flex-end;
  padding: 20px;
}
.haal-card-overlay .haal-eyebrow{ display:block; margin-bottom:6px; }
.haal-card-title{ font-size:1.05rem; color:#fff; margin:0; }

.haal-empty-state{
  text-align:center;
  color: var(--haal-fg-muted);
  border: 1px dashed var(--haal-line);
  border-radius: var(--haal-radius);
  padding: 48px 24px;
}

.haal-cta-more{ text-align:center; margin-top: 40px; }

/* Single evento */
.haal-single-evento{ padding: 60px 0 100px; }
.haal-single-evento .haal-eyebrow{ display:block; margin-bottom: 10px; }
.haal-single-evento h1{ font-size: clamp(1.8rem, 4vw, 2.6rem); }
.haal-single-evento-meta{ color: var(--haal-fg-muted); margin-bottom: 30px; }
.haal-single-evento-cover{ border-radius: var(--haal-radius); overflow:hidden; margin-bottom: 40px; }
.haal-single-evento .entry-content { color: var(--haal-fg-muted); }
.haal-single-evento .entry-content .wp-block-gallery,
.haal-single-evento .entry-content figure.wp-block-image{ margin: 0 0 24px; }
.haal-single-evento .entry-content img{ border-radius: 10px; }
.haal-back-link{ display:inline-block; margin-bottom: 30px; color: var(--haal-gold); }

/* Redes / contacto footer */
.haal-social-band{
  display:flex; flex-wrap:wrap; gap:16px; justify-content:center;
}

/* Footer */
.haal-footer{
  border-top: 1px solid var(--haal-line);
  padding: 50px 0 34px;
  color: var(--haal-fg-muted);
  font-size: .88rem;
}
.haal-footer-top{
  display:flex; flex-wrap:wrap; gap:24px;
  justify-content:space-between; align-items:center;
  margin-bottom: 26px;
}
.haal-footer-bottom{
  border-top: 1px solid var(--haal-line);
  padding-top: 20px;
  display:flex; flex-wrap:wrap; gap:10px;
  justify-content:space-between;
}

/* Botón flotante de WhatsApp */
.haal-whatsapp-float{
  position: fixed;
  right: 20px; bottom: 20px;
  z-index: 60;
  width: 60px; height:60px;
  border-radius: 50%;
  background: var(--haal-wa);
  display:flex; align-items:center; justify-content:center;
  box-shadow: 0 12px 28px -10px rgba(0,0,0,.6);
  animation: haal-pulse 2.4s infinite;
}
.haal-whatsapp-float svg{ width:30px; height:30px; fill:#08210f; }
@keyframes haal-pulse{
  0%{ box-shadow: 0 0 0 0 rgba(37,211,102,.55); }
  70%{ box-shadow: 0 0 0 14px rgba(37,211,102,0); }
  100%{ box-shadow: 0 0 0 0 rgba(37,211,102,0); }
}

.screen-reader-text{
  position:absolute !important;
  clip: rect(1px,1px,1px,1px);
  width:1px; height:1px; overflow:hidden;
}
