:root {
  --bg: #f5f6f8;
  --card: #ffffff;
  --border: #e2e5ea;
  --text: #1f2430;
  --muted: #6b7280;
  --primary: #2563eb;
  --primary-dark: #1d4ed8;
  --green: #16a34a;
  --amber: #d97706;
  --red: #dc2626;
  --radius: 10px;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  font-family: -apple-system, "Segoe UI", "Hiragino Kaku Gothic ProN", "Yu Gothic", sans-serif;
  background: var(--bg);
  color: var(--text);
}

.top-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 24px;
  background: var(--card);
  border-bottom: 1px solid var(--border);
}

.top-bar h1 { font-size: 18px; margin: 0; }

.container {
  max-width: 1100px;
  margin: 0 auto;
  padding: 24px;
}

.card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px;
  margin-bottom: 20px;
}

.card h2 { margin-top: 0; font-size: 16px; }

table {
  width: 100%;
  border-collapse: collapse;
  font-size: 14px;
}

th, td {
  text-align: left;
  padding: 8px 10px;
  border-bottom: 1px solid var(--border);
}

th { color: var(--muted); font-weight: 600; font-size:13px; text-transform: uppercase; }

tr.clickable { cursor: pointer; }
tr.clickable:hover { background: #f9fafb; }

.badge {
  display: inline-block;
  padding: 2px 8px;
  border-radius: 999px;
  font-size:13px;
  font-weight: 600;
}
.badge.online { background: #dcfce7; color: var(--green); }
.badge.away { background: #fef3c7; color: var(--amber); }
.badge.offline { background: #f1f2f4; color: var(--muted); }

button {
  cursor: pointer;
  border: none;
  border-radius: 8px;
  padding: 8px 14px;
  font-size: 14px;
  font-weight: 600;
  background: var(--primary);
  color: white;
}
button:hover { background: var(--primary-dark); }
button.secondary { background: #f1f2f4; color: var(--text); }
button.secondary:hover { background: #e5e7eb; }
button.danger { background: #fee2e2; color: var(--red); }
button.danger:hover { background: #fecaca; }

input[type="text"], input[type="email"], input[type="password"], input[type="date"] {
  padding: 8px 10px;
  border: 1px solid var(--border);
  border-radius: 8px;
  font-size: 14px;
}

.row { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.form-row { display: flex; gap: 10px; margin-bottom: 12px; flex-wrap: wrap; }

.muted { color: var(--muted); font-size: 13px; }

.bar-row { display: flex; align-items: center; gap: 10px; margin-bottom: 6px; }
.bar-label { width: 160px; font-size: 13px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.bar-track { flex: 1; background: #eef0f3; border-radius: 6px; height: 14px; overflow: hidden; }
.bar-fill { background: var(--primary); height: 100%; }
.bar-value { width: 60px; text-align: right; font-size:13px; color: var(--muted); }

.token-box {
  background: #f1f5f9;
  border-radius: 8px;
  padding: 10px;
  font-family: monospace;
  font-size: 13px;
  word-break: break-all;
  margin-top: 8px;
}

.login-wrap {
  height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
}
.login-card { width: 320px; }
.error-text { color: var(--red); font-size: 13px; margin-top: 8px; }

.back-link { cursor: pointer; color: var(--primary); font-size: 14px; }

/* ----- 行動タイムライン(dataviz skillの検証済みカテゴリカルパレット。ライトモードのみ) ----- */
:root {
  --series-1: #2a78d6; /* blue */
  --series-2: #eb6834; /* orange */
  --series-3: #1baf7a; /* aqua */
  --series-4: #eda100; /* yellow */
  --series-5: #e87ba4; /* magenta */
  --series-6: #008300; /* green */
  --series-7: #4a3aa7; /* violet */
  --series-other: #c3c2b7;
  --series-idle: #e1e0d9;
}

/* 1時間ごとの積み上げ棒グラフ */
.hourly-plot {
  display: flex;
  align-items: flex-end;
  gap: 6px;
  min-width: 240px;
}
.hourly-plot.compact { gap: 1px; min-width: 90px; }

.hourly-slot {
  flex: 1 1 0;
  min-width: 0;
  height: 100%;
  display: flex;
  justify-content: center;
  align-items: flex-end;
  cursor: pointer;
}

.hourly-col {
  position: relative;
  height: 100%;
  border-radius: 4px 4px 0 0;
  overflow: hidden;
  background: transparent;
}

.hourly-seg { position: absolute; left: 0; right: 0; }

.hourly-axis { display: flex; gap: 6px; margin-top: 4px; }
.hourly-axis-slot { flex: 1 1 0; min-width: 0; text-align: center; font-size:13px; color: var(--muted); }

.timeline-legend { display: flex; flex-wrap: wrap; gap: 6px 14px; margin-top: 10px; }
.timeline-legend-item { display: flex; align-items: center; gap: 6px; font-size:13px; color: var(--text); }
.timeline-legend-swatch { width: 10px; height: 10px; border-radius: 2px; flex: none; }

.timeline-tooltip {
  position: fixed;
  pointer-events: none;
  background: #1f2430;
  color: #fff;
  padding: 8px 12px;
  border-radius: 8px;
  font-size:13px;
  line-height: 1.6;
  z-index: 1000;
  display: none;
  max-width: 280px;
}
.timeline-tooltip .tt-header { color: #c3c2b7; font-size:13px; margin-bottom: 4px; }
.timeline-tooltip .tt-item { display: flex; align-items: center; gap: 8px; white-space: nowrap; }
.timeline-tooltip .tt-dot { width: 9px; height: 9px; border-radius: 50%; flex: none; }
.timeline-tooltip .tt-app { font-weight: 700; flex: none; }
.timeline-tooltip .tt-window {
  color: #c3c2b7;
  overflow: hidden;
  text-overflow: ellipsis;
}
/* Worklog workspace */
:root{--bg:#f6f8fa;--card:#fff;--text:#22323c;--muted:#74818b;--border:#e8edf0;--primary:#168575;--primary-dark:#106b5e;--green:#15816c;--radius:14px;--series-1:#299a88;--series-2:#648ed3;--series-3:#b293cf;--series-4:#ddb875;--series-5:#d58799;--series-6:#7b9a67;--series-7:#6a72a8;--series-idle:#dce3e8;--series-other:#aab6bc}
[hidden]{display:none!important}body{font-family:Inter,"Segoe UI","Yu Gothic UI","Meiryo",sans-serif;font-size:14px;line-height:1.6;-webkit-font-smoothing:antialiased}button,input{font:inherit}button,a,input{ -webkit-tap-highlight-color:transparent}button{transition:background .18s,box-shadow .18s;min-height:40px;font-weight:600;padding:10px 18px}button:focus-visible,a:focus-visible,input:focus-visible,tr:focus-visible{outline:3px solid #65b6a7;outline-offset:3px}button:disabled{opacity:.55;cursor:wait}a{color:inherit;text-decoration:none}h1,h2,h3,p{margin-top:0}h1{font-size:29px;letter-spacing:-1px;line-height:1.45;margin-bottom:10px;font-weight:700}h2{font-size:16px!important;letter-spacing:-.3px;margin:0}small{font-size:13px}.sidebar{position:fixed;inset:0 auto 0 0;width:236px;background:#172b34;color:#d1dce0;padding:34px 20px 20px;display:flex;flex-direction:column;z-index:10}.brand{display:flex;position:relative;align-items:center;gap:10px;font-size:27px;font-weight:700;letter-spacing:-1px;color:#fff;padding:0 12px}.brand-mark{display:inline-flex;align-items:center;justify-content:center;width:35px;height:35px;border-radius:10px;background:#309987;font-size:26px;line-height:1}.brand-mark span{color:#c9ede1}.brand-label{position:absolute;left:58px;top:42px;font-size:13px;letter-spacing:1.8px;color:#96aab3}.workspace{display:flex;align-items:center;gap:10px;padding:16px 10px;border-top:1px solid #ffffff12;border-bottom:1px solid #ffffff12;margin-top:48px;font-size:13px;font-weight:600}.workspace small,.admin-profile small{display:block;font-weight:400;color:#9cafb8;font-size:13px;margin-top:3px}.workspace-icon{background:#2a3e47;border:1px solid #40535c;border-radius:8px;padding:5px 10px;font-weight:700}.nav-label{font-size:13px;letter-spacing:1.8px;color:#8b9fa8;margin:30px 12px 12px}.nav-item{width:100%;text-align:left;display:flex;align-items:center;gap:13px;background:transparent;color:#aebec5;padding:12px;margin-bottom:6px;font-size:13px;border-radius:7px}.nav-item span{font-size:20px;width:21px;text-align:center}.nav-item:hover{background:#ffffff0d;color:#fff}.nav-item.active{background:#294841;color:#e0f2e9;box-shadow:inset 3px 0 #63b29a}.sidebar-bottom{margin-top:auto}.sidebar-note{font-size:13px;padding:20px 8px;color:#a7bbc2;line-height:2}.sidebar-note small{display:block;margin-left:14px;color:#8299a3;font-size:13px}.live-dot{display:inline-block;width:6px;height:6px;background:#48a58c;border-radius:50%;margin-right:6px;vertical-align:middle}.admin-profile{display:flex;align-items:center;gap:10px;border-top:1px solid #ffffff14;padding-top:20px;margin-top:16px;font-size:13px}.avatar{display:inline-flex;flex-shrink:0;align-items:center;justify-content:center;width:36px;height:36px;background:#e8efec;color:#597568;border-radius:11px;font-size:13px;font-weight:700}.admin-profile .avatar{background:#38514f;color:#d6e8e1}.profile-dot{width:6px;height:6px;background:#62b49b;border-radius:50%;margin-left:auto}.main{margin-left:236px;min-height:100vh}.top-bar{height:76px;padding:0 40px;background:#fff;border-bottom:1px solid var(--border);font-size:13px;color:#8c979e}.top-bar strong{color:#475a64;font-weight:500}.breadcrumb{padding:0 15px;color:#c0cbd0}.header-label{font-size:13px;letter-spacing:1.6px;color:#9da9af}.container{max-width:1500px;padding:39px 40px;margin:0 auto}.page-heading{display:flex;align-items:center;justify-content:space-between;gap:20px;margin-bottom:30px}.eyebrow{font-size:13px;font-weight:700;color:#358776;letter-spacing:2px;margin-bottom:12px}.page-description{color:var(--muted);font-size:13px;margin-bottom:0;line-height:1.9}.update-indicator{background:#edf4f0;color:#658577;font-size:13px;padding:7px 10px;border-radius:6px;white-space:nowrap}.stats-grid{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:16px;margin-bottom:29px}.stat-card{padding:22px 23px 19px;border:1px solid var(--border);border-radius:12px;background:#fff;min-width:0;box-shadow:0 2px 3px #173c4802}.stat-label{display:flex;align-items:center;justify-content:space-between;font-size:13px;color:#72818a;margin-bottom:13px}.stat-label>span{color:#a0b2ba;font-size:17px}.stat-card strong{font-size:30px;line-height:1.5;letter-spacing:-1.2px;font-weight:600;font-variant-numeric:tabular-nums}.stat-unit{font-size:13px;color:#86979d;margin-left:8px}.stat-card small{display:block;color:#93a0a7;font-size:13px;margin-top:8px}.accent-stat{background:#eff6f3;border-color:#dcebe3}.accent-stat strong{color:#237d65}#stat-active,#stat-idle{font-size:23px;line-height:1.95}.card{padding:0;border:1px solid var(--border);box-shadow:0 3px 8px #213a4802;overflow:hidden;margin-bottom:24px}.section-header{display:flex;align-items:center;justify-content:space-between;gap:20px;padding:25px 26px}.section-header .muted{margin:6px 0 0;font-size:13px}.title-row{display:flex;align-items:center;gap:10px;flex-wrap:wrap}.count-pill{background:#f1f4f6;border:1px solid #e9eef1;padding:3px 8px;border-radius:5px;font-size:13px;color:#83929b;letter-spacing:.6px;white-space:nowrap}.date-control{display:flex;align-items:center;gap:9px;flex-shrink:0;font-size:13px;color:var(--muted)}input[type=date]{color:#43535d;font-size:13px;background:#fff;padding:8px 10px;border-color:#e1e7eb;border-radius:7px}.table-scroll{overflow:auto}table{font-size:13px;white-space:nowrap}th{background:#f8fafb;font-size:13px;text-transform:none;letter-spacing:.15px;font-weight:500;padding:13px 22px;border-top:1px solid var(--border);color:#85939c}td{padding:22px;vertical-align:middle;color:#566773;font-variant-numeric:tabular-nums}tr:last-child td{border-bottom:0}.summary-table td{padding:23px 19px}.summary-table th{padding:13px 19px}.summary-table td:nth-child(5){color:#2b7a69;font-weight:600}.person-cell{display:flex;gap:11px;align-items:center}.person-cell strong{font-size:13px;color:#354953;font-weight:600;display:block}.person-cell small{display:block;font-size:13px;color:#9aa6ae;margin-top:4px}.person-cell .avatar{background:#eaf0f7;color:#6485a3}.clickable:nth-child(2n) .avatar{background:#f2edf6;color:#9b80ac}.clickable:nth-child(3n) .avatar{background:#f6f0e7;color:#b09970}tr.clickable:hover{background:#f5faf8}.badge{font-size:13px;font-weight:500;padding:4px 9px;white-space:nowrap}.badge:before{content:'';display:inline-block;width:5px;height:5px;border-radius:50%;background:currentColor;margin-right:6px}.badge.online{background:#eaf5ef;color:#359077}.badge.away{background:#faf3e6;color:#b69149}.badge.offline{background:#f0f3f5;color:#83909a}.table-footer{display:flex;justify-content:space-between;border-top:1px solid var(--border);padding:15px 24px;color:#95a2aa;font-size:13px}.legend-dot{display:inline-block;background:#299a88;width:6px;height:6px;border-radius:2px;margin-right:5px}.idle-dot{background:#dce3e8;margin-left:13px}.page-footer{display:flex;justify-content:space-between;font-size:13px;color:#a5b0b7;padding:14px 0;margin-top:26px;letter-spacing:.5px}.footer-dot{padding:0 10px;color:#c0c9ce}.detail-grid{display:grid;grid-template-columns:1.5fr 1fr;gap:22px}.chart-pad{padding:16px 26px 30px}.hourly-plot:not(.compact){background:repeating-linear-gradient(to top,#edf1f3 0,#edf1f3 1px,transparent 1px,transparent 35px);border-bottom:1px solid #dde5e8}.hourly-plot.compact{min-width:110px;gap:3px}.hourly-axis{margin-top:10px}.hourly-axis-slot{font-size:13px}.timeline-legend{margin-top:23px;gap:15px}.timeline-legend-item{font-size:13px;color:#7a8a94}.timeline-legend-swatch{width:7px;height:7px}.bar-row{margin-bottom:20px;gap:14px}.bar-label{width:90px;font-size:13px;color:#526673}.bar-track{height:8px;background:#f0f4f6;border-radius:3px}.bar-fill{border-radius:3px}.bar-value{width:82px;font-size:13px}.back-link{padding:0;background:transparent;color:#70858f;font-size:13px;margin-bottom:25px;min-height:24px}.back-link:hover{background:transparent;color:var(--primary)}.log-table{max-height:420px}.log-table th{position:sticky;top:0}.log-table td:nth-child(4){white-space:normal;min-width:200px;overflow-wrap:anywhere}.form-row{padding:0 26px 26px;align-items:flex-end;gap:15px;margin:0}.form-row label{display:flex;flex-direction:column;gap:8px;font-size:13px;color:#6f818c;flex:1}.form-row input{width:100%;font-size:13px;padding:11px 12px}.form-row button{font-size:13px;padding:11px 20px}.token-notice{padding:0 26px 25px}.token-box{background:#edf5f1;color:#377663}.maintenance{display:flex;justify-content:space-between;align-items:center;padding:18px 2px}.maintenance strong{font-size:13px}.maintenance p{font-size:13px;margin:4px 0 0}button.secondary{background:white;border:1px solid #dfe6eb;color:#70818b;font-size:13px;padding:7px 12px;min-height:33px}button.secondary:hover{background:#f2f7f5;border-color:#bbd6cb}button.danger{font-size:13px;background:#fff5f3;color:#b16d62;padding:7px 12px;min-height:33px}#employee-table-body button{margin:3px}.error-banner{background:#fff0ed;color:#a44835;padding:13px 18px;border-radius:8px;margin-bottom:20px}.login-page{display:grid;grid-template-columns:1fr 1fr;min-height:100vh;background:#fff}.login-story{background:#172e37;color:#fff;padding:45px 55px;display:flex;flex-direction:column;min-height:100vh;overflow:hidden}.login-story>.brand{padding:0}.story-content{margin:auto 0;padding:70px 0}.story-content .eyebrow{color:#7fb6a5;font-size:13px}.story-content h1{font-size:43px;line-height:1.6;letter-spacing:1px;margin:22px 0}.story-content p:not(.eyebrow){color:#9fb4bd;font-size:13px;line-height:2.3}.story-chart{display:flex;align-items:flex-end;gap:11px;height:140px;margin-top:55px;padding-bottom:15px;border-bottom:1px solid #ffffff18}.story-chart span{flex:1;height:70%;background:#4c9889;border-radius:5px 5px 0 0}.story-chart span:nth-child(3n){height:95%;background:#95c5b2}.story-chart span:nth-child(3n+1){height:40%;background:#345b5e}.story-chart span:nth-child(4n){height:60%}.story-caption{display:flex;justify-content:space-between;font-size:13px;letter-spacing:1.5px;color:#73939d;margin-top:15px}.login-story>small{font-size:13px;letter-spacing:2px;color:#71909a}.login-wrap{min-height:100vh;height:auto;position:relative;padding:50px}.login-card{width:360px}.login-card h2{font-size:28px!important;margin:0 0 12px;letter-spacing:-.7px}.login-card form{margin-top:38px}.login-card label{display:block;font-size:13px;color:#637883;margin-bottom:10px}.login-card input{width:100%;padding:14px;font-size:13px;background:#fafcfc}.login-card button{display:flex;justify-content:space-between;width:100%;margin-top:22px;padding:13px 18px;font-size:13px}.login-footnote{font-size:13px;color:#a0adb5;text-align:center;margin-top:25px}.login-copyright{position:absolute;bottom:32px;color:#aeb9c0;letter-spacing:1.5px;font-size:13px}
@media(min-width:1500px){.container{padding-top:48px}.summary-table td{padding-top:29px;padding-bottom:29px}}
@media(max-width:1150px){.sidebar{width:202px;padding-left:12px;padding-right:12px}.main{margin-left:202px}.container{padding:30px 25px}.top-bar{padding:0 25px}.stat-card{padding:18px 16px}.page-heading{align-items:flex-start}.update-indicator{margin-top:8px}.section-header{flex-wrap:wrap}.login-story{padding:35px}.story-content h1{font-size:35px}}
@media(max-width:800px){.sidebar{position:static;width:100%;padding:14px 20px;flex-direction:row;align-items:center;gap:20px}.brand{font-size:22px;padding:0}.brand-mark{width:30px;height:30px;font-size:22px}.brand-label,.workspace,.nav-label,.sidebar-note,.admin-profile{display:none}.sidebar nav{display:flex;gap:5px;margin-left:auto}.nav-item{font-size:13px;padding:8px;margin:0;white-space:nowrap}.nav-item span{display:none}.sidebar-bottom{margin:0}.main{margin-left:0}.top-bar{height:52px}.header-label{display:none}.container{padding:26px 20px}.page-heading{flex-wrap:wrap;gap:10px}h1{font-size:25px}.stats-grid{grid-template-columns:repeat(2,minmax(0,1fr));gap:12px}.detail-grid{grid-template-columns:1fr;gap:0}.page-footer>span:last-child{display:none}.login-page{grid-template-columns:1fr}.login-story{display:none}.login-wrap{padding:30px;min-height:100dvh}.login-card{max-width:360px;width:100%}.form-row{flex-direction:column;align-items:stretch}.section-header{padding:20px}.table-footer{padding:14px}.chart-pad{padding:15px 16px 25px}.hourly-plot{gap:3px;min-width:0}.hourly-axis{gap:3px}.hourly-axis-slot{font-size:13px}.maintenance{gap:15px}.maintenance button{white-space:nowrap}}
@media(prefers-reduced-motion:reduce){*{transition:none!important}}
@media(max-width:520px){.sidebar{flex-wrap:wrap;gap:10px}.sidebar nav{order:3;width:100%;margin:0}.sidebar nav .nav-item{width:auto;flex:1;justify-content:center}.sidebar-bottom{margin-left:auto}.stat-card strong{font-size:28px}#stat-active,#stat-idle{font-size:20px}.page-heading .update-indicator{margin-top:0}.date-control{max-width:100%}}

/* Readability: readable secondary text and consistent minimum type sizes. */
:root { --muted: #52636e; --primary: #107969; --primary-dark: #0c6053; }
body { font-size: 15px; }
h2 { font-size: 18px !important; }
small, .muted { font-size: 13px; }
.page-description, table, .person-cell strong, .nav-item,
.form-row input, .form-row button, .login-card input, .login-card button { font-size: 14px; }
.stat-label, .date-control, input[type=date], th, .badge,
.form-row label, .login-card label, button.secondary, button.danger { font-size: 14px; }
.stat-card small, .person-cell small, .count-pill, .table-footer,
.page-footer, .header-label, .top-bar, .breadcrumb, .footer-dot,
.timeline-legend-item, .hourly-axis-slot, .bar-value, .bar-label,
.login-footnote, .login-copyright { color: #52636e; }
.stat-label, .stat-unit, .stat-label>span { color: #52636e; }
.stat-card strong { color: #233b46; }
.accent-stat strong { color: #17664e; }
.update-indicator { color: #35624e; }
.badge.online { color: #216b54; }
.badge.away { color: #805b18; }
.badge.offline { color: #52616c; }
.person-cell .avatar, .clickable:nth-child(2n) .avatar,
.clickable:nth-child(3n) .avatar { color: #405c70; }
button.secondary { color: #465d69; }
button.danger { color: #964a3e; }
input::placeholder { color: #64727b; opacity: 1; }
.sidebar .brand-label, .sidebar .nav-label, .workspace small,
.admin-profile small, .sidebar-note, .sidebar-note small,
.sidebar .nav-item { color: #bccdd4; }
.sidebar .nav-item.active { color: #f0fff8; }
.workspace { font-size: 13px; }
.sidebar-note { line-height: 1.8; }
.brand-label { font-size: 13px; letter-spacing: .4px; }
.nav-label, .eyebrow, .header-label, .page-footer { letter-spacing: .8px; }
.story-content p:not(.eyebrow), .story-caption, .login-story>small { color: #bbced6; font-size: 14px; }
.story-content .eyebrow { color: #9ed9c5; font-size: 13px; }
.brand-mark { background: #197d6d; font-size: 23px; }
.bar-label { width: 105px; }
.bar-value { width: 100px; }
.timeline-tooltip { font-size: 14px; max-width: 380px; }
.timeline-tooltip .tt-header, .timeline-tooltip .tt-window { color: #d5e0e4; }
.hourly-axis-slot { font-size: 13px; }
@media(max-width:800px) {
  .sidebar .nav-item { font-size: 14px; }
  .hourly-axis-slot { font-size: 13px; }
  #detail-timeline-chart { overflow-x: auto; }
  #detail-timeline-chart .hourly-plot, #detail-timeline-chart .hourly-axis { min-width: 540px; }
  .page-footer { flex-wrap: wrap; }
}
th { color: #52636e; }
.brand-label { white-space: nowrap; font-size: 13px; letter-spacing: 0; }
@media(max-width:1150px) and (min-width:801px) { .stats-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }

/* Direct month/day navigation in member details. */
.detail-datebar { display:flex; align-items:center; gap:18px; flex-wrap:wrap; padding:18px 20px; margin-bottom:24px; background:#fff; border:1px solid #d7e0e5; border-radius:12px; }
.datebar-controls { display:flex; align-items:center; gap:18px; flex-wrap:wrap; }
.month-buttons { display:flex; }
.month-buttons button { min-height:36px; padding:6px 11px; border:1px solid #a7b8c1; border-radius:0; background:#fff; color:#345264; font-size:14px; }
.month-buttons button+button { border-left:0; }
.month-buttons button:first-child { border-radius:6px 0 0 6px; }
.month-buttons button:last-child { border-radius:0 6px 6px 0; }
.month-buttons button:hover { background:#edf5f2; }
#detail-today { color:#116b58; background:#edf7f2; }
#detail-date-label { font-size:18px; color:#263f4b; white-space:nowrap; font-variant-numeric:tabular-nums; }
.month-days { display:flex; overflow-x:auto; max-width:100%; padding:4px 2px 7px; }
.day-button { flex:0 0 31px; min-height:34px; padding:4px 0; border:1px solid #d4dfe6; border-radius:0; background:#fff; color:#344e60; font-size:14px; font-weight:500; }
.day-button+.day-button { margin-left:-1px; }
.day-button.saturday { background:#eaf2ff; color:#225d9d; }
.day-button.sunday { background:#fff0f0; color:#a73543; }
.day-button:hover { background:#e3efe9; color:#174e3e; }
.day-button.selected { background:#946000; border-color:#946000; color:#fff; font-weight:700; position:relative; }
.day-button[aria-current=date]:not(.selected) { box-shadow:inset 0 -3px #168575; }
.day-button:focus-visible { outline-offset:-3px; position:relative; z-index:1; }
@media(max-width:520px) { .detail-datebar { padding:14px; gap:10px; } .datebar-controls { gap:12px; } #detail-date-label { font-size:16px; } }
body { font-family: "Noto Sans JP", "Yu Gothic UI", "Meiryo", sans-serif; } button, input, select, textarea { font-family: inherit; }

/* Recoru connection and provenance */
.recoru-syncbar { display:flex; align-items:center; flex-wrap:wrap; gap:12px; padding:0 26px 20px; }
.recoru-settings { padding:0 26px 24px; }
.recoru-link-form { display:flex; gap:14px; align-items:flex-end; flex-wrap:wrap; margin:18px 0; }
.recoru-link-form label { display:flex; flex-direction:column; gap:7px; font-size:14px; color:#425b69; }
.recoru-link-form input,.recoru-link-form select { background:#fff; color:#233b46; border:1px solid #b7c6cf; border-radius:7px; min-height:42px; padding:8px 12px; font:inherit; max-width:100%; }
.recoru-link-form button { font-size:14px; }
.source-label { display:block; font-size:13px; color:#52636e; margin-top:5px; }
.attendance-source { margin:0; padding:0 26px 20px; color:#425b69; font-size:13px; }
@media(max-width:600px) { .recoru-link-form { flex-direction:column; align-items:stretch; } }

.attendance-subtitle { padding:16px 26px 10px; margin:0; color:#354e5b; font-size:15px; }
.summary-table td:nth-child(5) { color:#566773; font-weight:400; }
.summary-table td:nth-child(5),.summary-table td:nth-child(6) { background:#f1f7f5; color:#255e4f; }

/* Secondary explanations are available on demand. */
.ui-help { margin:12px 0; color:#425b69; font-size:14px; line-height:1.8; }
.ui-help summary { cursor:pointer; width:fit-content; font-weight:500; padding:4px 0; }
.ui-help summary:focus-visible { outline:2px solid #167561; outline-offset:4px; }
.ui-help p { margin:8px 0; max-width:85ch; }
#summary-recoru-message:empty, #ai-status:empty, .section-header p:empty { display:none; }
