@import url('https://fonts.googleapis.com/css2?family=Fredoka:wght@400;500;600;700&family=Merriweather:wght@400;700&family=Montserrat:wght@400;500;600;700&family=Nunito:wght@400;600;700&family=Roboto+Slab:wght@400;700&family=Space+Grotesk:wght@400;500;700&display=swap');
:root {
  --bg-primary: #0b0f19;
  --bg-secondary: #111827;
  --bg-tertiary: #1f2937;
  --accent-primary: #2563eb;
  --accent-hover: #3b82f6;
  --accent-subtle: rgba(37, 99, 235, 0.15);
  --text-primary: #f9fafb;
  --text-secondary: #9ca3af;
  --border-color: #1f2937;
  --danger: #ef4444;
  --card-radius: 12px;
  --max-width: 1200px;
}

*, *::before, *::after, input, button, textarea, select, a {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  font-family: var(--app-font-family, 'Montserrat', -apple-system, BlinkMacSystemFont, sans-serif) !important;
}

body {
  background-color: var(--bg-primary);
  color: var(--text-primary);
  line-height: 1.5;
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
}

a, a:visited {
  color: var(--accent-hover);
  text-decoration: none;
}

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

.app-header {
  height: 60px;
  background-color: var(--bg-secondary);
  border-bottom: 1px solid var(--border-color);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 24px;
  position: sticky;
  top: 0;
  z-index: 50;
}

.app-brand a {
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--accent-hover) !important;
}

.app-layout {
  display: flex;
  width: 100%;
  max-width: var(--max-width);
  margin: 0 auto;
  min-height: calc(100vh - 60px);
}

.sidebar {
  width: 220px;
  min-width: 220px;
  padding: 20px 12px;
  border-right: 1px solid var(--border-color);
  display: flex;
  flex-direction: column;
  gap: 8px;
  background-color: var(--bg-primary);
  flex-shrink: 0;
}

.nav-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 16px;
  color: var(--text-secondary) !important;
  font-weight: 600;
  font-size: 0.95rem;
  border-radius: 8px;
  transition: all 0.2s ease;
}

.nav-item:hover, .nav-item.active {
  background-color: var(--accent-subtle);
  color: var(--accent-hover) !important;
}

.main-content {
  flex: 1;
  min-width: 0;
  border-right: 1px solid var(--border-color);
  padding: 24px;
}

.right-panel {
  width: 300px;
  min-width: 300px;
  padding: 24px;
  display: flex;
  flex-direction: column;
  gap: 20px;
  flex-shrink: 0;
}

.post-card, .profile-card {
  background-color: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: var(--card-radius);
  padding: 20px;
  margin-bottom: 16px;
  width: 100%;
}

.post-card {
  animation: postAppear 0.5s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

.post-card-theme-midnight { background: #111827; border-color: #334155; }
.post-card-theme-paper { background: #f5f1e8; border-color: #c9bda8; color: #292524; }
.post-card-theme-paper .post-body, .post-card-theme-paper .display-name { color: #292524; }
.post-card-theme-synthwave { background: #211536; border-color: #c026d3; }
.post-card-theme-forest { background: #10251d; border-color: #3f8f68; }

.profile-card-glass .profile-card, .profile-card-glass .profile-widget { background: color-mix(in srgb, var(--bg-secondary) 62%, transparent); backdrop-filter: blur(14px); }
.profile-card-neon .profile-card, .profile-card-neon .profile-widget { border-color: var(--profile-accent); box-shadow: 0 0 18px color-mix(in srgb, var(--profile-accent) 45%, transparent); }
.profile-card-minimal .profile-card, .profile-card-minimal .profile-widget { border-width: 0 0 1px; border-radius: 0; background: transparent; box-shadow: none; }
.profile-card-gradient .profile-card, .profile-card-gradient .profile-widget { background: linear-gradient(135deg, color-mix(in srgb, var(--profile-accent) 22%, var(--bg-secondary)), var(--bg-secondary)); }

.profile-effect-particle { position: absolute; width: 7px; height: 7px; top: -12px; opacity: calc(.25 + var(--effect-intensity) * .25); animation: profile-particle-fall calc(5s + var(--particle-index, 1) * .12s) linear infinite; background: var(--profile-accent); }
.profile-bg-effect[data-effect="stars"] .profile-effect-particle, .profile-bg-effect[data-effect="sparkles"] .profile-effect-particle { box-shadow: 0 0 12px var(--profile-accent); border-radius: 50%; }
.profile-bg-effect[data-effect="snow"] .profile-effect-particle { border-radius: 50%; background: #fff; }
.profile-bg-effect[data-effect="bubbles"] .profile-effect-particle { border-radius: 50%; background: transparent; border: 2px solid var(--profile-accent); }
.profile-bg-effect[data-effect="aurora"] { background: linear-gradient(120deg, transparent, color-mix(in srgb, var(--profile-accent) 25%, transparent), transparent); animation: profile-aurora 7s ease-in-out infinite alternate; }
@keyframes profile-particle-fall { to { transform: translateY(110vh) rotate(180deg); } }
@keyframes profile-aurora { from { opacity: .3; transform: translateX(-12%); } to { opacity: .8; transform: translateX(12%); } }

.customization-editor-section { margin-top: 22px; padding-top: 18px; border-top: 1px solid var(--border-color); }
.customization-editor-section h3 { margin-bottom: 6px; }
.customization-actions { display: flex; flex-wrap: wrap; gap: 10px; }
.userboxes-settings-list { display: flex; flex-direction: column; gap: 8px; margin-top: 14px; }
.settings-userbox-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 10px 12px; border: 1px solid var(--border-color); border-radius: 8px; background: var(--bg-primary); }

.google-font-browser {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 8px;
  margin-top: 10px;
}

.font-choice {
  min-height: 72px;
  padding: 10px 12px;
  border: 1px solid var(--border-color);
  border-radius: 8px;
  background: var(--bg-primary);
  color: var(--text-primary);
  cursor: pointer;
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  flex-direction: column;
  gap: 8px;
  text-align: left;
  transition: border-color .18s ease, background-color .18s ease, color .18s ease, transform .18s ease;
}
.font-choice:hover { transform: translateY(-2px); }
.font-choice-name { font-size: .82rem; font-weight: 700; }
.font-choice-preview { font-size: 1.25rem; line-height: 1; opacity: .86; letter-spacing: -.04em; }

.font-choice:hover, .font-choice.active {
  border-color: var(--accent-hover);
  background: var(--accent-subtle);
  color: var(--accent-hover);
}

@keyframes postAppear {
  from {
    opacity: 0;
    transform: translateY(25px) scale(0.98);
    filter: blur(3px);
  }

  to {
    opacity: 1;
    transform: translateY(0) scale(1);
    filter: blur(0);
  }
}

.post-header, .profile-header {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 12px;
}

.avatar {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  object-fit: cover;
  background-color: var(--bg-tertiary);
  border: 1px solid var(--border-color);
}

.avatar-lg {
  width: 72px;
  height: 72px;
}

.post-user-info {
  display: flex;
  flex-direction: column;
  flex: 1;
}

.display-name {
  font-weight: 700;
  color: var(--text-primary);
}

.username-handle {
  font-size: 0.85rem;
  color: var(--text-secondary);
}

.post-time {
  font-size: 0.75rem;
  color: var(--text-secondary);
}

.post-body {
  color: var(--text-primary);
  font-size: 0.95rem;
  white-space: pre-wrap;
  word-break: break-word;
}

.empty-state {
  padding: 32px;
  text-align: center;
  color: var(--text-secondary);
  background-color: var(--bg-secondary);
  border-radius: var(--card-radius);
  border: 1px dashed var(--border-color);
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-bottom: 16px;
}

.form-group label {
  font-size: 0.85rem;
  color: var(--text-secondary);
  font-weight: 600;
}

.form-control, input[type="text"], input[type="password"], textarea, select {
  width: 100%;
  background-color: var(--bg-primary);
  border: 1px solid var(--border-color);
  color: var(--text-primary);
  padding: 10px 14px;
  border-radius: 8px;
  outline: none;
  transition: border-color 0.2s ease;
}

.form-control:focus, input:focus, textarea:focus, select:focus {
  border-color: var(--accent-hover);
}

.btn {
  width: fit-content;
  font-weight: 600;
  background-color: var(--accent-primary);
  color: #ffffff !important;
  border: none;
  padding: 10px 20px;
  border-radius: 8px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  cursor: pointer;
  transition: all 0.2s ease;
}

.btn:hover {
  background-color: var(--accent-hover);
}

.btn-secondary {
  background-color: var(--bg-tertiary);
  color: var(--text-primary) !important;
}

.auth-container {
  max-width: 400px;
  margin: 60px auto;
  padding: 32px;
  background-color: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: var(--card-radius);
}

.auth-header {
  text-align: center;
  margin-bottom: 24px;
}

.auth-header h1 {
  color: var(--accent-hover);
  margin-bottom: 6px;
}

.fab {
  position: fixed;
  bottom: 24px;
  right: 24px;
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background-color: var(--accent-primary);
  color: white;
  font-size: 28px;
  border: none;
  box-shadow: 0 4px 16px rgba(0,0,0,0.4);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform 0.2s ease, background-color 0.2s ease;
  z-index: 100;
}

.fab:hover {
  background-color: var(--accent-hover);
  transform: scale(1.08);
}

.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background-color: rgba(11, 15, 25, 0.75);
  backdrop-filter: blur(6px);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.25s ease, visibility 0.25s ease;
  z-index: 1000;
}

.modal-overlay.open {
  opacity: 1;
  visibility: visible;
}

.modal-card {
  background-color: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: var(--card-radius);
  width: 90%;
  max-width: 520px;
  padding: 24px;
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.6);
  transform: translateY(20px) scale(0.95);
  transition: transform 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

.modal-overlay.open .modal-card {
  transform: translateY(0) scale(1);
}

.modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 16px;
}

.modal-header h3 {
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--text-primary);
}

.close-btn {
  background: transparent !important;
  border: none;
  font-size: 1.5rem;
  color: var(--text-secondary) !important;
  cursor: pointer;
  padding: 0 4px;
}

#modal-content {
  width: 100%;
  height: 120px;
  margin-bottom: 16px;
  resize: none;
}

.modal-footer {
  display: flex;
  justify-content: flex-end;
}

/* ===== COMPOSER ===== */

.modal-post-card {
  max-width: 580px;
  width: 100%;
  padding: 0;
  border-radius: 24px;
  overflow: visible;
  background: #0b1220;
  border: 1px solid rgba(255,255,255,.09);
  box-shadow:
    0 30px 80px rgba(0,0,0,.55),
    0 0 0 1px rgba(255,255,255,.04) inset;
}

.composer-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px 20px 14px;
  border-bottom: 1px solid rgba(255,255,255,.06);
}

.composer-header-left {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
}

.composer-avatar {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  object-fit: cover;
  flex-shrink: 0;
  border: 2px solid rgba(255,255,255,.1);
}

.composer-user-info {
  display: flex;
  flex-direction: column;
  gap: 4px;
  min-width: 0;
}

.composer-display-name {
  font-size: .9rem;
  font-weight: 700;
  color: var(--text-primary);
  line-height: 1;
}

.composer-header .node-selector {
  margin: 0;
}

.composer-header .node-selector-button {
  width: auto;
  padding: 4px 10px;
  border-radius: 999px;
  font-size: .75rem;
  font-weight: 600;
  background: rgba(255,255,255,.06);
  border: 1px solid rgba(255,255,255,.09);
  gap: 5px;
  min-height: 0;
}

.composer-header .node-selector-button:hover {
  background: rgba(59,130,246,.15);
  border-color: rgba(59,130,246,.3);
}

.composer-header .node-selector-button svg {
  width: 13px;
  height: 13px;
}

.composer-close-btn {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  border: 1px solid rgba(255,255,255,.08);
  background: rgba(255,255,255,.04);
  color: var(--text-secondary);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  flex-shrink: 0;
  transition: background .18s ease, color .18s ease, transform .18s ease;
}

.composer-close-btn:hover {
  background: rgba(239,68,68,.15);
  border-color: rgba(239,68,68,.25);
  color: #ef4444;
  transform: rotate(90deg);
}

.composer-close-btn svg {
  width: 16px;
  height: 16px;
}

.composer-body {
  position: relative;
  padding: 4px 20px 8px;
}

.composer-drop-overlay {
  position: absolute;
  inset: 8px;
  border-radius: 16px;
  border: 2px dashed rgba(59,130,246,.5);
  background: rgba(37,99,235,.08);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 10px;
  color: var(--accent-hover);
  font-weight: 600;
  font-size: .9rem;
  opacity: 0;
  pointer-events: none;
  transition: opacity .18s ease;
  z-index: 10;
}

.composer-drop-overlay.active {
  opacity: 1;
}

.composer-drop-overlay svg {
  width: 32px;
  height: 32px;
}

.composer-textarea {
  width: 100%;
  min-height: 130px;
  max-height: 280px;
  background: transparent;
  border: none;
  outline: none;
  color: var(--text-primary);
  font-size: 1rem;
  line-height: 1.65;
  resize: none;
  padding: 12px 0;
  font-family: inherit;
}

.composer-textarea::placeholder {
  color: rgba(255,255,255,.28);
}

.composer-media-preview {
  margin: 4px 0 8px;
  padding: 12px;
  border-radius: 14px;
  background: rgba(255,255,255,.04);
  border: 1px solid rgba(255,255,255,.07);
}

.composer-media-preview.hidden {
  display: none;
}

/* Poll builder */
.poll-builder-header {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 12px;
  color: var(--accent-hover);
  font-weight: 700;
  font-size: .88rem;
}

.poll-builder-header svg {
  width: 16px;
  height: 16px;
}

.composer-pill-close {
  margin-left: auto;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  border: none;
  background: rgba(255,255,255,.07);
  color: var(--text-secondary);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: background .15s ease;
}

.composer-pill-close:hover {
  background: rgba(239,68,68,.18);
  color: #ef4444;
}

.composer-pill-close svg {
  width: 13px;
  height: 13px;
}

.composer-poll-input {
  width: 100%;
  background: rgba(255,255,255,.05);
  border: 1px solid rgba(255,255,255,.09);
  border-radius: 12px;
  color: var(--text-primary);
  padding: 10px 14px;
  font-size: .9rem;
  font-family: inherit;
  outline: none;
  margin-bottom: 10px;
  transition: border-color .18s ease;
}

.composer-poll-input:focus {
  border-color: rgba(59,130,246,.45);
}

#poll-options-list .poll-option-input {
  background: rgba(255,255,255,.04);
  border: 1px solid rgba(255,255,255,.07);
  border-radius: 10px;
  margin-bottom: 8px;
}

.composer-add-option-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 7px 12px;
  border-radius: 999px;
  border: 1px dashed rgba(255,255,255,.15);
  background: transparent;
  color: var(--text-secondary);
  font-size: .8rem;
  font-weight: 600;
  cursor: pointer;
  transition: border-color .18s ease, color .18s ease, background .18s ease;
  font-family: inherit;
}

.composer-add-option-btn:hover {
  border-color: rgba(59,130,246,.4);
  color: var(--accent-hover);
  background: rgba(37,99,235,.08);
}

.composer-add-option-btn svg {
  width: 14px;
  height: 14px;
}

.composer-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 20px 16px;
  border-top: 1px solid rgba(255,255,255,.06);
  gap: 12px;
}

.composer-tools {
  display: flex;
  align-items: center;
  gap: 4px;
}

.composer-tool-btn {
  width: 36px;
  height: 36px;
  border-radius: 10px;
  border: none;
  background: transparent;
  color: var(--text-secondary);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: background .18s ease, color .18s ease, transform .15s ease;
}

.composer-tool-btn:hover {
  background: rgba(59,130,246,.12);
  color: var(--accent-hover);
  transform: translateY(-1px);
}

.composer-tool-btn:active {
  transform: scale(.92);
}

.composer-tool-btn svg {
  width: 18px;
  height: 18px;
}

.composer-footer-right {
  display: flex;
  align-items: center;
  gap: 12px;
}

.composer-char-wrap {
  position: relative;
  width: 28px;
  height: 28px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.composer-char-ring {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

.composer-char-ring-bg {
  fill: none;
  stroke: rgba(255,255,255,.1);
  stroke-width: 3;
}

.composer-char-ring-fill {
  fill: none;
  stroke: #3b82f6;
  stroke-width: 3;
  stroke-linecap: round;
  transition: stroke-dashoffset .2s ease, stroke .2s ease;
}

.composer-char-count {
  position: relative;
  font-size: .6rem;
  font-weight: 700;
  color: var(--text-secondary);
  display: none;
  line-height: 1;
}

.composer-submit-btn {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 9px 18px;
  border-radius: 999px;
  border: none;
  background: linear-gradient(135deg, #60a5fa, #2563eb);
  color: #fff;
  font-size: .88rem;
  font-weight: 700;
  cursor: pointer;
  box-shadow: 0 6px 18px rgba(37,99,235,.3);
  transition: filter .18s ease, transform .18s ease, box-shadow .18s ease;
  font-family: inherit;
}

.composer-submit-btn:hover {
  filter: brightness(1.08);
  transform: translateY(-1px);
  box-shadow: 0 8px 22px rgba(37,99,235,.4);
}

.composer-submit-btn:active {
  transform: scale(.96);
}

.composer-submit-btn svg {
  width: 15px;
  height: 15px;
}

@media (max-width: 600px) {
  .modal-post-card {
    border-radius: 20px 20px 12px 12px;
  }

  .composer-textarea {
    min-height: 100px;
    font-size: .95rem;
  }

  .composer-tool-btn {
    width: 32px;
    height: 32px;
  }
}

@media (max-width: 992px) {
  .right-panel {
    display: none;
  }
}

@media (max-width: 768px) {
  .app-layout {
    flex-direction: column;
  }

  .sidebar {
    width: 100%;
    border-right: none;
    border-bottom: 1px solid var(--border-color);
    flex-direction: row;
    overflow-x: auto;
    padding: 8px 12px;
  }

  .main-content {
    border-right: none;
    padding: 16px;
  }
}

.nav-item svg, .fab svg {
  width: 20px;
  height: 20px;
  stroke-width: 2;
  flex-shrink: 0;
}

.fab svg {
  width: 26px;
  height: 26px;
}

.post-actions {
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: 8px;
}

.icon-btn {
  background: transparent;
  border: none;
  color: var(--text-secondary);
  cursor: pointer;
  display: flex;
  align-items: center;
}

.icon-btn:hover {
  color: var(--danger);
}

.icon-btn svg {
  width: 18px;
  height: 18px;
}

.post-actions {
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: 8px;
}

.post-time {
  order: 2;
}

.report-btn {
  order: 1;
  width: 28px;
  height: 28px;
  padding: 0;
  border-radius: 50%;
  border: 1px solid var(--border-color);
  background: transparent;
  color: var(--text-secondary);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
}

.report-btn svg {
  width: 15px;
  height: 15px;
}

.report-btn:hover {
  color: var(--danger);
  border-color: var(--danger);
}

.post-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-left: auto;
}

.report-icon {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  border: none;
  background: transparent;
  color: var(--text-secondary);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
}

.report-icon:hover {
  background: var(--accent-subtle);
  color: var(--danger);
}

.report-icon svg {
  width: 16px;
  height: 16px;
}

#report-modal .modal-card {
  width: 90%;
  max-width: 520px;
  min-height: 280px;
}

#report-content {
  min-height: 160px;
  resize: vertical;
}

.post-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-left: auto;
}

