:root {
  color-scheme: light;
  --legal-ink: #0e172d;
  --legal-ink-2: #26344f;
  --legal-muted: #66758e;
  --legal-soft: #f6f8fd;
  --legal-soft-2: #eef4ff;
  --legal-paper: #ffffff;
  --legal-line: rgba(14, 23, 45, 0.1);
  --legal-line-strong: rgba(14, 23, 45, 0.16);
  --legal-blue: #3458ff;
  --legal-blue-2: #5d78ff;
  --legal-cyan: #24c7c1;
  --legal-pink: #ff6f9f;
  --legal-gold: #f5b657;
  --legal-shadow: 0 24px 80px rgba(32, 52, 96, 0.12);
  --legal-shadow-soft: 0 16px 50px rgba(32, 52, 96, 0.08);
  --legal-container: min(980px, calc(100vw - 48px));
  font-family: Inter, -apple-system, BlinkMacSystemFont, "PingFang SC", "Microsoft YaHei", "Helvetica Neue", Arial, sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  min-height: 100vh;
  margin: 0;
  padding: 48px 0 80px;
  color: var(--legal-ink);
  background:
    linear-gradient(180deg, rgba(248, 250, 255, 0.98) 0%, rgba(255, 255, 255, 0.96) 46%, #ffffff 100%),
    linear-gradient(90deg, rgba(52, 88, 255, 0.055) 0 1px, transparent 1px 100%),
    linear-gradient(180deg, rgba(52, 88, 255, 0.055) 0 1px, transparent 1px 100%);
  background-size: auto, 72px 72px, 72px 72px;
}

a {
  color: inherit;
}

:focus-visible {
  outline: 3px solid rgba(52, 88, 255, 0.32);
  outline-offset: 3px;
}

.legal-nav {
  position: fixed;
  z-index: 20;
  top: 18px;
  left: 0;
  right: 0;
  padding: 0 24px;
}

.legal-nav__inner {
  width: min(1120px, calc(100vw - 48px));
  min-height: 64px;
  margin: 0 auto;
  padding: 8px 10px 8px 16px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  border: 1px solid rgba(255, 255, 255, 0.82);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.78);
  box-shadow: 0 18px 70px rgba(28, 42, 82, 0.12);
  backdrop-filter: blur(24px) saturate(1.18);
}

.legal-brand {
  min-width: max-content;
  display: inline-flex;
  align-items: center;
  gap: 11px;
  color: var(--legal-ink);
  font-size: 17px;
  font-weight: 900;
  line-height: 1;
  text-decoration: none;
}

.legal-brand img {
  width: 44px;
  height: 44px;
  object-fit: contain;
}

.legal-nav__links {
  display: inline-flex;
  align-items: center;
  justify-content: flex-end;
  gap: 6px;
  min-width: 0;
}

.legal-nav__link {
  min-height: 40px;
  padding: 0 15px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid transparent;
  border-radius: 999px;
  color: rgba(14, 23, 45, 0.66);
  font-size: 13px;
  font-weight: 800;
  line-height: 1;
  text-decoration: none;
  white-space: nowrap;
  transition: transform 180ms ease, color 180ms ease, background 180ms ease, border-color 180ms ease;
}

.legal-nav__link:hover,
.legal-nav__link.is-active {
  color: var(--legal-ink);
  background: rgba(52, 88, 255, 0.08);
  border-color: rgba(52, 88, 255, 0.12);
}

.legal-nav__link:hover {
  transform: translateY(-1px);
}

.legal-nav__link--language {
  color: #ffffff;
  background: var(--legal-blue);
  box-shadow: 0 14px 28px rgba(52, 88, 255, 0.24);
}

.legal-nav__link--language:hover {
  color: #ffffff;
  background: #1f43f2;
}

.container {
  position: relative;
  max-width: var(--legal-container);
  margin: 0 auto;
  padding: clamp(44px, 6vw, 76px) clamp(24px, 7vw, 88px);
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.82);
  border-radius: 34px;
  background: rgba(255, 255, 255, 0.9);
  box-shadow: var(--legal-shadow);
}

.container::before {
  content: "";
  position: absolute;
  inset: 0 0 auto;
  height: 9px;
  background: linear-gradient(90deg, var(--legal-blue), var(--legal-cyan) 52%, var(--legal-pink));
}

.container::after {
  content: "Bifrost";
  position: absolute;
  top: 24px;
  right: clamp(24px, 7vw, 88px);
  color: rgba(52, 88, 255, 0.08);
  font-size: clamp(48px, 8vw, 92px);
  font-weight: 900;
  line-height: 1;
  pointer-events: none;
}

p.p1 {
  position: relative;
  z-index: 1;
  max-width: 780px;
  margin: 0 auto 16px;
  color: var(--legal-ink);
  font-size: clamp(34px, 5vw, 52px);
  font-weight: 900;
  line-height: 1.08;
  text-align: center;
  letter-spacing: 0;
}

