/* ============================================
   KEPLER AEROSPACE — legal.css
   Shared styles for Privacy Policy & Terms
   ============================================ */

/* ============================================
   HERO
   ============================================ */
.legal-hero {
  padding: calc(var(--header-h) + 80px) 0 60px;
  background:
    radial-gradient(ellipse 60% 50% at 50% 40%, rgba(10,42,75,0.45) 0%, transparent 65%),
    linear-gradient(170deg, #020810 0%, #040c18 55%, #000000 100%);
  position: relative;
  overflow: hidden;
  text-align: center;
}

/* Stars */
.legal-hero::before {
  content: '';
  position: absolute; inset: 0; z-index: 0;
  background-image:
    radial-gradient(1px 1px at 10% 15%, rgba(255,255,255,0.5) 0%, transparent 100%),
    radial-gradient(1px 1px at 30% 8%,  rgba(255,255,255,0.35) 0%, transparent 100%),
    radial-gradient(1.5px 1.5px at 60% 22%, rgba(255,255,255,0.4) 0%, transparent 100%),
    radial-gradient(1px 1px at 80% 10%, rgba(255,255,255,0.3) 0%, transparent 100%),
    radial-gradient(1px 1px at 92% 35%, rgba(255,255,255,0.38) 0%, transparent 100%);
}

/* Bottom separator line */
.legal-hero::after {
  content: '';
  position: absolute; bottom: 0; left: 8%; right: 8%; height: 1px;
  background: linear-gradient(to right, transparent, rgba(35,165,220,0.4), transparent);
}

.legal-hero .container { position: relative; z-index: 1; }

.legal-hero-inner { max-width: 680px; margin: 0 auto; }

.legal-hero-inner h1 {
  font-size: clamp(32px, 5vw, 47px);
  font-weight: 300;
  line-height: 1.15;
  margin: 12px 0 20px;
  color: var(--primary);
}
.legal-hero-inner h1 span {
  font-weight: 700;
  color: var(--accent2);
}

.legal-meta {
  font-size: 13px;
  color: rgba(255,255,255,0.4);
  letter-spacing: 0.04em;
}
.legal-meta strong {
  color: rgba(255,255,255,0.6);
  font-weight: 500;
}

/* ============================================
   CONTENT SECTION
   ============================================ */
.legal-content-section {
  padding: clamp(60px, 8vw, 100px) 0;
  background: var(--bg);
}

/* Two-column layout: TOC sidebar + article body */
.legal-layout {
  display: grid;
  grid-template-columns: 220px 1fr;
  gap: 64px;
  align-items: start;
}

/* ============================================
   SIDEBAR TOC
   ============================================ */
.legal-toc {
  position: sticky;
  top: calc(var(--header-h) + 32px);
}

.toc-label {
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.15em;
  color: var(--accent);
  opacity: 0.75;
  margin-bottom: 16px;
}

.legal-toc nav {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.legal-toc nav a {
  font-size: 13px;
  color: rgba(255,255,255,0.38);
  padding: 7px 12px;
  border-left: 2px solid rgba(255,255,255,0.07);
  text-decoration: none;
  transition: color 0.25s, border-color 0.25s, padding-left 0.25s;
  line-height: 1.45;
}
.legal-toc nav a:hover,
.legal-toc nav a.active {
  color: rgba(255,255,255,0.82);
  border-left-color: var(--accent);
  padding-left: 16px;
}

/* ============================================
   ARTICLE BODY
   ============================================ */
.legal-body { max-width: 720px; }

.legal-section {
  padding-bottom: 48px;
  margin-bottom: 48px;
  border-bottom: 1px solid rgba(255,255,255,0.05);
}
.legal-section:last-child {
  border-bottom: none;
  margin-bottom: 0;
  padding-bottom: 0;
}

.legal-section h2 {
  font-size: clamp(18px, 2.5vw, 24px);
  font-weight: 700;
  color: var(--primary);
  margin-bottom: 18px;
  padding-bottom: 12px;
  border-bottom: 1px solid rgba(35,165,220,0.15);
  position: relative;
}

/* Accent underline on h2 */
.legal-section h2::after {
  content: '';
  position: absolute;
  bottom: -1px; left: 0;
  width: 36px; height: 2px;
  background: var(--accent);
}

.legal-section h3 {
  font-size: 14px;
  font-weight: 700;
  color: rgba(255,255,255,0.75);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin: 24px 0 10px;
}

.legal-section p {
  font-size: 15px;
  color: rgba(255,255,255,0.62);
  line-height: 1.82;
  margin-bottom: 14px;
}
.legal-section p:last-of-type { margin-bottom: 0; }

/* Lists */
.legal-list {
  list-style: none;
  padding: 0;
  margin: 14px 0 18px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.legal-list li {
  font-size: 14px;
  color: rgba(255,255,255,0.6);
  line-height: 1.65;
  padding-left: 20px;
  position: relative;
}

.legal-list li::before {
  content: '';
  position: absolute;
  left: 0; top: 9px;
  width: 5px; height: 5px;
  border-radius: 50%;
  background: var(--accent);
  opacity: 0.7;
}

/* Contact card */
.legal-contact-card {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  padding: 14px 22px;
  margin-top: 10px;
  border: 1px solid rgba(35,165,220,0.2);
  background: rgba(35,165,220,0.05);
  border-radius: 3px;
  transition: background 0.3s, border-color 0.3s;
}
.legal-contact-card:hover {
  background: rgba(35,165,220,0.1);
  border-color: rgba(35,165,220,0.4);
}

.legal-contact-card i {
  font-size: 15px;
  color: var(--accent);
}

.legal-contact-card a {
  font-size: 14px;
  font-weight: 500;
  color: rgba(255,255,255,0.75);
  text-decoration: none;
  transition: color 0.25s;
}
.legal-contact-card a:hover { color: var(--accent); }

/* ============================================
   RESPONSIVE
   ============================================ */
@media (max-width: 900px) {
  .legal-layout {
    grid-template-columns: 1fr;
    gap: 40px;
  }

  .legal-toc {
    position: static;
    border: 1px solid rgba(255,255,255,0.06);
    background: rgba(255,255,255,0.02);
    border-radius: 4px;
    padding: 20px 24px;
  }

  .legal-toc nav {
    flex-direction: row;
    flex-wrap: wrap;
    gap: 4px 0;
  }

  .legal-toc nav a {
    border-left: none;
    border-bottom: 2px solid rgba(255,255,255,0.07);
    padding: 6px 14px;
  }

  .legal-toc nav a:hover {
    padding-left: 14px;
    border-bottom-color: var(--accent);
  }
}

@media (max-width: 640px) {
  .legal-hero-inner h1 { font-size: 30px; }
  .legal-section h2 { font-size: 18px; }
}