:root {
  --color-primary: #181818;
  --color-secondary: #25d366;
  --color-light: #fff;
  --color-dark: #191919;
  --radius: 10px;
  --transition: 0.3s;
  --shadow: 0 4px 16px rgba(0,0,0,0.18);
  --overlay: rgba(0,0,0,0.58);
  --gap: 2rem;
  --font-base: 'Poppins', sans-serif;
}

/* Reset */
body, h1, h2, p, ul, li, section {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}
body {
  background: var(--color-primary);
  color: var(--color-light);
  font-family: var(--font-base);
  min-height: 100vh;
}

/* ===== Hero Carrusel ===== */
.hero-carrusel {
  position: relative;
  width: 100vw;
  min-height: 70vh;
  overflow: hidden;
  display: flex;
  align-items: center;
  background: #000;
}

.hero-carousel-container {
  width: 100%;
  position: relative;
}

.hero-carousel-slides {
  display: flex;
  width: 300%;
  height: 70vh;
  transition: transform 0.6s cubic-bezier(0.72,0.15,0.24,0.98);
}

.hero-carousel-slide {
  min-width: 100vw;
  height: 70vh;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
}
.hero-carousel-slide img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  background: #111;
  display: block;
}

.hero-carousel-overlay {
  position: absolute;
  inset: 0;
  background: var(--overlay);
  z-index: 1;
}

.hero-carousel-content {
  position: absolute;
  z-index: 2;
  top: 55%;
  left: 50%;
  transform: translate(-50%, -50%);
  text-align: center;
  width: 100vw;
}

.hero-carousel-content h1 {
  font-size: 3rem;
  letter-spacing: 3px;
  margin-bottom: 0.5rem;
  color: var(--color-light);
  text-shadow: 0 3px 8px #000b;
}
.hero-carousel-content p {
  font-size: 1.2rem;
  margin-bottom: 1.5rem;
  color: #eee;
}
.hero-carousel-content .btn {
  background: transparent;
  border: 2px solid var(--color-secondary);
  color: var(--color-secondary);
  padding: 0.75rem 2rem;
  border-radius: var(--radius);
  font-weight: 600;
  font-size: 1.1rem;
  cursor: pointer;
  text-decoration: none;
  transition: background var(--transition), color var(--transition);
}
.hero-carousel-content .btn:hover {
  background: var(--color-secondary);
  color: var(--color-dark);
}

.hero-carousel-dots {
  position: absolute;
  bottom: 25px;
  width: 100vw;
  text-align: center;
  z-index: 10;
}
.hero-dot {
  display: inline-block;
  width: 12px; height: 12px;
  margin: 0 5px;
  background: #bbb;
  border-radius: 50%;
  cursor: pointer;
  transition: background 0.3s;
}
.hero-dot.active {
  background: var(--color-secondary);
}

/* ===== Galería Home ===== */
.gallery-home {
  padding: 3rem 0 2rem 0;
  text-align: center;
  background: var(--color-primary);
}
.gallery-home h2 {
  font-size: 2rem;
  color: var(--color-secondary);
  margin-bottom: 2rem;
}
.gallery-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 1.5rem;
  max-width: 1200px;
  margin: 0 auto;
}
.gallery-item {
  background: var(--color-dark);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
  transition: transform .25s;
}
.gallery-item img {
  width: 100%;
  aspect-ratio: 1/1;
  object-fit: cover;
  object-position: center;
  display: block;
  transition: transform .3s;
}
.gallery-item img:hover {
  transform: scale(1.05);
}

.btn {
  display: inline-block;
  padding: 0.75rem 2rem;
  border-radius: var(--radius);
  background: var(--color-secondary);
  color: #222;
  font-weight: 600;
  font-size: 1.1rem;
  border: none;
  text-decoration: none;
  cursor: pointer;
  margin-top: 1.5rem;
  transition: background var(--transition), color var(--transition);
}
.btn:hover {
  background: #fff;
  color: var(--color-secondary);
}

/* ===== About Home ===== */
.about-home {
  padding: 3rem 1rem 3.5rem 1rem;
  text-align: center;
  max-width: 800px;
  margin: 0 auto;
}
.about-home h2 {
  color: var(--color-secondary);
  font-size: 1.8rem;
  margin-bottom: 1rem;
}
.about-home p {
  color: #eee;
  line-height: 1.7;
}

/* ===== Responsive ===== */
@media (max-width: 900px) {
  .hero-carousel-content h1 { font-size: 2.1rem; }
  .hero-carousel-content p { font-size: 1rem; }
  .hero-carousel-slide, .hero-carousel-slide img,
  .hero-carousel-slides { height: 38vh; min-height: 240px; }
  .hero-carrusel { min-height: 38vh; }
}
@media (max-width: 600px) {
  .gallery-grid { grid-template-columns: 1fr 1fr; gap: 0.7rem; }
  .btn { padding: 0.6rem 1rem; font-size: 1rem; }
  .about-home { padding: 2rem 0 2rem 0; }
  .hero-carousel-content { top: 57%; }
}
@media (max-width: 420px) {
  .gallery-grid { grid-template-columns: 1fr; }
  .hero-carousel-content h1 { font-size: 1.15rem; }
}

/* Redes Sociales */
.social-home {
  text-align: center;
  padding: 2rem 1rem;
  background: #111;
  color: #fff;
}

.social-home h2 {
  font-size: 1.8rem;
  margin-bottom: 1rem;
  color: var(--color-light);
}

