/* Reset y Variables */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

:root {
  --rosa-claro: #fde4e8;
  --rosa-medio: #f8bbd0;
  --rosa-fuerte: #e91e63;
  --rosa-oscuro: #c2185b;
  --texto-principal: #4a4a4a;
  --texto-secundario: #757575;
  --blanco: #ffffff;
  --sombra: rgba(233, 30, 99, 0.15);
}

body {
  font-family: "Georgia", "Times New Roman", serif;
  background: linear-gradient(to bottom, #ffffff 0%, var(--rosa-claro) 100%);
  color: var(--texto-principal);
  line-height: 1.6;
  min-height: 100vh;
}

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
}

/* Header */
header {
  background: var(--blanco);
  padding: 20px 0;
  box-shadow: 0 2px 10px var(--sombra);
  position: sticky;
  top: 0;
  z-index: 100;
}

header .container {
  display: block;
}

.header-content {
  display: grid;
  gap: 14px;
}

.header-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.logo-space {
  flex: 1;
}

.logo-placeholder {
  width: 150px;
  height: 80px;
  border: 2px dashed var(--rosa-medio);
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  color: var(--rosa-fuerte);
  font-size: 14px;
  font-weight: bold;
}

.logo {
  height: 80px;
  width: auto;
  object-fit: contain;
  cursor: pointer;
}

.cart-icon {
  font-size: 28px;
  cursor: pointer;
  position: relative;
  padding: 10px;
  transition: transform 0.3s ease;
}

.cart-icon:hover {
  transform: scale(1.1);
}

.cart-count {
  position: absolute;
  top: 5px;
  right: 5px;
  background: var(--rosa-fuerte);
  color: var(--blanco);
  border-radius: 50%;
  width: 22px;
  height: 22px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  font-weight: bold;
  font-family: "Arial", sans-serif;
}

