/* =============================================================
   MAYAMÍA JEWELRY — styles.css
   Archetype: Editorial Light Cream · boho · artesanal
   ============================================================= */

/* =============================================================
   1. Tokens
   ============================================================= */
:root {
  /* Paleta de marca */
  --bg:        #F1E7DB;   /* crema — fondo principal */
  --bg-2:      #EBBEAC;   /* rosa pálido — secciones de acento */
  --bg-sand:   #E7DACA;   /* arena, intermedio */
  --paper:     #FBF6EF;   /* crema clara — tarjetas */
  --accent:    #C45737;   /* terracota — CTAs, acentos */
  --accent-dk: #A8462B;   /* terracota oscuro — hover */
  --olive:     #687434;   /* verde oliva — complemento natural */
  --olive-dk:  #535D29;

  /* Tinta (texto). El #DFC9C2 del brief se usa como línea/divisor;
     para el texto se usa un marrón cálido legible. */
  --ink:       #3C2A20;   /* texto principal */
  --ink-soft:  #5A4536;   /* texto secundario */
  --ink-mute:  #8A7361;   /* metadatos */
  --line:      #DFC9C2;   /* marrón pálido — divisores */
  --line-soft: rgba(60, 42, 32, 0.10);

  /* Tipografía */
  --script: "Parisienne", "Brush Script MT", cursive;
  --serif:  "Cormorant Garamond", "Della Respira", Georgia, serif;
  --sans:   "Montserrat", system-ui, -apple-system, sans-serif;

  /* Escala */
  --gutter: clamp(1.25rem, 5vw, 5rem);
  --maxw: 1280px;
  --radius: 4px;
  --radius-lg: 14px;

  /* Easings */
  --ease-out:    cubic-bezier(0.16, 1, 0.3, 1);
  --ease-in:     cubic-bezier(0.7, 0, 0.84, 0);
  --ease-soft:   cubic-bezier(0.25, 0.46, 0.45, 0.94);
  --ease-bounce: cubic-bezier(0.34, 1.56, 0.64, 1);

  /* Sombra cálida */
  --shadow:    0 18px 50px -28px rgba(60, 42, 32, 0.45);
  --shadow-lg: 0 40px 90px -40px rgba(60, 42, 32, 0.55);
  --halo:      rgba(196, 87, 55, 0.22);
}

/* =============================================================
   2. Reset & base
   ============================================================= */
*, *::before, *::after { box-sizing: border-box; margin: 0; }
html {
  -webkit-text-size-adjust: 100%;
  tab-size: 2;
  overflow-x: clip;
  scroll-behavior: smooth;
}
body {
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.65;
  color: var(--ink);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: clip;
  overscroll-behavior-y: none;
}
img, svg, video { display: block; max-width: 100%; }
img { height: auto; }
button { font: inherit; color: inherit; cursor: pointer; border: 0; background: none; }
a { color: inherit; text-decoration: none; }
p { text-wrap: pretty; }
ul { list-style: none; }
input, textarea, select { font: inherit; color: inherit; }

::selection { background: var(--accent); color: var(--paper); }

:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
  border-radius: 4px;
}

@view-transition { navigation: auto; }
::view-transition-old(root) { animation: vtOut .5s var(--ease-out) both; }
::view-transition-new(root) { animation: vtIn .5s var(--ease-out) both; }
@keyframes vtOut { to { opacity: 0; transform: translateY(-10px); } }
@keyframes vtIn { from { opacity: 0; transform: translateY(12px); } }

/* =============================================================
   3. Utilities
   ============================================================= */
.container { width: 100%; max-width: var(--maxw); margin-inline: auto; padding-inline: var(--gutter); }
.sr-only {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0;
}
.skip-link {
  position: fixed; top: -100px; left: 1rem;
  padding: .6rem 1rem; background: var(--ink); color: var(--paper);
  z-index: 9999; border-radius: 8px; font-weight: 500; font-family: var(--sans);
}
.skip-link:focus { top: 1rem; }

.kicker {
  font-family: var(--sans);
  font-size: .72rem;
  font-weight: 600;
  letter-spacing: .34em;
  text-transform: uppercase;
  color: var(--accent);
}
.eyebrow-script {
  font-family: var(--script);
  font-size: clamp(1.6rem, 3.4vw, 2.4rem);
  color: var(--accent);
  line-height: 1;
}

/* Grano sutil sobre todo */
.grain {
  position: fixed; inset: 0; z-index: 4; pointer-events: none;
  opacity: .35; mix-blend-mode: multiply;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='0.06'/%3E%3C/svg%3E");
}

/* =============================================================
   4. Tipografía
   ============================================================= */
h1, h2, h3, h4 {
  font-family: var(--serif);
  font-weight: 500;
  line-height: 1.04;
  letter-spacing: -0.01em;
  color: var(--ink);
  text-wrap: balance;
}
.display {
  font-size: clamp(2.6rem, 8vw, 6.2rem);
  font-weight: 500;
  line-height: .98;
}
.display em, .section-title em { font-style: italic; color: var(--accent); }
.section-title {
  font-size: clamp(2rem, 5vw, 3.6rem);
  font-weight: 500;
}
.lead {
  font-family: var(--serif);
  font-size: clamp(1.2rem, 2.2vw, 1.5rem);
  font-style: italic;
  color: var(--ink-soft);
  line-height: 1.5;
  max-width: 40ch;
}

/* =============================================================
   5. Componentes
   ============================================================= */
