/* Base styles */
body {
    font-family: 'Inter', system-ui, -apple-system, sans-serif;
    background-color: var(--t-bg);
    color: var(--t-text);
    line-height: 1.5;
    font-size: 16px;
    display: flex;
    min-height: 100vh;
    margin: 0;
    padding: 0;
    overflow-x: hidden;
    transition: background-color var(--transition-normal) ease,
                color var(--transition-normal) ease;
}

/* Force black background on auth/legal/home pages */
body:has(.vk-auth-page),
body:has(.vk-legal-page),
body:has(.home-page) {
    background-color: #000 !important;
}

h1, h2, h3, h4, h5, h6 {
    font-family: 'Plus Jakarta Sans', sans-serif;
    font-weight: 700;
    letter-spacing: -0.025em;
    line-height: 1.2;
    margin-bottom: 1rem;
}

h1 {
    font-size: 1.5rem;
}

h2 {
    font-size: 1.25rem;
}

h3 {
    font-size: 1rem;
}

a {
    color: var(--primary-600);
    text-decoration: none;
    transition: color var(--transition-fast) ease;
}

a:hover {
    color: var(--primary-700);
}

/* a {
    color: var(--primary-400);
}
 */
a:hover {
    color: var(--primary-300);
}

/* Utility classes */
.visually-hidden {
    position: absolute !important;
    width: 1px !important;
    height: 1px !important;
    padding: 0 !important;
    margin: -1px !important;
    overflow: hidden !important;
    clip: rect(0, 0, 0, 0) !important;
    white-space: nowrap !important;
    border: 0 !important;
}

/* Layout */
.app-container {
    display: flex;
    width: 100%;
    min-height: 100vh;
}

/* Sidebar */
.sidebar {
    width: var(--sidebar-width);
    background-color: white;
    border-right: 1px solid var(--gray-200);
    display: flex;
    flex-direction: column;
    position: fixed;
    top: 0;
    left: 0;
    height: 100vh;
    z-index: 1000;
    transition: transform var(--transition-normal) ease;
    overflow-y: auto;
    /* 隐藏滚动条 */
    scrollbar-width: none; /* Firefox */
    -ms-overflow-style: none; /* IE and Edge */
}

/* 隐藏Webkit浏览器的滚动条 */
.sidebar::-webkit-scrollbar {
    display: none;
}

.sidebar {
    background-color: var(--gray-800);
    border-right-color: var(--gray-700);
}

.sidebar-header {
    padding: 1.5rem;
    display: flex;
    align-items: center;
    border-bottom: 1px solid var(--gray-200);
    position: relative;
}

.sidebar-header {
    border-bottom-color: var(--gray-700);
}

