@import url('https://fonts.googleapis.com/css2?family=Dancing+Script:wght@600;700&family=Lato:wght@300;400;700&display=swap');

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --cream:       #fdfaf7;
  --white:       #ffffff;
  --charcoal:    #2c2824;
  --charcoal-60: rgba(44,40,36,0.6);
  --rose:        #c9907a;
  --rose-dark:   #b07a65;
  --rose-light:  #f5e8e3;
  --nude:        #d9bfac;
  --sand:        #ede5de;
  --sand-dark:   #ddd3c8;
  --text:        #2c2824;
  --text-muted:  #9e8e82;
  --border:      #ede5de;
  --radius:      14px;
  --radius-sm:   8px;
  --shadow:      0 2px 16px rgba(44,40,36,0.07);
  --shadow-hover:0 8px 32px rgba(44,40,36,0.13);
  --font-script: 'Dancing Script', cursive;
  --font-body:   'Lato', system-ui, sans-serif;
}

html { scroll-behavior: smooth; }

body {
  font-family: var(--font-body);
  background: var(--cream);
  color: var(--text);
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
}

/* ── HEADER ── */
header {
  background: var(--white);
  border-bottom: 1.5px solid var(--sand);
  position: sticky;
  top: 0;
  z-index: 100;
}

.header-inner {
  max-width: 1400px;
  margin: 0 auto;
  padding: 12px 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.header-brand {
  flex: 1;
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
}

.brand-logo {
  height: 36px;
  max-width: 120px;
  width: auto;
  object-fit: contain;
  flex-shrink: 0;
}

.brand-text {
  display: flex;
  flex-direction: column;
  gap: 1px;
  min-width: 0;
}

.brand-name {
  font-family: var(--font-script);
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--charcoal);
  line-height: 1;
  white-space: nowrap;
}

.header-brand h1 {
  font-family: var(--font-body);
  font-size: 0.6rem;
  font-weight: 700;
  color: var(--text-muted);
  letter-spacing: 2.5px;
  text-transform: uppercase;
  line-height: 1;
}

.header-brand p {
  font-family: var(--font-body);
  font-size: 0.58rem;
  color: var(--rose);
  letter-spacing: 2px;
  text-transform: uppercase;
  font-weight: 700;
}

@media (max-width: 480px) {
  .brand-logo { height: 28px; max-width: 90px; }
  .brand-name { font-size: 1.05rem; }
  .header-brand gap { gap: 8px; }
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
}

.search-btn {
  background: none;
  border: 1.5px solid var(--border);
  border-radius: 50%;
  width: 38px;
  height: 38px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  color: var(--charcoal);
  transition: border-color 0.2s, background 0.2s;
  flex-shrink: 0;
}
.search-btn:hover { border-color: var(--charcoal); background: var(--sand); }

.cart-btn {
  background: var(--charcoal);
  color: var(--white);
  border: none;
  border-radius: 50px;
  padding: 10px 20px;
  font-family: var(--font-body);
  font-weight: 700;
  font-size: 0.82rem;
  letter-spacing: 0.5px;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 8px;
  white-space: nowrap;
  transition: background 0.2s, transform 0.1s;
  flex-shrink: 0;
}
.cart-btn:hover { background: var(--rose-dark); }
.cart-btn:active { transform: scale(0.97); }

.cart-count {
  color: var(--white);
  display: flex;
  align-items: center;
  justify-content: center;
}

/* ── FILTROS ── */
.filters-bar {
  background: var(--white);
  border-bottom: 1px solid var(--sand);
  position: sticky;
  top: 66px;
  z-index: 90;
  display: flex;
  align-items: stretch;
}

.filters-inner {
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 24px;
  display: flex;
  gap: 0;
  overflow-x: auto;
  scrollbar-width: none;
  -webkit-overflow-scrolling: touch;
  flex: 1;
}
.filters-inner::-webkit-scrollbar { display: none; }

.filters-all-wrap {
  flex-shrink: 0;
  display: flex;
  align-items: stretch;
  background: var(--white);
}

.filter-btn {
  background: none;
  border: none;
  padding: 13px 18px;
  font-family: var(--font-body);
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.5px;
  color: var(--text-muted);
  cursor: pointer;
  white-space: nowrap;
  flex-shrink: 0;
  border-bottom: 2.5px solid transparent;
  transition: color 0.2s, border-color 0.2s;
}
.filter-btn:hover { color: var(--charcoal); }
.filter-btn.active { color: var(--charcoal); border-bottom-color: var(--rose); }

.filter-btn-all {
  color: var(--rose-dark);
  border-left: 1.5px solid var(--border);
  flex-shrink: 0;
}
.filter-btn-all.active { color: var(--rose-dark); border-bottom-color: var(--rose-dark); }

/* ── CATÁLOGO ── */
.catalog {
  max-width: 1400px;
  margin: 0 auto;
  padding: 32px 24px 80px;
}

.catalog-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(230px, 1fr));
  gap: 24px;
}

/* Vista completa por tipología */
.catalog-grid-full {
  display: block;
}

.catalog-section {
  margin-bottom: 52px;
}

.catalog-section-header {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-bottom: 20px;
}

.catalog-section-title {
  font-family: var(--font-script);
  font-size: 1.6rem;
  font-weight: 700;
  color: var(--charcoal);
  white-space: nowrap;
  line-height: 1;
}

.catalog-section-line {
  flex: 1;
  height: 1px;
  background: var(--border);
}

.catalog-section-count {
  font-size: 0.65rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  color: var(--text-muted);
  white-space: nowrap;
}

.catalog-section-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(210px, 1fr));
  gap: 20px;
}

/* ── PRODUCT CARD ── */
.product-card {
  background: var(--white);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  overflow: hidden;
  cursor: pointer;
  transition: box-shadow 0.25s, transform 0.25s;
  display: flex;
  flex-direction: column;
  border: 1.5px solid transparent;
}
.product-card:hover {
  box-shadow: var(--shadow-hover);
  transform: translateY(-3px);
  border-color: var(--sand-dark);
}

.card-img {
  width: 100%;
  aspect-ratio: 3/4;
  object-fit: cover;
  background: var(--sand);
  display: block;
}

.card-img-placeholder {
  width: 100%;
  aspect-ratio: 3/4;
  background: linear-gradient(135deg, #f5ede8 0%, #ede5de 100%);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 10px;
  color: var(--nude);
  font-size: 0.75rem;
  font-family: var(--font-body);
}
.card-img-placeholder svg { width: 36px; height: 36px; opacity: 0.45; }

.card-body {
  padding: 14px 16px 16px;
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 5px;
}

.card-art {
  font-size: 0.65rem;
  font-weight: 700;
  color: var(--text-muted);
  letter-spacing: 1.5px;
  text-transform: uppercase;
}

.card-name {
  font-size: 0.9rem;
  font-weight: 700;
  color: var(--charcoal);
  line-height: 1.3;
}

.card-talles {
  font-size: 0.75rem;
  color: var(--text-muted);
  font-weight: 400;
}

.card-colores {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  margin-top: 4px;
}

.color-chip {
  font-size: 0.68rem;
  background: var(--cream);
  border: 1px solid var(--border);
  border-radius: 20px;
  padding: 2px 8px;
  color: var(--text-muted);
  font-weight: 400;
}

.card-related-badge {
  font-size: 0.68rem;
  color: var(--rose-dark);
  font-weight: 700;
  display: flex;
  align-items: center;
  gap: 4px;
  margin-top: auto;
  padding-top: 8px;
  letter-spacing: 0.3px;
}

/* ── MODAL PRODUCTO ── */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(44,40,36,0.55);
  z-index: 200;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  padding: 0;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s, visibility 0.3s;
  backdrop-filter: blur(2px);
}
.modal-overlay.open { opacity: 1; visibility: visible; }

@media (min-width: 640px) {
  .modal-overlay { align-items: center; padding: 24px; }
}

