* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Microsoft YaHei', Arial, sans-serif;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    min-height: 100vh;
    color: #333;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
}

.header {
    text-align: center;
    color: white;
    margin-bottom: 30px;
}

.header h1 {
    font-size: 2.5em;
    margin-bottom: 10px;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3);
}

.header p {
    font-size: 1.2em;
    opacity: 0.9;
}

.main-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 30px;
    margin-bottom: 40px;
}

.query-section {
    background: white;
    border-radius: 15px;
    padding: 25px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease;
}

.query-section:hover {
    transform: translateY(-5px);
}

.query-section h2 {
    color: #667eea;
    margin-bottom: 20px;
    font-size: 1.5em;
    border-bottom: 2px solid #667eea;
    padding-bottom: 10px;
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: bold;
    color: #555;
}

.form-group select,
.form-group input {
    width: 100%;
    padding: 12px;
    border: 2px solid #ddd;
    border-radius: 8px;
    font-size: 16px;
    transition: border-color 0.3s ease;
}

.form-group select:focus,
.form-group input:focus {
    outline: none;
    border-color: #667eea;
}

.btn {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    padding: 12px 30px;
    border-radius: 25px;
    font-size: 16px;
    cursor: pointer;
    transition: all 0.3s ease;
    width: 100%;
}

.btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(102, 126, 234, 0.4);
}

.result-section {
    grid-column: 1 / -1;
    margin-top: 20px;
}

.result-card {
    background: white;
    border-radius: 15px;
    padding: 25px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    margin-bottom: 20px;
}

.result-card h3 {
    color: #667eea;
    font-size: 1.8em;
    margin-bottom: 20px;
    text-align: center;
}

.overall-rating {
    text-align: center;
    margin-bottom: 25px;
    padding: 15px;
    background: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
    border-radius: 10px;
    color: white;
}

.overall-rating .label {
    font-size: 1.2em;
    margin-right: 10px;
}

.stars {
    font-size: 1.5em;
    color: #ffd700;
}

.period-info {
    text-align: center;
    margin-bottom: 15px;
}

.period {
    background: #667eea;
    color: white;
    padding: 5px 15px;
    border-radius: 20px;
    font-size: 0.9em;
}

.fortune-details {
    display: grid;
    gap: 15px;
}

.fortune-item {
    padding: 15px;
    background: #f8f9ff;
    border-radius: 8px;
    border-left: 4px solid #667eea;
}

.fortune-item strong {
    color: #667eea;
    margin-right: 10px;
}

.lucky-info {
    color: #e74c3c;
    font-weight: bold;
}

.bazi-info {
    background: #f0f8ff;
    padding: 20px;
    border-radius: 10px;
    margin-bottom: 20px;
}

.bazi-item {
    margin-bottom: 10px;
    font-size: 1.1em;
}

.knowledge-section {
    background: white;
    border-radius: 15px;
    padding: 25px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    margin-bottom: 30px;
}

.knowledge-section h2 {
    color: #667eea;
    margin-bottom: 20px;
    font-size: 1.8em;
    text-align: center;
}

.knowledge-content {
    line-height: 1.8;
    color: #555;
}

.knowledge-content h3 {
    color: #764ba2;
    margin: 20px 0 10px 0;
    font-size: 1.3em;
}

.knowledge-content ul {
    margin-left: 20px;
    margin-bottom: 15px;
}

.knowledge-content li {
    margin-bottom: 8px;
}

.error {
    background: #ffe6e6;
    color: #d63031;
    padding: 15px;
    border-radius: 8px;
    border: 1px solid #fab1a0;
    text-align: center;
}

.current-info {
    background: rgba(255, 255, 255, 0.1);
    color: white;
    padding: 15px;
    border-radius: 10px;
    margin-bottom: 20px;
    text-align: center;
}

.tabs {
    display: flex;
    margin-bottom: 20px;
    background: #f1f3f4;
    border-radius: 10px;
    padding: 5px;
}

.tab {
    flex: 1;
    padding: 12px;
    text-align: center;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-weight: bold;
}

.tab.active {
    background: #667eea;
    color: white;
}

.tab-content {
    display: none;
}

.tab-content.active {
    display: block;
}

/* 推荐区域样式 */
.recommend-section {
    background: white;
    border-radius: 15px;
    padding: 25px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    margin-bottom: 30px;
}

.recommend-section h2 {
    color: #667eea;
    margin-bottom: 20px;
    font-size: 1.8em;
    text-align: center;
    border-bottom: 2px solid #667eea;
    padding-bottom: 10px;
}

