/* 教室の掲載依頼フォーム（form.html だけ）— 青 #2563A6・飾り線なし（2026-10-16 決定） */
.fm-page {
  --fm-main: #2563A6;
  --fm-hover: #1D4F85;
  --fm-tint: #E7F0FA;
  --fm-done: #8DB3DE;
  --fm-ink: #1f2430;
  --fm-sub: #4b5563;
  --fm-line: #b7bfcc;
  --fm-bg: #F6F7F9;
  max-width: 720px;
  margin: 0 auto;
  padding: 32px 20px 44px;
  color: var(--fm-ink);
  line-height: 1.7;
  font-size: 16px;
}
.fm-page [hidden] { display: none !important; }
.fm-h1 { font-size: 28px; color: var(--fm-main); margin: 0 0 8px; }
.fm-h2 { font-size: 22px; margin: 4px 0 14px; color: var(--fm-main); }
#fm-step-2 .fm-h2 { margin-top: 30px; }
.fm-lead { margin: 0 0 20px; color: var(--fm-sub); }
.fm-notice { background: #FFF4E5; border-radius: 12px; padding: 12px 16px; margin: 0 0 20px; font-size: 16px; }

/* 進み具合（B） */
.fm-prog { margin: 0 0 26px; }
.fm-pn { margin: 0 0 10px; font-size: 18px; color: var(--fm-sub); }
.fm-pn b { font-size: 24px; color: var(--fm-main); }
.fm-prog ol { list-style: none; display: grid; grid-template-columns: repeat(5, 1fr); gap: 6px; margin: 0; padding: 0; }
.fm-prog li { border-top: 8px solid #d5dae3; border-radius: 4px; padding-top: 6px; font-size: 15px; color: #6b7280; }
.fm-prog li.done { border-color: var(--fm-done); color: var(--fm-sub); }
.fm-prog li.now { border-color: var(--fm-main); color: var(--fm-main); font-weight: 700; }

/* 探す（B） */
.fm-search { background: #fff; border-radius: 16px; padding: 22px 24px 24px; }
.fm-rescount { margin: 26px 0 10px; font-size: 17px; color: var(--fm-sub); }
.fm-rescount b { font-size: 22px; color: var(--fm-main); margin-right: 6px; }
.fm-cands { display: flex; flex-direction: column; gap: 10px; }
.fm-cand { display: flex; align-items: center; justify-content: space-between; gap: 14px; background: #fff; border: 2px solid #d9dee7; border-radius: 16px; padding: 14px 16px; }
.fm-cand .cn { font-size: 18px; font-weight: 700; }
.fm-cand .cm { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 10px; margin-top: 4px; }
.fm-cand .ca { font-size: 16px; color: var(--fm-sub); }
.fm-type { background: var(--fm-tint); color: var(--fm-main); font-size: 14px; padding: 3px 12px; border-radius: 20px; font-weight: 700; }
.fm-notfound { margin-top: 20px; padding: 16px 4px; display: flex; flex-direction: column; gap: 4px; font-size: 16px; color: var(--fm-sub); align-items: flex-start; }
.fm-notfound strong { color: var(--fm-ink); font-size: 17px; }

/* カード（C）: サイトの検索カードからピンクの帯・線を外す */
.fm-stk-label { font-size: 16px; font-weight: 700; color: var(--fm-main); margin: 0 0 8px; }
.fm-page .card { width: auto; margin: 0; background: #fff; border: 1px solid #d9dee7; border-radius: 16px; box-shadow: none; animation: none; }
.fm-page .card::before { display: none; }
.fm-page .card:hover { transform: none; box-shadow: none; }
.fm-page .school-name { border-left: 0; border-bottom: 0; font-size: 19px; color: var(--fm-ink); padding: 16px 20px 4px; }
.fm-page .card-content { background: none; }
.fm-page .type-box { background: var(--fm-tint); color: var(--fm-main); font-size: 14px; padding: 3px 12px; }
.fm-page .address, .fm-page .description { font-size: 16px; color: var(--fm-sub); }
.fm-page .tel-link, .fm-page .homepage-button { font-size: 16px; color: var(--fm-main); background: #fff; border: 2px solid var(--fm-main); min-height: 44px; box-sizing: border-box; box-shadow: none; transform: none; display: inline-flex; align-items: center; padding: 0 16px; border-radius: 12px; text-decoration: none; font-weight: 700; }
.fm-chg { margin: 10px 0 0; }

/* 用件チップ・関係の選択 */
.fm-chips { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; }
.fm-chips.three { grid-template-columns: repeat(3, 1fr); }
.fm-chips.two { grid-template-columns: repeat(2, 1fr); }
.fm-chip { position: relative; display: block; text-align: left; padding: 14px 16px; border: 2px solid #c3cad6; border-radius: 12px; background: #fff; color: var(--fm-ink); cursor: pointer; box-sizing: border-box; }
.fm-chip b { display: block; font-size: 17px; font-weight: 700; line-height: 1.45; }
.fm-chip small { display: block; margin-top: 4px; font-size: 13px; line-height: 1.5; color: #6b7280; }
.fm-chip input { position: absolute; opacity: 0; inset: 0; margin: 0; cursor: pointer; }
.fm-chip:has(input:checked) { background: var(--fm-tint); border-color: var(--fm-main); box-shadow: inset 0 0 0 1px var(--fm-main); }
.fm-chip:has(input:checked) b { color: var(--fm-hover); }
.fm-chip:has(input:checked) b::before { content: "✓ "; }
.fm-chip:has(input:focus-visible) { outline: 3px solid var(--fm-done); outline-offset: 2px; }
.fm-chip:has(input:disabled) { opacity: .45; cursor: not-allowed; }

/* セクション: 枠線や上線なし、余白と文字の強弱で区切る */
.fm-sec { background: #fff; border-radius: 16px; padding: 26px 24px 28px; margin: 28px 0 0; }
.fm-sec h2 { font-size: 22px; margin: 0 0 18px; color: var(--fm-main); }
.fm-field { margin: 0 0 22px; }
.fm-label { display: block; font-weight: 700; font-size: 18px; margin: 0 0 8px; }
.fm-label .opt, .fm-label .req { font-size: 14px; font-weight: 700; margin-left: 8px; padding: 2px 8px; border-radius: 6px; }
.fm-label .opt { background: #eceef2; color: var(--fm-sub); }
.fm-label .req { background: var(--fm-tint); color: var(--fm-main); }
#fm-content-remove h2 .req { font-size: 14px; font-weight: 700; margin-left: 8px; padding: 2px 8px; border-radius: 6px; background: var(--fm-tint); color: var(--fm-main); vertical-align: middle; }
.fm-in, .fm-ta { width: 100%; box-sizing: border-box; font: inherit; font-size: 18px; border: 2px solid var(--fm-line); border-radius: 12px; padding: 12px 14px; background: #fff; min-height: 56px; color: var(--fm-ink); }
.fm-in:focus, .fm-ta:focus { outline: none; border-color: var(--fm-main); box-shadow: 0 0 0 3px var(--fm-tint); }
.fm-in[aria-invalid="true"], .fm-ta[aria-invalid="true"] { border-color: #b42318; }
.fm-ta { line-height: 1.7; min-height: 9em; resize: vertical; }
.fm-ta.short { min-height: 5em; }
.fm-count { display: flex; justify-content: space-between; font-size: 16px; color: var(--fm-sub); margin-top: 6px; }
.fm-count b { color: var(--fm-main); font-size: 19px; }
.fm-meter { position: relative; height: 10px; border-radius: 5px; background: #e3e7ee; margin-top: 4px; }
.fm-meter i { position: absolute; left: 0; top: 0; bottom: 0; width: 0; background: var(--fm-main); border-radius: 5px; }
.fm-meter u { position: absolute; left: 50%; top: -3px; bottom: -3px; border-left: 2px dashed #7b8494; }
.fm-grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.fm-drop { display: flex; gap: 16px; align-items: center; border: 2px dashed var(--fm-line); border-radius: 14px; padding: 14px; background: var(--fm-bg); }
.fm-thumb { flex: 0 0 96px; }
.fm-thumb img { width: 96px; height: 96px; object-fit: cover; border-radius: 12px; display: block; }
.fm-drop .txt { position: relative; display: flex; flex-direction: column; gap: 6px; align-items: flex-start; font-size: 16px; }
.fm-drop .txt span { color: var(--fm-sub); font-size: 15px; }
.fm-file { position: absolute; width: 1px; height: 1px; opacity: 0; }
.fm-drop:has(.fm-file:focus-visible) .fm-btn.sub { outline: 3px solid var(--fm-done); outline-offset: 2px; }
.fm-help { font-size: 15px; color: var(--fm-sub); margin: 8px 0 0; }
.fm-check { position: relative; display: flex; gap: 14px; align-items: flex-start; padding: 12px 4px; font-size: 17px; cursor: pointer; }
.fm-check input { position: absolute; opacity: 0; width: 28px; height: 28px; margin: 0; }
.fm-check .bx { flex: 0 0 28px; height: 28px; border: 2px solid var(--fm-main); border-radius: 6px; background: #fff; margin-top: 1px; position: relative; box-sizing: border-box; }
.fm-check .bx { pointer-events: none; } /* 透明の input の上に重なっても押せるように（Playwright の check もこれで通る） */
.fm-check .bx.round { border-radius: 50%; }
.fm-check input:checked + .bx { background: var(--fm-main); }
.fm-check input:checked + .bx::after { content: ""; position: absolute; left: 8px; top: 2px; width: 7px; height: 14px; border: solid #fff; border-width: 0 3px 3px 0; transform: rotate(45deg); }
.fm-check input:focus-visible + .bx { outline: 3px solid var(--fm-done); outline-offset: 2px; }
.fm-check small { display: block; color: var(--fm-sub); font-size: 15px; }
.fm-warn { margin-top: 12px; background: #FFF4E5; border-radius: 12px; padding: 12px 16px; font-size: 16px; }
.fm-err { color: #b42318; font-size: 15px; font-weight: 700; margin: 6px 0 0; }

/* 確認 */
.fm-sum { width: 100%; border-collapse: collapse; font-size: 16px; margin: 0 0 18px; background: var(--fm-bg); border-radius: 12px; overflow: hidden; }
.fm-sum th, .fm-sum td { text-align: left; padding: 10px 14px; border-bottom: 1px solid #e3e7ee; vertical-align: top; overflow-wrap: anywhere; white-space: pre-wrap; }
.fm-sum th { width: 6.5em; color: var(--fm-sub); white-space: nowrap; }
.fm-consents { background: var(--fm-bg); border-radius: 14px; padding: 6px 14px; }
.fm-caution { font-size: 16px; color: var(--fm-sub); margin: 14px 0; }
.fm-turn { min-height: 65px; margin: 0 0 16px; }

/* ボタン */
.fm-btn { display: inline-flex; align-items: center; justify-content: center; min-height: 56px; padding: 0 24px; border-radius: 14px; font: inherit; font-size: 18px; font-weight: 700; text-decoration: none; box-sizing: border-box; cursor: pointer; white-space: nowrap; border: 0; }
.fm-btn.main { background: var(--fm-main); color: #fff; }
.fm-btn.main:hover { background: var(--fm-hover); }
.fm-btn.sub { background: #fff; color: var(--fm-main); border: 2px solid var(--fm-main); min-height: 48px; padding: 0 18px; font-size: 16px; }
.fm-btn.sm { min-height: 48px; padding: 0 16px; font-size: 16px; }
.fm-btn.wide { width: 100%; }
.fm-btn.big { width: 100%; min-height: 64px; font-size: 20px; }
.fm-btn:disabled { opacity: .55; cursor: wait; }
.fm-link { background: none; border: 0; padding: 0; font: inherit; color: var(--fm-main); text-decoration: underline; font-size: 16px; font-weight: 700; cursor: pointer; }
.fm-nav { display: flex; gap: 12px; margin-top: 22px; }
.fm-nav #fm-next { flex: 1; }
.fm-done h2 { color: var(--fm-main); }
.fm-done strong { font-size: 22px; color: var(--fm-main); letter-spacing: .04em; }

@media (max-width: 560px) {
  .fm-page { padding: 22px 16px 34px; }
  .fm-h1 { font-size: 24px; }
  .fm-search { padding: 18px 16px 20px; }
  .fm-sec { padding: 20px 16px 22px; }
  .fm-chips, .fm-chips.two, .fm-chips.three { grid-template-columns: 1fr; }
  .fm-grid2 { grid-template-columns: 1fr; gap: 0; }
  .fm-drop { flex-direction: column; align-items: flex-start; }
  .fm-prog li { font-size: 14px; }
  .fm-cand { flex-direction: column; align-items: stretch; }
  .fm-cand .fm-btn { width: 100%; }
  .fm-page .card-content { flex-direction: row; padding: 12px 14px; gap: 10px; }
  .fm-page .card-content .right-column { width: 96px; }
  .fm-page .tel-hp-wrapper { flex-wrap: wrap; gap: 8px; }
  .fm-sum th, .fm-sum td { display: block; width: auto; padding: 4px 14px; }
  .fm-sum th { padding-top: 10px; border: 0; }
  .fm-btn { white-space: normal; text-align: center; }
}

/* 教室カード（フォーム内）: コンパクト表示。説明文は4行まで */
#fm-card .card-content { align-items: flex-start; }
#fm-card .card-content .right-column { flex: 1 1 45%; width: auto; flex-direction: column; align-items: flex-start; justify-content: flex-start; gap: 8px; }
#fm-card .card-content .right-column img { flex: 0 0 72px; width: 72px; max-width: 72px; height: 72px; }
#fm-card .card-content .description { margin-top: 0; text-align: left; display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 4; overflow: hidden; }
#fm-card .card:hover .right-column img { transform: none; }
@media (max-width: 768px) {
  #fm-card .card-content { flex-direction: column; align-items: stretch; }
  #fm-card .card-content .left-column { width: 100%; }
  #fm-card .card-content .right-column { padding: 0; width: 100%; flex: 0 0 auto; }
  #fm-card .card-content .right-column img { margin: 0; align-self: flex-start; }
  #fm-card .card-content .description { max-width: none; width: 100%; }
}

/* ご案内メールの停止（optout.html） */
.oo-box { background: #fff; border: 1px solid #d9dee7; border-radius: 16px; padding: 24px 20px; margin: 0 0 20px; font-size: 17px; line-height: 1.8; }
.oo-box p { margin: 0 0 16px; }
.oo-name { font-size: 20px; font-weight: 700; color: var(--fm-ink); }
.oo-box .fm-notice { margin: 16px 0 0; }
.oo-note { font-size: 15px; color: var(--fm-sub); line-height: 1.8; }