.modal {
  background: var(--white);
  border-radius: var(--radius) var(--radius) 0 0;
  width: 100%;
  max-width: 960px;
  max-height: 88vh;
  overflow-y: auto;
  transform: translateY(40px);
  transition: transform 0.35s cubic-bezier(0.4,0,0.2,1);
  -webkit-overflow-scrolling: touch;
}
.modal-overlay.open .modal { transform: translateY(0); }

@media (min-width: 640px) {
  .modal { border-radius: var(--radius); max-height: 85vh; }
}

.modal-close {
  position: absolute;
  top: 14px;
  right: 14px;
  background: var(--white);
  border: 1.5px solid var(--border);
  width: 34px;
  height: 34px;
  border-radius: 50%;
  cursor: pointer;
  font-size: 1rem;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 10;
  color: var(--text-muted);
  transition: border-color 0.2s, color 0.2s;
}
.modal-close:hover { border-color: var(--charcoal); color: var(--charcoal); }

/* === OPCIÓN E — Modal con bastante aire arriba + X en zona segura === */
@media (max-width: 640px) {
  .modal-overlay {
    /* Padding arriba para que el modal NO arranque pegado a la URL bar */
    padding-top: 90px;
    align-items: stretch;
    box-sizing: border-box;
  }
  .modal {
    max-height: none;
    padding-top: 60px;
    position: relative;
  }
  .modal-close {
    position: absolute;
    top: 50px;
    right: 14px;
    width: 42px;
    height: 42px;
    font-size: 1.2rem;
    background: var(--white);
    box-shadow: 0 3px 12px rgba(44, 40, 36, 0.18);
    border-color: var(--sand);
    z-index: 50;
  }
}

.modal-inner {
  display: grid;
  grid-template-columns: 1fr;
  position: relative;
}
@media (min-width: 640px) {
  /* Imagen ocupa menos para dar más ancho a la tabla y evitar scroll horizontal */
  .modal-inner { grid-template-columns: 4fr 6fr; }
}

/* Galería */
.gallery {
  background: var(--cream);
  overflow: hidden;
  display: flex;
  flex-direction: row;
}

.gallery-thumbs {
  display: flex;
  flex-direction: column;
  gap: 5px;
  padding: 8px 6px;
  overflow-y: auto;
  overflow-x: hidden;
  background: var(--cream);
  scrollbar-width: none;
  flex-shrink: 0;
}
.gallery-thumbs::-webkit-scrollbar { display: none; }

.gallery-main {
  flex: 1;
  min-width: 0;
  aspect-ratio: 3/4;
  object-fit: cover;
  display: block;
  max-height: 420px;
}

.gallery-thumb {
  width: 46px;
  height: 46px;
  object-fit: cover;
  border-radius: 6px;
  cursor: pointer;
  opacity: 0.55;
  border: 2px solid transparent;
  flex-shrink: 0;
  transition: opacity 0.2s, border-color 0.2s;
}
.gallery-thumb.active, .gallery-thumb:hover {
  opacity: 1;
  border-color: var(--rose);
}

/* Detalle producto */
.product-detail {
  padding: 20px 20px 24px;
  display: flex;
  flex-direction: column;
  gap: 14px;
  overflow-y: auto;
}

.detail-cat {
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 2.5px;
  text-transform: uppercase;
  color: var(--rose);
}

.detail-name {
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--charcoal);
  line-height: 1.2;
  margin-top: -6px;
}

.detail-art {
  font-size: 0.75rem;
  color: var(--text-muted);
  font-weight: 700;
  letter-spacing: 0.5px;
  margin-top: -10px;
}

.selector-label {
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  color: var(--text-muted);
  margin-bottom: 7px;
}

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

.pill {
  padding: 7px 16px;
  border-radius: 50px;
  border: 1.5px solid var(--border);
  font-size: 0.8rem;
  font-weight: 700;
  cursor: pointer;
  background: var(--white);
  color: var(--charcoal);
  font-family: var(--font-body);
  transition: border-color 0.2s, background 0.2s, color 0.2s;
}
.pill:hover { border-color: var(--charcoal); }
.pill.selected { background: var(--charcoal); color: var(--white); border-color: var(--charcoal); }

.qty-row {
  display: flex;
  align-items: center;
  gap: 12px;
}
.qty-btn {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  border: 1.5px solid var(--border);
  background: var(--white);
  font-size: 1.1rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 300;
  color: var(--charcoal);
  transition: border-color 0.2s, background 0.2s;
  font-family: var(--font-body);
}
.qty-btn:hover { border-color: var(--charcoal); background: var(--cream); }
.qty-num { font-size: 1rem; font-weight: 700; min-width: 24px; text-align: center; }

.btn-add {
  background: var(--charcoal);
  color: var(--white);
  border: none;
  border-radius: 50px;
  padding: 15px 28px;
  font-size: 0.85rem;
  font-weight: 700;
  letter-spacing: 0.8px;
  text-transform: uppercase;
  cursor: pointer;
  width: 100%;
  font-family: var(--font-body);
  transition: background 0.2s, transform 0.1s;
}
.btn-add:hover { background: var(--rose-dark); }
.btn-add:active { transform: scale(0.98); }
.btn-add:disabled { background: var(--border); color: var(--text-muted); cursor: not-allowed; }

/* Relacionados */
.related-section {
  border-top: 1px solid var(--border);
  padding-top: 16px;
}

.related-title {
  font-size: 0.65rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 2px;
  color: var(--rose);
  margin-bottom: 12px;
  display: flex;
  align-items: center;
  gap: 6px;
}

.related-cards {
  display: flex;
  gap: 10px;
  overflow-x: auto;
  scrollbar-width: none;
  padding-bottom: 4px;
}
.related-cards::-webkit-scrollbar { display: none; }

.related-card {
  flex-shrink: 0;
  width: 96px;
  cursor: pointer;
  text-align: center;
  border-radius: var(--radius-sm);
  overflow: hidden;
  border: 1.5px solid var(--border);
  background: var(--white);
  transition: border-color 0.2s, box-shadow 0.2s;
}
.related-card:hover { border-color: var(--rose); box-shadow: 0 2px 12px rgba(201,144,122,0.15); }

.related-card img {
  width: 100%;
  aspect-ratio: 1;
  object-fit: cover;
  display: block;
  background: var(--cream);
}
.related-card-placeholder {
  width: 100%;
  aspect-ratio: 1;
  background: var(--cream);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.55rem;
  color: var(--nude);
}

.related-card p {
  font-size: 0.65rem;
  font-weight: 700;
  padding: 6px 4px;
  color: var(--charcoal);
  line-height: 1.2;
}

/* ── SIDEBAR CARRITO ── */
.cart-overlay {
  position: fixed;
  inset: 0;
  background: rgba(44,40,36,0.45);
  z-index: 300;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s, visibility 0.3s;
  backdrop-filter: blur(2px);
}
.cart-overlay.open { opacity: 1; visibility: visible; }

.cart-sidebar {
  position: fixed;
  top: 0;
  right: 0;
  bottom: 0;
  width: min(420px, 100vw);
  background: var(--white);
  z-index: 301;
  display: flex;
  flex-direction: column;
  transform: translateX(100%);
  transition: transform 0.35s cubic-bezier(0.4,0,0.2,1);
  box-shadow: -4px 0 40px rgba(44,40,36,0.12);
}
.cart-overlay.open .cart-sidebar { transform: translateX(0); }

.cart-header {
  padding: 22px 24px;
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.cart-header h2 {
  font-family: var(--font-script);
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--charcoal);
}

.cart-close {
  background: none;
  border: 1.5px solid var(--border);
  width: 32px;
  height: 32px;
  border-radius: 50%;
  font-size: 1rem;
  cursor: pointer;
  color: var(--text-muted);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: border-color 0.2s, color 0.2s;
}
.cart-close:hover { border-color: var(--charcoal); color: var(--charcoal); }