.report-icon {
  width: 30px;
  height: 30px;
  padding: 0;
  border-radius: 50%;
  border: 0;
  background: transparent;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  color: var(--text-secondary);
}

.report-icon:hover {
  color: var(--danger);
  background: var(--accent-subtle);
}

.report-icon svg {
  width: 16px;
  height: 16px;
}

.icon-action {
  appearance: none;
  -webkit-appearance: none;
  border: 1px solid var(--border-color) !important;
  outline: none;
  padding: 0;
  background: var(--bg-primary) !important;
  color: var(--text-secondary) !important;
}

.icon-action:focus, .icon-action:active {
  outline: none;
  box-shadow: none;
}

.icon-action svg {
  pointer-events: none;
}

.icon-action.liked {
  color: #3b82f6 !important;
  background: rgba(37, 99, 235, 0.15) !important;
  border-color: rgba(59, 130, 246, 0.3) !important;
}

.icon-action.liked svg {
  fill: #3b82f6 !important;
  stroke: #3b82f6;
}

.icon-action.disliked svg {
  fill: #ef4444 !important;
  stroke: #ef4444;
}

.icon-action.disliked svg {
  fill: #ef4444;
}

/* Reaction animation */
@keyframes reactionPop {
  0%   { transform: scale(1);    filter: brightness(1); }
  20%  { transform: scale(1.22); filter: brightness(1.4); }
  50%  { transform: scale(0.94); filter: brightness(1.1); }
  75%  { transform: scale(1.08); filter: brightness(1.2); }
  100% { transform: scale(1);    filter: brightness(1); }
}

@keyframes reactionRipple {
  0%   { box-shadow: 0 0 0 0px rgba(59, 130, 246, 0.35); }
  100% { box-shadow: 0 0 0 10px rgba(59, 130, 246, 0); }
}

@keyframes reactionRippleRed {
  0%   { box-shadow: 0 0 0 0px rgba(239, 68, 68, 0.35); }
  100% { box-shadow: 0 0 0 10px rgba(239, 68, 68, 0); }
}

.icon-action.reaction-pop {
  animation:
    reactionPop 0.45s cubic-bezier(.16, 1, .3, 1),
    reactionRipple 0.5s ease-out;
}

.icon-action.disliked.reaction-pop {
  animation:
    reactionPop 0.45s cubic-bezier(.16, 1, .3, 1),
    reactionRippleRed 0.5s ease-out;
}

.post-footer {
  display: flex;
  gap: 18px;
  margin-top: 16px;
  padding-top: 12px;
  border-top: 1px solid var(--border-color);
}

.icon-action {
  appearance: none;
  -webkit-appearance: none;
  width: auto;
  min-width: 42px;
  height: 36px;
  border: none !important;
  padding: 0 10px;
  background: transparent !important;
  color: var(--text-secondary) !important;
  border-radius: 999px;
  display: flex;
  gap: 6px;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: background-color .2s ease, color .2s ease;
}

.icon-action:hover {
  background: var(--accent-subtle) !important;
  color: var(--accent-hover) !important;
}

.engagement-count {
  min-width: 1.25em;
  margin-left: 0;
  text-align: center;
  font-size: .78rem;
  line-height: 1;
}

.moderation-tabs .btn.active {
  background: var(--accent-primary);
  border-color: var(--accent-primary);
  color: #fff;
}

.icon-action svg {
  width: 20px;
  height: 20px;
}

.node-selector {
  position: relative;
  margin-bottom: 12px;
}

.node-selector-button {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 9px 14px;
  background: var(--bg-tertiary);
  color: var(--text-primary);
  border: 1px solid var(--border-color);
  border-radius: 10px;
  cursor: pointer;
  font-weight: 600;
  font-size: 0.85rem;
  transition: .2s ease;
}

.node-selector-button:hover {
  background: var(--accent-subtle);
  border-color: var(--accent-hover);
}

.node-dropdown {
  position: absolute;
  top: calc(100% + 8px);
  left: 0;
  width: 240px;
  max-height: 260px;
  overflow-y: auto;
  padding: 8px;
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  box-shadow: 0 20px 40px rgba(0,0,0,.45);
  display: none;
  z-index: 9999;
}

.node-dropdown.open {
  display: block;
}

.node-option {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  border-radius: 8px;
  color: var(--text-primary);
  cursor: pointer;
  transition: .15s ease;
}

.node-option:hover {
  background: var(--accent-subtle);
}

.node-option small {
  margin-left: auto;
  color: var(--text-secondary);
  font-size: .75rem;
}

.node-option.disabled {
  opacity: .45;
  cursor: not-allowed;
}

.modal-post-card {
  max-width: 620px;
  width: 100%;
  border-radius: 22px;
  overflow: hidden;
  background: #0b1220;
  border: 1px solid rgba(255,255,255,.08);
  box-shadow: 0 18px 45px rgba(0,0,0,.45);
}

.post-textarea {
  width: 100%;
  min-height: 150px;
  background: #08111d;
  border: 1px solid rgba(255,255,255,.08);
  color: var(--text-primary);
  border-radius: 16px;
  padding: 16px;
  font-size: 1rem;
  line-height: 1.65;
  resize: vertical;
  transition: border-color .18s ease, box-shadow .18s ease, background .18s ease;
}

.post-textarea::placeholder {
  color: rgba(255,255,255,.42);
}

.post-textarea:focus {
  outline: none;
  background: #091322;
  border-color: rgba(59,130,246,.45);
  box-shadow: 0 0 0 3px rgba(59,130,246,.12);
}

.post-attach-bar {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 16px 0;
  padding: 10px;
  border-radius: 14px;
  background: #0c1424;
  border: 1px solid rgba(255,255,255,.06);
}

.attach-btn {
  width: 42px;
  height: 42px;
  border: 1px solid rgba(255,255,255,.06);
  border-radius: 12px;
  background: #111827;
  color: #9ca3af;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: transform .16s ease, background .16s ease, color .16s ease, border-color .16s ease;
}

.attach-btn:hover {
  transform: translateY(-2px);
  background:
    linear-gradient(
      135deg,
      #60a5fa,
      #2563eb
    );
  border-color: rgba(96,165,250,.35);
  color: #fff;
}

.attach-btn:active {
  transform: scale(.96);
}

.attach-btn svg {
  width: 20px;
  height: 20px;
}

.media-preview {
  margin-top: 14px;
  padding: 14px;
  border-radius: 16px;
  background: #0c1424;
  border: 1px solid rgba(255,255,255,.06);
}

.media-preview.hidden {
  display: none;
}

.progressive-media {
  position: relative;
}

.progressive-media .post-image {
  min-height: 180px;
  filter: blur(10px);
  transform: scale(1.02);
  transition: filter .25s ease, transform .25s ease;
}

.progressive-media.is-loaded .post-image {
  filter: none;
  transform: none;
}

.image-loading-spinner {
  position: absolute;
  z-index: 1;
  top: 50%;
  left: 50%;
  width: 30px;
  height: 30px;
  margin: -15px;
  border: 3px solid rgba(255,255,255,.35);
  border-top-color: #fff;
  border-radius: 50%;
  animation: image-spinner .8s linear infinite;
}

.progressive-media.is-loaded .image-loading-spinner {
  display: none;
}

@keyframes image-spinner {
  to { transform: rotate(360deg); }
}

.post-node-label {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin: 10px 0 2px;
  color: var(--text-secondary);
  font-size: .8rem;
}

.post-node-label svg {
  width: 14px;
  height: 14px;
}

.search-leaderboard {
  margin: 20px 0 28px;
  padding: 16px;
  border: 1px solid var(--border-color);
  border-radius: 12px;
  background: var(--bg-secondary);
}

.search-section-heading {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 12px;
}

.search-section-heading h3 {
  margin: 0;
}

.search-leaderboard-list {
  display: grid;
  gap: 8px;
}

.leaderboard-user {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
  padding: 8px;
  color: inherit;
  text-decoration: none;
  border-radius: 8px;
}

.leaderboard-user:hover {
  background: var(--bg-tertiary);
}

.leaderboard-rank {
  width: 20px;
  color: var(--text-secondary);
  text-align: center;
  font-weight: 700;
}

.leaderboard-name {
  display: grid;
  min-width: 0;
  flex: 1;
}

.leaderboard-name strong,
.leaderboard-name small {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.leaderboard-name small,
.leaderboard-count {
  color: var(--text-secondary);
  font-size: .8rem;
}

.leaderboard-count {
  white-space: nowrap;
}

.preview-thumb {
  width: 100%;
  max-height: 300px;
  object-fit: cover;
  border-radius: 14px;
  border: 1px solid rgba(255,255,255,.08);
  display: block;
  margin-bottom: 12px;
}

.music-preview-label {
  display: flex;
  align-items: center;
  gap: 8px;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 10px;
}

.post-audio {
  width: 100%;
  margin-bottom: 12px;
  accent-color: #3b82f6;
}

.uploading, .error-text {
  padding: 12px 14px;
  border-radius: 12px;
  font-size: .92rem;
}

.uploading {
  color: var(--text-secondary);
  background: #0c1424;
}

.error-text {
  color: #fecaca;
  background: rgba(239,68,68,.12);
  border: 1px solid rgba(239,68,68,.22);
}

.poll-builder {
  margin-top: 16px;
  padding: 16px;
  border-radius: 16px;
  background: #0c1424;
  border: 1px solid rgba(255,255,255,.06);
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.poll-builder.hidden {
  display: none;
}

#poll-options-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.poll-option-input {
  border-radius: 12px;
  background: #08111d;
  border: 1px solid rgba(255,255,255,.08);
}

.node-selector {
  margin-bottom: 14px;
}

.node-selector-button {
  width: 100%;
  display: inline-flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 12px 14px;
  border-radius: 14px;
  background: #0c1424;
  border: 1px solid rgba(255,255,255,.06);
  color: var(--text-primary);
  transition: border-color .18s ease, background .18s ease;
}

.node-selector-button:hover {
  background: #0d1728;
  border-color: rgba(96,165,250,.28);
}

.node-selector-button .chevron-icon {
  margin-left: auto;
  transition: transform .18s ease;
}

.node-selector.open .chevron-icon {
  transform: rotate(180deg);
}

.node-dropdown {
  margin-top: 8px;
  background: #0b1220;
  border: 1px solid rgba(255,255,255,.08);
  border-radius: 14px;
  overflow: hidden;
  box-shadow: 0 14px 32px rgba(0,0,0,.35);
}

.node-option {
  padding: 11px 14px;
  color: var(--text-primary);
  transition: background .16s ease;
}

.node-option:hover {
  background: rgba(59,130,246,.10);
}

.node-option.disabled {
  opacity: .45;
}

.modal-footer {
  display: flex;
  justify-content: flex-end;
  margin-top: 18px;
}

.modal-footer .btn {
  min-width: 120px;
  border-radius: 12px;
  padding: 12px 18px;
  background:
    linear-gradient(
      135deg,
      #60a5fa,
      #2563eb
    );
  border: 1px solid rgba(255,255,255,.08);
}

.modal-footer .btn:hover {
  filter: brightness(1.05);
}

.modal-footer .btn-secondary {
  background: #111827;
  border: 1px solid rgba(255,255,255,.08);
}

.profile-userboxes {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin: 16px 0 24px;
}

.profile-userbox {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 220px;
  max-width: 360px;
  padding: 10px 14px 10px 10px;
  background: var(--userbox-bg, var(--bg-secondary));
  border: 1px solid var(--userbox-border, var(--border-color));
  border-radius: 12px;
}

.profile-userbox img,
.profile-userbox .userbox-image-fallback {
  width: 42px;
  height: 42px;
  flex: 0 0 42px;
  object-fit: cover;
  border-radius: 9px;
  background: var(--bg-tertiary);
}

.profile-userbox p { margin: 0; line-height: 1.4; word-break: break-word; }

@media (max-width: 768px) {
  .modal-post-card {
    width: calc(100% - 24px);
    border-radius: 18px;
  }

  .post-textarea {
    min-height: 120px;
  }

  .post-attach-bar {
    justify-content: space-between;
  }

  .attach-btn {
    flex: 1;
  }
}

.profile-banner {
  width: 100%;
  height: 220px;
  overflow: hidden;
  border-radius: 18px 18px 0 0;
  background: #0b1220;
}

.profile-banner img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  display: block;
}

.post-header {
  position: relative;
}

.post-actions {
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: 10px;
}

.report-icon {
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  border: 1px solid transparent;
  background: transparent;
  color: var(--text-secondary);
  cursor: pointer;
  transition:
    background .2s ease,
    color .2s ease,
    transform .2s ease;
}

.report-icon:hover {
  background: rgba(239,68,68,.12);
  color: var(--danger);
  transform: scale(1.08);
}

.report-icon svg {
  width: 17px;
  height: 17px;
}

.post-footer {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 18px;
  padding-top: 14px;
  border-top: 1px solid rgba(255,255,255,.06);
}

.icon-action {
  width: auto;
  min-width: 42px;
  height: 42px;
  padding: 0 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  border-radius: 999px;
  background:
    rgba(
      255,
      255,
      255,
      .03
    ) !important;
  border: 1px solid rgba(255,255,255,.06) !important;
  color: var(--text-secondary) !important;
  transition:
    transform .18s ease,
    background .18s ease,
    color .18s ease;
}

.icon-action:hover {
  background:
    rgba(
      37,
      99,
      235,
      .15
    ) !important;
  color: var(--accent-hover) !important;
  transform: translateY(-2px);
}

.icon-action svg {
  width: 20px;
  height: 20px;
}

.node-selector {
  position: relative;
}

#node-dropdown, .node-dropdown {
  position: absolute;
  top: calc(100% + 8px);
  left: 0;
  width: 100%;
  max-height: 280px;
  overflow-y: auto;
  background: #0b1220;
  border: 1px solid rgba(255,255,255,.08);
  border-radius: 14px;
  box-shadow: 0 20px 50px rgba(0,0,0,.55);
  padding: 8px;
  display: none;
  z-index: 99999;
}

#node-dropdown.open, .node-dropdown.open {
  display: block;
}

.node-option {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px;
  border-radius: 10px;
  cursor: pointer;
  color: white;
  transition: .15s ease;
}

.node-option:hover {
  background:
    rgba(
      59,
      130,
      246,
      .12
    );
}

.node-option svg {
  width: 18px;
  height: 18px;
  color: #60a5fa;
}

.node-option.disabled {
  opacity: .45;
  cursor: not-allowed;
}

.comments-overlay {
  position: fixed;
  inset: 0;
  background:
    rgba(
      3,
      7,
      18,
      .72
    );
  backdrop-filter: blur(14px);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity .25s ease;
  z-index: 99990;
}

.comments-overlay.open {
  opacity: 1;
  pointer-events: auto;
}

.comments-window {
  width: min(620px,92vw);
  height: min(780px,85vh);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  background:
    linear-gradient(
      145deg,
      rgba(15,23,42,.96),
      rgba(2,6,23,.94)
    );
  border:
    1px solid
    rgba(255,255,255,.10);
  border-radius: 26px;
  box-shadow:
    0 30px 90px rgba(0,0,0,.65),
    0 0 50px rgba(37,99,235,.12);
  transform:
    translateX(80px)
    scale(.96);
  opacity: 0;
  transition:
    transform .35s cubic-bezier(.16,1,.3,1),
    opacity .25s ease;
}

.comments-overlay.open .comments-window {
  transform:
    translateX(0)
    scale(1);
  opacity: 1;
}

.comments-header {
  height: 70px;
  padding: 0 22px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom:
    1px solid
    rgba(255,255,255,.08);
}

.comments-header h2 {
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--text-primary);
}

.comments-header button {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  border:
    1px solid
    rgba(255,255,255,.08);
  background:
    rgba(
      255,
      255,
      255,
      .04
    );
  color: var(--text-secondary);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-size: 24px;
  transition: .2s ease;
}

.comments-header button:hover {
  background:
    rgba(
      239,
      68,
      68,
      .15
    );
  color: #ef4444;
  transform:
    rotate(90deg)
    scale(1.08);
}

.comments-list {
  flex: 1;
  overflow-y: auto;
  padding: 22px;
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.comment-item {
  display: flex;
  gap: 12px;
  padding: 14px;
  border-radius: 16px;
  background:
    rgba(
      255,
      255,
      255,
      .035
    );
  border:
    1px solid
    rgba(255,255,255,.06);
  animation: commentSlide .35s cubic-bezier(.16,1,.3,1);
}

@keyframes commentSlide {
  from {
    opacity: 0;
    transform: translateX(-35px);
  }

  to {
    opacity: 1;
    transform: translateX(0);
  }
}

.comment-avatar {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  object-fit: cover;
  flex-shrink: 0;
}

.comment-name {
  color: var(--accent-hover);
  font-weight: 700;
  font-size: .9rem;
}

.comment-item p {
  margin-top: 5px;
  color: var(--text-primary);
  line-height: 1.5;
  word-break: break-word;
}

.empty-comments {
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-secondary);
  font-size: .95rem;
}

.comments-input {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 16px;
  border-top:
    1px solid
    rgba(255,255,255,.08);
  background:
    rgba(
      2,
      6,
      23,
      .55
    );
}

.comments-input .comment-avatar {
  width: 38px;
  height: 38px;
}

.comments-input input {
  flex: 1;
  height: 44px;
  padding: 0 16px;
  border-radius: 22px;
  border:
    1px solid
    rgba(255,255,255,.1);
  background:
    rgba(
      255,
      255,
      255,
      .05
    );
  color: white;
  outline: none;
  transition: .2s ease;
}

.comments-input input:focus {
  border-color: var(--accent-hover);
  background:
    rgba(
      255,
      255,
      255,
      .08
    );
}

.comments-input button {
  height: 44px;
  padding: 0 20px;
  border-radius: 22px;
  border: none;
  cursor: pointer;
  font-weight: 700;
  color: white;
  background:
    linear-gradient(
      135deg,
      #60a5fa,
      #2563eb
    );
  transition: .2s ease;
}

.comments-input button:hover {
  transform: translateY(-2px);
  filter: brightness(1.1);
}

.comments-list::-webkit-scrollbar {
  width: 8px;
}

.comments-list::-webkit-scrollbar-thumb {
  background:
    rgba(
      255,
      255,
      255,
      .15
    );
  border-radius: 20px;
}

@media(max-width:600px) {
  .comments-window {
    width: 95vw;
    height: 85vh;
    border-radius: 22px;
  }

  .comments-input button {
    padding: 0 14px;
  }
}

.nn-alert {
  min-width: 320px;
  max-width: 420px;
  padding: 16px 18px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  color: var(--text-primary, #fff);
  background:
    linear-gradient(
      135deg,
      rgba(15,23,42,.92),
      rgba(30,41,59,.85)
    );
  border:
    1px solid
    rgba(255,255,255,.12);
  border-radius: 18px;
  backdrop-filter: blur(20px);
  box-shadow:
    0 20px 50px
    rgba(0,0,0,.35);
  animation: nexusAlertIn .35s cubic-bezier(.2,.8,.2,1);
  pointer-events: auto;
  overflow: hidden;
}

.nn-alert::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 4px;
  background:
    var(
      --accent,
      #22d3ee
    );
}

.nn-alert-success::before {
  background: #22c55e;
}

.nn-alert-error::before {
  background: #ef4444;
}

.nn-alert-info::before {
  background: #22d3ee;
}

.nn-alert-success {
  box-shadow:
    0 0 30px
    rgba(34,197,94,.18),
    0 20px 50px
    rgba(0,0,0,.35);
}

