:root { color-scheme: light; --ink: #172d48; --muted: #617186; --blue: #2868ba; --navy: #163a69; --line: #dbe3ed; --canvas: #f3f6fa; --orange: #b96513; }
* { box-sizing: border-box; }
body { margin: 0; background: var(--canvas); color: var(--ink); font-family: -apple-system,BlinkMacSystemFont,"Hiragino Sans","Noto Sans JP",sans-serif; font-size: 14px; -webkit-font-smoothing: antialiased; }
button,a { -webkit-tap-highlight-color: transparent; }
button { font: inherit; cursor: pointer; color: inherit; }
button:disabled { cursor: wait; opacity: .6; }
a { color: var(--blue); }
button:focus-visible,a:focus-visible,summary:focus-visible { outline: 3px solid #5798e6; outline-offset: 4px; }
button,summary { touch-action: manipulation; }
svg { display: block; }
p { line-height: 1.75; }
h1,h2,p { margin-top: 0; }
[hidden] { display: none!important; }
.topbar { height: 86px; max-width: 1160px; margin: auto; padding: 0 30px; display: flex; align-items: center; justify-content: space-between; }
.brand { display: flex; gap: 11px; align-items: center; text-decoration: none; color: var(--navy); font-weight: 700; font-size: 17px; }
.brand small { display: block; font-size: 11px; font-weight: 500; color: var(--muted); margin-top: 1px; }
.header-actions { display: flex; align-items: center; gap: 16px; }
.private { display: flex; align-items: center; gap: 6px; color: var(--muted); font-size: 12px; }
.icon-button { border: 1px solid var(--line); background: white; border-radius: 50%; width: 36px; height: 36px; font-size: 17px; display: grid; place-items: center; }
main { max-width: 1100px; margin: auto; padding: 24px 30px 28px; }
.intro { display: flex; justify-content: space-between; align-items: center; margin-bottom: 28px; gap: 20px; }
.intro h1 { font-size: 24px; letter-spacing: -.025em; margin-bottom: 9px; font-weight: 650; }
.intro p { color: var(--muted); margin-bottom: 0; font-size: 13px; }
.refresh { border: 1px solid #ccd8e7; background: white; border-radius: 9px; min-height: 42px; padding: 10px 14px; display: flex; gap: 7px; align-items: center; font-size: 12px; white-space: nowrap; }
.refresh svg { width: 16px; height: 16px; }
.refresh:hover { background: #eaf2fc; }
.overview { display: grid; grid-template-columns: 1fr 220px; background: white; border: 1px solid var(--line); border-radius: 18px; overflow: hidden; margin-bottom: 24px; }
.usage { padding: 27px 32px 24px; }
.eyeline { display: flex; gap: 10px; align-items: center; font-size: 13px; color: var(--muted); }
.badge { padding: 4px 8px; border-radius: 5px; background: #edf2f8; font-size: 10px; white-space: nowrap; color: #5d7087; }
.value { display: flex; align-items: baseline; margin: 12px 0 15px; line-height: 1; font-variant-numeric: tabular-nums; }
.value>span:first-child { font-size: 64px; letter-spacing: -.045em; font-weight: 650; color: var(--navy); }
.percent { font-size: 25px; margin-left: 5px; color: var(--navy); }
.remaining { margin-left: auto; color: var(--muted); font-size: 12px; }
.remaining strong { font-weight: 600; margin: 0 3px; }
.meter { height: 9px; background: #eaf0f7; border-radius: 10px; position: relative; margin-bottom: 10px; }
.meter>div { height: 100%; background: var(--blue); border-radius: 10px; }
.meter-reference { position: absolute; top: -3px; bottom: -3px; left: 10%; width: 2px; background: var(--orange); }
.meter-labels { display: flex; justify-content: space-between; color: var(--muted); font-size: 11px; }
.reset { background: #f8fafd; border-left: 1px solid var(--line); padding: 30px 26px; display: flex; flex-direction: column; align-items: flex-start; justify-content: center; }
.label { font-size: 11px; color: var(--muted); margin-bottom: 12px; }
.reset strong { font-size: 24px; letter-spacing: -.02em; font-weight: 650; }
.reset>span:not(.label) { margin-top: 4px; color: var(--muted); font-size: 12px; }
.reset p { margin: 14px 0 0; font-size: 11px; color: var(--muted); }
.workspace { display: grid; grid-template-columns: minmax(0,1fr) 282px; gap: 24px; align-items: start; }
.chart-section { min-width: 0; background: white; border: 1px solid var(--line); border-radius: 18px; padding: 25px 24px 19px; }
.section-heading { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
h2 { font-size: 15px; font-weight: 650; margin-bottom: 0; }
.segmented { display: flex; gap: 3px; padding: 3px; background: #f3f6fa; border-radius: 8px; border: 1px solid var(--line); }
.segmented button { border: 0; background: transparent; padding: 5px 12px; border-radius: 5px; color: var(--muted); font-size: 12px; min-height: 30px; }
.segmented button[aria-pressed=true] { background: white; color: var(--navy); box-shadow: 0 1px 4px #172d481a; font-weight: 650; }
.legend { display: flex; gap: 20px; font-size: 10px; margin: 22px 0 8px; color: var(--muted); flex-wrap: wrap; }
.legend>span { display: flex; gap: 6px; align-items: center; }
.legend i { display: inline-block; width: 20px; height: 0; border-top: 2px solid var(--blue); }
.legend .reference-line { border-top: 2px dashed var(--orange); }
.legend b { font-weight: 600; color: var(--orange); }
.chart { height: 250px; width: 100%; position: relative; }
.chart svg { width: 100%; height: 100%; overflow: visible; }
.chart text { font-family: inherit; fill: #758499; font-size: 11px; }
.chart .gridline { stroke: #e9edf4; stroke-width: 1; }
.chart .reference { stroke: var(--orange); stroke-width: 1.6; stroke-dasharray: 5 5; }
.chart .series { stroke: var(--blue); stroke-width: 2.5; stroke-linecap: round; stroke-linejoin: round; fill: none; }
.chart .point { fill: var(--blue); stroke: white; stroke-width: 3; cursor: pointer; }
.chart .hit { fill: transparent; cursor: pointer; }
.chart .point-label { fill: var(--navy); font-weight: 650; font-size: 13px; }
.chart-caption { font-size: 12px; background: #f3f7fc; padding: 10px 12px; border-radius: 7px; color: #46607e; margin: 8px 0 10px; min-height: 39px; }
.chart-note { font-size: 10px; color: var(--muted); margin: 0; }
.comparison { padding: 25px 23px; background: #e9f0f8; border-radius: 18px; }
.compare-icon { width: 32px; height: 32px; background: white; border-radius: 8px; display: grid; place-items: center; color: var(--navy); margin-bottom: 16px; }
.compare-icon svg { width: 21px; height: 21px; }
.comparison h2 { font-size: 12px; color: #55708d; margin-bottom: 12px; }
.comparison-headline { font-size: 18px; font-weight: 650; line-height: 1.6; margin-bottom: 10px; }
.comparison>p:not(.comparison-headline):not(.small-note) { color: #566b83; font-size: 12px; line-height: 1.85; }
.thresholds { display: grid; gap: 12px; margin: 22px 0; padding: 18px 0; border-top: 1px solid #cfdce9; border-bottom: 1px solid #cfdce9; }
.thresholds>div { display: flex; justify-content: space-between; align-items: center; }
.thresholds dt { font-size: 12px; color: #4a627d; }
.thresholds dt span { font-size: 9px; margin-left: 5px; border: 1px solid #c2d0df; border-radius: 3px; padding: 2px 4px; }
.thresholds dd { font-size: 23px; margin: 0; line-height: 1.2; font-weight: 650; font-variant-numeric: tabular-nums; }
.thresholds small { font-size: 12px; margin-left: 3px; }
.small-note { font-size: 11px; color: var(--muted); line-height: 1.8; margin-bottom: 0; }
.records { margin-top: 24px; border: 1px solid var(--line); border-radius: 12px; background: white; overflow: hidden; }
.method { margin-top: 10px; border-bottom: 1px solid var(--line); }
summary { display: flex; align-items: center; gap: 10px; list-style: none; cursor: pointer; min-height: 55px; padding: 16px 20px; font-size: 12px; font-weight: 600; }
summary::-webkit-details-marker { display: none; }
.chevron { margin-left: auto; font-size: 17px; color: var(--muted); }
details[open] .chevron { transform: rotate(180deg); }
#record-count { font-size: 10px; color: var(--muted); font-weight: 400; }
.table-wrap { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; white-space: nowrap; text-align: left; font-size: 11px; }
th { background: #f8fafd; color: var(--muted); font-weight: 500; }
th,td { padding: 13px 20px; border-top: 1px solid #e9eef4; }
td:nth-child(2) { font-weight: 650; color: var(--blue); font-size: 13px; }
.method-copy { padding: 0 20px 20px; color: var(--muted); font-size: 12px; max-width: 800px; }
.method-copy a { display: inline-block; margin-right: 20px; margin-top: 6px; }
.method-copy p { margin-bottom: 10px; }
footer { padding: 22px 0 0; color: var(--muted); font-size: 10px; text-align: center; }
footer p { margin: 5px 0; }
.update-info { display: flex; justify-content: center; align-items: center; gap: 6px; }
.status-dot { width: 6px; height: 6px; background: #4c9d87; border-radius: 50%; }
.footer-note { font-size: 10px; color: #7a8899; }
.loading,.empty { text-align: center; padding: 65px 20px; color: var(--muted); }
.device-gate { max-width: 570px; margin: 20px auto; padding: 30px 25px; background: white; border: 1px solid var(--line); border-radius: 18px; }
.device-gate h2 { margin: 20px 0 14px; font-size: 21px; line-height: 1.6; }
.device-gate>p { color: var(--muted); }
.device-gate>.small-note:last-child { margin-top: 22px; }
#device-pending { margin-top: 24px; border-top: 1px solid var(--line); padding-top: 20px; }
.device-code { display: block; text-align: center; background: #edf3fb; padding: 18px 8px; font-size: 26px; letter-spacing: .06em; font-variant-numeric: tabular-nums; color: var(--navy); border-radius: 8px; }
#device-message { font-size: 12px; color: var(--muted); margin-top: 18px; }
.empty h2 { margin-bottom: 12px; }
.error { padding: 13px 16px; background: #fff0eb; color: #9e401b; border: 1px solid #efc5b5; border-radius: 8px; font-size: 12px; }
dialog { border: 0; border-radius: 18px; padding: 26px; max-width: 440px; width: calc(100% - 36px); color: var(--ink); box-shadow: 0 15px 70px #163a6930; }
dialog::backdrop { background: #172d4860; }
.dialog-heading { display: flex; align-items: center; justify-content: space-between; margin-bottom: 18px; gap: 12px; }
dialog p,dialog li { font-size: 13px; line-height: 1.9; }
dialog ol { padding-left: 21px; margin: 22px 0; }
.primary-button { background: var(--navy); color: white; border: 0; border-radius: 9px; min-height: 44px; width: 100%; margin-top: 23px; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0; }
@media(max-width:800px) {
  .workspace { grid-template-columns: 1fr; }
  .comparison { display: grid; grid-template-columns: 1fr 160px; column-gap: 28px; padding: 24px; }
  .compare-icon { display: none; }
  .comparison h2,.comparison-headline,.comparison>p { grid-column: 1; }
  .thresholds { grid-column: 2; grid-row: 1/4; margin: 0; border: 0; align-self: center; }
  .comparison .small-note { grid-column: 1/3; margin-top: 7px; }
  .overview { grid-template-columns: 1fr 190px; }
  .reset { padding: 24px; }
  .intro h1 { font-size: 21px; }
}
@media(max-width:540px) {
  .topbar { height: 73px; padding: 0 21px; }
  .brand { font-size: 16px; gap: 9px; }
  .brand img { width: 31px; height: 31px; }
  .private { font-size: 11px; }
  .header-actions { gap: 12px; }
  main { padding: 16px 18px calc(25px + env(safe-area-inset-bottom)); }
  .intro { align-items: flex-start; margin-bottom: 23px; gap: 8px; }
  .intro h1 { font-size: 19px; line-height: 1.6; letter-spacing: -.045em; margin-bottom: 6px; }
  .intro p { font-size: 11px; }
  .refresh { padding: 10px; min-height: 38px; border-radius: 10px; margin-top: 2px; }
  .refresh span { display: none; }
  .refresh svg { width: 17px; height: 17px; }
  .overview { grid-template-columns: 1fr; margin-bottom: 18px; border-radius: 15px; }
  .usage { padding: 22px 22px 21px; }
  .value>span:first-child { font-size: 61px; }
  .value { margin-top: 14px; margin-bottom: 18px; }
  .eyeline { font-size: 12px; }
  .reset { display: grid; grid-template-columns: 1fr auto; gap: 3px 10px; padding: 16px 22px; border-left: 0; border-top: 1px solid var(--line); }
  .reset .label { margin: 0; grid-column: 1; font-size: 10px; }
  .reset strong { grid-column: 1; font-size: 18px; margin-top: 3px; }
  .reset>span:not(.label) { grid-column: 2; grid-row: 2; align-self: center; margin: 0; font-size: 11px; }
  .reset p { grid-column: 2; grid-row: 1; margin: 0; text-align: right; font-size: 10px; }
  .workspace { gap: 18px; }
  .chart-section { padding: 20px 17px 17px; border-radius: 15px; }
  .section-heading h2 { font-size: 14px; }
  .segmented button { padding: 4px 11px; }
  .legend { gap: 14px; font-size: 9px; margin-top: 19px; }
  .chart { height: 227px; }
  .chart-caption { font-size: 11px; padding: 10px; margin-top: 4px; }
  .chart-note { font-size: 10px; line-height: 1.75; }
  .comparison { grid-template-columns: 1fr; padding: 22px; border-radius: 15px; }
  .comparison h2 { margin-bottom: 10px; }
  .comparison-headline { font-size: 17px; margin-bottom: 7px; }
  .thresholds { grid-column: 1; grid-row: auto; display: grid; grid-template-columns: 1fr 1fr; gap: 15px; border-top: 1px solid #cfdce9; border-bottom: 1px solid #cfdce9; margin: 10px 0 13px; padding: 15px 0; }
  .thresholds>div { display: block; }
  .thresholds dt { font-size: 11px; margin-bottom: 8px; }
  .thresholds dd { font-size: 26px; }
  .comparison .small-note { grid-column: 1; margin: 0; }
  .records { margin-top: 18px; }
  .method-copy { padding: 0 16px 18px; font-size: 11px; }
  summary { padding: 15px 16px; }
  th,td { padding: 12px 14px; }
  footer { padding-top: 20px; }
  .footer-note { max-width: 290px; margin: 8px auto 0; }
  dialog { padding: 22px; }
}
@media(prefers-reduced-motion:no-preference) { button { transition: background-color .15s,opacity .15s; } }