.cart-items {
  flex: 1;
  overflow-y: auto;
  padding: 16px 20px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.cart-empty {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  height: 100%;
  gap: 14px;
  color: var(--text-muted);
}
.cart-empty svg { width: 52px; height: 52px; opacity: 0.2; }
.cart-empty p { font-size: 0.88rem; }

.cart-item {
  display: grid;
  grid-template-columns: 68px 1fr auto;
  gap: 12px;
  align-items: start;
  padding: 12px;
  background: var(--cream);
  border-radius: 10px;
  border: 1px solid var(--border);
}

.cart-item-img {
  width: 68px;
  height: 68px;
  object-fit: cover;
  border-radius: var(--radius-sm);
  background: var(--sand);
  display: block;
}

.cart-item-name { font-size: 0.83rem; font-weight: 700; color: var(--charcoal); line-height: 1.3; }
.cart-item-art { font-size: 0.68rem; color: var(--text-muted); margin-top: 2px; letter-spacing: 0.5px; }
.cart-item-meta { font-size: 0.75rem; color: var(--text-muted); margin-top: 5px; }

.cart-item-qty {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-top: 8px;
}
.cart-item-qty .qty-btn { width: 26px; height: 26px; font-size: 0.9rem; }
.cart-item-qty .qty-num { font-size: 0.82rem; }

.cart-item-remove {
  background: none;
  border: none;
  color: var(--nude);
  cursor: pointer;
  font-size: 0.9rem;
  padding: 4px;
  transition: color 0.2s;
  margin-top: 2px;
}
.cart-item-remove:hover { color: #c0392b; }

.cart-footer {
  padding: 16px 20px 24px;
  border-top: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.cart-summary {
  font-size: 0.8rem;
  color: var(--text-muted);
  text-align: center;
  letter-spacing: 0.3px;
}

.btn-confirm {
  background: var(--rose);
  color: var(--white);
  border: none;
  border-radius: 50px;
  padding: 15px;
  font-size: 0.85rem;
  font-weight: 700;
  letter-spacing: 0.8px;
  text-transform: uppercase;
  cursor: pointer;
  width: 100%;
  font-family: var(--font-body);
  transition: background 0.2s;
}
.btn-confirm:hover { background: var(--rose-dark); }

.btn-clear {
  background: none;
  border: 1px solid var(--border);
  border-radius: 50px;
  padding: 10px;
  font-size: 0.78rem;
  color: var(--text-muted);
  cursor: pointer;
  font-family: var(--font-body);
  transition: border-color 0.2s, color 0.2s;
}
.btn-clear:hover { border-color: #c0392b; color: #c0392b; }

/* ── BOTÓN "Ver pedido completo" en carrito ── */
.btn-vista-general {
  background: none;
  border: 1.5px solid var(--border);
  border-radius: 50px;
  padding: 11px 16px;
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--charcoal);
  cursor: pointer;
  font-family: var(--font-body);
  transition: all 0.2s;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  letter-spacing: 0.4px;
}
.btn-vista-general:hover {
  border-color: var(--rose);
  color: var(--rose-dark);
  background: var(--rose-light);
}

/* ── VISTA PEDIDO PANTALLA ENTERA ── */
.vista-pedido-overlay {
  position: fixed;
  inset: 0;
  background: var(--cream);
  z-index: 500;
  display: flex;
  flex-direction: column;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.25s, visibility 0.25s;
  overflow: hidden;
}
.vista-pedido-overlay.open { opacity: 1; visibility: visible; }

.vista-pedido-header {
  background: var(--white);
  border-bottom: 1.5px solid var(--sand);
  padding: 18px 28px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  flex-shrink: 0;
}
.vista-pedido-title {
  display: flex;
  align-items: center;
  gap: 16px;
  min-width: 0;
}
.vista-pedido-back {
  background: none;
  border: 1.5px solid var(--border);
  border-radius: 50%;
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  color: var(--charcoal);
  transition: all 0.2s;
  flex-shrink: 0;
}
.vista-pedido-back:hover { border-color: var(--charcoal); background: var(--sand); }
.vista-pedido-title h2 {
  font-family: var(--font-script);
  font-size: 1.7rem;
  font-weight: 700;
  color: var(--charcoal);
  line-height: 1;
  margin: 0;
}
.vista-pedido-title p {
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  color: var(--text-muted);
  margin: 4px 0 0;
}

.vista-pedido-stats {
  display: flex;
  gap: 14px;
  flex-shrink: 0;
}
.vp-stat {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 8px 18px;
  border: 1.5px solid var(--border);
  border-radius: 12px;
  background: var(--white);
  min-width: 78px;
}
.vp-stat-main { border-color: var(--rose); background: var(--rose-light); }
.vp-stat-num {
  font-size: 1.4rem;
  font-weight: 700;
  color: var(--charcoal);
  line-height: 1;
}
.vp-stat-main .vp-stat-num { color: var(--rose-dark); }
.vp-stat-lbl {
  font-size: 0.6rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1.2px;
  color: var(--text-muted);
  margin-top: 4px;
}

.vista-pedido-body {
  flex: 1;
  overflow-y: auto;
  padding: 28px;
  -webkit-overflow-scrolling: touch;
}

.vp-section { margin-bottom: 34px; }
.vp-section:last-child { margin-bottom: 0; }
.vp-section-header {
  display: flex;
  align-items: baseline;
  gap: 14px;
  margin-bottom: 14px;
  padding-bottom: 10px;
  border-bottom: 1.5px solid var(--sand);
}
.vp-section-title {
  font-family: var(--font-script);
  font-size: 1.4rem;
  font-weight: 700;
  color: var(--charcoal);
  line-height: 1;
}
.vp-section-count {
  font-size: 0.65rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  color: var(--text-muted);
}

.vp-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 12px;
}

.vp-card {
  display: flex;
  background: var(--white);
  border: 1.5px solid var(--sand);
  border-radius: 10px;
  overflow: hidden;
  transition: border-color 0.2s, box-shadow 0.2s;
}
.vp-card:hover { border-color: var(--rose-light); box-shadow: var(--shadow); }

.vp-card-img {
  width: 78px;
  height: auto;
  min-height: 100px;
  object-fit: cover;
  flex-shrink: 0;
  background: var(--sand);
}
.vp-card-noimg {
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--nude);
  font-size: 1.1rem;
}

.vp-card-body {
  flex: 1;
  padding: 9px 11px;
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.vp-card-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 8px;
  margin-bottom: 7px;
  padding-bottom: 7px;
  border-bottom: 1px dashed var(--border);
}
.vp-card-art {
  font-size: 0.54rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1.3px;
  color: var(--text-muted);
  margin-bottom: 2px;
}
.vp-card-name {
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--charcoal);
  line-height: 1.2;
}
.vp-card-total {
  display: flex;
  flex-direction: column;
  align-items: center;
  background: var(--rose-light);
  border-radius: 8px;
  padding: 3px 8px;
  flex-shrink: 0;
}
.vp-card-total-num {
  font-size: 0.9rem;
  font-weight: 700;
  color: var(--rose-dark);
  line-height: 1;
}
.vp-card-total-lbl {
  font-size: 0.5rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.8px;
  color: var(--rose-dark);
  margin-top: 1px;
}

