/* ========================================
   BOROIMISE 絵画教室 — trial.css
   体験LP (trial.html) 固有スタイル
   ======================================== */

/* ===== Page-level overrides ===== */
.page-trial {
  color: var(--c-text);
  background-color: var(--c-bg);
}

.page-trial .hero-title {
  color: var(--c-theme-trial);
}

.page-trial .hero-location {
  color: var(--c-theme-regular);
  border-color: rgba(42, 59, 77, 0.2);
}

.page-trial .section-title {
  color: var(--c-theme-trial);
}

/* ===== Button overrides ===== */
.page-trial .btn {
  border-radius: 60px;
  font-weight: 700;
  letter-spacing: 0.08em;
}

.page-trial .btn-primary {
  background: linear-gradient(135deg, var(--c-theme-trial) 0%, var(--c-terra-dark) 100%);
  box-shadow: 0 6px 24px rgba(196, 101, 74, 0.4);
}

.page-trial .btn-primary:hover {
  transform: translateY(-3px) scale(1.02);
  box-shadow: 0 10px 32px rgba(196, 101, 74, 0.5);
}

/* ===== Contact section ===== */
.page-trial .contact {
  background: linear-gradient(135deg, var(--c-theme-trial) 0%, var(--c-terra-dark) 100%);
}

.page-trial .contact .section-title {
  color: #FFF;
  margin-bottom: 40px;
}

.page-trial .contact .section-title::after {
  display: none;
}

.page-trial .contact-sub {
  color: rgba(255, 255, 255, 0.92);
  font-weight: 600;
  margin-bottom: 16px;
}

.page-trial .contact-sub::after {
  content: '';
  display: block;
  width: 32px;
  height: 2px;
  background: rgba(255, 255, 255, 0.5);
  border-radius: 2px;
  margin: 12px auto 0;
}

.page-trial .contact .btn-primary {
  background: #FFF;
  color: var(--c-theme-trial);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
}

.page-trial .contact .btn-primary:focus,
.page-trial .contact .btn-primary:hover {
  background: #FEF0ED;
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.2);
}

/* 必須・任意バッジ（テラコッタ背景に合わせて白地反転） */
.page-trial .required {
  background: rgba(255, 255, 255, 0.9);
  color: var(--c-theme-trial);
}

.page-trial .optional {
  background: var(--c-theme-trial);
  color: #FFF;
  opacity: 0.85;
}

/* ===== Features override ===== */
@media (min-width: 1024px) {
  .page-trial .features-grid {
    grid-template-columns: repeat(2, 1fr);
    max-width: 900px;
    margin: 0 auto;
  }
}

/* ===== Curriculum steps ===== */
.curriculum-step {
  background: #FFF;
  padding: 32px;
  border-radius: 12px;
  border: 1px solid var(--c-border);
  margin-bottom: 24px;
  transition: transform var(--t-base), box-shadow var(--t-base);
}

.curriculum-step:last-child {
  margin-bottom: 40px;
}

.curriculum-step:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 30px rgba(196, 101, 74, 0.08);
  border-color: var(--c-terra-light);
}

.curriculum-step .note {
  font-size: 0.85rem;
  color: var(--c-text-muted);
}

/* ===== カリキュラムステップ — グラフィカルレイアウト ===== */

/* ヘッダー */
.cs-header {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-bottom: 24px;
  padding-bottom: 16px;
  border-bottom: 2px solid var(--c-terra-light);
}

.cs-num {
  font-family: var(--f-serif);
  font-size: 2.4rem;
  font-weight: 700;
  color: var(--c-terra-light);
  line-height: 1;
  min-width: 44px;
}

.cs-meta {
  flex: 1;
}

.cs-session {
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  color: var(--c-terra);
  margin: 0 0 3px;
}

