/*
 * Theme extras — overrides + components added on top of the source styles.css
 * Keep narrow & purposeful. Anything visual that already exists in styles.css
 * does NOT need to be duplicated here.
 */

/* ─── HERO (home + page heroes) ───────────────────────────────────── */
.hero { padding: 5rem 0 4rem; position:relative; }
.hero .container { max-width: 1200px; margin: 0 auto; padding: 0 1.5rem; }
.hero-badge { display:inline-block; padding:.35rem .8rem; border-radius:100px; background:rgba(149,213,178,.12); color:#95D5B2; font-size:.78rem; font-weight:600; letter-spacing:.03em; margin-bottom:1.25rem; border:1px solid rgba(149,213,178,.25); }
.hero-title { font-size: clamp(2rem, 4.5vw, 3.4rem); line-height:1.1; font-weight:800; margin:0 0 1rem; letter-spacing:-.02em; }
.hero-intro, .hero-subtitle { color:#cdd6e0; font-size:1.05rem; line-height:1.6; max-width:60ch; margin:0 0 1.5rem; }
.hero-cta { display:flex; gap:.75rem; flex-wrap:wrap; margin-bottom:2rem; }
.btn-primary, .btn-secondary { display:inline-flex; align-items:center; gap:.4rem; padding:.7rem 1.2rem; border-radius:100px; font-weight:600; text-decoration:none; transition: transform .2s ease, background .2s ease; border:1px solid transparent; }
.btn-primary  { background: linear-gradient(135deg,#2D6A4F,#52b788); color:#fff; }
.btn-primary:hover  { transform: translateY(-2px); }
.btn-secondary { background: transparent; color:#fff; border-color:#1d2731; }
.btn-secondary:hover { background:#1d2731; }
.hero-stats { display:flex; gap:2rem; flex-wrap:wrap; margin-top:1rem; }
.hero-stats .stat { display:flex; flex-direction:column; }
.hero-stats .stat strong { font-size:1.5rem; font-weight:800; color:#fff; }
.hero-stats .stat span { color:#9aa4ad; font-size:.85rem; }

.hero-split .hero-grid { display:grid; grid-template-columns: 1.1fr 1fr; gap:3rem; align-items:center; }
.hero-map-preview { position:relative; border-radius:18px; overflow:hidden; }
.hero-map-preview #map-home { z-index:1; }
.hero-map-overlay-cta { position:absolute; left:50%; bottom:1rem; transform: translateX(-50%); padding:.5rem 1rem; background:rgba(0,0,0,.85); color:#fff; border-radius:100px; text-decoration:none; font-size:.85rem; z-index:2; backdrop-filter: blur(8px); }
.hero-map-overlay-cta:hover { background:rgba(45,106,79,.9); }

@media (max-width: 900px) {
  .hero-split .hero-grid { grid-template-columns: 1fr; }
  .hero-map-preview #map-home { height: 280px !important; }
  .hero-stats { gap: 1.2rem; }
}

/* Category hero / barrio hero / blog hero / others use simpler vertical layout */
/* superseded — kept for clarity; effective rules are at the bottom with !important */
.hero-category h1, .hero-page h1, .hero-blog h1, .hero-explore h1, .hero-municipio h1, .hero-map h1, .barrio-hero h1, .shop-hero h1 { font-size: clamp(1.7rem, 3.8vw, 2.6rem); line-height:1.15; margin:.5rem 0 .8rem; }

/* Breadcrumb */
.breadcrumb { color:#9aa4ad; font-size:.85rem; margin-bottom:.8rem; }
.breadcrumb a { color:#95D5B2; text-decoration:none; }
.breadcrumb a:hover { text-decoration:underline; }

/* Reveal-on-scroll defaults */
.reveal-on-scroll { opacity: 0; transform: translateY(20px); transition: opacity .6s ease, transform .6s ease; }
.reveal-on-scroll.revealed { opacity: 1; transform: none; }
/* Safety: if JS doesn't load, reveal anyway after 3s */
@keyframes wib-fail-safe-reveal { to { opacity: 1; transform: none; } }
.reveal-on-scroll:not(.revealed) { animation: wib-fail-safe-reveal 0s 3s forwards; }

/* Shop card */
.shop-card { background:#0e151c; border:1px solid #1d2731; border-radius:14px; overflow:hidden; transition: transform .25s ease, border-color .25s ease; }
.shop-card:hover { transform: translateY(-4px); border-color:#2D6A4F; }
.shop-card-link { color:inherit; text-decoration:none; display:block; }
.shop-card-image { position:relative; }
.shop-card-image .badge { position:absolute; top:8px; padding:3px 8px; border-radius:6px; font-size:.7rem; font-weight:700; color:#fff; }
.shop-card-image .badge-verified { left:8px; background:linear-gradient(135deg,#2D6A4F,#52b788); }
.shop-card-image .badge-cat      { right:8px; background:rgba(0,0,0,.6); backdrop-filter:blur(6px); }
.shop-card-body { padding: 1rem; }
.shop-card-title { font-size:1.05rem; margin:0 0 .25rem; }
.shop-card-district { color:#9aa4ad; font-size:.85rem; margin:0 0 .5rem; }
.shop-card-excerpt { font-size:.85rem; color:#cdd6e0; line-height:1.45; min-height:3em; }
.shop-card-meta { display:flex; justify-content:space-between; align-items:center; margin-top:.6rem; font-size:.85rem; }
.shop-card-rating { color:#FFC107; }
.shop-card-price { color:#9aa4ad; }
.shops-grid { display:grid; grid-template-columns: repeat(auto-fill,minmax(280px,1fr)); gap:1.25rem; }

/* Stars */
.stars { display:inline-flex; gap:1px; }
.stars .star { color:#FFC107; }
.stars .star.empty { color:#3a4150; }

/* Categories grid (home) */
.categories-grid { display:grid; grid-template-columns: repeat(auto-fit,minmax(220px,1fr)); gap:1.25rem; margin:3rem auto; }
.cat-card { border:1px solid #1d2731; border-radius:16px; background:linear-gradient(160deg, rgba(255,255,255,.02), rgba(255,255,255,0)); overflow:hidden; transition: transform .25s ease; }
.cat-card:hover { transform: translateY(-4px); border-color: var(--c, #2D6A4F); }
.cat-card a { display:block; padding: 1.25rem 1.5rem; color:inherit; text-decoration:none; }
.cat-card h3 { margin:.4rem 0 .25rem; }
.cat-card .cat-emoji { font-size: 2rem; }
.cat-card p { color:#9aa4ad; margin:0; }

/* Barrios cards (home) */
.barrios-cards { display:grid; grid-template-columns: repeat(auto-fit,minmax(220px,1fr)); gap:1rem; }
.barrio-card { display:block; padding:1.25rem; border:1px solid #1d2731; border-radius:14px; color:inherit; text-decoration:none; transition: transform .25s ease; }
.barrio-card:hover { transform: translateY(-4px); border-color:#2D6A4F; }
.barrio-emoji { font-size:1.5rem; }
.barrio-card p { color:#9aa4ad; font-size:.85rem; margin-top:.4rem; }

/* Section header */
.section-header { display:flex; align-items:flex-end; justify-content:space-between; flex-wrap:wrap; gap:.5rem; margin-bottom:1.5rem; }
.section-header h2 { margin:0; }
.link-more { color:#52b788; text-decoration:none; }

/* Blog grid */
.blog-grid { display:grid; grid-template-columns: repeat(auto-fill,minmax(280px,1fr)); gap:1.25rem; }
.blog-card { background:#0e151c; border:1px solid #1d2731; border-radius:14px; overflow:hidden; }
.blog-card a { color:inherit; text-decoration:none; display:block; }
.blog-card-image { background-position:center; }
.blog-card-body { padding:1rem; }
.blog-card-body small { color:#9aa4ad; }
.blog-card-body h3 { margin:.4rem 0 .5rem; font-size:1.05rem; }
.blog-card-body p { color:#cdd6e0; font-size:.9rem; }
.cat-pills { display:flex; gap:.4rem; flex-wrap:wrap; margin-top:1rem; }
.cat-pill { padding:.3rem .8rem; border:1px solid #2D6A4F; border-radius:100px; color:#cdd6e0; text-decoration:none; font-size:.85rem; }
.cat-pill.active, .cat-pill:hover { background:#2D6A4F; color:#fff; }

/* Archive shop layout */
.archive-shop .archive-body { display:grid; grid-template-columns: 260px 1fr; gap:2rem; margin:2rem auto; }
.filters-sidebar { border:1px solid #1d2731; border-radius:14px; padding:1rem; height: fit-content; }
.filters-sidebar h3 { margin-top:0; font-size:.95rem; }
.filters-sidebar select { width:100%; padding:.5rem; background:#0e151c; color:#fff; border:1px solid #1d2731; border-radius:8px; }
.mobile-filters-toggle { display:none; width:100%; padding:.6rem; background:#2D6A4F; color:#fff; border:0; border-radius:10px; cursor:pointer; }
@media (max-width: 900px) {
  .archive-shop .archive-body { grid-template-columns: 1fr; }
  .filters-sidebar { position:fixed; left:0; top:0; bottom:0; width:280px; max-width:85vw; transform: translateX(-100%); transition: transform .3s ease; background:#0a1117; z-index: 999; padding:5rem 1rem 1rem; overflow-y:auto; border-radius:0; }
  body.filters-open .filters-sidebar { transform: translateX(0); }
  body.filters-open::after { content:''; position:fixed; inset:0; background:rgba(0,0,0,.6); z-index:998; }
  .mobile-filters-toggle { display:block; }
}

/* Single shop layout */
.single-shop { padding-bottom: 4rem; }
.shop-grid { display:grid; grid-template-columns: minmax(0,1fr) 320px; gap:2rem; margin: 2rem auto; }
/* Gallery: flex auto-wrap, max 3-per-row at full width, but each img keeps a sensible size when fewer */
.shop-gallery { display:flex; flex-wrap:wrap; gap:.6rem; }
.shop-gallery img { flex: 1 1 280px; max-width: calc(33.333% - .4rem); height:220px; object-fit:cover; border-radius:10px; }
.shop-gallery img:only-child { max-width: 100%; height: 360px; }
.shop-gallery img:first-child:nth-last-child(2),
.shop-gallery img:first-child:nth-last-child(2) ~ img { max-width: calc(50% - .3rem); height: 280px; }
@media (max-width: 700px) {
  .shop-gallery img,
  .shop-gallery img:only-child,
  .shop-gallery img:first-child:nth-last-child(2),
  .shop-gallery img:first-child:nth-last-child(2) ~ img { max-width: 100%; height: 220px; }
}
.shop-main h2 { margin-top:2rem; }
.scores-grid .score-row { display:grid; grid-template-columns: 140px 1fr 40px; gap:1rem; align-items:center; margin: .4rem 0; }
.score-bar { height:8px; background:#1d2731; border-radius:4px; overflow:hidden; }
.score-bar span { display:block; height:100%; background: linear-gradient(90deg,#2D6A4F,#52b788); }
.products-list { list-style:none; padding:0; }
.products-list li { padding:1rem; border:1px solid #1d2731; border-radius:10px; margin-bottom:.6rem; }
.products-list h3 small { font-weight:400; color:#9aa4ad; margin-left:.4rem; }
.review { border-left:3px solid #2D6A4F; padding:.6rem 1rem; margin: .8rem 0; background: rgba(45,106,79,.04); border-radius:0 8px 8px 0; }
.review header { font-size:.85rem; color:#9aa4ad; }
.faq-item { padding:.6rem 0; border-bottom:1px solid #1d2731; }
.faq-item summary { cursor:pointer; font-weight:600; }
.shop-sidebar .card { background:#0e151c; border:1px solid #1d2731; border-radius:14px; padding:1rem; margin-bottom:1rem; }
.shop-sidebar dl dt { font-weight:600; color:#9aa4ad; font-size:.8rem; margin-top:.6rem; }
.shop-sidebar dl dd { margin: 0 0 .4rem; }
@media (max-width: 900px) { .shop-grid { grid-template-columns: 1fr; } }

/* Single barrio */
.barrio-grid { display:grid; grid-template-columns: minmax(0,1fr) 280px; gap:2rem; margin: 2rem auto; }
@media (max-width: 900px) { .barrio-grid { grid-template-columns: 1fr; } }
.cat-counts { display:flex; gap:.5rem; flex-wrap:wrap; margin: .5rem 0 1.5rem; }
.cat-counts a { padding:.5rem .9rem; border:1px solid #1d2731; border-radius:100px; color:inherit; text-decoration:none; font-size:.85rem; }
.cat-counts a:hover { border-color:#2D6A4F; }
.highlights-list { list-style:none; padding:0; }
.highlights-list li { padding:.4rem 0; }

/* Explore page */
.comm-grid { display:grid; grid-template-columns: repeat(auto-fit,minmax(220px,1fr)); gap:1rem; }
.comm-card { display:flex; flex-direction:column; padding:1rem 1.25rem; border:1px solid #1d2731; border-radius:14px; color:inherit; text-decoration:none; transition: transform .25s ease, border-color .25s ease; }
.comm-card:hover { transform: translateY(-3px); border-color:#2D6A4F; }
.comm-card small { color:#9aa4ad; }

/* Related pages */
.related-pages-grid { display:grid; grid-template-columns: repeat(auto-fill,minmax(200px,1fr)); gap:1rem; }
.related-page-card { padding:1.25rem; border:1px solid #1d2731; border-radius:14px; color:inherit; text-decoration:none; display:flex; flex-direction:column; gap:.4rem; transition: transform .25s ease; }
.related-page-card:hover { transform: translateY(-3px); border-color:#2D6A4F; }
.related-icon { font-size:1.5rem; }
.related-tag { color:#9aa4ad; font-size:.75rem; text-transform:uppercase; letter-spacing:.04em; }

/* Language switcher styling */
.wib-lang-switcher { font-size:.85rem; }
.wib-lang-switcher--dropdown { position:relative; }
.wib-lang-switcher--dropdown .wib-lang-current { display:inline-flex; gap:.4rem; align-items:center; background:transparent; border:1px solid #1d2731; color:inherit; padding:.4rem .7rem; border-radius:100px; cursor:pointer; }
.wib-lang-switcher--dropdown .wib-lang-list { display:none; position:absolute; right:0; top:100%; margin-top:.4rem; background:#0a1117; border:1px solid #1d2731; border-radius:12px; padding:.4rem; list-style:none; min-width:160px; z-index:100; }
.wib-lang-switcher--dropdown[data-state="open"] .wib-lang-list { display:block; }
.wib-lang-switcher--dropdown .wib-lang-list a { display:flex; gap:.5rem; align-items:center; padding:.4rem .6rem; color:inherit; text-decoration:none; border-radius:8px; }
.wib-lang-switcher--dropdown .wib-lang-list a:hover { background:#1d2731; }
.wib-lang-switcher--inline { display:flex; gap:.4rem; flex-wrap:wrap; list-style:none; padding:0; margin:.5rem 0 0; }
.wib-lang-switcher--inline li a { display:flex; gap:.3rem; align-items:center; padding:.25rem .6rem; border:1px solid #1d2731; border-radius:100px; color:inherit; text-decoration:none; font-size:.8rem; }
.wib-lang-switcher--inline li.is-active a { background:#2D6A4F; border-color:#2D6A4F; color:#fff; }

/* Container helper (theme-wide) */
.container { max-width: 1200px; margin: 0 auto; padding: 0 1.5rem; }

/* Pagination */
.pagination { display:flex; justify-content:center; gap:.4rem; margin:2rem 0; }
.pagination .page-numbers { display:inline-flex; align-items:center; justify-content:center; min-width:36px; height:36px; border:1px solid #1d2731; border-radius:8px; color:inherit; text-decoration:none; padding:0 .6rem; }
.pagination .page-numbers.current, .pagination .page-numbers:hover { background:#2D6A4F; border-color:#2D6A4F; color:#fff; }

/* Shop info card dl */
.shop-info-card dl { margin:0; }
.shop-info-card dl dt { font-size:.78rem; color:#9aa4ad; text-transform:uppercase; letter-spacing:.05em; margin-top:.8rem; }
.shop-info-card dl dd { margin:.2rem 0 0; }
.shop-related-card ul, .related-shops { list-style:none; padding:0; margin:0; }
.shop-related-card a, .related-shops a { color:#95D5B2; text-decoration:none; }
.shop-related-card li, .related-shops li { padding:.4rem 0; border-bottom:1px solid #1d2731; }

/* Shop hero badges */
.shop-hero-badges { display:flex; gap:.5rem; flex-wrap:wrap; margin-bottom:.8rem; }
.shop-hero-badges .badge { padding:.25rem .7rem; border-radius:100px; font-size:.78rem; font-weight:600; }
.shop-hero-badges .badge-verified { background: linear-gradient(135deg,#2D6A4F,#52b788); }
.shop-hero-badges .badge-cat      { background: rgba(0,0,0,.5); border:1px solid #fff3; }
.shop-hero-badges .badge-price    { background: rgba(255,255,255,.1); }

/* /zona/map — full-viewport map */
.page-zona-map .hero-map { padding: 1.5rem 0 1rem; }
.page-zona-map .map-container { height: calc(100vh - 220px); min-height: 480px; position:relative; }
.page-zona-map .map-container #map-full { position:absolute; inset:0; z-index:1; }
.page-zona-map .map-filters { z-index: 1000; display:flex; flex-direction:column; gap:.25rem; }
.page-zona-map .map-filters label { font-size:.85rem; cursor:pointer; }

/* Hero padding tweak for non-home pages — overrides source styles.css min-height */
.hero-category, .hero-page, .hero-post, .hero-blog, .hero-contact, .hero-explore, .hero-municipio, .hero-map, .barrio-hero, .shop-hero {
  padding: 2.5rem 0 2rem !important;
  min-height: 0 !important;
  height: auto !important;
  display: block !important;
}
.hero-category .container, .hero-page .container, .hero-post .container, .hero-blog .container,
.hero-contact .container, .hero-explore .container, .hero-municipio .container, .hero-map .container,
.barrio-hero .container, .shop-hero .container { max-width: 1200px; }
/* /zona/map specifically: shrink hero further */
.page-zona-map .hero-map { padding: 1.2rem 0 .8rem !important; }
.page-zona-map .map-container { height: calc(100vh - 220px) !important; min-height: 480px !important; }

/* Mobile drawer — guard against backdrop-filter containing-block issue */
@media (max-width: 820px) {
  body .navbar { backdrop-filter: none !important; }
}
