/* =========================================================
   Finca Navalalteza — Hoja de estilos
   Paleta de marca: azul marino · dorado · blanco
   ========================================================= */

/* ---- Tipografías de marca (uso local) ----
   NewYork y RetroSignature son las fuentes del brandboard.
   Nota de licencia: los .otf entregados son "PERSONAL USE".
   Para uso comercial online conviene adquirir la licencia web
   o mantener las alternativas de Google Fonts (ya cargadas). */
@font-face {
  font-family: "NewYork";
  src: url("../assets/fonts/NewYork.otf") format("opentype");
  font-weight: normal;
  font-display: swap;
}
@font-face {
  font-family: "RetroSignature";
  src: url("../assets/fonts/RetroSignature.otf") format("opentype");
  font-weight: normal;
  font-display: swap;
}

:root {
  /* Colores de marca */
  --navy: #12203f;
  --navy-800: #1b2c50;
  --navy-700: #26385f;
  --gold: #b8934e;
  --gold-light: #cca866;
  --gold-soft: #e7d7b6;
  --cream: #faf7f1;
  --cream-2: #f3ecdf;
  --white: #ffffff;
  --ink: #22272e;
  --muted: #6b6459;

  /* Tipografías */
  --font-display: "NewYork", "Cormorant Garamond", Georgia, serif;
  --font-serif: "Cormorant Garamond", Georgia, serif;
  --font-sans: "Jost", "Segoe UI", system-ui, sans-serif;
  --font-script: "RetroSignature", "Great Vibes", cursive;

  --shadow-sm: 0 2px 10px rgba(18, 32, 63, .06);
  --shadow-md: 0 12px 40px rgba(18, 32, 63, .12);
  --radius: 4px;
  --maxw: 1200px;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--font-sans);
  color: var(--ink);
  background: var(--cream);
  line-height: 1.65;
  font-size: 17px;
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; display: block; }

a { color: var(--navy); text-decoration: none; transition: color .2s ease; }
a:hover { color: var(--gold); }

h1, h2, h3, h4 {
  font-family: var(--font-display);
  color: var(--navy);
  font-weight: 500;
  line-height: 1.12;
  margin: 0 0 .5em;
  letter-spacing: .01em;
}

h1 { font-size: clamp(2.4rem, 5vw, 4rem); }
h2 { font-size: clamp(1.9rem, 3.4vw, 2.9rem); }
h3 { font-size: clamp(1.3rem, 2vw, 1.7rem); }

p { margin: 0 0 1.1em; }

.container { width: 100%; max-width: var(--maxw); margin: 0 auto; padding: 0 24px; }

