/* 合宿申込・ライツID ページ共通（site/camp/**, site/id/）。トップの styles.css とは独立（色・書体だけ合わせる） */
:root {
  --ink: #0b0b0c; --ink-2: #1e1e21; --paper: #f3efe6; --bg: #fbf9f4; --surface: #fff;
  --red: #e1251b; --red-deep: #b3160e; --mute: #6d6a62; --line: rgba(11, 11, 12, .14);
  --ok: #1f7a3d; --warn: #9a6400; --navy: #13203a;
  --font-sans: "Zen Kaku Gothic New", "Hiragino Kaku Gothic ProN", "Hiragino Sans", "Yu Gothic", Meiryo, sans-serif;
  --font-en: "Anton", Impact, sans-serif;
  --r: 14px;
}
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--bg); color: var(--ink); font-family: var(--font-sans); line-height: 1.75; font-size: 16px; }
img { max-width: 100%; height: auto; display: block; }
a { color: var(--red-deep); }
h1, h2, h3 { line-height: 1.35; margin: 0 0 .5em; }
.wrap { width: min(1040px, 100% - 32px); margin-inline: auto; }
.narrow { width: min(720px, 100% - 32px); margin-inline: auto; }

/* ヘッダー */
.cbar { position: sticky; top: 0; z-index: 30; background: rgba(11, 11, 12, .94); color: #fff; backdrop-filter: blur(8px); }
.cbar .wrap { display: flex; align-items: center; gap: 12px; min-height: 60px; }
.cbar__home { color: #fff; text-decoration: none; font-family: var(--font-en); letter-spacing: .06em; font-size: 1.15rem; }
.cbar__home small { font-family: var(--font-sans); font-weight: 700; font-size: .72rem; letter-spacing: 0; opacity: .7; margin-left: 6px; }
.cbar__sp { flex: 1; }
.cbar__user { font-size: .85rem; display: flex; align-items: center; gap: 10px; min-width: 0; }
.cbar__user span, .cbar__user > a:not(.cbtn) { color: inherit; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 34vw; opacity: .85; }
.cbar a.cbtn, .cbar button.cbtn { color: #fff; border-color: rgba(255, 255, 255, .5); }

/* ボタン */
.cbtn { display: inline-flex; align-items: center; justify-content: center; gap: .4em; min-height: 46px; padding: .55em 1.4em; border-radius: 999px; border: 2px solid var(--ink); background: transparent; color: var(--ink); font: 700 .98rem/1.3 var(--font-sans); text-decoration: none; cursor: pointer; }
.cbtn--sm { min-height: 36px; padding: .3em 1em; font-size: .85rem; }
.cbtn--red { background: var(--red); border-color: var(--red); color: #fff; }
.cbtn--red:hover { background: var(--red-deep); border-color: var(--red-deep); }
.cbtn--ink { background: var(--ink); color: #fff; }
.cbtn--block { width: 100%; }
.cbtn[disabled] { opacity: .5; cursor: not-allowed; }
.cbtn:focus-visible, input:focus-visible, select:focus-visible, textarea:focus-visible { outline: 3px solid rgba(225, 37, 27, .45); outline-offset: 2px; }

/* セクション */
.sec { padding: clamp(36px, 6vw, 72px) 0; }
.sec--paper { background: var(--paper); }
.kicker { font-family: var(--font-en); letter-spacing: .14em; color: var(--red); font-size: .9rem; }
.lead { color: var(--mute); }
.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); padding: clamp(18px, 3.5vw, 32px); }
.toast { position: fixed; left: 50%; bottom: 20px; z-index: 1000; width: min(560px, calc(100% - 32px)); transform: translate(-50%, 20px); opacity: 0; pointer-events: none;
  background: #b3160e; color: #fff; border-radius: 12px; padding: 14px 18px; box-shadow: 0 10px 30px rgba(0,0,0,.25); transition: opacity .2s, transform .2s; cursor: pointer; font-size: .92rem; }
.toast.is-on { opacity: 1; transform: translate(-50%, 0); pointer-events: auto; }
.toast ul { margin: 6px 0 0; padding-left: 1.2em; }
.toast li { margin: 2px 0; }
.notice { border-radius: 12px; padding: 14px 18px; font-size: .95rem; background: #fff4e5; border: 1px solid #f0c98a; }
.notice--info { background: #eef3fb; border-color: #c4d4ee; }
.notice--ok { background: #eaf6ee; border-color: #a9d8b8; }
.notice--err { background: #fdecea; border-color: #f2b5ae; color: #8a1a12; }
.hidden { display: none !important; }

/* フォーム */
.form { display: grid; gap: 18px; }
.fset { border: 0; padding: 0; margin: 0; display: grid; gap: 14px; }
.fset > legend { font-weight: 900; font-size: 1.1rem; padding: 0 0 6px; border-bottom: 2px solid var(--ink); width: 100%; margin-bottom: 6px; }
.row { display: grid; gap: 12px; grid-template-columns: 1fr 1fr; }
.row--3 { grid-template-columns: 1fr 1fr 1fr; }
.field { display: grid; gap: 4px; min-width: 0; }
.field > label, .field > .lbl { font-weight: 700; font-size: .92rem; }
.req { display: inline-block; background: var(--red); color: #fff; font-size: .68rem; padding: 1px 6px; border-radius: 4px; margin-left: 6px; vertical-align: 2px; }
.opt { display: inline-block; background: #ddd8cc; color: var(--ink); font-size: .68rem; padding: 1px 6px; border-radius: 4px; margin-left: 6px; vertical-align: 2px; }
input[type=text], input[type=email], input[type=tel], input[type=password], input[type=date], select, textarea {
  width: 100%; min-height: 48px; padding: 10px 12px; border: 1.5px solid #c9c3b5; border-radius: 10px; background: #fff; font: inherit; color: inherit;
}
textarea { min-height: 96px; resize: vertical; }
.hint { font-size: .8rem; color: var(--mute); }
.err { font-size: .82rem; color: #b3160e; font-weight: 700; }
.field.is-err input, .field.is-err select, .field.is-err textarea { border-color: #d0453b; background: #fff8f7; }
.choices { display: flex; flex-wrap: wrap; gap: 10px; }
.choice { position: relative; flex: 1 1 200px; }
.choices--inline .choice { flex: 1 1 90px; }
/* 性別などの横並び選択肢は、隣の入力欄と同じ高さ・枠にそろえる */
.choices--inline .choice span { display: flex; align-items: center; min-height: 48px; padding: 10px 12px; border-width: 1.5px; border-radius: 10px; }
.profile { display: grid; gap: 12px; }
.profile__head { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; justify-content: space-between; }
.profile__head h2, .mp-head h2 { margin: 0; font-size: 1.2rem; }
.profile__list { display: grid; grid-template-columns: 7em 1fr; gap: 6px 14px; margin: 0; font-size: .95rem; }
.profile__list dt { color: var(--mute); font-weight: 700; }
.profile__list dd { margin: 0; overflow-wrap: anywhere; }
@media (max-width: 520px) { .profile__list { grid-template-columns: 1fr; gap: 0; } .profile__list dd { margin-bottom: 8px; } }
.mp-head { display: grid; gap: 4px; margin-top: 6px; }
.bank { border: 1.5px solid #c9c3b5; border-radius: 12px; padding: 14px 16px; background: #fbfaf6; display: grid; gap: 8px; }
.bank__lead { margin: 0; font-weight: 700; }
.bank__acct { font-size: 1.02rem; line-height: 1.7; padding: 10px 12px; background: #fff; border-radius: 8px; border: 1px dashed #c9c3b5; user-select: all; }
.choice input { position: absolute; opacity: 0; inset: 0; }
.choice span { display: block; border: 2px solid #c9c3b5; border-radius: 12px; padding: 12px 14px; background: #fff; cursor: pointer; height: 100%; }
.choice span b { display: block; }
.choice span small { color: var(--mute); }
.choice input:checked + span { border-color: var(--red); background: #fff5f4; box-shadow: 0 0 0 2px rgba(225, 37, 27, .15); }
.choice input:focus-visible + span { outline: 3px solid rgba(225, 37, 27, .45); }
/* 参加区分（自動判定の表示。押せない） */
.choice--auto span { cursor: default; }
.choice--auto:not([aria-current]) { display: none; }
.choice--auto[aria-current] span { opacity: 1; border-color: var(--red); background: #fff5f4; box-shadow: 0 0 0 2px rgba(225, 37, 27, .15); }
.choice--auto[aria-current] span b::after { content: '  ✓ 適用'; color: var(--red); font-size: .85em; }
.check { display: flex; gap: 10px; align-items: flex-start; font-weight: 700; }
.check input { width: 22px; height: 22px; margin-top: 3px; flex-shrink: 0; accent-color: var(--red); }

/* 写真 */
.photo { display: grid; gap: 10px; }
.photo__drop { border: 2px dashed #c9c3b5; border-radius: 12px; padding: 18px; text-align: center; background: #fff; cursor: pointer; }
.photo__drop:hover { border-color: var(--red); }
.photo__preview { max-height: 320px; width: auto; margin: 0 auto; border-radius: 8px; border: 1px solid var(--line); }

/* 同意書 */
.consent { max-height: 340px; overflow: auto; border: 1px solid var(--line); border-radius: 10px; padding: 14px 18px; background: #fff; font-size: .9rem; }
.consent h3 { font-size: 1rem; margin-top: .4em; }
.consent ol { padding-left: 1.3em; margin: 0; }
.consent li { margin-bottom: .5em; }

/* 合宿ページ */
.camp-hero { background: var(--ink); color: #fff; padding: clamp(28px, 5vw, 56px) 0; }
.camp-hero h1 { font-size: clamp(1.7rem, 5vw, 2.8rem); margin: .2em 0 .3em; }
.camp-hero p { color: #d8d4ca; }
.camp-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: clamp(18px, 3vw, 32px); }
.camp-grid--one { grid-template-columns: minmax(0, 560px); justify-content: center; }
.poster { margin: 0; background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); overflow: hidden; }
.poster__tag { display: flex; justify-content: space-between; align-items: center; gap: 8px; padding: 12px 16px; font-weight: 900; }
.poster__tag em { font-style: normal; font-size: .78rem; color: #fff; background: var(--ink); border-radius: 999px; padding: 2px 10px; }
.poster__tag em.is-red { background: var(--red); }
.poster__img { position: relative; }
.poster__lock { position: absolute; left: 4%; right: 40%; top: 61.5%; height: 22%; display: grid; place-items: center; text-align: center; padding: 8px; }
.poster__lock a { background: rgba(11, 11, 12, .86); color: #fff; text-decoration: none; border-radius: 12px; padding: 10px 14px; font-weight: 700; font-size: clamp(.72rem, 1.6vw, .92rem); line-height: 1.5; }
.poster__lock a b { display: block; font-size: 1.1em; }
.facts { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; margin: 0; }
.facts div { background: var(--surface); border: 1px solid var(--line); border-radius: 12px; padding: 12px 14px; }
.facts dt { font-size: .76rem; color: var(--mute); font-weight: 700; }
.facts dd { margin: 0; font-weight: 900; }
.price-table { width: 100%; border-collapse: collapse; font-size: .95rem; }
.price-table th, .price-table td { border-bottom: 1px solid var(--line); padding: 8px 6px; text-align: left; }
.price-table td:last-child { text-align: right; }
.price-total { font-size: 1.4rem; font-weight: 900; color: var(--red); }
.steps { counter-reset: s; list-style: none; padding: 0; margin: 0; display: grid; gap: 10px; }
.steps li { counter-increment: s; background: var(--surface); border: 1px solid var(--line); border-radius: 12px; padding: 12px 14px 12px 52px; position: relative; }
.steps li::before { content: counter(s); position: absolute; left: 14px; top: 12px; width: 26px; height: 26px; border-radius: 50%; background: var(--red); color: #fff; font-weight: 900; display: grid; place-items: center; font-size: .85rem; }

/* ライツID の説明 */
.idbox { background: var(--navy); color: #e6e9f0; border-radius: var(--r); padding: 18px 20px; }
.idbox h2 { color: #fff; font-size: 1.1rem; }
.idbox ul { margin: .4em 0 0; padding-left: 1.2em; }
.idsites { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 8px; }
.idsites span { background: rgba(255, 255, 255, .12); border-radius: 999px; padding: 2px 10px; font-size: .8rem; }
.tabs { display: flex; gap: 6px; margin-bottom: 14px; }
.tabs button { flex: 1; min-height: 46px; border: 2px solid var(--ink); background: #fff; border-radius: 10px; font: 700 .95rem var(--font-sans); cursor: pointer; }
.tabs button[aria-selected=true] { background: var(--ink); color: #fff; }

/* マイページ・管理 */
.app { display: grid; gap: 8px; }
.badge { display: inline-block; border-radius: 999px; padding: 1px 10px; font-size: .78rem; font-weight: 700; background: #ddd8cc; }
.badge--ok { background: #d5efdd; color: var(--ok); }
.badge--warn { background: #fdf0d5; color: var(--warn); }
.badge--red { background: #fde1de; color: #9b1c13; }
.tbl-wrap { overflow-x: auto; }
.tbl { border-collapse: collapse; width: 100%; font-size: .85rem; background: #fff; }
.tbl th, .tbl td { border: 1px solid var(--line); padding: 6px 8px; vertical-align: top; text-align: left; }
.tbl th { background: var(--paper); white-space: nowrap; }

.cfoot { background: var(--ink); color: #a9a59c; font-size: .82rem; padding: 28px 0; margin-top: 40px; }
.cfoot a { color: #fff; }

@media (max-width: 760px) {
  .camp-grid, .row, .row--3 { grid-template-columns: 1fr; }
  .facts { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 420px) { .cbar__user > a:not(.cbtn) { max-width: 40vw; } .cbar__home small { display: none; } .cbar__user .cbtn { white-space: nowrap; } }

/* 申込フォーム: 会員情報から入力済みの欄（連絡先・住所・緊急連絡先）を折りたたむ */
.prefill { border: 1px solid #e3dfd5; border-radius: 12px; padding: 12px 16px; background: #fcfbf8; }
.prefill > summary { cursor: pointer; font-weight: 700; padding: 4px 0; }
.prefill > summary span { font-weight: 400; color: var(--mute); font-size: .9em; }
.prefill[open] > summary { margin-bottom: 12px; }
.prefill .fset + .fset { margin-top: 18px; }