/* h3 override: 既存の border-bottom などをリセット */
.cs-header .cs-title {
  font-size: 1.05rem;
  color: var(--c-navy);
  border-bottom: none;
  padding-bottom: 0;
  margin-bottom: 0;
  display: block;
  font-weight: 500;
}

.cs-duration {
  font-size: 0.73rem;
  font-weight: 600;
  color: var(--c-text-muted);
  background: var(--c-bg);
  border: 1px solid var(--c-border);
  border-radius: 20px;
  padding: 4px 12px;
  white-space: nowrap;
  flex-shrink: 0;
}

/* タイムライン縦線 */
.cs-timeline {
  position: relative;
  padding-left: 28px;
}

.cs-timeline::before {
  content: '';
  position: absolute;
  left: 6px;
  top: 8px;
  bottom: 8px;
  width: 2px;
  background: linear-gradient(to bottom, var(--c-terra-light), var(--c-border));
  border-radius: 2px;
}

/* 各フェーズ */
.cs-phase {
  position: relative;
  margin-bottom: 18px;
}

.cs-phase:last-child {
  margin-bottom: 0;
}

.cs-phase::before {
  content: '';
  position: absolute;
  left: -28px;
  top: 6px;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: #FFF;
  border: 2px solid var(--c-terra-light);
  box-sizing: border-box;
}

.cs-phase-head {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 5px;
}

.cs-phase-icon {
  width: 16px;
  height: 16px;
  color: var(--c-terra);
  flex-shrink: 0;
}

.cs-phase-label {
  font-size: 0.88rem;
  font-weight: 700;
  color: var(--c-navy);
}

.cs-phase-time {
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  color: var(--c-terra);
  background: rgba(196, 101, 74, 0.1);
  padding: 2px 8px;
  border-radius: 10px;
}

.cs-phase-desc {
  font-size: 0.87rem;
  line-height: 1.75;
  color: var(--c-text);
  margin: 0;
}

/* ノート（注記） */
.cs-note {
  font-size: 0.82rem;
  color: var(--c-text-muted);
  margin: 20px 0 0;
  padding-top: 16px;
  border-top: 1px solid var(--c-border);
  line-height: 1.6;
}

/* ===== カリキュラムステップ — モバイル ===== */
@media (max-width: 479px) {
  .curriculum-step {
    padding: 20px 16px;
  }

  /* ヘッダー: 折り返しを許可 */
  .cs-header {
    flex-wrap: wrap;
    gap: 8px 12px;
    margin-bottom: 18px;
  }

  /* 番号サイズ縮小 */
  .cs-num {
    font-size: 1.9rem;
    min-width: 32px;
  }

  /* バッジを2行目に送る */
  .cs-duration {
    order: 3;
    flex-basis: 100%;
    text-align: left;
    font-size: 0.68rem;
    padding: 3px 10px;
  }

  /* タイムライン: インデント縮小 */
  .cs-timeline {
    padding-left: 22px;
  }

  .cs-timeline::before {
    left: 4px;
  }

  .cs-phase::before {
    left: -22px;
    width: 12px;
    height: 12px;
  }

  /* アイコン: サイズと表示を明示 */
  .cs-phase-icon {
    width: 14px;
    height: 14px;
    display: block;
  }

  .cs-phase-desc {
    font-size: 0.83rem;
  }
}

/* ===== Section subtitle ===== */
.section-sub {
  text-align: center;
  color: var(--c-text-light);
  margin-top: -12px;
  margin-bottom: 48px;
  line-height: 1.8;
}

.section-sub strong {
  color: var(--c-terra);
  font-size: 1.1rem;
  display: inline-block;
  margin-top: 16px;
}

/* ===== Instructor bridge section ===== */
.instructor-bridge {
  padding: 60px 0;
  background: var(--c-bg-warm);
  text-align: center;
}

.instructor-bridge p {
  font-size: 1rem;
  color: var(--c-text);
  line-height: 1.9;
  max-width: 600px;
  margin: 0 auto 32px;
}

