:root {
    --primary-color: #e53e3e;
    --secondary-color: #2d3748;
    --background-color: #f7fafc;
    --text-color: #1a202c;
    --border-color: #e2e8f0;
    --success-color: #48bb78;
    --warning-color: #ed8936;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    margin: 0;
    padding: 0;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    background: linear-gradient(135deg, #f5f7fa 0%, #e4e8eb 100%);
    min-height: 100vh;
    color: #2d3748;
    line-height: 1.5;
}

.main-center {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
    min-height: 100vh;
    width: 100%;
    padding: 20px;
    box-sizing: border-box;
    position: relative;
    padding-bottom: 60px; /* 为广告留出空间 */
}

.container {
    width: 100%;
    max-width: 600px;
    margin: 0 auto;
    position: relative;
}

.page {
    display: none;
}

.page.active {
    display: block;
}

.card {
    background: #ffffff;
    border-radius: 12px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    padding: 24px;
    margin-bottom: 20px;
}

.title-emoji {
    font-size: 1.3em;
    vertical-align: middle;
    margin-right: 0.18em;
    display: inline-block;
}

h1 {
    font-size: 2.5rem;
    text-align: center;
    margin-bottom: 1.5rem;
    background: linear-gradient(90deg, #e53e3e 0%, #ff6b81 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    font-weight: 800;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.18em;
}

h2 {
    font-size: 1.8rem;
    margin-bottom: 1rem;
    color: #2d3748;
}

h3 {
    color: #4a5568;
    font-size: 1.3rem;
    margin-bottom: 15px;
}

.warning {
    background: #fed7d7;
    color: #c53030;
    padding: 15px;
    border-radius: 10px;
    margin-bottom: 25px;
    text-align: center;
    font-weight: 500;
}

.age-input {
    margin-bottom: 30px;
}

.age-input label {
    display: block;
    margin-bottom: 10px;
    font-weight: 500;
    color: #4a5568;
}

.age-input input {
    width: 100%;
    padding: 15px;
    border: 2px solid #e2e8f0;
    border-radius: 10px;
    font-size: 16px;
    transition: border-color 0.3s ease;
}

.age-input input:focus {
    outline: none;
    border-color: #667eea;
}

.btn-primary, .btn-secondary {
    padding: 12px 24px;
    border-radius: 8px;
    border: none;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    width: 100%;
    margin-bottom: 10px;
}

.btn-primary {
    background: linear-gradient(90deg, #e53e3e 0%, #ff6b81 100%);
    color: white;
    border: none;
    border-radius: 8px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    width: 100%;
    margin-bottom: 10px;
    padding: 12px 24px;
    transition: background 0.2s, box-shadow 0.2s;
}

.btn-secondary {
    background: #e2e8f0;
    color: #4a5568;
}

.btn-primary:hover {
    background: linear-gradient(90deg, #c53030 0%, #e53e3e 100%);
    color: #fff;
    box-shadow: 0 4px 12px rgba(229,62,62,0.18);
}

.btn-secondary:hover {
    background: #cbd5e0;
}

.btn-primary:disabled {
    background: #a0aec0;
    cursor: not-allowed;
    transform: none;
}

.disclaimer-content {
    max-height: 60vh;
    overflow-y: auto;
    padding: 10px;
    margin-bottom: 1rem;
    border-radius: 8px;
    background-color: #f8f9fa;
    border: 1px solid #e9ecef;
    font-size: 0.9rem;
    line-height: 1.6;
}

.disclaimer-content ul, .disclaimer-content p,
.important-reminder-list {
    font-size: 0.89em;
    color: #888;
}

.disclaimer-content li {
    padding: 8px 0;
    position: relative;
    padding-left: 25px;
}

.checkbox-group {
    display: flex;
    align-items: center;
    margin-bottom: 25px;
    padding: 15px;
    background: #f7fafc;
    border-radius: 10px;
}

.checkbox-group input[type="checkbox"] {
    margin-right: 10px;
    transform: scale(1.2);
}

.checkbox-group label {
    font-weight: 500;
    color: #4a5568;
}

.progress-bar {
    width: 100%;
    height: 8px;
    background: #e2e8f0;
    border-radius: 4px;
    margin-bottom: 15px;
    overflow: hidden;
}

.progress {
    height: 100%;
    background: linear-gradient(90deg, #e53e3e 0%, #ff6b81 100%);
    border-radius: 6px;
    transition: width 0.3s ease-in-out;
}

.progress-text {
    text-align: center;
    margin-bottom: 20px;
    color: #718096;
}

.question-emoji {
    font-size: 2em;
    display: block;
    text-align: center;
    margin-bottom: 15px;
}

.question-container {
    margin: 1.5rem 0;
    text-align: center;
}

#question-text {
    font-size: 6.0rem;
    font-weight: bold;
    margin-bottom: 1.5rem;
    line-height: 1.5;
    color: #333;
}

.large-question-text {
    font-size: 6.0rem !important;
    font-weight: bold !important;
    color: #333 !important;
}

.options {
    flex: 0 0 auto;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    justify-content: flex-start;
    min-height: 60px;
    margin-top: 18px;
    gap: 15px;
}

.option {
    padding: 20px;
    border: 2px solid #e2e8f0;
    border-radius: 10px;
    cursor: pointer;
    transition: all 0.3s ease;
    background: white;
}

.option:hover {
    border-color: #667eea;
    background: #f7fafc;
}

.option.selected {
    border-color: #667eea;
    background: #ebf8ff;
    color: #2b6cb0;
}

.option input[type="radio"] {
    margin-right: 10px;
    transform: scale(1.2);
}

.navigation {
    display: flex;
    justify-content: space-between;
    gap: 15px;
}

.navigation button {
    flex: 1;
    margin-bottom: 0;
}

.results-container {
    margin-bottom: 30px;
}

.result-summary {
    text-align: center;
    margin-bottom: 30px;
    padding: 20px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border-radius: 15px;
}

.overall-score {
    font-size: 3rem;
    font-weight: 700;
    margin: 10px 0;
}

.category-results {
    margin-bottom: 30px;
}

.category-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px;
    margin-bottom: 10px;
    background: #f7fafc;
    border-radius: 10px;
    border-left: 4px solid #667eea;
}

.category-name {
    font-weight: 600;
    color: #2d3748;
}

.category-score {
    font-weight: 700;
    color: #667eea;
}

.detailed-analysis {
    background: #f7fafc;
    padding: 20px;
    border-radius: 10px;
    line-height: 1.6;
}

.action-buttons {
    display: flex;
    flex-wrap: wrap;
    gap: 16px;
    justify-content: center;
    margin-top: 30px;
}

.action-buttons button {
    flex: 1;
    margin-bottom: 0;
}

@media (max-width: 768px) {
    .container {
        padding: 10px;
    }
    
    .card {
        padding: 25px;
    }
    
    h1 {
        font-size: 2rem;
    }
    
    .navigation {
        flex-direction: column;
    }
    
    .action-buttons {
        flex-direction: column;
    }
}

.age-buttons {
    margin-bottom: 30px;
    text-align: center;
}

.age-buttons p {
    font-size: 1.2rem;
    font-weight: 500;
    color: #4a5568;
    margin-bottom: 20px;
}

.button-group {
    display: flex;
    gap: 15px;
    justify-content: center;
}

.button-group button {
    flex: 1;
    max-width: 200px;
}

/* 评分方格样式 */
.rating-grid {
    display: grid;
    grid-template-columns: repeat(10, 1fr);
    gap: 4px;
    justify-content: center;
    margin: 0 auto;
    width: fit-content;
    min-width: 0; /* 防止内容溢出导致换行 */
}

.rating-box {
    width: 40px;
    height: 40px;
    background-color: #ccc;
    border: 1px solid #aaa;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    border-radius: 4px;
    transition: none; /* 移除渐变效果 */
    min-width: 30px; /* 允许在小屏幕上缩小，但保持比例 */
    font-size: clamp(12px, 1.2vw, 16px); /* 动态调整字体大小 */
}

.rating-box.hover-with-lower {
    background-color: #ffb6c1 !important;
    border-color: #ffb6c1 !important;
}

.rating-box.selected-with-lower {
    background-color: #e75480 !important;
    border-color: #e75480 !important;
    color: #fff !important;
}

.rating-labels {
    display: flex;
    align-items: center;
    margin-top: 2px;
    font-size: 0.98rem;
    color: #666;
    width: 100%;
    max-width: 420px;
    margin-left: auto;
    margin-right: auto;
    margin-bottom: 2px;
}
.rating-labels .label-left {
    flex: 0 0 60px;
    text-align: left;
    font-size: 0.97em;
}
.rating-labels .label-arrow {
    flex: 1;
    text-align: center;
    color: #6c63ff;
    opacity: 0.18;
    font-size: 1.1em;
    letter-spacing: 2px;
}
.rating-labels .label-right {
    flex: 0 0 70px;
    text-align: right;
    font-size: 1.03em;
}

.rating-explain {
    font-size: 0.9rem;
    margin-top: 0.5rem;
    text-align: center;
    color: #718096;
}
.rating-explain ul {
    margin: 0;
    padding: 0 0 0 18px;
}
.rating-explain li {
    font-size: 0.97rem;
    margin-bottom: 1px;
    list-style: decimal;
}

/* 结果页面专业蓝紫灰色系 */
#main-role .result-summary {
    margin-bottom: 30px;
    border-radius: 0;
    box-shadow: none;
    border: none;
    padding: 0 0 0 0;
    text-align: center;
    background: none;
    color: #3a3a5a;
}
.result-main-emoji {
    font-size: 3.2em;
    margin-bottom: 0.18em;
    display: block;
    text-align: center;
    margin-left: auto;
    margin-right: auto;
}
.result-main-title-lg {
    font-size: 2.1em;
    font-weight: 800;
    margin-bottom: 0.25em;
    color: #3a3a5a;
    text-align: center;
}
.result-main-title {
    font-size: 1.5em;
    font-weight: 700;
    margin-bottom: 0.2em;
    color: #3a3a5a;
}
.result-main-section {
    margin-bottom: 0.7em;
    font-size: 1.08em;
    color: #444;
}
.result-main-section strong {
    color: #6c63ff;
}

.category-item .category-emoji {
    font-size: 1.5em;
    margin-bottom: 0.1em;
    display: inline-block;
}

.social-buttons {
    display: flex;
    gap: 16px;
    justify-content: center;
    margin-top: 18px;
}
.btn-social {
    background: linear-gradient(90deg,#6c63ff 0%,#bfc6ff 100%);
    color: #fff;
    border: none;
    border-radius: 8px;
    padding: 10px 22px;
    font-size: 1.08em;
    font-weight: 600;
    text-decoration: none;
    transition: background 0.2s, box-shadow 0.2s;
    box-shadow: 0 2px 8px rgba(108,99,255,0.08);
    display: inline-block;
    text-align: center;
}
.btn-social:hover {
    background: linear-gradient(90deg,#bfc6ff 0%,#6c63ff 100%);
    color: #fff;
}

@media (max-width: 600px) {
    .container {
        max-width: 100vw;
        padding: 0 2vw;
    }
    .card {
        padding: 12px;
        max-width: 99vw;
    }
    .rating-box {
        width: 30px;
        height: 30px;
        font-size: 15px;
    }
    .result-summary h2 {
        font-size: 1.1rem !important;
    }
    .rating-grid {
        grid-template-columns: repeat(5, 1fr);
    }
    .disclaimer-content ul, .disclaimer-content p {
        font-size: 0.92em;
    }
    .result-main-emoji {
        font-size: 2em;
    }
    .result-other-emoji {
        font-size: 1.3em;
    }
    .result-main-title-lg {
        font-size: 1.3em;
    }
    .result-other-title {
        font-size: 1em;
    }
    .action-buttons {
        flex-direction: column;
        gap: 10px;
    }
}

.explain-inline {
    display: flex;
    justify-content: space-between;
    gap: 5px;
}

.explain-light {
    color: #a0aec0;
}

.rating-labels {
    font-size: 0.92rem;
    margin-top: 0px;
    margin-bottom: 0px;
}

.rating-labels .label-left, .rating-labels .label-right {
    font-size: 0.89em;
}

.rating-grid {
    margin-bottom: 0px;
}

.result-main-title-lg {
    font-size: 2.1em;
    font-weight: 800;
    margin-bottom: 0.25em;
    color: #3a3a5a;
    text-align: center;
}

.result-main-section-center {
    text-align: center;
}

.advice-list {
    margin: 0.2em 0 0.2em 0;
    padding: 0 0 0 1.2em;
    text-align: left;
    font-size: 1em;
}

.result-other-emoji {
    font-size: 2.2em;
    margin-bottom: 0.12em;
    display: block;
    text-align: center;
}

.result-other-title {
    font-size: 1.25em;
    font-weight: 700;
    margin-bottom: 0.18em;
    color: #3a3a5a;
    text-align: center;
    margin-left: auto;
    margin-right: auto;
}

.result-main-section.result-other-section {
    font-size: 0.98em;
    text-align: center;
    color: #555;
    margin-bottom: 0.5em;
}

.advice-list.result-other-advice {
    font-size: 0.98em;
    margin: 0.15em 0 0.15em 0;
    padding: 0 0 0 1.1em;
    text-align: left;
}

@media (max-width: 600px) {
    .explain-inline {
        flex-direction: column;
        align-items: center;
    }
    .result-main-title-lg {
        font-size: 1.3em;
    }
    .result-other-emoji {
        font-size: 1.3em;
    }
    .result-other-title {
        font-size: 1em;
    }
}

.important-reminder-list {
    list-style: disc inside;
    margin: 0.5em 0 0.5em 0;
    padding: 0;
}
.important-reminder-list li {
    margin-bottom: 0.2em;
    padding-left: 0.2em;
}

/* 结果页角色卡片间横线 */
.result-role-block {
    padding: 18px;
    border: 1px solid #e2e8f0;
    border-radius: 10px;
    margin-bottom: 18px;
    background: #f7fafc;
    box-shadow: 0 2px 8px rgba(108,99,255,0.04);
    text-align: center;
}
.result-role-block:last-child {
    border-bottom: none;
    margin-bottom: 0;
}

/* 百分比标注样式 */
.result-role-percent, .result-other-percent {
    font-size: 2.5em;
    font-weight: bold;
    color: #4a5568;
    text-align: center;
    margin: 15px 0;
}
.result-other-percent {
    text-align: left;
    margin-left: 0.2em;
}

/* 其它角色名称左对齐 */
.result-other-title {
    text-align: left;
    margin-left: 0;
    margin-right: 0;
}

.result-main-title-lg, .result-main-title, .result-other-title {
    color: #e53e3e !important;
}
.result-other-title {
    font-size: 1.35em;
    font-weight: 800;
    display: flex;
    align-items: center;
    gap: 0.32em;
}
.result-other-emoji {
    font-size: 2em;
    margin-bottom: 0;
    display: inline-block;
    vertical-align: middle;
    margin-right: 0.18em;
}

/* 广告容器样式 */
#ad-container {
    position: fixed;
    left: 0;
    bottom: 0;
    width: 100%;
    z-index: 999;
    text-align: center;
    background: #fff;
    box-shadow: 0 -2px 8px rgba(0,0,0,0.08);
    padding: 8px 0;
}

.ad-content {
    max-width: 728px;
    margin: 0 auto;
    padding: 0 15px;
}

@media (max-width: 600px) {
    #ad-container {
        width: 100%;
        left: 0;
        right: 0;
        bottom: 0;
        font-size: 0.95em;
    }
    .ad-content {
        padding: 0 10px;
    }
}

/* 年龄验证页样式 */
.age-verification-content {
    text-align: center;
    padding: 20px 0;
}

.warning-text {
    margin-bottom: 30px;
    color: #e53e3e;
}

.warning-text .warning {
    font-size: 1.2em;
    font-weight: bold;
    margin-bottom: 10px;
}

.age-buttons {
    margin-top: 20px;
}

.button-group {
    display: flex;
    gap: 15px;
    justify-content: center;
    margin-top: 15px;
}

/* 测试页样式 */
#question-text {
    font-size: 1.1em;
    margin-bottom: 20px;
    text-align: center;
}

.main-role {
    margin-bottom: 30px;
    padding: 20px;
    background: #f7fafc;
    border-radius: 8px;
}

.role-description {
    margin: 15px 0;
    line-height: 1.6;
}

.role-advice {
    margin-top: 20px;
}

.advice-list {
    list-style: none;
    padding: 0;
    margin: 10px 0;
}

.advice-list li {
    margin-bottom: 10px;
    padding-left: 20px;
    position: relative;
}

.advice-list li:before {
    content: "•";
    position: absolute;
    left: 0;
    color: #4a5568;
}

.result-other-title {
    font-size: 1.1em;
    font-weight: bold;
    margin-bottom: 10px;
}

.result-other-percent {
    font-size: 1.2em;
    color: #4a5568;
    margin: 10px 0;
}

.result-other-section {
    font-size: 0.95em;
    color: #718096;
}

.related-roles {
    margin: 30px 0;
}

.role-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 10px;
}