.recommend-card {
    background: linear-gradient(135deg, #ffecd2 0%, #fcb69f 100%);
    border-radius: 12px;
    padding: 20px;
    margin-bottom: 20px;
}

.recommend-card h3 {
    color: #d63031;
    margin-bottom: 15px;
    font-size: 1.4em;
}

.recommend-card p {
    line-height: 1.8;
    color: #2d3436;
}

/* 文章区域样式 */
.article-section {
    background: white;
    border-radius: 15px;
    padding: 25px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    margin-bottom: 30px;
}

.article-section h2 {
    color: #667eea;
    margin-bottom: 20px;
    font-size: 1.8em;
    text-align: center;
    border-bottom: 2px solid #667eea;
    padding-bottom: 10px;
}

.article-card {
    border: 1px solid #e9ecef;
    border-radius: 12px;
    padding: 20px;
    margin-bottom: 20px;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.article-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.1);
}

.article-card h3 {
    color: #2d3436;
    margin-bottom: 10px;
    font-size: 1.3em;
}

.article-summary {
    color: #636e72;
    font-style: italic;
    margin-bottom: 15px;
    font-size: 0.95em;
}

.article-content {
    line-height: 1.8;
    color: #2d3436;
}

/* SEO内容区域样式 */
.seo-section {
    background: white;
    border-radius: 15px;
    padding: 25px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    margin-bottom: 30px;
}

.seo-section h2 {
    color: #667eea;
    margin-bottom: 20px;
    font-size: 1.8em;
    text-align: center;
    border-bottom: 2px solid #667eea;
    padding-bottom: 10px;
}

.seo-content {
    line-height: 1.8;
    color: #2d3436;
}

.seo-content h3 {
    color: #667eea;
    margin: 25px 0 15px 0;
    font-size: 1.4em;
}

.seo-content ul,
.seo-content ol {
    margin-left: 25px;
    margin-bottom: 20px;
}

.seo-content li {
    margin-bottom: 10px;
}

.highlight-box {
    background: linear-gradient(135deg, #a8edea 0%, #fed6e3 100%);
    border-radius: 10px;
    padding: 20px;
    margin: 20px 0;
    border-left: 4px solid #667eea;
}

.highlight-box h4 {
    color: #2d3436;
    margin-bottom: 10px;
    font-size: 1.2em;
}

/* FAQ区域样式 */
.faq-section {
    background: white;
    border-radius: 15px;
    padding: 25px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    margin-bottom: 30px;
}

.faq-section h2 {
    color: #667eea;
    margin-bottom: 20px;
    font-size: 1.8em;
    text-align: center;
    border-bottom: 2px solid #667eea;
    padding-bottom: 10px;
}

.faq-item {
    border: 1px solid #e9ecef;
    border-radius: 8px;
    margin-bottom: 15px;
    overflow: hidden;
    transition: box-shadow 0.3s ease;
}

.faq-item:hover {
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.faq-question {
    background: #f8f9fa;
    padding: 15px 20px;
    cursor: pointer;
    font-weight: bold;
    color: #2d3436;
    border-bottom: 1px solid #e9ecef;
    position: relative;
    transition: background-color 0.3s ease;
}

.faq-question:hover {
    background: #e9ecef;
}

.faq-question::after {
    content: '+';
    position: absolute;
    right: 20px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 1.2em;
    color: #667eea;
    transition: transform 0.3s ease;
}

.faq-question.active::after {
    transform: translateY(-50%) rotate(45deg);
}

.faq-answer {
    padding: 15px 20px;
    line-height: 1.8;
    color: #555;
    display: none;
    background: white;
}

.faq-answer.active {
    display: block;
}

/* 响应式设计 */
@media (max-width: 768px) {
    .main-content {
        grid-template-columns: 1fr;
        gap: 20px;
    }

    .header h1 {
        font-size: 2em;
    }

    .container {
        padding: 15px;
    }

    .query-section,
    .recommend-section,
    .article-section,
    .seo-section,
    .faq-section {
        padding: 20px;
    }

    .tabs {
        flex-direction: column;
    }

    .tab {
        margin-bottom: 5px;
    }
}

.tab {
    font-size: 14px;
    padding: 8px 12px;
}

/* 动态广告按钮样式 */
.ad-section {
    margin-top: 25px;
    text-align: center;
}

.ad-divider {
    height: 2px;
    background: linear-gradient(90deg, transparent, #667eea, transparent);
    margin-bottom: 20px;
    border-radius: 1px;
}

.dynamic-ad-btn {
    display: inline-block;
    padding: 15px 30px;
    border-radius: 50px;
    text-decoration: none;
    font-weight: bold;
    font-size: 16px;
    text-align: center;
    border: none;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
    margin-bottom: 15px;
    min-width: 280px;
}

.dynamic-ad-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.3);
    text-decoration: none;
    color: white !important;
}

.ad-note {
    font-size: 12px;
    color: #666;
    font-style: italic;
}

/* 动画效果 */
@keyframes pulse {
    0% {
        transform: scale(1);
    }

    50% {
        transform: scale(1.05);
    }

    100% {
        transform: scale(1);
    }
}

@keyframes glow {
    from {
        box-shadow: 0 0 5px rgba(255, 255, 255, 0.5);
    }

    to {
        box-shadow: 0 0 20px rgba(255, 255, 255, 0.8), 0 0 30px rgba(255, 255, 255, 0.6);
    }
}

@keyframes bounce {

    0%,
    20%,
    50%,
    80%,
    100% {
        transform: translateY(0);
    }

    40% {
        transform: translateY(-10px);
    }

    60% {
        transform: translateY(-5px);
    }
}

@keyframes shake {

    0%,
    100% {
        transform: translateX(0);
    }

    10%,
    30%,
    50%,
    70%,
    90% {
        transform: translateX(-2px);
    }

    20%,
    40%,
    60%,
    80% {
        transform: translateX(2px);
    }
}

@keyframes rotate {
    from {
        transform: rotate(0deg);
    }

    to {
        transform: rotate(360deg);
    }
}

@keyframes flash {

    0%,
    50%,
    100% {
        opacity: 1;
    }

    25%,
    75% {
        opacity: 0.7;
    }
}

@keyframes swing {
    20% {
        transform: rotate(15deg);
    }

    40% {
        transform: rotate(-10deg);
    }

    60% {
        transform: rotate(5deg);
    }

    80% {
        transform: rotate(-5deg);
    }

    100% {
        transform: rotate(0deg);
    }
}

@keyframes tada {
    0% {
        transform: scale(1);
    }

    10%,
    20% {
        transform: scale(0.9) rotate(-3deg);
    }

    30%,
    50%,
    70%,
    90% {
        transform: scale(1.1) rotate(3deg);
    }

    40%,
    60%,
    80% {
        transform: scale(1.1) rotate(-3deg);
    }

    100% {
        transform: scale(1) rotate(0);
    }
}

@keyframes heartbeat {
    0% {
        transform: scale(1);
    }

    14% {
        transform: scale(1.1);
    }

    28% {
        transform: scale(1);
    }

    42% {
        transform: scale(1.1);
    }

    70% {
        transform: scale(1);
    }
}

@keyframes wobble {
    0% {
        transform: translateX(0%);
    }

    15% {
        transform: translateX(-25%) rotate(-5deg);
    }

    30% {
        transform: translateX(20%) rotate(3deg);
    }

    45% {
        transform: translateX(-15%) rotate(-3deg);
    }

    60% {
        transform: translateX(10%) rotate(2deg);
    }

    75% {
        transform: translateX(-5%) rotate(-1deg);
    }

    100% {
        transform: translateX(0%);
    }
}

/* 友情链接区域样式 */
.links-section {
    background: white;
    border-radius: 15px;
    padding: 25px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    margin-bottom: 30px;
}

.links-section h2 {
    color: #667eea;
    margin-bottom: 20px;
    font-size: 1.8em;
    text-align: center;
    border-bottom: 2px solid #667eea;
    padding-bottom: 10px;
}

.links-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 15px;
    margin-top: 20px;
}

