:root {
  color-scheme: light;
  --bg: #f6f3ea;
  --surface: #fffdf7;
  --line: #d7cbb5;
  --text: #29241d;
  --muted: #756b5e;
  --accent: #24758a;
  --accent-dark: #16596b;
  --font-ui: "Noto Sans JP", "Noto Sans", -apple-system, BlinkMacSystemFont, "Hiragino Kaku Gothic ProN", "Yu Gothic", "Segoe UI", sans-serif;
  --font-ui-rounded: "Gen Jyuu Gothic", "Zen Maru Gothic", "M PLUS Rounded 1c", "Hiragino Maru Gothic ProN", "Arial Rounded MT Bold", "Noto Sans JP", "Noto Sans", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-family: var(--font-ui);
}

html[lang="zh-Hans"] {
  --font-ui: "PingFang SC", "Hiragino Sans GB", "Noto Sans CJK SC", "Noto Sans SC", "Microsoft YaHei", sans-serif;
  --font-ui-rounded: "PingFang SC", "Hiragino Sans GB", "Noto Sans CJK SC", "Noto Sans SC", "Microsoft YaHei", sans-serif;
}

html[lang="zh-Hant"] {
  --font-ui: "PingFang TC", "Noto Sans CJK TC", "Noto Sans TC", "Microsoft JhengHei", sans-serif;
  --font-ui-rounded: "PingFang TC", "Noto Sans CJK TC", "Noto Sans TC", "Microsoft JhengHei", sans-serif;
}

html[lang="ko"] {
  --font-ui: "Apple SD Gothic Neo", "Noto Sans KR", "Noto Sans CJK KR", "Malgun Gothic", sans-serif;
  --font-ui-rounded: "Apple SD Gothic Neo", "Noto Sans KR", "Noto Sans CJK KR", "Malgun Gothic", sans-serif;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
}

a {
  color: var(--accent-dark);
  font-family: var(--font-ui-rounded);
  font-weight: 700;
}

select {
  font-family: var(--font-ui);
  min-height: 42px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fffaf0;
  color: var(--text);
  padding: 0 12px;
  font: inherit;
}

.legal-shell {
  width: min(920px, calc(100vw - 32px));
  margin: 0 auto;
  padding: 28px 0 48px;
}

.legal-header {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 18px;
}

.back-link {
  text-decoration: none;
}

.language-select {
  display: grid;
  gap: 6px;
  color: var(--muted);
  font-size: 0.9rem;
  font-weight: 700;
}

.legal-card {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  padding: clamp(20px, 4vw, 42px);
}

.eyebrow {
  margin: 0 0 8px;
  color: var(--muted);
  font-family: var(--font-ui-rounded);
  font-size: 0.86rem;
  font-weight: 800;
  text-transform: uppercase;
}

h1 {
  font-family: var(--font-ui-rounded);
  margin: 0 0 10px;
  font-size: clamp(2rem, 6vw, 4rem);
  line-height: 0.98;
  letter-spacing: 0;
}

.updated {
  margin: 0 0 28px;
  color: var(--muted);
  line-height: 1.6;
}

section {
  padding: 22px 0;
  border-top: 1px solid var(--line);
}

section:first-of-type {
  border-top: 0;
}

h2 {
  margin: 0 0 10px;
  font-size: 1.25rem;
}

p,
li {
  line-height: 1.78;
}

p {
  margin: 0 0 12px;
}

ul {
  margin: 0;
  padding-left: 1.25rem;
}

.legal-footer {
  margin-top: 28px;
  padding-top: 18px;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 0.95rem;
  line-height: 1.7;
}

.commerce-table {
  width: 100%;
  border-collapse: collapse;
  border: 1px solid var(--line);
  background: #fffaf0;
}

.commerce-table th,
.commerce-table td {
  border-top: 1px solid var(--line);
  padding: 14px 16px;
  text-align: left;
  vertical-align: top;
  line-height: 1.7;
}

.commerce-table tr:first-child th,
.commerce-table tr:first-child td {
  border-top: 0;
}

.commerce-table th {
  width: 30%;
  color: var(--muted);
  font-weight: 800;
}

@media (max-width: 680px) {
  .legal-header {
    align-items: stretch;
    flex-direction: column;
  }

  .language-select {
    width: 100%;
  }

  select {
    width: 100%;
  }

  .commerce-table,
  .commerce-table tbody,
  .commerce-table tr,
  .commerce-table th,
  .commerce-table td {
    display: block;
    width: 100%;
  }

  .commerce-table td {
    border-top: 0;
    padding-top: 0;
  }
}
