:root {
  color-scheme: light;
  --color-bg: #edf2f7;
  --body-gradient: radial-gradient(
    circle at top,
    rgba(37, 99, 235, 0.12),
    transparent 60%
  );
  --color-surface: rgba(255, 255, 255, 0.8);
  --color-surface-solid: #ffffff;
  --color-border: rgba(15, 23, 42, 0.12);
  --color-text: #0f172a;
  --color-muted: #475569;
  --color-primary: #2563eb;
  --color-chip-bg: rgba(241, 245, 249, 0.9);
  --color-header: rgba(255, 255, 255, 0.9);
  --color-footer: rgba(241, 245, 249, 0.9);
  --shadow-header: 0 18px 36px rgba(15, 23, 42, 0.08);
  --shadow-card: 0 24px 48px rgba(15, 23, 42, 0.08);
}

body[data-theme='dark'] {
  color-scheme: dark;
  --color-bg: #050814;
  --body-gradient: radial-gradient(
    circle at top,
    rgba(56, 189, 248, 0.12),
    transparent 58%
  );
  --color-surface: rgba(13, 20, 37, 0.9);
  --color-surface-solid: #10172a;
  --color-border: rgba(148, 163, 184, 0.18);
  --color-text: #f8fafc;
  --color-muted: #94a3c8;
  --color-primary: #38bdf8;
  --color-chip-bg: rgba(13, 20, 37, 0.8);
  --color-header: rgba(5, 8, 20, 0.88);
  --color-footer: rgba(7, 11, 22, 0.9);
  --shadow-header: 0 18px 36px rgba(2, 8, 20, 0.55);
  --shadow-card: 0 24px 48px rgba(2, 8, 20, 0.42);
}

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

body {
  font-family: 'Poppins', 'Segoe UI', sans-serif;
  line-height: 1.6;
  background: var(--body-gradient), var(--color-bg);
  color: var(--color-text);
  min-height: 100vh;
  transition: background 0.3s ease, color 0.3s ease;
}

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

a:focus-visible {
  outline: 2px solid var(--color-primary);
  outline-offset: 4px;
}

img {
  display: block;
  width: 100%;
  height: auto;
  border-radius: 16px;
  object-fit: cover;
}

.shell {
  width: min(1500px, 100% - 2rem);
  margin: 0 auto;
}

.eyebrow {
  text-transform: uppercase;
  letter-spacing: 0.32em;
  font-size: 0.7rem;
  color: var(--color-muted);
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  padding: 0.6rem 1.6rem;
  border-radius: 999px;
  background: var(--color-primary);
  color: #020617;
  font-weight: 600;
  letter-spacing: 0.08em;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  box-shadow: 0 18px 42px rgba(56, 189, 248, 0.32);
}

.btn:hover,
.btn:focus-visible {
  transform: translateY(-2px);
  box-shadow: 0 26px 52px rgba(56, 189, 248, 0.4);
}

/* HEADER */

.site-header {
  position: sticky;
  top: 0;
  z-index: 30;
  backdrop-filter: blur(18px);
  background: var(--color-header);
  border-bottom: 1px solid var(--color-border);
  box-shadow: var(--shadow-header);
}

.site-header .shell {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: clamp(0.75rem, 2vw, 1.8rem);
  padding: 0.65rem 0;
}

.brand {
  display: flex;
  flex-direction: column;
  gap: 0.1rem;
  text-transform: uppercase;
  letter-spacing: 0.28em;
}

.brand__name {
  font-weight: 600;
  font-size: 0.95rem;
}

.brand__tagline {
  font-size: 0.7rem;
  letter-spacing: 0.24em;
  color: var(--color-muted);
}

.site-nav {
  display: flex;
  align-items: center;
  gap: clamp(0.75rem, 2.8vw, 2.4rem);
  flex-wrap: wrap;
}

.site-nav a {
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.32em;
  color: var(--color-muted);
  position: relative;
  padding-bottom: 0.2rem;
}

.site-nav a::after {
  content: '';
  position: absolute;
  left: 0;
  bottom: 0;
  width: 100%;
  height: 1px;
  background: transparent;
  transition: background 0.2s ease, transform 0.2s ease;
  transform: scaleX(0);
  transform-origin: left;
}

.site-nav a:hover,
.site-nav a:focus-visible {
  color: var(--color-primary);
}

