@import url('https://fonts.googleapis.com/css2?family=Orbitron:wght@600;800&family=Rajdhani:wght@500;700&display=swap');

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: 'Rajdhani', Arial, sans-serif;
  background: #090a10 url("feign.png") center/cover fixed;
  color: #f2f5ff;
  position: relative;
  min-height: 100vh;
  overflow-x: hidden;
}

/* 3D Ambient Background Layer */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  background: 
    radial-gradient(circle at 20% 20%, rgba(0, 243, 255, 0.12) 0%, transparent 40%),
    radial-gradient(circle at 80% 80%, rgba(189, 0, 255, 0.12) 0%, transparent 40%),
    linear-gradient(180deg, rgba(8, 10, 18, 0.82) 0%, rgba(13, 16, 28, 0.92) 100%);
  z-index: -1;
  pointer-events: none;
}

/* Cyber Grid Overlay */
body::after {
  content: "";
  position: fixed;
  inset: 0;
  background-image: 
    linear-gradient(rgba(0, 243, 255, 0.03) 1px, transparent 1px),
    linear-gradient(90deg, rgba(0, 243, 255, 0.03) 1px, transparent 1px);
  background-size: 40px 40px;
  z-index: -1;
  pointer-events: none;
}

.hidden {
  display: none !important;
}

/* 3D Container & Card Layouts */
.login {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 24px;
  perspective: 1000px;
}

.card {
  width: min(440px, 100%);
  background: rgba(16, 20, 36, 0.75);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid rgba(0, 243, 255, 0.35);
  border-radius: 20px;
  padding: 32px;
  box-shadow: 
    0 20px 50px rgba(0, 0, 0, 0.8),
    0 0 30px rgba(0, 243, 255, 0.2),
    inset 0 0 20px rgba(189, 0, 255, 0.15);
  transform-style: preserve-3d;
  transition: transform 0.4s ease, box-shadow 0.4s ease;
  position: relative;
}

.card:hover {
  transform: translateY(-6px) rotateX(2deg) rotateY(-1deg);
  box-shadow: 
    0 30px 60px rgba(0, 0, 0, 0.9),
    0 0 45px rgba(0, 243, 255, 0.35),
    inset 0 0 25px rgba(189, 0, 255, 0.25);
}

.logo-image {
  display: block;
  width: 100%;
  max-width: 320px;
  height: 150px;
  object-fit: cover;
  object-position: center;
  border-radius: 14px;
  margin: 0 auto 18px;
  border: 2px solid rgba(0, 243, 255, 0.6);
  box-shadow: 
    0 0 15px rgba(0, 243, 255, 0.4),
    0 8px 25px rgba(0, 0, 0, 0.6);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.logo-image:hover {
  transform: scale(1.02);
  box-shadow: 
    0 0 25px rgba(0, 243, 255, 0.7),
    0 0 40px rgba(189, 0, 255, 0.4);
}

h1, h2 {
  font-family: 'Orbitron', 'Rajdhani', sans-serif;
  margin: 12px 0;
  letter-spacing: 1px;
  text-transform: uppercase;
}

h1 {
  font-size: 24px;
  color: #ffffff;
  text-shadow: 
    0 0 10px rgba(0, 243, 255, 0.8),
    0 0 20px rgba(0, 243, 255, 0.5),
    0 0 30px rgba(189, 0, 255, 0.3);
  text-align: center;
}

p, small, label {
  color: #a6b4d0;
}

p {
  font-size: 15px;
  line-height: 1.4;
  text-align: center;
  margin-bottom: 20px;
}

label {
  display: block;
  margin-top: 16px;
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 0.5px;
  color: #00f3ff;
  text-shadow: 0 0 8px rgba(0, 243, 255, 0.4);
}

/* 3D Inputs */
input {
  width: 100%;
  padding: 14px 16px;
  border: 1.5px solid rgba(0, 243, 255, 0.25);
  border-radius: 12px;
  background: rgba(10, 14, 26, 0.85);
  color: #ffffff;
  font-size: 16px;
  font-family: inherit;
  margin-top: 8px;
  outline: none;
  box-shadow: inset 0 2px 6px rgba(0, 0, 0, 0.6);
  transition: all 0.3s ease;
}

input:focus {
  border-color: #00f3ff;
  background: rgba(14, 20, 38, 0.95);
  box-shadow: 
    0 0 15px rgba(0, 243, 255, 0.5),
    inset 0 0 10px rgba(0, 243, 255, 0.2);
}

/* 3D Neon Buttons */
button {
  border: 0;
  border-radius: 12px;
  padding: 14px 20px;
  margin-top: 16px;
  cursor: pointer;
  font-family: 'Orbitron', 'Rajdhani', sans-serif;
  font-weight: 700;
  font-size: 15px;
  letter-spacing: 1px;
  color: #ffffff;
  text-transform: uppercase;
  position: relative;
  overflow: hidden;
  transition: all 0.25s cubic-bezier(0.2, 0.8, 0.2, 1);
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.4);
}

button:hover {
  transform: translateY(-3px);
  filter: brightness(1.15);
}

