/* ==========================================================================
   Multi-sitio El Salto · acentos por proyecto
   Se carga después de styles.css. Cada body.site-* cambia el acento.
   ========================================================================== */

body.site-elsalto {
  --paper: #f1f4e6;
  --paper-2: #e6ecda;
  --surface: #fffef9;
  --surface-2: #f7f9ef;
  --ink: #1f2a17;
  --muted: #55624a;
  --muted-2: #6d7863;
  --pine: #55752f;
  --pine-2: #6b8e3f;
  --pine-soft: #e3ecd4;
  --honey: #7a5a14;
  --honey-2: #93762a;
  --honey-soft: #f6edd3;
  --honey-soft-2: #efdfb9;
  --line: #c7d2b4;
  --line-2: #aebd99;
  --serif: var(--sans);
}

body.site-gallinero {
  --honey: #8f4424;
  --honey-2: #c46b45;
  --honey-soft: #f6e3da;
  --honey-soft-2: #ecd0c4;
  --pine: #4a3a2a;
  --pine-2: #6b5544;
  --pine-soft: #efe4d7;
}

body.site-agricultura {
  --honey: #5f7a2f;
  --honey-2: #7f9c45;
  --honey-soft: #e8eed8;
  --honey-soft-2: #d5e0bd;
  --pine: #355020;
  --pine-2: #55752f;
  --pine-soft: #e3ecd4;
}

body.site-museo {
  --honey: #3d5a73;
  --honey-2: #5b7d9a;
  --honey-soft: #e1e8ef;
  --honey-soft-2: #cbd8e3;
  --pine: #284444;
  --pine-2: #3d5a73;
  --pine-soft: #dcebeb;
}

body.site-formacion {
  --honey: #176f6f;
  --honey-2: #2f8f8f;
  --honey-soft: #dff0ef;
  --honey-soft-2: #c3e3e1;
  --pine: #214a52;
  --pine-2: #176f6f;
  --pine-soft: #d9e8eb;
}

body.site-centro {
  --honey: #6b6257;
  --honey-2: #8a7f72;
  --honey-soft: #eee9e2;
  --honey-soft-2: #ddd5cb;
  --pine: #4a443d;
  --pine-2: #6b6257;
  --pine-soft: #e9e4dd;
}

body.site-obrador {
  --honey: #6b3a5a;
  --honey-2: #8a5475;
  --honey-soft: #f0e2ea;
  --honey-soft-2: #e0c9d6;
  --pine: #4a2638;
  --pine-2: #6b3a5a;
  --pine-soft: #eedcdf;
}

/* ── Logos ──────────────────────────────────────────────────────────────── */
.site-logo {
  width: 46px;
  height: 46px;
  flex: 0 0 auto;
  border-radius: 50%;
  object-fit: contain;
  background: #fef9e7;
}
.site-logo-fallback {
  width: 46px;
  height: 46px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: var(--honey-soft);
  border: 1px solid var(--honey);
  color: var(--honey);
  font-family: var(--serif);
  font-size: 18px;
  font-weight: 700;
}
/* ── Marca de cabecera (sin <a> anidados) ───────────────────────────────── */
.site-header-brand { display: flex; align-items: center; gap: 12px; min-width: 0; }
.brand-mark { display: flex; flex: 0 0 auto; text-decoration: none; }
.brand-mark .site-logo { display: block; }
.brand-text { display: flex; flex-direction: column; line-height: 1.08; min-width: 0; }
.brand-name { font-family: var(--serif); font-size: 20px; letter-spacing: -.01em; white-space: nowrap; color: inherit; text-decoration: none; }
a.brand-name:hover { color: var(--honey); }
.brand-sub { color: var(--muted); text-decoration: none; }
a.brand-sub:hover { color: var(--honey); text-decoration: underline; text-underline-offset: 2px; }