.vp-variants {
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.vp-variant {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 4px 7px;
  background: var(--cream);
  border-radius: 6px;
  gap: 6px;
}
.vp-variant-info {
  display: flex;
  align-items: baseline;
  gap: 6px;
  min-width: 0;
  flex: 1;
}
.vp-variant-talle {
  font-size: 0.68rem;
  font-weight: 700;
  color: var(--charcoal);
  line-height: 1;
  white-space: nowrap;
}
.vp-variant-color {
  font-size: 0.62rem;
  color: var(--text-muted);
  line-height: 1;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.vp-variant-qty {
  display: flex;
  align-items: center;
  gap: 3px;
  flex-shrink: 0;
}
.vp-qty-btn {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  border: 1.5px solid var(--border);
  background: var(--white);
  cursor: pointer;
  font-size: 0.82rem;
  color: var(--charcoal);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  font-family: var(--font-body);
  transition: all 0.15s;
  line-height: 1;
}
.vp-qty-btn:hover { border-color: var(--rose); background: var(--rose-light); color: var(--rose-dark); }
.vp-qty-input {
  width: 32px;
  height: 22px;
  text-align: center;
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--rose-dark);
  border: 1.5px solid transparent;
  background: transparent;
  border-radius: 5px;
  font-family: var(--font-body);
  padding: 0;
  -moz-appearance: textfield;
  outline: none;
  cursor: text;
}
.vp-qty-input::-webkit-outer-spin-button,
.vp-qty-input::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }
.vp-qty-input:focus { border-color: var(--rose); background: var(--white); }
.vp-variant-remove {
  background: none;
  border: none;
  color: var(--text-muted);
  font-size: 0.75rem;
  cursor: pointer;
  padding: 2px 4px;
  margin-left: 2px;
  border-radius: 4px;
  transition: color 0.2s, background 0.2s;
  line-height: 1;
}
.vp-variant-remove:hover { color: #c0392b; background: rgba(192,57,43,0.08); }

.vista-empty {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 100px 30px;
  text-align: center;
  color: var(--text-muted);
}
.vista-empty svg { margin-bottom: 18px; color: var(--nude); }
.vista-empty h3 {
  font-family: var(--font-script);
  font-size: 1.6rem;
  color: var(--charcoal);
  margin-bottom: 8px;
  font-weight: 700;
}
.vista-empty p { font-size: 0.85rem; }

.vista-pedido-footer {
  background: var(--white);
  border-top: 1.5px solid var(--sand);
  padding: 16px 28px;
  display: flex;
  gap: 14px;
  justify-content: flex-end;
  flex-shrink: 0;
}
.btn-vista-close {
  background: none;
  border: 1.5px solid var(--border);
  border-radius: 50px;
  padding: 13px 26px;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.5px;
  color: var(--charcoal);
  cursor: pointer;
  font-family: var(--font-body);
  transition: all 0.2s;
}
.btn-vista-close:hover { border-color: var(--charcoal); background: var(--sand); }
.btn-vista-confirm {
  background: var(--charcoal);
  color: var(--white);
  border: none;
  border-radius: 50px;
  padding: 13px 28px;
  font-size: 0.82rem;
  font-weight: 700;
  letter-spacing: 0.5px;
  cursor: pointer;
  font-family: var(--font-body);
  transition: background 0.2s, transform 0.1s;
  display: flex;
  align-items: center;
  gap: 9px;
}
.btn-vista-confirm:hover { background: var(--rose-dark); }
.btn-vista-confirm:active { transform: scale(0.97); }

/* Mobile */
@media (max-width: 600px) {
  .vista-pedido-header {
    padding: 12px 14px;
    flex-direction: column;
    align-items: stretch;
    gap: 12px;
  }
  .vista-pedido-title h2 { font-size: 1.4rem; }
  .vista-pedido-stats { justify-content: space-between; gap: 8px; }
  .vp-stat { padding: 6px 10px; min-width: 0; flex: 1; }
  .vp-stat-num { font-size: 1.15rem; }
  .vista-pedido-body { padding: 16px; }
  .vp-grid { grid-template-columns: 1fr; gap: 12px; }
  .vp-card-img { width: 92px; min-height: 130px; }
  .vp-card-body { padding: 10px 12px; }
  .vp-section-title { font-size: 1.2rem; }
  .vista-pedido-footer {
    padding: 12px 14px;
    flex-direction: column-reverse;
    gap: 8px;
  }
  .btn-vista-close, .btn-vista-confirm {
    width: 100%;
    justify-content: center;
  }
}

/* ── MODAL PEDIDO ── */
.order-overlay {
  position: fixed;
  inset: 0;
  background: rgba(44,40,36,0.55);
  z-index: 400;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s, visibility 0.3s;
  backdrop-filter: blur(2px);
}
.order-overlay.open { opacity: 1; visibility: visible; }

@media (min-width: 640px) {
  .order-overlay { align-items: center; padding: 24px; }
}

.order-modal {
  background: var(--white);
  border-radius: var(--radius) var(--radius) 0 0;
  width: 100%;
  max-width: 580px;
  max-height: 92vh;
  overflow-y: auto;
  transform: translateY(40px);
  transition: transform 0.35s cubic-bezier(0.4,0,0.2,1);
  -webkit-overflow-scrolling: touch;
}
.order-overlay.open .order-modal { transform: translateY(0); }

@media (min-width: 640px) {
  .order-modal { border-radius: var(--radius); max-height: 88vh; }
}

.order-modal-header {
  padding: 16px 24px 12px;
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.order-modal-header h2 {
  font-family: var(--font-script);
  font-size: 1.35rem;
  font-weight: 700;
  color: var(--charcoal);
}

.order-form { padding: 18px 24px 22px; }

.form-group { margin-bottom: 11px; }
.form-group label {
  display: block;
  font-size: 0.64rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1.3px;
  color: var(--text-muted);
  margin-bottom: 4px;
}
.form-group input {
  width: 100%;
  padding: 9px 14px;
  border: 1.5px solid var(--border);
  border-radius: var(--radius-sm);
  font-size: 0.88rem;
  color: var(--charcoal);
  background: var(--white);
  font-family: var(--font-body);
  transition: border-color 0.2s;
  -webkit-appearance: none;
}
.form-group input:focus { outline: none; border-color: var(--charcoal); }
.form-group input::placeholder { color: var(--nude); }
.form-group input.error { border-color: #c0392b; }

.form-group select {
  width: 100%;
  padding: 9px 14px;
  border: 1.5px solid var(--border);
  border-radius: var(--radius-sm);
  font-size: 0.88rem;
  color: var(--charcoal);
  background: var(--white);
  font-family: var(--font-body);
  transition: border-color 0.2s;
  -webkit-appearance: none;
  -moz-appearance: none;
  appearance: none;
  cursor: pointer;
  /* Flecha de dropdown personalizada (SVG inline) */
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8' fill='none' stroke='%239e8e82' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'><polyline points='1 1 6 7 11 1'/></svg>");
  background-repeat: no-repeat;
  background-position: right 14px center;
  padding-right: 36px;
}
.form-group select:focus { outline: none; border-color: var(--charcoal); }
.form-group select:invalid { color: var(--nude); }  /* mientras tiene placeholder seleccionado */
.form-group select.error { border-color: #c0392b; }

.label-opt {
  font-weight: 400;
  text-transform: none;
  letter-spacing: 0.3px;
  color: var(--nude);
  font-size: 0.62rem;
}

.form-group textarea {
  width: 100%;
  padding: 9px 14px;
  border: 1.5px solid var(--border);
  border-radius: var(--radius-sm);
  font-size: 0.88rem;
  color: var(--charcoal);
  background: var(--white);
  font-family: var(--font-body);
  transition: border-color 0.2s;
  -webkit-appearance: none;
  resize: vertical;
  min-height: 50px;
  line-height: 1.4;
}
.form-group textarea:focus { outline: none; border-color: var(--charcoal); }
.form-group textarea::placeholder { color: var(--nude); }
.form-group textarea.error { border-color: #c0392b; }

.form-group-full { margin-top: 0; }

.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }

.order-summary-box {
  background: var(--cream);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 16px;
  margin-bottom: 22px;
  max-height: 200px;
  overflow-y: auto;
}
.order-summary-box h3 {
  font-size: 0.65rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 2px;
  color: var(--rose);
  margin-bottom: 12px;
}

.summary-item {
  display: flex;
  justify-content: space-between;
  font-size: 0.8rem;
  padding: 6px 0;
  border-bottom: 1px solid var(--border);
  gap: 10px;
}
.summary-item:last-child { border-bottom: none; }
.summary-item-name { color: var(--charcoal); font-weight: 700; }
.summary-item-detail { color: var(--text-muted); text-align: right; flex-shrink: 0; }

.btn-send {
  background: var(--charcoal);
  color: var(--white);
  border: none;
  border-radius: 50px;
  padding: 13px;
  font-size: 0.82rem;
  margin-top: 4px;
  font-weight: 700;
  letter-spacing: 0.8px;
  text-transform: uppercase;
  cursor: pointer;
  width: 100%;
  font-family: var(--font-body);
  transition: background 0.2s;
}
.btn-send:hover { background: var(--rose-dark); }
.btn-send:disabled { background: var(--border); color: var(--text-muted); cursor: not-allowed; }

/* ── SUCCESS ── */
.success-screen {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 52px 28px;
  text-align: center;
  gap: 16px;
}
.success-icon {
  width: 68px;
  height: 68px;
  background: var(--rose-light);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.8rem;
}
.success-screen h2 {
  font-family: var(--font-script);
  font-size: 1.8rem;
  font-weight: 700;
  color: var(--charcoal);
}
.success-screen p { color: var(--text-muted); font-size: 0.88rem; line-height: 1.6; }
.btn-new-order {
  background: var(--rose);
  color: var(--white);
  border: none;
  border-radius: 50px;
  padding: 13px 30px;
  font-size: 0.82rem;
  font-weight: 700;
  letter-spacing: 0.8px;
  text-transform: uppercase;
  cursor: pointer;
  margin-top: 8px;
  font-family: var(--font-body);
  transition: background 0.2s;
}
.btn-new-order:hover { background: var(--rose-dark); }

/* ── TOAST ── */
.toast {
  position: fixed;
  bottom: 28px;
  left: 50%;
  transform: translateX(-50%) translateY(16px);
  background: var(--charcoal);
  color: var(--white);
  padding: 12px 24px;
  border-radius: 50px;
  font-size: 0.82rem;
  font-weight: 700;
  letter-spacing: 0.3px;
  box-shadow: 0 4px 24px rgba(44,40,36,0.2);
  z-index: 500;
  opacity: 0;
  transition: opacity 0.3s, transform 0.3s;
  pointer-events: none;
  white-space: nowrap;
}
.toast.show { opacity: 1; transform: translateX(-50%) translateY(0); }

/* ── RESPONSIVE ── */
@media (max-width: 480px) {
  .catalog-grid { grid-template-columns: repeat(2, 1fr); gap: 14px; }
  .catalog { padding: 20px 16px 60px; }
  .card-body { padding: 10px 12px 12px; }
  .card-name { font-size: 0.82rem; }
}

/* ── MOBILE (≤ 600px) ── */
@media (max-width: 600px) {

  /* Header */
  .header-inner {
    padding: 10px 14px;
    gap: 10px;
  }
  .brand-logo { height: 30px; max-width: 100px; }
  .brand-text { display: none; }
  .header-actions { gap: 8px; }

  /* Howto button: icono solo */
  .filter-btn-howto {
    padding: 8px 10px;
    border-radius: 50%;
    width: 38px;
    height: 38px;
    justify-content: center;
  }
  .howto-text { display: none; }

  /* Cart button: compacto */
  .cart-btn {
    padding: 9px 14px;
    font-size: 0.78rem;
    gap: 6px;
  }
  .cart-btn > span:not(.cart-count) { display: none; }

  /* Filters bar */
  .filters-bar { top: 54px; }
  .filters-inner { padding: 0 10px; }
  .filter-btn { padding: 11px 13px; font-size: 0.75rem; }

  /* Catalog */
  .catalog { padding: 18px 12px 60px; }
  .catalog-grid { grid-template-columns: repeat(2, 1fr); gap: 12px; }
  .catalog-section-grid { grid-template-columns: repeat(2, 1fr); gap: 12px; }
  .catalog-section-title { font-size: 1.35rem; }

  /* Card */
  .card-body { padding: 10px 12px 12px; }
  .card-name { font-size: 0.8rem; }
  .card-art { font-size: 0.62rem; }
  .card-price { font-size: 0.9rem; }
  .card-actions { gap: 6px; }

  /* Form row */
  .form-row { grid-template-columns: 1fr; }

  /* Order modal */
  .order-form { padding: 18px 20px 28px; }
  .order-modal-header { padding: 18px 20px 14px; }
  .order-modal-header h2 { font-size: 1.35rem; }
  .order-summary-box { padding: 14px 16px; margin-bottom: 18px; }

  /* Vista Completa: ocultar sidebar, full width */
  .vc-layout { display: block; }
  .vc-sidebar { display: none; }
  .vc-content { width: 100%; }

  /* VC categorías: scroll horizontal arriba */
  .vc-cat-nav {
    display: flex;
    overflow-x: auto;
    gap: 6px;
    padding: 0 0 12px;
    margin-bottom: 16px;
    scrollbar-width: none;
    -webkit-overflow-scrolling: touch;
  }
  .vc-cat-nav::-webkit-scrollbar { display: none; }
  .vc-cat-nav-item {
    flex-shrink: 0;
    background: var(--sand);
    border-radius: 50px;
    padding: 6px 14px;
    font-size: 0.72rem;
    font-weight: 700;
    color: var(--charcoal);
    text-decoration: none;
    white-space: nowrap;
  }
  .vc-cat-nav-item.active {
    background: var(--charcoal);
    color: var(--white);
  }
}

@media (min-width: 1024px) {
  .catalog-grid { grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); }
}

.loading {
  text-align: center;
  padding: 60px 20px;
  color: var(--text-muted);
  font-size: 0.88rem;
  letter-spacing: 0.3px;
}

/* ── VISTA COMPLETA ── */
.vc-grid {
  display: block !important;
  padding: 0;
}

.vc-layout {
  display: flex;
  gap: 24px;
  align-items: flex-start;
}

.vc-sidebar {
  width: 148px;
  flex-shrink: 0;
  position: sticky;
  top: 130px;
  max-height: calc(100vh - 150px);
  overflow-y: auto;
  scrollbar-width: none;
  padding: 4px 0;
}
.vc-sidebar::-webkit-scrollbar { display: none; }

.vc-sidebar-label {
  font-size: 0.58rem;
  font-weight: 700;
  letter-spacing: 2.5px;
  text-transform: uppercase;
  color: var(--text-muted);
  padding: 0 10px 8px;
  border-bottom: 1.5px solid var(--border);
  margin-bottom: 6px;
}

.vc-sidebar-link {
  display: block;
  padding: 7px 10px;
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--charcoal);
  text-decoration: none;
  border-radius: 6px;
  border-left: 2.5px solid transparent;
  transition: background 0.15s, color 0.15s, border-color 0.15s;
  line-height: 1.2;
}
.vc-sidebar-link:hover {
  background: var(--sand);
  color: var(--charcoal);
}
.vc-sidebar-link.active {
  color: var(--rose-dark);
  background: var(--rose-light);
  border-left-color: var(--rose);
}

/* Sub-links indentados (sub-categorías dentro de Corsetería).
   Solo se muestran cuando la sección Corsetería está activa. */
.vc-sidebar-sublink {
  padding-left: 22px;
  font-size: 0.72rem;
  font-weight: 500;
  color: var(--text-muted);
  display: none;
}
.vc-sidebar.expand-corseteria .vc-sidebar-sublink { display: block; }
.vc-sidebar-sublink::before {
  content: '›';
  margin-right: 6px;
  color: var(--rose);
  font-weight: 700;
}
.vc-sidebar-sublink.active {
  color: var(--rose-dark);
  background: var(--rose-light);
  font-weight: 700;
}

/* Sub-secciones del contenido */
.vc-subsection { margin-top: 18px; }
.vc-subcat-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 8px 14px 6px;
  border-bottom: 1.5px dashed var(--sand);
  margin-bottom: 8px;
}
.vc-subcat-title {
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--rose-dark);
  text-transform: uppercase;
  letter-spacing: 1.2px;
}
.vc-subcat-count {
  font-size: 0.7rem;
  color: var(--text-muted);
  font-weight: 600;
}