.nn-alert-error {
  box-shadow:
    0 0 30px
    rgba(239,68,68,.18),
    0 20px 50px
    rgba(0,0,0,.35);
}

.nn-alert-info {
  box-shadow:
    0 0 30px
    rgba(34,211,238,.18),
    0 20px 50px
    rgba(0,0,0,.35);
}

.nn-alert-content {
  font-size: .95rem;
  font-weight: 500;
  letter-spacing: .2px;
}

.nn-alert-close {
  width: 30px;
  height: 30px;
  flex: 0 0 30px;
  aspect-ratio: 1 / 1;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  border: none;
  background:
    rgba(
      255,
      255,
      255,
      .08
    );
  color: white;
  cursor: pointer;
  transition: .2s;
}

.nn-alert-close:hover {
  background:
    rgba(
      255,
      255,
      255,
      .18
    );
  transform: rotate(90deg);
}

.nn-alert-hide {
  opacity: 0;
  transform:
    translateX(80px)
    scale(.95);
  transition: .3s ease;
}

@keyframes nexusAlertIn {
  from {
    opacity: 0;
    transform:
      translateX(80px)
      scale(.95);
  }

  to {
    opacity: 1;
    transform:
      translateX(0)
      scale(1);
  }
}

#node-create-modal {
  animation: nexusModalFade .25s ease;
}

#node-create-modal .modal-card {
  width: min(520px, 92vw);
  background:
    linear-gradient(
      145deg,
      rgba(15,23,42,.96),
      rgba(2,6,23,.94)
    );
  border:
    1px solid
    rgba(255,255,255,.12);
  border-radius: 24px;
  box-shadow:
    0 30px 90px
    rgba(0,0,0,.5),
    0 0 50px
    rgba(34,211,238,.08);
  backdrop-filter: blur(25px);
  animation: nexusModalPop .3s cubic-bezier(.2,.8,.2,1);
}

#node-create-modal .modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 20px;
}

#node-create-modal h3 {
  font-size: 1.35rem;
  font-weight: 700;
}

#node-create-modal .form-control {
  background:
    rgba(
      255,
      255,
      255,
      .06
    );
  border:
    1px solid
    rgba(255,255,255,.12);
  color: white;
  border-radius: 14px;
  transition: .2s;
}

#node-create-modal .form-control:focus {
  border-color:
    var(
      --accent,
      #22d3ee
    );
  box-shadow:
    0 0 0 4px
    rgba(34,211,238,.12);
  outline: none;
}

#node-create-modal textarea {
  min-height: 120px;
  resize: vertical;
}

#node-create-modal .modal-footer {
  margin-top: 20px;
  display: flex;
  justify-content: flex-end;
  gap: 12px;
}

@keyframes nexusModalFade {
  from {
    opacity: 0;
  }

  to {
    opacity: 1;
  }
}

@keyframes nexusModalPop {
  from {
    opacity: 0;
    transform:
      translateY(20px)
      scale(.96);
  }

  to {
    opacity: 1;
    transform:
      translateY(0)
      scale(1);
  }
}

@media(max-width:600px) {
  #nn-alert-container {
    left: 16px;
    right: 16px;
    top: 16px;
  }

  .nn-alert {
    min-width: unset;
    width: 100%;
  }
}

.profile-bg-effect, .profile-effect-layer, .confetti-container, #confetti-canvas, canvas.confetti {
  position: absolute !important;
  inset: 0;
  z-index: 1 !important;
  pointer-events: none !important;
  overflow: hidden;
}

.profile-page {
  position: relative !important;
  overflow: hidden !important;
  isolation: isolate;
}

.profile-inner {
  position: relative;
  z-index: 10;
}

.app-header, .sidebar, .main-content, .right-panel {
  position: relative;
  z-index: 100;
}

.profile-card, .profile-widget, .settings-card, .post-card {
  position: relative;
  z-index: 20;
}

.confetti-piece {
  position: absolute !important;
  top: -30px;
  pointer-events: none;
  animation: nexus-confetti-fall linear forwards;
}

@keyframes nexus-confetti-fall {
  from {
    transform: translateY(0) rotate(0deg);
    opacity: 1;
  }

  to {
    transform: translateY(120vh) rotate(720deg);
    opacity: 0;
  }
}

.modal-overlay {
  position: fixed !important;
  inset: 0;
  z-index: 99990 !important;
}

#nn-alert-container {
  position: fixed;
  z-index: 99999 !important;
}

.profile-bg-effect, .profile-effect-layer {
  position: fixed !important;
  top: 0 !important;
  bottom: 0 !important;
  height: 100vh !important;
  width: 140px !important;
  overflow: hidden !important;
  pointer-events: none !important;
  z-index: 5 !important;
}

.profile-bg-effect {
  left: 0 !important;
  right: auto !important;
}

.profile-effect-layer {
  right: 0 !important;
  left: auto !important;
}

.confetti-piece {
  position: absolute !important;
  top: -30px !important;
  animation: nexus-side-fall linear forwards;
}

@keyframes nexus-side-fall {
  from {
    transform: translateY(0) rotate(0deg);
    opacity: 1;
  }

  to {
    transform: translateY(110vh) rotate(720deg);
    opacity: 0;
  }
}

.profile-banner {
  width: 100%;
  height: 220px;
  overflow: hidden;
  border-radius: 18px 18px 0 0;
  background: #0b1220;
  position: relative;
}

.profile-banner img {
  width: 100% !important;
  height: 100% !important;
  object-fit: cover !important;
  object-position: center center !important;
  display: block;
}

.post-poll {
  margin-top: 18px;
  padding: 16px;
  border-radius: 18px;
  background: var(--bg-tertiary);
  border: 1px solid var(--border-color);
}

.poll-question {
  font-size: 1rem;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 14px;
}

.poll-option {
  position: relative;
  overflow: hidden;
  width: 100%;
  min-height: 48px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 12px 16px;
  margin-bottom: 10px;
  border-radius: 14px;
  border:
    1px solid
    rgba(255,255,255,.08);
  background: var(--bg-secondary);
  color: var(--text-primary);
  cursor: pointer;
  transition:
    transform .2s ease,
    border-color .2s ease,
    background .2s ease;
}

.poll-option:hover {
  transform: translateY(-2px);
  border-color: var(--accent-hover);
  background:
    rgba(
      37,
      99,
      235,
      .12
    );
}

.poll-option-bar {
  position: absolute;
  left: 0;
  top: 0;
  height: 100%;
  background:
    linear-gradient(
      90deg,
      rgba(37,99,235,.35),
      rgba(59,130,246,.2)
    );
  border-radius: 14px;
  transition: width .45s cubic-bezier(.16,1,.3,1);
  pointer-events: none;
}

.poll-option-text, .poll-option-count {
  position: relative;
  z-index: 2;
}

.poll-option-text {
  font-weight: 600;
}

.poll-option-count {
  color: var(--text-secondary);
  font-size: .85rem;
}

.poll-option.selected {
  border-color: var(--accent-hover);
  box-shadow:
    0 0 0 2px
    var(--accent-subtle);
}

.poll-meta {
  margin-top: 12px;
  color: var(--text-secondary);
  font-size: .85rem;
}

button:disabled {
  opacity: .6;
  cursor: not-allowed;
}

img {
  display: block;
  max-width: 100%;
  height: auto;
}

.post-image, .post-media, .post-card .post-image, .post-card .post-media {
  display: block;
  width: 100%;
  max-width: 100%;
  height: auto;
  object-fit: cover;
  border-radius: 14px;
  overflow: hidden;
  background: var(--bg-tertiary);
  border: 1px solid var(--border-color);
}

.post-image-container, .post-media-container {
  width: 100%;
  max-width: 100%;
  margin-top: 14px;
  overflow: hidden;
  border-radius: 16px;
  background: var(--bg-tertiary);
}

.post-image-container img, .post-media-container img {
  display: block;
  width: 100%;
  max-width: 100%;
  height: auto;
  object-fit: cover;
}

.preview-thumb {
  display: block;
  width: 100%;
  max-width: 100%;
  height: auto;
  max-height: 360px;
  margin: 0 0 12px;
  object-fit: contain;
  border-radius: 14px;
  border: 1px solid var(--border-color);
  background: #08111d;
}

.avatar, .comment-avatar {
  display: block;
  flex-shrink: 0;
  object-fit: cover;
  object-position: center;
  overflow: hidden;
}

.profile-banner {
  overflow: hidden;
}

.profile-banner img {
  display: block;
  width: 100% !important;
  height: 100% !important;
  max-width: none !important;
  object-fit: cover !important;
  object-position: center center !important;
}

.post-card img, .profile-card img, .profile-widget img, .settings-card img, .comment-item img {
  min-width: 0;
  max-width: 100%;
}

img:not([src]), img[src=""] {
  display: none;
}