p.p1 b {
  font-weight: inherit;
}

p.p2 {
  position: relative;
  z-index: 1;
  max-width: 720px;
  margin: 0 auto 44px;
  color: var(--legal-muted);
  font-size: 16px;
  font-weight: 500;
  line-height: 1.8;
  text-align: center;
}

.policy-dates {
  position: relative;
  z-index: 1;
  max-width: 820px;
  margin: -24px auto 34px;
  padding: 13px 18px;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 6px 10px;
  border: 1px solid rgba(52, 88, 255, 0.14);
  border-radius: 14px;
  color: var(--legal-ink-2);
  background: rgba(238, 244, 255, 0.72);
  font-size: 14px;
  line-height: 1.65;
  text-align: center;
}

.policy-dates strong {
  font-weight: 800;
}

p {
  margin: 0 0 17px;
  color: var(--legal-ink-2);
  font-size: 16px;
  line-height: 1.92;
}

p.p9,
p.p10,
p.p12,
p.p13 {
  margin-bottom: 17px;
}

b,
strong,
span.s1,
span.s2 {
  color: var(--legal-ink);
  font-weight: 800;
}

p.p8 {
  position: relative;
  margin: 58px 0 22px;
  padding: 18px 22px 18px 26px;
  border: 1px solid rgba(52, 88, 255, 0.12);
  border-radius: 18px;
  color: var(--legal-ink);
  background: linear-gradient(90deg, rgba(238, 244, 255, 0.92), rgba(255, 255, 255, 0.62));
  box-shadow: 0 12px 32px rgba(32, 52, 96, 0.06);
  font-size: 21px;
  font-weight: 900;
  line-height: 1.35;
}

.child-safety-standard {
  margin-top: 34px;
  padding: 4px clamp(20px, 4vw, 34px) 20px;
  scroll-margin-top: 28px;
  border: 1px solid rgba(255, 107, 93, 0.22);
  border-radius: 26px;
  background: rgba(255, 248, 243, 0.86);
}

.child-safety-standard p.p8 {
  margin-top: 20px;
  border-color: rgba(255, 107, 93, 0.22);
  background: rgba(255, 255, 255, 0.72);
}

.child-safety-standard a {
  color: #b73f36;
  font-weight: 800;
  overflow-wrap: anywhere;
}

p.p8::before {
  content: "";
  position: absolute;
  left: 0;
  top: 16px;
  bottom: 16px;
  width: 5px;
  border-radius: 999px;
  background: linear-gradient(180deg, var(--legal-blue), var(--legal-cyan));
}

table {
  width: 100%;
  margin: 30px 0;
  overflow: hidden;
  border: 1px solid var(--legal-line);
  border-radius: 20px;
  border-collapse: separate;
  border-spacing: 0;
  background: rgba(255, 255, 255, 0.9);
  box-shadow: var(--legal-shadow-soft);
}

td {
  padding: 17px 20px;
  border-right: 1px solid var(--legal-line);
  border-bottom: 1px solid var(--legal-line);
  color: var(--legal-ink-2);
  font-size: 15px;
  line-height: 1.72;
  vertical-align: top;
  overflow-wrap: anywhere;
}

td:last-child {
  border-right: none;
}

tr:last-child td {
  border-bottom: none;
}

tr td:first-child {
  width: 28%;
  color: var(--legal-ink);
  background: linear-gradient(180deg, rgba(246, 248, 253, 0.92), rgba(238, 244, 255, 0.7));
  font-weight: 800;
}

td p {
  margin: 0;
  color: inherit;
  font-size: 14.5px;
  line-height: 1.7;
}

.container > table:first-of-type {
  margin-top: 36px;
}

.container > table:first-of-type td {
  padding-top: 15px;
  padding-bottom: 15px;
}

.container > table:first-of-type tr td:first-child {
  width: 160px;
}

.container > table:nth-of-type(2) {
  border-color: rgba(52, 88, 255, 0.16);
  background: linear-gradient(135deg, rgba(238, 244, 255, 0.96), rgba(255, 255, 255, 0.88));
  box-shadow: 0 18px 52px rgba(52, 88, 255, 0.12);
}

.container > table:nth-of-type(2) td {
  border: none;
  padding: 22px 24px 22px 28px;
}

.container > table:nth-of-type(2) tr td:first-child {
  width: auto;
  background: transparent;
  font-weight: 500;
}

.container > table:nth-of-type(2) p {
  color: var(--legal-ink-2);
  font-size: 15.5px;
}

.container > table:nth-of-type(2) b,
.container > table:nth-of-type(2) strong,
.container > table:nth-of-type(2) span.s1 {
  font-weight: 900;
}

p:empty,
p.p5:empty,
p.p7:empty,
p.p14:empty {
  display: none;
}

p.p5,
p.p7,
p.p14 {
  margin: 0;
  height: 0;
}

