/* ===== Jersey DEF - estilos base ===== */

:root {
  --color-olive: #7A6D4E;
  --color-olive-dark: #635A40;
  --color-black: #000000;
  --color-white: #FFFFFF;
  --color-cream: #FAF9F5;

  --font-display: "Playfair Display", Georgia, "Times New Roman", serif;
  --font-body: "Inter", "Helvetica Neue", Arial, sans-serif;

  --max-width: 1440px;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--font-body);
  color: var(--color-black);
  background: var(--color-white);
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; display: block; }

a { color: inherit; text-decoration: none; }

button { font-family: inherit; cursor: pointer; }

.container {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 24px;
}

/* ===== Barra de anuncio ===== */
.announcement-bar {
  background: var(--color-black);
  color: var(--color-cream);
  text-align: center;
  font-size: 13px;
  letter-spacing: 0.04em;
  padding: 10px 16px;
}

/* ===== Header ===== */
.site-header {
  position: sticky;
  top: 0;
  z-index: 70;
  display: flex;
  align-items: center;
  justify-content: space-between;
  /* La barra blanca ocupa todo el ancho; el contenido se alinea con .container */
  padding: 16px max(24px, calc((100% - var(--max-width)) / 2 + 24px));
  background: var(--color-white);
  border-bottom: 1px solid #ececec;
  box-shadow: 0 1px 0 rgba(0,0,0,0.02), 0 8px 24px -20px rgba(0,0,0,0.25);
}

.logo {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-display);
  font-size: 24px;
  font-weight: 700;
  letter-spacing: 0.02em;
  color: var(--color-black);
}

.logo .accent { color: var(--color-olive); }

.brand-crest {
  width: auto;
  height: 46px;
  flex-shrink: 0;
}

.main-nav {
  display: flex;
  gap: 36px;
}

.main-nav a {
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--color-black);
  padding-bottom: 6px;
  border-bottom: 2px solid transparent;
}

.main-nav a.active,
.main-nav a:hover {
  border-bottom-color: var(--color-olive);
}

.header-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
  min-width: 40px; /* reserva el espacio del carrito para que el menú no se mueva */
}

.cart-button.is-empty { display: none; }

.cart-button:not(.is-empty) { animation: cart-in 0.25s ease-out; }

@keyframes cart-in {
  from { opacity: 0; transform: scale(0.8); }
  to { opacity: 1; transform: scale(1); }
}

.icon-button {
  position: relative;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: var(--color-black);
  border: none;
  padding: 0;
  transition: background 0.15s ease;
}

.icon-button:hover {
  background: var(--color-olive);
}

.icon-button svg {
  width: 19px;
  height: 19px;
  stroke: var(--color-cream);
}

.cart-button {
  /* alias de icon-button para el carrito */
}

.cart-count {
  position: absolute;
  top: -4px;
  right: -4px;
  background: var(--color-olive);
  color: var(--color-white);
  font-size: 11px;
  font-weight: 700;
  min-width: 18px;
  height: 18px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 4px;
}

.nav-toggle {
  display: none;
  background: none;
  border: none;
}

/* ===== Hero ===== */
.hero {
  position: relative;
  background: #8A7E5E url("../img/brand/fondo.jpg") center / cover no-repeat;
  color: var(--color-black);
  overflow: hidden;
}

.hero-inner {
  position: relative;
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 100px 24px 96px;
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  align-items: center;
  gap: 40px;
}

.hero-eyebrow {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 22px;
}

.hero-eyebrow .line {
  width: 32px;
  height: 2px;
  background: currentColor;
  opacity: 0.6;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  background: var(--color-cream);
  color: var(--color-black);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  padding: 7px 16px;
  border-radius: 999px;
  box-shadow: 0 8px 20px -8px rgba(0,0,0,0.45);
}

.hero h1 {
  font-family: var(--font-display);
  font-size: 60px;
  line-height: 1.05;
  letter-spacing: -0.01em;
  margin: 0 0 22px;
  color: var(--color-black);
}

.hero p {
  font-size: 17px;
  line-height: 1.65;
  color: var(--color-black);
  opacity: 0.85;
  max-width: 460px;
  margin: 0 0 36px;
}

.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 0.04em;
  padding: 16px 30px;
  border-radius: 4px;
  border: 2px solid transparent;
  transition: transform 0.18s ease, box-shadow 0.18s ease, background 0.15s ease, color 0.15s ease;
}

.btn:hover { transform: translateY(-2px); }

.btn-primary {
  background: var(--color-white);
  color: var(--color-black);
  box-shadow: 0 14px 30px -12px rgba(0,0,0,0.5);
}

.btn-primary:hover {
  background: var(--color-cream);
  box-shadow: 0 18px 34px -12px rgba(0,0,0,0.55);
}

.btn-dark {
  background: var(--color-black);
  color: var(--color-white);
}

.btn-dark:hover {
  background: var(--color-olive);
}

.btn-outline {
  background: transparent;
  border-color: var(--color-cream);
  color: var(--color-cream);
}

