:root{font-family:'Segoe UI',Arial,sans-serif;color:#263649;background:#f5f7fa;font-synthesis:none;--blue:#315ede;--muted:#718094;--line:#e3e8f0}*{box-sizing:border-box}body{margin:0}button,input,select{font:inherit}button,a,input,select{touch-action:manipulation}button{cursor:pointer}button:focus-visible,a:focus-visible{outline:3px solid #8aa9ff;outline-offset:3px}button{border:1px solid var(--line);border-radius:7px;background:white;padding:10px 14px;color:inherit;font-weight:600}button:hover{background:#edf2fc}button:disabled{opacity:.45;cursor:default}header{height:82px;background:white;border-bottom:1px solid var(--line);padding:0 5%;display:flex;align-items:center;gap:36px}.brand{font-size:23px;font-weight:750;display:flex;align-items:center;gap:12px;color:inherit;text-decoration:none;letter-spacing:-.8px}.logo{background:var(--blue);color:white;width:36px;height:36px;border-radius:11px;display:grid;place-items:center;font-size:25px}.logo span{display:none}.tagline,.save-status{font-size:13px;color:var(--muted)}.save-status{margin-left:auto}.save-status:before{content:'●';color:#56a185;margin-right:7px;font-size:9px}main{max-width:1440px;margin:auto;padding:38px 5% 20px}.intro{display:flex;align-items:center;justify-content:space-between;gap:24px;margin-bottom:30px}h1{font-size:32px;font-weight:650;letter-spacing:-1.15px;margin:0 0 10px}p{line-height:1.55;margin:6px 0}h2{font-size:18px;letter-spacing:-.3px;margin:0}.intro p,.subtle{color:var(--muted);font-size:13px}.workspace{display:grid;grid-template-columns:275px 1fr;gap:26px}.settings{background:white;border:1px solid var(--line);border-radius:12px;padding:24px}.settings h2{margin-bottom:22px}label{display:block;font-size:12px;font-weight:600;margin-bottom:16px}input:not([type=checkbox]),select{display:block;width:100%;margin-top:8px;border:1px solid #dce2eb;border-radius:6px;background:#fff;padding:10px;color:#263649;min-height:40px}input:focus,select:focus{outline:2px solid #a6baff;border-color:var(--blue)}.hint{font-size:11px;color:var(--muted);line-height:1.55;margin:-6px 0 18px}.segmented{display:flex;background:#f0f3f8;padding:3px;border-radius:7px;margin:22px 0 18px}.segmented button{width:50%;font-size:12px;border:0;background:transparent;padding:9px 5px}.segmented button.active{background:white;color:var(--blue);box-shadow:0 1px 4px #26364915}fieldset{border:0;padding:0;margin:20px 0 14px}legend{font-size:12px;font-weight:600;margin-bottom:10px}.weekdays{display:flex;gap:4px}.weekdays button{padding:0;min-width:26px;height:30px;font-size:11px;flex:1}.weekdays .active{color:var(--blue);background:#eaf0ff;border-color:#d3dfff}.aside-note{display:flex;gap:12px;border-top:1px solid var(--line);padding-top:18px;margin-top:24px}.aside-note span{font-size:25px;color:var(--blue)}.aside-note p{font-size:11px;color:var(--muted);margin:0}.summary{display:flex;background:#eaf0fe;border-radius:12px;padding:26px 30px;gap:28px;align-items:center;margin-bottom:24px}.daily{min-width:205px}.daily>span{font-size:12px;color:#4f65a3;font-weight:600}.daily>div{display:flex;align-items:baseline;gap:9px;color:#274cba}.daily strong{font-size:56px;letter-spacing:-2px;font-weight:650;line-height:1.3}.daily>div>span{font-size:16px}.daily p{font-size:12px;color:#5670a5}.metrics{display:flex;flex:1;justify-content:space-around;gap:18px;border-left:1px solid #cedaf4;padding-left:22px}.metrics strong{display:block;font-size:28px;font-weight:600;letter-spacing:-1px}.metrics span{font-size:11px;color:#697992}.calendar-panel{background:#fff;border:1px solid var(--line);border-radius:12px;padding:24px}.section-heading{display:flex;align-items:center;justify-content:space-between;gap:16px}.legend{display:flex;flex-wrap:wrap;gap:18px;font-size:11px;color:#6c7c91;margin:18px 0}.legend span{display:flex;align-items:center;gap:6px}.dot{width:8px;height:8px;display:inline-block;border-radius:3px}.work{background:#4a74e8}.holiday{background:#edb750}.vacation{background:#a58acb}.weekend{background:#d7dde5}.personal{background:#71b6a4}.month-calendar{display:grid;grid-template-columns:repeat(7,minmax(0,1fr));gap:5px}.day-name{text-align:center;font-size:11px;color:#8691a3;padding:10px}.day{height:69px;min-width:0;text-align:left;padding:9px;border:1px solid #e6ebf3;background:#f1f5ff;position:relative;font-weight:500;display:flex;flex-direction:column;gap:7px}.day .date-number{font-size:13px}.day small{font-size:9px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;max-width:100%;color:#5f78b3}.day.off{background:#f8f9fb;color:#9da7b4;border-color:#f0f2f5}.day.past{background:#fff;color:#aab3bf;border-color:#f0f2f5}.day.holiday{background:#fff7e7;border-color:#f6e8c8}.day.holiday small{color:#a37c2f}.day.vacation{background:#f2edfa;border-color:#e6dcf4}.day.vacation small{color:#8a6ab4}.day.today .date-number{background:var(--blue);color:white;border-radius:50%;width:23px;height:23px;display:grid;place-items:center;margin-top:-3px;margin-left:-3px}.planner{background:white;border:1px solid var(--line);border-radius:12px;padding:26px;margin-top:26px}.actions{display:flex;gap:10px;align-items:center}.primary{background:var(--blue);border-color:var(--blue);color:white}.primary:hover{background:#254fc4}.secondary{font-size:12px}.planner-toolbar{display:flex;gap:24px;align-items:center;margin-top:18px}.week-nav{display:flex;align-items:center;gap:12px}.week-nav strong{font-size:12px;min-width:145px;text-align:center}.week-nav button{padding:4px 10px;font-size:22px;line-height:1}.planner-toolbar>span{margin-left:auto;font-size:12px}.progress{height:4px;background:#edf1f7;border-radius:8px;margin:8px 0 0;overflow:hidden}.progress div{height:100%;background:#6d8ff1;transition:width .2s}#plan-notice{font-size:12px;color:#9b7428;min-height:18px;margin:10px 0}.schedule-scroll{overflow:auto;max-height:590px}.schedule{min-width:780px;display:grid;grid-template-columns:52px repeat(7,minmax(100px,1fr));position:relative}.schedule-head{height:67px;text-align:center;font-size:11px;color:#7d899c;border-bottom:1px solid var(--line);position:sticky;top:0;background:white;z-index:3;padding-top:7px}.schedule-head strong{font-size:18px;display:inline-block;margin-left:5px;font-weight:500;color:#3a4c63}.schedule-head small{display:block;margin-top:6px;color:var(--blue);font-size:10px}.time-labels{position:relative;height:960px;font-size:10px;color:#96a1b1}.time-labels span{position:absolute;top:calc(var(--hour)*60px);transform:translateY(-50%)}.day-column{position:relative;height:960px;border-left:1px solid #e9edf4;background:repeating-linear-gradient(to bottom,transparent 0,transparent 59px,#edf0f5 59px,#edf0f5 60px)}.day-column.unavailable{background-color:#f8f9fb}.time-block{position:absolute;left:5px;right:5px;border:0;border-left:3px solid #4b75df;background:#eaf0ff;color:#3558b4;text-align:left;padding:7px 8px;overflow:hidden;border-radius:5px;font-size:11px;min-height:15px;font-weight:500}.time-block.personal{background:#eaf5f1;border-color:#72af9f;color:#4a8676}.time-block small{display:block;font-size:9px;margin-top:4px}.time-block:hover{filter:brightness(.97)}footer{padding:28px 0 10px;display:flex;justify-content:space-between;font-size:11px;color:#718094}footer a{color:inherit;margin-left:12px}dialog{border:1px solid var(--line);border-radius:15px;padding:26px;max-width:440px;width:calc(100% - 32px);box-shadow:0 20px 100px #26364930}dialog::backdrop{background:#1f30435e}.dialog-heading{display:flex;align-items:center;justify-content:space-between;margin-bottom:22px}.dialog-heading button{border:0;padding:0 6px;font-size:23px}.form-row{display:flex;gap:14px}.form-row label{flex:1;min-width:0}.check{display:flex;gap:8px;align-items:center;font-weight:400}.danger{color:#b24a4a;margin-right:auto}#block-error{color:#b24a4a;font-size:12px;margin-bottom:15px}[hidden]{display:none!important}@media(min-width:1500px){main{padding-left:30px;padding-right:30px}}@media(max-width:1000px){.summary{padding:22px;gap:15px}.metrics{gap:12px;padding-left:15px}.daily{min-width:150px}.daily strong{font-size:45px}.metrics strong{font-size:24px}.workspace{grid-template-columns:245px 1fr;gap:18px}.settings{padding:18px}.calendar-panel{padding:18px}.planner-toolbar{flex-wrap:wrap;gap:12px}.planner .section-heading{align-items:flex-start}.tagline{display:none}.day{padding:7px;height:65px}.section-heading>.subtle{display:none}}@media(max-width:760px){header{height:66px;padding:0 20px}main{padding:26px 16px}.intro{display:block}.intro button{margin-top:12px}h1{font-size:27px}.workspace{display:flex;flex-direction:column}.settings{display:grid;grid-template-columns:1fr 1fr;gap:0 18px}.settings h2,.settings .segmented,.settings .aside-note{grid-column:1/-1}.settings .aside-note{margin-top:0}.summary{gap:16px}.metrics{flex-wrap:wrap;justify-content:flex-start}.metrics div{min-width:65px}.calendar-panel{padding:14px}.legend{gap:12px}.planner{padding:17px}.planner .section-heading{display:block}.actions{margin-top:15px;flex-wrap:wrap}.planner-toolbar>span{margin-left:0}.day{height:60px;padding:6px}.day small{font-size:8px}footer{gap:20px;line-height:1.7}.save-status{font-size:10px}.schedule-scroll{max-height:500px}}@media(prefers-reduced-motion:reduce){*{transition:none!important}}

/* Dark mode keeps calendar categories distinct without bright surfaces. */
#theme-toggle { font-size:12px; white-space:nowrap; }
:root[data-theme="light"] { color-scheme:light; }
:root[data-theme="dark"] {
  color-scheme:dark;
  color:#dce4ef;
  background:#151b24;
  --blue:#8faeff;
  --muted:#a2afc2;
  --line:#334051;
}
[data-theme="dark"] :is(header,.settings,.calendar-panel,.planner,.schedule-head,dialog,button) { background:#1e2733; color:#dce4ef; }
[data-theme="dark"] button:hover { background:#303e52; }
[data-theme="dark"] :is(input:not([type=checkbox]),select) { background:#151e2a; color:#dce4ef; border-color:#405069; }
[data-theme="dark"] :is(.segmented,.progress) { background:#141d29; }
[data-theme="dark"] :is(.segmented button.active,.weekdays .active) { background:#2b3c5a; color:#b6cbff; border-color:#4a6393; }
[data-theme="dark"] .segmented button:not(.active) { background:transparent; }
[data-theme="dark"] .summary { background:#23324b; }
[data-theme="dark"] :is(.daily>span,.daily p,.daily>div,.day small,.schedule-head small) { color:#b3c9ff; }
[data-theme="dark"] .metrics { border-color:#435677; }
[data-theme="dark"] :is(.metrics span,.legend,.day-name,.schedule-head,.time-labels,footer) { color:#a2afc2; }
[data-theme="dark"] .schedule-head strong { color:#dce4ef; }
[data-theme="dark"] .day { background:#263650; border-color:#3b5074; }
[data-theme="dark"] .day.off { background:#1a222d; border-color:#303c4d; color:#a6b3c5; }
[data-theme="dark"] .day.past { background:#1e2733; border-color:#303c4d; color:#98a6ba; }
[data-theme="dark"] .day.holiday { background:#3a3225; border-color:#645338; }
[data-theme="dark"] .day.holiday small { color:#e8c480; }
[data-theme="dark"] .day.vacation { background:#342d46; border-color:#584870; }
[data-theme="dark"] .day.vacation small { color:#cfb5f2; }
[data-theme="dark"] :is(.logo,.primary,.day.today .date-number) { background:#416ad2; color:#fff; }
[data-theme="dark"] .primary:hover { background:#517be5; }
[data-theme="dark"] #plan-notice { color:#e8c480; }
[data-theme="dark"] .day-column { border-color:#334051; background-image:repeating-linear-gradient(to bottom,transparent 0,transparent 59px,#334051 59px,#334051 60px); }
[data-theme="dark"] .day-column.unavailable { background-color:#19212c; }
[data-theme="dark"] .time-block { background:#293e63; color:#c0d3ff; border-color:#85a7ff; }
[data-theme="dark"] .time-block.personal { background:#243e39; color:#a9dacb; border-color:#78bca9; }
[data-theme="dark"] :is(.danger,#block-error) { color:#ffa6a6; }
[data-theme="dark"] dialog::backdrop { background:#090e18b8; }
@media(max-width:760px) { header { gap:12px; flex-wrap:wrap; height:auto; min-height:66px; padding-top:12px; padding-bottom:12px; } #theme-toggle { padding:8px; } }

.quick-place,.lunch-options { display:flex; flex-wrap:wrap; align-items:center; gap:16px; padding:16px 0; border-bottom:1px solid var(--line); }
.quick-place label,.lunch-options label { margin:0; }
.quick-place input,.quick-place select,.lunch-options input,.lunch-options select { margin-top:4px; }
.preset-buttons { display:flex; gap:8px; }
[data-preset],.time-block { touch-action:none; cursor:grab; }
[data-preset][aria-pressed="true"] { outline:2px solid var(--blue); outline-offset:2px; }
.drag-preview { position:fixed; z-index:10; pointer-events:none; background:#315ede; color:white; padding:12px 16px; border-radius:8px; box-shadow:0 8px 30px #0005; font-size:13px; }
#placement-status { font-size:13px; color:var(--blue); min-height:20px; }
.lunch-options .check input { width:auto; }
.dragging { opacity:.35; }
.drag-preview.in-calendar { white-space:pre-line; padding:8px; border:2px solid #a9c1ff; background:#315ededd; border-radius:5px; font-size:11px; overflow:hidden; }
.drag-preview.in-calendar.personal { background:#285c4fee; border-color:#9bdbc6; }
.drag-preview.in-calendar.invalid { background:#823e48dd; border-color:#ffadb6; }
.sources-page { max-width:850px; }
.sources-page h1 { margin-top:30px; }
.sources-page section { padding:24px 0; border-bottom:1px solid var(--line); }
.sources-page p { margin-top:12px; }
.sources-page a { color:var(--blue); }
#language { width:auto; min-width:94px; margin:0; font-size:12px; }
html[lang="ja"] { font-family:'Segoe UI','Yu Gothic UI','Meiryo',sans-serif; }
html[lang="ja"] h1 { letter-spacing:0; line-height:1.5; }
html[lang="ja"] .actions { flex-wrap:wrap; }
html[lang="ja"] .section-heading { align-items:flex-start; }
html[lang="ja"] .day small { font-size:10px; }
@media(max-width:1100px) { header { gap:14px; } .planner>.section-heading { flex-wrap:wrap; } }
