/* ═══════════════════════════════════════════════════════════════
   RECETAS — Minimal Black & White Design System
   ═══════════════════════════════════════════════════════════════ */

/* ── 1. Variables ──────────────────────────────────────────────── */
:root {
  --c-black:     #0f0f0f;
  --c-ink:       #1c1c1c;
  --c-gray-1:    #333;
  --c-gray-2:    #555;
  --c-gray-3:    #888;
  --c-gray-4:    #bbb;
  --c-gray-5:    #ddd;
  --c-gray-6:    #f0efed;
  --c-off-white: #f8f7f5;
  --c-white:     #fff;
  --f-sans:  system-ui, -apple-system, "Segoe UI", Arial, sans-serif;
  --f-serif: Georgia, "Times New Roman", Times, serif;
  --border:  1px solid var(--c-gray-5);
  --ease:    140ms ease;
}

/* ── 2. Reset & base ───────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--f-sans);
  font-size: 1rem;
  line-height: 1.65;
  color: var(--c-ink);
  background: var(--c-white);
  -webkit-font-smoothing: antialiased;
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}
img { display: block; max-width: 100%; height: auto; }
a   { color: inherit; }

/* ── 3. Skip link ──────────────────────────────────────────────── */
.skip-link {
  position: absolute;
  top: -999px; left: 1rem;
  background: var(--c-black); color: #fff;
  padding: .5rem 1rem; font-size: .8rem;
  z-index: 9999; text-decoration: none;
}
.skip-link:focus { top: 1rem; }

/* ── 4. Bootstrap overrides ────────────────────────────────────── */
.btn, .btn:focus { border-radius: 0 !important; box-shadow: none !important; }
.btn { font-size: .85rem; letter-spacing: .04em; padding: .45rem 1.2rem; font-weight: 500; }

