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

body {
    font-family: 'Microsoft YaHei', 'PingFang SC', 'Helvetica Neue', Arial, sans-serif;
    /* 渐变色：从上方白色偏蓝到下方亮蓝 */
    background: linear-gradient(135deg, 
                #ffffff 0%, 
                #aee3ff 20%, 
                #00bfff 80%);    
    min-height: 100vh;
    min-width: 100vw;
    color: #333;
    line-height: 1.6;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
}

header {
    text-align: center;
    color: white;
}

header h1 {
    font-size: 2.5rem;
    margin-bottom: 10px;
}

header p {
    font-size: 1.1rem;
    opacity: 0.9;
}

.logo-container {
    display: flex;
    justify-content: center;
    align-items: center;
    margin-top: 15px;
    margin-bottom: 20px;
}

.logo-image {
    width: 60px;
    height: 60px;
    object-fit: contain;
    filter: drop-shadow(2px 2px 4px rgba(0, 0, 0, 0.3));
    transition: transform 0.3s ease;
}

.logo-image:hover {
    transform: scale(1.1);
}

.calculator-section {
    background: #ffffff;
    border-radius: 20px;
    padding: 30px;
    margin-bottom: 30px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
    border: 1px solid #e5e7eb;
    transition: transform 0.3s ease;
}

.calculator-section:hover {
    transform: translateY(-5px);
}

.calculator-section h2 {
    color: #4a5568;
    margin-bottom: 20px;
    font-size: 1.5rem;
    border-bottom: 3px solid #667eea;
    padding-bottom: 10px;
}

.calculator-section h3 {
    color: #2d3748;
    margin: 20px 0 15px 0;
    font-size: 1.2rem;
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    color: #4a5568;
}

.form-group input,
.form-group select {
    width: 100%;
    padding: 12px 15px;
    border: 1px solid #e5e7eb;
    border-radius: 20px;
    font-size: 16px;
    transition: all 0.3s ease;
    background: #ffffff;
}

.form-group input:focus,
.form-group select:focus {
    outline: none;
    border-color: #667eea;
    background: #ffffff;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.2);
}

.form-group select {
    cursor: pointer;
    color: #333;
}

.form-group select option {
    background: #ffffff;
    color: #333;
    padding: 8px;
}

.base-range {
    display: block;
    margin-top: 5px;
    font-size: 0.85rem;
    color: #718096;
    font-style: italic;
}

.checkbox-option {
    margin-top: 10px;
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 12px;
    background: #f8fafc;
    border-radius: 8px;
    border: 1px solid #e5e7eb;
    transition: all 0.3s ease;
}

.checkbox-option:hover {
    background: #f1f5f9;
    border-color: rgba(102, 126, 234, 0.3);
}

.checkbox-option input[type="checkbox"] {
    width: auto;
    margin: 0;
    cursor: pointer;
    transform: scale(1.2);
    accent-color: #667eea;
}

.checkbox-option label {
    margin: 0;
    font-size: 0.9rem;
    color: #4a5568;
    cursor: pointer;
    user-select: none;
    font-weight: 500;
}

.checkbox-option input[type="checkbox"]:checked + label {
    color: #667eea;
    font-weight: 600;
}

.checkbox-option input[type="checkbox"]:checked {
    background-color: #667eea;
    border-color: #667eea;
}

.base-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 20px;
    margin-bottom: 20px;
}

/* 地区选择器样式 */
.location-selector {
    margin-bottom: 30px;
    border-radius: 15px;
}

.location-selector h3 {
    color: #2d3748;
    margin-bottom: 15px;
    font-size: 1.1rem;
    display: flex;
    align-items: center;
}

.location-selector h3::before {
    content: "📍";
    margin-right: 8px;
    font-size: 1.2rem;
}

.selector-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 15px;
    margin-bottom: 15px;
}

.cascade-selector {
    display: flex;
    gap: 10px;
    align-items: flex-end;
}

.cascade-selector .form-select {
    flex: 1;
    min-width: 0;
}

/* Cascader 级联选择器样式 */
.cascader-container {
    position: relative;
    width: 100%;
}

.cascader-input {
    width: 100%;
    padding: 12px 15px;
    border: 1px solid #e5e7eb;
    border-radius: 20px;
    font-size: 16px;
    transition: all 0.3s ease;
    background: #ffffff;
    color: #333;
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
    min-height: 48px;
}

