* { box-sizing: border-box; }
body { font-family: -apple-system, "Hiragino Sans", "Noto Sans JP", sans-serif; margin: 0; background: #f6f7f9; color: #222; font-size: 16px; }
header { background: #fff; border-bottom: 1px solid #ddd; padding: 10px 14px; position: sticky; top: 0; z-index: 10; }
header h1 { font-size: 19px; margin: 2px 0 8px; }
#tabs { display: flex; gap: 6px; }
.tab { flex: 1; padding: 10px 4px; border: 1px solid #ccc; background: #fff; border-radius: 8px; font-size: 15px; }
.tab.active { background: #2f6fb2; color: #fff; border-color: #2f6fb2; }
main { padding: 12px; max-width: 760px; margin: 0 auto; }
.hidden { display: none !important; }
.card { background: #fff; border: 1px solid #e2e2e2; border-radius: 10px; padding: 14px; margin-bottom: 12px; }
.card h2 { font-size: 17px; margin: 0 0 10px; }
.card h3 { font-size: 15px; margin: 14px 0 6px; }
label { display: block; font-size: 13px; color: #555; margin: 10px 0 4px; }
input, select, textarea { width: 100%; padding: 10px; font-size: 16px; border: 1px solid #bbb; border-radius: 8px; background: #fff; }
textarea { min-height: 56px; }
button.btn { padding: 10px 14px; border: none; border-radius: 8px; background: #2f6fb2; color: #fff; font-size: 15px; }
button.btn.sub { background: #eef1f4; color: #234; border: 1px solid #c9d2da; }
button.btn.danger { background: #b23a2f; }
button.btn.small { padding: 6px 10px; font-size: 13px; }
button:disabled { opacity: .5; }
.row { display: flex; gap: 8px; align-items: center; }
.row > * { flex: 1; }
.row .shrink { flex: 0 0 auto; }
.badge { display: inline-block; padding: 2px 8px; border-radius: 999px; font-size: 12px; border: 1px solid #bbb; }
.st-pending { color: #1450c8; font-weight: 600; }   /* 申請中＝青文字 */
.st-approved { color: #111; font-weight: 600; }    /* 承認済み＝黒文字 */
.st-rejected { color: #b23a2f; font-weight: 600; }
.item { border-top: 1px solid #eee; padding: 10px 2px; }
.item:first-of-type { border-top: none; }
.meta { font-size: 13px; color: #666; }
.alert { background: #fdecea; border: 1px solid #e5a19a; color: #8c2b20; border-radius: 8px; padding: 10px; margin-bottom: 10px; font-size: 14px; }
.notice { background: #fff8e1; border: 1px solid #e3cf8a; border-radius: 8px; padding: 10px; margin-bottom: 8px; font-size: 14px; }
.bar { height: 10px; background: #e6e9ec; border-radius: 999px; overflow: hidden; margin: 4px 0 8px; }
.bar > div { height: 100%; background: #2f6fb2; }
.bar.over > div { background: #b23a2f; }
.chips { display: flex; gap: 6px; flex-wrap: wrap; margin: 6px 0; }
.chip { padding: 6px 12px; border: 1px solid #bbb; border-radius: 999px; background: #fff; font-size: 13px; }
.chip.active { background: #2f6fb2; color: #fff; border-color: #2f6fb2; }
table.cal { width: 100%; border-collapse: collapse; table-layout: fixed; }
table.cal td, table.cal th { border: 1px solid #e3e3e3; vertical-align: top; padding: 4px; font-size: 11px; height: 74px; background: #fff; }
table.cal th { height: auto; text-align: center; background: #f0f2f4; font-size: 12px; }
table.cal td.today { outline: 2px solid #2f6fb2; outline-offset: -2px; }
table.cal td.sel { background: #eef4fb; }
.cal-ev { display: block; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; line-height: 1.5; }
#toast { position: fixed; left: 50%; bottom: 22px; transform: translateX(-50%); background: #222; color: #fff; padding: 10px 18px; border-radius: 999px; font-size: 14px; opacity: 0; pointer-events: none; transition: opacity .25s; z-index: 50; max-width: 92vw; text-align: center; }
#toast.show { opacity: .94; }
.kv { font-size: 15px; margin: 4px 0; }
.kv b { font-size: 18px; }
details.timebox { border: 1px dashed #bbb; border-radius: 8px; padding: 8px 10px; margin-top: 8px; }
details.timebox summary { font-size: 14px; color: #2f6fb2; cursor: pointer; }
.modal-bg { position: fixed; inset: 0; background: rgba(0,0,0,.45); z-index: 40; display: flex; align-items: flex-start; justify-content: center; overflow: auto; }
.modal { background: #fff; border-radius: 12px; padding: 18px; margin: 24px 10px; max-width: 720px; width: 100%; }
pre.inv { white-space: pre-wrap; font-family: inherit; font-size: 14px; line-height: 1.7; }
