/*
 Theme Name: Astra Child
 Theme URI: https://example.com
 Description: Child theme para Astra (ZZ Percusión)
 Author: Jeremías
 Template: astra
 Version: 1.0.0
*/


/* Design tokens / CSS variables */
:root{
  --zz-gap: 24px;
  --zz-gap-sm: 12px;
  --zz-thumb-gap: 10px;
  --zz-thumb-w: 92px;
  --zz-thumb-h: 120px;
  --zz-thumb-w-sm: 74px;
  --zz-accent: #111;
  --zz-hero-gradient: linear-gradient(180deg, rgba(255,255,255,0.05), rgba(255,255,255,0.25));
}


/**
 Front page
*/
.mobile--only {
  display: none !important;
}

.desktop--only {
  display: block !important;
}
@media (max-width: 768px) {

  .mobile--only {
    display: block !important;
  }

  .desktop--only {
    display: none !important;
  }

}


/* Single product */

.zz-product { width: 100%; }

.zz-product__hero{
  min-height: calc(100vh - 110px);
  background-position: right top;
  background-repeat: no-repeat;
  padding: 0;
  position: relative;
  background-color: #000000;
  
}

.zz-product__hero::before{
  content:"";
  position:absolute;
  inset:0;
  background: linear-gradient(180deg, rgba(255,255,255,0.05), rgba(255,255,255,0.25));
  pointer-events:none;
}

.zz-product__inner{
  position: relative;
  width: 100%;
  max-width: 100vw;
  min-height: calc(100vh - 110px);
  margin: 0 auto;
  padding: 0;
  display: flex;
  align-items: stretch;
}

.zz-product__infoCard{
  background: rgba(255,255,255,0.60);
  backdrop-filter: blur(6px);
  border: 1px solid rgba(0,0,0,0.08);
  padding: 18px;
  width: 380px;
  flex: 0 0 380px;
  order: 0;
}

.zz-product__title{ margin: 0 0 10px; font-size: 28px; }
.zz-product__meta{ display:flex; gap:8px; flex-wrap:wrap; margin-bottom: 10px; }
.zz-product__excerpt{ margin: 0 0 12px; opacity: .85; }

.zz-spec h3{ margin: 12px 0 6px; font-size: 14px; opacity: .8; text-transform: uppercase; letter-spacing: .04em; display: block; }
.zz-spec p{ margin: 0; }