.nsfw-pending-image {
  opacity: 0;
  background: var(--skeleton-base, #1f2937);
  animation: skeletonPulse 1.4s ease-in-out infinite;
}

.skeleton-block,
.skeleton-post {
  background: linear-gradient(100deg, #182235 20%, #2b3a52 38%, #182235 56%);
  background-size: 200% 100%;
  animation: skeletonShimmer 1.4s ease-in-out infinite;
}

.skeleton-block {
  display: block;
  width: 100%;
  height: 12px;
  border-radius: 6px;
}

.skeleton-block.short { width: 58%; }
.skeleton-block.medium { width: 78%; }
.skeleton-block.skeleton-inline {
  display: inline-block;
  width: 120px;
  height: 12px;
}

.skeleton-google-button {
  width: 240px;
  height: 40px;
  margin: 0 auto;
  border-radius: 4px;
}

.skeleton-post {
  padding: 20px;
  min-height: 150px;
  margin-bottom: 16px;
  border: 1px solid var(--border-color);
  border-radius: var(--card-radius);
}

.skeleton-post-header {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 18px;
}

.skeleton-avatar {
  width: 42px;
  height: 42px;
  flex: 0 0 42px;
  border-radius: 50%;
}

.skeleton-lines {
  display: flex;
  flex: 1;
  flex-direction: column;
  gap: 8px;
}

.skeleton-content { width: 92%; margin: 10px 0; }
.skeleton-content.medium { width: 64%; }

.feed-load-sentinel {
  min-height: 48px;
  margin: 10px 0 30px;
}

.engagement-count {
  min-width: 1.2em;
  color: var(--text-secondary, #8298b8);
  font-size: 12px;
  text-align: left;
}

.engagement-count[hidden] {
  display: none !important;
}

.signals-section {
  margin-bottom: 24px;
}

.signals-section-header,
.moderation-report-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 12px;
}

.signals-section-header h3 {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 0;
}

.signals-section-header svg {
  width: 17px;
  color: var(--accent-primary, #00e5ff);
}

.signals-section-header > span {
  color: var(--text-secondary, #8298b8);
  font-size: 12px;
}

.signals-empty {
  margin: 0;
  padding: 18px;
  border: 1px dashed var(--border-color, rgba(255,255,255,.12));
  color: var(--text-secondary, #8298b8);
  text-align: center;
}

.moderation-tabs,
.moderation-report-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 16px;
}

.moderation-report blockquote {
  margin: 12px 0;
  padding: 10px 12px;
  border-left: 3px solid var(--accent-primary, #00e5ff);
  color: var(--text-secondary, #8298b8);
}

@keyframes skeletonShimmer {
  from { background-position: 200% 0; }
  to { background-position: -200% 0; }
}

@keyframes skeletonPulse {
  0%, 100% { opacity: 0.35; }
  50% { opacity: 0.7; }
}

.nsfw-blocked-image {
  display: none !important;
}

.nsfw-image-notice {
  display: inline-flex;
  align-items: center;
  min-height: 42px;
  padding: 10px 12px;
  border: 1px solid var(--border-color);
  border-radius: 8px;
  color: var(--text-secondary);
  font-size: 0.85rem;
}

@media (max-width: 768px) {
  .post-image, .post-media {
    border-radius: 12px;
  }

  .post-image-container, .post-media-container {
    border-radius: 12px;
  }

  .preview-thumb {
    max-height: 280px;
  }
}

#signals-list {
  display: flex;
  flex-direction: column;
  gap: 14px;
  width: 100%;
}

.signal-card {
  --signal-color: var(--accent, #2563eb);
  position: relative;
  display: flex;
  align-items: flex-start;
  gap: 16px;
  width: 100%;
  padding: 18px;
  background:
    linear-gradient(
      135deg,
      color-mix(in srgb, var(--signal-color) 7%, var(--bgColor, #0b0f19)),
      var(--bgColor2, #111827)
    );
  border:
    1px solid
    color-mix(in srgb, var(--signal-color) 22%, transparent);
  border-radius: 16px;
  box-shadow:
    0 8px 24px rgba(0, 0, 0, 0.18),
    inset 0 1px 0 rgba(255, 255, 255, 0.025);
  overflow: hidden;
  transition:
    transform 0.18s ease,
    border-color 0.18s ease,
    box-shadow 0.18s ease;
}

.signal-card::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 3px;
  background: var(--signal-color);
  box-shadow:
    0 0 14px
    color-mix(in srgb, var(--signal-color) 55%, transparent);
}

.signal-card:hover {
  transform: translateY(-2px);
  border-color:
    color-mix(
      in srgb,
      var(--signal-color) 40%,
      transparent
    );
  box-shadow:
    0 12px 30px rgba(0, 0, 0, 0.24),
    0 0 20px
    color-mix(in srgb, var(--signal-color) 8%, transparent);
}

.signal-icon {
  flex: 0 0 auto;
  width: 44px;
  height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--signal-color);
  background:
    color-mix(
      in srgb,
      var(--signal-color) 12%,
      transparent
    );
  border:
    1px solid
    color-mix(in srgb, var(--signal-color) 25%, transparent);
  border-radius: 12px;
  box-shadow:
    inset 0 0 12px
    color-mix(in srgb, var(--signal-color) 8%, transparent);
}

.signal-icon svg {
  width: 21px;
  height: 21px;
  stroke-width: 2;
}

.signal-content {
  flex: 1;
  min-width: 0;
}

.signal-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 8px;
}

.signal-header h3 {
  margin: 0;
  color: var(--text-primary, #f8fafc);
  font-size: 15px;
  font-weight: 700;
  line-height: 1.3;
}

.signal-date {
  display: block;
  margin-top: 4px;
  color: var(--text-secondary, #94a3b8);
  font-size: 12px;
  line-height: 1.4;
}

.signal-message {
  color: var(--text-secondary, #cbd5e1);
  font-size: 14px;
  line-height: 1.65;
  white-space: pre-line;
  overflow-wrap: anywhere;
}

.signal-unread {
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 4px 8px;
  color: #fff;
  background: var(--signal-color);
  border-radius: 999px;
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  box-shadow:
    0 0 12px
    color-mix(in srgb, var(--signal-color) 35%, transparent);
}

.signal-policy {
  --signal-color: #8b5cf6;
}

.signal-system {
  --signal-color: #64748b;
}

.signal-announcement {
  --signal-color: #3b82f6;
}

.signal-security {
  --signal-color: #ef4444;
}

.signal-moderation {
  --signal-color: #f59e0b;
}

.signal-account {
  --signal-color: #06b6d4;
}

.signal-update {
  --signal-color: #22c55e;
}

.signal-default {
  --signal-color: #94a3b8;
}

.signal-loading {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 100px;
  color: var(--text-secondary, #94a3b8);
  font-size: 14px;
}

.signal-loading::after {
  content: "";
  width: 16px;
  height: 16px;
  margin-left: 10px;
  border:
    2px solid
    color-mix(in srgb, var(--accent, #2563eb) 20%, transparent);
  border-top-color: var(--accent, #2563eb);
  border-radius: 50%;
  animation: signal-spin 0.75s linear infinite;
}

@keyframes signal-spin {
  to {
    transform: rotate(360deg);
  }
}

#signals-list .empty-state, #signals-list .error-state {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: 240px;
  padding: 32px;
  text-align: center;
}

.empty-state-icon, .error-state-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 52px;
  height: 52px;
  margin-bottom: 14px;
  border-radius: 14px;
  background:
    color-mix(
      in srgb,
      var(--accent, #2563eb) 10%,
      transparent
    );
  color: var(--accent, #2563eb);
}

.error-state-icon {
  color: #ef4444;
  background:
    color-mix(
      in srgb,
      #ef4444 10%,
      transparent
    );
}

.empty-state h3, .error-state h3 {
  margin: 0 0 6px;
  color: var(--text-primary, #f8fafc);
  font-size: 16px;
}

.empty-state p, .error-state p {
  margin: 0;
  color: var(--text-secondary, #94a3b8);
  font-size: 14px;
}

@media (max-width: 600px) {
  .post-footer {
    gap: 6px;
  }

  .icon-action {
    min-width: 42px;
    padding: 0 8px;
  }

  .signal-card {
    gap: 12px;
    padding: 14px;
  }

  .signal-icon {
    width: 40px;
    height: 40px;
    border-radius: 10px;
  }

  .signal-icon svg {
    width: 19px;
    height: 19px;
  }

  .signal-header {
    gap: 8px;
  }

  .signal-header h3 {
    font-size: 14px;
  }

  .signal-message {
    font-size: 13px;
  }

  .signal-unread {
    padding: 3px 7px;
    font-size: 9px;
  }
}

.settings-page {
  width: 100%;
  max-width: 980px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.page-header {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.page-header h2 {
  font-size: 1.9rem;
  font-weight: 700;
  color: var(--text-primary);
}

.page-subtitle {
  color: var(--text-secondary);
  font-size: 0.95rem;
}

.settings-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 20px;
}

.settings-card {
  background:
    linear-gradient(
      145deg,
      rgba(17,24,39,.98),
      rgba(11,15,25,.98)
    );
  border: 1px solid rgba(255,255,255,.08);
  border-radius: 20px;
  padding: 22px;
  display: flex;
  flex-direction: column;
  gap: 18px;
  box-shadow:
    0 12px 30px rgba(0,0,0,.25),
    inset 0 1px 0 rgba(255,255,255,.03);
}

.settings-card h3 {
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--text-primary);
}

.help-text {
  color: var(--text-secondary);
  font-size: 0.9rem;
  line-height: 1.5;
  margin: 0;
}

.settings-card .form-group {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.settings-card label {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-secondary);
}

.settings-card .form-control {
  background: #08111d;
  border: 1px solid rgba(255,255,255,.08);
  color: var(--text-primary);
  border-radius: 12px;
  padding: 12px 14px;
  transition:
    border-color .18s ease,
    box-shadow .18s ease,
    background .18s ease;
}

.settings-card .form-control:focus {
  outline: none;
  background: #091322;
  border-color: rgba(59,130,246,.45);
  box-shadow: 0 0 0 3px rgba(59,130,246,.12);
}

.settings-card textarea.form-control {
  min-height: 120px;
  resize: vertical;
}

.settings-card input[type="color"].form-control {
  height: 48px;
  padding: 6px;
  cursor: pointer;
}

.theme-picker {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

.theme-option {
  flex: 1;
  min-width: 140px;
  padding: 12px 16px;
  border-radius: 14px;
  border: 1px solid rgba(255,255,255,.08);
  background: #111827;
  color: var(--text-primary);
  font-weight: 600;
  cursor: pointer;
  transition:
    transform .18s ease,
    border-color .18s ease,
    background .18s ease,
    box-shadow .18s ease;
}

.theme-option:hover {
  transform: translateY(-1px);
  border-color: rgba(96,165,250,.28);
  background: rgba(37,99,235,.12);
}

.theme-option.active {
  background:
    linear-gradient(
      135deg,
      #60a5fa,
      #2563eb
    );
  border-color: rgba(255,255,255,.08);
  color: #fff;
  box-shadow: 0 0 18px rgba(37,99,235,.22);
}

.settings-card .btn {
  align-self: flex-start;
}

.settings-card .btn-secondary {
  background: #111827;
  border: 1px solid rgba(255,255,255,.08);
  color: var(--text-primary) !important;
}

.settings-card .btn-secondary:hover {
  background: rgba(37,99,235,.12);
}

.settings-danger {
  display: flex;
  flex-direction: column;
  gap: 16px;
  border-color: rgba(239,68,68,.22);
  background:
    linear-gradient(
      145deg,
      rgba(127,29,29,.18),
      rgba(17,24,39,.98)
    );
}

.settings-danger h3 {
  color: #fecaca;
}

.settings-danger .help-text {
  color: #fca5a5;
}

.settings-danger .btn {
  align-self: flex-start;
}

.settings-danger .btn-secondary {
  border-color: rgba(239,68,68,.22);
}

.settings-danger .btn-secondary:hover {
  background: rgba(239,68,68,.14);
  color: #fee2e2 !important;
}

.settings-divider {
  width: 100%;
  height: 1px;
  background: rgba(255,255,255,.08);
}

@media (max-width: 768px) {
  .settings-page {
    gap: 18px;
  }

  .settings-card {
    padding: 18px;
    border-radius: 18px;
  }

  .theme-picker {
    flex-direction: column;
  }

  .theme-option {
    width: 100%;
  }

  .settings-card .btn {
    width: 100%;
    justify-content: center;
  }
}

.confession-overlay {
  position: fixed;
  inset: 0;
  background: rgba(3, 7, 18, 0.72);
  backdrop-filter: blur(14px);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 99998;
  animation: confessionFadeIn 0.25s ease;
}

.confession-box {
  width: min(420px, 92vw);
  background:
    linear-gradient(
      145deg,
      rgba(17,24,39,.98),
      rgba(11,15,25,.98)
    );
  border: 1px solid rgba(255,255,255,.10);
  border-radius: 22px;
  padding: 28px;
  text-align: center;
  box-shadow:
    0 30px 90px rgba(0,0,0,.55),
    0 0 40px rgba(37,99,235,.10);
  animation: confessionPop 0.28s cubic-bezier(.16,1,.3,1);
}

.confession-box h2 {
  margin: 0 0 10px;
  font-size: 1.35rem;
  font-weight: 700;
  color: var(--text-primary);
}

.confession-box p {
  margin: 0 0 22px;
  color: var(--text-secondary);
  font-size: 0.95rem;
  line-height: 1.6;
}

.confession-buttons {
  display: flex;
  gap: 12px;
}

.confession-buttons button {
  flex: 1;
  height: 46px;
  border-radius: 14px;
  border: 1px solid rgba(255,255,255,.08);
  font-size: 0.95rem;
  font-weight: 700;
  cursor: pointer;
  transition:
    transform .18s ease,
    background .18s ease,
    border-color .18s ease,
    color .18s ease;
}

.confession-buttons button:hover {
  transform: translateY(-2px);
}

.confession-buttons button:active {
  transform: scale(.98);
}

.yes-btn {
  background:
    linear-gradient(
      135deg,
      #60a5fa,
      #2563eb
    );
  color: #fff;
}

.yes-btn:hover {
  filter: brightness(1.05);
}

.no-btn {
  background: var(--bg-tertiary);
  color: var(--text-primary);
}

.no-btn:hover {
  background: rgba(239,68,68,.14);
  border-color: rgba(239,68,68,.28);
  color: #fee2e2;
}

@keyframes confessionFadeIn {
  from {
    opacity: 0;
  }

  to {
    opacity: 1;
  }
}

@keyframes confessionPop {
  from {
    opacity: 0;
    transform: translateY(20px) scale(.96);
  }

  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

#nn-alert-container {
  position: fixed;
  top: 20px;
  right: 20px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  z-index: 99999;
  pointer-events: none;
}

#nn-alert-container .nn-alert {
  pointer-events: auto;
}

.confession-glitch {
  animation:
    confession-shake 0.07s infinite,
    confession-flicker 0.11s infinite;
}

.confession-screen-glitch {
  animation: confession-screen-shake 0.08s infinite;
}

.confession-loading-box {
  min-height: 180px;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

.confession-loading {
  width: 100%;
  min-height: 150px;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  overflow: hidden;
}

.confession-loading-noise {
  position: absolute;
  inset: -50%;
  opacity: 0.12;
  background:
    repeating-linear-gradient(
      0deg,
      transparent 0px,
      transparent 3px,
      currentColor 4px,
      transparent 5px
    );
  animation: confession-noise 0.08s steps(2) infinite;
}

.confession-loading-text {
  position: relative;
  z-index: 2;
  font-family: monospace;
  font-size: 16px;
  letter-spacing: 2px;
}

.loading-dots {
  display: inline-block;
  width: 24px;
  overflow: hidden;
  animation: confession-dots 1s steps(4) infinite;
}

@keyframes confession-shake {
  0% {
    transform: translate(0, 0) rotate(0deg);
  }

  15% {
    transform: translate(-8px, 4px) rotate(-1deg);
  }

  30% {
    transform: translate(7px, -5px) rotate(1deg);
  }

  45% {
    transform: translate(-5px, -7px) rotate(-2deg);
  }

  60% {
    transform: translate(9px, 6px) rotate(2deg);
  }

  75% {
    transform: translate(-7px, 3px) rotate(-1deg);
  }

  90% {
    transform: translate(5px, -4px) rotate(1deg);
  }

  100% {
    transform: translate(0, 0) rotate(0deg);
  }
}

@keyframes confession-screen-shake {
  0% {
    transform: translate(0, 0);
  }

  20% {
    transform: translate(-4px, 2px);
  }

  40% {
    transform: translate(3px, -3px);
  }

  60% {
    transform: translate(-2px, -2px);
  }

  80% {
    transform: translate(4px, 3px);
  }

  100% {
    transform: translate(0, 0);
  }
}

@keyframes confession-flicker {
  0%, 100% {
    opacity: 1;
  }

  25% {
    opacity: 0.65;
  }

  50% {
    opacity: 0.9;
  }

  75% {
    opacity: 0.45;
  }
}

@keyframes confession-noise {
  0% {
    transform: translate(0, 0);
  }

  25% {
    transform: translate(-8px, 5px);
  }

  50% {
    transform: translate(6px, -7px);
  }

  75% {
    transform: translate(-4px, -3px);
  }

  100% {
    transform: translate(7px, 6px);
  }
}

@keyframes confession-dots {
  0% {
    width: 8px;
  }

  33% {
    width: 14px;
  }

  66% {
    width: 20px;
  }

  100% {
    width: 24px;
  }
}

.confession-overlay {
  position: fixed;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(3, 7, 18, 0.72);
  backdrop-filter: blur(14px);
  z-index: 99998;
  animation: confessionFadeIn 0.25s ease both;
}

.confession-box {
  box-sizing: border-box;
  width: min(420px, 92vw);
  min-height: 180px;
  padding: 28px;
  background:
    linear-gradient(
      145deg,
      rgba(17, 24, 39, 0.98),
      rgba(11, 15, 25, 0.98)
    );
  border: 1px solid rgba(255, 255, 255, 0.10);
  border-radius: 22px;
  text-align: center;
  box-shadow:
    0 30px 90px rgba(0, 0, 0, 0.55),
    0 0 40px rgba(37, 99, 235, 0.10);
  animation: confessionPop 0.28s cubic-bezier(.16, 1, .3, 1) both;
  position: relative;
  overflow: hidden;
}

.confession-box h2 {
  margin: 0 0 10px;
  font-size: 1.35rem;
  font-weight: 700;
  color: var(--text-primary);
}

.confession-box p {
  margin: 0 0 22px;
  color: var(--text-secondary);
  font-size: 0.95rem;
  line-height: 1.6;
}

.confession-buttons {
  display: flex;
  gap: 12px;
}

.confession-buttons button {
  flex: 1;
  height: 46px;
  border-radius: 14px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  font-size: 0.95rem;
  font-weight: 700;
  cursor: pointer;
  transition:
    transform 0.18s ease,
    background 0.18s ease,
    border-color 0.18s ease,
    color 0.18s ease,
    filter 0.18s ease;
}

.confession-buttons button:hover {
  transform: translateY(-2px);
}

.confession-buttons button:active {
  transform: scale(0.98);
}

.yes-btn {
  background:
    linear-gradient(
      135deg,
      #60a5fa,
      #2563eb
    );
  color: #fff;
}

.yes-btn:hover {
  filter: brightness(1.05);
}

.no-btn {
  background: var(--bg-tertiary);
  color: var(--text-primary);
}

.no-btn:hover {
  background: rgba(239, 68, 68, 0.14);
  border-color:
    rgba(
      239,
      68,
      68,
      0.28
    );
  color: #fee2e2;
}

.confession-captcha-check {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  margin-top: 8px;
  padding: 13px 15px;
  border-radius: 13px;
  background: rgba(255, 255, 255, 0.035);
  border: 1px solid rgba(255, 255, 255, 0.07);
  color: var(--text-secondary);
  font-size: 0.88rem;
  cursor: pointer;
  transition:
    background 0.18s ease,
    border-color 0.18s ease;
}

.confession-captcha-check:hover {
  background: rgba(255, 255, 255, 0.055);
  border-color:
    rgba(
      255,
      255,
      255,
      0.12
    );
}

.confession-checkbox {
  width: 17px;
  height: 17px;
  margin: 0;
  accent-color: #2563eb;
  cursor: pointer;
}

.confession-checkbox:disabled {
  cursor: default;
}

.confession-captcha-status {
  margin-top: 12px;
  font-size: 0.78rem;
  color: #93c5fd;
  letter-spacing: 0.02em;
  animation: confessionStatusIn 0.2s ease both;
}

.confession-loading-box {
  min-height: 180px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 28px;
  overflow: hidden;
}

.confession-loading {
  width: 100%;
  min-height: 124px;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  overflow: hidden;
}

.confession-loader {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  border: 3px solid rgba(255, 255, 255, 0.10);
  border-top-color: rgba(147, 197, 253, 0.95);
  border-right-color: rgba(59, 130, 246, 0.80);
  animation: confessionLoaderSpin 0.75s linear infinite;
  position: relative;
}

.confession-loader::after {
  content: "";
  position: absolute;
  width: 20px;
  height: 20px;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  border-radius: 50%;
  background:
    linear-gradient(
      145deg,
      rgba(17, 24, 39, 0.98),
      rgba(11, 15, 25, 0.98)
    );
}

.confession-loading::before {
  content: "";
  position: absolute;
  inset: -100% 0;
  pointer-events: none;
  opacity: 0.08;
  background:
    repeating-linear-gradient(
      to bottom,
      transparent 0,
      transparent 4px,
      rgba(255, 255, 255, 0.25) 5px,
      transparent 6px
    );
  animation: confessionScanlines 0.65s linear infinite;
}

.confession-glitch {
  animation:
    confessionShake 0.055s steps(2, end) infinite,
    confessionFlicker 0.09s steps(2, end) infinite;
}

.confession-glitch::before, .confession-glitch::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  border-radius: inherit;
  opacity: 0.18;
  mix-blend-mode: screen;
}

.confession-glitch::before {
  background:
    repeating-linear-gradient(
      0deg,
      transparent 0,
      transparent 3px,
      rgba(255, 255, 255, 0.16) 4px,
      transparent 5px
    );
  animation: confessionGlitchLines 0.12s steps(2, end) infinite;
}

.confession-glitch::after {
  background:
    linear-gradient(
      90deg,
      rgba(255, 0, 80, 0.10),
      transparent 35%,
      rgba(0, 150, 255, 0.12)
    );
  animation: confessionChromatic 0.08s steps(2, end) infinite;
}

.confession-screen-glitch {
  animation: confessionScreenShake 0.075s steps(2, end) infinite;
}

#nn-alert-container {
  position: fixed;
  top: 20px;
  right: 20px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  z-index: 99999;
  pointer-events: none;
}

#nn-alert-container .nn-alert {
  pointer-events: auto;
}

@keyframes confessionFadeIn {
  from {
    opacity: 0;
  }

  to {
    opacity: 1;
  }
}

@keyframes confessionPop {
  from {
    opacity: 0;
    transform:
      translateY(20px)
      scale(0.96);
  }

  to {
    opacity: 1;
    transform:
      translateY(0)
      scale(1);
  }
}

@keyframes confessionStatusIn {
  from {
    opacity: 0;
    transform: translateY(-4px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes confessionShake {
  0% {
    transform:
      translate(
        0,
        0) rotate(0deg) skew(0deg
      );
  }

  12% {
    transform:
      translate(
        -10px,
        5px) rotate(-1deg) skewX(2deg
      );
  }

  25% {
    transform:
      translate(
        8px,
        -6px) rotate(1deg) skewX(-3deg
      );
  }

  37% {
    transform:
      translate(
        -6px,
        -8px) rotate(-2deg) skewY(2deg
      );
  }

  50% {
    transform:
      translate(
        11px,
        7px) rotate(2deg) skewX(-2deg
      );
  }

  62% {
    transform:
      translate(
        -9px,
        2px) rotate(-1deg) skewY(-2deg
      );
  }

  75% {
    transform:
      translate(
        6px,
        -5px) rotate(1deg) skewX(3deg
      );
  }

  87% {
    transform:
      translate(
        -4px,
        6px) rotate(-1deg) skewY(2deg
      );
  }

  100% {
    transform:
      translate(
        0,
        0) rotate(0deg) skew(0deg
      );
  }
}

@keyframes confessionScreenShake {
  0% {
    transform: translate(0, 0);
  }

  12% {
    transform: translate(-5px, 2px);
  }

  25% {
    transform: translate(4px, -4px);
  }

  37% {
    transform: translate(-3px, -2px);
  }

  50% {
    transform: translate(6px, 3px);
  }

  62% {
    transform: translate(-4px, 4px);
  }

  75% {
    transform: translate(3px, -3px);
  }

  87% {
    transform: translate(-2px, 2px);
  }

  100% {
    transform: translate(0, 0);
  }
}

@keyframes confessionFlicker {
  0% {
    opacity: 1;
  }

  20% {
    opacity: 0.55;
  }

  38% {
    opacity: 0.95;
  }

  55% {
    opacity: 0.40;
  }

  72% {
    opacity: 0.85;
  }

  88% {
    opacity: 0.50;
  }

  100% {
    opacity: 1;
  }
}

@keyframes confessionGlitchLines {
  0% {
    transform: translateY(0);
    clip-path: inset(0 0 85% 0);
  }

  25% {
    transform: translateY(-7px);
    clip-path: inset(15% 0 55% 0);
  }

  50% {
    transform: translateY(9px);
    clip-path: inset(65% 0 12% 0);
  }

  75% {
    transform: translateY(-4px);
    clip-path: inset(35% 0 35% 0);
  }

  100% {
    transform: translateY(0);
    clip-path: inset(0 0 85% 0);
  }
}

@keyframes confessionChromatic {
  0% {
    transform: translateX(0);
  }

  25% {
    transform: translateX(-6px);
  }

  50% {
    transform: translateX(7px);
  }

  75% {
    transform: translateX(-4px);
  }

  100% {
    transform: translateX(0);
  }
}

@keyframes confessionLoaderSpin {
  from {
    transform: rotate(0deg);
  }

  to {
    transform: rotate(360deg);
  }
}

@keyframes confessionScanlines {
  from {
    transform: translateY(0);
  }

  to {
    transform: translateY(12px);
  }
}

@media (prefers-reduced-motion: reduce) {
  .confession-overlay, .confession-box, .confession-glitch, .confession-screen-glitch, .confession-loader, .confession-loading::before, .confession-glitch::before, .confession-glitch::after {
    animation: none !important;
  }

}

.profile-banner-wrap {
  width: 100%;
  height: 220px;
  overflow: hidden;
  border-radius: 24px;
  position: relative;
}

.profile-banner {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  display: block;
}

.post-footer {
  display: flex;
  align-items: center;
  gap: 8px;
  width: 100%;
  flex-wrap: nowrap;
}

.reaction-button {
  display: inline-grid;
  grid-template-columns: 18px minmax(0, 0fr);
  align-items: center;
  justify-content: start;
  gap: 0;
  min-width: 38px;
  width: max-content;
  padding: 8px;
  overflow: hidden;
  white-space: nowrap;
  flex-shrink: 0;
  transition:
    width 0.2s ease,
    padding 0.2s ease,
    background 0.2s ease,
    transform 0.15s ease;
}

.reaction-button svg {
  width: 18px;
  height: 18px;
  flex-shrink: 0;
}

.reaction-count {
  display: block;
  min-width: 0;
  max-width: 0;
  opacity: 0;
  overflow: hidden;
  white-space: nowrap;
  font-size: 13px;
  font-weight: 600;
  transform: translateX(-4px) scale(.86);
  transform-origin: left center;
  transition: max-width .42s cubic-bezier(.16,1,.3,1), opacity .22s ease, transform .42s cubic-bezier(.16,1,.3,1);
  }

  .reaction-button.has-count {
  grid-template-columns: 18px minmax(0, 1fr);
  gap: 6px;
  padding-right: 11px;
  }

  .reaction-button.has-count .reaction-count {
  max-width: 100px;
  opacity: 1;
  transform: translateX(0) scale(1);
  }

.reaction-button.active {
  transform: scale(1.03);
}

.post-footer > .icon-action {
  flex-shrink: 0;
}

.post-card .post-footer {
  justify-content: flex-start;
}

.post-card .icon-action {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-align: center;
}

.post-card .engagement-count {
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

@media (max-width: 600px) {
  .post-footer {
    gap: 6px;
  }

  .reaction-button {
    padding: 7px;
  }

  .reaction-button.has-count {
    padding-right: 9px;
  }

  .reaction-count {
    font-size: 12px;
  }
}

.changelog-page {
  width: 100%;
  max-width: var(--max-width);
  margin: 0 auto;
}

.changelog-page .page-header {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-bottom: 24px;
}

.changelog-page .page-header h2 {
  margin: 0;
  font-size: 1.9rem;
  font-weight: 700;
  color: var(--text-primary);
}

.changelog-page .page-header p {
  margin: 0;
  color: var(--text-secondary);
  font-size: 0.95rem;
  line-height: 1.5;
}

.changelog-list {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.changelog-release {
  width: 100%;
  padding: 20px;
  background-color: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: var(--card-radius);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.16);
  transition:
    border-color 0.2s ease,
    transform 0.2s ease,
    box-shadow 0.2s ease;
}

.changelog-release:hover {
  border-color: rgba(59, 130, 246, 0.35);
  transform: translateY(-1px);
  box-shadow:
    0 12px 30px rgba(0, 0, 0, 0.2),
    0 0 20px rgba(37, 99, 235, 0.05);
}

.changelog-release-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
}

.changelog-release-header > div {
  min-width: 0;
}

.changelog-release-header h3 {
  margin: 0;
  color: var(--text-primary);
  font-size: 1.15rem;
  font-weight: 700;
  line-height: 1.4;
}

.changelog-version {
  display: inline-flex;
  align-items: center;
  margin-top: 7px;
  padding: 4px 8px;
  border-radius: 6px;
  background: var(--accent-subtle);
  border: 1px solid rgba(37, 99, 235, 0.2);
  color: var(--accent-hover);
  font-size: 0.72rem;
  font-weight: 700;
  line-height: 1;
}

.changelog-date {
  flex-shrink: 0;
  padding-top: 3px;
  color: var(--text-secondary);
  font-size: 0.75rem;
  white-space: nowrap;
}

.changelog-description {
  margin: 16px 0 18px;
  color: var(--text-secondary);
  font-size: 0.9rem;
  line-height: 1.6;
}

.changelog-items {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.changelog-item {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
  padding: 10px 12px;
  background: var(--bg-primary);
  border: 1px solid var(--border-color);
  border-radius: 8px;
  transition:
    background-color 0.18s ease,
    border-color 0.18s ease;
}

.changelog-item:hover {
  background: var(--bg-tertiary);
  border-color: rgba(59, 130, 246, 0.22);
}

.changelog-type {
  flex-shrink: 0;
  min-width: 72px;
  padding: 4px 7px;
  border-radius: 6px;
  font-size: 0.68rem;
  font-weight: 700;
  line-height: 1.2;
  text-align: center;
  text-transform: uppercase;
  letter-spacing: 0.02em;
}

.changelog-text {
  min-width: 0;
  color: var(--text-primary);
  font-size: 0.85rem;
  line-height: 1.5;
  overflow-wrap: anywhere;
}

.changelog-type-added {
  color: #4ade80;
  background: rgba(34, 197, 94, 0.1);
  border: 1px solid rgba(34, 197, 94, 0.18);
}

.changelog-type-improved {
  color: #60a5fa;
  background: rgba(59, 130, 246, 0.1);
  border: 1px solid rgba(59, 130, 246, 0.18);
}

.changelog-type-fixed {
  color: #facc15;
  background: rgba(234, 179, 8, 0.1);
  border: 1px solid rgba(234, 179, 8, 0.18);
}

.changelog-type-security {
  color: #c084fc;
  background: rgba(168, 85, 247, 0.1);
  border: 1px solid rgba(168, 85, 247, 0.18);
}

.changelog-type-removed {
  color: #f87171;
  background: rgba(239, 68, 68, 0.1);
  border: 1px solid rgba(239, 68, 68, 0.18);
}

.changelog-type-breaking {
  color: #fb7185;
  background: rgba(244, 63, 94, 0.1);
  border: 1px solid rgba(244, 63, 94, 0.18);
}

.changelog-type-changed {
  color: var(--text-secondary);
  background: rgba(156, 163, 175, 0.08);
  border: 1px solid rgba(156, 163, 175, 0.14);
}

@media (max-width: 768px) {
  .changelog-page .page-header h2 {
    font-size: 1.6rem;
  }

  .changelog-release {
    padding: 16px;
  }

  .changelog-release-header {
    flex-direction: column;
    gap: 8px;
  }

  .changelog-date {
    padding-top: 0;
  }
}

@media (max-width: 520px) {
  .changelog-item {
    align-items: flex-start;
    flex-direction: column;
    gap: 7px;
  }

  .changelog-type {
    min-width: 0;
  }

  .changelog-text {
    font-size: 0.82rem;
  }
}

.nexusplay-view {
  width: 100%;
  max-width: var(--max-width);
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 24px;
  animation: nexusPlayAppear .4s cubic-bezier(.16, 1, .3, 1);
}

.nexusplay-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding-bottom: 4px;
}

.nexusplay-header h1 {
  margin: 0;
  color: var(--text-primary);
  font-size: 1.9rem;
  font-weight: 700;
  line-height: 1.2;
}

.nexusplay-header p {
  margin: 7px 0 0;
  color: var(--text-secondary);
  font-size: .95rem;
  line-height: 1.5;
}

.nexusplay-status {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 12px;
  border-radius: 999px;
  background: rgba(34, 197, 94, .08);
  border: 1px solid rgba(34, 197, 94, .18);
  color: #86efac;
  font-size: .78rem;
  font-weight: 700;
  white-space: nowrap;
}

.status-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #22c55e;
  box-shadow: 0 0 10px rgba(34, 197, 94, .65);
  animation: nexusPlayPulse 2s ease-in-out infinite;
}

.nexusplay-server-card {
  position: relative;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  gap: 22px;
  padding: 24px;
  background:
    linear-gradient(
      145deg,
      rgba(17, 24, 39, .98),
      rgba(11, 15, 25, .98)
    );
  border: 1px solid var(--border-color);
  border-radius: 20px;
  box-shadow:
    0 14px 35px rgba(0, 0, 0, .22),
    inset 0 1px 0 rgba(255, 255, 255, .025);
}

.nexusplay-server-card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 2px;
  background:
    linear-gradient(
      90deg,
      transparent,
      var(--accent-hover),
      transparent
    );
  opacity: .8;
}

.nexusplay-server-card::after {
  content: "";
  position: absolute;
  width: 220px;
  height: 220px;
  top: -120px;
  right: -80px;
  border-radius: 50%;
  background: rgba(37, 99, 235, .10);
  filter: blur(50px);
  pointer-events: none;
}

.server-info {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  gap: 16px;
}

.server-icon {
  width: 58px;
  height: 58px;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 16px;
  background:
    linear-gradient(
      145deg,
      rgba(59, 130, 246, .18),
      rgba(37, 99, 235, .08)
    );
  border: 1px solid rgba(59, 130, 246, .22);
  color: var(--accent-hover);
  box-shadow:
    inset 0 0 18px rgba(37, 99, 235, .08),
    0 0 20px rgba(37, 99, 235, .06);
}

.server-icon svg {
  width: 28px;
  height: 28px;
  stroke-width: 2;
}

.server-info h2 {
  margin: 0;
  color: var(--text-primary);
  font-size: 1.2rem;
  font-weight: 700;
}

.server-info p {
  margin: 4px 0 0;
  color: var(--text-secondary);
  font-size: .85rem;
}

.server-stats {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
}

.server-stat {
  min-width: 0;
  padding: 14px;
  background: rgba(255, 255, 255, .025);
  border: 1px solid rgba(255, 255, 255, .06);
  border-radius: 12px;
}

.stat-label {
  display: block;
  margin-bottom: 5px;
  color: var(--text-secondary);
  font-size: .72rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: .04em;
}

.stat-value {
  display: block;
  color: var(--text-primary);
  font-size: .9rem;
  font-weight: 700;
}

.stat-value.online {
  color: #4ade80;
}

.nexusplay-join-btn {
  position: relative;
  z-index: 1;
  width: 100%;
  min-height: 48px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  padding: 12px 18px;
  border: 1px solid rgba(96, 165, 250, .25);
  border-radius: 12px;
  background:
    linear-gradient(
      135deg,
      #60a5fa,
      #2563eb
    );
  color: #fff;
  font-size: .9rem;
  font-weight: 700;
  cursor: pointer;
  box-shadow: 0 8px 22px rgba(37, 99, 235, .18);
  transition:
    transform .18s ease,
    filter .18s ease,
    box-shadow .18s ease;
}

.nexusplay-join-btn:hover {
  transform: translateY(-2px);
  filter: brightness(1.06);
  box-shadow: 0 12px 28px rgba(37, 99, 235, .28);
}

.nexusplay-join-btn:active {
  transform: translateY(0) scale(.985);
}

.nexusplay-join-btn svg {
  width: 18px;
  height: 18px;
}

.nexusplay-section {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.nexusplay-section .section-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 0 2px;
}

.nexusplay-section .section-header h2 {
  margin: 0;
  color: var(--text-primary);
  font-size: 1.05rem;
  font-weight: 700;
}

.nexusplay-section .section-header > svg {
  width: 18px;
  height: 18px;
  color: var(--text-secondary);
}

.nexusplay-news-card {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  padding: 18px;
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: var(--card-radius);
  transition:
    transform .18s ease,
    border-color .18s ease,
    background .18s ease;
}

.nexusplay-news-card:hover {
  transform: translateY(-2px);
  border-color: rgba(59, 130, 246, .28);
  background: #131c2c;
}

.news-icon {
  width: 42px;
  height: 42px;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 12px;
  background: var(--accent-subtle);
  border: 1px solid rgba(37, 99, 235, .18);
  color: var(--accent-hover);
}

.news-icon svg {
  width: 20px;
  height: 20px;
}

.nexusplay-news-card h3 {
  margin: 0 0 5px;
  color: var(--text-primary);
  font-size: .95rem;
  font-weight: 700;
}

.nexusplay-news-card p {
  margin: 0;
  color: var(--text-secondary);
  font-size: .85rem;
  line-height: 1.6;
}

.nexusplay-links {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
}

.nexusplay-link {
  width: 100%;
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 16px;
  text-align: left;
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: 14px;
  color: var(--text-primary);
  cursor: pointer;
  transition:
    transform .18s ease,
    background .18s ease,
    border-color .18s ease,
    box-shadow .18s ease;
}

.nexusplay-link:hover {
  transform: translateY(-2px);
  background: #131c2c;
  border-color: rgba(59, 130, 246, .3);
  box-shadow: 0 8px 24px rgba(0, 0, 0, .18);
}

.nexusplay-link > svg {
  width: 21px;
  height: 21px;
  flex-shrink: 0;
  color: var(--accent-hover);
}

.nexusplay-link span {
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 3px;
}

.nexusplay-link strong {
  color: var(--text-primary);
  font-size: .85rem;
  font-weight: 700;
}

.nexusplay-link small {
  color: var(--text-secondary);
  font-size: .72rem;
  line-height: 1.4;
}

@keyframes nexusPlayAppear {
  from {
    opacity: 0;
    transform: translateY(18px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes nexusPlayPulse {
  0%, 100% {
    opacity: 1;
    transform: scale(1);
  }

  50% {
    opacity: .55;
    transform: scale(.82);
  }
}

@media (max-width: 768px) {
  .nexusplay-view {
    gap: 18px;
  }

  .nexusplay-header {
    align-items: flex-start;
    flex-direction: column;
    gap: 12px;
  }

  .nexusplay-header h1 {
    font-size: 1.6rem;
  }

  .nexusplay-server-card {
    padding: 18px;
    border-radius: 18px;
  }

  .server-stats {
    grid-template-columns: 1fr;
  }

  .nexusplay-links {
    grid-template-columns: 1fr;
  }

  .nexusplay-link {
    padding: 14px;
  }
}

@media (max-width: 480px) {
  .nexusplay-server-card {
    padding: 16px;
  }

  .server-info {
    gap: 12px;
  }

  .server-icon {
    width: 50px;
    height: 50px;
    border-radius: 14px;
  }

  .server-icon svg {
    width: 24px;
    height: 24px;
  }

  .server-info h2 {
    font-size: 1.05rem;
  }

  .server-info p {
    font-size: .78rem;
  }

  .nexusplay-news-card {
    padding: 15px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .nexusplay-view, .status-dot, .nexusplay-server-card, .nexusplay-news-card, .nexusplay-link, .nexusplay-join-btn {
    animation: none !important;
    transition: none !important;
  }
}

.server-icon img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: inherit;
  display: block;
}

.nexusplay-verification-card {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 14px 0 16px;
  padding: 14px;
  background: rgba(37, 99, 235, .08);
  border: 1px solid rgba(59, 130, 246, .2);
  border-radius: 14px;
}

.verification-icon {
  width: 40px;
  height: 40px;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 11px;
  background: rgba(59, 130, 246, .14);
  border: 1px solid rgba(59, 130, 246, .2);
  color: var(--accent-hover);
}

.verification-icon svg {
  width: 20px;
  height: 20px;
}

.verification-content {
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 3px;
}

.verification-label {
  color: var(--text-secondary);
  font-size: .72rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: .04em;
}

.verification-content strong {
  overflow: hidden;
  color: var(--text-primary);
  font-size: .95rem;
  font-weight: 700;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.nexusplay-confirm-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.nexusplay-confirm-btn, .nexusplay-cancel-btn {
  min-height: 44px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 10px 14px;
  border-radius: 11px;
  font-size: .85rem;
  font-weight: 700;
  cursor: pointer;
  transition:
    transform .18s ease,
    filter .18s ease,
    background .18s ease,
    border-color .18s ease;
}

.nexusplay-confirm-btn {
  border: 1px solid rgba(96, 165, 250, .25);
  background:
    linear-gradient(
      135deg,
      #60a5fa,
      #2563eb
    );
  color: #fff;
  box-shadow: 0 6px 18px rgba(37, 99, 235, .16);
}

.nexusplay-cancel-btn {
  border: 1px solid var(--border-color);
  background: rgba(255, 255, 255, .025);
  color: var(--text-secondary);
}

.nexusplay-confirm-btn:hover, .nexusplay-cancel-btn:hover {
  transform: translateY(-1px);
}

.nexusplay-confirm-btn:hover {
  filter: brightness(1.06);
}

.nexusplay-cancel-btn:hover {
  background: rgba(255, 255, 255, .05);
  border-color: rgba(255, 255, 255, .12);
  color: var(--text-primary);
}

.nexusplay-confirm-btn:active, .nexusplay-cancel-btn:active {
  transform: translateY(0) scale(.985);
}

.nexusplay-confirm-btn:disabled {
  opacity: .6;
  cursor: not-allowed;
  transform: none;
}

.nexusplay-confirm-btn svg, .nexusplay-cancel-btn svg {
  width: 17px;
  height: 17px;
}

@media (max-width: 480px) {
  .nexusplay-confirm-actions {
    grid-template-columns: 1fr;
  }

  .nexusplay-confirm-btn, .nexusplay-cancel-btn {
    width: 100%;
  }
}

.search-view {
  width: 100%;
  max-width: 900px;
  margin: 0 auto;
  padding: 32px 20px 60px;
}

.search-hero {
  position: relative;
  text-align: center;
  padding: 48px 24px 38px;
  border: 1px solid var(--border-color);
  border-radius: 24px;
  background:
    radial-gradient(
      circle at 50% 0%,
      rgba(99, 102, 241, 0.14),
      transparent 45%), var(--bg-secondary
    );
  overflow: hidden;
}

.search-hero::before {
  content: "";
  position: absolute;
  width: 300px;
  height: 300px;
  top: -180px;
  left: 50%;
  transform: translateX(-50%);
  background: rgba(99, 102, 241, 0.12);
  filter: blur(80px);
  pointer-events: none;
}

.search-hero-icon {
  position: relative;
  width: 64px;
  height: 64px;
  margin: 0 auto 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 18px;
  background: var(--bg-tertiary);
  border: 1px solid var(--border-color);
  color: var(--accent-color);
  box-shadow: 0 12px 35px rgba(0, 0, 0, 0.2);
}

.search-hero-icon svg {
  width: 30px;
  height: 30px;
}

.search-hero h1 {
  position: relative;
  margin: 0;
  font-size: 32px;
  font-weight: 700;
  letter-spacing: -0.8px;
  color: var(--text-primary);
}

.search-hero p {
  position: relative;
  margin: 10px auto 28px;
  max-width: 520px;
  color: var(--text-secondary);
  font-size: 15px;
  line-height: 1.6;
}

.search-box {
  position: relative;
  max-width: 680px;
  margin: 0 auto;
}

.search-box .form-control {
  width: 100%;
  height: 58px;
  padding: 0 76px 0 52px;
  border: 1px solid var(--border-color);
  border-radius: 16px;
  background: var(--bg-primary);
  color: var(--text-primary);
  font-size: 16px;
  outline: none;
  transition:
    border-color 0.2s ease,
    box-shadow 0.2s ease,
    transform 0.2s ease;
}

.search-box .form-control::placeholder {
  color: var(--text-secondary);
}

.search-box .form-control:hover {
  border-color: rgba(99, 102, 241, 0.45);
}

.search-box .form-control:focus {
  border-color: var(--accent-color);
  box-shadow:
    0 0 0 4px rgba(99, 102, 241, 0.12),
    0 12px 35px rgba(0, 0, 0, 0.18);
  transform: translateY(-1px);
}

.search-input-icon {
  position: absolute;
  z-index: 2;
  left: 18px;
  top: 50%;
  width: 21px;
  height: 21px;
  transform: translateY(-50%);
  color: var(--text-secondary);
  pointer-events: none;
  transition: color 0.2s ease;
}

.search-box:focus-within .search-input-icon {
  color: var(--accent-color);
}

.search-box kbd {
  position: absolute;
  right: 16px;
  top: 50%;
  transform: translateY(-50%);
  min-width: 30px;
  height: 28px;
  padding: 0 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--border-color);
  border-radius: 7px;
  background: var(--bg-tertiary);
  color: var(--text-secondary);
  font-family: inherit;
  font-size: 12px;
  font-weight: 600;
}

.search-suggestions {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 20px;
}

.search-suggestions > span {
  margin-right: 4px;
  color: var(--text-secondary);
  font-size: 12px;
}

.search-suggestions button {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 7px 11px;
  border: 1px solid var(--border-color);
  border-radius: 999px;
  background: var(--bg-tertiary);
  color: var(--text-secondary);
  font-family: inherit;
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  transition:
    background 0.2s ease,
    border-color 0.2s ease,
    color 0.2s ease,
    transform 0.2s ease;
}

.search-suggestions button svg {
  width: 14px;
  height: 14px;
}

.search-suggestions button:hover {
  border-color: var(--accent-color);
  color: var(--text-primary);
  background: var(--bg-primary);
  transform: translateY(-1px);
}

.search-results {
  margin-top: 24px;
  min-height: 100px;
}

.search-results:empty {
  display: none;
}

.search-results .search-result-section {
  margin-bottom: 24px;
}

.search-results .search-result-section-title {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 0 0 12px;
  color: var(--text-primary);
  font-size: 15px;
  font-weight: 700;
}

.search-results .search-result-section-title svg {
  width: 17px;
  height: 17px;
  color: var(--accent-color);
}

.search-results .search-result-card {
  padding: 16px;
  margin-bottom: 10px;
  border: 1px solid var(--border-color);
  border-radius: 16px;
  background: var(--bg-secondary);
  transition:
    border-color 0.2s ease,
    transform 0.2s ease,
    background 0.2s ease;
}

.search-results .search-result-card:hover {
  border-color: rgba(99, 102, 241, 0.4);
  background: var(--bg-tertiary);
  transform: translateY(-1px);
}

.search-results .empty-state {
  padding: 50px 20px;
  text-align: center;
  border: 1px dashed var(--border-color);
  border-radius: 20px;
  color: var(--text-secondary);
}

@media (max-width: 600px) {
  .search-view {
    padding: 20px 12px 40px;
  }

  .search-hero {
    padding: 36px 16px 28px;
    border-radius: 20px;
  }

  .search-hero h1 {
    font-size: 26px;
  }

  .search-hero p {
    font-size: 14px;
  }

  .search-suggestions > span {
    width: 100%;
    margin: 0 0 4px;
  }

  .search-box .form-control {
    height: 54px;
  }
}


.gamenight-view {
  width: 100%;
  max-width: var(--max-width);
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 24px;
  animation: gameNightAppear 0.4s cubic-bezier(.16, 1, .3, 1);
}

.gamenight-header {
  position: relative;
  overflow: hidden;
  border: 1px solid var(--border-color);
  border-radius: 18px;
  background:
    linear-gradient(
      135deg,
      rgba(37, 99, 235, 0.10),
      rgba(34, 211, 238, 0.04) 45%,
      var(--bg-secondary) 100%
    );
  box-shadow: 0 12px 35px rgba(0, 0, 0, .18);
}

.gamenight-header::before {
  content: "";
  position: absolute;
  width: 280px;
  height: 280px;
  top: -170px;
  right: -90px;
  border-radius: 50%;
  background: rgba(34, 211, 238, .08);
  filter: blur(45px);
  pointer-events: none;
}

.gamenight-header::after {
  content: "";
  position: absolute;
  width: 220px;
  height: 220px;
  bottom: -160px;
  left: -100px;
  border-radius: 50%;
  background: rgba(37, 99, 235, .08);
  filter: blur(45px);
  pointer-events: none;
}

.gamenight-header-content {
  position: relative;
  z-index: 2;
  display: flex;
  align-items: center;
  gap: 18px;
  padding: 26px;
}

.gamenight-icon {
  width: 58px;
  height: 58px;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 16px;
  color: var(--accent);
  background: rgba(34, 211, 238, .08);
  border: 1px solid rgba(34, 211, 238, .18);
  box-shadow:
    0 8px 25px rgba(34, 211, 238, .08),
    inset 0 1px 0 rgba(255,255,255,.04);
}

.gamenight-icon svg {
  width: 28px;
  height: 28px;
  stroke-width: 2;
}

.gamenight-header h1 {
  color: var(--text-primary);
  font-size: clamp(1.5rem, 3vw, 2rem);
  font-weight: 700;
  letter-spacing: -.035em;
  line-height: 1.2;
}

.gamenight-header p {
  margin-top: 6px;
  color: var(--text-secondary);
  font-size: .9rem;
}

.game-nights-grid {
  width: 100%;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(310px, 1fr));
  gap: 18px;
}

.game-night-card {
  position: relative;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  min-width: 0;
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: var(--card-radius);
  box-shadow:
    0 10px 30px rgba(0, 0, 0, .14),
    inset 0 1px 0 rgba(255,255,255,.025);
  transition:
    transform .22s ease,
    border-color .22s ease,
    box-shadow .22s ease;
}

.game-night-card:hover {
  transform: translateY(-4px);
  border-color: rgba(59, 130, 246, .32);
  box-shadow:
    0 18px 40px rgba(0, 0, 0, .22),
    0 0 25px rgba(37, 99, 235, .06);
}

.game-night-image {
  position: relative;
  width: 100%;
  height: 180px;
  overflow: hidden;
  background: var(--bg-tertiary);
}

.game-night-image img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
  transition:
    transform .45s cubic-bezier(.16, 1, .3, 1),
    filter .3s ease;
}

.game-night-card:hover .game-night-image img {
  transform: scale(1.045);
}

.game-night-image::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(
      to bottom,
      rgba(11,15,25,0) 45%,
      rgba(11,15,25,.42) 100%
    );
  pointer-events: none;
}

.game-night-image-placeholder {
  display: flex;
  align-items: center;
  justify-content: center;
  background:
    radial-gradient(
      circle at center,
      rgba(34,211,238,.08),
      transparent 55% ), var(--bg-tertiary
    );
}

.game-night-image-placeholder svg {
  width: 48px;
  height: 48px;
  color: var(--accent);
  opacity: .7;
}


.game-night-content {
  flex: 1;
  display: flex;
  flex-direction: column;
  padding: 20px;
}

.game-night-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 12px;
}


.game-night-game {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  max-width: 100%;
  padding: 6px 10px;
  border-radius: 999px;
  background: var(--accent-subtle);
  border: 1px solid rgba(37,99,235,.18);
  color: var(--accent-hover);
  font-size: .7rem;
  font-weight: 700;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.game-night-game svg {
  width: 14px;
  height: 14px;
  flex-shrink: 0;
}

.game-night-status {
  display: inline-flex;
  align-items: center;
  padding: 6px 10px;
  border-radius: 999px;
  font-size: .68rem;
  font-weight: 700;
  text-transform: capitalize;
  white-space: nowrap;
  background: rgba(156,163,175,.08);
  border: 1px solid rgba(156,163,175,.12);
  color: var(--text-secondary);
}

.game-night-status-upcoming {
  color: #60a5fa;
  background: rgba(37,99,235,.10);
  border-color: rgba(37,99,235,.18);
}

.game-night-status-live {
  color: #f87171;
  background: rgba(239,68,68,.10);
  border-color: rgba(239,68,68,.20);
}

.game-night-status-full {
  color: #fbbf24;
  background: rgba(245,158,11,.10);
  border-color: rgba(245,158,11,.18);
}

.game-night-status-ended {
  color: var(--text-secondary);
  background: rgba(156,163,175,.08);
  border-color: rgba(156,163,175,.12);
}

.game-night-content h2 {
  color: var(--text-primary);
  font-size: 1.15rem;
  font-weight: 700;
  line-height: 1.35;
  letter-spacing: -.02em;
}

.game-night-description {
  margin-top: 8px;
  margin-bottom: 18px;
  color: var(--text-secondary);
  font-size: .84rem;
  line-height: 1.6;
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 3;
  line-clamp: 3;
  overflow: hidden;
}

.game-night-details {
  display: flex;
  flex-direction: column;
  gap: 9px;
  margin-top: auto;
  padding: 14px 0;
  border-top: 1px solid rgba(255,255,255,.055);
  border-bottom: 1px solid rgba(255,255,255,.055);
}

.game-night-detail {
  display: flex;
  align-items: center;
  gap: 9px;
  min-width: 0;
  color: var(--text-secondary);
  font-size: .78rem;
}

.game-night-detail svg {
  width: 16px;
  height: 16px;
  flex-shrink: 0;
  color: var(--accent-hover);
}

.game-night-detail span {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.game-night-button {
  width: 100%;
  min-height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin-top: 16px;
  padding: 10px 16px;
  border-radius: 10px;
  border: 1px solid rgba(59,130,246,.28);
  background:
    linear-gradient(
      135deg,
      var(--accent-primary),
      #1d4ed8
    );
  color: #fff !important;
  font-size: .82rem;
  font-weight: 700;
  box-shadow: 0 7px 20px rgba(37,99,235,.18);
  transition:
    transform .18s ease,
    filter .18s ease,
    box-shadow .18s ease;
}

.game-night-button:hover {
  color: #fff !important;
  transform: translateY(-2px);
  filter: brightness(1.08);
  box-shadow: 0 10px 25px rgba(37,99,235,.28);
}

.game-night-button:active {
  transform: translateY(0);
}

.game-night-button svg {
  width: 16px;
  height: 16px;
}

.game-night-loading {
  grid-column: 1 / -1;
  min-height: 260px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 12px;
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: 16px;
  color: var(--text-secondary);
  font-size: .85rem;
}

.game-night-loading svg {
  width: 28px;
  height: 28px;
  color: var(--accent);
}

.game-night-loading .spin {
  animation: gameNightSpin .85s linear infinite;
}

.game-night-empty, .game-night-error {
  grid-column: 1 / -1;
  min-height: 300px;
  padding: 40px 24px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  background:
    radial-gradient(
      circle at center,
      rgba(37,99,235,.05),
      transparent 55% ), var(--bg-secondary
    );
  border: 1px solid var(--border-color);
  border-radius: 16px;
}

.game-night-empty-icon, .game-night-error-icon {
  width: 58px;
  height: 58px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 16px;
  border-radius: 16px;
  background: var(--accent-subtle);
  border: 1px solid rgba(37,99,235,.15);
  color: var(--accent-hover);
}

.game-night-empty-icon svg, .game-night-error-icon svg {
  width: 27px;
  height: 27px;
}

.game-night-empty h2, .game-night-error h2 {
  color: var(--text-primary);
  font-size: 1.1rem;
  font-weight: 700;
}

.game-night-empty p, .game-night-error p {
  max-width: 430px;
  margin-top: 7px;
  color: var(--text-secondary);
  font-size: .82rem;
  line-height: 1.6;
}

.game-night-error-icon {
  background: rgba(239,68,68,.08);
  border-color: rgba(239,68,68,.16);
  color: #f87171;
}

.game-night-retry {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin-top: 18px;
  padding: 10px 16px;
  border-radius: 9px;
  border: 1px solid rgba(37,99,235,.22);
  background: var(--accent-subtle);
  color: var(--accent-hover);
  font-family: inherit;
  font-size: .8rem;
  font-weight: 700;
  cursor: pointer;
  transition:
    background .18s ease,
    transform .18s ease,
    border-color .18s ease;
}

.game-night-retry:hover {
  background: rgba(37,99,235,.22);
  border-color: rgba(59,130,246,.35);
  transform: translateY(-2px);
}

.game-night-retry svg {
  width: 16px;
  height: 16px;
}

@keyframes gameNightAppear {
  from {
    opacity: 0;
    transform: translateY(16px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes gameNightSpin {
  from {
    transform: rotate(0deg);
  }

  to {
    transform: rotate(360deg);
  }
}

@media (max-width: 900px) {
  .game-nights-grid {
    grid-template-columns:
      repeat(
        auto-fill,
        minmax(280px, 1fr)
      );
  }
}

@media (max-width: 768px) {
  .gamenight-view {
    gap: 18px;
  }

  .gamenight-header-content {
    padding: 22px;
  }

  .gamenight-icon {
    width: 50px;
    height: 50px;
  }

  .gamenight-icon svg {
    width: 24px;
    height: 24px;
  }

  .game-nights-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 520px) {
  .gamenight-header {
    border-radius: 14px;
  }

  .gamenight-header-content {
    gap: 14px;
    padding: 18px;
  }

  .gamenight-header h1 {
    font-size: 1.35rem;
  }

  .gamenight-header p {
    font-size: .78rem;
  }

  .game-night-image {
    height: 165px;
  }

  .game-night-content {
    padding: 17px;
  }

  .game-night-top {
    align-items: flex-start;
  }

  .game-night-status, .game-night-game {
    font-size: .65rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  .gamenight-view, .game-night-card, .game-night-image img, .game-night-button, .game-night-retry {
    animation: none;
    transition: none;
  }

  .game-night-loading .spin {
    animation: none;
  }
}

.widget-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 16px;
  margin: 20px 0;
  width: 100%;
}

.profile-widget {
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: var(--card-radius);
  padding: 20px;
  margin-bottom: 16px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
  backdrop-filter: blur(12px);
  transition:
    transform 0.2s ease,
    border-color 0.2s ease,
    box-shadow 0.2s ease;
  color: inherit;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.profile-widget:hover {
  border-color:
    color-mix(
      in srgb,
      var(--accent-hover, #3b82f6) 40%,
      rgba(255, 255, 255, 0.15)
    );
  transform: translateY(-2px);
  box-shadow: 0 6px 24px rgba(0, 0, 0, 0.3);
}

.profile-widget .widget-header {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 1rem;
  font-weight: 600;
  margin-bottom: 14px;
  color: var(--text-primary);
}

.profile-widget .widget-header i, .profile-widget .widget-header svg {
  width: 18px;
  height: 18px;
  color: var(--accent-hover);
  stroke-width: 2.2;
  flex-shrink: 0;
}

.widget-sub {
  font-size: 0.85rem;
  color: var(--text-secondary);
  margin-top: -2px;
}

.profile-widget .help-text {
  font-size: 0.85rem;
  color: var(--text-muted);
  margin: 4px 0 0;
  font-style: italic;
}

.text-widget .widget-content {
  font-size: 0.95rem;
  line-height: 1.6;
  color: var(--text-secondary);
  white-space: pre-wrap;
  word-break: break-word;
}

.text-widget p {
  font-size: 0.9rem;
  line-height: 1.5;
  color: var(--text-primary);
  margin: 4px 0 0;
  white-space: pre-wrap;
  word-break: break-word;
}

.music-widget .widget-sub {
  font-size: 0.85rem;
  font-weight: 500;
  color: var(--text-muted);
  margin: 0 0 12px;
}

.widget-audio, .music-widget .widget-audio {
  width: 100%;
  height: 40px;
  margin-top: 6px;
  border-radius: 20px;
  outline: none;
}

.widget-links, .widget-stats {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.links-widget .widget-links {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.widget-links-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
  list-style: none;
}

.profile-widget-link {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 14px;
  background: var(--bg-primary);
  border: 1px solid var(--border-color);
  border-radius: 8px;
  color: var(--text-primary);
  text-decoration: none;
  font-size: 0.875rem;
  font-weight: 500;
  transition:
    border-color 0.2s ease,
    background-color 0.2s ease,
    transform 0.2s ease;
}

.profile-widget-link:hover {
  border-color: var(--accent-hover);
  background: var(--bg-tertiary);
  transform: translateX(2px);
}

.profile-widget-link i, .profile-widget-link svg {
  width: 16px;
  height: 16px;
  color: var(--text-muted);
  flex-shrink: 0;
  transition: color 0.2s ease;
}

.profile-widget-link:hover i, .profile-widget-link:hover svg {
  color: var(--accent-hover);
}

.widget-stats-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 10px;
}

.stats-widget .widget-stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
  gap: 12px;
}

.widget-stat-box, .widget-stat {
  background: var(--bg-primary);
  border: 1px solid var(--border-color);
  border-radius: 8px;
  text-align: center;
}

.widget-stat-box {
  padding: 12px;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.widget-stat {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 16px 12px;
}

.widget-stat-value, .widget-stat strong {
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--text-primary);
  word-break: break-word;
}

.widget-stat-label, .widget-stat span {
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-top: 4px;
}

.profile-widgets-settings {
  grid-column: 1 / -1;
}

.profile-widgets-settings .settings-card-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 18px;
}

.profile-widgets-settings .settings-card-header svg, .profile-widgets-settings .settings-card-header i {
  width: 22px;
  height: 22px;
  color: var(--accent-hover);
  flex-shrink: 0;
}

#settings-widget-editor {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 50px;
  width: 100%;
  min-height: 140px;
  padding: 20px;
  background: var(--bg-primary);
  border: 1px dashed var(--border-color);
  border-radius: var(--card-radius);
  transition: border-color 0.2s ease, background-color 0.2s ease;
}

#settings-widget-editor:hover {
  border-color: var(--accent-hover);
  background: var(--bg-tertiary);
}

#settings-widget-editor:empty {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 12px;
  text-align: center;
}

#settings-widget-editor .help-text {
  margin: 0;
  text-align: center;
}

.widget-add-buttons {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 12px;
  margin-bottom: 20px;
}

.widget-add-btn {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 16px;
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: var(--card-radius);
  color: var(--text-primary);
  cursor: pointer;
  text-align: left;
  transition: border-color 0.2s ease, background-color 0.2s ease, transform 0.2s ease, box-shadow 0.2s ease;
}

.widget-add-btn:hover {
  border-color: var(--accent-hover);
  background: var(--bg-tertiary);
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
}

.widget-add-btn:active {
  transform: translateY(0);
}

.widget-add-btn i, .widget-add-btn svg {
  width: 20px;
  height: 20px;
  color: var(--accent-hover);
  flex-shrink: 0;
}

.widget-add-btn span {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.widget-add-btn strong {
  font-size: 0.9rem;
  font-weight: 600;
  line-height: 1.2;
}

.widget-add-btn small {
  font-size: 0.75rem;
  color: var(--text-muted);
  line-height: 1.3;
}

.widget-edit-item {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: 18px;
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: var(--card-radius);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
  transition: border-color 0.2s ease, box-shadow 0.2s ease, transform 0.2s ease;
}

.widget-edit-item:hover {
  border-color: color-mix(in srgb, var(--accent-hover) 45%, var(--border-color));
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.08);
  transform: translateY(-1px);
}

.widget-edit-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--border-color);
}

.widget-edit-title {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
  font-weight: 600;
  color: var(--text-primary);
}

.widget-edit-title i, .widget-edit-title svg {
  width: 18px;
  height: 18px;
  color: var(--accent-hover);
  flex-shrink: 0;
}

.widget-edit-controls {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-shrink: 0;
}

.widget-links-editor {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-bottom: 4px;
}

.widget-link-edit {
  display: flex;
  align-items: center;
  gap: 8px;
}

.widget-edit-item input, .widget-edit-item textarea, .widget-edit-item select {
  width: 100%;
  padding: 10px 12px;
  background: var(--bg-primary);
  border: 1px solid var(--border-color);
  border-radius: 8px;
  color: var(--text-primary);
  font: inherit;
  outline: none;
  transition: border-color 0.2s ease, box-shadow 0.2s ease, background-color 0.2s ease;
}

.widget-edit-item input:focus, .widget-edit-item textarea:focus, .widget-edit-item select:focus {
  border-color: var(--accent-hover);
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--accent-hover) 15%, transparent);
}

.widget-edit-item textarea {
  min-height: 90px;
  resize: vertical;
}

#settings-widget-editor .profile-widget {
  width: 100%;
  margin-bottom: 0;
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: var(--card-radius);
  padding: 18px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
}

#settings-widget-editor .profile-widget:hover {
  transform: translateY(-2px);
  border-color: color-mix(in srgb, var(--accent-hover) 40%, var(--border-color));
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.08);
}

#settings-widget-editor .widget-header {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 12px;
  font-size: 1rem;
  font-weight: 600;
  color: var(--text-primary);
}

#settings-widget-editor .widget-header i, #settings-widget-editor .widget-header svg {
  width: 18px;
  height: 18px;
  color: var(--accent-hover);
  flex-shrink: 0;
}

#settings-widget-editor .text-widget .widget-content {
  font-size: 0.95rem;
  line-height: 1.6;
  color: var(--text-secondary);
  white-space: pre-wrap;
  word-break: break-word;
}

#settings-widget-editor .music-widget .widget-sub {
  font-size: 0.85rem;
  font-weight: 500;
  color: var(--text-muted);
  margin-bottom: 10px;
}

#settings-widget-editor .music-widget .widget-audio {
  width: 100%;
  height: 38px;
  border-radius: 19px;
}

#settings-widget-editor .profile-widget-link {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 14px;
  background: var(--bg-primary);
  border: 1px solid var(--border-color);
  border-radius: 8px;
  color: var(--text-primary);
  text-decoration: none;
  font-size: 0.875rem;
  font-weight: 500;
  transition: border-color 0.2s ease, background-color 0.2s ease, transform 0.2s ease;
}

#settings-widget-editor .profile-widget-link:hover {
  border-color: var(--accent-hover);
  background: var(--bg-tertiary);
  transform: translateX(2px);
}