.btn {
  display: inline-flex; align-items: center; gap: .6em;
  font-family: var(--sans); font-size: .8rem; font-weight: 600;
  letter-spacing: .14em; text-transform: uppercase;
  padding: 1.05em 2em; border-radius: 100px;
  transition: transform .4s var(--ease-out), background .35s var(--ease-out), color .35s var(--ease-out), box-shadow .4s var(--ease-out);
  will-change: transform;
}
.btn svg { width: 1.05em; height: 1.05em; }
.btn-primary { background: var(--accent); color: var(--paper); box-shadow: 0 14px 30px -16px var(--halo); }
.btn-primary:hover { background: var(--accent-dk); transform: translateY(-2px); box-shadow: 0 22px 44px -18px var(--halo); }
.btn-ghost { border: 1px solid var(--ink); color: var(--ink); }
.btn-ghost:hover { background: var(--ink); color: var(--paper); transform: translateY(-2px); }
.btn-olive { background: var(--olive); color: var(--paper); }
.btn-olive:hover { background: var(--olive-dk); transform: translateY(-2px); }
.btn-block { width: 100%; justify-content: center; }

.link-underline {
  position: relative; display: inline-block;
  font-family: var(--sans); font-size: .78rem; font-weight: 600;
  letter-spacing: .14em; text-transform: uppercase; color: var(--ink);
}
.link-underline::after {
  content: ""; position: absolute; left: 0; bottom: -4px;
  width: 100%; height: 1px; background: var(--accent);
  transform: scaleX(0); transform-origin: right; transition: transform .45s var(--ease-out);
}
.link-underline:hover { color: var(--accent); }
.link-underline:hover::after { transform: scaleX(1); transform-origin: left; }

.badge {
  display: inline-flex; align-items: center; gap: .4em;
  font-family: var(--sans); font-size: .62rem; font-weight: 600;
  letter-spacing: .16em; text-transform: uppercase;
  padding: .4em .85em; border-radius: 100px;
}
.badge-hand { background: rgba(104,116,52,.14); color: var(--olive-dk); }
.badge-status { border: 1px solid var(--line); color: var(--ink-mute); background: var(--paper); }
.badge-status[data-status="disponible"] { color: var(--olive-dk); border-color: rgba(104,116,52,.4); }
.badge-status[data-status="ultima"] { color: var(--accent); border-color: rgba(196,87,55,.4); }
.badge-status[data-status="agotado"] { color: var(--ink-mute); }

/* =============================================================
   6. Cursor personalizado (sutil, gated por puntero fino)
   ============================================================= */
.cursor { position: fixed; top: 0; left: 0; z-index: 9000; pointer-events: none; opacity: 0; transition: opacity .3s var(--ease-out); mix-blend-mode: multiply; }
.cursor.is-ready { opacity: 1; }
.cursor-spark { width: 20px; height: 20px; display: block; fill: var(--accent); transform: translate(-50%, -50%); transition: width .25s var(--ease-out), height .25s var(--ease-out); }
.cursor.is-hover .cursor-spark { width: 30px; height: 30px; }
.cursor-ring { position: fixed; top: 0; left: 0; z-index: 9000; pointer-events: none; mix-blend-mode: multiply; width: 34px; height: 34px; border: 1px solid var(--accent); border-radius: 50%; transform: translate(-50%, -50%); opacity: 0; transition: width .3s var(--ease-out), height .3s var(--ease-out), opacity .3s; }
.cursor-ring.is-ready { opacity: 1; }
.cursor-ring.is-hover { width: 54px; height: 54px; opacity: .6; }
@media (hover: none), (pointer: coarse) { .cursor { display: none; } }

/* =============================================================
   7. Splash
   ============================================================= */
.splash {
  position: fixed; inset: 0; z-index: 9500;
  display: grid; place-items: center;
  background: var(--bg);
  animation: splashSafety .01s 4.5s forwards;
}
.splash.is-out { opacity: 0; pointer-events: none; transform: translateY(-8px); transition: opacity .9s var(--ease-out), transform .9s var(--ease-out); }
.splash-inner { display: flex; flex-direction: column; align-items: center; text-align: center; }
.brand-mark.splash-mark { width: clamp(78px, 20vw, 116px); height: clamp(78px, 20vw, 116px); color: var(--accent); opacity: 0; animation: splashIn 1.1s .05s var(--ease-out) forwards; }
.splash-logo { font-family: var(--serif); font-weight: 500; font-size: clamp(2.6rem, 9vw, 4.4rem); color: var(--ink); line-height: 1; margin-top: .6rem; opacity: 0; animation: splashIn 1.1s .25s var(--ease-out) forwards; }
.splash-sub { font-family: var(--sans); font-size: .68rem; letter-spacing: .38em; text-transform: uppercase; color: var(--ink-mute); margin-top: .6rem; text-align: center; opacity: 0; animation: splashIn 1.1s .5s var(--ease-out) forwards; }
@keyframes splashIn { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }
@keyframes splashSafety { to { opacity: 0; pointer-events: none; visibility: hidden; } }

/* =============================================================
   8. Nav
   ============================================================= */
.nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 1000;
  display: flex; align-items: center; justify-content: space-between;
  padding: 1.4rem var(--gutter);
  transition: background .4s var(--ease-out), padding .4s var(--ease-out), box-shadow .4s var(--ease-out), border-color .4s;
  border-bottom: 1px solid transparent;
}
.nav.is-scrolled {
  background: rgba(241, 231, 219, 0.85);
  backdrop-filter: blur(12px) saturate(140%);
  -webkit-backdrop-filter: blur(12px) saturate(140%);
  padding-block: .9rem;
  border-bottom: 1px solid var(--line-soft);
}
.nav-logo { display: inline-flex; align-items: center; gap: .5rem; line-height: 1; }
.brand-mark { display: inline-block; width: 34px; height: 34px; flex-shrink: 0; line-height: 0; }
.brand-mark svg, .brand-mark img { width: 100%; height: 100%; display: block; object-fit: contain; }
.nav-logo .brand-mark { transition: width .4s var(--ease-out), height .4s var(--ease-out); }
.footer-logo .brand-mark img { filter: brightness(0) invert(1); }
.nav.is-scrolled .nav-logo .brand-mark { width: 29px; height: 29px; }
.nav-logo .nav-wordmark { width: clamp(140px, 34vw, 170px); height: auto; }
.nav.is-scrolled .nav-logo .nav-wordmark { width: clamp(124px, 30vw, 150px); height: auto; }
.nav-logo-word { font-family: var(--serif); font-size: 1.65rem; font-weight: 500; color: var(--ink); letter-spacing: .01em; }
.nav-links { display: none; align-items: center; gap: 2.2rem; }
.nav-link {
  font-family: var(--sans); font-size: .74rem; font-weight: 500;
  letter-spacing: .16em; text-transform: uppercase; color: var(--ink-soft);
  position: relative; transition: color .3s var(--ease-out);
}
.nav-link::after { content: ""; position: absolute; left: 0; bottom: -6px; width: 100%; height: 1px; background: var(--accent); transform: scaleX(0); transform-origin: right; transition: transform .4s var(--ease-out); }
.nav-link:hover { color: var(--accent); }
.nav-link:hover::after { transform: scaleX(1); transform-origin: left; }
.nav-right { display: flex; align-items: center; gap: 1rem; }

.cart-btn { position: relative; display: inline-flex; align-items: center; justify-content: center; width: 44px; height: 44px; border-radius: 50%; transition: background .3s var(--ease-out); }
.cart-btn:hover { background: rgba(60,42,32,.07); }
.cart-btn svg { width: 22px; height: 22px; stroke: var(--ink); }
.cart-count {
  position: absolute; top: 2px; right: 0; min-width: 18px; height: 18px;
  display: grid; place-items: center; padding: 0 4px;
  background: var(--accent); color: var(--paper);
  font-family: var(--sans); font-size: .62rem; font-weight: 700; border-radius: 100px;
  transform: scale(0); transition: transform .35s var(--ease-bounce);
}
.cart-count.is-visible { transform: scale(1); }

.nav-toggle { display: inline-flex; flex-direction: column; gap: 5px; width: 44px; height: 44px; align-items: center; justify-content: center; }
.nav-toggle span { width: 22px; height: 1.5px; background: var(--ink); transition: transform .35s var(--ease-out), opacity .35s; }
.nav-toggle.is-open span:nth-child(1) { transform: translateY(6.5px) rotate(45deg); }
.nav-toggle.is-open span:nth-child(2) { opacity: 0; }
.nav-toggle.is-open span:nth-child(3) { transform: translateY(-6.5px) rotate(-45deg); }

/* Menú móvil */
.mobile-menu {
  position: fixed; inset: 0; z-index: 999;
  background: var(--bg);
  display: flex; flex-direction: column; justify-content: center; gap: 1.5rem;
  padding: var(--gutter);
  transform: translateY(-100%); transition: transform .55s var(--ease-out);
}
.mobile-menu.is-open { transform: translateY(0); }
.mobile-menu a { font-family: var(--serif); font-size: 2.2rem; color: var(--ink); transition: color .3s; }
.mobile-menu a:hover { color: var(--accent); font-style: italic; }
.mobile-menu .mm-meta { margin-top: 2rem; font-family: var(--sans); font-size: .8rem; letter-spacing: .1em; color: var(--ink-mute); }

/* =============================================================
   9. Hero
   ============================================================= */
.hero {
  position: relative; min-height: 100svh;
  display: grid; align-items: start;
  padding-top: 6.5rem; padding-bottom: 4rem;
  overflow: hidden;
}
.hero-grid { display: grid; gap: 2.5rem; align-items: center; }
.hero-eyebrow { margin-bottom: 1.2rem; }
.hero-title { margin-bottom: 1.6rem; }
.hero-sub { margin-bottom: 2.4rem; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 1rem; }
.hero-meta { margin-top: 2.6rem; display: flex; flex-wrap: wrap; gap: 1.6rem; color: var(--ink-mute); font-family: var(--sans); font-size: .76rem; letter-spacing: .08em; }
.hero-meta span { display: inline-flex; align-items: center; gap: .5em; }
.hero-meta .dot { width: 6px; height: 6px; border-radius: 50%; background: var(--olive); }

