/* ================================================================
   京才塾 LP v2 — 仲間と航海する受験
   モノクロ / ドット絵 / ミニマル / スマホファースト
================================================================= */

:root {
  --ink: #1a1a1a;
  --paper: #ffffff;
  --mid: #8c8c8c;
  --light: #e6e6e6;
  --faint: #f4f4f4;
  --brand: #f1891d; /* ロゴのオレンジ（ロゴ・ロゴ文字にのみ使用） */
  --font-body: 'Zen Kaku Gothic New', 'Hiragino Kaku Gothic ProN', sans-serif;
  --font-dot: 'DotGothic16', 'Zen Kaku Gothic New', monospace;
  --maxw: 640px;
}

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

html { scroll-behavior: smooth; }

body {
  background: var(--paper);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 15px;
  line-height: 1.9;
  letter-spacing: 0.02em;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

.dot { font-family: var(--font-dot); font-weight: 400; }

img { max-width: 100%; display: block; }
a { color: inherit; }
h1, h2, h3 { line-height: 1.5; }
h3 { font-size: 16px; font-weight: 700; }

canvas { image-rendering: pixelated; image-rendering: crisp-edges; }

/* ----------------------------------------------------------------
   ボタン
---------------------------------------------------------------- */
.btn {
  display: inline-block;
  background: var(--ink);
  color: var(--paper);
  text-decoration: none;
  font-family: var(--font-dot);
  text-align: center;
  border: 2px solid var(--ink);
  padding: 14px 32px;
  font-size: 16px;
  line-height: 1.4;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
  box-shadow: 4px 4px 0 rgba(26, 26, 26, 0.18);
}
.btn:active { transform: translate(2px, 2px); box-shadow: 1px 1px 0 rgba(26,26,26,0.18); }
@media (hover: hover) {
  .btn:hover { transform: translate(-1px, -1px); box-shadow: 6px 6px 0 rgba(26,26,26,0.18); }
}
.btn-small {
  padding: 8px 16px;
  font-size: 13px;
  box-shadow: 3px 3px 0 rgba(26,26,26,0.18);
}
.btn-cta { min-width: 260px; }

/* ----------------------------------------------------------------
   ヘッダー
---------------------------------------------------------------- */
.site-header {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 20px;
  padding-top: max(12px, env(safe-area-inset-top));
  background: transparent;
  transition: background 0.3s ease, border-color 0.3s ease;
  border-bottom: 1px solid transparent;
}
.site-header.is-solid {
  background: rgba(255, 255, 255, 0.92);
  -webkit-backdrop-filter: blur(6px);
  backdrop-filter: blur(6px);
  border-bottom-color: var(--light);
}
.header-logo {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  text-decoration: none;
}
.header-logo .logo-mark {
  height: 24px;
  width: auto;
  display: block;
}
.header-logo .logo-text {
  font-size: 19px;
  letter-spacing: 0.1em;
  color: var(--brand);
  line-height: 1;
}

/* 右側のかたまり（LINE / メニュー） */
.header-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}

/* ハンバーガー */
.nav-toggle {
  width: 22px;
  display: flex;
  flex-direction: column;
  gap: 5px;
  padding: 0;
  border: 0;
  background: none;
  cursor: pointer;
}
.nav-toggle i {
  display: block;
  height: 2px;
  background: var(--ink);
  transition: background 0.3s ease;
}

/* ドロップダウン。ヘッダー直下に全幅で開く */
.site-nav {
  display: none;
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  padding: 4px 20px 20px;
  background: var(--paper);
  border-bottom: 1px solid var(--light);
}
.site-nav.is-open { display: block; }
.site-nav a {
  display: block;
  padding: 12px 0;
  border-bottom: 1px solid var(--light);
  font-size: 14px;
  font-weight: 700;
  text-decoration: none;
  color: var(--ink);
}
.site-nav a:last-child { border-bottom: 0; }

