/* ==================================================
   FUENTES
================================================== */
@import url('https://fonts.googleapis.com/css2?family=Playfair+Display:wght@400;700&family=Lora:wght@400;500&display=swap');


/* ==================================================
   BASE / RESET GENERAL
================================================== */

:root {
  --space-s: 8px;
  --space-m: 16px;
  --space-l: 32px;
  --space-xl: 64px;
  --font-title: 'Playfair Display', Georgia, serif;
  --font-body: 'Lora', Georgia, serif;
}

body {
  margin: 0;
  font-family: var(--font-body);
  line-height: 1.6;
  color: #111;
  background: #fff;
}

h1, h2, h3 {
  font-family: var(--font-title);
}

img {
  width: 100%;
  height: auto;
}


/* ==================================================
   CONTAINER
================================================== */

.container {
  width: 100%;
  max-width: 1100px;
  margin-left: auto;
  margin-right: auto;
  box-sizing: border-box;
  padding: 0 var(--space-l);
}


/* ==================================================
   HEADER / NAV
================================================== */

.topbar {
  position: sticky;
  top: 0;
  background: #fff;
  z-index: 1000;
  border-bottom: 1px solid rgba(0,0,0,0.05);
}

/* FILA 1: logo + idiomas */
.topbar-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: var(--space-m) var(--space-l);
}

.logo {
  flex-shrink: 0;
  text-decoration: none;
  color: inherit;
  font-family: var(--font-title);
}

/* selector de idiomas */
.lang-switcher {
  display: flex;
  align-items: center;
  gap: var(--space-m);
}

.lang-switcher button {
  background: none;
  border: none;
  cursor: pointer;
  font-family: var(--font-body);
  font-size: 0.85rem;
  color: #aaa;
  padding: 0;
  transition: color 0.2s;
}

.lang-switcher button:hover {
  color: #111;
}

.lang-switcher button.active {
  color: #111;
  font-weight: 500;
}

/* FILA 2: menú centrado */
.topbar-nav {
  display: flex;
  justify-content: center;
  padding-bottom: var(--space-m);
}

.menu {
  display: flex;
  align-items: center;
  gap: var(--space-m);
}

.menu a {
  text-decoration: none;
  color: inherit;
  position: relative;
  font-size: 0.95rem;
}

.menu a::after {
  content: "";
  position: absolute;
  width: 0;
  height: 1px;
  background: black;
  bottom: -3px;
  left: 0;
  transition: 0.3s;
}

.menu a:hover::after {
  width: 100%;
}

.menu a.active {
  border-bottom: 1px solid #111;
}


/* ==================================================
   RESPONSIVE HEADER
================================================== */

@media (max-width: 768px) {
  .topbar-top {
    flex-direction: column;
    align-items: center;
    gap: var(--space-s);
    padding: var(--space-m);
  }

  .lang-switcher {
    flex-wrap: wrap;
    justify-content: center;
    gap: var(--space-s);
  }

  .menu {
    flex-wrap: wrap;
    justify-content: center;
  }
}


/* ==================================================
   HOME — BANNERS
================================================== */

.home {
  padding: var(--space-xl) 0;
}

.banner-principal {
  display: block;
  text-decoration: none;
  color: inherit;
  margin-bottom: var(--space-l);
}

.banner-principal-media {
  width: 100%;
  aspect-ratio: 16 / 6;
  overflow: hidden;
  background: #f0f0f0;
}

.banner-principal-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.4s;
}

.banner-principal:hover .banner-principal-media img {
  transform: scale(1.02);
}

.banner-principal-text {
  padding: var(--space-m) 0;
}

.banner-principal-text h2 {
  margin: 0 0 var(--space-s) 0;
}

.banner-principal-text p {
  margin: 0;
  opacity: 0.7;
}

/* cuadrícula */
.banner-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--space-l);
  margin-bottom: var(--space-xl);
}

.banner-card {
  display: block;
  text-decoration: none;
  color: inherit;
}

.banner-card-media {
  width: 100%;
  aspect-ratio: 4 / 3;
  overflow: hidden;
  background: #f0f0f0;
  margin-bottom: var(--space-s);
}

.banner-card-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.4s;
}

.banner-card:hover .banner-card-media img {
  transform: scale(1.03);
}

.banner-card p {
  margin: 0;
  font-size: 0.9rem;
}

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

  .banner-principal-media {
    aspect-ratio: 16 / 9;
  }
}


/* ==================================================
   POST
================================================== */

.post {
  padding: var(--space-xl) 0;
}

.post-back {
  display: inline-block;
  margin-bottom: var(--space-l);
  text-decoration: none;
  color: inherit;
  font-size: 0.9rem;
  opacity: 0.6;
  transition: opacity 0.2s;
}