button:active {
  transform: translateY(1px);
}

.primary {
  width: 100%;
  background: linear-gradient(135deg, #00d2ff 0%, #0066ff 100%);
  border: 1px solid rgba(0, 243, 255, 0.8);
  box-shadow: 
    0 6px 20px rgba(0, 102, 255, 0.4),
    0 0 15px rgba(0, 243, 255, 0.5);
}

.primary:hover {
  box-shadow: 
    0 8px 25px rgba(0, 102, 255, 0.6),
    0 0 25px rgba(0, 243, 255, 0.8);
}

.admin {
  width: 100%;
  background: linear-gradient(135deg, #b000ff 0%, #ff0077 100%);
  border: 1px solid rgba(255, 0, 200, 0.8);
  box-shadow: 
    0 6px 20px rgba(176, 0, 255, 0.4),
    0 0 15px rgba(255, 0, 200, 0.5);
}

.admin:hover {
  box-shadow: 
    0 8px 25px rgba(176, 0, 255, 0.6),
    0 0 25px rgba(255, 0, 200, 0.8);
}

.side-footer-actions {
  padding: 12px;
  display: flex;
  gap: 10px;
}

.note-btn {
  background: linear-gradient(135deg, #ffaa00 0%, #ff5500 100%);
  border: 1px solid rgba(255, 170, 0, 0.8);
  color: #000;
  flex: 1;
  margin: 0;
  padding: 10px 14px;
  font-weight: 800;
  box-shadow: 0 4px 15px rgba(255, 170, 0, 0.4);
}

.note-btn:hover {
  box-shadow: 0 6px 20px rgba(255, 170, 0, 0.6);
}

.side .danger {
  flex: 1;
  margin: 0;
  padding: 10px 14px;
}

small#conn {
  display: block;
  text-align: center;
  margin-top: 14px;
  font-size: 13px;
  color: #7d8bb2;
}

/* Room Layout */
.room {
  min-height: 100vh;
  display: flex;
  backdrop-filter: blur(10px);
}

.side {
  width: 320px;
  background: rgba(14, 18, 32, 0.85);
  backdrop-filter: blur(16px);
  border-right: 1px solid rgba(0, 243, 255, 0.25);
  display: flex;
  flex-direction: column;
  box-shadow: 10px 0 30px rgba(0, 0, 0, 0.5);
}

.user-lists {
  flex: 1;
  display: flex;
  flex-direction: column;
  overflow-y: auto;
  padding: 12px;
  gap: 16px;
}

.room-box {
  background: rgba(18, 24, 45, 0.6);
  border-radius: 16px;
  padding: 12px;
  display: flex;
  flex-direction: column;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.4);
  transition: all 0.3s ease;
}

.main-room-box {
  border: 1px solid rgba(0, 243, 255, 0.25);
  box-shadow: 0 0 15px rgba(0, 243, 255, 0.08);
}

.waiting-room-box {
  border: 1px solid rgba(255, 170, 0, 0.25);
  box-shadow: 0 0 15px rgba(255, 170, 0, 0.08);
  background: rgba(28, 22, 16, 0.5);
}

.room-box-header {
  margin-bottom: 10px;
  padding-bottom: 8px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.side h2 {
  padding: 2px 0;
  margin: 0;
  font-size: 15px;
  color: #00f3ff;
  text-shadow: 0 0 10px rgba(0, 243, 255, 0.5);
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-family: 'Orbitron', 'Rajdhani', sans-serif;
  letter-spacing: 0.5px;
}

.side h2.waiting-header {
  color: #ffaa00;
  text-shadow: 0 0 10px rgba(255, 170, 0, 0.5);
}

.side h2 span {
  background: linear-gradient(135deg, #00f3ff, #0066ff);
  color: #000;
  font-weight: 800;
  border-radius: 999px;
  padding: 2px 10px;
  font-size: 12px;
  box-shadow: 0 0 10px rgba(0, 243, 255, 0.6);
}

.side h2.waiting-header span {
  background: linear-gradient(135deg, #ffaa00, #ff5500);
  box-shadow: 0 0 10px rgba(255, 170, 0, 0.6);
}

#users, #waitingUsers {
  list-style: none;
  padding: 0;
  margin: 0;
}

.empty-msg {
  color: #64748b;
  font-size: 13px;
  font-style: italic;
  padding: 8px 12px;
}
  padding: 8px 12px;
}

.admin-row-waiting {
  border-color: rgba(255, 170, 0, 0.3) !important;
  background: rgba(40, 30, 10, 0.5) !important;
}

/* 3D Neon User Cards */
.user {
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding: 12px 14px;
  border-radius: 14px;
  margin-bottom: 10px;
  background: rgba(22, 28, 50, 0.7);
  border: 1px solid rgba(0, 243, 255, 0.15);
  box-shadow: 
    0 4px 15px rgba(0, 0, 0, 0.4),
    inset 0 0 10px rgba(0, 243, 255, 0.05);
  transition: all 0.3s ease;
}

.user-top {
  display: flex;
  align-items: center;
  gap: 12px;
}

.user-actions-row {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
  padding-top: 8px;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.user:hover {
  transform: translateX(4px) scale(1.01);
  background: rgba(30, 38, 68, 0.85);
  border-color: rgba(0, 243, 255, 0.4);
  box-shadow: 
    0 6px 20px rgba(0, 0, 0, 0.6),
    0 0 15px rgba(0, 243, 255, 0.3);
}

.avatar {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: linear-gradient(135deg, #1f2744, #121628);
  border: 2px solid rgba(0, 243, 255, 0.6);
  box-shadow: 0 0 10px rgba(0, 243, 255, 0.4);
  font-weight: 700;
  color: #00f3ff;
  font-size: 18px;
}

.u-meta {
  flex: 1;
  min-width: 0;
}

.u-name {
  font-weight: 700;
  font-size: 15px;
  color: #ffffff;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.u-role {
  font-size: 12px;
  color: #8f9fc2;
  margin-top: 2px;
}

.user-card-actions {
  display: none;
}

.btn-xs {
  padding: 4px 8px !important;
  font-size: 11px !important;
  border-radius: 6px !important;
  margin-top: 0 !important;
}

.user-audio-btn {
  background: rgba(0, 243, 255, 0.12);
  border: 1px solid rgba(0, 243, 255, 0.35);
  color: #00f3ff;
  padding: 4px 10px;
  font-size: 12px;
  border-radius: 8px;
  margin-top: 0;
  cursor: pointer;
  transition: all 0.2s ease;
  white-space: nowrap;
}

.user-audio-btn:hover {
  background: rgba(0, 243, 255, 0.25);
  box-shadow: 0 0 8px rgba(0, 243, 255, 0.5);
}

.user-audio-btn.is-muted {
  background: rgba(255, 69, 0, 0.2);
  border-color: rgba(255, 69, 0, 0.5);
  color: #ff5533;
}

.user-audio-btn.is-muted:hover {
  background: rgba(255, 69, 0, 0.4);
  box-shadow: 0 0 8px rgba(255, 69, 0, 0.5);
}

.muted-btn {
  background: linear-gradient(135deg, #ff3300, #990000) !important;
  box-shadow: 0 0 15px rgba(255, 51, 0, 0.6) !important;
}

.my-mute-btn {
  width: 100%;
  background: linear-gradient(135deg, #00d2ff, #0066ff);
  color: #fff;
  padding: 8px 14px;
  font-size: 13px;
  font-weight: 700;
  margin-top: 0;
  border-radius: 8px;
  box-shadow: 0 0 12px rgba(0, 210, 255, 0.5);
  cursor: pointer;
  transition: all 0.2s ease;
}

.my-mute-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 0 20px rgba(0, 210, 255, 0.8);
}

.my-mute-btn.is-muted {
  background: linear-gradient(135deg, #ff3300, #990000);
  box-shadow: 0 0 15px rgba(255, 51, 0, 0.6);
}

.join-main-btn {
  width: 100%;
  background: linear-gradient(135deg, #00ff88, #00b359);
  color: #000;
  padding: 8px 14px;
  font-size: 13px;
  font-weight: 800;
  margin-top: 0;
  border-radius: 8px;
  box-shadow: 0 0 12px rgba(0, 255, 136, 0.5);
  cursor: pointer;
  transition: all 0.2s ease;
}

.join-main-btn:hover:not(:disabled) {
  transform: translateY(-2px);
  box-shadow: 0 0 20px rgba(0, 255, 136, 0.8);
}

.join-main-btn:disabled {
  background: rgba(100, 116, 139, 0.3);
  color: #64748b;
  box-shadow: none;
  cursor: not-allowed;
}

/* Content Area */
.content {
  flex: 1;
  padding: 36px;
  overflow-y: auto;
}

.status {
  display: inline-block;
  padding: 12px 22px;
  border-radius: 999px;
  background: rgba(18, 24, 44, 0.8);
  border: 1px solid rgba(0, 243, 255, 0.4);
  color: #00f3ff;
  font-size: 16px;
  font-weight: 700;
  letter-spacing: 0.5px;
  box-shadow: 
    0 0 15px rgba(0, 243, 255, 0.3),
    inset 0 0 10px rgba(0, 243, 255, 0.15);
}

.controls {
  margin-top: 32px;
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
}

.controls button {
  width: auto;
  padding: 14px 26px;
}

#handBtn {
  background: linear-gradient(135deg, #ffaa00 0%, #ff6600 100%);
  border: 1px solid rgba(255, 170, 0, 0.8);
  box-shadow: 
    0 6px 20px rgba(255, 170, 0, 0.4),
    0 0 15px rgba(255, 170, 0, 0.5);
}

#handBtn:hover {
  box-shadow: 
    0 8px 25px rgba(255, 170, 0, 0.6),
    0 0 25px rgba(255, 170, 0, 0.8);
}

#muteBtn {
  background: linear-gradient(135deg, #00ff88 0%, #00b359 100%);
  border: 1px solid rgba(0, 255, 136, 0.8);
  color: #000;
  box-shadow: 
    0 6px 20px rgba(0, 255, 136, 0.4),
    0 0 15px rgba(0, 255, 136, 0.5);
}

/* 3D Admin Panel */
.panel {
  margin-top: 36px;
  background: rgba(16, 20, 36, 0.8);
  backdrop-filter: blur(16px);
  border: 1px solid rgba(189, 0, 255, 0.4);
  border-radius: 20px;
  padding: 24px;
  box-shadow: 
    0 15px 40px rgba(0, 0, 0, 0.7),
    0 0 25px rgba(189, 0, 255, 0.25),
    inset 0 0 15px rgba(189, 0, 255, 0.1);
}

.panel h2 {
  color: #ff00ea;
  text-shadow: 0 0 10px rgba(255, 0, 234, 0.6);
  margin-top: 0;
}

.panel-header-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
}

.panel-header-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

.panel-header-actions input {
  width: 180px;
  margin: 0;
  padding: 8px 10px;
  font-size: 13px;
}

.panel-header-actions .danger {
  width: auto;
  margin: 0;
  white-space: nowrap;
}

#clearLogsBtn {
  background: linear-gradient(135deg, #ff3344, #a80018) !important;
  border: 1px solid rgba(255, 70, 90, 0.9) !important;
  color: #fff !important;
  box-shadow: 0 0 12px rgba(255, 40, 65, 0.55) !important;
}

#clearLogsBtn:hover {
  background: linear-gradient(135deg, #ff5566, #cc0022) !important;
  box-shadow: 0 0 20px rgba(255, 40, 65, 0.8) !important;
}

.logs-container {
  max-height: 380px;
  overflow-y: auto;
  padding-right: 4px;
}

.logs-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.log-entry {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  padding: 11px 13px;
  background: rgba(26, 32, 58, 0.7);
  border: 1px solid rgba(0, 243, 255, 0.16);
  border-left: 4px solid #00f3ff;
  border-radius: 10px;
}

.log-leave {
  border-left-color: #ffaa00;
}

.log-kick,
.log-ban {
  border-left-color: #ff4500;
}

.log-entry-main {
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.log-entry-main b {
  color: #fff;
}

.log-action {
  color: #00f3ff;
  font-size: 13px;
  font-weight: 700;
}

.log-leave .log-action {
  color: #ffaa00;
}

.log-kick .log-action,
.log-ban .log-action {
  color: #ff7043;
}

.log-entry-main small {
  color: #a6b4d0;
}

.log-entry-meta {
  flex: 0 0 auto;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 3px;
  color: #8f9fc2;
  font-size: 12px;
}

.log-empty {
  padding: 20px;
  color: #64748b;
  text-align: center;
}

.admin-row {
  display: flex;
  align-items: center;
  gap: 12px;
  justify-content: space-between;
  background: rgba(26, 32, 58, 0.7);
  border: 1px solid rgba(189, 0, 255, 0.2);
  border-radius: 12px;
  padding: 12px 16px;
  margin-top: 12px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
  transition: all 0.25s ease;
  flex-wrap: wrap;
}

.admin-row:hover {
  background: rgba(34, 42, 74, 0.85);
  border-color: rgba(189, 0, 255, 0.4);
}

.admin-actions {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.move-waiting {
  background: linear-gradient(135deg, #00b4db, #0083b0);
  color: #fff;
  padding: 8px 14px;
  font-size: 13px;
  margin-top: 0;
  box-shadow: 0 0 10px rgba(0, 180, 219, 0.4);
}

.move-main {
  background: linear-gradient(135deg, #00ff88, #00b359);
  color: #000;
  padding: 8px 14px;
  font-size: 13px;
  margin-top: 0;
  box-shadow: 0 0 10px rgba(0, 255, 136, 0.4);
}

.user.waiting-user {
  opacity: 0.7;
  border-style: dashed;
}

.grant {
  background: linear-gradient(135deg, #00ff88, #00b359);
  color: #000;
  padding: 8px 14px;
  font-size: 13px;
  margin-top: 0;
  box-shadow: 0 0 10px rgba(0, 255, 136, 0.4);
}

.revoke {
  background: linear-gradient(135deg, #ffaa00, #ff7700);
  color: #000;
  padding: 8px 14px;
  font-size: 13px;
  margin-top: 0;
  box-shadow: 0 0 10px rgba(255, 170, 0, 0.4);
}

.kick {
  background: linear-gradient(135deg, #ff4500, #cc0000);
  padding: 8px 14px;
  font-size: 13px;
  margin-top: 0;
  box-shadow: 0 0 10px rgba(255, 69, 0, 0.4);
}

.ban {
  background: linear-gradient(135deg, #9b002b, #66001c);
  border: 1px solid rgba(255, 0, 85, 0.5);
  padding: 8px 14px;
  font-size: 13px;
  margin-top: 0;
  box-shadow: 0 0 10px rgba(155, 0, 43, 0.4);
}

.help {
  margin-top: 32px;
  color: #e2e8f0;
  background: rgba(14, 20, 36, 0.85);
  backdrop-filter: blur(16px);
  border: 1.5px solid rgba(0, 243, 255, 0.4);
  border-radius: 16px;
  padding: 20px 24px;
  max-width: 760px;
  box-shadow: 
    0 10px 30px rgba(0, 0, 0, 0.6),
    0 0 20px rgba(0, 243, 255, 0.25),
    inset 0 0 15px rgba(0, 243, 255, 0.1);
}

.help-title {
  font-family: 'Orbitron', 'Rajdhani', sans-serif;
  font-size: 16px;
  font-weight: 800;
  color: #ffaa00;
  text-shadow: 0 0 12px rgba(255, 170, 0, 0.6);
  letter-spacing: 1px;
  margin-bottom: 10px;
}

.help-body {
  font-size: 15px;
  line-height: 1.7;
  color: #cbd5e1;
}

.help-body b {
  color: #00f3ff;
  text-shadow: 0 0 8px rgba(0, 243, 255, 0.4);
}

/* 3D Glowing Toast Notification */
#toast {
  position: fixed;
  left: 50%;
  bottom: 28px;
  transform: translateX(-50%) translateY(100px);
  background: rgba(10, 14, 28, 0.95);
  backdrop-filter: blur(16px);
  color: #00f3ff;
  border: 1.5px solid rgba(0, 243, 255, 0.6);
  padding: 14px 24px;
  border-radius: 999px;
  font-weight: 700;
  font-size: 15px;
  letter-spacing: 0.5px;
  transition: transform 0.35s cubic-bezier(0.175, 0.885, 0.32, 1.275);
  z-index: 999;
  box-shadow: 
    0 15px 35px rgba(0, 0, 0, 0.8),
    0 0 20px rgba(0, 243, 255, 0.5);
}

#toast.show {
  transform: translateX(-50%) translateY(0);
}

audio {
  display: none;
}

@media(max-width: 760px) {
  .room {
    flex-direction: column;
  }
  .side {
    width: 100%;
    height: auto;
    max-height: 45vh;
    border-right: none;
    border-bottom: 1px solid rgba(0, 243, 255, 0.25);
  }
  .content {
    padding: 16px;
  }
  .card {
    padding: 22px;
  }
  h1 {
    font-size: 19px;
  }
  .controls {
    gap: 10px;
  }
  .controls button {
    flex: 1;
    padding: 12px 10px;
    font-size: 13px;
  }
  .panel {
    padding: 16px;
    margin-top: 24px;
  }
  .panel-header-row,
  .panel-header-actions {
    align-items: stretch;
    flex-direction: column;
  }
  .panel-header-actions input,
  .panel-header-actions .danger {
    width: 100%;
  }
  .log-entry {
    flex-direction: column;
    gap: 7px;
  }
  .log-entry-meta {
    align-items: flex-start;
  }
  .admin-row {
    flex-direction: column;
    align-items: stretch;
    gap: 10px;
  }
  .admin-actions {
    justify-content: flex-start;
  }
  .help {
    padding: 14px 16px;
    margin-top: 20px;
  }
  .status {
    font-size: 14px;
    padding: 10px 16px;
  }
  .logo-image {
    height: 110px;
  }
}

@media(max-width: 480px) {
  .user-actions-row {
    gap: 4px;
  }
  .btn-xs, .user-audio-btn, .my-mute-btn, .join-main-btn {
    font-size: 11px !important;
    padding: 5px 8px !important;
  }
  .avatar {
    width: 34px;
    height: 34px;
    font-size: 15px;
  }
  .u-name {
    font-size: 13px;
  }
  .u-role {
    font-size: 11px;
  }
}

/* Site Kurallari Modali */
.rules-overlay {
  position: fixed;
  inset: 0;
  z-index: 1200;
  background: rgba(5, 6, 12, 0.85);
  backdrop-filter: blur(6px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
}

.rules-modal {
  width: min(480px, 100%);
  background: rgba(16, 20, 36, 0.97);
  border: 1.5px solid rgba(0, 243, 255, 0.5);
  border-radius: 20px;
  padding: 28px;
  box-shadow:
    0 25px 60px rgba(0, 0, 0, 0.8),
    0 0 35px rgba(0, 243, 255, 0.3);
  max-height: 85vh;
  overflow-y: auto;
}

.rules-modal h2 {
  margin-top: 0;
  text-align: center;
  color: #00f3ff;
  text-shadow: 0 0 12px rgba(0, 243, 255, 0.6);
}

.rules-list {
  list-style: none;
  margin: 18px 0 6px;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.rules-list li {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 12px;
  padding: 12px 14px;
  color: #dbe4f5;
  font-size: 14px;
  line-height: 1.5;
}

.rules-modal .primary {
  margin-top: 20px;
}

@media(max-width: 480px) {
  .rules-modal {
    padding: 20px;
  }
  .rules-list li {
    font-size: 13px;
    padding: 10px 12px;
  }
}

/* ---- Admine Ozel Canli Sohbet Widget ---- */
.chat-widget {
  position: fixed;
  right: 20px;
  bottom: 20px;
  z-index: 999;
  width: 320px;
  font-family: 'Rajdhani', Arial, sans-serif;
}

.chat-header {
  background: linear-gradient(135deg, #00d2ff, #0066ff);
  color: #fff;
  font-weight: 800;
  padding: 12px 16px;
  border-radius: 12px;
  box-shadow: 0 0 20px rgba(0, 210, 255, 0.5);
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 8px;
  user-select: none;
}

.chat-badge {
  margin-left: auto;
  background: #ff3300;
  color: #fff;
  border-radius: 999px;
  min-width: 22px;
  height: 22px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  font-weight: 800;
  padding: 0 6px;
  box-shadow: 0 0 8px rgba(255, 51, 0, 0.7);
}

.chat-box {
  margin-top: 8px;
  background: rgba(13, 16, 28, 0.97);
  border: 1px solid rgba(0, 210, 255, 0.35);
  border-radius: 12px;
  box-shadow: 0 0 25px rgba(0, 0, 0, 0.6);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  max-height: 440px;
}

.chat-user-list {
  max-height: 160px;
  overflow-y: auto;
  border-bottom: 1px solid rgba(0, 210, 255, 0.25);
}

.chat-user-row {
  padding: 8px 12px;
  cursor: pointer;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
  transition: background 0.15s ease;
}

.chat-user-row:hover {
  background: rgba(0, 210, 255, 0.08);
}

.chat-user-row.active {
  background: rgba(0, 210, 255, 0.18);
}

.chat-user-row-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  color: #f2f5ff;
  font-size: 13px;
}

.chat-unread-dot {
  background: #ff3300;
  color: #fff;
  border-radius: 999px;
  min-width: 18px;
  height: 18px;
  font-size: 11px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 5px;
}

.chat-user-row-preview {
  color: #94a3b8;
  font-size: 12px;
  margin-top: 2px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.chat-thread {
  display: flex;
  flex-direction: column;
  flex: 1;
  min-height: 200px;
}

.chat-messages {
  flex: 1;
  overflow-y: auto;
  padding: 10px 12px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  max-height: 260px;
}

.chat-empty {
  color: #64748b;
  font-size: 13px;
  text-align: center;
  padding: 20px 8px;
}

.chat-msg {
  max-width: 80%;
  padding: 8px 10px;
  border-radius: 10px;
  font-size: 13px;
  line-height: 1.35;
}

.chat-msg-user {
  align-self: flex-start;
  background: rgba(255, 255, 255, 0.08);
  color: #f2f5ff;
  border-bottom-left-radius: 2px;
}

.chat-msg-admin {
  align-self: flex-end;
  background: linear-gradient(135deg, #00d2ff, #0066ff);
  color: #fff;
  border-bottom-right-radius: 2px;
}

.chat-msg-time {
  font-size: 10px;
  opacity: 0.65;
  margin-top: 2px;
  text-align: right;
}

.admin-inbox-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.admin-inbox-row {
  width: 100%;
  margin: 0;
  padding: 12px 14px;
  display: grid;
  grid-template-columns: minmax(130px, 0.7fr) minmax(180px, 1.5fr) auto;
  align-items: center;
  gap: 12px;
  text-align: left;
  color: #f2f5ff;
  background: rgba(22, 28, 50, 0.78);
  border: 1px solid rgba(0, 210, 255, 0.25);
  border-radius: 10px;
}

.admin-inbox-row:hover {
  transform: translateY(-1px);
  border-color: rgba(0, 210, 255, 0.65);
}

.admin-inbox-person {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.admin-inbox-person small,
.admin-inbox-time {
  color: #8f9fc2;
  font-size: 12px;
}

.admin-inbox-preview {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

@media (max-width: 640px) {
  .admin-inbox-row {
    grid-template-columns: 1fr auto;
  }
  .admin-inbox-preview {
    grid-column: 1 / -1;
  }
}

.chat-input-row {
  display: flex;
  gap: 6px;
  padding: 10px;
  border-top: 1px solid rgba(0, 210, 255, 0.25);
}

.chat-input-row input {
  flex: 1;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(0, 210, 255, 0.3);
  border-radius: 8px;
  padding: 8px 10px;
  color: #f2f5ff;
  font-size: 13px;
}

.chat-input-row input:focus {
  outline: none;
  border-color: #00d2ff;
}

.chat-input-row button {
  background: linear-gradient(135deg, #00d2ff, #0066ff);
  color: #fff;
  border: none;
  border-radius: 8px;
  padding: 8px 14px;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.2s ease;
}

.chat-input-row button:hover {
  transform: translateY(-1px);
  box-shadow: 0 0 12px rgba(0, 210, 255, 0.6);
}

@media (max-width: 640px) {
  .chat-widget {
    width: calc(100% - 24px);
    right: 12px;
    left: 12px;
    bottom: 12px;
  }
}

/* ---- Admin: Ayr� Ayr� A��l�r Sohbet Pencereleri (Messenger tarz�) ---- */
.chat-windows {
  position: fixed;
  right: 16px;
  bottom: 0;
  z-index: 999;
  display: flex;
  flex-direction: row-reverse;
  flex-wrap: wrap-reverse;
  align-items: flex-end;
  gap: 10px;
  max-width: calc(100% - 32px);
  pointer-events: none;
}

.chat-windows > * {
  pointer-events: auto;
}

.chat-window {
  width: 260px;
  background: rgba(13, 16, 28, 0.97);
  border: 1px solid rgba(0, 210, 255, 0.35);
  border-radius: 10px 10px 0 0;
  box-shadow: 0 0 20px rgba(0, 0, 0, 0.6);
  display: flex;
  flex-direction: column;
  max-height: 360px;
  overflow: hidden;
}

.chat-window-header {
  background: linear-gradient(135deg, #00d2ff, #0066ff);
  color: #fff;
  font-weight: 800;
  font-size: 13px;
  padding: 10px 12px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  cursor: pointer;
  user-select: none;
}

.chat-window-header-right {
  display: flex;
  align-items: center;
  gap: 6px;
}

.chat-close-btn {
  background: rgba(0, 0, 0, 0.25);
  border: none;
  color: #fff;
  border-radius: 6px;
  width: 22px;
  height: 22px;
  cursor: pointer;
  font-size: 12px;
  line-height: 1;
}

.chat-close-btn:hover {
  background: rgba(255, 51, 0, 0.6);
}

.chat-window-body {
  display: flex;
  flex-direction: column;
  flex: 1;
  min-height: 0;
}

.chat-window.minimized {
  max-height: none;
}

.chat-window-body.hidden {
  display: none;
}

.chat-window .chat-messages {
  flex: 1;
  overflow-y: auto;
  padding: 10px 12px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  max-height: 240px;
}

.chat-window .chat-input-row {
  display: flex;
  gap: 6px;
  padding: 8px;
  border-top: 1px solid rgba(0, 210, 255, 0.25);
}

.chat-window .chat-input-row input {
  flex: 1;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(0, 210, 255, 0.3);
  border-radius: 8px;
  padding: 6px 8px;
  color: #f2f5ff;
  font-size: 13px;
}

.chat-window .chat-input-row input:focus {
  outline: none;
  border-color: #00d2ff;
}

.chat-window .chat-input-row button {
  background: linear-gradient(135deg, #00d2ff, #0066ff);
  color: #fff;
  border: none;
  border-radius: 8px;
  padding: 6px 12px;
  font-weight: 700;
  cursor: pointer;
}

.chat-window .chat-input-row button:hover {
  transform: translateY(-1px);
}

@media (max-width: 640px) {
  .chat-window {
    width: 88vw;
  }
}

/* ---- Not Defteri Sistemi Stilleri ---- */
.note-panel {
  position: fixed;
  left: 335px;
  bottom: 20px;
  z-index: 1000;
  width: 360px;
  max-height: 560px;
  background: rgba(13, 16, 28, 0.97);
  border: 1.5px solid rgba(255, 170, 0, 0.5);
  border-radius: 16px;
  box-shadow: 0 15px 40px rgba(0, 0, 0, 0.8), 0 0 25px rgba(255, 170, 0, 0.25);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  font-family: 'Rajdhani', Arial, sans-serif;
}

.note-panel-header {
  background: linear-gradient(135deg, #ffaa00, #ff5500);
  color: #000;
  font-weight: 800;
  padding: 12px 16px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.note-panel-title {
  font-size: 15px;
  font-family: 'Orbitron', 'Rajdhani', sans-serif;
  letter-spacing: 0.5px;
}

.note-paper-selector {
  display: flex;
  gap: 6px;
  padding: 8px 12px;
  background: rgba(255, 255, 255, 0.04);
  border-bottom: 1px solid rgba(255, 170, 0, 0.2);
}

.paper-type-btn {
  flex: 1;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.15);
  color: #cbd5e1;
  padding: 6px 8px;
  font-size: 12px;
  font-weight: 700;
  border-radius: 8px;
  cursor: pointer;
  margin-top: 0;
  box-shadow: none;
  transition: all 0.2s ease;
  text-transform: none;
}

.paper-type-btn:hover {
  background: rgba(255, 170, 0, 0.2);
  color: #fff;
  transform: none;
}

.paper-type-btn.active {
  background: linear-gradient(135deg, #ffaa00, #ff6600);
  color: #000;
  border-color: #ffaa00;
  box-shadow: 0 0 10px rgba(255, 170, 0, 0.4);
}

.note-editor-box {
  padding: 12px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  border-bottom: 1px solid rgba(255, 170, 0, 0.2);
}

.note-title-input {
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 170, 0, 0.3);
  border-radius: 8px;
  padding: 8px 12px;
  color: #fff;
  font-size: 13px;
  font-weight: 700;
  margin-top: 0;
}

.note-textarea {
  width: 100%;
  border-radius: 10px;
  padding: 10px 14px;
  font-size: 14px;
  font-family: inherit;
  resize: vertical;
  min-height: 100px;
  outline: none;
  box-sizing: border-box;
  border: 1.5px solid rgba(255, 170, 0, 0.4);
  transition: border-color 0.2s ease;
}

.note-textarea:focus {
  border-color: #ffaa00;
  box-shadow: 0 0 10px rgba(255, 170, 0, 0.4);
}

/* Kagit Desen Stilleri */
.paper-lined {
  background-color: #fdfbf7 !important;
  background-image: linear-gradient(rgba(170, 185, 205, 0.6) 1px, transparent 1px) !important;
  background-size: 100% 28px !important;
  line-height: 28px !important;
  color: #1e293b !important;
  font-weight: 600;
}

.paper-grid {
  background-color: #fdfbf7 !important;
  background-image: 
    linear-gradient(rgba(170, 185, 205, 0.5) 1px, transparent 1px),
    linear-gradient(90deg, rgba(170, 185, 205, 0.5) 1px, transparent 1px) !important;
  background-size: 22px 24px !important;
  line-height: 24px !important;
  color: #1e293b !important;
  font-weight: 600;
}

.paper-plain {
  background-color: #fdfbf7 !important;
  color: #1e293b !important;
  line-height: 24px !important;
  font-weight: 600;
}

.note-editor-actions {
  display: flex;
  gap: 8px;
}

.btn-sm {
  padding: 8px 14px !important;
  font-size: 13px !important;
  margin-top: 0 !important;
}

.note-list-section {
  flex: 1;
  display: flex;
  flex-direction: column;
  min-height: 0;
  padding: 10px 12px;
  overflow: hidden;
}

.note-list-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  color: #ffaa00;
  font-weight: 800;
  font-size: 13px;
  margin-bottom: 8px;
  padding-bottom: 4px;
  border-bottom: 1px solid rgba(255, 170, 0, 0.2);
}

.notes-list {
  flex: 1;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding-right: 4px;
}

.note-card {
  border-radius: 10px;
  padding: 12px 14px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.4);
  border: 1px solid rgba(0, 0, 0, 0.15);
  display: flex;
  flex-direction: column;
  gap: 6px;
  transition: transform 0.2s ease;
}

.note-card:hover {
  transform: translateY(-2px);
}

.note-card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-bottom: 4px;
  border-bottom: 1px dashed rgba(0, 0, 0, 0.2);
}

.note-card-title-group {
  display: flex;
  align-items: center;
  gap: 8px;
}

.note-card-title {
  font-weight: 800;
  font-size: 14px;
  color: #0f172a;
}

.note-type-badge {
  background: rgba(0, 0, 0, 0.12);
  color: #475569;
  font-size: 11px;
  font-weight: 700;
  padding: 1px 6px;
  border-radius: 4px;
}

.note-card-actions {
  display: flex;
  gap: 4px;
}

.btn-icon {
  background: transparent;
  border: none;
  cursor: pointer;
  padding: 2px 6px;
  font-size: 14px;
  margin-top: 0;
  box-shadow: none;
  opacity: 0.8;
  transition: opacity 0.2s ease;
}

.btn-icon:hover {
  opacity: 1;
  transform: scale(1.15);
}

.note-card-content {
  font-size: 13px;
  word-break: break-word;
  white-space: pre-wrap;
}

.note-card-footer {
  font-size: 10px;
  color: #64748b;
  text-align: right;
  margin-top: 2px;
}

.note-empty {
  color: #64748b;
  font-size: 13px;
  text-align: center;
  padding: 20px 8px;
}

@media (max-width: 760px) {
  .note-panel {
    width: calc(100% - 24px);
    left: 12px;
    right: 12px;
    bottom: 20px;
    max-height: 80vh;
  }
}

/* Log temizleme butonu: diğer genel buton stillerinden sonra uygulanır. */
button#clearLogsBtn,
button#clearLogsBtn.btn-xs,
button#clearLogsBtn.danger {
  background: #c40020 !important;
  background-image: linear-gradient(135deg, #ff3344, #a80018) !important;
  border: 1px solid #ff5265 !important;
  color: #ffffff !important;
  box-shadow: 0 0 14px rgba(255, 40, 65, 0.65) !important;
}

button#clearLogsBtn:hover,
button#clearLogsBtn.btn-xs:hover,
button#clearLogsBtn.danger:hover {
  background: #e00028 !important;
  background-image: linear-gradient(135deg, #ff5566, #cc0022) !important;
  color: #ffffff !important;
  box-shadow: 0 0 22px rgba(255, 40, 65, 0.9) !important;
}

/* Sol menüdeki Not Defterim ve Çıkış butonları */
button.note-btn,
button.side-exit-btn,
.side-footer-actions button.danger {
  background: #c40020 !important;
  background-image: linear-gradient(135deg, #ff3344, #a80018) !important;
  border: 1px solid #ff5265 !important;
  color: #ffffff !important;
  box-shadow: 0 0 14px rgba(255, 40, 65, 0.65) !important;
}

button.note-btn:hover,
button.side-exit-btn:hover,
.side-footer-actions button.danger:hover {
  background: #e00028 !important;
  background-image: linear-gradient(135deg, #ff5566, #cc0022) !important;
  color: #ffffff !important;
  box-shadow: 0 0 22px rgba(255, 40, 65, 0.9) !important;
}