/* Visual del hero (composición de marca, sin foto stock) */
.hero-visual { position: relative; aspect-ratio: 4/5; }
.hero-frame {
  position: absolute; inset: 0; border-radius: 200px 200px 18px 18px;
  background: linear-gradient(160deg, var(--bg-2), var(--bg-sand));
  overflow: hidden; box-shadow: var(--shadow-lg);
}
.hero-frame::after {
  content: ""; position: absolute; inset: 0;
  background: radial-gradient(60% 45% at 50% 30%, rgba(251,246,239,.55), transparent 70%);
}
.hero-frame .ph-motif { position: absolute; inset: 0; margin: auto; width: 58%; opacity: .85; }
.hero-frame .ph-motif path, .hero-frame .ph-motif circle, .hero-frame .ph-motif line { stroke: var(--accent); }
.hero-mark { position: absolute; bottom: 1.4rem; left: 0; right: 0; text-align: center; font-family: var(--script); font-size: 2.2rem; color: var(--accent); opacity: .9; }
.hero-leaf { position: absolute; z-index: 2; opacity: .5; }
.hero-leaf svg { stroke: var(--olive); }
.hero-leaf.l1 { top: -1.5rem; right: 8%; width: 90px; transform: rotate(12deg); }
.hero-leaf.l2 { bottom: 6%; left: -1.2rem; width: 70px; transform: rotate(-20deg); }
.hero-note {
  position: absolute; top: 8%; left: -1rem; z-index: 3;
  background: var(--paper); padding: .7rem 1rem; border-radius: 12px;
  box-shadow: var(--shadow); font-family: var(--sans); font-size: .66rem;
  letter-spacing: .14em; text-transform: uppercase; color: var(--olive-dk);
  display: inline-flex; align-items: center; gap: .5em;
}

/* =============================================================
   10. Marquee
   ============================================================= */
.marquee { overflow: hidden; border-block: 1px solid var(--line); padding-block: 1.1rem; background: var(--bg-sand); }
.marquee-track { display: flex; gap: 3rem; white-space: nowrap; width: max-content; animation: marquee 38s linear infinite; }
.marquee:hover .marquee-track { animation-play-state: paused; }
.marquee span { font-family: var(--serif); font-style: italic; font-size: clamp(1.1rem, 2.4vw, 1.7rem); color: var(--ink-soft); display: inline-flex; align-items: center; gap: 3rem; }
.marquee span::after { content: "✦"; color: var(--accent); font-style: normal; font-size: .7em; }
@keyframes marquee { to { transform: translateX(-50%); } }

/* =============================================================
   11. Secciones genéricas
   ============================================================= */
.section { padding-block: clamp(4.5rem, 10vw, 8rem); position: relative; }
.section-pink { background: var(--bg-2); }
.section-sand { background: var(--bg-sand); }
.section-head { max-width: 60ch; margin-bottom: clamp(2.5rem, 5vw, 4rem); }
.section-head.center { margin-inline: auto; text-align: center; }
.section-head .kicker { display: block; margin-bottom: 1rem; }
.section-head p { margin-top: 1.2rem; color: var(--ink-soft); max-width: 52ch; }
.section-head.center p { margin-inline: auto; }

/* =============================================================
   12. Cards de categoría
   ============================================================= */
