/* Legal pages (Privacy Policy, Terms of Use). Builds on the shared tokens from global.css. */

/* ---------- Hero ---------- */
.lg-hero {
  color: #fff; padding-block: clamp(2rem, 4vw, 2.8rem) clamp(5rem, 8vw, 6.5rem);
  background:
    radial-gradient(40% 70% at 85% 30%, rgba(44, 45, 116, 0.65) 0%, rgba(44, 45, 116, 0) 70%),
    linear-gradient(125deg, #15163d 0%, #1a1b4a 45%, #202158 100%);
}
.crumbs { display: flex; align-items: center; gap: 0.4rem; font-size: 0.9rem; color: rgba(232, 232, 248, 0.7); }
.crumbs a { color: rgba(232, 232, 248, 0.85); transition: color 0.2s ease; }
.crumbs a:hover { color: var(--orange); }
.crumbs .i { width: 0.9rem; height: 0.9rem; }
.crumbs [aria-current] { color: #fff; font-weight: 500; }
.lg-hero-copy { margin-top: clamp(1.8rem, 3.5vw, 2.8rem); max-width: 46rem; }
.lg-hero .eyebrow.chip { background: transparent; border-color: rgba(255, 152, 0, 0.6); color: var(--orange); }
.lg-hero h1 { margin-top: 1.2rem; color: #fff; font-size: clamp(2.2rem, 4vw, 3.6rem); font-weight: 800; line-height: 1.1; letter-spacing: -0.03em; }
.lg-hero p { margin-top: 1.1rem; font-size: clamp(1.05rem, 1.3vw, 1.2rem); line-height: 1.7; color: rgba(232, 232, 248, 0.85); max-width: 40rem; }
.lg-meta { display: flex; flex-wrap: wrap; gap: 0.6rem; margin-top: 1.6rem; }
.lg-meta li {
  display: inline-flex; align-items: center; gap: 0.5rem; padding: 0.4rem 0.85rem; border-radius: 999px;
  font-size: 0.88rem; font-weight: 500; color: rgba(232, 232, 248, 0.9);
  background: rgba(255, 255, 255, 0.06); border: 1px solid rgba(255, 255, 255, 0.12);
}
.lg-meta .i { width: 1rem; height: 1rem; color: var(--orange); }

/* ---------- Layout: sticky contents beside the document (overlaps the hero edge) ---------- */
.lg-main { position: relative; z-index: 2; margin-top: calc(-1 * clamp(3rem, 4.5vw, 3.6rem)); padding-bottom: clamp(1rem, 2vw, 1.5rem); }
.lg-in { display: grid; grid-template-columns: minmax(250px, 300px) minmax(0, 1fr); gap: clamp(1.5rem, 3vw, 2.5rem); align-items: start; }
.lg-side { position: sticky; top: calc(var(--head-h) + 20px); display: flex; flex-direction: column; gap: 1rem; max-height: calc(100vh - var(--head-h) - 40px); }

.lg-toc {
  display: flex; flex-direction: column; min-height: 0; background: #fff; border: 1px solid var(--line);
  border-radius: var(--radius-card); box-shadow: var(--shadow-md); overflow: hidden;
}
.lg-toc summary {
  display: flex; align-items: center; gap: 0.6rem; padding: 1.1rem 1.25rem; cursor: pointer; list-style: none;
  font-weight: 700; font-size: 0.82rem; letter-spacing: 0.12em; text-transform: uppercase; color: var(--orange-text);
  border-bottom: 1px solid var(--line-2);
}
.lg-toc summary::-webkit-details-marker { display: none; }
.lg-toc summary .i { width: 1.05rem; height: 1.05rem; }
.lg-toc summary span { flex: 1; }
.lg-caret { color: var(--muted-2); rotate: 90deg; transition: rotate 0.25s ease; }
.lg-toc:not([open]) .lg-caret { rotate: 0deg; }
.lg-toc:not([open]) summary { border-bottom-color: transparent; }
.lg-toc ol { padding: 0.5rem; overflow-y: auto; overscroll-behavior: contain; max-height: min(62vh, 560px); scrollbar-width: thin; }
.lg-toc a {
  display: flex; gap: 0.7rem; align-items: baseline; padding: 0.5rem 0.75rem; border-radius: 10px;
  font-size: 0.9rem; line-height: 1.4; color: var(--muted); transition: background 0.2s ease, color 0.2s ease;
}
.lg-toc a:hover { background: var(--bg-soft); color: var(--navy); }
.lg-toc a.on { background: var(--orange-50); color: var(--navy); font-weight: 600; }
.lg-toc-num { flex: none; font-size: 0.75rem; font-weight: 700; color: var(--muted-2); font-variant-numeric: tabular-nums; }
.lg-toc a.on .lg-toc-num { color: var(--orange-600); }

.lg-related { display: flex; flex-direction: column; gap: 0.5rem; padding: 1rem 1.1rem; background: var(--navy-50); border-radius: var(--radius-card); }
.lg-related small { font-size: 0.75rem; font-weight: 700; letter-spacing: 0.12em; text-transform: uppercase; color: var(--muted-2); }
.lg-related a { display: flex; align-items: center; gap: 0.55rem; font-weight: 600; font-size: 0.95rem; color: var(--navy); }
.lg-related a .i { width: 1.1rem; height: 1.1rem; color: var(--orange-600); }
.lg-related a .lg-go { margin-left: auto; color: var(--muted-2); transition: translate 0.2s ease, color 0.2s ease; }
.lg-related a:hover .lg-go { translate: 3px 0; color: var(--orange-600); }

/* ---------- Document ---------- */
.lg-doc {
  min-width: 0; background: #fff; border: 1px solid var(--line); border-radius: var(--radius-card); box-shadow: var(--shadow-md);
  padding: clamp(1.5rem, 3.5vw, 3rem) clamp(1.25rem, 4vw, 3.5rem);
}
.lg-sec { padding-block: clamp(1.4rem, 2.4vw, 2rem); border-top: 1px solid var(--line-2); }
.lg-sec:first-child, .lg-group + .lg-sec { border-top: 0; }
.lg-sec:first-child { padding-top: 0; }
.lg-sec:last-child { padding-bottom: 0; }
.lg-sec h2 { display: flex; gap: 0.9rem; align-items: baseline; font-size: clamp(1.2rem, 1.6vw, 1.45rem); font-weight: 700; line-height: 1.3; letter-spacing: -0.01em; }
.lg-num {
  flex: none; display: inline-flex; align-items: center; justify-content: center; min-width: 2.4rem; height: 1.9rem; padding-inline: 0.5rem;
  border-radius: 9px; background: var(--orange-50); color: var(--orange-600); font-size: 0.85rem; font-weight: 700;
  font-variant-numeric: tabular-nums; translate: 0 -0.1rem;
}
.lg-intro .lg-body { font-size: 1.1rem; color: var(--text); }
.lg-intro { padding-left: 1.2rem; border-left: 3px solid var(--orange); }

.lg-body { margin-top: 0.9rem; color: var(--muted); font-size: 1rem; line-height: 1.8; }
.lg-intro .lg-body { margin-top: 0; }
.lg-body > * + * { margin-top: 0.9rem; }
.lg-body b, .lg-body strong { color: var(--navy); font-weight: 600; }
.lg-body a { color: var(--orange-text); font-weight: 500; text-decoration: underline; text-decoration-color: rgba(168, 100, 0, 0.35); text-underline-offset: 3px; overflow-wrap: anywhere; }
.lg-body a:hover { text-decoration-color: currentColor; }
.lg-body ol, .lg-body ul { padding-left: 1.5rem; }
.lg-body ol { list-style: decimal; }
.lg-body ul { list-style: disc; }
.lg-body ol ol { list-style: lower-roman; margin-top: 0.5rem; }
.lg-body li { padding-left: 0.35rem; }
.lg-body li + li { margin-top: 0.55rem; }
.lg-body li::marker { color: var(--orange-600); font-weight: 600; }

.lg-group {
  display: flex; align-items: center; gap: 1rem; margin-top: clamp(1.4rem, 2.4vw, 2rem); padding-top: clamp(1.4rem, 2.4vw, 2rem);
  border-top: 1px solid var(--line-2); font-size: 0.82rem; font-weight: 700; letter-spacing: 0.14em; text-transform: uppercase; color: var(--orange-text);
}
.lg-group::after { content: ""; flex: 1; height: 1px; background: var(--line); }

.lg-address {
  display: flex; flex-wrap: wrap; gap: 1.1rem 2.5rem; margin-top: 1.2rem; padding: 1.2rem 1.3rem;
  background: var(--bg-soft); border: 1px solid var(--line-2); border-radius: 14px;
}
.lg-addr-row { flex: 1 1 260px; display: flex; gap: 0.9rem; align-items: flex-start; min-width: 0; }
/* the email column takes the width its address needs, so it stays on one line where it fits */
.lg-addr-row:has(a) { flex: 0 1 auto; }
.lg-addr-row > div { min-width: 0; display: flex; flex-direction: column; gap: 0.2rem; }
.lg-addr-ic { width: 40px; height: 40px; flex: none; border-radius: 12px; display: flex; align-items: center; justify-content: center; background: var(--orange-50); color: var(--orange-600); }
.lg-addr-ic.n { background: var(--navy-50); color: var(--navy); }
.lg-addr-ic .i { width: 1.15rem; height: 1.15rem; }
.lg-addr-row small { font-size: 0.75rem; font-weight: 700; letter-spacing: 0.12em; text-transform: uppercase; color: var(--muted-2); }
.lg-addr-row address { font-style: normal; color: var(--text); line-height: 1.65; font-size: 0.97rem; }
.lg-addr-row a { color: var(--navy); font-weight: 600; overflow-wrap: break-word; }
.lg-addr-row a:hover { color: var(--orange-600); }

/* ---------- Closing call to action ---------- */
.lg-cta-sec { padding-top: clamp(2.5rem, 4vw, 3.5rem); }
.lg-cta {
  display: flex; align-items: center; gap: clamp(1rem, 2.5vw, 1.75rem); padding: clamp(1.5rem, 3vw, 2.2rem) clamp(1.4rem, 3vw, 2.5rem);
  border-radius: var(--radius-card); color: #fff;
  background: radial-gradient(60% 120% at 100% 0%, rgba(255, 152, 0, 0.18) 0%, rgba(255, 152, 0, 0) 60%), linear-gradient(125deg, #15163d 0%, #202158 100%);
  box-shadow: var(--shadow-lg);
}
.lg-cta > div { flex: 1; min-width: 0; }
.lg-cta-ic { width: 56px; height: 56px; flex: none; border-radius: 16px; display: flex; align-items: center; justify-content: center; background: var(--orange); color: #fff; }
.lg-cta-ic .i { width: 1.5rem; height: 1.5rem; }
.lg-cta h2 { color: #fff; font-size: clamp(1.3rem, 2vw, 1.7rem); font-weight: 700; }
.lg-cta p { margin-top: 0.4rem; color: rgba(232, 232, 248, 0.82); }
.lg-cta p a { color: var(--orange); font-weight: 600; overflow-wrap: anywhere; }
.lg-cta p a:hover { text-decoration: underline; }
.lg-cta .btn { flex: none; }

/* ---------- Responsive ---------- */
@media (max-width: 1024px) {
  .lg-in { grid-template-columns: minmax(0, 1fr); }
  .lg-side { position: static; max-height: none; }
  .lg-toc ol { max-height: 50vh; }
}
@media (max-width: 760px) {
  .lg-cta { flex-direction: column; align-items: flex-start; }
  .lg-cta .btn { width: 100%; justify-content: center; }
  .lg-sec h2 { gap: 0.7rem; }
  .lg-num { min-width: 2.1rem; height: 1.7rem; font-size: 0.78rem; }
  .lg-intro { padding-left: 0.9rem; }
}
