/* SER BASICS · remate final — sistema visual minimal, negro / cream / oliva */

:root {
  --bg: #f5f0e4;        /* cream */
  --fg: #0a0a0a;        /* casi negro */
  --muted: #6b6a63;
  --line: #d9d3c2;
  --accent: #4a5436;    /* oliva */
  --danger: #9c2626;
  --white: #ffffff;
  --max: 1240px;
}

* { box-sizing: border-box; }

html, body { margin: 0; padding: 0; background: var(--bg); color: var(--fg); }

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  font-weight: 400;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }

.container { max-width: var(--max); margin: 0 auto; padding: 0 20px; }

/* --- header -------------------------------------------------------- */
.topbar {
  background: var(--fg);
  color: var(--bg);
  text-align: center;
  padding: 9px 20px;
  font-size: 11px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  font-weight: 500;
}
.topbar strong { font-weight: 800; }

.nav {
  padding: 18px 0;
  border-bottom: 1px solid var(--line);
  background: var(--bg);
  position: sticky;
  top: 0;
  z-index: 50;
}
.nav .wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  max-width: var(--max);
  margin: 0 auto;
  padding: 0 20px;
}
.nav .brand {
  display: inline-flex;
  align-items: center;
}
.nav .brand .wordmark {
  height: 18px;
  width: auto;
  display: block;
}
@media (min-width: 700px) {
  .nav .brand .wordmark { height: 20px; }
}
.nav .cart-link {
  font-size: 14px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

/* --- hero ---------------------------------------------------------- */
.hero {
  padding: 60px 20px 44px;
  text-align: center;
}
.hero h1 {
  font-weight: 900;
  font-size: clamp(44px, 10vw, 128px);
  line-height: 0.95;
  letter-spacing: -0.02em;
  margin: 0 0 18px;
  text-transform: uppercase;
}
.hero p {
  font-size: clamp(15px, 2.4vw, 20px);
  color: var(--muted);
  max-width: 620px;
  margin: 0 auto 24px;
}
.hero .meta {
  display: inline-flex;
  gap: 20px;
  font-size: 12px;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  padding-top: 20px;
  border-top: 1px solid var(--line);
}

/* --- grid productos ----------------------------------------------- */
.grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 24px 12px;
  padding: 20px 0 60px;
}
@media (min-width: 640px) {
  .grid {
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
    gap: 28px 20px;
    padding: 24px 0 80px;
  }
}
.card { position: relative; display: block; }
.card .ph {
  aspect-ratio: 3/4;
  background: var(--line);
  overflow: hidden;
}
.card .ph img {
  width: 100%; height: 100%; object-fit: cover;
  transition: transform 0.4s ease;
}
.card:hover .ph img { transform: scale(1.03); }

.card .meta { padding: 10px 2px 0; }
.card .n { font-size: 14px; font-weight: 500; line-height: 1.3; }
.card .pr { font-size: 14px; font-weight: 700; margin-top: 4px; }
.card .lo {
  position: absolute; top: 8px; left: 8px;
  background: var(--fg); color: var(--bg);
  padding: 4px 7px; font-size: 9px; font-weight: 800;
  letter-spacing: 0.1em; text-transform: uppercase;
  z-index: 2;
}
.card .ribbon-card {
  position: absolute; top: 8px; right: 8px;
  background: var(--accent); color: var(--white);
  padding: 4px 7px; font-size: 10px; font-weight: 800;
  letter-spacing: 0.03em;
  z-index: 2;
}
@media (min-width: 640px) {
  .card .lo { top: 10px; left: 10px; padding: 5px 9px; font-size: 10px; }
  .card .ribbon-card { top: 10px; right: 10px; padding: 5px 9px; font-size: 11px; }
}
.card .pr .was {
  font-size: 11px; color: var(--muted); text-decoration: line-through;
  margin-left: 6px; font-weight: 400;
}
.card .n { font-size: 13px; }
.card .pr { font-size: 13px; }
@media (min-width: 640px) {
  .card .n { font-size: 14px; }
  .card .pr { font-size: 14px; }
}

