:root {
  --bg: #f4f7f6; --card: #ffffff; --text: #17201f; --muted: #57635f; --line: #d7dfdc;
  --accent: #0f766e; --accent-text: #ffffff; --accent-soft: #e2f3f0; --error: #c4262e;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0f1514; --card: #172020; --text: #e5ecea; --muted: #9aa9a5; --line: #2a3634;
    --accent: #2dd4bf; --accent-text: #062a26; --accent-soft: #123532; --error: #ff7b7b;
  }
}
* { box-sizing: border-box; }
body { margin: 0; background: var(--bg); color: var(--text); font: 16px/1.55 system-ui, -apple-system, "Segoe UI", Roboto, sans-serif; }
.wrap { max-width: 1100px; margin: 0 auto; padding: 0 16px; }
a { color: var(--accent); }

.top { background: var(--card); border-bottom: 1px solid var(--line); }
.brand { display: flex; align-items: center; gap: 12px; padding-top: 14px; padding-bottom: 14px; }
.brand h1 { font-size: 20px; margin: 0; }
.brand p { margin: 0; color: var(--muted); font-size: 14px; }
.brand .gh { margin-left: auto; font-weight: 600; text-decoration: none; }

.intro { padding: 28px 0 8px; }
.lead { font-size: 18px; max-width: 820px; margin: 0 0 12px; }
.privacy { display: inline-block; background: var(--accent-soft); border-radius: 8px; padding: 8px 12px; margin: 0; font-size: 14px; }

.card { background: var(--card); border: 1px solid var(--line); border-radius: 12px; padding: 20px; margin: 20px 0; }
.tabs { display: flex; gap: 4px; border-bottom: 1px solid var(--line); margin: -4px 0 16px; flex-wrap: wrap; }
.tabs button { background: none; border: 0; border-bottom: 3px solid transparent; color: var(--muted); font: inherit; font-weight: 600; padding: 8px 12px; cursor: pointer; }
.tabs button[aria-selected="true"] { color: var(--text); border-bottom-color: var(--accent); }

.label { display: block; font-weight: 600; margin-bottom: 6px; }
.label.inline { display: inline; margin: 0; }
textarea { width: 100%; min-height: 240px; resize: vertical; font: 13px/1.5 ui-monospace, Consolas, monospace; color: var(--text); background: var(--bg); border: 1px solid var(--line); border-radius: 8px; padding: 12px; }
.row { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; margin-top: 12px; }
select { font: inherit; color: var(--text); background: var(--bg); border: 1px solid var(--line); border-radius: 6px; padding: 6px 8px; }
button.primary, .button { font: inherit; font-weight: 600; border-radius: 8px; padding: 8px 18px; cursor: pointer; border: 1px solid var(--accent); }
button.primary { background: var(--accent); color: var(--accent-text); margin-left: auto; }
button.primary:disabled { opacity: .5; cursor: wait; }
.button { display: inline-block; background: var(--card); color: var(--accent); }
.hint { color: var(--muted); margin: 0 0 8px; }

.examples { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 10px; }
.example { text-align: left; font: inherit; color: var(--text); background: var(--bg); border: 1px solid var(--line); border-radius: 10px; padding: 12px; cursor: pointer; }
.example:hover, .example:focus { border-color: var(--accent); }
.example strong { display: block; }
.example span { color: var(--muted); font-size: 13px; font-family: ui-monospace, Consolas, monospace; }

.status { margin: 16px 0 0; color: var(--muted); font-size: 14px; min-height: 1.5em; }
.status.error { color: var(--error); font-weight: 600; }
.notice { margin-top: 12px; background: var(--accent-soft); border-radius: 8px; padding: 4px 16px; font-size: 14px; }
.notice ul { padding-left: 20px; }
.notice li { margin: 6px 0; }

.result iframe { width: 100%; height: 85vh; border: 1px solid var(--line); border-radius: 12px; background: var(--card); }

.more { padding: 12px 0 40px; }
.more h2 { font-size: 18px; }
.cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 12px; }
.cards > div { background: var(--card); border: 1px solid var(--line); border-radius: 12px; padding: 4px 16px; }
.cards h3 { font-size: 16px; margin: 12px 0 4px; }
.cards p { margin: 0 0 12px; color: var(--muted); font-size: 14px; }
.fine { color: var(--muted); font-size: 13px; margin-top: 20px; }
code { font-family: ui-monospace, Consolas, monospace; font-size: 0.92em; }
