:root {
  color-scheme: light;
  --page: #faf9f6;
  --surface: #fffefa;
  --ink: #272a25;
  --muted: #62665e;
  --line: #e3e5dc;
  --green: #26724b;
  --green-soft: #edf5ec;
  --amber: #8c5b12;
  --amber-soft: #fcf4df;
  --red: #ad3936;
  --red-soft: #fceeed;
  --unknown: #73776c;
  --unknown-soft: #f0f0e9;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Noto Sans JP", "Hiragino Kaku Gothic ProN", "Yu Gothic", Meiryo, sans-serif;
  font-size: 15px;
  line-height: 1.7;
  color: var(--ink);
  background: var(--page);
}
* { box-sizing: border-box; }
body { margin: 0; }
[hidden] { display: none !important; }
button, input, select, textarea { font: inherit; }
button, a, input, select, textarea, summary { -webkit-tap-highlight-color: transparent; }
a { color: inherit; text-underline-offset: .25em; }
button, summary { cursor: pointer; }
button:disabled { cursor: wait; opacity: .6; }
h1, h2, h3, p { margin: 0; }
h1 { font-size: clamp(1.8rem, 4.5vw, 2.6rem); line-height: 1.45; font-weight: 600; letter-spacing: -.035em; }
h2 { font-size: 1.14rem; font-weight: 600; }
h3 { font-size: 1rem; font-weight: 600; }
:focus-visible { outline: 3px solid #386aad; outline-offset: 4px; }
.site-shell { width: min(880px, 100% - 64px); margin: 0 auto; }
.site-header { display: flex; align-items: center; justify-content: space-between; gap: 24px; padding: 30px 0; border-bottom: 1px solid var(--line); }
.brand { display: inline-flex; align-items: center; gap: 12px; text-decoration: none; font-weight: 650; font-size: 1.14rem; letter-spacing: .025em; }
.brand-mark { display: grid; place-items: center; width: 38px; height: 38px; background: #e9ebdf; border-radius: 12px; font-family: "Yu Mincho", "Hiragino Mincho ProN", serif; font-weight: bold; font-size: 1.4rem; }
.brand-sub { font-size: .87rem; font-weight: 400; color: var(--muted); margin-left: 8px; }
.header-note { font-size: .8rem; color: var(--muted); }
.intro { padding: 55px 0 30px; }
.intro > p:last-child { margin-top: 15px; }
.eyebrow { font-size: .7rem; letter-spacing: .16em; font-weight: 650; color: var(--muted); margin-bottom: 14px; }
.muted { color: var(--muted); }
.small { font-size: .8rem; }
.mobile-break { display: none; }
.health-banner { display: flex; align-items: center; gap: 19px; padding: 25px 28px; border: 1px solid var(--line); border-radius: 12px; background: var(--unknown-soft); }
.health-banner h2 { font-size: 1.17rem; line-height: 1.5; }
.health-banner p { font-size: .86rem; margin-top: 5px; color: var(--muted); }
.health-icon { flex: 0 0 32px; width: 32px; height: 32px; display: grid; place-items: center; border-radius: 50%; font-size: 1.2rem; background: var(--unknown); color: white; font-weight: 600; }
.health-banner[data-status="operational"] { background: var(--green-soft); border-color: #d5e6d3; }
.health-banner[data-status="operational"] .health-icon { background: var(--green); }
.health-banner[data-status="degraded"] { background: var(--amber-soft); border-color: #eadebb; }
.health-banner[data-status="degraded"] .health-icon { background: var(--amber); }
.health-banner[data-status="outage"] { background: var(--red-soft); border-color: #eed2ce; }
.health-banner[data-status="outage"] .health-icon { background: var(--red); }
.refresh-bar { display: flex; align-items: center; justify-content: space-between; gap: 15px; margin: 14px 0 18px; font-size: .78rem; color: var(--muted); min-height: 44px; }
.refresh-bar .small { font-size: .74rem; margin-top: 3px; }
.stale { color: var(--amber); font-weight: 600; }
.button { display: inline-flex; align-items: center; justify-content: center; min-height: 40px; padding: 8px 16px; border: 1px solid var(--line); border-radius: 7px; background: var(--surface); color: var(--ink); font-size: .83rem; font-weight: 550; line-height: 1.5; text-decoration: none; white-space: nowrap; }
.button:hover:not(:disabled) { background: #f0f1e9; }
.button-primary { color: white; background: #303e31; border-color: #303e31; }
.button-primary:hover:not(:disabled) { background: #435644; }
.button-quiet { background: transparent; }
.section { margin-top: 38px; }
.section-heading { display: flex; justify-content: space-between; gap: 15px; align-items: center; margin-bottom: 14px; }
.panel { border: 1px solid var(--line); border-radius: 10px; background: var(--surface); }
.component-row { display: flex; justify-content: space-between; align-items: center; gap: 20px; padding: 20px 24px; }
.component-row + .component-row { border-top: 1px solid var(--line); }
.status-badge { display: inline-flex; align-items: center; gap: 7px; font-size: .8rem; font-weight: 500; white-space: nowrap; }
.status-badge[data-status="operational"] { color: var(--green); }
.status-badge[data-status="degraded"] { color: var(--amber); }
.status-badge[data-status="outage"] { color: var(--red); }
.status-badge[data-status="unknown"] { color: var(--muted); }
.dot { display: inline-block; width: 8px; height: 8px; border-radius: 50%; background: var(--unknown); flex: 0 0 auto; }
.dot[data-status="operational"], .history-day[data-status="operational"] { background: var(--green); }
.dot[data-status="degraded"], .history-day[data-status="degraded"] { background: #bd872e; }
.dot[data-status="outage"], .history-day[data-status="outage"] { background: var(--red); }
.dot[data-status="unknown"] { background: #94988b; }
.history-panel { padding: 22px 24px 18px; }
.history-help { margin-bottom: 19px; }
.history-strip { display: grid; grid-template-columns: repeat(90, minmax(0, 1fr)); gap: 3px; min-height: 40px; }
.history-day { min-width: 0; height: 38px; padding: 0; border: 0; border-radius: 2px; background: #d9dccf; }
.history-day[data-status="unknown"] { background: repeating-linear-gradient(135deg, #d5d8ce, #d5d8ce 3px, #e9ebe3 3px, #e9ebe3 6px); }
.history-day:hover, .history-day[aria-pressed="true"] { outline: 2px solid var(--ink); outline-offset: 2px; z-index: 1; }
.history-day:focus-visible { outline: 3px solid #386aad; outline-offset: 3px; }
.history-range { display: flex; justify-content: space-between; margin-top: 9px; }
.history-detail { min-height: 24px; margin-top: 12px; font-size: .8rem; }
.legend { display: flex; flex-wrap: wrap; gap: 10px 20px; list-style: none; padding: 13px 0 0; margin: 12px 0 0; border-top: 1px solid var(--line); font-size: .75rem; color: var(--muted); }
.legend li { display: flex; align-items: center; gap: 7px; }
.empty-state { padding: 28px 24px; color: var(--muted); font-size: .87rem; }
.incident + .incident { margin-top: 12px; }
.incident-summary { padding: 21px 24px; display: flex; align-items: center; justify-content: space-between; gap: 15px; list-style: none; }
.incident-summary::-webkit-details-marker { display: none; }
.incident-heading { min-width: 0; }
.incident-heading h3 { overflow-wrap: anywhere; }
.incident-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 14px; margin-top: 8px; color: var(--muted); font-size: .75rem; }
.incident-state { font-weight: 650; color: var(--amber); }
.incident-state[data-resolved="true"] { color: var(--green); }
.detail-toggle { flex-shrink: 0; font-size: .7rem; color: var(--muted); }
.detail-toggle::after { content: " ＋"; }
.incident[open] .detail-toggle::after { content: " −"; }
.incident-body { border-top: 1px solid var(--line); padding: 22px 24px; }
.timeline { list-style: none; padding: 0 0 0 18px; margin: 0 0 22px 4px; border-left: 1px solid var(--line); }
.timeline-item { position: relative; padding: 0 0 24px 4px; }
.timeline-item:last-child { padding-bottom: 0; }
.timeline-item::before { position: absolute; content: ""; width: 7px; height: 7px; border-radius: 50%; background: #8d9785; left: -22px; top: 8px; }
.timeline-meta { display: flex; flex-wrap: wrap; gap: 5px 15px; align-items: baseline; font-size: .8rem; }
.timeline-meta time { color: var(--muted); font-size: .75rem; }
.message-text { font-size: .87rem; margin-top: 8px; white-space: pre-wrap; overflow-wrap: anywhere; }
.site-footer { display: flex; align-items: flex-start; justify-content: space-between; gap: 20px; padding: 25px 0 36px; margin-top: 58px; border-top: 1px solid var(--line); color: var(--muted); font-size: .72rem; }
.site-footer a { white-space: nowrap; }
.notice { border: 1px solid #dddcc9; background: #f5f3e9; border-radius: 7px; padding: 14px 17px; font-size: .84rem; }
.notice-error { background: var(--red-soft); border-color: #eccfc9; color: #913530; }
.skip-link { position: fixed; z-index: 10; top: -100px; left: 15px; background: var(--surface); padding: 10px 20px; border: 2px solid var(--ink); border-radius: 5px; }
.skip-link:focus { top: 12px; }
.admin-shell { max-width: 1100px; width: min(1100px, 100% - 64px); }
.auth-panel { padding: 28px; }
.auth-panel p { margin-top: 10px; }
.auth-panel .button { margin-top: 20px; }
.session-bar { display: flex; justify-content: space-between; align-items: center; gap: 15px; margin-bottom: 18px; }
.environment-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.environment-card { padding: 22px; min-width: 0; }
.environment-card .section-heading { margin-bottom: 5px; }
.environment-card h3 { overflow-wrap: anywhere; }
.identifier { color: var(--muted); overflow-wrap: anywhere; font-family: ui-monospace, monospace; }
.environment-times { margin: 20px 0; }
.data-field { display: grid; grid-template-columns: minmax(100px, .9fr) minmax(0, 1.5fr); gap: 12px; margin: 9px 0; font-size: .78rem; }
.data-field dt { color: var(--muted); }
.data-field dd { margin: 0; overflow-wrap: anywhere; white-space: pre-wrap; }
.failure-details { border-top: 1px solid var(--line); padding-top: 14px; }
.failure-details summary { font-size: .8rem; }
.failure-entry { padding-top: 12px; }
.failure-entry + .failure-entry { border-top: 1px solid var(--line); }
.notification-state { padding: 20px 24px; font-size: .87rem; }
.form-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; }
.incident-form { display: flex; flex-direction: column; gap: 9px; padding: 25px; }
.incident-form h3 { margin-bottom: 10px; }
.incident-form > label:not(.checkbox-label) { font-size: .82rem; font-weight: 550; margin-top: 8px; }
input:not([type="checkbox"]), select, textarea { min-width: 0; width: 100%; background: white; border: 1px solid #c4c8bc; border-radius: 5px; padding: 9px 11px; color: var(--ink); font-size: .88rem; }
textarea { resize: vertical; min-height: 125px; }
.checkbox-label { display: flex; align-items: center; gap: 8px; margin: 8px 0 2px; font-size: .84rem; min-height: 36px; }
input[type="checkbox"] { width: 18px; height: 18px; accent-color: #303e31; }
.incident-form .button { margin-top: 12px; }
.form-result { min-height: 24px; font-size: .8rem; color: var(--green); }
.text-error { color: var(--red); }
.publication-label { padding: 0 7px; background: #efefe6; border-radius: 4px; }
@media (max-width: 720px) {
  .site-shell, .admin-shell { width: calc(100% - 36px); }
  .site-header { padding: 22px 0; gap: 10px; }
  .header-note { display: none; }
  .brand-sub { margin-left: 4px; font-size: .76rem; }
  .brand { gap: 8px; font-size: 1rem; }
  .intro { padding-top: 35px; }
  .health-banner { padding: 20px; align-items: flex-start; gap: 14px; }
  .health-banner h2 { font-size: 1rem; }
  .health-icon { margin-top: 2px; }
  .history-panel { padding: 18px 15px; }
  .history-strip { gap: 2px; }
  .history-day { border-radius: 1px; }
  .environment-grid, .form-grid { grid-template-columns: minmax(0, 1fr); }
  .section-heading { flex-wrap: wrap; gap: 5px 12px; }
  .site-footer { flex-direction: column; gap: 12px; }
  .incident-summary, .incident-body { padding: 19px; }
  .detail-toggle { font-size: 0; }
  .detail-toggle::after { font-size: 1rem; }
}
@media (max-width: 420px) {
  .mobile-break { display: initial; }
  .site-header > .button { font-size: .7rem; padding: 8px; }
  .component-row { padding: 18px; gap: 10px; }
  .component-row h3 { font-size: .9rem; }
  .refresh-bar { align-items: flex-start; }
  .data-field { grid-template-columns: 1fr; gap: 2px; }
}
@media (prefers-reduced-motion: no-preference) {
  .button { transition: background-color .15s ease; }
}
@media (forced-colors: active) {
  .history-day { border: 1px solid ButtonText; }
  .history-day[data-status="unknown"] { border-style: dashed; }
  .dot { border: 1px solid currentColor; }
}