.post-back:hover {
  opacity: 1;
}

.post-media {
  width: 100%;
  aspect-ratio: 16 / 7;
  overflow: hidden;
  background: #f0f0f0;
  margin-bottom: var(--space-l);
}

.post-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.post-content h1 {
  margin: 0 0 var(--space-m) 0;
}

.post-content p {
  line-height: 1.8;
  max-width: 700px;
}

.post-fecha {
  margin-top: var(--space-l);
  font-size: 0.85rem;
  color: #aaa;
}


/* ==================================================
   STORE
================================================== */

.store {
  padding: var(--space-xl) 0;
}

.store h1,
.dentro h1,
.about h1 {
  font-size: 1.1rem;
  font-weight: 400;
  color: #999;
  margin-bottom: var(--space-xl);
}

.product {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-l);
  align-items: start;
  margin-bottom: var(--space-xl);
  padding-bottom: var(--space-xl);
  border-bottom: 1px solid rgba(0,0,0,0.08);
}

.product:last-child {
  border-bottom: none;
}

.product-media {
  display: flex;
  flex-direction: column;
  gap: var(--space-s);
}

.product-media-main {
  width: 100%;
  aspect-ratio: 4 / 5;
  overflow: hidden;
  background: #f0f0f0;
}

.product-media-main img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.product-thumbs {
  display: flex;
  gap: var(--space-s);
}

.product-thumb {
  width: 64px;
  height: 64px;
  object-fit: cover;
  cursor: pointer;
  opacity: 0.5;
  border: 1px solid transparent;
  transition: opacity 0.2s, border-color 0.2s;
}

.product-thumb:hover {
  opacity: 0.8;
}

.product-thumb.active {
  opacity: 1;
  border-color: #111;
}

.product-info {
  display: flex;
  flex-direction: column;
  gap: var(--space-m);
}

.product-info h2 {
  margin: 0;
}

.product-info p {
  line-height: 1.7;
  margin: 0;
}

.product-price {
  font-size: 1.1rem;
  font-weight: 500;
}

.product-variants-label {
  margin: 0 0 var(--space-s) 0;
  font-size: 0.8rem;
  opacity: 0.6;
}

.product-variants-options {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-s);
}

.variant-btn {
  padding: 8px 16px;
  background: none;
  border: 1px solid #ccc;
  font-family: var(--font-body);
  font-size: 0.85rem;
  cursor: pointer;
  transition: border-color 0.2s, background 0.2s, color 0.2s;
}

.variant-btn:hover {
  border-color: #111;
}

.variant-btn.selected {
  background: #111;
  color: #fff;
  border-color: #111;
}

.variant-btn.variant-agotado {
  opacity: 0.35;
  text-decoration: line-through;
  cursor: not-allowed;
}

.variant-btn.variant-agotado:hover {
  border-color: #ccc;
}

.btn-comprar {
  display: inline-block;
  margin-top: auto;
  padding: 12px 28px;
  background: #111;
  color: #fff;
  text-decoration: none;
  font-size: 0.9rem;
  letter-spacing: 0.05em;
  transition: background 0.2s;
  align-self: flex-start;
}

.btn-comprar:hover {
  background: #444;
}

/* producto agotado */
.product-agotado .product-media {
  opacity: 0.5;
}

.product-agotado .product-info h2,
.product-agotado .product-info p,
.product-agotado .product-price {
  opacity: 0.5;
}

.btn-agotado {
  display: inline-block;
  padding: 12px 28px;
  background: none;
  border: 1px solid #ccc;
  color: #aaa;
  font-size: 0.9rem;
  letter-spacing: 0.05em;
  align-self: flex-start;
  cursor: default;
}

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


/* ==================================================
   DENTRO
================================================== */

.dentro {
  padding: var(--space-xl) 0;
  max-width: 700px;
}

.dentro h1 {
  margin-bottom: var(--space-l);
}

.dentro p {
  line-height: 1.8;
  margin-bottom: var(--space-l);
}


/* ==================================================
   ABOUT
================================================== */

.about {
  padding: var(--space-xl) 0;
  max-width: 700px;
}

.about h1 {
  margin-bottom: var(--space-l);
}

.about p {
  line-height: 1.8;
}


/* ==================================================
   FOOTER
================================================== */

.site-footer {
  border-top: 1px solid rgba(0,0,0,0.08);
  padding: var(--space-l) 0;
  margin-top: var(--space-xl);
}

.site-footer p {
  margin: 0;
  font-size: 0.8rem;
  color: #aaa;
  text-align: center;
}