/* --- producto page ------------------------------------------------- */
.pdp {
  display: grid;
  grid-template-columns: 1fr;
  gap: 24px;
  padding: 24px 0 80px;
  max-width: 1120px;
  margin: 0 auto;
}
@media (min-width: 900px) {
  .pdp {
    grid-template-columns: minmax(0, 1fr) minmax(340px, 400px);
    gap: 48px;
    align-items: start;
  }
  .pdp .info {
    position: sticky;
    top: 90px;
  }
}
.pdp .gallery { display: flex; flex-direction: column; gap: 10px; }
.pdp .gallery .main {
  position: relative;
  aspect-ratio: 3/4;
  max-height: 78vh;
  background: var(--line);
  overflow: hidden;
}
.pdp .gallery .main .ribbon {
  position: absolute; top: 14px; right: 14px;
  background: var(--accent); color: var(--white);
  padding: 8px 14px; font-size: 15px; font-weight: 800;
  letter-spacing: 0.03em;
  z-index: 2;
  box-shadow: 0 2px 6px rgba(0,0,0,0.12);
}
.pdp .gallery .main .main-badge {
  position: absolute; top: 14px; left: 14px;
  background: var(--fg); color: var(--bg);
  padding: 8px 14px; font-size: 12px; font-weight: 800;
  letter-spacing: 0.12em; text-transform: uppercase;
  z-index: 2;
  box-shadow: 0 2px 6px rgba(0,0,0,0.12);
}
.pdp .gallery .main img { width: 100%; height: 100%; object-fit: cover; }
.pdp .gallery .thumbs { display: flex; gap: 8px; overflow-x: auto; }
.pdp .gallery .thumbs img {
  width: 64px; height: 82px; object-fit: cover;
  cursor: pointer; opacity: 0.55;
  flex: 0 0 auto;
}
.pdp .gallery .thumbs img.on { opacity: 1; outline: 2px solid var(--fg); outline-offset: -2px; }

.pdp .info h2 {
  font-size: clamp(22px, 3vw, 32px);
  font-weight: 800;
  margin: 0 0 10px;
  letter-spacing: -0.01em;
}
.pdp .info .price {
  display: flex; align-items: baseline; gap: 12px;
  margin: 10px 0 20px;
}
.pdp .info .price .now { font-size: 28px; font-weight: 800; }
.pdp .info .price .was { font-size: 15px; color: var(--muted); text-decoration: line-through; }
.pdp .info .price .pct {
  background: var(--accent); color: var(--white);
  padding: 2px 8px; font-size: 12px; font-weight: 700; letter-spacing: 0.05em;
}
.pdp .info .desc {
  color: var(--muted); font-size: 14px; line-height: 1.6; margin: 10px 0 24px;
}

.selector h4 {
  text-transform: uppercase; letter-spacing: 0.1em; font-size: 11px;
  font-weight: 700; margin: 18px 0 10px; color: var(--muted);
}
.pills { display: flex; flex-wrap: wrap; gap: 8px; }
.pill {
  padding: 8px 14px; min-width: 48px; text-align: center;
  background: transparent; color: var(--fg);
  border: 1px solid var(--line); font-size: 14px; font-weight: 500;
  cursor: pointer; font-family: inherit;
  transition: all 0.15s ease;
}
.pill:hover { border-color: var(--fg); }
.pill.on { background: var(--fg); color: var(--bg); border-color: var(--fg); }
.pill.off {
  color: var(--line); cursor: not-allowed; text-decoration: line-through;
  border-color: var(--line);
}

.add-btn {
  width: 100%; padding: 18px;
  background: var(--fg); color: var(--bg);
  border: none; cursor: pointer;
  font-family: inherit; font-weight: 700; font-size: 14px;
  letter-spacing: 0.1em; text-transform: uppercase;
  margin-top: 24px;
  transition: opacity 0.15s;
}
.add-btn:hover { opacity: 0.85; }
.add-btn[disabled] { opacity: 0.4; cursor: not-allowed; }

.stock-note { font-size: 13px; color: var(--muted); margin-top: 10px; min-height: 1.6em; padding: 6px 0; }
.stock-note.alert {
  color: var(--danger); font-weight: 600;
  background: rgba(156, 38, 38, 0.06);
  padding: 10px 12px; margin-top: 10px;
  border-left: 3px solid var(--danger);
}
.stock-note.alert strong { color: var(--danger); }
.stock-note.ok { color: var(--accent); font-weight: 500; }

.signals {
  display: flex; flex-wrap: wrap; gap: 10px 16px;
  padding: 12px 0 18px;
  border-bottom: 1px solid var(--line);
  margin-bottom: 16px;
}
.signals .sig {
  display: inline-flex; align-items: center; gap: 6px;
  font-size: 12px; color: var(--muted);
  letter-spacing: 0.02em;
}
.signals .sig svg { opacity: 0.7; }
.signals .sig strong { color: var(--fg); font-weight: 700; }