.site-nav a:hover::after,
.site-nav a:focus-visible::after {
  background: var(--color-primary);
  transform: scaleX(1);
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 0.65rem;
}

.theme-toggle {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  border: 1px solid var(--color-border);
  background: var(--color-surface);
  color: var(--color-text);
  font-size: 0.7rem;
  padding: 0.35rem 1rem;
  border-radius: 999px;
  cursor: pointer;
  transition: background 0.2s ease, color 0.2s ease, border 0.2s ease;
}

.theme-toggle:hover,
.theme-toggle:focus-visible {
  border-color: rgba(56, 189, 248, 0.5);
  color: var(--color-primary);
}

.theme-toggle__icon {
  font-size: 1rem;
  line-height: 1;
}

.theme-toggle__label {
  text-transform: uppercase;
  letter-spacing: 0.18em;
}

.whatsapp-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 34px;
  height: 34px;
  border-radius: 999px;
  background: #22c55e;
  color: #021311;
  box-shadow: 0 16px 32px rgba(34, 197, 94, 0.36);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.whatsapp-badge:hover {
  transform: translateY(-2px) scale(1.02);
  box-shadow: 0 22px 40px rgba(34, 197, 94, 0.42);
}

/* PROMO BANNER */

.promo-banner {
  background: linear-gradient(120deg, rgba(244, 63, 94, 0.18), rgba(59, 130, 246, 0.18)),
    var(--color-surface-solid);
  border-bottom: 2px dashed rgba(244, 63, 94, 0.4);
  position: relative;
  overflow: hidden;
  box-shadow: 0 24px 48px rgba(15, 23, 42, 0.12);
}

.promo-banner::before,
.promo-banner::after {
  content: '';
  position: absolute;
  top: 0;
  bottom: 0;
  width: 80px;
  pointer-events: none;
}

.promo-banner::before {
  left: 0;
  background: linear-gradient(90deg, var(--color-surface-solid), transparent);
}

.promo-banner::after {
  right: 0;
  background: linear-gradient(270deg, var(--color-surface-solid), transparent);
}

.promo-banner .shell {
  padding: 0.4rem 0;
}

.promo-banner__content {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  padding: 0.4rem 0;
}

.promo-banner__item {
  font-size: 0.85rem;
  text-transform: none;
  letter-spacing: 0.08em;
  color: var(--color-text);
}

.promo-banner__separator {
  color: #f43f5e;
  font-weight: 700;
}

body[data-theme='dark'] .promo-banner {
  background: linear-gradient(120deg, rgba(244, 63, 94, 0.22), rgba(14, 165, 233, 0.16)),
    rgba(5, 8, 20, 0.94);
  border-bottom-color: rgba(248, 250, 252, 0.15);
  box-shadow: 0 24px 48px rgba(2, 8, 20, 0.55);
}

body[data-theme='dark'] .promo-banner::before {
  background: linear-gradient(90deg, rgba(5, 8, 20, 0.94), transparent);
}

body[data-theme='dark'] .promo-banner::after {
  background: linear-gradient(270deg, rgba(5, 8, 20, 0.94), transparent);
}

body[data-theme='dark'] .promo-banner__separator {
  color: #f472b6;
}

/* HERO */

.hero {
  padding: clamp(2.5rem, 8vw, 4.5rem) 0;
}

.hero__grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: clamp(1.8rem, 4vw, 3rem);
  align-items: center;
}

.hero__content h1 {
  font-size: clamp(2.2rem, 4.8vw, 3.4rem);
  line-height: 1.1;
  margin: 1rem 0 1.4rem;
}

.hero__content p {
  max-width: 520px;
  color: var(--color-muted);
  margin-bottom: 1.6rem;
}

.hero__media img {
  box-shadow: var(--shadow-card);
}

/* DESTACADOS */

.highlight {
  padding: clamp(1.5rem, 6vw, 2.8rem) 0;
}

.highlight__grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 1.4rem;
  align-items: stretch;
}

