/* コネクション実践 — 共通スタイル（ダークテーマ） */

:root {
  --bg: #0F172A;
  --surface: #1A2333;
  --surface-2: #212C40;
  --border: #2E3A52;
  --text: #E2E8F0;
  --muted: #94A3B8;
  --accent: #F472B6;
  --accent-2: #38BDF8;
  --accent-warn: #FBBF24;
  --green: #34D399;
  --radius: 12px;
  --shadow: 0 1px 4px rgba(0,0,0,.35), 0 8px 24px rgba(0,0,0,.25);
}

* { box-sizing: border-box; margin: 0; padding: 0; }

body {
  font-family: -apple-system, BlinkMacSystemFont, "Hiragino Sans", "Yu Gothic", sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.75;
}

a { color: var(--accent); }

.container { max-width: 900px; margin: 0 auto; padding: 32px 24px 64px; }

/* ---------- header / breadcrumb ---------- */

header.page-header {
  background: linear-gradient(135deg, #1E293B 0%, #0F172A 100%);
  border-bottom: 1px solid var(--border);
  padding: 32px 24px 26px;
}

.breadcrumb { font-size: 12px; opacity: .75; margin-bottom: 10px; display: flex; gap: 6px; flex-wrap: wrap; }
.breadcrumb a { color: var(--muted); text-decoration: none; }
.breadcrumb a:hover { color: var(--accent); }
.breadcrumb span { opacity: .5; }

header.page-header h1 { font-size: 24px; font-weight: 800; margin-bottom: 6px; }
header.page-header p.subtitle { font-size: 13px; color: var(--muted); }

.badge-row { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 12px; }
.badge {
  display: inline-block; border-radius: 99px; padding: 3px 12px; font-size: 11px;
  font-weight: 700; border: 1px solid var(--border); color: var(--muted); background: var(--surface);
}
.badge.category { color: #0F172A; background: var(--accent); border-color: var(--accent); }
.badge.day { color: #0F172A; background: var(--accent-2); border-color: var(--accent-2); }

/* ---------- card / section ---------- */

.card {
  background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius);
  box-shadow: var(--shadow); padding: 22px 24px; margin-bottom: 24px;
}
.card h2 { font-size: 17px; font-weight: 700; margin-bottom: 14px; display: flex; align-items: center; gap: 8px; }
.card h2::before { content: ""; display: block; width: 4px; height: 18px; background: var(--accent); border-radius: 2px; }

/* ---------- JP/US lang tabs ---------- */

.lang-tabs { display: flex; gap: 8px; margin-bottom: 16px; }
.lang-tab-btn {
  flex: 1; background: var(--surface-2); border: 1px solid var(--border); color: var(--muted);
  border-radius: 8px; padding: 10px 14px; font-size: 13px; font-weight: 700; cursor: pointer;
  transition: background .15s, color .15s, border-color .15s;
}
.lang-tab-btn.active { background: var(--accent); color: #0F172A; border-color: var(--accent); }
.lang-panel { display: none; }
.lang-panel.active { display: block; }

/* ---------- dialogue quote ---------- */

.dialogue {
  background: var(--surface-2); border-left: 4px solid var(--accent-2); border-radius: 0 8px 8px 0;
  padding: 14px 18px; margin: 10px 0; font-size: 14px; font-style: italic;
}

/* ---------- multi-turn transcript ---------- */

.transcript { display: flex; flex-direction: column; gap: 8px; margin: 10px 0; }
.turn {
  border-radius: 8px; padding: 12px 16px; font-size: 14px; max-width: 88%;
}
.turn .speaker { font-size: 11px; font-weight: 700; letter-spacing: .04em; margin-bottom: 4px; display: block; }
.turn.them { background: var(--surface-2); border-left: 4px solid var(--accent-2); align-self: flex-start; }
.turn.them .speaker { color: var(--accent-2); }
.turn.you { background: rgba(244,114,182,.10); border-left: 4px solid var(--accent); align-self: flex-end; }
.turn.you .speaker { color: var(--accent); }
.turn.inner { background: transparent; border-left: 4px dashed var(--border); font-style: italic; color: var(--muted); align-self: flex-start; }

/* ---------- hint accordion ---------- */

details.hint {
  background: var(--surface-2); border: 1px solid var(--border); border-radius: 8px;
  padding: 10px 16px; margin-bottom: 10px;
}
details.hint summary {
  cursor: pointer; font-weight: 700; font-size: 13px; color: var(--accent-warn);
  list-style: none; display: flex; align-items: center; gap: 8px;
}
details.hint summary::-webkit-details-marker { display: none; }
details.hint summary::before { content: "▶"; font-size: 10px; transition: transform .15s; }
details.hint[open] summary::before { transform: rotate(90deg); }
details.hint .hint-body { margin-top: 10px; font-size: 13px; color: var(--text); line-height: 1.8; }

/* ---------- reveal (model answer) ---------- */

.reveal-btn {
  background: var(--accent); color: #0F172A; border: none; border-radius: 8px;
  padding: 10px 20px; font-size: 13px; font-weight: 700; cursor: pointer;
  display: inline-flex; align-items: center; gap: 6px; transition: opacity .15s;
}
.reveal-btn:hover { opacity: .85; }
.reveal-body { display: none; margin-top: 16px; border-top: 1px solid var(--border); padding-top: 16px; }
.reveal-body.open { display: block; }

.answer-block {
  background: var(--surface-2); border: 1px solid var(--border); border-radius: 8px;
  padding: 14px 18px; margin-bottom: 12px; font-size: 14px;
}
.answer-block .answer-label {
  font-size: 11px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase;
  color: var(--accent); margin-bottom: 8px;
}
.answer-block ul, .answer-block ol { margin-left: 18px; margin-top: 6px; }

/* ---------- contrast note ---------- */

.contrast-note {
  background: rgba(56,189,248,.08); border: 1px solid rgba(56,189,248,.35);
  border-radius: 8px; padding: 16px 18px; font-size: 14px;
}

/* ---------- small step highlight box ---------- */

.step-box {
  background: rgba(52,211,153,.10); border: 1.5px solid rgba(52,211,153,.5);
  border-radius: var(--radius); padding: 18px 22px; font-size: 14px;
  box-shadow: var(--shadow);
}
.step-box .step-label {
  display: inline-flex; align-items: center; gap: 6px; font-size: 11px; font-weight: 800;
  letter-spacing: .06em; text-transform: uppercase; color: var(--green); margin-bottom: 10px;
}
.step-box .step-label::before { content: "🌱"; font-size: 13px; }

/* ---------- why-hard note ---------- */

.why-hard {
  background: var(--surface-2); border: 1px solid var(--border); border-radius: var(--radius);
  padding: 18px 22px; font-size: 14px; margin-bottom: 24px;
}

/* ---------- self-eval checkboxes ---------- */

.self-eval { display: flex; flex-direction: column; gap: 14px; }
.eval-row { background: var(--surface-2); border: 1px solid var(--border); border-radius: 8px; padding: 14px 16px; }
.eval-row .eval-lang { font-weight: 700; font-size: 13px; margin-bottom: 8px; color: var(--accent); }
.eval-options { display: flex; gap: 16px; flex-wrap: wrap; font-size: 13px; }
.eval-options label { display: flex; align-items: center; gap: 6px; cursor: pointer; }
.eval-note {
  width: 100%; margin-top: 12px; background: var(--bg); border: 1px solid var(--border); border-radius: 6px;
  color: var(--text); font-size: 13px; padding: 8px 10px; font-family: inherit; resize: vertical; min-height: 60px;
}

/* ---------- nav footer ---------- */

.nav-footer { display: flex; gap: 12px; flex-wrap: wrap; padding-top: 24px; margin-top: 8px; border-top: 1px solid var(--border); }
.nav-btn {
  display: inline-flex; align-items: center; gap: 6px; border-radius: 8px; padding: 10px 18px;
  font-size: 13px; font-weight: 700; text-decoration: none; transition: opacity .15s;
}
.nav-prev { background: var(--surface); border: 1px solid var(--border); color: var(--text); }
.nav-next { background: var(--accent); border: 1px solid var(--accent); color: #0F172A; }
.nav-prev:hover, .nav-next:hover { opacity: .85; }

/* ---------- index page ---------- */

.index-header {
  background: linear-gradient(135deg, #1E293B 0%, #0F172A 100%);
  padding: 56px 24px; text-align: center; border-bottom: 1px solid var(--border);
}
.index-header h1 { font-size: 30px; font-weight: 800; margin-bottom: 10px; }
.index-header p { font-size: 14px; color: var(--muted); }

.week-legend { display: flex; gap: 8px; flex-wrap: wrap; margin: 32px 0 28px; }
.week-legend .leg {
  font-size: 11px; color: var(--muted); border: 1px solid var(--border); background: var(--surface);
  border-radius: 99px; padding: 4px 12px;
}

.entry-list { display: flex; flex-direction: column; gap: 12px; }
.entry-card {
  display: flex; align-items: center; gap: 16px; background: var(--surface);
  border: 1px solid var(--border); border-radius: var(--radius); padding: 16px 20px;
  text-decoration: none; color: inherit; box-shadow: var(--shadow); transition: transform .15s, border-color .15s;
}
.entry-card:hover { transform: translateY(-2px); border-color: var(--accent); }
.entry-day {
  flex: 0 0 auto; width: 56px; height: 56px; border-radius: 10px; background: var(--surface-2);
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  font-weight: 800; color: var(--accent); font-size: 11px; border: 1px solid var(--border);
}
.entry-day .num { font-size: 18px; }
.entry-main { flex: 1; }
.entry-main .entry-title { font-size: 15px; font-weight: 700; margin-bottom: 4px; }
.entry-main .entry-meta { font-size: 12px; color: var(--muted); display: flex; gap: 10px; flex-wrap: wrap; }
.entry-arrow { color: var(--muted); font-size: 18px; }
