/* ============================================================
   INVURIA — Legal pages shared stylesheet
   Loaded ONLY by privacy.html and terms-of-service.html
   Dark teal-stone theme (mirrors the homepage identity)
   ============================================================ */

:root {
  --bg: #101214;
  --bg-soft: #15181b;
  --surface: #1a1e21;
  --surface-2: #1f2428;
  --line: #2a3034;
  --line-soft: #23282c;
  --text: #E9EEF0;
  --muted: #a7b3b7;
  --muted-2: #82909a;
  --accent: #0F766E;
  --accent-deep: #115E59;
  --accent-light: #99F6E4;
  --accent-darkest: #042624;
  --maxw: 1180px;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: "Inter", "Segoe UI", "Helvetica Neue", Arial, sans-serif;
  font-size: 16px;
  line-height: 1.75;
  color: var(--text);
  background-color: var(--bg);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

.legal-page {
  background-color: #101214;
  color: #E9EEF0;
}

a {
  color: var(--accent-light);
  text-decoration: none;
}

a:hover {
  color: var(--text);
}

/* ============================================================
   LEGAL TOP NAV
   ============================================================ */

.legal-nav {
  position: sticky;
  top: 0;
  z-index: 1000;
  background-color: #0d0f11;
  border-bottom: 1px solid var(--line);
}

.legal-nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 66px;
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 0 24px;
}

.legal-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--text);
  font-weight: 700;
  font-size: 18px;
}

.legal-brand-mark {
  width: 30px;
  height: 30px;
  border-radius: 8px;
  background: linear-gradient(145deg, #115E59, #042624);
  border: 1.5px solid var(--accent-light);
  position: relative;
}

.legal-brand-mark::before {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  width: 14px;
  height: 14px;
  transform: translate(-50%, -50%);
  border-radius: 50%;
  border: 1.5px solid var(--accent-light);
  background: #0b1214;
}

.legal-brand span {
  color: var(--accent-light);
}

.legal-nav-back {
  font-size: 14px;
  font-weight: 600;
  color: var(--accent-light);
  padding: 8px 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
}

.legal-nav-back:hover {
  background-color: var(--surface);
}

/* ============================================================
   LEGAL PAGE HEADER (must be a div/header, not a section)
   ============================================================ */

.legal-header {
  background: linear-gradient(150deg, #0F766E 0%, #115E59 40%, #042624 100%);
  padding: 84px 0 60px;
  border-bottom: 1px solid var(--accent);
}

.legal-header-inner {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 0 24px;
}

.legal-header .kicker {
  display: inline-block;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 1.6px;
  text-transform: uppercase;
  color: #99F6E4;
  margin-bottom: 16px;
}

.legal-header h1 {
  font-size: 44px;
  line-height: 1.15;
  font-weight: 800;
  letter-spacing: -0.5px;
  color: #042624;
  max-width: 820px;
}

.legal-header .lede {
  font-size: 17px;
  color: #042624;
  max-width: 680px;
  margin-top: 18px;
}

/* ============================================================
   LEGAL CONTENT
   ============================================================ */

.legal-content {
  padding: 60px 0 72px;
}

.legal-content .container {
  max-width: 880px;
  margin: 0 auto;
  padding: 0 24px;
}

/* Scope isolation: keep any same-id section transparent on legal pages */
.legal-page .legal-content section {
  background-color: transparent !important;
}

.legal-content section {
  margin-bottom: 52px;
}

.legal-content h2 {
  font-size: 26px;
  line-height: 1.3;
  font-weight: 800;
  color: var(--accent-light);
  letter-spacing: -0.3px;
  margin-bottom: 16px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--line);
}

.legal-content h3 {
  font-size: 19px;
  font-weight: 700;
  color: var(--text);
  margin: 24px 0 10px;
}

.legal-content p {
  font-size: 16px;
  color: var(--muted);
  margin-bottom: 16px;
}

.legal-content ul,
.legal-content ol {
  margin: 0 0 18px 24px;
  color: var(--muted);
}

.legal-content li {
  font-size: 16px;
  margin-bottom: 10px;
}

.legal-content strong {
  color: var(--text);
}

.legal-content em {
  color: var(--accent-light);
  font-style: normal;
}

/* Table of contents */
.toc {
  background-color: var(--surface);
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 28px 30px;
  margin-bottom: 44px;
}

.toc-title {
  font-size: 15px;
  font-weight: 700;
  letter-spacing: 0.8px;
  text-transform: uppercase;
  color: var(--accent-light);
  margin-bottom: 16px;
}

.toc ol {
  list-style: none;
  margin: 0;
  columns: 1;
}

.toc li {
  margin-bottom: 8px;
}

.toc a {
  font-size: 15px;
  color: var(--muted);
  border-bottom: 1px dotted var(--line);
}

.toc a:hover {
  color: var(--accent-light);
}

/* ============================================================
   LEGAL FOOTER
   ============================================================ */

.legal-footer {
  background-color: #0c0e10;
  border-top: 2px solid var(--accent);
  padding: 40px 0;
}

.legal-footer-inner {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 0 24px;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.legal-footer p {
  font-size: 14px;
  color: var(--muted-2);
}

.legal-footer .links {
  display: flex;
  gap: 20px;
  flex-wrap: wrap;
}

.legal-footer .links a {
  font-size: 14px;
  color: var(--muted);
}

.legal-footer .links a:hover {
  color: var(--accent-light);
}

/* ============================================================
   RESPONSIVE
   ============================================================ */

@media (max-width: 720px) {
  .legal-header {
    padding: 64px 0 48px;
  }

  .legal-header h1 {
    font-size: 32px;
  }

  .legal-content {
    padding: 44px 0 56px;
  }

  .legal-content h2 {
    font-size: 22px;
  }
}