.btn-dark       { background: var(--c-black); border-color: var(--c-black); color: #fff; }
.btn-dark:hover { background: var(--c-white); border-color: var(--c-black); color: var(--c-black); }
.btn-dark:focus-visible { outline: 2px solid var(--c-black); outline-offset: 2px; }

.btn-outline-dark       { border-color: var(--c-black); color: var(--c-black); background: transparent; }
.btn-outline-dark:hover { background: var(--c-black); color: var(--c-white); border-color: var(--c-black); }

.form-control { border-radius: 0 !important; }
.form-control:focus { box-shadow: none !important; border-color: var(--c-black) !important; }

.card { border-radius: 0 !important; }

/* ── 5. Header ─────────────────────────────────────────────────── */
.site-header {
  position: sticky; top: 0; z-index: 200;
  background: var(--c-white);
  border-bottom: var(--border);
}
.site-header--minimal {
  border-bottom: none;
}
.site-header--note-only {
  border-bottom: var(--border);
}
.site-header__note {
  max-width: 28rem;
  margin-left: auto;
  margin-right: auto;
}
body.home-landing .site-header--minimal {
  padding-bottom: 0;
}
.logo {
  font-family: var(--f-serif);
  font-size: 1.25rem;
  font-weight: normal;
  letter-spacing: .08em;
  text-transform: uppercase;
  text-decoration: none;
  color: var(--c-black);
  white-space: nowrap;
  flex-shrink: 0;
}
.logo.logo--image {
  text-transform: none;
  letter-spacing: normal;
  font-family: var(--f-sans);
  font-size: 1rem;
  white-space: normal;
  display: inline-flex;
  align-items: center;
  gap: .65rem;
  max-width: 100%;
}
.site-logo--header {
  display: block;
  max-height: 42px;
  width: auto;
  height: auto;
}
.site-logo--hero {
  display: block;
  max-height: clamp(2.25rem, 7vw, 3.25rem);
  width: auto;
  height: auto;
}
.site-logo__wordmark {
  font-family: var(--f-serif);
  font-size: clamp(1rem, 2.8vw, 1.45rem);
  font-weight: normal;
  letter-spacing: .06em;
  text-transform: uppercase;
  color: var(--c-black);
}
.google-hero__title .logo--image {
  justify-content: center;
}
.hero h1:has(.logo--image) {
  line-height: 1.2;
}
.search-form .form-control {
  min-width: 0;
  background: var(--c-off-white);
  border-color: var(--c-gray-5);
  font-size: .875rem;
}
.search-form--header {
  width: 100%;
  max-width: 22rem;
  min-width: 0;
}
@media (min-width: 768px) {
  .search-form--header { flex: 0 1 22rem; }
}

/* ── 6. Hero ───────────────────────────────────────────────────── */
.hero {
  padding: 3.5rem 0 3rem;
  border-bottom: var(--border);
  margin-bottom: 3rem;
}
.hero h1 {
  font-family: var(--f-serif);
  font-weight: normal;
  font-size: clamp(2rem, 5vw, 3.2rem);
  line-height: 1.18;
  letter-spacing: -.01em;
  margin-bottom: .65rem;
}
.hero .lead {
  font-size: 1.05rem;
  color: var(--c-gray-2);
  max-width: 38rem;
  margin: 0;
}

/* ── 5b. Google-style home search ─────────────────────────────── */
.google-hero {
  text-align: center;
  padding: 2.5rem 0 3rem;
  margin-bottom: 2.5rem;
  border-bottom: var(--border);
}
.google-hero__title {
  font-family: var(--f-serif);
  font-weight: normal;
  font-size: clamp(2rem, 6vw, 3rem);
  letter-spacing: -.02em;
  margin: 0 0 .75rem;
}
.google-hero__lead {
  font-size: 1rem;
  color: var(--c-gray-2);
  max-width: 32rem;
  margin: 0 auto 2rem;
  line-height: 1.55;
}
.google-hero__form {
  max-width: 36rem;
  margin: 0 auto;
}
.google-hero__bar {
  border: 1px solid var(--c-gray-5);
  border-radius: 999px;
  overflow: hidden;
  background: var(--c-white);
  box-shadow: 0 2px 10px rgba(0,0,0,.07);
  flex-wrap: nowrap !important;
}
.google-hero__bar > .form-control {
  flex: 1 1 auto;
  min-width: 0;
}
.google-hero__input {
  border: none !important;
  border-radius: 0 !important;
  padding: .8rem 1.15rem;
  font-size: 1rem;
  background: transparent;
}
.google-hero__input:focus {
  box-shadow: none !important;
  z-index: 3;
}
.google-hero__submit {
  flex-shrink: 0;
  padding-left: 1.15rem;
  padding-right: 1.15rem;
  border: none !important;
  border-left: 1px solid var(--c-gray-5) !important;
  border-radius: 0 !important;
  white-space: nowrap;
}
@media (max-width: 380px) {
  .google-hero__submit { padding-left: .75rem; padding-right: .75rem; font-size: .8rem; }
}

/* ── 7. Section labels ─────────────────────────────────────────── */
.section-label {
  font-size: .74rem;
  font-weight: 700;
  letter-spacing: .2em;
  text-transform: uppercase;
  color: var(--c-gray-2);
  margin-bottom: 1.35rem;
  padding: .35rem 0 .35rem .85rem;
  border-left: 3px solid var(--c-black);
  border-bottom: none;
}

/* ── 8. Recipe cards ───────────────────────────────────────────── */
.recipe-card {
  border: var(--border) !important;
  background: var(--c-white);
  transition: border-color var(--ease), box-shadow var(--ease), transform var(--ease);
  overflow: hidden;
}
.recipe-card:hover {
  border-color: var(--c-gray-2) !important;
  box-shadow: 0 6px 24px rgba(0,0,0,.08);
  transform: translateY(-2px);
}

.recipe-card__img {
  display: block;
  overflow: hidden;
  background: var(--c-gray-6);
}
.recipe-card__img img {
  width: 100%; height: 100%;
  object-fit: cover;
  transition: transform 380ms ease;
}
.recipe-card:hover .recipe-card__img img { transform: scale(1.04); }

.recipe-card__placeholder {
  display: flex; align-items: center; justify-content: center;
  background: var(--c-gray-6);
  color: var(--c-gray-4);
  font-size: .68rem; letter-spacing: .1em; text-transform: uppercase;
  text-decoration: none;
}

.card-body { padding: 1rem 1rem .9rem; }
.card-title { font-size: .92rem; font-weight: 600; line-height: 1.35; margin-bottom: .35rem; }
.card-title a { text-decoration: none; }
.card-title a:hover { text-decoration: underline; text-underline-offset: 2px; }
.card-text { font-size: .8rem; line-height: 1.5; color: var(--c-gray-2); }

.recipe-card__title {
  font-family: var(--f-serif);
  font-size: 1.02rem;
  font-weight: 600;
  line-height: 1.3;
  letter-spacing: -.01em;
}
.recipe-card__excerpt,
.recipe-card__intro {
  display: -webkit-box;
  -webkit-line-clamp: 4;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.recipe-card__meta {
  color: var(--c-gray-2);
  row-gap: .35rem;
}
.recipe-card__chip {
  display: inline-flex;
  align-items: center;
  gap: .2rem;
  white-space: nowrap;
}
.recipe-ui-icon {
  display: inline-block;
  flex-shrink: 0;
  vertical-align: middle;
  color: var(--c-gray-2);
}
.recipe-card__chip .recipe-ui-icon {
  color: var(--c-gray-3);
}
.recipe-card__meta-num {
  font-weight: 600;
  color: var(--c-ink);
}
.recipe-card__meta-lbl {
  font-size: .72rem;
  text-transform: uppercase;
  letter-spacing: .06em;
  color: var(--c-gray-3);
  margin-left: .1rem;
}
.search-suggest a { font-weight: 500; }
.recipe-card__cta {
  letter-spacing: .04em;
  font-weight: 500;
  color: var(--c-gray-3);
}
.recipe-card:hover .recipe-card__cta {
  color: var(--c-black);
}

/* ── 9. Search results header ──────────────────────────────────── */
.results-heading {
  font-family: var(--f-serif);
  font-weight: normal;
  font-size: 1.5rem;
  margin-bottom: 1.5rem;
  padding-bottom: .75rem;
  border-bottom: var(--border);
}
.results-count {
  font-size: .78rem;
  color: var(--c-gray-3);
  letter-spacing: .04em;
  margin-bottom: 1.5rem;
}

/* ── 10. Pagination ────────────────────────────────────────────── */
.pagination-bar {
  display: flex; align-items: center;
  flex-wrap: wrap; gap: .4rem;
  margin-top: 2.5rem; padding-top: 1.5rem;
  border-top: var(--border);
}
.pagination-info { font-size: .8rem; color: var(--c-gray-3); margin: 0 .5rem; }

/* ── 11. Single recipe ─────────────────────────────────────────── */
.recipe-single__breadcrumb {
  font-size: .8rem; color: var(--c-gray-3);
  margin-bottom: 1.25rem;
  display: flex; align-items: center; gap: .4rem;
}
.recipe-single__breadcrumb a { text-decoration: none; color: var(--c-gray-3); }
.recipe-single__breadcrumb a:hover { color: var(--c-black); }
.recipe-single__breadcrumb::after { content: ''; }

.recipe-single__title {
  font-family: var(--f-serif);
  font-weight: normal;
  font-size: clamp(1.6rem, 4vw, 2.4rem);
  line-height: 1.22; letter-spacing: -.01em;
  margin-bottom: .4rem;
}
.recipe-single__date { font-size: .8rem; color: var(--c-gray-3); }

.recipe-single__hero {
  border: var(--border);
  overflow: hidden;
  margin-bottom: 2rem;
}
.recipe-single__hero img { width: 100%; height: 100%; object-fit: cover; }

/* ── 12. Recipe content (WP output) ───────────────────────────── */
.recipe-content {
  max-width: 46rem;
  font-size: 1.02rem;
}
.recipe-content h2, .recipe-content h3 {
  font-family: var(--f-serif);
  font-weight: normal;
  margin-top: 2rem; margin-bottom: .5rem;
}
.recipe-content h2 { font-size: 1.45rem; }
.recipe-content h3 { font-size: 1.15rem; }
.recipe-content p  { margin-bottom: 1rem; }
.recipe-content ul, .recipe-content ol { padding-left: 1.5rem; margin-bottom: 1rem; }
.recipe-content li { margin-bottom: .3rem; }
.recipe-content img { max-width: 100%; height: auto; border: var(--border); }
.recipe-content a { text-decoration: underline; text-underline-offset: 2px; }
.recipe-content a:hover { color: var(--c-gray-1); }

/* ── 13. Ficha de receta (salida app: .recipe-ficha-*; .wprm-* = alias por compatibilidad) ─ */
.recipe-ficha,
.wprm-recipe-container {
  border: var(--border);
  border-left: 3px solid var(--c-black);
  padding: 1.5rem 1.75rem;
  margin: 2rem 0;
  background: var(--c-off-white);
}
.wprm-recipe-name {
  font-family: var(--f-serif);
  font-weight: normal;
  font-size: 1.4rem;
  margin-bottom: .75rem;
}
.wprm-recipe-summary { font-size: .95rem; color: var(--c-gray-2); margin-bottom: 1.25rem; }

.recipe-ficha-meta-columns,
.wprm-recipe-block-container-columns { display: flex; flex-wrap: wrap; gap: .75rem 1.5rem; margin-bottom: 1.5rem; }
.recipe-ficha-meta-col,
.wprm-recipe-block-container-column { flex: 1; min-width: 7rem; }
.recipe-ficha-meta-label,
.wprm-recipe-block-container-column-label {
  display: flex; align-items: center; gap: .3rem; flex-wrap: wrap;
  font-size: .62rem; font-weight: 700;
  letter-spacing: .16em; text-transform: uppercase;
  color: var(--c-gray-3); margin-bottom: .1rem;
}
.recipe-ficha-meta-label .recipe-ui-icon,
.wprm-recipe-block-container-column-label .recipe-ui-icon {
  color: var(--c-gray-3);
}
.recipe-ficha-meta-value,
.wprm-recipe-block-container-column-value { font-size: 1rem; font-weight: 600; }

.recipe-ficha-ingredients,
.wprm-recipe-ingredient-container { list-style: none; padding: 0; margin: .5rem 0 1.5rem; }
.recipe-ficha-ingredients li,
.wprm-recipe-ingredient-container li {
  display: flex; align-items: baseline; gap: .35rem;
  padding: .32rem 0; border-bottom: 1px solid var(--c-gray-6);
}
.recipe-ficha-ingredients li:last-child,
.wprm-recipe-ingredient-container li:last-child { border-bottom: none; }
.recipe-ficha-ingredient-amount,
.recipe-ficha-ingredient-unit,
.wprm-recipe-ingredient-amount,
.wprm-recipe-ingredient-unit { font-weight: 600; flex-shrink: 0; }

.recipe-ficha-instruction-group,
.wprm-recipe-instruction-group-name {
  font-family: var(--f-serif);
  font-size: 1.05rem; font-weight: normal;
  margin: 1.25rem 0 .5rem;
}
.recipe-ficha-instruction,
.wprm-recipe-instruction { margin-bottom: 1rem; }
.recipe-ficha-instruction-text,
.wprm-recipe-instruction-text { margin: 0; }

.recipe-ficha-nutrition,
.wprm-nutrition-label-container { font-size: .85rem; color: var(--c-gray-2); margin-top: 1rem; }
.recipe-ficha-nutrition-header,
.wprm-nutrition-label-header { font-weight: 700; font-size: .75rem; letter-spacing: .08em; text-transform: uppercase; }
.recipe-ficha-nutrition-row,
.wprm-recipe-block-with-label { margin-bottom: .25rem; }

/* Rating (contenido incrustado / WP) */
.wprm-recipe-rating { color: var(--c-gray-3); font-size: .85rem; }
.wprm-rating-star-full::before { content: '★'; color: var(--c-gray-2); }
.wprm-rating-star-empty::before { content: '☆'; }

/* Jump-to buttons (HTML del blog si incrusta shortcodes WPRM) */
.wprm-jump-to-recipe-shortcode-wrap,
.wprm-print-recipe-shortcode-wrap {
  display: inline-block; margin: 0 .3rem .75rem 0;
}
.wprm-jump-to-recipe-shortcode-wrap a,
.wprm-print-recipe-shortcode-wrap a {
  display: inline-block;
  border: var(--border);
  padding: .3rem .9rem;
  font-size: .8rem;
  text-decoration: none;
  transition: background var(--ease), color var(--ease);
}
.wprm-jump-to-recipe-shortcode-wrap a:hover,
.wprm-print-recipe-shortcode-wrap a:hover {
  background: var(--c-black); color: var(--c-white);
}

/* ── 14. App alert ─────────────────────────────────────────────── */
.app-alert {
  border: var(--border);
  border-left: 3px solid var(--c-black);
  padding: 1rem 1.25rem;
  background: var(--c-off-white);
  font-size: .88rem; line-height: 1.55;
}
.app-alert code {
  background: var(--c-gray-5);
  padding: .1em .35em;
  font-size: .85em;
}

/* ── 15. Footer ────────────────────────────────────────────────── */
.site-footer {
  font-size: .75rem;
  color: var(--c-gray-4);
  letter-spacing: .02em;
}
.site-footer a { color: var(--c-gray-4); text-decoration: none; }
.site-footer a:hover { color: var(--c-ink); }
.site-footer__copy { max-width: 100%; min-width: 0; }
.site-footer__extra { color: var(--c-gray-3); line-height: 1.55; }
.site-footer__extra a {
  text-decoration: underline;
  text-underline-offset: 2px;
  color: inherit;
}
.site-footer__extra a:hover { color: var(--c-ink); }
.site-footer__logo {
  display: block;
  max-height: 40px;
  width: auto;
  height: auto;
}
.site-footer__logo-link { line-height: 0; }
.site-footer__copyright { color: var(--c-gray-4); max-width: 42rem; }
.site-footer__rich { line-height: 1.55; }
.site-footer__rich a { color: inherit; text-decoration: underline; text-underline-offset: 2px; }
.site-footer__rich a:hover { color: var(--c-ink); }
.site-footer__rich img {
  display: inline-block;
  vertical-align: middle;
  margin: .35rem 0;
  max-width: 88px;
  height: auto;
}
.site-footer__copyright-plain { color: var(--c-gray-4); }
.site-footer__nav a { text-decoration: none; }
.site-footer__nav a:hover { text-decoration: underline; text-underline-offset: 2px; color: var(--c-ink); }

/* ── 16. Browse (taxonomías) ───────────────────────────────────── */
.browse-clouds__toolbar .btn {
  font-weight: 500;
  letter-spacing: .02em;
}
.browse-cloud-panel {
  margin-top: .35rem;
  padding: 1rem 1rem 1.1rem;
  border: 1px solid var(--c-gray-6);
  border-radius: 6px;
  background: var(--c-off-white);
}
.browse-cloud {
  display: flex;
  flex-wrap: wrap;
  gap: .55rem .85rem;
  align-items: center;
  justify-content: center;
  line-height: 1.5;
  text-align: center;
  row-gap: .55rem;
}
.browse-cloud__link {
  display: inline-block;
  font-weight: 500;
  text-decoration: none;
  color: var(--c-gray-1);
  padding: .2rem .55rem;
  margin: 0;
  border-radius: 4px;
  border: 1px solid var(--c-gray-6);
  background: #fff;
  transition: color .15s ease, border-color .15s ease, background .15s ease;
}
.browse-cloud__link:hover {
  color: var(--c-black);
  border-color: var(--c-gray-4);
  background: #fff;
}
.browse-term-list { margin: 0; padding: 0; }
.browse-term-list__item {
  margin-bottom: .5rem;
  padding-bottom: .5rem;
  border-bottom: 1px solid var(--c-gray-6);
}
.browse-term-list__item:last-child { border-bottom: none; margin-bottom: 0; padding-bottom: 0; }
.browse-term-list a { font-weight: 500; text-decoration: none; }
.browse-term-list a:hover { text-decoration: underline; text-underline-offset: 2px; }
.browse-landing { margin-top: .25rem; }
.recipe-related__title {
  font-family: var(--f-serif);
  font-weight: normal;
  margin-bottom: 1rem;
}
.app-adsense-slot { min-height: 120px; }

/* ── 17. Utilities ─────────────────────────────────────────────── */
.letter-space    { letter-spacing: .05em; }
.letter-space-sm { letter-spacing: .16em; }
.font-serif      { font-family: var(--f-serif); }
.flex-grow-1     { flex-grow: 1; }