/* --- carrito ------------------------------------------------------- */
.cart-wrap { padding: 40px 0 80px; }
.cart-wrap h2 {
  font-size: 28px; font-weight: 900; margin: 0 0 24px;
  text-transform: uppercase; letter-spacing: 0.02em;
}
.cart-row {
  display: grid; grid-template-columns: 80px 1fr auto; gap: 16px;
  padding: 16px 0; border-bottom: 1px solid var(--line);
  align-items: center;
}
.cart-row .ph img { width: 80px; height: 100px; object-fit: cover; }
.cart-row .n { font-weight: 500; font-size: 15px; }
.cart-row .vd { color: var(--muted); font-size: 13px; margin-top: 4px; }
.cart-row .pr { font-weight: 700; }
.cart-row .rm { color: var(--muted); font-size: 12px; text-decoration: underline; background: none; border: none; cursor: pointer; margin-top: 4px; font-family: inherit; }

.totals { margin-top: 24px; }
.totals .row { display: flex; justify-content: space-between; padding: 8px 0; }
.totals .row.big { font-size: 20px; font-weight: 800; border-top: 1px solid var(--line); padding-top: 14px; margin-top: 8px; }

.cta-row { display: flex; gap: 12px; margin-top: 24px; flex-wrap: wrap; }
.btn {
  padding: 16px 28px;
  background: var(--fg); color: var(--bg);
  border: none; cursor: pointer;
  font-family: inherit; font-weight: 700; font-size: 13px;
  letter-spacing: 0.1em; text-transform: uppercase;
  display: inline-block;
}
.btn.ghost { background: transparent; color: var(--fg); border: 1px solid var(--fg); }
.btn.wa { background: #25D366; color: #fff; }
.btn:hover { opacity: 0.88; }

/* --- checkout form ------------------------------------------------- */
.form { max-width: 640px; margin: 0 auto; padding: 24px 0 80px; }
.form h2 { font-size: 28px; font-weight: 900; margin: 0 0 24px; text-transform: uppercase; }
.form .field { margin-bottom: 16px; }
.form label {
  display: block; font-size: 11px; text-transform: uppercase;
  font-weight: 700; letter-spacing: 0.1em; margin-bottom: 6px; color: var(--muted);
}
.form input, .form select, .form textarea {
  width: 100%; padding: 12px 14px;
  border: 1px solid var(--line); background: var(--white);
  font-family: inherit; font-size: 15px;
}
.form input:focus, .form select:focus, .form textarea:focus { outline: 2px solid var(--fg); outline-offset: -2px; }
.form .radios { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.form .radios label {
  padding: 16px; border: 1px solid var(--line); cursor: pointer;
  text-transform: none; letter-spacing: normal; font-size: 14px; color: var(--fg);
  text-align: center; font-weight: 500;
}
.form .radios input { display: none; }
.form .radios input:checked + span { font-weight: 700; }
.form .radios label.on { border-color: var(--fg); background: var(--fg); color: var(--bg); }

.form .ship-fields { display: none; }
.form .ship-fields.on { display: block; }

.ship-day-notice {
  background: var(--white);
  border-left: 3px solid var(--accent);
  padding: 14px 16px;
  margin-top: 16px;
  font-size: 14px;
  line-height: 1.45;
}
.ship-day-notice strong {
  display: block;
  font-weight: 800;
  margin-bottom: 2px;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  font-size: 13px;
}

/* --- reserva (post-checkout) --------------------------------------- */
.ok-page { max-width: 640px; margin: 0 auto; padding: 48px 0 80px; }
.ok-page h2 { font-size: clamp(28px, 5vw, 48px); font-weight: 900; margin: 0 0 10px; text-transform: uppercase; line-height: 0.95; }
.ok-page .sub { color: var(--muted); margin-bottom: 32px; }
.ok-page .block {
  background: var(--white); padding: 20px; margin-bottom: 16px;
  border-left: 3px solid var(--accent);
}
.ok-page .block h4 {
  text-transform: uppercase; font-size: 11px; letter-spacing: 0.1em;
  color: var(--muted); font-weight: 700; margin: 0 0 10px;
}
.ok-page .block .big { font-size: 20px; font-weight: 800; }
.ok-page .items { list-style: none; padding: 0; margin: 0; }
.ok-page .items li { padding: 6px 0; border-bottom: 1px solid var(--line); font-size: 14px; }
.ok-page .items li:last-child { border-bottom: none; }

.bank-row {
  display: grid;
  grid-template-columns: 72px 1fr auto;
  gap: 10px;
  padding: 10px 0;
  align-items: center;
}
.bank-row + .bank-row { border-top: 1px solid var(--line); }
.bank-label {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--muted);
  font-weight: 700;
}
.bank-value {
  font-size: 15px;
  font-weight: 600;
  min-width: 0;
  overflow-wrap: anywhere;
}
@media (max-width: 480px) {
  .bank-row {
    grid-template-columns: 72px 1fr;
    grid-template-areas: "label value" ". copy";
    row-gap: 4px;
  }
  .bank-label { grid-area: label; }
  .bank-value { grid-area: value; }
  .copy-btn { grid-area: copy; justify-self: start; margin-top: 2px; }
  .bank-row:has(.bank-value.big) {
    grid-template-areas: "label value" "copy copy";
  }
}
.bank-value.mono { font-family: 'JetBrains Mono', Menlo, Consolas, monospace; letter-spacing: 0.02em; }
.bank-value.big { font-size: 20px; font-weight: 800; }
.copy-btn {
  padding: 6px 12px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  background: var(--fg);
  color: var(--bg);
  border: none;
  cursor: pointer;
  font-family: inherit;
  transition: background 0.15s;
}
.copy-btn:hover { opacity: 0.85; }
.copy-btn.copied { background: var(--accent); }

/* --- admin --------------------------------------------------------- */
.admin-wrap { padding: 24px 0 80px; }
.admin-wrap h2 { font-size: 22px; font-weight: 900; margin: 32px 0 12px; text-transform: uppercase; }
.admin-table { width: 100%; border-collapse: collapse; font-size: 13px; }
.admin-table th, .admin-table td { padding: 10px 8px; text-align: left; border-bottom: 1px solid var(--line); vertical-align: top; }
.admin-table th { text-transform: uppercase; font-size: 11px; letter-spacing: 0.08em; color: var(--muted); font-weight: 700; }
.admin-table .inline-actions form { display: inline-block; margin: 0 4px 0 0; }
.admin-table button { padding: 6px 10px; font-size: 11px; text-transform: uppercase; letter-spacing: 0.05em; border: 1px solid var(--fg); background: var(--fg); color: var(--bg); cursor: pointer; font-family: inherit; }
.admin-table button.ghost { background: transparent; color: var(--fg); }

/* --- farewell block (home) --------------------------------------- */
.farewell {
  background: var(--fg);
  color: var(--bg);
  padding: 80px 20px 90px;
  margin-top: 40px;
}
.farewell-inner {
  text-align: center;
  max-width: 720px;
  margin: 0 auto;
}
.farewell h3 {
  font-size: clamp(56px, 12vw, 140px);
  font-weight: 900;
  letter-spacing: -0.03em;
  line-height: 0.9;
  margin: 0 0 24px;
}
.farewell p {
  font-size: clamp(14px, 2.2vw, 18px);
  line-height: 1.65;
  color: var(--bg);
  opacity: 0.88;
  margin: 0 0 40px;
  font-weight: 400;
}
.farewell-signature img {
  height: 22px;
  width: auto;
  margin: 0 auto;
  display: block;
  filter: invert(1);
  opacity: 0.95;
}

/* --- footer -------------------------------------------------------- */
footer {
  margin-top: 60px; padding: 40px 20px;
  border-top: 1px solid var(--line);
  text-align: center;
  font-size: 12px; color: var(--muted);
  letter-spacing: 0.08em; text-transform: uppercase;
}

/* --- wa floating button ------------------------------------------- */
.wa-float {
  position: fixed; bottom: 22px; right: 22px;
  background: #25D366; color: #fff;
  width: 56px; height: 56px; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  box-shadow: 0 4px 20px rgba(0,0,0,0.15);
  z-index: 100;
  font-size: 26px;
}
/* dejar espacio al final del scroll para que el botón flotante no tape el contenido */
main { padding-bottom: 90px; }

/* --- empty state -------------------------------------------------- */
.empty { text-align: center; padding: 80px 20px; color: var(--muted); }
.empty h3 { font-size: 20px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.05em; color: var(--fg); margin-bottom: 10px; }