.logo {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.logo-icon {
    width: 32px;
    height: 32px;
    background: linear-gradient(135deg, var(--primary-600), var(--primary-500));
    border-radius: var(--border-radius-sm);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-weight: bold;
    font-size: 1.25rem;
    box-shadow: var(--shadow-md);
}

.logo-text {
    font-family: 'Plus Jakarta Sans', sans-serif;
    font-weight: 800;
    font-size: 1.25rem;
    color: var(--gray-900);
    display: flex;
    flex-direction: column;
    line-height: 1.1;
}

.logo-text {
    color: white;
}

.logo-text-deja {
    color: var(--primary-600);
    font-size: 0.85rem;
    font-weight: 700;
    text-transform: lowercase;
}

.logo-text-deja {
    color: var(--primary-400);
}

.logo-text-vocab {
    font-size: 1.2rem;
}

.sidebar-menu {
    flex: 1;
    padding: 1rem 0.75rem;
}

.menu-category {
    color: var(--gray-500);
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    padding: 0 0.75rem;
    margin: 1rem 0 0.75rem 0;
}

.menu-category {
    color: var(--gray-400);
}

.menu-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.menu-item {
    margin: 0.25rem 0;
}

.menu-link {
    display: flex;
    align-items: center;
    padding: 0.75rem;
    border-radius: var(--border-radius);
    color: var(--gray-700);
    font-weight: 500;
    transition: all var(--transition-fast) ease;
}

.menu-link {
    color: var(--gray-300);
}

.menu-link:hover {
    background-color: var(--gray-100);
    color: var(--gray-900);
}

.menu-link:hover {
    background-color: var(--gray-700);
    color: white;
}

.menu-link.active {
    background-color: var(--primary-50);
    color: var(--primary-700);
}

.menu-link.active {
    background-color: rgba(59, 130, 246, 0.15);
    color: var(--primary-300);
}

.menu-link-locked { opacity: 0.5; }
.menu-link-locked:hover { opacity: 0.7; }
.menu-lock-icon { font-size: 0.55rem; margin-left: auto; opacity: 0.6; }

.menu-icon {
    margin-right: 0.75rem;
    font-size: 1.25rem;
    width: 1.5rem;
    text-align: center;
    opacity: 0.9;
}

.menu-badge {
    margin-left: auto;
    font-size: 0.75rem;
    background-color: var(--gray-200);
    color: var(--gray-700);
    padding: 0.125rem 0.5rem;
    border-radius: 1rem;
    font-weight: 500;
}

.menu-badge {
    background-color: var(--gray-700);
    color: var(--gray-300);
}


/* 微信弹窗样式 — 简约黑白 */
.wechat-modal .modal-content {
    border-radius: 12px;
    border: 1px solid var(--t-border);
    box-shadow: 0 16px 48px rgba(0,0,0,0.15);
    overflow: hidden;
    background: var(--t-bg);
}

.wechat-modal .modal-header {
    background: var(--t-bg);
    color: var(--t-text);
    border-bottom: 1px solid var(--t-border);
    padding: 1rem 1.25rem;
}

.wechat-modal .modal-header .btn-close {
    filter: var(--t-close-filter, none);
}

.wechat-modal .modal-title {
    font-weight: 600;
    font-size: 0.95rem;
    display: flex;
    align-items: center;
    gap: 0.4rem;
}

.wechat-modal .modal-body {
    padding: 1.5rem;
    text-align: center;
    background: var(--t-bg);
}

.wechat-qrcode {
    width: 180px;
    height: 180px;
    margin: 0 auto 1rem;
    border-radius: 10px;
    overflow: hidden;
    border: 1px solid var(--t-border);
}

.wechat-qrcode img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.wechat-group-text {
    font-size: 0.8rem;
    color: var(--t-text-muted);
    line-height: 1.5;
    margin: 0;
}

.wechat-features {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-top: 1rem;
    justify-content: center;
}

.wechat-feature {
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
    padding: 0.35rem 0.7rem;
    background: var(--t-bg-hover);
    border: 1px solid var(--t-border);
    border-radius: 6px;
    font-size: 0.72rem;
    color: var(--t-text-muted);
    font-weight: 500;
    cursor: default;
}

.wechat-feature i {
    font-size: 0.8rem;
}

@media (max-width: 640px) {
    .wechat-qrcode {
        width: 160px;
        height: 160px;
    }
}

/* 美化版配额显示模块样式 */
.quota-display-compact {
    margin: 0.75rem 1.5rem;
    padding: 0.75rem;
    background: linear-gradient(135deg, var(--primary-50), var(--primary-100));
    border: 1px solid var(--primary-200);
    border-radius: 0.75rem;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
    transition: all 0.2s ease;
}

.quota-display-compact:hover {
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
    transform: translateY(-1px);
}

.quota-display-compact {
    background: linear-gradient(135deg, var(--gray-800), var(--gray-750));
    border-color: var(--primary-700);
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

.quota-display-compact:hover {
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.3);
}

/* 推荐好友按钮样式 */
.quota-referral-section {
    margin-top: 0.75rem;
    margin-bottom: 0.5rem;
}

.quota-referral-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    width: 100%;
    padding: 0.6rem 1rem;
    background: linear-gradient(135deg, #f59e0b, #d97706);
    color: white;
    text-decoration: none;
    border-radius: 8px;
    font-size: 0.875rem;
    font-weight: 500;
    transition: all 0.2s ease;
    box-shadow: 0 2px 4px rgba(245, 158, 11, 0.2);
}

.quota-referral-btn:hover {
    background: linear-gradient(135deg, #d97706, #b45309);
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(245, 158, 11, 0.3);
    color: white;
    text-decoration: none;
}

.quota-referral-btn i {
    font-size: 1rem;
}

.quota-referral-btn {
    background: linear-gradient(135deg, #f59e0b, #d97706);
    box-shadow: 0 2px 4px rgba(245, 158, 11, 0.3);
}

.quota-referral-btn:hover {
    background: linear-gradient(135deg, #d97706, #b45309);
    box-shadow: 0 4px 8px rgba(245, 158, 11, 0.4);
}

.quota-header-compact {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 0.5rem;
}

.quota-icon {
    color: var(--primary-600);
    font-size: 0.875rem;
    animation: pulse 2s infinite;
}

.quota-icon {
    color: var(--primary-400);
}

@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.7; }
}

.quota-label {
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--gray-700);
}

.quota-label {
    color: var(--gray-300);
}

.quota-numbers {
    margin-left: auto;
    font-size: 0.75rem;
    font-weight: 700;
    color: var(--primary-700);
    font-family: 'SF Mono', 'Monaco', 'Consolas', monospace;
}

.quota-numbers {
    color: var(--primary-300);
}

.quota-progress-compact {
    width: 100%;
    height: 6px;
    background-color: var(--gray-200);
    border-radius: 3px;
    overflow: hidden;
    margin-bottom: 0.5rem;
    box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.1);
}

