/* navbar.css - 精简版 */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    background: var(--bg-primary);
    border-bottom: none !important;
    box-shadow: none !important;
    z-index: 1000;
    height: 60px;
    transition: all .3s ease;
}
.navbar.scrolled {
    background: var(--bg-primary);
    box-shadow: none !important;
}

.nav-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 100%;
    padding: 0 var(--container-padding-xs);
    max-width: 1200px;
    margin: 0 auto;
}
@media (min-width:576px) { .nav-container { padding: 0 var(--container-padding-sm); } }
@media (min-width:768px) { .nav-container { padding: 0 var(--container-padding-md); } }
@media (min-width:992px) { .nav-container { padding: 0 var(--container-padding-lg); } }
@media (min-width:1200px) { .nav-container { padding: 0 var(--container-padding-xl); } }

.nav-brand {
    display: flex;
    align-items: center;
    gap: 12px;
    text-decoration: none;
    color: inherit;
}
.navbar .nav-brand .logo {
    width: 36px;
    height: 36px;
    background: #fff !important;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-primary);
    font-size: 18px;
    transition: var(--transition);
    border: 1px solid var(--border-color);
    box-shadow: 0 1px 3px rgba(0,0,0,.1);
    overflow: hidden;
    padding: 2px;
    box-sizing: border-box;
}
.navbar .nav-brand .logo i { color: var(--text-primary) !important; font-size: 18px; }
.nav-brand:hover .logo { transform: scale(1.05); border-color: var(--border-color); }
.logo img { width:100%; height:100%; object-fit:contain; display:block; border-radius:6px; }

.brand-text-container {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: flex-start;
    gap: 4px;
    line-height: 1;
}
.brand-text {
    font-weight: 700;
    font-size: 17px;
    color: var(--text-primary);
    white-space: nowrap;
    line-height: 1.1;
}
.brand-subtitle {
    font-size: 12px;
    color: var(--text-secondary);
    font-weight: 500;
    letter-spacing: .5px;
    white-space: nowrap;
    opacity: .8;
    line-height: 1.1;
}

.nav-actions { display: flex; gap: 16px; position: relative; }
.nav-btn {
    width: 36px;
    height: 36px;
    border: none;
    background: var(--bg-secondary);
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: var(--transition);
    color: var(--text-primary);
    position: relative;
}
.nav-btn:hover { background: var(--primary-color); color: #fff; transform: translateY(-2px); }
.nav-btn.active { background: rgba(74,144,226,.2); color: var(--primary-color); transform: scale(1.05); }
.nav-btn.active:hover { background: rgba(74,144,226,.3); }

.music-btn.active { animation: pulse 2s infinite; }
@keyframes pulse {
    0% { box-shadow: 0 0 0 0 rgba(74,144,226,.7); }
    70% { box-shadow: 0 0 0 10px rgba(74,144,226,0); }
    100% { box-shadow: 0 0 0 0 rgba(74,144,226,0); }
}

.nav-badge {
    position: absolute;
    top: -5px;
    right: -5px;
    background: var(--error-color);
    color: #fff;
    border-radius: 50%;
    width: 16px;
    height: 16px;
    font-size: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    animation: bounce 2s infinite;
    transform: scale(0);
    transition: transform .3s ease;
    z-index: 1001;
    box-shadow: 0 2px 4px rgba(0,0,0,.2);
    font-weight: 700;
}
.nav-badge.show { transform: scale(1); }
@keyframes bounce {
    0%,20%,50%,80%,100% { transform: translateY(0) scale(1); }
    40% { transform: translateY(-3px) scale(1.1); }
    60% { transform: translateY(-2px) scale(1.05); }
}

.announcement-btn.has-unread { animation: gentle-pulse 3s infinite; }
@keyframes gentle-pulse {
    0%,100% { box-shadow: 0 0 0 0 rgba(239,68,68,.4); }
    50% { box-shadow: 0 0 0 6px rgba(239,68,68,0); }
}

#announcementBtn.active { background: #3764F4 !important; color: #fff !important; transition: none; }
#announcementBtn.active i { color: #fff !important; }

/* 暗色模式 */
@media (prefers-color-scheme:dark) {
    .navbar .nav-brand .logo { background: #fff !important; border-color: var(--border-color); }
    .navbar .nav-brand .logo i { color: var(--text-primary) !important; }
    .nav-brand:hover .logo { border-color: var(--border-color); }
    .brand-text { color: var(--text-primary); }
    .brand-subtitle { color: var(--text-secondary); }
}

/* 响应式 */
@media (min-width:768px) and (max-width:991px) {
    .brand-text { font-size:15px; }
    .brand-subtitle { font-size:12px; }
    .nav-actions { gap:18px; }
    .nav-btn { width:36px; height:36px; font-size:16px; }
    .nav-badge { width:18px; height:18px; font-size:11px; top:-6px; right:-6px; }
}
@media (max-width:767px) {
    .brand-text { font-size:16px; }
    .brand-subtitle { font-size:12px; display:none; }
}
@media (max-width:480px) {
    .navbar { height:60px; }
    .navbar .nav-brand .logo { width:36px; height:36px; padding:2px; font-size:16px; }
    .navbar .nav-brand .logo i { font-size:16px; }
    .brand-text { font-size:16px; }
    .brand-subtitle { display:none; }
    .nav-actions { gap:16px; }
    .nav-btn { width:36px; height:36px; font-size:15px; }
    .nav-badge { width:16px; height:16px; font-size:10px; top:-5px; right:-5px; }
}
@media (max-width:360px) {
    .nav-actions { gap:12px; }
    .nav-btn { width:36px; height:36px; font-size:14px; }
    .navbar .nav-brand .logo { width:36px; height:36px; }
    .brand-text { font-size:15px; }
    .brand-subtitle { display:none; }
    .nav-badge { width:14px; height:14px; font-size:9px; top:-4px; right:-4px; }
}
@media (min-width:992px) { .brand-subtitle { display:block; } }
@media (min-width:1200px) {
    .brand-text { font-size:18px; }
    .brand-subtitle { font-size:13px; }
    .brand-text-container { gap:5px; }
}