.role-tag {
    background: #f7fafc;
    padding: 5px 12px;
    border-radius: 15px;
    font-size: 0.9em;
}

.important-reminder {
    margin-top: 30px;
    padding: 20px;
    background: #fff5f5;
    border-radius: 8px;
}

.important-reminder-list {
    list-style: none;
    padding: 0;
    margin: 10px 0;
}

.important-reminder-list li {
    margin-bottom: 10px;
    padding-left: 20px;
    position: relative;
    color: #e53e3e;
}

.important-reminder-list li:before {
    content: "⚠️";
    position: absolute;
    left: 0;
}

.action-buttons {
    display: flex;
    flex-wrap: wrap;
    gap: 16px;
    justify-content: center;
    margin-top: 30px;
}

@media (max-width: 600px) {
    .rating-grid {
        grid-template-columns: repeat(5, 1fr);
    }
    
    .explain-inline {
        flex-direction: column;
        align-items: center;
    }
    
    .action-buttons {
        flex-direction: column;
    }
    
    .role-tags {
        justify-content: center;
    }
}

.title-emoji-top {
    font-size: 2.5em;
    text-align: center;
    margin-bottom: 0.1em;
    display: block;
}
.subtitle-age {
    text-align: center;
    font-size: 1.08em;
    color: #222;
    margin-bottom: 0.1em;
    font-weight: 500;
}
.subtitle-age-warn {
    color: #222;
    font-weight: 700;
    margin-bottom: 1.2em;
} 