@import url("https://fonts.googleapis.com/css2?family=Fraunces:ital,opsz,wght@0,9..144,400;0,9..144,600;1,9..144,500;1,9..144,600&family=Space+Grotesk:wght@500;600;700&family=DM+Sans:ital,wght@0,400;0,500;0,700;1,400&display=swap");

:root {
  --cream: #f5efe2;
  --cream-soft: #ede2ca;
  --cream-line: #ddceac;
  --ink: #1c160d;
  --gold: #b5813a;
  --gold-deep: #8a5f26;
  --gold-soft: #e3c184;
  --forest: #253a1f;
  --forest-deep: #182813;
  --forest-soft: #3f5a36;
  --flag-red: #d52b1e;
  --flag-yellow: #f4c300;
  --flag-green: #007a3d;
}

* {
  scrollbar-color: var(--gold) var(--cream-soft);
}

html {
  scroll-behavior: smooth;
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
  .marquee__track {
    animation: none !important;
  }
}

body {
  background: var(--cream);
  color: var(--ink);
  font-family: "DM Sans", ui-sans-serif, system-ui, sans-serif;
  cursor: url("cursor.png") 13 1, auto;
}

a,
button,
[role="button"],
[role="tab"],
input,
label {
  cursor: url("cursor.png") 13 1, pointer;
}

.font-display {
  font-family: "Fraunces", ui-serif, Georgia, serif;
}

.font-head {
  font-family: "Space Grotesk", ui-sans-serif, system-ui, sans-serif;
}

::selection {
  background: var(--gold);
  color: var(--forest-deep);
}

a:focus-visible,
button:focus-visible {
  outline: 2.5px solid var(--forest);
  outline-offset: 3px;
  border-radius: 2px;
}

/* ---------- Wave dividers (authored, echoes the printed catálogo cover) ---------- */

.wave-down {
  display: block;
  width: 100%;
  height: auto;
  transform: translateY(1px);
}

.wave-up {
  display: block;
  width: 100%;
  height: auto;
  transform: translateY(-1px) rotate(180deg);
}

/* ---------- Marquee (word slider: 100% NATURALES) ---------- */

.marquee {
  overflow: hidden;
  white-space: nowrap;
  position: relative;
  border-block: 1.5px solid var(--forest-deep);
}

.marquee__track {
  display: inline-flex;
  align-items: center;
  width: max-content;
  animation: marquee 26s linear infinite;
}

.marquee--reverse .marquee__track {
  animation-direction: reverse;
  animation-duration: 32s;
}

@keyframes marquee {
  from {
    transform: translateX(0);
  }
  to {
    transform: translateX(-50%);
  }
}

.marquee__item {
  display: inline-flex;
  align-items: center;
  gap: 0.75rem;
  padding-inline: 1.5rem;
  font-family: "Space Grotesk", ui-sans-serif, system-ui, sans-serif;
  font-weight: 700;
  letter-spacing: 0.02em;
  font-size: clamp(1.1rem, 2.4vw, 1.65rem);
}

.marquee__dot {
  width: 0.4em;
  height: 0.4em;
  border-radius: 999px;
  background: currentColor;
  opacity: 0.55;
  flex: none;
}

/* ---------- Nav ---------- */

#mobile-menu {
  display: none;
}

#mobile-menu.is-open {
  display: flex;
}

#nav-toggle svg {
  transition: transform 200ms ease;
}

#nav-toggle.is-open svg {
  transform: rotate(90deg);
}

#nav-toggle .icon-close {
  display: none;
}

#nav-toggle.is-open .icon-menu {
  display: none;
}

#nav-toggle.is-open .icon-close {
  display: block;
}

/* ---------- Category tabs ---------- */

.tab-btn {
  font-family: "Space Grotesk", ui-sans-serif, system-ui, sans-serif;
  font-weight: 600;
  border: 1.5px solid var(--forest);
  color: var(--forest);
  background: transparent;
  transition: background-color 160ms ease, color 160ms ease, transform 160ms ease;
}

.tab-btn:hover {
  background: var(--forest);
  color: var(--cream);
}

.tab-btn.is-active {
  background: var(--forest);
  color: var(--cream);
  box-shadow: 0 2px 0 0 var(--forest-deep);
}

/* ---------- Product cards ---------- */

.product-card {
  background: #fffdf8;
  border: 1px solid var(--cream-line);
  border-radius: 1.1rem;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  box-shadow: 0 1px 2px rgba(37, 58, 31, 0.06);
  transition: transform 220ms cubic-bezier(0.22, 1, 0.36, 1), box-shadow 220ms cubic-bezier(0.22, 1, 0.36, 1), border-color 220ms ease;
}

.product-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 18px 32px -18px rgba(28, 22, 13, 0.35), 0 4px 10px -4px rgba(28, 22, 13, 0.15);
  border-color: var(--gold);
}