.instructor-bridge .btn-bridge {
  background: var(--c-navy);
  color: #FFF;
  padding: 14px 36px;
  border-radius: 50px;
  text-decoration: none;
  font-size: 0.95rem;
  display: inline-block;
  transition: all 0.3s ease;
}

.instructor-bridge .btn-bridge:hover {
  background: var(--c-navy-light);
  color: #FFF;
  transform: translateY(-2px);
}

/* ===== Footer extras ===== */
.footer-extra-link {
  text-align: center;
  margin-top: 32px;
}

.footer-extra-link a {
  color: rgba(255, 255, 255, 0.7);
  text-decoration: none;
  font-size: 0.9rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.4);
  padding-bottom: 2px;
}

.footer-extra-link a:hover {
  color: #FFF;
}

/* ===== 体験コース空き状況グリッド ===== */

/* グリッド見出し */
.trial-grid-heading {
  display: block;
  font-size: 0.82rem;
  font-weight: 500;
  color: rgba(255, 255, 255, 0.9);
  margin-bottom: 6px;
  line-height: 1.6;
}

.trial-grid-heading-sub {
  font-size: 0.75rem;
  font-weight: 400;
  opacity: 0.75;
}

/* スクロールラッパー */
.trial-grid-scroll {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  font-family: var(--f-sans, 'Noto Sans JP', sans-serif);
  width: 100%;
  box-sizing: border-box;
}

.trial-grid-scroll .schedule-grid {
  min-width: max-content;
  gap: 2px;
}

/* 左上コーナー非表示 */
.trial-grid-corner {
  background: transparent !important;
  border: none !important;
}

/* 日付ヘッダー */
.trial-grid-scroll .schedule-header {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 1.4em;
  padding: 3px 6px;
  color: rgba(255, 255, 255, 0.85);
  border: 1px solid rgba(255, 255, 255, 0.7);
  border-radius: 4px;
  background: transparent;
  font-weight: 600;
}

/* 左列スティッキー */
.trial-sticky-col {
  position: sticky;
  left: 0;
  z-index: 2;
  background: #FFF;
}

/* 左列: 時間とクラス名を縦並び */
.trial-grid-scroll .schedule-time {
  flex-direction: column;
  align-items: flex-start;
  padding: 8px 10px;
  min-height: 56px;
  background: #FFF;
  border-left: none;
}

/* 時間帯テキスト */
.slot-time-label {
  display: block;
  color: var(--c-text-muted);
  margin-bottom: 4px;
  line-height: 1.3;
}

/* クラス名テキスト: クラスごとのテーマカラー */
.slot-class-label {
  display: block;
  line-height: 1.3;
}
.trial-row-child-lower .slot-class-label,
.trial-row-child-upper .slot-class-label { color: var(--c-class-jiyu); }
.trial-row-teen   .slot-class-label       { color: var(--c-class-design); }
.trial-row-family .slot-class-label       { color: var(--c-class-family); }
.trial-row-adult  .slot-class-label       { color: var(--c-class-kiso); }

/* データセル: 背景白・ボーダーなし */
.trial-grid-scroll .schedule-cell {
  background: #FFF;
  border-left: none;
}

/* データセルのテキストカラー */
.trial-data-child-lower,
.trial-data-child-upper { color: var(--c-class-jiyu); }
.trial-data-teen        { color: var(--c-class-design); }
.trial-data-family      { color: var(--c-class-family); }
.trial-data-adult       { color: var(--c-class-kiso); }

/* 空きあり: クリック可能 */
.trial-slot-avail {
  cursor: pointer;
  font-size: 1rem;
  font-weight: 700;
}

/* ホバー: 上移動をキャンセルし明度で表現 */
.trial-grid-scroll .schedule-cell:hover {
  transform: none;
  box-shadow: none;
  background: #FFF;
  filter: brightness(0.90);
}

