/* ダイエット・メディカルダイエット診断ウィジェット
   清潔感のあるミントグリーン × ソフトブルー基調 */

.diet-med-diagnosis-widget,
.dmdw-container {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Hiragino Sans", "Hiragino Kaku Gothic ProN", Meiryo, sans-serif;
    font-size: 14px;
    line-height: 1.5;
    color: #2c3e50;
    max-width: 100%;
    box-sizing: border-box;
}

.dmdw-container * {
    box-sizing: border-box;
}

.dmdw-step {
    display: none;
    animation: dmdw-fade 0.25s ease;
}

.dmdw-step.active {
    display: block;
}

@keyframes dmdw-fade {
    from { opacity: 0; transform: translateY(6px); }
    to   { opacity: 1; transform: translateY(0); }
}

.dmdw-question {
    font-weight: 600;
    font-size: 15px;
    margin: 0 0 12px;
    color: #1a5f7a;
    padding-bottom: 8px;
    border-bottom: 2px solid #a8e6cf;
}

.dmdw-options {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-bottom: 16px;
}

.dmdw-option {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    padding: 10px 12px;
    background: #f7fcfa;
    border: 1px solid #d4efe6;
    border-radius: 8px;
    cursor: pointer;
    transition: background 0.2s, border-color 0.2s, box-shadow 0.2s;
    margin: 0;
}

.dmdw-option:hover {
    background: #e8f8f3;
    border-color: #7dcea0;
}

.dmdw-option:has(input:checked) {
    background: #e0f7f1;
    border-color: #27ae60;
    box-shadow: 0 0 0 2px rgba(39, 174, 96, 0.15);
}

.dmdw-option input[type="radio"] {
    margin-top: 3px;
    accent-color: #27ae60;
    flex-shrink: 0;
}

.dmdw-option span {
    flex: 1;
    font-size: 13px;
    color: #34495e;
}

/* ボタン */
.dmdw-btn {
    display: inline-block;
    padding: 10px 18px;
    font-size: 14px;
    font-weight: 600;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    transition: background 0.2s, transform 0.1s, opacity 0.2s;
    text-align: center;
}

.dmdw-btn:active {
    transform: scale(0.98);
}

.dmdw-btn:disabled {
    opacity: 0.45;
    cursor: not-allowed;
}

.dmdw-next,
.dmdw-result {
    background: linear-gradient(135deg, #27ae60, #2ecc71);
    color: #fff;
    width: 100%;
}

.dmdw-next:hover:not(:disabled),
.dmdw-result:hover:not(:disabled) {
    background: linear-gradient(135deg, #219a52, #27ae60);
}

.dmdw-prev {
    background: #ecf0f1;
    color: #5d6d7e;
    flex: 1;
}

.dmdw-prev:hover {
    background: #d5dbdb;
}

.dmdw-restart {
    background: #3498db;
    color: #fff;
    width: 100%;
    margin-top: 12px;
}

.dmdw-restart:hover {
    background: #2980b9;
}

.dmdw-nav {
    display: flex;
    gap: 10px;
}

.dmdw-nav .dmdw-result {
    flex: 2;
}

/* 結果画面 */
.dmdw-result-title {
    font-weight: 700;
    font-size: 16px;
    color: #1a5f7a;
    margin: 0 0 14px;
    text-align: center;
    padding-bottom: 8px;
    border-bottom: 2px solid #a8e6cf;
}

.dmdw-recommendations {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-bottom: 16px;
}

.dmdw-item {
    background: #fff;
    border: 1px solid #d4efe6;
    border-radius: 8px;
    padding: 12px 14px;
    transition: box-shadow 0.2s;
}

.dmdw-item:hover {
    box-shadow: 0 2px 8px rgba(39, 174, 96, 0.12);
}

.dmdw-item-name {
    display: block;
    font-weight: 600;
    font-size: 14px;
    color: #1a5f7a;
    text-decoration: none;
    margin-bottom: 4px;
}

.dmdw-item-name:hover {
    color: #27ae60;
    text-decoration: underline;
}

.dmdw-item-desc {
    font-size: 12px;
    color: #7f8c8d;
    margin: 0;
}

.dmdw-item-badge {
    display: inline-block;
    font-size: 11px;
    font-weight: 600;
    padding: 2px 8px;
    border-radius: 999px;
    background: #e8f8f3;
    color: #27ae60;
    margin-bottom: 6px;
}

/* 免責事項 */
.dmdw-disclaimer {
    background: #fef9e7;
    border: 1px solid #f9e79f;
    border-radius: 6px;
    padding: 10px 12px;
    margin-bottom: 4px;
}

.dmdw-disclaimer p {
    margin: 0 0 6px;
    font-size: 11px;
    line-height: 1.45;
    color: #7d6608;
}

.dmdw-disclaimer p:last-child {
    margin-bottom: 0;
}

/* レスポンシブ（サイドバー・スマホ対応） */
@media (max-width: 480px) {
    .dmdw-option {
        padding: 9px 10px;
    }
    .dmdw-option span {
        font-size: 12.5px;
    }
    .dmdw-question {
        font-size: 14px;
    }
    .dmdw-btn {
        padding: 9px 14px;
        font-size: 13px;
    }
}

/* Cocoonなどテーマ側の余白調整 */
.widget .dmdw-container {
    margin-top: 4px;
}
