:root{
  --bq-primary: var(--e-global-color-primary);
  --bq-secondary: var(--e-global-color-secondary);
  --bq-text: var(--e-global-color-text);
  --bq-accent: var(--e-global-color-accent);

  --bq-muted: color-mix(in srgb, var(--bq-text) 70%, transparent);
  --bq-border: color-mix(in srgb, var(--bq-text) 18%, transparent);
  --bq-surface: color-mix(in srgb, var(--bq-text) 7%, transparent);

  --bq-max: 1120px;
}

/* Sin esquinas redondeadas en ningún elemento */
*{
  border-radius: 0 !important;
}

/* =========================
   Layout base
   ========================= */

.bq-wrap{
  max-width: var(--bq-max);
  margin: 0 auto;
  padding: 28px 18px 72px;
  color: var(--bq-text);
}

.bq-wrap--blog{
  max-width: 100%;
  padding: 0;
}

.bq-section{
  max-width: var(--bq-max);
  margin: 0 auto;
  padding: 18px 18px 0;
}

.bq-section:last-of-type{
  padding-bottom: 72px;
}

.bq-sr-only{
  position:absolute;
  width:1px;
  height:1px;
  padding:0;
  margin:-1px;
  overflow:hidden;
  clip:rect(0,0,0,0);
  white-space:nowrap;
  border:0;
}

/* =========================
   HERO (según page-blog.php)
   ========================= */

.bq-hero{
  border: 1px solid var(--bq-border);
  background: var(--bq-surface);
  overflow: hidden;
}

.bq-hero.bq-hero--image{
  width: 100%;
  height: 40vh;
  min-height: 260px;

  margin-top: -90px;
  padding-top: 90px;

  border: 0;
  background-image: url("https://images.unsplash.com/photo-1711725637816-b0755c582c86?q=80&w=1333&auto=format&fit=crop&ixlib=rb-4.1.0&ixid=M3wxMjA3fDB8MHxwaG90by1wYWdlfHx8fGVufDB8fHx8fA%3D%3D");
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;

  position: relative;
  display: flex;
  align-items: flex-end;
}

/* Overlay sin “bloquear” la imagen */
.bq-hero.bq-hero--image::before{
  content: "";
  position: absolute;
  inset: 0;
  background: rgba(0,0,0,.45);
  pointer-events: none;
}

.bq-hero__inner{
  width: 100%;
  max-width: var(--bq-max);
  margin: 0 auto;
  padding: 28px 18px;
  position: relative;
  z-index: 1;
}

.bq-hero__title{
  margin: 0 0 14px;
  font-size: clamp(32px, 4vw, 52px);
  line-height: 1.05;
  color: #ffffff;
}

/* Herramientas dentro del hero */
.bq-tools{
  display: grid;
  grid-template-columns: 1fr 240px auto auto;
  gap: 12px;
  align-items: center;
}

@media (max-width: 860px){
  .bq-tools{ grid-template-columns: 1fr; }
}

.bq-input,
.bq-select{
  width: 100%;
  padding: 12px 12px;
  outline: none;
  border: 1px solid var(--bq-border);
  background: transparent;
  color: var(--bq-text);
}

/* Todo el texto dentro del hero blanco + bordes blancos en inputs/select */
.bq-hero.bq-hero--image .bq-input,
.bq-hero.bq-hero--image .bq-select{
  color: #ffffff;
  border-color: #ffffff;
}

.bq-hero.bq-hero--image .bq-input::placeholder{
  color: rgba(255,255,255,.75);
}

/* Botones */
.bq-btn{
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;

  padding: 12px 18px;
  border: 1px solid var(--bq-border);
  background: transparent;
  color: var(--bq-text);
  text-decoration: none;
  cursor: pointer;
  white-space: nowrap;
}

/* Botón Filtrar: igual que etiquetas (accent) + texto blanco */
.bq-hero.bq-hero--image .bq-btn{
  background: var(--bq-accent);
  border-color: var(--bq-accent);
  color: #ffffff;
}

.bq-hero.bq-hero--image .bq-btn:hover{
  filter: brightness(.92);
}

/* Botón Limpiar (ghost) dentro del hero */
.bq-hero.bq-hero--image .bq-btn--ghost{
  background: transparent;
  border-color: #ffffff;
  color: #ffffff;
}

.bq-hero.bq-hero--image .bq-btn--ghost:hover{
  background: rgba(255,255,255,.10);
}

/* =========================
   Destacado (template-parts/card-featured.php)
   ========================= */

.bq-section--featured{
  margin-top: 36px;
}

