/* ===== V05 · PROYECTOS BGSC — usa los tokens de body.bgsc-home (styles.css) ===== */

body.bgsc-home .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;
}

/* ---------- Encabezado (imagen a todo lo ancho) ---------- */
body.bgsc-home .pj-hero {
  position: relative; isolation: isolate; overflow: hidden;
  min-height: clamp(260px, 17vw, 330px);
  display: flex; align-items: center;
  padding: clamp(26px, 2.4vw, 36px) 0;
  background: radial-gradient(60% 90% at 75% 40%, rgba(182,0,255,.28), transparent 70%), var(--bg-2);
}
body.bgsc-home .pj-hero-bg { position: absolute; inset: 0; z-index: -2; width: 100%; height: 100%; object-fit: cover; object-position: 60% 55%; }
body.bgsc-home .pj-hero-shade {
  position: absolute; inset: 0; z-index: -1;
  background:
    linear-gradient(90deg, rgba(10,8,23,.94) 0%, rgba(10,8,23,.78) 26%, rgba(10,8,23,.25) 50%, rgba(10,8,23,0) 66%),
    linear-gradient(180deg, rgba(10,8,23,.2) 0%, rgba(10,8,23,0) 30%, rgba(10,8,23,0) 72%, var(--bg) 100%);
}
body.bgsc-home .pj-hero-in { position: relative; }
body.bgsc-home .pj-hero h1 {
  margin-top: 14px;
  font-size: clamp(2.2rem, 3.7vw, 3.6rem); font-weight: 800; line-height: 1.02; letter-spacing: -.035em;
  text-shadow: 0 2px 22px rgba(0,0,0,.45);
}
body.bgsc-home .pj-t1 { display: block; color: #fff; }
body.bgsc-home .pj-hero h1 em {
  font-style: normal;
  background: linear-gradient(90deg, #a35bff, #c47dff);
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
body.bgsc-home .pj-lead { margin-top: 14px; max-width: 520px; color: #ece8fb; font-size: clamp(.98rem, 1.15vw, 1.1rem); line-height: 1.5; text-shadow: 0 1px 12px rgba(0,0,0,.5); }

/* ---------- Buscador + filtros ---------- */
body.bgsc-home .pj-catalog { padding: 18px 0 30px; }
body.bgsc-home .pj-tools { display: grid; grid-template-columns: minmax(240px, 1.05fr) minmax(0, 3fr); gap: 16px; align-items: center; margin-bottom: 26px; }
body.bgsc-home .pj-search {
  position: relative; display: flex; align-items: center;
  min-height: 50px; border-radius: 10px; border: 1px solid var(--line-2);
  background: rgba(16, 12, 36, .85);
  transition: border-color .2s, box-shadow .2s;
}
body.bgsc-home .pj-search:focus-within { border-color: var(--violet); box-shadow: 0 0 0 3px rgba(164,107,255,.18); }
body.bgsc-home .pj-search .ico { position: absolute; left: 16px; width: 20px; height: 20px; color: #d9d2f2; pointer-events: none; }
body.bgsc-home .pj-search input {
  width: 100%; height: 48px; padding: 0 16px 0 48px;
  background: transparent; border: 0; outline: 0;
  color: var(--text); font: inherit; font-size: .95rem;
}
body.bgsc-home .pj-search input::placeholder { color: var(--dim); }
body.bgsc-home .pj-search input::-webkit-search-cancel-button { filter: invert(.8); }

body.bgsc-home .pj-filters { display: none; }
html.js body.bgsc-home .pj-filters { display: grid; grid-template-columns: repeat(auto-fit, minmax(118px, 1fr)); gap: 12px; }
body.bgsc-home .pj-chip {
  display: flex; align-items: center; justify-content: center; gap: 10px; min-height: 50px; padding: 0 14px;
  border-radius: 10px; border: 1px solid var(--line);
  background: linear-gradient(180deg, rgba(26, 19, 56, .7), rgba(16, 12, 36, .85));
  color: #ece7fc; font-weight: 600; font-size: .9rem; white-space: nowrap;
  transition: border-color .2s, background-color .2s, color .2s;
}
body.bgsc-home .pj-chip .ico { width: 22px; height: 22px; color: var(--violet); }
body.bgsc-home .pj-chip:hover { border-color: var(--line-2); color: #fff; }
body.bgsc-home .pj-chip.is-active { border-color: transparent; background: var(--grad); color: #fff; box-shadow: 0 8px 22px -12px rgba(155,77,255,.9); }
body.bgsc-home .pj-chip.is-active .ico { color: #fff; }

/* ---------- Título ---------- */
body.bgsc-home .pj-head { display: flex; align-items: center; gap: 22px; margin-bottom: 16px; }
body.bgsc-home .pj-head h2 { font-size: clamp(1.5rem, 2.1vw, 2rem); font-weight: 800; white-space: nowrap; }
body.bgsc-home .pj-head h2 span { color: var(--violet); }
body.bgsc-home .pj-head::after { content: ""; flex: 1; height: 1px; background: rgba(167,128,255,.22); order: 1; }
body.bgsc-home .pj-count { order: 2; font-size: .85rem; color: var(--muted); white-space: nowrap; }

/* ---------- Tarjetas ---------- */
body.bgsc-home .pj-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
body.bgsc-home .pj-card {
  position: relative; display: flex; flex-direction: column; overflow: hidden;
  border-radius: 10px; border: 1px solid var(--line);
  background: linear-gradient(180deg, rgba(22, 16, 48, .92), rgba(14, 10, 32, .96));
  transition: border-color .25s, transform .25s var(--ease), box-shadow .25s;
}
body.bgsc-home .pj-card[hidden] { display: none; }
body.bgsc-home .pj-card:hover { border-color: var(--line-2); box-shadow: 0 18px 40px -26px rgba(139,61,255,.7); }

body.bgsc-home .pj-media { position: relative; aspect-ratio: 4.2 / 1; overflow: hidden; background: #120d29; }
body.bgsc-home .pj-media img { width: 100%; height: 100%; object-fit: cover; object-position: 50% 55%; transition: transform .6s var(--ease); }
body.bgsc-home .pj-media::after { content: ""; position: absolute; inset: auto 0 0 0; height: 40%; background: linear-gradient(180deg, rgba(14,10,32,0), rgba(14,10,32,.55)); }
body.bgsc-home .pj-card:hover .pj-media img { transform: scale(1.05); }
body.bgsc-home .pj-concept {
  position: absolute; left: 8px; bottom: 8px; z-index: 1; padding: 3px 8px; border-radius: 5px;
  background: rgba(10,8,23,.7); color: #e7e1fa; font-size: .66rem; font-weight: 600; letter-spacing: .01em;
}
body.bgsc-home .pj-media.is-empty { display: grid; place-items: center; background: radial-gradient(60% 90% at 50% 50%, rgba(182,0,255,.24), transparent 70%), #120d29; }
body.bgsc-home .pj-media-ico { width: 44px; height: 44px; color: var(--violet); opacity: .8; }

body.bgsc-home .pj-body { flex: 1; display: grid; grid-template-columns: auto minmax(0, 1fr) auto; gap: 6px 16px; padding: 14px 16px 16px 18px; }
body.bgsc-home .pj-ico { align-self: center; color: var(--violet); }
body.bgsc-home .pj-ico .ico { width: 40px; height: 40px; stroke-width: 1.5; }
body.bgsc-home .pj-txt { min-width: 0; }
body.bgsc-home .pj-sector { display: block; font-size: .78rem; font-weight: 600; color: var(--violet); }
body.bgsc-home .pj-card h3 { margin-top: 4px; font-size: 1.12rem; font-weight: 700; letter-spacing: -.01em; }
body.bgsc-home .pj-card p { margin-top: 6px; font-size: .8rem; color: #d3cceb; line-height: 1.45; }

body.bgsc-home .pj-side { display: flex; flex-direction: column; align-items: flex-end; justify-content: space-between; gap: 10px; }
body.bgsc-home .pj-estado {
  display: inline-block; padding: 5px 12px; border-radius: 999px; white-space: nowrap;
  font-size: .74rem; font-weight: 600;
  background: rgba(139,61,255,.16); border: 1px solid rgba(167,128,255,.32); color: var(--lav);
}
body.bgsc-home .pj-estado.is-plan  { background: rgba(255,255,255,.05); border-color: rgba(200,185,255,.28); color: #d6cff0; }
body.bgsc-home .pj-estado.is-live  { background: rgba(70,200,130,.12); border-color: rgba(110,220,160,.35); color: #8be3b2; }
body.bgsc-home .pj-estado.is-pause { background: rgba(255,190,90,.1); border-color: rgba(255,200,120,.32); color: #f3cf8e; }
body.bgsc-home .pj-link { display: inline-flex; align-items: center; gap: 8px; color: var(--violet); font-weight: 700; font-size: .86rem; white-space: nowrap; }
body.bgsc-home .pj-link .ico { transition: transform .2s var(--ease); }
body.bgsc-home .pj-card:hover .pj-link .ico { transform: translateX(4px); }
/* Toda la tarjeta es clicable sin duplicar enlaces */
body.bgsc-home .pj-stretch { position: absolute; inset: 0; z-index: 3; }

body.bgsc-home .pj-none, body.bgsc-home .pj-empty { padding: 34px 20px; text-align: center; color: var(--muted); border: 1px dashed rgba(167,128,255,.25); border-radius: var(--radius); }
body.bgsc-home .pj-none[hidden] { display: none; }
body.bgsc-home .pj-none a, body.bgsc-home .pj-empty a { color: var(--violet); font-weight: 600; }
body.bgsc-home .pj-empty strong { color: #fff; }
body.bgsc-home .pj-empty-ico { width: 36px; height: 36px; color: var(--violet); margin: 0 auto 10px; }

/* ---------- Cierre ---------- */
body.bgsc-home .pj-band {
  position: relative; margin-top: 22px; padding: 18px 24px 18px 40px;
  display: flex; align-items: center; justify-content: space-between; gap: 20px; flex-wrap: wrap;
  border-radius: 10px; border: 1px solid var(--line);
  background: linear-gradient(90deg, rgba(26,19,56,.92), rgba(30,18,66,.88));
}
body.bgsc-home .pj-band::before { content: ""; position: absolute; left: 16px; top: 14px; bottom: 14px; width: 5px; border-radius: 3px; background: var(--grad); }
body.bgsc-home .pj-band h2 { font-size: clamp(1.1rem, 1.4vw, 1.3rem); font-weight: 700; }
body.bgsc-home .pj-band p { margin-top: 4px; font-size: .88rem; color: var(--muted); }
body.bgsc-home .pj-band .btn { min-width: 240px; }
body.bgsc-home .pj-legal { margin-top: 16px; font-size: .74rem; color: var(--dim); max-width: 110ch; }

/* ---------- Responsive ---------- */
@media (max-width: 1280px) {
body.bgsc-home .pj-tools { grid-template-columns: 1fr; }
body.bgsc-home .pj-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 900px) {
body.bgsc-home .pj-grid { grid-template-columns: 1fr; }
body.bgsc-home .pj-media { aspect-ratio: 3.4 / 1; }
}
@media (max-width: 760px) {
body.bgsc-home .pj-hero { min-height: 240px; }
body.bgsc-home .pj-hero-bg { object-position: 72% 55%; }
body.bgsc-home .pj-hero-shade { background: linear-gradient(180deg, rgba(10,8,23,.55) 0%, rgba(10,8,23,.72) 55%, var(--bg) 100%); }
html.js body.bgsc-home .pj-filters { display: flex; overflow-x: auto; scrollbar-width: none; margin-inline: calc(var(--gutter) * -1); padding-inline: var(--gutter); }
body.bgsc-home .pj-filters::-webkit-scrollbar { display: none; }
body.bgsc-home .pj-chip { flex: none; min-height: 44px; }
body.bgsc-home .pj-head h2 { white-space: normal; }
body.bgsc-home .pj-head::after { display: none; }
body.bgsc-home .pj-body { grid-template-columns: auto minmax(0, 1fr); padding: 14px 14px 16px; }
body.bgsc-home .pj-ico { align-self: start; }
body.bgsc-home .pj-ico .ico { width: 32px; height: 32px; }
body.bgsc-home .pj-side { grid-column: 1 / -1; flex-direction: row; align-items: center; }
body.bgsc-home .pj-band { padding-left: 34px; }
body.bgsc-home .pj-band .btn { flex: 1 1 100%; min-width: 0; }
}