/* Promo banner */
.promo-banner {
  display: none;
  align-self: center;
  max-width: 540px;
  padding: 10px 18px;
  border: 1px solid var(--rosa-medio);
  border-radius: 999px;
  background: linear-gradient(135deg, #fff7fa, #ffffff);
  color: var(--rosa-oscuro);
  font-size: 0.95rem;
  font-weight: 600;
  line-height: 1.4;
  text-align: center;
  box-shadow: 0 8px 22px rgba(233, 30, 99, 0.12);
}

/* Banner especial mes de las Madres */
.madres-banner {
    align-self: center;
    max-width: 540px;
    margin-top: 8px;
    padding: 10px 18px;
    border: 1.5px dashed var(--rosa-fuerte);
    border-radius: 999px;
    background: linear-gradient(90deg, #fff0f6 0%, #ffe3ec 100%);
    color: var(--rosa-oscuro);
    font-size: 1.05rem;
    font-weight: 700;
    text-align: center;
    box-shadow: 0 2px 8px rgba(233, 30, 99, 0.10);
    letter-spacing: 0.01em;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 6px;
  }

@media (max-width: 600px) {
  .madres-banner {
    font-size: 0.98rem;
    padding: 9px 10px;
    margin-top: 6px;
    max-width: 98vw;
    border-width: 1px;
  }
}

/* Hero Section */
.hero {
  padding: 60px 20px;
  text-align: center;
  background: linear-gradient(135deg, var(--rosa-claro) 0%, #ffffff 100%);
  position: relative;
  overflow: hidden;
}

.hero::before,
.hero::after {
  content: "🌸";
  position: absolute;
  font-size: 80px;
  opacity: 0.1;
}

.hero::before {
  top: 20px;
  left: 50px;
  transform: rotate(-15deg);
}

.hero::after {
  bottom: 20px;
  right: 50px;
  transform: rotate(15deg);
}

.hero h1 {
  font-size: 2.5rem;
  color: var(--rosa-oscuro);
  margin-bottom: 30px;
  font-weight: 400;
  letter-spacing: 1px;
  line-height: 1.3;
}

.hero-content {
  max-width: 800px;
  margin: 0 auto;
}

.hero-content p {
  font-size: 1.1rem;
  color: var(--texto-secundario);
  margin-bottom: 20px;
  line-height: 1.8;
}

.hero-content .note {
  font-style: italic;
  color: var(--rosa-oscuro);
  font-size: 1rem;
  margin-top: 30px;
}

/* Filters */
.filters {
  padding: 40px 20px;
  text-align: center;
}

.filters h2 {
  font-size: 2rem;
  color: var(--rosa-oscuro);
  margin-bottom: 30px;
  font-weight: 400;
}

.filter-buttons {
  display: flex;
  gap: 15px;
  justify-content: center;
  flex-wrap: wrap;
}

.filter-btn {
  padding: 12px 30px;
  border: 2px solid var(--rosa-medio);
  background: var(--blanco);
  color: var(--rosa-fuerte);
  border-radius: 30px;
  cursor: pointer;
  font-size: 1rem;
  font-family: "Georgia", serif;
  transition: all 0.3s ease;
  font-weight: 500;
}

.filter-btn:hover {
  background: var(--rosa-claro);
  transform: translateY(-2px);
  box-shadow: 0 4px 15px var(--sombra);
}

.filter-btn.active {
  background: var(--rosa-fuerte);
  color: var(--blanco);
  border-color: var(--rosa-fuerte);
}

/* Products Grid */
.products {
  padding: 40px 20px 80px;
}

.products-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 35px;
}

.product-empty {
  grid-column: 1 / -1;
  text-align: center;
  color: var(--texto-secundario);
  padding: 30px 10px;
  font-style: italic;
}

.product-card {
  background: var(--blanco);
  border-radius: 20px;
  overflow: hidden;
  box-shadow: 0 5px 20px var(--sombra);
  transition: all 0.4s ease;
  opacity: 1;
  transform: scale(1);
}

.product-card:hover {
  transform: translateY(-10px);
  box-shadow: 0 10px 30px rgba(233, 30, 99, 0.25);
}

.product-card.hidden {
  display: none;
}

/* Estilos para imágenes de productos */
.product-image {
  width: 100%;
  height: 350px;
  background: var(--blanco); /* ← Fondo blanco */
  border-bottom: 3px solid var(--rosa-medio);
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
}

.product-image img {
  width: 100%;
  height: 100%;
  object-fit: contain; /* ← Muestra la imagen completa sin recortar */
  transition: transform 0.4s ease;
}

.product-badge {
  position: absolute;
  top: 16px;
  left: 16px;
  z-index: 1;
  padding: 8px 14px;
  border-radius: 999px;
  background: rgba(179, 18, 67, 0.92);
  color: var(--blanco);
  font-size: 0.85rem;
  font-weight: bold;
  letter-spacing: 0.04em;
  box-shadow: 0 8px 18px rgba(179, 18, 67, 0.24);
}

.product-card:hover .product-image img {
  transform: scale(1.1);
}

.product-card.is-out-of-stock .product-image img {
  opacity: 0.58;
}

/* Placeholder para cuando no hay imagen */
.product-image-placeholder {
  width: 100%;
  height: 350px;
  background: linear-gradient(
    135deg,
    var(--rosa-claro) 0%,
    var(--rosa-medio) 100%
  );
  display: flex;
  align-items: center;
  justify-content: center;
  border-bottom: 3px solid var(--rosa-medio);
  position: relative;
  overflow: hidden;
}

.product-image-placeholder::before {
  content: "🌺";
  position: absolute;
  font-size: 100px;
  opacity: 0.3;
}

.product-image-placeholder span {
  color: var(--rosa-oscuro);
  font-size: 1.1rem;
  font-weight: 500;
  z-index: 1;
  background: rgba(255, 255, 255, 0.9);
  padding: 15px 25px;
  border-radius: 10px;
}

.product-info {
  padding: 25px;
}

.product-name {
  font-size: 1.4rem;
  color: var(--rosa-oscuro);
  margin-bottom: 10px;
  font-weight: 500;
  min-height: 40px;
}

.product-name:focus,
.product-reference:focus,
.product-description:focus,
.product-price:focus {
  outline: 2px solid var(--rosa-medio);
  background: #fff9fa;
  border-radius: 5px;
  padding: 5px;
}

.product-reference {
  font-size: 0.92rem;
  color: var(--rosa-oscuro);
  margin-bottom: 10px;
  font-weight: 600;
}

.product-description {
  font-size: 1rem;
  color: var(--texto-secundario);
  margin-bottom: 15px;
  font-style: italic;
}

.product-price {
  font-size: 1.8rem;
  color: var(--rosa-fuerte);
  font-weight: bold;
  margin-bottom: 20px;
  font-family: "Arial", sans-serif;
}

.product-stock-status {
  margin-bottom: 18px;
  color: #b31243;
  font-weight: 600;
  letter-spacing: 0.01em;
}

.add-to-cart {
  width: 100%;
  padding: 15px;
  background: var(--rosa-fuerte);
  color: var(--blanco);
  border: none;
  border-radius: 30px;
  font-size: 1.1rem;
  cursor: pointer;
  transition: all 0.3s ease;
  font-family: "Georgia", serif;
  font-weight: 500;
}

.add-to-cart:hover {
  background: var(--rosa-oscuro);
  transform: scale(1.05);
  box-shadow: 0 5px 15px var(--sombra);
}

.add-to-cart:active {
  transform: scale(0.98);
}

.add-to-cart:disabled {
  background: #d6a7b8;
  color: rgba(255, 255, 255, 0.96);
  cursor: not-allowed;
  box-shadow: none;
  transform: none;
}

.product-card.is-out-of-stock {
  box-shadow: 0 5px 20px rgba(179, 18, 67, 0.16);
}

.product-card.is-out-of-stock:hover {
  transform: translateY(-4px);
}

/* Cart Modal */
.cart-modal {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.6);
  z-index: 1000;
  align-items: center;
  justify-content: center;
}

.cart-modal.active {
  display: flex;
}

.cart-content {
  background: var(--blanco);
  border-radius: 20px;
  width: 90%;
  max-width: 600px;
  max-height: 80vh;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.3);
}

