/* へジョンの楽しく学ぶ韓国語 - サイト共通スタイル
   配色: 生成り背景 + コーラル。文字は濃いグレー。主要ボタンの白文字コントラストは4.5以上。 */
:root {
  --bg: #fffaf4;
  --paper: #ffffff;
  --soft: #fdeee8;
  --ink: #3b3433;
  --muted: #6b5f5c;
  --line-c: #eaded6;
  --primary: #bd4b34;
  --primary-dark: #a33d29;
  --accent: #e8735a;
  --line-green: #05803a;
  --c-real: #e8896a;
  --c-online: #5b86b0;
  --c-morning: #e5a52b;
  --c-line: #3aa665;
  --radius: 14px;
  --shadow: 0 4px 18px rgba(120, 70, 50, .08);
  --font: "Zen Maru Gothic", "Hiragino Maru Gothic ProN", "Hiragino Kaku Gothic ProN", "Yu Gothic", Meiryo, sans-serif;
}
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0; background: var(--bg); color: var(--ink);
  font-family: var(--font); font-size: 17px; line-height: 1.85; font-weight: 500;
}
img { max-width: 100%; height: auto; }
a { color: var(--primary); text-underline-offset: 3px; }
a:hover { color: var(--primary-dark); }
:focus-visible { outline: 3px solid #1a5fb4; outline-offset: 2px; }
h1, h2, h3, h4 { line-height: 1.5; font-weight: 700; margin: 0 0 .6em; }
p { margin: 0 0 1.1em; }
.container { width: min(1040px, 100% - 40px); margin-inline: auto; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip-link { position: absolute; left: -999px; top: 0; background: #fff; padding: 8px 14px; z-index: 100; }
.skip-link:focus { left: 8px; top: 8px; }
.hp { position: absolute; left: -9999px; }
.note { font-size: .88rem; color: var(--muted); }
.draft { color: var(--primary); }
.center { text-align: center; }

/* ---------- ヘッダー ---------- */
.site-header { position: sticky; top: 0; z-index: 50; background: rgba(255, 250, 244, .96); backdrop-filter: blur(6px); border-bottom: 1px solid var(--line-c); }
.header-inner { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 64px; }
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; color: var(--ink); }
.brand img { border-radius: 50%; background: var(--soft); }
.brand-text { display: flex; flex-direction: column; line-height: 1.3; }
.brand-text strong { font-size: 1.02rem; }
.brand-text small { font-size: .72rem; color: var(--muted); }
.nav-toggle { display: none; width: 48px; height: 48px; border: 1px solid var(--line-c); background: #fff; border-radius: 12px; cursor: pointer; position: relative; }
.nav-toggle .bars, .nav-toggle .bars::before, .nav-toggle .bars::after { position: absolute; left: 12px; width: 22px; height: 2.5px; background: var(--ink); border-radius: 2px; content: ""; transition: transform .2s, opacity .2s; }
.nav-toggle .bars { top: 22px; }
.nav-toggle .bars::before { left: 0; top: -7px; }
.nav-toggle .bars::after { left: 0; top: 7px; }
.nav-toggle[aria-expanded="true"] .bars { background: transparent; }
.nav-toggle[aria-expanded="true"] .bars::before { transform: translateY(7px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] .bars::after { transform: translateY(-7px) rotate(-45deg); }

.site-nav ul { list-style: none; margin: 0; padding: 0; display: flex; align-items: center; gap: 2px; }
.site-nav li { position: relative; }
.site-nav a { display: block; padding: 10px 12px; color: var(--ink); text-decoration: none; font-size: .93rem; border-radius: 10px; white-space: nowrap; }
.site-nav a:hover, .site-nav li.current > a { background: var(--soft); color: var(--primary-dark); }
.site-nav .sub { display: none; position: absolute; left: 0; top: 100%; min-width: 230px; flex-direction: column; align-items: stretch; background: #fff; border: 1px solid var(--line-c); border-radius: 12px; box-shadow: var(--shadow); padding: 8px; }
.site-nav li.has-sub:hover > .sub, .site-nav li.has-sub:focus-within > .sub { display: flex; }

/* ---------- ボタン ---------- */
.btn { display: inline-flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px; min-height: 48px; padding: 10px 24px; border-radius: 999px; border: 2px solid transparent; font: inherit; font-weight: 700; text-decoration: none; text-align: center; cursor: pointer; line-height: 1.4; }
.btn small { font-weight: 500; font-size: .78rem; opacity: .95; }
.btn-primary { background: var(--primary); color: #fff; }
.btn-primary:hover { background: var(--primary-dark); color: #fff; }
.btn-line { background: var(--line-green); color: #fff; }
.btn-line:hover { background: #046a31; color: #fff; }
.btn-ghost { background: #fff; color: var(--primary-dark); border-color: var(--primary); }
.btn-ghost:hover { background: var(--soft); }
.btn-sm { min-height: 40px; padding: 6px 18px; font-size: .9rem; }
.btn-block { display: flex; width: 100%; }
.btn-row { display: flex; flex-wrap: wrap; gap: 12px; margin: 22px 0; }
.btn-row.center { justify-content: center; }

/* ---------- ヒーロー ---------- */
.hero { background: linear-gradient(160deg, #fff 0%, var(--soft) 100%); padding: 56px 0 48px; }
.hero-inner { display: grid; grid-template-columns: 1.15fr 1fr; gap: 40px; align-items: center; }
.hero .label { display: inline-block; background: var(--primary); color: #fff; font-size: .8rem; letter-spacing: .08em; padding: 3px 16px; border-radius: 999px; margin-bottom: 14px; }
.hero h1 { font-size: clamp(1.7rem, 4.6vw, 2.5rem); margin-bottom: .5em; }
.hero h1 em { color: var(--primary); font-style: normal; }
.hero p.sub { color: var(--muted); }
.hero-photo { margin: 0; }
.hero-photo img { width: 100%; border-radius: 20px; box-shadow: var(--shadow); display: block; }
.hero-photo figcaption { text-align: right; color: var(--muted); font-size: .8rem; margin-top: 6px; }

/* ---------- セクション ---------- */
.section { padding: 56px 0; }
.section.alt { background: #fff; border-block: 1px solid var(--line-c); }
.section.soft { background: var(--soft); }
.section-title { text-align: center; font-size: clamp(1.35rem, 3.4vw, 1.8rem); margin-bottom: .4em; }
.section-title small { display: block; color: var(--primary); font-size: .72rem; letter-spacing: .18em; margin-bottom: 4px; font-weight: 700; }
.section-lead { text-align: center; color: var(--muted); max-width: 640px; margin: 0 auto 30px; }

.page-head { background: linear-gradient(160deg, #fff 0%, var(--soft) 100%); padding: 36px 0 26px; border-bottom: 1px solid var(--line-c); }
.page-head h1 { font-size: clamp(1.5rem, 4vw, 2.1rem); margin: 0; }
.page-lead { color: var(--muted); margin: .6em 0 0; }
.page-head .crumb { font-size: .85rem; color: var(--muted); margin: 0 0 .4em; }
.page-head time { display: block; color: var(--muted); font-size: .9rem; margin-top: 6px; }
.page-body { padding-block: 36px 56px; }
.course-hero { border-left: 8px solid var(--course, var(--accent)); }

/* 本文 */
.prose { max-width: 800px; }
.prose h2 { font-size: 1.4rem; margin-top: 2em; padding: .2em 0 .3em .7em; border-left: 6px solid var(--course, var(--accent)); }
.prose h3 { font-size: 1.15rem; margin-top: 1.6em; color: var(--primary-dark); }
.prose ul, .prose ol { padding-left: 1.4em; }
.prose li { margin-bottom: .4em; }
.prose .facts, .prose .steps { padding: 0; }
.prose .steps { margin-inline: 0; }
.prose img { border-radius: 10px; }
.prose table { border-collapse: collapse; width: 100%; }
.prose th, .prose td { border: 1px solid var(--line-c); padding: 8px 12px; text-align: left; }
.prose blockquote { margin: 1.2em 0; padding: .6em 1.2em; background: var(--soft); border-radius: 10px; }
.page-body > .prose { max-width: 800px; }

/* カード類 */
.cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 18px; }
.card { background: var(--paper); border: 1px solid var(--line-c); border-top: 4px solid var(--accent); border-radius: var(--radius); padding: 20px 22px; box-shadow: var(--shadow); }
.card strong { display: block; color: var(--primary-dark); margin-bottom: 6px; font-size: 1.05rem; }
.card p:last-child { margin-bottom: 0; }

.course-cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); gap: 18px; }
.course-card { display: flex; flex-direction: column; gap: 6px; background: #fff; border: 1px solid var(--line-c); border-top: 6px solid var(--course); border-radius: var(--radius); padding: 22px 20px; text-decoration: none; color: var(--ink); box-shadow: var(--shadow); transition: transform .15s, box-shadow .15s; }
.course-card:hover { transform: translateY(-3px); box-shadow: 0 8px 24px rgba(120, 70, 50, .14); color: var(--ink); }
.cc-icon { font-size: 2rem; line-height: 1; }
.cc-name { font-weight: 700; font-size: 1.15rem; }
.cc-desc { color: var(--muted); font-size: .92rem; flex: 1; }
.cc-price { font-weight: 700; color: var(--primary-dark); font-size: 1.05rem; }
.cc-more { color: var(--primary); font-weight: 700; font-size: .92rem; }
.course-real { --course: var(--c-real); }
.course-online { --course: var(--c-online); }
.course-morning { --course: var(--c-morning); }
.course-line { --course: var(--c-line); }
body.course-real, body.course-online, body.course-morning, body.course-line { --accent: var(--course); }

.steps { counter-reset: step; list-style: none; padding: 0; max-width: 680px; margin: 0 auto; }
.steps li { position: relative; padding: 14px 0 14px 60px; border-bottom: 1px dashed var(--line-c); }
.steps li::before { counter-increment: step; content: counter(step); position: absolute; left: 0; top: 12px; width: 40px; height: 40px; border-radius: 50%; background: var(--primary); color: #fff; display: flex; align-items: center; justify-content: center; font-weight: 700; }
.steps li strong { display: block; }
.time-tag { color: var(--primary-dark); font-weight: 700; margin-right: 6px; }

.teacher { display: grid; grid-template-columns: 150px 1fr; gap: 24px; align-items: center; background: #fff; border: 1px solid var(--line-c); border-radius: var(--radius); padding: 24px; max-width: 760px; margin-inline: auto; box-shadow: var(--shadow); }
.teacher img { width: 150px; height: 150px; border-radius: 50%; object-fit: cover; object-position: center 30%; border: 4px solid var(--soft); }
.teacher p:last-child { margin: 0; }

.callout { background: var(--soft); border: 1px solid #f3d7cd; border-radius: var(--radius); padding: 20px 24px; margin: 1.6em 0; }
.callout > :last-child { margin-bottom: 0; }
.facts { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 12px; margin: 1.4em 0; padding: 0; list-style: none; }
.facts li { background: #fff; border: 1px solid var(--line-c); border-radius: 12px; padding: 12px 16px; margin: 0; }
.facts b { display: block; font-size: .8rem; color: var(--muted); font-weight: 700; }

/* 料金 */
.price-blocks { display: grid; gap: 22px; }
.price-block h3 { margin-bottom: .4em; font-size: 1.1rem; color: var(--ink); }
.price-table { width: 100%; border-collapse: collapse; background: #fff; border-radius: 12px; overflow: hidden; box-shadow: var(--shadow); }
.price-table th, .price-table td { padding: 14px 16px; border-bottom: 1px solid var(--line-c); text-align: left; vertical-align: top; }
.price-table th { width: 55%; font-weight: 700; background: #fffdfb; }
.price-table tr:last-child th, .price-table tr:last-child td { border-bottom: 0; }
.price-table strong { color: var(--primary-dark); font-size: 1.15rem; }
.plans { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 18px; max-width: 640px; margin: 0 auto; }
.plan { background: #fff; border: 2px solid var(--line-c); border-radius: 16px; padding: 28px 20px; text-align: center; position: relative; }
.plan.main { border-color: var(--primary); }
.plan.main::before { content: "おすすめ"; position: absolute; top: -13px; left: 50%; transform: translateX(-50%); background: var(--primary); color: #fff; font-size: .75rem; padding: 2px 14px; border-radius: 999px; }
.plan h3 { margin: 0 0 4px; }
.plan .detail, .plan .unit { font-size: .85rem; color: var(--muted); }
.plan .price { font-size: 2rem; font-weight: 700; color: var(--primary-dark); }
.plan .price span { font-size: .85rem; font-weight: 500; color: var(--muted); }
.subscribe { max-width: 640px; margin: 28px auto 0; background: var(--soft); border: 1px solid #f3d7cd; border-radius: 16px; padding: 26px 24px; text-align: center; }
.subscribe h3 { margin-bottom: .3em; }
.sub-buttons { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 12px; margin: 16px 0; }

/* FAQ */
.faq-list { max-width: 800px; }
.faq-list details { background: #fff; border: 1px solid var(--line-c); border-radius: 12px; margin-bottom: 10px; padding: 0 18px; }
.faq-list summary { cursor: pointer; font-weight: 700; padding: 14px 0; list-style: none; position: relative; padding-right: 28px; }
.faq-list summary::-webkit-details-marker { display: none; }
.faq-list summary::before { content: "Q. "; color: var(--primary); }
.faq-list summary::after { content: "＋"; position: absolute; right: 0; top: 14px; color: var(--primary); }
.faq-list details[open] summary::after { content: "－"; }
.faq-list details p { margin: 0 0 14px; color: var(--muted); }

/* 空き状況 */
.schedule { overflow-x: auto; margin: 1em 0 1.6em; }
.schedule-table { border-collapse: collapse; background: #fff; min-width: 340px; width: 100%; max-width: 560px; text-align: center; }
.schedule-table caption { text-align: left; font-weight: 700; padding-bottom: 8px; }
.schedule-table th, .schedule-table td { border: 1px solid var(--line-c); padding: 8px 6px; }
.schedule-table thead th { background: var(--soft); }
.schedule-table .s-o { color: var(--line-green); font-weight: 700; }
.schedule-table .s-t { color: #a35f00; font-weight: 700; }
.schedule-table .s-x { color: var(--muted); }

/* フォーム */
.form { background: #fff; border: 1px solid var(--line-c); border-radius: 16px; padding: 28px 26px; box-shadow: var(--shadow); max-width: 680px; margin: 1.5em 0; }
.form-row { margin: 0 0 20px; padding: 0; border: 0; min-width: 0; }
.form-row label, .form-row legend { display: block; font-weight: 700; margin-bottom: 6px; padding: 0; }
.req, .opt { font-size: .72rem; font-weight: 700; border-radius: 6px; padding: 1px 7px; margin-left: 8px; vertical-align: 2px; }
.req { background: var(--primary); color: #fff; }
.opt { background: #eee6e1; color: var(--muted); }
.form input[type=text], .form input[type=email], .form input[type=tel], .form input[type=number], .form select, .form textarea {
  width: 100%; font: inherit; font-size: 1rem; padding: 12px 14px; border: 2px solid #d9cbc2; border-radius: 10px; background: #fff; color: var(--ink); }
.form input[type=number] { width: 8em; }
.form input:focus, .form select:focus, .form textarea:focus { border-color: var(--primary); outline: none; box-shadow: 0 0 0 3px rgba(189, 75, 52, .2); }
.form .unit { margin-left: 8px; }
.radio-group { display: flex; flex-wrap: wrap; gap: 8px 20px; }
.opt-item { display: inline-flex !important; align-items: center; gap: 8px; font-weight: 500 !important; min-height: 44px; cursor: pointer; }
.opt-item input { width: 22px; height: 22px; accent-color: var(--primary); }
.hint, .privacy-note { font-size: .85rem; color: var(--muted); margin: 6px 0 0; }
.privacy-note { margin: 0 0 16px; }
.form-status { margin: 14px 0 0; font-weight: 700; }
.form-status.ok { color: var(--line-green); }
.form-status.error { color: #b3261e; }

/* ブログ */
.post-list { display: grid; grid-template-columns: repeat(auto-fill, minmax(290px, 1fr)); gap: 18px; }
.post-card { position: relative; background: #fff; border: 1px solid var(--line-c); border-radius: var(--radius); padding: 18px 20px 52px; box-shadow: var(--shadow); }
.post-card > a:first-child { color: var(--ink); text-decoration: none; display: block; }
.post-card h3 { font-size: 1.05rem; margin: 4px 0 6px; color: var(--primary-dark); }
.post-card p { font-size: .88rem; color: var(--muted); margin: 0; }
.post-card time { font-size: .8rem; color: var(--muted); }
.post-card .tag { position: absolute; left: 20px; bottom: 16px; }
.tag { display: inline-block; font-size: .8rem; text-decoration: none; background: var(--soft); color: var(--primary-dark); padding: 2px 12px; border-radius: 999px; border: 1px solid #f3d7cd; }
.tag.on { background: var(--primary); color: #fff; border-color: var(--primary); }
.cat-nav { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 24px; }
.pager { display: flex; flex-wrap: wrap; gap: 8px; justify-content: center; margin-top: 30px; }
.pager a { min-width: 44px; min-height: 44px; display: flex; align-items: center; justify-content: center; border: 1px solid var(--line-c); border-radius: 10px; background: #fff; text-decoration: none; }
.pager a.on { background: var(--primary); color: #fff; border-color: var(--primary); }
.post-nav { display: flex; justify-content: space-between; gap: 16px; margin-top: 36px; font-size: .92rem; }
.post-nav a { max-width: 48%; }
.post-nav .next { text-align: right; margin-left: auto; }
.back { text-align: center; margin-top: 24px; }
.sitemap-list { line-height: 2; }

/* フッター */
.site-footer { background: #3b3433; color: #f3ebe6; margin-top: 0; padding: 40px 0 24px; }
.site-footer a { color: #f3ebe6; }
.site-footer .btn-line { color: #fff; }
.footer-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr; gap: 28px; }
.footer-grid ul { list-style: none; margin: 8px 0 0; padding: 0; line-height: 2; }
.f-name { font-size: 1.1rem; }
.copy { text-align: center; font-size: .8rem; margin: 30px 0 0; opacity: .8; }

/* スマホ固定ボタン */
.fixed-cta { display: none; }

@media (max-width: 920px) {
  .nav-toggle { display: block; }
  .site-nav { display: none; position: absolute; left: 0; right: 0; top: 100%; background: #fff; border-bottom: 1px solid var(--line-c); box-shadow: var(--shadow); max-height: calc(100vh - 64px); overflow-y: auto; }
  .site-nav.open { display: block; }
  .site-nav ul { flex-direction: column; align-items: stretch; padding: 8px 20px 16px; gap: 0; }
  .site-nav a { padding: 14px 8px; font-size: 1rem; border-bottom: 1px solid var(--line-c); border-radius: 0; white-space: normal; }
  .site-nav .sub { display: flex; position: static; border: 0; box-shadow: none; padding: 0 0 0 16px; min-width: 0; }
  .site-nav .sub a { font-size: .95rem; }
  .hero-inner { grid-template-columns: 1fr; gap: 26px; }
  .hero-photo { order: -1; }
  .hero-photo figcaption { text-align: center; }
  .footer-grid { grid-template-columns: 1fr; }
  .fixed-cta { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; position: fixed; left: 0; right: 0; bottom: 0; z-index: 40; padding: 8px 12px calc(8px + env(safe-area-inset-bottom)); background: rgba(255, 250, 244, .97); border-top: 1px solid var(--line-c); }
  .fixed-cta .btn { min-height: 46px; padding: 6px 10px; font-size: .95rem; }
  body { padding-bottom: 70px; }
}
@media (max-width: 600px) {
  body { font-size: 16.5px; }
  .brand-text strong { font-size: .92rem; }
  .teacher { grid-template-columns: 1fr; text-align: center; }
  .teacher img { margin-inline: auto; }
  .form { padding: 22px 16px; }
  .price-table th, .price-table td { display: block; width: 100%; }
  .price-table th { border-bottom: 0; padding-bottom: 2px; }
  .section { padding: 44px 0; }
}
@media (prefers-reduced-motion: reduce) { * { transition: none !important; scroll-behavior: auto !important; } }