.social-icons {
  display: flex;
  justify-content: center;
  gap: 1.2rem;
  flex-wrap: wrap;
}

.social-icons a {
  display: inline-block;
  transition: transform 0.2s ease;
}

.social-icons a:hover {
  transform: scale(1.1);
}

.social-icons img {
  width: 40px;
  height: 40px;
  filter: brightness(0) invert(1);
}

/* ======= Home – resumen del último post del blog (stack vertical + thumbs) ======= */
/* Contenedor del resumen del blog */
.home-blog-card {
  display: grid;
  grid-template-columns: 1fr;
  gap: .85rem;
  background: #1d1d1d;
  border: 1px solid #2b2b2b;
  border-radius: 16px;
  box-shadow: 0 10px 30px rgba(0,0,0,.35);
  overflow: hidden;
  max-width: 750px;      /* ancho máximo más pequeño */
  margin: 0 auto;        /* centrado */
}

/* Galería de miniaturas */
.home-blog-media {
  order: 1;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr)); /* 3 columnas por defecto */
  gap: .5rem;
  padding: .8rem;
  background: #181818;
  max-height: 150px;     /* limita altura */
  overflow: hidden;
}

.home-blog-media a {
  display: block;
  height: 100%;
}

.home-blog-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 10px;
  filter: saturate(.95);
  transition: transform .15s ease, filter .15s ease;
}

.home-blog-media img:hover {
  transform: scale(1.02);
  filter: saturate(1);
}

/* Texto */
.home-blog-body {
  order: 2;
  text-decoration: none;
  padding: 1rem;
  color: #eee;
  max-height: 220px;     /* altura máxima del contenido */
  overflow: hidden;      /* oculta exceso */
}

/* Responsive (ajuste columnas sin apilar en 1) */
@media (max-width: 820px) {
  .home-blog-media { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 520px) {
  .home-blog-media { grid-template-columns: repeat(2, 1fr); max-height: unset; }
}

/* ----- Tags (chips) en el teaser del blog ----- */
.home-blog-tags{
  display:flex;
  flex-wrap:wrap;
  gap:.45rem .55rem;
  margin:.55rem 0 .25rem;
}
.blog-chip{
  display:inline-block;
  font-size:.82rem;
  line-height:1;
  padding:.45rem .7rem;
  border-radius:999px;
  background:#222;               /* fondo chip */
  border:1px solid #333;         /* borde chip */
  color:#ddd;                    /* texto chip */
  letter-spacing:.2px;
}
.blog-chip-empty{ opacity:.65; }

/* ----- Título del teaser ----- */
.home-blog-title{
  margin:.35rem 0 .4rem;
  line-height:1.25;
}
.home-blog-title-link{
  color:#fff;
  text-decoration:none;
}
.home-blog-title-link:hover{
  text-decoration:underline;
  text-decoration-thickness:2px;
  text-underline-offset:3px;
  text-decoration-color:#25d366; /* acento */
}

/* ----- Botón “Leer historia completa” (llamativo) ----- */
.home-blog-actions{ margin-top:.8rem; }
.btn-outline{
  display:inline-block;
  padding:.75rem 1.15rem;
  border:2px solid #25d366;
  color:#25d366;
  border-radius:999px;
  font-weight:700;
  letter-spacing:.2px;
  transition:background .2s, color .2s, transform .06s, box-shadow .2s;
}
.btn-outline:hover{
  background:#25d366;
  color:#121212;
  box-shadow:0 8px 24px rgba(37,211,102,.25);
}
.btn-outline:active{
  transform:scale(.98);
}

/* ----- Tarjeta teaser compacta y responsive ----- */
.home-blog-card{
  background:#1b1b1b;
  border:1px solid #2a2a2a;
  border-radius:14px;
  box-shadow:0 10px 28px rgba(0,0,0,.25);
  overflow:hidden;
  max-width:900px;       /* compacta */
  margin:0 auto;
}

/* Galería mini en el teaser: imágenes arriba, texto abajo */
.home-blog-media{
  display:grid;
  grid-template-columns:repeat(3, 1fr); /* 3 columnas por defecto */
  gap:6px;
  background:#151515;
  padding:6px;
}
.home-blog-media img{
  width:100%;
  aspect-ratio:16/10;
  object-fit:cover;
  border-radius:10px;
}
.home-blog-media a{ display:block; }

/* Cuerpo del teaser */
.home-blog-body{
  padding:.95rem 1rem 2.1rem;
}
.home-blog-meta{
  display:flex; align-items:center; gap:.55rem;
  color:#bdbdbd; font-size:.92rem;
}

/* Responsive (coherente con el bloque anterior) */
@media (max-width:820px){
  .home-blog-card{ max-width:100%; }
  .home-blog-media{ grid-template-columns:repeat(3, 1fr); }
  .home-blog-body{padding:.95rem 1rem 7.0rem;}
  .btn-outline{ width:90%; text-align:center; }
}
@media (max-width:640px){
  .home-blog-media{ grid-template-columns:repeat(3, 1fr); } /* 3 columnas en móvil */
  .btn-outline{ width:90%; text-align:center; } /* botón full-width en móvil */
  .home-blog-body{padding:.95rem 1rem 7.0rem;}
}
@media (max-width: 600px) {
  .hero-carousel-dots {
    bottom: 5px; /* valor actual */
  }
}

@media (max-width: 420px) {
  .hero-carousel-dots {
    bottom: -3px;
  }
}