:root {
  --bg1: #1a2a6c;
  --bg2: #2a5298;
  --card: #ffffff;
  --ink: #1f2430;
  --muted: #6b7280;
  --accent: #ff7a59;
  --accent-d: #f15a35;
  --chip: #eef2ff;
  --chip-ink: #4254c5;
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
  min-height: 100%;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Hiragino Kaku Gothic ProN",
    "Noto Sans JP", Meiryo, sans-serif;
  color: var(--ink);
  background: linear-gradient(135deg, var(--bg1), var(--bg2));
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px 16px;
}

.card {
  width: 100%;
  max-width: 480px;
  background: var(--card);
  border-radius: 22px;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.28);
  padding: 28px 24px 22px;
}

.head {
  text-align: center;
  margin-bottom: 18px;
}

.title {
  margin: 0;
  font-size: 1.5rem;
  letter-spacing: 0.02em;
}

.subtitle {
  margin: 6px 0 0;
  color: var(--muted);
  font-size: 0.9rem;
}

.stage {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.topic {
  background: #f7f8fc;
  border: 1px solid #eceefb;
  border-radius: 16px;
  padding: 20px 18px;
  min-height: 150px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.cat {
  align-self: flex-start;
  background: var(--chip);
  color: var(--chip-ink);
  font-size: 0.75rem;
  font-weight: 700;
  padding: 4px 12px;
  border-radius: 999px;
}

.topic-title {
  margin: 0;
  font-size: 1.25rem;
  line-height: 1.4;
}

.topic-desc {
  margin: 0;
  color: #3c4250;
  font-size: 0.98rem;
  line-height: 1.7;
}

.actions {
  display: flex;
  gap: 10px;
}

.spark-btn {
  flex: 1;
  border: none;
  cursor: pointer;
  font-size: 1.05rem;
  font-weight: 700;
  color: #fff;
  background: linear-gradient(135deg, var(--accent), var(--accent-d));
  padding: 14px 16px;
  border-radius: 14px;
  box-shadow: 0 8px 18px rgba(241, 90, 53, 0.35);
  transition: transform 0.08s ease, box-shadow 0.2s ease;
}

.spark-btn:hover { box-shadow: 0 10px 22px rgba(241, 90, 53, 0.45); }
.spark-btn:active { transform: translateY(2px) scale(0.99); }

.ghost-btn {
  border: 1.5px solid #d7dbe6;
  background: #fff;
  color: #4b5160;
  cursor: pointer;
  font-size: 0.95rem;
  font-weight: 600;
  padding: 14px 16px;
  border-radius: 14px;
  transition: background 0.15s ease, border-color 0.15s ease;
}

.ghost-btn:hover { background: #f2f4fa; border-color: #c3c9d8; }
.ghost-btn:active { transform: translateY(1px); }

.hint {
  margin: 2px 0 0;
  text-align: center;
  color: var(--muted);
  font-size: 0.82rem;
  min-height: 1.2em;
}

.foot {
  margin-top: 18px;
  text-align: center;
  color: #9aa1b1;
  font-size: 0.74rem;
}

@keyframes pop {
  0% { opacity: 0; transform: translateY(8px) scale(0.99); }
  100% { opacity: 1; transform: translateY(0) scale(1); }
}

.topic.pop {
  animation: pop 0.28s ease;
}

@media (max-width: 380px) {
  .actions { flex-direction: column; }
}
