:root {
  --bg: #fbfaf7;
  --surface: #ffffff;
  --text: #1f2328;
  --muted: #5d6470;
  --line: #e3e0d8;
  --accent: #1a7f5a;
  --accent-ink: #ffffff;
  --warn: #b3261e;
  --quote: #f3f1ea;
  --radius: 10px;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #15171a;
    --surface: #1d2024;
    --text: #e8e6e1;
    --muted: #a3a9b3;
    --line: #33373d;
    --accent: #4cc490;
    --accent-ink: #0c1f17;
    --warn: #ff8a80;
    --quote: #24282d;
  }
}
:root[data-theme="dark"] {
  --bg: #15171a;
  --surface: #1d2024;
  --text: #e8e6e1;
  --muted: #a3a9b3;
  --line: #33373d;
  --accent: #4cc490;
  --accent-ink: #0c1f17;
  --warn: #ff8a80;
  --quote: #24282d;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: "Hiragino Sans", "Noto Sans JP", "Yu Gothic", system-ui, sans-serif;
  line-height: 1.8;
  font-size: 16px;
}
a { color: var(--accent); }
.wrap { max-width: 760px; margin: 0 auto; padding: 0 16px; }
header.site, footer.site { border-bottom: 1px solid var(--line); }
footer.site { border-top: 1px solid var(--line); border-bottom: 0; margin-top: 64px; padding: 24px 0; color: var(--muted); font-size: 14px; }
header.site .wrap { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding-top: 12px; padding-bottom: 12px; flex-wrap: wrap; }
header.site a { text-decoration: none; color: var(--text); font-weight: 700; }
header.site nav a { font-weight: 400; color: var(--muted); margin-left: 16px; font-size: 14px; }

h1 { font-size: clamp(1.5rem, 4.5vw, 2.1rem); line-height: 1.4; margin: 40px 0 12px; }
h2 { font-size: 1.35rem; margin: 48px 0 12px; padding-bottom: 6px; border-bottom: 2px solid var(--line); }
h3 { font-size: 1.1rem; margin: 28px 0 8px; }
.lead { color: var(--muted); }
.toc { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 12px 20px; }
.toc ol { margin: 0; padding-left: 1.2em; }

.example {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 14px 16px;
  margin: 12px 0;
}
.example .review { background: var(--quote); border-radius: 6px; padding: 8px 12px; margin: 0 0 10px; font-size: 15px; }
.example .review::before { content: "クチコミ: "; font-weight: 700; }
.example .reply { white-space: pre-wrap; margin: 0; }
.example .reply::before { content: "返信例: "; font-weight: 700; display: block; }
.ng { border-color: var(--warn); }
.ng .reply::before { content: "NG例: "; color: var(--warn); }
.why { color: var(--muted); font-size: 14px; margin: 8px 0 0; }

.tool { background: var(--surface); border: 2px solid var(--accent); border-radius: var(--radius); padding: 16px; margin: 20px 0; }
.tool .grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
@media (max-width: 560px) { .tool .grid { grid-template-columns: 1fr; } }
label { display: block; font-size: 14px; font-weight: 700; margin-bottom: 4px; }
input, select, textarea {
  width: 100%;
  font: inherit;
  padding: 8px 10px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: var(--bg);
  color: var(--text);
}
.hint { color: var(--muted); font-size: 13px; margin: 2px 0 0; }
.btn {
  display: inline-block;
  background: var(--accent);
  color: var(--accent-ink);
  border: 0;
  border-radius: 8px;
  padding: 10px 18px;
  font: inherit;
  font-weight: 700;
  cursor: pointer;
  text-decoration: none;
}
.btn.secondary { background: transparent; color: var(--accent); border: 1px solid var(--accent); padding: 4px 12px; font-size: 14px; }
.btn[aria-disabled="true"] { opacity: .5; pointer-events: none; }
.result { margin-top: 12px; }
.result .example .reply::before { content: none; }

.cta { background: var(--surface); border: 1px solid var(--line); border-left: 6px solid var(--accent); border-radius: var(--radius); padding: 16px 20px; margin: 32px 0; }
.cta p { margin: 4px 0 12px; }
.price { font-size: 1.6rem; font-weight: 700; }
.mail-mock { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 16px; font-size: 14px; }
.mail-mock .subject { font-weight: 700; border-bottom: 1px solid var(--line); padding-bottom: 8px; margin-bottom: 8px; }
.mail-mock .urgent { color: var(--warn); }
table { border-collapse: collapse; width: 100%; font-size: 15px; }
th, td { border: 1px solid var(--line); padding: 6px 10px; text-align: left; vertical-align: top; }
.table-scroll { overflow-x: auto; }
details { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 10px 16px; margin: 8px 0; }
summary { cursor: pointer; font-weight: 700; }
