/* Tipografías y base */
body {
  margin: 0;
  font-family: 'Inter', sans-serif;
  color: #222;
  background: white;
}

h1, h2 {
  font-family: 'Playfair Display', serif;
  font-weight: 700;
  margin: 0 0 10px;
}

h2 {
  font-size: 24px;
}

.navbar {
  background:whitesmoke;
  padding:1rem;
  position: sticky;
  top: 0;
  z-index: 999;
}
.logo {
  cursor: pointer;
}
.nav-bar{display:flex;align-items:center;justify-content:center;gap:1.25rem}
.nav-bar a img.logo {
  height: 80px;
  display: block;
}
/* Menú desktop centrado */
.desktop-only ul{display:flex;gap:3rem;margin:0;padding:0}
.desktop-only li{list-style:none}
.desktop-only a{color:#000;text-decoration:none;font-weight:700;font-size:15px}
.desktop-only a:hover{color:#c02f07;text-decoration:underline}

/* Hamburguesa (oculta en desktop) */
.hamburger-btn{display:none;width:36px;height:28px;position:relative;border:0;background:transparent;cursor:pointer}
.hamburger-btn span{position:absolute;left:0;right:0;height:3px;background:#000;border-radius:2px;transition:transform .25s,opacity .2s,top .25s}
.hamburger-btn span:nth-child(1){top:0}
.hamburger-btn span:nth-child(2){top:12px}
.hamburger-btn span:nth-child(3){top:24px}

/* Drawer y backdrop */
.backdrop{position:fixed;inset:0;background:rgba(0,0,0,.35);backdrop-filter:blur(1px);display:none}
.nav-drawer{position:fixed;top:0;right:0;height:100vh;width:min(78vw,360px);background:whitesmoke;
  box-shadow:-6px 0 20px rgba(0,0,0,.12);transform:translateX(100%);transition:transform .28s ease;
  padding:84px 24px 24px;z-index:1001}
.nav-drawer ul{display:flex;flex-direction:column;gap:1.25rem;margin:0;padding:0;list-style:none}
.nav-drawer a{color:#000;text-decoration:none;font-weight:700;font-size:18px}
.nav-drawer a:hover{color:#c02f07;text-decoration:underline}
.close-btn{position:absolute;top:20px;right:20px;width:36px;height:36px;border-radius:50%;border:none;background:#f0f0f0;cursor:pointer;font-size:20px;line-height:36px}

/* Estados abiertos */
.nav-drawer.open{transform:translateX(0)}
.backdrop.show{display:block}

/* ====== Responsive ≤1020px ====== */
@media (max-width:1020px){
  .nav-bar{justify-content:space-between}         /* Logo IZQ / Hamburguesa DER */
  .hamburger-btn{display:inline-block}
  .desktop-only{display:none}
  .logo-link img{height:56px;max-height:56px}
  /* animación hamburguesa -> X */
  .hamburger-btn.is-open span:nth-child(1){top:12px;transform:rotate(45deg)}
  .hamburger-btn.is-open span:nth-child(2){opacity:0}
  .hamburger-btn.is-open span:nth-child(3){top:12px;transform:rotate(-45deg)}
}

.container-narrow {
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 1rem 4rem;
}

.catalog-hero {
  height: 240px;
  background: url("./Imágenes/header-cata.webp") center/cover no-repeat;
}

.breadcrumbs {
  padding: 1rem 0;
  font-size: .95rem;
  color: #666;
}
.breadcrumbs ol {
  list-style: none;
  display: flex;
  gap: .5rem;
  flex-wrap: wrap;
}
.breadcrumbs a {
  color: #666;
  text-decoration: none;
}
.breadcrumbs li+li::before {
  content: "/";
  margin: 0 .5rem 0 0;
  color: #bbb;
}

/* ---------- Head ---------- */
.catalog-head {
  margin-bottom: 1rem;
}
.catalog-head h1 {
  font-size: 1.75rem;
  font-weight: 700;
}
.catalog-head .sub {
  color: #8b8b8b;
  margin-top: .5rem;
}

/* ---------- Tabs sin JS ---------- */
.tabs {
  margin-top: 1.5rem;
}

.tabs input[type="radio"] {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.tabs label {
  display: inline-block;
  padding: .6rem 1rem;
  background: #f3f3f3;
  border: 1px solid #e6e6e6;
  border-bottom: none;
  border-radius: 10px 10px 0 0;
  margin-right: .25rem;
  cursor: pointer;
  font-weight: 600;
  color: #555;
}

.tab-panel {
  border: 1px solid #e6e6e6;
  border-radius: 0 10px 10px 10px;
  padding: 1rem;
  display: none;
  background: #fff;
}

#tab1:checked ~ .tab-panel[data-tab="tab1"],
#tab2:checked ~ .tab-panel[data-tab="tab2"],
#tab3:checked ~ .tab-panel[data-tab="tab3"] {
  display: block;
}

#tab1:checked + label,
#tab2:checked + label,
#tab3:checked + label {
  background: #fff;
  color: #222;
  border-bottom: 1px solid #fff;
}

/* ---------- Grid de productos ---------- */
.product-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.25rem;
}

.card {
  background: #fff;
  border: 1px solid #eee;
  border-radius: 12px;
  padding: .75rem;
  transition: transform .15s ease, box-shadow .15s ease;
  display: flex;
  flex-direction: column;
  gap: .5rem;
}
.card:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 24px rgba(0,0,0,.06);
}
.card__link {
  text-decoration: none;
  color: inherit;
}

.card__link:hover .title {
  text-decoration: underline;
}
.thumb {
  margin: 0;
  line-height: 0;
  display: grid;
  place-items: center;
  width: 100%;
  aspect-ratio: 1 / 1;
  border-radius: 10px;
  background: #fafafa;
  overflow: hidden;
}
.thumb img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.title {
  font-size: 1rem;
  text-align: center;
  margin-top: .25rem;
  color: #333;
  font-weight: 600;
  min-height: 1.25rem;
}

/* ---------- Paginación ---------- */
.pagination {
  margin-top: 1.25rem;
  display: flex;
  gap: .5rem;
  justify-content: center;
  align-items: center;
}
.page {
  display: inline-flex;
  justify-content: center;
  align-items: center;
  width: 36px;
  height: 36px;
  border-radius: 8px;
  border: 1px solid #e6e6e6;
  color: #444;
  text-decoration: none;
  font-weight: 600;
  background: #fff;
}
.page:hover { background: #f7f7f7; }
.page.is-active {
  background: #e76f51;
  color: #fff;
  border-color: #e76f51;
}

/* ---------- CTA final ---------- */
.cta-center {
  text-align: center;
  margin-top: 2rem;
}
.btn {
  display: inline-block;
  padding: .75rem 1.5rem;
  border-radius: 999px;
  text-decoration: none;
  font-weight: 700;
}
.btn-primary {
  background: #e76f51;
  color: #fff;
}

/* ---------- Footer ---------- */
footer {
  background: #333;
  color: #eee;
  padding: 3rem 1rem;
}
footer h3 {
  text-align: center;
  margin-bottom: 1.5rem;
}
.button-footer {
  display: block;
  background: #e76f51;
  color: #fff;
  padding: 0.75rem 1.5rem;
  border-radius: 50px;
  text-decoration: none;
  font-weight: bold;
  margin: 0 auto 2rem;
  max-width: fit-content;
}
.info {
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 2rem;
}
.info a {
  color: #eee;
  text-decoration: none;
}
.info a:hover {
  text-decoration: underline;
}
.logo-footer img {
  max-height: 50px;
}

.whatsapp-float {
  position: fixed;
  right: 18px;
  bottom: 18px;
  z-index: 9999;
  transition: transform 0.2s ease;
}

/* Tamaño base del ícono */
.whatsapp-float img {
  width: 48px;
  height: auto;
  display: block;
  pointer-events: none;
}

/* Hover en desktop: pequeño salto */
@media (hover: hover) {
  .whatsapp-float:hover {
    transform: translateY(-4px);
  }
}

/* Click/touch en móvil: efecto de sombra */
@media (hover: none) {
  .whatsapp-float:active {
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
    border-radius: 50%;
  }
}
/* ---------- Responsive ---------- */
@media (max-width: 1024px) {
  .product-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 640px) {
  .catalog-hero { height: 180px; }
  .product-grid { grid-template-columns: 1fr; }
  .tabs label { font-size: .95rem; }
}