.vc-content {
  flex: 1;
  min-width: 0;
}

.vc-section {
  margin-bottom: 32px;
}

.vc-cat-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 10px 14px 8px;
  border-bottom: 2px solid var(--sand);
  margin-bottom: 10px;
}

.vc-cat-title {
  font-size: 0.62rem;
  font-weight: 700;
  letter-spacing: 3px;
  text-transform: uppercase;
  color: var(--rose);
  white-space: nowrap;
}

.vc-cat-count {
  font-size: 0.65rem;
  color: var(--text-muted);
  white-space: nowrap;
}

.vc-row {
  display: flex;
  align-items: center;
  gap: 14px;
  background: var(--white);
  border-radius: 10px;
  padding: 10px 14px;
  border: 1px solid var(--border);
  margin-bottom: 6px;
}

.vc-product-block {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  width: 110px;
  flex-shrink: 0;
  gap: 5px;
}

.vc-photo {
  width: 110px;
  height: 146px;
  object-fit: cover;
  border-radius: 8px;
  background: var(--sand);
  display: block;
}

.vc-photo-empty {
  width: 110px;
  height: 146px;
  background: var(--sand);
  border-radius: 8px;
  display: block;
}

.vc-name {
  font-size: 0.74rem;
  font-weight: 700;
  color: var(--charcoal);
  line-height: 1.3;
  width: 100%;
}

