* { box-sizing: border-box; }
body { margin: 0; font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif; background-color: #313338; color: #dbdee1; overflow: hidden; }
.app-container { display: flex; height: 100vh; width: 100vw; }
.sidebar { width: 260px; background-color: #2b2d31; display: flex; flex-direction: column; padding: 15px; border-right: 1px solid #1f2023; }
.sidebar h2 { color: #fff; font-size: 1.1rem; margin: 0 0 15px 0; border-bottom: 1px solid #1f2023; padding-bottom: 10px; }
.channel-list { flex: 1; overflow-y: auto; }
.channel-list h3, .members-sidebar h3 { color: #949ba4; font-size: 0.75rem; text-transform: uppercase; margin-top: 15px; margin-bottom: 8px; font-weight: 700; }
.channel-item { padding: 8px 10px; border-radius: 4px; cursor: pointer; margin-bottom: 4px; color: #949ba4; transition: background 0.15s, color 0.15s; }
.channel-item:hover { background-color: #35373c; color: #dbdee1; }
.channel-item.voice.active-voice { background-color: #23a55a; color: #ffffff; font-weight: 600; }
.user-footer { margin-top: auto; display: flex; align-items: center; gap: 8px; padding: 12px 15px; background-color: #232428; margin: -15px; margin-top: auto; }
.user-name { font-weight: 600; color: #f2f3f5; font-size: 0.9rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 90px; }
.chat-area { flex: 1; display: flex; flex-direction: column; background-color: #313338; }
.channel-header { height: 48px; border-bottom: 1px solid #1f2023; display: flex; align-items: center; padding-left: 20px; font-weight: bold; color: #fff; }
.messages-container { flex: 1; padding: 20px; overflow-y: auto; display: flex; flex-direction: column; gap: 16px; }
.message-card { display: flex; gap: 14px; align-items: flex-start; }
.avatar { width: 40px; height: 40px; border-radius: 50%; object-fit: cover; flex-shrink: 0; }
.avatar-sm { width: 28px; height: 28px; border-radius: 50%; object-fit: cover; flex-shrink: 0; }
.msg-content h4 { margin: 0 0 4px 0; font-size: 0.95rem; color: #f2f3f5; display: flex; align-items: center; gap: 4px; }
.msg-content p { margin: 0; color: #dbdee1; font-size: 0.95rem; word-break: break-word; }
.timestamp { font-size: 0.75rem; color: #949ba4; font-weight: 400; margin-left: 6px; }
.verified-coche { display: inline-flex; align-items: center; justify-content: center; width: 18px; height: 18px; margin-left: 4px; position: relative; cursor: pointer; }
.verified-coche svg { width: 100%; height: 100%; fill: #5865f2; filter: drop-shadow(0px 0px 4px rgba(88, 101, 242, 0.6)); }
.verified-coche::after { content: attr(data-tooltip); position: absolute; bottom: 125%; left: 50%; transform: translateX(-50%) translateY(5px); background-color: #111214; color: #f2f3f5; padding: 6px 10px; border-radius: 6px; font-size: 0.72rem; font-weight: 600; white-space: nowrap; pointer-events: none; opacity: 0; box-shadow: 0 4px 12px rgba(0,0,0,0.4); border: 1px solid #35373c; transition: opacity 0.2s; z-index: 1000; }
.verified-coche:hover::after { opacity: 1; transform: translateX(-50%) translateY(0); }
.chat-input-box { padding: 0 20px 20px 20px; display: flex; gap: 10px; }
.chat-input-box input { flex: 1; padding: 12px 16px; border-radius: 8px; border: none; background-color: #383a40; color: #f2f3f5; font-size: 1rem; outline: none; }
.chat-input-box button { padding: 0 20px; border-radius: 8px; border: none; background-color: #5865f2; color: white; font-weight: 600; cursor: pointer; }
.members-sidebar { width: 240px; background-color: #2b2d31; border-left: 1px solid #1f2023; padding: 15px; display: flex; flex-direction: column; }
.member-list { display: flex; flex-direction: column; gap: 4px; overflow-y: auto; }
.member-item { display: flex; align-items: center; gap: 8px; padding: 6px 8px; border-radius: 4px; }
.member-name { color: #dbdee1; font-size: 0.9rem; font-weight: 500; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.role-badge.admin { background-color: #ed4245; color: white; font-size: 0.6rem; padding: 1px 4px; border-radius: 3px; font-weight: 700; margin-left: auto; }
.admin-btn { background-color: #ed4245; color: #fff; padding: 4px 8px; border-radius: 4px; font-size: 0.75rem; font-weight: bold; text-decoration: none; margin-left: auto; }
.logout-btn { background-color: #4e5058; color: #fff; padding: 4px 8px; border-radius: 4px; font-size: 0.75rem; text-decoration: none; margin-left: 4px; }
.auth-body { display: flex; justify-content: center; align-items: center; height: 100vh; background-color: #1e1f22; }
.auth-card { background-color: #313338; padding: 30px; border-radius: 8px; width: 360px; box-shadow: 0 8px 24px rgba(0,0,0,0.4); text-align: center; }
.auth-card h2 { color: #fff; font-size: 1.3rem; margin-bottom: 20px; }
.auth-card input { width: 100%; padding: 10px 12px; margin-bottom: 12px; border-radius: 4px; border: none; background-color: #1e1f22; color: #fff; box-sizing: border-box; }
.auth-card button { width: 100%; padding: 10px; border-radius: 4px; border: none; background-color: #5865f2; color: white; font-weight: bold; cursor: pointer; }
.admin-container { padding: 40px; max-width: 900px; margin: 0 auto; }
.admin-table { width: 100%; border-collapse: collapse; margin-top: 20px; background-color: #2b2d31; border-radius: 8px; overflow: hidden; }
.admin-table th, .admin-table td { padding: 12px 15px; text-align: left; border-bottom: 1px solid #3f4147; }
.admin-table th { background-color: #1e1f22; color: #fff; }
.verify-toggle-btn { background-color: #248046; color: white; border: none; padding: 6px 12px; border-radius: 4px; cursor: pointer; }
.admin-toggle-btn { background-color: #5865f2; color: white; border: none; padding: 6px 12px; border-radius: 4px; cursor: pointer; }
.back-link { color: #00a8fc; text-decoration: none; }
@keyframes fadeIn { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: translateY(0); } }
.animate-fade { animation: fadeIn 0.25s cubic-bezier(0.16, 1, 0.3, 1) forwards; }