/* フミタネ by EsyouSystem：公開ページの見た目 */
:root {
  color-scheme: light dark;
  --bg: #f6f6f4;
  --text: #1f2330;
  --muted: #555b6b;
  --field-bg: #ffffff;
  --border: #9a9fae;
  --accent: #4449a5;
  --accent-text: #ffffff;
  --link: #3a3f96;
  --focus: #4449a5;
  --error: #b3261e;
  --error-bg: #fbeceb;
  --notice-bg: #eceefa;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #16181d;
    --text: #e7e8ec;
    --muted: #a8acb8;
    --field-bg: #20232b;
    --border: #5c6170;
    --accent: #4449a5;
    --accent-text: #ffffff;
    --link: #aeb3f7;
    --focus: #aeb3f7;
    --error: #ff8f86;
    --error-bg: #3a2222;
    --notice-bg: #262a45;
  }
}
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: system-ui, -apple-system, "Hiragino Sans", "Hiragino Kaku Gothic ProN", "Yu Gothic UI", "Meiryo", sans-serif;
  font-size: 16px;
  line-height: 1.75;
  overflow-wrap: anywhere;
}
main, footer { max-width: 40rem; margin: 0 auto; padding-left: 16px; padding-right: 16px; }
main { padding-top: 24px; padding-bottom: 8px; }
footer { padding-bottom: 32px; color: var(--muted); font-size: 14px; }
h1 { font-size: 22px; line-height: 1.45; margin: 0 0 16px; }
h2 { font-size: 18px; line-height: 1.5; margin: 32px 0 8px; }
h3 { font-size: 16px; line-height: 1.5; margin: 20px 0 4px; }
p { margin: 0 0 16px; }
ul { margin: 0 0 16px; padding-left: 1.5em; }
li { margin: 0 0 8px; }
a { color: var(--link); text-underline-offset: 2px; }
form { margin: 24px 0; }
.field { margin: 0 0 16px; }
label { display: block; font-weight: bold; margin: 0 0 4px; }
.hint { color: var(--muted); margin: 0 0 8px; }
input[type="text"] {
  display: block;
  width: 100%;
  min-height: 48px;
  margin: 0;
  padding: 8px 12px;
  font-family: ui-monospace, "SFMono-Regular", Menlo, Consolas, monospace;
  font-size: 18px;
  color: var(--text);
  background: var(--field-bg);
  border: 2px solid var(--border);
  border-radius: 6px;
}
input[aria-invalid="true"] { border-color: var(--error); }
button {
  display: block;
  width: 100%;
  min-height: 48px;
  margin: 0;
  padding: 10px 16px;
  font-family: inherit;
  font-size: 17px;
  font-weight: bold;
  line-height: 1.4;
  color: var(--accent-text);
  background: var(--accent);
  border: 0;
  border-radius: 6px;
  cursor: pointer;
}
button:hover { filter: brightness(1.12); }
:focus-visible { outline: 3px solid var(--focus); outline-offset: 2px; }
.toc-title { font-weight: bold; margin: 0 0 4px; }
.draft {
  padding: 12px 16px;
  border-left: 4px solid var(--accent);
  background: var(--notice-bg);
  font-weight: bold;
}
.error {
  padding: 12px 16px;
  border-left: 4px solid var(--error);
  background: var(--error-bg);
}
