/* ボランティア画面（A1・A2・A3・名前を変更する） */

.break-all { word-break: break-all; }

/* ---------- 帯 ---------- */
.band--names { padding: 26px 20px 16px; }
.band--names .band__sub { font-size: 14px; margin-top: 4px; }

.band--cal { padding: 24px 20px 10px; }
.band--cal .band__top { display: flex; align-items: baseline; justify-content: space-between; gap: 8px; }
.band--cal .band__row { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-top: 6px; }
.band--cal .band__period { display: none; }

.band--day { padding: 20px 12px 8px; display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.band--day .band__name { font-size: 15px; padding-right: 6px; }

/* ---------- A1・名前を変更する ---------- */
.page { padding: 24px 16px 32px; }
.page--rename { padding: 22px 16px 32px; }
.page__title { font-size: 24px; font-weight: 700; line-height: 1.4; margin: 0; }
.page__lead { font-size: 15px; color: var(--text-sub); line-height: 1.7; margin: 8px 0 0; }

.current-name {
  margin-top: 12px; padding: 12px 14px; background: var(--surface);
  border: 1px solid var(--rule); border-radius: 4px; font-size: 15px; line-height: 1.6;
}
.current-name strong { font-size: 18px; }

.name-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-top: 18px; }
.name-btn {
  min-height: 60px; padding: 6px; border-radius: 6px; background: #fff;
  border: 1.5px solid var(--input-border); color: var(--text);
  font-size: 18px; font-weight: 700; line-height: 1.3;
  overflow: hidden; text-overflow: ellipsis;
}
.name-btn[aria-current="true"] { background: var(--olive); color: #fff; border: 2px solid var(--olive); }

.add-area { margin-top: 24px; padding-top: 16px; border-top: 1px solid var(--rule); }
.add-area .btn--dashed { width: 100%; }
.add-area .label { margin-top: 16px; }
.add-area .input { margin-top: 8px; }
.add-area .btn--primary { margin-top: 12px; min-height: 56px; font-size: 17px; }

/* ---------- A2 お知らせ ---------- */
.notice { margin: 16px 16px 0; padding: 14px 16px 4px; }
.notice__title { font-size: 17px; font-weight: 700; margin: 0 0 8px; }
.notice__body {
  position: relative; overflow: hidden; font-size: 15px; line-height: 1.75;
  display: flex; flex-direction: column; gap: .8em; overflow-wrap: anywhere;
}
.notice__body p { margin: 0; white-space: pre-line; }
.notice__body.is-closed { max-height: 9.4em; }
.notice__body.is-closed::after {
  content: ''; position: absolute; left: 0; right: 0; bottom: 0; height: 3em;
  background: linear-gradient(rgba(251, 248, 240, 0), var(--surface));
}
.notice__toggle {
  min-height: 44px; width: 100%; background: none; border: none; border-top: 1px dashed var(--rule);
  margin-top: 8px; color: var(--olive-dark); font-size: 15px; font-weight: 700;
}

/* ---------- A2 カレンダー ---------- */
.cal-wrap { margin: 22px 16px 0; }
.section-head { display: flex; justify-content: space-between; align-items: baseline; gap: 8px; margin-bottom: 8px; }
.section-head h2 { font-size: 19px; font-weight: 700; margin: 0; }
.section-head p { font-size: 13px; color: var(--text-note); margin: 0; text-align: right; }

.cal-dow {
  display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); font-size: 13px; text-align: center;
  padding: 4px 0; border-top: 1.5px solid var(--text);
}
.cal-dow .sun { color: var(--sunday); }
.cal-dow .sat { color: var(--saturday); }

