/* Legal pages — Соглашение и Политика. Минимум поверх tokens.css. */

* { box-sizing: border-box; margin: 0; padding: 0; }
html, body { height: 100%; }
body {
  font-family: -apple-system, BlinkMacSystemFont, 'SF Pro Display', 'Segoe UI', 'Inter', Roboto, 'Helvetica Neue', Arial, sans-serif;
  background: var(--bg);
  color: var(--fg);
  -webkit-font-smoothing: antialiased;
  min-height: 100svh;
  position: relative;
}

body::before {
  content: '';
  position: fixed;
  inset: 0;
  background:
    radial-gradient(900px 700px at 10% 0%,    rgba(255, 180, 140, 0.20), transparent 65%),
    radial-gradient(800px 600px at 90% 10%,   rgba(229,  99,  63, 0.10), transparent 65%),
    linear-gradient(180deg, var(--bg) 0%, var(--bg-2) 100%);
  z-index: -2;
}

.wrap {
  min-height: 100svh;
  display: flex;
  flex-direction: column;
  padding: 32px 24px;
  max-width: 880px;
  margin: 0 auto;
}

header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-bottom: 16px;
}
.logo {
  display: flex;
  align-items: center;
  gap: 12px;
  font-weight: 700;
  font-size: 18px;
  letter-spacing: -0.01em;
  color: var(--fg);
  text-decoration: none;
}
.logo-mark {
  width: 32px;
  height: 32px;
  border-radius: 10px;
  background: conic-gradient(from 210deg, #e5633f, #ffa66b, #5c8076, #e5633f);
  box-shadow: 0 4px 20px rgba(229, 99, 63, 0.40);
  position: relative;
  flex-shrink: 0;
}
.logo-mark::after {
  content: '';
  position: absolute;
  inset: 6px;
  border-radius: 6px;
  background: #ffffff;
}
.logo-mark::before {
  content: '';
  position: absolute;
  inset: 10px;
  border-radius: 999px;
  background: radial-gradient(circle, #e5633f, #ffa66b);
  z-index: 1;
}
.back-link {
  color: var(--muted);
  text-decoration: none;
  font-size: 14px;
  transition: color 0.15s;
}
.back-link:hover { color: var(--fg); }

main.legal {
  flex: 1;
  padding: 32px 0 64px;
  font-size: 16px;
  line-height: 1.7;
  color: var(--fg);
}

main.legal h1 {
  font-family: Georgia, 'Times New Roman', serif;
  font-size: clamp(28px, 5vw, 40px);
  font-weight: 800;
  letter-spacing: -0.02em;
  line-height: 1.15;
  margin-bottom: 16px;
}
main.legal h2 {
  font-size: clamp(20px, 3vw, 24px);
  font-weight: 700;
  margin-top: 36px;
  margin-bottom: 12px;
  letter-spacing: -0.01em;
}
main.legal h3 {
  font-size: 17px;
  font-weight: 600;
  margin-top: 24px;
  margin-bottom: 8px;
  color: var(--muted);
}
main.legal p {
  margin-bottom: 14px;
  color: var(--fg);
}
main.legal p em {
  color: var(--muted);
  font-style: normal;
  font-size: 14px;
}
main.legal ul,
main.legal ol {
  margin: 0 0 14px 24px;
}
main.legal li {
  margin-bottom: 6px;
}
main.legal a {
  color: var(--primary);
  text-decoration: underline;
  text-underline-offset: 2px;
  text-decoration-thickness: 1px;
}
main.legal a:hover {
  text-decoration-thickness: 2px;
}
main.legal strong {
  font-weight: 600;
  color: var(--fg);
}

footer {
  padding-top: 32px;
  border-top: 1px solid var(--border);
  display: flex;
  justify-content: space-between;
  align-items: center;
  color: var(--muted-2);
  font-size: 13px;
  flex-wrap: wrap;
  gap: 12px;
}
footer a { color: var(--muted-2); text-decoration: none; transition: color 0.15s; }
footer a:hover { color: var(--muted); }
.footer-links { display: flex; gap: 18px; flex-wrap: wrap; }