.hero .btn-outline { border-color: var(--color-black); color: var(--color-black); }
.hero .btn-outline:hover { background: var(--color-black); color: var(--color-cream); }

.hero-art {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
}

.hero-art svg {
  width: 100%;
  max-width: 400px;
  height: auto;
  filter: drop-shadow(0 30px 40px rgba(0,0,0,0.35));
}

/* ===== Secciones generales ===== */
.section {
  padding: 72px 0;
}

.section-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  margin-bottom: 36px;
  flex-wrap: wrap;
  gap: 16px;
}

.section-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--color-olive);
  margin-bottom: 10px;
}

.section-eyebrow::before {
  content: "";
  width: 22px;
  height: 2px;
  background: var(--color-olive);
}

.section-head h1,
.section-head h2 {
  font-family: var(--font-display);
  font-size: 36px;
  letter-spacing: -0.01em;
  margin: 0 0 8px;
}

.section-head p {
  margin: 0;
  color: #666;
  font-size: 15px;
}

.section-link {
  font-size: 14px;
  font-weight: 700;
  border-bottom: 2px solid var(--color-olive);
  padding-bottom: 3px;
  white-space: nowrap;
  transition: opacity 0.15s ease;
}

.section-link:hover { opacity: 0.65; }

/* ===== Grid de productos ===== */
.product-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
}

.product-card {
  border: 1px solid #f0efe9;
  border-radius: 10px;
  overflow: hidden;
  background: var(--color-white);
  display: flex;
  flex-direction: column;
  box-shadow: 0 1px 2px rgba(0,0,0,0.03);
  transition: box-shadow 0.25s ease, transform 0.25s ease, border-color 0.25s ease;
}

.product-card:hover {
  box-shadow: 0 22px 40px -20px rgba(0,0,0,0.22);
  transform: translateY(-4px);
  border-color: #e8e5da;
}

.product-media {
  position: relative;
  aspect-ratio: 4 / 5;
  background: linear-gradient(150deg, #F2EFE6 0%, #E7E1D2 100%);
  display: flex;
  align-items: center;
  justify-content: center;
}

.product-media svg {
  width: 56%;
}

.product-badge {
  position: absolute;
  top: 12px;
  left: 12px;
  background: var(--color-black);
  color: var(--color-white);
  font-size: 10.5px;
  font-weight: 700;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  padding: 6px 11px;
  border-radius: 999px;
  box-shadow: 0 6px 14px -6px rgba(0,0,0,0.4);
}

.product-badge.stock-low {
  background: var(--color-olive);
}

.product-fav {
  position: absolute;
  top: 10px;
  right: 10px;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: rgba(255,255,255,0.9);
  border: none;
  display: flex;
  align-items: center;
  justify-content: center;
}

.product-info {
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  flex: 1;
}

.product-category {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--color-olive);
}

.product-name {
  font-size: 16px;
  font-weight: 600;
  margin: 0;
}

.product-desc {
  margin: 2px 0 4px;
  font-size: 13px;
  line-height: 1.55;
  color: #5f5f5f;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
  cursor: pointer;
}

.product-name a:hover, .product-desc:hover { color: var(--color-olive-dark); }

.product-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin: 2px 0 4px;
}

.product-tag {
  font-size: 11px;
  font-weight: 600;
  background: var(--color-cream);
  color: var(--color-olive-dark);
  padding: 3px 9px;
  border-radius: 999px;
}

.product-tag-outline {
  background: transparent;
  border: 1px solid #ddd;
  color: #666;
}

.product-sizes {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
  margin: 4px 0;
}

.size-chip {
  border: 1px solid #ddd;
  background: var(--color-white);
  font-size: 12px;
  font-weight: 600;
  min-width: 32px;
  padding: 6px 9px;
  border-radius: 999px;
  color: var(--color-black);
  transition: all 0.15s ease;
}

.size-chip:not(:disabled):hover {
  border-color: var(--color-black);
}

.size-chip.selected {
  border-color: var(--color-black);
  background: var(--color-black);
  color: var(--color-white);
}

.size-chip:disabled {
  opacity: 0.35;
  text-decoration: line-through;
  cursor: not-allowed;
}

.product-footer {
  margin-top: auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding-top: 8px;
}

.product-price {
  font-size: 16px;
  font-weight: 700;
}

.btn-add {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: var(--color-black);
  color: var(--color-white);
  border: none;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.01em;
  padding: 10px 16px;
  border-radius: 999px;
  transition: background 0.15s ease, transform 0.15s ease;
}

.btn-add:hover { background: var(--color-olive); transform: translateY(-1px); }

.btn-add:disabled {
  background: #ccc;
  cursor: not-allowed;
}

/* ===== Retros (franjas alternadas) ===== */
.retro-hero {
  padding: 56px 0 8px;
  text-align: center;
}

.retro-hero h1 {
  font-family: var(--font-display);
  font-size: 40px;
  margin: 0 0 10px;
}

.retro-hero p {
  color: #666;
  max-width: 520px;
  margin: 0 auto;
}