.cat-grid { display: grid; gap: 1.5rem; grid-template-columns: 1fr; }
.cat-card {
  position: relative; display: block; overflow: hidden;
  border-radius: var(--radius-lg); min-height: 320px;
  padding: 2rem; color: var(--ink);
  background: linear-gradient(165deg, var(--bg-sand), var(--bg-2));
  box-shadow: var(--shadow); transition: transform .5s var(--ease-out), box-shadow .5s var(--ease-out);
  display: flex; flex-direction: column; justify-content: space-between;
}
.cat-card:hover { transform: translateY(-6px); box-shadow: var(--shadow-lg); }
.cat-card .cat-motif { position: absolute; right: -10%; bottom: -8%; width: 65%; opacity: .5; transition: transform .6s var(--ease-out), opacity .5s; }
.cat-card .cat-motif path, .cat-card .cat-motif circle, .cat-card .cat-motif line { stroke: var(--accent); }
.cat-card:hover .cat-motif { transform: scale(1.08) rotate(-4deg); opacity: .7; }
.cat-card:nth-child(2) { background: linear-gradient(165deg, var(--bg-2), #E3B7A2); }
.cat-card:nth-child(3) { background: linear-gradient(165deg, #DBD7C0, var(--bg-sand)); }
.cat-card .cat-num { font-family: var(--sans); font-size: .7rem; letter-spacing: .2em; color: var(--ink-mute); }
.cat-card h3 { font-size: 2.2rem; position: relative; z-index: 1; }
.cat-card .cat-foot { display: inline-flex; align-items: center; gap: .6em; position: relative; z-index: 1; font-family: var(--sans); font-size: .76rem; font-weight: 600; letter-spacing: .12em; text-transform: uppercase; color: var(--accent); }
.cat-card .cat-foot svg { width: 16px; transition: transform .4s var(--ease-out); }
.cat-card:hover .cat-foot svg { transform: translateX(5px); }

/* =============================================================
   13. Producto (tarjeta)
   ============================================================= */
.product-grid { display: grid; gap: 1.6rem 1.4rem; grid-template-columns: repeat(2, 1fr); }
.product {
  position: relative; display: flex; flex-direction: column;
  background: var(--paper); border-radius: var(--radius-lg); overflow: hidden;
  box-shadow: 0 12px 34px -26px rgba(60,42,32,.4);
  transition: transform .5s var(--ease-out), box-shadow .5s var(--ease-out);
}
.product:hover { box-shadow: var(--shadow-lg); }
.product-media { position: relative; aspect-ratio: 4/5; overflow: hidden; }
.product-media img { width: 100%; height: 100%; object-fit: cover; transition: transform .8s var(--ease-out); }
.product:hover .product-media img { transform: scale(1.06); }
.product-tags { position: absolute; top: .7rem; left: .7rem; right: .7rem; display: flex; justify-content: space-between; gap: .4rem; z-index: 2; }
.product-fav { width: 34px; height: 34px; border-radius: 50%; background: rgba(251,246,239,.85); display: grid; place-items: center; backdrop-filter: blur(4px); transition: background .3s, transform .3s var(--ease-out); }
.product-fav:hover { transform: scale(1.1); }
.product-fav svg { width: 17px; stroke: var(--accent); fill: none; transition: fill .3s; }
.product-fav.is-fav svg { fill: var(--accent); }
.product-body { padding: 1.1rem 1.1rem 1.3rem; display: flex; flex-direction: column; gap: .5rem; flex: 1; }
.product-name { font-family: var(--serif); font-size: 1.35rem; line-height: 1.1; }
.product-insp { font-family: var(--serif); font-style: italic; font-size: .92rem; color: var(--ink-mute); line-height: 1.4; }
.product-meta { font-family: var(--sans); font-size: .68rem; letter-spacing: .06em; color: var(--ink-mute); text-transform: uppercase; }
.product-foot { margin-top: auto; padding-top: .8rem; display: flex; align-items: center; justify-content: space-between; gap: .6rem; }
.product-price { font-family: var(--serif); font-size: 1.3rem; color: var(--ink); }
.product-price small { font-family: var(--sans); font-size: .62rem; letter-spacing: .08em; color: var(--ink-mute); display: block; text-transform: none; }
.product-add {
  display: inline-flex; align-items: center; gap: .45em;
  background: var(--accent); color: var(--paper);
  font-family: var(--sans); font-size: .68rem; font-weight: 600; letter-spacing: .1em; text-transform: uppercase;
  padding: .7em 1.1em; border-radius: 100px;
  transition: background .3s var(--ease-out), transform .3s var(--ease-out);
}
.product-add svg { width: 15px; }
.product-add:hover { background: var(--accent-dk); transform: translateY(-2px); }
.product.is-sold { }
.product.is-sold .product-media img { filter: grayscale(.5) saturate(.7); opacity: .85; }
.product-add[disabled] { background: var(--line); color: var(--ink-mute); cursor: not-allowed; pointer-events: none; }

/* Placeholder de diseño (cuando no hay foto) */
.ph { position: absolute; inset: 0; display: grid; place-items: center; overflow: hidden; }
.ph::after { content: ""; position: absolute; inset: 0; background: radial-gradient(55% 40% at 50% 32%, rgba(251,246,239,.5), transparent 72%); }
.ph[data-tone="1"] { background: linear-gradient(155deg, #EBBEAC, #DFC9C2); }
.ph[data-tone="2"] { background: linear-gradient(155deg, #F4ECE0, #E7D8C7); }
.ph[data-tone="3"] { background: linear-gradient(155deg, #EFC7B8, #E3B7A2); }
.ph[data-tone="4"] { background: linear-gradient(155deg, #DBD7C0, #C9C7A4); }
.ph[data-tone="5"] { background: linear-gradient(155deg, #E0C2AE, #CBA78F); }
.ph-motif { width: 52%; max-width: 180px; position: relative; z-index: 1; transition: transform .8s var(--ease-out); }
.ph-motif path, .ph-motif circle, .ph-motif line, .ph-motif ellipse { fill: none; stroke: var(--accent); stroke-width: 1.4; vector-effect: non-scaling-stroke; opacity: .9; }
.product:hover .ph-motif { transform: scale(1.05) translateY(-4px); }
.ph-mark { position: absolute; bottom: .8rem; z-index: 1; font-family: var(--script); font-size: 1.3rem; color: var(--accent); opacity: .8; }

/* =============================================================
   14. Proceso / Galería
   ============================================================= */
.process-grid { display: grid; gap: 1.4rem; grid-template-columns: 1fr; counter-reset: step; }
.process-card {
  position: relative; padding: 2rem 1.8rem; border-radius: var(--radius-lg);
  background: var(--paper); box-shadow: var(--shadow); overflow: hidden;
}
.process-card::before {
  counter-increment: step; content: "0" counter(step);
  font-family: var(--serif); font-size: 3.4rem; color: var(--bg-2);
  position: absolute; top: .6rem; right: 1.2rem; line-height: 1;
}
.process-card h3 { font-size: 1.6rem; margin-bottom: .6rem; position: relative; z-index: 1; }
.process-card p { color: var(--ink-soft); position: relative; z-index: 1; }

.reel-grid { display: grid; gap: 1rem; grid-template-columns: repeat(2, 1fr); margin-top: 2.5rem; }
.reel {
  position: relative; aspect-ratio: 9/14; border-radius: var(--radius-lg); overflow: hidden;
  background: linear-gradient(165deg, var(--bg-2), var(--bg-sand));
  display: grid; place-items: center; box-shadow: var(--shadow);
  transition: transform .5s var(--ease-out);
}
.reel:hover { transform: translateY(-5px) scale(1.01); }
.reel .reel-play { width: 56px; height: 56px; border-radius: 50%; background: rgba(251,246,239,.9); display: grid; place-items: center; position: relative; z-index: 1; }
.reel .reel-play svg { width: 22px; fill: var(--accent); margin-left: 3px; }
.reel .reel-cap { position: absolute; bottom: 1rem; left: 1rem; right: 1rem; z-index: 1; font-family: var(--script); font-size: 1.5rem; color: var(--accent); }
.reel-grid--big { grid-template-columns: repeat(2, 1fr); }
/* Embeds reales de Instagram (cuando hay reels en lib/manifest.js) */
.reel-grid.has-embeds { grid-template-columns: 1fr; gap: 1.4rem; align-items: start; }
.reel-grid.has-embeds .instagram-media { width: 100% !important; min-width: 0 !important; max-width: 100% !important; margin: 0 !important; border-radius: var(--radius-lg) !important; box-shadow: var(--shadow) !important; }

/* =============================================================
   15. Sobre
   ============================================================= */
.about { display: grid; gap: 2.5rem; align-items: center; }
.about-visual { position: relative; aspect-ratio: 4/5; border-radius: 18px 200px 18px 18px; overflow: hidden; background: linear-gradient(160deg, var(--bg-sand), var(--bg-2)); box-shadow: var(--shadow-lg); display: grid; place-items: center; }
.about-visual .ph-motif { width: 50%; }
.about-visual .ph-mark { font-size: 2rem; }
.about-text .signature { font-family: var(--script); font-size: 2.4rem; color: var(--accent); margin-top: 1.5rem; }
.about-text p + p { margin-top: 1.1rem; }
.about-text p { color: var(--ink-soft); font-size: 1.05rem; }
.about-text .lead { color: var(--ink); margin-bottom: 1.5rem; }
.pillars { display: grid; gap: 1.2rem; margin-top: 2.5rem; grid-template-columns: 1fr; }
.pillar { border-top: 1px solid var(--line); padding-top: 1rem; }
.pillar h4 { font-family: var(--serif); font-size: 1.5rem; color: var(--accent); margin-bottom: .3rem; }
.pillar p { font-family: var(--sans); font-size: .9rem; color: var(--ink-soft); }

/* =============================================================
   16. Contacto
   ============================================================= */
.contact-grid { display: grid; gap: 2.5rem; }
.contact-methods { display: flex; flex-direction: column; gap: 1rem; margin-top: 2rem; }
.contact-method {
  display: flex; align-items: center; gap: 1rem; padding: 1.1rem 1.3rem;
  background: var(--paper); border-radius: var(--radius-lg); box-shadow: var(--shadow);
  transition: transform .4s var(--ease-out);
}
.contact-method:hover { transform: translateX(5px); }
.contact-method .cm-icon { width: 44px; height: 44px; border-radius: 50%; background: var(--bg-2); display: grid; place-items: center; flex-shrink: 0; }
.contact-method .cm-icon svg { width: 22px; stroke: var(--accent); }
.contact-method .cm-label { font-family: var(--sans); font-size: .66rem; letter-spacing: .18em; text-transform: uppercase; color: var(--ink-mute); }
.contact-method .cm-value { font-family: var(--serif); font-size: 1.2rem; color: var(--ink); }

.form { display: grid; gap: 1.1rem; background: var(--paper); padding: clamp(1.6rem, 4vw, 2.6rem); border-radius: var(--radius-lg); box-shadow: var(--shadow); }
.form-row { display: grid; gap: 1.1rem; }
.field { display: flex; flex-direction: column; gap: .4rem; }
.field label { font-family: var(--sans); font-size: .68rem; letter-spacing: .14em; text-transform: uppercase; color: var(--ink-mute); }
.field input, .field textarea {
  background: var(--bg); border: 1px solid var(--line); border-radius: 10px;
  padding: .85rem 1rem; transition: border-color .3s, box-shadow .3s; color: var(--ink);
}
.field input:focus, .field textarea:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px rgba(196,87,55,.12); }
.field textarea { resize: vertical; min-height: 120px; }
.form-note { font-family: var(--sans); font-size: .76rem; color: var(--ink-mute); }
.form-success { display: none; align-items: center; gap: .6em; color: var(--olive-dk); font-weight: 600; font-size: .9rem; }
.form-success svg { width: 20px; stroke: var(--olive-dk); }
.form.is-sent .form-success { display: flex; }

/* =============================================================
   17. Footer
   ============================================================= */
.footer { background: var(--ink); color: var(--bg); padding-block: clamp(3.5rem, 7vw, 5.5rem) 2rem; }
.footer a { color: var(--bg); }
.footer-grid { display: grid; gap: 2.5rem; grid-template-columns: 1fr; }
.footer-logo { display: inline-flex; align-items: center; gap: .65rem; }
.footer-logo .brand-mark { width: 42px; height: 42px; color: var(--bg-2); }
.footer-logo .footer-wordmark { width: clamp(170px, 44vw, 215px); height: auto; }
.footer-logo-word { display: flex; flex-direction: column; line-height: 1; font-family: var(--serif); font-weight: 500; font-size: 2rem; color: var(--bg); }
.footer-logo-word small { font-family: var(--sans); font-size: .55rem; letter-spacing: .42em; text-transform: uppercase; color: var(--bg-2); margin-top: .25rem; }
.footer-tag { font-family: var(--serif); font-style: italic; color: rgba(241,231,219,.7); margin-top: .6rem; max-width: 30ch; }
.footer-col h4 { font-family: var(--sans); font-size: .7rem; letter-spacing: .2em; text-transform: uppercase; color: var(--bg-2); margin-bottom: 1.1rem; }
.footer-col ul { display: flex; flex-direction: column; gap: .7rem; }
.footer-col a { font-size: .92rem; color: rgba(241,231,219,.78); transition: color .3s; }
.footer-col a:hover { color: var(--bg-2); }
.footer-social { display: flex; gap: .8rem; margin-top: 1rem; }
.footer-social a { width: 40px; height: 40px; border-radius: 50%; border: 1px solid rgba(241,231,219,.25); display: grid; place-items: center; transition: background .3s, border-color .3s; }
.footer-social a:hover { background: var(--accent); border-color: var(--accent); }
.footer-social svg { width: 18px; stroke: var(--bg); }
.footer-bottom { margin-top: 3rem; padding-top: 1.5rem; border-top: 1px solid rgba(241,231,219,.15); display: flex; flex-wrap: wrap; gap: .6rem 1.5rem; justify-content: space-between; font-family: var(--sans); font-size: .72rem; color: rgba(241,231,219,.6); }

/* =============================================================
   18. WhatsApp flotante
   ============================================================= */
.wa-float {
  position: fixed; bottom: 1.4rem; right: 1.4rem; z-index: 900;
  display: inline-flex; align-items: center; gap: .7em;
  background: #25D366; color: #fff; padding: .9em 1.2em; border-radius: 100px;
  box-shadow: 0 16px 36px -14px rgba(37,211,102,.6);
  font-family: var(--sans); font-size: .8rem; font-weight: 600;
  transition: transform .4s var(--ease-out), box-shadow .4s;
  animation: waPulse 3.5s ease-in-out infinite;
}
.wa-float:hover { transform: translateY(-3px) scale(1.03); }
.wa-float svg { width: 22px; fill: #fff; }
.wa-float .wa-label { display: none; }
@keyframes waPulse { 0%, 100% { box-shadow: 0 16px 36px -14px rgba(37,211,102,.55); } 50% { box-shadow: 0 16px 50px -10px rgba(37,211,102,.85); } }

/* =============================================================
   19. Carrito (drawer)
   ============================================================= */
.cart-overlay { position: fixed; inset: 0; z-index: 1100; background: rgba(60,42,32,.45); opacity: 0; visibility: hidden; transition: opacity .4s var(--ease-out), visibility .4s; backdrop-filter: blur(2px); }
.cart-overlay.is-open { opacity: 1; visibility: visible; }
.cart-drawer {
  position: fixed; top: 0; right: 0; bottom: 0; z-index: 1200;
  width: min(420px, 92vw); background: var(--bg);
  display: flex; flex-direction: column;
  transform: translateX(100%); transition: transform .5s var(--ease-out);
  box-shadow: -30px 0 80px -30px rgba(60,42,32,.5);
}
.cart-drawer.is-open { transform: translateX(0); }
.cart-header { display: flex; align-items: center; justify-content: space-between; padding: 1.5rem; border-bottom: 1px solid var(--line); }
.cart-header h3 { font-size: 1.6rem; }
.cart-close { width: 40px; height: 40px; border-radius: 50%; display: grid; place-items: center; transition: background .3s; }
.cart-close:hover { background: rgba(60,42,32,.07); }
.cart-close svg { width: 20px; stroke: var(--ink); }
.cart-items { flex: 1; overflow-y: auto; padding: 1.2rem 1.5rem; display: flex; flex-direction: column; gap: 1rem; }
.cart-empty { margin: auto; text-align: center; color: var(--ink-mute); display: flex; flex-direction: column; gap: 1rem; align-items: center; padding: 2rem 0; }
.cart-empty svg { width: 54px; stroke: var(--line); }
.cart-empty .eyebrow-script { color: var(--ink-mute); }
.cart-item { display: grid; grid-template-columns: 64px 1fr auto; gap: .9rem; align-items: center; }
.cart-item-media { width: 64px; height: 80px; border-radius: 8px; overflow: hidden; position: relative; flex-shrink: 0; }
.cart-item-media img { width: 100%; height: 100%; object-fit: cover; }
.cart-item-media .ph-motif { width: 60%; }
.cart-item-name { font-family: var(--serif); font-size: 1.05rem; line-height: 1.1; }
.cart-item-meta { font-family: var(--sans); font-size: .68rem; color: var(--ink-mute); text-transform: uppercase; letter-spacing: .06em; }
.cart-item-price { font-family: var(--serif); font-size: 1rem; color: var(--accent); margin-top: .2rem; }
.cart-item-remove { font-family: var(--sans); font-size: .68rem; color: var(--ink-mute); text-decoration: underline; transition: color .3s; }
.cart-item-remove:hover { color: var(--accent); }
.cart-foot { padding: 1.3rem 1.5rem 1.6rem; border-top: 1px solid var(--line); background: var(--paper); }
.cart-total { display: flex; align-items: baseline; justify-content: space-between; margin-bottom: 1rem; }
.cart-total .ct-label { font-family: var(--sans); font-size: .72rem; letter-spacing: .16em; text-transform: uppercase; color: var(--ink-mute); }
.cart-total .ct-value { font-family: var(--serif); font-size: 1.8rem; color: var(--ink); }
.cart-note { font-family: var(--sans); font-size: .72rem; color: var(--ink-mute); margin-top: .9rem; text-align: center; line-height: 1.5; }

/* Toast */
.toast {
  position: fixed; bottom: 1.4rem; left: 50%; z-index: 1300;
  transform: translate(-50%, 130%); transition: transform .5s var(--ease-bounce);
  background: var(--ink); color: var(--bg); padding: .9rem 1.4rem; border-radius: 100px;
  font-family: var(--sans); font-size: .82rem; display: inline-flex; align-items: center; gap: .6em;
  box-shadow: var(--shadow-lg); max-width: 90vw;
}
.toast.is-visible { transform: translate(-50%, 0); }
.toast svg { width: 18px; stroke: var(--bg-2); }

/* =============================================================
   20. Filtros (página colección)
   ============================================================= */
.collection-hero { padding-top: 9rem; padding-bottom: 2rem; text-align: center; }
.filter-bar { position: sticky; top: 64px; z-index: 500; background: rgba(241,231,219,.9); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); padding-block: 1rem; border-bottom: 1px solid var(--line-soft); margin-bottom: 2.5rem; }
.filter-track { display: flex; gap: .6rem; overflow-x: auto; overflow-y: visible; padding-block: .2rem; scrollbar-width: none; }
.filter-track::-webkit-scrollbar { display: none; }
.filter-chip {
  flex-shrink: 0; font-family: var(--sans); font-size: .72rem; font-weight: 600;
  letter-spacing: .1em; text-transform: uppercase; color: var(--ink-soft);
  padding: .65em 1.2em; border-radius: 100px; border: 1px solid var(--line);
  background: var(--paper); transition: all .3s var(--ease-out); white-space: nowrap;
}
.filter-chip:hover { border-color: var(--accent); color: var(--accent); }
.filter-chip.is-active { background: var(--accent); color: var(--paper); border-color: var(--accent); }
.collection-count { text-align: center; font-family: var(--sans); font-size: .76rem; letter-spacing: .1em; color: var(--ink-mute); margin-bottom: 2rem; text-transform: uppercase; }

/* =============================================================
   21. Modal de producto
   ============================================================= */
.modal-overlay { position: fixed; inset: 0; z-index: 1400; background: rgba(60,42,32,.5); opacity: 0; visibility: hidden; transition: opacity .4s, visibility .4s; backdrop-filter: blur(3px); display: grid; place-items: center; padding: 1.2rem; }
.modal-overlay.is-open { opacity: 1; visibility: visible; }
.modal { background: var(--bg); border-radius: 18px; max-width: 880px; width: 100%; max-height: 90vh; overflow-y: auto; display: grid; grid-template-columns: 1fr; box-shadow: var(--shadow-lg); transform: translateY(20px); transition: transform .5s var(--ease-out); }
.modal-overlay.is-open .modal { transform: none; }
.modal-media { position: relative; aspect-ratio: 4/5; }
.modal-media img { width: 100%; height: 100%; object-fit: cover; }
.modal-body { padding: clamp(1.6rem, 4vw, 2.6rem); display: flex; flex-direction: column; gap: 1rem; }
.modal-close { position: absolute; top: 1rem; right: 1rem; z-index: 5; width: 40px; height: 40px; border-radius: 50%; background: rgba(251,246,239,.9); display: grid; place-items: center; box-shadow: var(--shadow); }
.modal-close svg { width: 20px; stroke: var(--ink); }
.modal-body h2 { font-size: 2.4rem; }
.modal-insp { font-family: var(--serif); font-style: italic; font-size: 1.2rem; color: var(--ink-soft); }
.modal-specs { display: grid; gap: .6rem; margin-top: .5rem; }
.modal-spec { display: flex; gap: .8rem; padding-bottom: .6rem; border-bottom: 1px solid var(--line); }
.modal-spec dt { font-family: var(--sans); font-size: .68rem; letter-spacing: .12em; text-transform: uppercase; color: var(--ink-mute); min-width: 110px; }
.modal-spec dd { font-family: var(--serif); font-size: 1.05rem; }
.modal-price { font-family: var(--serif); font-size: 2rem; }
.modal-price small { display: block; font-family: var(--sans); font-size: .7rem; letter-spacing: .06em; color: var(--ink-mute); }
.modal-actions { display: flex; flex-wrap: wrap; gap: .8rem; margin-top: .5rem; }

/* =============================================================
   22. Reveal
   ============================================================= */
.reveal { opacity: 0; transform: translateY(38px); transition: opacity 1s var(--ease-out), transform 1s var(--ease-out); }
.reveal.is-revealed { opacity: 1; transform: none; }
.reveal[data-delay="1"] { transition-delay: .08s; }
.reveal[data-delay="2"] { transition-delay: .16s; }
.reveal[data-delay="3"] { transition-delay: .24s; }
.reveal[data-delay="4"] { transition-delay: .32s; }
/* Defensa: nunca dejar invisible un reveal con split */
.reveal[data-split] { opacity: 1; transform: none; }

/* =============================================================
   23. Responsive
   ============================================================= */
@media (min-width: 540px) {
  .product-grid { grid-template-columns: repeat(2, 1fr); }
  .reel-grid { grid-template-columns: repeat(3, 1fr); }
}
@media (min-width: 720px) {
  .hero { align-items: center; }
  .hero-grid { grid-template-columns: 1.05fr .95fr; gap: 3.5rem; }
  .cat-grid { grid-template-columns: repeat(3, 1fr); }
  .process-grid { grid-template-columns: repeat(2, 1fr); }
  .about { grid-template-columns: .9fr 1.1fr; gap: 4rem; }
  .pillars { grid-template-columns: repeat(3, 1fr); }
  .contact-grid { grid-template-columns: .9fr 1.1fr; }
  .form-row { grid-template-columns: 1fr 1fr; }
  .footer-grid { grid-template-columns: 1.4fr 1fr 1fr; }
  .product-grid { grid-template-columns: repeat(3, 1fr); }
  .wa-float .wa-label { display: inline; }
  .nav-links { display: flex; }
  .nav-toggle { display: none; }
  .reel-grid { grid-template-columns: repeat(4, 1fr); }
  .reel-grid.has-embeds { grid-template-columns: repeat(2, 1fr); }
  .modal { grid-template-columns: 1fr 1fr; }
  .modal-media { aspect-ratio: auto; }
}
@media (min-width: 960px) {
  .process-grid { grid-template-columns: repeat(4, 1fr); }
  .product-grid { grid-template-columns: repeat(4, 1fr); }
}
@media (min-width: 1280px) {
  .display { font-size: clamp(3.5rem, 6vw, 6.5rem); }
}

/* =============================================================
   24. Reduced motion (solo lo intrusivo)
   ============================================================= */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .marquee-track { animation: none; }
  .wa-float { animation: none; }
  .hero-leaf { display: none; }
}