.vc-art {
  font-size: 0.6rem;
  color: var(--text-muted);
  letter-spacing: 0.4px;
  margin-top: -3px;
}

.vc-grid-wrap {
  flex: 1;
  min-width: 0;
}

.vc-grid-wrap .grid-scroll-wrapper {
  border-radius: 6px;
}

.vc-grid-wrap .grid-row-header {
  padding: 5px 6px;
  font-size: 0.66rem;
  min-width: 0;
}

.vc-grid-wrap .grid-corner {
  padding: 6px 6px;
  min-width: 0;
}

.vc-add-btn {
  flex-shrink: 0;
  background: var(--charcoal);
  color: var(--white);
  border: none;
  border-radius: 50px;
  padding: 7px 14px;
  font-size: 0.72rem;
  font-weight: 700;
  cursor: pointer;
  font-family: var(--font-body);
  transition: background 0.2s;
  white-space: nowrap;
  letter-spacing: 0.4px;
}
.vc-add-btn:hover { background: var(--rose-dark); }
.vc-add-btn:disabled { background: var(--border); color: var(--text-muted); cursor: not-allowed; }

/* ── BOTÓN 1 CURVA ── */
.grid-curva-wrap {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-top: 10px;
}

.btn-curva {
  display: flex;
  align-items: center;
  gap: 6px;
  background: none;
  border: 1.5px solid var(--border);
  border-radius: 50px;
  padding: 7px 14px;
  font-family: var(--font-body);
  font-size: 0.74rem;
  font-weight: 700;
  color: var(--text-muted);
  cursor: pointer;
  transition: all 0.2s;
  white-space: nowrap;
  flex-shrink: 0;
}
.btn-curva:hover { border-color: var(--rose); color: var(--rose-dark); background: var(--rose-light); }

.curva-hint {
  font-size: 0.69rem;
  color: var(--text-muted);
  line-height: 1.3;
}

/* ── Botones VC (Agregar + 1 Curva) ── */
.vc-btns {
  display: flex;
  flex-direction: column;
  gap: 6px;
  flex-shrink: 0;
  align-items: stretch;
}

.vc-curva-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  background: none;
  color: var(--text-muted);
  border: 1.5px solid var(--border);
  border-radius: 50px;
  padding: 6px 12px;
  font-size: 0.7rem;
  font-weight: 700;
  cursor: pointer;
  font-family: var(--font-body);
  transition: all 0.2s;
  white-space: nowrap;
  letter-spacing: 0.4px;
  text-align: center;
}
.vc-curva-btn:hover { border-color: var(--rose); color: var(--rose-dark); background: var(--rose-light); }

/* ── BOTÓN AGREGAR TODO (en sidebar Vista Completa) ── */
.vc-agregar-todo-wrap {
  margin-top: 20px;
  padding-top: 20px;
  border-top: 1.5px solid var(--sand);
}

.vc-btn-agregar-todo {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  width: 100%;
  background: var(--charcoal);
  color: var(--white);
  border: none;
  border-radius: 50px;
  padding: 12px 16px;
  font-family: var(--font-body);
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.4px;
  cursor: pointer;
  transition: background 0.2s, transform 0.1s, opacity 0.2s;
  white-space: nowrap;
  text-align: center;
}
.vc-btn-agregar-todo:hover:not(:disabled) { background: var(--rose-dark); }
.vc-btn-agregar-todo:active:not(:disabled) { transform: scale(0.97); }
.vc-btn-agregar-todo:disabled { opacity: 0.38; cursor: not-allowed; }

@media (max-width: 640px) {
  .vc-row { flex-wrap: wrap; }
  .vc-info { width: auto; flex: 1; }
  .vc-grid-wrap { flex: 0 0 100%; order: 3; }
  .vc-btns { order: 4; width: 100%; flex-direction: row; }
  .vc-add-btn { flex: 1; padding: 10px; }
  .vc-curva-btn { flex: 1; padding: 10px; }
}

/* ── GRILLA DE PEDIDO (doble entrada talle × color) ── */
.grid-scroll-wrapper {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  border-radius: var(--radius-sm);
  border: 1.5px solid var(--border);
}

.order-grid {
  width: 100%;
  border-collapse: collapse;
  font-family: var(--font-body);
}

.grid-corner {
  background: var(--cream);
  padding: 10px 12px;
  border-right: 1.5px solid var(--border);
  border-bottom: 1.5px solid var(--border);
  min-width: 60px;
  vertical-align: middle;
}

.corner-inner {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 0;
  font-size: 0.6rem;
  font-weight: 700;
  letter-spacing: 1px;
  text-transform: uppercase;
  color: var(--text-muted);
  line-height: 1.2;
}
.corner-sep { font-size: 0.7rem; opacity: 0.3; line-height: 1; }
.corner-talle { color: var(--charcoal); }
.corner-color { color: var(--rose); }

.grid-col-header {
  padding: 7px 8px;
  font-size: 0.62rem;
  font-weight: 700;
  text-align: center;
  background: var(--cream);
  border-bottom: 1.5px solid var(--border);
  border-right: 1px solid var(--border);
  color: var(--rose-dark);
  letter-spacing: 0.3px;
  white-space: nowrap;
}
.grid-col-header:last-child { border-right: none; }

.grid-row-header {
  padding: 5px 10px;
  font-size: 0.7rem;
  font-weight: 700;
  color: var(--charcoal);
  border-right: 1.5px solid var(--border);
  border-bottom: 1px solid var(--border);
  background: var(--cream);
  text-align: center;
  white-space: nowrap;
}

.grid-row-surtido {
  color: var(--text-muted);
  font-style: italic;
  border-top: 2px dashed var(--border);
}

.order-grid tbody tr:last-child .grid-row-header,
.order-grid tbody tr:last-child .grid-cell-td { border-bottom: none; }

.grid-cell-td {
  padding: 4px 3px;
  border-bottom: 1px solid var(--border);
  border-right: 1px solid var(--border);
  text-align: center;
}
.grid-cell-td:last-child { border-right: none; }

.grid-row-surtido + .grid-cell-td,
tr:has(.grid-row-surtido) .grid-cell-td {
  background: var(--cream);
  border-top: 2px dashed var(--border);
}

.grid-cell {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 2px;
}

