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

body {
  font-family: 'Hiragino Sans', 'Hiragino Kaku Gothic ProN', 'Noto Sans JP', sans-serif;
  background: linear-gradient(135deg, #1a0000 0%, #3d0000 50%, #1a0000 100%);
  min-height: 100vh;
  color: #fff;
  padding: 20px;
}

.container {
  max-width: 600px;
  margin: 0 auto;
  padding-bottom: 60px;
}

header {
  text-align: center;
  padding: 40px 0 30px;
}

.fire {
  font-size: 60px;
  animation: flicker 1.5s infinite alternate;
}

@keyframes flicker {
  0% { transform: scale(1) rotate(-2deg); }
  100% { transform: scale(1.1) rotate(2deg); }
}

h1 {
  font-size: 2rem;
  font-weight: 900;
  line-height: 1.3;
  margin: 12px 0 8px;
  text-shadow: 0 0 20px rgba(255, 100, 0, 0.8);
  color: #ff6b00;
}

.subtitle {
  font-size: 0.9rem;
  color: #ccc;
  margin-top: 8px;
}

.quiz {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.question {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 100, 0, 0.3);
  border-radius: 12px;
  padding: 20px;
}

.q-label {
  font-weight: 700;
  font-size: 1rem;
  margin-bottom: 14px;
  color: #ff9944;
}

.options {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.options label {
  display: flex;
  align-items: center;
  gap: 10px;
  cursor: pointer;
  padding: 10px 14px;
  border-radius: 8px;
  border: 1px solid transparent;
  transition: all 0.2s;
  font-size: 0.95rem;
}

.options label:hover {
  background: rgba(255, 100, 0, 0.15);
  border-color: rgba(255, 100, 0, 0.4);
}

.options input[type="radio"] {
  accent-color: #ff6b00;
  width: 18px;
  height: 18px;
  flex-shrink: 0;
}

.options input[type="radio"]:checked + * {
  color: #ff9944;
}

.options label:has(input:checked) {
  background: rgba(255, 100, 0, 0.2);
  border-color: #ff6b00;
}

.submit-btn {
  margin-top: 10px;
  width: 100%;
  padding: 18px;
  font-size: 1.1rem;
  font-weight: 700;
  background: linear-gradient(135deg, #ff4400, #ff8800);
  color: white;
  border: none;
  border-radius: 12px;
  cursor: pointer;
  transition: all 0.2s;
  box-shadow: 0 4px 20px rgba(255, 68, 0, 0.4);
}

.submit-btn:hover:not(:disabled) {
  transform: translateY(-2px);
  box-shadow: 0 6px 24px rgba(255, 68, 0, 0.6);
}

.submit-btn:disabled {
  opacity: 0.4;
  cursor: not-allowed;
}

.hidden {
  display: none !important;
}

.result {
  margin-top: 30px;
}

.loading {
  text-align: center;
  padding: 40px;
}

.spinner {
  width: 50px;
  height: 50px;
  border: 4px solid rgba(255, 100, 0, 0.2);
  border-top-color: #ff6b00;
  border-radius: 50%;
  margin: 0 auto 20px;
  animation: spin 1s linear infinite;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

.result-content {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.hell-meter {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 100, 0, 0.5);
  border-radius: 16px;
  padding: 30px;
  text-align: center;
}

.hell-label {
  font-size: 0.9rem;
  color: #ccc;
  margin-bottom: 8px;
}

.hell-score {
  font-size: 4rem;
  font-weight: 900;
  color: #ff4400;
  text-shadow: 0 0 30px rgba(255, 68, 0, 0.8);
}

.hell-name {
  font-size: 1.5rem;
  font-weight: 700;
  color: #ff9944;
  margin-top: 8px;
}

.diagnosis-text {
  background: rgba(255, 255, 255, 0.05);
  border-left: 4px solid #ff6b00;
  border-radius: 0 12px 12px 0;
  padding: 20px;
  font-size: 0.95rem;
  line-height: 1.8;
  color: #eee;
  white-space: pre-wrap;
}

.share-area {
  text-align: center;
}

.share-label {
  font-size: 0.85rem;
  color: #ccc;
  margin-bottom: 12px;
}

.screenshot-hint {
  font-size: 0.85rem;
  color: #ff9944;
  margin-bottom: 12px;
}

.tweet-btn {
  display: inline-block;
  padding: 14px 32px;
  background: #000;
  color: #fff;
  border: 1px solid #555;
  border-radius: 30px;
  text-decoration: none;
  font-weight: 700;
  font-size: 1rem;
  transition: all 0.2s;
}

.tweet-btn:hover {
  background: #222;
  transform: translateY(-2px);
}

.made-with {
  text-align: center;
  padding: 16px;
  background: rgba(255, 255, 255, 0.03);
  border-radius: 8px;
  font-size: 0.85rem;
  color: #aaa;
}

.note-link {
  color: #41c9b4;
  text-decoration: none;
}

.note-link:hover {
  text-decoration: underline;
}

.retry-btn {
  width: 100%;
  padding: 14px;
  background: transparent;
  color: #ccc;
  border: 1px solid #555;
  border-radius: 12px;
  cursor: pointer;
  font-size: 0.95rem;
  transition: all 0.2s;
}

.retry-btn:hover {
  background: rgba(255, 255, 255, 0.05);
  color: #fff;
}

.free-text-wrap {
  display: none;
  margin-top: 10px;
}

.free-text-wrap.visible {
  display: block;
}

.free-text-wrap textarea {
  width: 100%;
  min-height: 80px;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 100, 0, 0.4);
  border-radius: 8px;
  color: #fff;
  font-size: 0.9rem;
  padding: 10px 12px;
  resize: vertical;
  font-family: inherit;
  line-height: 1.6;
}

.free-text-wrap textarea::placeholder {
  color: rgba(255, 255, 255, 0.4);
}

.free-text-wrap textarea:focus {
  outline: none;
  border-color: #ff6b00;
  background: rgba(255, 255, 255, 0.12);
}

@media (max-width: 480px) {
  h1 { font-size: 1.6rem; }
  .hell-score { font-size: 3rem; }
  .question { padding: 16px; }
}
