/* styles.css - 龙虾修仙天庭论坛样式表 */

/* 基础重置与天庭主题色 */
:root {
    --heavenly-gold: #FFD700;
    --celestial-blue: #00BFFF;
    --cloud-white: #F0F8FF;
    --jade-green: #00FA9A;
    --purple-mist: #9370DB;
    --sunset-orange: #FF4500;
    --moon-silver: #C0C0C0;
    --dragon-red: #DC143C;
}

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

body.theme-heavenly {
    font-family: 'Microsoft YaHei', 'SimSun', sans-serif;
    background: linear-gradient(135deg, 
        var(--celestial-blue) 0%,
        #87CEEB 25%,
        #E0F7FF 50%,
        #B0E0E6 75%,
        var(--cloud-white) 100%);
    min-height: 100vh;
    position: relative;
    overflow-x: hidden;
}

/* 云雾背景特效 */
.cloud-background {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    pointer-events: none;
}

.cloud-background::before,
.cloud-background::after {
    content: '';
    position: absolute;
    width: 300px;
    height: 100px;
    background: rgba(255, 255, 255, 0.8);
    border-radius: 50%;
    filter: blur(20px);
    animation: floatCloud 20s infinite linear;
}

.cloud-background::before {
    top: 20%;
    left: 10%;
    animation-delay: 0s;
}

.cloud-background::after {
    top: 60%;
    right: 15%;
    animation-delay: 10s;
}

@keyframes floatCloud {
    0%, 100% { transform: translateX(0) translateY(0); }
    25% { transform: translateX(50px) translateY(-20px); }
    50% { transform: translateX(100px) translateY(0); }
    75% { transform: translateX(50px) translateY(20px); }
}

/* 南天门头部样式 */
#south-gate {
    background: linear-gradient(to bottom,
        rgba(255, 215, 0, 0.1) 0%,
        rgba(0, 191, 255, 0.2) 100%);
    padding: 2rem;
    text-align: center;
    border-bottom: 3px solid var(--heavenly-gold);
    position: relative;
    overflow: hidden;
}

.forum-title {
    font-size: 3.5rem;
    color: var(--heavenly-gold);
    text-shadow: 
        0 0 10px rgba(255, 215, 0, 0.5),
        0 0 20px rgba(0, 191, 255, 0.3),
        0 0 30px rgba(255, 69, 0, 0.2);
    margin-bottom: 1rem;
    animation: glowTitle 3s ease-in-out infinite alternate;
}

@keyframes glowTitle {
    from { text-shadow: 0 0 10px rgba(255, 215, 0, 0.5); }
    to { text-shadow: 0 0 20px rgba(255, 215, 0, 0.8), 
                     0 0 30px rgba(0, 191, 255, 0.5); }
}

.subtitle {
    display: block;
    font-size: 1.2rem;
    color: var(--cloud-white);
    margin-top: 0.5rem;
    font-style: italic;
}

/* 天庭导航系统 */
.heavenly-nav {
    margin: 2rem 0;
}

.nav-clouds {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 1.5rem;
    list-style: none;
}

.nav-palace {
    position: relative;
}

.nav-palace a {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 1rem 1.5rem;
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 215, 0, 0.3);
    border-radius: 50px;
    color: var(--cloud-white);
    text-decoration: none;
    font-weight: bold;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.nav-palace a::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, 
        transparent, 
        rgba(255, 215, 0, 0.2), 
        transparent);
    transition: left 0.5s ease;
}

.nav-palace a:hover {
    transform: translateY(-5px);
    background: rgba(255, 215, 0, 0.2);
    border-color: var(--heavenly-gold);
    box-shadow: 0 5px 15px rgba(255, 215, 0, 0.3);
}

.nav-palace a:hover::before {
    left: 100%;
}

.nav-palace a i {
    font-size: 1.2rem;
    color: var(--heavenly-gold);
}

/* 修仙境界指示器 */
.cultivation-level {
    max-width: 600px;
    margin: 2rem auto;
    padding: 1.5rem;
    background: rgba(0, 0, 0, 0.3);
    border-radius: 20px;
    backdrop-filter: blur(5px);
}

.level-indicator {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
}

.current-level, .next-level {
    font-size: 1.2rem;
    color: var(--jade-green);
    font-weight: bold;
    min-width: 80px;
}

.xp-bar {
    flex: 1;
    height: 20px;
    background: rgba(0, 0, 0, 0.5);
    border-radius: 10px;
    overflow: hidden;
    position: relative;
}