.cart-header {
  background: linear-gradient(
    135deg,
    var(--rosa-fuerte) 0%,
    var(--rosa-oscuro) 100%
  );
  color: var(--blanco);
  padding: 25px;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.cart-header h2 {
  font-size: 1.8rem;
  font-weight: 400;
}

.close-cart {
  background: none;
  border: none;
  color: var(--blanco);
  font-size: 2rem;
  cursor: pointer;
  padding: 0;
  width: 35px;
  height: 35px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  transition: all 0.3s ease;
}

.close-cart:hover {
  background: rgba(255, 255, 255, 0.2);
}

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

.cart-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 15px;
  border-bottom: 1px solid var(--rosa-claro);
  margin-bottom: 15px;
}

.cart-item-info h4 {
  color: var(--rosa-oscuro);
  margin-bottom: 5px;
  font-size: 1.1rem;
}

.cart-item-info p {
  color: var(--texto-secundario);
  font-size: 0.9rem;
}

.cart-item-price {
  font-size: 1.3rem;
  color: var(--rosa-fuerte);
  font-weight: bold;
  font-family: "Arial", sans-serif;
}

.remove-item {
  background: none;
  border: none;
  color: var(--texto-secundario);
  cursor: pointer;
  font-size: 1.2rem;
  padding: 5px 10px;
  transition: all 0.3s ease;
}

.remove-item:hover {
  color: var(--rosa-fuerte);
}

.cart-empty {
  text-align: center;
  padding: 40px 20px;
  color: var(--texto-secundario);
  font-size: 1.1rem;
}

