:root {
    --bg-primary: #0a0a0a; --bg-secondary: #111111; --bg-card: #1a1a1a; --bg-card-hover: #222222;
    --accent: #e63946; --accent-dark: #b82d38; --accent-glow: rgba(230, 57, 70, 0.3);
    --text-primary: #f5f5f5; --text-secondary: #888888; --text-muted: #555555;
    --success: #2ecc71; --warning: #f39c12; --border: #2a2a2a; --shadow: 0 4px 20px rgba(0,0,0,0.5);
}
* { margin: 0; padding: 0; box-sizing: border-box; }
body { font-family: 'IBM Plex Sans', sans-serif; background: var(--bg-primary); color: var(--text-primary); min-height: 100vh; }

/* Mobile only elements - hidden on desktop */
.mobile-only { display: none !important; }
@media (max-width: 768px) { .mobile-only { display: flex !important; } }

/* Auth Bar */
.auth-bar { position: fixed; top: 0; left: 0; right: 0; z-index: 100; background: rgba(15,15,15,0.95); backdrop-filter: blur(20px); -webkit-backdrop-filter: blur(20px); border-bottom: 1px solid rgba(255,255,255,0.05); padding: 0 2rem; display: flex; justify-content: space-between; align-items: center; height: 60px; }

/* Left: Logo */
.auth-bar-left { flex-shrink: 0; }
.auth-bar-logo-img { height: 45px; cursor: pointer; transition: transform 0.2s; }
.auth-bar-logo-img:hover { transform: scale(1.05); }

/* Center: Navigation */
.auth-bar-center { display: flex; align-items: center; gap: 0.5rem; position: absolute; left: 50%; transform: translateX(-50%); }

/* Right: Actions */
.auth-bar-right { display: flex; align-items: center; gap: 0.5rem; flex-shrink: 0; }

