:root {
    /* カラーパレットの再定義 */
    --bg-color: #fffef0; /* 非常に明るいクリームイエロー */
    --card-bg: #fefdf0; /* カード背景：少しクリームがかった白 */
    --text-main: #ef6c00; /* メインカラー：濃いオレンジ (見出し、プログレスバー、ボタン) */
    --text-sub: #795548; /* サブテキスト：暖かみのあるブラウン系グレー */
    --red: #ff7043; /* リッカート「全く違う」：コーラルレッド */
    --gray: #d7ccc8; /* リッカート「中立」：暖かみのあるグレー */
    --green: #8bc34a; /* リッカート「非常にそう思う」：柔らかい黄緑 */
}

body {
    margin: 0;
    padding: 0;
    font-family: 'Helvetica Neue', Arial, 'Hiragino Kaku Gothic ProN', 'Hiragino Sans', Meiryo, sans-serif;
    background-color: var(--bg-color);
    color: var(--text-sub); /* デフォルトのテキスト色をブラウン系へ */
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
}

.container {
    width: 100%;
    max-width: 600px;
    padding: 20px;
}

.card {
    background-color: var(--card-bg);
    border-radius: 16px;
    padding: 40px 30px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.05); /* シャドウを柔らかく */
    text-align: center;
    animation: fadeIn 0.5s ease-out;
    border: 1px solid rgba(0, 0, 0, 0.03); /* ほのかなボーダーを追加 */
}

.hidden {
    display: none !important;
}

.progress-bar {
    width: 100%;
    height: 6px;
    background-color: rgba(239, 108, 0, 0.1); /* オレンジ系の薄い背景 */
    border-radius: 3px;
    margin-bottom: 20px;
    overflow: hidden;
}

#progress {
    height: 100%;
    background-color: var(--text-main); /* プログレスバーの色：オレンジ */
    width: 0%;
    transition: width 0.3s ease;
}

#question-number {
    color: var(--text-main); /* オレンジ */
    font-size: 0.9rem;
    font-weight: bold;
    letter-spacing: 2px;
}

#question-text {
    font-size: 1.4rem;
    margin: 30px 0 40px;
    line-height: 1.5;
    color: var(--text-sub); /* ブラウン系グレー */
}

/* リッカート尺度のUI */
.likert-container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 40px;
}

.likert-label {
    font-size: 0.8rem;
    color: var(--text-sub); /* ブラウン系グレー */
    white-space: nowrap;
}

.likert-options {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-grow: 1;
    margin: 0 15px;
}

.likert-option {
    cursor: pointer;
    position: relative;
}

.likert-option input {
    display: none; /* デフォルトのラジオボタンを隠す */
}

.circle {
    display: block;
    border-radius: 50%;
    border: 2px solid;
    transition: all 0.2s ease;
}

/* 丸のサイズ (変更なし) */
.size-l { width: 40px; height: 40px; }
.size-m { width: 30px; height: 30px; }
.size-s { width: 22px; height: 22px; }
.size-xs { width: 16px; height: 16px; }

/* 丸の色 */
.color-red { border-color: var(--red); } /* コーラルレッド */
.color-gray { border-color: var(--gray); } /* 暖かみのあるグレー */
.color-green { border-color: var(--green); } /* 柔らかい黄緑 */

/* ホバー時のスタイル */
.likert-option:hover .circle {
    opacity: 0.7;
}

/* 選択時の色とシャドウ */
.likert-option input:checked + .color-red { background-color: var(--red); box-shadow: 0 0 15px rgba(255, 112, 67, 0.4); }
.likert-option input:checked + .color-gray { background-color: var(--gray); box-shadow: 0 0 15px rgba(215, 204, 200, 0.4); }
.likert-option input:checked + .color-green { background-color: var(--green); box-shadow: 0 0 15px rgba(139, 195, 74, 0.4); }


/* ボタンUI */
button {
    background-color: var(--text-main); /* オレンジ */
    color: #fff;
    border: none;
    padding: 15px 40px;
    font-size: 1.1rem;
    border-radius: 30px;
    cursor: pointer;
    font-weight: bold;
    transition: all 0.3s ease;
    width: 100%;
    max-width: 300px;
}

button:disabled {
    background-color: #d7ccc8; /* 無効時は暖かみのあるグレー */
    color: #fff;
    cursor: not-allowed;
}

button:not(:disabled):hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(239, 108, 0, 0.3);
}

/* 結果画面特有のスタイル */
#result-title {
    font-size: 3rem;
    color: var(--text-main); /* オレンジ */
    margin: 10px 0;
    letter-spacing: 5px;
}

#result-subtitle {
    font-size: 1.2rem;
    color: var(--text-sub); /* ブラウン系グレー */
    margin-bottom: 20px;
}

#result-desc {
    color: var(--text-sub); /* ブラウン系グレー */
    line-height: 1.6;
    margin-bottom: 30px;
}

/* 再試行ボタン */
#retry-btn {
    background-color: var(--text-main); /* オレンジ */
    color: #fff;
}

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