/* ── Hero por sitio ─────────────────────────────────────────────────────── */
.site-hero {
  color: #fff;
  background:
    linear-gradient(90deg, rgba(20, 30, 15, .92) 0%, rgba(20, 30, 15, .70) 55%, rgba(20, 30, 15, .38) 100%),
    url("finca-olivar.jpg") center 55% / cover no-repeat;
}
body.site-corral-del-viento .site-hero {
  background:
    linear-gradient(90deg, rgba(20, 30, 15, .90) 0%, rgba(20, 30, 15, .67) 55%, rgba(20, 30, 15, .35) 100%),
    url("hero-colmenar.jpg") 62% 50% / cover no-repeat;
}
body.site-museo .site-hero {
  background:
    linear-gradient(90deg, rgba(20, 30, 15, .92) 0%, rgba(20, 30, 15, .68) 55%, rgba(20, 30, 15, .35) 100%),
    url("museo-corcho.jpg") center 55% / cover no-repeat;
}
body.site-formacion .site-hero {
  background:
    linear-gradient(90deg, rgba(20, 30, 15, .92) 0%, rgba(20, 30, 15, .68) 55%, rgba(20, 30, 15, .35) 100%),
    url("visita-apicultor.jpg") center 45% / cover no-repeat;
}
body.site-obrador .site-hero {
  background:
    linear-gradient(90deg, rgba(20, 30, 15, .92) 0%, rgba(20, 30, 15, .68) 55%, rgba(20, 30, 15, .35) 100%),
    url("panal-macro.jpg") center 55% / cover no-repeat;
}
body.site-gallinero .site-hero {
  background:
    linear-gradient(90deg, rgba(20, 30, 15, .92) 0%, rgba(20, 30, 15, .68) 55%, rgba(20, 30, 15, .35) 100%),
    url("finca-olivar.jpg") center 55% / cover no-repeat;
}
body.site-agricultura .site-hero {
  background:
    linear-gradient(90deg, rgba(20, 30, 15, .92) 0%, rgba(20, 30, 15, .68) 55%, rgba(20, 30, 15, .35) 100%),
    url("finca-olivar.jpg") center 55% / cover no-repeat;
}
body.site-centro .site-hero {
  background:
    linear-gradient(90deg, rgba(20, 30, 15, .92) 0%, rgba(20, 30, 15, .68) 55%, rgba(20, 30, 15, .35) 100%),
    url("finca-olivar.jpg") center 55% / cover no-repeat;
}

/* ── Cards de proyecto ──────────────────────────────────────────────────── */
.project-card { position: relative; }
.project-card .project-logo {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  background: #fef9e7;
  margin-bottom: 4px;
}
.project-card .meta { color: var(--honey); }
.project-card h3 { font-size: 26px; }
.project-card .status-line { display: flex; align-items: center; gap: 8px; margin-top: auto; padding-top: 8px; }

/* ── Productos genéricos (huevos, fruta, conservas) ─────────────────────── */
.product-media.generic {
  background:
    radial-gradient(circle at 50% 30%, rgba(255, 255, 255, .9), transparent 60%),
    linear-gradient(160deg, var(--honey-soft) 0%, var(--paper-2) 100%);
}
.product-media.generic .product-icon {
  width: 46%;
  max-width: 140px;
  color: var(--honey);
  opacity: .9;
}
.product-media.generic .product-icon svg { width: 100%; height: auto; }
.product-media.generic svg { filter: none; }