.cascader-input:hover {
    border-color: #667eea;
    background: #ffffff;
}

.cascader-input.active {
    border-color: #667eea;
    background: #ffffff;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.2);
}

.cascader-placeholder {
    color: #999;
}

.cascader-arrow {
    font-size: 12px;
    color: #666;
    transition: transform 0.3s ease;
}

.cascader-input.active .cascader-arrow {
    transform: rotate(180deg);
}

.cascader-dropdown {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: #ffffff;
    border: 1px solid #e5e7eb;
    border-radius: 12px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
    z-index: 1000;
    margin-top: 5px;
    max-height: 300px;
    overflow: hidden;
}

.cascader-panel {
    display: flex;
    min-height: 200px;
}

.cascader-column {
    flex: 1;
    border-right: 1px solid #e5e7eb;
    overflow-y: auto;
    max-height: 300px;
}

.cascader-column:last-child {
    border-right: none;
}

.cascader-option {
    padding: 12px 15px;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid #f3f4f6;
    background: #ffffff;
}

    .cascader-option:hover {
        background: #f8fafc !important;
    }

    .cascader-option.selected {
        background: #e0e7ff !important;
        color: #667eea !important;
        font-weight: 600 !important;
    }

.cascader-option.has-children::after {
    content: ">";
    color: #999;
    font-size: 12px;
}

.cascader-option.selected.has-children::after {
    color: #667eea;
}

.form-select {
    width: 100%;
    padding: 12px 15px;
    border: 1px solid #e5e7eb;
    border-radius: 20px;
    font-size: 16px;
    transition: all 0.3s ease;
    background: #ffffff;
    color: #333;
    cursor: pointer;
}

.form-select:focus {
    outline: none;
    border-color: #667eea;
    background: #ffffff;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.2);
}

.form-select:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    background: #f9fafb;
}

.form-select option {
    background: rgba(255, 255, 255, 0.9);
    color: #333;
    padding: 8px;
}

.auto-fill-info {
    padding: 10px 15px;
    background: rgba(102, 126, 234, 0.1);
    border-radius: 8px;
    border-left: 4px solid #667eea;
}

.info-text {
    color: #4a5568;
    font-size: 0.9rem;
    margin: 0;
    display: flex;
    align-items: center;
}

.info-text::before {
    content: "💡";
    margin-right: 8px;
    font-size: 1rem;
}

.ratio-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
}

.button-group {
    text-align: center;
    margin: 40px 0;
}

.btn {
    padding: 15px 30px;
    border: none;
    border-radius: 50px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    margin: 0 10px;
    min-width: 150px;
}