.cal {
  display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 1px;
  background: var(--rule); border: 1px solid var(--rule);
}
.cell {
  position: relative; display: flex; flex-direction: column; align-items: flex-start; gap: 3px;
  min-height: 74px; padding: 5px 4px 6px; border: none; text-align: left; color: var(--text);
  background: var(--surface); min-width: 0;
}
.cell--out { background: var(--ground); }
.cell--confirmed { background: var(--harvest-bg); }
.cell--canceled { background: var(--cancel-bg); }
.cell--reserve { background: var(--reserve-bg); }
.cell[aria-pressed="true"] { box-shadow: inset 0 0 0 2px var(--text); }
.cell__date { display: flex; flex-direction: column; line-height: 1.05; }
.cell__month { font-size: 10px; color: var(--text-note); min-height: 10px; }
.cell__day { font-size: 16px; font-weight: 700; }
.cell--sun .cell__day { color: var(--sunday); }
.cell--sat .cell__day { color: var(--saturday); }
.cell--out .cell__day { color: var(--out-date); }
.cell .good { position: absolute; top: 4px; right: 3px; }
.cell .tag { font-size: 10.5px; padding: 2px 3px; }
.cell .tag--canceled, .cell .tag--reserve { padding: 1px 3px; }
.cell__count { margin-top: auto; font-size: 13px; font-weight: 700; }
.cell__count.is-zero { color: #7A735E; }
.cell--canceled .cell__count { text-decoration: line-through; }
.cell__bar { width: 100%; height: 4px; background: var(--bar-bg); border-radius: 2px; overflow: hidden; }
.cell__bar > span { display: block; height: 100%; background: var(--olive); }
.cell--canceled .cell__bar > span { background: var(--cancel-bar); }

.legend {
  display: flex; flex-wrap: wrap; gap: 8px 14px; margin-top: 12px;
  font-size: 13px; color: var(--text-sub); align-items: center;
}
.legend > span { display: flex; align-items: center; gap: 5px; white-space: nowrap; }
.legend .tag { font-size: 11px; padding: 1px 4px; }
.legend .tag--confirmed { padding: 2px 4px; }
.legend__bar { width: 28px; height: 4px; background: linear-gradient(90deg, var(--olive) 60%, var(--bar-bg) 60%); border-radius: 2px; }

/* ---------- A2 選んだ日（スマートフォン） ---------- */
.picked { margin: 16px; padding: 14px 16px; background: var(--surface); border: 1.5px solid var(--text); border-radius: 4px; }
.picked__head { display: flex; align-items: center; gap: 12px; }
.picked__text { flex: 1; min-width: 0; }
.picked__label { font-size: 12px; color: var(--text-note); }
.picked__title { font-size: 19px; font-weight: 700; }
.picked__summary { font-size: 14px; }
.picked__head .btn { min-height: 48px; font-size: 15px; white-space: nowrap; }
.picked__slots { margin-top: 14px; padding-top: 12px; border-top: 1px solid var(--rule); }


/* ---------- A2 収穫する日 ---------- */
.harvest-list { margin: 8px 16px 28px; }
.harvest-list h2 { font-size: 19px; font-weight: 700; margin: 0 0 6px; }
.harvest-item {
  width: 100%; display: flex; align-items: center; gap: 12px; min-height: 64px; padding: 10px 2px;
  background: none; border: none; border-top: 1px solid var(--rule); text-align: left; color: var(--text);
}
.harvest-item__main { flex: 1; min-width: 0; }
.harvest-item__title { font-size: 18px; font-weight: 700; }
.harvest-item__memo { font-size: 14px; color: var(--text-sub); margin-top: 2px; }
.harvest-item__side { text-align: right; }
.harvest-item__count { font-size: 17px; font-weight: 700; }
.mine-note {
  display: flex; align-items: center; justify-content: flex-end; gap: 4px;
  font-size: 12px; color: var(--olive-dark); font-weight: 700; white-space: nowrap;
}

/* ---------- A3 日付の詳細 ---------- */
.day { padding: 18px 16px 32px; }
.day__label { font-size: 13px; color: var(--text-note); }
.day__head { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.day__title { font-size: 24px; font-weight: 700; margin: 0; line-height: 1.4; }
.day__title:focus { outline: none; }
.day__title:focus-visible { outline: 3px solid var(--text); outline-offset: 2px; }
.day__memo { margin-top: 12px; padding: 10px 14px; background: var(--surface-strong); border-radius: 3px; font-size: 15px; line-height: 1.6; white-space: pre-wrap; }

.mine { margin-top: 20px; padding: 18px 16px; background: #fff; border: 1.5px solid var(--olive); border-radius: 6px; }
.mine__title { font-size: 18px; font-weight: 700; margin: 0; overflow-wrap: anywhere; }
.mine__canceled { margin-top: 10px; font-size: 15px; line-height: 1.7; color: var(--cancel); font-weight: 700; }
.mine__view { margin-top: 12px; display: flex; align-items: center; gap: 12px; }
.mine__view-label { font-size: 13px; color: var(--text-note); }
.mine__view-time { font-size: 21px; font-weight: 700; }
.mine__view-memo { font-size: 15px; color: var(--text-sub); overflow-wrap: anywhere; }
.two-col { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.mine .two-col { margin-top: 8px; }
.mine__actions { margin-top: 16px; }
.mine .label { margin-top: 18px; }
.mine .label:first-of-type { margin-top: 14px; }
.preset { min-height: 62px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px; }
.preset__sub { font-size: 13px; font-weight: 400; }

.stepper { margin-top: 14px; padding: 14px 12px; background: var(--ground); border-radius: 4px; display: flex; flex-direction: column; gap: 12px; }
.stepper__row { display: grid; grid-template-columns: 64px 56px minmax(0, 1fr) 56px; align-items: center; gap: 8px; }
.stepper__label { font-size: 15px; font-weight: 700; }
.stepper__btn {
  height: 56px; border-radius: 4px; background: #fff; border: 1.5px solid var(--input-border);
  font-size: 26px; font-weight: 700; color: var(--text);
}
.stepper__btn[aria-disabled="true"] { opacity: .35; cursor: default; }
.stepper__time { text-align: center; font-size: 28px; font-weight: 700; }
.stepper__note { font-size: 13px; color: var(--text-sub); }

.chosen { margin-top: 14px; padding: 12px; background: var(--surface-strong); border-radius: 4px; text-align: center; }
.chosen__label { font-size: 13px; color: var(--text-sub); }
.chosen__time { font-size: 22px; font-weight: 700; }
.mine .input { margin-top: 8px; }
.mine__hint { margin-top: 14px; font-size: 15px; color: var(--text-sub); line-height: 1.7; }
.mine__save { margin-top: 20px; min-height: 58px; font-size: 18px; }
.mine__error { margin-top: 10px; }

.day-slots { margin-top: 24px; padding-top: 16px; border-top: 1.5px solid var(--text); }
.people { margin-top: 20px; }
.people__head { display: flex; justify-content: space-between; align-items: baseline; }
.people__head h3 { font-size: 16px; font-weight: 700; margin: 0; }
.people__count { font-size: 15px; font-weight: 700; }
.you-tag { flex: none; font-size: 11px; padding: 1px 5px; border: 1px solid var(--olive); color: var(--olive-dark); border-radius: 2px; font-weight: 400; }
.day__back { margin-top: 20px; }

/* ---------- 確認シートの中身 ---------- */
.sheet__box { margin-top: 12px; padding: 14px 16px; background: #fff; border: 1px solid var(--rule); border-radius: 4px; font-size: 16px; line-height: 1.7; }
.sheet__time { font-size: 21px; font-weight: 700; }
.sheet__memo { overflow-wrap: anywhere; }
.sheet__note { font-size: 14px; color: var(--text-sub); margin-top: 10px; line-height: 1.6; }
.sheet .btn--primary, .sheet .btn--danger { margin-top: 16px; min-height: 56px; font-size: 18px; }
.sheet .btn--secondary { margin-top: 8px; font-size: 17px; }

/* ---------- 名前を変更する（パソコンでは重ねて出す） ---------- */
.rename-shade {
  position: fixed; inset: 0; z-index: 40; background: var(--shade); overflow-y: auto;
  display: flex; align-items: flex-start; justify-content: center; padding: 80px 16px 40px;
}
.rename-box { width: 520px; max-width: 100%; background: var(--surface); border-radius: 8px; padding: 28px 28px 24px; }
.rename-box__head { display: flex; justify-content: space-between; align-items: center; }
.rename-box .current-name { background: #fff; }

/* ---------- パソコン ---------- */
@media (min-width: 900px) {
  .brand { left: 40px; top: 8px; }
  .band--cal { display: flex; align-items: center; justify-content: space-between; padding: 24px 40px 18px; }
  .band--cal .band__top { gap: 16px; justify-content: flex-start; }
  .band--cal .band__app { font-size: 28px; }
  .band--cal .band__sub { font-size: 14px; }
  .band--cal .band__row { margin-top: 0; gap: 20px; }

  .pc-grid {
    display: grid; grid-template-columns: minmax(0, 1fr) 440px; gap: 32px;
    padding: 28px 40px 40px; align-items: start; max-width: 1400px; margin: 0 auto;
  }
  .pc-left { display: flex; flex-direction: column; gap: 24px; min-width: 0; }
  .notice { margin: 0; padding: 16px 20px 4px; }
  .notice__title { font-size: 18px; }
  .notice__body.is-closed { max-height: 6.2em; }
  .notice__body.is-closed::after { height: 2.6em; }
  .notice__toggle { width: auto; border-top: none; margin-top: 0; padding: 0; }
  .cal-wrap { margin: 0; }
  .section-head { margin-bottom: 10px; }
  .section-head h2 { font-size: 22px; }
  .section-head p { font-size: 14px; }
  .cal-dow { font-size: 14px; }
  .cell { min-height: 100px; padding: 8px 10px 10px; gap: 5px; }
  .cell__date { flex-direction: row-reverse; align-items: baseline; gap: 4px; line-height: 1.1; }
  .cell__month { font-size: 12px; min-height: 0; }
  .cell__day { font-size: 21px; }
  .cell .good { top: 8px; right: 8px; width: 24px !important; height: 24px !important; }
  .cell .tag { font-size: 12px; padding: 3px 5px; }
  .cell .tag--canceled, .cell .tag--reserve { padding: 2px 5px; }
  .cell__count { font-size: 16px; }
  .cell__bar { height: 5px; border-radius: 3px; }
  .legend { gap: 8px 20px; font-size: 14px; }

  .day { background: var(--surface); border: 1px solid var(--rule); border-radius: 4px; padding: 24px; }
  .day__title { font-size: 28px; }
  .day-slots { margin-top: 22px; border-top: 1px solid var(--rule); }
  .day-slots .slots { height: 84px !important; }
  .people { padding-top: 16px; border-top: 1px solid var(--rule); }
  .toast { top: 84px; }
}

/* 360px 前後の狭い画面 */
@media (max-width: 374px) {
  .stepper__row { grid-template-columns: 56px 52px minmax(0, 1fr) 52px; gap: 6px; }
  .stepper__label { font-size: 14px; }
  .stepper__time { font-size: 24px; }
  .cell .good { top: 16px; }
}