.bq-featured{
  display: grid;
  grid-template-columns: 7fr 5fr;
  border: 1px solid var(--bq-border);
  background: transparent;
}

@media (max-width: 920px){
  .bq-featured{ grid-template-columns: 1fr; }
}

.bq-featured__media{
  position: relative;
  display: block;
  text-decoration: none;
  border-right: 1px solid var(--bq-border);
}

@media (max-width: 920px){
  .bq-featured__media{
    border-right: 0;
    border-bottom: 1px solid var(--bq-border);
  }
}

.bq-featured__img{
  width: 100%;
  height: 100%;
  min-height: 420px;
  object-fit: cover;
  display: block;
}

.bq-featured__img--fallback{
  min-height: 420px;
  background: color-mix(in srgb, var(--bq-text) 8%, transparent);
}

.bq-featured__body{
  padding: 30px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 14px;
}

.bq-featured__kicker{
  margin: 0;
  font-size: 12px;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--bq-muted);
}

.bq-featured__title{
  margin: 0;
  font-size: clamp(28px, 2.8vw, 44px);
  line-height: 1.12;
}

.bq-featured__title a{
  color: var(--bq-text);
  text-decoration: none;
}

.bq-featured__title a:hover{
  text-decoration: underline;
}

.bq-featured__excerpt{
  margin: 0;
  color: var(--bq-muted);
  line-height: 1.7;
  font-size: 15px;
  display: -webkit-box;
  -webkit-line-clamp: 4;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* Metadata compartida */
.bq-meta{
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  color: var(--bq-muted);
  font-size: 13px;
}

.bq-meta a{
  color: var(--bq-text);
  text-decoration: none;
}

.bq-meta a:hover{
  text-decoration: underline;
}

.bq-meta__dot{
  opacity: .7;
}

/* =========================
   Grilla + Cards (template-parts/card-post.php)
   ========================= */

.bq-grid{
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  gap: 20px;
  margin-top: 34px;
}

@media (max-width: 1020px){
  .bq-grid{ grid-template-columns: repeat(8, 1fr); }
}
@media (max-width: 680px){
  .bq-grid{ grid-template-columns: repeat(4, 1fr); }
}

.bq-card{
  grid-column: span 4;
  border: 1px solid var(--bq-border);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  min-height: 0;
}

@media (max-width: 1020px){
  .bq-card{ grid-column: span 4; }
}
@media (max-width: 680px){
  .bq-card{ grid-column: span 4; }
}

.bq-card__media{
  position: relative;
  display: block;
  text-decoration: none;
  border-bottom: 1px solid var(--bq-border);
}

.bq-card__img{
  display: block;
  width: 100%;
  height: 200px;
  object-fit: cover;
}

.bq-card__img--fallback{
  height: 200px;
  background: color-mix(in srgb, var(--bq-text) 8%, transparent);
}

/* Etiquetas categoría: fondo accent + texto primary */
.bq-chip{
  position: absolute;
  left: 12px;
  bottom: 12px;

  background: var(--bq-accent);
  border: 1px solid var(--bq-accent);
  color: var(--bq-primary);

  padding: 6px 10px;
  font-size: 12px;
}

.bq-card__body{
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  flex: 1;
}

.bq-card__title{
  margin: 0;
  font-size: 18px;
  line-height: 1.25;
}

.bq-card__title a{
  color: var(--bq-text);
  text-decoration: none;
}

.bq-card__title a:hover{
  text-decoration: underline;
}

.bq-card__excerpt{
  margin: 0;
  color: var(--bq-muted);
  line-height: 1.6;
  font-size: 14px;

  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.bq-card__cta{
  margin-top: 6px;
  color: var(--bq-text);
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 8px;

  border-top: 1px solid var(--bq-border);
  padding-top: 12px;
}

.bq-card__cta:hover{
  opacity: .9;
}

/* =========================
   Paginación
   ========================= */

.bq-pagination{
  margin-top: 34px;
}

.bq-pagination ul{
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.bq-pagination a,
.bq-pagination span{
  display: inline-flex;
  padding: 10px 14px;
  border: 1px solid var(--bq-border);
  text-decoration: none;
  color: var(--bq-text);
  background: transparent;
}

.bq-pagination .current{
  background: var(--bq-accent);
  border-color: var(--bq-accent);
  color: #ffffff;
}

/* =========================
   Empty state
   ========================= */

.bq-empty{
  grid-column: 1 / -1;
  padding: 34px;
  border: 1px solid var(--bq-border);
}

.bq-empty__title{
  margin: 0 0 8px;
}

.bq-empty__text{
  margin: 0;
  color: var(--bq-muted);
}
