@import url("https://fonts.googleapis.com/css2?family=Zen+Kaku+Gothic+New:wght@500;700&family=Noto+Sans+JP:wght@400;500;700&family=JetBrains+Mono:wght@400;700&display=swap");

/* =========================================================
   COTTY SHINDAN — design tokens (案A: パステル診断カルテ・進化版)
   palette   : 紙 #FFF8F2 / インク #2B2622 / ライン #E8DFD3
   accent    : --accent はタイプ別に1色（result.htmlで上書き）/ --accent-soft は全タイプ共通の暖色
   type      : 見出し = Zen Kaku Gothic New / 本文 = Noto Sans JP / データ表記 = monospace
   signature : 円形バッジ＋パルスリング、ピル型ゲージのデュオトーン、フェードインモーション
   ========================================================= */

:root {
  --paper: #FFF8F2;
  --panel: #FBF3E8;
  --ink: #2B2622;
  --mute: #9B948C;
  --line: #E8DFD3;
  --accent: #8B5FBF;
  --accent-soft: #F2966B;
  --accent-text: var(--accent);
  --accent-ink: #FFFFFF;

  --font-display: "Zen Kaku Gothic New", "Noto Sans JP", sans-serif;
  --font-body: "Noto Sans JP", "Hiragino Sans", sans-serif;
  --font-mono: "JetBrains Mono", "Courier New", monospace;

  --max-w: 760px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--font-body);
  line-height: 1.8;
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; display: block; }
a { color: inherit; }

.wrap {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 0 24px;
}

@keyframes fadeUp {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: translateY(0); }
}

/* ---------- header ---------- */
.site-header {
  border-bottom: 1px solid var(--line);
  background: rgba(255, 248, 242, 0.92);
  backdrop-filter: blur(6px);
  position: sticky;
  top: 0;
  z-index: 10;
}
.site-header .wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 64px;
}
.logo {
  font-family: var(--font-mono);
  font-size: 14px;
  letter-spacing: 0.1em;
  text-decoration: none;
  color: var(--ink);
}
.logo b { font-weight: 700; color: var(--accent); }
.nav { display: flex; gap: 22px; }
.nav a {
  font-size: 13px;
  text-decoration: none;
  color: var(--mute);
  letter-spacing: 0.02em;
}
.nav a:hover { color: var(--ink); }

/* ---------- footer ---------- */
.site-footer {
  border-top: 1px solid var(--line);
  margin-top: 96px;
  padding: 40px 0 56px;
  color: var(--mute);
  font-size: 13px;
}
.site-footer .wrap {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  justify-content: space-between;
  align-items: center;
}
.site-footer nav { display: flex; gap: 18px; flex-wrap: wrap; }
.site-footer a { text-decoration: none; color: var(--mute); }
.site-footer a:hover { color: var(--ink); }

/* ---------- hero ---------- */
.hero {
  padding: 72px 0 56px;
  border-bottom: 1px solid var(--line);
}
.hero .eyebrow {
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.14em;
  color: var(--accent);
  text-transform: uppercase;
  margin: 0 0 18px;
}
.hero h1 {
  font-family: var(--font-display);
  font-size: clamp(28px, 5vw, 42px);
  line-height: 1.48;
  margin: 0 0 20px;
  font-weight: 700;
}
.hero p.lead {
  color: var(--mute);
  font-size: 16px;
  max-width: 520px;
  margin: 0 0 32px;
}

/* ---------- buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-mono);
  font-size: 14px;
  letter-spacing: 0.02em;
  text-decoration: none;
  padding: 14px 28px;
  border-radius: 999px;
  border: 1.5px solid var(--ink);
  color: var(--ink);
  background: transparent;
  cursor: pointer;
  transition: background 0.15s ease, color 0.15s ease, transform 0.1s ease;
}
.btn:hover { background: var(--ink); color: var(--paper); }
.btn:active { transform: scale(0.98); }
.btn-stamp {
  border-color: var(--accent);
  background: var(--accent);
  color: var(--accent-ink);
}
.btn-stamp:hover {
  background: var(--accent);
  filter: brightness(0.93);
  color: var(--accent-ink);
}
.btn-block { width: 100%; justify-content: center; }

/* ---------- section blocks shared by report-style pages ---------- */
.block {
  padding: 40px 0;
  border-bottom: 1px solid var(--line);
  animation: fadeUp 0.5s ease both;
}
.block .label {
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.08em;
  color: var(--accent-text);
  margin: 0 0 14px;
  text-transform: uppercase;
}
.block h2 {
  font-family: var(--font-display);
  font-size: 20px;
  margin: 0 0 14px;
}
.block p { margin: 0 0 12px; }

