@charset "UTF-8";

:root {
  color-scheme: light;
  --paper: #faf8f2;
  --card: #fffefa;
  --ink: #293b33;
  --muted: #68766b;
  --green: #2f6754;
  --green-deep: #25533f;
  --green-soft: #e9f1e7;
  --line: #e3e5d9;
  --gold: #aa7724;
  --gold-soft: #fff2d4;
  --rose: #9f5140;
  --rose-soft: #fbece5;
  --shadow: 0 5px 24px #30493708;
  font-family: "Noto Sans JP", "Hiragino Kaku Gothic ProN", "Yu Gothic", Meiryo, sans-serif;
  font-synthesis: none;
  font-size: 16px;
  line-height: 1.7;
  color: var(--ink);
  background: var(--paper);
  -webkit-text-size-adjust: 100%;
}
* { box-sizing: border-box; }
body { margin: 0; min-width: 320px; }
button, input, select, textarea { font: inherit; }
button { -webkit-tap-highlight-color: transparent; cursor: pointer; }
button:disabled { cursor: default; }
button, input, select, textarea, summary, a { touch-action: manipulation; }
button:focus-visible, input:focus-visible, select:focus-visible, textarea:focus-visible, summary:focus-visible, img:focus-visible { outline: 3px solid #a8772a; outline-offset: 4px; }
h1, h2, h3, p { margin: 0; }
h1 { font-size: clamp(1.7rem, 6vw, 2.15rem); line-height: 1.45; letter-spacing: .01em; font-weight: 750; }
h2 { font-size: 1.15rem; line-height: 1.5; }
h3 { font-size: 1.1rem; line-height: 1.55; }
p { overflow-wrap: anywhere; }
img, video { max-width: 100%; }
fieldset { margin: 0; padding: 0; border: 0; }
.icon { width: 24px; height: 24px; flex: 0 0 24px; }
.app-shell { max-width: 800px; min-height: 100dvh; margin-inline: auto; }
.app-shell.with-nav { padding-bottom: calc(112px + env(safe-area-inset-bottom)); }
.app-header { min-height: 91px; padding: calc(16px + env(safe-area-inset-top)) 20px 16px; border-bottom: 1px solid var(--line); display: flex; justify-content: space-between; align-items: center; gap: 10px; }
.brand { display: flex; align-items: center; gap: 11px; }
.brand-mark { width: 46px; height: 46px; border-radius: 14px; }
.brand-overline { display: block; font-size: .64rem; color: var(--muted); letter-spacing: .08em; }
.brand strong { display: block; font-size: .95rem; letter-spacing: .03em; }
.role-pill { flex-shrink: 0; padding: 4px 10px; border: 1px solid #d6dfcf; border-radius: 99px; font-size: .71rem; color: var(--green); font-weight: 700; background: var(--card); }
.sync-bar { min-height: 38px; padding: 7px 22px; font-size: .73rem; color: var(--muted); display: flex; align-items: center; gap: 8px; }
.sync-dot { width: 7px; height: 7px; border-radius: 50%; background: #6c9472; flex-shrink: 0; }
.sync-bar.pending { color: #815f1e; }
.sync-bar.pending .sync-dot { background: #c49031; }
.sync-bar.failed { color: var(--rose); background: var(--rose-soft); }
.sync-bar.failed .sync-dot { background: var(--rose); }
.sync-bar .small-button { margin-left: auto; min-height: 36px; padding-block: 2px; font-size: .8rem; }
.page { padding: 26px 20px 32px; }
.page.narrow { max-width: 620px; margin-inline: auto; }
.page-heading { margin-bottom: 26px; }
.page-heading p { margin-top: 8px; color: var(--muted); font-size: .9rem; }
.page-heading h1 { white-space: pre-line; }
.card { padding: 23px 21px; border: 1px solid var(--line); border-radius: 20px; background: var(--card); box-shadow: var(--shadow); }
.page > .card + .card { margin-top: 18px; }
.card > h2 { margin-bottom: 13px; }
.card > p + .button { margin-top: 17px; }
.card > .button + .button { margin-top: 11px; }
.card > .quiet-text { margin-top: 15px; }
.card > .field + .button { margin-top: 20px; }
.section { margin-top: 31px; }
.section > h2, .section-title { margin-bottom: 14px; }
.section-title { display: flex; align-items: center; justify-content: space-between; }
.section-kicker { color: var(--green); font-size: .72rem; letter-spacing: .08em; font-weight: 750; margin-bottom: 18px; }
.count-chip { padding: 1px 10px; border-radius: 99px; color: var(--green); background: var(--green-soft); font-size: .82rem; font-weight: 700; }
.button { min-height: 52px; width: 100%; padding: 12px 16px; border: 1px solid transparent; border-radius: 13px; font-weight: 700; font-size: 1rem; line-height: 1.5; display: inline-flex; justify-content: center; align-items: center; gap: 9px; transition: background-color .15s, border-color .15s; }
.button.primary { color: white; background: var(--green); box-shadow: 0 3px 0 #244e3d; }
.button.primary:hover { background: var(--green-deep); }
.button.primary:active { box-shadow: none; transform: translateY(2px); }
.button.secondary { color: var(--green); border-color: #cbd8c9; background: #f9fbf5; }
.button.secondary:hover { background: var(--green-soft); }
.button.text { background: transparent; color: var(--green); box-shadow: none; width: auto; padding-inline: 10px; }
.button.redo { background: var(--rose-soft); color: #873b2c; border-color: #ebcbbd; }
.button:disabled { background: #e8eae2; border-color: #dfe2d8; color: #8c9589; box-shadow: none; transform: none; }
.button-row, .review-actions { display: flex; align-items: center; gap: 11px; margin-top: 18px; }
.button-row .button, .review-actions .button { flex: 1; }
.review-actions .primary { flex: 1.5; }
.quiet-text { color: var(--muted); font-size: .82rem; line-height: 1.75; }
.center { text-align: center; }
.notice { padding: 13px 16px; border-radius: 12px; font-size: .9rem; line-height: 1.7; background: var(--gold-soft); color: #6c551e; margin-bottom: 18px; }
.notice.success { background: var(--green-soft); color: var(--green-deep); }
.notice.error { background: var(--rose-soft); color: #833825; border: 1px solid #ecd0c1; }
.notice.redo { background: #fff3e6; color: #87442c; }
.global-message { padding: 0 20px; }
.global-message .notice { margin-bottom: 10px; }
.working { margin: 0 20px; padding: 8px; text-align: center; color: var(--muted); font-size: .8rem; }
.field { display: flex; flex-direction: column; gap: 8px; margin-bottom: 20px; }
.field-label, legend { font-size: .92rem; font-weight: 700; }
.field-hint { color: var(--muted); font-size: .76rem; }
input:not([type="checkbox"]):not([type="file"]), select, textarea { width: 100%; min-height: 52px; border: 1px solid #cbd3c6; border-radius: 11px; background: white; color: var(--ink); padding: 12px 13px; font-size: 1rem; }
input[type="file"] { width: 100%; font-size: .86rem; min-height: 52px; }
input[type="file"]::file-selector-button { min-height: 48px; padding: 10px 12px; margin-right: 10px; border: 1px solid #cbd8c9; border-radius: 10px; background: var(--green-soft); color: var(--green); font: inherit; }
textarea { resize: vertical; }
input::placeholder, textarea::placeholder { color: #8b9286; opacity: 1; }
input[type="checkbox"] { width: 22px; height: 22px; accent-color: var(--green); flex: 0 0 22px; margin: 0; }
.check-field { display: flex; align-items: center; gap: 11px; min-height: 48px; font-size: .92rem; }
.bottom-nav { position: fixed; z-index: 10; bottom: 0; left: 50%; transform: translateX(-50%); width: min(100%, 800px); padding: 7px 12px calc(7px + env(safe-area-inset-bottom)); min-height: 82px; display: flex; gap: 8px; border-top: 1px solid var(--line); background: #fffefa; box-shadow: 0 -4px 20px #293b3308; }
.nav-item { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px; min-width: 0; min-height: 60px; border: 0; border-radius: 13px; color: #7e897d; background: transparent; font-size: .74rem; font-weight: 700; }
.nav-item.active { color: var(--green); background: var(--green-soft); }
.nav-item .icon { width: 22px; height: 22px; }
.child-identity { display: flex; align-items: center; gap: 14px; }
.child-avatar { width: 52px; height: 52px; border-radius: 17px; background: #f0e7cf; color: #6d694c; display: flex; align-items: center; justify-content: center; font-size: 1.2rem; font-weight: 750; flex-shrink: 0; }
.child-identity p { margin-top: 2px; color: var(--muted); font-size: .78rem; }
.metrics { display: grid; grid-template-columns: repeat(4, 1fr); margin: 24px 0 20px; gap: 8px; }
.metric { display: flex; flex-direction: column; text-align: center; border-right: 1px solid var(--line); }
.metric:last-child { border-right: 0; }
.metric strong { font-size: 1.8rem; font-weight: 700; line-height: 1.3; }
.metric span { font-size: .68rem; margin-top: 5px; color: var(--muted); }
.metric-done strong { color: var(--green); }
.metric-waiting strong { color: var(--gold); }
.metric-redo strong { color: var(--rose); }
progress { appearance: none; display: block; border: none; width: 100%; height: 8px; overflow: hidden; border-radius: 99px; background: #ecede4; }
progress::-webkit-progress-bar { background: #ecede4; border-radius: 99px; }
progress::-webkit-progress-value { background: #70926c; border-radius: 99px; }
progress::-moz-progress-bar { background: #70926c; border-radius: 99px; }
.review-row { width: 100%; display: flex; align-items: center; gap: 15px; min-height: 90px; padding: 19px; border: 1px solid #e5dbc5; border-radius: 17px; text-align: left; background: #fffcf3; color: var(--ink); margin-bottom: 11px; }
.review-row:hover { background: var(--gold-soft); }
.review-symbol { width: 46px; height: 46px; background: #f7eed6; border-radius: 13px; display: flex; align-items: center; justify-content: center; color: #92723c; flex-shrink: 0; }
.review-row-content { flex: 1; }
.review-row strong { display: block; font-size: 1.07rem; }
.review-row small { display: block; margin-top: 3px; font-size: .76rem; color: var(--muted); }
.review-row > .icon { width: 20px; color: #8d977f; }
.task-list, .master-list { display: flex; flex-direction: column; gap: 16px; }
.task-topline { display: flex; justify-content: space-between; gap: 12px; align-items: flex-start; }
.task-topline h2, .task-topline h3 { overflow-wrap: anywhere; }
.status { flex-shrink: 0; font-weight: 700; font-size: .68rem; border-radius: 99px; padding: 5px 9px; line-height: 1.6; }
.status-todo { color: #737e71; background: #eeefe9; }
.status-waiting { color: #896318; background: #fcf0d1; }
.status-done { color: #316444; background: #e8f1e5; }
.status-redo { color: #98452f; background: #fae9df; }
.readonly-task { padding-block: 18px; }
.readonly-task > .quiet-text { margin-top: 10px; }
.history-photos { margin-top: 13px; }
.history-photos .button { font-size: .86rem; }
.privacy-footer { margin-top: 28px; font-size: .72rem; color: #7c877b; display: flex; align-items: center; justify-content: center; gap: 7px; }
.privacy-footer .icon { width: 15px; height: 15px; flex-basis: 15px; }
.parent-comment { margin-top: 18px; padding: 13px 15px; border-left: 3px solid #c2d3b8; background: #f2f5ed; border-radius: 0 10px 10px 0; }
.parent-comment small { color: #637d5a; font-size: .72rem; font-weight: 700; }
.parent-comment p { font-size: .98rem; margin-top: 4px; white-space: pre-wrap; }
.review-photos { display: flex; flex-direction: column; gap: 16px; }
.photo-frame { border-radius: 13px; overflow: hidden; background: #efede3; min-height: 100px; display: flex; justify-content: center; align-items: center; position: relative; }
.photo-frame.large { background: #e9e7de; border-radius: 17px; }
.homework-photo { display: block; max-width: 100%; max-height: 60dvh; object-fit: contain; }
.photo-large { width: 100%; max-height: 75dvh; cursor: zoom-in; }
.photo-loading { padding: 25px 16px; color: var(--muted); text-align: center; font-size: .82rem; }
.review-photos + .quiet-text { margin: 13px 0 22px; }
.child-greeting { display: flex; justify-content: space-between; gap: 12px; margin-bottom: 10px; font-size: .86rem; color: var(--green); font-weight: 700; }
.date-label { font-size: .7rem; color: var(--muted); font-weight: 400; align-self: center; }
.child-progress { margin: -5px 0 28px; }
.child-progress span { display: block; font-size: .86rem; color: var(--muted); margin-bottom: 9px; }
.child-progress strong { color: var(--green); font-size: 1.45rem; }
.child-task { padding: 22px 18px; border-radius: 19px; }
.child-task h2 { font-size: 1.22rem; }
.child-task .task-topline { gap: 8px; }
.child-task .task-topline .status { font-size: .64rem; }
.task-name { display: flex; align-items: baseline; gap: 11px; }
.task-number { font-family: ui-monospace, monospace; font-size: .78rem; color: #9caa92; font-weight: 700; }
.task-body { margin-top: 21px; }
.photo-requirement { font-size: .92rem; color: var(--muted); display: flex; align-items: center; gap: 8px; margin-bottom: 14px; }
.photo-requirement .icon { width: 19px; height: 19px; flex-basis: 19px; }
.photo-buttons { display: grid; grid-template-columns: 1fr 1fr; gap: 9px; margin: 15px 0 14px; }
.photo-buttons .button { font-size: .92rem; padding-inline: 9px; gap: 6px; min-height: 55px; }
.photo-buttons .icon { width: 22px; height: 22px; flex-basis: 22px; }
.submit-button { min-height: 56px; font-size: 1.08rem; }
.draft-preview { margin-top: 8px; }
.draft-caption { display: flex; justify-content: space-between; align-items: center; gap: 8px; font-size: .82rem; }
.draft-caption .button { font-size: .76rem; gap: 5px; }
.draft-caption .button .icon { width: 16px; height: 16px; flex-basis: 16px; }
.task-redo > .notice { margin: 17px 0 0; }
.task-done { border-color: #d3e0c8; background: #fbfdf7; }
.submitted-note { display: flex; align-items: center; gap: 10px; margin-top: 20px; color: #8c702b; }
.submitted-note p { font-size: .94rem; }
.done-note { color: var(--green); }
.all-done { margin-bottom: 24px; padding: 26px 20px; border-radius: 20px; background: #e9f1e1; border: 1px solid #d5e3c6; text-align: center; }
.celebration-mark { width: 49px; height: 49px; border-radius: 50%; display: inline-flex; align-items: center; justify-content: center; margin-bottom: 12px; color: white; background: #6d9164; }
.all-done h2 { font-size: 1.16rem; color: var(--green-deep); }
.all-done p { font-size: .88rem; margin-top: 7px; color: var(--green); }
.empty-state { padding: 28px 16px; text-align: center; color: var(--muted); background: #f1f4e9; border-radius: 16px; }
.empty-state > .icon { margin-bottom: 13px; color: #719768; width: 36px; height: 36px; }
.empty-state p { margin-top: 9px; font-size: .84rem; }
.history-picker .child-identity { margin-bottom: 22px; }
.history-picker .field { margin-bottom: 0; }
.child-identity.small .child-avatar { width: 42px; height: 42px; border-radius: 13px; font-size: 1rem; }
.master-list { margin-bottom: 18px; }
.master-card { padding: 21px 18px; }
.master-topline { display: flex; justify-content: space-between; align-items: center; margin-bottom: 17px; }
.master-topline .section-kicker { margin-bottom: 0; }
.master-topline .check-field { min-height: 32px; }
.weekday-fieldset { margin-bottom: 17px; }
.weekday-fieldset legend { margin-bottom: 11px; }
.weekday-grid { display: grid; grid-template-columns: repeat(7, 1fr); gap: 6px; }
.weekday-option { display: flex; position: relative; min-width: 0; height: 50px; align-items: center; justify-content: center; border: 1px solid #d8decf; border-radius: 10px; background: white; font-size: .94rem; color: var(--muted); font-weight: 700; cursor: pointer; }
.weekday-option input { position: absolute; width: 100%; height: 100%; opacity: 0; inset: 0; cursor: pointer; }
.weekday-option:has(input:checked) { background: var(--green); border-color: var(--green); color: white; }
.weekday-option:has(input:focus-visible) { outline: 3px solid #a8772a; outline-offset: 3px; }
.master-flags { border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); padding: 10px 0; }
.order-controls { display: flex; align-items: center; justify-content: flex-end; gap: 6px; padding-top: 6px; }
.order-controls > span { margin-right: auto; }
.order-controls .button { font-size: .82rem; min-height: 48px; }
.sticky-action { position: sticky; z-index: 5; bottom: calc(92px + env(safe-area-inset-bottom)); padding: 12px 0; margin-top: 10px; background: var(--paper); }
.horizon-card { background: #f4f7ee; }
.horizon-date { display: block; font-size: 1.38rem; color: var(--green); margin-bottom: 13px; }
.restore-details { border-top: 1px solid var(--line); margin-top: 24px; padding-top: 10px; }
.restore-details summary { font-weight: 700; color: var(--green); min-height: 48px; padding-block: 10px; cursor: pointer; }
.restore-details > .quiet-text { margin: 7px 0 20px; }
.privacy-card { position: relative; }
.privacy-card > .icon { color: #8b9c7e; margin-bottom: 11px; }
.recovery-code { font: 600 1.03rem/1.9 ui-monospace, monospace; color: var(--green-deep); background: #f5f6ed; letter-spacing: .04em; }
.pair-code { font: .75rem/1.6 ui-monospace, monospace; overflow-wrap: anywhere; word-break: break-all; }
.number-card { text-align: center; }
.number-card > p { margin: 17px 0 19px; font-size: .88rem; }
.number-card .check-field { text-align: left; margin-bottom: 20px; }
.confirmation-number { display: block; margin: 21px -5px 17px; font: 700 clamp(1.32rem, 5.8vw, 2.15rem)/1.5 ui-monospace, monospace; color: var(--green); letter-spacing: .025em; white-space: nowrap; background: #f1f5e9; padding: 17px 4px; border-radius: 12px; }
.landing { padding-top: 26px; text-align: center; max-width: 590px; margin-inline: auto; }
.welcome-art { width: 158px; height: 158px; margin: 4px auto 26px; }
.welcome-art img { width: 100%; height: 100%; border-radius: 38px; }
.landing .page-heading { margin-bottom: 17px; }
.landing h1 { line-height: 1.55; }
.landing .page-heading p { max-width: 280px; margin: 12px auto 0; }
.privacy-line { display: flex; justify-content: center; align-items: center; gap: 7px; font-size: .73rem; color: var(--muted); margin-bottom: 28px; }
.privacy-line .icon { width: 16px; height: 16px; flex-basis: 16px; }
.landing > .button { margin-top: 13px; }
.landing > .quiet-text { margin-top: 19px; }
.install-tip { border-top: 1px solid var(--line); margin-top: 32px; padding-top: 25px; }
.install-tip strong { font-size: .88rem; }
.install-tip p { font-size: .78rem; color: var(--muted); margin-top: 8px; }
.loading-screen { min-height: 80dvh; padding: 30px; display: flex; flex-direction: column; justify-content: center; align-items: center; text-align: center; color: var(--muted); font-size: .88rem; }
.loading-mark { width: 80px; height: 80px; margin-bottom: 22px; border-radius: 22px; }
dialog { border: 1px solid var(--line); border-radius: 20px; padding: 19px; background: var(--paper); color: var(--ink); width: min(calc(100% - 24px), 760px); max-height: 95dvh; overflow: auto; }
dialog::backdrop { background: #172d23a8; }
.dialog-header { display: flex; justify-content: space-between; align-items: center; gap: 10px; margin-bottom: 15px; }
.dialog-header h2 { font-size: 1rem; }
.dialog-header .button { min-height: 48px; font-size: .83rem; }
.camera-video { display: block; width: 100%; max-height: 60dvh; border-radius: 13px; background: #22352b; object-fit: contain; }
.camera-dialog > .quiet-text { margin: 17px 0; }
.photo-dialog > .button { margin-bottom: 15px; }
.photo-dialog .homework-photo { max-height: none; width: auto; }
.visually-hidden { position: absolute; width: 1px !important; height: 1px !important; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }
@media (min-width: 600px) {
  .app-header { padding-inline: 32px; }
  .brand strong { font-size: 1.08rem; }
  .page { padding-inline: 32px; }
  .sync-bar { padding-inline: 34px; }
  .global-message { padding-inline: 32px; }
  .child-task { padding: 26px; }
  .child-task .status { font-size: .75rem; }
  .photo-buttons .button { font-size: 1rem; }
  .photo-frame:not(.large) .homework-photo { max-height: 420px; }
  .weekday-option { height: 54px; }
}
@media (max-width: 359px) {
  .page { padding-inline: 14px; }
  .app-header { padding-inline: 14px; }
  .brand-mark { width: 38px; height: 38px; }
  .brand strong { font-size: .8rem; }
  .brand-overline { font-size: .58rem; }
  .role-pill { padding-inline: 7px; }
  .child-task { padding-inline: 14px; }
  .child-task h2 { font-size: 1.05rem; }
  .task-name { gap: 6px; }
  .photo-buttons .button { flex-direction: column; min-height: 72px; }
  .weekday-grid { gap: 3px; }
  .button-row { flex-direction: column; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; transition: none !important; }
}
