/* ================================================================
   PLANTA BAJA — Hoja de estilos compartida (pb.css)
   Incluir en todas las páginas públicas excepto terminos y privacy.
   ================================================================ */

/* ── RESET ──────────────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html, body { min-height: 100vh; }

/* ── VARIABLES ──────────────────────────────────────────────────── */
:root {
  --bg:         #0a0a0a;
  --bg-card:    rgba(20, 20, 20, 0.85);
  --bg-card-hv: rgba(28, 28, 28, 0.95);
  --gold:        #c9a961;
  --gold-bright: #e0c178;
  --text:        #f5f5f5;
  --text-muted:  #aaa;
  --border:      rgba(255, 255, 255, 0.08);
}

/* ── BODY BASE ──────────────────────────────────────────────────── */
body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  color: var(--text);
  background-color: var(--bg);
  line-height: 1.5;
  position: relative;
}
a { color: inherit; text-decoration: none; }

/* ── FONDO: imagen de fondo y overlay ──────────────────────────── */
body::before {
  content: '';
  position: fixed;
  inset: 0;
  z-index: -2;
  background-image: url('/assets/fondo.jpg');
  background-size: cover;
  background-position: center;
  background-attachment: fixed;
}
body::after {
  content: '';
  position: fixed;
  inset: 0;
  z-index: -1;
  background: linear-gradient(
    to bottom,
    rgba(10, 10, 10, 0.9)  0%,
    rgba(10, 10, 10, 0.82) 50%,
    rgba(10, 10, 10, 0.9)  100%
  );
}

/* ── PAGE HERO ──────────────────────────────────────────────────── */
.page-hero {
  padding: 48px 0 40px;
  border-bottom: 1px solid var(--border);
  margin-bottom: 36px;
}
.page-hero-label {
  font-size: 12px;
  letter-spacing: 3px;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 10px;
}
.page-hero h1 { font-size: 36px; font-weight: 700; margin-bottom: 10px; }
.page-hero p  { font-size: 16px; color: var(--text-muted); max-width: 560px; }

/* ── HERO STATS ─────────────────────────────────────────────────── */
.hero-stats { display: flex; gap: 32px; margin-top: 24px; flex-wrap: wrap; }
.hero-stat .num {
  font-size: 24px; font-weight: 800; color: var(--gold); line-height: 1;
}
.hero-stat .lbl {
  font-size: 11px; color: var(--text-muted);
  text-transform: uppercase; letter-spacing: .5px; margin-top: 3px;
}

/* ── LOGIN BANNER ───────────────────────────────────────────────── */
.login-banner {
  background: rgba(201, 169, 97, 0.06);
  border: 1px solid rgba(201, 169, 97, 0.2);
  border-radius: 10px;
  padding: 14px 20px;
  margin-bottom: 28px;
  font-size: 14px;
  color: var(--text-muted);
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}
.login-banner a { color: var(--gold); font-weight: 600; }
.login-banner a:hover { color: var(--gold-bright); }

/* ── ALERTAS ────────────────────────────────────────────────────── */
.alert-ok, .msg-ok {
  background: #081a08;
  border: 1px solid #103a10;
  border-radius: 8px;
  padding: 12px 16px;
  font-size: 13px;
  color: #6bff6b;
  margin-bottom: 16px;
}
.alert-err, .msg-err {
  background: #1a0808;
  border: 1px solid #3a1010;
  border-radius: 8px;
  padding: 12px 16px;
  font-size: 13px;
  color: #ff6b6b;
  margin-bottom: 16px;
}

/* ── TABS (estilo link, usadas en recursos/arq/comunidad) ───────── */
.tab-nav {
  display: flex;
  gap: 4px;
  border-bottom: 1px solid var(--border);
  margin-bottom: 32px;
}
.tab-btn {
  padding: 10px 20px;
  font-size: 13px;
  font-weight: 600;
  color: var(--text-muted);
  text-decoration: none;
  border-radius: 7px 7px 0 0;
  border: 1px solid transparent;
  border-bottom: none;
  position: relative;
  bottom: -1px;
  transition: color .2s;
  background: none;
  cursor: pointer;
  font-family: inherit;
}
.tab-btn:hover  { color: var(--text); }
.tab-btn.active {
  color: var(--text);
  background: rgba(14, 14, 14, 0.95);
  border-color: var(--border);
  border-bottom-color: rgba(14, 14, 14, 0.95);
}

/* ── MODAL ──────────────────────────────────────────────────────── */
.modal-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.72);
  z-index: 500;
  align-items: center;
  justify-content: center;
  padding: 20px;
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
}
.modal-overlay.open { display: flex; }
.modal-box {
  background: #111;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 14px;
  padding: 28px;
  max-width: 520px;
  width: 100%;
  max-height: 90vh;
  overflow-y: auto;
  position: relative;
}
.modal-close {
  position: absolute;
  top: 12px; right: 12px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid #2a2a2a;
  color: var(--text-muted);
  font-size: 18px;
  width: 30px; height: 30px;
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background .2s, color .2s;
  line-height: 1;
  padding: 0;
}
.modal-close:hover { background: var(--gold); border-color: transparent; color: #fff; }

/* ── EMPTY STATE ────────────────────────────────────────────────── */
.pb-empty {
  text-align: center;
  padding: 60px 0;
  color: #444;
  font-size: 15px;
}
.pb-empty span { display: block; font-size: 13px; margin-top: 6px; }

/* ── RESPONSIVE ─────────────────────────────────────────────────── */
@media (max-width: 600px) {
  body::before { background-attachment: scroll; }
  .page-hero h1 { font-size: 26px; }
  .tab-btn { padding: 8px 12px; font-size: 12px; }
}