#settings-widget-editor .widget-stats, #settings-widget-editor .stats-widget .widget-stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(100px, 1fr));
  gap: 10px;
}

#settings-widget-editor .widget-stat {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 14px 10px;
  background: var(--bg-primary);
  border: 1px solid var(--border-color);
  border-radius: 8px;
  text-align: center;
}

#settings-widget-editor .widget-stat strong {
  font-size: 1.2rem;
  font-weight: 700;
  color: var(--text-primary);
}

#settings-widget-editor .widget-stat span {
  margin-top: 4px;
  font-size: 0.7rem;
  font-weight: 600;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

@media (max-width: 700px) {
  #settings-widget-editor {
    grid-template-columns: 1fr;
    padding: 14px;
  }

  .widget-add-buttons {
    grid-template-columns: 1fr;
  }

  .widget-edit-header {
    align-items: flex-start;
  }

  .widget-link-edit {
    flex-wrap: wrap;
  }
}

#settings-widget-editor {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 50px;
  width: 100%;
  padding: 20px;
  box-sizing: border-box;
}

#settings-widget-editor > * {
  min-width: 0;
  width: 100%;
  box-sizing: border-box;
}

#settings-widget-editor {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  column-gap: 50px;
  row-gap: 20px;
  width: 100%;
  padding: 20px;
  box-sizing: border-box;
}