.btn-primary {
    background: linear-gradient(135deg, #6fd6ff 0%, #4FB7FF 60%, #2fa0e6 100%) !important;
    border: 1px solid #4FB7FF !important;
    color: #fff !important;
    border-radius: 32px !important;
    box-shadow:
        0 8px 32px rgba(79, 183, 255, 0.25),
        0 4px 16px rgba(0, 0, 0, 0.12),
        inset 0 2px 12px rgba(255, 255, 255, 0.45),
        inset 0 -2px 8px rgba(79, 183, 255, 0.18);
    position: relative;
    overflow: hidden;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow:
        0 12px 40px rgba(79, 183, 255, 0.35),
        0 6px 20px rgba(0, 0, 0, 0.15),
        inset 0 2px 12px rgba(255, 255, 255, 0.45),
        inset 0 -2px 8px rgba(79, 183, 255, 0.18);
}

.btn-secondary {
    background: linear-gradient(135deg, #6fd6ff 0%, #4FB7FF 60%, #2fa0e6 100%) !important;
    border: 1px solid #4FB7FF !important;
    color: #fff !important;
    border-radius: 32px !important;
    box-shadow:
        0 8px 32px rgba(79, 183, 255, 0.25),
        0 4px 16px rgba(0, 0, 0, 0.12),
        inset 0 2px 12px rgba(255, 255, 255, 0.45),
        inset 0 -2px 8px rgba(79, 183, 255, 0.18);
    position: relative;
    overflow: hidden;
}

.btn-secondary:hover {
    background: linear-gradient(135deg, #5bc5ff 0%, #3ea6ff 60%, #1e8fd6 100%) !important;
    transform: translateY(-2px);
    box-shadow:
        0 12px 40px rgba(79, 183, 255, 0.35),
        0 6px 20px rgba(0, 0, 0, 0.15),
        inset 0 2px 12px rgba(255, 255, 255, 0.45),
        inset 0 -2px 8px rgba(79, 183, 255, 0.18);
}

.btn-danger {
    background: linear-gradient(135deg, #ff6b6b 0%, #ff5252 60%, #ff3d3d 100%) !important;
    border: 1px solid #ff3d3d !important;
    color: #fff !important;
    border-radius: 32px !important;
}

.btn-danger:hover {
    background: linear-gradient(135deg, #ff8a8a 0%, #ff7171 60%, #ff5c5c 100%) !important;
    transform: translateY(-2px);
    box-shadow:
        0 12px 40px rgba(255, 107, 107, 0.35),
        0 6px 20px rgba(0, 0, 0, 0.15),
        inset 0 2px 12px rgba(255, 255, 255, 0.45),
        inset 0 -2px 8px rgba(255, 107, 107, 0.18);
}   

.results-section {
    background: rgb(255, 255, 255);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border-radius: 20px;
    padding: 30px;
    margin-top: 30px;
    box-shadow: 0 8px 32px rgba(31, 38, 135, 0.15);
    border: 1px solid rgba(255, 255, 255, 0.18);
}

.results-section h2 {
    color: #4a5568;
    margin-bottom: 25px;
    text-align: center;
    font-size: 1.8rem;
}

/* 对比表格样式 */
.comparison-table {
    margin-bottom: 30px;
}

/* 桌面端显示表格，隐藏移动卡片 */
.mobile-comparison {
    display: none;
}

/* 确保移动端结果卡片在桌面端隐藏 */
#mobileResultsSection {
    display: none;
}

/* 桌面端显示表格 */
/* 移除全局的display: block规则，让HTML中的display: none生效 */

/* 确保在桌面端只显示表格，隐藏移动端卡片 */
@media (min-width: 769px) {
    .comparison-table.show {
        display: block !important;
    }
    
    .mobile-comparison {
        display: none !important;
    }
    
    #mobileResultsSection {
        display: none !important;
    }
}

.comparison-table table {
    width: 100%;
    border-collapse: collapse;
    background: #ffffff;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.1);
    border: 1px solid #e5e7eb;
}

.comparison-table thead {
    background: #f8f9fa;
}

.comparison-table th {
    color: #374151;
    font-weight: bold;
    padding: 15px;
    text-align: center;
    font-size: 1rem;
    border-bottom: 2px solid #e5e7eb;
}

.comparison-table tbody tr {
    border-bottom: 1px solid #f3f4f6;
    background: #ffffff;
}

.comparison-table tbody tr:nth-child(even) {
    background: #f9fafb;
}

.comparison-table tbody tr:last-child {
    border-bottom: none;
}

.comparison-table tbody tr:hover {
    background: #f3f4f6;
}

.comparison-table td{
    text-align: center;
    padding: 12px 15px;
    color: #374151;
    font-size: 0.95rem;
}

.comparison-table td:first-child {
    font-weight: 500;
    text-align: center;
}

.comparison-table td:nth-child(2),
.comparison-table td:nth-child(3) {
    text-align: center;
    font-weight: 600;
}

.total-row {
    background: #f8f9fa !important;
    border-top: 2px solid #d1d5db !important;
}

.total-row td {
    font-weight: bold !important;
    color: #1f2937 !important;
}

/* 计算过程和结果样式 */
.calculation-result {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.result-amount {
    font-size: 1rem;
    font-weight: 600;
    color: #1f2937;
    text-align: right;
}

.calculation-formula {
    padding: 8px 0;
    font-size: 0.75rem;
    color: #9ca3af;
    line-height: 1.4;
    border-top: 1px solid #e5e7eb;
    padding-top: 8px;
}

.calculation-formula span {
    color: #9ca3af;
    font-weight: 400;
}

/* 违法成本单元格样式 */
.comparison-table td:nth-child(3) {
    white-space: normal;
    word-wrap: break-word;
    line-height: 1.4;
    font-size: 0.9rem;
    text-align: center;
}

.calculation-detail {
    background: #f8f9fa !important;
    border-top: 1px solid #e5e7eb;
}

/* 详细分解样式 */
.detailed-breakdown {
    margin-top: 30px;
}

.detailed-breakdown h3 {
    color: #4a5568;
    margin-bottom: 20px;
    font-size: 1.4rem;
    text-align: center;
}

.breakdown-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 20px;
}

.breakdown-card {
    background: rgba(255, 255, 255, 0.25);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    border-radius: 16px;
    padding: 20px;
    border-left: 4px solid #667eea;
    border: 1px solid rgba(255, 255, 255, 0.2);
    box-shadow: 0 4px 16px rgba(31, 38, 135, 0.1);
}

.breakdown-card h4 {
    color: #2d3748;
    margin-bottom: 15px;
    font-size: 1.1rem;
    text-align: center;
}

.breakdown-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.2);
}

.breakdown-item:last-child {
    border-bottom: none;
}

.breakdown-item span:last-child {
    font-weight: 600;
    color: #667eea;
}

footer {
    text-align: center;
    margin-top: 40px;
    color: white;
    opacity: 0.8;
    font-size: 0.9rem;
}

/* 响应式设计 */
@media (max-width: 768px) {
    .container {
        padding: 15px;
    }

    header h1 {
        font-size: 1.5rem;
    }

    .logo-container {
        margin-top: 10px;
        margin-bottom: 15px;
    }

    .logo-image {
        width: 50px;
        height: 50px;
    }

    .calculator-section {
        padding: 20px;
    }

    .base-grid {
        grid-template-columns: 1fr;
    }

    .selector-grid {
        grid-template-columns: 1fr;
    }

    .cascade-selector {
        flex-direction: column;
        gap: 8px;
    }

    .cascade-selector .form-select {
        width: 100%;
    }

    /* 移动端 Cascader 样式 */
    .cascader-dropdown {
        position: fixed !important;
        top: 50% !important;
        left: 50% !important;
        transform: translate(-50%, -50%) !important;
        width: 95% !important;
        max-width: 500px !important;
        max-height: 80vh !important;
        border-radius: 16px !important;
        z-index: 9999 !important;
        background: #ffffff !important;
        backdrop-filter: none !important;
        -webkit-backdrop-filter: none !important;
        box-shadow: 0 10px 40px rgba(0, 0, 0, 0.3) !important;
        border: 1px solid #e5e7eb !important;
    }

    /* 移动端遮罩层 */
    .cascader-dropdown::before {
        content: '';
        position: fixed;
        top: 0;
        left: 0;
        right: 0;
        bottom: 0;
        background: rgba(0, 0, 0, 0.5);
        z-index: -1;
        animation: fadeIn 0.3s ease-out;
    }

    /* 移动端级联选择器动画 */
    @keyframes cascaderSlideIn {
        from {
            opacity: 0;
            transform: translate(-50%, -50%) scale(0.9);
        }
        to {
            opacity: 1;
            transform: translate(-50%, -50%) scale(1);
        }
    }

    .cascader-dropdown {
        animation: cascaderSlideIn 0.3s ease-out;
    }

    /* 移动端关闭按钮 */
    .cascader-close-btn {
        position: absolute;
        top: -40px;
        right: 0;
        width: 32px;
        height: 32px;
        background: #ffffff;
        border: 1px solid #e5e7eb;
        border-radius: 50%;
        display: flex;
        align-items: center;
        justify-content: center;
        cursor: pointer;
        font-size: 18px;
        color: #666;
        box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
        z-index: 1002;
    }

    .cascader-close-btn:hover {
        background: #f8fafc;
        color: #333;
    }

    .cascader-panel {
        flex-direction: row !important;
        min-height: 300px !important;
        max-height: 60vh !important;
        background: #ffffff !important;
        border-radius: 16px !important;
        overflow: visible !important;
        border: 1px solid #e5e7eb !important;
    }

    .cascader-column {
        flex: 1 !important;
        border-right: 1px solid #e5e7eb !important;
        max-height: 60vh !important;
        overflow-y: auto !important;
        overflow-x: hidden !important;
        min-width: 0 !important;
        background: #ffffff !important;
        -webkit-overflow-scrolling: touch !important;
        scroll-behavior: smooth !important;
    }

    .cascader-column:last-child {
        border-right: none;
    }

    .cascader-option {
        padding: 10px 12px !important;
        font-size: 14px !important;
        white-space: nowrap !important;
        overflow: hidden !important;
        text-overflow: ellipsis !important;
        display: flex !important;
        justify-content: space-between !important;
        align-items: center !important;
        min-height: 44px !important;
        cursor: pointer !important;
        user-select: none !important;
        -webkit-tap-highlight-color: transparent !important;
        -webkit-touch-callout: none !important;
        -webkit-user-select: none !important;
        -moz-user-select: none !important;
        -ms-user-select: none !important;
        touch-action: manipulation !important;
        background: #ffffff !important;
        color: #333 !important;
        border-bottom: 1px solid #f3f4f6 !important;
    }

    /* 移动端级联选择器列宽优化 */
    .cascader-column:first-child {
        flex: 0 0 45%;
        min-width: 120px;
        border-right: 1px solid #e5e7eb;
    }

    .cascader-column:last-child {
        flex: 0 0 55%;
        min-width: 140px;
    }

    /* 移动端级联选择器选项优化 */
    .cascader-option.has-children::after {
        content: ">";
        color: #999;
        font-size: 12px;
        margin-left: 8px;
        flex-shrink: 0;
    }

    .cascader-option.selected.has-children::after {
        color: #667eea;
    }

    /* 移动端滚动条样式 */
    .cascader-column::-webkit-scrollbar {
        width: 4px;
    }

    .cascader-column::-webkit-scrollbar-track {
        background: #f3f4f6;
        border-radius: 2px;
    }

    .cascader-column::-webkit-scrollbar-thumb {
        background: #d1d5db;
        border-radius: 2px;
    }

    .cascader-column::-webkit-scrollbar-thumb:hover {
        background: #9ca3af;
    }

    /* 小屏幕手机优化 */
    @media screen and (max-width: 480px) {
        .cascader-dropdown {
            width: 98%;
            max-width: 350px;
            max-height: 70vh;
            background: #ffffff !important;
            touch-action: pan-y !important;
        }

        .cascader-panel {
            min-height: 250px;
            max-height: 50vh;
            background: #ffffff;
            border: 1px solid #e5e7eb;
        }

        .cascader-column:first-child {
            flex: 0 0 40%;
            min-width: 100px;
            background: #ffffff;
            border-right: 1px solid #e5e7eb;
        }

        .cascader-column:last-child {
            flex: 0 0 60%;
            min-width: 120px;
            background: #ffffff;
        }

        .cascader-option {
            padding: 8px 10px;
            font-size: 13px;
            background: #ffffff;
            color: #333;
            border-bottom: 1px solid #f3f4f6;
        }

        .cascader-option.has-children::after {
            font-size: 11px;
            margin-left: 6px;
        }
    }

    .ratio-grid {
        grid-template-columns: 1fr;
    }

    .breakdown-grid {
        grid-template-columns: 1fr;
    }

    .btn {
        margin: 10px 5px;
        min-width: 120px;
    }

    /* 移动端表格样式 */
    .comparison-table {
        overflow-x: auto;
    }
    
    .comparison-table table {
        min-width: 600px;
    }
    
    .comparison-table th,
    .comparison-table td {
        padding: 10px 8px;
        font-size: 0.9rem;
    }
    

    
    .mobile-card {
        background: #ffffff;
        border-radius: 16px;
        padding: 20px;
        margin-bottom: 20px;
        border: 1px solid #e5e7eb;
        box-shadow: 0 4px 16px rgba(0, 0, 0, 0.1);
    }
    
    .mobile-card h3 {
        color: #4a5568;
        margin-bottom: 15px;
        font-size: 1.2rem;
        text-align: center;
        border-bottom: 2px solid #d1d5db;
        padding-bottom: 8px;
        position: relative;
    }
    
    .mobile-card h3::before {
        content: '';
        position: absolute;
        left: 50%;
        bottom: -2px;
        transform: translateX(-50%);
        width: 60px;
        height: 2px;
        background: linear-gradient(90deg, transparent, #9ca3af, transparent);
    }
    
    .mobile-card-item {
        display: flex;
        justify-content: flex-start;
        align-items: flex-start;
        padding: 12px 0 12px 15px;
        border-bottom: 1px solid #f3f4f6;
        gap: 15px;
    }
    
    .mobile-amounts {
        display: flex;
        flex-direction: column;
        gap: 4px;
        text-align: left;
        font-size: 0.9rem;
        min-width: 120px;
    }
    
    .mobile-amounts div {
        color: #4a5568;
    }
    
    .mobile-amounts div:last-child {
        font-weight: bold;
        color: #6b7280;
    }
    
    /* 移动端括号内计算过程样式 */
    .mobile-amounts .calculation-formula-gray {
        font-size: 0.75rem;
        color: #9ca3af;
        font-weight: 400;
        margin-left: 4px;
    }
    
    .mobile-card-item.section-header {
        justify-content: center;
        background: #f8f9fa;
        margin: 15px -15px 10px -15px;
        padding: 12px 15px;
        border-radius: 8px;
        border: 1px solid #e5e7eb;
        border-bottom: 1px solid #f3f4f6;
    }
    
    .mobile-card-item.section-header span {
        color: #6b7280;
        font-weight: 700;
        font-size: 0.95rem;
        text-align: center;
    }
    
    .mobile-card-item.calculation-item {
        flex-direction: column;
        align-items: stretch;
        padding: 15px 0;
        background: #f9fafb;
        margin: 8px -15px;
        padding: 15px;
        border-radius: 12px;
        border: 1px solid #e5e7eb;
        transition: all 0.3s ease;
        position: relative;
        overflow: hidden;
    }
    
    .mobile-card-item.calculation-item::before {
        content: '';
        position: absolute;
        top: 0;
        left: -100%;
        width: 100%;
        height: 100%;
        background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.1), transparent);
        transition: left 0.5s ease;
    }
    
    .mobile-card-item.calculation-item:hover::before {
        left: 100%;
    }
    
    .mobile-card-item.calculation-item:hover {
        transform: translateY(-2px);
        box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
        border-color: #d1d5db;
    }
    
    .mobile-card-item.calculation-item .item-main {
        display: flex;
        justify-content: space-between;
        align-items: center;
        margin-bottom: 8px;
    }
    
    .mobile-card-item.calculation-item .calculation-detail {
        font-size: 0.75rem;
        color: #9ca3af;
        background: #f8f9fa;
        padding: 10px 12px;
        border-radius: 8px;
        border-left: 3px solid #9ca3af;
        line-height: 1.4;
        position: relative;
        box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.1);
    }
    
    .mobile-card-item.calculation-item .calculation-detail::before {
        
        position: absolute;
        left: -8px;
        top: 50%;
        transform: translateY(-50%);
        background: #9ca3af;
        color: white;
        width: 16px;
        height: 16px;
        border-radius: 50%;
        display: flex;
        align-items: center;
        justify-content: center;
        font-size: 8px;
        box-shadow: 0 2px 4px rgba(156, 163, 175, 0.3);
    }
    
    .mobile-card-item.total-item {
        border-bottom: none;
        font-weight: bold;
        color: #1f2937;
        background: #f8f9fa;
        margin: 15px -20px -20px -20px;
        padding: 18px 20px;
        border-radius: 0 0 16px 16px;
        border-top: 2px solid #d1d5db;
        box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.05);
    }
    
    .mobile-card-item span:first-child {
        font-weight: 500;
        color: #4a5568;
    }
    
    .mobile-card-item span:last-child {
        font-weight: 600;
        text-align: right;
    }
    
    .mobile-card-item.calculation-item span:first-child {
        color: #2d3748;
        font-weight: 600;
    }
    
    .mobile-card-item.calculation-item span:last-child {
        color: #9ca3af;
        font-weight: 700;
    }
    
    .mobile-card-item.total-item span:first-child {
        color: #1f2937;
        font-weight: 700;
    }
    
    .mobile-card-item.total-item span:last-child {
        color: #e53e3e;
        font-weight: 700;
        font-size: 1.1rem;
    }
    
    /* 移动端checkbox优化 */
    .checkbox-option {
        padding: 12px 16px;
        background: #f8fafc;
        border-radius: 12px;
        border: 2px solid #e5e7eb;
        margin-top: 15px;
        box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    }
    
    .checkbox-option:hover {
        background: #f1f5f9;
        border-color: rgba(102, 126, 234, 0.4);
        transform: translateY(-1px);
        box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    }
    
    .checkbox-option input[type="checkbox"] {
        transform: scale(1.4);
        margin-right: 4px;
    }
    
    .checkbox-option label {
        font-size: 1rem;
        font-weight: 600;
        color: #2d3748;
        line-height: 1.4;
    }
    
    .checkbox-option input[type="checkbox"]:checked + label {
        color: #667eea;
        font-weight: 700;
    }
    
    .checkbox-option input[type="checkbox"]:checked {
        background-color: #667eea;
        border-color: #667eea;
        box-shadow: 0 0 0 2px rgba(102, 126, 234, 0.3);
    }
    
    /* 移动端卡片样式 */
    .comparison-table {
        display: none;
    }
    
    /* 合规成本表格在移动端隐藏，只显示卡片 */
    .compliance-results-section .comparison-table {
        display: none;
    }
    
    /* 合规成本移动端卡片显示 */
    .compliance-results-section .mobile-comparison {
        display: block;
    }
    
    .mobile-comparison {
        display: block;
    }
    
    /* 移动端显示结果卡片 */
    #mobileResultsSection {
        display: block;
    }
}

