/* ============================================================
   EINIEX — Legal pages (Privacy · Terms · Cookies)
   Long-form document layout. Inherits tokens from einiex.css.
   Prefixed lgl- to avoid collision with login's lg- classes.
   ============================================================ */

.lgl-main { padding: clamp(7rem, 12vw, 9.5rem) 0 clamp(4rem, 8vw, 7rem); }
.lgl-wrap { width: min(75rem, 92vw); margin: 0 auto; }

/* ---------- hero ---------- */
.lgl-hero { max-width: 52rem; }
.lgl-kicker {
  display: inline-flex; align-items: center; gap: 0.6rem;
  font-family: var(--font-mono), monospace; font-size: 0.6875rem;
  letter-spacing: 0.16em; text-transform: uppercase; color: var(--text-2);
}
.lgl-kicker__dot { width: 0.4rem; height: 0.4rem; border-radius: 50%; background: var(--gold-gradient); }
.lgl-title {
  font-family: var(--font-display), sans-serif; font-weight: 500;
  font-size: clamp(2.4rem, 6vw, 4.25rem); line-height: 1.02; letter-spacing: -0.035em;
  color: var(--text); margin-top: 1.5rem;
}
.lgl-title em { font-family: var(--font-serif), serif; font-style: italic; font-weight: 400; letter-spacing: -0.01em; }
.lgl-meta {
  display: flex; flex-wrap: wrap; align-items: center; gap: 0.5rem 1rem; margin-top: 1.75rem;
  font-family: var(--font-mono), monospace; font-size: 0.72rem; letter-spacing: 0.06em;
  text-transform: uppercase; color: var(--text-2);
}
.lgl-meta span.dot { opacity: 0.5; }
.lgl-lead {
  margin-top: 1.75rem; font-size: clamp(1.0625rem, 1.8vw, 1.3125rem); line-height: 1.55;
  color: var(--text-2); max-width: 46ch; text-wrap: pretty;
}
.lgl-lead b { color: var(--text); font-weight: 500; }

/* ---------- TL;DR summary card ---------- */
.lgl-tldr {
  margin-top: clamp(2.5rem, 5vw, 3.5rem);
  border: 0.0625rem solid var(--border); border-radius: 1rem;
  background: var(--surface); padding: clamp(1.5rem, 3vw, 2.25rem);
  position: relative; overflow: hidden;
}
.lgl-tldr::before {
  content: ""; position: absolute; left: 0; top: 0; bottom: 0; width: 0.1875rem;
  background: var(--gold-gradient); opacity: 0.7;
}
.lgl-tldr__label {
  font-family: var(--font-mono), monospace; font-size: 0.6875rem; letter-spacing: 0.16em;
  text-transform: uppercase; color: var(--text-2);
}
.lgl-tldr__grid {
  margin-top: 1.25rem; display: grid; grid-template-columns: repeat(2, 1fr);
  gap: 1rem 2.5rem;
}
.lgl-tldr__item { display: flex; gap: 0.75rem; align-items: flex-start; }
.lgl-tldr__item svg { width: 1.15rem; height: 1.15rem; flex: 0 0 auto; margin-top: 0.15rem; color: var(--text); }
.lgl-tldr__item p { font-size: 0.9375rem; line-height: 1.5; color: var(--text-2); }
.lgl-tldr__item b { color: var(--text); font-weight: 500; }

/* ---------- two-column layout: sticky TOC + body ---------- */
.lgl-layout {
  margin-top: clamp(3rem, 6vw, 5rem);
  display: grid; grid-template-columns: 15rem 1fr; gap: clamp(2.5rem, 6vw, 6rem);
  align-items: start;
}

.lgl-toc { position: sticky; top: 6.5rem; }
.lgl-toc__title {
  font-family: var(--font-mono), monospace; font-size: 0.6875rem; letter-spacing: 0.16em;
  text-transform: uppercase; color: var(--text-2); margin-bottom: 1rem;
  padding-bottom: 0.75rem; border-bottom: 0.0625rem solid var(--border);
}
.lgl-toc__list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 0.1rem; }
.lgl-toc__link {
  display: flex; gap: 0.7rem; align-items: baseline; padding: 0.4rem 0;
  font-size: 0.84rem; line-height: 1.35; color: var(--text-2);
  transition: color 0.2s ease;
}
.lgl-toc__link:hover { color: var(--text); }
.lgl-toc__link .n {
  font-family: var(--font-mono), monospace; font-size: 0.68rem; color: var(--text-2);
  opacity: 0.7; flex: 0 0 1.4rem;
}
.lgl-toc__link.is-active { color: var(--text); }
.lgl-toc__link.is-active .n { opacity: 1; }

/* ---------- body ---------- */
.lgl-body { max-width: 44rem; min-width: 0; }

.lgl-sec { padding-top: 2.75rem; scroll-margin-top: 6rem; }
.lgl-sec:first-child { padding-top: 0; }
.lgl-sec + .lgl-sec { border-top: 0.0625rem solid var(--border); margin-top: 2.75rem; }
.lgl-sec__head { display: flex; align-items: baseline; gap: 0.9rem; margin-bottom: 1.25rem; }
.lgl-sec__no {
  font-family: var(--font-mono), monospace; font-size: 0.8125rem; color: var(--text-2);
  letter-spacing: 0.08em; flex: 0 0 auto; padding-top: 0.15rem;
}
.lgl-h2 {
  font-family: var(--font-display), sans-serif; font-weight: 500;
  font-size: clamp(1.4rem, 2.6vw, 1.875rem); line-height: 1.1; letter-spacing: -0.02em; color: var(--text);
  text-wrap: balance;
}