#settings-widget-editor > .profile-widget {
  min-width: 0;
  width: 100%;
  max-width: 100%;
  margin: 0;
  box-sizing: border-box;
}

.custom-audio-player {
  display: flex;
  align-items: center;
  gap: 12px;
  background-color: #18181b;
  color: #f4f4f5;
  padding: 10px 16px;
  border-radius: 10px;
  font-family: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
  max-width: 500px;
  width: 100%;
  box-sizing: border-box;
  margin: 8px 0;
}

.custom-audio-player button {
  background-color: #2563eb;
  color: #ffffff;
  border: none;
  padding: 8px 14px;
  border-radius: 6px;
  font-size: 0.875rem;
  font-weight: 600;
  cursor: pointer;
  transition: background-color 0.2s ease, transform 0.1s ease;
  min-width: 60px;
  text-align: center;
}

.custom-audio-player button:hover {
  background-color: #1d4ed8;
}

.custom-audio-player button:active {
  transform: scale(0.96);
}

.custom-audio-player .time-display {
  font-size: 0.8rem;
  font-variant-numeric: tabular-nums;
  color: #a1a1aa;
  white-space: nowrap;
}

.custom-audio-player input[type="range"] {
  -webkit-appearance: none;
  appearance: none;
  background: #3f3f46;
  border-radius: 4px;
  height: 6px;
  outline: none;
}