@media (min-width: 900px) {
  .highlight__grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

.highlight__card {
  padding: 1.6rem;
  border-radius: 20px;
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  box-shadow: var(--shadow-card);
  display: flex;
  gap: 1rem;
  align-items: flex-start;
}

.highlight__icon {
  width: 48px;
  height: 48px;
  border-radius: 14px;
  background: rgba(59, 130, 246, 0.15);
  color: var(--color-primary);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.highlight__icon svg {
  width: 28px;
  height: 28px;
  fill: currentColor;
}

.highlight__card > div {
  flex: 1;
}

.highlight__card h2 {
  margin-bottom: 0.6rem;
}

/* CATÁLOGO */

.catalog {
  padding: clamp(2.5rem, 8vw, 4.5rem) 0;
}

.catalog__header {
  text-align: left;
  display: grid;
  gap: 0.75rem;
  margin-bottom: 2rem;
}

/* MENÚ DE CATEGORÍAS */
.catalog__nav {
  margin: 1.5rem auto 0;
  width: 100%;
  max-width: 1400px;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 0.9rem 1.1rem;
}

.catalog__nav a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.65rem 1.2rem;
  border-radius: 999px;
  border: 1px solid var(--color-border);
  background: var(--color-chip-bg);
  font-size: 0.68rem;
  letter-spacing: 0.32em;
  text-transform: uppercase;
  color: var(--color-muted);
  min-height: 48px;
  width: 100%;
  text-align: center;
  white-space: normal;
  line-height: 1.35;
}

.catalog__nav a[data-pill='festividades'] {
  border-width: 2px;
  border-style: dashed;
  border-color: rgba(251, 191, 36, 0.8);
  background: radial-gradient(circle at top, rgba(251, 146, 60, 0.22), transparent),
    var(--color-chip-bg);
  color: #fcd34d;
  box-shadow: 0 0 0 2px rgba(251, 146, 60, 0.15), 0 0 12px rgba(251, 191, 36, 0.35);
  animation: festividadesPulse 3s ease-in-out infinite;
}

.catalog__nav a[data-pill='festividades']::after {
  content: '✨';
  margin-left: 0.35rem;
  font-size: 0.8rem;
}

.catalog__nav a[data-pill='mujeres'] {
  border-width: 2px;
  border-style: dashed;
  border-color: rgba(236, 72, 153, 0.8);
  background: radial-gradient(circle at top, rgba(244, 114, 182, 0.28), transparent),
    var(--color-chip-bg);
  color: #f9a8d4;
  box-shadow: 0 0 0 2px rgba(244, 114, 182, 0.2), 0 0 16px rgba(236, 72, 153, 0.45);
  animation: mujeresPulse 3s ease-in-out infinite;
}

.catalog__nav a[data-pill='mujeres']::after {
  content: '💋';
  margin-left: 0.35rem;
  font-size: 0.8rem;
}

@keyframes festividadesPulse {
  0%,
  100% {
    box-shadow: 0 0 0 2px rgba(251, 146, 60, 0.15), 0 0 10px rgba(251, 191, 36, 0.35);
  }
  50% {
    box-shadow: 0 0 0 3px rgba(251, 146, 60, 0.3), 0 0 26px rgba(251, 191, 36, 0.6);
  }
}

@keyframes mujeresPulse {
  0%,
  100% {
    box-shadow: 0 0 0 2px rgba(244, 114, 182, 0.18), 0 0 14px rgba(236, 72, 153, 0.35);
  }
  50% {
    box-shadow: 0 0 0 3px rgba(244, 114, 182, 0.35), 0 0 28px rgba(236, 72, 153, 0.6);
  }
}

.catalog__nav a:hover,
.catalog__nav a:focus-visible {
  color: var(--color-primary);
  border-color: rgba(56, 189, 248, 0.5);
}

/* Variante en modo claro */
body[data-theme='light'] .catalog__nav a {
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.96), #e0e7ff);
  border-color: rgba(99, 102, 241, 0.25);
  color: #0f172a;
  box-shadow: 0 10px 25px rgba(15, 23, 42, 0.08);
}

