/* ============================================================
   AlcalSpark, Legal Page Styles
   ============================================================ */

.legal-hero { background: transparent; }
.legal-hero .ph-bg {
  background: radial-gradient(ellipse 50% 60% at 50% 100%, rgba(201, 168, 76, 0.05) 0%, transparent 70%);
}

/* ── Legal layout ───────────────────────────────────────────── */
.legal-section { background: transparent; }
.legal-layout {
  display: grid;
  grid-template-columns: 220px 1fr;
  gap: 60px;
  align-items: start;
}

/* ── Sidebar nav ─────────────────────────────────────────────── */
.legal-nav {
  position: sticky;
  top: 100px;
  background: var(--black);
  border: 1px solid rgba(201, 168, 76, 0.1);
  border-radius: 4px;
  padding: 24px 20px;
}
.legal-nav ul { list-style: none; display: flex; flex-direction: column; gap: 4px; }
.legal-nav-link {
  display: block;
  font-family: var(--font-ui);
  font-size: 0.78rem;
  font-weight: 500;
  color: rgba(248, 245, 242, 0.72);
  padding: 8px 12px;
  border-radius: 2px;
  border-left: 2px solid transparent;
  transition: color 0.3s, border-color 0.3s, background 0.3s, padding-left 0.3s;
}
.legal-nav-link:hover,
.legal-nav-link.active {
  color: var(--gold);
  border-left-color: var(--gold);
  background: rgba(201, 168, 76, 0.05);
  padding-left: 18px;
}

/* ── Legal articles ─────────────────────────────────────────── */
.legal-content {
  display: flex;
  flex-direction: column;
  gap: 60px;
}

.legal-article {
  scroll-margin-top: 100px;
}
.legal-article h2 {
  font-family: var(--font-display);
  font-size: clamp(1.5rem, 2.5vw, 2rem);
  font-weight: 500;
  color: var(--gold);
  margin-bottom: 20px;
  padding-bottom: 14px;
  border-bottom: 1px solid rgba(201, 168, 76, 0.12);
}
.legal-article h3 {
  font-family: var(--font-ui);
  font-size: 0.82rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: rgba(248, 245, 242, 0.82);
  margin: 24px 0 10px;
}
.legal-article p {
  font-size: 0.92rem;
  line-height: 1.85;
  color: rgba(248, 245, 242, 0.88);
  margin-bottom: 14px;
}
.legal-article p:last-child { margin-bottom: 0; }
.legal-article a { color: var(--gold); text-decoration: underline; transition: color 0.3s; }
.legal-article a:hover { color: var(--gold-light); }
.legal-article ul {
  list-style: none;
  margin: 10px 0 14px 20px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.legal-article ul li {
  font-size: 0.92rem;
  color: rgba(248, 245, 242, 0.88);
  line-height: 1.7;
  position: relative;
  padding-left: 20px;
}
.legal-article ul li::before {
  content: '✦';
  position: absolute;
  left: 0;
  color: rgba(201, 168, 76, 0.5);
  font-size: 0.5rem;
  top: 6px;
}

/* Info block (table-like) */
.legal-info-block {
  background: var(--black);
  border: 1px solid rgba(201, 168, 76, 0.1);
  border-radius: 4px;
  overflow: hidden;
  margin-top: 16px;
}
.lib-row {
  display: flex;
  align-items: baseline;
  gap: 20px;
  padding: 12px 20px;
  border-bottom: 1px solid rgba(201, 168, 76, 0.06);
  transition: background 0.2s;
}
.lib-row:last-child { border-bottom: none; }
.lib-row:hover { background: rgba(201, 168, 76, 0.03); }
.lib-label {
  font-family: var(--font-ui);
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: rgba(248, 245, 242, 0.62);
  min-width: 220px;
  flex-shrink: 0;
}
.lib-value {
  font-size: 0.9rem;
  color: rgba(248, 245, 242, 0.92);
}
.lib-value a { color: var(--gold); text-decoration: none; }
.lib-value a:hover { text-decoration: underline; }

/* ── Responsive ─────────────────────────────────────────────── */
@media (max-width: 900px) {
  .legal-layout {
    grid-template-columns: 1fr;
  }
  .legal-nav {
    position: static;
    display: none;
  }
  .lib-label { min-width: 160px; }
  /* Force reveal visible, legal-content is too tall for the 15% threshold */
  .legal-layout .reveal {
    opacity: 1 !important;
    transform: none !important;
    transition: none !important;
  }
}
@media (max-width: 520px) {
  .lib-row { flex-direction: column; gap: 4px; }
  .lib-label { min-width: auto; }
}