/* =========================================================
   QUIZ (やわらかい回答シート)
   ========================================================= */
.quiz-shell {
  padding-top: 56px;
  padding-bottom: 96px;
}
.quiz-progress {
  display: flex;
  align-items: center;
  gap: 14px;
  font-family: var(--font-mono);
  font-size: 13px;
  color: var(--mute);
  margin-bottom: 28px;
}
.quiz-progress .bar {
  flex: 1;
  height: 4px;
  border-radius: 999px;
  background: var(--panel);
  position: relative;
  overflow: hidden;
}
.quiz-progress .bar i {
  position: absolute;
  left: 0; top: 0; bottom: 0;
  border-radius: 999px;
  background: linear-gradient(90deg, var(--accent-soft), var(--accent));
  width: 0%;
  transition: width 0.3s ease;
}
.quiz-card {
  border: 1px solid var(--line);
  background: var(--panel);
  padding: 40px 32px;
  border-radius: 22px;
}
.quiz-card.enter { animation: fadeUp 0.4s ease; }
.quiz-card .qno {
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--accent);
  letter-spacing: 0.08em;
  margin: 0 0 16px;
}
.quiz-card h2 {
  font-family: var(--font-display);
  font-size: 22px;
  line-height: 1.6;
  margin: 0 0 28px;
}
.choices { display: flex; flex-direction: column; gap: 12px; }
.choice {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 16px 18px;
  border: 1px solid var(--line);
  background: var(--paper);
  text-align: left;
  font-size: 15px;
  border-radius: 14px;
  cursor: pointer;
  font-family: var(--font-body);
  color: var(--ink);
  transition: border-color 0.15s ease, transform 0.1s ease;
}
.choice:hover { border-color: var(--accent); transform: translateY(-1px); }
.choice .tag {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: var(--accent-soft);
  color: #fff;
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.quiz-nav { margin-top: 20px; }
.quiz-nav button {
  background: none;
  border: none;
  font-family: var(--font-mono);
  font-size: 13px;
  color: var(--mute);
  cursor: pointer;
}
.quiz-nav button:hover { color: var(--accent); }

/* =========================================================
   RESULT (診断書 / カルテ）
   ========================================================= */
.report {
  padding-top: 56px;
}
.report-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 24px;
  border-bottom: 1px solid var(--line);
  padding-bottom: 32px;
  margin-bottom: 8px;
  animation: fadeUp 0.5s ease both;
}
.report-head .meta .label {
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--accent-text);
  letter-spacing: 0.12em;
  margin: 0 0 10px;
}
.report-head h1 {
  font-family: var(--font-display);
  font-size: clamp(26px, 4.5vw, 36px);
  margin: 0 0 6px;
}
.report-head .nickname {
  color: var(--mute);
  font-size: 15px;
}

/* badge (旧スタンプ) */
.stamp {
  flex-shrink: 0;
  width: 88px;
  height: 88px;
  border-radius: 50%;
  background: radial-gradient(circle at 35% 30%, var(--accent-soft), var(--accent));
  color: var(--accent-ink);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-mono);
  font-weight: 700;
  font-size: 14px;
  letter-spacing: 0.02em;
  position: relative;
  box-shadow: 0 6px 18px rgba(43, 38, 34, 0.12);
}
.stamp::after {
  content: "";
  position: absolute;
  inset: -6px;
  border-radius: 50%;
  border: 1.5px solid var(--accent);
  opacity: 0.55;
  animation: ringPulse 2.6s ease-out infinite;
}
@keyframes ringPulse {
  0% { transform: scale(0.92); opacity: 0.5; }
  100% { transform: scale(1.28); opacity: 0; }
}