/* ----------------------------------------------------------------
   Hero
---------------------------------------------------------------- */
.hero {
  position: relative;
  height: 100svh;
  min-height: 560px;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
}
.hero-canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}
.hero-inner {
  position: relative;
  z-index: 2;
  text-align: center;
  padding: 0 24px;
  will-change: opacity, transform;
}
.hero-eyebrow {
  font-size: 13px;
  letter-spacing: 0.28em;
  margin-bottom: 18px;
  opacity: 0;
  animation: hero-in 1s ease 0.9s forwards;
}
.hero-title {
  font-size: clamp(25px, 6.4vw, 42px);
  white-space: nowrap;
  letter-spacing: 0.06em;
  line-height: 1.7;
  opacity: 0;
  animation: hero-in 1.1s ease 1.2s forwards;
}
.hero-lead {
  margin-top: 20px;
  font-size: 14px;
  opacity: 0;
  animation: hero-in 1.1s ease 1.7s forwards;
}
.hero-lead strong { font-weight: 700; }
.hero-inner .btn-cta {
  margin-top: 28px;
  opacity: 0;
  animation: hero-in 1.1s ease 2.2s forwards;
}
.hero-note {
  margin-top: 14px;
  font-size: 12px;
  color: var(--mid);
  opacity: 0;
  animation: hero-in 1.1s ease 2.5s forwards;
}
@keyframes hero-in {
  from { opacity: 0; transform: translateY(14px); }
  to { opacity: 1; transform: translateY(0); }
}

/* 夜（Heroの時間経過に合わせて文字が白へ反転する） */
.hero-inner { color: var(--ink); transition: color 1.4s ease; }
.hero-note { transition: color 1.4s ease; }
.hero .btn-cta { transition: border-color 1.4s ease, box-shadow 1.4s ease, transform 0.15s ease; }
.hero.is-night .hero-inner { color: var(--paper); }
.hero.is-night .hero-note { color: var(--paper); opacity: 0.9; }
.hero.is-night .btn-cta { border-color: var(--paper); box-shadow: 4px 4px 0 rgba(255,255,255,0.28); }
.scroll-hint { transition: color 1.4s ease; }
.hero.is-night ~ * .scroll-hint,
.hero.is-night .scroll-hint { color: var(--paper); }
/* ロゴはオレンジ固定（昼夜どちらでも視認できる） */
body.is-night-sky .site-header:not(.is-solid) .btn-small { border-color: var(--paper); box-shadow: 3px 3px 0 rgba(255,255,255,0.28); }
body.is-night-sky .site-header:not(.is-solid) .nav-toggle i { background: var(--paper); }
.scroll-hint {
  position: absolute;
  bottom: max(22px, env(safe-area-inset-bottom));
  left: 50%;
  transform: translateX(-50%);
  z-index: 2;
  font-size: 14px;
  color: var(--ink);
  opacity: 0;
  animation: hero-in 1s ease 3s forwards, hint-bob 2s ease-in-out 4s infinite;
}
@keyframes hint-bob {
  0%, 100% { transform: translate(-50%, 0); }
  50% { transform: translate(-50%, 6px); }
}

/* ----------------------------------------------------------------
   セクション共通
---------------------------------------------------------------- */
.section {
  position: relative;
  padding: 0 0 104px;
}
.scene {
  display: block;
  width: 100%;
  height: auto;
}
.section-body {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 40px 24px 0;
}
.sec-label {
  font-size: 12px;
  letter-spacing: 0.3em;
  color: var(--mid);
  margin-bottom: 14px;
}
.sec-title {
  font-size: clamp(22px, 6vw, 32px);
  letter-spacing: 0.04em;
  line-height: 1.7;
  margin-bottom: 24px;
}
.sec-lead {
  font-size: 14px;
  margin-bottom: 36px;
}

/* スクロールリビール */
.reveal {
  opacity: 0;
  transform: translateY(18px);
  transition: opacity 0.8s ease, transform 0.8s ease;
}
.reveal.is-visible { opacity: 1; transform: translateY(0); }