/* 空き記号: ◎ .trial-slot-plenty / △ .trial-slot-few はクラスカラーを継承 */
.trial-slot-one { font-size: 0.75rem; font-weight: 700; } /* 残り1名/1組 */

/* 選択状態 */
.trial-slot-selected {
  background: rgba(240, 160, 130, 0.22) !important;
  box-shadow: inset 0 0 0 2px rgba(240, 160, 130, 0.95) !important;
  color: rgba(255, 255, 255, 0.9) !important;
  transform: none;
}

/* 満席 */
.trial-slot-full {
  background: #FFF !important;
  color: #ccc !important;
  font-weight: 700;
  cursor: not-allowed;
  font-size: 1rem;
}

.trial-slot-full:hover {
  transform: none !important;
  box-shadow: none !important;
}

/* 日程調整中 */
.trial-slot-empty {
  text-align: center;
  color: var(--c-text-muted);
  font-size: 0.9rem;
  padding: 24px 0;
}

/* 空き状況グリッドの幅をフォームに揃える */
#trial-slot-summary,
#trial-slot-wrapper-23 {
  max-width: 560px;
  width: 100%;
  box-sizing: border-box;
  margin: 0 auto 24px;
}

/* フォームのフォント統一 */
#trial-form {
  font-family: var(--f-sans, 'Noto Sans JP', sans-serif);
}

/* ===== 2・3日目グリッド：2日選択のハイライト（1日目と同色） ===== */
.trial-slot-sel2,
.trial-slot-sel3 {
  background: rgba(240, 160, 130, 0.22) !important;
  box-shadow: inset 0 0 0 2px rgba(240, 160, 130, 0.95) !important;
  transform: none;
}

/* ===== 選択中の枠を可視化 ===== */
.trial-selection-box {
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.3);
  border-radius: 8px;
  padding: 14px 18px;
  margin-bottom: 24px;
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}

.trial-selection-label {
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  color: rgba(255, 255, 255, 0.6);
  text-transform: uppercase;
  white-space: nowrap;
  margin: 0;
}

.trial-selection-text {
  font-size: 0.95rem;
  font-weight: 700;
  color: #FFF;
  flex: 1;
  margin: 0;
}

.trial-selection-clear {
  background: none;
  border: 1px solid rgba(255, 255, 255, 0.35);
  border-radius: 4px;
  color: rgba(255, 255, 255, 0.6);
  font-size: 0.75rem;
  padding: 4px 10px;
  cursor: pointer;
  transition: all 0.2s;
  white-space: nowrap;
}

.trial-selection-clear:hover {
  border-color: rgba(255, 255, 255, 0.7);
  color: #FFF;
}


/* ===== 送信ボタン無効化状態 ===== */
.btn-submit:disabled {
  opacity: 0.6;
  cursor: not-allowed;
  transform: none !important;
  box-shadow: none !important;
}

/* ===== キャンセルセクション ===== */
.cancel-section {
  max-width: 560px;
  margin: 48px auto 0;
  border-top: 1px solid rgba(255, 255, 255, 0.2);
  padding-top: 32px;
}

.cancel-section summary {
  cursor: pointer;
  font-size: 0.88rem;
  color: rgba(255, 255, 255, 0.6);
  text-decoration: underline;
  text-underline-offset: 3px;
  list-style: none;
  text-align: center;
  transition: color 0.3s;
}

.cancel-section summary::-webkit-details-marker {
  display: none;
}

.cancel-section summary:hover {
  color: rgba(255, 255, 255, 0.9);
}

.cancel-desc {
  font-size: 0.85rem;
  color: rgba(255, 255, 255, 0.65);
  margin: 20px 0 24px;
  text-align: center;
  line-height: 1.7;
}

#cancel-success p {
  color: rgba(255, 255, 255, 0.8);
  font-size: 0.95rem;
  text-align: center;
  padding: 24px 0;
}