body[data-theme='light'] .catalog__nav a[data-pill='festividades'] {
  background: radial-gradient(circle at 30% 20%, rgba(249, 115, 22, 0.35), #fff7ed);
  border-color: rgba(249, 115, 22, 0.85);
  color: #9a3412;
  box-shadow: 0 0 0 2px rgba(251, 146, 60, 0.25), 0 0 12px rgba(251, 191, 36, 0.35);
}

body[data-theme='light'] .catalog__nav a[data-pill='mujeres'] {
  background: radial-gradient(circle at 30% 30%, rgba(244, 114, 182, 0.32), #fff0f6);
  border-color: rgba(236, 72, 153, 0.85);
  color: #be185d;
  box-shadow: 0 0 0 2px rgba(244, 114, 182, 0.25), 0 0 16px rgba(236, 72, 153, 0.35);
}

body[data-theme='light'] .catalog__nav a:hover,
body[data-theme='light'] .catalog__nav a:focus-visible {
  border-color: rgba(79, 70, 229, 0.5);
  color: #312e81;
}

/* CATEGORÍAS */

.category {
  padding: 2.6rem 0 0;
}

.category h3 {
  font-size: 1.6rem;
  margin: 0.6rem 0 1.6rem;
}

/* PRODUCTOS */

.products {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  gap: 1.5rem;
}

.product-card {
  padding: 1rem;
  background: var(--color-surface);
  border-radius: 20px;
  border: 1px solid var(--color-border);
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  min-height: 100%;
}

.product-card img {
  border-radius: 14px;
  height: 110px;
  object-fit: cover;
}

.product-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 22px 46px rgba(2, 8, 20, 0.48);
}

.product-card h4 {
  font-size: 0.9rem;
  line-height: 1.3;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.product-card p {
  color: var(--color-muted);
  font-size: 0.85rem;
}

.product-card__price {
  color: var(--color-primary);
  font-size: 0.95rem;
  font-weight: 600;
}

/* CONTACTO */

.contact {
  padding: clamp(2.8rem, 8vw, 4.5rem) 0;
}

.contact__grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 2rem;
  align-items: start;
}

.contact__list {
  list-style: none;
  display: grid;
  gap: 1.2rem;
}

.contact__list li {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
}

.contact__list span {
  display: block;
  font-size: 0.75rem;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: var(--color-muted);
  margin-bottom: 0.25rem;
}

.contact__social {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.contact__social svg {
  width: 20px;
  height: 20px;
  fill: currentColor;
}

/* FOOTER */

.site-footer {
  padding: 2rem 0 2.8rem;
  background: var(--color-footer);
  border-top: 1px solid var(--color-border);
  margin-top: 2rem;
}

.site-footer__grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 1.5rem;
  align-items: center;
}

.site-footer__links {
  display: flex;
  gap: 1rem;
  font-size: 0.75rem;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: var(--color-muted);
}

.site-footer__links a:hover,
.site-footer__links a:focus-visible {
  color: var(--color-primary);
}

.site-footer__legal {
  color: var(--color-muted);
  font-size: 0.78rem;
}

/* RESPONSIVE */

@media (max-width: 1200px) {
  .products {
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  }
}

@media (max-width: 900px) {
  .site-nav {
    justify-content: center;
  }

  .products {
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  }

  .catalog__nav {
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  }
}

@media (max-width: 720px) {
  .site-header .shell {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.75rem;
    padding: 0.5rem 0;
  }

  .whatsapp-badge {
    align-self: flex-end;
  }

  .site-nav {
    width: 100%;
    justify-content: flex-start;
    overflow-x: auto;
    padding-bottom: 0.2rem;
  }

  .site-nav a {
    white-space: nowrap;
    font-size: 0.6rem;
  }

  .shell {
    width: min(100%, 96vw);
  }

  .products {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .catalog__header {
    text-align: left;
  }

  .catalog__nav {
    gap: 0.5rem;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  }

  .product-card img {
    height: 90px;
  }
}

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

  .product-card {
    padding: 0.9rem;
  }

  .product-card img {
    height: 80px;
  }

  .whatsapp-badge {
    width: 32px;
    height: 32px;
  }
}

@media (prefers-color-scheme: light) {
  :root {
    /* Colores base para modo claro */
    --color-bg: #f8fafc;
    --color-surface: rgba(255, 255, 255, 0.9);
    --color-surface-solid: #ffffff;
    --color-border: rgba(148, 163, 184, 0.4);
    --color-text: #020617;
    --color-muted: #64748b;
  }

  body {
    background: radial-gradient(circle at top, rgba(56, 189, 248, 0.16), transparent 58%), var(--color-bg);
  }

  /* CATEGORÍAS EN MODO CLARO */
  .catalog__nav a {
    background: rgba(255, 255, 255, 0.96);
    border-color: var(--color-border);
    color: var(--color-muted);
  }

  .catalog__nav a:hover,
  .catalog__nav a:focus-visible {
    color: var(--color-primary);
    border-color: rgba(56, 189, 248, 0.7);
    box-shadow: 0 8px 18px rgba(15, 23, 42, 0.16);
  }
}