@media (max-width: 820px) {
  body {
    padding: 24px 0 44px;
  }

  .legal-nav {
    top: 10px;
    padding: 0 12px;
  }

  .legal-nav__inner {
    width: calc(100vw - 24px);
    min-height: 58px;
    padding: 7px 8px 7px 12px;
    gap: 10px;
  }

  .legal-brand img {
    width: 38px;
    height: 38px;
  }

  .legal-brand span {
    display: none;
  }

  .legal-nav__links {
    gap: 4px;
    overflow-x: auto;
    scrollbar-width: none;
  }

  .legal-nav__links::-webkit-scrollbar {
    display: none;
  }

  .legal-nav__link {
    min-height: 36px;
    padding: 0 12px;
    font-size: 12px;
  }

  .container {
    width: calc(100vw - 24px);
    padding: 38px 18px 44px;
    border-radius: 24px;
  }

  .container::after {
    top: 18px;
    right: 18px;
    font-size: 48px;
  }

  p.p1 {
    font-size: clamp(30px, 9vw, 42px);
  }

  p.p2 {
    margin-bottom: 32px;
    font-size: 14.5px;
  }

  p {
    font-size: 15.5px;
    line-height: 1.88;
  }

  p.p8 {
    margin-top: 44px;
    padding: 15px 17px 15px 20px;
    border-radius: 16px;
    font-size: 18px;
  }

  table {
    display: block;
    margin: 24px 0;
    overflow-x: auto;
    white-space: normal;
    -webkit-overflow-scrolling: touch;
  }

  table tbody {
    display: table;
    width: 100%;
  }

  .container > table:nth-of-type(n+3) tbody {
    min-width: 680px;
  }

  td {
    padding: 14px 15px;
    font-size: 14px;
  }

  td p {
    font-size: 13.5px;
  }

  .container > table:first-of-type tr td:first-child {
    width: 118px;
  }
}

@media (max-width: 520px) {
  body {
    padding-bottom: 28px;
  }

  .legal-nav__link:not(.is-active):not(.legal-nav__link--language) {
    display: none;
  }

  .container {
    width: calc(100vw - 16px);
    padding: 34px 16px 38px;
    border-radius: 22px;
  }

  p.p1 {
    text-align: left;
  }

  p.p2 {
    text-align: left;
  }

  .container > table:first-of-type,
  .container > table:nth-of-type(2) {
    border-radius: 17px;
  }

  .container > table:first-of-type tr,
  .container > table:first-of-type td {
    display: block;
    width: 100%;
  }

  .container > table:first-of-type td {
    border-right: none;
  }

  .container > table:first-of-type tr td:first-child {
    width: auto;
    padding-bottom: 4px;
    border-bottom: none;
  }

  .container > table:first-of-type tr td:last-child {
    padding-top: 4px;
  }

  .container > table:nth-of-type(n+3) tbody {
    min-width: 620px;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    transition-duration: 0.01ms !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
  }
}

@media (prefers-color-scheme: dark) {
  :root {
    color-scheme: dark;
    --legal-ink: #f7f9ff;
    --legal-ink-2: #d7def0;
    --legal-muted: #9ba7c1;
    --legal-soft: #111827;
    --legal-soft-2: #18223a;
    --legal-paper: #111827;
    --legal-line: rgba(255, 255, 255, 0.1);
    --legal-line-strong: rgba(255, 255, 255, 0.18);
    --legal-shadow: 0 24px 80px rgba(0, 0, 0, 0.3);
    --legal-shadow-soft: 0 16px 50px rgba(0, 0, 0, 0.18);
  }

  body {
    background:
      linear-gradient(180deg, rgba(11, 18, 32, 0.98) 0%, rgba(12, 19, 34, 0.98) 52%, #0b1220 100%),
      linear-gradient(90deg, rgba(93, 120, 255, 0.08) 0 1px, transparent 1px 100%),
      linear-gradient(180deg, rgba(93, 120, 255, 0.08) 0 1px, transparent 1px 100%);
    background-size: auto, 72px 72px, 72px 72px;
  }

  .legal-nav__inner,
  .container,
  table {
    border-color: rgba(255, 255, 255, 0.1);
    background: rgba(17, 24, 39, 0.84);
  }

  .legal-nav__link {
    color: rgba(247, 249, 255, 0.72);
  }

  .legal-nav__link:hover,
  .legal-nav__link.is-active {
    color: var(--legal-ink);
    background: rgba(93, 120, 255, 0.16);
    border-color: rgba(93, 120, 255, 0.22);
  }

  p.p8,
  .container > table:nth-of-type(2) {
    background: linear-gradient(90deg, rgba(24, 34, 58, 0.92), rgba(17, 24, 39, 0.72));
  }

  tr td:first-child {
    background: linear-gradient(180deg, rgba(24, 34, 58, 0.92), rgba(17, 24, 39, 0.7));
  }
}
