/* 予約受付の自動化（体験版）。色は common/base.css のトークンだけを使う */
/* ───────── 左右に分かれる画面（左：お客さん側／右：お店側）。900px 未満は切り替え ───────── */
.dual { display: grid; grid-template-columns: 384px minmax(0, 1fr); grid-template-rows: minmax(0, 1fr); background: var(--paper); }
.mswitch { display: none; }
.left-col { display: flex; flex-direction: column; min-height: 0; min-width: 0; border-right: 1px solid var(--line-2); background: var(--surface); }
.left-ctrl { padding: 12px 16px 12px; border-bottom: 1px solid var(--line); background: var(--surface); flex: none; }
.ctrl-cap { font-size: 12.5px; color: var(--ink-3); line-height: 1.6; }
.ctrl-row { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-top: 8px; }
.ctrl-row .lbl { font-size: 12.5px; font-weight: 700; color: var(--ink-2); }
.ctrl-link { margin-left: auto; font-size: 12.5px; font-weight: 600; color: var(--brand-2); min-height: 28px; text-decoration: underline; text-underline-offset: 3px; }
.seg { display: inline-flex; padding: 2px; border: 1.5px solid var(--line-2); border-radius: 999px; background: var(--paper); }
.seg button { min-height: 30px; padding: 0 12px; border-radius: 999px; font-size: 13px; font-weight: 600; color: var(--ink-2); white-space: nowrap; }
.seg button[aria-pressed="true"] { background: var(--brand); color: #fff; }
.right-col { display: flex; flex-direction: column; min-height: 0; min-width: 0; }
.work-head { display: flex; align-items: center; gap: 16px; padding: 0 16px 0 20px; background: var(--brand); color: var(--on-brand); min-height: 52px; flex: none; }
.work-brand { display: flex; align-items: center; gap: 8px; white-space: nowrap; }
.work-brand b { color: #fff; font-size: 15px; }
.work-brand span { font-size: 12px; color: var(--on-brand-2); }
.work-tabs { display: flex; gap: 4px; margin-left: auto; align-self: stretch; }
.work-tabs button { position: relative; display: flex; align-items: center; gap: 7px; padding: 0 14px; color: var(--on-brand); font-weight: 600; font-size: 14px; border-bottom: 3px solid transparent; white-space: nowrap; }
.work-tabs button:hover { background: rgba(255, 255, 255, .06); }
.work-tabs button[aria-current="page"] { color: #fff; border-bottom-color: var(--accent); background: rgba(255, 255, 255, .08); }
.work-tabs .dot { width: 8px; height: 8px; border-radius: 50%; background: var(--accent); }
.work-body { flex: 1; min-height: 0; overflow: auto; padding: 16px 20px 32px; -webkit-overflow-scrolling: touch; }
@media (max-width: 1179px) { .dual { grid-template-columns: 344px minmax(0, 1fr); } .work-brand span { display: none; } }
@media (max-width: 899px) {
  .dual { grid-template-columns: minmax(0, 1fr); grid-template-rows: auto minmax(0, 1fr); }
  .mswitch { display: grid; grid-template-columns: 1fr 1fr; gap: 4px; padding: 6px 10px; background: var(--surface); border-bottom: 1px solid var(--line); }
  .mswitch button { height: 38px; border-radius: 8px; font-size: 14px; font-weight: 700; color: var(--ink-3); display: flex; align-items: center; justify-content: center; gap: 6px; }
  .mswitch button[aria-selected="true"] { background: var(--brand); color: #fff; }
  .mswitch .mdot { width: 8px; height: 8px; border-radius: 50%; background: var(--accent); }
  .dual[data-view="left"] .right-col, .dual[data-view="right"] .left-col { display: none; }
  .left-col { border-right: 0; }
  .work-head { padding: 0 6px 0 14px; min-height: 46px; }
  .work-brand { display: none; }
  .work-tabs { margin-left: 0; flex: 1; gap: 0; overflow-x: auto; }
  .work-tabs button { flex: 1; justify-content: center; padding: 0 9px; font-size: 13px; }
}
@media (max-width: 640px) {
  .left-ctrl { padding: 8px 12px; }
  .ctrl-cap { display: none; }
  .ctrl-row { margin-top: 0; }
  .work-body { padding: 14px 14px 28px; }
}
/* ───────── 右：シート ───────── */
.sheet-cap { font-size: 13px; color: var(--ink-3); margin-bottom: 10px; }
.sheet-empty { padding: 28px 16px; text-align: center; color: var(--ink-3); background: var(--surface); border: 1px dashed var(--line-2); border-radius: var(--r-m); }
.sheet-wrap { overflow-x: auto; background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-m); box-shadow: var(--shadow-s); }
.sheet { width: 100%; border-collapse: collapse; font-size: 13.5px; min-width: 560px; }
.sheet th { position: sticky; top: 0; text-align: left; padding: 9px 12px; background: var(--brand-soft); color: var(--brand); font-size: 12.5px; font-weight: 700; white-space: nowrap; border-bottom: 1px solid var(--line-2); }
.sheet td { padding: 9px 12px; border-bottom: 1px solid var(--line); vertical-align: top; }
.sheet tr:last-child td { border-bottom: 0; }
.sheet tr.own td { background: var(--accent-soft); }
.sheet .nw { white-space: nowrap; }
.sheet .cell-text { min-width: 200px; white-space: pre-line; overflow-wrap: anywhere; }
.sheet .cell-act { margin-top: 6px; }
.muted { color: var(--ink-3); }

/* スマホでは、表をカードの並びにする（横にはみ出させない） */
@media (max-width: 640px) {
  .sheet-wrap { overflow: visible; background: none; border: 0; box-shadow: none; }
  .sheet { display: block; min-width: 0; }
  .sheet thead { display: none; }
  .sheet tbody { display: grid; gap: 10px; }
  .sheet tr { display: grid; gap: 4px; padding: 10px 12px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-m); box-shadow: var(--shadow-s); }
  .sheet td { display: grid; grid-template-columns: 64px minmax(0, 1fr); gap: 8px; padding: 0; border: 0; align-items: start; }
  .sheet td::before { content: attr(data-label); color: var(--ink-3); font-size: 12px; font-weight: 700; line-height: 1.9; }
  .sheet tr.own, .sheet tr.own td { background: var(--accent-soft); }
  .sheet td.nw { white-space: normal; }
  .sheet .cell-act { margin-top: 0; }
  .sheet .cell-act .btn { width: 100%; }
  .sheet td .chip, .sheet td .cell-act { justify-self: start; }
  .sheet td .cell-act { width: 100%; }
}

/* ───────── 左：申込みフォーム ───────── */
.clock-row { margin-top: 0; }
.clock-row b { font-size: 14.5px; }
.fm-scroll { flex: 1; min-height: 0; overflow-y: auto; padding: 14px 14px 24px; background: var(--sunken); display: grid; gap: 12px; align-content: start; -webkit-overflow-scrolling: touch; }
.fm { background: var(--surface); border: 1px solid var(--line); border-top: 6px solid var(--brand-2); border-radius: var(--r-m); padding: 16px 16px 14px; display: grid; gap: 16px; box-shadow: var(--shadow-s); }
.fm-head b { display: block; font-size: 19px; font-weight: 800; }
.fm-head span { display: block; font-size: 13px; color: var(--ink-3); margin-top: 1px; }
.fm-head p { margin-top: 8px; font-size: 13.5px; color: var(--ink-2); line-height: 1.7; }
.fm-q { border: 0; padding: 0; margin: 0; min-width: 0; display: grid; gap: 8px; }
.fm-q legend, .fm-q label { font-size: 14px; font-weight: 700; padding: 0; }
.fm-q input[type="text"], .fm-q input[type="email"] { width: 100%; height: 44px; padding: 0 12px; border: 1.5px solid var(--line-2); border-radius: var(--r-s); background: var(--paper); font-size: 16px; }
.fm-q input:focus { border-color: var(--brand-2); background: #fff; outline: none; }
#slotList { display: grid; gap: 8px; }
.slot-opt { display: flex; align-items: center; gap: 10px; width: 100%; padding: 10px 12px; border: 1.5px solid var(--line-2); border-radius: var(--r-m); background: var(--surface); text-align: left; min-height: 56px; }
.slot-opt:hover { background: var(--paper); }
.slot-opt[aria-checked="true"] { border-color: var(--brand-2); background: var(--brand-soft); }
.so-sel { display: block; margin-top: 2px; font-size: 12px; font-weight: 800; color: var(--brand-2); }
.slot-opt[aria-checked="true"] { box-shadow: 0 0 0 2px var(--brand-2); }
.radio { width: 18px; height: 18px; flex: none; border-radius: 50%; border: 2px solid var(--line-2); background: #fff; }
.slot-opt[aria-checked="true"] .radio { border-color: var(--brand-2); box-shadow: inset 0 0 0 3.5px #fff; background: var(--brand-2); }
.so-main { flex: 1; min-width: 0; display: grid; font-size: 14px; line-height: 1.45; }
.so-main b { font-weight: 700; font-size: 13.5px; }
.fm-help { font-size: 12.5px; color: var(--ink-3); white-space: pre-line; line-height: 1.7; }
.fm-empty { padding: 14px; text-align: center; color: var(--ink-3); background: var(--paper); border-radius: var(--r-m); font-size: 13.5px; }
.fm .seg button { min-width: 56px; }
.fm-foot { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.fm-foot .btn { min-width: 120px; }
.fm-foot .ctrl-link { margin-left: 0; }
.fm-try { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-m); padding: 14px 16px; box-shadow: var(--shadow-s); }
.fm-try h2 { font-size: 14px; font-weight: 800; }
.try-btns { display: grid; gap: 8px; margin-top: 10px; }
.try-btns .btn { white-space: normal; text-align: center; line-height: 1.4; padding: 8px 14px; }
.fm-result { background: var(--surface); border: 1px solid var(--line); border-left: 4px solid var(--accent); border-radius: var(--r-m); padding: 12px 16px; box-shadow: var(--shadow-s); font-size: 14px; }
.fm-result h2 { font-size: 12.5px; color: var(--ink-3); font-weight: 700; margin-bottom: 4px; }
.res-why { margin-top: 4px; color: var(--ink-2); font-size: 13px; }
.res-mail { margin-top: 6px; font-size: 13px; color: var(--brand-2); font-weight: 600; }
.res-note { margin-top: 4px; font-size: 12px; color: var(--ink-3); }

/* ───────── 右：運営の画面 ───────── */
.slot-cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 12px; }
.slot-card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-m); padding: 14px 16px; box-shadow: var(--shadow-s); }
.slot-card header { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.slot-card header b { font-size: 13.5px; }
.slot-card h3 { margin-top: 6px; font-size: 16px; font-weight: 800; }
.meter { display: flex; gap: 4px; margin-top: 12px; }
.meter i { flex: 1; height: 12px; border-radius: 3px; background: var(--sunken); border: 1px solid var(--line); }
.meter i.on { background: var(--brand-2); border-color: var(--brand-2); }
.sc-stat { margin-top: 8px; font-size: 13.5px; font-weight: 600; }
.sc-dl { font-size: 12.5px; color: var(--ink-3); }
.mail-list { display: grid; gap: 10px; }
.mail { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-m); box-shadow: var(--shadow-s); }
.mail summary { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 2px 10px; align-items: center; padding: 11px 14px; cursor: pointer; list-style: none; }
.mail summary::-webkit-details-marker { display: none; }
.mail summary b { font-size: 14px; font-weight: 700; overflow-wrap: anywhere; }
.mail summary small { grid-column: 2; color: var(--ink-3); font-size: 12px; }
.mail pre { margin: 0; padding: 4px 16px 14px; font: inherit; font-size: 13.5px; line-height: 1.75; white-space: pre-wrap; overflow-wrap: anywhere; color: var(--ink-2); border-top: 1px dashed var(--line); padding-top: 12px; }
@media (max-width: 640px) {
  .fm-scroll { padding: 10px 12px 22px; }
  .fm-head b { font-size: 18px; }
}

.slot-opt.is-off { opacity: .6; background: var(--paper); cursor: not-allowed; }
.slot-opt.is-off:hover { background: var(--paper); }
.slot-opt.is-off .so-main b, .slot-opt.is-off .so-main span { color: var(--ink-3); }
.btn.is-wait { color: var(--ink-3); border-style: dashed; }
.try-note { margin-top: 8px; font-size: 12.5px; color: var(--ink-3); line-height: 1.7; }