.section { padding: 92px 0; }
.section--tight { padding: 60px 0; }
.section--cream2 { background: var(--cream-2); }
.section--navy { background: var(--navy); color: #e9e6df; }
.section--navy h1, .section--navy h2, .section--navy h3 { color: var(--white); }

.text-center { text-align: center; }

.eyebrow {
  font-family: var(--font-sans);
  text-transform: uppercase;
  letter-spacing: .32em;
  font-size: .72rem;
  color: var(--gold);
  font-weight: 600;
  margin: 0 0 1rem;
  display: block;
}

.script {
  font-family: var(--font-script);
  color: var(--gold);
  font-weight: 400;
}

.lead { font-size: 1.18rem; color: var(--muted); max-width: 60ch; }
.section--navy .lead { color: #cfd4de; }

.divider-acorn {
  width: 44px; height: 44px; margin: 0 auto 1.2rem;
  background: url("../assets/img/emblema-dorado.png") center/contain no-repeat;
  opacity: .9;
}
.divider-acorn.is-lg { width: 88px; height: 88px; margin-bottom: 1.6rem; }

/* ---------- Botones ---------- */
.btn {
  display: inline-flex; align-items: center; gap: .55em;
  font-family: var(--font-sans);
  font-size: .82rem; font-weight: 600;
  letter-spacing: .16em; text-transform: uppercase;
  padding: 14px 30px;
  border-radius: var(--radius);
  border: 1.5px solid var(--gold);
  background: var(--gold);
  color: var(--navy);
  cursor: pointer;
  transition: all .25s ease;
}
.btn:hover { background: var(--gold-light); border-color: var(--gold-light); color: var(--navy); transform: translateY(-2px); }
.btn--outline { background: transparent; color: var(--gold); }
.btn--outline:hover { background: var(--gold); color: var(--navy); }
.btn--navy { background: var(--navy); border-color: var(--navy); color: var(--white); }
.btn--navy:hover { background: var(--navy-800); border-color: var(--navy-800); color: var(--white); }
.btn--light { background: transparent; border-color: rgba(255,255,255,.6); color: #fff; }
.btn--light:hover { background: #fff; color: var(--navy); border-color: #fff; }
.btn--sm { padding: 10px 20px; font-size: .74rem; }

/* ---------- Header / Nav ---------- */
.site-header {
  position: sticky; top: 0; z-index: 100;
  background: rgba(18, 32, 63, .96);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid rgba(184, 147, 78, .25);
}
.nav {
  display: flex; align-items: center; justify-content: space-between;
  height: 76px;
}
.nav__logo { display: flex; align-items: center; gap: 12px; }
.nav__logo img { height: 44px; width: auto; }
.nav__logo-text { display: flex; flex-direction: column; line-height: 1; }
.nav__logo-text b { font-family: var(--font-display); font-weight: 500; font-size: 1.35rem; color: #fff; letter-spacing: .02em; }
.nav__logo-text em { font-family: var(--font-sans); font-style: normal; text-transform: uppercase; letter-spacing: .22em; font-size: .62rem; font-weight: 500; color: var(--gold-light); margin-top: 5px; }
@media (max-width: 420px) { .nav__logo-text b { font-size: 1.1rem; } .nav__logo-text em { font-size: .54rem; letter-spacing: .16em; } }
.nav__links { display: flex; align-items: center; gap: 30px; list-style: none; margin: 0; padding: 0; }
.nav__links a {
  color: #eceaf1; font-size: .82rem; letter-spacing: .14em;
  text-transform: uppercase; font-weight: 500;
}
.nav__links a:hover, .nav__links a.is-active { color: var(--gold-light); }
.nav__actions { display: flex; align-items: center; gap: 16px; }

.cart-btn {
  position: relative; background: none; border: none; cursor: pointer;
  color: #eceaf1; display: flex; align-items: center; padding: 6px;
}
.cart-btn:hover { color: var(--gold-light); }
.cart-btn svg { width: 24px; height: 24px; }
.cart-count {
  position: absolute; top: -4px; right: -6px;
  background: var(--gold); color: var(--navy);
  font-size: .66rem; font-weight: 700; font-family: var(--font-sans);
  min-width: 18px; height: 18px; border-radius: 9px;
  display: flex; align-items: center; justify-content: center; padding: 0 4px;
}

.nav__toggle { display: none; background: none; border: none; cursor: pointer; padding: 6px; }
.nav__toggle span { display: block; width: 26px; height: 2px; background: #eceaf1; margin: 5px 0; transition: .3s; }

/* ---------- Hero ---------- */
.hero {
  position: relative; min-height: 88vh;
  display: flex; align-items: center;
  color: #fff; text-align: center;
  background: linear-gradient(rgba(18,32,63,.62), rgba(18,32,63,.78)),
              url("../assets/img/dehesa-cochinos.jpg") center/cover fixed;
}
.hero__inner { max-width: 820px; margin: 0 auto; padding: 120px 24px; }
.hero h1 { color: #fff; font-size: clamp(2.8rem, 6vw, 5rem); margin-bottom: .2em; }
.hero .script { font-size: clamp(1.8rem, 4vw, 2.8rem); display: block; margin-bottom: .3em; }
.hero p { color: #e6e6e6; font-size: 1.2rem; max-width: 46ch; margin: 0 auto 2rem; }
.hero__cta { display: flex; gap: 16px; justify-content: center; flex-wrap: wrap; }

/* ---------- Feature grid (valores) ---------- */
.features { display: grid; grid-template-columns: repeat(4, 1fr); gap: 28px; }
.feature { text-align: center; padding: 8px; }
.feature__icon {
  width: 64px; height: 64px; margin: 0 auto 18px;
  border: 1.5px solid var(--gold); border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  color: var(--gold);
}
.feature__icon svg { width: 30px; height: 30px; }
.feature h3 { font-size: 1.25rem; margin-bottom: .35em; }
.feature p { font-size: .95rem; color: var(--muted); margin: 0; }

/* ---------- Split (imagen + texto) ---------- */
.split { display: grid; grid-template-columns: 1fr 1fr; gap: 64px; align-items: center; }
.split--reverse .split__media { order: 2; }
.split__media img { border-radius: var(--radius); box-shadow: var(--shadow-md); width: 100%; height: 100%; object-fit: cover; max-height: 520px; }
.split__media--emblem { display: flex; align-items: center; justify-content: center; }
.split__media--emblem img { box-shadow: none; max-width: 320px; }

/* ---------- Productos destacados ---------- */
.product-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(270px, 1fr));
  gap: 30px;
}
.product-card {
  background: #fff; border: 1px solid #ece5d8; border-radius: var(--radius);
  overflow: hidden; display: flex; flex-direction: column;
  transition: transform .25s ease, box-shadow .25s ease;
}
.product-card:hover { transform: translateY(-5px); box-shadow: var(--shadow-md); }
.product-card__media {
  position: relative; aspect-ratio: 4/3; background: var(--cream-2);
  display: flex; align-items: center; justify-content: center; overflow: hidden;
}
.product-card__media img { width: 62%; opacity: .95; transition: transform .4s ease; }
.product-card:hover .product-card__media img { transform: scale(1.05); }
.product-card__tag {
  position: absolute; top: 12px; left: 12px;
  background: var(--navy); color: #fff; font-size: .64rem; font-weight: 600;
  letter-spacing: .12em; text-transform: uppercase; padding: 5px 11px; border-radius: 2px;
}
.product-card__body { padding: 22px 22px 24px; display: flex; flex-direction: column; flex: 1; }
.product-card__cat { font-size: .68rem; letter-spacing: .18em; text-transform: uppercase; color: var(--gold); font-weight: 600; margin-bottom: 6px; }
.product-card__title { font-family: var(--font-display); font-size: 1.35rem; color: var(--navy); margin: 0 0 6px; }
.product-card__desc { font-size: .9rem; color: var(--muted); margin: 0 0 16px; flex: 1; }
.product-card__footer { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.product-card__price { font-family: var(--font-display); font-size: 1.5rem; color: var(--navy); }
.product-card__price small { font-size: .8rem; color: var(--muted); font-family: var(--font-sans); }
.product-card__price--ask { font-size: 1.2rem; color: var(--gold); }
/* Producto "próximamente" */
.product-card.is-soon { opacity: .96; }
.product-card.is-soon .product-card__media img { filter: grayscale(30%); opacity: .8; }
.product-card__tag--soon { background: var(--gold); color: var(--navy); }
.product-card__soon { margin-top: auto; border-top: 1px dashed #d9cfbb; padding-top: 14px; font-size: .78rem; letter-spacing: .1em; text-transform: uppercase; color: var(--gold); font-weight: 700; }
.product-card__soon span { display: block; text-transform: none; letter-spacing: 0; font-weight: 400; color: var(--muted); margin-top: 4px; font-size: .9rem; }

/* ---------- Catálogo: layout con filtros ---------- */
.catalog { display: grid; grid-template-columns: 260px 1fr; gap: 44px; align-items: start; }
.filters {
  position: sticky; top: 100px;
  background: #fff; border: 1px solid #ece5d8; border-radius: var(--radius);
  padding: 26px 24px;
}
.filters h3 { font-size: 1.1rem; margin-bottom: 4px; }
.filters__group { padding: 18px 0; border-bottom: 1px solid #eee3d0; }
.filters__group:last-of-type { border-bottom: none; }
.filters__legend { font-size: .72rem; letter-spacing: .16em; text-transform: uppercase; color: var(--navy); font-weight: 700; margin-bottom: 12px; }
.filter-option { display: flex; align-items: center; gap: 10px; margin-bottom: 9px; cursor: pointer; font-size: .95rem; color: var(--ink); }
.filter-option input { accent-color: var(--gold); width: 16px; height: 16px; cursor: pointer; }
.filter-option .count { margin-left: auto; color: var(--muted); font-size: .82rem; }
.range-value { font-family: var(--font-sans); font-weight: 600; color: var(--navy); }
input[type="range"] { width: 100%; accent-color: var(--gold); cursor: pointer; }
.search-box { position: relative; margin-bottom: 8px; }
.search-box input {
  width: 100%; padding: 12px 14px 12px 40px; border: 1px solid #d9cfbb; border-radius: var(--radius);
  font-family: var(--font-sans); font-size: .95rem; background: var(--cream);
}
.search-box input:focus { outline: none; border-color: var(--gold); }
.search-box svg { position: absolute; left: 13px; top: 50%; transform: translateY(-50%); width: 18px; height: 18px; color: var(--muted); }

.catalog__bar { display: flex; align-items: center; justify-content: space-between; gap: 16px; margin-bottom: 26px; flex-wrap: wrap; }
.catalog__count { color: var(--muted); font-size: .95rem; }
.catalog__count strong { color: var(--navy); }
.select {
  font-family: var(--font-sans); font-size: .9rem; padding: 10px 14px;
  border: 1px solid #d9cfbb; border-radius: var(--radius); background: #fff; color: var(--ink); cursor: pointer;
}
.filters__reset { background: none; border: none; color: var(--gold); font-family: var(--font-sans); font-size: .82rem; cursor: pointer; padding: 0; font-weight: 600; }
.filters__reset:hover { text-decoration: underline; }

.no-results { text-align: center; padding: 60px 20px; color: var(--muted); grid-column: 1/-1; }

/* Filtros móvil */
.filters-toggle { display: none; }

/* ---------- Franja de cifras / confianza ---------- */
.stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 30px; text-align: center; }
.stat__num { font-family: var(--font-display); font-size: 2.8rem; color: var(--gold-light); line-height: 1; }
.stat__label { font-size: .8rem; letter-spacing: .14em; text-transform: uppercase; color: #cfd4de; margin-top: 8px; }

/* ---------- Proceso (pasos) ---------- */
.steps { display: grid; grid-template-columns: repeat(4, 1fr); gap: 26px; counter-reset: step; }
.step { position: relative; padding: 30px 24px; background: #fff; border: 1px solid #ece5d8; border-radius: var(--radius); }
.step::before {
  counter-increment: step; content: "0" counter(step);
  font-family: var(--font-display); font-size: 2.2rem; color: var(--gold-soft);
  display: block; margin-bottom: 10px; line-height: 1;
}
.step h3 { font-size: 1.15rem; margin-bottom: .4em; }
.step p { font-size: .9rem; color: var(--muted); margin: 0; }

/* ---------- CTA final ---------- */
.cta-band { text-align: center; }
.cta-band .btn { margin-top: 10px; }

/* ---------- Formulario contacto ---------- */
.contact-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 56px; align-items: start; }
.form-field { margin-bottom: 20px; }
.form-field label { display: block; font-size: .8rem; letter-spacing: .1em; text-transform: uppercase; color: var(--navy); font-weight: 600; margin-bottom: 7px; }
.form-field input, .form-field textarea, .form-field select {
  width: 100%; padding: 13px 15px; border: 1px solid #d9cfbb; border-radius: var(--radius);
  font-family: var(--font-sans); font-size: 1rem; background: #fff; color: var(--ink);
}
.form-field input:focus, .form-field textarea:focus, .form-field select:focus { outline: none; border-color: var(--gold); box-shadow: 0 0 0 3px rgba(184,147,78,.12); }
.form-field textarea { resize: vertical; min-height: 130px; }
.contact-info__item { display: flex; gap: 16px; margin-bottom: 26px; }
.contact-info__item svg { width: 24px; height: 24px; color: var(--gold); flex-shrink: 0; margin-top: 3px; }
.contact-info__item h4 { font-family: var(--font-sans); font-size: .78rem; text-transform: uppercase; letter-spacing: .12em; color: var(--navy); margin: 0 0 3px; font-weight: 700; }
.contact-info__item p { margin: 0; color: var(--muted); }

/* ---------- Panel del carrito ---------- */
.cart-overlay {
  position: fixed; inset: 0; background: rgba(18,32,63,.5);
  opacity: 0; visibility: hidden; transition: .3s; z-index: 200;
}
.cart-overlay.is-open { opacity: 1; visibility: visible; }
.cart-panel {
  position: fixed; top: 0; right: 0; height: 100%; width: 400px; max-width: 90vw;
  background: var(--cream); z-index: 210; transform: translateX(100%);
  transition: transform .35s cubic-bezier(.4,0,.2,1); display: flex; flex-direction: column;
  box-shadow: -10px 0 40px rgba(0,0,0,.2);
}
.cart-panel.is-open { transform: translateX(0); }
.cart-panel__head { display: flex; align-items: center; justify-content: space-between; padding: 24px; border-bottom: 1px solid #e3d9c6; background: var(--navy); color: #fff; }
.cart-panel__head h3 { color: #fff; margin: 0; font-size: 1.3rem; }
.cart-close { background: none; border: none; color: #fff; cursor: pointer; font-size: 1.6rem; line-height: 1; padding: 0; }
.cart-panel__body { flex: 1; overflow-y: auto; padding: 20px 24px; }
.cart-item { display: flex; gap: 14px; padding: 16px 0; border-bottom: 1px solid #e3d9c6; }
.cart-item__img { width: 66px; height: 66px; background: #fff; border-radius: var(--radius); display: flex; align-items: center; justify-content: center; flex-shrink: 0; border: 1px solid #ece5d8; }
.cart-item__img img { width: 74%; }
.cart-item__info { flex: 1; min-width: 0; }
.cart-item__name { font-family: var(--font-display); font-size: 1.05rem; color: var(--navy); margin: 0 0 2px; }
.cart-item__price { color: var(--muted); font-size: .85rem; }
.cart-item__qty { display: inline-flex; align-items: center; gap: 10px; margin-top: 8px; }
.cart-item__qty button { width: 26px; height: 26px; border: 1px solid #d3c8b2; background: #fff; border-radius: 3px; cursor: pointer; color: var(--navy); font-size: 1rem; line-height: 1; }
.cart-item__qty button:hover { border-color: var(--gold); color: var(--gold); }
.cart-item__remove { background: none; border: none; color: var(--muted); cursor: pointer; font-size: .78rem; margin-top: 6px; padding: 0; text-decoration: underline; }
.cart-item__remove:hover { color: #a3402f; }
.cart-empty { text-align: center; color: var(--muted); padding: 50px 20px; }
.cart-panel__foot { padding: 22px 24px; border-top: 1px solid #e3d9c6; background: #fff; }
.cart-total { display: flex; justify-content: space-between; align-items: baseline; margin-bottom: 16px; }
.cart-total span { color: var(--muted); }
.cart-total strong { font-family: var(--font-display); font-size: 1.7rem; color: var(--navy); }
.cart-panel__foot .btn { width: 100%; justify-content: center; }
.cart-note { font-size: .78rem; color: var(--muted); text-align: center; margin: 12px 0 0; }

.toast {
  position: fixed; bottom: 26px; left: 50%; transform: translateX(-50%) translateY(20px);
  background: var(--navy); color: #fff; padding: 14px 26px; border-radius: var(--radius);
  font-size: .9rem; z-index: 300; opacity: 0; visibility: hidden; transition: .3s;
  box-shadow: var(--shadow-md);
}
.toast.is-show { opacity: 1; visibility: visible; transform: translateX(-50%) translateY(0); }

/* ---------- Footer ---------- */
.site-footer { background: var(--navy); color: #b9c0cf; padding: 68px 0 30px; }
.footer-grid { display: grid; grid-template-columns: 1.6fr 1fr 1fr 1.3fr; gap: 40px; }
.site-footer img.footer-logo { height: 54px; margin-bottom: 18px; }
.site-footer h4 { color: #fff; font-family: var(--font-sans); font-size: .78rem; letter-spacing: .16em; text-transform: uppercase; margin-bottom: 18px; }
.site-footer ul { list-style: none; margin: 0; padding: 0; }
.site-footer li { margin-bottom: 10px; }
.site-footer a { color: #b9c0cf; font-size: .92rem; }
.site-footer a:hover { color: var(--gold-light); }
.footer-social { display: flex; gap: 14px; margin-top: 6px; }
.footer-social a { width: 38px; height: 38px; border: 1px solid rgba(255,255,255,.2); border-radius: 50%; display: flex; align-items: center; justify-content: center; color: #b9c0cf; }
.footer-social a:hover { border-color: var(--gold); color: var(--gold-light); }
.footer-social svg { width: 18px; height: 18px; }
.footer-bottom { border-top: 1px solid rgba(255,255,255,.12); margin-top: 46px; padding-top: 24px; display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; font-size: .82rem; color: #8a92a4; }
.footer-bottom a { color: #8a92a4; }

/* ---------- Página interior: cabecera ---------- */
.page-head {
  background: linear-gradient(rgba(18,32,63,.72), rgba(18,32,63,.82)), url("../assets/img/dehesa-cochinos.jpg") center/cover;
  color: #fff; text-align: center; padding: 130px 24px 90px;
}
.page-head h1 { color: #fff; margin-bottom: .2em; }
.page-head p { color: #dfe2e8; max-width: 54ch; margin: 0 auto; font-size: 1.1rem; }
.breadcrumb { font-size: .78rem; letter-spacing: .12em; text-transform: uppercase; color: var(--gold-light); margin-bottom: 1.2rem; }
.breadcrumb a { color: var(--gold-light); }

/* ---------- Bloque cita ---------- */
.quote { text-align: center; max-width: 780px; margin: 0 auto; }
.quote p { font-family: var(--font-display); font-size: clamp(1.5rem, 3vw, 2.2rem); color: var(--navy); font-style: italic; line-height: 1.4; }
.section--navy .quote p { color: #fff; }
.quote cite { display: block; margin-top: 1.1rem; font-family: var(--font-script); font-size: 2.7rem; color: var(--gold); font-style: normal; line-height: 1.1; }

/* ---------- Utilidades ---------- */
.mt-0 { margin-top: 0; }
.reveal { opacity: 0; transform: translateY(24px); transition: opacity .7s ease, transform .7s ease; }
.reveal.is-visible { opacity: 1; transform: none; }

/* ---------- Responsive ---------- */
@media (max-width: 960px) {
  .features, .steps, .stats { grid-template-columns: repeat(2, 1fr); }
  .split, .contact-grid { grid-template-columns: 1fr; gap: 40px; }
  .split--reverse .split__media { order: 0; }
  .footer-grid { grid-template-columns: 1fr 1fr; gap: 34px; }
  .catalog { grid-template-columns: 1fr; }
  .filters { position: static; display: none; }
  .filters.is-open { display: block; }
  .filters-toggle { display: inline-flex; }
}

@media (max-width: 680px) {
  .section { padding: 64px 0; }
  .nav__links { display: none; }
  .nav__links.is-open {
    display: flex; position: absolute; top: 76px; left: 0; right: 0;
    flex-direction: column; background: var(--navy); padding: 20px 24px; gap: 18px;
    border-bottom: 1px solid rgba(184,147,78,.25);
  }
  .nav__toggle { display: block; }
  .features, .steps, .stats, .footer-grid { grid-template-columns: 1fr; }
  .hero { background-attachment: scroll; }
  .page-head { padding: 90px 24px 64px; }
}
