:root {
  --bg: #f6f8fb;
  --surface: #ffffff;
  --text: #07142b;
  --muted: #617086;
  --line: #cfdae8;
  --blue: #22aee5;
}

* { box-sizing: border-box; }

body.legal-page {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: "Inter", "Yu Gothic", "Meiryo", system-ui, sans-serif;
  font-size: 14px;
  line-height: 1.7;
}

body.legal-page a { color: inherit; text-decoration: none; }

body.legal-page .simple-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 70px;
  padding: 0 28px;
  background: #fff;
  border-bottom: 1px solid var(--line);
}

body.legal-page .brand {
  font-size: 28px;
  font-weight: 900;
}

body.legal-page .simple-header nav {
  display: flex;
  gap: 18px;
  font-weight: 700;
}

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

.legal-shell > h1 {
  margin: 0 0 8px;
  font-size: 28px;
}

.legal-lead {
  margin: 0 0 28px;
  color: var(--muted);
}

.legal-section {
  margin-bottom: 24px;
  padding: 24px 28px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 8px;
}

.legal-section h2 {
  margin: 0 0 12px;
  font-size: 18px;
}

.legal-section p {
  margin: 0 0 12px;
}

.legal-section p:last-child,
.legal-section ul:last-child {
  margin-bottom: 0;
}

.legal-section ul {
  margin: 0;
  padding-left: 1.4em;
}

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

.legal-table {
  width: 100%;
  border-collapse: collapse;
}

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

.legal-table th {
  width: 32%;
  background: #f0f4f9;
  font-weight: 700;
}

.faq-list {
  display: grid;
  gap: 16px;
}

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

.faq-item h2 {
  margin: 0 0 10px;
  font-size: 16px;
}

.faq-item h2::before {
  content: "Q. ";
  color: var(--blue);
  font-weight: 900;
}

.faq-item p {
  margin: 0;
}

.faq-item p::before {
  content: "A. ";
  color: var(--muted);
  font-weight: 700;
}

.contact-form {
  display: grid;
  gap: 18px;
  padding: 28px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 8px;
}

.contact-form label {
  display: grid;
  gap: 8px;
  font-weight: 700;
}

.contact-form input,
.contact-form textarea {
  width: 100%;
  padding: 12px 14px;
  border: 1px solid var(--line);
  border-radius: 6px;
  font: inherit;
  background: #fff;
}

.contact-form textarea {
  min-height: 160px;
  resize: vertical;
}

.contact-form button {
  justify-self: start;
  padding: 12px 28px;
  border: none;
  border-radius: 6px;
  background: var(--blue);
  color: #fff;
  font: inherit;
  font-weight: 700;
  cursor: pointer;
}

.contact-form button:hover {
  opacity: 0.92;
}

.success-message {
  margin: 16px 0 0;
  padding: 14px 18px;
  background: #e8f7ef;
  border: 1px solid #9ed4b6;
  border-radius: 6px;
  color: #1f6b3f;
  font-weight: 700;
}

.site-footer {
  padding: 28px 24px 36px;
  background: #fff;
  border-top: 1px solid var(--line);
  text-align: center;
}

.site-footer nav {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 12px 20px;
  margin-bottom: 12px;
  font-size: 13px;
  font-weight: 700;
}

.site-footer nav a:hover {
  color: var(--blue);
}

.site-footer p {
  margin: 0;
  color: var(--muted);
  font-size: 12px;
}

@media (max-width: 640px) {
  body.legal-page .simple-header {
    flex-direction: column;
    align-items: flex-start;
    gap: 12px;
    padding: 16px 20px;
  }

  .legal-section,
  .contact-form {
    padding: 18px 20px;
  }

  .legal-table th,
  .legal-table td {
    display: block;
    width: 100%;
  }

  .legal-table th {
    border-bottom: none;
  }
}