.custom-audio-player input[type="range"]::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: #2563eb;
  cursor: pointer;
  transition: background-color 0.2s ease;
}

.custom-audio-player input[type="range"]::-moz-range-thumb {
  width: 14px;
  height: 14px;
  border: none;
  border-radius: 50%;
  background: #2563eb;
  cursor: pointer;
}

.custom-audio-player input[type="range"]::-webkit-slider-thumb:hover {
  background: #60a5fa;
}

.custom-audio-player .seek-bar {
  flex: 1;
}

.custom-audio-player .volume-container {
  display: flex;
  align-items: center;
  gap: 8px;
}

.custom-audio-player .volume-bar {
  width: 70px;
}

.custom-audio-player {
  display: flex;
  flex-direction: column;
  gap: 12px;
  background-color: #18181b;
  color: #f4f4f5;
  padding: 16px;
  border-radius: 12px;
  font-family: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
  max-width: 500px;
  width: 100%;
  box-sizing: border-box;
  margin: 8px 0;
}

.custom-audio-player .player-header {
  width: 100%;
  text-align: center;
}

.custom-audio-player .track-title {
  font-size: 0.95rem;
  font-weight: 600;
  color: #f4f4f5;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  display: block;
}

.custom-audio-player .player-controls {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.custom-audio-player .play-pause-btn {
  background-color: #2563eb;
  color: #ffffff;
  border: none;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  font-size: 1rem;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: background-color 0.2s ease, transform 0.1s ease;
  flex-shrink: 0;
}

.custom-audio-player .play-pause-btn:hover {
  background-color: #1d4ed8;
}

.custom-audio-player .play-pause-btn:active {
  transform: scale(0.92);
}

.custom-audio-player .time-display {
  font-size: 0.8rem;
  font-variant-numeric: tabular-nums;
  color: #a1a1aa;
  white-space: nowrap;
}

.custom-audio-player .volume-container {
  display: flex;
  align-items: center;
  gap: 8px;
}

.custom-audio-player .mute-btn {
  background: transparent;
  border: none;
  color: #a1a1aa;
  font-size: 0.8rem;
  cursor: pointer;
  padding: 4px 8px;
}

.custom-audio-player .mute-btn:hover {
  color: #ffffff;
}

.custom-audio-player .player-bottom {
  width: 100%;
  display: flex;
}

.custom-audio-player input[type="range"] {
  -webkit-appearance: none;
  appearance: none;
  background: #3f3f46;
  border-radius: 4px;
  height: 6px;
  outline: none;
  width: 100%;
}

.custom-audio-player input[type="range"]::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: #2563eb;
  cursor: pointer;
  transition: background-color 0.2s ease;
}

.custom-audio-player input[type="range"]::-moz-range-thumb {
  width: 14px;
  height: 14px;
  border: none;
  border-radius: 50%;
  background: #2563eb;
  cursor: pointer;
}

.custom-audio-player input[type="range"]::-webkit-slider-thumb:hover {
  background: #60a5fa;
}

.custom-audio-player .volume-bar {
  width: 70px;
}

#main-view .empty-state {
  min-height: 70vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 40px 20px;
  box-sizing: border-box;
}

#main-view .empty-state h2 {
  margin: 0 0 10px;
  font-size: 24px;
  font-weight: 700;
}

#main-view .empty-state p {
  margin: 0 0 24px;
  font-size: 15px;
  line-height: 1.6;
  opacity: 0.7;
}

#main-view .empty-state .btn-primary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 11px 20px;
  border: none;
  border-radius: 10px;
  background: var(--accent-color, #4e84f2bd);
  color: white;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: transform 0.15s ease, opacity 0.15s ease;
}

#main-view .empty-state .btn-primary:hover {
  opacity: 0.9;
  transform: translateY(-1px);
}

#main-view .empty-state .btn-primary:active {
  transform: translateY(0);
}

#css-inspector-overlay {
  position: fixed;
  z-index: 2147483646;

  pointer-events: none;

  box-sizing: border-box;

  border: 2px solid #00ffff;
  background: rgba(0, 255, 255, 0.12);

  box-shadow:
    0 0 12px rgba(0, 255, 255, 0.35);
}

#css-inspector-tooltip {
  position: fixed;
  z-index: 2147483647;

  width: 320px;
  max-width: calc(100vw - 20px);

  padding: 12px;

  background: #111;
  color: #fff;

  border: 1px solid #00ffff;
  border-radius: 10px;

  font-family: monospace;
  font-size: 12px;
  line-height: 1.5;

  pointer-events: none;

  box-shadow:
    0 10px 30px rgba(0, 0, 0, 0.5);

  box-sizing: border-box;
}

#css-inspector-tooltip strong {
  display: block;

  margin-top: 5px;

  color: #aaa;

  font-family: sans-serif;
  font-size: 10px;

  text-transform: uppercase;
}

#css-inspector-tooltip code {
  display: block;

  margin-bottom: 6px;

  color: #00ffff;

  word-break: break-all;
}

#css-inspector-tooltip small {
  display: block;

  margin-top: 8px;

  color: #aaa;

  font-family: sans-serif;
}

#tos-update-notice {
  position: fixed;
  left: 50%;
  bottom: 24px;
  transform: translateX(-50%);
  width: min(520px, calc(100vw - 32px));
  z-index: 99999;

  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: var(--card-radius);
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.35);

  animation: tosNoticeAppear 0.45s cubic-bezier(0.16, 1, 0.3, 1);
}

.tos-update-content {
  padding: 20px;
}

.tos-update-title {
  color: var(--text-primary);
  font-size: 1.05rem;
  font-weight: 700;
  margin-bottom: 8px;
}

.tos-update-text {
  color: var(--text-secondary);
  font-size: 0.9rem;
  line-height: 1.6;
}

.tos-update-date {
  color: var(--text-secondary);
  font-size: 0.75rem;
  margin-top: 10px;
  opacity: 0.8;
}

.tos-update-actions {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
  margin-top: 18px;
}

.tos-update-actions button {
  border: 1px solid var(--border-color);
  border-radius: 8px;
  padding: 9px 14px;

  background: var(--bg-primary);
  color: var(--text-primary);

  font: inherit;
  font-size: 0.85rem;
  font-weight: 600;

  cursor: pointer;
  transition:
    background-color 0.2s ease,
    border-color 0.2s ease,
    transform 0.2s ease;
}

.tos-update-actions button:hover {
  background: var(--bg-secondary);
  border-color: var(--accent-hover);
  transform: translateY(-1px);
}

.tos-update-actions button:active {
  transform: translateY(0);
}

.tos-update-actions button:last-child {
  background: var(--accent-hover);
  border-color: var(--accent-hover);
  color: #fff;
}

.tos-update-actions button:last-child:hover {
  filter: brightness(1.08);
}

@keyframes tosNoticeAppear {
  from {
    opacity: 0;
    transform: translate(-50%, 20px) scale(0.97);
  }

  to {
    opacity: 1;
    transform: translate(-50%, 0) scale(1);
  }
}

@media (max-width: 600px) {
  #tos-update-notice {
    bottom: 12px;
    width: calc(100vw - 24px);
  }

  .tos-update-content {
    padding: 17px;
  }

  .tos-update-actions {
    flex-direction: column;
  }

  .tos-update-actions button {
    width: 100%;
  }
}