.retro-band {
  padding: 56px 0;
}

.retro-band:nth-child(odd) {
  background: var(--color-olive);
  color: var(--color-cream);
}

.retro-band:nth-child(even) {
  background: var(--color-cream);
  color: var(--color-black);
}

.retro-band-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 24px;
  display: grid;
  grid-template-columns: 1fr 0.6fr 1fr;
  align-items: center;
  gap: 32px;
}

.retro-photo-placeholder {
  aspect-ratio: 4 / 5;
  border-radius: 10px;
  border: 1.5px dashed currentColor;
  opacity: 0.85;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 12px;
  text-align: center;
  padding: 20px;
}

.retro-photo {
  aspect-ratio: 4 / 5;
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 20px 40px -20px rgba(0,0,0,0.4);
}

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

.retro-jersey-thumb.retro-jersey-photo {
  padding: 0;
  overflow: hidden;
  aspect-ratio: 4 / 5;
}

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

.retro-photo-placeholder svg {
  width: 40%;
  opacity: 0.7;
}

.retro-photo-placeholder span {
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.03em;
  opacity: 0.75;
}

.retro-jersey-stack {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.retro-jersey-thumb {
  background: linear-gradient(150deg, #F2EFE6 0%, #E7E1D2 100%);
  border-radius: 8px;
  box-shadow: 0 10px 24px -14px rgba(0,0,0,0.35);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 10px;
}

.retro-jersey-thumb svg { width: 80%; }

.retro-category {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  opacity: 0.75;
}

.retro-info h3 {
  font-family: var(--font-display);
  font-size: 26px;
  margin: 6px 0 8px;
}

.retro-info .product-tag {
  background: rgba(255,255,255,0.18);
  color: inherit;
}

.retro-band:nth-child(even) .retro-info .product-tag {
  background: var(--color-white);
  color: var(--color-olive-dark);
}

.retro-info .product-sizes { margin: 12px 0; }

.retro-band:nth-child(odd) .size-chip {
  border-color: rgba(250,249,245,0.5);
  background: transparent;
  color: var(--color-cream);
}

.retro-band:nth-child(odd) .size-chip.selected {
  background: var(--color-cream);
  color: var(--color-black);
  border-color: var(--color-cream);
}

.retro-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-top: 10px;
}

.retro-footer .product-price {
  font-size: 22px;
  font-family: var(--font-display);
}

.retro-band:nth-child(odd) .btn-add {
  background: var(--color-cream);
  color: var(--color-black);
}

.retro-band:nth-child(odd) .btn-add:hover {
  background: var(--color-white);
}

@media (max-width: 900px) {
  .retro-band-inner { grid-template-columns: 1fr; text-align: center; }
  .retro-jersey-stack { flex-direction: row; justify-content: center; }
  .retro-jersey-thumb { width: 140px; }
  .retro-info .product-sizes { justify-content: center; }
  .retro-footer { justify-content: center; flex-direction: column; }
}

/* ===== Filtros catálogo ===== */
.catalog-toolbar {
  display: flex;
  gap: 14px;
  flex-wrap: wrap;
  align-items: center;
  margin-bottom: 32px;
  padding: 18px;
  background: var(--color-cream);
  border-radius: 8px;
}

.catalog-toolbar select,
.catalog-toolbar input {
  font-family: inherit;
  font-size: 14px;
  padding: 10px 12px;
  border: 1px solid #ddd;
  border-radius: 4px;
  background: var(--color-white);
}

.catalog-toolbar .results-count {
  margin-left: auto;
  font-size: 13px;
  color: #666;
}

.empty-state {
  text-align: center;
  padding: 60px 20px;
  color: #777;
}

/* ===== Footer ===== */
.site-footer {
  background: var(--color-black);
  color: var(--color-cream);
  padding: 64px 0 24px;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1fr;
  gap: 40px;
  padding-bottom: 40px;
}

.footer-brand .logo { color: var(--color-white); }

.footer-logo { display: inline-block; }
.footer-logo img { width: auto; height: 160px; }

.footer-brand p {
  color: #bdb9ab;
  font-size: 14px;
  line-height: 1.6;
  margin-top: 14px;
  max-width: 280px;
}

.footer-col h4 {
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin: 0 0 16px;
  color: var(--color-white);
}

.footer-col a,
.footer-col li {
  display: block;
  font-size: 14px;
  color: #bdb9ab;
  margin-bottom: 10px;
}

.footer-col a:hover { color: var(--color-white); }

.footer-contact-item,
.footer-col a.footer-contact-item {
  display: flex;
  align-items: center;
  gap: 10px;
}

.footer-contact-item .social-icon { width: 20px; height: 20px; flex-shrink: 0; }
a.footer-contact-item:hover span { text-decoration: underline; }

.footer-bottom {
  border-top: 1px solid rgba(255,255,255,0.1);
  padding-top: 22px;
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 10px;
  font-size: 13px;
  color: #8f8b7d;
}

/* ===== Carrito (drawer) ===== */
.cart-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.5);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s ease;
  z-index: 90;
}