.product-card__media-link {
  display: block;
}

.product-card__frame {
  position: relative;
  aspect-ratio: 4 / 5;
  overflow: hidden;
  background: var(--cream-soft);
}

.product-card__img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: top center;
  transition: transform 420ms cubic-bezier(0.22, 1, 0.36, 1);
}

.product-card:hover .product-card__img {
  transform: scale(1.045);
}

.product-card__save {
  position: absolute;
  top: 0.6rem;
  left: 0.6rem;
  background: var(--flag-red);
  color: #fff;
  font-family: "Space Grotesk", sans-serif;
  font-weight: 700;
  font-size: 0.68rem;
  letter-spacing: 0.03em;
  padding: 0.3rem 0.55rem;
  border-radius: 999px;
  text-transform: uppercase;
}

.product-card__category {
  position: absolute;
  top: 0.6rem;
  right: 0.6rem;
  background: rgba(28, 22, 13, 0.72);
  color: var(--cream);
  font-family: "Space Grotesk", sans-serif;
  font-weight: 600;
  font-size: 0.68rem;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  padding: 0.3rem 0.55rem;
  border-radius: 999px;
  backdrop-filter: blur(2px);
}

.product-card__body {
  padding: 1.1rem 1.15rem 1.15rem;
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
  flex: 1;
}

.product-card__link {
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
  color: inherit;
  text-decoration: none;
}

.product-card__name {
  font-family: "Space Grotesk", sans-serif;
  font-weight: 700;
  font-size: 1.05rem;
  line-height: 1.25;
  color: var(--ink);
}

.product-card__desc {
  font-size: 0.86rem;
  color: var(--forest-soft);
  line-height: 1.4;
}

.product-card__benefits {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
  font-size: 0.79rem;
  color: #4a4030;
  margin-top: 0.1rem;
}

.product-card__benefits li {
  padding-left: 1.05rem;
  position: relative;
}

.product-card__benefits li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.5em;
  width: 0.45rem;
  height: 0.45rem;
  background: var(--gold);
  border-radius: 999px;
}

.product-card__meta {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.74rem;
  color: #8a7a5c;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  margin-top: 0.15rem;
}

.product-card__footer {
  margin-top: auto;
  padding-top: 0.75rem;
  border-top: 1px dashed var(--cream-line);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.6rem;
}

.product-card__price {
  display: flex;
  flex-direction: column;
  line-height: 1.1;
}

.product-card__price-old {
  font-size: 0.72rem;
  color: #a3937a;
  text-decoration: line-through;
}

.product-card__price-now {
  font-family: "Space Grotesk", sans-serif;
  font-weight: 700;
  font-size: 1.2rem;
  color: var(--forest-deep);
}

/* ---------- Floating WhatsApp button ---------- */

.float-whatsapp {
  position: fixed;
  right: 1.1rem;
  bottom: 1.1rem;
  z-index: 40;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  background: var(--forest);
  color: var(--cream);
  padding: 0.8rem 1.1rem;
  border-radius: 999px;
  box-shadow: 0 12px 24px -8px rgba(24, 40, 19, 0.55);
  font-family: "Space Grotesk", sans-serif;
  font-weight: 600;
  font-size: 0.85rem;
  transition: transform 180ms ease, box-shadow 180ms ease;
}

.float-whatsapp:hover {
  transform: translateY(-2px) scale(1.02);
  box-shadow: 0 16px 30px -8px rgba(24, 40, 19, 0.6);
}

/* ---------- Loader ---------- */

.loader {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 1.5rem;
  background: var(--cream);
  transition: opacity 480ms cubic-bezier(0.22, 1, 0.36, 1), visibility 480ms;
}