/* ── Estados de stock ───────────────────────────────────────────────────── */
.product-card.is-out,
.product-card.is-soon { background: #f5f3ed; }
.product-card.is-preorder { border-style: dashed; }
.product-card.is-out .product-media,
.product-card.is-soon .product-media {
  background: linear-gradient(160deg, #efede7 0%, #ddd9d0 100%);
}
.product-card.is-out .product-media svg,
.product-card.is-soon .product-media svg { filter: grayscale(1); opacity: .5; }
.product-card.is-out .card-body h3,
.product-card.is-soon .card-body h3 { color: var(--muted); }
.product-card.is-out .price,
.product-card.is-soon .price { color: var(--muted-2); }
.product-card.is-out .product-notes,
.product-card.is-soon .product-notes { color: var(--muted-2); }

.product-flag {
  position: absolute; top: 12px; left: 12px; z-index: 3;
  font-size: 10px; letter-spacing: .12em; text-transform: uppercase; font-weight: 800;
  padding: 5px 10px; border-radius: 999px;
}
.product-flag.out { background: #6b2b22; color: #fff; }
.product-flag.soon { background: #fff; color: #6b6257; border: 1px solid #d8d0c4; }
.product-flag.season { background: var(--pine-soft); color: var(--pine); border: 1px solid #c7d2b4; }

.stock.soon { background: #e9e6df; color: #6b6257; border: 1px dashed #c9c2b6; }
.stock.preorder { background: var(--honey-soft); color: var(--honey); }
.stock.season { background: var(--pine-soft); color: var(--pine); }
.product-card.is-season { border-color: #c7d2b4; }
.season-note { margin: 0; font-size: 11px; color: var(--honey); }
.season-reserve { flex: 1 0 100%; text-align: center; font-size: 11px; color: var(--honey); text-decoration: underline; text-underline-offset: 2px; }
.product-actions { flex-wrap: wrap; }
.price-note { font-family: var(--sans); font-size: 10px; letter-spacing: .06em; text-transform: uppercase; color: var(--muted-2); }

.product-detail-media { position: relative; background: linear-gradient(160deg, #f8efd8, #ead9b6); }
.product-detail-media.is-out { background: linear-gradient(160deg, #efede7, #ddd9d0); }
.product-detail-media.is-out svg { filter: grayscale(1); opacity: .5; }
.product-detail-media .product-flag { top: 18px; left: 18px; }

/* ── Puente entre tiendas ───────────────────────────────────────────────── */
.other-shops {
  border: 1px solid var(--honey-soft-2);
  background: var(--honey-soft);
  border-radius: var(--radius-sm);
  padding: 12px 14px;
  margin: 4px 0 10px;
}
.other-shops-head {
  display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between;
  gap: 4px 10px; margin-bottom: 8px;
}
.other-shops-head strong { font-size: 13px; }
.other-shops-head span { font-size: 10px; letter-spacing: .12em; text-transform: uppercase; color: var(--honey); }
.shop-links { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; }
.shop-link {
  position: relative; display: flex; flex-direction: column; gap: 1px;
  padding: 8px 34px 8px 10px; border: 1px solid var(--line); border-radius: 8px;
  background: var(--surface); text-decoration: none; color: var(--ink);
  transition: border-color .15s, transform .15s;
}
.shop-link:hover { border-color: var(--honey); transform: translateY(-1px); }
.shop-link-name { font-size: 12px; font-weight: 700; }
.shop-link small { font-size: 10px; color: var(--muted); }
.shop-link .shop-count { position: absolute; top: 7px; right: 7px; }
.shop-carry-note { margin: 8px 0 0; font-size: 11px; color: var(--muted); line-height: 1.4; }

.shop-switcher {
  display: flex; flex-wrap: wrap; align-items: center; gap: 8px;
  margin: 0 0 18px;
}
.shop-switcher-label {
  font-size: 10px; letter-spacing: .14em; text-transform: uppercase;
  color: var(--muted); font-weight: 700;
}
.shop-chips { display: flex; flex-wrap: wrap; gap: 6px; }
.shop-chip {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 6px 11px; border: 1px solid var(--line); border-radius: 999px;
  background: var(--surface); color: var(--ink); text-decoration: none;
  font-size: 12px; font-weight: 650; transition: border-color .15s, color .15s;
}
.shop-chip:hover { border-color: var(--honey); color: var(--honey); }
.shop-count {
  display: inline-grid; place-items: center; min-width: 18px; height: 18px;
  padding: 0 5px; border-radius: 999px; background: var(--honey); color: #fff;
  font-size: 10px; font-weight: 700;
}
.shop-count[hidden] { display: none; }
.cart-shop {
  display: inline-block !important; margin-top: 3px; padding: 1px 6px;
  border-radius: 4px; background: var(--honey-soft); color: var(--honey) !important;
  font-size: 9.5px !important; letter-spacing: .08em; text-transform: uppercase;
}

/* ── Tienda ─────────────────────────────────────────────────────────────── */
.shop-intro {
  display: flex; flex-wrap: wrap; gap: 10px; align-items: center; justify-content: space-between;
  margin-bottom: 22px;
}
.shop-note {
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-sm);
  padding: 14px 18px; font-size: 13px; color: var(--muted);
}

/* ── Obrador ────────────────────────────────────────────────────────────── */
.obrador-line h3 { font-size: 24px; }
.obrador-line p { font-size: 13px; }
.obrador-line .product-tags { margin-top: auto; }

/* ── Legal ──────────────────────────────────────────────────────────────── */
.legal { max-width: 780px; margin: 0 auto; }
.legal h2 { font-size: 30px; margin-top: 38px; }
.legal h3 { font-size: 22px; margin-top: 24px; }
.legal p, .legal li { font-size: 15px; color: var(--muted); }
.legal .placeholder {
  background: var(--honey-soft); border: 1px dashed var(--honey);
  border-radius: 8px; padding: 10px 12px; color: var(--honey);
  font-family: var(--mono); font-size: 12px;
}

/* ── Varios ─────────────────────────────────────────────────────────────── */
.site-footer-brand { font-size: 12px; color: rgba(241, 238, 226, .55); margin-top: 8px; }
.site-footer-brand a { color: inherit; }
.site-small { font-size: 12px; color: var(--muted); }
.site-kicker-line { display: flex; align-items: center; gap: 10px; }

@media (max-width: 640px) {
  .site-logo, .site-logo-fallback { width: 40px; height: 40px; }
  .project-card .project-logo { width: 56px; height: 56px; }
  .site-hero { background-position: center 55%; }
}

/* ── Cifras y cabecera en móvil ─────────────────────────────────────────── */
@media (max-width: 760px) {
  .stats { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .stat { border-right: 0; border-bottom: 1px solid var(--line); }
  .stat:nth-child(odd) { border-right: 1px solid var(--line); }
  .stat:nth-last-child(-n+2) { border-bottom: 0; }
}
@media (max-width: 430px) {
  .cart-btn > span:not(.cart-count) { display: none; }
  .cart-btn { padding: 8px 10px; }
  .site-header-brand { gap: 9px; }
  .brand-name { font-size: 17px; }
}
@media (max-width: 360px) {
  .stats { grid-template-columns: 1fr; }
  .shop-links { grid-template-columns: 1fr; }
  .type-grid { grid-template-columns: 1fr; }
  .stat, .stat:nth-child(odd) { border-right: 0; border-bottom: 1px solid var(--line); }
  .stat:last-child { border-bottom: 0; }
}

/* ── Avisos y canales de noticias ───────────────────────────────────────── */
.avisos {
  display: grid; grid-template-columns: 1.1fr .9fr; gap: 30px;
  background: var(--surface); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 32px; box-shadow: var(--shadow);
}
.avisos h2 { margin: 8px 0 10px; }
.channels { display: grid; gap: 8px; margin-top: 18px; }
.channel {
  display: flex; flex-direction: column; gap: 1px;
  padding: 10px 12px; border: 1px solid var(--line); border-radius: 8px;
  background: var(--surface-2); text-decoration: none; color: var(--ink);
  transition: border-color .15s;
}
.channel:hover { border-color: var(--honey); }
.channel b { font-size: 13px; }
.channel-arrow { font-style: normal; color: var(--honey); }
.channel span { font-size: 11px; color: var(--muted); }
.avisos-form { border-left: 1px solid var(--line); padding-left: 30px; }
.avisos-form h3 { margin: 0 0 6px; font-size: 24px; }
.avisos-form p { margin: 0; font-size: 13px; color: var(--muted); line-height: 1.5; }
.avisos-form .input { margin: 12px 0 10px; }
.avisos-form .form-note { margin-top: 8px; font-size: 11px; }

/* ── Calendario de temporada ────────────────────────────────────────────── */
.season-list { display: grid; gap: 8px; }
.season-item {
  display: grid; grid-template-columns: 1.2fr auto auto; gap: 14px; align-items: center;
  background: var(--surface); border: 1px solid var(--line); border-radius: 8px;
  padding: 14px 16px;
}
.season-item b { display: block; font-size: 16px; }
.season-item span { font-size: 12px; color: var(--muted); }
.season-item .btn { white-space: nowrap; }
@media (max-width: 760px) {
  .avisos { grid-template-columns: 1fr; gap: 22px; padding: 22px; }
  .avisos-form { border-left: 0; border-top: 1px solid var(--line); padding: 22px 0 0; }
  .season-item { grid-template-columns: 1fr auto; }
  .season-item .btn { grid-column: 1 / -1; }
}

/* ── Accesibilidad y prototipo ──────────────────────────────────────────── */
.skip-link {
  position: absolute; left: 12px; top: -60px; z-index: 200;
  padding: 10px 16px; border-radius: 0 0 8px 8px;
  background: var(--pine); color: #fff; font-size: 13px; font-weight: 700;
  text-decoration: none;
}
.skip-link:focus { top: 0; }
.topbar a { color: #fff; text-underline-offset: 3px; }
.topbar b { color: #f6edd3; }
[id] { scroll-margin-top: 96px; }
.footer h4 { color: #e8d9a8; }
.type-card, .breed-card, .breed-pill { text-decoration: none; }
.type-card:focus-visible, .breed-card:focus-visible, .btn:focus-visible, a:focus-visible {
  outline: 3px solid var(--honey-2); outline-offset: 3px;
}
.checkbox {
  display: flex; align-items: flex-start; gap: 8px;
  font-size: 12px; color: var(--muted); line-height: 1.45; margin: 8px 0 12px;
}
.checkbox input { margin-top: 2px; accent-color: var(--pine); }
.checkbox a { color: var(--honey); text-underline-offset: 2px; }

/* ── Fichas de raza ─────────────────────────────────────────────────────── */
.breed-hero { background: var(--paper-2); color: var(--ink); padding: 34px 0 30px; }
.breed-hero-grid { display: grid; grid-template-columns: 1.2fr .8fr; gap: 30px; align-items: center; }
.breed-hero h1 { color: var(--ink); text-shadow: none; }
.breed-hero .lead { color: var(--muted); }
.breed-hero .kicker { color: var(--honey); }
.breed-hero .breadcrumbs a { color: var(--muted); }
.breed-hero-art { display: grid; place-items: center; }
.breed-hero-art img { width: min(240px, 70%); height: auto; }
.breed-card .breed-art { background: var(--honey-soft); display: grid; place-items: center; padding: 12px; }
.breed-card .breed-art img { width: 120px; height: 120px; }
.breed-card p { font-size: 13px; color: var(--muted); }
.breed-pill { display: inline-flex; text-decoration: none; }

/* ── Fichas de colmena ──────────────────────────────────────────────────── */
.type-hero { background: var(--paper-2); color: var(--ink); padding: 34px 0 30px; }
.type-hero-grid { display: grid; grid-template-columns: 1.15fr .85fr; gap: 30px; align-items: center; }
.type-hero h1 { color: var(--ink); text-shadow: none; }
.type-hero .lead { color: var(--muted); }
.type-hero .kicker { color: var(--honey); }
.type-hero .breadcrumbs a { color: var(--muted); }
.type-hero-photo {
  width: 100%; max-height: 320px; object-fit: cover;
  border-radius: var(--radius); box-shadow: var(--shadow-lg);
}
.type-card .type-link { color: #fff; }

/* ── Cuaderno: diagrama ─────────────────────────────────────────────────── */
.flow-diagram {
  display: flex; flex-wrap: wrap; align-items: center; gap: 8px;
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 18px; box-shadow: var(--shadow);
}
.flow-step {
  flex: 1 1 120px; min-width: 120px; padding: 12px;
  background: var(--honey-soft); border-radius: 8px;
}
.flow-step b { display: block; font-size: 13px; }
.flow-step span { display: block; font-size: 11px; color: var(--muted); margin-top: 3px; }
.flow-arrow { color: var(--honey); font-size: 20px; font-weight: 700; }

/* ── Ficha genérica de producto ─────────────────────────────────────────── */
.product-detail-generic { background: linear-gradient(160deg, var(--honey-soft), var(--paper-2)); }
.product-detail-generic svg { width: min(260px, 70%); height: auto; }

@media (max-width: 760px) {
  .breed-hero-grid, .type-hero-grid { grid-template-columns: 1fr; }
  .breed-hero-art { order: -1; }
  .breed-hero-art img { width: 160px; }
  .type-hero-photo { max-height: 220px; }
  .flow-diagram { flex-direction: column; align-items: stretch; }
  .flow-arrow { text-align: center; transform: rotate(90deg); }
}
.breed-hero .breadcrumbs, .type-hero .breadcrumbs { color: var(--muted); }
.breed-hero .breadcrumbs a, .type-hero .breadcrumbs a { color: var(--muted); }

/* ── Proyecto interno (Cuaderno) ────────────────────────────────────────── */
.project-intro {
  display: grid; grid-template-columns: auto 1fr auto; gap: 18px; align-items: center;
  background: var(--surface); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 20px; box-shadow: var(--shadow);
}
.project-intro img { width: 72px; height: 72px; }
.project-intro h2 { margin: 2px 0 4px; }
.project-intro p { margin: 0 0 8px; font-size: 13px; color: var(--muted); }
@media (max-width: 760px) {
  .project-intro { grid-template-columns: 1fr; text-align: left; }
  .project-intro img { width: 56px; height: 56px; }
}

/* Tarjetas dentro de una sección oscura: fondo claro, texto oscuro */
.section.dark .card,
.section.dark .card h3,
.section.dark .card a { color: var(--ink); }
.section.dark .card p { color: var(--muted); }
.section.dark .card .meta { color: var(--honey); }

/* ── Buscador y mapa del sitio ──────────────────────────────────────────── */
.search-row { max-width: 420px; margin: 0 0 16px; }
.search-row .input { width: 100%; }
.map-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 26px; }
.map-block h2 { font-size: 24px; margin: 0 0 10px; }
.map-list { list-style: none; padding: 0; margin: 0; display: grid; gap: 6px; }
.map-item a { font-size: 14px; color: var(--ink); text-decoration: none; }
.map-item a:hover { color: var(--honey); text-decoration: underline; text-underline-offset: 2px; }
@media (max-width: 760px) { .map-grid { grid-template-columns: 1fr; } }
.qty-note { font-size: 11px; color: var(--muted); }

/* ── Formulario de avisos en el pie ─────────────────────────────────────── */
.footer-form { margin-top: 14px; }
.footer-form-row { display: flex; gap: 6px; }
.footer-form-row .input { flex: 1; min-width: 0; background: rgba(255,255,255,.08); border-color: rgba(255,255,255,.18); color: #f1eee2; }
.footer-form-row .input::placeholder { color: rgba(241,238,226,.55); }
.footer-form .checkbox { color: rgba(241,238,226,.7); font-size: 10.5px; margin: 6px 0 0; }
.footer-form .checkbox a { color: #e8d9a8; }
.footer-form .form-success { margin-top: 8px; font-size: 11px; color: #e8d9a8; background: rgba(255,255,255,.06); border-color: rgba(255,255,255,.16); }
.footer-form .btn { background: #e8d9a8; color: #1f2a17; border-color: #e8d9a8; }
.footer-form .btn:hover { background: #f2e6bf; border-color: #f2e6bf; }