.cart-footer {
  padding: 25px;
  border-top: 2px solid var(--rosa-claro);
}

.btn-whatsapp {
  width: 100%;
  padding: 18px;
  background: #25d366;
  color: var(--blanco);
  border: none;
  border-radius: 30px;
  font-size: 1.2rem;
  cursor: pointer;
  transition: all 0.3s ease;
  font-family: "Georgia", serif;
  font-weight: 500;
}

.btn-whatsapp:hover {
  background: #20ba5a;
  transform: scale(1.05);
  box-shadow: 0 5px 20px rgba(37, 211, 102, 0.4);
}

.btn-whatsapp:active {
  transform: scale(0.98);
}

/* Footer */
footer {
  background: var(--rosa-oscuro);
  color: var(--blanco);
  padding: 40px 20px;
  text-align: center;
  margin-top: 60px;
}

.footer-decoration {
  font-size: 2rem;
  margin-bottom: 20px;
}

footer p {
  margin: 10px 0;
  font-size: 1rem;
}

.footer-note {
  opacity: 0.8;
  font-size: 0.9rem;
}

/* Animaciones */
@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.product-card {
  animation: fadeIn 0.5s ease forwards;
}

/* Responsive Mejorado */

/* Tablets - Pantallas medianas (768px - 1024px) */
@media (max-width: 1024px) {
  .container {
    padding: 0 15px;
  }

  .hero h1 {
    font-size: 2.2rem;
  }

  .products-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 25px;
  }

  .product-image,
  .product-image-placeholder {
    height: 320px;
  }
}

/* Tablets pequeñas y móviles grandes (481px - 768px) */
@media (max-width: 768px) {
  /* Header */
  header {
    padding: 15px 0;
  }

  .header-content {
    gap: 12px;
  }

  .promo-banner {
    max-width: 100%;
    padding: 9px 14px;
    font-size: 0.88rem;
  }

  .logo-placeholder {
    width: 100px;
    height: 50px;
    font-size: 11px;
  }

  .logo {
    height: 50px;
  }

  .cart-icon {
    font-size: 24px;
  }

  /* Hero */
  .hero {
    padding: 40px 15px;
  }

  .hero h1 {
    font-size: 1.6rem;
    margin-bottom: 20px;
    line-height: 1.4;
  }

  .hero-content p {
    font-size: 0.95rem;
    line-height: 1.6;
  }

  .hero-content .note {
    font-size: 0.9rem;
    margin-top: 20px;
  }

  .hero::before,
  .hero::after {
    font-size: 50px;
  }

  /* Filtros */
  .filters {
    padding: 30px 15px;
  }

  .filters h2 {
    font-size: 1.6rem;
    margin-bottom: 20px;
  }

  .filter-buttons {
    gap: 10px;
    justify-content: center;
  }

  .filter-btn {
    padding: 10px 18px;
    font-size: 0.9rem;
  }

  /* Productos */
  .products {
    padding: 30px 15px 60px;
  }

  .products-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
  }

  .product-image,
  .product-image-placeholder {
    height: 250px;
    background-size: cover;
    background-position: center;
  }

  .product-image-placeholder::before {
    font-size: 60px;
  }

  .product-image-placeholder span {
    font-size: 0.9rem;
    padding: 10px 15px;
  }

  .product-info {
    padding: 15px;
  }

  .product-name {
    font-size: 1.1rem;
    min-height: 35px;
  }

  .product-description {
    font-size: 0.85rem;
    margin-bottom: 10px;
  }

  .product-price {
    font-size: 1.4rem;
    margin-bottom: 15px;
  }

  .add-to-cart {
    padding: 12px;
    font-size: 0.95rem;
  }

  /* Modal del carrito */
  .cart-content {
    width: 95%;
    max-height: 85vh;
  }

  .cart-header {
    padding: 20px;
  }

  .cart-header h2 {
    font-size: 1.4rem;
  }

  .cart-items {
    padding: 20px;
  }

  .cart-item {
    flex-direction: column;
    align-items: flex-start;
    gap: 10px;
    padding: 12px;
  }

  .cart-item > div:last-child {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
  }

  .cart-item-info h4 {
    font-size: 1rem;
  }

  .cart-item-info p {
    font-size: 0.85rem;
  }

  .cart-item-price {
    font-size: 1.2rem;
  }

  .cart-footer {
    padding: 20px;
  }

  .btn-whatsapp {
    padding: 15px;
    font-size: 1rem;
  }

  /* Footer */
  footer {
    padding: 30px 15px;
  }

  .footer-decoration {
    font-size: 1.5rem;
    margin-bottom: 15px;
  }

  footer p {
    font-size: 0.9rem;
  }
}