.auth-bar-search { position: relative; }
.auth-bar-search input { background: rgba(255,255,255,0.05); border: 1px solid transparent; border-radius: 8px; padding: 0.5rem 1rem; color: var(--text-primary); font-size: 0.9rem; width: 180px; transition: all 0.3s; }
.auth-bar-search input::placeholder { color: var(--text-muted); }
.auth-bar-search input:focus { outline: none; border-color: var(--accent); background: rgba(255,255,255,0.08); width: 220px; }
.auth-bar-search::before { content: ''; }
.auth-bar-btn { background: none; border: none; color: var(--text-secondary); padding: 0.6rem 0.8rem; border-radius: 8px; cursor: pointer; transition: all 0.2s; font-size: 1.1rem; position: relative; }
.auth-bar-btn:hover { background: rgba(255,255,255,0.08); color: var(--text-primary); }
.auth-bar-btn .btn-label { font-size: 0.8rem; margin-left: 0.25rem; }
.auth-bar-btn .notif-dot { position: absolute; top: 8px; right: 8px; width: 8px; height: 8px; background: var(--accent); border-radius: 50%; display: none; }
.auth-bar-btn .notif-dot.active { display: block; animation: pulse 2s infinite; }
.nav-text-btn { font-size: 0.85rem !important; font-weight: 500; letter-spacing: 0.3px; text-decoration: none; color: inherit; }
.nav-text-btn .notif-dot { top: 4px; right: -2px; }
@keyframes pulse { 0%, 100% { transform: scale(1); opacity: 1; } 50% { transform: scale(1.2); opacity: 0.7; } }
.auth-bar-divider { width: 1px; height: 24px; background: rgba(255,255,255,0.1); margin: 0 0.5rem; }
.auth-bar-user { display: flex; align-items: center; gap: 0.75rem; padding: 0.4rem 0.6rem 0.4rem 0.4rem; border-radius: 8px; cursor: pointer; transition: all 0.2s; }
.auth-bar-user:hover { background: rgba(255,255,255,0.08); }
.auth-bar-user-avatar { width: 36px; height: 36px; border-radius: 8px; background: var(--bg-card); overflow: hidden; display: flex; align-items: center; justify-content: center; font-size: 1.2rem; }
.auth-bar-user-avatar img { width: 100%; height: 100%; object-fit: cover; }
.auth-bar-user-name { font-size: 0.9rem; font-weight: 500; max-width: 120px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.auth-bar-user-arrow { font-size: 0.6rem; color: var(--text-muted); transition: transform 0.2s; }
.auth-bar-user.open .auth-bar-user-arrow { transform: rotate(180deg); }
.auth-user { display: flex; align-items: center; gap: 0.5rem; color: var(--text-secondary); font-size: 0.9rem; cursor: pointer; padding: 0.25rem 0.5rem; border-radius: 6px; transition: background 0.2s; }
.auth-user:hover { background: var(--bg-card); }
.auth-user img { width: 28px; height: 28px; border-radius: 50%; object-fit: cover; }
.user-menu-container { position: relative; }
.user-dropdown { position: absolute; top: calc(100% + 0.5rem); right: 0; background: var(--bg-card); border: 1px solid var(--border); border-radius: 12px; min-width: 220px; box-shadow: 0 10px 40px rgba(0,0,0,0.5); opacity: 0; visibility: hidden; transform: translateY(-10px); transition: all 0.2s; z-index: 1000; overflow: hidden; }
.user-dropdown.active { opacity: 1; visibility: visible; transform: translateY(0); }
.user-dropdown-header { padding: 1rem; display: flex; align-items: center; gap: 0.75rem; }
.user-dropdown-header img { width: 40px; height: 40px; border-radius: 8px; object-fit: cover; }
.user-dropdown-header-info { flex: 1; }
.user-dropdown-header-name { font-weight: 600; font-size: 0.95rem; }
.user-dropdown-header-username { color: var(--text-muted); font-size: 0.8rem; }
.user-dropdown-divider { height: 1px; background: var(--border); margin: 0.25rem 0; }
.user-dropdown-item { display: flex; align-items: center; gap: 0.5rem; width: 100%; padding: 0.75rem 1rem; background: none; border: none; color: var(--text-primary); font-size: 0.9rem; cursor: pointer; transition: background 0.2s; text-align: left; }
.user-dropdown-item:hover { background: var(--bg-secondary); }
.user-dropdown-item.danger { color: var(--accent); }
.user-dropdown-item.danger:hover { background: rgba(230,57,70,0.1); }

/* Hamburger - hidden on desktop */
.hamburger-btn { display: none; }

.body-with-auth { padding-top: 60px; }

/* Profile Header */
.profile-header { position: relative; margin-bottom: 2rem; }
.profile-banner { width: 100%; height: 280px; background: linear-gradient(135deg, var(--bg-secondary) 0%, var(--accent-dark) 50%, var(--bg-secondary) 100%); background-size: cover; background-position: center; position: relative; }
.profile-banner::after { content: ''; position: absolute; bottom: 0; left: 0; right: 0; height: 120px; background: linear-gradient(to top, var(--bg-primary), transparent); }
.profile-banner-edit { position: absolute; top: 1rem; right: 1rem; background: rgba(0,0,0,0.6); border: none; color: white; padding: 0.5rem 1rem; border-radius: 6px; cursor: pointer; font-size: 0.85rem; display: flex; align-items: center; gap: 0.5rem; transition: all 0.2s; z-index: 5; }
.profile-banner-edit:hover { background: var(--accent); }

.profile-info { position: relative; max-width: 1400px; margin: 0 auto; padding: 0 2rem; margin-top: -80px; display: flex; gap: 1.5rem; align-items: flex-end; z-index: 10; }
.profile-avatar-wrapper { position: relative; flex-shrink: 0; }
.profile-avatar { width: 150px; height: 150px; border-radius: 12px; background: var(--bg-card); border: 4px solid var(--bg-primary); box-shadow: var(--shadow); overflow: hidden; display: flex; align-items: center; justify-content: center; font-size: 4rem; position: relative; }
.profile-avatar img { width: 100%; height: 100%; object-fit: cover; }
.profile-avatar-edit { position: absolute; bottom: -8px; right: -8px; width: 36px; height: 36px; background: var(--accent); border: 3px solid var(--bg-primary); border-radius: 50%; display: flex; align-items: center; justify-content: center; cursor: pointer; font-size: 1rem; transition: transform 0.2s; z-index: 5; }
.profile-avatar-edit:hover { transform: scale(1.1); }

/* Profile Border Styles */
.profile-avatar-border { position: absolute; inset: -6px; border-radius: 16px; pointer-events: none; z-index: 2; }

/* Standard Border */
.border-standard .profile-avatar-border { border: 3px solid var(--border); }

/* Sakura - Cherry Blossom */
.border-sakura .profile-avatar-border { border: 3px solid #ffb7c5; box-shadow: 0 0 15px rgba(255,183,197,0.5); animation: sakuraPulse 3s ease-in-out infinite; }
.border-sakura .profile-avatar-border::before { content: '🌸'; position: absolute; font-size: 1rem; animation: sakuraFloat 4s ease-in-out infinite; top: -5px; left: 10%; }
.border-sakura .profile-avatar-border::after { content: '🌸'; position: absolute; font-size: 0.8rem; animation: sakuraFloat 5s ease-in-out infinite reverse; bottom: -5px; right: 15%; }
@keyframes sakuraPulse { 0%, 100% { box-shadow: 0 0 15px rgba(255,183,197,0.5); } 50% { box-shadow: 0 0 25px rgba(255,183,197,0.8); } }
@keyframes sakuraFloat { 0%, 100% { transform: translateY(0) rotate(0deg); } 50% { transform: translateY(-5px) rotate(15deg); } }

/* Flame - Fire */
.border-flame .profile-avatar-border { border: 3px solid #ff4500; box-shadow: 0 0 20px rgba(255,69,0,0.6), 0 0 40px rgba(255,140,0,0.3); animation: flameBorder 0.5s ease-in-out infinite alternate; }
@keyframes flameBorder { 0% { box-shadow: 0 0 20px rgba(255,69,0,0.6), 0 0 40px rgba(255,140,0,0.3); border-color: #ff4500; } 100% { box-shadow: 0 0 30px rgba(255,140,0,0.8), 0 0 50px rgba(255,69,0,0.4); border-color: #ff8c00; } }

/* Galaxy - Cosmic */
.border-galaxy .profile-avatar-border { border: 3px solid #6366f1; background: linear-gradient(45deg, transparent 40%, rgba(99,102,241,0.1) 50%, transparent 60%); box-shadow: 0 0 20px rgba(99,102,241,0.5), 0 0 40px rgba(139,92,246,0.3); animation: galaxyRotate 8s linear infinite; }
.border-galaxy .profile-avatar-border::before { content: '✨'; position: absolute; font-size: 0.8rem; top: 5%; right: 5%; animation: starTwinkle 2s ease-in-out infinite; }
.border-galaxy .profile-avatar-border::after { content: '⭐'; position: absolute; font-size: 0.6rem; bottom: 10%; left: 8%; animation: starTwinkle 2.5s ease-in-out infinite 0.5s; }
@keyframes galaxyRotate { 0% { filter: hue-rotate(0deg); } 100% { filter: hue-rotate(360deg); } }
@keyframes starTwinkle { 0%, 100% { opacity: 1; transform: scale(1); } 50% { opacity: 0.5; transform: scale(0.8); } }

/* Golden - Luxury */
.border-golden .profile-avatar-border { border: 4px solid transparent; background: linear-gradient(135deg, #ffd700, #ffec8b, #ffd700, #daa520, #ffd700) border-box; -webkit-mask: linear-gradient(#fff 0 0) padding-box, linear-gradient(#fff 0 0); -webkit-mask-composite: xor; mask-composite: exclude; box-shadow: 0 0 25px rgba(255,215,0,0.6), inset 0 0 20px rgba(255,215,0,0.2); animation: goldenShine 3s linear infinite; }
@keyframes goldenShine { 0% { filter: brightness(1); } 50% { filter: brightness(1.3); } 100% { filter: brightness(1); } }

/* Glitch - Cyberpunk */
.border-glitch .profile-avatar-border { border: 3px solid #0ff; box-shadow: 0 0 10px #0ff, 0 0 20px #0ff, 3px 0 0 #f0f, -3px 0 0 #0f0; animation: glitchBorder 0.3s steps(2) infinite; }
@keyframes glitchBorder { 0%, 100% { box-shadow: 0 0 10px #0ff, 0 0 20px #0ff, 3px 0 0 #f0f, -3px 0 0 #0f0; transform: translate(0); } 25% { box-shadow: 0 0 10px #f0f, 0 0 20px #0ff, -3px 0 0 #0ff, 3px 0 0 #0f0; transform: translate(-2px, 1px); } 50% { box-shadow: 0 0 10px #0f0, 0 0 20px #f0f, 2px 0 0 #0ff, -2px 0 0 #f0f; transform: translate(1px, -1px); } 75% { box-shadow: 0 0 10px #0ff, 0 0 20px #0f0, -2px 0 0 #f0f, 2px 0 0 #0ff; transform: translate(-1px, 2px); } }

/* Rainbow - Spectrum */
.border-rainbow .profile-avatar-border { border: 4px solid transparent; background: linear-gradient(90deg, #ff0000, #ff8000, #ffff00, #00ff00, #00ffff, #0080ff, #8000ff, #ff0080, #ff0000) border-box; background-size: 400% 100%; -webkit-mask: linear-gradient(#fff 0 0) padding-box, linear-gradient(#fff 0 0); -webkit-mask-composite: xor; mask-composite: exclude; animation: rainbowMove 4s linear infinite; box-shadow: 0 0 15px rgba(255,0,128,0.4); }
@keyframes rainbowMove { 0% { background-position: 0% 50%; } 100% { background-position: 400% 50%; } }

/* Ice - Frozen */
.border-ice .profile-avatar-border { border: 3px solid #87ceeb; box-shadow: 0 0 20px rgba(135,206,250,0.6), 0 0 40px rgba(173,216,230,0.3); animation: icePulse 4s ease-in-out infinite; }
.border-ice .profile-avatar-border::before { content: '❄️'; position: absolute; font-size: 0.9rem; top: -8px; left: 50%; transform: translateX(-50%); animation: iceFloat 3s ease-in-out infinite; }

/* Creator TikTok Border - Exclusive */
.border-tiktok .profile-avatar-border { 
    border: 4px solid #ff0050;
    box-shadow: 
        0 0 0 2px #00f2ea,
        0 0 20px rgba(255,0,80,0.6), 
        0 0 40px rgba(0,242,234,0.3),
        inset 0 0 15px rgba(255,0,80,0.2);
    animation: tiktokPulse 2s ease-in-out infinite;
}
.border-tiktok .profile-avatar-border::before { 
    content: ''; 
    position: absolute; 
    top: -8px; 
    right: -8px; 
    width: 26px; 
    height: 26px; 
    background: linear-gradient(135deg, #00f2ea, #ff0050); 
    border-radius: 50%;
    box-shadow: 0 2px 10px rgba(255,0,80,0.6);
    z-index: 5;
}
.border-tiktok .profile-avatar-border::after { 
    content: '♪'; 
    position: absolute; 
    top: -8px; 
    right: -8px; 
    width: 26px; 
    height: 26px; 
    display: flex; 
    align-items: center; 
    justify-content: center;
    font-size: 14px; 
    color: white; 
    font-weight: bold;
    text-shadow: 1px 1px 2px rgba(0,0,0,0.5);
    animation: tiktokNote 0.8s ease-in-out infinite;
    z-index: 6;
}
@keyframes tiktokPulse { 
    0%, 100% { 
        box-shadow: 0 0 0 2px #00f2ea, 0 0 20px rgba(255,0,80,0.6), 0 0 40px rgba(0,242,234,0.3);
        border-color: #ff0050;
    } 
    50% { 
        box-shadow: 0 0 0 2px #ff0050, 0 0 25px rgba(0,242,234,0.7), 0 0 50px rgba(255,0,80,0.4);
        border-color: #00f2ea;
    } 
}
@keyframes tiktokNote { 
    0%, 100% { transform: scale(1) rotate(-5deg); } 
    50% { transform: scale(1.1) rotate(5deg); } 
}
@keyframes icePulse { 0%, 100% { box-shadow: 0 0 20px rgba(135,206,250,0.6), 0 0 40px rgba(173,216,230,0.3); } 50% { box-shadow: 0 0 30px rgba(135,206,250,0.8), 0 0 50px rgba(173,216,230,0.5); } }
@keyframes iceFloat { 0%, 100% { transform: translateX(-50%) translateY(0); } 50% { transform: translateX(-50%) translateY(-3px); } }

.profile-details { flex: 1; padding-bottom: 0.5rem; }
.profile-name { font-family: 'Bebas Neue', sans-serif; font-size: 2.5rem; letter-spacing: 1px; margin-bottom: 0.25rem; display: flex; align-items: center; gap: 0.75rem; }
.profile-name-edit { background: none; border: none; color: var(--text-muted); cursor: pointer; font-size: 1rem; padding: 0.25rem; }
.profile-name-edit:hover { color: var(--accent); }
.profile-username { color: var(--text-secondary); font-size: 0.9rem; margin-bottom: 0.5rem; display: flex; align-items: center; gap: 0.5rem; flex-wrap: wrap; }
.role-badge { padding: 0.25rem 0.6rem; border-radius: 4px; font-size: 0.7rem; font-weight: 700; text-transform: uppercase; letter-spacing: 1px; }
.role-badge.admin { background: linear-gradient(135deg, #ff0040, #ff4d00); color: white; box-shadow: 0 0 15px rgba(255,0,64,0.5), 0 0 30px rgba(255,0,64,0.3); animation: adminGlow 2s ease-in-out infinite alternate; }
.role-badge.mod { background: linear-gradient(135deg, #7c3aed, #a855f7); color: white; box-shadow: 0 0 15px rgba(124,58,237,0.5); }
@keyframes adminGlow { from { box-shadow: 0 0 15px rgba(255,0,64,0.5), 0 0 30px rgba(255,0,64,0.3); } to { box-shadow: 0 0 20px rgba(255,0,64,0.8), 0 0 40px rgba(255,0,64,0.5), 0 0 60px rgba(255,0,64,0.3); } }
.profile-badges { display: flex; gap: 0.5rem; margin-top: 0.75rem; margin-bottom: 0.5rem; flex-wrap: wrap; }
.profile-badge { background: var(--accent); color: white; padding: 0.2rem 0.6rem; border-radius: 4px; font-size: 0.7rem; font-weight: 600; text-transform: uppercase; letter-spacing: 0.5px; }
.profile-badge.collector { background: var(--success); }
.profile-badge.otaku { background: #9b59b6; }

.profile-stats-row { display: flex; gap: 2rem; margin-top: 0.75rem; flex-wrap: wrap; }
.profile-stat { text-align: center; }
.profile-stat.clickable { cursor: pointer; padding: 0.25rem 0.5rem; border-radius: 6px; transition: background 0.2s; margin: -0.25rem; }
.profile-stat.clickable:hover { background: var(--bg-card); }
.profile-stat-value { font-family: 'Bebas Neue', sans-serif; font-size: 1.5rem; color: var(--accent); }
.profile-stat-value.money { color: var(--success); }
.profile-stat-label { font-size: 0.7rem; color: var(--text-secondary); text-transform: uppercase; letter-spacing: 1px; }
.follow-btn { padding: 0.5rem 1.5rem; border-radius: 6px; font-weight: 600; cursor: pointer; transition: all 0.2s; border: 2px solid var(--accent); font-size: 0.9rem; }
.follow-btn.follow { background: var(--accent); color: white; }
.follow-btn.follow:hover { background: var(--accent-dark); }
.follow-btn.following { background: transparent; color: var(--accent); }
.follow-btn.following:hover { background: rgba(230,57,70,0.1); }

/* Messages */
.msg-badge { position: absolute; top: -5px; right: -5px; background: var(--accent); color: white; font-size: 0.7rem; padding: 0.15rem 0.4rem; border-radius: 10px; font-weight: 600; }
.messages-container { display: flex; height: 500px; border-radius: 12px; overflow: hidden; border: 1px solid var(--border); }
.conversations-list { width: 280px; background: var(--bg-secondary); border-right: 1px solid var(--border); display: flex; flex-direction: column; flex-shrink: 0; }
.conversations-header { padding: 1rem; border-bottom: 1px solid var(--border); display: flex; gap: 0.5rem; }
.conversations-header button { flex: 1; padding: 0.5rem; border: none; background: var(--bg-card); color: var(--text-secondary); border-radius: 6px; cursor: pointer; font-size: 0.85rem; transition: all 0.2s; }
.conversations-header button.active { background: var(--accent); color: white; }
.conversations-scroll { flex: 1; overflow-y: auto; }
.conversation-item { display: flex; gap: 0.75rem; padding: 0.75rem 1rem; cursor: pointer; border-bottom: 1px solid var(--border); transition: background 0.2s; }
.conversation-item:hover { background: var(--bg-card); }
.conversation-item.active { background: var(--bg-card); border-left: 3px solid var(--accent); }
.conversation-item.unread { background: rgba(230,57,70,0.1); }
.conversation-avatar { width: 45px; height: 45px; border-radius: 8px; overflow: hidden; flex-shrink: 0; }
.conversation-avatar img { width: 100%; height: 100%; object-fit: cover; }
.conversation-info { flex: 1; min-width: 0; }
.conversation-name { font-weight: 600; font-size: 0.9rem; margin-bottom: 0.15rem; }
.conversation-preview { font-size: 0.8rem; color: var(--text-muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.conversation-time { font-size: 0.7rem; color: var(--text-muted); }
.chat-area { flex: 1; display: flex; flex-direction: column; background: var(--bg-primary); }
.chat-header { padding: 1rem; border-bottom: 1px solid var(--border); display: flex; align-items: center; gap: 0.75rem; background: var(--bg-card); }
.chat-messages { flex: 1; overflow-y: auto; padding: 1rem; display: flex; flex-direction: column; gap: 0.75rem; }
.chat-message { max-width: 75%; padding: 0.75rem 1rem; border-radius: 12px; }
.chat-message.sent { align-self: flex-end; background: var(--accent); color: white; border-bottom-right-radius: 4px; }
.chat-message.received { align-self: flex-start; background: var(--bg-card); border-bottom-left-radius: 4px; }
.chat-message-time { font-size: 0.7rem; opacity: 0.7; margin-top: 0.25rem; }
.chat-input-area { padding: 1rem; border-top: 1px solid var(--border); display: flex; gap: 0.5rem; background: var(--bg-card); }
.chat-input-area input { flex: 1; background: var(--bg-secondary); border: 1px solid var(--border); border-radius: 20px; padding: 0.75rem 1rem; color: var(--text-primary); font-size: 0.9rem; }
.chat-input-area input:focus { outline: none; border-color: var(--accent); }
.chat-input-area button { background: var(--accent); border: none; color: white; padding: 0.75rem 1.25rem; border-radius: 20px; cursor: pointer; font-size: 0.9rem; font-weight: 500; }
.chat-empty { flex: 1; display: flex; align-items: center; justify-content: center; color: var(--text-muted); text-align: center; }
.request-actions { display: flex; gap: 0.5rem; padding: 1rem; background: var(--bg-secondary); border-top: 1px solid var(--border); }
.request-actions button { flex: 1; padding: 0.75rem; border-radius: 8px; font-weight: 600; cursor: pointer; border: none; }

/* About Section */
.profile-about { max-width: 1400px; margin: 0 auto 2rem; padding: 0 2rem; margin-top: 1.5rem; clear: both; }
.profile-about-card { background: var(--bg-card); border-radius: 12px; border: 1px solid var(--border); padding: 1.25rem; position: relative; }
.profile-about-title { font-family: 'Bebas Neue', sans-serif; font-size: 1.2rem; color: var(--text-secondary); margin-bottom: 0.75rem; display: flex; align-items: center; justify-content: space-between; }
.profile-about-edit { background: none; border: none; color: var(--text-muted); cursor: pointer; font-size: 0.9rem; }
.profile-about-edit:hover { color: var(--accent); }
.profile-about-text { color: var(--text-primary); line-height: 1.8; }
.profile-about-text.empty { color: var(--text-muted); font-style: italic; }
.profile-about-text img { max-width: 100%; max-height: 300px; border-radius: 8px; margin: 0.5rem 0; }
.profile-about-text a { color: var(--accent); text-decoration: none; }
.profile-about-text a:hover { text-decoration: underline; }
.profile-about-text .text-center { text-align: center; display: block; }
.profile-about-text .text-right { text-align: right; display: block; }
.profile-about-text .text-small { font-size: 0.85rem; }
.profile-about-text .text-large { font-size: 1.2rem; }
.profile-about-text .text-muted { color: var(--text-muted); }
.profile-about-text .text-accent { color: var(--accent); }
.profile-about-text .text-success { color: var(--success); }
.profile-about-text hr { border: none; border-top: 1px solid var(--border); margin: 1rem 0; }
.profile-about-text blockquote { border-left: 3px solid var(--accent); padding-left: 1rem; margin: 0.5rem 0; color: var(--text-secondary); font-style: italic; }
.profile-about-text .spoiler-text { background: var(--text-primary); color: transparent; cursor: pointer; padding: 0 0.25rem; border-radius: 3px; transition: all 0.2s; user-select: none; }
.profile-about-text .spoiler-text.revealed { background: var(--bg-secondary); color: var(--text-primary); }
.about-editor-toolbar { display: flex; gap: 0.25rem; flex-wrap: wrap; margin-bottom: 0.75rem; padding-bottom: 0.75rem; border-bottom: 1px solid var(--border); }
.about-editor-btn { background: var(--bg-secondary); border: 1px solid var(--border); color: var(--text-secondary); padding: 0.4rem 0.6rem; border-radius: 4px; cursor: pointer; font-size: 0.85rem; transition: all 0.2s; }
.about-editor-btn:hover { background: var(--bg-card); border-color: var(--accent); color: var(--text-primary); }
.about-editor-help { font-size: 0.75rem; color: var(--text-muted); margin-top: 0.75rem; padding-top: 0.75rem; border-top: 1px solid var(--border); }
.profile-favorite-manga { display: flex; gap: 0.75rem; margin-top: 1rem; flex-wrap: wrap; }
.favorite-manga-item { width: 60px; height: 90px; border-radius: 6px; overflow: hidden; border: 2px solid var(--border); transition: all 0.2s; cursor: pointer; }
.favorite-manga-item:hover { border-color: var(--accent); transform: translateY(-2px); }
.favorite-manga-item img { width: 100%; height: 100%; object-fit: cover; }

/* Favorite Characters */
.favorite-characters { margin-top: 1rem; }
.favorite-characters-title { font-size: 0.75rem; color: var(--text-muted); text-transform: uppercase; letter-spacing: 1px; margin-bottom: 0.5rem; }
.favorite-characters-grid { display: flex; gap: 0.5rem; flex-wrap: wrap; }
.favorite-character { position: relative; width: 70px; height: 70px; border-radius: 8px; overflow: hidden; border: 2px solid var(--border); cursor: pointer; transition: all 0.2s; }
.favorite-character:hover { border-color: var(--accent); transform: scale(1.05); }
.favorite-character img { width: 100%; height: 100%; object-fit: cover; }
.favorite-character-name { position: absolute; bottom: 0; left: 0; right: 0; background: linear-gradient(transparent, rgba(0,0,0,0.9)); padding: 0.25rem; font-size: 0.6rem; text-align: center; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.character-search-results { display: grid; grid-template-columns: repeat(auto-fill, minmax(80px, 1fr)); gap: 0.5rem; max-height: 250px; overflow-y: auto; margin-top: 0.5rem; }
.character-search-item { background: var(--bg-secondary); border: 2px solid var(--border); border-radius: 8px; padding: 0.5rem; text-align: center; cursor: pointer; transition: all 0.2s; }
.character-search-item:hover { border-color: var(--accent); }
.character-search-item.selected { border-color: var(--success); background: rgba(46, 204, 113, 0.1); }
.character-search-item img { width: 50px; height: 50px; border-radius: 6px; object-fit: cover; margin-bottom: 0.25rem; }
.character-search-item span { display: block; font-size: 0.7rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

/* Navigation */
.nav-tabs { max-width: 1400px; margin: 0 auto 1.5rem; padding: 0 2rem; display: flex; gap: 0.5rem; border-bottom: 1px solid var(--border); flex-wrap: wrap; }
.nav-tab { padding: 0.75rem 1.5rem; background: none; border: none; color: var(--text-secondary); font-size: 0.95rem; cursor: pointer; position: relative; transition: all 0.2s; }
.nav-tab:hover { color: var(--text-primary); }
.nav-tab.active { color: var(--accent); }
.nav-tab.active::after { content: ''; position: absolute; bottom: -1px; left: 0; right: 0; height: 2px; background: var(--accent); }
.nav-badge { background: var(--accent); color: white; padding: 0.15rem 0.5rem; border-radius: 10px; font-size: 0.75rem; margin-left: 0.25rem; }
.nav-badge.empty { background: var(--text-muted); }

/* Leaderboard Styles */
.leaderboard-container { max-width: 900px; margin: 0 auto; }
.leaderboard-header { text-align: center; margin-bottom: 2rem; }
.leaderboard-header h2 { font-family: 'Bebas Neue', sans-serif; font-size: 2.5rem; margin-bottom: 0.5rem; }
.leaderboard-header h2 span { color: var(--accent); }
.leaderboard-header p { color: var(--text-muted); }
.leaderboard-podium { display: flex; justify-content: center; align-items: flex-end; gap: 1rem; margin-bottom: 2rem; }
.podium-item { text-align: center; cursor: pointer; transition: transform 0.2s; }
.podium-item:hover { transform: translateY(-5px); }
.podium-item.gold { order: 2; }
.podium-item.silver { order: 1; }
.podium-item.bronze { order: 3; }
.podium-cover { border-radius: 12px; overflow: hidden; margin-bottom: 0.75rem; box-shadow: 0 10px 30px rgba(0,0,0,0.3); }
.podium-item.gold .podium-cover { width: 160px; height: 240px; border: 4px solid #ffd700; box-shadow: 0 0 30px rgba(255,215,0,0.4); }
.podium-item.silver .podium-cover { width: 130px; height: 195px; border: 4px solid #c0c0c0; box-shadow: 0 0 20px rgba(192,192,192,0.3); }
.podium-item.bronze .podium-cover { width: 130px; height: 195px; border: 4px solid #cd7f32; box-shadow: 0 0 20px rgba(205,127,50,0.3); }
.podium-cover img { width: 100%; height: 100%; object-fit: cover; }
.podium-rank { font-family: 'Bebas Neue', sans-serif; font-size: 2rem; margin-bottom: 0.25rem; }
.podium-item.gold .podium-rank { color: #ffd700; font-size: 2.5rem; }
.podium-item.silver .podium-rank { color: #c0c0c0; }
.podium-item.bronze .podium-rank { color: #cd7f32; }
.podium-title { font-weight: 600; font-size: 0.9rem; max-width: 150px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; margin: 0 auto; }
.podium-score { font-family: 'Bebas Neue', sans-serif; font-size: 1.4rem; color: var(--accent); }
.podium-votes { font-size: 0.75rem; color: var(--text-muted); }
.leaderboard-list { background: var(--bg-card); border-radius: 12px; border: 1px solid var(--border); overflow: hidden; }
.leaderboard-item { display: flex; align-items: center; gap: 1rem; padding: 1rem 1.25rem; border-bottom: 1px solid var(--border); cursor: pointer; transition: background 0.2s; }
.leaderboard-item:last-child { border-bottom: none; }
.leaderboard-item:hover { background: var(--bg-secondary); }
.leaderboard-rank { font-family: 'Bebas Neue', sans-serif; font-size: 1.5rem; color: var(--text-muted); width: 40px; text-align: center; }
.leaderboard-cover { width: 50px; height: 75px; border-radius: 6px; overflow: hidden; flex-shrink: 0; }
.leaderboard-cover img { width: 100%; height: 100%; object-fit: cover; }
.leaderboard-info { flex: 1; min-width: 0; }
.leaderboard-title { font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; margin-bottom: 0.25rem; }
.leaderboard-meta { font-size: 0.8rem; color: var(--text-muted); }
.leaderboard-score { text-align: right; }
.leaderboard-score-value { font-family: 'Bebas Neue', sans-serif; font-size: 1.5rem; color: var(--accent); }
.leaderboard-score-votes { font-size: 0.75rem; color: var(--text-muted); }

/* Main Content */
.container { max-width: 1400px; margin: 0 auto; padding: 0 2rem 2rem; }
.action-bar { display: flex; gap: 1rem; margin-bottom: 2rem; flex-wrap: wrap; }
.btn { font-family: inherit; padding: 0.875rem 1.5rem; border: none; border-radius: 8px; cursor: pointer; font-size: 0.95rem; font-weight: 500; display: flex; align-items: center; gap: 0.5rem; transition: all 0.2s; }
.btn-primary { background: var(--accent); color: white; box-shadow: 0 0 20px var(--accent-glow); }
.btn-primary:hover { background: var(--accent-dark); transform: translateY(-2px); }
.btn-primary:disabled { background: var(--text-muted); box-shadow: none; cursor: not-allowed; transform: none; }
.btn-secondary { background: var(--bg-card); color: var(--text-primary); border: 1px solid var(--border); }
.btn-secondary:hover { background: var(--bg-card-hover); border-color: var(--accent); }
.btn-small { padding: 0.5rem 1rem; font-size: 0.85rem; }
.search-box { flex: 1; min-width: 200px; position: relative; }
.search-box input { width: 100%; padding: 0.875rem 1rem 0.875rem 2.75rem; background: var(--bg-card); border: 1px solid var(--border); border-radius: 8px; color: var(--text-primary); font-size: 0.95rem; font-family: inherit; }
.search-box input:focus { outline: none; border-color: var(--accent); }
.search-box::before { content: '🔍'; position: absolute; left: 1rem; top: 50%; transform: translateY(-50%); }
.filter-tabs { display: flex; gap: 0.5rem; margin-bottom: 1.5rem; flex-wrap: wrap; }
.filter-tab { padding: 0.5rem 1rem; background: transparent; border: 1px solid var(--border); border-radius: 20px; color: var(--text-secondary); font-size: 0.85rem; cursor: pointer; transition: all 0.2s; }
.filter-tab:hover { border-color: var(--accent); color: var(--text-primary); }
.filter-tab.active { background: var(--accent); border-color: var(--accent); color: white; }

.manga-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); gap: 1.25rem; }
.manga-card { background: var(--bg-card); border-radius: 12px; border: 1px solid var(--border); overflow: hidden; transition: all 0.3s; cursor: pointer; }
.manga-card:hover { transform: translateY(-4px); border-color: var(--accent); box-shadow: var(--shadow), 0 0 30px var(--accent-glow); }
.manga-card.complete:hover { border-color: var(--success); box-shadow: var(--shadow), 0 0 30px rgba(46, 204, 113, 0.4); }
.manga-card.ongoing:hover { border-color: #f39c12; box-shadow: var(--shadow), 0 0 30px rgba(243, 156, 18, 0.4); }
.manga-card.incomplete:hover { border-color: var(--accent); box-shadow: var(--shadow), 0 0 30px var(--accent-glow); }
.manga-card-header { padding: 1.25rem; display: flex; gap: 1rem; align-items: flex-start; }
.manga-cover { width: 70px; height: 105px; background: var(--bg-secondary); border-radius: 6px; display: flex; align-items: center; justify-content: center; font-size: 1.5rem; flex-shrink: 0; border: 1px solid var(--border); overflow: hidden; }
.manga-cover img { width: 100%; height: 100%; object-fit: cover; }
.manga-info { flex: 1; min-width: 0; }
.manga-title { font-family: 'Bebas Neue', sans-serif; font-size: 1.3rem; margin-bottom: 0.25rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.manga-publisher { font-size: 0.8rem; color: var(--text-secondary); margin-bottom: 0.5rem; }
.manga-progress { display: flex; align-items: center; gap: 0.75rem; margin-bottom: 0.5rem; }
.progress-bar { flex: 1; height: 8px; background: var(--bg-secondary); border-radius: 4px; overflow: hidden; }
.progress-fill { height: 100%; background: linear-gradient(90deg, var(--accent), var(--accent-dark)); border-radius: 4px; transition: width 0.3s; }
.progress-fill.complete { background: linear-gradient(90deg, var(--success), #27ae60); }
.progress-fill.ongoing { background: linear-gradient(90deg, #f39c12, #e67e22); }
.progress-fill.incomplete { background: linear-gradient(90deg, var(--accent), var(--accent-dark)); }
.progress-text { font-family: 'Bebas Neue', sans-serif; font-size: 1.1rem; color: var(--accent); }
.progress-text.complete { color: var(--success); }
.progress-text.ongoing { color: #f39c12; }
.progress-text.incomplete { color: var(--accent); }
.manga-value { font-size: 0.85rem; font-weight: 500; }
.manga-card.complete .manga-value { color: var(--success); }
.manga-card.ongoing .manga-value { color: #f39c12; }
.manga-card.incomplete .manga-value { color: var(--accent); }
.manga-card .manga-value { color: var(--accent); }
.manga-card-footer { padding: 0 1.25rem 1.25rem; }
.missing-label { font-size: 0.75rem; color: var(--text-muted); text-transform: uppercase; letter-spacing: 1px; margin-bottom: 0.5rem; }
.missing-volumes { display: flex; flex-wrap: wrap; gap: 0.375rem; }
.missing-badge { padding: 0.25rem 0.5rem; border-radius: 4px; font-size: 0.75rem; background: var(--bg-secondary); }
.manga-card.complete .missing-badge { border: 1px solid var(--success); color: var(--success); }
.manga-card.ongoing .missing-badge { border: 1px solid #f39c12; color: #f39c12; }
.manga-card.incomplete .missing-badge { border: 1px solid var(--accent); color: var(--accent); }
.manga-card .missing-badge { border: 1px solid var(--accent); color: var(--accent); }
.missing-more { background: var(--bg-secondary); border: 1px solid var(--border); color: var(--text-secondary); padding: 0.25rem 0.5rem; border-radius: 4px; font-size: 0.75rem; }

.empty-state { text-align: center; padding: 4rem 2rem; color: var(--text-secondary); }
.empty-state-icon { font-size: 4rem; margin-bottom: 1rem; opacity: 0.5; }
.empty-state h3 { font-family: 'Bebas Neue', sans-serif; font-size: 1.5rem; color: var(--text-primary); margin-bottom: 0.5rem; }

/* Shopping List */
.shopping-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 1.5rem; flex-wrap: wrap; gap: 1rem; }
.shopping-header h2 { font-family: 'Bebas Neue', sans-serif; font-size: 1.75rem; }
.shopping-total { background: var(--bg-card); border: 1px solid var(--border); border-radius: 8px; padding: 0.75rem 1.25rem; display: flex; align-items: center; gap: 1rem; }
.shopping-total-label { color: var(--text-secondary); font-size: 0.85rem; }
.shopping-total-value { font-family: 'Bebas Neue', sans-serif; font-size: 1.5rem; color: var(--success); }
.shopping-filters { display: flex; gap: 0.5rem; margin-bottom: 1rem; flex-wrap: wrap; }
.shopping-group { background: var(--bg-card); border-radius: 12px; border: 1px solid var(--border); margin-bottom: 1rem; overflow: hidden; }
.shopping-group-header { padding: 1rem 1.25rem; display: flex; align-items: center; gap: 1rem; cursor: pointer; transition: background 0.2s; }
.shopping-group-header:hover { background: var(--bg-card-hover); }
.shopping-group-cover { width: 50px; height: 75px; border-radius: 6px; overflow: hidden; flex-shrink: 0; background: var(--bg-secondary); }
.shopping-group-cover img { width: 100%; height: 100%; object-fit: cover; }
.shopping-group-info { flex: 1; }
.shopping-group-title { font-family: 'Bebas Neue', sans-serif; font-size: 1.2rem; }
.shopping-group-meta { font-size: 0.8rem; color: var(--text-secondary); }
.shopping-group-stats { text-align: right; }
.shopping-group-count { font-family: 'Bebas Neue', sans-serif; font-size: 1.3rem; color: var(--warning); }
.shopping-group-price { font-size: 0.85rem; color: var(--success); }
.shopping-group-items { padding: 0 1.25rem 1rem; display: none; }
.shopping-group.expanded .shopping-group-items { display: block; }
.shopping-group-toggle { color: var(--text-muted); font-size: 1.25rem; transition: transform 0.2s; }
.shopping-group.expanded .shopping-group-toggle { transform: rotate(180deg); }
.shopping-volume-grid { display: flex; flex-wrap: wrap; gap: 0.5rem; }
.shopping-volume { background: var(--bg-secondary); border: 1px solid var(--warning); color: var(--warning); padding: 0.4rem 0.6rem; border-radius: 6px; font-size: 0.8rem; display: flex; align-items: center; gap: 0.35rem; transition: all 0.2s; }
.shopping-volume span { cursor: pointer; }
.shopping-volume span:hover { text-decoration: underline; }
.shopping-volume.bought { background: var(--success); border-color: var(--success); color: white; text-decoration: line-through; opacity: 0.6; }
.shopping-volume.bought .amazon-btn-small { display: none; }
.shopping-empty { text-align: center; padding: 4rem 2rem; }
.shopping-empty-icon { font-size: 4rem; margin-bottom: 1rem; }
.shopping-actions { display: flex; gap: 0.5rem; margin-top: 1rem; flex-wrap: wrap; }

/* Modals */
.modal-overlay { display: none; position: fixed; inset: 0; background: rgba(0,0,0,0.9); z-index: 1000; align-items: center; justify-content: center; padding: 1rem; }
.modal-overlay.active { display: flex; }
.modal { background: var(--bg-card); border-radius: 16px; border: 1px solid var(--border); width: 100%; max-width: 550px; max-height: 90vh; overflow-y: auto; }
.modal-header { padding: 1.25rem; border-bottom: 1px solid var(--border); display: flex; justify-content: space-between; align-items: center; position: sticky; top: 0; background: var(--bg-card); z-index: 10; }
.modal-title { font-family: 'Bebas Neue', sans-serif; font-size: 1.5rem; }
.modal-close { background: none; border: none; color: var(--text-secondary); font-size: 1.5rem; cursor: pointer; padding: 0.5rem; }
.modal-close:hover { color: var(--accent); }
.modal-body { padding: 1.25rem; }
#scanner-container { width: 100%; aspect-ratio: 1; background: var(--bg-secondary); border-radius: 12px; overflow: hidden; margin-bottom: 1rem; }
.scanner-status { text-align: center; padding: 1rem; color: var(--text-secondary); }
.scanner-status.success { color: var(--success); }
.scanner-status.error { color: var(--accent); }
.scanned-book { background: var(--bg-secondary); border-radius: 8px; padding: 1rem; margin-top: 1rem; display: flex; gap: 1rem; align-items: center; }
.scanned-book-cover { width: 60px; height: 90px; background: var(--bg-card); border-radius: 4px; overflow: hidden; flex-shrink: 0; }
.scanned-book-cover img { width: 100%; height: 100%; object-fit: cover; }
.scanned-book-info h4 { font-size: 1rem; margin-bottom: 0.25rem; }
.scanned-book-info p { font-size: 0.85rem; color: var(--text-secondary); }
.api-matches { margin-top: 1rem; }
.api-match-item { display: flex; gap: 1rem; padding: 0.75rem; background: var(--bg-secondary); border: 2px solid var(--border); border-radius: 8px; margin-bottom: 0.5rem; cursor: pointer; transition: all 0.2s; }
.api-match-item:hover { border-color: var(--accent); }
.api-match-cover { width: 50px; height: 75px; border-radius: 4px; overflow: hidden; flex-shrink: 0; background: var(--bg-card); }
.api-match-cover img { width: 100%; height: 100%; object-fit: cover; }
.api-match-info { flex: 1; min-width: 0; }
.api-match-info h4 { font-size: 0.95rem; margin-bottom: 0.25rem; }
.api-match-info p { font-size: 0.8rem; color: var(--text-secondary); }
.api-match-info .synonyms { font-size: 0.7rem; color: var(--text-muted); margin-top: 0.25rem; font-style: italic; }
.volumes-badge { display: inline-block; background: var(--accent); color: white; padding: 0.15rem 0.5rem; border-radius: 4px; font-size: 0.7rem; margin-top: 0.25rem; }
.form-group { margin-bottom: 1rem; }
.form-label { display: block; font-size: 0.85rem; color: var(--text-secondary); margin-bottom: 0.5rem; text-transform: uppercase; letter-spacing: 0.5px; }
.form-input, .form-select, .form-textarea { width: 100%; padding: 0.75rem 1rem; background: var(--bg-secondary); border: 1px solid var(--border); border-radius: 8px; color: var(--text-primary); font-size: 0.95rem; font-family: inherit; }
.form-textarea { min-height: 120px; resize: vertical; }
.form-input:focus, .form-select:focus, .form-textarea:focus { outline: none; border-color: var(--accent); }
.form-row { display: flex; gap: 0.75rem; }
.form-row .form-group { flex: 1; margin-bottom: 1rem; }
.search-results { max-height: 300px; overflow-y: auto; margin-top: 0.5rem; }
.search-result-item { display: flex; gap: 1rem; padding: 0.75rem; background: var(--bg-secondary); border: 2px solid var(--border); border-radius: 8px; margin-bottom: 0.5rem; cursor: pointer; transition: all 0.2s; }
.search-result-item:hover { border-color: var(--accent); }
.search-result-cover { width: 50px; height: 75px; background: var(--bg-card); border-radius: 4px; overflow: hidden; flex-shrink: 0; }
.search-result-cover img { width: 100%; height: 100%; object-fit: cover; }
.search-result-info { flex: 1; }
.search-result-info h4 { font-size: 0.95rem; margin-bottom: 0.25rem; }
.search-result-info p { font-size: 0.8rem; color: var(--text-secondary); }
.search-result-info .synonyms { font-size: 0.7rem; color: var(--text-muted); margin-top: 0.25rem; font-style: italic; max-height: 2.5em; overflow: hidden; }
.volume-selector { display: flex; flex-wrap: wrap; gap: 0.5rem; max-height: 250px; overflow-y: auto; padding: 0.5rem; background: var(--bg-secondary); border-radius: 8px; }

/* Add to Reading Checkbox */
.add-to-reading-checkbox { display: flex; align-items: center; gap: 0.75rem; cursor: pointer; padding: 0.75rem 1rem; background: var(--bg-secondary); border-radius: 8px; transition: all 0.2s; }
.add-to-reading-checkbox:hover { background: var(--bg-card); }
.add-to-reading-checkbox input[type="checkbox"] { width: 18px; height: 18px; accent-color: var(--accent); cursor: pointer; }
.add-to-reading-checkbox span { font-size: 0.9rem; color: var(--text-secondary); }
.volume-chip { width: 44px; height: 44px; display: flex; align-items: center; justify-content: center; background: var(--bg-card); border: 1px solid var(--border); border-radius: 6px; cursor: pointer; font-size: 0.85rem; font-weight: 500; transition: all 0.2s; }
.volume-chip:hover { border-color: var(--accent); }
.volume-chip.owned { background: var(--accent); border-color: var(--accent); color: white; }
.detail-header { display: flex; gap: 1.5rem; margin-bottom: 1.5rem; }
.detail-cover { width: 120px; height: 180px; background: var(--bg-secondary); border-radius: 8px; flex-shrink: 0; overflow: hidden; border: 1px solid var(--border); }
.detail-cover img { width: 100%; height: 100%; object-fit: cover; }
.detail-info h2 { font-family: 'Bebas Neue', sans-serif; font-size: 1.75rem; margin-bottom: 0.25rem; }
.detail-publisher { color: var(--text-secondary); margin-bottom: 0.5rem; }
.detail-genres { display: flex; flex-wrap: wrap; gap: 0.35rem; margin-bottom: 0.75rem; }
.detail-genre { background: var(--bg-secondary); border: 1px solid var(--border); padding: 0.2rem 0.5rem; border-radius: 4px; font-size: 0.7rem; color: var(--text-muted); }
.detail-stats { display: flex; gap: 1rem; flex-wrap: wrap; }
.detail-stat-value { font-family: 'Bebas Neue', sans-serif; font-size: 1.3rem; color: var(--accent); }
.detail-stat-value.money { color: var(--success); }
.detail-stat-label { font-size: 0.7rem; color: var(--text-secondary); text-transform: uppercase; }
.detail-tabs { display: flex; gap: 0.5rem; margin-bottom: 1rem; border-bottom: 1px solid var(--border); padding-bottom: 0.5rem; }
.detail-tab { padding: 0.5rem 1rem; background: none; border: none; color: var(--text-muted); cursor: pointer; font-size: 0.9rem; border-radius: 6px 6px 0 0; transition: all 0.2s; }
.detail-tab:hover { color: var(--text-primary); }
.detail-tab.active { color: var(--accent); background: var(--bg-secondary); }
.detail-section { margin-bottom: 1.5rem; }
.detail-section-title { font-size: 0.85rem; color: var(--text-secondary); text-transform: uppercase; letter-spacing: 1px; margin-bottom: 0.75rem; padding-bottom: 0.5rem; border-bottom: 1px solid var(--border); }
.detail-description { color: var(--text-secondary); line-height: 1.6; font-size: 0.9rem; max-height: 200px; overflow-y: auto; padding-right: 0.5rem; }
.detail-characters { display: grid; grid-template-columns: repeat(auto-fill, minmax(70px, 1fr)); gap: 0.75rem; }
.detail-character { text-align: center; }
.detail-character img { width: 60px; height: 60px; border-radius: 8px; object-fit: cover; margin-bottom: 0.25rem; border: 1px solid var(--border); }
.detail-character-name { font-size: 0.7rem; color: var(--text-muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.detail-rating { display: flex; align-items: center; gap: 1rem; margin-bottom: 1rem; }
.detail-rating-input { display: flex; align-items: center; gap: 0.5rem; }
.detail-rating-input input { width: 70px; text-align: center; font-family: 'Bebas Neue', sans-serif; font-size: 1.3rem; }
.detail-rating-stars { color: #f1c40f; font-size: 1.2rem; }
.detail-anilist-score { font-size: 0.85rem; color: var(--text-muted); }
.shopping-list { background: var(--bg-secondary); border-radius: 8px; padding: 1rem; max-height: 200px; overflow-y: auto; }
.shopping-list-empty { text-align: center; color: var(--success); padding: 1rem; }
.shopping-item { display: flex; justify-content: space-between; align-items: center; padding: 0.5rem 0; border-bottom: 1px solid var(--border); }
.shopping-item:last-child { border-bottom: none; }
.amazon-btn { background: linear-gradient(135deg, #ff9900, #ff8000); color: #000; font-size: 0.7rem; font-weight: 600; padding: 0.25rem 0.5rem; border-radius: 4px; text-decoration: none; transition: all 0.2s; }
.amazon-btn:hover { background: linear-gradient(135deg, #ffaa22, #ff9900); transform: scale(1.05); }
.amazon-btn-small { background: linear-gradient(135deg, #ff9900, #ff8000); color: #000; font-size: 0.6rem; font-weight: 600; padding: 0.15rem 0.35rem; border-radius: 3px; text-decoration: none; transition: all 0.2s; margin-left: 0.25rem; }
.amazon-btn-small:hover { background: linear-gradient(135deg, #ffaa22, #ff9900); }
.loading-spinner { display: inline-block; width: 20px; height: 20px; border: 2px solid var(--text-muted); border-radius: 50%; border-top-color: var(--accent); animation: spin 0.8s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.toast-container { position: fixed; bottom: 2rem; right: 2rem; z-index: 2000; display: flex; flex-direction: column; gap: 0.75rem; }
.toast { background: var(--bg-card); border: 1px solid var(--border); border-radius: 8px; padding: 1rem; display: flex; align-items: center; gap: 0.75rem; box-shadow: var(--shadow); animation: slideIn 0.3s; max-width: 350px; }
.toast.success { border-color: var(--success); }
.toast.error { border-color: var(--accent); }
@keyframes slideIn { from { transform: translateX(100%); opacity: 0; } to { transform: translateX(0); opacity: 1; } }
.volume-input-row { display: flex; gap: 0.75rem; align-items: flex-end; margin-bottom: 1rem; }
.volume-input-row .form-group { margin-bottom: 0; }
.volume-input-row .form-group:first-child { flex: 1; }
.quick-actions { display: flex; gap: 0.5rem; margin-bottom: 1rem; flex-wrap: wrap; }
.quick-action-btn { padding: 0.5rem 0.75rem; background: var(--bg-secondary); border: 1px solid var(--border); border-radius: 6px; color: var(--text-secondary); font-size: 0.8rem; cursor: pointer; }
.quick-action-btn:hover { border-color: var(--accent); color: var(--text-primary); }
.info-box { background: var(--bg-secondary); border-left: 3px solid var(--accent); padding: 0.75rem 1rem; margin-bottom: 1rem; font-size: 0.85rem; color: var(--text-secondary); }

.price-presets { display: flex; gap: 0.5rem; margin-top: 0.5rem; flex-wrap: wrap; }
.price-preset { padding: 0.35rem 0.6rem; background: var(--bg-card); border: 1px solid var(--border); border-radius: 4px; color: var(--text-secondary); font-size: 0.75rem; cursor: pointer; }
.price-preset:hover { border-color: var(--accent); color: var(--text-primary); }

/* Image Upload */
.image-upload-area { border: 2px dashed var(--border); border-radius: 8px; padding: 2rem; text-align: center; cursor: pointer; transition: all 0.2s; margin-bottom: 1rem; }
.image-upload-area:hover { border-color: var(--accent); }
.image-upload-area.dragover { border-color: var(--accent); background: rgba(230, 57, 70, 0.1); }
.upload-placeholder { color: var(--text-muted); }
.upload-placeholder .upload-icon { font-size: 3rem; margin-bottom: 0.5rem; }
.upload-placeholder p { margin: 0.25rem 0; }
.upload-placeholder .hint { font-size: 0.8rem; opacity: 0.7; }
.image-preview { max-width: 100%; max-height: 200px; border-radius: 8px; margin-top: 1rem; }

/* Auth Forms */
.auth-container { min-height: 100vh; display: flex; align-items: center; justify-content: center; padding: 2rem; }
.auth-card { background: var(--bg-card); border: 1px solid var(--border); border-radius: 16px; padding: 2rem; width: 100%; max-width: 400px; }
.auth-logo { text-align: center; margin-bottom: 2rem; }
.auth-logo h1 { font-family: 'Bebas Neue', sans-serif; font-size: 2.5rem; }
.auth-logo h1 span { color: var(--accent); }
.auth-tabs { display: flex; margin-bottom: 1.5rem; border-bottom: 1px solid var(--border); }
.auth-tab { flex: 1; padding: 0.75rem; background: none; border: none; color: var(--text-secondary); font-size: 1rem; cursor: pointer; }
.auth-tab.active { color: var(--accent); border-bottom: 2px solid var(--accent); }
.auth-divider { display: flex; align-items: center; gap: 1rem; margin: 1.5rem 0; color: var(--text-muted); font-size: 0.85rem; }
.auth-divider::before, .auth-divider::after { content: ''; flex: 1; height: 1px; background: var(--border); }
.auth-error { background: rgba(230, 57, 70, 0.1); border: 1px solid var(--accent); color: var(--accent); padding: 0.75rem; border-radius: 8px; margin-bottom: 1rem; font-size: 0.9rem; }

/* Sync indicator */
.sync-indicator { display: flex; align-items: center; gap: 0.5rem; font-size: 0.8rem; color: var(--text-muted); }
.sync-indicator.syncing { color: var(--warning); }
.sync-indicator.synced { color: var(--success); }

/* Hamburger Menu - Hidden on Desktop */
.mobile-nav-item { display: none !important; }

@media (max-width: 768px) {
    /* Auth Bar Mobile */
    .auth-bar { padding: 0 1rem; height: 60px; }
    .body-with-auth { padding-top: 60px; }
    
    /* Left: Logo */
    .auth-bar-left { flex: 0 0 auto; }
    .auth-bar-logo-img { height: 35px; }
    
    /* Center: Hidden, becomes dropdown */
    .auth-bar-center { 
        display: none; 
        position: fixed;
        top: 60px;
        left: 0;
        right: 0;
        background: rgba(15,15,15,0.98);
        backdrop-filter: blur(20px);
        flex-direction: column;
        padding: 1rem;
        border-bottom: 1px solid var(--border);
        gap: 0.25rem;
        z-index: 99;
        animation: slideDown 0.2s ease;
        transform: none;
    }
    .auth-bar-center.open { display: flex; }
    .auth-bar-center .auth-bar-btn { 
        width: 100%; 
        text-align: left; 
        padding: 0.9rem 1rem;
        border-radius: 8px;
        font-size: 1rem;
    }
    .auth-bar-center .auth-bar-btn:hover { background: var(--bg-secondary); }
    .auth-bar-search { 
        display: block !important; 
        margin-top: 0.5rem;
        padding-top: 0.5rem;
        border-top: 1px solid var(--border);
    }
    .auth-bar-search input { width: 100%; padding: 0.75rem 1rem; }
    .mobile-nav-item { display: block !important; }
    .mobile-nav-item.mobile-logout { 
        margin-top: 0.5rem; 
        padding-top: 0.75rem; 
        border-top: 1px solid var(--border); 
        color: #ff4444 !important;
    }
    .mobile-nav-item.mobile-logout:hover { background: rgba(255,68,68,0.1); }
    
    /* Right: Only Bell + Hamburger visible */
    .auth-bar-right > *:not(#notification-bell-container):not(.hamburger-btn) { display: none; }
    .auth-bar-right { gap: 0.25rem; }
    
    /* Hamburger Button */
    .hamburger-btn {
        display: flex;
        flex-direction: column;
        justify-content: center;
        gap: 5px;
        width: 36px;
        height: 36px;
        background: none;
        border: none;
        cursor: pointer;
        padding: 6px;
    }
    .hamburger-btn span {
        display: block;
        width: 100%;
        height: 2px;
        background: var(--text-primary);
        border-radius: 2px;
        transition: all 0.3s ease;
    }
    .hamburger-btn.active span:nth-child(1) {
        transform: rotate(45deg) translate(5px, 5px);
    }
    .hamburger-btn.active span:nth-child(2) {
        opacity: 0;
    }
    .hamburger-btn.active span:nth-child(3) {
        transform: rotate(-45deg) translate(5px, -5px);
    }
    
    /* Profile Header Mobile */
    .profile-banner { height: 150px; }
    .profile-info { flex-direction: column; align-items: center; text-align: center; margin-top: -50px; padding: 0 1rem; }
    .profile-avatar { width: 100px; height: 100px; font-size: 3rem; }
    .profile-avatar-wrapper { margin-bottom: 0.5rem; }
    .profile-details { align-items: center; }
    .profile-name { font-size: 1.8rem; justify-content: center; flex-wrap: wrap; }
    .profile-name-edit { font-size: 0.8rem; }
    .profile-username { font-size: 0.9rem; }
    .profile-stats-row { justify-content: center; flex-wrap: wrap; gap: 0.5rem; }
    .profile-stat { min-width: 60px; padding: 0.4rem; }
    .profile-stat-value { font-size: 1.1rem; }
    .profile-stat-label { font-size: 0.65rem; }
    .profile-badges { justify-content: center; }
    .profile-badge { font-size: 0.6rem; padding: 0.15rem 0.5rem; }
    
    /* Profile About Mobile */
    .profile-about { padding: 0 1rem; margin-top: 1rem; }
    .profile-about-title { font-size: 1rem; }
    .profile-about-text { font-size: 0.9rem; }
    
    /* Navigation Mobile */
    .nav-tabs { justify-content: flex-start; overflow-x: auto; padding: 0 1rem; gap: 0.25rem; -webkit-overflow-scrolling: touch; scrollbar-width: none; }
    .nav-tabs::-webkit-scrollbar { display: none; }
    .nav-tab { flex-shrink: 0; font-size: 0.85rem; padding: 0.6rem 1rem; }
    
    /* Container Mobile */
    .container { padding: 0 1rem 2rem; }
    
    /* Action Bar Mobile */
    .action-bar { flex-direction: column; gap: 0.75rem; }
    .btn { width: 100%; justify-content: center; padding: 0.75rem 1rem; }
    .search-box { width: 100%; }
    
    /* Manga Grid Mobile */
    .manga-grid { grid-template-columns: 1fr; gap: 1rem; }
    .manga-card-header { padding: 1rem; gap: 0.75rem; }
    .manga-cover { width: 70px; height: 100px; }
    .manga-title { font-size: 1.1rem; }
    .manga-publisher { font-size: 0.75rem; }
    .manga-value { font-size: 0.8rem; }
    .manga-card-footer { padding: 0 1rem 1rem; }
    
    /* Detail Modal Mobile */
    .modal { max-width: 100%; margin: 0; border-radius: 12px 12px 0 0; max-height: 90vh; }
    .modal-header { padding: 1rem; }
    .modal-body { padding: 1rem; }
    .detail-header { flex-direction: column; align-items: center; text-align: center; gap: 1rem; }
    .detail-cover { width: 120px; height: 180px; }
    .detail-stats { justify-content: center; flex-wrap: wrap; }
    .form-row { flex-direction: column; gap: 0; }
    
    /* Messages Mobile */
    .messages-container { flex-direction: column; height: 70vh; }
    .conversations-list { width: 100%; max-height: 200px; border-right: none; border-bottom: 1px solid var(--border); }
    .conversations-scroll { max-height: 150px; }
    .chat-area { flex: 1; min-height: 300px; }
    .chat-header { padding: 0.75rem; }
    .chat-messages { padding: 0.75rem; }
    .chat-message { max-width: 90%; }
    .chat-input-area { padding: 0.75rem; }
    .chat-input-area input { font-size: 16px; } /* Prevents iOS zoom */
    
    /* Leaderboard Mobile */
    .leaderboard-container { padding: 1rem; }
    .leaderboard-header h2 { font-size: 1.5rem; }
    .leaderboard-podium { flex-direction: column; align-items: center; gap: 1rem; padding: 1rem 0; }
    .podium-item { width: 80%; max-width: 200px; }
    .podium-item.gold { order: -1; }
    .podium-item.silver { order: 0; }
    .podium-item.bronze { order: 1; }
    .podium-cover { width: 100px; height: 150px; }
    .podium-item.gold .podium-cover { width: 120px; height: 180px; }
    .podium-rank { font-size: 1.5rem; }
    .podium-title { font-size: 1rem; }
    .leaderboard-list { gap: 0.5rem; }
    .leaderboard-item { padding: 0.75rem; }
    .leaderboard-cover { width: 45px; height: 65px; }
    .leaderboard-title { font-size: 0.9rem; }
    .leaderboard-score-value { font-size: 1.1rem; }
    
    /* Auth Card Mobile */
    .auth-card { padding: 1.5rem; margin: 1rem; }
    .auth-logo h1 { font-size: 2rem; }
    
    /* Social Section Mobile */
    .social-section { padding: 0; }
    .comment-form { padding: 0.75rem; }
    .comment-form textarea { min-height: 60px; font-size: 16px; }
    .activity-header { padding: 0.75rem; }
    .activity-avatar { width: 40px; height: 40px; }
    .activity-content { padding: 0 0.75rem 0.75rem; font-size: 0.9rem; }
    .activity-actions { padding: 0.5rem 0.75rem; }
    
    /* Favorites Mobile */
    .favorites-grid { grid-template-columns: repeat(auto-fill, minmax(70px, 1fr)); gap: 0.5rem; }
    .favorites-grid.characters { grid-template-columns: repeat(auto-fill, minmax(60px, 1fr)); }
    
    /* User Cards Mobile */
    .user-card { padding: 0.75rem; }
    .user-card-avatar { width: 50px; height: 50px; }
    .user-card-name { font-size: 1.1rem; }
    
    /* Shopping List Mobile */
    .shopping-header { flex-direction: column; align-items: stretch; }
    .shopping-total { text-align: center; }
    
    /* Stats Page Mobile */
    .stats-grid { grid-template-columns: repeat(2, 1fr); gap: 0.75rem; }
    .stat-card { padding: 1rem; }
    .stat-value { font-size: 1.5rem; }
    .stat-label { font-size: 0.7rem; }
    
    /* Volume Selector Mobile */
    .volume-selector { gap: 0.35rem; }
    .volume-chip { width: 36px; height: 36px; font-size: 0.8rem; }
    
    /* Quick Actions Mobile */
    .quick-actions { flex-wrap: wrap; }
    .quick-action-btn { flex: 1; min-width: 80px; font-size: 0.8rem; }
    
    /* Price Presets Mobile */
    .price-presets { justify-content: center; }
}

/* Extra small screens */
@media (max-width: 400px) {
    .profile-stats-row { gap: 0.25rem; }
    .profile-stat { min-width: 50px; padding: 0.3rem; }
    .profile-stat-value { font-size: 1rem; }
    .profile-stat-label { font-size: 0.6rem; }
    .manga-cover { width: 60px; height: 85px; }
    .manga-title { font-size: 1rem; }
    .leaderboard-header h2 { font-size: 1.3rem; }
    .podium-cover { width: 80px; height: 120px; }
    .podium-item.gold .podium-cover { width: 100px; height: 150px; }
}

/* User Search Results */
.user-card { display: flex; gap: 1rem; padding: 1rem; background: var(--bg-secondary); border: 1px solid var(--border); border-radius: 8px; margin-bottom: 0.75rem; cursor: pointer; transition: all 0.2s; }
.user-card:hover { border-color: var(--accent); transform: translateX(4px); }
.user-card-avatar { width: 60px; height: 60px; border-radius: 8px; overflow: hidden; flex-shrink: 0; background: var(--bg-card); display: flex; align-items: center; justify-content: center; font-size: 1.5rem; }
.user-card-avatar img { width: 100%; height: 100%; object-fit: cover; }
.user-card-info { flex: 1; }
.user-card-name { font-family: 'Bebas Neue', sans-serif; font-size: 1.2rem; }
.user-card-username { color: var(--text-secondary); font-size: 0.85rem; }
.user-card-stats { display: flex; gap: 1rem; margin-top: 0.5rem; font-size: 0.8rem; color: var(--text-muted); }
.user-card-stats span { color: var(--accent); font-weight: 600; }

/* Viewing other profile indicator */


/* AniList-Style Activity/Social Section */
.social-section { max-width: 800px; margin: 0 auto; }
.comment-form { background: var(--bg-card); border-radius: 12px; border: 1px solid var(--border); padding: 1rem; margin-bottom: 1.5rem; }
.comment-form textarea { width: 100%; min-height: 80px; background: var(--bg-secondary); border: 1px solid var(--border); border-radius: 8px; padding: 0.75rem; color: var(--text-primary); font-family: inherit; font-size: 0.95rem; resize: vertical; margin-bottom: 0.75rem; }
.comment-form textarea:focus { outline: none; border-color: var(--accent); }
.comment-form-actions { display: flex; justify-content: space-between; align-items: center; gap: 0.5rem; }
.comment-media-btns { display: flex; gap: 0.5rem; }
.media-btn { background: var(--bg-secondary); border: 1px solid var(--border); border-radius: 8px; padding: 0.5rem 0.75rem; color: var(--text-primary); font-size: 0.85rem; cursor: pointer; transition: all 0.2s; display: flex; align-items: center; gap: 0.35rem; }
.media-btn:hover { background: var(--bg-card); border-color: var(--accent); color: var(--accent); }
.comment-image { max-width: 100%; max-height: 300px; border-radius: 8px; margin-top: 0.5rem; cursor: pointer; transition: transform 0.2s; display: block; }
.comment-image:hover { transform: scale(1.02); }

.activity-feed { display: flex; flex-direction: column; gap: 1rem; }
.activity-item { background: var(--bg-card); border-radius: 12px; border: 1px solid var(--border); overflow: hidden; transition: border-color 0.2s; }
.activity-item:hover { border-color: var(--border); }
.activity-header { display: flex; gap: 0.75rem; padding: 1rem; }
.activity-avatar { width: 45px; height: 45px; border-radius: 8px; overflow: hidden; flex-shrink: 0; cursor: pointer; }
.activity-avatar img { width: 100%; height: 100%; object-fit: cover; }
.activity-meta { flex: 1; }
.activity-author { font-weight: 600; cursor: pointer; }
.activity-author:hover { color: var(--accent); }
.activity-time { font-size: 0.8rem; color: var(--text-muted); }
.activity-content { padding: 0 1rem 1rem; line-height: 1.6; white-space: pre-wrap; }
.activity-actions { padding: 0.75rem 1rem; border-top: 1px solid var(--border); display: flex; gap: 1rem; }
.activity-action { background: none; border: none; color: var(--text-muted); font-size: 0.85rem; cursor: pointer; display: flex; align-items: center; gap: 0.25rem; padding: 0.25rem 0.5rem; border-radius: 4px; transition: all 0.2s; }
.activity-action:hover { background: var(--bg-secondary); color: var(--accent); }
.activity-action.danger:hover { color: var(--accent); }

.activity-empty { text-align: center; padding: 3rem; color: var(--text-muted); }
.activity-empty-icon { font-size: 3rem; margin-bottom: 1rem; opacity: 0.5; }

/* Favorites Grid (AniList Style) */
.favorites-section { margin-bottom: 2rem; }
.favorites-title { font-family: 'Bebas Neue', sans-serif; font-size: 1.1rem; color: var(--text-secondary); margin-bottom: 0.75rem; display: flex; align-items: center; gap: 0.5rem; }
.favorites-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(85px, 1fr)); gap: 0.75rem; }
.favorite-item { position: relative; aspect-ratio: 2/3; border-radius: 8px; overflow: hidden; cursor: pointer; transition: transform 0.2s; }
.favorite-item:hover { transform: scale(1.05); }
.favorite-item img { width: 100%; height: 100%; object-fit: cover; }
.favorite-item-overlay { position: absolute; bottom: 0; left: 0; right: 0; background: linear-gradient(transparent, rgba(0,0,0,0.9)); padding: 0.5rem; }
.favorite-item-name { font-size: 0.7rem; font-weight: 500; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

/* Character favorites (square) */
.favorites-grid.characters { grid-template-columns: repeat(auto-fill, minmax(70px, 1fr)); }
.favorite-item.character { aspect-ratio: 1; border-radius: 8px; }

/* Profile Overview Grid */
.profile-content-grid { display: grid; grid-template-columns: 1fr 320px; gap: 2rem; max-width: 1400px; margin: 0 auto; padding: 0 2rem; }
.profile-main { min-width: 0; }
.profile-sidebar { display: flex; flex-direction: column; gap: 1.5rem; }

@media (max-width: 900px) {
    .profile-content-grid { grid-template-columns: 1fr; padding: 0 1rem; }
    .profile-sidebar { order: -1; }
}

/* Leaderboard Page Styles */
.leaderboard-container { max-width: 1000px; margin: 0 auto; padding: 2rem; }
.leaderboard-header { text-align: center; margin-bottom: 2rem; }
.leaderboard-header h2 { font-family: 'Bebas Neue', sans-serif; font-size: 2.5rem; }
.leaderboard-tabs { display: flex; justify-content: center; gap: 0.5rem; margin-bottom: 2rem; }
.leaderboard-tab { background: var(--bg-card); border: 1px solid var(--border); color: var(--text-secondary); padding: 0.75rem 2rem; border-radius: 8px; cursor: pointer; font-size: 1rem; transition: all 0.2s; }
.leaderboard-tab:hover { border-color: var(--accent); color: var(--text-primary); }
.leaderboard-tab.active { background: var(--accent); border-color: var(--accent); color: white; }
.leaderboard-podium { display: flex; justify-content: center; align-items: flex-end; gap: 1rem; margin-bottom: 2rem; padding: 1rem; }
.leaderboard-podium.users .podium-item { text-align: center; }
.podium-item { background: var(--bg-card); border-radius: 12px; padding: 1rem; text-align: center; cursor: pointer; transition: all 0.3s; border: 2px solid transparent; }
.podium-item:hover { transform: translateY(-4px); }
.podium-item.gold { order: 0; border-color: #ffd700; box-shadow: 0 0 20px rgba(255, 215, 0, 0.3); }
.podium-item.silver { order: -1; border-color: #c0c0c0; }
.podium-item.bronze { order: 1; border-color: #cd7f32; }
.podium-cover { width: 120px; height: 180px; border-radius: 8px; overflow: hidden; margin: 0 auto 0.75rem; }
.podium-item.gold .podium-cover { width: 140px; height: 210px; }
.podium-cover img { width: 100%; height: 100%; object-fit: cover; }
.podium-avatar { width: 80px; height: 80px; border-radius: 50%; overflow: hidden; margin: 0 auto 0.75rem; }
.podium-item.gold .podium-avatar { width: 100px; height: 100px; }
.podium-avatar img { width: 100%; height: 100%; object-fit: cover; }
.podium-rank { font-family: 'Bebas Neue', sans-serif; font-size: 1.5rem; }
.podium-item.gold .podium-rank { color: #ffd700; font-size: 2rem; }
.podium-item.silver .podium-rank { color: #c0c0c0; }
.podium-item.bronze .podium-rank { color: #cd7f32; }
.podium-title { font-weight: 600; margin: 0.25rem 0; font-size: 0.95rem; max-width: 140px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.podium-username { color: var(--text-muted); font-size: 0.8rem; }
.podium-score { color: var(--accent); font-family: 'Bebas Neue', sans-serif; font-size: 1.3rem; }
.podium-votes { color: var(--text-muted); font-size: 0.75rem; }
.leaderboard-list { display: flex; flex-direction: column; gap: 0.5rem; }
.leaderboard-item { display: flex; align-items: center; gap: 1rem; background: var(--bg-card); border: 1px solid var(--border); border-radius: 8px; padding: 0.75rem 1rem; cursor: pointer; transition: all 0.2s; }
.leaderboard-item:hover { border-color: var(--accent); transform: translateX(4px); }
.leaderboard-rank { font-family: 'Bebas Neue', sans-serif; font-size: 1.2rem; color: var(--text-muted); min-width: 40px; }
.leaderboard-cover { width: 50px; height: 75px; border-radius: 4px; overflow: hidden; flex-shrink: 0; }
.leaderboard-cover img { width: 100%; height: 100%; object-fit: cover; }
.leaderboard-avatar { width: 45px; height: 45px; border-radius: 50%; overflow: hidden; flex-shrink: 0; background: var(--bg-secondary); }
.leaderboard-avatar img { width: 100%; height: 100%; object-fit: cover; }
.leaderboard-info { flex: 1; min-width: 0; }
.leaderboard-title { font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.leaderboard-subtitle { color: var(--text-muted); font-size: 0.8rem; }
.leaderboard-score { text-align: right; }
.leaderboard-score-value { font-family: 'Bebas Neue', sans-serif; font-size: 1.5rem; color: var(--accent); }
.leaderboard-score-label { font-size: 0.7rem; color: var(--text-muted); }

/* Active nav button */
.auth-bar-btn.active { background: rgba(230, 57, 70, 0.2); color: var(--accent); }

/* Discover Page Styles */
.discover-container { max-width: 1200px; margin: 0 auto; padding: 2rem; }
.discover-header { text-align: center; margin-bottom: 2rem; }
.discover-header h2 { font-family: 'Bebas Neue', sans-serif; font-size: 2.5rem; margin-bottom: 0.5rem; }
.discover-header p { color: var(--text-secondary); }
.discover-actions { display: flex; justify-content: center; margin-bottom: 2rem; }
.recommendations-intro { text-align: center; margin-bottom: 1.5rem; color: var(--text-secondary); }
.recommendations-intro strong { color: var(--accent); }
.recommendations-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); gap: 1.25rem; }
.recommendation-card { background: var(--bg-card); border: 1px solid var(--border); border-radius: 12px; overflow: hidden; cursor: pointer; transition: all 0.3s; }
.recommendation-card:hover { transform: translateY(-4px); border-color: var(--accent); box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3); }
.recommendation-cover { aspect-ratio: 2/3; overflow: hidden; position: relative; }
.recommendation-cover img { width: 100%; height: 100%; object-fit: cover; }
.recommendation-score { position: absolute; top: 0.5rem; right: 0.5rem; background: rgba(0,0,0,0.8); color: #ffd700; font-weight: 700; font-size: 0.8rem; padding: 0.25rem 0.5rem; border-radius: 6px; }
.recommendation-info { padding: 0.875rem; }
.recommendation-title { font-weight: 600; margin-bottom: 0.25rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; font-size: 0.95rem; }
.recommendation-meta { font-size: 0.8rem; color: var(--text-muted); margin-bottom: 0.5rem; }
.recommendation-reason { font-size: 0.75rem; color: var(--text-secondary); line-height: 1.4; }
.recommendation-reason strong { color: var(--accent); font-weight: 500; }

@media (max-width: 768px) {
    .leaderboard-container { padding: 1rem; }
    .leaderboard-header h2 { font-size: 1.8rem; }
    .leaderboard-tabs { flex-wrap: wrap; }
    .leaderboard-tab { padding: 0.5rem 1rem; font-size: 0.9rem; }
    .leaderboard-podium { flex-direction: column; align-items: center; }
    .podium-item { width: 80%; max-width: 200px; }
    .podium-item.gold { order: -1; }
    .podium-cover { width: 100px; height: 150px; }
    .podium-item.gold .podium-cover { width: 120px; height: 180px; }
    .discover-container { padding: 1rem; }
    .discover-header h2 { font-size: 1.8rem; }
    .recommendations-grid { grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); gap: 1rem; }
}

/* Reading Tracker Styles */
.reading-tracker { max-width: 1000px; margin: 0 auto; }
.reading-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 1.5rem; flex-wrap: wrap; gap: 1rem; }
.reading-header h2 { font-family: 'Bebas Neue', sans-serif; font-size: 1.8rem; margin: 0; }
.reading-actions { display: flex; gap: 0.5rem; }

/* Visual Stats Cards */
.reading-visual-stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1rem; margin-bottom: 1.5rem; }
.visual-stat-card { background: linear-gradient(135deg, var(--bg-card) 0%, var(--bg-secondary) 100%); border: 1px solid var(--border); border-radius: 16px; padding: 1.25rem; display: flex; align-items: center; gap: 1rem; position: relative; overflow: hidden; }
.visual-stat-card::before { content: ''; position: absolute; top: 0; left: 0; right: 0; height: 3px; }
.visual-stat-card.chapters::before { background: linear-gradient(90deg, #e74c3c, #c0392b); }
.visual-stat-card.volumes::before { background: linear-gradient(90deg, #3498db, #2980b9); }
.visual-stat-card.time::before { background: linear-gradient(90deg, #2ecc71, #27ae60); }
.visual-stat-card.score::before { background: linear-gradient(90deg, #f1c40f, #f39c12); }
.visual-stat-icon { width: 50px; height: 50px; border-radius: 12px; display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.visual-stat-card.chapters .visual-stat-icon { background: rgba(231, 76, 60, 0.15); color: #e74c3c; }
.visual-stat-card.volumes .visual-stat-icon { background: rgba(52, 152, 219, 0.15); color: #3498db; }
.visual-stat-card.time .visual-stat-icon { background: rgba(46, 204, 113, 0.15); color: #2ecc71; }
.visual-stat-card.score .visual-stat-icon { background: rgba(241, 196, 15, 0.15); color: #f1c40f; }
.visual-stat-icon svg { width: 26px; height: 26px; }
.visual-stat-content { flex: 1; min-width: 0; }
.visual-stat-value { font-family: 'Bebas Neue', sans-serif; font-size: 2rem; line-height: 1; margin-bottom: 0.2rem; }
.visual-stat-card.chapters .visual-stat-value { color: #e74c3c; }
.visual-stat-card.volumes .visual-stat-value { color: #3498db; }
.visual-stat-card.time .visual-stat-value { color: #2ecc71; }
.visual-stat-card.score .visual-stat-value { color: #f1c40f; }
.visual-stat-value.glow { text-shadow: 0 0 10px rgba(241, 196, 15, 0.5), 0 0 20px rgba(241, 196, 15, 0.3), 0 0 30px rgba(241, 196, 15, 0.2); animation: scoreGlow 2s ease-in-out infinite alternate; }
@keyframes scoreGlow { from { text-shadow: 0 0 10px rgba(241, 196, 15, 0.5), 0 0 20px rgba(241, 196, 15, 0.3); } to { text-shadow: 0 0 15px rgba(241, 196, 15, 0.7), 0 0 30px rgba(241, 196, 15, 0.5), 0 0 45px rgba(241, 196, 15, 0.3); } }
.visual-stat-label { font-size: 0.8rem; color: var(--text-muted); text-transform: uppercase; letter-spacing: 0.5px; }
.visual-stat-card.score { padding-top: 1.75rem; }
.reader-title { position: absolute; top: 0.5rem; left: 50%; transform: translateX(-50%); font-size: 0.55rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.5px; padding: 0.15rem 0.5rem; border-radius: 4px; background: linear-gradient(135deg, #f1c40f, #f39c12); color: #1a1a2e; white-space: nowrap; z-index: 1; }

.reading-stats { display: flex; gap: 0.75rem; margin-bottom: 1.5rem; flex-wrap: wrap; }
.reading-stat { flex: 1; min-width: 100px; background: var(--bg-card); border: 2px solid var(--border); border-radius: 12px; padding: 1rem; text-align: center; cursor: pointer; transition: all 0.2s; }
.reading-stat:hover { transform: translateY(-2px); }
.reading-stat-value { font-family: 'Bebas Neue', sans-serif; font-size: 2rem; }
.reading-stat-label { font-size: 0.75rem; color: var(--text-muted); text-transform: uppercase; }

.reading-filters { display: flex; gap: 0.5rem; margin-bottom: 1.5rem; flex-wrap: wrap; }

.reading-list { display: flex; flex-direction: column; gap: 0.75rem; }
.reading-item { display: flex; gap: 1rem; background: var(--bg-card); border: 1px solid var(--border); border-radius: 12px; padding: 1rem; cursor: pointer; transition: all 0.2s; }
.reading-item:hover { border-color: var(--accent); transform: translateX(4px); }
.reading-item-cover { width: 60px; height: 90px; border-radius: 6px; overflow: hidden; flex-shrink: 0; background: var(--bg-secondary); }
.reading-item-cover img { width: 100%; height: 100%; object-fit: cover; }
.reading-item-cover .no-cover { width: 100%; height: 100%; display: flex; align-items: center; justify-content: center; color: var(--text-muted); font-size: 1.5rem; }
.reading-item-info { flex: 1; min-width: 0; }
.reading-item-title { font-weight: 600; margin-bottom: 0.25rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.reading-item-status { font-size: 0.8rem; font-weight: 500; margin-bottom: 0.5rem; }
.reading-item-progress-text { font-size: 0.75rem; color: var(--text-muted); margin-bottom: 0.35rem; }
.reading-item-progress { height: 4px; background: var(--bg-secondary); border-radius: 2px; overflow: hidden; }
.reading-item-progress-bar { height: 100%; border-radius: 2px; transition: width 0.3s; }
.reading-item-score { display: flex; align-items: center; }
.score-badge { background: var(--accent); color: white; font-weight: 600; padding: 0.25rem 0.5rem; border-radius: 6px; font-size: 0.9rem; }

/* Import Modal */
.import-options { display: flex; flex-direction: column; gap: 1rem; }
.import-option { display: flex; gap: 1rem; padding: 1rem; background: var(--bg-secondary); border: 1px solid var(--border); border-radius: 12px; cursor: pointer; transition: all 0.2s; }
.import-option:hover { border-color: var(--accent); }
.import-option-icon { width: 50px; height: 50px; border-radius: 10px; background: var(--accent); color: white; display: flex; align-items: center; justify-content: center; font-weight: 700; font-size: 1.1rem; flex-shrink: 0; }
.import-option-info { flex: 1; }
.import-option-title { font-weight: 600; margin-bottom: 0.25rem; }
.import-option-desc { font-size: 0.85rem; color: var(--text-muted); }

@media (max-width: 768px) {
    .reading-header { flex-direction: column; align-items: stretch; }
    .reading-actions { justify-content: center; }
    .reading-visual-stats { grid-template-columns: repeat(2, 1fr); gap: 0.75rem; }
    .visual-stat-card { padding: 1rem; }
    .visual-stat-icon { width: 40px; height: 40px; }
    .visual-stat-icon svg { width: 20px; height: 20px; }
    .visual-stat-value { font-size: 1.5rem; }
    .reader-title { font-size: 0.5rem; padding: 0.1rem 0.35rem; }
    .reading-stats { gap: 0.5rem; }
    .reading-stat { min-width: 80px; padding: 0.75rem 0.5rem; }
    .reading-stat-value { font-size: 1.5rem; }
    .reading-item { padding: 0.75rem; }
    .reading-item-cover { width: 50px; height: 75px; }
}

/* ==================== FORUM STYLES ==================== */
.forum-container { max-width: 1200px; margin: 0 auto; }
.forum-header { text-align: center; margin-bottom: 2rem; }
.forum-header h1 { font-family: 'Bebas Neue', sans-serif; font-size: 2.5rem; margin-bottom: 0.5rem; }
.forum-header p { color: var(--text-muted); }
.forum-header.category-header { display: flex; align-items: center; gap: 1rem; text-align: left; padding: 1.5rem; background: var(--bg-card); border-radius: 12px; }
.category-header-icon { width: 60px; height: 60px; border-radius: 12px; display: flex; align-items: center; justify-content: center; font-size: 1.8rem; }

.forum-layout { display: grid; grid-template-columns: 1fr 300px; gap: 1.5rem; }
.forum-main { min-width: 0; }
.forum-sidebar { display: flex; flex-direction: column; gap: 1rem; }

.forum-toolbar { display: flex; justify-content: space-between; align-items: center; margin-bottom: 1rem; flex-wrap: wrap; gap: 0.5rem; }
.forum-sort { display: flex; gap: 0.25rem; background: var(--bg-card); padding: 0.25rem; border-radius: 8px; }
.sort-btn { background: transparent; border: none; color: var(--text-muted); padding: 0.5rem 1rem; border-radius: 6px; cursor: pointer; font-size: 0.9rem; transition: all 0.2s; }
.sort-btn:hover { color: var(--text-primary); }
.sort-btn.active { background: var(--accent); color: white; }

.forum-categories-card, .forum-rules-card { background: var(--bg-card); border-radius: 12px; padding: 1rem; border: 1px solid var(--border); }
.forum-categories-card h3, .forum-rules-card h3 { font-size: 1rem; margin-bottom: 1rem; padding-bottom: 0.5rem; border-bottom: 1px solid var(--border); }
.forum-categories-list { display: flex; flex-direction: column; gap: 0.5rem; }
.forum-category-item { display: flex; align-items: center; gap: 0.75rem; padding: 0.75rem; border-radius: 8px; cursor: pointer; transition: all 0.2s; }
.forum-category-item:hover { background: var(--bg-secondary); }
.forum-category-item.active { background: var(--bg-secondary); border: 1px solid var(--accent); }
.category-icon { width: 36px; height: 36px; border-radius: 8px; display: flex; align-items: center; justify-content: center; font-size: 1.1rem; }
.category-info { flex: 1; }
.category-name { font-weight: 500; font-size: 0.9rem; }
.category-count { font-size: 0.75rem; color: var(--text-muted); }

.forum-rules-card ul { margin: 0; padding-left: 1.25rem; }
.forum-rules-card li { font-size: 0.85rem; color: var(--text-muted); margin-bottom: 0.5rem; }

/* Forum Posts */
.forum-posts { display: flex; flex-direction: column; gap: 0.75rem; }
.forum-post-card { display: flex; gap: 1rem; background: var(--bg-card); border-radius: 12px; padding: 1rem; border: 1px solid var(--border); cursor: pointer; transition: all 0.2s; }
.forum-post-card:hover { border-color: var(--accent); transform: translateY(-2px); }
.forum-empty { text-align: center; padding: 3rem; color: var(--text-muted); }

.post-votes { display: flex; flex-direction: column; align-items: center; gap: 0.25rem; min-width: 40px; }
.post-votes.vertical { flex-direction: column; }
.vote-btn { background: transparent; border: none; color: var(--text-muted); cursor: pointer; padding: 0.25rem; border-radius: 4px; transition: all 0.2s; }
.vote-btn:hover { background: var(--bg-secondary); }
.vote-btn svg { width: 20px; height: 20px; }
.vote-btn.small svg { width: 16px; height: 16px; }
.vote-btn.upvote.active { color: #ff4500; }
.vote-btn.downvote.active { color: #7193ff; }
.vote-score { font-weight: 600; font-size: 0.9rem; }
.vote-score.small { font-size: 0.8rem; }
.vote-score.positive { color: #ff4500; }
.vote-score.negative { color: #7193ff; }

.post-content { flex: 1; min-width: 0; }
.post-meta { display: flex; align-items: center; gap: 0.75rem; margin-bottom: 0.5rem; flex-wrap: wrap; font-size: 0.8rem; }
.post-category { padding: 0.2rem 0.5rem; border-radius: 4px; color: white; font-size: 0.7rem; font-weight: 500; }
.post-author { display: flex; align-items: center; gap: 0.35rem; color: var(--text-muted); }
.post-avatar { width: 20px; height: 20px; border-radius: 50%; overflow: hidden; background: var(--accent); display: flex; align-items: center; justify-content: center; }
.post-avatar img { width: 100%; height: 100%; object-fit: cover; }
.post-avatar span { font-size: 0.65rem; color: white; font-weight: 600; }
.post-time { color: var(--text-muted); }
.post-title { font-size: 1.1rem; font-weight: 600; margin-bottom: 0.5rem; line-height: 1.3; }
.post-preview { color: var(--text-muted); font-size: 0.9rem; line-height: 1.5; margin-bottom: 0.75rem; }
.post-stats { display: flex; gap: 1rem; font-size: 0.8rem; color: var(--text-muted); }
.post-comments { display: flex; align-items: center; gap: 0.35rem; }
.post-comments svg { width: 16px; height: 16px; }

/* Post Detail */
.forum-post-detail { background: var(--bg-card); border-radius: 12px; border: 1px solid var(--border); overflow: hidden; }
.post-detail-header { display: flex; gap: 1rem; padding: 1.5rem; border-bottom: 1px solid var(--border); }
.post-detail-content { flex: 1; }
.post-detail-title { font-size: 1.5rem; font-weight: 600; margin-bottom: 1rem; line-height: 1.3; }
.post-detail-body { font-size: 1rem; line-height: 1.7; color: var(--text-secondary); margin-bottom: 1rem; }
.post-detail-body a { color: var(--accent); }
.post-image { max-width: 100%; border-radius: 8px; margin-bottom: 1rem; }
.post-actions { display: flex; gap: 0.5rem; }

/* Comments */
.post-comments-section { padding: 1.5rem; }
.post-comments-section h3 { margin-bottom: 1rem; }
.comment-form { margin-bottom: 1.5rem; display: flex; flex-direction: column; gap: 0.75rem; }
.comment-form textarea { resize: vertical; }
.login-hint { color: var(--text-muted); font-size: 0.9rem; margin-bottom: 1rem; }
.comments-list { display: flex; flex-direction: column; gap: 1rem; }

.comment-card { display: flex; gap: 0.75rem; }
.comment-votes { display: flex; flex-direction: column; align-items: center; gap: 0.15rem; }
.comment-content { flex: 1; background: var(--bg-secondary); padding: 1rem; border-radius: 8px; }
.comment-header { display: flex; align-items: center; gap: 0.5rem; margin-bottom: 0.5rem; font-size: 0.85rem; }
.comment-avatar { width: 24px; height: 24px; border-radius: 50%; overflow: hidden; background: var(--accent); display: flex; align-items: center; justify-content: center; }
.comment-avatar img { width: 100%; height: 100%; object-fit: cover; }
.comment-avatar span { font-size: 0.7rem; color: white; font-weight: 600; }
.comment-header a { font-weight: 500; color: var(--text-primary); text-decoration: none; }
.comment-header a:hover { color: var(--accent); }
.comment-time { color: var(--text-muted); font-size: 0.75rem; }
.comment-body { font-size: 0.95rem; line-height: 1.5; margin-bottom: 0.5rem; }
.comment-actions { display: flex; gap: 1rem; }
.comment-action-btn { background: none; border: none; color: var(--text-muted); font-size: 0.8rem; cursor: pointer; padding: 0; }
.comment-action-btn:hover { color: var(--accent); }
.comment-replies { margin-top: 1rem; padding-left: 1rem; border-left: 2px solid var(--border); }

.forum-loading { text-align: center; padding: 3rem; }
.forum-loading p { margin-top: 1rem; color: var(--text-muted); }
.forum-error { text-align: center; padding: 3rem; color: var(--accent); }

/* Mobile Responsive */
@media (max-width: 900px) {
    .forum-layout { grid-template-columns: 1fr; }
    .forum-sidebar { order: -1; }
    .forum-categories-card { display: none; }
}
@media (max-width: 600px) {
    .forum-post-card { flex-direction: column; }
    .post-votes { flex-direction: row; justify-content: flex-start; }
    .post-detail-header { flex-direction: column; }
    .post-votes.vertical { flex-direction: row; margin-bottom: 1rem; }
}

/* Forum Breadcrumbs */
.forum-breadcrumbs { display: flex; align-items: center; gap: 0.5rem; margin-bottom: 1rem; font-size: 0.9rem; flex-wrap: wrap; }
.forum-breadcrumbs a { color: var(--accent); text-decoration: none; }
.forum-breadcrumbs a:hover { text-decoration: underline; }
.breadcrumb-sep { color: var(--text-muted); }
.breadcrumb-current { color: var(--text-muted); }

/* Forum Author Large Style */
.post-author-large { display: flex; align-items: center; gap: 0.75rem; margin: 1rem 0; }
.post-avatar-large { width: 48px; height: 48px; border-radius: 50%; overflow: hidden; background: var(--accent); display: flex; align-items: center; justify-content: center; cursor: pointer; flex-shrink: 0; }
.post-avatar-large img { width: 100%; height: 100%; object-fit: cover; }
.post-avatar-large span { font-size: 1.2rem; color: white; font-weight: 600; }
.post-author-info { display: flex; flex-direction: column; gap: 0.15rem; }
.post-author-name { display: flex; align-items: center; gap: 0.5rem; font-size: 1rem; }
.post-author-name a { font-weight: 600; color: var(--text-primary); text-decoration: none; }
.post-author-name a:hover { color: var(--accent); }

/* Role Tags */
.role-tag { font-size: 0.65rem; font-weight: 600; padding: 0.15rem 0.4rem; border-radius: 4px; text-transform: uppercase; letter-spacing: 0.5px; }
.role-admin { background: linear-gradient(135deg, #e74c3c, #c0392b); color: white; }
.role-mod { background: linear-gradient(135deg, #3498db, #2980b9); color: white; }

/* Comment header with role tag */
.comment-header .role-tag { margin-left: 0.25rem; }

/* ==================== SETTINGS STYLES ==================== */
.settings-container { max-width: 1000px; margin: 0 auto; }
.settings-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 2rem; flex-wrap: wrap; gap: 1rem; }
.settings-header h1 { font-family: 'Bebas Neue', sans-serif; font-size: 2rem; margin: 0; }

.settings-layout { display: grid; grid-template-columns: 220px 1fr; gap: 2rem; }
.settings-sidebar { display: flex; flex-direction: column; gap: 0.25rem; }
.settings-nav-item { display: flex; align-items: center; gap: 0.75rem; padding: 0.75rem 1rem; background: transparent; border: none; border-radius: 8px; color: var(--text-secondary); cursor: pointer; transition: all 0.2s; text-align: left; font-size: 0.95rem; }
.settings-nav-item:hover { background: var(--bg-secondary); color: var(--text-primary); }
.settings-nav-item.active { background: var(--accent); color: white; }

/* Settings Pro Button */
.settings-pro-button { display: flex; align-items: center; gap: 0.75rem; padding: 0.85rem 1rem; margin-top: 1rem; background: linear-gradient(135deg, rgba(168,85,247,0.15), rgba(236,72,153,0.15)); border: 1px solid rgba(168,85,247,0.3); border-radius: 12px; cursor: pointer; transition: all 0.3s; position: relative; overflow: hidden; }
.settings-pro-button:hover { background: linear-gradient(135deg, rgba(168,85,247,0.25), rgba(236,72,153,0.25)); border-color: rgba(168,85,247,0.5); transform: translateY(-2px); box-shadow: 0 8px 25px rgba(168,85,247,0.3); }
.settings-pro-glow { position: absolute; inset: 0; background: radial-gradient(circle at 50% 50%, rgba(168,85,247,0.3), transparent 70%); opacity: 0; animation: proGlow 2s ease-in-out infinite; }
@keyframes proGlow { 0%, 100% { opacity: 0; transform: scale(1); } 50% { opacity: 1; transform: scale(1.1); } }
.settings-pro-icon { font-size: 1.2rem; animation: proCrown 3s ease-in-out infinite; }
@keyframes proCrown { 0%, 100% { transform: rotate(-5deg); } 50% { transform: rotate(5deg); } }
.settings-pro-text { flex: 1; font-weight: 600; background: linear-gradient(135deg, #a855f7, #ec4899); -webkit-background-clip: text; -webkit-text-fill-color: transparent; background-clip: text; }
.settings-pro-badge { font-size: 0.6rem; font-weight: 700; padding: 0.2rem 0.4rem; background: linear-gradient(135deg, #a855f7, #ec4899); color: white; border-radius: 4px; text-transform: uppercase; letter-spacing: 0.5px; animation: proBadgePulse 2s ease-in-out infinite; }
@keyframes proBadgePulse { 0%, 100% { opacity: 1; } 50% { opacity: 0.7; } }
.settings-nav-icon { font-size: 1.1rem; }

.settings-content { min-width: 0; }
.settings-section h2 { font-size: 1.5rem; margin-bottom: 0.5rem; }
.settings-description { color: var(--text-muted); margin-bottom: 1.5rem; }

.settings-card { background: var(--bg-card); border: 1px solid var(--border); border-radius: 12px; padding: 1.5rem; margin-bottom: 1rem; }

/* Creator Settings Card */
.settings-creator-card { border: 1px solid rgba(255, 0, 80, 0.3); background: linear-gradient(135deg, rgba(0, 242, 234, 0.05), rgba(255, 0, 80, 0.05)); }
.settings-creator-header { display: flex; align-items: center; gap: 0.75rem; margin-bottom: 0.5rem; }
.creator-badge-small { background: linear-gradient(135deg, #00f2ea, #ff0050); color: white; font-weight: 700; font-size: 0.6rem; padding: 0.2rem 0.5rem; border-radius: 4px; letter-spacing: 0.5px; }
.input-with-prefix { display: flex; align-items: center; }
.input-prefix { background: var(--bg-secondary); border: 1px solid var(--border); border-right: none; padding: 0.75rem 0.75rem; border-radius: 8px 0 0 8px; color: var(--text-muted); font-size: 0.9rem; }
.input-with-prefix .form-input { border-radius: 0 8px 8px 0; }
.settings-divider { height: 1px; background: var(--border); margin: 1.25rem 0; }
.settings-videos-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 0.75rem; margin-bottom: 1rem; }
.settings-videos-grid .settings-form-group { margin-bottom: 0; }
@media (max-width: 500px) { .settings-videos-grid { grid-template-columns: 1fr; } }
.settings-card h3 { font-size: 1.1rem; margin-bottom: 0.5rem; }
.settings-card-description { color: var(--text-muted); font-size: 0.9rem; margin-bottom: 1rem; }

/* Theme Settings */
.themes-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(100px, 1fr)); gap: 1rem; margin-top: 1rem; }
.theme-option { display: flex; flex-direction: column; align-items: center; gap: 0.5rem; padding: 0.75rem; border-radius: 8px; cursor: pointer; transition: all 0.2s; position: relative; border: 2px solid transparent; }
.theme-option:hover { background: var(--bg-secondary); }
.theme-option.active { border-color: var(--accent); background: rgba(230,57,70,0.1); }
.theme-option.locked { opacity: 0.6; }
.theme-preview { width: 60px; height: 40px; border-radius: 6px; border: 2px solid var(--border); position: relative; overflow: hidden; }
.theme-preview-accent { position: absolute; bottom: 0; left: 0; right: 0; height: 8px; }
.theme-name { font-size: 0.8rem; text-align: center; }
.theme-lock { position: absolute; top: 4px; right: 4px; font-size: 0.7rem; }
.theme-check { position: absolute; top: 4px; right: 4px; color: var(--accent); font-size: 0.9rem; font-weight: bold; }

.accent-grid { display: flex; flex-wrap: wrap; gap: 0.75rem; margin-top: 1rem; }
.accent-option { width: 40px; height: 40px; border-radius: 50%; cursor: pointer; transition: all 0.2s; display: flex; align-items: center; justify-content: center; border: 3px solid transparent; }
.accent-option:hover { transform: scale(1.1); }
.accent-option.active { border-color: white; box-shadow: 0 0 0 2px var(--bg-primary), 0 0 10px currentColor; }
.accent-option span { color: white; font-weight: bold; text-shadow: 0 1px 2px rgba(0,0,0,0.5); }

.settings-form-group { margin-bottom: 1rem; }
.settings-label { display: block; font-weight: 500; margin-bottom: 0.5rem; font-size: 0.9rem; }
.settings-hint { color: var(--text-muted); font-size: 0.8rem; margin-top: 0.35rem; }
.settings-hint strong { color: var(--accent); font-weight: 600; }

.settings-avatar-section { display: flex; align-items: center; gap: 1.5rem; margin-bottom: 1.5rem; padding-bottom: 1.5rem; border-bottom: 1px solid var(--border); }
.settings-avatar { width: 80px; height: 80px; border-radius: 50%; overflow: hidden; background: var(--accent); display: flex; align-items: center; justify-content: center; }
.settings-avatar img { width: 100%; height: 100%; object-fit: cover; }
.settings-avatar span { font-size: 2rem; color: white; font-weight: 600; }
.settings-avatar-actions { display: flex; gap: 0.5rem; flex-wrap: wrap; }

.settings-banner-preview { width: 100%; height: 120px; border-radius: 8px; background: var(--bg-secondary); background-size: cover; background-position: center; display: flex; align-items: center; justify-content: center; margin-bottom: 1rem; }
.settings-banner-preview span { color: var(--text-muted); }
.settings-banner-actions { display: flex; gap: 0.5rem; }

.settings-toggle-row { display: flex; justify-content: space-between; align-items: center; padding: 1rem 0; border-bottom: 1px solid var(--border); }
.settings-toggle-row:last-child { border-bottom: none; }
.settings-toggle-info { flex: 1; }
.settings-toggle-label { font-weight: 500; margin-bottom: 0.25rem; }
.settings-toggle-hint { color: var(--text-muted); font-size: 0.8rem; }

.settings-toggle { position: relative; display: inline-block; width: 48px; height: 26px; flex-shrink: 0; }
.settings-toggle input { opacity: 0; width: 0; height: 0; }
.settings-toggle-slider { position: absolute; cursor: pointer; top: 0; left: 0; right: 0; bottom: 0; background-color: var(--bg-secondary); transition: 0.3s; border-radius: 26px; border: 1px solid var(--border); }
.settings-toggle-slider:before { position: absolute; content: ""; height: 20px; width: 20px; left: 2px; bottom: 2px; background-color: white; transition: 0.3s; border-radius: 50%; }
.settings-toggle input:checked + .settings-toggle-slider { background-color: var(--accent); border-color: var(--accent); }
.settings-toggle input:checked + .settings-toggle-slider:before { transform: translateX(22px); }

.settings-info-row { display: flex; justify-content: space-between; padding: 0.75rem 0; border-bottom: 1px solid var(--border); }
.settings-info-row:last-child { border-bottom: none; }
.settings-info-label { color: var(--text-muted); }
.settings-info-value { font-weight: 500; }

.settings-danger-card { border-color: var(--accent); }
.settings-danger-card h3 { color: var(--accent); }
.btn-danger { background: var(--accent); color: white; border: none; padding: 0.6rem 1.2rem; border-radius: 8px; cursor: pointer; font-weight: 500; transition: all 0.2s; }
.btn-danger:hover { background: #c0392b; }

/* Mobile */
@media (max-width: 768px) {
    .settings-layout { grid-template-columns: 1fr; }
    .settings-sidebar { flex-direction: row; flex-wrap: wrap; gap: 0.5rem; margin-bottom: 1rem; }
    .settings-nav-item { padding: 0.5rem 0.75rem; font-size: 0.85rem; }
    .settings-nav-label { display: none; }
    .settings-avatar-section { flex-direction: column; text-align: center; }
}

/* ==================== ENHANCED DM STYLES ==================== */
.chat-input-container { display: flex; flex-direction: column; border-top: 1px solid var(--border); }
.chat-input-area { display: flex; align-items: center; gap: 0.5rem; padding: 0.75rem; }
.chat-input-actions { display: flex; gap: 0.25rem; }
.chat-action-btn { background: var(--bg-secondary); border: 1px solid var(--border); color: var(--text-secondary); width: 36px; height: 36px; border-radius: 8px; cursor: pointer; display: flex; align-items: center; justify-content: center; transition: all 0.2s; font-size: 1rem; }
.chat-action-btn:hover { background: var(--bg-card); color: var(--text-primary); border-color: var(--accent); }
.chat-action-btn.gif-btn { font-size: 0.7rem; font-weight: 700; width: 42px; }
.chat-input-area input { flex: 1; background: var(--bg-secondary); border: 1px solid var(--border); border-radius: 20px; padding: 0.6rem 1rem; color: var(--text-primary); font-size: 0.9rem; }
.chat-input-area input:focus { border-color: var(--accent); outline: none; }
.chat-send-btn { background: var(--accent); border: none; color: white; width: 40px; height: 40px; border-radius: 50%; cursor: pointer; display: flex; align-items: center; justify-content: center; transition: all 0.2s; font-size: 1.1rem; }
.chat-send-btn:hover { background: #c0392b; transform: scale(1.05); }

/* GIF Picker */
.gif-picker { position: absolute; bottom: 100%; left: 0; right: 0; background: var(--bg-card); border: 1px solid var(--border); border-radius: 12px 12px 0 0; flex-direction: column; max-height: 350px; z-index: 10; }
.gif-picker-header { display: flex; gap: 0.5rem; padding: 0.75rem; border-bottom: 1px solid var(--border); }
.gif-picker-header input { flex: 1; background: var(--bg-secondary); border: 1px solid var(--border); border-radius: 8px; padding: 0.5rem 0.75rem; color: var(--text-primary); font-size: 0.85rem; }
.gif-picker-close { background: none; border: none; color: var(--text-muted); font-size: 1.2rem; cursor: pointer; padding: 0.25rem 0.5rem; }
.gif-picker-close:hover { color: var(--text-primary); }
.gif-picker-results { display: grid; grid-template-columns: repeat(3, 1fr); gap: 0.5rem; padding: 0.75rem; overflow-y: auto; max-height: 280px; }
.gif-result { width: 100%; aspect-ratio: 1; object-fit: cover; border-radius: 6px; cursor: pointer; transition: transform 0.2s; }
.gif-result:hover { transform: scale(1.05); }

/* Chat Media */
.chat-media { max-width: 200px; max-height: 200px; border-radius: 8px; cursor: pointer; }
.chat-gif { max-width: 180px; }
.chat-message.sent .chat-media { margin-left: auto; }

/* Image Preview Modal */
.image-preview-modal { position: fixed; inset: 0; z-index: 10000; display: flex; align-items: center; justify-content: center; }
.image-preview-backdrop { position: absolute; inset: 0; background: rgba(0,0,0,0.9); }
.image-preview-content { position: relative; max-width: 90vw; max-height: 90vh; object-fit: contain; border-radius: 8px; z-index: 1; }
.image-preview-close { position: absolute; top: 1rem; right: 1rem; background: rgba(255,255,255,0.2); border: none; color: white; width: 40px; height: 40px; border-radius: 50%; font-size: 1.2rem; cursor: pointer; z-index: 2; }
.image-preview-close:hover { background: rgba(255,255,255,0.3); }

/* Chat input container positioning */
.chat-input-container { position: relative; }

/* ==================== PREMIUM STYLES ==================== */
.premium-modal { text-align: center; }
.premium-hero { padding: 1.5rem 0; border-bottom: 1px solid var(--border); margin-bottom: 1.5rem; }
.premium-badge { display: inline-block; background: linear-gradient(135deg, #ffd700, #ffaa00); color: #1a1a1a; font-weight: 700; font-size: 0.9rem; padding: 0.35rem 1rem; border-radius: 20px; margin-bottom: 1rem; letter-spacing: 1px; }
.premium-hero h2 { font-size: 1.5rem; margin-bottom: 0.5rem; }
.premium-price { color: var(--text-muted); }
.price-amount { font-size: 2rem; font-weight: 700; color: var(--accent); }

.premium-features { display: grid; gap: 1rem; margin-bottom: 1.5rem; text-align: left; }
.premium-feature { display: flex; align-items: flex-start; gap: 1rem; padding: 0.75rem; background: var(--bg-secondary); border-radius: 10px; }
.premium-feature-icon { font-size: 1.5rem; }
.premium-feature-title { font-weight: 600; margin-bottom: 0.15rem; }
.premium-feature-desc { font-size: 0.85rem; color: var(--text-muted); }

.premium-cta { padding-top: 1rem; border-top: 1px solid var(--border); }
.btn-premium { background: linear-gradient(135deg, #ffd700, #ffaa00); color: #1a1a1a; font-weight: 600; padding: 0.9rem 2.5rem; font-size: 1.1rem; border: none; border-radius: 30px; cursor: pointer; transition: all 0.3s; }
.btn-premium:hover { transform: scale(1.05); box-shadow: 0 8px 25px rgba(255, 215, 0, 0.4); }
.premium-note { font-size: 0.8rem; color: var(--text-muted); margin-top: 0.75rem; }
.premium-status.active { background: linear-gradient(135deg, rgba(34, 197, 94, 0.2), rgba(34, 197, 94, 0.1)); border: 1px solid #22c55e; color: #22c55e; padding: 0.75rem; border-radius: 10px; margin-top: 1rem; display: flex; align-items: center; justify-content: center; gap: 0.5rem; }

/* Premium Banner in Settings */
.premium-banner { display: flex; align-items: center; gap: 0.75rem; background: linear-gradient(135deg, rgba(255, 215, 0, 0.15), rgba(255, 170, 0, 0.1)); border: 1px solid rgba(255, 215, 0, 0.3); padding: 1rem; border-radius: 10px; margin-bottom: 1.5rem; cursor: pointer; transition: all 0.2s; }
.premium-banner:hover { background: linear-gradient(135deg, rgba(255, 215, 0, 0.25), rgba(255, 170, 0, 0.15)); }
.premium-badge-small { background: linear-gradient(135deg, #ffd700, #ffaa00); color: #1a1a1a; font-weight: 700; font-size: 0.7rem; padding: 0.2rem 0.5rem; border-radius: 4px; }
.premium-banner-arrow { margin-left: auto; color: #ffd700; }
.pro-badge { font-size: 0.6rem; background: linear-gradient(135deg, #ffd700, #ffaa00); color: #1a1a1a; padding: 0.15rem 0.4rem; border-radius: 4px; margin-left: 0.5rem; vertical-align: middle; }

/* Theme Grid */
.theme-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(100px, 1fr)); gap: 1rem; margin-top: 1rem; }
.theme-option { cursor: pointer; transition: all 0.2s; }
.theme-option:hover { transform: translateY(-2px); }
.theme-option.active .theme-preview { border-color: var(--accent); box-shadow: 0 0 0 2px var(--accent); }
.theme-option.locked { opacity: 0.7; }
.theme-preview { height: 60px; border-radius: 8px; border: 2px solid var(--border); position: relative; overflow: hidden; }
.theme-preview-accent { position: absolute; bottom: 0; left: 0; right: 0; height: 8px; }
.theme-lock { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; background: rgba(0,0,0,0.5); font-size: 1.2rem; }
.theme-check { position: absolute; top: 4px; right: 4px; background: var(--accent); color: white; width: 18px; height: 18px; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: 0.7rem; }
.theme-name { font-size: 0.8rem; text-align: center; margin-top: 0.5rem; color: var(--text-secondary); }

/* Accent Color Grid */
.accent-grid { display: flex; gap: 0.75rem; flex-wrap: wrap; margin-top: 1rem; }
.accent-option { position: relative; cursor: pointer; transition: all 0.2s; }
.accent-option:hover { transform: scale(1.1); }
.accent-option.active .accent-color { box-shadow: 0 0 0 3px var(--bg-primary), 0 0 0 5px currentColor; }
.accent-color { width: 36px; height: 36px; border-radius: 50%; }
.accent-check { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; color: white; font-size: 0.9rem; text-shadow: 0 1px 2px rgba(0,0,0,0.5); }

/* Theme Live Preview */
.theme-live-preview { background: var(--bg-secondary); border-radius: 12px; padding: 1.5rem; margin-top: 1rem; }
.preview-card { background: var(--bg-card); border: 1px solid var(--border); border-radius: 8px; padding: 1rem; max-width: 200px; }
.preview-header { font-weight: 600; color: var(--text-primary); margin-bottom: 0.5rem; }
.preview-content { font-size: 0.85rem; color: var(--text-secondary); margin-bottom: 1rem; }
.preview-btn { background: var(--accent); color: white; border: none; padding: 0.5rem 1rem; border-radius: 6px; font-size: 0.85rem; cursor: pointer; }

/* Collection Limit Warning */
.limit-warning { background: linear-gradient(135deg, rgba(255, 215, 0, 0.1), rgba(255, 170, 0, 0.05)); border: 1px solid rgba(255, 215, 0, 0.2); padding: 0.5rem 1rem; border-radius: 8px; font-size: 0.85rem; cursor: pointer; display: inline-flex; align-items: center; gap: 0.5rem; margin-bottom: 1rem; }
.limit-upgrade { color: #ffd700; font-weight: 500; }

/* Beta Note Styling */
.beta-note { color: #22c55e; font-size: 0.9rem; margin-top: 0.5rem; }

/* Pro Badge on Profile */
.pro-badge-profile { display: inline-block; background: linear-gradient(135deg, #ffd700, #ffaa00); color: #1a1a1a; font-weight: 700; font-size: 0.7rem; padding: 0.25rem 0.6rem; border-radius: 4px; margin-left: 0.5rem; vertical-align: middle; letter-spacing: 1px; text-transform: uppercase; cursor: pointer; transition: all 0.2s; box-shadow: 0 0 10px rgba(255, 215, 0, 0.3); }
.pro-badge-profile:hover { filter: brightness(1.15); transform: scale(1.05); box-shadow: 0 0 15px rgba(255, 215, 0, 0.6); }

/* Creator Badge */
.creator-badge-profile { display: inline-block; background: linear-gradient(135deg, #00f2ea, #ff0050); color: white; font-weight: 700; font-size: 0.65rem; padding: 0.25rem 0.6rem; border-radius: 4px; margin-left: 0.5rem; vertical-align: middle; letter-spacing: 1px; text-transform: uppercase; cursor: pointer; transition: all 0.2s; box-shadow: 0 0 10px rgba(255, 0, 80, 0.3); animation: creatorGlow 2s ease-in-out infinite; }
.creator-badge-profile:hover { filter: brightness(1.15); transform: scale(1.05); box-shadow: 0 0 20px rgba(255, 0, 80, 0.6); }
@keyframes creatorGlow { 0%, 100% { box-shadow: 0 0 10px rgba(255, 0, 80, 0.3); } 50% { box-shadow: 0 0 20px rgba(0, 242, 234, 0.5); } }

/* TikTok Stat in Profile Header */
.tiktok-stat-link { text-decoration: none !important; transition: all 0.2s; }
.tiktok-stat-link:hover { transform: scale(1.05); }
.tiktok-stat-link:hover .tiktok-value { color: #ff0050; }
.tiktok-value { display: flex; align-items: center; color: #ff0050; }

/* Creator Tab */
.nav-tab.creator-tab { background: linear-gradient(135deg, rgba(0,242,234,0.1), rgba(255,0,80,0.1)); }
.nav-tab.creator-tab.active { background: linear-gradient(135deg, #00f2ea, #ff0050); color: white; }

.creator-tab-content { padding: 1.5rem 0; }
.creator-header { margin-bottom: 2rem; }

.creator-profile-card { display: flex; align-items: center; gap: 1rem; padding: 1.25rem; background: linear-gradient(135deg, rgba(0,0,0,0.8), rgba(20,20,20,0.9)); border-radius: 16px; border: 1px solid rgba(255,255,255,0.1); }
.creator-profile-icon { width: 50px; height: 50px; background: linear-gradient(135deg, #00f2ea, #ff0050); border-radius: 12px; display: flex; align-items: center; justify-content: center; color: white; }
.creator-profile-info { flex: 1; display: flex; flex-direction: column; gap: 0.25rem; }
.creator-profile-name { font-weight: 700; font-size: 1.1rem; color: white; }
.creator-profile-followers { font-size: 0.85rem; color: rgba(255,255,255,0.6); }
.creator-follow-btn { padding: 0.6rem 1.5rem; background: #ff0050; color: white; border: none; border-radius: 8px; font-weight: 600; font-size: 0.9rem; text-decoration: none; transition: all 0.2s; }
.creator-follow-btn:hover { background: #ff1a66; transform: scale(1.05); }

.creator-videos-grid { display: flex; gap: 1rem; justify-content: center; flex-wrap: wrap; }
.creator-video-card { width: 280px; height: 500px; border-radius: 16px; overflow: hidden; background: #000; box-shadow: 0 8px 32px rgba(0,0,0,0.4); border: 1px solid rgba(255,255,255,0.1); }
.creator-video-card iframe { width: 100%; height: 100%; border: none; }

/* Responsive grid for different video counts */
.creator-videos-grid.videos-1 .creator-video-card { width: 325px; height: 580px; }
.creator-videos-grid.videos-2 .creator-video-card { width: 325px; height: 580px; }
.creator-videos-grid.videos-3 .creator-video-card,
.creator-videos-grid.videos-4 .creator-video-card { width: 280px; height: 500px; }

.creator-no-videos { text-align: center; padding: 4rem 2rem; background: var(--bg-card); border-radius: 16px; border: 1px dashed var(--border); }
.creator-no-videos-icon { font-size: 3rem; margin-bottom: 1rem; }
.creator-no-videos p { color: var(--text-muted); margin: 0.5rem 0; }
.creator-no-videos .hint { font-size: 0.85rem; }
.creator-no-videos .hint a { color: var(--accent); }

@media (max-width: 768px) {
    .creator-profile-card { flex-direction: column; text-align: center; }
    .creator-video-card { width: 100%; max-width: 280px; height: 500px; }
    .creator-videos-grid.videos-1 .creator-video-card,
    .creator-videos-grid.videos-2 .creator-video-card { max-width: 300px; height: 530px; }
}

/* Creator Benefits */
.creator-benefits { display: flex; flex-direction: column; gap: 0.5rem; text-align: left; background: var(--bg-secondary); padding: 1rem; border-radius: 12px; }
.benefit-item { display: flex; align-items: center; gap: 0.75rem; color: var(--text-secondary); font-size: 0.9rem; }
.benefit-icon { color: #00f2ea; font-weight: bold; }
.pro-badge-small { display: inline-block; background: linear-gradient(135deg, #ffd700, #ffaa00); color: #1a1a1a; font-weight: 700; font-size: 0.55rem; padding: 0.1rem 0.35rem; border-radius: 3px; margin-left: 0.4rem; vertical-align: middle; }
.creator-badge-header { display: inline-block; background: linear-gradient(135deg, #00f2ea, #ff0050); color: white; font-weight: 700; font-size: 0.55rem; padding: 0.1rem 0.35rem; border-radius: 3px; margin-left: 0.4rem; vertical-align: middle; }

/* Info Box Variants */
.info-box.success { background: rgba(34, 197, 94, 0.1); border-color: rgba(34, 197, 94, 0.3); color: #22c55e; }
.info-box.pro-hint { background: rgba(255, 215, 0, 0.1); border-color: rgba(255, 215, 0, 0.3); }
.info-box.pro-hint:hover { background: rgba(255, 215, 0, 0.15); }
.premium-active-section { text-align: center; }

/* Settings Header Row */
.settings-header-row { display: flex; align-items: flex-start; justify-content: space-between; margin-bottom: 1.5rem; gap: 1rem; }
.settings-header-row h2 { margin-bottom: 0.25rem; }
.settings-header-row .btn { flex-shrink: 0; }

/* ==================== CLUBS STYLES ==================== */
.clubs-page { max-width: 1200px; margin: 0 auto; padding: 2rem 1rem; }
.clubs-header { display: flex; justify-content: space-between; align-items: flex-start; margin-bottom: 1.5rem; flex-wrap: wrap; gap: 1rem; }
.clubs-header h1 { margin-bottom: 0.25rem; }
.clubs-header p { color: var(--text-muted); }
.clubs-search { margin-bottom: 1rem; }
.clubs-search input { width: 100%; max-width: 400px; padding: 0.75rem 1rem; background: var(--bg-secondary); border: 1px solid var(--border); border-radius: 10px; color: var(--text-primary); font-size: 1rem; }
.clubs-tabs { display: flex; gap: 0.5rem; margin-bottom: 1.5rem; flex-wrap: wrap; }
.club-tab { background: var(--bg-secondary); border: 1px solid var(--border); padding: 0.5rem 1rem; border-radius: 8px; cursor: pointer; color: var(--text-secondary); transition: all 0.2s; }
.club-tab:hover, .club-tab.active { background: var(--accent); border-color: var(--accent); color: white; }

/* Club Cards Grid */
.clubs-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 1.5rem; }
.club-card { background: var(--bg-card); border: 1px solid var(--border); border-radius: 12px; overflow: hidden; cursor: pointer; transition: all 0.2s; }
.club-card:hover { transform: translateY(-4px); box-shadow: 0 8px 25px rgba(0,0,0,0.3); border-color: var(--accent); }
.club-card-banner { height: 80px; position: relative; display: flex; align-items: flex-end; justify-content: center; }
.club-card-banner img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.club-card-icon { width: 60px; height: 60px; background: var(--bg-card); border-radius: 14px; display: flex; align-items: center; justify-content: center; font-size: 1.8rem; position: relative; transform: translateY(50%); border: 3px solid var(--bg-card); overflow: hidden; box-shadow: 0 2px 8px rgba(0,0,0,0.2); }
.club-card-icon img { width: 100%; height: 100%; object-fit: cover; border-radius: 11px; }
.club-card-content { padding: 2.25rem 1rem 1rem; text-align: center; }
.club-card-prefix { color: var(--accent); font-weight: 700; font-size: 0.8rem; margin-bottom: 0.25rem; }
.club-card-name { font-size: 1.1rem; margin-bottom: 0.5rem; }
.club-card-desc { font-size: 0.85rem; color: var(--text-muted); margin-bottom: 0.75rem; min-height: 2.5em; }
.club-card-meta { display: flex; justify-content: space-between; font-size: 0.75rem; color: var(--text-muted); }

/* Club Detail */
.club-detail { max-width: 1200px; margin: 0 auto; }
.club-detail-banner { height: 220px; position: relative; border-radius: 12px 12px 0 0; overflow: hidden; }
.club-detail-banner img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.club-back-btn { position: absolute; top: 1rem; left: 1rem; z-index: 2; }
.club-detail-header { display: flex; gap: 1.5rem; padding: 1.5rem 1.5rem 1.5rem 1.5rem; background: var(--bg-card); border: 1px solid var(--border); border-top: none; align-items: flex-start; flex-wrap: wrap; position: relative; }
.club-detail-icon { width: 120px; height: 120px; background: var(--bg-secondary); border-radius: 20px; display: flex; align-items: center; justify-content: center; font-size: 3.5rem; flex-shrink: 0; margin-top: -70px; border: 5px solid var(--bg-card); box-shadow: 0 4px 15px rgba(0,0,0,0.3); overflow: hidden; position: relative; z-index: 10; }
.club-detail-icon img { width: 100%; height: 100%; object-fit: cover; border-radius: 15px; }
.club-detail-info { flex: 1; min-width: 200px; }
.club-detail-prefix { color: var(--accent); font-weight: 700; font-size: 0.9rem; }
.club-detail-info h1 { margin: 0.25rem 0 0.5rem; font-size: 1.5rem; }
.club-detail-short { color: var(--text-muted); }
.club-detail-actions { display: flex; gap: 0.5rem; flex-wrap: wrap; }

.club-detail-body { display: grid; grid-template-columns: 1fr 320px; gap: 1.5rem; margin-top: 1.5rem; }
@media (max-width: 900px) { .club-detail-body { grid-template-columns: 1fr; } }
.club-section { background: var(--bg-card); border: 1px solid var(--border); border-radius: 12px; padding: 1.5rem; margin-bottom: 1.5rem; }
.club-section h2 { margin-bottom: 1rem; font-size: 1.1rem; }
.club-description { color: var(--text-secondary); line-height: 1.6; white-space: pre-wrap; }
.club-chat-preview { background: var(--bg-secondary); border-radius: 8px; padding: 1rem; cursor: pointer; text-align: center; color: var(--accent); transition: all 0.2s; }
.club-chat-preview:hover { background: var(--accent); color: white; }

/* Club Sidebar */
.club-detail-sidebar { display: flex; flex-direction: column; gap: 1rem; }
.club-sidebar-card { background: var(--bg-card); border: 1px solid var(--border); border-radius: 12px; padding: 1rem; }
.club-sidebar-card h3 { font-size: 0.9rem; margin-bottom: 0.75rem; color: var(--text-muted); }
.club-owner { display: flex; align-items: center; gap: 0.75rem; cursor: pointer; padding: 0.5rem; border-radius: 8px; transition: background 0.2s; }
.club-owner:hover { background: var(--bg-secondary); }
.club-owner-avatar { width: 40px; height: 40px; border-radius: 10px; background: var(--bg-secondary); display: flex; align-items: center; justify-content: center; overflow: hidden; }
.club-owner-avatar img { width: 100%; height: 100%; object-fit: cover; }
.club-members-list { display: flex; flex-direction: column; gap: 0.5rem; max-height: 300px; overflow-y: auto; }
.club-member { display: flex; align-items: center; gap: 0.5rem; padding: 0.4rem; border-radius: 6px; cursor: pointer; transition: background 0.2s; }
.club-member:hover { background: var(--bg-secondary); }
.club-member-avatar { width: 32px; height: 32px; border-radius: 8px; background: var(--bg-secondary); display: flex; align-items: center; justify-content: center; overflow: hidden; font-size: 0.9rem; }
.club-member-avatar img { width: 100%; height: 100%; object-fit: cover; }
.club-role { font-size: 0.6rem; padding: 0.15rem 0.4rem; border-radius: 4px; margin-left: auto; }
.club-role.admin { background: rgba(239, 68, 68, 0.2); color: #ef4444; }
.club-role.mod { background: rgba(59, 130, 246, 0.2); color: #3b82f6; }
.club-stats { font-size: 0.85rem; color: var(--text-muted); display: flex; flex-direction: column; gap: 0.5rem; }

/* Club Create/Edit */
.club-create { max-width: 700px; margin: 0 auto; padding: 2rem 1rem; }
.club-create-header { display: flex; align-items: center; gap: 1rem; margin-bottom: 2rem; }
.club-create-header h1 { margin: 0; }
.club-create-form { background: var(--bg-card); border: 1px solid var(--border); border-radius: 12px; padding: 1.5rem; }
.club-create-preview { margin-bottom: 1.5rem; border-radius: 12px; overflow: hidden; border: 1px solid var(--border); }
.club-preview-banner { height: 100px; position: relative; display: flex; align-items: flex-end; justify-content: center; }
.club-preview-icon { width: 50px; height: 50px; background: var(--bg-card); border-radius: 12px; display: flex; align-items: center; justify-content: center; font-size: 1.5rem; transform: translateY(50%); border: 3px solid var(--bg-card); }
.club-preview-info { padding: 2rem 1rem 1rem; text-align: center; background: var(--bg-secondary); }
.club-preview-prefix { color: var(--accent); font-weight: 700; }
.club-preview-name { margin-left: 0.5rem; font-weight: 600; }
.form-section { margin-bottom: 1.5rem; padding-bottom: 1.5rem; border-bottom: 1px solid var(--border); }
.form-section:last-of-type { border-bottom: none; }
.form-section h3 { margin-bottom: 1rem; font-size: 1rem; }
.color-presets { display: flex; gap: 0.75rem; flex-wrap: wrap; }
.color-preset { width: 40px; height: 40px; border-radius: 10px; cursor: pointer; transition: all 0.2s; border: 3px solid transparent; }
.color-preset:hover, .color-preset.active { transform: scale(1.1); border-color: white; }
.club-create-actions { display: flex; justify-content: space-between; margin-top: 1.5rem; gap: 1rem; }

/* Club Management */
.club-manage { max-width: 800px; margin: 0 auto; padding: 2rem 1rem; }
.club-manage-header { display: flex; align-items: center; gap: 1rem; margin-bottom: 2rem; }
.club-manage-header h1 { margin: 0; }
.club-manage-section { background: var(--bg-card); border: 1px solid var(--border); border-radius: 12px; padding: 1.5rem; margin-bottom: 1.5rem; }
.club-manage-section h2 { margin-bottom: 1rem; }
.club-requests-list, .club-members-manage { display: flex; flex-direction: column; gap: 0.75rem; }
.club-request, .club-member-manage { display: flex; justify-content: space-between; align-items: center; padding: 0.75rem; background: var(--bg-secondary); border-radius: 8px; flex-wrap: wrap; gap: 0.75rem; }
.club-request-user { display: flex; align-items: center; gap: 0.75rem; }
.club-request-avatar { width: 44px; height: 44px; border-radius: 10px; background: var(--bg-card); display: flex; align-items: center; justify-content: center; overflow: hidden; }
.club-request-avatar img { width: 100%; height: 100%; object-fit: cover; }
.club-request-name { font-weight: 600; }
.club-request-username { font-size: 0.85rem; color: var(--text-muted); }
.club-request-actions { display: flex; gap: 0.5rem; }
.club-member-role { display: flex; align-items: center; gap: 0.5rem; }
.club-member-role select { background: var(--bg-card); border: 1px solid var(--border); border-radius: 6px; padding: 0.4rem 0.75rem; color: var(--text-primary); }

/* Club Prefix on Profile */
.profile-club-prefix { display: inline-block; background: linear-gradient(135deg, var(--accent), #8b5cf6); color: white; font-weight: 700; font-size: 0.7rem; padding: 0.25rem 0.6rem; border-radius: 4px; margin-left: 0.5rem; letter-spacing: 1px; text-transform: uppercase; }

/* Empty States */
.empty-state { text-align: center; padding: 3rem; color: var(--text-muted); }
.empty-small { text-align: center; padding: 1rem; color: var(--text-muted); font-size: 0.9rem; }

/* Club Icon Upload */
.club-icon-upload { width: 100px; height: 100px; border: 2px dashed var(--border); border-radius: 16px; cursor: pointer; position: relative; overflow: hidden; transition: all 0.2s; display: flex; align-items: center; justify-content: center; }
.club-icon-upload:hover { border-color: var(--accent); }
.club-icon-preview { width: 100%; height: 100%; display: flex; align-items: center; justify-content: center; font-size: 2.5rem; background: var(--bg-secondary); border-radius: 14px; }
.club-icon-preview img { width: 100%; height: 100%; object-fit: cover; border-radius: 14px; }
.club-icon-overlay { position: absolute; inset: 0; background: rgba(0,0,0,0.5); display: flex; align-items: center; justify-content: center; font-size: 1.5rem; opacity: 0; transition: opacity 0.2s; border-radius: 14px; }
.club-icon-upload:hover .club-icon-overlay { opacity: 1; }

/* Club Banner Upload */
.club-banner-upload { width: 100%; height: 120px; border: 2px dashed var(--border); border-radius: 12px; cursor: pointer; overflow: hidden; transition: all 0.2s; }
.club-banner-upload:hover { border-color: var(--accent); }
.club-banner-preview { width: 100%; height: 100%; display: flex; align-items: center; justify-content: center; color: var(--text-muted); font-size: 0.9rem; background-size: cover; background-position: center; position: relative; }
.club-banner-preview span { background: rgba(0,0,0,0.5); color: white; padding: 0.5rem 1rem; border-radius: 8px; }

/* Rich Text Editor Toolbar */
.rich-editor-toolbar { display: flex; gap: 0.25rem; padding: 0.5rem; background: var(--bg-secondary); border: 1px solid var(--border); border-bottom: none; border-radius: 8px 8px 0 0; flex-wrap: wrap; }
.rich-editor-toolbar button { background: transparent; border: 1px solid transparent; padding: 0.4rem 0.6rem; border-radius: 4px; cursor: pointer; color: var(--text-primary); font-size: 0.85rem; transition: all 0.15s; min-width: 32px; }
.rich-editor-toolbar button:hover { background: var(--bg-card); border-color: var(--border); }
.toolbar-divider { width: 1px; background: var(--border); margin: 0 0.25rem; }

/* Rich Textarea */
.rich-textarea { border-radius: 0 0 8px 8px !important; font-family: 'IBM Plex Sans', monospace; line-height: 1.6; }

/* Rich Preview */
.rich-preview-toggle { margin-top: 0.5rem; }
.rich-preview { background: var(--bg-secondary); border: 1px solid var(--border); border-radius: 8px; padding: 1rem; margin-top: 0.5rem; line-height: 1.6; }
.rich-preview img { max-width: 100%; border-radius: 8px; margin: 0.5rem 0; }
.rich-preview h3 { color: var(--accent); margin: 1rem 0 0.5rem; font-size: 1.1rem; }
.rich-preview blockquote { border-left: 3px solid var(--accent); padding-left: 1rem; margin: 1rem 0; color: var(--text-muted); font-style: italic; }
.rich-preview a { color: var(--accent); text-decoration: none; }
.rich-preview a:hover { text-decoration: underline; }

/* Spoiler Text */
.spoiler-text { background: var(--text-primary); color: var(--text-primary); cursor: pointer; padding: 0 4px; border-radius: 3px; transition: all 0.2s; }
.spoiler-text.revealed { background: var(--bg-secondary); color: var(--text-primary); }

/* Form Row for side-by-side layout */
.form-row { display: flex; flex-wrap: wrap; }

/* ==================== BBCODE STYLES ==================== */

/* Headers */
.bbcode-h1 { font-size: 1.8rem; color: var(--accent); margin: 1.5rem 0 1rem; font-weight: 700; border-bottom: 2px solid var(--accent); padding-bottom: 0.5rem; }
.bbcode-h2 { font-size: 1.4rem; color: var(--accent); margin: 1.25rem 0 0.75rem; font-weight: 600; }
.bbcode-h3 { font-size: 1.2rem; color: var(--text-primary); margin: 1rem 0 0.5rem; font-weight: 600; }
.bbcode-h4 { font-size: 1.1rem; color: var(--text-primary); margin: 0.75rem 0 0.5rem; font-weight: 600; }
.bbcode-h5, .bbcode-h6 { font-size: 1rem; color: var(--text-secondary); margin: 0.5rem 0; font-weight: 600; }

/* Links */
.bbcode-link { color: var(--accent); text-decoration: none; transition: all 0.2s; }
.bbcode-link:hover { text-decoration: underline; filter: brightness(1.2); }

/* Images */
.bbcode-img { max-width: 100%; border-radius: 8px; margin: 0.75rem 0; display: block; }
.bbcode-img-left { float: left; margin-right: 1rem; margin-bottom: 0.5rem; max-width: 50%; }
.bbcode-img-right { float: right; margin-left: 1rem; margin-bottom: 0.5rem; max-width: 50%; }
.bbcode-img-center { margin: 1rem auto; display: block; }

/* Videos */
.bbcode-video { position: relative; padding-bottom: 56.25%; height: 0; overflow: hidden; border-radius: 12px; margin: 1rem 0; }
.bbcode-video iframe { position: absolute; top: 0; left: 0; width: 100%; height: 100%; border: none; }
.bbcode-video-native { max-width: 100%; border-radius: 12px; margin: 1rem 0; }

/* Quotes */
.bbcode-quote { border-left: 4px solid var(--accent); background: var(--bg-secondary); padding: 1rem 1.25rem; margin: 1rem 0; border-radius: 0 8px 8px 0; font-style: italic; color: var(--text-secondary); }
.bbcode-quote cite { display: block; font-weight: 600; color: var(--accent); font-style: normal; margin-bottom: 0.5rem; }

/* Code */
.bbcode-code { background: #1a1a2e; border-radius: 8px; padding: 1rem; margin: 1rem 0; overflow-x: auto; font-family: 'Consolas', 'Monaco', monospace; font-size: 0.9rem; line-height: 1.5; border: 1px solid var(--border); }
.bbcode-code code { color: #a8ff60; }
.bbcode-pre { background: var(--bg-secondary); border-radius: 8px; padding: 1rem; margin: 1rem 0; overflow-x: auto; white-space: pre-wrap; font-family: monospace; }
.bbcode-mono { background: var(--bg-secondary); padding: 0.2rem 0.4rem; border-radius: 4px; font-family: 'Consolas', monospace; font-size: 0.9em; }

/* Lists */
.bbcode-list { margin: 1rem 0; padding-left: 1.5rem; }
.bbcode-list li { margin: 0.35rem 0; }

/* Tables */
.bbcode-table { width: 100%; border-collapse: collapse; margin: 1rem 0; }
.bbcode-table th, .bbcode-table td { border: 1px solid var(--border); padding: 0.75rem; text-align: left; }
.bbcode-table th { background: var(--bg-secondary); font-weight: 600; }
.bbcode-table tr:hover { background: var(--bg-secondary); }

/* Spoiler */
.bbcode-spoiler { background: var(--text-primary); color: var(--text-primary); cursor: pointer; padding: 0.1rem 0.4rem; border-radius: 4px; transition: all 0.3s; user-select: none; }
.bbcode-spoiler.revealed { background: var(--bg-secondary); color: var(--text-primary); }
.bbcode-spoiler:hover:not(.revealed) { opacity: 0.8; }

/* Details/Collapse */
.bbcode-details { background: var(--bg-secondary); border: 1px solid var(--border); border-radius: 8px; margin: 1rem 0; overflow: hidden; }
.bbcode-details summary { padding: 0.75rem 1rem; cursor: pointer; font-weight: 600; background: var(--bg-card); border-bottom: 1px solid var(--border); transition: background 0.2s; }
.bbcode-details summary:hover { background: var(--bg-secondary); }
.bbcode-details[open] summary { border-radius: 8px 8px 0 0; }
.bbcode-details > *:not(summary) { padding: 1rem; }

/* Horizontal Rule */
.bbcode-hr { border: none; border-top: 2px solid var(--border); margin: 1.5rem 0; }

/* Box */
.bbcode-box { background: var(--bg-secondary); border: 1px solid var(--border); border-radius: 12px; padding: 1rem 1.25rem; margin: 1rem 0; }
.bbcode-box-title { font-weight: 700; color: var(--accent); margin-bottom: 0.75rem; font-size: 1.05rem; border-bottom: 1px solid var(--border); padding-bottom: 0.5rem; }

/* Alerts */
.bbcode-alert { padding: 1rem 1.25rem; border-radius: 8px; margin: 1rem 0; border-left: 4px solid; }
.bbcode-alert-info, .bbcode-note { background: rgba(59, 130, 246, 0.1); border-left-color: #3b82f6; }
.bbcode-alert-success, .bbcode-tip { background: rgba(34, 197, 94, 0.1); border-left-color: #22c55e; }
.bbcode-alert-warning, .bbcode-warning { background: rgba(245, 158, 11, 0.1); border-left-color: #f59e0b; }
.bbcode-alert-danger { background: rgba(239, 68, 68, 0.1); border-left-color: #ef4444; }

/* Progress Bar */
.bbcode-progress { background: var(--bg-secondary); border-radius: 10px; height: 20px; overflow: hidden; margin: 0.75rem 0; }
.bbcode-progress-bar { height: 100%; background: linear-gradient(90deg, var(--accent), #8b5cf6); border-radius: 10px; transition: width 0.5s ease; }

/* Mention */
.bbcode-mention { color: var(--accent); font-weight: 600; cursor: pointer; }
.bbcode-mention:hover { text-decoration: underline; }

/* Columns */
.bbcode-columns { display: flex; gap: 1.5rem; flex-wrap: wrap; margin: 1rem 0; }
.bbcode-column { flex: 1; min-width: 200px; }

/* Rich Preview improvements */
.rich-preview { line-height: 1.7; }
.rich-preview img { max-width: 100%; }
.rich-preview * { max-width: 100%; }

/* Toolbar improvements */
.rich-editor-toolbar { display: flex; gap: 0.25rem; padding: 0.5rem; background: var(--bg-secondary); border: 1px solid var(--border); border-bottom: none; border-radius: 8px 8px 0 0; flex-wrap: wrap; align-items: center; }
.rich-editor-toolbar button { background: transparent; border: 1px solid transparent; padding: 0.35rem 0.5rem; border-radius: 4px; cursor: pointer; color: var(--text-primary); font-size: 0.8rem; transition: all 0.15s; min-width: 28px; text-align: center; }
.rich-editor-toolbar button:hover { background: var(--bg-card); border-color: var(--border); }
.toolbar-group { display: flex; gap: 2px; }
.toolbar-divider { width: 1px; height: 24px; background: var(--border); margin: 0 0.35rem; }
.toolbar-help { background: var(--accent) !important; color: white !important; }
.toolbar-help:hover { filter: brightness(1.1); }

/* BBCode Help Modal */
.bbcode-help-section { margin-bottom: 1.5rem; }
.bbcode-help-section h4 { color: var(--accent); margin-bottom: 0.75rem; font-size: 1rem; border-bottom: 1px solid var(--border); padding-bottom: 0.5rem; }
.bbcode-help-grid { font-size: 0.9rem; line-height: 1.8; }
.bbcode-help-grid code { background: var(--bg-secondary); padding: 0.15rem 0.4rem; border-radius: 4px; font-size: 0.85rem; }

/* Mobile Toolbar */
@media (max-width: 768px) {
    .rich-editor-toolbar { gap: 0.15rem; padding: 0.35rem; }
    .rich-editor-toolbar button { padding: 0.3rem 0.4rem; font-size: 0.75rem; min-width: 26px; }
    .toolbar-group { flex-wrap: wrap; }
    .toolbar-divider { height: 20px; margin: 0 0.2rem; }
}

/* ==================== CLICKABLE BADGES ==================== */
.clickable { cursor: pointer; transition: all 0.2s; }
.clickable:hover { filter: brightness(1.2); transform: scale(1.05); }
.profile-club-prefix.clickable:hover { box-shadow: 0 0 10px var(--accent); }

/* ==================== IMAGE MODAL ==================== */
.image-modal-overlay { position: fixed; top: 0; left: 0; right: 0; bottom: 0; background: rgba(0,0,0,0.9); z-index: 10001; display: flex; align-items: center; justify-content: center; cursor: pointer; animation: fadeIn 0.2s ease; }
.image-modal-content { position: relative; max-width: 90vw; max-height: 90vh; cursor: default; }
.image-modal-content img { max-width: 100%; max-height: 90vh; border-radius: 8px; box-shadow: 0 10px 50px rgba(0,0,0,0.5); }
.image-modal-close { position: absolute; top: -40px; right: 0; background: none; border: none; color: white; font-size: 1.5rem; cursor: pointer; padding: 0.5rem; opacity: 0.8; }
.image-modal-close:hover { opacity: 1; }

/* ==================== CLUB CHAT ==================== */

.club-chat-container { display: flex; flex-direction: column; height: calc(100vh - 100px); max-height: 800px; background: var(--bg-card); border-radius: 12px; overflow: hidden; }

/* Header */
.club-chat-header { display: flex; align-items: center; gap: 1rem; padding: 1rem 1.5rem; background: var(--bg-secondary); border-bottom: 1px solid var(--border); }
.club-chat-title { flex: 1; display: flex; align-items: center; gap: 0.75rem; }
.club-chat-prefix { background: linear-gradient(135deg, var(--accent), #8b5cf6); padding: 0.25rem 0.5rem; border-radius: 4px; font-weight: 700; font-size: 0.8rem; }
.club-chat-title h2 { margin: 0; font-size: 1.2rem; }
.club-chat-members-btn { width: 40px; height: 40px; border-radius: 8px; background: var(--bg-card); display: flex; align-items: center; justify-content: center; cursor: pointer; transition: all 0.2s; font-size: 1.2rem; }
.club-chat-members-btn:hover { background: var(--accent); }

/* Body */
.club-chat-body { flex: 1; display: flex; overflow: hidden; }
.club-chat-messages { flex: 1; overflow-y: auto; padding: 1rem; display: flex; flex-direction: column; gap: 0.25rem; }
.club-chat-members-sidebar { width: 250px; background: var(--bg-secondary); border-left: 1px solid var(--border); overflow-y: auto; padding: 1rem; }

/* Empty State */
.club-chat-empty { display: flex; flex-direction: column; align-items: center; justify-content: center; height: 100%; color: var(--text-muted); }
.club-chat-empty-icon { font-size: 4rem; margin-bottom: 1rem; opacity: 0.5; }

/* Date Separator */
.club-chat-date-sep { text-align: center; color: var(--text-muted); font-size: 0.75rem; padding: 1rem 0; position: relative; }
.club-chat-date-sep::before, .club-chat-date-sep::after { content: ''; position: absolute; top: 50%; width: 30%; height: 1px; background: var(--border); }
.club-chat-date-sep::before { left: 10%; }
.club-chat-date-sep::after { right: 10%; }

/* Load More */
.club-chat-load-more { text-align: center; color: var(--accent); padding: 0.75rem; cursor: pointer; font-size: 0.85rem; }
.club-chat-load-more:hover { text-decoration: underline; }

/* Messages */
.club-chat-message { display: flex; align-items: flex-start; gap: 0.75rem; padding: 0.5rem; border-radius: 8px; transition: background 0.2s; }
.club-chat-message:hover { background: rgba(255,255,255,0.03); }
.club-chat-message.grouped { padding-top: 0.1rem; }
.club-chat-message.own { flex-direction: row-reverse; }
.club-chat-message.own .chat-msg-content { align-items: flex-end; }
.club-chat-message.own .chat-msg-text { background: var(--accent); color: white; }

/* Avatar */
.chat-msg-avatar { width: 40px; height: 40px; border-radius: 50%; overflow: hidden; cursor: pointer; flex-shrink: 0; background: var(--bg-secondary); display: flex; align-items: center; justify-content: center; }
.chat-msg-avatar img { width: 100%; height: 100%; object-fit: cover; }
.chat-msg-avatar span { font-size: 1.2rem; }
.chat-msg-avatar-spacer { width: 40px; flex-shrink: 0; }

/* Content */
.chat-msg-content { display: flex; flex-direction: column; gap: 0.25rem; max-width: 70%; }
.chat-msg-header { display: flex; align-items: center; gap: 0.5rem; flex-wrap: wrap; }
.chat-msg-name { font-weight: 600; cursor: pointer; font-size: 0.9rem; }
.chat-msg-name:hover { color: var(--accent); }
.chat-msg-time { font-size: 0.7rem; color: var(--text-muted); }
.chat-msg-text { background: var(--bg-secondary); padding: 0.5rem 0.75rem; border-radius: 12px; line-height: 1.4; word-break: break-word; font-size: 0.95rem; }
.chat-msg-edited { font-size: 0.7rem; color: var(--text-muted); font-style: italic; }

/* Message Image */
.chat-msg-image { margin-top: 0.5rem; }
.chat-msg-image img { max-width: 300px; max-height: 200px; border-radius: 8px; cursor: pointer; transition: transform 0.2s; }
.chat-msg-image img:hover { transform: scale(1.02); }

/* Message Actions */
.chat-msg-actions { opacity: 0; transition: opacity 0.2s; display: flex; gap: 0.25rem; }
.club-chat-message:hover .chat-msg-actions { opacity: 1; }
.chat-msg-actions button { background: none; border: none; cursor: pointer; padding: 0.25rem; font-size: 0.9rem; opacity: 0.6; }
.chat-msg-actions button:hover { opacity: 1; }

/* Mentions */
.chat-mention { color: var(--accent); font-weight: 600; cursor: pointer; }
.chat-mention:hover { text-decoration: underline; }

/* Role Badges */
.chat-role-badge { font-size: 0.6rem; padding: 0.15rem 0.4rem; border-radius: 4px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.5px; }
.chat-role-badge.owner { background: linear-gradient(135deg, #ffd700, #ffaa00); color: #1a1a1a; }
.chat-role-badge.admin { background: linear-gradient(135deg, #ff0040, #ff4d00); color: white; }
.chat-role-badge.mod { background: linear-gradient(135deg, #7c3aed, #a855f7); color: white; }
.chat-pro-badge { font-size: 0.55rem; padding: 0.1rem 0.3rem; border-radius: 3px; background: linear-gradient(135deg, #ffd700, #ffaa00); color: #1a1a1a; font-weight: 700; }
.chat-pro-badge.small { font-size: 0.5rem; }

/* Input Area */
.club-chat-input-area { padding: 1rem 1.5rem; background: var(--bg-secondary); border-top: 1px solid var(--border); }
.club-chat-input-wrapper { display: flex; gap: 0.75rem; align-items: flex-end; }
.club-chat-input-wrapper textarea { flex: 1; background: var(--bg-card); border: 1px solid var(--border); border-radius: 20px; padding: 0.75rem 1rem; color: var(--text-primary); resize: none; font-family: inherit; font-size: 0.95rem; max-height: 120px; }
.club-chat-input-wrapper textarea:focus { outline: none; border-color: var(--accent); }
.club-chat-send-btn { width: 44px; height: 44px; border-radius: 50%; background: var(--accent); border: none; color: white; font-size: 1.2rem; cursor: pointer; transition: all 0.2s; display: flex; align-items: center; justify-content: center; }
.club-chat-send-btn:hover { background: var(--accent-hover); transform: scale(1.05); }

/* Members Sidebar */
.chat-members-header { padding-bottom: 0.75rem; border-bottom: 1px solid var(--border); margin-bottom: 0.75rem; }
.chat-members-header h3 { margin: 0; font-size: 1rem; }
.chat-members-section { margin-bottom: 1rem; }
.chat-members-section-title { font-size: 0.75rem; color: var(--text-muted); text-transform: uppercase; letter-spacing: 0.5px; margin-bottom: 0.5rem; }
.chat-member-item { display: flex; align-items: center; gap: 0.5rem; padding: 0.4rem; border-radius: 6px; cursor: pointer; transition: background 0.2s; }
.chat-member-item:hover { background: var(--bg-card); }
.chat-member-avatar { width: 32px; height: 32px; border-radius: 50%; overflow: hidden; background: var(--bg-card); display: flex; align-items: center; justify-content: center; }
.chat-member-avatar img { width: 100%; height: 100%; object-fit: cover; }
.chat-member-info { display: flex; align-items: center; gap: 0.4rem; }
.chat-member-name { font-size: 0.85rem; }

/* Chat Preview in Club Detail */
.club-chat-preview { background: var(--bg-secondary); border-radius: 8px; padding: 1rem; cursor: pointer; transition: all 0.2s; display: flex; align-items: center; justify-content: center; color: var(--accent); font-weight: 600; }
.club-chat-preview:hover { background: var(--accent); color: white; }

/* Mobile */
@media (max-width: 768px) {
    .club-chat-container { height: calc(100vh - 80px); max-height: none; border-radius: 0; }
    .club-chat-header { padding: 0.75rem 1rem; }
    .club-chat-title h2 { font-size: 1rem; }
    .club-chat-messages { padding: 0.75rem; }
    .chat-msg-content { max-width: 85%; }
    .club-chat-members-sidebar { position: absolute; right: 0; top: 0; bottom: 0; z-index: 100; width: 280px; box-shadow: -5px 0 20px rgba(0,0,0,0.3); }
    .club-chat-input-area { padding: 0.75rem 1rem; }
    .club-chat-input-wrapper textarea { padding: 0.6rem 0.9rem; }
}

/* ==================== NOTIFICATIONS ==================== */

/* Bell Container */
.notification-bell-container { position: relative; }
.notification-bell { background: none; border: none; color: var(--text-secondary); cursor: pointer; padding: 0.6rem 0.8rem; border-radius: 8px; transition: all 0.2s; position: relative; display: flex; align-items: center; justify-content: center; }
.notification-bell:hover { background: rgba(255,255,255,0.08); color: var(--text-primary); }
.notification-bell svg { width: 22px; height: 22px; }

/* Badge */
.notification-badge { position: absolute; top: 0; right: 0; background: var(--accent); color: white; font-size: 0.65rem; font-weight: 700; min-width: 18px; height: 18px; border-radius: 10px; display: flex; align-items: center; justify-content: center; padding: 0 4px; border: 2px solid var(--bg-primary); animation: pulse-badge 2s infinite; }

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

/* Panel */
.notification-panel { position: fixed; top: 60px; right: 1rem; width: 380px; max-width: calc(100vw - 2rem); max-height: 70vh; background: var(--bg-card); border: 1px solid var(--border); border-radius: 12px; box-shadow: 0 10px 40px rgba(0,0,0,0.4); z-index: 10000; overflow: hidden; animation: slideDown 0.2s ease; }

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

/* Header */
.notification-header { display: flex; justify-content: space-between; align-items: center; padding: 1rem 1.25rem; border-bottom: 1px solid var(--border); background: var(--bg-secondary); }
.notification-header h3 { margin: 0; font-size: 1rem; font-family: 'Bebas Neue', sans-serif; letter-spacing: 0.5px; }
.notification-actions { display: flex; gap: 0.5rem; }

/* List */
.notification-list { max-height: calc(70vh - 120px); overflow-y: auto; }

/* Item */
.notification-item { display: flex; gap: 0.75rem; padding: 1rem 1.25rem; border-bottom: 1px solid var(--border); cursor: pointer; transition: all 0.2s; position: relative; }
.notification-item:hover { background: var(--bg-secondary); }
.notification-item.unread { background: rgba(230, 57, 70, 0.05); }
.notification-item.unread:hover { background: rgba(230, 57, 70, 0.1); }

/* Avatar */
.notification-avatar { width: 42px; height: 42px; border-radius: 50%; background: var(--bg-secondary); display: flex; align-items: center; justify-content: center; flex-shrink: 0; overflow: hidden; }
.notification-avatar img { width: 100%; height: 100%; object-fit: cover; }

/* Content */
.notification-content { flex: 1; min-width: 0; }
.notification-title { font-weight: 600; font-size: 0.9rem; margin-bottom: 0.2rem; }
.notification-message { color: var(--text-secondary); font-size: 0.85rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.notification-time { color: var(--text-muted); font-size: 0.75rem; margin-top: 0.3rem; }

/* Unread dot */
.notification-unread-dot { width: 10px; height: 10px; background: var(--accent); border-radius: 50%; flex-shrink: 0; align-self: center; }

/* Empty state */
.notification-empty { text-align: center; padding: 3rem 2rem; color: var(--text-muted); }
.notification-empty-icon { font-size: 3rem; margin-bottom: 1rem; opacity: 0.5; }

/* Footer */
.notification-footer { padding: 0.75rem 1.25rem; border-top: 1px solid var(--border); text-align: center; background: var(--bg-secondary); }

/* Mobile */
@media (max-width: 480px) {
    .notification-panel { right: 0.5rem; left: 0.5rem; width: auto; top: 60px; }
    .notification-item { padding: 0.75rem 1rem; }
}

@media (max-width: 768px) {
    .notification-panel { top: 60px; }
}

/* ==================== CLUB TABS & NEW FEATURES ==================== */
.club-tabs { display: flex; gap: 0; padding: 0; background: var(--bg-secondary); border-bottom: 1px solid var(--border); overflow-x: auto; }
.club-tabs .club-tab { padding: 1rem 1.5rem; background: transparent; border: none; border-radius: 0; color: var(--text-muted); cursor: pointer; font-weight: 500; border-bottom: 3px solid transparent; white-space: nowrap; transition: all 0.2s; }
.club-tabs .club-tab:hover { color: var(--text-primary); background: rgba(255,255,255,0.05); }
.club-tabs .club-tab.active { color: var(--accent); border-bottom-color: var(--accent); background: transparent; }

.club-meta-row { display: flex; gap: 1rem; font-size: 0.85rem; color: var(--text-muted); margin-top: 0.5rem; flex-wrap: wrap; }

#club-tab-content { padding: 1.5rem; }

/* Club Overview / Stats */
.club-overview { max-width: 900px; margin: 0 auto; }
.club-stats-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 1rem; margin-bottom: 1.5rem; }
.club-stat-card { background: var(--bg-card); border: 1px solid var(--border); border-radius: 12px; padding: 1.25rem; text-align: center; }
.club-stat-value { font-family: 'Bebas Neue', sans-serif; font-size: 2rem; color: var(--accent); }
.club-stat-label { font-size: 0.8rem; color: var(--text-muted); text-transform: uppercase; }
.club-genres { margin-top: 1rem; }
.club-genres h3 { font-size: 0.9rem; margin-bottom: 0.5rem; }
.genre-tags { display: flex; flex-wrap: wrap; gap: 0.5rem; }
.genre-tag { background: var(--bg-secondary); padding: 0.35rem 0.75rem; border-radius: 20px; font-size: 0.8rem; }
.genre-tag small { color: var(--text-muted); }

/* Club Members Tab */
.club-members-tab { max-width: 1000px; margin: 0 auto; }
.section-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 1rem; }
.ranks-list { display: flex; flex-direction: column; gap: 0.5rem; }
.rank-item { display: flex; align-items: center; gap: 0.75rem; padding: 0.75rem; background: var(--bg-card); border-radius: 8px; }
.rank-icon { font-size: 1.25rem; }
.rank-name { flex: 1; font-weight: 500; }
.members-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 1rem; }
.member-card { display: flex; align-items: center; gap: 0.75rem; padding: 1rem; background: var(--bg-card); border: 1px solid var(--border); border-radius: 12px; cursor: pointer; transition: all 0.2s; position: relative; }
.member-card:hover { border-color: var(--accent); transform: translateY(-2px); }
.member-card.owner { border-color: gold; background: linear-gradient(135deg, var(--bg-card) 0%, rgba(255,215,0,0.1) 100%); }
.member-avatar { width: 50px; height: 50px; border-radius: 50%; overflow: hidden; background: var(--bg-secondary); display: flex; align-items: center; justify-content: center; font-size: 1.5rem; }
.member-avatar img { width: 100%; height: 100%; object-fit: cover; }
.member-info { flex: 1; min-width: 0; }
.member-name { font-weight: 500; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.member-role { font-size: 0.75rem; color: var(--text-muted); }
.member-role.owner { color: gold; }
.member-role.admin { color: #e63946; }
.member-role.mod { color: #3498db; }
.member-role.custom { font-weight: 500; }
.member-rank-btn { position: absolute; top: 0.5rem; right: 0.5rem; padding: 0.25rem 0.5rem; font-size: 0.75rem; opacity: 0; transition: opacity 0.2s; }
.member-card:hover .member-rank-btn { opacity: 1; }

/* Rank Assignment Modal */
.assign-rank-list { display: flex; flex-direction: column; gap: 0.5rem; }
.rank-option { padding: 1rem; background: var(--bg-secondary); border-radius: 8px; cursor: pointer; transition: all 0.2s; }
.rank-option:hover { background: var(--bg-card); transform: translateX(5px); }

/* Club Forum */
.club-forum { max-width: 800px; margin: 0 auto; }
.forum-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 1.5rem; }
.forum-posts { display: flex; flex-direction: column; gap: 1rem; }
.forum-post { background: var(--bg-card); border: 1px solid var(--border); border-radius: 12px; padding: 1.25rem; cursor: pointer; transition: all 0.2s; }
.forum-post:hover { border-color: var(--accent); }
.forum-post.pinned { border-color: gold; background: linear-gradient(135deg, var(--bg-card) 0%, rgba(255,215,0,0.05) 100%); }
.post-pin { font-size: 0.75rem; color: gold; margin-bottom: 0.5rem; }
.post-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 0.75rem; }
.post-author { display: flex; align-items: center; gap: 0.5rem; }
.post-author-avatar { width: 32px; height: 32px; border-radius: 50%; overflow: hidden; background: var(--bg-secondary); display: flex; align-items: center; justify-content: center; }
.post-author-avatar img { width: 100%; height: 100%; object-fit: cover; }
.post-time { font-size: 0.8rem; color: var(--text-muted); }
.post-title { font-size: 1.1rem; margin-bottom: 0.5rem; }
.post-preview { color: var(--text-secondary); font-size: 0.9rem; margin-bottom: 0.75rem; }
.post-stats { display: flex; gap: 1rem; font-size: 0.85rem; color: var(--text-muted); }
.forum-empty { text-align: center; padding: 3rem; color: var(--text-muted); }

/* Post Detail */
.post-detail { max-height: 70vh; overflow-y: auto; }
.post-meta { display: flex; justify-content: space-between; align-items: center; margin-bottom: 1rem; padding-bottom: 1rem; border-bottom: 1px solid var(--border); }
.post-body { margin-bottom: 1.5rem; line-height: 1.7; }
.post-actions { display: flex; gap: 0.5rem; margin-bottom: 1rem; }
.btn-liked { background: var(--accent) !important; color: white !important; }
.comments-section { margin-top: 1rem; }
.comments-list { display: flex; flex-direction: column; gap: 1rem; margin: 1rem 0; max-height: 300px; overflow-y: auto; }
.comment { background: var(--bg-secondary); padding: 1rem; border-radius: 8px; }
.comment-author { display: flex; align-items: center; gap: 0.5rem; margin-bottom: 0.5rem; font-size: 0.85rem; }
.comment-avatar { width: 24px; height: 24px; border-radius: 50%; overflow: hidden; }
.comment-avatar img { width: 100%; height: 100%; object-fit: cover; }
.comment-time { color: var(--text-muted); font-size: 0.75rem; }
.comment p { margin: 0; font-size: 0.9rem; }
.add-comment { display: flex; gap: 0.5rem; align-items: flex-end; }
.add-comment textarea { flex: 1; resize: none; }

/* Club Challenges */
.club-challenges { max-width: 800px; margin: 0 auto; }
.challenges-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 1.5rem; }
.active-challenge { background: var(--bg-card); border: 2px solid var(--accent); border-radius: 16px; padding: 1.5rem; margin-bottom: 2rem; }
.challenge-banner { display: flex; gap: 1.5rem; margin-bottom: 1.5rem; }
.challenge-cover { width: 120px; height: 180px; border-radius: 8px; object-fit: cover; }
.challenge-info { flex: 1; }
.challenge-badge { display: inline-block; background: var(--accent); color: white; padding: 0.25rem 0.75rem; border-radius: 20px; font-size: 0.75rem; font-weight: 600; margin-bottom: 0.5rem; }
.challenge-info h3 { font-size: 1.5rem; margin-bottom: 0.5rem; }
.challenge-manga { color: var(--text-secondary); margin-bottom: 0.25rem; }
.challenge-goal { font-weight: 500; }
.challenge-deadline { color: var(--text-muted); font-size: 0.85rem; }
.challenge-my-progress { background: var(--bg-secondary); padding: 1.25rem; border-radius: 12px; margin-bottom: 1.5rem; }
.challenge-my-progress h4 { margin-bottom: 0.75rem; }
.progress-bar-container { position: relative; height: 24px; background: var(--bg-card); border-radius: 12px; overflow: hidden; margin-bottom: 1rem; }
.progress-bar-container .progress-bar { height: 100%; background: linear-gradient(90deg, var(--accent), #8b5cf6); border-radius: 12px; transition: width 0.3s; }
.progress-bar-container .progress-text { position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%); font-size: 0.8rem; font-weight: 600; color: white; text-shadow: 0 1px 2px rgba(0,0,0,0.5); }
.progress-controls { display: flex; align-items: center; justify-content: center; gap: 1rem; }
.progress-current { font-family: 'Bebas Neue', sans-serif; font-size: 2rem; min-width: 60px; text-align: center; }
.challenge-leaderboard { margin-bottom: 1.5rem; }
.challenge-leaderboard h4 { margin-bottom: 1rem; }
.challenge-participants { display: flex; flex-direction: column; gap: 0.5rem; }
.participant { display: flex; align-items: center; gap: 0.75rem; padding: 0.75rem; background: var(--bg-secondary); border-radius: 8px; }
.participant-rank { font-size: 1.25rem; min-width: 30px; }
.participant-avatar { width: 36px; height: 36px; border-radius: 50%; overflow: hidden; }
.participant-avatar img { width: 100%; height: 100%; object-fit: cover; }
.participant-name { flex: 1; font-weight: 500; }
.participant-progress { display: flex; align-items: center; gap: 0.5rem; }
.mini-progress { width: 80px; height: 8px; background: var(--bg-card); border-radius: 4px; overflow: hidden; }
.mini-progress div { height: 100%; background: var(--accent); border-radius: 4px; }
.completed-badge { color: #2ecc71; }
.no-active-challenge { text-align: center; padding: 3rem; background: var(--bg-card); border-radius: 12px; }
.no-active-challenge .empty-icon { font-size: 4rem; margin-bottom: 1rem; }
.past-challenges { margin-top: 2rem; }
.past-challenges h3 { margin-bottom: 1rem; }
.past-challenge { display: flex; align-items: center; gap: 1rem; padding: 1rem; background: var(--bg-card); border-radius: 8px; margin-bottom: 0.5rem; }
.past-challenge-title { flex: 1; font-weight: 500; }
.past-challenge-manga { color: var(--text-muted); }
.past-challenge-status.completed { color: #2ecc71; }
.past-challenge-status.cancelled { color: var(--text-muted); }

/* Club Polls */
.club-polls { max-width: 700px; margin: 0 auto; }
.polls-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 1.5rem; }
.polls-list { display: flex; flex-direction: column; gap: 1.5rem; }
.poll-card { background: var(--bg-card); border: 1px solid var(--border); border-radius: 12px; padding: 1.5rem; }
.poll-card.closed { opacity: 0.7; }
.poll-header { display: flex; justify-content: space-between; align-items: flex-start; margin-bottom: 1rem; }
.poll-header h3 { flex: 1; font-size: 1.1rem; }
.poll-status { font-size: 0.75rem; white-space: nowrap; }
.poll-options { display: flex; flex-direction: column; gap: 0.5rem; margin-bottom: 1rem; }
.poll-option { padding: 0.75rem 1rem; border-radius: 8px; }
.poll-option.voteable { background: var(--bg-secondary); border: 1px solid var(--border); cursor: pointer; text-align: left; width: 100%; transition: all 0.2s; }
.poll-option.voteable:hover { border-color: var(--accent); background: var(--bg-card); }
.poll-option.result { position: relative; background: var(--bg-secondary); overflow: hidden; }
.poll-option.result.selected { border: 2px solid var(--accent); }
.poll-option-bar { position: absolute; top: 0; left: 0; height: 100%; background: rgba(230, 57, 70, 0.2); transition: width 0.5s; }
.poll-option-text { position: relative; z-index: 1; }
.poll-option-percent { position: relative; z-index: 1; float: right; font-weight: 600; color: var(--accent); }
.poll-footer { display: flex; justify-content: space-between; align-items: center; font-size: 0.85rem; color: var(--text-muted); }
.polls-empty { text-align: center; padding: 3rem; color: var(--text-muted); }

/* Create Forms */
.create-rank-form, .create-post-form, .create-challenge-form, .create-poll-form { display: flex; flex-direction: column; gap: 1.25rem; }
.create-rank-form .form-group, .create-post-form .form-group, .create-challenge-form .form-group, .create-poll-form .form-group { display: flex; flex-direction: column; gap: 0.5rem; }
.create-rank-form label, .create-post-form label, .create-challenge-form label, .create-poll-form label { color: var(--text-secondary) !important; font-size: 0.9rem; font-weight: 500; }
.create-rank-form input, .create-post-form input, .create-challenge-form input, .create-poll-form input,
.create-rank-form textarea, .create-post-form textarea, .create-challenge-form textarea, .create-poll-form textarea,
.create-rank-form select, .create-post-form select, .create-challenge-form select, .create-poll-form select { 
    background: var(--bg-secondary) !important; 
    border: 1px solid var(--border) !important; 
    border-radius: 10px !important; 
    padding: 0.875rem 1rem !important; 
    color: var(--text-primary) !important; 
    font-size: 1rem !important; 
    transition: all 0.2s;
    width: 100%;
    box-sizing: border-box;
}
.create-rank-form input:focus, .create-post-form input:focus, .create-challenge-form input:focus, .create-poll-form input:focus,
.create-rank-form textarea:focus, .create-post-form textarea:focus, .create-challenge-form textarea:focus, .create-poll-form textarea:focus,
.create-rank-form select:focus, .create-post-form select:focus, .create-challenge-form select:focus, .create-poll-form select:focus {
    border-color: var(--accent) !important;
    outline: none !important;
    box-shadow: 0 0 0 3px rgba(230, 57, 70, 0.1) !important;
}
.create-rank-form input::placeholder, .create-post-form input::placeholder, .create-challenge-form input::placeholder, .create-poll-form input::placeholder,
.create-rank-form textarea::placeholder, .create-post-form textarea::placeholder, .create-challenge-form textarea::placeholder, .create-poll-form textarea::placeholder {
    color: var(--text-muted) !important;
}
.form-row { display: flex; gap: 1rem; }
.form-row .form-group { flex: 1; margin-bottom: 0; }

/* Special Input Types */
input[type="color"] { width: 100%; height: 50px; padding: 4px; border: 1px solid var(--border); border-radius: 10px; background: var(--bg-secondary); cursor: pointer; }
input[type="color"]::-webkit-color-swatch-wrapper { padding: 4px; }
input[type="color"]::-webkit-color-swatch { border-radius: 6px; border: none; }
input[type="date"] { color-scheme: dark; }
input[type="number"] { -moz-appearance: textfield; }

/* Select Styling */
select { appearance: none; -webkit-appearance: none; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%23888' d='M6 8L1 3h10z'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 1rem center; padding-right: 2.5rem !important; cursor: pointer; }
select option { background: var(--bg-card); color: var(--text-primary); }

.poll-option-input { margin-bottom: 0.5rem; }

@media (max-width: 768px) {
    .club-tabs { padding: 0; }
    .club-tabs .club-tab { padding: 0.75rem 1rem; font-size: 0.85rem; }
    .challenge-banner { flex-direction: column; align-items: center; text-align: center; }
    .challenge-cover { width: 100px; height: 150px; }
    .members-grid { grid-template-columns: 1fr; }
    .form-row { flex-direction: column; gap: 0.75rem; }
}

/* ==================== POLL IMAGE SUPPORT & UI POLISH ==================== */
.poll-question-input { font-size: 1.1rem !important; padding: 1rem !important; }
.poll-type-toggle { display: flex; gap: 0.75rem; }
.poll-type-btn { flex: 1; padding: 1rem; border: 2px solid var(--border); background: var(--bg-secondary); border-radius: 12px; cursor: pointer; transition: all 0.2s; font-weight: 600; color: var(--text-secondary); font-size: 1rem; }
.poll-type-btn:hover { border-color: var(--accent); background: rgba(230, 57, 70, 0.05); }
.poll-type-btn.active { border-color: var(--accent); background: rgba(230, 57, 70, 0.15); color: var(--accent); }

.poll-option-row { display: flex; align-items: center; gap: 0.75rem; margin-bottom: 0.75rem; background: var(--bg-card); padding: 0.75rem; border-radius: 12px; border: 1px solid var(--border); }
.poll-option-preview { width: 60px; height: 60px; border-radius: 10px; overflow: hidden; background: var(--bg-secondary); display: none; flex-shrink: 0; border: 1px solid var(--border); }
.poll-option-preview.has-image { display: flex; align-items: center; justify-content: center; }
.poll-option-preview img { width: 100%; height: 100%; object-fit: cover; }
.poll-option-row .poll-option-input { flex: 1; margin: 0; background: var(--bg-secondary) !important; border: 1px solid var(--border) !important; border-radius: 8px !important; padding: 0.75rem 1rem !important; color: var(--text-primary) !important; }
.poll-option-row .poll-option-input::placeholder { color: var(--text-muted) !important; }
.poll-image-btn { width: 44px; height: 44px; display: flex; align-items: center; justify-content: center; background: var(--bg-secondary); border: 2px solid var(--border); border-radius: 10px; cursor: pointer; font-size: 1.25rem; transition: all 0.2s; flex-shrink: 0; }
.poll-image-btn:hover { border-color: var(--accent); background: rgba(230, 57, 70, 0.1); transform: scale(1.05); }
.poll-remove-btn { width: 36px; height: 36px; display: flex; align-items: center; justify-content: center; background: none; border: none; color: var(--text-muted); cursor: pointer; border-radius: 50%; transition: all 0.2s; flex-shrink: 0; font-size: 1.1rem; }
.poll-remove-btn:hover { background: rgba(230, 57, 70, 0.2); color: var(--accent); }

/* Poll Card with Images */
.poll-card.has-images { }
.poll-options.image-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); gap: 1rem; }
.poll-option-card { background: var(--bg-secondary); border: 2px solid var(--border); border-radius: 12px; overflow: hidden; cursor: pointer; transition: all 0.2s; position: relative; }
.poll-option-card:hover { border-color: var(--accent); transform: translateY(-2px); box-shadow: 0 4px 12px rgba(0,0,0,0.2); }
.poll-option-card.selected { border-color: var(--accent); background: rgba(230, 57, 70, 0.1); }
.poll-option-card .poll-option-image-wrapper { position: relative; width: 100%; padding-bottom: 100%; overflow: hidden; }
.poll-option-card .poll-option-image { position: absolute; top: 0; left: 0; width: 100%; height: 100%; object-fit: cover; }
.poll-option-card-content { padding: 0.75rem; }
.poll-option-card .poll-option-text { font-weight: 500; display: block; margin-bottom: 0.25rem; }
.poll-option-card .poll-option-result { margin-top: 0.5rem; }
.poll-mini-bar { height: 6px; background: var(--bg-card); border-radius: 3px; overflow: hidden; margin-bottom: 0.25rem; }
.poll-mini-bar div { height: 100%; background: linear-gradient(90deg, var(--accent), #ff6b6b); border-radius: 3px; transition: width 0.5s; }
.poll-option-card .poll-option-percent { font-size: 0.85rem; font-weight: 600; color: var(--accent); }
.poll-check { position: absolute; top: 0.5rem; right: 0.5rem; width: 24px; height: 24px; background: var(--accent); color: white; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: 0.8rem; z-index: 2; }

/* Image Crop Modal */
.crop-modal { position: fixed; inset: 0; background: rgba(0,0,0,0.9); z-index: 10000; display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 1rem; }
.crop-container { position: relative; max-width: 90vw; max-height: 60vh; overflow: hidden; border: 2px solid var(--border); border-radius: 12px; }
.crop-image { max-width: 100%; max-height: 60vh; display: block; }
.crop-overlay { position: absolute; inset: 0; pointer-events: none; }
.crop-box { position: absolute; border: 3px solid var(--accent); box-shadow: 0 0 0 9999px rgba(0,0,0,0.6); cursor: move; }
.crop-box::before { content: ''; position: absolute; inset: 0; background: repeating-linear-gradient(0deg, transparent, transparent 33.33%, rgba(255,255,255,0.2) 33.33%, rgba(255,255,255,0.2) 33.34%), repeating-linear-gradient(90deg, transparent, transparent 33.33%, rgba(255,255,255,0.2) 33.33%, rgba(255,255,255,0.2) 33.34%); }
.crop-controls { display: flex; gap: 1rem; margin-top: 1.5rem; }
.crop-controls button { padding: 0.75rem 2rem; border-radius: 10px; font-weight: 600; font-size: 1rem; }

/* Poll Card General Polish */
.poll-card { background: linear-gradient(135deg, var(--bg-card) 0%, var(--bg-secondary) 100%); border: 1px solid var(--border); border-radius: 16px; padding: 1.5rem; transition: all 0.2s; }
.poll-card:hover { border-color: rgba(230, 57, 70, 0.3); }
.poll-card.active { border-left: 4px solid #2ecc71; }
.poll-card.closed { border-left: 4px solid var(--text-muted); }
.poll-header { margin-bottom: 1.25rem; }
.poll-header h3 { font-size: 1.2rem; line-height: 1.4; }
.poll-footer { display: flex; justify-content: space-between; align-items: center; margin-top: 1rem; padding-top: 1rem; border-top: 1px solid var(--border); font-size: 0.85rem; color: var(--text-muted); }

/* Challenge UI Polish */
.active-challenge { background: linear-gradient(135deg, var(--bg-card) 0%, rgba(230, 57, 70, 0.05) 100%); border: 2px solid var(--accent); border-radius: 20px; padding: 2rem; position: relative; overflow: hidden; }
.active-challenge::before { content: ''; position: absolute; top: 0; left: 0; right: 0; height: 4px; background: linear-gradient(90deg, var(--accent), #8b5cf6, #3498db); }
.challenge-badge { animation: pulse 2s infinite; }
@keyframes pulse { 0%, 100% { opacity: 1; } 50% { opacity: 0.7; } }
.progress-bar-container .progress-bar { background: linear-gradient(90deg, #2ecc71, #27ae60, #1abc9c); }
.progress-controls button { font-size: 1.25rem; width: 48px; height: 48px; border-radius: 50%; }

/* Forum UI Polish */
.forum-post { background: linear-gradient(135deg, var(--bg-card) 0%, var(--bg-secondary) 100%); border-radius: 16px; transition: all 0.2s; }
.forum-post:hover { transform: translateY(-2px); box-shadow: 0 4px 16px rgba(0,0,0,0.15); }
.forum-post.pinned { background: linear-gradient(135deg, rgba(255,215,0,0.1) 0%, var(--bg-card) 100%); border: 1px solid rgba(255,215,0,0.3); }
.post-title { font-size: 1.15rem; color: var(--text-primary); }

/* Members UI Polish */
.member-card { background: linear-gradient(135deg, var(--bg-card) 0%, var(--bg-secondary) 100%); border-radius: 16px; }
.member-card.owner { background: linear-gradient(135deg, rgba(255,215,0,0.15) 0%, var(--bg-card) 100%); border: 2px solid rgba(255,215,0,0.5); }
.member-avatar { border: 2px solid var(--border); }
.member-card.owner .member-avatar { border-color: gold; }

/* Stats Cards Polish */
.club-stat-card { background: linear-gradient(135deg, var(--bg-card) 0%, var(--bg-secondary) 100%); border-radius: 16px; transition: all 0.2s; }
.club-stat-card:hover { transform: translateY(-2px); box-shadow: 0 4px 12px rgba(0,0,0,0.15); }
.club-stat-card:nth-child(1) .club-stat-value { color: #e63946; }
.club-stat-card:nth-child(2) .club-stat-value { color: #3498db; }
.club-stat-card:nth-child(3) .club-stat-value { color: #2ecc71; }
.club-stat-card:nth-child(4) .club-stat-value { color: #f1c40f; }

/* Rank Item Polish */
.rank-item { background: linear-gradient(135deg, var(--bg-card) 0%, var(--bg-secondary) 100%); border-radius: 12px; transition: all 0.2s; }
.rank-item:hover { transform: translateX(4px); }

/* Button Polish */
.btn-large { padding: 1rem 2rem; font-size: 1.1rem; }

/* Section Headers */
.club-section h2 { font-size: 1.3rem; margin-bottom: 1rem; display: flex; align-items: center; gap: 0.5rem; }
.club-section h2::after { content: ''; flex: 1; height: 1px; background: linear-gradient(90deg, var(--border) 0%, transparent 100%); margin-left: 1rem; }

/* Participant Leaderboard Polish */
.participant { background: linear-gradient(135deg, var(--bg-secondary) 0%, var(--bg-card) 100%); border-radius: 12px; transition: all 0.2s; }
.participant:hover { transform: translateX(4px); }
.participant:first-child { background: linear-gradient(135deg, rgba(255,215,0,0.1) 0%, var(--bg-card) 100%); border: 1px solid rgba(255,215,0,0.3); }
.participant:nth-child(2) { background: linear-gradient(135deg, rgba(192,192,192,0.1) 0%, var(--bg-card) 100%); }
.participant:nth-child(3) { background: linear-gradient(135deg, rgba(205,127,50,0.1) 0%, var(--bg-card) 100%); }

/* Challenge & Poll Owner Actions */
.challenge-owner-actions { display: flex; gap: 0.75rem; margin-top: 1.5rem; flex-wrap: wrap; }
.poll-actions { display: flex; gap: 0.5rem; align-items: center; }
.past-challenge { display: flex; align-items: center; gap: 1rem; padding: 1rem; background: var(--bg-card); border-radius: 8px; margin-bottom: 0.5rem; }
.past-challenge .btn { margin-left: auto; flex-shrink: 0; }

/* Crop Modal Enhancements */
.crop-container { position: relative; background: #000; }
#crop-canvas { display: block; }
.crop-box { position: absolute; border: 3px solid var(--accent); box-shadow: 0 0 0 9999px rgba(0,0,0,0.7); cursor: move; touch-action: none; }
.crop-box::before { content: ''; position: absolute; inset: 0; background: linear-gradient(to right, rgba(255,255,255,0.1) 1px, transparent 1px) 0 0 / 33.33% 100%, linear-gradient(to bottom, rgba(255,255,255,0.1) 1px, transparent 1px) 0 0 / 100% 33.33%; pointer-events: none; }
.crop-box::after { content: ''; position: absolute; inset: -3px; border: 3px solid white; border-radius: 2px; pointer-events: none; }

/* Crop Resize Handles */
.crop-handle { position: absolute; width: 20px; height: 20px; background: white; border: 2px solid var(--accent); border-radius: 50%; z-index: 10; cursor: pointer; }
.crop-handle-nw { top: -10px; left: -10px; cursor: nw-resize; }
.crop-handle-ne { top: -10px; right: -10px; cursor: ne-resize; }
.crop-handle-sw { bottom: -10px; left: -10px; cursor: sw-resize; }
.crop-handle-se { bottom: -10px; right: -10px; cursor: se-resize; }
.crop-handle:hover { background: var(--accent); transform: scale(1.2); }

/* GIF Picker Modal */
.gif-picker-container { background: var(--bg-card); border-radius: 16px; width: 90%; max-width: 500px; max-height: 70vh; display: flex; flex-direction: column; overflow: hidden; border: 1px solid var(--border); }
.gif-picker-header { display: flex; justify-content: space-between; align-items: center; padding: 1rem 1.25rem; border-bottom: 1px solid var(--border); }
.gif-picker-header h3 { margin: 0; font-family: 'Bebas Neue', sans-serif; font-size: 1.3rem; }
.gif-search-box { padding: 0.75rem 1rem; border-bottom: 1px solid var(--border); }
.gif-search-box input { width: 100%; padding: 0.75rem 1rem; background: var(--bg-secondary); border: 1px solid var(--border); border-radius: 8px; color: var(--text-primary); font-size: 1rem; box-sizing: border-box; }
.gif-search-box input:focus { outline: none; border-color: var(--accent); }
.gif-categories { display: flex; gap: 0.5rem; padding: 0.75rem 1rem; overflow-x: auto; border-bottom: 1px solid var(--border); flex-shrink: 0; }
.gif-categories button { background: var(--bg-secondary); border: 1px solid var(--border); border-radius: 20px; padding: 0.4rem 0.75rem; color: var(--text-primary); font-size: 0.8rem; white-space: nowrap; cursor: pointer; transition: all 0.2s; }
.gif-categories button:hover { background: var(--accent); border-color: var(--accent); color: white; }
.gif-results { flex: 1; overflow-y: auto; padding: 0.75rem; min-height: 250px; max-height: 350px; }
.gif-grid { display: grid !important; grid-template-columns: repeat(3, 1fr) !important; gap: 8px !important; }
.gif-item { aspect-ratio: 1; border-radius: 8px; overflow: hidden; cursor: pointer; transition: transform 0.2s; background: var(--bg-secondary); min-height: 0; }
.gif-item:hover { transform: scale(1.05); box-shadow: 0 0 15px rgba(230, 57, 70, 0.3); }
.gif-item img { width: 100%; height: 100%; object-fit: cover; display: block; }
.gif-loading, .gif-empty { text-align: center; padding: 2rem; color: var(--text-muted); }
.gif-powered-by { text-align: center; padding: 0.5rem; font-size: 0.7rem; color: var(--text-muted); border-top: 1px solid var(--border); flex-shrink: 0; }


/* ==================== HOMEPAGE ==================== */
.homepage { min-height: 100vh; background: var(--bg-primary); }

/* Homepage Nav */
.homepage-nav { position: fixed; top: 0; left: 0; right: 0; z-index: 100; background: rgba(15, 15, 15, 0.85); backdrop-filter: blur(20px); border-bottom: 1px solid rgba(255,255,255,0.05); }
.homepage-nav-inner { max-width: 100%; margin: 0; padding: 1rem 3rem; display: flex; justify-content: space-between; align-items: center; }
.homepage-logo { display: flex; align-items: center; gap: 0.75rem; cursor: pointer; }
.homepage-logo img { height: 40px; filter: drop-shadow(0 0 10px rgba(230, 57, 70, 0.3)); }
.homepage-logo span { font-family: 'Bebas Neue', sans-serif; font-size: 1.5rem; color: var(--text-primary); }
.homepage-nav-links { display: flex; align-items: center; gap: 2rem; }
.homepage-nav-links a { color: var(--text-secondary); text-decoration: none; font-size: 0.95rem; transition: all 0.2s; }
.homepage-nav-links a:hover { color: var(--accent); text-shadow: 0 0 20px rgba(230, 57, 70, 0.5); }

/* Hero Section with Background Image */
.hero-section { min-height: 100vh; display: flex; align-items: center; padding: 6rem 2rem 4rem; position: relative; overflow: hidden; }
.hero-bg-image { position: absolute; top: 0; right: 0; width: 65%; height: 100%; background: url('/hero-bg.jpg') center right / cover no-repeat; mask-image: linear-gradient(to left, rgba(0,0,0,1) 0%, rgba(0,0,0,0.8) 50%, rgba(0,0,0,0) 100%); -webkit-mask-image: linear-gradient(to left, rgba(0,0,0,1) 0%, rgba(0,0,0,0.8) 50%, rgba(0,0,0,0) 100%); }
.hero-overlay { position: absolute; inset: 0; background: linear-gradient(135deg, rgba(15,15,15,1) 0%, rgba(15,15,15,0.95) 30%, rgba(15,15,15,0.7) 60%, rgba(15,15,15,0.4) 100%); }
.hero-content { flex: 1; max-width: 550px; margin-left: 8%; position: relative; z-index: 2; }
.hero-badge { display: inline-block; background: linear-gradient(135deg, rgba(230, 57, 70, 0.2), rgba(139, 92, 246, 0.2)); border: 1px solid rgba(230, 57, 70, 0.3); padding: 0.5rem 1rem; border-radius: 30px; font-size: 0.85rem; color: var(--accent); margin-bottom: 1.5rem; animation: pulse-glow 2s ease-in-out infinite; }
@keyframes pulse-glow { 0%, 100% { box-shadow: 0 0 20px rgba(230, 57, 70, 0.2); } 50% { box-shadow: 0 0 30px rgba(230, 57, 70, 0.4); } }
.hero-title { margin-bottom: 1.5rem; }
.hero-title-line { display: block; font-family: 'IBM Plex Sans', sans-serif; font-size: 1.1rem; font-weight: 300; color: var(--text-muted); text-transform: uppercase; letter-spacing: 4px; margin-bottom: 0.5rem; }
.hero-title-accent { display: block; font-family: 'Bebas Neue', sans-serif; font-size: 5rem; color: var(--text-primary); line-height: 1; background: linear-gradient(135deg, #fff 0%, var(--accent) 50%, #8b5cf6 100%); -webkit-background-clip: text; -webkit-text-fill-color: transparent; background-clip: text; text-shadow: none; filter: drop-shadow(0 0 30px rgba(230, 57, 70, 0.3)); }
.hero-subtitle { font-size: 1.1rem; color: var(--text-secondary); line-height: 1.8; margin-bottom: 2.5rem; }
.hero-buttons { display: flex; gap: 1rem; margin-bottom: 3rem; }
.btn-large { padding: 1rem 2rem; font-size: 1rem; }
.btn-glow { box-shadow: 0 0 30px rgba(230, 57, 70, 0.4); transition: all 0.3s; }
.btn-glow:hover { box-shadow: 0 0 50px rgba(230, 57, 70, 0.6); transform: translateY(-2px); }
.hero-stats { display: flex; align-items: center; gap: 1.5rem; padding: 1.5rem; background: rgba(255,255,255,0.03); border-radius: 16px; border: 1px solid rgba(255,255,255,0.05); backdrop-filter: blur(10px); }
.hero-stat { text-align: center; flex: 1; }
.hero-stat-value { display: block; font-family: 'Bebas Neue', sans-serif; font-size: 2rem; color: var(--accent); text-shadow: 0 0 20px rgba(230, 57, 70, 0.5); }
.hero-stat-label { font-size: 0.8rem; color: var(--text-muted); text-transform: uppercase; letter-spacing: 1px; }
.hero-stat-divider { width: 1px; height: 40px; background: linear-gradient(to bottom, transparent, var(--border), transparent); }

/* Section Styling */
.section-header { text-align: center; margin-bottom: 3rem; }
.section-badge { display: inline-block; background: rgba(230, 57, 70, 0.1); border: 1px solid rgba(230, 57, 70, 0.2); padding: 0.4rem 1rem; border-radius: 20px; font-size: 0.8rem; color: var(--accent); text-transform: uppercase; letter-spacing: 2px; margin-bottom: 1rem; }
.section-title { font-family: 'Bebas Neue', sans-serif; font-size: 2.5rem; margin-bottom: 0.5rem; }
.section-subtitle { color: var(--text-secondary); font-size: 1.1rem; }

/* Features Section */
.features-section { padding: 6rem 2rem; max-width: 1200px; margin: 0 auto; }
.features-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(320px, 1fr)); gap: 1.5rem; }
.feature-card { background: linear-gradient(135deg, rgba(30,30,30,1), rgba(25,25,25,1)); border: 1px solid var(--border); border-radius: 20px; padding: 2rem; transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275); position: relative; overflow: hidden; }
.feature-card::before { content: ''; position: absolute; top: 0; left: 0; right: 0; height: 2px; background: linear-gradient(90deg, transparent, var(--accent), transparent); opacity: 0; transition: opacity 0.3s; }
.feature-card:hover { transform: translateY(-8px); border-color: rgba(230, 57, 70, 0.3); box-shadow: 0 20px 60px rgba(0,0,0,0.3), 0 0 40px rgba(230, 57, 70, 0.1); }
.feature-card:hover::before { opacity: 1; }
.feature-icon { font-size: 2.5rem; margin-bottom: 1rem; filter: drop-shadow(0 0 10px rgba(230, 57, 70, 0.3)); }
.feature-card h3 { font-family: 'Bebas Neue', sans-serif; font-size: 1.4rem; margin-bottom: 0.75rem; }
.feature-card p { color: var(--text-secondary); font-size: 0.95rem; line-height: 1.7; }

/* Showcase Section */
.showcase-section { padding: 6rem 2rem; background: linear-gradient(180deg, var(--bg-primary) 0%, rgba(230, 57, 70, 0.03) 50%, var(--bg-primary) 100%); display: flex; align-items: center; justify-content: center; gap: 6rem; max-width: 1200px; margin: 0 auto; }
.showcase-content { flex: 1; max-width: 450px; }
.showcase-content h2 { font-family: 'Bebas Neue', sans-serif; font-size: 2.5rem; line-height: 1.2; margin-bottom: 1.5rem; }
.showcase-content p { color: var(--text-secondary); line-height: 1.8; margin-bottom: 2rem; }
.showcase-list { list-style: none; padding: 0; display: flex; flex-direction: column; gap: 0.75rem; }
.showcase-list li { display: flex; align-items: center; gap: 0.75rem; color: var(--text-secondary); }
.showcase-list .check { color: var(--accent); font-weight: bold; }
.showcase-visual { flex: 1; display: flex; flex-direction: column; gap: 1rem; max-width: 350px; }
.showcase-card { background: var(--bg-card); border: 1px solid var(--border); border-radius: 16px; padding: 1.25rem; transition: all 0.3s; }
.showcase-card:hover { transform: translateX(10px); border-color: var(--accent); box-shadow: 0 0 30px rgba(230, 57, 70, 0.15); }
.showcase-card-header { font-size: 0.85rem; color: var(--text-muted); margin-bottom: 0.5rem; }
.showcase-card-value { font-family: 'Bebas Neue', sans-serif; font-size: 2.5rem; color: var(--accent); }
.showcase-card-label { font-size: 0.9rem; color: var(--text-secondary); }
.showcase-card-1 { animation: float-card 4s ease-in-out infinite; }
.showcase-card-2 { animation: float-card 4s ease-in-out infinite 0.5s; }
.showcase-card-3 { animation: float-card 4s ease-in-out infinite 1s; }
@keyframes float-card { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-5px); } }

/* CTA Section */
.cta-section { padding: 8rem 2rem; position: relative; overflow: hidden; text-align: center; display: flex; align-items: center; justify-content: center; }
.cta-glow { position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%); width: 600px; height: 600px; background: radial-gradient(circle, rgba(230, 57, 70, 0.15) 0%, transparent 70%); pointer-events: none; animation: cta-pulse 4s ease-in-out infinite; }
@keyframes cta-pulse { 0%, 100% { transform: translate(-50%, -50%) scale(1); opacity: 0.5; } 50% { transform: translate(-50%, -50%) scale(1.2); opacity: 1; } }
.cta-content { position: relative; z-index: 1; display: flex; flex-direction: column; align-items: center; }
.cta-content h2 { font-family: 'Bebas Neue', sans-serif; font-size: 3rem; margin-bottom: 1rem; }
.cta-content p { color: var(--text-secondary); margin-bottom: 2rem; font-size: 1.2rem; }

/* Homepage Footer */
.homepage-footer { padding: 4rem 3rem 2rem; border-top: 1px solid var(--border); background: rgba(0,0,0,0.5); }
.footer-content { max-width: 1200px; margin: 0 auto; display: flex; justify-content: space-between; align-items: flex-start; flex-wrap: wrap; gap: 3rem; padding-bottom: 2rem; border-bottom: 1px solid var(--border); }
.footer-section { display: flex; flex-direction: column; gap: 0.75rem; }
.footer-section h4 { font-family: 'Bebas Neue', sans-serif; font-size: 1.1rem; color: var(--text-primary); margin-bottom: 0.25rem; }
.footer-logo { display: flex; align-items: center; gap: 0.5rem; }
.footer-logo img { height: 35px; }
.footer-logo span { font-family: 'Bebas Neue', sans-serif; font-size: 1.3rem; }
.footer-tagline { color: var(--text-muted); font-size: 0.85rem; max-width: 250px; line-height: 1.5; }
.footer-links-list { display: flex; flex-direction: column; gap: 0.5rem; }
.footer-links-list a { color: var(--text-secondary); text-decoration: none; font-size: 0.9rem; transition: all 0.2s; }
.footer-links-list a:hover { color: var(--accent); transform: translateX(3px); }
.footer-bottom { max-width: 1200px; margin: 0 auto; padding-top: 1.5rem; text-align: center; }
.footer-copyright { color: var(--text-muted); font-size: 0.85rem; }

/* Legal Modals */
.legal-modal-overlay { position: fixed; inset: 0; background: rgba(0, 0, 0, 0.9); backdrop-filter: blur(10px); display: flex; align-items: center; justify-content: center; z-index: 1001; overflow-y: auto; padding: 2rem; }
.legal-modal { background: var(--bg-card); border-radius: 16px; padding: 2rem; width: 100%; max-width: 700px; position: relative; border: 1px solid var(--border); animation: modalSlideIn 0.3s ease; max-height: 80vh; overflow-y: auto; }
.legal-modal h2 { font-family: 'Bebas Neue', sans-serif; font-size: 1.8rem; margin-bottom: 1.5rem; color: var(--accent); }
.legal-modal-close { position: absolute; top: 1rem; right: 1rem; background: none; border: none; color: var(--text-muted); font-size: 1.5rem; cursor: pointer; width: 36px; height: 36px; border-radius: 50%; display: flex; align-items: center; justify-content: center; transition: all 0.2s; }
.legal-modal-close:hover { background: var(--bg-secondary); color: var(--accent); }
.legal-content h3 { font-size: 1.1rem; color: var(--text-primary); margin: 1.5rem 0 0.75rem; }
.legal-content h3:first-child { margin-top: 0; }
.legal-content p { color: var(--text-secondary); font-size: 0.9rem; line-height: 1.7; margin-bottom: 0.75rem; }

/* Auth Modal */
.auth-modal-overlay { position: fixed; inset: 0; background: rgba(0, 0, 0, 0.85); backdrop-filter: blur(10px); display: flex; align-items: center; justify-content: center; z-index: 1000; }
.auth-modal { background: linear-gradient(135deg, var(--bg-card), rgba(30,30,30,1)); border-radius: 24px; padding: 2.5rem; width: 90%; max-width: 400px; position: relative; border: 1px solid var(--border); animation: modalSlideIn 0.3s ease; box-shadow: 0 25px 80px rgba(0,0,0,0.5), 0 0 60px rgba(230, 57, 70, 0.1); }
@keyframes modalSlideIn { from { opacity: 0; transform: translateY(-20px) scale(0.95); } to { opacity: 1; transform: translateY(0) scale(1); } }
.auth-modal-close { position: absolute; top: 1rem; right: 1rem; background: none; border: none; color: var(--text-muted); font-size: 1.5rem; cursor: pointer; width: 36px; height: 36px; border-radius: 50%; display: flex; align-items: center; justify-content: center; transition: all 0.2s; }
.auth-modal-close:hover { background: var(--bg-secondary); color: var(--accent); }
.auth-modal-header { text-align: center; margin-bottom: 2rem; }
.auth-modal-header .auth-logo { height: 60px; margin-bottom: 1rem; filter: drop-shadow(0 0 20px rgba(230, 57, 70, 0.3)); }
.auth-modal-header h2 { font-family: 'Bebas Neue', sans-serif; font-size: 1.5rem; }
.auth-switch { text-align: center; margin-top: 1rem; font-size: 0.9rem; color: var(--text-secondary); }
.auth-switch a { color: var(--accent); text-decoration: none; font-weight: 500; }
.auth-switch a:hover { text-decoration: underline; }

/* Mobile Homepage */
@media (max-width: 900px) {
    .hero-section { flex-direction: column; text-align: center; padding-top: 6rem; }
    .hero-bg-image { width: 100%; opacity: 0.3; mask-image: linear-gradient(to bottom, rgba(0,0,0,0.5) 0%, rgba(0,0,0,0) 100%); -webkit-mask-image: linear-gradient(to bottom, rgba(0,0,0,0.5) 0%, rgba(0,0,0,0) 100%); }
    .hero-overlay { background: linear-gradient(to bottom, rgba(15,15,15,0.8), rgba(15,15,15,1)); }
    .hero-content { margin-left: 0; max-width: 100%; }
    .hero-title-accent { font-size: 3.5rem; }
    .hero-buttons { justify-content: center; flex-wrap: wrap; }
    .hero-stats { flex-wrap: wrap; justify-content: center; }
    .hero-stat-divider { display: none; }
    .homepage-nav-inner { padding: 1rem 1.5rem; }
    .homepage-nav-links a:not(.btn) { display: none; }
    .showcase-section { flex-direction: column; gap: 3rem; }
    .showcase-visual { max-width: 100%; }
    .footer-content { flex-direction: column; text-align: center; align-items: center; gap: 2rem; }
    .footer-section { align-items: center; }
    .footer-tagline { text-align: center; }
    .footer-links-list { align-items: center; }
    .footer-links-list a:hover { transform: none; }
    .cta-content h2 { font-size: 2rem; }
    .legal-modal { padding: 1.5rem; max-height: 90vh; }
}

/* Guest Auth Buttons in Navbar */
.guest-auth-buttons { display: flex; align-items: center; gap: 0.75rem; }
.user-auth-actions { display: flex; align-items: center; gap: 0.5rem; }


/* ==================== SHOWCASE GALLERY ==================== */
.showcase-container { padding: 1rem 0; }
.showcase-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 1.5rem; flex-wrap: wrap; gap: 1rem; }
.showcase-title h2 { margin: 0; font-size: 1.5rem; }
.showcase-subtitle { color: var(--text-muted); font-size: 0.9rem; margin-top: 0.25rem; }

.showcase-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 1rem; }
.showcase-item { position: relative; aspect-ratio: 1; border-radius: 12px; overflow: hidden; cursor: pointer; background: var(--bg-card); border: 1px solid var(--border); transition: transform 0.2s, box-shadow 0.2s; }
.showcase-item:hover { transform: scale(1.02); box-shadow: 0 8px 25px rgba(0,0,0,0.3); }
.showcase-item img { width: 100%; height: 100%; object-fit: cover; }
.showcase-caption { position: absolute; bottom: 0; left: 0; right: 0; padding: 0.75rem; background: linear-gradient(transparent, rgba(0,0,0,0.8)); color: white; font-size: 0.85rem; }
.showcase-delete { position: absolute; top: 8px; right: 8px; width: 28px; height: 28px; border-radius: 50%; background: rgba(0,0,0,0.7); color: white; border: none; cursor: pointer; font-size: 1.2rem; display: flex; align-items: center; justify-content: center; opacity: 0; transition: opacity 0.2s, background 0.2s; }
.showcase-item:hover .showcase-delete { opacity: 1; }
.showcase-delete:hover { background: var(--accent); }

.showcase-empty { grid-column: 1 / -1; text-align: center; padding: 4rem 2rem; background: var(--bg-card); border-radius: 16px; border: 2px dashed var(--border); }
.showcase-empty-icon { font-size: 4rem; margin-bottom: 1rem; }
.showcase-empty p { color: var(--text-muted); margin: 0.5rem 0; }
.showcase-empty .hint { font-size: 0.85rem; }

.showcase-loading { grid-column: 1 / -1; text-align: center; padding: 3rem; }

/* Showcase Upload */
.showcase-upload-form { padding: 0.5rem; }
.showcase-preview-img { max-width: 100%; max-height: 300px; object-fit: contain; border-radius: 8px; }
.showcase-upload-actions { display: flex; gap: 1rem; justify-content: flex-end; margin-top: 1.5rem; }
#showcase-upload-area.dragover { border-color: var(--accent); background: rgba(230, 57, 70, 0.1); }

/* Lightbox */
.showcase-lightbox { position: fixed; top: 0; left: 0; right: 0; bottom: 0; background: rgba(0,0,0,0.95); z-index: 10000; display: flex; align-items: center; justify-content: center; animation: fadeIn 0.2s ease; }
.lightbox-content { position: relative; max-width: 90vw; max-height: 90vh; display: flex; flex-direction: column; align-items: center; }
.lightbox-content img { max-width: 100%; max-height: 85vh; object-fit: contain; border-radius: 8px; }
.lightbox-caption { margin-top: 1rem; color: white; font-size: 1rem; text-align: center; max-width: 600px; }
.lightbox-close { position: absolute; top: -40px; right: 0; background: none; border: none; color: white; font-size: 2rem; cursor: pointer; padding: 0.5rem; opacity: 0.7; transition: opacity 0.2s; }
.lightbox-close:hover { opacity: 1; }
.lightbox-nav { position: absolute; top: 50%; transform: translateY(-50%); background: rgba(255,255,255,0.1); border: none; color: white; font-size: 2.5rem; padding: 1rem 1.5rem; cursor: pointer; border-radius: 8px; transition: background 0.2s; }
.lightbox-nav:hover { background: rgba(255,255,255,0.2); }
.lightbox-prev { left: -80px; }
.lightbox-next { right: -80px; }

@media (max-width: 768px) {
    .showcase-grid { grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 0.75rem; }
    .showcase-header { flex-direction: column; align-items: flex-start; }
    .lightbox-nav { display: none; }
    .lightbox-close { top: -50px; right: -10px; }
}

@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }

/* ==================== MANGACOINS SYSTEM ==================== */
.coin-display { display: flex; align-items: center; gap: 0.35rem; padding: 0.4rem 0.75rem; background: linear-gradient(135deg, rgba(255,193,7,0.15), rgba(255,152,0,0.15)); border: 1px solid rgba(255,193,7,0.3); border-radius: 20px; cursor: pointer; transition: all 0.2s; margin-right: 0.5rem; }
.coin-display:hover { background: linear-gradient(135deg, rgba(255,193,7,0.25), rgba(255,152,0,0.25)); transform: scale(1.05); }
.coin-icon { font-size: 1rem; }
.coin-amount { font-weight: 700; color: #ffc107; font-size: 0.9rem; }
.coin-balance-header { background: linear-gradient(135deg, #ffc107, #ff9800); color: #1a1a1a; padding: 0.2rem 0.6rem; border-radius: 12px; font-size: 0.85rem; font-weight: 700; }

/* Missions Container */
.missions-container { max-height: 70vh; overflow-y: auto; }
.missions-timer { text-align: center; padding: 0.75rem; background: var(--bg-secondary); border-radius: 8px; margin-bottom: 1rem; color: var(--text-muted); font-size: 0.85rem; }
.missions-section { margin-bottom: 1.5rem; }
.missions-section-title { font-size: 1rem; margin-bottom: 0.75rem; color: var(--text-primary); }
.missions-list { display: flex; flex-direction: column; gap: 0.75rem; }

/* Mission Card */
.mission-card { display: flex; align-items: center; gap: 1rem; padding: 1rem; background: var(--bg-card); border: 1px solid var(--border); border-radius: 12px; transition: all 0.2s; }
.mission-card:hover { border-color: var(--accent); }
.mission-card.completed { border-color: #22c55e; background: rgba(34, 197, 94, 0.05); }
.mission-card.claimed { opacity: 0.6; }
.mission-icon { font-size: 1.75rem; width: 50px; height: 50px; display: flex; align-items: center; justify-content: center; background: var(--bg-secondary); border-radius: 12px; }
.mission-info { flex: 1; min-width: 0; }
.mission-name { font-weight: 600; color: var(--text-primary); margin-bottom: 0.2rem; }
.mission-desc { font-size: 0.8rem; color: var(--text-muted); margin-bottom: 0.5rem; }
.mission-progress-bar { height: 6px; background: var(--bg-secondary); border-radius: 3px; overflow: hidden; margin-bottom: 0.25rem; }
.mission-progress-fill { height: 100%; background: linear-gradient(90deg, var(--accent), #f59e0b); border-radius: 3px; transition: width 0.3s ease; }
.mission-progress-text { font-size: 0.75rem; color: var(--text-muted); }

/* Mission Reward */
.mission-reward { display: flex; flex-direction: column; align-items: center; gap: 0.25rem; min-width: 70px; }
.reward-amount { font-weight: 700; color: #ffc107; font-size: 1rem; }
.reward-icon { font-size: 1.25rem; }
.claim-btn { margin-top: 0.25rem; font-size: 0.7rem !important; padding: 0.3rem 0.6rem !important; animation: claimPulse 1.5s ease-in-out infinite; }
.claimed-badge { color: #22c55e; font-size: 1.25rem; }

@keyframes claimPulse {
    0%, 100% { box-shadow: 0 0 0 0 rgba(230, 57, 70, 0.4); }
    50% { box-shadow: 0 0 0 8px rgba(230, 57, 70, 0); }
}

@media (max-width: 500px) {
    .mission-card { flex-wrap: wrap; }
    .mission-reward { flex-direction: row; width: 100%; justify-content: flex-end; margin-top: 0.5rem; padding-top: 0.5rem; border-top: 1px solid var(--border); }
}

/* ==================== ADMIN PANEL ==================== */
.admin-panel { padding: 0.5rem; }
.admin-section { margin-bottom: 1.5rem; }
.admin-section h3 { margin-bottom: 1rem; font-size: 1rem; color: var(--text-primary); }

.admin-search-row { display: flex; gap: 0.75rem; margin-bottom: 1rem; }
.admin-search-row input { flex: 1; }

.admin-search-results { max-height: 400px; overflow-y: auto; }
.admin-loading, .admin-error, .admin-empty { text-align: center; padding: 2rem; color: var(--text-muted); }
.admin-error { color: var(--accent); }

.admin-user-card { background: var(--bg-secondary); border-radius: 12px; padding: 1rem; margin-bottom: 0.75rem; border: 1px solid var(--border); }
.admin-user-info { display: flex; align-items: center; gap: 1rem; margin-bottom: 0.75rem; }
.admin-user-avatar { width: 50px; height: 50px; border-radius: 50%; overflow: hidden; background: var(--bg-card); }
.admin-user-avatar img { width: 100%; height: 100%; object-fit: cover; }
.admin-avatar-placeholder { width: 100%; height: 100%; display: flex; align-items: center; justify-content: center; font-weight: 600; font-size: 1.25rem; background: var(--accent); color: white; }
.admin-user-details { flex: 1; }
.admin-user-name { font-weight: 600; color: var(--text-primary); }
.admin-user-username { font-size: 0.85rem; color: var(--text-muted); }
.admin-user-badges { display: flex; gap: 0.5rem; margin-top: 0.35rem; flex-wrap: wrap; }

.admin-badge { font-size: 0.65rem; padding: 0.15rem 0.4rem; border-radius: 4px; font-weight: 700; }
.admin-badge.admin { background: linear-gradient(135deg, #dc2626, #b91c1c); color: white; }
.admin-badge.mod { background: linear-gradient(135deg, #7c3aed, #6d28d9); color: white; }
.admin-badge.creator { background: linear-gradient(135deg, #00f2ea, #ff0050); color: white; }
.admin-badge.pro { background: linear-gradient(135deg, #ffc107, #ff9800); color: #1a1a1a; }

.admin-user-actions { display: flex; gap: 0.5rem; flex-wrap: wrap; }
.admin-user-actions .btn-small { font-size: 0.75rem; padding: 0.4rem 0.75rem; }
.btn-danger { background: #dc2626 !important; border-color: #dc2626 !important; }
.btn-danger:hover { background: #b91c1c !important; }

.admin-quick-actions { display: flex; gap: 0.75rem; flex-wrap: wrap; }

.admin-role-menu { padding: 1rem; }
.admin-role-menu h4 { margin-bottom: 1rem; text-align: center; }
.admin-role-option { display: flex; align-items: center; width: 100%; padding: 0.75rem 1rem; background: var(--bg-card); border: 1px solid var(--border); border-radius: 8px; margin-bottom: 0.5rem; cursor: pointer; transition: all 0.2s; text-align: left; }
.admin-role-option:hover { border-color: var(--accent); }
.admin-role-option.active { border-color: var(--accent); background: rgba(230,57,70,0.1); }
.admin-role-option .role-name { font-weight: 600; color: var(--text-primary); margin-right: 0.75rem; }
.admin-role-option .role-desc { color: var(--text-muted); font-size: 0.85rem; flex: 1; }
.admin-role-option .role-check { color: var(--accent); font-weight: bold; }

.admin-dropdown-btn { background: linear-gradient(135deg, rgba(220,38,38,0.15), rgba(185,28,28,0.1)) !important; border-left: 3px solid #dc2626 !important; margin-top: 0.25rem; }
.admin-dropdown-btn:hover { background: linear-gradient(135deg, rgba(220,38,38,0.25), rgba(185,28,28,0.2)) !important; }

@media (max-width: 500px) {
    .admin-user-actions { flex-direction: column; }
    .admin-user-actions .btn-small { width: 100%; }
}