.grid-btn {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  border: 1.5px solid var(--border);
  background: var(--white);
  cursor: pointer;
  font-size: 0.85rem;
  font-weight: 300;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--charcoal);
  transition: background 0.15s, border-color 0.15s, color 0.15s;
  flex-shrink: 0;
  font-family: var(--font-body);
  padding: 0;
  line-height: 1;
}
.grid-btn:hover { border-color: var(--charcoal); background: var(--cream); }
.grid-plus:hover { border-color: var(--rose); color: var(--rose); }

.grid-qty {
  font-size: 0.72rem;
  font-weight: 700;
  width: 22px;
  text-align: center;
  color: var(--text-muted);
  transition: color 0.2s;
  border: none;
  background: transparent;
  font-family: var(--font-body);
  padding: 0;
  -moz-appearance: textfield;
  outline: none;
  cursor: text;
}
.grid-qty::-webkit-outer-spin-button,
.grid-qty::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }
.grid-qty:focus { color: var(--charcoal); }
.grid-qty.has-value { color: var(--rose-dark); }

.grid-footer {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
  margin-top: 10px;
  padding: 0 2px;
}
.grid-total-label {
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: var(--text-muted);
}
.grid-total-num {
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--rose-dark);
}

/* Fade para indicar scroll lateral en categorías */
.filters-inner::after {
  content: '';
  position: sticky;
  right: 0;
  min-width: 24px;
  background: linear-gradient(to right, transparent, white);
  pointer-events: none;
  flex-shrink: 0;
}

/* ── VISTA COMPLETA BUTTON ── */
.filter-btn-vc {
  display: flex;
  align-items: center;
  gap: 7px;
  padding: 8px 16px;
  margin: 7px 8px;
  background: var(--sand);
  border: 1.5px solid var(--sand-dark);
  border-radius: 50px;
  font-family: var(--font-body);
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.3px;
  color: var(--charcoal);
  cursor: pointer;
  transition: background 0.2s, border-color 0.2s, color 0.2s;
  white-space: nowrap;
  flex-shrink: 0;
}
.filter-btn-vc:hover { background: var(--rose-light); border-color: var(--rose); color: var(--rose-dark); }
.filter-btn-vc.active { background: var(--charcoal); border-color: var(--charcoal); color: var(--white); }
.filter-btn-vc.active svg { stroke: var(--white); }

/* ── CÓMO PEDIR BUTTON (en filters-bar) ── */
.filter-btn-howto {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 8px 14px;
  margin: 7px 8px 7px 0;
  background: none;
  border: 1.5px solid var(--border);
  border-radius: 50px;
  font-family: var(--font-body);
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--text-muted);
  cursor: pointer;
  transition: all 0.2s;
  white-space: nowrap;
  flex-shrink: 0;
}
.filter-btn-howto:hover { border-color: var(--rose); color: var(--rose-dark); background: var(--rose-light); }

/* ── BUSCADOR OVERLAY ── */
.search-overlay {
  position: fixed;
  inset: 0;
  background: rgba(44,40,36,0.5);
  z-index: 200;
  display: flex;
  align-items: flex-start;
  justify-content: center;
  padding-top: 80px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s;
}
.search-overlay.open { opacity: 1; pointer-events: all; }

.search-modal {
  background: var(--white);
  border-radius: var(--radius);
  width: 100%;
  max-width: 860px;
  max-height: 80vh;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  box-shadow: var(--shadow-hover);
  transform: translateY(-10px);
  transition: transform 0.2s;
}
.search-overlay.open .search-modal { transform: translateY(0); }

.search-header {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 16px 20px;
  border-bottom: 1.5px solid var(--border);
  flex-shrink: 0;
  color: var(--text-muted);
}
.search-header input {
  flex: 1;
  border: none;
  outline: none;
  font-family: var(--font-body);
  font-size: 1rem;
  color: var(--charcoal);
  background: none;
}
.search-header input::placeholder { color: var(--text-muted); }
.search-header button {
  background: none;
  border: none;
  font-size: 1rem;
  color: var(--text-muted);
  cursor: pointer;
  padding: 4px;
}

.search-results {
  overflow-y: auto;
  padding: 12px 16px 20px;
  flex: 1;
  display: block !important;
}

.search-list {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.search-item {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 10px 12px;
  border-radius: 10px;
  cursor: pointer;
  transition: background 0.15s;
}
.search-item:hover { background: var(--bg); }

.search-item-thumb {
  width: 58px;
  height: 58px;
  border-radius: 8px;
  overflow: hidden;
  flex-shrink: 0;
  background: var(--bg);
}
.search-item-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.search-item-no-img {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-muted);
}
.search-item-no-img svg { width: 22px; height: 22px; }

.search-item-info {
  flex: 1;
  min-width: 0;
}
.search-item-name {
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--charcoal);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.search-item-meta {
  font-size: 0.78rem;
  color: var(--text-muted);
  margin-top: 2px;
}

.search-item-arrow { color: var(--text-muted); flex-shrink: 0; }

.search-empty {
  color: var(--text-muted);
  font-size: 0.9rem;
  text-align: center;
  padding: 30px 0 16px;
}
.search-noresult { padding-bottom: 4px; }

/* Banner que aparece arriba del catálogo cuando hay filtro de búsqueda activo */
.search-result-banner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  background: var(--cream);
  border: 1.5px solid var(--rose-light);
  border-radius: var(--radius);
  padding: 12px 18px;
  margin-bottom: 14px;
  flex-wrap: wrap;
}
.search-result-banner .srb-label {
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-right: 6px;
}
.search-result-banner strong {
  font-size: 0.95rem;
  color: var(--charcoal);
  font-weight: 700;
}
.search-result-banner .srb-count {
  margin-left: 10px;
  background: var(--rose-light);
  color: var(--rose-dark);
  font-size: 0.72rem;
  font-weight: 700;
  padding: 3px 10px;
  border-radius: 50px;
  letter-spacing: 0.3px;
}
.search-result-banner .srb-clear {
  background: var(--white);
  border: 1.5px solid var(--border);
  color: var(--charcoal);
  font-family: var(--font-body);
  font-size: 0.78rem;
  font-weight: 700;
  padding: 8px 16px;
  border-radius: 50px;
  cursor: pointer;
  letter-spacing: 0.4px;
  transition: all 0.15s;
  flex-shrink: 0;
}
.search-result-banner .srb-clear:hover {
  border-color: var(--rose);
  color: var(--rose-dark);
  background: var(--rose-light);
}

.search-suggestions-title {
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-muted);
  padding: 8px 12px 6px;
}

/* ── TUTORIAL OVERLAY ── */
.tutorial-overlay {
  position: fixed;
  inset: 0;
  background: rgba(44,40,36,0.55);
  z-index: 200;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s;
}
.tutorial-overlay.open { opacity: 1; pointer-events: all; }

.tutorial-modal {
  background: var(--white);
  border-radius: 20px;
  width: 100%;
  max-width: 440px;
  padding: 32px 28px 28px;
  position: relative;
  text-align: center;
  box-shadow: 0 20px 60px rgba(44,40,36,0.18);
  transform: scale(0.96);
  transition: transform 0.25s;
}
.tutorial-overlay.open .tutorial-modal { transform: scale(1); }

.tutorial-header h2 {
  font-family: var(--font-script);
  font-size: 1.5rem;
  color: var(--charcoal);
  margin-bottom: 4px;
}
.tutorial-header p {
  font-size: 0.78rem;
  color: var(--text-muted);
  letter-spacing: 0.5px;
  margin-bottom: 28px;
}

.tutorial-body { padding: 10px 0 20px; }

.tut-illustration {
  min-height: 160px;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  margin-bottom: 4px;
}
.tut-ill {
  width: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
}
.tut-hint {
  font-size: 0.71rem;
  color: var(--text-muted);
  font-style: italic;
  text-align: center;
}