.loader.is-hidden {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.loader__mark {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.85rem;
}

.loader__logo {
  width: 4.25rem;
  height: 4.25rem;
  border-radius: 999px;
  background: #fff;
  box-shadow: 0 10px 30px -12px rgba(28, 22, 13, 0.35);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

.loader__logo img {
  width: 2.9rem;
  height: 2.9rem;
  object-fit: contain;
}

.loader__word {
  font-family: "Fraunces", ui-serif, serif;
  font-style: italic;
  font-weight: 600;
  font-size: 1.35rem;
  color: var(--forest-deep);
}

.loader__bar {
  width: 13rem;
  height: 0.28rem;
  border-radius: 999px;
  background: var(--cream-line);
  overflow: hidden;
}

.loader__bar-fill {
  display: block;
  height: 100%;
  width: 0%;
  border-radius: 999px;
  background: linear-gradient(90deg, var(--gold-deep), var(--gold));
  animation: loader-fill 1000ms cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

@keyframes loader-fill {
  0% {
    width: 4%;
  }
  55% {
    width: 68%;
  }
  100% {
    width: 100%;
  }
}

@media (prefers-reduced-motion: reduce) {
  .loader__bar-fill {
    animation: none;
    width: 100%;
  }
}

/* ---------- Cart ---------- */

.cart-btn {
  position: relative;
  display: inline-flex;
  height: 2.5rem;
  width: 2.5rem;
  flex: none;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  border: 1.5px solid rgba(37, 58, 31, 0.3);
  color: var(--forest-deep);
  transition: background-color 160ms ease, border-color 160ms ease;
}

.cart-btn:hover {
  background: var(--cream-soft);
  border-color: var(--forest);
}

.cart-badge {
  position: absolute;
  top: -0.35rem;
  right: -0.35rem;
  min-width: 1.15rem;
  height: 1.15rem;
  padding: 0 0.25rem;
  border-radius: 999px;
  background: var(--flag-red);
  color: #fff;
  font-family: "Space Grotesk", sans-serif;
  font-size: 0.65rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  line-height: 1;
}

.cart-badge[data-count="0"] {
  display: none;
}

#sound-toggle .icon-sound-off {
  display: none;
}

#sound-toggle.is-muted .icon-sound-on {
  display: none;
}

#sound-toggle.is-muted .icon-sound-off {
  display: block;
}

.cart-backdrop {
  position: fixed;
  inset: 0;
  z-index: 90;
  background: rgba(28, 22, 13, 0.5);
  opacity: 0;
  pointer-events: none;
  transition: opacity 260ms ease;
}

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

.cart-drawer {
  position: fixed;
  top: 0;
  right: 0;
  bottom: 0;
  z-index: 95;
  width: min(24rem, 100vw);
  background: var(--cream);
  box-shadow: -20px 0 40px -20px rgba(28, 22, 13, 0.4);
  transform: translateX(100%);
  transition: transform 320ms cubic-bezier(0.22, 1, 0.36, 1);
  display: flex;
  flex-direction: column;
}

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

.cart-item {
  display: grid;
  grid-template-columns: 3.5rem 1fr auto;
  gap: 0.75rem;
  padding-block: 0.9rem;
  border-bottom: 1px solid var(--cream-line);
}

.cart-item__img {
  width: 3.5rem;
  height: 3.5rem;
  border-radius: 0.65rem;
  object-fit: cover;
  background: var(--cream-soft);
  border: 1px solid var(--cream-line);
}

.cart-item__name {
  font-family: "Space Grotesk", sans-serif;
  font-weight: 600;
  font-size: 0.88rem;
  color: var(--ink);
  line-height: 1.25;
}

.cart-item__price {
  font-size: 0.78rem;
  color: var(--forest-soft);
  margin-top: 0.15rem;
}

.cart-stepper {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  margin-top: 0.5rem;
}

.cart-stepper button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 1.5rem;
  height: 1.5rem;
  border-radius: 999px;
  border: 1.3px solid var(--forest);
  color: var(--forest-deep);
  font-family: "Space Grotesk", sans-serif;
  font-weight: 700;
  line-height: 1;
  transition: background-color 140ms ease, color 140ms ease;
}

.cart-stepper button:hover {
  background: var(--forest);
  color: var(--cream);
}

.cart-stepper span {
  min-width: 1.1rem;
  text-align: center;
  font-family: "Space Grotesk", sans-serif;
  font-weight: 700;
  font-size: 0.85rem;
}

.cart-item__remove {
  align-self: start;
  color: #a3937a;
  transition: color 140ms ease;
}

.cart-item__remove:hover {
  color: var(--flag-red);
}

/* ---------- Add-to-cart control on product cards ---------- */

.add-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  background: var(--gold);
  color: var(--ink);
  font-family: "Space Grotesk", sans-serif;
  font-weight: 600;
  font-size: 0.82rem;
  padding: 0.5rem 0.85rem;
  border-radius: 999px;
  transition: background-color 160ms ease, transform 160ms ease;
  white-space: nowrap;
}

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

.qty-stepper {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  background: var(--forest);
  border-radius: 999px;
  padding: 0.3rem 0.55rem;
}

.qty-stepper button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 1.4rem;
  height: 1.4rem;
  border-radius: 999px;
  background: rgba(245, 239, 226, 0.15);
  color: var(--cream);
  font-family: "Space Grotesk", sans-serif;
  font-weight: 700;
  line-height: 1;
  transition: background-color 140ms ease;
}

.qty-stepper button:hover {
  background: rgba(245, 239, 226, 0.3);
}

.qty-stepper span {
  min-width: 1rem;
  text-align: center;
  font-family: "Space Grotesk", sans-serif;
  font-weight: 700;
  font-size: 0.85rem;
  color: var(--cream);
}

/* ---------- Hero slider ---------- */

.hero-slider {
  aspect-ratio: 4 / 5;
  background: var(--cream-soft);
}