.lgl-sec p {
  font-size: 1rem; line-height: 1.72; color: var(--text-2); max-width: 68ch;
  text-wrap: pretty;
}
.lgl-sec p + p { margin-top: 1rem; }
.lgl-sec p b, .lgl-sec li b { color: var(--text); font-weight: 500; }
.lgl-sec a:not(.lgl-toc__link):not(.lgl-mail) { color: var(--text); text-decoration: underline; text-underline-offset: 0.18em; text-decoration-color: var(--border); transition: text-decoration-color 0.2s ease; }
.lgl-sec a:not(.lgl-toc__link):not(.lgl-mail):hover { text-decoration-color: var(--text); }

.lgl-sub {
  font-family: var(--font-display), sans-serif; font-weight: 500; font-size: 1.0625rem;
  letter-spacing: -0.01em; color: var(--text); margin-top: 1.75rem; margin-bottom: 0.6rem;
}

.lgl-list { list-style: none; margin: 1rem 0 0; padding: 0; display: flex; flex-direction: column; gap: 0.7rem; }
.lgl-list li {
  position: relative; padding-left: 1.4rem; font-size: 1rem; line-height: 1.6;
  color: var(--text-2); max-width: 66ch;
}
.lgl-list li::before {
  content: ""; position: absolute; left: 0.1rem; top: 0.6rem; width: 0.36rem; height: 0.36rem;
  border: 0.0625rem solid var(--text-2); transform: rotate(45deg);
}
.lgl-list--check li { padding-left: 1.8rem; }
.lgl-list--check li::before { content: none; }
.lgl-list--check li > svg {
  position: absolute; left: 0; top: 0.2rem; width: 1.1rem; height: 1.1rem; color: var(--text);
}

/* ---------- sub-processor / integrations table ---------- */
.lgl-table { margin-top: 1.5rem; border: 0.0625rem solid var(--border); border-radius: 0.875rem; overflow: hidden; }
.lgl-table__row {
  display: grid; grid-template-columns: 13rem 1fr; gap: 1.25rem;
  padding: 1rem 1.25rem; border-top: 0.0625rem solid var(--border);
}
.lgl-table__row:first-child { border-top: 0; background: color-mix(in srgb, var(--surface) 70%, transparent); }
.lgl-table__row:first-child .lgl-table__k,
.lgl-table__row:first-child .lgl-table__v {
  font-family: var(--font-mono), monospace; font-size: 0.66rem; letter-spacing: 0.12em;
  text-transform: uppercase; color: var(--text-2);
}
.lgl-table__k { font-size: 0.9375rem; font-weight: 500; color: var(--text); }
.lgl-table__v { font-size: 0.9rem; line-height: 1.5; color: var(--text-2); }

/* ---------- contact callout ---------- */
.lgl-callout {
  margin-top: 1.5rem; border: 0.0625rem solid var(--border); border-radius: 1rem;
  background: var(--surface); padding: clamp(1.5rem, 3vw, 2rem);
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 1.25rem;
}
.lgl-callout__t { font-family: var(--font-display), sans-serif; font-size: 1.125rem; font-weight: 500; color: var(--text); letter-spacing: -0.01em; }
.lgl-callout__t span { display: block; font-family: var(--font-mono), monospace; font-size: 0.72rem; letter-spacing: 0.08em; text-transform: uppercase; color: var(--text-2); margin-top: 0.4rem; font-weight: 400; }
.lgl-mail {
  display: inline-flex; align-items: center; gap: 0.55rem; padding: 0.85em 1.4em; border-radius: 0.6em;
  font-family: var(--font-display), sans-serif; font-size: 0.95rem; font-weight: 500;
  background: var(--text); color: var(--bg); white-space: nowrap; transition: transform 0.15s ease;
}
.lgl-mail:hover { transform: translateY(-1px); }
.lgl-mail svg { width: 1.05rem; height: 1.05rem; }

/* ---------- cross-doc footer nav ---------- */
.lgl-docnav {
  margin-top: clamp(3rem, 6vw, 4.5rem); padding-top: 2rem; border-top: 0.0625rem solid var(--border);
  display: flex; flex-wrap: wrap; gap: 1rem;
}
.lgl-docnav__link {
  display: inline-flex; align-items: center; gap: 0.7rem; padding: 0.85em 1.4em; border-radius: 0.6em;
  border: 0.0625rem solid var(--border); font-size: 0.95rem; color: var(--text); white-space: nowrap;
  transition: border-color 0.2s ease, background 0.2s ease;
}
.lgl-docnav__link svg { width: 1.1rem; height: 1.1rem; flex: 0 0 auto; }
.lgl-docnav__link:hover { border-color: var(--text); background: color-mix(in srgb, var(--surface) 60%, transparent); }
.lgl-docnav__link .lab { font-family: var(--font-mono), monospace; font-size: 0.66rem; letter-spacing: 0.12em; text-transform: uppercase; color: var(--text-2); }

/* ---------- responsive ---------- */
@media (max-width: 64rem) {
  .lgl-layout { grid-template-columns: 1fr; gap: 2.5rem; }
  .lgl-toc {
    position: relative; top: 0; border: 0.0625rem solid var(--border); border-radius: 0.875rem;
    padding: 1.25rem 1.4rem; background: var(--surface);
  }
  .lgl-toc__list { display: grid; grid-template-columns: 1fr 1fr; gap: 0.1rem 1.5rem; }
}
@media (max-width: 40rem) {
  .lgl-tldr__grid { grid-template-columns: 1fr; }
  .lgl-toc__list { grid-template-columns: 1fr; }
  .lgl-table__row { grid-template-columns: 1fr; gap: 0.35rem; }
  .lgl-sec__head { gap: 0.6rem; }
  .lgl-callout { flex-direction: column; align-items: flex-start; }
}
