:root {
  --blue: #2762EB;
  --ink: #1a1f2b;
  --sub: #5b6475;
  --line: #e3e7ee;
  --bg: #f6f8fb;
  --card: #ffffff;
}
* { box-sizing: border-box; }
[hidden] { display: none !important; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: -apple-system, BlinkMacSystemFont, "Hiragino Sans", "Noto Sans JP", "Yu Gothic", sans-serif;
  line-height: 1.7;
}
.site-header, .site-footer {
  max-width: 720px; margin: 0 auto; padding: 16px 20px;
  display: flex; align-items: center; justify-content: space-between;
}
.brand { display: flex; align-items: center; gap: 10px; color: var(--ink); text-decoration: none; font-weight: 700; }
.mark { width: 20px; height: 20px; background: var(--blue); display: inline-block; }
.header-link { color: var(--sub); font-size: 14px; text-decoration: none; }
.container { max-width: 720px; margin: 0 auto; padding: 8px 20px 32px; }
h1 { font-size: 24px; margin: 12px 0 8px; line-height: 1.4; }
h2 { font-size: 16px; margin: 0 0 14px; }
.lead { color: var(--sub); margin: 0 0 20px; }
.card {
  background: var(--card); border: 1px solid var(--line);
  border-radius: 12px; padding: 20px; margin-bottom: 16px;
}
.field { margin-bottom: 16px; }
.field:last-child { margin-bottom: 0; }
.label { display: block; font-size: 14px; color: var(--sub); margin-bottom: 6px; }
.input-wrap { position: relative; }
input[type="text"], select {
  width: 100%; font-size: 20px; padding: 12px 40px 12px 14px;
  border: 1px solid #c9d0dc; border-radius: 10px; background: #fff; color: var(--ink);
  font-family: inherit;
}
select { font-size: 16px; padding-right: 14px; }
input[type="text"]:focus, select:focus { outline: 2px solid var(--blue); outline-offset: 0; border-color: var(--blue); }
.unit { position: absolute; right: 14px; top: 50%; transform: translateY(-50%); color: var(--sub); }
.seg { display: flex; gap: 8px; flex-wrap: wrap; }
.seg label { flex: 1 1 200px; }
.seg input { position: absolute; opacity: 0; pointer-events: none; }
.seg span {
  display: block; text-align: center; padding: 11px 12px; font-size: 14px;
  border: 1px solid #c9d0dc; border-radius: 10px; cursor: pointer; background: #fff;
}
.seg input:checked + span { background: var(--blue); border-color: var(--blue); color: #fff; font-weight: 700; }
.seg input:focus-visible + span { outline: 2px solid var(--blue); outline-offset: 2px; }
.rows { margin: 0 0 22px; }
.rows > div { display: flex; justify-content: space-between; gap: 12px; padding: 10px 0; border-bottom: 1px solid var(--line); }
.rows dt { color: var(--sub); font-size: 14px; }
.rows dd { margin: 0; font-weight: 700; font-variant-numeric: tabular-nums; white-space: nowrap; }
.rows .sub dt { padding-left: 14px; font-size: 13px; }
.rows .sub dd { font-weight: 400; }
.notice { background: #eef3ff; border-radius: 10px; padding: 12px 14px; margin-bottom: 14px; font-size: 14px; }
.chips { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 10px; }
.chip { font: inherit; padding: 8px 14px; border: 1px solid var(--blue); background: #fff; color: var(--blue); border-radius: 999px; cursor: pointer; }
.chip.on { background: var(--blue); color: #fff; }
.journal { width: 100%; border-collapse: collapse; font-size: 14px; margin-bottom: 18px; }
.journal th, .journal td { padding: 10px 8px; border-bottom: 1px solid var(--line); text-align: left; }
.journal th { color: var(--sub); font-weight: 500; font-size: 13px; }
.journal .r { text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }
.primary {
  display: block; width: 100%; text-align: center; font: inherit; font-weight: 700;
  background: var(--blue); color: #fff; border: 0; border-radius: 10px;
  padding: 14px; cursor: pointer; text-decoration: none;
}
.primary:hover { opacity: .92; }
.primary:disabled { opacity: .4; cursor: default; }
.copy-msg { min-height: 1.5em; margin: 10px 0 0; color: var(--blue); font-size: 14px; }
.btn-copy {
  display: inline-flex; align-items: center; justify-content: center;
  padding: 3px 10px; font-size: 12px; font-weight: 500;
  color: var(--blue); background: #fff; border: 1px solid var(--blue);
  border-radius: 6px; cursor: pointer; margin-left: 10px;
  vertical-align: middle; font-family: inherit;
  transition: background-color .15s, color .15s, border-color .15s;
}
.btn-copy:hover { background: var(--blue); color: #fff; }
.btn-copy.copied { background: #2ea44f; border-color: #2ea44f; color: #fff; }
.btn-copy:disabled { opacity: .35; cursor: default; pointer-events: none; }
.note ul { margin: 0; padding-left: 20px; color: var(--sub); font-size: 14px; }
.contact p { margin: 0 0 14px; color: var(--sub); font-size: 14px; }
.site-footer { color: var(--sub); font-size: 13px; justify-content: center; }
.tool-list { list-style: none; margin: 0; padding: 0; }
.tool-list a { display: block; padding: 16px 0; color: var(--ink); text-decoration: none; border-bottom: 1px solid var(--line); }
.tool-list a:hover .t { color: var(--blue); }
.tool-list .t { font-weight: 700; display: block; }
.tool-list .d { color: var(--sub); font-size: 14px; }
@media (max-width: 480px) {
  h1 { font-size: 21px; }
  .card { padding: 16px; }
  .journal { font-size: 13px; }
}

.hero-box {
  background: #f8fafc;
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 16px 20px;
  margin-bottom: 18px;
  text-align: center;
}
.hero-label {
  font-size: 13px;
  color: var(--sub);
  margin-bottom: 6px;
}
.hero-value {
  font-size: 32px;
  font-weight: 700;
  color: var(--blue);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  font-variant-numeric: tabular-nums;
}
.hero-value.zero {
  color: #16a34a;
}
.banner-eco {
  background: #f0fdf4;
  border: 1px solid #86efac;
  border-radius: 10px;
  padding: 16px;
  margin-top: 18px;
}
.banner-eco h3 {
  margin: 0 0 6px;
  font-size: 15px;
  color: #166534;
}
.banner-eco p {
  margin: 0;
  font-size: 13px;
  color: #14532d;
  line-height: 1.6;
}
.checkbox-wrap {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-top: 8px;
  font-size: 14px;
  color: var(--sub);
  cursor: pointer;
}
.checkbox-wrap input {
  width: 16px;
  height: 16px;
  cursor: pointer;
}
.field-hint {
  font-size: 12px;
  color: var(--sub);
  margin-top: 4px;
}