.cart-overlay.open {
  opacity: 1;
  pointer-events: auto;
}

.cart-drawer {
  position: fixed;
  top: 0;
  right: 0;
  height: 100%;
  width: 420px;
  max-width: 92vw;
  background: var(--color-white);
  z-index: 91;
  display: flex;
  flex-direction: column;
  transform: translateX(100%);
  transition: transform 0.3s ease;
  box-shadow: -10px 0 30px rgba(0,0,0,0.15);
}

.cart-drawer.open { transform: translateX(0); }

.cart-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px;
  border-bottom: 1px solid #eee;
}

.cart-header h3 {
  font-family: var(--font-display);
  margin: 0;
  font-size: 22px;
}

.cart-close {
  background: none;
  border: none;
  font-size: 22px;
  line-height: 1;
}

.cart-items {
  flex: 1;
  overflow-y: auto;
  padding: 8px 20px;
}

.cart-item {
  display: grid;
  grid-template-columns: 56px 1fr auto;
  gap: 12px;
  padding: 16px 0;
  border-bottom: 1px solid #f1f1f1;
  align-items: center;
}

.cart-item-thumb {
  width: 64px;
  height: 80px;
  border-radius: 6px;
  overflow: hidden;
  background: linear-gradient(150deg, #F2EFE6 0%, #E7E1D2 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.cart-item-thumb svg { width: 70%; }
.cart-item-thumb img { width: 100%; height: 100%; object-fit: cover; }

.cart-item-name { font-size: 14px; font-weight: 600; margin: 0 0 2px; }
.cart-item-meta { font-size: 12px; color: #777; margin: 0 0 8px; }

.qty-control {
  display: inline-flex;
  align-items: center;
  border: 1px solid #ddd;
  border-radius: 4px;
}

.qty-control button {
  background: none;
  border: none;
  width: 26px;
  height: 26px;
  font-size: 14px;
}

.qty-control span {
  min-width: 24px;
  text-align: center;
  font-size: 13px;
}

.cart-item-price {
  font-size: 14px;
  font-weight: 700;
  text-align: right;
}

.cart-item-remove {
  display: inline-block;
  margin-top: 8px;
  margin-right: 12px;
  font-size: 12px;
  color: #999;
  background: none;
  border: none;
  text-decoration: underline;
  padding: 0;
}

.personalize-box {
  margin-top: 8px;
}

.personalize-box summary {
  font-size: 12px;
  font-weight: 600;
  color: var(--color-olive-dark);
  cursor: pointer;
}

.personalize-box input {
  display: block;
  width: 100%;
  font-size: 12px;
  font-family: inherit;
  padding: 7px 9px;
  margin-top: 6px;
  border: 1px solid #ddd;
  border-radius: 4px;
}

.cart-empty {
  padding: 60px 20px;
  text-align: center;
  color: #888;
}

.cart-footer {
  border-top: 1px solid #eee;
  padding: 20px;
}

.cart-total-row {
  display: flex;
  justify-content: space-between;
  font-size: 16px;
  font-weight: 700;
  margin-bottom: 16px;
}

.whatsapp-btn {
  width: 100%;
  justify-content: center;
  gap: 10px;
  background: var(--color-black);
  color: var(--color-cream);
}

.whatsapp-btn:hover { background: var(--color-olive); transform: none; }

.whatsapp-btn svg { width: 18px; height: 18px; flex-shrink: 0; }

.cart-shipping {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  margin: 8px 0 0;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.02em;
  color: var(--color-olive-dark);
}

.cart-shipping svg { width: 16px; height: 16px; flex-shrink: 0; }

.cart-note {
  font-size: 12px;
  color: #888;
  margin-top: 10px;
  text-align: center;
}

/* ===== Responsive ===== */
@media (max-width: 900px) {
  .hero-inner { grid-template-columns: 1fr; text-align: center; }
  .hero p { margin-left: auto; margin-right: auto; }
  .hero-art { order: -1; }
  .product-grid { grid-template-columns: repeat(2, 1fr); }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .main-nav { display: none; }
}

@media (max-width: 520px) {
  .hero h1 { font-size: 38px; }
  .product-grid { grid-template-columns: 1fr 1fr; gap: 14px; }
  .footer-grid { grid-template-columns: 1fr; }
  .cart-drawer { width: 100%; }
}

/* =====================================================================
   v2 — loader 3D, portada, filtros, Mystery Box
   ===================================================================== */

/* ===== Pantalla de carga ===== */
html.loader-active { overflow: hidden; }

.page-loader {
  position: fixed;
  inset: 0;
  z-index: 200;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 18px;
  background: #8A7E5E url("../img/brand/fondo.jpg") center / cover no-repeat;
  color: var(--color-black);
  transition: opacity 0.55s ease, visibility 0.55s ease;
}

.page-loader.is-hidden {
  opacity: 0;
  visibility: hidden;
}

.loader-logo {
  width: auto;
  height: min(240px, 36vh);
  animation: loader-in 0.5s ease-out both;
}

@keyframes loader-in {
  from { opacity: 0; transform: scale(0.94); }
  to { opacity: 1; transform: scale(1); }
}

.loader-bar {
  width: 96px;
  margin-top: 10px;
  height: 2px;
  background: rgba(0,0,0,0.15);
  overflow: hidden;
  border-radius: 2px;
}

.loader-bar::after {
  content: "";
  display: block;
  width: 40%;
  height: 100%;
  background: var(--color-black);
  animation: loader-bar 1.1s ease-in-out infinite;
}

@keyframes loader-bar {
  from { transform: translateX(-100%); }
  to { transform: translateX(250%); }
}

@media (prefers-reduced-motion: reduce) {
  .loader-logo, .loader-bar::after, .cart-button { animation: none; }
  .main-nav, .main-nav a, .nav-toggle span, .filter-collapse, .filter-panel { transition: none !important; }
  .page-loader { transition: none; }
}

/* ===== Fotos de producto ===== */
.product-media { overflow: hidden; }

.product-media .product-photo {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.4s ease;
}

.product-card:hover .product-photo { transform: scale(1.04); }

.product-badge { z-index: 1; }
.product-badge.badge-limited { background: #B5A477; color: var(--color-black); }
.product-badge.badge-sale { background: #B3261E; }

.product-price-old {
  font-size: 12px;
  font-weight: 500;
  color: #999;
  margin-left: 4px;
}

/* ===== Portada: nueva colección ===== */
.hero-collection-art {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  max-width: 460px;
  width: 100%;
}

.hero-collection-art .hero-tile {
  aspect-ratio: 4 / 5;
  border-radius: 10px;
  overflow: hidden;
  background: rgba(250,249,245,0.22);
  border: 1px solid rgba(0,0,0,0.12);
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 30px 50px -25px rgba(0,0,0,0.6);
}

.hero-collection-art .hero-tile:nth-child(2) { transform: translateY(32px); }
.hero-collection-art .hero-tile img { width: 100%; height: 100%; object-fit: cover; }
.hero-collection-art .hero-tile svg { width: 70%; }

.hero-actions { display: flex; gap: 12px; flex-wrap: wrap; }

/* ===== Categorías ===== */
.category-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
}

.category-tile {
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  min-height: 150px;
  padding: 20px;
  border-radius: 10px;
  background: var(--color-cream);
  border: 1px solid #ece9df;
  transition: transform 0.2s ease, background 0.2s ease, color 0.2s ease;
}

.category-tile:hover { transform: translateY(-3px); background: var(--color-black); color: var(--color-cream); }

.category-tile .category-count {
  position: absolute;
  top: 18px;
  right: 20px;
  font-size: 12px;
  font-weight: 700;
  color: var(--color-olive);
}

.category-tile h3 {
  font-family: var(--font-display);
  font-size: 24px;
  margin: 0 0 4px;
}

.category-tile p { margin: 0; font-size: 13px; opacity: 0.7; }

/* ===== Banner Mystery Box ===== */
.mystery-banner {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 32px;
  padding: 40px;
  border-radius: 14px;
  background:
    radial-gradient(ellipse at 0% 0%, rgba(122,109,78,0.45), transparent 55%),
    var(--color-black);
  color: var(--color-cream);
}

.mystery-banner svg { width: 120px; }

.mystery-banner h2 {
  font-family: var(--font-display);
  font-size: 34px;
  margin: 0 0 8px;
  color: var(--color-white);
}

.mystery-banner p { margin: 0; opacity: 0.8; line-height: 1.6; }

.section-cta { display: flex; justify-content: center; margin-top: 40px; }

/* ===== Catálogo: filtros ===== */
.catalog-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 20px;
}

.catalog-bar .results-count { font-size: 13px; color: #666; }

.filter-toggle {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 18px;
  border: 1px solid #d9d5c8;
  border-radius: 999px;
  background: var(--color-white);
  font-size: 14px;
  font-weight: 600;
  color: var(--color-black);
  transition: border-color 0.15s ease, background 0.15s ease, color 0.15s ease;
}

.filter-toggle:hover { border-color: var(--color-black); }
.filter-toggle[aria-expanded="true"] { background: var(--color-black); border-color: var(--color-black); color: var(--color-white); }
.filter-toggle svg { width: 18px; height: 18px; }

.filter-badge {
  min-width: 20px;
  height: 20px;
  padding: 0 6px;
  border-radius: 999px;
  background: var(--color-olive);
  color: var(--color-white);
  font-size: 11px;
  font-weight: 700;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.filter-badge[hidden] { display: none; }

/* Panel plegable: se abre con una animación de altura */
.filter-collapse {
  display: grid;
  grid-template-rows: 0fr;
  opacity: 0;
  transition: grid-template-rows 0.35s ease, opacity 0.25s ease;
}

.filter-collapse.open { grid-template-rows: 1fr; opacity: 1; }
.filter-collapse > .filter-panel { overflow: hidden; min-height: 0; }
.filter-collapse:not(.open) > .filter-panel { padding-top: 0; padding-bottom: 0; margin-bottom: 0; visibility: hidden; }

.filter-panel {
  display: flex;
  flex-direction: column;
  gap: 16px;
  margin-bottom: 32px;
  transition: padding 0.35s ease, margin 0.35s ease, visibility 0.35s;
  padding: 20px;
  background: var(--color-cream);
  border-radius: 10px;
}

.filter-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px 14px;
}

.filter-label {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--color-olive-dark);
  min-width: 64px;
}

.chip {
  border: 1px solid #d9d5c8;
  background: var(--color-white);
  font-size: 13px;
  font-weight: 600;
  padding: 8px 14px;
  border-radius: 999px;
  color: var(--color-black);
  transition: background 0.15s ease, color 0.15s ease, border-color 0.15s ease;
}

.chip:hover { border-color: var(--color-black); }

.chip[aria-pressed="true"] {
  background: var(--color-black);
  border-color: var(--color-black);
  color: var(--color-white);
}

.filter-panel input,
.filter-panel select {
  font-family: inherit;
  font-size: 14px;
  padding: 9px 12px;
  border: 1px solid #d9d5c8;
  border-radius: 6px;
  background: var(--color-white);
}

.filter-panel input[type="number"] { width: 110px; }
.filter-panel input[type="search"] { flex: 1; min-width: 180px; }


.filter-clear {
  background: none;
  border: none;
  font-size: 13px;
  font-weight: 600;
  text-decoration: underline;
  color: var(--color-olive-dark);
  padding: 0;
}

/* ===== Mystery Box ===== */
.mystery-hero {
  background:
    radial-gradient(ellipse at 80% 0%, rgba(122,109,78,0.5), transparent 55%),
    var(--color-black);
  color: var(--color-cream);
  padding: 80px 0 64px;
}

.mystery-hero .container {
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: 40px;
  align-items: center;
}

.mystery-hero h1 {
  font-family: var(--font-display);
  font-size: 54px;
  line-height: 1.05;
  margin: 0 0 18px;
  color: var(--color-white);
}

.mystery-hero p { font-size: 17px; line-height: 1.65; opacity: 0.85; max-width: 520px; margin: 0; }
.mystery-hero-art { display: flex; justify-content: center; }
.mystery-hero-art svg { width: min(260px, 60vw); filter: drop-shadow(0 30px 40px rgba(0,0,0,0.5)); }

.mystery-how {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}

.mystery-how-item {
  padding: 24px;
  border-radius: 10px;
  background: var(--color-cream);
}

.mystery-how-item strong {
  display: block;
  font-family: var(--font-display);
  font-size: 34px;
  color: var(--color-olive);
  margin-bottom: 6px;
}

.mystery-how-item h3 { margin: 0 0 6px; font-size: 16px; }
.mystery-how-item p { margin: 0; font-size: 14px; color: #555; line-height: 1.55; }

.mystery-builder { display: flex; flex-direction: column; gap: 28px; }

.builder-step h3 {
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--color-olive-dark);
  margin: 0 0 14px;
}

.box-size-options {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 14px;
}

.box-size {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 4px;
  padding: 22px;
  border: 2px solid #e6e2d6;
  border-radius: 12px;
  background: var(--color-white);
  text-align: left;
  transition: border-color 0.15s ease, background 0.15s ease, color 0.15s ease;
}

.box-size:hover { border-color: var(--color-black); }

.box-size[aria-pressed="true"] {
  border-color: var(--color-black);
  background: var(--color-black);
  color: var(--color-cream);
}

.box-size .box-size-num {
  font-family: var(--font-display);
  font-size: 40px;
  font-weight: 700;
  line-height: 1;
}

.box-size .box-size-label { font-size: 13px; opacity: 0.75; }
.box-size .box-size-price { font-size: 17px; font-weight: 700; margin-top: 8px; }
.box-size .box-size-each { font-size: 12px; opacity: 0.65; }

.combo-options {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 14px;
}

.combo-option {
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: 18px;
  border: 2px solid #e6e2d6;
  border-radius: 12px;
  background: var(--color-white);
  text-align: left;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.combo-option:hover { border-color: var(--color-black); }

.combo-option[aria-pressed="true"] {
  border-color: var(--color-olive);
  box-shadow: 0 0 0 3px rgba(122,109,78,0.2);
}

.combo-option .combo-title { font-size: 15px; font-weight: 700; }

.combo-slots { display: flex; flex-wrap: wrap; gap: 6px; }

.combo-slot {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  padding: 5px 9px;
  border-radius: 6px;
}

.combo-slot.cat-retro { background: #000; color: #FAF9F5; }
.combo-slot.cat-seleccion { background: #7A6D4E; color: #fff; }
.combo-slot.cat-club { background: #E7E1D2; color: #000; }
.combo-slot.cat-limitada { background: #B5A477; color: #000; }

.builder-extra {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  align-items: flex-end;
}

.builder-extra label { display: flex; flex-direction: column; gap: 6px; font-size: 13px; font-weight: 600; }

.builder-extra select,
.builder-extra input {
  font-family: inherit;
  font-size: 14px;
  padding: 11px 12px;
  border: 1px solid #d9d5c8;
  border-radius: 6px;
}

.builder-extra label.grow { flex: 1; min-width: 220px; }

.builder-summary {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 20px 24px;
  border-radius: 12px;
  background: var(--color-cream);
}

.builder-summary .summary-text { font-size: 15px; }
.builder-summary .summary-price { font-size: 24px; font-weight: 700; }

/* ===== Responsive v2 ===== */
@media (max-width: 900px) {
  /* Menú de tres rayitas */
  .nav-toggle {
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 5px;
    width: 40px;
    height: 40px;
    padding: 0 9px;
  }
  .nav-toggle span {
    display: block;
    height: 2px;
    border-radius: 2px;
    background: var(--color-black);
    transition: transform 0.3s ease, opacity 0.2s ease;
  }
  .nav-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
  .nav-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; transform: scaleX(0); }
  .nav-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

  .main-nav {
    display: flex;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    flex-direction: column;
    gap: 0;
    padding: 4px 24px 18px;
    background: var(--color-white);
    border-bottom: 1px solid #ececec;
    box-shadow: 0 18px 30px -22px rgba(0,0,0,0.35);
    opacity: 0;
    visibility: hidden;
    transform: translateY(-8px);
    transition: opacity 0.25s ease, transform 0.25s ease, visibility 0.25s;
  }
  .main-nav.open { opacity: 1; visibility: visible; transform: none; }
  .main-nav a {
    font-size: 15px;
    padding: 16px 0;
    border-bottom: 1px solid #f0efe9;
    opacity: 0;
    transform: translateY(-6px);
    transition: opacity 0.3s ease, transform 0.3s ease, color 0.15s ease;
  }
  .main-nav a:last-child { border-bottom: none; }
  .main-nav a.active, .main-nav a:hover { color: var(--color-olive); border-bottom-color: #f0efe9; }
  .main-nav.open a { opacity: 1; transform: none; }
  .main-nav.open a:nth-child(1) { transition-delay: 0.05s; }
  .main-nav.open a:nth-child(2) { transition-delay: 0.1s; }
  .main-nav.open a:nth-child(3) { transition-delay: 0.15s; }
  .category-grid { grid-template-columns: repeat(2, 1fr); }
  .mystery-banner { grid-template-columns: 1fr; text-align: center; justify-items: center; padding: 32px 24px; }
  .mystery-hero .container { grid-template-columns: 1fr; text-align: center; }
  .mystery-hero p { margin: 0 auto; }
  .mystery-hero-art { order: -1; }
  .mystery-how,
  .combo-options { grid-template-columns: 1fr; }
  .hero-collection-art { margin: 0 auto; }
}

@media (max-width: 520px) {
  .container { padding: 0 16px; }
  .site-header { padding: 12px 16px; }
  .mystery-hero h1 { font-size: 38px; }
  .mystery-banner h2 { font-size: 28px; }
  .box-size-options { grid-template-columns: repeat(2, 1fr); }
  .box-size { padding: 14px; }
  .box-size .box-size-num { font-size: 30px; }
  .box-size .box-size-price { font-size: 14px; }
  .filter-label { min-width: 100%; }
  .filter-panel input[type="number"] { width: calc(50% - 20px); }
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

/* ===== Páginas legales ===== */
.legal { max-width: 760px; }
.legal h1 { font-family: var(--font-display); font-size: 40px; margin: 0 0 6px; }
.legal-date { color: #777; font-size: 13px; margin: 0 0 32px; }
.legal h2 { font-size: 18px; margin: 32px 0 10px; }
.legal p, .legal li { font-size: 15px; line-height: 1.7; color: #333; }
.legal ul, .legal ol { padding-left: 22px; }
.legal a { text-decoration: underline; color: var(--color-olive-dark); }
.legal-fill { background: #FFF3C4; color: #6B4E00; padding: 0 4px; border-radius: 3px; font-weight: 600; }

/* ===== Página de detalle de una jersey ===== */
.pd-section { padding-top: 32px; }

.pd-breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  font-size: 13px;
  color: #888;
  margin-bottom: 24px;
}

.pd-breadcrumb a { color: var(--color-olive-dark); }
.pd-breadcrumb a:hover { text-decoration: underline; }

.pd-layout {
  display: grid;
  grid-template-columns: minmax(0, 420px) minmax(0, 1fr);
  gap: 56px;
  align-items: start;
  max-width: 1080px;
}

.pd-gallery { position: sticky; top: 100px; }

.pd-main {
  aspect-ratio: 4 / 5;
  border-radius: 12px;
  overflow: hidden;
  background: linear-gradient(150deg, #F2EFE6 0%, #E7E1D2 100%);
  display: flex;
  align-items: center;
  justify-content: center;
}

.pd-main img { width: 100%; height: 100%; object-fit: cover; }
.pd-main svg { width: 55%; }

.pd-thumbs { display: flex; gap: 10px; margin-top: 12px; flex-wrap: wrap; }

.pd-thumb {
  width: 76px;
  aspect-ratio: 4 / 5;
  padding: 0;
  border: 2px solid transparent;
  border-radius: 8px;
  overflow: hidden;
  background: none;
  opacity: 0.65;
  transition: opacity 0.15s ease, border-color 0.15s ease;
}

.pd-thumb img { width: 100%; height: 100%; object-fit: cover; }
.pd-thumb:hover { opacity: 1; }
.pd-thumb[aria-pressed="true"] { opacity: 1; border-color: var(--color-black); }

.pd-info { display: flex; flex-direction: column; gap: 14px; }

.pd-title {
  font-family: var(--font-display);
  font-size: 40px;
  line-height: 1.1;
  margin: 0;
}

.pd-price .product-price { font-size: 24px; }

.pd-desc { font-size: 15px; line-height: 1.7; color: #444; margin: 4px 0 0; }

.pd-specs {
  list-style: none;
  margin: 4px 0 0;
  padding: 0;
  border-top: 1px solid #ece9df;
}

.pd-specs li {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  padding: 11px 0;
  border-bottom: 1px solid #ece9df;
  font-size: 14px;
}

.pd-specs span { color: #777; }
.pd-specs strong { font-weight: 600; text-align: right; }

.pd-buy { display: flex; flex-direction: column; gap: 10px; margin-top: 8px; }

.pd-size-head {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.pd-stock { letter-spacing: 0; text-transform: none; font-weight: 600; color: var(--color-olive-dark); }
.pd-buy .size-chip { min-width: 46px; padding: 10px 14px; font-size: 14px; }
.pd-add { justify-content: center; width: 100%; margin-top: 6px; }
.pd-add:disabled { background: #ccc; cursor: not-allowed; transform: none; }
.pd-error { margin: 0; min-height: 1em; font-size: 13px; color: #B3261E; }
.pd-note { font-size: 12px; color: #888; margin: 0; }

.pd-empty { text-align: center; padding: 60px 0; }
.pd-empty h1 { font-family: var(--font-display); }
.pd-empty p { color: #666; margin-bottom: 24px; }

@media (max-width: 900px) {
  .pd-layout { grid-template-columns: 1fr; gap: 24px; }
  .pd-gallery { max-width: 360px; width: 100%; margin: 0 auto; }
  .pd-gallery { position: static; }
  .pd-title { font-size: 30px; }
}

/* Foto principal: clic para verla en grande */
.pd-zoomable {
  position: relative;
  width: 100%;
  padding: 0;
  border: none;
  cursor: zoom-in;
}

.pd-zoom-hint {
  position: absolute;
  right: 10px;
  bottom: 10px;
  padding: 5px 10px;
  border-radius: 999px;
  background: rgba(0,0,0,0.65);
  color: #fff;
  font-size: 11px;
  font-weight: 600;
  opacity: 0;
  transition: opacity 0.2s ease;
}

.pd-zoomable:hover .pd-zoom-hint,
.pd-zoomable:focus-visible .pd-zoom-hint { opacity: 1; }

@media (hover: none) { .pd-zoom-hint { opacity: 1; } }

/* Visor en grande */
html.lightbox-open { overflow: hidden; }

.pd-lightbox {
  position: fixed;
  inset: 0;
  z-index: 150;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 56px 64px;
  background: rgba(0,0,0,0.9);
  animation: lb-in 0.2s ease-out;
}

.pd-lightbox[hidden] { display: none; }

@keyframes lb-in { from { opacity: 0; } to { opacity: 1; } }

.pd-lb-img {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
  border-radius: 6px;
}

.pd-lb-close,
.pd-lb-nav {
  position: absolute;
  display: flex;
  align-items: center;
  justify-content: center;
  border: none;
  border-radius: 50%;
  background: rgba(255,255,255,0.12);
  color: #fff;
  transition: background 0.15s ease;
}

.pd-lb-close:hover, .pd-lb-nav:hover { background: rgba(255,255,255,0.25); }
.pd-lb-close { top: 14px; right: 14px; width: 42px; height: 42px; font-size: 18px; }
.pd-lb-nav { top: 50%; transform: translateY(-50%); width: 46px; height: 46px; font-size: 30px; line-height: 1; padding-bottom: 4px; }
.pd-lb-prev { left: 12px; }
.pd-lb-next { right: 12px; }

.pd-lb-count {
  position: absolute;
  bottom: 16px;
  left: 50%;
  transform: translateX(-50%);
  color: rgba(255,255,255,0.8);
  font-size: 13px;
}

@media (max-width: 600px) {
  .pd-lightbox { padding: 64px 12px; }
  .pd-lb-nav { top: auto; bottom: 8px; transform: none; }
  .pd-lb-prev { left: 16px; }
  .pd-lb-next { right: 16px; }
}

@media (prefers-reduced-motion: reduce) {
  .pd-lightbox { animation: none; }
}