.hero-slider__slide {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: top center;
  opacity: 0;
  transition: opacity 700ms cubic-bezier(0.22, 1, 0.36, 1);
}

.hero-slider__slide.is-active {
  opacity: 1;
}

.hero-slider__dots {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0.9rem;
  z-index: 2;
  display: flex;
  justify-content: center;
  gap: 0.5rem;
}

.hero-slider__dots button {
  width: 0.5rem;
  height: 0.5rem;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.55);
  border: 1px solid rgba(28, 22, 13, 0.25);
  transition: background-color 200ms ease, width 200ms ease;
}

.hero-slider__dots button.is-active {
  width: 1.4rem;
  background: var(--gold);
  border-color: var(--gold-deep);
}

@media (prefers-reduced-motion: reduce) {
  .hero-slider__slide {
    transition: none;
  }
}

/* ---------- Reveal on scroll ---------- */

.reveal {
  opacity: 0;
  transform: translateY(14px);
}

.reveal.is-visible {
  animation: reveal-in 620ms cubic-bezier(0.22, 1, 0.36, 1) forwards;
}

@keyframes reveal-in {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@media (prefers-reduced-motion: reduce) {
  .reveal {
    opacity: 1;
    transform: none;
    animation: none;
  }
}

/* ---------- Product detail page ---------- */

.pdp-media__frame {
  position: relative;
  aspect-ratio: 4 / 5;
  overflow: hidden;
  border-radius: 1.75rem;
  border: 1px solid var(--cream-line);
  background: var(--cream-soft);
  box-shadow: 0 20px 40px -24px rgba(28, 22, 13, 0.35);
}

.pdp-media__img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: top center;
}

.pdp-media__save {
  position: absolute;
  top: 1rem;
  left: 1rem;
  background: var(--flag-red);
  color: #fff;
  font-family: "Space Grotesk", sans-serif;
  font-weight: 700;
  font-size: 0.75rem;
  letter-spacing: 0.02em;
  padding: 0.4rem 0.7rem;
  border-radius: 999px;
  text-transform: uppercase;
}

@media (min-width: 1024px) {
  .pdp-media {
    position: sticky;
    top: 5.5rem;
  }
}

.pdp-tag {
  display: inline-flex;
  align-items: center;
  font-family: "Space Grotesk", sans-serif;
  font-weight: 600;
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--gold-deep);
  background: rgba(181, 129, 58, 0.12);
  padding: 0.35rem 0.75rem;
  border-radius: 999px;
}

.pdp-price-old {
  font-family: "Space Grotesk", sans-serif;
  font-size: 1.05rem;
  color: #a3937a;
  text-decoration: line-through;
}

.pdp-price-now {
  font-family: "Space Grotesk", sans-serif;
  font-weight: 700;
  font-size: 2rem;
  color: var(--forest-deep);
}

.pdp-meta-grid {
  margin-top: 1.75rem;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(9rem, 1fr));
  gap: 1rem;
  padding: 1.1rem 1.25rem;
  border: 1px solid var(--cream-line);
  border-radius: 1.1rem;
  background: #fffdf8;
}

.pdp-meta-grid dt {
  font-family: "Space Grotesk", sans-serif;
  font-size: 0.68rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: #8a7a5c;
}

.pdp-meta-grid dd {
  margin-top: 0.2rem;
  font-size: 0.92rem;
  color: var(--ink);
  font-weight: 500;
}

.pdp-benefits {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
  font-size: 0.94rem;
  color: #4a4030;
}

.pdp-benefits li {
  padding-left: 1.35rem;
  position: relative;
  line-height: 1.45;
}

.pdp-benefits li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.5em;
  width: 0.5rem;
  height: 0.5rem;
  background: var(--gold);
  border-radius: 999px;
}

.pdp-actions {
  margin-top: 2rem;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 1rem;
  padding-top: 1.5rem;
  border-top: 1px dashed var(--cream-line);
}

.pdp-whatsapp-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  background: var(--forest);
  color: var(--cream);
  font-family: "Space Grotesk", sans-serif;
  font-weight: 600;
  font-size: 0.92rem;
  padding: 0.85rem 1.4rem;
  border-radius: 999px;
  box-shadow: 0 10px 20px -10px rgba(24, 40, 19, 0.5);
  transition: background-color 160ms ease, transform 160ms ease;
}

.pdp-whatsapp-btn:hover {
  background: var(--forest-deep);
  transform: translateY(-1px);
}

.pdp-back-link {
  margin-top: 1.75rem;
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-family: "Space Grotesk", sans-serif;
  font-weight: 600;
  font-size: 0.85rem;
  color: var(--forest-deep);
  transition: gap 160ms ease, color 160ms ease;
}

.pdp-back-link:hover {
  color: var(--gold-deep);
  gap: 0.6rem;
}