/* Móviles (320px - 480px) */
@media (max-width: 480px) {
  /* Header */
  .header-top {
    gap: 12px;
  }

  .logo-placeholder {
    width: 80px;
    height: 40px;
    font-size: 9px;
  }

  .logo {
    height: 40px;
  }

  .cart-icon {
    font-size: 22px;
    padding: 8px;
  }

  .cart-count {
    width: 20px;
    height: 20px;
    font-size: 11px;
    top: 3px;
    right: 3px;
  }

  .promo-banner {
    border-radius: 20px;
    padding: 10px 12px;
    font-size: 0.82rem;
    line-height: 1.35;
  }

  /* Hero */
  .hero {
    padding: 30px 15px;
  }

  .hero h1 {
    font-size: 1.4rem;
    margin-bottom: 15px;
  }

  .hero-content p {
    font-size: 0.9rem;
    margin-bottom: 15px;
  }

  .hero-content .note {
    font-size: 0.85rem;
  }

  .hero::before,
  .hero::after {
    font-size: 40px;
  }

  /* Filtros */
  .filters {
    padding: 25px 10px;
  }

  .filters h2 {
    font-size: 1.4rem;
    margin-bottom: 15px;
  }

  .filter-buttons {
    gap: 8px;
  }

  .filter-btn {
    padding: 8px 15px;
    font-size: 0.85rem;
    border-width: 1.5px;
  }

  /* Productos */
  .products {
    padding: 25px 10px 50px;
  }

  .products-grid {
    grid-template-columns: 1fr;
    gap: 20px;
  }

  .product-card {
    max-width: 100%;
  }

  .product-image,
  .product-image-placeholder {
    height: 300px;
  }

  .product-image-placeholder::before {
    font-size: 70px;
  }

  .product-image-placeholder span {
    font-size: 0.95rem;
    padding: 12px 20px;
  }

  .product-info {
    padding: 18px;
  }

  .product-name {
    font-size: 1.2rem;
    min-height: auto;
    margin-bottom: 8px;
  }

  .product-description {
    font-size: 0.9rem;
    margin-bottom: 12px;
  }

  .product-price {
    font-size: 1.6rem;
    margin-bottom: 15px;
  }

  .add-to-cart {
    padding: 14px;
    font-size: 1rem;
    border-radius: 25px;
  }

  /* Modal del carrito */
  .cart-content {
    width: 100%;
    max-width: 100%;
    max-height: 90vh;
    border-radius: 15px 15px 0 0;
    margin-top: auto;
  }

  .cart-header {
    padding: 18px;
    border-radius: 15px 15px 0 0;
  }

  .cart-header h2 {
    font-size: 1.3rem;
  }

  .close-cart {
    font-size: 1.8rem;
    width: 32px;
    height: 32px;
  }

  .cart-items {
    padding: 15px;
  }

  .cart-item {
    padding: 10px;
    margin-bottom: 10px;
  }

  .cart-item-info h4 {
    font-size: 0.95rem;
  }

  .cart-item-info p {
    font-size: 0.8rem;
  }

  .cart-item-price {
    font-size: 1.1rem;
  }

  .remove-item {
    font-size: 1.1rem;
    padding: 3px 8px;
  }

  .cart-empty {
    padding: 30px 15px;
    font-size: 1rem;
  }

  .cart-footer {
    padding: 15px;
  }

  .btn-whatsapp {
    padding: 14px;
    font-size: 1rem;
    border-radius: 25px;
  }

  /* Footer */
  footer {
    padding: 25px 15px;
    margin-top: 40px;
  }

  .footer-decoration {
    font-size: 1.3rem;
  }

  footer p {
    font-size: 0.85rem;
    margin: 8px 0;
  }

  .footer-note {
    font-size: 0.8rem;
  }
}

