﻿/* ==========================================
   风格 1：边角标风 (Muji Floating Badge)
   ========================================== */

/* 容器基础样式 */
    .muji-radio-list {
        list-style: none;
        padding: 0;
        margin: 0;
    }

    /* 每个选项的容器 (li) */
    .muji-radio-list li {
        position: relative;
        margin-bottom: 15px; /* 卡片之间的间距 */
    }

    /* 隐藏原始 Radio */
    .muji-radio-list input[type="radio"] {
        position: absolute;
        opacity: 0;
    }

    /* Label 模拟卡片样式 */
    .muji-radio-list label {
        display: flex;
        align-items: center;
        width: 100%;
        padding: 15px 20px;
        cursor: pointer;
        background: #fff;
        border: 2px solid #f0f0f0; /* 默认浅色边框 */
        border-radius: 15px; /* 圆角效果 */
        transition: all 0.3s ease;
        position: relative;
        box-sizing: border-box;
    }

    /* 选中状态：边框变绿，背景变浅绿 */
    .muji-radio-list input[type="radio"]:checked + label {
        border-color: #26c299; /* 图片中的翠绿色 */
        background-color: #f4fdfa; /* 极淡的绿色背景 */
        box-shadow: none !important;
    }

    /* 伪元素：左侧的定位图标 (Placeholder) */
    .muji-radio-list label::before {
        /* content: '📍'; */
        display: flex;
        align-items: center;
        justify-content: center;
        width: 40px;
        height: 40px;
        background: #26c299;
        color: white;
        border-radius: 10px;
        margin-right: 15px;
        font-size: 18px;
    }

    /* 伪元素：右侧的勾选图标 (仅在选中时显示) */
    .muji-radio-list label::after {
        content: '✓';
        position: absolute;
        right: 20px;
        width: 24px;
        height: 24px;
        background: #26c299;
        color: #fff;
        border-radius: 50%;
        display: flex;
        align-items: center;
        justify-content: center;
        font-size: 14px;
        font-weight: bold;
        opacity: 0; /* 默认隐藏 */
        transition: opacity 0.2s;
    }

    /* 选中时显示右侧勾选圆圈 */
    .muji-radio-list input[type="radio"]:checked + label::after {
        opacity: 1;
    }

    /* 鼠标悬停效果 */
    .muji-radio-list li:hover label {
        border-color: #26c299;
    }

/* ==========================================
   风格 2：挂边角标风 (Elegant Floating Badge)
   ========================================== */
.elegant-radio-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

    .elegant-radio-list li {
        margin-bottom: 12px;
        position: relative;
    }

    /* 隐藏原生 Radio 圆点 */
    .elegant-radio-list input[type="radio"] {
        position: absolute;
        opacity: 0;
        width: 0;
        height: 0;
    }

    /* 卡片 Label 基础样式 */
    .elegant-radio-list label {
        display: flex;
        align-items: center;
        justify-content: space-between;
        width: 100%;
        padding: 14px 18px;
        background-color: #ffffff;
        border: 1.5px solid #e5e7eb;
        border-radius: 12px;
        cursor: pointer;
        position: relative;
        overflow: visible !important; /* 允许角标浮在边框外 */
        transition: all 0.2s ease-in-out;
        box-sizing: border-box;
    }

    /* 鼠标悬停 */
    .elegant-radio-list li:hover label {
        border-color: #26c299;
        background-color: #f9fbfb;
    }

    /* 选中状态卡片背景与边框 */
    .elegant-radio-list input[type="radio"]:checked + label {
        border-color: #26c299;
        background-color: #f0fdf9;
    }

    /* 右上角挂边勾选图标 (默认隐藏) */
    .elegant-radio-list label::after {
        content: '✓';
        position: absolute;
        top: -7px; /* 向上压在边框上 */
        right: -7px; /* 向右压在边框上 */
        width: 22px;
        height: 22px;
        background: #26c299;
        color: #ffffff;
        border-radius: 50%;
        display: flex;
        align-items: center;
        justify-content: center;
        font-size: 12px;
        font-weight: bold;
        opacity: 0;
        transform: scale(0.4);
        transition: all 0.2s cubic-bezier(0.175, 0.885, 0.32, 1.275); /* 微弹跳动画 */
        box-shadow: 0 2px 5px rgba(38, 194, 153, 0.4);
        z-index: 10;
    }

    /* 选中时显示勾选图标 */
    .elegant-radio-list input[type="radio"]:checked + label::after {
        opacity: 1;
        transform: scale(1);
    }


/* ==========================================
   Radio Toolbar
   ========================================== */
.radio-toolbar {
    margin: 0 !important;
    width: 100% !important;
}

    .radio-toolbar table {
        width: 100% !important;
        border-collapse: collapse !important;
    }

    .radio-toolbar th {
        width: 100% !important;
        display: block !important;
    }

    .radio-toolbar tr {
        width: 100% !important;
        display: block !important;
        margin-bottom: 10px !important;
    }

    .radio-toolbar td {
        width: 100% !important;
        display: block !important;
        padding: 0 !important;
        margin: 0 !important;
        height: 47px !important;
    }

    .radio-toolbar input[type="radio"] {
        opacity: 0;
        position: fixed;
        width: 0;
    }

    .radio-toolbar label {
        display: block;
        background-color: #fff;
        padding: 8px 8px;
        border: 1px solid #f5f5f5 !important;
        border-radius: 4px;
        color: #000;
        width: 100%;
        height: 45px;
        margin-bottom: 5px;
    }

@media (max-width: 576px) {
    .radio-toolbar label {
        padding: 5px 5px;
        font-size: 11px;
    }
}

.radio-toolbar label:hover {
    border-color: #000;
}

.radio-toolbar input[type="radio"]:focus + label {
    border: 0px dashed #000;
}

.radio-toolbar input[type="radio"]:checked + label {
    border-width: 2px !important;
    border-color: #000 !important;
    color: #000 !important;
    background-color: #f5f5f5 !important;
}