/* ===== V08 · ALIADOS ESTRATÉGICOS — 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 ---------- */
body.bgsc-home .al-hero {
  position: relative; isolation: isolate; overflow: hidden;
  min-height: clamp(260px, 17vw, 330px); display: flex; align-items: center;
  padding: clamp(18px, 1.8vw, 26px) 0 clamp(26px, 2.4vw, 36px);
  background: radial-gradient(60% 90% at 75% 40%, rgba(182,0,255,.28), transparent 70%), var(--bg-2);
}
body.bgsc-home .al-hero-bg { position: absolute; inset: 0; z-index: -2; width: 100%; height: 100%; object-fit: cover; object-position: 65% 40%; }
body.bgsc-home .al-hero-shade {
  position: absolute; inset: 0; z-index: -1;
  background:
    linear-gradient(90deg, rgba(10,8,23,.95) 0%, rgba(10,8,23,.82) 30%, rgba(10,8,23,.3) 55%, rgba(10,8,23,0) 72%),
    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 .al-crumbs { display: flex; flex-wrap: wrap; gap: 10px; margin-bottom: 14px; font-size: .9rem; color: #e4def8; text-shadow: 0 1px 10px rgba(0,0,0,.5); }
body.bgsc-home .al-crumbs a:hover { color: #fff; }
body.bgsc-home .al-crumbs [aria-current] { color: var(--violet); }
body.bgsc-home .al-crumbs span[aria-hidden] { color: var(--dim); }
body.bgsc-home .al-hero h1 { margin-top: 14px; font-size: clamp(2rem, 3.3vw, 3.2rem); font-weight: 800; line-height: 1.04; letter-spacing: -.035em; text-shadow: 0 2px 22px rgba(0,0,0,.45); }
body.bgsc-home .al-hero h1 > span { display: block; color: #fff; }
body.bgsc-home .al-hero h1 em { font-style: normal; background: linear-gradient(90deg, #a35bff, #c47dff); -webkit-background-clip: text; background-clip: text; color: transparent; }
body.bgsc-home .al-lead { margin-top: 14px; max-width: 640px; color: #ece8fb; font-size: clamp(.98rem, 1.15vw, 1.1rem); text-shadow: 0 1px 12px rgba(0,0,0,.5); }

/* ---------- Encabezado del directorio + herramientas ---------- */
body.bgsc-home .al-main { padding: 22px 0 30px; }
body.bgsc-home .al-head { display: flex; align-items: center; justify-content: space-between; gap: 18px; flex-wrap: wrap; margin-bottom: 16px; }
body.bgsc-home .al-head h2 { font-size: clamp(1.5rem, 2.1vw, 2rem); font-weight: 800; }
body.bgsc-home .al-head h2 span { color: var(--violet); }
body.bgsc-home .al-tools { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
body.bgsc-home .al-search { position: relative; display: flex; align-items: center; min-width: 240px; min-height: 42px; border-radius: 999px; border: 1px solid var(--line-2); background: rgba(16,12,36,.85); }
body.bgsc-home .al-search:focus-within { border-color: var(--violet); box-shadow: 0 0 0 3px rgba(164,107,255,.18); }
body.bgsc-home .al-search .ico { position: absolute; left: 14px; width: 18px; height: 18px; color: #d9d2f2; pointer-events: none; }
body.bgsc-home .al-search input { width: 100%; height: 40px; padding: 0 14px 0 42px; border: 0; outline: 0; background: transparent; color: var(--text); font: inherit; font-size: .9rem; }
body.bgsc-home .al-filters { display: none; }
html.js body.bgsc-home .al-filters { display: flex; gap: 8px; flex-wrap: wrap; }
body.bgsc-home .al-chip { min-height: 40px; padding: 0 16px; border-radius: 999px; border: 1px solid var(--line); background: rgba(16,12,36,.85); color: #ece7fc; font-weight: 600; font-size: .85rem; }
body.bgsc-home .al-chip:hover { border-color: var(--line-2); }
body.bgsc-home .al-chip.is-active { border-color: transparent; background: var(--grad); color: #fff; }

/* ---------- Tarjetas ---------- */
body.bgsc-home .al-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
body.bgsc-home .al-card {
  position: relative; display: flex; flex-direction: column; gap: 14px; padding: 16px 18px;
  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, box-shadow .25s;
}
body.bgsc-home .al-card[hidden] { display: none; }
body.bgsc-home .al-card:hover { border-color: var(--line-2); box-shadow: 0 18px 40px -26px rgba(139,61,255,.7); }
body.bgsc-home .al-top { display: grid; grid-template-columns: 88px minmax(0, 1fr); gap: 16px; align-items: start; }
body.bgsc-home .al-logo {
  display: grid; place-items: center; width: 88px; height: 88px; overflow: hidden;
  border-radius: 12px; border: 1px solid rgba(167,128,255,.25); background: #fff;
}
body.bgsc-home .al-logo img { width: 78%; height: 78%; object-fit: contain; }
body.bgsc-home .al-logo.is-ini { background: linear-gradient(160deg, rgba(139,61,255,.45), rgba(80,30,160,.35)); }
body.bgsc-home .al-logo.is-ini span { font-size: 2.4rem; font-weight: 800; color: #fff; letter-spacing: -.02em; }
body.bgsc-home .al-name { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
body.bgsc-home .al-card h3 { font-size: 1.2rem; font-weight: 700; letter-spacing: -.01em; }
body.bgsc-home .al-tag { padding: 3px 10px; border-radius: 999px; font-size: .72rem; font-weight: 600; color: var(--lav); background: rgba(139,61,255,.18); border: 1px solid rgba(167,128,255,.35); }
body.bgsc-home .al-titular { margin-top: 8px; font-weight: 700; color: #fff; font-size: .98rem; }
body.bgsc-home .al-txt p:not(.al-titular) { margin-top: 4px; font-size: .84rem; color: #d3cceb; line-height: 1.45; }
body.bgsc-home .al-foot {
  margin-top: auto; display: grid; grid-template-columns: auto minmax(0, 1fr) auto; gap: 12px; align-items: center;
  padding-top: 12px; border-top: 1px solid rgba(167,128,255,.18);
}
body.bgsc-home .al-foot > .ico { width: 28px; height: 28px; color: var(--violet); }
body.bgsc-home .al-foot strong { display: block; font-size: .84rem; }
body.bgsc-home .al-foot span:not(.sr-only) { display: block; font-size: .8rem; color: var(--muted); }
body.bgsc-home .al-link { display: inline-flex; align-items: center; gap: 6px; color: var(--violet); font-weight: 600; font-size: .86rem; white-space: nowrap; }
body.bgsc-home .al-link .ico { transition: transform .2s var(--ease); }
body.bgsc-home .al-link:hover { color: #c9a8ff; }
body.bgsc-home .al-link:hover .ico { transform: translateX(4px); }

/* Tarjeta de invitación (solo mientras haya pocos aliados) */
body.bgsc-home .al-invite { align-items: flex-start; justify-content: center; border-style: dashed; border-color: rgba(167,128,255,.35); background: rgba(139,61,255,.06); }
body.bgsc-home .al-invite-ico { width: 40px; height: 40px; color: var(--violet); }
body.bgsc-home .al-invite p { font-size: .86rem; color: var(--muted); max-width: 46ch; }

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

/* ---------- Cierre ---------- */
body.bgsc-home .al-band {
  position: relative; isolation: isolate; overflow: hidden; margin-top: 22px;
  display: flex; align-items: center; gap: 22px; flex-wrap: wrap; padding: 22px 26px;
  border-radius: 10px; border: 1px solid var(--line); background: linear-gradient(90deg, rgba(26,19,56,.95), rgba(30,18,66,.9));
}
body.bgsc-home .al-band-bg { position: absolute; inset: 0; z-index: -2; width: 100%; height: 100%; object-fit: cover; object-position: 50% 60%; }
body.bgsc-home .al-band::before { content: ""; position: absolute; inset: 0; z-index: -1; background: linear-gradient(90deg, rgba(18,13,40,.97) 0%, rgba(18,13,40,.88) 45%, rgba(18,13,40,.55) 75%, rgba(18,13,40,.4) 100%); }
body.bgsc-home .al-band-ico { width: 64px; height: 64px; color: var(--violet); padding-right: 22px; box-sizing: content-box; border-right: 1px solid rgba(167,128,255,.3); }
body.bgsc-home .al-band-copy { flex: 1 1 340px; }
body.bgsc-home .al-band h2 { font-size: clamp(1.15rem, 1.6vw, 1.5rem); font-weight: 800; }
body.bgsc-home .al-band h2 span { color: var(--violet); }
body.bgsc-home .al-band p { margin-top: 6px; color: #e4def8; font-size: .92rem; }
body.bgsc-home .al-band .btn { min-width: 220px; }
body.bgsc-home .al-legal { margin-top: 16px; font-size: .74rem; color: var(--dim); max-width: 120ch; }

/* ---------- Responsive ---------- */
@media (max-width: 1280px) {
body.bgsc-home .al-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 900px) {
body.bgsc-home .al-grid { grid-template-columns: 1fr; }
}
@media (max-width: 760px) {
body.bgsc-home .al-hero-bg { object-position: 70% 40%; }
body.bgsc-home .al-hero-shade { background: linear-gradient(180deg, rgba(10,8,23,.6) 0%, rgba(10,8,23,.78) 55%, var(--bg) 100%); }
body.bgsc-home .al-crumbs { font-size: .82rem; }
body.bgsc-home .al-tools, body.bgsc-home .al-search { width: 100%; }
body.bgsc-home .al-top { grid-template-columns: 64px minmax(0, 1fr); }
body.bgsc-home .al-logo { width: 64px; height: 64px; }
body.bgsc-home .al-logo.is-ini span { font-size: 1.8rem; }
body.bgsc-home .al-foot { grid-template-columns: auto minmax(0, 1fr); }
body.bgsc-home .al-link { grid-column: 2; }
body.bgsc-home .al-band-ico { display: none; }
body.bgsc-home .al-band .btn { flex: 1 1 100%; min-width: 0; }
}
