/* 全局样式 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'PingFang SC', 'Microsoft YaHei', 'Segoe UI', sans-serif;
    line-height: 1.6;
    color: #333;
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    min-height: 100vh;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 90px 20px 40px;
}

/* 导航栏样式 */
.navbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 40px;
    background: linear-gradient(135deg, #fff 0%, #fefefe 100%);
    box-shadow: 0 4px 25px rgba(0, 0, 0, 0.1);
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    height: 70px;
    -webkit-backdrop-filter: blur(10px);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid rgba(255, 157, 0, 0.1);
}

.logo a {
    font-size: 28px;
    font-weight: 800;
    background: linear-gradient(135deg, #ff9d00, #ff6b00);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    text-decoration: none;
    letter-spacing: -0.5px;
    position: relative;
    display: flex;
    align-items: center;
}

.logo-image {
    max-height: 50px;
    width: auto;
    display: block;
    object-fit: contain;
}

/* APK下载链接样式 - 简约文字版 */
.apk-download-link {
    text-decoration: none;
    color: #666;
    font-size: 15px;
    font-weight: 600;
    transition: all 0.3s ease;
    padding: 8px 0;
    margin: 0 15px;
    position: relative;
}

.apk-download-link:hover {
    color: #ff9d00;
}

.apk-download-link::before {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background: linear-gradient(135deg, #ff9d00, #ff6b00);
    transition: width 0.3s ease;
}

.apk-download-link:hover::before {
    width: 100%;
}

.logo a:has(.logo-image)::after {
    display: none;
}

.logo a:not(:has(.logo-image))::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 100%;
    height: 2px;
    background: linear-gradient(135deg, #ff9d00, #ff6b00);
    transform: scaleX(0);
    transition: transform 0.3s ease;
}

.logo a:not(:has(.logo-image)):hover::after {
    transform: scaleX(1);
}

.nav-links {
    display: flex;
    list-style: none;
    gap: 30px;
    align-items: center;
}

.nav-links li {
    position: relative;
}

.nav-links a {
    text-decoration: none;
    color: #666;
    font-weight: 600;
    font-size: 15px;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    padding: 8px 0;
    position: relative;
}

.nav-links a::before {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background: linear-gradient(135deg, #ff9d00, #ff6b00);
    transition: width 0.3s ease;
}

.nav-links a:hover,
.nav-links a.active {
    color: #ff9d00;
    transform: translateY(-1px);
}

.nav-links a:hover::before,
.nav-links a.active::before {
    width: 100%;
}

/* 全局标题样式 */
h1 {
    margin-bottom: 20px;
    color: #333;
    font-size: 26px;
}

h2 {
    margin-bottom: 10px;
    color: #333;
    font-size: 16px;
    font-weight: 600;
}

h4 {
    margin-bottom: 8px;
    color: #555;
    font-size: 14px;
    font-weight: 500;
}

/* 全局表单样式 */
.form-group {
    margin-bottom: 8px;
}

label {
    display: block;
    margin-bottom: 6px;
    font-weight: 500;
    color: #444;
}

input[type="text"] {
    width: 100%;
    padding: 10px 12px;
    border: 1px solid #ddd;
    border-radius: 25px;
    font-size: 14px;
    transition: border-color 0.3s;
}

input[type="text"]:focus {
    border-color: #ff9d00;
    outline: none;
}

textarea {
    width: 100%;
    padding: 10px 12px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 14px;
    min-height: 80px;
    resize: vertical;
    transition: border-color 0.3s;
}

textarea:focus {
    border-color: #ff9d00;
    outline: none;
}

.char-count {
    font-size: 12px;
    color: #999;
    text-align: right;
    display: block;
    margin-top: 4px;
}

/* 全局页脚样式 */
footer {
    text-align: center;
    padding: 15px;
    margin-top: 30px;
    color: #999;
    font-size: 14px;
}

/* 用户状态样式 */
#user-status {
    margin-left: 25px;
    display: flex;
    align-items: center;
    gap: 10px;
}

/* 顶部导航栏头像通知角标 */
#user-status .user-avatar .notification-badge {
    position: absolute;
    top: -5px;
    right: -5px;
    background: linear-gradient(135deg, #ff6b35, #ff4757);
    color: white;
    font-size: 11px;
    font-weight: 700;
    padding: 2px 6px;
    border-radius: 10px;
    min-width: 18px;
    height: 18px;
    display: flex;
    align-items: center;
    justify-content: center;
    line-height: 1;
    box-shadow: 0 2px 8px rgba(255, 107, 53, 0.4);
    animation: badgePulse 2s infinite;
    z-index: 10;
}

@keyframes badgePulse {
    0%, 100% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.1);
    }
}

/* 管理员控制台角标 */
#user-status .admin-console-link .admin-badge {
    position: absolute;
    top: -8px;
    right: -8px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    font-size: 11px;
    font-weight: 700;
    padding: 2px 6px;
    border-radius: 10px;
    min-width: 18px;
    height: 18px;
    display: flex;
    align-items: center;
    justify-content: center;
    line-height: 1;
    box-shadow: 0 2px 8px rgba(102, 126, 234, 0.4);
    animation: adminBadgePulse 2s infinite;
    z-index: 10;
}

@keyframes adminBadgePulse {
    0%, 100% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.1);
    }
}

#user-status .user-avatar {
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    padding: 4px 8px;
    border-radius: 20px;
    transition: background-color 0.3s;
}

#user-status .user-avatar:hover {
    background-color: #f0f0f0;
}

#user-status .user-avatar img {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid #ff9d00;
}

#user-status .user-name {
    font-size: 14px;
    font-weight: 500;
}

/* 管理员控制台链接 */
#user-status .admin-console-link {
    padding: 6px 16px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    text-decoration: none;
    border-radius: 20px;
    font-size: 14px;
    font-weight: 500;
    transition: all 0.3s;
    box-shadow: 0 2px 8px rgba(102, 126, 234, 0.3);
}

#user-status .admin-console-link:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.4);
}

.user-name-truncated {
    color: #555;
    max-width: 80px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.guest-status {
    display: flex;
    align-items: center;
    gap: 4px;
    color: #999;
    text-decoration: none;
    padding: 6px 12px;
    border-radius: 20px;
    transition: all 0.3s;
    height: 32px;
}

.guest-status:hover {
    color: #ff9d00;
    background-color: #fff9f0;
}

.guest-status svg {
    color: inherit;
    flex-shrink: 0;
    width: 20px;
    height: 20px;
}

/* 全局响应式设计 */
@media (max-width: 768px) {
    .navbar {
        flex-direction: column;
        padding: 15px;
        height: auto;
        min-height: 70px;
    }

    .apk-download-link {
        margin: 10px 0;
        font-size: 14px;
    }

    .nav-links {
        margin-top: 10px;
        width: 100%;
        justify-content: space-around;
        flex-wrap: wrap;
        gap: 5px;
    }

    .nav-links li {
        margin: 0;
    }
    
    .container {
        padding-top: 130px;
    }
    
    @media (max-width: 480px) {
        .container {
            padding-top: 150px;
        }
        
        .apk-download-link {
            font-size: 13px;
            margin: 8px 0;
        }
    }
}
