:root {
    --primary-color: #4a90e2;
    --secondary-color: #f4f4f4;
    --text-color: #333;
    --border-color: #ccc;
    --hover-color: #3a7bc8;
    --bg-color: white;
}

[data-theme="dark"] {
    --primary-color: #66a6ff;
    --secondary-color: #1a1a1a;
    --text-color: #ffffff;
    --border-color: #444;
    --hover-color: #5590e6;
    --bg-color: #2d2d2d;
}

body {
    font-family: Arial, sans-serif;
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    margin: 0;
    background-color: var(--secondary-color);
    padding: 20px;
    box-sizing: border-box;
}

.container {
    width: 100%;
    max-width: 500px;
    text-align: center;
    background-color: var(--bg-color);
    color: var(--text-color);
    padding: 30px;
    border-radius: 12px;
    box-shadow: 0 4px 6px rgba(0,0,0,0.1);
}

h1 {
    color: var(--primary-color);
    font-size: 24px;
    margin-bottom: 20px;
}

.input-group {
    margin: 20px 0;
    text-align: left;
}

label {
    display: block;
    margin-bottom: 8px;
    font-weight: bold;
    color: var(--text-color);
}

select {
    width: 100%;
    padding: 10px;
    border-radius: 6px;
    border: 1px solid var(--border-color);
    font-size: 16px;
    background-color: var(--bg-color);
    color: var(--text-color);
    cursor: pointer;
    transition: border-color 0.3s ease;
}

select:focus {
    outline: none;
    border-color: var(--primary-color);
}

button {
    padding: 12px 24px;
    background-color: var(--primary-color);
    border: none;
    border-radius: 6px;
    color: white;
    cursor: pointer;
    font-size: 16px;
    transition: background-color 0.3s ease;
    margin-top: 20px;
}

button:hover {
    background-color: var(--hover-color);
}

h2 {
    color: var(--text-color);
    margin-top: 30px;
}

.cancer-options {
    display: none;
}

@media (max-width: 600px) {
    .container {
        padding: 20px;
    }

    h1 {
        font-size: 20px;
    }

    select, button {
        font-size: 14px;
    }
}

/* 为长文本选项添加样式 */
select option {
    padding: 8px;
    line-height: 1.4;
    background-color: var(--bg-color);
    color: var(--text-color);
}

/* 添加选项的悬停效果 */
select option:hover {
    background-color: var(--primary-color);
    color: white;
}

/* 为分期结果添加样式 */
#result {
    font-size: 1.2em;
    font-weight: bold;
    color: var(--primary-color);
    padding: 15px;
    border: 2px solid var(--primary-color);
    border-radius: 8px;
    margin-top: 30px;
}

/* 在文件末尾添加以下样式 */
.footer {
    margin-top: 40px;
    padding-top: 20px;
    border-top: 1px solid var(--border-color);
    font-size: 0.9em;
    color: #666;
}

.copyright {
    margin-bottom: 8px;
}

.creator {
    font-size: 0.85em;
    color: #888;
}

/* 修改移动端适配 */
@media (max-width: 600px) {
    .footer {
        margin-top: 30px;
        padding-top: 15px;
        font-size: 0.8em;
    }
}

/* 修改主题切换样式 */
.theme-switch {
    position: absolute;
    top: 20px;
    right: 20px;
    z-index: 100;
}

.theme-switch select {
    padding: 6px 8px;
    background-color: transparent;
    border: 1px solid var(--border-color);
    border-radius: 20px;
    color: var(--text-color);
    cursor: pointer;
    font-size: 18px;
    width: auto;
    min-width: 45px;
    appearance: none;
    -webkit-appearance: none;
    text-align: center;
    transition: all 0.3s ease;
    backdrop-filter: blur(5px);
    -webkit-backdrop-filter: blur(5px);
}

.theme-switch select:hover {
    border-color: var(--primary-color);
    box-shadow: 0 0 10px rgba(74, 144, 226, 0.1);
}

.theme-switch select option {
    background-color: var(--bg-color);
    color: var(--text-color);
    padding: 8px;
    text-align: center;
    font-size: 16px;
}

/* 确保下拉选项在暗色主题下也清晰可见 */
.theme-switch select option:checked {
    background-color: var(--primary-color);
    color: white;
}

/* 添加动画效果 */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(-10px); }
    to { opacity: 1; transform: translateY(0); }
}

.theme-switch select option {
    animation: fadeIn 0.2s ease;
}