/* Step 1 – category tabs */
.tut-mock-bar {
  display: flex;
  gap: 0;
  width: 100%;
  border-bottom: 1.5px solid var(--sand);
  padding: 0 4px;
}
.tut-mock-tab {
  padding: 8px 14px;
  font-size: 0.76rem;
  font-weight: 600;
  color: var(--text-muted);
  border-bottom: 2.5px solid transparent;
  margin-bottom: -1.5px;
  cursor: default;
}
@keyframes tabCycle {
  0%, 5%   { color: var(--charcoal); border-bottom-color: var(--rose); }
  30%, 100% { color: var(--text-muted); border-bottom-color: transparent; }
}
.tut-mock-bar .tut-mock-tab:nth-child(1) { animation: tabCycle 4s ease-in-out infinite 0s; }
.tut-mock-bar .tut-mock-tab:nth-child(2) { animation: tabCycle 4s ease-in-out infinite 1s; }
.tut-mock-bar .tut-mock-tab:nth-child(3) { animation: tabCycle 4s ease-in-out infinite 2s; }
.tut-mock-bar .tut-mock-tab:nth-child(4) { animation: tabCycle 4s ease-in-out infinite 3s; }

/* Step 2 – product card */
.tut-mock-card {
  width: 190px;
  border-radius: 14px;
  overflow: hidden;
  background: var(--white);
  box-shadow: 0 3px 14px rgba(44,40,36,0.12);
  border: 1.5px solid var(--sand);
  cursor: default;
}
@keyframes cardLift {
  0%, 40%  { transform: translateY(0);   box-shadow: 0 3px 14px rgba(44,40,36,0.12); }
  60%, 90% { transform: translateY(-5px); box-shadow: 0 10px 24px rgba(44,40,36,0.2); }
  100%     { transform: translateY(0);   box-shadow: 0 3px 14px rgba(44,40,36,0.12); }
}
.tut-anim-card { animation: cardLift 2.8s ease-in-out infinite; }
.tut-mock-card-img {
  height: 80px;
  background: linear-gradient(135deg, var(--rose-light) 0%, var(--sand) 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--rose);
}
.tut-mock-card-body { padding: 8px 12px 10px; text-align: left; }
.tut-mock-art-label { font-size: 0.65rem; color: var(--text-muted); text-transform: uppercase; letter-spacing: 0.5px; }
.tut-mock-card-name { font-size: 0.8rem; font-weight: 700; color: var(--charcoal); margin: 3px 0 6px; line-height: 1.2; }
.tut-mock-chips { display: flex; gap: 4px; }
.tut-chip { font-size: 0.64rem; padding: 2px 8px; border-radius: 10px; background: var(--sand); color: var(--charcoal); font-weight: 600; }

/* Step 3 – quantity grid */
.tut-mock-grid {
  border-collapse: collapse;
  width: 100%;
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 1px 6px rgba(44,40,36,0.08);
}
.tut-mock-grid th {
  background: var(--sand);
  padding: 6px 8px;
  font-size: 0.69rem;
  font-weight: 700;
  color: var(--charcoal);
  text-align: center;
  border: 1px solid var(--sand-dark);
}
.tut-mock-grid td {
  padding: 5px 6px;
  text-align: center;
  border: 1px solid var(--sand);
  background: var(--white);
}
.tut-talle {
  font-size: 0.74rem;
  font-weight: 700;
  color: var(--charcoal);
  background: var(--sand) !important;
  min-width: 32px;
}
.tut-qty {
  width: 44px;
  text-align: center;
  border: 1.5px solid var(--sand-dark);
  border-radius: 6px;
  padding: 3px 4px;
  font-size: 0.8rem;
  color: var(--charcoal);
  outline: none;
  transition: border-color 0.2s;
}
.tut-qty:focus { border-color: var(--rose); }

/* Step 4 – add button */
.tut-mock-btn-add {
  padding: 12px 30px;
  background: var(--charcoal);
  color: var(--white);
  border: none;
  border-radius: 50px;
  font-size: 0.88rem;
  font-weight: 700;
  cursor: pointer;
  font-family: var(--font-body);
  transition: background 0.3s, transform 0.15s;
}
@keyframes btnGlow {
  0%, 100% { box-shadow: 0 0 0 0 rgba(201,144,122,0); }
  50%       { box-shadow: 0 0 0 9px rgba(201,144,122,0.22); }
}
.tut-mock-btn-add { animation: btnGlow 2.2s ease-in-out infinite; }
.tut-mock-btn-add:hover { transform: scale(1.04); }

/* Step 5 – form */
.tut-mock-form { width: 100%; display: flex; flex-direction: column; gap: 8px; }
.tut-mock-field label {
  display: block;
  font-size: 0.69rem;
  font-weight: 700;
  color: var(--charcoal);
  margin-bottom: 4px;
  text-align: left;
}
.tut-mock-field input {
  width: 100%;
  padding: 8px 12px;
  border: 1.5px solid var(--sand-dark);
  border-radius: 8px;
  font-size: 0.82rem;
  box-sizing: border-box;
  font-family: var(--font-body);
  outline: none;
  color: var(--charcoal);
  transition: border-color 0.2s;
}
.tut-mock-field input:focus { border-color: var(--rose); }

/* Step 6 – send */
.tut-send-demo { display: flex; flex-direction: column; align-items: center; gap: 14px; }
.tut-mock-btn-send {
  padding: 12px 32px;
  background: var(--rose);
  color: var(--white);
  border: none;
  border-radius: 50px;
  font-size: 0.9rem;
  font-weight: 700;
  cursor: pointer;
  font-family: var(--font-body);
  transition: transform 0.15s, background 0.2s;
}
.tut-mock-btn-send:hover { transform: scale(1.04); background: var(--rose-dark); }
@keyframes tutFadeIn { from { opacity: 0; transform: scale(0.93); } to { opacity: 1; transform: scale(1); } }
.tut-send-ok {
  display: flex;
  align-items: center;
  gap: 12px;
  background: #f0fdf4;
  border: 1.5px solid #bbf7d0;
  border-radius: 14px;
  padding: 12px 18px;
  animation: tutFadeIn 0.35s ease;
}
.tut-ok-check {
  width: 32px;
  height: 32px;
  background: #16a34a;
  color: var(--white);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 1rem;
  flex-shrink: 0;
}
.tut-ok-title { font-size: 0.88rem; font-weight: 700; color: #166534; }
.tut-ok-sub { font-size: 0.71rem; color: #15803d; margin-top: 2px; }

.tut-step-num {
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--rose);
  margin-bottom: 10px;
}

.tut-title {
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--charcoal);
  margin-bottom: 10px;
  line-height: 1.3;
}

.tut-desc {
  font-size: 0.875rem;
  color: var(--text-muted);
  line-height: 1.6;
  min-height: 56px;
}

.tutorial-progress-bar {
  height: 3px;
  background: var(--sand);
  border-radius: 2px;
  margin: 20px 0 16px;
  overflow: hidden;
}
.tutorial-progress-fill {
  height: 100%;
  background: var(--rose);
  border-radius: 2px;
  transition: width 0.4s ease;
}

.tut-dots {
  display: flex;
  justify-content: center;
  gap: 7px;
  margin-bottom: 22px;
}
.tut-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--sand-dark);
  cursor: pointer;
  transition: background 0.2s, transform 0.2s;
}
.tut-dot.active { background: var(--rose); transform: scale(1.3); }

.tut-nav {
  display: flex;
  gap: 10px;
}
.tut-btn-prev, .tut-btn-next {
  flex: 1;
  padding: 11px;
  border-radius: 50px;
  font-family: var(--font-body);
  font-size: 0.82rem;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.2s;
  border: none;
}
.tut-btn-prev {
  background: var(--sand);
  color: var(--charcoal);
}
.tut-btn-prev:hover:not(:disabled) { background: var(--sand-dark); }
.tut-btn-prev:disabled { opacity: 0.35; cursor: not-allowed; }
.tut-btn-next {
  background: var(--charcoal);
  color: var(--white);
}
.tut-btn-next:hover { background: var(--rose-dark); }
