:root {
  --page-bg: #f3f7fb;
  --surface: #ffffff;
  --line: #dbe7f0;
  --text: #0f172a;
  --muted: #64748b;
  --primary: #0f766e;
  --primary-strong: #115e59;
}

* {
  box-sizing: border-box;
}

html,
body {
  width: 100%;
  max-width: 100%;
  overflow-x: hidden;
}

body {
  margin: 0;
  min-height: 100vh;
  font-family: 'Inter', system-ui, -apple-system, sans-serif;
  color: var(--text);
  background:
    radial-gradient(circle at top left, rgba(15, 118, 110, 0.11), transparent 26rem),
    linear-gradient(180deg, #f9fbfd 0%, var(--page-bg) 100%);
}

.legal-shell {
  position: relative;
  min-height: 100vh;
  padding: 24px 12px 150px;
}

.legal-wave-zone {
  pointer-events: none;
  position: absolute;
  left: 50%;
  width: 140vw;
  transform: translateX(-50%);
  z-index: 0;
}

.legal-wave-zone-top {
  top: 0;
  height: 180px;
}

.legal-wave-zone-bottom {
  bottom: 0;
  height: 210px;
}

.legal-wave {
  position: absolute;
  left: -20vw;
  width: 180vw;
  min-width: 1200px;
  transform-origin: center;
  will-change: transform;
}

.legal-wave svg {
  display: block;
  width: 100%;
  height: 100%;
}

.legal-wave path {
  fill: currentColor;
}

.legal-wave-top-1 {
  top: 0;
  height: 170px;
  color: rgba(168, 220, 209, 0.56);
  animation: legalWaveFloatA 14s ease-in-out infinite;
}

.legal-wave-top-2 {
  top: 14px;
  height: 164px;
  color: rgba(47, 143, 131, 0.2);
  animation: legalWaveFloatB 11s ease-in-out infinite;
}

.legal-wave-top-3 {
  top: 24px;
  height: 152px;
  color: rgba(31, 111, 99, 0.14);
  animation: legalWaveFloatC 18s ease-in-out infinite;
}

.legal-wave-bottom-1 {
  bottom: 0;
  height: 180px;
  color: rgba(168, 220, 209, 0.56);
  animation: legalWaveFloatA 16s ease-in-out infinite reverse;
}

.legal-wave-bottom-2 {
  bottom: 10px;
  height: 170px;
  color: rgba(47, 143, 131, 0.22);
  animation: legalWaveFloatB 12s ease-in-out infinite reverse;
}

.legal-wave-bottom-3 {
  bottom: 20px;
  height: 162px;
  color: rgba(31, 111, 99, 0.16);
  animation: legalWaveFloatC 20s ease-in-out infinite reverse;
}

.legal-wrap {
  position: relative;
  z-index: 2;
  width: min(960px, calc(100% - 8px));
  margin: 0 auto;
}

.legal-topbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  margin-bottom: 14px;
  padding: 10px 14px;
  border: 1px solid rgba(255, 255, 255, 0.82);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.7);
  backdrop-filter: blur(12px);
  box-shadow: 0 12px 30px rgba(15, 23, 42, 0.09);
}

.legal-brand {
  display: inline-flex;
  align-items: center;
  border-radius: 14px;
  transition: transform 0.18s ease;
  text-decoration: none;
}

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

.legal-brand img {
  width: 52px;
  height: 52px;
  object-fit: cover;
  border-radius: 14px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.82);
  display: block;
}

.legal-home-link {
  text-decoration: none;
  color: var(--primary);
  border: 1px solid rgba(15, 118, 110, 0.28);
  background: rgba(15, 118, 110, 0.09);
  padding: 9px 13px;
  border-radius: 999px;
  font-size: 14px;
  font-weight: 700;
  white-space: nowrap;
}

.legal-card {
  border: 1px solid var(--line);
  border-radius: 24px;
  background: var(--surface);
  box-shadow: 0 24px 52px rgba(15, 23, 42, 0.12);
  padding: 24px;
}

h1 {
  margin: 0 0 14px;
  font-size: clamp(30px, 4.4vw, 46px);
  line-height: 1.05;
}

h2 {
  margin: 20px 0 8px;
  font-size: clamp(19px, 2.8vw, 23px);
}

p,
li {
  color: #334155;
  line-height: 1.65;
}

ul {
  margin: 10px 0 0;
  padding-left: 18px;
}

.legal-note {
  margin-top: 18px;
  padding: 12px 14px;
  border-radius: 14px;
  border: 1px solid rgba(15, 118, 110, 0.24);
  background: rgba(15, 118, 110, 0.08);
}

a {
  color: var(--primary);
  font-weight: 700;
}

a:hover {
  color: var(--primary-strong);
}

@keyframes legalWaveFloatA {
  0% { transform: translateX(-2%); }
  50% { transform: translateX(2.4%); }
  100% { transform: translateX(-2%); }
}

@keyframes legalWaveFloatB {
  0% { transform: translateX(1.4%); }
  50% { transform: translateX(-2.2%); }
  100% { transform: translateX(1.4%); }
}

@keyframes legalWaveFloatC {
  0% { transform: translateX(-1%); }
  50% { transform: translateX(1.6%); }
  100% { transform: translateX(-1%); }
}

@media (max-width: 720px) {
  .legal-shell {
    padding: 12px 8px 136px;
  }

  .legal-wrap {
    width: 100%;
  }

  .legal-topbar {
    border-radius: 16px;
    padding: 9px 10px;
    gap: 8px;
  }

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

  .legal-home-link {
    padding: 8px 10px;
    font-size: 13px;
  }

  .legal-card {
    border-radius: 20px;
    padding: 18px;
  }

  .legal-wave-zone-top {
    height: 150px;
  }

  .legal-wave-zone-bottom {
    height: 178px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .legal-wave {
    animation: none !important;
  }
}