.links-grid a {
    display: block;
    padding: 12px 20px;
    background: linear-gradient(135deg, #f8f9ff 0%, #e8ecff 100%);
    border: 1px solid #e0e6ff;
    border-radius: 8px;
    text-decoration: none;
    color: #667eea;
    font-weight: 500;
    text-align: center;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.links-grid a::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(102, 126, 234, 0.1), transparent);
    transition: left 0.5s ease;
}

.links-grid a:hover::before {
    left: 100%;
}

.links-grid a:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(102, 126, 234, 0.2);
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border-color: #667eea;
}

/* 备案信息区域样式 */
.footer-section {
    background: linear-gradient(135deg, #2d3436 0%, #636e72 100%);
    border-radius: 15px;
    padding: 30px;
    text-align: center;
    margin-bottom: 20px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
}

.beian-info {
    margin-bottom: 15px;
}

.beian-info a {
    color: #ddd;
    text-decoration: none;
    font-size: 14px;
    padding: 8px 16px;
    border: 1px solid #74b9ff;
    border-radius: 20px;
    background: rgba(116, 185, 255, 0.1);
    transition: all 0.3s ease;
    display: inline-block;
}

.beian-info a:hover {
    background: #74b9ff;
    color: white;
    transform: translateY(-1px);
    box-shadow: 0 3px 10px rgba(116, 185, 255, 0.3);
}

.copyright {
    color: #b2bec3;
    font-size: 13px;
    line-height: 1.6;
}

.copyright p {
    margin: 0;
}

/* 响应式设计 - 友情链接 */
@media (max-width: 768px) {
    .links-grid {
        grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
        gap: 10px;
    }

    .links-grid a {
        padding: 10px 15px;
        font-size: 14px;
    }

    .footer-section {
        padding: 20px;
    }

    .beian-info a {
        font-size: 13px;
        padding: 6px 12px;
    }

    .copyright {
        font-size: 12px;
    }
}