/**
 * WEKits 首页功能样式：广播栏和底部导航模块
 */

/* ====== 顶部广播栏 ====== */
.broadcast-bar {
    width: 100%;
    height: 50px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    display: flex;
    align-items: center;
    padding: 0 20px;
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.3);
    position: fixed;
    top: 0;
    left: 0;
    z-index: 1000;
    animation: broadcastSlideDown 0.5s ease-out;
}

@keyframes broadcastSlideDown {
    from {
        transform: translateY(-100%);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

.broadcast-icon {
    font-size: 24px;
    margin-right: 15px;
    animation: broadcastPulse 2s ease-in-out infinite;
}

@keyframes broadcastPulse {
    0%, 100% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.1);
    }
}

.broadcast-content {
    flex: 1;
    overflow: hidden;
    position: relative;
    height: 100%;
    display: flex;
    align-items: center;
}

.broadcast-messages {
    position: absolute;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
}

.broadcast-message {
    position: absolute;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    font-size: 16px;
    font-weight: 500;
    opacity: 0;
    transform: translateY(20px);
    transition: all 0.5s ease;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.broadcast-message.active {
    opacity: 1;
    transform: translateY(0);
}

/* ====== 底部导航模块 ====== */
.footer-nav {
    width: 100%;
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    border-radius: 12px;
    padding: 20px;
    margin-bottom: 20px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
}

.footer-nav-title {
    font-size: 16px;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.9);
    margin-bottom: 15px;
    text-align: center;
}

.footer-nav-links {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 12px;
}

.footer-nav-link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 18px;
    background: rgba(255, 255, 255, 0.15);
    border: 1px solid rgba(255, 255, 255, 0.3);
    border-radius: 20px;
    color: white;
    text-decoration: none;
    font-size: 14px;
    font-weight: 500;
    transition: all 0.3s ease;
    backdrop-filter: blur(5px);
}

.footer-nav-link:hover {
    background: rgba(255, 255, 255, 0.25);
    border-color: rgba(255, 255, 255, 0.5);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

.footer-nav-icon {
    font-size: 16px;
}

.footer-nav-text {
    white-space: nowrap;
}

/* ====== 响应式适配 ====== */
@media (max-width: 768px) {
    .broadcast-bar {
        height: 40px;
        padding: 0 15px;
    }
    
    .broadcast-icon {
        font-size: 20px;
        margin-right: 10px;
    }
    
    .broadcast-message {
        font-size: 14px;
    }
    
    .footer-nav {
        padding: 15px;
        margin-bottom: 15px;
    }
    
    .footer-nav-title {
        font-size: 14px;
        margin-bottom: 12px;
    }
    
    .footer-nav-links {
        gap: 8px;
    }
    
    .footer-nav-link {
        padding: 8px 14px;
        font-size: 13px;
    }
    
    .footer-nav-icon {
        font-size: 14px;
    }
}

/* ====== 深色模式适配（预留） ====== */
@media (prefers-color-scheme: dark) {
    .footer-nav {
        background: rgba(0, 0, 0, 0.3);
    }
}

/* ====== 公告弹窗 ====== */
.announcement-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.6);
    z-index: 2000;
    backdrop-filter: blur(8px);
}

.announcement-modal.visible {
    display: flex;
    align-items: center;
    justify-content: center;
}

.announcement-content {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-radius: 16px;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5),
                0 0 0 1px rgba(255, 255, 255, 0.1);
    width: 90%;
    max-width: 520px;
    padding: 0;
    animation: announcementSlideDown 0.4s cubic-bezier(0.16, 1, 0.3, 1);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

@keyframes announcementSlideDown {
    from {
        transform: translateY(-30px) scale(0.95);
        opacity: 0;
    }
    to {
        transform: translateY(0) scale(1);
        opacity: 1;
    }
}

.announcement-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 24px 28px;
    border-bottom: 1px solid rgba(0, 0, 0, 0.08);
}

.announcement-header h3 {
    margin: 0;
    font-size: 20px;
    font-weight: 600;
    color: #1a1a1a;
    letter-spacing: -0.5px;
}

.announcement-close {
    background: rgba(0, 0, 0, 0.05);
    border: none;
    font-size: 28px;
    cursor: pointer;
    color: #666;
    padding: 0;
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: all 0.3s ease;
}

.announcement-close:hover {
    background: rgba(0, 0, 0, 0.1);
    color: #333;
    transform: rotate(90deg);
}

.announcement-body {
    padding: 28px;
}

.announcement-body p {
    margin: 0;
    line-height: 1.6;
    color: #666;
}

.announcement-footer {
    padding: 15px 20px;
    text-align: right;
    border-top: 1px solid #eee;
}

.btn-announcement {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    padding: 10px 25px;
    border-radius: 5px;
    cursor: pointer;
    font-size: 14px;
    transition: all 0.3s ease;
}

.btn-announcement:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(102, 126, 234, 0.4) ;
}

/* 公告类型样式 */
.type-info {
    border-left: 4px solid #667eea;
}

.type-warning {
    border-left: 4px solid #f39c12;
}

.type-error {
    border-left: 4px solid #e74c3c;
}