/* 动画效果 */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes slideInFromRight {
    from {
        opacity: 0;
        transform: translateX(30px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes pulse {
    0%, 100% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.05);
    }
}

.results-section {
    animation: fadeIn 0.5s ease-out;
}

.mobile-card {
    animation: slideInFromRight 0.6s ease-out;
}

.mobile-card:nth-child(2) {
    animation-delay: 0.1s;
}

.mobile-card-item.calculation-item {
    animation: fadeIn 0.8s ease-out;
}

.mobile-card-item.calculation-item:nth-child(3) {
    animation-delay: 0.2s;
}

.mobile-card-item.calculation-item:nth-child(4) {
    animation-delay: 0.3s;
}

.mobile-card-item.calculation-item:nth-child(5) {
    animation-delay: 0.4s;
}

.mobile-card-item.total-item {
    animation: pulse 0.5s ease-out 0.6s both;
}

/* 输入验证样式 */
.form-group input:invalid {
    border-color: #e53e3e;
    background: #fed7d7;
}

.form-group input:invalid:focus {
    box-shadow: 0 0 0 3px rgba(229, 62, 62, 0.1);
}

/* 加载状态 */
.btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none !important;
}

/* 页脚样式 */
.footer {
    background: linear-gradient(135deg, #1e3c72, #2a5298);
    padding: 40px 0;
    margin-top: 50px;
}

.footer-content {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

.footer-services {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    align-items: center;
    max-width: 1000px;
    margin: 0 auto;
}

.service-item {
    background: rgba(255, 255, 255, 0.1);
    color: white;
    border-radius: 25px;
    font-weight: 500;
    border: 1px solid rgba(255, 255, 255, 0.2);
    transition: all 0.3s ease;
    cursor: pointer;
    white-space: nowrap;
    text-align: center;
    box-sizing: border-box;
    overflow: hidden;
    text-overflow: ellipsis;
}

.service-item:hover {
    background: rgba(255, 255, 255, 0.2);
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
}

.service-link {
    text-decoration: none;
    color: inherit;
    display: block;
    height: 100%;
}

.service-link:hover {
    text-decoration: none;
    color: inherit;
}

/* 响应式设计 */
@media screen and (min-width: 1200px) {

    /* 大屏幕：一行八列 */
    .footer-services {
        flex-wrap: nowrap;
        gap: 15px;
    }

    .service-item {
        flex: 1;
        padding: 12px 16px;
        font-size: 15px;
        min-width: 0;
    }
}

@media screen and (max-width: 1199px) {

    /* 其他屏幕：两行四列布局 */
    .footer {
        padding: 30px 0;
    }

    .footer-services {
        display: grid;
        grid-template-columns: repeat(4, 1fr);
        grid-template-rows: repeat(2, auto);
        gap: 15px 10px;
        max-width: 800px;
        padding: 0 20px;
        margin: 0 auto;
    }

    .service-item {
        min-width: 0;
        padding: 10px 8px;
        font-size: 14px;
        width: 100%;
    }

    .service-link {
        width: 100%;
    }
}

@media screen and (max-width: 768px) {

    /* 平板：两行四列布局 */
    .footer {
        padding: 25px 0;
    }

    .footer-services {
        display: grid;
        grid-template-columns: repeat(4, 1fr);
        grid-template-rows: repeat(2, auto);
        gap: 10px 8px;
        max-width: 100%;
        padding: 0 15px;
    }

    .service-item {
        min-width: 0;
        padding: 8px 6px;
        font-size: 13px;
        width: 100%;
    }

    .service-link {
        width: 100%;
    }
}

@media screen and (max-width: 480px) {

    /* 手机：两行四列布局 */
    .footer {
        padding: 20px 0;
    }

    .footer-services {
        display: grid;
        grid-template-columns: repeat(4, 1fr);
        grid-template-rows: repeat(2, auto);
        gap: 8px 6px;
        padding: 0 10px;
    }

    .service-item {
        min-width: 0;
        padding: 6px 4px;
        font-size: 12px;
        width: 100%;
    }

    .service-link {
        width: 100%;
    }
}

/* 社保缴费比例显示样式 */
.ratio-display {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 15px;
    margin-bottom: 20px;
    padding: 20px;
    background: rgba(255, 255, 255, 0.15);
    border-radius: 15px;
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.ratio-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 15px;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 10px;
    border: 1px solid rgba(255, 255, 255, 0.3);
}

.ratio-label {
    font-weight: 600;
    color: #4a5568;
}

.ratio-value {
    font-weight: 700;
    color: #667eea;
    font-size: 1.1rem;
}

/* 社保费用明细样式 */
.social-security-breakdown,
.housing-fund-breakdown {
    background: rgba(255, 255, 255, 0.25);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border-radius: 20px;
    padding: 25px;
    margin-bottom: 25px;
    box-shadow: 0 8px 32px rgba(31, 38, 135, 0.15);
    border: 1px solid rgba(255, 255, 255, 0.18);
}

.social-security-breakdown h3,
.housing-fund-breakdown h3 {
    color: #2d3748;
    margin-bottom: 20px;
    font-size: 1.3rem;
    border-bottom: 2px solid #667eea;
    padding-bottom: 10px;
}

.breakdown-table {
    overflow-x: auto;
}

.breakdown-table table {
    width: 100%;
    border-collapse: collapse;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    overflow: hidden;
}

.breakdown-table th {
    background: rgba(102, 126, 234, 0.2);
    color: #2d3748;
    font-weight: 600;
    padding: 15px 12px;
    text-align: left;
    border-bottom: 2px solid rgba(102, 126, 234, 0.3);
}

.breakdown-table td {
    padding: 12px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.2);
    color: #4a5568;
}

.breakdown-table tr:hover {
    background: rgba(255, 255, 255, 0.1);
}

.subtotal-row {
    background: rgba(102, 126, 234, 0.1) !important;
    font-weight: 600;
}

.subtotal-row td {
    color: #2d3748;
}

.subtotal-item {
    background: rgba(102, 126, 234, 0.1) !important;
    font-weight: 600;
    border-top: 2px solid rgba(102, 126, 234, 0.3);
    border-bottom: 2px solid rgba(102, 126, 234, 0.3);
}

/* 移动端响应式调整 */
@media screen and (max-width: 768px) {
    .ratio-display {
        grid-template-columns: 1fr;
        gap: 10px;
        padding: 15px;
    }
    
    .ratio-item {
        padding: 8px 12px;
    }
    
    .breakdown-table {
        font-size: 14px;
    }
    
    .breakdown-table th,
    .breakdown-table td {
        padding: 8px 6px;
    }
    
    .social-security-breakdown,
    .housing-fund-breakdown {
        padding: 20px 15px;
    }
}

/* 计算过程灰色字体样式 */
.calculation-formula-gray {
    color: #9ca3af;
    font-size: 0.85rem;
    font-weight: 400;
}

/* 移动端隐藏比较表格 */
@media screen and (max-width: 768px) {
    .comparison-table {
        display: none !important;
    }
}