.auth-page {
  min-height: 100vh;
  min-height: 100dvh;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  overflow: hidden;
  padding: 32px 20px;
  background:
    radial-gradient(circle at 15% 15%, rgba(0, 162, 255, 0.16), transparent 35%),
    radial-gradient(circle at 85% 85%, rgba(0, 240, 255, 0.12), transparent 35%),
    var(--background, #05070c);
}

.auth-glow {
  position: absolute;
  width: 420px;
  height: 420px;
  border-radius: 50%;
  filter: blur(110px);
  opacity: 0.22;
  pointer-events: none;
}

.auth-glow-1 {
  top: -180px;
  left: -120px;
  background: #0066ff;
}

.auth-glow-2 {
  right: -160px;
  bottom: -180px;
  background: #00e5ff;
}

.auth-card {
  width: min(100%, 440px);
  position: relative;
  z-index: 2;
  padding: 38px;
  border: 1px solid rgba(0, 210, 255, 0.15);
  border-radius: 24px;
  background:
    linear-gradient(
      145deg,
      rgba(0, 162, 255, 0.08),
      rgba(255, 255, 255, 0.02)
    );
  backdrop-filter: blur(30px);
  -webkit-backdrop-filter: blur(30px);
  box-shadow:
    0 30px 80px rgba(0, 0, 0, 0.6),
    0 0 40px rgba(0, 114, 255, 0.1),
    inset 0 1px 0 rgba(0, 229, 255, 0.2);
}

.auth-brand {
  display: flex;
  align-items: center;
  gap: 13px;
  margin-bottom: 34px;
}

.auth-brand-logo {
  width: 40px;
  height: 40px;
  object-fit: contain;
  filter: drop-shadow(0 0 10px rgba(0, 210, 255, 0.5));
}

.auth-brand-icon {
  width: 46px;
  height: 46px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 13px;
  font-size: 21px;
  font-weight: 800;
  color: white;
  background: linear-gradient(135deg, #0066ff, #00e5ff);
  box-shadow: 0 8px 25px rgba(0, 140, 255, 0.4);
}

.auth-brand-text h1 {
  margin: 0;
  color: var(--text-primary, #fff);
  font-size: 20px;
  font-weight: 750;
  letter-spacing: -0.4px;
}

.auth-brand-text span {
  display: block;
  margin-top: 2px;
  color: var(--text-secondary, #7b93b5);
  font-size: 12px;
}

.auth-heading {
  margin-bottom: 28px;
}

.auth-heading h2 {
  margin: 0;
  color: var(--text-primary, #fff);
  font-size: 28px;
  line-height: 1.2;
  letter-spacing: -0.8px;
}

.auth-heading p {
  margin: 9px 0 0;
  color: var(--text-secondary, #8298b8);
  font-size: 14px;
  line-height: 1.55;
}

.auth-link-card {
  max-width: 480px;
}

.auth-link-card .auth-brand {
  margin-bottom: 26px;
}

.auth-link-icon {
  width: 52px;
  height: 52px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 18px;
  border: 1px solid rgba(0, 229, 255, 0.24);
  border-radius: 16px;
  color: #72eaff;
  background: rgba(0, 210, 255, 0.08);
  box-shadow: 0 12px 28px rgba(0, 162, 255, 0.14);
}

.auth-link-icon svg {
  width: 25px;
  height: 25px;
}

.auth-link-note {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  margin: 20px 0;
  padding: 13px 14px;
  border: 1px solid rgba(0, 210, 255, 0.12);
  border-radius: 12px;
  color: #91a9c8;
  background: rgba(0, 162, 255, 0.05);
  font-size: 12px;
  line-height: 1.55;
}

.auth-link-note svg {
  flex: 0 0 auto;
  width: 16px;
  height: 16px;
  margin-top: 1px;
  color: #72eaff;
}

.auth-link-action {
  display: flex;
  justify-content: center;
  min-height: 44px;
}

.auth-link-action > div {
  min-width: min(100%, 240px);
}

.auth-link-action #google-link-required-button {
  display: flex;
  justify-content: center;
}

.auth-link-card .auth-error {
  min-height: 20px;
  margin: 14px 0 18px;
  text-align: center;
}

.auth-link-logout {
  width: 100%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

.auth-link-logout svg {
  width: 16px;
  height: 16px;
}

.auth-form {
  display: flex;
  flex-direction: column;
  gap: 19px;
}

.auth-field {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.auth-field label,
.auth-label-row label {
  color: var(--text-primary, #e2ecff);
  font-size: 13px;
  font-weight: 600;
}

.auth-label-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.auth-input-wrapper {
  position: relative;
  display: flex;
  align-items: center;
}

.auth-input {
  width: 100%;
  height: 50px;
  box-sizing: border-box;
  padding: 0 15px 0 44px;
  border: 1px solid rgba(0, 210, 255, 0.15);
  border-radius: 12px;
  outline: none;
  color: var(--text-primary, #fff);
  background: rgba(0, 10, 25, 0.35);
  font-family: inherit;
  font-size: 14px;
  transition:
    border-color 0.18s ease,
    background 0.18s ease,
    box-shadow 0.18s ease;
}

.auth-input::placeholder {
  color: #526c91;
}

.auth-input:hover {
  border-color: rgba(0, 210, 255, 0.3);
}

.auth-input:focus {
  border-color: #00e5ff;
  background: rgba(0, 15, 35, 0.5);
  box-shadow: 0 0 0 3px rgba(0, 229, 255, 0.2);
}

.auth-input-icon {
  position: absolute;
  left: 16px;
  z-index: 1;
  color: #5c7fa3;
  font-size: 14px;
  pointer-events: none;
}

.auth-password {
  padding-right: 68px;
}

.auth-password-toggle {
  position: absolute;
  right: 8px;
  height: 34px;
  padding: 0 10px;
  border: 0;
  border-radius: 8px;
  color: #7ba6cc;
  background: transparent;
  font-family: inherit;
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  transition:
    color 0.15s ease,
    background 0.15s ease;
}

.auth-password-toggle:hover {
  color: #fff;
  background: rgba(0, 210, 255, 0.1);
}

.auth-forgot,
.auth-switch a,
.auth-footer a {
  color: #38bdf8;
  text-decoration: none;
  transition: color 0.15s ease;
}

.auth-forgot {
  font-size: 12px;
  font-weight: 600;
}

.auth-forgot:hover,
.auth-switch a:hover,
.auth-footer a:hover {
  color: #7dd3fc;
  text-decoration: underline;
}

.auth-error {
  min-height: 18px;
  margin-top: -5px;
  color: var(--danger, #ff4d6d);
  font-size: 13px;
  line-height: 1.4;
}

.auth-submit {
  width: 100%;
  height: 50px;
  border: 0;
  border-radius: 12px;
  color: white;
  background: linear-gradient(135deg, #0066ff, #00e5ff);
  font-family: inherit;
  font-size: 14px;
  font-weight: 700;
  cursor: pointer;
  box-shadow: 0 10px 25px rgba(0, 114, 255, 0.4);
  transition:
    transform 0.15s ease,
    filter 0.15s ease,
    box-shadow 0.15s ease;
}

.auth-submit:hover {
  filter: brightness(1.1);
  transform: translateY(-1px);
  box-shadow: 0 13px 30px rgba(0, 229, 255, 0.5);
}

.auth-submit:active {
  transform: translateY(0);
}

.auth-submit:disabled {
  opacity: 0.6;
  cursor: not-allowed;
  transform: none;
}

.auth-divider {
  display: flex;
  align-items: center;
  gap: 14px;
  margin: 25px 0;
}

.auth-divider::before,
.auth-divider::after {
  content: "";
  flex: 1;
  height: 1px;
  background: rgba(0, 210, 255, 0.15);
}

.auth-divider span {
  color: #526c91;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 1px;
}

.auth-google {
  width: 100%;
  height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  border: 1px solid rgba(0, 210, 255, 0.18);
  border-radius: 12px;
  color: #e2ecff;
  background: rgba(0, 162, 255, 0.04);
  font-family: inherit;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  transition:
    background 0.15s ease,
    border-color 0.15s ease,
    transform 0.15s ease;
}

.auth-google:hover {
  background: rgba(0, 162, 255, 0.1);
  border-color: rgba(0, 229, 255, 0.35);
  transform: translateY(-1px);
}

.google-logo {
  font-family: Arial, sans-serif;
  font-size: 18px;
  font-weight: 700;
}

.auth-switch {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  margin-top: 25px;
  color: #6a88b0;
  font-size: 13px;
  text-align: center;
}

.auth-switch a {
  font-weight: 650;
}

.auth-footer {
  margin-top: 25px;
  color: #486387;
  font-size: 11px;
  line-height: 1.6;
  text-align: center;
}

.auth-footer a {
  color: #6482a8;
}

@media (max-width: 520px) {
  .auth-page {
    padding: 20px 14px;
  }

  .auth-card {
    padding: 28px 22px;
    border-radius: 20px;
  }

  .auth-heading h2 {
    font-size: 25px;
  }

  .auth-brand {
    margin-bottom: 28px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .auth-input,
  .auth-submit,
  .auth-google,
  .auth-password-toggle {
    transition: none;
  }
}

.auth-input-icon {
  position: absolute;
  left: 16px;
  top: 50%;
  transform: translateY(-50%);
  z-index: 1;
  color: #5c7fa3;
  display: flex;
  align-items: center;
  justify-content: center;
  pointer-events: none;
}

.auth-input-icon svg {
  width: 18px;
  height: 18px;
  stroke-width: 2px;
}

.auth-input {
  width: 100%;
  height: 50px;
  box-sizing: border-box;
  padding: 0 16px 0 48px;
  border: 1px solid rgba(0, 210, 255, 0.15);
  border-radius: 12px;
  outline: none;
  color: var(--text-primary, #fff);
  background: rgba(0, 10, 25, 0.35);
  font-family: inherit;
  font-size: 14px;
  transition:
    border-color 0.18s ease,
    background 0.18s ease,
    box-shadow 0.18s ease;
}

.auth-password {
  padding-right: 50px;
}

.auth-password-toggle {
  position: absolute;
  right: 12px;
  top: 50%;
  transform: translateY(-50%);
  height: 34px;
  width: 34px;
  padding: 0;
  border: 0;
  border-radius: 8px;
  color: #7ba6cc;
  background: transparent;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition:
    color 0.15s ease,
    background 0.15s ease;
}

.auth-password-toggle svg {
  width: 18px;
  height: 18px;
  stroke-width: 2px;
}

.auth-password-toggle:hover {
  color: #fff;
  background: rgba(0, 210, 255, 0.1);
}

.auth-input-wrapper {
  display: flex;
  align-items: center;
  border: 1px solid rgba(0, 210, 255, 0.15);
  border-radius: 12px;
  background: rgba(0, 10, 25, 0.35);
  overflow: hidden;
  transition: border-color 0.18s ease, box-shadow 0.18s ease;
}

.auth-input-wrapper:focus-within {
  border-color: #00e5ff;
  box-shadow: 0 0 0 3px rgba(0, 229, 255, 0.2);
}

.auth-icon-box {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 48px;
  height: 50px;
  color: #5c7fa3;
  background: rgba(0, 210, 255, 0.06);
  border-right: 1px solid rgba(0, 210, 255, 0.1);
  flex-shrink: 0;
}

.auth-icon-box svg {
  width: 18px;
  height: 18px;
  stroke-width: 2px;
}

.auth-input {
  flex: 1;
  height: 50px;
  border: none;
  background: transparent;
  padding: 0 16px;
  color: var(--text-primary, #fff);
  font-family: inherit;
  font-size: 14px;
  outline: none;
}

.auth-input::placeholder {
  color: #526c91;
}

.auth-password {
  padding-right: 12px;
}

.auth-input-wrapper {
  display: flex;
  align-items: center;
  border: 1px solid rgba(0, 210, 255, 0.15);
  border-radius: 12px;
  background: rgba(0, 10, 25, 0.35);
  overflow: hidden;
  transition: border-color 0.18s ease, box-shadow 0.18s ease;
}

.auth-input-wrapper:focus-within {
  border-color: #00e5ff;
  box-shadow: 0 0 0 3px rgba(0, 229, 255, 0.2);
}

.auth-icon-box {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 48px;
  height: 50px;
  color: #5c7fa3;
  background: rgba(0, 210, 255, 0.06);
  border-right: 1px solid rgba(0, 210, 255, 0.1);
  border-top-left-radius: 12px;
  border-bottom-left-radius: 12px;
  flex-shrink: 0;
}

.auth-icon-box svg {
  width: 18px;
  height: 18px;
  stroke-width: 2px;
}

.auth-input {
  flex: 1;
  height: 50px;
  border: none;
  background: transparent;
  padding: 0 16px;
  color: var(--text-primary, #fff);
  font-family: inherit;
  font-size: 14px;
  outline: none;
  border-top-left-radius: 0;
  border-bottom-left-radius: 0;
}

.auth-input::placeholder {
  color: #526c91;
}

.auth-password {
  padding-right: 12px;
}

#node-list {
  display: flex;
  flex-direction: column;
  gap: 14px;
  padding-bottom: 40px;
}

#node-list > .content-header {
  margin: 22px 2px 4px;
  padding: 0;
  min-height: auto;
  border: 0;
  background: none;
  box-shadow: none;
}

#node-list > .content-header h2 {
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text-secondary, #8c8c99);
}

/* NODE CARD */

.node-card {
  --node-accent: #7c5cff;

  position: relative;
  isolation: isolate;
  overflow: hidden;

  padding: 0;
  border: 1px solid rgba(255, 255, 255, 0.075);
  border-radius: 20px;

  background:
    linear-gradient(
      145deg,
      rgba(255, 255, 255, 0.065),
      rgba(255, 255, 255, 0.025)
    );

  box-shadow:
    0 8px 30px rgba(0, 0, 0, 0.18),
    inset 0 1px 0 rgba(255, 255, 255, 0.035);

  cursor: pointer;

  transition:
    transform 180ms ease,
    border-color 180ms ease,
    box-shadow 180ms ease,
    background 180ms ease;
}

.node-card::before {
  content: "";

  position: absolute;
  z-index: -2;

  width: 260px;
  height: 260px;

  top: -150px;
  left: -100px;

  border-radius: 50%;

  background: var(--node-accent);

  opacity: 0.075;
  filter: blur(45px);

  pointer-events: none;

  transition:
    opacity 200ms ease,
    transform 300ms ease;
}

.node-card::after {
  content: "";

  position: absolute;
  z-index: -1;

  inset: 0;

  background:
    linear-gradient(
      115deg,
      rgba(124, 92, 255, 0.045),
      transparent 40%
    );

  pointer-events: none;
}

.node-card:hover {
  transform: translateY(-3px);

  border-color: rgba(124, 92, 255, 0.32);

  background:
    linear-gradient(
      145deg,
      rgba(255, 255, 255, 0.075),
      rgba(255, 255, 255, 0.03)
    );

  box-shadow:
    0 14px 45px rgba(0, 0, 0, 0.28),
    0 0 35px rgba(124, 92, 255, 0.075),
    inset 0 1px 0 rgba(255, 255, 255, 0.05);
}

.node-card:hover::before {
  opacity: 0.14;
  transform: scale(1.2);
}

.node-card:active {
  transform: translateY(-1px);
}

/* HEADER */

.node-card .post-header {
  display: flex;
  align-items: center;

  gap: 13px;

  padding: 19px 20px 14px;
}

.node-card .post-header > svg {
  width: 43px;
  height: 43px;

  flex: 0 0 43px;

  padding: 10px;

  border-radius: 14px;

  color: #a995ff;

  background:
    linear-gradient(
      145deg,
      rgba(124, 92, 255, 0.2),
      rgba(124, 92, 255, 0.07)
    );

  border: 1px solid rgba(124, 92, 255, 0.18);

  box-shadow:
    0 0 20px rgba(124, 92, 255, 0.08);
}

.node-card .post-user-info {
  min-width: 0;
}

.node-card .display-name {
  overflow: hidden;

  font-size: 1rem;
  font-weight: 750;
  line-height: 1.3;

  color: var(--text-primary, #f5f5f7);

  text-overflow: ellipsis;
  white-space: nowrap;
}

.node-card .username-handle {
  display: block;

  margin-top: 3px;

  color: var(--text-secondary, #858592);

  font-size: 0.76rem;
  font-weight: 500;
}

/* DESCRIPTION */

.node-card .post-body {
  padding: 0 20px 18px;

  color: var(--text-secondary, #a0a0ac);

  font-size: 0.9rem;
  line-height: 1.65;

  word-break: break-word;
}

/* ACTIONS */

.node-actions {
  display: flex;
  align-items: center;

  gap: 9px;

  padding: 13px 20px 17px;

  border-top: 1px solid rgba(255, 255, 255, 0.055);
}

.node-actions .btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;

  gap: 7px;

  min-height: 37px;

  border-radius: 11px;

  font-size: 0.82rem;
  font-weight: 700;

  transition:
    background 160ms ease,
    border-color 160ms ease,
    transform 160ms ease,
    box-shadow 160ms ease;
}

.node-actions .btn svg {
  width: 15px;
  height: 15px;
}

.node-actions .btn:first-child {
  flex: 1;
}

.node-actions .btn:not(:disabled):hover {
  transform: translateY(-1px);
}

.node-actions .btn:not(:disabled):active {
  transform: translateY(0);
}

/* JOIN BUTTON */

.node-actions .btn:not(.btn-secondary) {
  background:
    linear-gradient(
      135deg,
      #7658ff,
      #6847e8
    );

  border: 1px solid rgba(160, 140, 255, 0.28);

  color: white;

  box-shadow:
    0 5px 18px rgba(105, 75, 230, 0.2);
}

.node-actions .btn:not(.btn-secondary):hover {
  background:
    linear-gradient(
      135deg,
      #846aff,
      #7352f0
    );

  box-shadow:
    0 7px 24px rgba(105, 75, 230, 0.3);
}

/* SECONDARY BUTTON */

.node-actions .btn-secondary {
  background: rgba(255, 255, 255, 0.045);

  border: 1px solid rgba(255, 255, 255, 0.085);

  color: #c4c4ce;
}

.node-actions .btn-secondary:hover {
  background: rgba(255, 255, 255, 0.075);

  border-color: rgba(255, 255, 255, 0.13);

  color: white;
}

/* JOINED NODE */

.joined-node-card {
  --node-accent: #55d89a;

  border-color: rgba(85, 216, 154, 0.13);
}

.joined-node-card:hover {
  border-color: rgba(85, 216, 154, 0.3);

  box-shadow:
    0 14px 45px rgba(0, 0, 0, 0.28),
    0 0 32px rgba(85, 216, 154, 0.055),
    inset 0 1px 0 rgba(255, 255, 255, 0.05);
}

.joined-node-card .post-header > svg {
  color: #70e7ac;

  background:
    linear-gradient(
      145deg,
      rgba(85, 216, 154, 0.18),
      rgba(85, 216, 154, 0.055)
    );

  border-color: rgba(85, 216, 154, 0.17);
}

.node-status {
  display: inline-flex;
  align-items: center;

  gap: 6px;

  margin-left: auto;

  padding: 5px 9px;

  border-radius: 999px;

  background: rgba(85, 216, 154, 0.08);

  border: 1px solid rgba(85, 216, 154, 0.14);

  color: #70dfa7;

  font-size: 0.68rem;
  font-weight: 750;

  white-space: nowrap;
}

.node-status::before {
  content: "";

  width: 6px;
  height: 6px;

  border-radius: 50%;

  background: #65dda2;

  box-shadow: 0 0 8px rgba(101, 221, 162, 0.65);
}

/* EMPTY STATE */

#node-list .empty-state {
  display: flex;
  align-items: center;
  justify-content: center;

  min-height: 180px;

  padding: 30px;

  border: 1px dashed rgba(255, 255, 255, 0.1);
  border-radius: 20px;

  background: rgba(255, 255, 255, 0.02);

  color: #777783;

  font-size: 0.9rem;

  text-align: center;
}

/* MOBILE */

@media (max-width: 600px) {
  #node-list {
    gap: 11px;
  }

  .node-card {
    border-radius: 17px;
  }

  .node-card .post-header {
    padding: 16px 16px 12px;
  }

  .node-card .post-body {
    padding: 0 16px 15px;
  }

  .node-actions {
    padding: 11px 16px 14px;
  }

  .node-card .post-header > svg {
    width: 40px;
    height: 40px;
    flex-basis: 40px;
  }

  .node-status {
    padding: 4px 7px;
  }
}

  @media (max-width: 600px) {
    body { overflow-x: hidden; }
    .app-header { height: 56px; padding: 0 14px; }
    .app-header .btn { min-height: 40px; padding: 8px 12px !important; }
    .app-layout { min-height: calc(100vh - 56px); }
    .sidebar {
      position: sticky;
      top: 56px;
      z-index: 40;
      gap: 4px;
      padding: 8px;
      background: rgba(11, 15, 25, 0.96);
      scrollbar-width: none;
    }
    .sidebar::-webkit-scrollbar { display: none; }
    .nav-item {
      flex: 0 0 auto;
      justify-content: center;
      min-width: 52px;
      min-height: 44px;
      padding: 10px;
      border-radius: 12px;
    }
    .nav-item span { display: none; }
    .main-content { width: 100%; padding: 14px 10px 90px; }
    .page-header { margin: 4px 4px 14px; }
    .post-card, .profile-card, .settings-card {
      padding: 14px;
      margin-bottom: 12px;
      border-radius: 14px;
    }
    .post-body { font-size: 0.94rem; }
    .post-actions { gap: 2px; }
    .post-time { max-width: 92px; text-align: right; }
    .modal-overlay { align-items: flex-end; }
    .modal-card {
      width: calc(100% - 16px);
      max-height: calc(100dvh - 24px);
      margin-bottom: 8px;
      border-radius: 18px 18px 12px 12px;
      overflow-y: auto;
    }
    .fab { right: 16px; bottom: 18px; width: 52px; height: 52px; }
    input, textarea, select, button { font-size: 16px; }
  }

/* NexusNet motion layer: restrained, tactile, and compositor-friendly. */
:root {
  --motion-spring: cubic-bezier(0.22, 1, 0.36, 1);
  --motion-snap: cubic-bezier(0.16, 1, 0.3, 1);
  --motion-soft: cubic-bezier(0.4, 0, 0.2, 1);
}

html { scroll-behavior: smooth; }

.app-header {
  will-change: auto;
}

.app-brand a {
  display: inline-block;
  transition: transform 360ms var(--motion-spring), color 240ms var(--motion-soft);
}

.app-brand a:hover { transform: translateY(-2px) scale(1.025); }

.sidebar {
  will-change: auto;
}

/* 2.5.0 settings workspace */
.settings-page {
  max-width: 1080px;
  gap: 28px;
}

.settings-hero {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 24px;
  padding: 28px 30px;
  border: 1px solid rgba(96, 165, 250, .2);
  border-radius: 24px;
  background: linear-gradient(135deg, rgba(37, 99, 235, .18), rgba(17, 24, 39, .94) 52%, rgba(8, 17, 29, .96));
  box-shadow: 0 18px 42px rgba(0, 0, 0, .25), inset 0 1px rgba(255,255,255,.06);
}

.settings-hero-copy { display: flex; flex-direction: column; gap: 10px; }
.settings-hero h2 { font-size: clamp(2rem, 4vw, 3.2rem); line-height: 1.05; letter-spacing: -.04em; }
.settings-kicker { display: inline-flex; align-items: center; gap: 8px; color: #93c5fd; font-size: .78rem; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; }
.settings-kicker svg { width: 16px; height: 16px; }
.settings-hero-meta { display: flex; flex-direction: column; align-items: flex-end; gap: 10px; white-space: nowrap; }
.settings-version { color: #bfdbfe; font: 600 .78rem ui-monospace, SFMono-Regular, Menlo, monospace; }
.settings-status { display: inline-flex; align-items: center; gap: 7px; color: var(--text-secondary); font-size: .78rem; }
.settings-status-dot { width: 7px; height: 7px; border-radius: 50%; background: #60a5fa; box-shadow: 0 0 0 4px rgba(96,165,250,.12); }

.settings-grid { grid-template-columns: repeat(12, minmax(0, 1fr)); align-items: stretch; gap: 20px; }
.settings-card { grid-column: span 6; min-width: 0; width: 100%; box-sizing: border-box; border-radius: 18px; padding: 24px; background: linear-gradient(155deg, rgba(17,24,39,.98), rgba(8,17,29,.98)); transition: border-color .22s ease, box-shadow .22s ease, transform .22s var(--motion-spring); }
.settings-card > * { min-width: 0; }
.settings-card .customize-row, .settings-card .customize-actions { flex-wrap: wrap; }
.settings-card .form-control, .settings-card select, .settings-card textarea { width: 100%; max-width: 100%; box-sizing: border-box; }
.settings-card:has(.google-font-browser) { grid-column: 1 / -1; }
.google-font-browser { max-height: 300px; overflow-y: auto; padding: 2px; scrollbar-gutter: stable; }
.settings-card:hover { border-color: rgba(96,165,250,.22); box-shadow: 0 16px 34px rgba(0,0,0,.25), inset 0 1px rgba(255,255,255,.04); transform: translateY(-2px); }
.settings-card h3 { letter-spacing: -.015em; }
.settings-card-header { display: flex; align-items: flex-start; justify-content: space-between; }
.settings-card-header > svg { color: #60a5fa; width: 20px; height: 20px; }
.settings-card .form-group { gap: 7px; }
.settings-card .form-control { min-height: 44px; }
.settings-card .btn { min-height: 42px; }
.settings-card input[type="file"] { padding: 9px 12px; }
.profile-widgets-settings, .settings-card:has(.customization-editor-section), .settings-danger { grid-column: 1 / -1; }
.settings-danger { display: grid; grid-template-columns: 1fr auto auto; align-items: center; gap: 12px; }
.settings-danger h3, .settings-danger p { margin: 0; }
.settings-danger .btn { margin: 0; }

@media (max-width: 768px) {
  .settings-hero { align-items: flex-start; flex-direction: column; padding: 22px; }
  .settings-hero-meta { align-items: flex-start; }
  .settings-grid { grid-template-columns: 1fr; }
  .settings-card, .profile-widgets-settings, .settings-card:has(.customization-editor-section), .settings-danger { grid-column: 1; }
  .settings-card { padding: 20px; }
  .settings-danger { display: flex; align-items: stretch; }
}

@media (prefers-reduced-motion: reduce) {
  .settings-card { transition: none; }
  .settings-card:hover { transform: none; }
}

.nav-item {
  position: relative;
  overflow: hidden;
  transition: transform 280ms var(--motion-spring), background-color 240ms var(--motion-soft), color 240ms var(--motion-soft), box-shadow 280ms var(--motion-soft);
}

.nav-item::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(110deg, transparent 20%, rgba(255,255,255,.12) 48%, transparent 76%);
  transform: translateX(-130%);
  transition: transform 600ms var(--motion-snap);
  pointer-events: none;
}

.nav-item:hover { transform: translateX(4px); box-shadow: 0 8px 22px rgba(0,0,0,.16); }
.nav-item:hover::after { transform: translateX(130%); }

.main-content, .right-panel { animation: none; }

.post-card, .profile-card, .settings-card, .node-card {
  transform: translateZ(0);
  transition: transform 420ms var(--motion-spring), border-color 300ms var(--motion-soft), box-shadow 420ms var(--motion-soft), background-color 300ms var(--motion-soft);
  will-change: transform;
}

.post-card:hover, .profile-card:hover, .settings-card:hover, .node-card:hover {
  transform: translateY(-5px) scale(1.006);
  box-shadow: 0 18px 44px rgba(0,0,0,.24), 0 0 0 1px rgba(255,255,255,.025);
}

.post-header .avatar, .profile-header .avatar, .avatar-lg {
  transition: transform 500ms var(--motion-spring), box-shadow 300ms var(--motion-soft);
}

.post-card:hover .avatar, .profile-card:hover .avatar, .profile-card:hover .avatar-lg {
  transform: scale(1.07) rotate(-2deg);
  box-shadow: 0 8px 22px rgba(0,0,0,.28);
}

.btn, .fab, button, .font-choice {
  transition: transform 260ms var(--motion-spring), box-shadow 260ms var(--motion-soft), background-color 240ms var(--motion-soft), border-color 240ms var(--motion-soft), color 240ms var(--motion-soft);
}

.btn:hover, button:hover { transform: translateY(-2px); }
.btn:active, button:active, .fab:active { transform: translateY(1px) scale(.97); }

.form-control, input, textarea, select {
  transition: border-color 240ms var(--motion-soft), box-shadow 300ms var(--motion-soft), transform 300ms var(--motion-spring);
}

.form-control:focus, input:focus, textarea:focus, select:focus {
  transform: translateY(-1px);
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--accent-hover) 17%, transparent), 0 8px 24px rgba(0,0,0,.12);
}

.modal-overlay {
  transition: opacity 360ms var(--motion-soft), visibility 360ms var(--motion-soft), backdrop-filter 360ms var(--motion-soft);
  backdrop-filter: blur(0) saturate(100%);
}

.modal-overlay.open { backdrop-filter: blur(8px) saturate(115%); }
.modal-card { will-change: transform, opacity; }
.modal-overlay:not(.open) .modal-card { transform: translateY(18px) scale(.96) rotateX(3deg); opacity: 0; }
.modal-overlay.open .modal-card { animation: nexus-modal-in 520ms var(--motion-spring) both; }

.fab {
  will-change: auto;
}

.skeleton-block { animation: nexus-shimmer 1.5s linear infinite; background-size: 220% 100%; }

#verity-button {
  animation: nexus-fab-breathe 5s ease-in-out infinite;
}

#verity-modal { transition: opacity 360ms var(--motion-soft), visibility 360ms var(--motion-soft); }
#verity-modal > div { animation: nexus-modal-in 520ms var(--motion-spring) both; }

  @keyframes nexus-modal-in { from { opacity: 0; transform: translateY(24px) scale(.94) rotateX(4deg); } to { opacity: 1; transform: translateY(0) scale(1) rotateX(0); } }

@keyframes nexus-fab-breathe { 0%, 100% { box-shadow: 0 10px 30px rgba(0,0,0,.35); } 50% { box-shadow: 0 15px 38px rgba(105,75,230,.25); } }
@keyframes nexus-shimmer { 0% { background-position: 200% 0; } 100% { background-position: -20% 0; } }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 1ms !important; animation-iteration-count: 1 !important; scroll-behavior: auto !important; transition-duration: 1ms !important; }
  .post-card:hover, .profile-card:hover, .settings-card:hover, .node-card:hover, .nav-item:hover, .btn:hover, button:hover { transform: none; }
}