.zz-pill{ font-size: 12px; padding: 4px 10px; border-radius: 999px; background:#111; color:#fff; text-transform: capitalize; }
.zz-pill--muted{ background:#eee; color:#111; }

.zz-button{
  margin-top: 14px;
  display: inline-block;
  padding: 10px 14px;
  background: #111;
  color: #fff;
  text-decoration: none;
  border-radius: 4px;
}

/* WhatsApp branded button */
.zz-button--whatsapp{
  background: linear-gradient(180deg,#25d366,#1ebe5d);
  color: #fff;
  border: none;
  box-shadow: 0 2px 8px rgba(37,211,102,0.18);
  width: 100%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin: 24px auto;
}
.zz-button--whatsapp:hover{ filter: brightness(.95); color:#f9f9f9; }
.zz-button--whatsapp:active{ transform: translateY(1px); }
.zz-button--whatsapp .zz-button__icon{ display:inline-flex; width:18px; height:18px; margin-right:8px; vertical-align:middle; }
.zz-button--whatsapp .zz-button__icon svg{ width:100%; height:100%; display:block; }

.zz-spec .gallery-item:nth-child(odd) {
  padding-left: 0;
  padding-right: 20px;
}

.zz-spec .gallery-item:nth-child(even) {
  padding-right: 0;
  padding-left: 20px;
}


.zz-product__gallery{ 
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  align-self: flex-end;
  flex: 0 1 100vw;
  padding: 24px;
  background-color: rgba(0, 0, 0, .75);
  order: 1;
}
  .zz-galleryMain{ display:none; }

@media (max-width: 900px){
  .zz-galleryMain{ display:none; }
  .zz-galleryMain{ margin-bottom: 12px; display:flex; align-items:center; justify-content:center; }
  .zz-galleryMain__btn{ background:transparent; border:0; padding:0; cursor:pointer; }
  .zz-galleryMain{ display:none; }
  .zz-galleryMain__img{ width:360px; height:auto; max-width:100%; display:block; }
  /* Fade transition for main gallery image */
  .zz-galleryMain__img{ transition: opacity .24s ease; }
  .zz-galleryMain__img.is-loading{ opacity: 0; }

  /* Accessibility: focus and touch */
  button:focus-visible, a:focus-visible { outline: 3px solid rgba(0,0,0,0.12); outline-offset: 2px; }
  button{ touch-action: manipulation; }

}

.zz-thumbs{
  display: flex;
  gap: var(--zz-thumb-gap);
  align-items: center;
  justify-content: flex-end;
  flex-wrap: wrap;
}

.zz-thumb{
  border: 1px solid rgba(0,0,0,0.15);
  background: rgba(255,255,255,0.65);
  padding: 0;
  overflow: hidden;
  
  height: var(--zz-thumb-h);
  cursor: pointer;
  border-radius: 4px;
}

.zz-thumb img{
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.zz-thumb.is-active{ border-color: rgba(0,0,0,0.6); }

.zz-galleryControls{ margin-top: 10px; display:flex; gap: 8px; }
.zz-control{
  width: 38px;
  height: 32px;
  border: 1px solid rgba(0,0,0,0.15);
  background: rgba(255,255,255,0.70);
  cursor: pointer;
}

.zz-product__below{ padding: 30px 0; }
.zz-product__belowInner{ max-width: 1200px; margin: 0 auto; padding: 0 20px; }

.zz-spec p {
  font-size:15px;
  margin-bottom: 0.6em;
}

@media (max-width: 900px){
  .zz-product__inner{
    flex-direction: column;
    align-items: stretch;
    gap: 12px;
  }
  .zz-product__gallery{ align-items: flex-start; padding:0; background-color: transparent; }
  .zz-thumbs{ justify-content: flex-start; flex-wrap: wrap; }
}

.zz-product__heroTitle{ display: none; }
.zz-product__infoCard > h1.zz-product__title { font-size: 22px; margin-bottom: 6px; }

.zz-product__price { margin: 24px 0;}

/* Mobile layout tweaks: gallery under title, then card, remove hero background */
@media (max-width: 900px) {
  .zz-product__hero{
    min-height: auto;
    padding: 20px 0;
    background-image: none !important;
  }

  .zz-product__hero::before{ background: none; }

  .zz-product__heroTitle{ padding: 0 20px 8px; display: block; }

  .zz-product__inner{ padding: 0 0 0 0; }

  .zz-product__gallery{ order: 1; align-items: center; justify-content: center; flex: 0 0 auto; }

  .zz-product__infoCard{ order: 2; width: 100%; flex: 0 0 auto; background: rgba(255,255,255,0.95); padding: 14px; }

  .zz-product__infoCard > h1.zz-product__title { display: none; }

  .zz-product__below{ order: 3; }

  .zz-thumbs{ justify-content: center; gap: 8px; }

  .zz-thumb{ width: var(--zz-thumb-w-sm); height: auto; }
   .zz-thumb img { width: 100%; height: auto; }

  /* show featured image only on mobile, below thumbs */
  .zz-galleryMain{ display:block; margin-top:10px; }
  .zz-galleryMain__img{ width:100%; max-width:680px; height:auto; }
}

/* Lightbox styles */
.zz-lightbox{ display:none; }
.zz-lightbox.is-open{ display:block; position:fixed; inset:0; z-index:2000; }
.zz-lightbox__backdrop{ position:fixed; inset:0; background: rgba(0,0,0,0.65); }
.zz-lightbox__wrap{ position:fixed; inset:0; display:flex; align-items:center; justify-content:center; pointer-events:none; }
.zz-lightbox__stage{ max-width: 95%; max-height: 90%; pointer-events:auto; display:flex; align-items:center; justify-content:center; position:relative; }
.zz-lightbox__img{ max-width:95vw; max-height:95vh; display:block; box-shadow: 0 10px 30px rgba(0,0,0,0.5); background:#fff; transition: opacity .2s ease; }
.zz-lightbox__img.is-loading{ opacity:0; }

/* Lightbox spinner */
.zz-lightbox__spinner{
  display:none;
  position:absolute;
  top:50%; left:50%;
  width:40px; height:40px;
  margin:-20px 0 0 -20px;
  border:4px solid rgba(255,255,255,0.25);
  border-top-color:#fff;
  border-radius:50%;
  animation:zz-spin .7s linear infinite;
  z-index:10;
  pointer-events:none;
}
.zz-lightbox__spinner.is-visible{ display:block; }
@keyframes zz-spin{ to{ transform:rotate(360deg); } }
.zz-lightbox__close{ position: absolute; top:18px; right:18px; z-index:2100; pointer-events:auto; background:transparent; border:0; color:#fff; font-size:28px; cursor:pointer; }
.zz-lightbox__nav{ position: absolute; top:50%; transform:translateY(-50%); z-index:2100; pointer-events:auto; background: rgba(255,255,255,0.06); border:0; color:#fff; font-size:32px; width:56px; height:56px; display:flex; align-items:center; justify-content:center; cursor:pointer; }
.zz-lightbox__prev{ left:18px; }
.zz-lightbox__next{ right:18px; }

@media (max-width:600px){
  .zz-lightbox__nav{ width:42px; height:42px; font-size:24px; }
  .zz-lightbox__close{ font-size:22px; }
}

/* Product list (archive) */

/* Layout container */
.zz-archive { max-width: 1200px; margin: 0 auto; padding: 24px 20px 40px; }
.zz-archive__header { margin-bottom: 18px; }
.zz-archive__title { margin: 0; font-size:48px;  }

/* Category nav */
.zz-catnav { display:flex; gap:10px; flex-wrap:wrap; margin: 12px 0 18px; }
.zz-catnav__item { padding: 7px 10px; border: 1px solid #ddd; border-radius: 999px; text-decoration:none; }
.zz-catnav__item.is-active { border-color: #111; }

/* Filters */
.zz-filters { display:flex; gap:10px; flex-wrap:wrap; align-items:center; margin: 0 0 22px; }
.zz-filters__label { opacity:.7; }
.zz-filter { padding: 6px 10px; border: 1px solid #ddd; border-radius: 999px; text-decoration:none; }

/* Grid */
.zz-grid { display:grid; gap: 18px; }

/* Desktop >= 901px */
@media (min-width: 901px) {
  .zz-grid { grid-template-columns: repeat(3, 1fr); }

  .zz-pcard__metaMobile { display:none; }

  .zz-pcard__media {
    aspect-ratio: 4 / 3;
  }

  .zz-pcard__overlay {
    opacity: 0;
    transform: translateY(8px);
    transition: opacity .2s ease, transform .2s ease;
  }

  .zz-pcard__media::before{
    content:"";
    position:absolute;
    inset:0;
    background: rgba(255,255,255,0.0);
    transition: background .2s ease;
  }

  .zz-pcard:hover .zz-pcard__overlay {
    opacity: 1;
    transform: translateY(0);
  }

  .zz-pcard:hover .zz-pcard__media::before{
    background: rgba(255,255,255,0.45);
  }

  .zz-pcard:hover .zz-pcard__media{
    transform: scale(1.01);
  }
}

/* Mobile <= 900px */
@media (max-width: 900px) {
  .zz-grid { grid-template-columns: repeat(2, 1fr); }
  .zz-pcard__overlay { display:none; }
  .zz-pcard__title { margin: 10px 0 8px; font-size: 14px; }
  .zz-pcard__metaMobile { display:flex; gap:6px; flex-wrap:wrap; }
}

@media (max-width: 560px) {
  .zz-grid { grid-template-columns: 1fr; }
}

/* Cat “slider” (scroller) */
.zz-catScroller { margin: 14px 0 24px; overflow: hidden; }
.zz-catScroller__track{
  display: flex;
  gap: 10px;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  -webkit-overflow-scrolling: touch;
}
.zz-catScroller__track::-webkit-scrollbar{ height: 6px; }
.zz-catScroller__track::-webkit-scrollbar-thumb{ background: rgba(0,0,0,0.2); border-radius: 999px; }

.zz-catChip {
    flex: 0 0 auto;
    padding: 0 12px;
    border-right: 1px solid #333;
    text-decoration: none;
    scroll-snap-align: start;
}

.zz-catChip:hover { color: #333;}

.zz-catChip:first-of-type { border-left: 1px solid #333; }

.zz-catChip.is-active{ border-color:#111; font-weight: bold; }

/* Línea chips */
.zz-filters { display:flex; gap:10px; flex-wrap:wrap; align-items:center; margin: 0 0 20px; }
.zz-filters__label { opacity:.7; }
.zz-filter { padding: 6px 10px; border: 1px solid #ddd; border-radius: 999px; text-decoration:none; }

/* Grid */
.zz-grid { display:grid; gap: 18px; }

/* Desktop >= 901px */
@media (min-width: 901px) {
  .zz-grid { grid-template-columns: repeat(3, 1fr); }
  .zz-pcard__metaMobile { display:none; }

  .zz-pcard__media { aspect-ratio: 4 / 3; }

  .zz-pcard__overlay {
    opacity: 0;
    transform: translateY(8px);
    transition: opacity .2s ease, transform .2s ease;
  }

  .zz-pcard__media::before{
    content:"";
    position:absolute;
    inset:0;
    background: rgba(255,255,255,0.0);
    transition: background .2s ease;
  }

  .zz-pcard:hover .zz-pcard__overlay { opacity: 1; transform: translateY(0); }
  .zz-pcard:hover .zz-pcard__media::before{ background: rgba(255,255,255,0.45); }
  .zz-pcard:hover .zz-pcard__media{ transform: scale(1.01); }
}

/* Mobile <= 900px */
@media (max-width: 900px) {
  .zz-grid { grid-template-columns: repeat(2, 1fr); }
  .zz-pcard__overlay { display:none; }
  .zz-pcard__title { margin: 10px 0 8px; font-size: 14px; }
  .zz-pcard__metaMobile { display:flex; gap:6px; flex-wrap:wrap; }
}
@media (max-width: 560px) { .zz-grid { grid-template-columns: 1fr; } }

/* Card base */
.zz-pcard { border: 1px solid #eee; overflow:hidden; background:#fff; }
.zz-pcard__link { display:block; padding: 4px; color:inherit; text-decoration:none; }
.zz-pcard__media{
  position: relative;
  overflow:hidden;
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  transition: transform .2s ease;
  border: 1px solid rgba(0,0,0,0.06);
  min-height: 160px;
}
.zz-pcard__title { margin: 12px 0 0; font-size: 16px; }

.zz-pcard__overlay{
  position:absolute;
  inset:0;
  display:flex;
  align-items:flex-end;
  padding: 12px;
}
.zz-pcard__overlayInner{
  display:flex;
  gap:8px;
  flex-wrap:wrap;
  align-items:center;
}
.zz-pcard__cta { margin-left: auto; font-size: 13px; opacity:.8; }

/* Pills */
.zz-pill{ font-size: 12px; padding: 4px 10px; border-radius: 999px; background:#111; color:#fff; }
.zz-pill--muted{ background:#eee; color:#111; }

.zz-filter.is-active {
  border-color: #111;
}

.zz-swatches {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  margin-top: 10px;
}

.zz-swatch {
  width: 60px;
  height: 60px;
  border-radius: 50%;
  overflow: hidden;
  display: inline-flex;
  border: 1px solid rgba(0,0,0,.15);
  transition: transform .2s ease, box-shadow .2s ease;
}

.zz-swatch:hover {
  transform: scale(1.08);
  box-shadow: 0 4px 10px rgba(0,0,0,.15);
}

.zz-swatch__img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/*** Home
*/

.category-link-home {
	position: relative;
	overflow:hidden;
	border-radius: 4px;
  transition: box-shadow .2s ease-in-out, transform .2s ease-in-out;
}

.category-link-home figcaption {
	position:absolute;
	bottom: 0;
	left: 0;
	background: #000000;
  background: linear-gradient(0deg, rgba(0, 0, 0, 1) 58%, rgba(0, 0, 0, 0) 100%);
	opacity:0;
	transition: opacity .2s ease-in-out;
	width:100%;
	padding:10px;
	color: #fff;
	margin: 0;
  pointer-events: none;
}
@media (max-width: 560px) {
  .category-link-home figcaption {
    opacity: 1;
    position: static;
  }
}

.category-link-home:hover {
	box-shadow: 0px 4px 17px -8px rgba(0,0,0,0.75);
  -webkit-box-shadow: 0px 4px 17px -8px rgba(0,0,0,0.75);
  -moz-box-shadow: 0px 4px 17px -8px rgba(0,0,0,0.75);
  transform: scale(120%);
}

.category-link-home:hover figcaption {
	opacity:1;
	
}

.productos-destacados-home {
  position: relative;
}
.productos-destacados-home-bg {
  position: absolute;
  bottom: -84px;
  height: calc(60% + 84px);
  width: 200%;
  left: -50%;
  background-color: #E53935;
  border-bottom: 4px solid #111;
}

.productos-grid{
  display:grid;
  grid-template-columns:repeat(3,1fr);
  gap:24px;
  margin-bottom:24px;
}

.producto-item {
  height: 320px;
  background-size: cover;
  position: relative;
  border-radius: 4px;
  overflow: hidden;
  box-shadow: 0px 0px 10px 0px rgba(17,17,17,0.75);
  -webkit-box-shadow: 0px 0px 10px 0px rgba(17,17,17,0.75);
  -moz-box-shadow: 0px 0px 10px 0px rgba(17,17,17,0.75);
}
.producto-overlay {
  position: absolute;
  inset:0;
  background: rgba(0,0,0,0.6);
  transition: background .2s ease-in-out;
  opacity:1;
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  align-items: flex-start;
  padding: 20px;
  width: 65%;
}
.producto-overlay h3 {
  margin:0;
  font-size: 20px;
  text-align: center;
  color: #fff;
} 
.producto-overlay h5 {
  margin: 6px 0 0;
  font-size: 16px;
  opacity: .9;
  color: #fff;
}
.producto-overlay p {
  margin: 6px 0 0;
  font-size: 14px;
  opacity: .85;
  color: #fff;
  text-transform: lowercase;
}
.producto-item:hover .producto-overlay {
  background: rgba(0,0,0,0.75);
}

@media (max-width: 750px) {
  .productos-grid{
    display:grid;
    grid-template-columns:1fr;
    gap:20px;
  }
  .producto-item {
    height: 120px;
  }
  .producto-overlay {
    opacity: 1;
    justify-content: flex-end;
    background-color: transparent;
  }
  .producto-overlay h3 {
    font-size: 18px;
    padding: 8px;
    background: rgba(0,0,0,0.75);
  } 
  .producto-overlay p {
    display: none;
  }
}

@media (min-width: 751px) and (max-width: 1200px) {
  .productos-grid{
    display:grid;
    grid-template-columns:repeat(2, 1fr);
    gap:20px;
  }
  .producto-overlay {
    width: 70%;
  }
}

.zz-pagination > nav {
  text-align: center;
  margin: 40px 0;
  font-size: 1.3em;
}

.zz-pagination a {
  font-weight: bold;
}
.zz-pagination a:hover {
  text-decoration: underline;
}

