@import url("https://fonts.googleapis.com/css2?family=Manrope:wght@400;500;600;700&display=swap");

:root {
  --font: "Manrope", sans-serif;
  --accent: #00d97e;
  --accent-dim: rgba(0, 217, 126, 0.15);
  --link: #58a6ff;
  --link-underline: rgba(88, 166, 255, 0.4);
  --bg: #0d1117;
  --surface: #161b22;
  --surface-hover: #21262d;
  --text: #e6edf3;
  --text-muted: #8b949e;
  --border: rgba(255, 255, 255, 0.08);
  --shadow: 0 16px 48px rgba(0, 0, 0, 0.4);
  --radius: 12px;
  --radius-sm: 8px;
}

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

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font);
  background: var(--bg);
  color: var(--text);
  line-height: 1.7;
  min-height: 100vh;
}

.privacy {
  max-width: 720px;
  margin: 0 auto;
  padding: 3rem 1.5rem 4rem;
}

.privacy-header {
  position: relative;
  text-align: center;
  margin-bottom: 3rem;
  padding-bottom: 2rem;
  border-bottom: 1px solid var(--border);
}

.privacy-logo {
  display: block;
  margin: 0 auto 1.25rem;
  width: 80px;
  height: 80px;
  object-fit: contain;
}

.theme-toggle-wrap {
  position: absolute;
  top: 0;
  right: 0;
}

.theme-toggle {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 2.75rem;
  height: 2.75rem;
  padding: 0;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--surface);
  color: var(--text);
  cursor: pointer;
  transition: background 0.2s ease, border-color 0.2s ease, transform 0.15s ease;
}

.theme-toggle:hover {
  background: var(--surface-hover);
  border-color: var(--text-muted);
}

.theme-toggle:focus {
  outline: none;
  box-shadow: 0 0 0 2px var(--accent);
}

.theme-toggle-icon {
  font-size: 1.25rem;
  line-height: 1;
}

.theme-toggle .theme-icon-light {
  display: none;
}

.theme-toggle .theme-icon-dark {
  display: inline;
}

html[data-theme="light"] .theme-toggle .theme-icon-light {
  display: inline;
}

html[data-theme="light"] .theme-toggle .theme-icon-dark {
  display: none;
}

.privacy-header h1 {
  font-size: clamp(1.5rem, 4vw, 2rem);
  font-weight: 700;
  color: var(--text);
  margin-bottom: 0.5rem;
  letter-spacing: -0.02em;
}

.privacy-label {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--accent);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 0.5rem;
}

.privacy-header .meta {
  font-size: 0.9rem;
  color: var(--text-muted);
  margin-bottom: 1rem;
}

.privacy-header .intro {
  font-size: 0.95rem;
  color: var(--text-muted);
  margin-bottom: 1.25rem;
  line-height: 1.6;
}

.privacy-header .meta a {
  color: var(--accent);
  text-decoration: none;
  font-weight: 500;
}

.privacy-header .meta a:hover {
  text-decoration: underline;
}

.privacy section {
  margin-bottom: 2.5rem;
}

.privacy section h2 {
  font-size: 1.15rem;
  font-weight: 600;
  color: var(--accent);
  margin-bottom: 1rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.privacy section h2::before {
  content: "";
  width: 4px;
  height: 1.2em;
  background: linear-gradient(180deg, var(--accent), transparent);
  border-radius: 2px;
}

.privacy section p {
  font-size: 0.95rem;
  color: var(--text-muted);
  margin-bottom: 0.75rem;
}

.privacy section p:last-child {
  margin-bottom: 0;
}

.privacy section ul {
  list-style: none;
  margin: 0.5rem 0 1rem;
}

.privacy section ul li {
  position: relative;
  padding-left: 1.25rem;
  margin-bottom: 0.4rem;
  font-size: 0.95rem;
  color: var(--text-muted);
}

.privacy section ul li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.55em;
  width: 6px;
  height: 6px;
  background: var(--accent);
  border-radius: 50%;
  opacity: 0.8;
}

.privacy .contact-block {
  background: var(--accent-dim);
  border: 1px solid rgba(0, 217, 126, 0.25);
  border-radius: var(--radius-sm);
  padding: 1rem 1.25rem;
  margin: 1rem 0;
}

.privacy .contact-block a {
  text-decoration: underline;
  text-decoration-color: rgba(0, 217, 126, 0.4);
}

.privacy .contact-primary {
  margin-top: 1rem;
  line-height: 1.7;
}

.privacy .contact-block a {
  color: var(--accent);
  font-weight: 600;
}

/* Все ссылки в тексте политики — явное оформление (цвет + подчёркивание) */
.privacy a {
  color: var(--link);
  text-decoration: underline;
  text-decoration-color: var(--link-underline);
  text-underline-offset: 0.15em;
  font-weight: 500;
  transition: color 0.2s ease, text-decoration-color 0.2s ease;
}

.privacy a:hover {
  color: #79b8ff;
  text-decoration-color: var(--link);
}

.privacy a:focus {
  outline: 2px solid var(--link);
  outline-offset: 2px;
}

/* Ссылки в шапке и контакт-блоке остаются в акцентном цвете */
.privacy-header .meta a,
.privacy .contact-block a {
  color: var(--accent);
  text-decoration: underline;
  text-decoration-color: rgba(0, 217, 126, 0.4);
}

.privacy-header .meta a:hover,
.privacy .contact-block a:hover {
  color: #00e88b;
  text-decoration-color: var(--accent);
}

.privacy-footer {
  margin-top: 3rem;
  padding-top: 2rem;
  border-top: 1px solid var(--border);
  font-size: 0.9rem;
  color: var(--text-muted);
  text-align: center;
}

/* Светлая тема (включается переключателем или системной настройкой при первой загрузке) */
html[data-theme="light"] {
  --bg: #f6f8fa;
  --surface: #ffffff;
  --surface-hover: #f0f2f5;
  --text: #1f2328;
  --text-muted: #656d76;
  --border: rgba(0, 0, 0, 0.08);
  --shadow: 0 16px 48px rgba(0, 0, 0, 0.08);
  --link: #0969da;
  --link-underline: rgba(9, 105, 218, 0.35);
}

html[data-theme="light"] .privacy-logo {
  filter: invert(1);
}

html[data-theme="light"] .privacy section h2 {
  color: #0d8c5a;
}

html[data-theme="light"] .privacy section ul li::before {
  background: #0d8c5a;
}

html[data-theme="light"] .privacy a:hover {
  color: #0550ae;
}

html[data-theme="light"] .privacy-header .meta a,
html[data-theme="light"] .privacy .contact-block a {
  color: #0d8c5a;
}

html[data-theme="light"] .privacy .contact-block a:hover {
  color: #0a6e3e;
}

html[data-theme="light"] .privacy .contact-block {
  background: rgba(0, 217, 126, 0.08);
  border-color: rgba(0, 217, 126, 0.3);
}