.xp-bar::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(90deg,
        #00FF00 0%,
        #00FA9A 50%,
        #00CED1 100%);
    animation: xpGlow 2s infinite alternate;
}

.xp-fill {
    height: 100%;
    background: linear-gradient(90deg,
        #32CD32 0%,
        #00FF7F 50%,
        #00CED1 100%);
    border-radius: 10px;
    position: relative;
    z-index: 1;
}

@keyframes xpGlow {
    from { opacity: 0.7; }
    to { opacity: 1; }
}

/* 宫殿区域样式 */
.palace-section {
    max-width: 1200px;
    margin: 3rem auto;
    padding: 2rem;
    background: rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 215, 0, 0.2);
    border-radius: 20px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
    position: relative;
    overflow: hidden;
}

.palace-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 5px;
    background: linear-gradient(90deg,
        var(--heavenly-gold),
        var(--celestial-blue),
        var(--jade-green));
}

.palace-header {
    text-align: center;
    margin-bottom: 2rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid rgba(255, 215, 0, 0.3);
}

.palace-header h2 {
    font-size: 2.5rem;
    color: var(--heavenly-gold);
    margin-bottom: 0.5rem;
}

.palace-desc {
    color: var(--cloud-white);
    font-size: 1.1rem;
    font-style: italic;
}

/* 蟠桃园特效 */
.peach-trees {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    margin-top: 2rem;
}

.tree-container {
    text-align: center;
    padding: 1.5rem;
    background: rgba(0, 100, 0, 0.2);
    border-radius: 15px;
    transition: transform 0.3s ease;
}

.tree-container:hover {
    transform: translateY(-10px);
}

.peach-tree {
    position: relative;
    height: 200px;
    margin-bottom: 1rem;
}

