:root {
  --tono1  : #4F7302;
  --tono2  : #462207;
  --tono3  : #EAE8E8;
  --tono4  : #F2811D;
  --tono5  : #BF2604;
  --tono6  : #0D8FA1;
  --tono7  : #FED246;
}


/* Reset y tipografía */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}
body {
  font-family: 'Comic Neue', sans-serif;
  background: linear-gradient(to bottom, var(--tono3), var(--tono1));
  color: var(--tono2);
  font-size: 1.1rem;
}


/* Topbar */
.topbar {
  background: var(--tono6);
  padding: 10px 20px;
  text-align: right;
}
.social-icons a {
  color: white;
  margin: 0 8px;
  font-size: 18px;
  transition: 0.3s;
}
.social-icons a:hover { color: var(--tono4); }


/* Navbar */
.navbar {
  background: var(--tono7);
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 15px 40px;
  flex-wrap: wrap;
}
.navbar h1 {
  font-size: 2.2rem;
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--tono5);
}
.logo-kiwi { width: 32px; height: 32px; }
.navbar ul {
  list-style: none;
  display: flex;
  gap: 20px;
  flex-wrap: wrap;
}
.navbar a {
  text-decoration: none;
  color: var(--tono2);
  font-weight: bold;
  display: flex;
  align-items: center;
  gap: 5px;
  font-size: 1.15rem;
  transition: 0.3s;
}
.navbar a:hover { color: var(--tono6); }


/* Slider */
.slider {
  width: 90%;
  max-width: 800px;
  height: 350px;
  margin: 30px auto;
  position: relative;
  overflow: hidden;
  border-radius: 15px;
  box-shadow: 0px 4px 12px rgba(0,0,0,0.3);
}
.slider-bg {
  position: absolute;
  top: 0; left: 0;
  width: 100%; height: 100%;
  background: linear-gradient(120deg, var(--tono7) 0%, var(--tono1) 100%);
  z-index: 0;
}
.slides {
  position: relative;
  width: 100%; height: 100%;
  z-index: 1;
}
.slide {
  position: absolute;
  top: 0; left: 0;
  width: 100%; height: 100%;
  display: flex; justify-content: center; align-items: center;
  opacity: 0;
  transition: opacity 1s ease-in-out;
}
.slide.active { opacity: 1; }
.slide img {
  width: 100%; height: 100%;
  object-fit: contain;
  border-radius: 15px;
}


/* Slider buttons */
.slider-buttons {
  position: absolute;
  top: 50%;
  width: 100%;
  display: flex;
  justify-content: space-between;
  transform: translateY(-50%);
  z-index: 2;
}
.slider-buttons button {
  background: rgba(0,0,0,0.5);
  border: none; color: white;
  font-size: 24px;
  padding: 10px;
  cursor: pointer;
  border-radius: 50%;
  transition: 0.3s;
}
.slider-buttons button:hover { background: var(--tono4); }


/* Main sections */
main {
  display: flex;
  flex-direction: row;
  justify-content: center;
  align-items: stretch;
  gap: 20px;
  flex-wrap: wrap;
  padding: 40px 20px;
  text-align: center;
}
.about, .artist {
  padding: 30px;
  margin: 10px auto;
  border-radius: 15px;
  flex: 1 1 45%;
  max-width: 500px;
  color: var(--tono3);
}
.about { background-color: var(--tono1); }
.artist { background-color: var(--tono4); }
.about h2, .artist h2 {
  font-size: 2rem;
  margin-bottom: 15px;
  text-align: center;
}
.about p, .artist p {
  font-size: 1rem;
  line-height: 1.8;
  text-align: justify;
}


/* Footer */
footer {
  background: var(--tono2);
  color: var(--tono3);
  padding: 20px 40px;
}
footer .footer-content {
  display: flex;
  flex-direction: row;
  justify-content: space-between;
  align-items: center;
  gap: 20px;
  flex-wrap: wrap;
}
.footer-left p { margin: 0; font-size: 0.9rem; }
.footer-center { text-align: center; }
.footer-nav a {
  margin: 0 10px;
  color: var(--tono3); text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: 1rem;
  transition: 0.3s;
}
.footer-nav a:hover { color: var(--tono7); }
.footer-right .footer-social a {
  margin: 0 5px;
  color: var(--tono3);
  font-size: 18px;
  transition: 0.3s;
}
.footer-right .footer-social a:hover { color: var(--tono4); }


/* Responsive */
@media (max-width: 768px) {
  body { font-size: 1rem; }
  .navbar { flex-direction: column; gap: 10px; }
  .navbar h1 { font-size: 1.6rem; }
  .about h2, .artist h2 { font-size: 1.2rem; }
  .about p, .artist p { font-size: 0.95rem; }
  .navbar a { font-size: 1rem; }
  .slider { width: 95%; height: 300px; }
  main { flex-direction: column; padding: 20px 10px; }
  footer .footer-content { flex-direction: column; text-align: center; gap: 10px; }
  .footer-center, .footer-left, .footer-right { order: unset; }
}