/* axis gauges */
.gauges {
  padding: 32px 0;
  border-bottom: 1px solid var(--line);
  animation: fadeUp 0.5s ease both;
  animation-delay: 0.08s;
}
.gauge { margin-bottom: 18px; }
.gauge:last-child { margin-bottom: 0; }
.gauge-labels {
  display: flex;
  justify-content: space-between;
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--mute);
  margin-bottom: 6px;
}
.gauge-labels .side.active { color: var(--accent-text); font-weight: 700; }
.gauge-track {
  height: 10px;
  border-radius: 999px;
  background: var(--panel);
  border: none;
  position: relative;
  overflow: hidden;
}
.gauge-fill {
  position: absolute;
  top: 0; bottom: 0;
  border-radius: 999px;
  background: linear-gradient(90deg, var(--accent-soft), var(--accent));
}
.gauge-pct {
  text-align: right;
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--mute);
  margin-top: 4px;
}

.cta-panel {
  margin: 48px 0 64px;
  padding: 36px 32px;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 20px;
  text-align: center;
  animation: fadeUp 0.5s ease both;
  animation-delay: 0.16s;
}
.cta-panel .label {
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--accent-text);
  letter-spacing: 0.08em;
  margin: 0 0 12px;
}
.cta-panel p { color: var(--mute); margin: 0 0 24px; font-size: 14px; }

.share-row {
  display: flex;
  gap: 10px;
  justify-content: center;
  margin-top: 18px;
}

.type-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 8px;
  margin-top: 16px;
}
.type-grid a {
  display: block;
  text-align: center;
  padding: 10px 4px;
  border: 1px solid var(--line);
  border-radius: 10px;
  font-family: var(--font-mono);
  font-size: 12px;
  text-decoration: none;
  color: var(--mute);
}
.type-grid a:hover { border-color: var(--accent); color: var(--accent-text); }
.type-grid a.current { border-color: var(--accent); background: var(--panel); color: var(--accent-text); font-weight: 700; }

@media (max-width: 560px) {
  .type-grid { grid-template-columns: repeat(2, 1fr); }
  .report-head { flex-direction: column; }
}

/* ---------- blog list ---------- */
.post-list { list-style: none; padding: 0; margin: 0; }
.post-list li {
  border-bottom: 1px solid var(--line);
  padding: 22px 0;
}
.post-list a { text-decoration: none; }
.post-list .date {
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--accent-text);
}
.post-list h3 { margin: 6px 0 0; font-family: var(--font-display); font-size: 17px; }

/* ---------- simple page ---------- */
.page { padding-top: 56px; padding-bottom: 80px; }
.page h1 { font-family: var(--font-display); font-size: 28px; margin: 0 0 28px; }
.page h2 { font-family: var(--font-display); font-size: 18px; margin: 32px 0 12px; }
.page table { width: 100%; border-collapse: collapse; font-size: 14px; }
.page table th, .page table td {
  border-bottom: 1px solid var(--line);
  padding: 10px 8px;
  text-align: left;
  vertical-align: top;
}

/* ---------- contact form ---------- */
.form-banner {
  padding: 14px 18px;
  border: 1px solid var(--line);
  border-radius: 12px;
  margin-bottom: 28px;
  font-size: 14px;
  display: none;
}
.form-banner.show { display: block; }
.form-banner.success { border-color: var(--accent); color: var(--accent); }
.form-banner.error { border-color: #C2705B; color: #C2705B; }

.contact-form { margin-top: 8px; }
.form-field { margin-bottom: 22px; }
.form-field label {
  display: block;
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.04em;
  color: var(--mute);
  margin-bottom: 8px;
}
.form-field input,
.form-field textarea {
  width: 100%;
  padding: 13px 14px;
  border: 1px solid var(--line);
  background: var(--paper);
  font-family: var(--font-body);
  font-size: 15px;
  color: var(--ink);
  border-radius: 12px;
}
.form-field input:focus,
.form-field textarea:focus {
  outline: 2px solid var(--accent);
  outline-offset: 1px;
  border-color: var(--accent);
}
.form-field textarea { resize: vertical; }

.hp-field {
  position: absolute;
  left: -9999px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

.note {
  font-size: 12px;
  color: var(--mute);
  border-left: 2px solid var(--accent-soft);
  padding-left: 14px;
  margin: 24px 0;
}