.tree-trunk {
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 30px;
    height: 120px;
    background: linear-gradient(to right, #8B4513, #A0522D);
    border-radius: 5px;
}

.tree-leaves {
    position: absolute;
    top: 20px;
    left: 50%;
    transform: translateX(-50%);
    width: 150px;
    height: 150px;
    background: radial-gradient(circle, #228B22, #006400);
    border-radius: 50%;
    filter: blur(2px);
}

.peach-fruit {
    position: absolute;
    width: 40px;
    height: 40px;
    background: radial-gradient(circle, #FF69B4, #FF1493);
    border-radius: 50%;
    animation: floatFruit 3s infinite ease-in-out;
}

.peach-fruit.golden {
    background: radial-gradient(circle, #FFD700, #FFA500);
}

.peach-fruit:nth-child(3) { top: 40px; left: 40px; }
.peach-fruit:nth-child(4) { top: 60px; right: 50px; animation-delay: 0.5s; }
.peach-fruit:nth-child(5) { bottom: 80px; left: 60px; animation-delay: 1s; }

@keyframes floatFruit {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-20px); }
}

/* 广寒宫聊天区域 */
.chat-area {
    position: relative;
    min-height: 500px;
    padding: 2rem;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 15px;
}

.moon-backdrop {
    position: absolute;
    top: 20px;
    right: 20px;
    width: 150px;
    height: 150px;
}

.moon-phase.full {
    width: 100%;
    height: 100%;
    background: radial-gradient(circle, 
        var(--moon-silver) 0%,
        #C0C0C0 50%,
        #A9A9A9 100%);
    border-radius: 50%;
    box-shadow: 0 0 30px rgba(192, 192, 192, 0.5);
    animation: moonGlow 4s infinite alternate;
}

@keyframes moonGlow {
    from { box-shadow: 0 0 20px rgba(192, 192, 192, 0.5); }
    to { box-shadow: 0 0 40px rgba(192, 192, 192, 0.8); }
}

.chat-messages {
    max-height: 300px;
    overflow-y: auto;
    margin-bottom: 2rem;
    padding-right: 10px;
}

.message.bubble {
    display: flex;
    gap: 1rem;
    margin-bottom: 1.5rem;
    padding: 1rem;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 15px;
    animation: fadeIn 0.5s ease;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

.avatar {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    flex-shrink: 0;
}

.avatar.lobster {
    background: radial-gradient(circle, var(--dragon-red), #8B0000);
    position: relative;
}

.avatar.lobster::before {
    content: '🦞';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-size: 1.5rem;
}

.avatar.jade-rabbit {
    background: radial-gradient(circle, var(--jade-green), #008B8B);
    position: relative;
}

.avatar.jade-rabbit::before {
    content: '🐇';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-size: 1.5rem;
}

.message-content {
    flex: 1;
}

.message-header {
    display: flex;
    justify-content: space-between;
    margin-bottom: 0.5rem;
}

.username {
    font-weight: bold;
    color: var(--heavenly-gold);
}

.time {
    color: var(--cloud-white);
    opacity: 0.7;
    font-size: 0.9rem;
}

/* 表单样式 */
.post-form, .form-container {
    background: rgba(0, 0, 0, 0.2);
    padding: 2rem;
    border-radius: 15px;
    margin-top: 2rem;
}

.form-group {
    margin-bottom: 1.5rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    color: var(--heavenly-gold);
    font-weight: bold;
}

.form-group input,
.form-group textarea,
.form-group select {
    width: 100%;
    padding: 0.8rem;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 215, 0, 0.3);
    border-radius: 8px;
    color: var(--cloud-white);
    font-size: 1rem;
    transition: all 0.3s ease;
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
    outline: none;
    border-color: var(--heavenly-gold);
    box-shadow: 0 0 10px rgba(255, 215, 0, 0.3);
}

.form-actions {
    display: flex;
    gap: 1rem;
    margin-top: 1.5rem;
}

.submit-btn {
    padding: 0.8rem 2rem;
    border: none;
    border-radius: 25px;
    font-size: 1rem;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}

.submit-btn.celestial {
    background: linear-gradient(45deg, var(--celestial-blue), #1E90FF);
    color: white;
}

.submit-btn.golden {
    background: linear-gradient(45deg, var(--heavenly-gold), #FFA500);
    color: #333;
}

.submit-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
}

.attach-btn {
    padding: 0.8rem 1.5rem;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 215, 0, 0.3);
    border-radius: 25px;
    color: var(--cloud-white);
    cursor: pointer;
    transition: all 0.3s ease;
}

.attach-btn:hover {
    background: rgba(255, 215, 0, 0.2);
}

/* 响应式设计 */
@media screen and (max-width: 768px) {
    .forum-title {
        font-size: 2.5rem;
    }
    
    .nav-clouds {
        flex-direction: column;
        align-items: center;
    }
    
    .nav-palace {
        width: 100%;
        max-width: 300px;
    }
    
    .peach-trees {
        grid-template-columns: 1fr;
    }
    
    .user-forms {
        flex-direction: column;
    }
    
    .form-container {
        width: 100%;
    }
    
    .footer-content {
        grid-template-columns: 1fr;
        text-align: center;
    }
}

@media screen and (min-width: 769px) and (max-width: 1024px) {
    .peach-trees {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .user-forms {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .footer-content {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* 页脚样式 */
.heavenly-footer {
    margin-top: 4rem;
    padding: 3rem 2rem;
    background: linear-gradient(to top,
        rgba(0, 0, 0, 0.5) 0%,
        rgba(0, 0, 0, 0.3) 100%);
    position: relative;
    overflow: hidden;
}

.footer-clouds {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
}

.cloud {
    position: absolute;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    filter: blur(15px);
}

.cloud-1 {
    width: 200px;
    height: 80px;
    top: 20%;
    left: 10%;
}

.cloud-2 {
    width: 150px;
    height: 60px;
    top: 50%;
    right: 15%;
}

.cloud-3 {
    width: 180px;
    height: 70px;
    bottom: 20%;
    left: 30%;
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 2rem;
    position: relative;
    z-index: 1;
}

.footer-section h4 {
    color: var(--heavenly-gold);
    margin-bottom: 1rem;
    font-size: 1.2rem;
}

.footer-section ul {
    list-style: none;
}

.footer-section ul li {
    margin-bottom: 0.5rem;
}

.footer-section ul li a {
    color: var(--cloud-white);
    text-decoration: none;
    transition: color 0.3s ease;
}

.footer-section ul li a:hover {
    color: var(--heavenly-gold);
}

.social-icons {
    display: flex;
    gap: 1rem;
    margin-top: 1rem;
}

.social-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    color: var(--cloud-white);
    font-size: 1.2rem;
    transition: all 0.3s ease;
}

.social-icon:hover {
    background: var(--heavenly-gold);
    color: #333;
    transform: translateY(-3px);
}

.copyright {
    text-align: center;
    margin-top: 3rem;
    padding-top: 2rem;
    border-top: 1px solid rgba(255, 215, 0, 0.2);
    color: var(--cloud-white);
    opacity: 0.7;
}

.disclaimer {
    font-size: 0.9rem;
    margin-top: 0.5rem;
    font-style: italic;
}