/* Galería simple de recuadros */
.galeria {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 10px;
  padding: 1rem;
}
.recuadro {
  width: 200px;
  height: 200px;
  overflow: hidden;
  border: 1px solid #ccc;
  border-radius: 4px;
  background-color: #fff;
  box-shadow: 0 2px 5px rgba(0,0,0,0.1);
  transition: transform 0.3s ease;
}
.recuadro:hover {
  transform: scale(1.05);
  box-shadow: 0 6px 15px rgba(0,0,0,0.2);
}
.recuadro img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}


/* Galería de libros con ajuste para iPhone/Safari */
.gallery {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  justify-content: center;
  padding: 1rem 0;
}
.gallery-item {
  width: 250px;
  min-height: 380px;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 10px;
  box-sizing: border-box;
  background: #fff;
  border-radius: 6px;
  box-shadow: 0 1px 6px rgba(0,0,0,0.07);
}

/* ✅ Bordes redondeados para las imágenes de libros */
.gallery-imgbox {
  width: 100%;
  height: 250px;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;            /* mantiene el recorte */
  margin-bottom: 10px;
  border-radius: 20px;         /* <<--- radio de los bordes */
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}
.gallery-imgbox img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  border-radius: inherit;      /* hereda el radio del contenedor */
  transition: transform 0.4s ease;
}

.leyenda {
  font-size: 1rem;
  text-align: center;
  margin-top: 10px;
  background-color: rgba(255,255,255,0.8);
  padding: 8px;
  border-radius: 8px;
  width: 100%;
  color: var(--tono2);
  box-shadow: 0 1px 3px rgba(0,0,0,0.1);
  font-weight: 600;
  flex-shrink: 0;
}
.gallery-item a.buy-link {
  margin-top: auto;
  display: block;
  padding: 0.5rem;
  background-color: #25d366; 
  color: white;
  font-weight: bold;
  text-decoration: none;
  border-radius: 6px;
  text-align: center;
  transition: background-color 0.3s ease;
}
.gallery-item a.buy-link:hover {
  background-color: #1ebe57;
}
/* Hover: zoom + sombra */
.gallery-item:hover .gallery-imgbox img {
  transform: scale(1.08);
}

.gallery-item:hover .gallery-imgbox {
  box-shadow: 0px 8px 18px rgba(0,0,0,0.25);
}
.buy-link.disabled {
  background-color: #bbb;
  color: #f7f7f7;
  cursor: not-allowed;
  pointer-events: none;
  opacity: 0.65;
  text-decoration: none;
}


/* Estilo línea divisoria para "Otros libros" */
.divider {
  border: 0;
  height: 2px;
  background: var(--tono1);
  margin: 40px auto 20px auto;
  width: 80%;
  max-width: 1200px;
}

.section-title {
  text-align: center;
  color: var(--tono1);
  font-family: 'Comic Neue', cursive, sans-serif;
  font-weight: 700;
  font-size: 1.8rem;
  margin-bottom: 30px;
}

.otros-libros {
  overflow: hidden; /* Clear floats */
}

.otros-libros .gallery-item {
  width: 22%;
  margin: 0 1.5% 40px 1.5%;
  float: left;
}

/* Responsive para otros libros */
@media (max-width: 768px) {
  .otros-libros .gallery-item {
    width: 48%;
    margin: 0 1% 30px 1%;
    float: left;
  }
}

@media (max-width: 480px) {
  .otros-libros .gallery-item {
    width: 100%;
    margin: 0 0 20px 0;
    float: none;
  }
}
h2.section-title {
  clear: both;
}
/* === Topbar común + botón MERCH consistente === */
.topbar .topbar-inner{
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 14px;
}
.topbar .social-icons{ display: inline-flex; gap: 10px; }
@media (max-width: 560px){
  .topbar .topbar-inner{ flex-wrap: wrap; justify-content: center; }
}
.btn-merch{
  background: linear-gradient(180deg, #FFBE75, #F2811D);
  color:#fff; padding:10px 18px; border-radius:14px;
  font-weight:900; letter-spacing:.3px; text-decoration:none;
  box-shadow: 0 8px 20px rgba(242,129,29,.33), inset 0 -2px 0 rgba(0,0,0,.08);
  border:2px solid rgba(0,0,0,.06);
}
.btn-merch:hover{ filter: saturate(1.06); }
.btn-merch:focus-visible{ outline:3px solid #FED246; outline-offset:2px; }