.quota-progress-compact {
    background-color: var(--gray-700);
    box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.3);
}

.quota-progress-bar-compact {
    height: 100%;
    background: linear-gradient(90deg, var(--primary-500), var(--primary-600));
    border-radius: 3px;
    transition: width 0.5s cubic-bezier(0.4, 0, 0.2, 1);
    width: 0%;
    position: relative;
    overflow: hidden;
}

.quota-progress-bar-compact::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.3), transparent);
    animation: shimmer 2s infinite;
}

@keyframes shimmer {
    0% { transform: translateX(-100%); }
    100% { transform: translateX(100%); }
}

.quota-status {
    font-size: 0.6875rem;
    color: var(--gray-600);
    text-align: center;
    font-weight: 500;
}

.quota-status {
    color: var(--gray-400);
}

/* 升级按钮样式 */
.quota-upgrade-section {
    margin-top: 0.75rem;
    padding-top: 0.75rem;
    border-top: 1px solid var(--gray-200);
}

.quota-upgrade-section {
    border-top-color: var(--gray-700);
}

/* 反馈按钮样式 */
.feedback-btn {
    background: linear-gradient(135deg, #10B981, #059669);
    color: white;
    padding: 8px 12px;
    border-radius: 12px;
    text-decoration: none;
    font-size: 0.85rem;
    font-weight: 500;
    transition: all 0.3s ease;
    box-shadow: 0 2px 8px rgba(16, 185, 129, 0.25);
    border: none;
}

.feedback-btn:hover {
    background: linear-gradient(135deg, #059669, #047857);
    color: white;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(16, 185, 129, 0.35);
    text-decoration: none;
}

.feedback-badge {
    background: rgba(255, 255, 255, 0.9);
    color: #10B981;
    font-size: 0.7rem;
    font-weight: 600;
    padding: 2px 6px;
    border-radius: 10px;
    margin-left: 6px;
    min-width: 18px;
    text-align: center;
}

.feedback-btn {
    background: linear-gradient(135deg, #059669, #047857);
    box-shadow: 0 2px 8px rgba(5, 150, 105, 0.4);
}

.feedback-btn:hover {
    background: linear-gradient(135deg, #10B981, #059669);
    box-shadow: 0 4px 12px rgba(5, 150, 105, 0.5);
}

.quota-upgrade-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    width: 100%;
    padding: 0.625rem 1rem;
    background: linear-gradient(135deg, #EF4444, #DC2626);
    color: white;
    text-decoration: none;
    border-radius: 0.5rem;
    font-size: 0.75rem;
    font-weight: 600;
    transition: all 0.2s ease;
    box-shadow: 0 2px 4px rgba(239, 68, 68, 0.2);
}

.quota-upgrade-btn:hover {
    background: linear-gradient(135deg, #DC2626, #B91C1C);
    color: white;
    text-decoration: none;
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(239, 68, 68, 0.3);
}

.quota-upgrade-btn i {
    font-size: 0.875rem;
}

/* Sidebar footer */
.sidebar-footer {
    padding: 1rem 1.5rem;
    border-top: 1px solid var(--gray-200);
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.sidebar-footer {
    border-top-color: var(--gray-700);
}

.user-dropdown {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.user-avatar {
    width: 2.5rem;
    height: 2.5rem;
    border-radius: 50%;
    background-color: var(--t-text-muted);
    color: var(--t-bg);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    font-size: 1rem;
}

.user-info {
    overflow: hidden;
}

.user-name {
    color: var(--gray-900);
    font-size: 0.875rem;
    font-weight: 600;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 150px;
}

.user-name {
    color: white;
}

.feedback-sidebar-button, .logout-button {
    background-color: transparent;
    color: var(--gray-500);
    border: none;
    width: 2rem;
    height: 2rem;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all var(--transition-fast) ease;
}

.feedback-sidebar-button:hover, .logout-button:hover {
    background-color: var(--gray-100);
    color: var(--gray-700);
}

.feedback-sidebar-button, .logout-button {
    color: var(--gray-400);
}

.feedback-sidebar-button:hover, .logout-button:hover {
    background-color: var(--gray-700);
    color: white;
}

/* 现代化下拉菜单样式 */
.modern-dropdown {
    border: none;
    border-radius: 12px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.15);
    padding: 8px;
    min-width: 240px;
    backdrop-filter: blur(10px);
    background: rgba(255, 255, 255, 0.95);
}

.modern-dropdown {
    background: rgba(31, 41, 55, 0.95);
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.3);
}

.dropdown-user-info {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 8px;
}

.dropdown-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: var(--t-text-muted);
    color: var(--t-bg);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    font-size: 16px;
}

.dropdown-user-details {
    flex: 1;
}

.dropdown-username {
    font-weight: 600;
    color: var(--gray-900);
    font-size: 14px;
    margin-bottom: 2px;
}

.dropdown-username {
    color: white;
}

.dropdown-user-status {
    font-size: 12px;
    color: var(--accent-green);
    font-weight: 500;
}

.modern-dropdown-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 12px;
    border-radius: 8px;
    transition: all 0.2s ease;
    color: var(--gray-700);
    text-decoration: none;
}

.modern-dropdown-item {
    color: var(--gray-300);
}

.modern-dropdown-item:hover {
    background: var(--gray-100);
    color: var(--gray-900);
    transform: translateX(2px);
}

.modern-dropdown-item:hover {
    background: var(--gray-700);
    color: white;
}

.modern-dropdown-item i {
    width: 16px;
    font-size: 16px;
    opacity: 0.8;
}

.logout-item:hover {
    background: rgba(239, 68, 68, 0.1);
    color: var(--accent-red);
}

.logout-item:hover {
    background: rgba(239, 68, 68, 0.2);
    color: #FCA5A5;
}

.modern-dropdown .dropdown-divider {
    margin: 8px 0;
    border-color: var(--gray-200);
}

.modern-dropdown .dropdown-divider {
    border-color: var(--gray-600);
}

/* Content area */
.content {
    flex: 1;
    margin-left: var(--sidebar-width);
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    transition: margin var(--transition-normal) ease-in-out;
}

.content-inner {
    flex: 1;
    padding: 2rem;
    max-width: 1600px;
    margin: 0 auto;
    width: 100%;
}

/* Mobile header */
.mobile-header {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: 4rem;
    background-color: white;
    border-bottom: 1px solid var(--gray-200);
    z-index: 1000;
    align-items: center;
    padding: 0 1rem;
    justify-content: space-between;
}

.mobile-controls {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.sidebar-toggle-mobile {
    width: 2.5rem;
    height: 2.5rem;
    border-radius: 50%;
    border: none;
    background-color: transparent;
    color: var(--gray-600);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all var(--transition-fast) ease;
}

.sidebar-toggle-mobile {
    color: var(--gray-300);
}

.sidebar-toggle-mobile:hover {
    background-color: var(--gray-100);
}

.sidebar-toggle-mobile:hover {
    background-color: var(--gray-700);
}

.mobile-header {
    background-color: var(--gray-800);
    border-bottom-color: var(--gray-700);
}

.menu-trigger {
    background-color: transparent;
    border: none;
    width: 2.5rem;
    height: 2.5rem;
    border-radius: var(--border-radius);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--gray-700);
    cursor: pointer;
    transition: all var(--transition-fast) ease;
}

.menu-trigger:hover {
    background-color: var(--gray-100);
}

.menu-trigger {
    color: var(--gray-300);
}

.menu-trigger:hover {
    background-color: var(--gray-700);
}

/* 主题切换按钮 */
.theme-toggle {
    width: 2.5rem;
    height: 2.5rem;
    border-radius: 50%;
    background-color: white;
    color: var(--gray-800);
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all var(--transition-fast) ease;
}

.mobile-header .theme-toggle {
    margin-left: auto;
    background-color: transparent;
    box-shadow: none;
}

.sidebar-controls {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    position: absolute;
    top: 50%;
    right: 1rem;
    transform: translateY(-50%);
    z-index: 5;
}

.sidebar-toggle {
    width: 2.5rem;
    height: 2.5rem;
    border-radius: 50%;
    border: none;
    background-color: var(--gray-100);
    color: var(--gray-600);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all var(--transition-fast) ease;
    box-shadow: var(--shadow-sm);
}

.sidebar-toggle {
    background-color: var(--gray-700);
    color: var(--gray-300);
}

.sidebar-toggle:hover {
    transform: scale(1.05);
    box-shadow: var(--shadow-md);
}

/* Sidebar edge collapse button */
.sidebar-edge-toggle {
    position: absolute;
    right: -14px;
    top: 50%;
    transform: translateY(-50%);
    width: 28px;
    height: 28px;
    border-radius: 50%;
    border: 1px solid var(--gray-200);
    background-color: white;
    color: var(--gray-500);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.2s ease;
    opacity: 0;
    z-index: 10;
    font-size: 0.75rem;
    box-shadow: 0 2px 6px rgba(0,0,0,0.1);
}

.sidebar-edge-toggle {
    background-color: var(--gray-700);
    border-color: var(--gray-600);
    color: var(--gray-400);
}

.sidebar:hover .sidebar-edge-toggle {
    opacity: 1;
}

.sidebar-edge-toggle:hover {
    background-color: var(--primary-500);
    border-color: var(--primary-500);
    color: white;
    transform: translateY(-50%) scale(1.1);
}

.sidebar-edge-toggle:hover {
    background-color: var(--primary-600);
    border-color: var(--primary-600);
    color: white;
}

@media (max-width: 768px) {
    .sidebar-edge-toggle {
        display: none;
    }
}

.sidebar-controls .theme-toggle {
    background-color: var(--gray-100);
    box-shadow: var(--shadow-sm);
}

.theme-toggle {
    background-color: var(--gray-800);
    color: var(--gray-200);
}

.mobile-header .theme-toggle {
    background-color: transparent;
}

.sidebar-controls .theme-toggle {
    background-color: var(--gray-700);
}

.theme-toggle:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

.mobile-header .theme-toggle:hover {
    transform: none;
    box-shadow: none;
}

.sidebar-controls .theme-toggle:hover {
    transform: scale(1.05);
}

/* Language Switcher */
.language-switcher {
    width: 2.5rem;
    height: 2.5rem;
    border-radius: 50%;
    border: none;
    background-color: var(--gray-100);
    color: var(--gray-700);
    font-size: 0.75rem;
    font-weight: 700;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all var(--transition-fast) ease;
    box-shadow: var(--shadow-sm);
}

.language-switcher {
    background-color: var(--gray-700);
    color: var(--gray-300);
}

.language-switcher:hover {
    transform: scale(1.05);
    box-shadow: var(--shadow-md);
    background-color: var(--primary-100);
    color: var(--primary-700);
}

.language-switcher:hover {
    background-color: var(--primary-900);
    color: var(--primary-300);
}

.theme-toggle-icon {
    font-size: 1.25rem;
}

/* 微信浮动按钮 — 简约小巧 */
.wechat-floating-button {
    position: fixed;
    bottom: 1.5rem;
    right: 1.5rem;
    display: flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.5rem 0.9rem;
    background: var(--t-text);
    color: var(--t-bg);
    border: none;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
    cursor: pointer;
    font-weight: 500;
    font-size: 0.75rem;
    z-index: 50;
    transition: opacity 0.2s;
}
.wechat-floating-button:hover { opacity: 0.85; }
.wechat-floating-button i { font-size: 0.9rem; }

/* Discord 浮动按钮 — 简约小巧 */
.discord-floating-button {
    position: fixed;
    bottom: 1.5rem;
    right: 1.5rem;
    display: flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.5rem 0.9rem;
    background: var(--t-text);
    color: var(--t-bg);
    border: none;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
    cursor: pointer;
    font-weight: 500;
    font-size: 0.75rem;
    z-index: 50;
    text-decoration: none;
    transition: opacity 0.2s;
}
.discord-floating-button:hover { opacity: 0.85; color: var(--t-bg); text-decoration: none; }
.discord-floating-button i { font-size: 0.9rem; }

/* Footer - Vercel style */
.footer {
    background-color: #000;
    border-top: 1px solid rgba(255,255,255,0.08);
    padding: 3rem 1.5rem 1.5rem;
    color: var(--t-text-dimmer);
    font-size: 0.8rem;
}

.footer {
    background-color: #000;
    border-top-color: rgba(255,255,255,0.08);
    color: var(--t-text-dimmer);
}

.footer-top {
    max-width: 1100px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    padding-bottom: 1rem;
    margin-bottom: 1rem;
    gap: 0.75rem;
}

.footer-desc {
    color: var(--t-text-muted);
    font-size: 0.8rem;
}
.footer-desc .footer-brand {
    color: var(--t-text);
    font-weight: 700;
}

.footer-links {
    display: flex;
    align-items: center;
    gap: 1.25rem;
    flex-wrap: wrap;
}

.footer-link {
    color: var(--t-text-dimmer);
    font-size: 0.8rem;
    text-decoration: none;
    transition: color 0.15s;
}

.footer-link:hover {
    color: var(--t-text);
}

.footer-social {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-top: 0.75rem;
}
.footer-social-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 32px; height: 32px;
    border-radius: 50%;
    color: var(--t-text-dimmer) !important;
    background: transparent;
    text-decoration: none !important;
    transition: color 0.15s, background 0.15s;
    font-size: 16px;
}
.footer-social-icon:hover {
    color: var(--t-text) !important;
    background: var(--t-bg-hover);
    text-decoration: none !important;
}

.footer-bottom {
    max-width: 1100px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.footer-copy {
    color: var(--t-text-dimmer);
    font-size: 0.75rem;
}

.footer-controls {
    display: flex;
    align-items: center;
    gap: 0.35rem;
}

.footer-ctrl-btn {
    width: 32px;
    height: 32px;
    border-radius: 6px;
    border: none;
    background: transparent;
    color: var(--t-text-dimmer);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.15s;
    font-size: 0.8rem;
}
.footer-ctrl-btn:hover {
    color: #fff;
    background: var(--t-bg-hover);
}
.footer-ctrl-btn.active {
    color: white;
    background: rgba(255,255,255,0.08);
}

/* Feedback button */

/* Feedback modal */
.modal-dialog {
    max-width: 500px;
    margin: 1.75rem auto;
}

.modal-content {
    background-color: white;
    border-radius: var(--border-radius);
    border: none;
    box-shadow: var(--shadow-xl);
    overflow: hidden;
}

.modal-content {
    background-color: var(--gray-800);
    color: var(--gray-200);
}

.modal-header {
    padding: 1.25rem 1.5rem;
    border-bottom: 1px solid var(--gray-200);
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.modal-header {
    border-color: var(--gray-700);
}

.modal-title {
    font-weight: 700;
    font-size: 1.25rem;
    color: var(--gray-900);
    margin: 0;
}

.modal-title {
    color: white;
}

.modal-body {
    padding: 1.5rem;
}

.modal-footer {
    padding: 1.25rem 1.5rem;
    border-top: 1px solid var(--gray-200);
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 0.75rem;
}

.modal-footer {
    border-color: var(--gray-700);
}

.btn-close {
    opacity: 0.75;
    transition: opacity 0.2s ease;
}

.btn-close:hover {
    opacity: 1;
}

/* 移动端模态框样式优化 */
@media (max-width: 640px) {
    .modal-dialog {
        margin: 1rem;
        max-width: calc(100% - 2rem);
    }
    
    .modal-body {
        padding: 1.25rem;
    }
    
    .modal-header, .modal-footer {
        padding: 1rem 1.25rem;
    }
    
    textarea.form-control {
        min-height: 100px;
    }
}

/* 表单样式 */
.form-label {
    color: var(--gray-700);
    font-weight: 500;
    font-size: 0.875rem;
    margin-bottom: 0.5rem;
}

.form-label {
    color: var(--gray-300);
}

.form-control, .form-select {
    border: 1px solid var(--gray-300);
    border-radius: var(--border-radius);
    font-size: 0.875rem;
    padding: 0.625rem 0.75rem;
    transition: border-color var(--transition-fast) ease, box-shadow var(--transition-fast) ease;
    background-color: white;
}

.form-control, .form-select {
    background-color: var(--gray-700);
    border-color: var(--gray-600);
    color: white;
}

.form-control:focus, .form-select:focus {
    border-color: var(--primary-400);
    box-shadow: 0 0 0 2px rgba(59, 130, 246, 0.25);
    outline: none;
}

.form-control:focus, .form-select:focus {
    box-shadow: 0 0 0 2px rgba(59, 130, 246, 0.5);
}

.form-control::placeholder {
    color: var(--gray-400);
}

.alert {
    border-radius: var(--border-radius);
    border: 1px solid transparent;
    padding: 1rem;
    margin-bottom: 1rem;
    font-size: 0.875rem;
}

.alert-success {
    background-color: var(--primary-50);
    border-color: var(--primary-200);
    color: var(--primary-800);
}

.alert-success {
    background-color: rgba(59, 130, 246, 0.2);
    border-color: rgba(59, 130, 246, 0.3);
    color: var(--primary-300);
}

/* 按钮样式 */
.btn {
    font-weight: 500;
    border-radius: var(--border-radius);
    padding: 0.5rem 1rem;
    font-size: 0.875rem;
    transition: all var(--transition-fast) ease;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.btn-sm {
    padding: 0.375rem 0.75rem;
    font-size: 0.75rem;
}

.btn-lg {
    padding: 0.75rem 1.5rem;
    font-size: 1rem;
}

.btn-primary {
    background-color: var(--primary-600);
    color: white;
    border: none;
}

.btn-primary:hover {
    background-color: var(--primary-700);
    transform: translateY(-1px);
}

.btn-primary:active {
    background-color: var(--primary-800);
    transform: translateY(0);
}

.btn-secondary {
    background-color: white;
    border: 1px solid var(--gray-300);
    color: var(--gray-700);
}

.btn-secondary:hover {
    background-color: var(--gray-50);
    color: var(--gray-900);
    transform: translateY(-1px);
}

.btn-secondary {
    background-color: var(--gray-700);
    border-color: var(--gray-600);
    color: var(--gray-200);
}

.btn-secondary:hover {
    background-color: var(--gray-600);
    color: white;
}

.btn-icon {
    margin-right: 0.5rem;
}

/* 吐司通知 */
.toast-container {
    position: fixed;
    bottom: 1.5rem;
    right: 1.5rem;
    z-index: 50;
}

.toast {
    background-color: white;
    border-radius: var(--border-radius);
    box-shadow: var(--shadow-lg);
    overflow: hidden;
    width: 300px;
    margin-top: 0.75rem;
}

.toast {
    background-color: var(--gray-800);
}

.toast-header {
    background-color: var(--primary-600);
    color: white;
    padding: 0.75rem 1rem;
    font-weight: 500;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.toast-body {
    padding: 1rem;
    color: var(--gray-700);
}

.toast-body {
    color: var(--gray-300);
}

/* 移动端吐司通知优化 */
@media (max-width: 640px) {
    .toast-container {
        right: 1rem;
        bottom: 6rem; /* 移动位置，避免被固定按钮遮挡 */
    }
    
    .toast {
        width: calc(100vw - 2rem);
        max-width: 350px;
    }
}

/* Utilities */
.d-none {
    display: none !important;
}

/* Desktop sidebar toggle */
.sidebar.hidden {
    transform: translateX(-100%);
}

.content {
    transition: margin-left 0.3s ease;
}

.sidebar.hidden ~ .content {
    margin-left: 0;
}

/* Sidebar show button */
.sidebar-show-btn {
    position: fixed;
    top: 50%;
    left: -3rem;
    transform: translateY(-50%);
    width: 2.5rem;
    height: 4rem;
    background-color: var(--primary-600);
    color: white;
    border: none;
    border-radius: 0 0.5rem 0.5rem 0;
    cursor: pointer;
    z-index: 1001;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.25rem;
    opacity: 0;
    visibility: hidden;
}

.sidebar-show-btn.show {
    left: 0;
    opacity: 1;
    visibility: visible;
}

.sidebar-show-btn:hover {
    background-color: var(--primary-700);
    transform: translateY(-50%) translateX(0.25rem);
}

.sidebar-show-btn {
    background-color: var(--primary-500);
}

.sidebar-show-btn:hover {
    background-color: var(--primary-600);
}

/* Responsive styles */
@media (max-width: 1024px) {
    .sidebar {
        transform: translateX(-100%);
    }
    
    .sidebar.show {
        transform: translateX(0);
    }
    
    .content {
        margin-left: 0;
    }
    
    /* Hide desktop sidebar toggle on mobile */
    .sidebar-show-btn {
        display: none;
    }
    
    .mobile-header {
        display: flex;
    }
    
    .content-inner {
        padding: calc(var(--header-height) + 1rem) 1.5rem 1.5rem;
    }
    
    .overlay {
        position: fixed;
        top: 0;
        left: 0;
        right: 0;
        bottom: 0;
        background-color: rgba(0, 0, 0, 0.5);
        z-index: 35;
        opacity: 0;
        visibility: hidden;
        transition: opacity var(--transition-normal) ease, visibility var(--transition-normal) ease;
    }
    
    .overlay.show {
        opacity: 1;
        visibility: visible;
    }
}

@media (max-width: 640px) {
    .content-inner {
        padding: calc(var(--header-height) + 1rem) 1rem 1rem;
    }
    
    /* 移动设备上的社区按钮 */
    .wechat-floating-button,
    .discord-floating-button {
        bottom: 1rem;
        right: 1rem;
    }
    
    /* 移动设备上的反馈按钮样式 */
    .feedback-button {
        width: 3.5rem;
        height: 3.5rem;
        border-radius: 50%;
        padding: 0;
        display: flex;
        align-items: center;
        justify-content: center;
        box-shadow: var(--shadow-lg);
        bottom: 1.5rem;
        right: 1.5rem;
        position: fixed;
        z-index: 40;
    }
    
    .feedback-button span {
        display: none;
    }
    
    /* 移动设备上的Linki零记按钮调整 */
    .feedback-button[style*="bottom: 120px"] {
        bottom: 80px !important;
    }
    
    /* 移动设备上的主题切换按钮样式 */
    .theme-toggle {
        width: 2.5rem;
        height: 2.5rem;
    }
    
    /* 为底部内容添加更多底部内边距，避免被固定按钮遮挡 */
    .footer {
        padding-bottom: 5rem;
    }
    .footer-top {
        flex-direction: column;
        align-items: flex-start;
    }
}