/* ----------------------------------------------------------------
   02. 京才塾とは
---------------------------------------------------------------- */
.about-list { display: grid; gap: 36px; margin-top: 12px; }
.about-item {
  position: relative;
  padding-left: 52px;
}
.about-num {
  position: absolute;
  left: 0; top: 0;
  width: 34px; height: 34px;
  border: 2px solid var(--ink);
  display: grid;
  place-items: center;
  font-size: 16px;
  background: var(--paper);
  box-shadow: 3px 3px 0 var(--light);
}
.about-item h3 { margin-bottom: 6px; }
.about-item p:not(.about-num) { color: #444; font-size: 14px; }

/* ----------------------------------------------------------------
   03. コミュニティの価値（2×2）
---------------------------------------------------------------- */
.value-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
}
.value-item {
  border: 2px solid var(--ink);
  background: var(--paper);
  padding: 20px 14px 18px;
  text-align: center;
  box-shadow: 4px 4px 0 var(--light);
}
.value-item { transition: background 0.15s ease, color 0.15s ease; -webkit-tap-highlight-color: transparent; }
.value-item:active { background: var(--ink); }
.value-item:active h3 { color: var(--paper); }
.value-item:active p:last-child { color: #dcdcdc; }
.value-item:active .value-time { color: #bdbdbd; }
.value-item:active .value-icon canvas { filter: invert(1); }
.value-item h3 { font-size: 15px; }
.value-time {
  font-size: 12px;
  color: var(--mid);
  letter-spacing: 0.08em;
  margin: 2px 0 8px;
}
.value-item p:last-child { font-size: 12.5px; line-height: 1.8; color: #444; }
.value-icon {
  width: 44px; height: 44px;
  margin: 0 auto 10px;
}

/* ----------------------------------------------------------------
   04. 会員限定コンテンツ — Infinite Carousel
---------------------------------------------------------------- */
.carousel { margin-top: 8px; overflow: hidden; }
.carousel-track {
  display: flex;
  gap: 14px;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scrollbar-width: none;
  padding: 6px calc(50% - min(78vw, 420px) / 2) 10px;
  -webkit-overflow-scrolling: touch;
}
.carousel-track::-webkit-scrollbar { display: none; }
.content-card {
  flex: 0 0 min(78vw, 420px);
  scroll-snap-align: center;
  border: 2px solid var(--ink);
  background: var(--paper);
  padding: 26px 22px 28px;
  box-shadow: 4px 4px 0 var(--light);
}
.card-tag {
  display: inline-block;
  font-size: 11px;
  letter-spacing: 0.2em;
  border: 1px solid var(--ink);
  padding: 3px 10px;
  margin-bottom: 14px;
}
.content-card h3 { margin-bottom: 8px; font-size: 18px; }
.content-card p:last-child { font-size: 13.5px; color: #444; }
.content-card.is-soon { background: var(--faint); }
.content-card.is-soon .card-tag { color: var(--mid); border-color: var(--mid); }
.carousel-dots {
  display: flex;
  justify-content: center;
  gap: 8px;
  margin-top: 18px;
}
.carousel-dots span {
  width: 8px; height: 8px;
  background: var(--light);
  transition: background 0.25s ease;
}
.carousel-dots span.is-active { background: var(--ink); }

/* ----------------------------------------------------------------
   05. 料金
---------------------------------------------------------------- */
.price-card {
  border: 2px solid var(--ink);
  background: var(--paper);
  box-shadow: 6px 6px 0 var(--light);
  padding: 30px 24px 28px;
  text-align: center;
}
.price-plan {
  font-size: 13px;
  letter-spacing: 0.14em;
  border-bottom: 2px solid var(--ink);
  padding-bottom: 14px;
  margin-bottom: 18px;
}
.price-amount { line-height: 1; margin-bottom: 22px; }
.price-yen { font-size: 28px; vertical-align: 18px; margin-right: 2px; }
.price-num { font-size: 76px; letter-spacing: 0.02em; }
.price-unit { font-size: 13px; color: var(--mid); margin-left: 6px; }
.price-includes {
  list-style: none;
  text-align: left;
  max-width: 340px;
  margin: 0 auto 26px;
  font-size: 13.5px;
}
.price-includes li {
  padding: 9px 2px 9px 26px;
  border-bottom: 1px solid var(--light);
  position: relative;
}
.price-includes li::before {
  content: '';
  position: absolute;
  left: 4px; top: 50%;
  width: 8px; height: 8px;
  transform: translateY(-50%);
  background: var(--ink);
}
.price-note {
  font-size: 11.5px;
  color: var(--mid);
  text-align: left;
  margin-top: 18px;
  line-height: 1.8;
}

/* ----------------------------------------------------------------
   06. 1週間 — タイムライン
---------------------------------------------------------------- */
.week-tabs {
  display: flex;
  gap: 10px;
  margin-bottom: 30px;
}
.week-tab {
  flex: 1;
  font-size: 15px;
  padding: 12px 0;
  background: var(--paper);
  border: 2px solid var(--ink);
  color: var(--ink);
  cursor: pointer;
  box-shadow: 3px 3px 0 var(--light);
  transition: background 0.2s ease, color 0.2s ease;
}
.week-tab.is-active { background: var(--ink); color: var(--paper); }
.timeline { position: relative; padding-left: 8px; }
.timeline.is-hidden { display: none; }
.tl-item {
  position: relative;
  display: grid;
  grid-template-columns: 64px 1fr;
  gap: 16px;
  padding: 0 0 34px 0;
}
.tl-item::before {
  content: '';
  position: absolute;
  left: 76px;
  top: 8px;
  bottom: -4px;
  width: 2px;
  background-image: linear-gradient(to bottom, var(--ink) 50%, transparent 50%);
  background-size: 2px 8px;
}
.tl-item:last-child::before { display: none; }
.tl-item .tl-body { padding-left: 24px; }
.tl-time {
  font-size: 14px;
  text-align: right;
  padding-top: 2px;
  letter-spacing: 0.04em;
}
.tl-body::before {
  content: '';
  position: absolute;
  left: 72px;
  top: 6px;
  width: 10px; height: 10px;
  background: var(--paper);
  border: 2px solid var(--ink);
}
.tl-body h3 { margin-bottom: 4px; font-size: 15px; }
.tl-body p { font-size: 13.5px; color: #444; }

/* ----------------------------------------------------------------
   07. 代表紹介 — 夜の海
---------------------------------------------------------------- */
.section-night { background: var(--ink); color: var(--paper); position: relative; }
/* 夜 → 白ページへのディザ橋（市松） */
.section-night::after {
  content: '';
  position: absolute;
  left: 0; right: 0;
  bottom: -12px;
  height: 12px;
  background-image: conic-gradient(var(--ink) 25%, transparent 0 50%, var(--ink) 0 75%, transparent 0);
  background-size: 6px 6px;
  pointer-events: none;
}
.section-night .sec-label { color: #9a9a9a; }
.founder-card { margin-top: 8px; }
.founder-photo {
  width: 168px;
  margin-bottom: 22px;
  border: 2px solid var(--paper);
  box-shadow: 5px 5px 0 rgba(255,255,255,0.22);
}
.founder-name { font-size: 19px; font-weight: 700; }
.founder-kana { font-size: 12px; font-weight: 400; color: #9a9a9a; margin-left: 8px; }
.founder-title {
  font-size: 12.5px;
  color: #bdbdbd;
  margin: 6px 0 18px;
  line-height: 1.8;
}
.founder-story { font-size: 14px; color: #e8e8e8; }

/* ----------------------------------------------------------------
   08. 手厚いサポート
---------------------------------------------------------------- */
.support-list { display: grid; gap: 14px; }
.support-item {
  display: flex;
  align-items: center;
  gap: 16px;
  position: relative;
  border: 2px solid var(--ink);
  background: var(--paper);
  box-shadow: 4px 4px 0 var(--light);
  padding: 18px 18px;
  text-decoration: none;
  transition: background 0.15s ease, transform 0.15s ease, box-shadow 0.15s ease;
  -webkit-tap-highlight-color: transparent;
}
@media (hover: hover) {
  .support-item:hover { transform: translate(-1px, -1px); box-shadow: 6px 6px 0 var(--light); }
}
.support-item h3 { font-size: 15.5px; margin-bottom: 4px; }
.support-item p { font-size: 13px; color: #444; }
.support-item:active { background: var(--ink); }
.support-item:active h3 { color: var(--paper); }
.support-item:active p { color: #dcdcdc; }
.support-item:active .char-pixel canvas { filter: invert(1); }
.char-pixel { flex-shrink: 0; }
.char-pixel canvas { width: 44px; height: auto; display: block; image-rendering: pixelated; }

/* ----------------------------------------------------------------
   09. FAQ — アコーディオン
---------------------------------------------------------------- */
.faq-list { border-top: 2px solid var(--ink); }
.faq-item { border-bottom: 2px solid var(--ink); }
.faq-q {
  width: 100%;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  background: none;
  border: none;
  font-family: var(--font-body);
  font-size: 14.5px;
  font-weight: 700;
  color: var(--ink);
  text-align: left;
  padding: 18px 4px;
  cursor: pointer;
  line-height: 1.7;
}
.faq-icon {
  flex-shrink: 0;
  font-size: 20px;
  transition: transform 0.3s ease;
}
.faq-item.is-open .faq-icon { transform: rotate(45deg); }
.faq-a {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.35s ease;
}
.faq-a p {
  padding: 0 4px 20px;
  font-size: 13.5px;
  color: #444;
}

/* ----------------------------------------------------------------
   10. ゴール — 朝焼け
---------------------------------------------------------------- */
.section-goal { padding-bottom: 90px; text-align: center; }
.section-goal .sec-lead { margin-bottom: 30px; }
/* 出航のひとことは案内文。灰色だと読み飛ばされるので黒で置く */
.goal-cta .hero-note { animation: none; opacity: 1; margin-top: 16px; color: var(--ink); }

/* ----------------------------------------------------------------
   フッター（黒地・白文字）
---------------------------------------------------------------- */
.site-footer {
  position: relative;
  background: var(--ink);
  color: var(--paper);
  text-align: center;
  padding: 52px 24px calc(44px + 74px);
  margin-top: 12px;
}
/* 白ページ → 黒フッターへのディザ橋（市松） */
.site-footer::before {
  content: '';
  position: absolute;
  left: 0; right: 0;
  top: -12px;
  height: 12px;
  background-image: conic-gradient(var(--ink) 25%, transparent 0 50%, var(--ink) 0 75%, transparent 0);
  background-size: 6px 6px;
  pointer-events: none;
}
.footer-brand {
  justify-content: center;
  margin-bottom: 24px;
}
.footer-brand .logo-mark { height: 30px; }
.footer-brand .logo-text { font-size: 23px; }
.footer-sns {
  display: flex;
  justify-content: center;
  gap: 26px;
  margin-bottom: 26px;
}
.sns-pixel { display: inline-block; opacity: 0.92; transition: opacity 0.2s ease, transform 0.15s ease; }
.sns-pixel canvas { width: 26px; height: auto; display: block; }
@media (hover: hover) {
  .sns-pixel:hover { opacity: 1; transform: translateY(-2px); }
}
.footer-nav {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 8px 20px;
  font-size: 12.5px;
  margin-bottom: 16px;
}
.footer-nav a { color: #cfcfcf; text-decoration: none; }
.footer-nav a:hover { text-decoration: underline; }
.footer-copy { font-size: 11.5px; color: #9a9a9a; line-height: 2; margin-top: 10px; }

/* ----------------------------------------------------------------
   固定CTA
---------------------------------------------------------------- */
.fixed-cta {
  position: fixed;
  left: 0; right: 0;
  bottom: 0;
  z-index: 90;
  padding: 10px 16px calc(10px + env(safe-area-inset-bottom));
  background: rgba(255,255,255,0.92);
  -webkit-backdrop-filter: blur(6px);
  backdrop-filter: blur(6px);
  border-top: 1px solid var(--light);
  transform: translateY(110%);
  transition: transform 0.4s cubic-bezier(0.22, 1, 0.36, 1);
}
.fixed-cta.is-shown { transform: translateY(0); }
.fixed-cta .btn-cta {
  display: block;
  max-width: 480px;
  margin: 0 auto;
  padding: 11px 20px;
  box-shadow: 3px 3px 0 rgba(26,26,26,0.18);
}
.fixed-cta-sub {
  display: block;
  font-size: 10.5px;
  font-family: var(--font-body);
  opacity: 0.75;
  margin-top: 2px;
}

/* ----------------------------------------------------------------
   デスクトップ微調整
---------------------------------------------------------------- */
@media (min-width: 720px) {
  body { font-size: 16px; }
  .section { padding-bottom: 140px; }
  .section-body { padding-top: 56px; }
  .scene { max-width: 720px; margin: 0 auto; }
  .value-grid { gap: 18px; }
  .content-card { flex-basis: 400px; }
  .carousel-track { padding-left: calc(50% - 200px); padding-right: calc(50% - 200px); }
  .founder-card {
    display: grid;
    grid-template-columns: 200px 1fr;
    gap: 32px;
    align-items: start;
  }
  .founder-photo { width: 100%; margin-bottom: 0; }
}

/* ----------------------------------------------------------------
   Reduced motion
---------------------------------------------------------------- */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .reveal { opacity: 1; transform: none; transition: none; }
  .hero-eyebrow, .hero-title, .hero-lead, .hero-inner .btn-cta, .hero-note, .scroll-hint {
    animation: none; opacity: 1;
  }
  .scroll-hint { animation: none; }
}