/* Móviles muy pequeños (hasta 360px) */
@media (max-width: 360px) {
  .hero h1 {
    font-size: 1.2rem;
  }

  .filters h2 {
    font-size: 1.2rem;
  }

  .filter-btn {
    padding: 7px 12px;
    font-size: 0.8rem;
  }

  .product-name {
    font-size: 1.1rem;
  }

  .product-price {
    font-size: 1.4rem;
  }

  .product-image,
  .product-image-placeholder {
    height: 280px;
  }
}

/* Landscape en móviles */
@media (max-height: 600px) and (orientation: landscape) {
  .hero {
    padding: 20px 15px;
  }

  .hero h1 {
    font-size: 1.3rem;
    margin-bottom: 10px;
  }

  .hero-content p {
    font-size: 0.85rem;
    margin-bottom: 10px;
  }

  .filters {
    padding: 20px 15px;
  }

  .filters h2 {
    font-size: 1.3rem;
    margin-bottom: 15px;
  }

  .cart-content {
    max-height: 95vh;
  }

}

/* Mejorar táctil en móviles */
@media (hover: none) and (pointer: coarse) {
  .filter-btn,
  .add-to-cart,
  .cart-icon,
  .close-cart,
  .remove-item,
  .btn-whatsapp {
    min-height: 44px;
    min-width: 44px;
  }

  .filter-btn:active,
  .add-to-cart:active,
  .btn-whatsapp:active {
    transform: scale(0.95);
  }
}

/* Toast de recuperación de carrito */
.cart-toast {
  position: fixed;
  bottom: 28px;
  left: 50%;
  transform: translateX(-50%) translateY(16px);
  background: var(--blanco);
  border: 1.5px solid var(--rosa-medio);
  border-radius: 999px;
  padding: 11px 18px;
  display: flex;
  align-items: center;
  gap: 10px;
  box-shadow: 0 4px 24px rgba(233, 30, 99, 0.18);
  z-index: 999;
  opacity: 0;
  transition: opacity 0.35s ease, transform 0.35s ease;
  max-width: 90vw;
  pointer-events: none;
}

.cart-toast.visible {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
  pointer-events: auto;
}

.cart-toast-text {
  color: var(--texto-principal);
  font-size: 0.92rem;
  white-space: nowrap;
}

.cart-toast-link {
  color: var(--rosa-fuerte);
  font-weight: 700;
  font-size: 0.92rem;
  cursor: pointer;
  background: none;
  border: none;
  padding: 0;
  font-family: inherit;
  text-decoration: underline;
  white-space: nowrap;
}

.cart-toast-link:hover {
  color: var(--rosa-oscuro);
}

.cart-toast-close {
  background: none;
  border: none;
  color: var(--texto-secundario);
  cursor: pointer;
  font-size: 0.85rem;
  padding: 0;
  line-height: 1;
  flex-shrink: 0;
}

.cart-toast-close:hover {
  color: var(--rosa-fuerte);
}

@media (max-width: 480px) {
  .cart-toast {
    bottom: 16px;
    padding: 10px 14px;
    gap: 8px;
    border-radius: 16px;
  }

  .cart-toast-text {
    font-size: 0.85rem;
  }

  .cart-toast-link {
    font-size: 0.85rem;
  }
}
