:root {
  color-scheme: light;
  --ink: #101820;
  --muted: #5d6972;
  --line: #d9e1e5;
  --paper: #f7f9f8;
  --surface: #ffffff;
  --accent: #008b74;
  --accent-soft: #e0f4ee;
  --navy: #0b2530;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  overflow-x: hidden;
}

html[dir="rtl"] {
  direction: rtl;
}

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family:
    "Plus Jakarta Sans",
    -apple-system,
    BlinkMacSystemFont,
    "Segoe UI",
    sans-serif;
  line-height: 1.75;
  overflow-x: hidden;
}

a {
  color: inherit;
}

.legal-header {
  position: sticky;
  top: 0;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 72px;
  padding: 0 5vw;
  border-bottom: 1px solid rgba(217, 225, 229, 0.9);
  background: rgba(247, 249, 248, 0.94);
  backdrop-filter: blur(16px);
}

.legal-brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--ink);
  font-size: 20px;
  font-weight: 800;
  text-decoration: none;
}

.legal-brand img {
  width: 36px;
  height: 36px;
  border-radius: 8px;
}

.legal-nav {
  display: flex;
  align-items: center;
  gap: 24px;
}

.legal-nav a {
  color: var(--muted);
  font-size: 14px;
  font-weight: 700;
  text-decoration: none;
}

.legal-nav a:hover,
.legal-nav a[aria-current="page"] {
  color: var(--accent);
}

.legal-header-tools {
  display: flex;
  align-items: center;
  gap: 20px;
}

.language-menu {
  position: relative;
}

.language-menu summary {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  min-height: 38px;
  padding: 0 11px;
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--muted);
  background: var(--surface);
  cursor: pointer;
  font-size: 12px;
  font-weight: 700;
  list-style: none;
  white-space: nowrap;
}

.language-menu summary::-webkit-details-marker {
  display: none;
}

.language-menu summary::after {
  width: 6px;
  height: 6px;
  border-right: 1.5px solid currentColor;
  border-bottom: 1.5px solid currentColor;
  content: "";
  transform: rotate(45deg) translateY(-2px);
}

.language-icon {
  color: var(--accent);
  font-size: 13px;
  font-weight: 800;
}

.language-menu > nav {
  position: absolute;
  top: calc(100% + 9px);
  right: 0;
  z-index: 20;
  display: grid;
  min-width: 168px;
  overflow: hidden;
  padding-block: 6px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  box-shadow: 0 18px 45px rgba(11, 37, 48, 0.14);
}

html[dir="rtl"] .language-menu > nav {
  right: auto;
  left: 0;
}

.language-menu > nav a {
  padding: 8px 13px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
  line-height: 1.3;
  text-decoration: none;
}

.language-menu > nav a:hover,
.language-menu > nav a[aria-current="page"] {
  color: var(--accent);
  background: var(--accent-soft);
}

.legal-main {
  width: min(920px, calc(100% - 40px));
  margin: 0 auto;
  padding: 72px 0 96px;
}

.legal-hero {
  padding-bottom: 40px;
  border-bottom: 1px solid var(--line);
}

.legal-kicker {
  display: inline-flex;
  align-items: center;
  min-height: 30px;
  padding: 0 12px;
  border-radius: 6px;
  background: var(--accent-soft);
  color: var(--accent);
  font-size: 12px;
  font-weight: 800;
}

.legal-hero h1 {
  max-width: 760px;
  margin: 24px 0 18px;
  font-size: clamp(38px, 6vw, 64px);
  line-height: 1.08;
  letter-spacing: 0;
}

.legal-hero p {
  max-width: 720px;
  margin: 0;
  color: var(--muted);
  font-size: 17px;
}

.legal-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 18px;
  margin-top: 24px;
  color: var(--muted);
  font-size: 13px;
}

.legal-content {
  padding-top: 24px;
}

.legal-section {
  padding: 34px 0;
  border-bottom: 1px solid var(--line);
}

.legal-section h2 {
  margin: 0 0 14px;
  font-size: 24px;
  line-height: 1.3;
  letter-spacing: 0;
}

.legal-section h3 {
  margin: 24px 0 8px;
  font-size: 17px;
  letter-spacing: 0;
}

.legal-section p,
.legal-section li {
  color: #34434d;
}

.legal-section ul,
.legal-section ol {
  margin: 12px 0 0;
  padding-left: 22px;
}

html[dir="rtl"] .legal-section ul,
html[dir="rtl"] .legal-section ol {
  padding-right: 22px;
  padding-left: 0;
}

html[dir="rtl"] .legal-note {
  border-right: 3px solid var(--accent);
  border-left: 0;
}

.legal-section li + li {
  margin-top: 8px;
}

.legal-note {
  margin: 20px 0 0;
  padding: 18px 20px;
  border-left: 3px solid var(--accent);
  background: var(--surface);
  color: #34434d;
}

.support-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
  margin-top: 20px;
}

.support-item {
  padding: 20px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
}

.support-item strong {
  display: block;
  margin-bottom: 6px;
  font-size: 16px;
}

.support-item p {
  margin: 0;
  font-size: 14px;
}

.contact-box {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  margin-top: 18px;
  padding: 22px;
  border-radius: 8px;
  background: var(--navy);
  color: #ffffff;
}

.contact-box p {
  margin: 0;
  color: #c8d9dd;
}

.contact-box a {
  flex: 0 0 auto;
  padding: 11px 16px;
  border-radius: 6px;
  background: #ffffff;
  color: var(--navy);
  font-size: 13px;
  font-weight: 800;
  text-decoration: none;
}

.legal-footer {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 28px 5vw;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 13px;
}

.legal-footer div {
  display: flex;
  gap: 18px;
}

.legal-footer a {
  text-decoration: none;
}

@media (max-width: 700px) {
  .legal-header {
    min-height: 64px;
  }

  .legal-nav {
    display: none;
  }

  .legal-header-tools {
    gap: 0;
  }

  .language-current {
    display: none;
  }

  .language-menu summary {
    width: 40px;
    padding: 0;
    justify-content: center;
  }

  .language-menu summary::after {
    display: none;
  }

  .legal-main {
    width: min(100% - 32px, 920px);
    padding: 48px 0 72px;
  }

  .legal-hero h1 {
    font-size: 40px;
  }

  .support-grid {
    grid-template-columns: 1fr;
  }

  .contact-box {
    align-items: flex-start;
    flex-direction: column;
  }
}
