/* 来店予約。色は店舗販売のページ（seedstock.jp/user_data/store）に合わせた深緑。スマホを基準にする */
:root {
  --ink: #1f2d1f;
  --text: #3d4a3d;
  --muted: #6c7568;
  --accent: #3f6b3f;
  --accent-dark: #2a4a2a;
  --tint: #f5f8f5;
  --tint-border: #d6e2d6;
  --surface: #fff;
  --page: #fafbf9;
  --border: #e3e6e1;
  --danger: #a63a1e;
  --danger-tint: #fdf4ef;
  --radius: 10px;
  --font: "Hiragino Sans", "Hiragino Kaku Gothic ProN", "Yu Gothic", "Meiryo", sans-serif;
  --duration: 150ms;
}

* { box-sizing: border-box; }
body { margin: 0; background: var(--page); color: var(--text); font-family: var(--font); font-size: 16px; line-height: 1.7; }
a { color: var(--accent); }

.site-header { display: flex; align-items: baseline; gap: 12px; padding: 14px 16px; background: var(--accent-dark); color: #fff; }
.site-logo { color: #fff; font-weight: 800; letter-spacing: .08em; text-decoration: none; }
.site-sub { font-size: 13px; opacity: .8; }

.wrap { max-width: 720px; margin: 0 auto; padding: 20px 16px 64px; }
h1 { margin: 0 0 8px; font-size: 26px; color: var(--ink); letter-spacing: .04em; }
h2 { margin: 0 0 12px; font-size: 18px; color: var(--ink); display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.intro p { margin: 0 0 6px; }
.intro__meta { font-size: 13px; color: var(--muted); }

.step { margin-top: 24px; padding: 18px 16px; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); }
.step__no {
  display: inline-grid; place-items: center; width: 26px; height: 26px; border-radius: 50%;
  background: var(--accent); color: #fff; font-size: 14px; font-weight: 700;
}
.step__sub { font-size: 14px; font-weight: 400; color: var(--muted); }
.loading { color: var(--muted); margin: 0; }

/* 日付・時間の選択肢（ラジオボタンを大きなボタンに） */
/* 日付は日〜土の7列に固定する（列数が画面幅で変わると曜日がずれるため） */
.days { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 4px; }
@media (min-width: 640px) { .days { gap: 6px; } .days .choice { padding: 10px 0 8px; } .days .choice__main { font-size: 17px; } .days .choice__sub { font-size: 11px; } }
.days .loading { grid-column: 1 / -1; }
.cal-head { text-align: center; font-size: 12px; font-weight: 700; color: var(--muted); padding: 2px 0; }
.cal-head.is-sun { color: #b4483a; }
.cal-head.is-sat { color: #3a6ea5; }
.days .choice { padding: 8px 0 6px; border-radius: 6px; min-width: 0; }
.days .choice__main { font-size: 15px; white-space: nowrap; font-variant-numeric: tabular-nums; }
.days .choice__sub { font-size: 10px; line-height: 1.4; white-space: nowrap; }
.days .choice.has-month .choice__main { font-size: 12px; letter-spacing: -.02em; }
.slots { display: grid; grid-template-columns: repeat(auto-fill, minmax(130px, 1fr)); gap: 8px; }
.choice {
  position: relative; display: flex; flex-direction: column; align-items: center; gap: 0;
  padding: 10px 6px; border: 1px solid var(--tint-border); border-radius: 8px; background: var(--tint);
  cursor: pointer; text-align: center; transition: background var(--duration), border-color var(--duration), transform var(--duration);
}
.choice input { position: absolute; opacity: 0; inset: 0; cursor: pointer; }
.choice__main { font-weight: 700; color: var(--ink); font-size: 15px; }
.choice__sub { font-size: 12px; color: var(--accent); }
.choice:hover:not(.is-disabled) { border-color: var(--accent); }
.choice:active:not(.is-disabled) { transform: translateY(1px); }
.choice:has(input:checked) { background: var(--accent); border-color: var(--accent-dark); }
.choice:has(input:checked) .choice__main, .choice:has(input:checked) .choice__sub { color: #fff; }
.choice:has(input:focus-visible) { outline: 3px solid #b9d4b9; outline-offset: 2px; }
.choice.is-disabled { background: #f2f2f0; border-color: var(--border); cursor: not-allowed; }
.choice.is-disabled .choice__main, .choice.is-disabled .choice__sub { color: #a5aaa3; }
.choice.is-disabled input { cursor: not-allowed; }

/* 入力欄 */
.chosen { margin: 0 0 14px; padding: 8px 12px; background: var(--tint); border-left: 4px solid var(--accent); font-weight: 700; color: var(--ink); }
.field { display: flex; flex-direction: column; gap: 4px; margin-bottom: 14px; }
.field > span { font-size: 14px; font-weight: 700; color: var(--ink); }
.field small { font-weight: 400; color: var(--muted); margin-left: 6px; }
input[type="text"], input[type="email"], input[type="tel"], input[type="date"], input[type="number"], select, textarea {
  width: 100%; font: inherit; font-size: 16px; /* iOS で拡大されないよう16px */
  padding: 10px 12px; border: 1px solid #cfd5cd; border-radius: 8px; background: #fff; color: var(--ink);
}
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px #dbe9db; }
textarea { resize: vertical; }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

.errors { margin: 0 0 12px; padding: 10px 12px 10px 28px; background: var(--danger-tint); color: var(--danger); border-radius: 8px; font-size: 14px; }
.errors:empty { display: none; }
.fine { font-size: 12px; color: var(--muted); margin: 10px 0 0; }

.btn {
  display: inline-block; font: inherit; font-weight: 700; cursor: pointer; border-radius: 999px; text-decoration: none;
  padding: 12px 28px; border: 1px solid transparent; transition: background var(--duration), transform var(--duration);
}
.btn:active { transform: translateY(1px); }
.btn:focus-visible { outline: 3px solid #b9d4b9; outline-offset: 2px; }
.btn--primary { background: var(--accent); color: #fff; width: 100%; font-size: 17px; }
.btn--primary:hover { background: var(--accent-dark); }
.btn--primary:disabled { opacity: .6; cursor: wait; }
.btn--danger { background: #fff; color: var(--danger); border-color: var(--danger); }
.btn--danger:hover { background: var(--danger-tint); }
.btn--small { padding: 4px 12px; font-size: 13px; font-weight: 700; }
.btn--ghost { background: #fff; color: var(--accent); border-color: var(--tint-border); }
.btn--ghost:hover { background: var(--tint); }

.done, .manage { margin-top: 24px; padding: 22px 18px; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); }
.done h2 { color: var(--accent-dark); }
.done__when { font-size: 22px; font-weight: 800; color: var(--ink); margin: 0 0 8px; }
.manage__detail { display: grid; grid-template-columns: auto 1fr; gap: 6px 16px; margin: 16px 0 20px; }
.manage__detail dt { color: var(--muted); }
.manage__detail dd { margin: 0; font-weight: 700; color: var(--ink); }
.notice { padding: 10px 12px; background: var(--tint); border-left: 4px solid var(--accent); }

@media (min-width: 640px) {
  .wrap { padding-top: 32px; }
  .btn--primary { width: auto; }
}
@media (prefers-reduced-motion: reduce) {
  .choice, .btn { transition: none; }
}

/* ---- スタッフ画面（PC で使う前提） ---- */
.staff .wrap { max-width: 1100px; }
.staff-tools { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; margin: 12px 0 16px; }
.staff-tools input[type="date"] { width: auto; }
.staff-day { margin-bottom: 18px; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); overflow: hidden; }
.staff-day__head { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 10px 14px; background: var(--tint); border-bottom: 1px solid var(--tint-border); }
.staff-day__head h2 { margin: 0; font-size: 16px; }
.staff-day__closed { color: var(--danger); font-size: 13px; font-weight: 700; }
.staff-table { width: 100%; border-collapse: collapse; font-size: 14px; }
.staff-table th, .staff-table td { padding: 8px 12px; border-bottom: 1px solid var(--border); text-align: left; vertical-align: top; }
.staff-table th { font-size: 12px; color: var(--muted); font-weight: 700; white-space: nowrap; }
.staff-table tr.is-cancelled td { color: #9aa098; text-decoration: line-through; }
.staff-table tr.is-visited td:first-child { box-shadow: inset 4px 0 var(--accent); }
.staff-table tr.is-no_show td:first-child { box-shadow: inset 4px 0 var(--danger); }
.staff-table .actions { white-space: nowrap; text-align: right; }
.staff-table .actions .btn + .btn { margin-left: 4px; }
.slot-free { color: var(--muted); font-size: 13px; }
.badge { display: inline-block; padding: 0 8px; border-radius: 999px; font-size: 12px; font-weight: 700; background: var(--tint); color: var(--accent-dark); }
.badge--cancelled { background: #eee; color: #777; }
.badge--no_show { background: var(--danger-tint); color: var(--danger); }
.panel { margin-top: 24px; padding: 16px; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); }
.panel h2 { font-size: 16px; }
.form-row { display: flex; flex-wrap: wrap; gap: 10px; align-items: flex-end; }
.form-row .field { margin: 0; flex: 1 1 150px; }
.form-row .btn { flex: none; }
.toast { position: fixed; left: 50%; bottom: 24px; transform: translateX(-50%); background: var(--ink); color: #fff; padding: 10px 20px; border-radius: 999px; font-size: 14px; max-width: 90vw; }

/* スタッフ画面: 枠ごとの定員の増減と一括設定 */
.slot-row td { background: #fbfcfa; }
.slot-row .slot-label { font-weight: 700; color: var(--ink); white-space: nowrap; }
.slot-row.is-closed .slot-label { color: #9aa098; }
.cap { display: inline-flex; align-items: center; gap: 6px; white-space: nowrap; }
.cap__btn { width: 28px; height: 28px; padding: 0; border-radius: 50%; border: 1px solid var(--tint-border); background: #fff; color: var(--accent-dark); font: inherit; font-weight: 700; cursor: pointer; }
.cap__btn:hover:not(:disabled) { background: var(--tint); border-color: var(--accent); }
.cap__btn:disabled { opacity: .35; cursor: default; }
.cap__num { min-width: 1.5em; text-align: center; font-weight: 700; font-variant-numeric: tabular-nums; }
.changed { color: var(--danger); font-size: 12px; margin-left: 6px; }
.link-btn { background: none; border: 0; padding: 0; color: var(--accent); text-decoration: underline; cursor: pointer; font: inherit; font-size: 12px; }
.hours { border: 0; padding: 0; margin: 12px 0; display: flex; flex-wrap: wrap; gap: 6px; }
.hours legend { font-size: 14px; font-weight: 700; color: var(--ink); margin-bottom: 6px; padding: 0; }
.hours legend small { font-weight: 400; color: var(--muted); }
.hour-chip { position: relative; }
.hour-chip input { position: absolute; opacity: 0; inset: 0; cursor: pointer; }
.hour-chip span { display: inline-block; padding: 6px 12px; border: 1px solid var(--tint-border); border-radius: 999px; background: #fff; font-size: 13px; }
.hour-chip input:checked + span { background: var(--accent); border-color: var(--accent-dark); color: #fff; }
.hour-chip input:focus-visible + span { outline: 3px solid #b9d4b9; outline-offset: 2px; }
.sub-title { font-size: 14px; margin: 18px 0 6px; color: var(--ink); }
