/* ===== Canvas ===== */
html, body, #root {
  background: #fff;
  color: #111;
}

/* ===== Top nav (single line, left) ===== */
.topbar, .header, .topbar-inner, .hero {
  display: block;
  width: 100%;
  height: 48px;
  border: 0;
  border-bottom: 1px solid #e5e7eb;
  background: #fff;
  box-shadow: none;
  text-align: left;
}

/* (Optional) tiny logo lockup if present */
.logoWrap, .brandLogoWrap {
  display: inline-block;
  width: 40px;
  height: 40px;
  line-height: 0;
  vertical-align: middle;
  border: 0;
}
.logoWrap img, .brandLogoWrap img,
.logoWrap canvas, .brandLogoWrap canvas,
.logoWrap svg, .brandLogoWrap svg {
  width: 100%;
  height: 100%;
  object-fit: contain;
  display: block;
  border: 0;
}

/* ===== Search bar under nav (left) ===== */
.search, .header__search {
  display: block;
  width: 100%;
  border: 0;
  border-bottom: 1px solid #eef2f7;
  background: #fff;
}
.search input, .header__search input {
  display: inline-block;
  width: 360px;          /* fixed; not responsive */
  height: 32px;
  border: 1px solid #d1d5db;
  background: #fff;
  color: #111;
}

/* ===== Feed (vertical list; all-left) ===== */
.feed, .grid, .content, main, section, .container, .wrapper {
  display: block;
  width: 100%;
  border: 0;
  background: transparent;
  box-shadow: none;
  text-align: left;
}

/* Posts/items — flat list */
.post, .postCard, .composerCard, .rightCard, .thread-item, .card, .panel, .tile, .module, .widget, .sheet, .surface {
  display: block;
  width: 100%;
  border: 0;
  background: transparent;
  box-shadow: none;
  text-align: left;
  border-bottom: 1px solid #f3f4f6; /* thin row divider */
}

/* Chat/bubbles (if present) */
.chatHead, .chatScroll, .composer, .bubble, .leftCol, .rightCol, #messages, .wrap {
  display: block;
  width: 100%;
  border: 0;
  background: transparent;
  box-shadow: none;
  text-align: left;
}

/* Buttons/links — simple */
button, .btn, .pill, .chip, .tag, a {
  display: inline-block;
  height: 32px;
  line-height: 30px;
  border: 1px solid #d1d5db;
  background: #fff;
  color: #111;
  text-decoration: none;
}

/* Inputs/selects — plain */
input, textarea, select {
  border: 1px solid #d1d5db;
  background: #fff;
  color: #111;
}

/* Images/media — block */
img, canvas, video, svg {
  display: block;
  max-width: 100%;
  height: auto;
  border: 0;
}

/* Absolutely no responsive rules */


/* ===== AVATAR — global base clamp ===== */
.avatarMenuRoot .avatarBtn {
  display: inline-flex;
  justify-content: center;
  align-items: center;
  width: 32px;
  height: 32px;
  min-width: 32px;
  min-height: 32px;
  max-width: 32px;
  max-height: 32px;
  flex: 0 0 32px;
  padding: 0;
  line-height: 0;
  border: 0;
  border-radius: 50%;
  overflow: hidden;
  background: transparent;
}

/* media inside fills the circle */
.avatarMenuRoot .avatarBtn > .avatarImg,
.avatarMenuRoot .avatarBtn > img,
.avatarMenuRoot .avatarBtn > canvas,
.avatarMenuRoot .avatarBtn > svg,
.avatarMenuRoot .avatarBtn > .avatarFallback {
  width: 100%;
  height: 100%;
  display: block;
  border-radius: 50%;
  object-fit: cover;
  object-position: center;
}

/* fallback tone */
.avatarMenuRoot .avatarBtn > .avatarFallback {
  display: grid;
  place-items: center;
  font-weight: 900;
  color: #fff;
  background: #0b0b0b;
}
html[data-theme="light"] .avatarMenuRoot .avatarBtn > .avatarFallback {
  background: #e5e7eb;
  color: #111;
}

/* Route-scoped avatar clamps take precedence over global styles */
html[data-route="universe"] .composerAvatarImg,
html[data-route="universe"] .postHeadAvatar,
html[data-route="universe"] .userRowAvatar,
html[data-route="universe"] .commentAvatar{
  width: auto; height: auto; /* let the Universe CSS above set exact px */
}
/* === UNIVERSE: lock composer avatar to 40×40 (wins load order) === */
html[data-route="universe"] .composerTop { 
  grid-template-columns: 40px 1fr; 
  align-items: center;
}
html[data-route="universe"] .composerTop > .composerAvatar { 
  width: 40px; 
  height: 40px; 
  flex: 0 0 40px; 
  overflow: hidden; 
  border-radius: 50%;
}
html[data-route="universe"] .composerTop > .composerAvatar > img.composerAvatarImg {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  border-radius: 50%;
}
/* === UNIVERSE — clamp images inside NOTES === */
html[data-route="universe"] :is(.note, .notes, .noteCard, .noteBody, .noteContent, .noteMedia, .noteText) img,
html[data-route="universe"] :is(.note, .notes, .noteCard, .noteBody, .noteContent, .noteMedia, .noteText) picture img {
  display: block;
  width: 100%;
  height: auto;          /* keep aspect */
  max-height: 40vh;      /* don't let portraits take over */
  object-fit: contain;   /* never crop */
  border: 0;
}

/* if your notes have a dedicated media wrapper, make sure it doesn't force growth */
html[data-route="universe"] :is(.noteMedia, .noteBody, .noteContent) {
  overflow: hidden;      /* trims any weird intrinsic overflow */
}
/* ================================================
   HASH HUMANITY — UNIFIED SHELL LAYOUT
   Used by Universe, Messages, Notifications, etc.
   Root: .hh-page
   ================================================ */

body {
  margin: 0;
}

/* Global layout sanity: padding included in width */
*,
*::before,
*::after {
  box-sizing: border-box;
}


/* ---------- Base page wrapper ---------- */

.hh-page {
  --bg-light: #f5f5f5;
  --bg-dark: #020617;
  --header-light: #f3f3f3;
  --header-dark: #050816;
  --card-light: rgba(255, 255, 255, 0.9);
  --card-dark: rgba(15, 23, 42, 0.92);
  --border-light: #0f172a;
  --border-dark: #e5e7eb;
  --ink-light: #020617;
  --ink-dark: #e5e7eb;

  /* accent system */
  --accent-cyan: #22d3ee;
  --accent-violet: #a855f7;
  --accent-soft: rgba(56, 189, 248, 0.16);
  --accent-soft-2: rgba(244, 114, 182, 0.18);

  min-height: 100vh;
  width: 100%;
  display: flex;
  flex-direction: column;

  /* subtle, expensive “glow” behind everything */
  background:
    radial-gradient(circle at top left,  var(--accent-soft)   0%, transparent 55%),
    radial-gradient(circle at bottom right, var(--accent-soft-2) 0%, transparent 60%),
    #ffffff;

  color: var(--ink-light);
  font-family: system-ui, -apple-system, BlinkMacSystemFont, "SF Pro Text",
    "Segoe UI", sans-serif;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;

  position: relative;
  overflow-x: hidden;
}

/* Dark theme support */
html[data-theme="dark"] .hh-page {
  background:
    radial-gradient(circle at top left,  rgba(56,189,248,0.22) 0%, transparent 55%),
    radial-gradient(circle at bottom right, rgba(168,85,247,0.22) 0%, transparent 60%),
    #020617;
  color: var(--ink-dark);
}

/* Dark theme support */
html[data-theme="dark"] .hh-page {
  background: var(--bg-dark);
  color: var(--ink-dark);
}

/* =========================================================
   FROSTED STICKY HEADER + ICON NAV PILL
   ========================================================= */

.hh-header {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 999;
  display: flex; justify-content: center; align-items: center;
  padding: 10px 18px;

  /* stronger frost */
  background: rgba(245, 245, 245, 0.28);
  backdrop-filter: blur(20px) saturate(160%);
  -webkit-backdrop-filter: blur(20px) saturate(160%);
  border-bottom: 1px solid rgba(0, 0, 0, 0.06);
  box-shadow: 0 10px 28px rgba(15, 23, 42, 0.18);
}

html[data-theme="dark"] .hh-header {
  background: rgba(5, 5, 5, 0.48);
  backdrop-filter: blur(20px) saturate(220%);
  -webkit-backdrop-filter: blur(20px) saturate(220%);
  border-bottom: 1px solid rgba(255, 255, 255, 0.14);
  box-shadow: 0 14px 40px rgba(0, 0, 0, 0.9);
  color: #f5f5f5;
}

/* Center pill that holds all nav icons */
.hh-navRow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 15px;
  border-radius: 999px;
  box-sizing: border-box;

  background: white;
  border: 1px solid rgba(255, 255, 255, 0.7);
  box-shadow: 0 0 5px 1px rgba(0, 0, 0, 0.5);
}

html[data-theme="dark"] .hh-navRow {
  background: radial-gradient(
      circle at top left,
      rgba(16, 16, 16, 0.98),
      rgba(0, 0, 0, 0.78)
    );
  border: 1px solid rgba(255, 255, 255, 0.32);
  box-shadow: 0 0 5px 1px rgba(255, 255, 255, 0.5);
}

/* Nav icon buttons */
.hh-tab {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 30px;
  height: 30px;
  border-radius: 999px;
  border: none;
  background: transparent;
  color: #555;
  cursor: default;
  padding: 0;
  flex-shrink: 0;
  transition: all 0.16s ease;
}

html[data-theme="dark"] .hh-tab {
  color: #ccc;
}

.hh-tab svg {
  width: 18px;
  height: 18px;
  stroke: currentColor;
}

/* Hover only (no route-based active states) */
.hh-tab:hover {
  background: rgba(0, 0, 0, 0.04);
  color: #111;
}

html[data-theme="dark"] .hh-tab:hover {
  background: rgba(255, 255, 255, 0.08);
  color: #fff;
}

/* Brand logo button — centered, stable; uses light/dark JPGs */
.hh-brand {
  position: relative;
  width: 30px;
  height: 30px;
  border: 0;
  padding: 0;
  background: transparent;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  line-height: 0; /* kill inline-gap wobble */
}

/* Base img rules */
.hh-brand img {
  width: 20px;
  height: 20px;
  display: block;
  object-fit: contain;
  -webkit-user-drag: none;
  user-select: none;
}

/* Two stacked icons; hidden by default */
.hh-brand .hh-brand-icon {
  position: absolute;
  inset: 0;         /* centers without subpixel drift */
  margin: auto;
  pointer-events: none;
  display: none;
}

/* --- Theme switches (support html or body carrying data-theme) --- */

/* Light mode: show light icon (black on white JPG) */
html:not([data-theme="dark"]) .hh-brand-icon--light,
body:not([data-theme="dark"]) .hh-brand-icon--light {
  display: block;
}

/* Dark mode: show dark icon (white on black JPG) */
html[data-theme="dark"] .hh-brand-icon--dark,
body[data-theme="dark"] .hh-brand-icon--dark {
  display: block;
}

/* Prevent hover transforms from nudging the image */
.hh-tab.hh-brand:hover .hh-brand-icon { transform: none; }

/* Avatar button */
.avatar-tab {
  width: 30px;
  height: 30px;
  padding: 0;
  border-radius: 999px;
  overflow: hidden;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.avatar-tab img {
  width: 100%;
  height: 100%;
  border-radius: 999px;
  object-fit: cover;
  display: block;
}

/* Theme chip holder */
.hh-themeTab {
  width: 30px;
  height: 30px;
  padding: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.hh-themeTab button {
  width: 100%;
  height: 100%;
  border-radius: 999px;
  border: none;
  background: transparent;
  color: #555;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  cursor: default;
  transition: all 0.16s ease;
}

html[data-theme="dark"] .hh-themeTab button {
  color: #ccc;
}

.hh-themeTab button:hover {
  background: rgba(0, 0, 0, 0.06);
}

html[data-theme="dark"] .hh-themeTab button:hover {
  background: rgba(255, 255, 255, 0.10);
}

/* Unify nav icon base style */
.hh-navRow .hh-tab,
.hh-navRow .hh-brand,
.hh-navRow .avatar-tab,
.hh-navRow .hh-themeTab button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 30px;
  height: 30px;
  padding: 0;
  border-radius: 999px;
  border: none;
  background: transparent;
  cursor: default;
  flex-shrink: 0;
  transition: all 0.18s ease;
}

/* Shared hover: same feel as other pills (Marilyn’s effect) */
.hh-navRow .hh-tab:hover,
.hh-navRow .hh-brand:hover,
.hh-navRow .avatar-tab:hover,
.hh-navRow .hh-themeTab button:hover {
  background: rgba(255, 255, 255, 0.9);
  color: #111827;
  box-shadow: 0 4px 10px rgba(15, 23, 42, 0.18);
  transform: translateY(-1px);
}

html[data-theme="dark"] .hh-navRow .hh-tab:hover,
html[data-theme="dark"] .hh-navRow .hh-brand:hover,
html[data-theme="dark"] .hh-navRow .avatar-tab:hover,
html[data-theme="dark"] .hh-navRow .hh-themeTab button:hover {
  background: rgba(0, 0, 0, 0.9);
  color: #f9fafb;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.9);
}

/* =========================================================
   SHELL GRID
   ========================================================= */

.hh-shell {
  flex: 1;
  display: grid;
  grid-template-columns: minmax(0, 1.25fr) minmax(0, 2fr) minmax(260px, 1.1fr);
  gap: 18px;
  padding: 24px 24px 32px;
  width: 100%;
  max-width: 1440px;
  margin: 80px auto 0;  /* push content down ~80px */
  position: relative;
  z-index: 1;
}

.hh-left,
.hh-center,
.hh-right {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

/* Frosted feed / sidebar cards */
.hh-card {
  cursor: default;
  position: relative;
  padding: 16px 16px 14px;
  border-radius: 22px;
  box-sizing: border-box;

  background:
    radial-gradient(circle at top left, rgba(255,255,255,0.30), rgba(255,255,255,0.03));
  backdrop-filter: blur(20px) saturate(160%);
  -webkit-backdrop-filter: blur(20px) saturate(160%);
  border: 1px solid rgba(255, 255, 255, 0.75);
  box-shadow:
    0 18px 42px rgba(15, 23, 42, 0.26),
    0 4px 10px rgba(15, 23, 42, 0.16);
}

html[data-theme="dark"] .hh-card {
  cursor: default;
  background:
    radial-gradient(circle at top left, rgba(14,14,14,0.98), rgba(0,0,0,0.80));
  backdrop-filter: blur(20px) saturate(240%);
  -webkit-backdrop-filter: blur(20px) saturate(240%);
  border: 1px solid rgba(255, 255, 255, 0.22);
  box-shadow:
    0 18px 42px rgba(0, 0, 0, 0.95),
    0 4px 10px rgba(0, 0, 0, 0.9);
  color: #f5f5f5;
}

/* ============================================================
   HH-SHELL — UNIFIED SEARCH BAR + USER ROWS
   ============================================================ */

/* Wrapper matching card width */
.hh-content-block {
  width: 100%;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

/* Search bar container */
.hh-searchBar {
  display: flex;
  align-items: center;
  gap: 8px;
  width: 100%;
}

/* Iconified search button */
.hh-searchButton {
  width: 32px;
  height: 32px;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  border: none;
  background: var(--ink-dark);
  color: var(--ink-light);
  transition: all 0.15s ease;
}

html[data-theme="dark"] .hh-searchButton {
  background: var(--ink-light);
  color: var(--ink-dark);
}

.hh-searchButton:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(0,0,0,0.25);
}

/* Search results grid */
.hh-searchResults {
  display: grid;
  gap: 10px;
  margin-top: 2px;
}

/* User row */
.hh-userRow {
  width: 100%;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 12px;
  border-radius: 18px;
  cursor: pointer;
  border: 1px solid rgba(15,23,42,0.08);
  background: var(--card-light);
  text-align: left;
  transition: all 0.15s ease;
}

.hh-userRow:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(0,0,0,0.14);
}

html[data-theme="dark"] .hh-userRow {
  background: rgba(0,0,0,0.35);
  border-color: rgba(255,255,255,0.12);
}

/* Avatar for search results */
.hh-avatarSm {
  width: 36px;
  height: 36px;
  border-radius: 999px;
  object-fit: cover;
}

.hh-avatarPlaceholder {
  width: 36px;
  height: 36px;
  border-radius: 999px;
  background: #e5e7eb;
}

html[data-theme="dark"] .hh-avatarPlaceholder {
  background: rgba(255,255,255,0.18);
}

/* Username + displayName stack */
.hh-userMeta {
  display: flex;
  flex-direction: column;
  line-height: 1.2;
}

.hh-userUname {
  font-weight: 600;
}

.hh-userDisplay {
  font-size: 12px;
  opacity: 0.75;
}

/* Empty / error states */
.hh-searchErr,
.hh-searchEmpty {
  margin-top: 6px;
  font-size: 13px;
  opacity: 0.75;
}



/* Inputs / textareas inside cards */
.hh-card input,
.hh-card textarea {
  cursor: default;
  width: 100%;
  font-family: inherit;
  font-size: 14px;
  color: #111827;
  padding: 8px 10px;
  border-radius: 12px;
  border: 1px solid rgba(15, 23, 42, 0.18);
  background: rgba(255, 255, 255, 0.9);
  outline: none;
  box-sizing: border-box;
}

.hh-card input::placeholder,
.hh-card textarea::placeholder {
  cursor: default;
  color: #9ca3af;
}

html[data-theme="dark"] .hh-card input,
html[data-theme="dark"] .hh-card textarea {
  cursor: default;
  background: rgba(12, 12, 12, 0.96);
  color: #f9fafb;
  border: 1px solid rgba(249, 250, 251, 0.28);
}

html[data-theme="dark"] .hh-card input::placeholder,
html[data-theme="dark"] .hh-card textarea::placeholder {
  cursor: default;
  color: #6b7280;
}

/* Generic form helpers */
.hh-input,
.hh-textarea {
  width: 95%;
  font-size: 14px;
  border-radius: 12px;
  padding: 10px 10px;
  border: 1px solid #000;
  outline: none;
  background: #ffffff;
  color: #000;
  font-family: inherit;
}

html[data-theme="dark"] .hh-input,
html[data-theme="dark"] .hh-textarea {
  background: #101010;
  color: #ffffff;
  border: 1px solid #ffffff;
}

.hh-textarea {
  resize: vertical;
  margin-bottom: 10px;
}

.hh-composerActions {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.hh-file {
  font-size: 12px;
  color: inherit;
}

/* Buttons */
.hh-btn {
  padding: 7px 14px;
  border-radius: 999px;
  font-size: 12px;
  cursor: default;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  border: 1px solid rgba(15, 23, 42, 0.22);
  background: rgba(255, 255, 255, 0.96);
  color: #111827;
  font-family: inherit;
  transition: all 0.16s ease;
  text-decoration: none;
}

.hh-btn:hover {
  box-shadow: 0 6px 16px rgba(15, 23, 42, 0.18);
  transform: translateY(-1px);
}

/* Ghost / subtle */
.hh-btn-ghost {
  background: transparent;
  border-color: rgba(148, 163, 253, 0.0);
  color: #6b7280;
}

/* Primary */
.hh-btn-primary {
  background: #000;
  color: #ffffff;
  border-color: #000;
}

.hh-btn-primary:hover {
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.35);
}

/* Dark theme buttons */
html[data-theme="dark"] .hh-btn {
  background: rgba(0, 0, 0, 0.96);
  color: #f9fafb;
  border-color: rgba(249, 250, 251, 0.24);
}

html[data-theme="dark"] .hh-btn-primary {
  background: #ffffff;
  color: #000;
  border-color: #ffffff;
}

.hh-iconButton {
  border: none;
  background: transparent;
  padding: 4px;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
}

.hh-iconButton__icon {
  width: 16px;
  height: 16px;
  fill: var(--ink-muted, #9ca3af);
}

.hh-iconButton:hover .hh-iconButton__icon {
  fill: var(--ink-light, #f9fafb);
}


/* Utilities */
.hh-muted {
  font-size: 12px;
  color: #555;
}

html[data-theme="dark"] .hh-muted {
  color: #aaa;
}

/* Pills */
.hh-pill {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 4px 9px;
  border-radius: 999px;
  font-size: 10px;
  line-height: 1.2;
  box-sizing: border-box;

  background: rgba(255, 255, 255, 0.9);
  color: #111827;
  border: 1px solid rgba(15, 23, 42, 0.12);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}

html[data-theme="dark"] .hh-pill {
  background: rgba(0, 0, 0, 0.9);
  color: #e5e7eb;
  border: 1px solid rgba(229, 231, 235, 0.24);
}

/* =========================================================
   SINGLE-COLUMN VIEWS (e.g. Settings)
   If hh-center is the only child in hh-shell, center it
   and reuse frosted hh-card layout
   ========================================================= */

.hh-shell > .hh-center:only-child {
  grid-column: 1 / -1;
  max-width: 760px;
  margin: 0 auto;
}

/* =========================================================
   RESPONSIVE
   ========================================================= */

@media (max-width: 1100px) {
  .hh-shell {
    grid-template-columns: minmax(0, 1.4fr) minmax(0, 2fr);
    gap: 14px;
  }

  .hh-right {
    display: none;
  }
}

@media (max-width: 768px) {
  .hh-shell {
    grid-template-columns: 1fr;
    gap: 10px;
    padding: 12px;
    margin-top: 56px; /* room for the fixed header */
  }

  .hh-header {
    padding: 8px 10px;
    box-shadow: 0 8px 18px rgba(0, 0, 0, 0.14);
  }

  /* Cards + posts on mobile */
  .hh-card,
  .hh-post {
    padding: 12px;
    border-radius: 16px;
    margin-bottom: 10px; /* readability */
  }

  /* Give the glass something to blur behind on small screens */
  .hh-page::before {
    opacity: 0.55;
  }
}
.hh-card {
  background: linear-gradient(180deg, rgba(255,255,255,.92), rgba(255,255,255,.86));
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border: 1px solid rgba(15,23,42,.12);
  box-shadow: 0 16px 40px rgba(15,23,42,.20);
}
.hh-muted { color: rgba(15,23,42,.72); }
.hh-kv { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size:12px; }
.hh-kv-pill { background:rgba(15,23,42,.06); padding:6px 10px; border-radius:10px; }
.hh-page .hh-card { margin-block: 14px; padding: 18px 20px; }
.hh-card h2 { margin: 2px 0 10px; }
.hh-row { display:flex; align-items:center; gap:10px; }
.hh-state { display:flex; align-items:center; gap:8px; }
.hh-state .ok { color:#059669; }
.hh-state .bad { color:#b91c1c; }

/* =========================================================
   GLOBAL WORLD MAP BACKGROUND LAYER
   Applied behind all .hh-page shells
   ========================================================= */

:root {
  /* gets updated from JS on scroll */
  --hh-scrollY: 0px;
}

/* make sure content sits above the background */
.hh-page {
  position: relative;
  z-index: 1;
  background: transparent;
}

/* =========================================================
   GLOBAL WORLD MAP BACKGROUND LAYER (PARALLAX)
   ========================================================= */
.hh-page::before {
  content: "";
  position: fixed;
  top: 70px;
  left: 0;
  right: 0;
  width: 100%;
  height: 100vh;
  background: url("/world.png") no-repeat center top / cover;
  opacity: 1;
  pointer-events: none;
  z-index: 0;
  filter: grayscale(1);
  /* subtle parallax + tiny scale */
  transform: translate3d(
      0,
      calc(var(--hh-scrollY, 0px) * -0.15),
      0
    )
    scale(1.03);
  transition:
    filter 1900ms ease;
  will-change: transform;
}

/* When theme = dark, invert the map */
html[data-theme="dark"] .hh-page::before {
  filter: grayscale(1) invert(1);
}

/* Explicit light */
html[data-theme="light"] .hh-page::before {
  filter: grayscale(1);
}


/* =========================================================
   PREMIUM UNIVERSE FEED — NOVA LUX EDITION
   ========================================================= */

/* ----------------------------------------
   FROSTED POST CARD (Luxury Glass Module)
   ---------------------------------------- */

.hh-post {
  position: relative;
  padding: 18px 20px 16px;
  border-radius: 22px;
  box-sizing: border-box;
  display: flex;
  flex-direction: column;
  gap: 14px;

  /* ULTRA-LUX GLASS */
  background:
    linear-gradient(
      to bottom right,
      rgba(255, 255, 255, 0.32),
      rgba(255, 255, 255, 0.14)
    );
  backdrop-filter: blur(22px) saturate(180%);
  -webkit-backdrop-filter: blur(22px) saturate(180%);

  /* Subtle chrome border */
  border: 1px solid rgba(255, 255, 255, 0.55);

  /* Cinematic floating glass shadow */
  box-shadow:
    0 22px 60px rgba(0, 0, 0, 0.25),
    0 6px 18px rgba(0, 0, 0, 0.18);
}

/* ----------------------------------------
   DARK MODE: Ultra-premium obsidian glass
   ---------------------------------------- */

html[data-theme="dark"] .hh-post {
  background:
    linear-gradient(
      to bottom right,
      rgba(22, 22, 22, 0.82),
      rgba(10, 10, 10, 0.62)
    );
  backdrop-filter: blur(26px) saturate(260%);
  -webkit-backdrop-filter: blur(26px) saturate(260%);

  border: 1px solid rgba(255, 255, 255, 0.18);

  box-shadow:
    0 26px 70px rgba(0, 0, 0, 0.85),
    0 10px 24px rgba(0, 0, 0, 0.72);

  color: #f8f8f9;
}

/* ----------------------------------------
   HEADER (avatar + name row)
   ---------------------------------------- */

.hh-postHeader {
  display: flex;
  align-items: center;
  gap: 12px;
}

.hh-postUserBtn {
  display: flex;
  align-items: center;
  gap: 10px;
  border: none;
  background: transparent;
  cursor: pointer;
  color: inherit;
}

.hh-postAvatar {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  object-fit: cover;

  /* Subtle ring */
  box-shadow: 0 0 0 2px rgba(255, 255, 255, 0.4);
}

html[data-theme="dark"] .hh-postAvatar {
  box-shadow: 0 0 0 2px rgba(255, 255, 255, 0.14);
}

.hh-postUsername {
  font-weight: 600;
  font-size: 14px;
  letter-spacing: 0.1px;
}

.hh-postTime {
  font-size: 11px;
  opacity: 0.7;
}

/* ----------------------------------------
   TEXT — Pristine and expensive
   ---------------------------------------- */

.hh-postBody,
.hh-commentText {
  white-space: pre-wrap;
  word-break: break-word;
  line-height: 1.55;
  font-size: 14px;
}

/* Premium link styling */
.hh-postBody a,
.hh-commentText a {
  color: #0073ff;
  font-weight: 500;
  text-decoration: none;
  border-bottom: 1px solid rgba(0, 115, 255, 0.35);
  transition: all 0.2s ease;
}

.hh-postBody a:hover,
.hh-commentText a:hover {
  color: #004fcc;
  border-bottom-color: rgba(0, 115, 255, 0.7);
}

html[data-theme="dark"] .hh-postBody a,
html[data-theme="dark"] .hh-commentText a {
  color: #8bb7ff;
  border-bottom-color: rgba(139, 183, 255, 0.35);
}

html[data-theme="dark"] .hh-postBody a:hover,
html[data-theme="dark"] .hh-commentText a:hover {
  color: #d7e5ff;
  border-bottom-color: rgba(139, 183, 255, 0.75);
}

/* ----------------------------------------
   MEDIA — Clean, raised, cinematic
   ---------------------------------------- */

.hh-postImage,
.hh-postVideo {
  width: 100%;
  border-radius: 16px;
  margin-top: 4px;
  object-fit: cover;
  background: #000;

  box-shadow:
    0 10px 30px rgba(0, 0, 0, 0.35),
    0 4px 14px rgba(0, 0, 0, 0.22);

  border: 1px solid rgba(255, 255, 255, 0.35);
}

html[data-theme="dark"] .hh-postImage,
html[data-theme="dark"] .hh-postVideo {
  border-color: rgba(255, 255, 255, 0.14);
}

/* ----------------------------------------
   ACTION PILL ROW — Premium micro-interactions
   ---------------------------------------- */

.hh-postActions {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  margin-top: 4px;
}

.hh-postActions .hh-pill,
.hh-postPulse .hh-pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 4px;

  padding: 5px 14px;
  font-size: 12px;
  font-weight: 500;
  border-radius: 999px;

  background: rgba(255, 255, 255, 0.9);
  backdrop-filter: blur(14px);
  border: 1px solid rgba(0, 0, 0, 0.12);

  transition: all 0.2s ease;
}

.hh-postActions .hh-pill:hover,
.hh-postPulse .hh-pill:hover {
  background: #000;
  color: #fff;
  border-color: #000;
  box-shadow: 0 12px 24px rgba(0, 0, 0, 0.25);
  transform: translateY(-2px);
}

html[data-theme="dark"] .hh-postActions .hh-pill,
html[data-theme="dark"] .hh-postPulse .hh-pill {
  background: rgba(0, 0, 0, 0.92);
  border-color: rgba(255, 255, 255, 0.18);
}

html[data-theme="dark"] .hh-postActions .hh-pill:hover,
html[data-theme="dark"] .hh-postPulse .hh-pill:hover {
  background: #fff;
  color: #000;
}

/* ----------------------------------------
   REPOST CARD — Mini glass card
   ---------------------------------------- */

.hh-postRepostCard {
  margin-top: 8px;
  padding: 10px 12px;
  border-radius: 14px;

  background: rgba(255, 255, 255, 0.2);
  border: 1px solid rgba(255, 255, 255, 0.45);
  backdrop-filter: blur(14px);
}

html[data-theme="dark"] .hh-postRepostCard {
  background: rgba(0, 0, 0, 0.45);
  border-color: rgba(255, 255, 255, 0.22);
}

/* ----------------------------------------
   MOBILE RESPONSIVE EXCELLENCE
   ---------------------------------------- */

@media (max-width: 600px) {
  .hh-post {
    width: 92vw !important;
    margin-left: auto;
    margin-right: auto;
    padding: 16px 16px 14px;
  }

  .hh-postImage,
  .hh-postVideo {
    border-radius: 14px;
  }
}
/* ===============================================
   PREMIUM BACKGROUND — NON-SCROLLING WORLD MAP
   =============================================== */

html, body, #root {
  height: 100%;
  overflow: hidden !important;
  background: transparent !important;
}

/* PAGE WRAPPER */
.hh-page {
  position: relative;
  z-index: 1;
  height: 100vh;
  background: transparent !important;
}

/* FIXED WORLD MAP (Ultra-clean) */
.hh-page::before {
  content: "";
  position: fixed;
  inset: 0;
  width: 100vw;
  height: 100vh;

  background: url("/world.png") center top / cover no-repeat;
  pointer-events: none;
  z-index: 0;

  filter: grayscale(1) brightness(0.88);
  opacity: 1;
}

/* DARK MODE WALLPAPER */
html[data-theme="dark"] .hh-page::before {
  filter: grayscale(1) invert(1) brightness(1.15);
}

/* REMOVE the giant bright gradient */
.hh-page::after {
  display: none !important;
}

/* SCROLL AREA — smooth scrolling */
.hh-scrollArea {
  position: relative;
  height: 100vh;
  overflow-y: auto;
  overflow-x: hidden;
  padding-bottom: 200px;
  -webkit-overflow-scrolling: touch;
  z-index: 5;
}
/* =========================================
   PREMIUM LINK PREVIEW (Nova Luxury Edition)
   ========================================= */

.hh-linkPreviewCard {
  margin-top: 12px;
  width: 100%;
  display: flex;
  overflow: hidden;
  border-radius: 18px;

  /* Premium frosted glass */
  background: rgba(255, 255, 255, 0.22);
  backdrop-filter: blur(20px) saturate(160%);
  -webkit-backdrop-filter: blur(20px) saturate(160%);

  border: 1px solid rgba(255, 255, 255, 0.55);
  text-decoration: none;
  color: #111;

  /* Cinematic floating shadow */
  box-shadow:
    0 18px 50px rgba(0, 0, 0, 0.25),
    0 6px 16px rgba(0, 0, 0, 0.18);
}

/* DARK MODE */
html[data-theme="dark"] .hh-linkPreviewCard {
  background: rgba(0, 0, 0, 0.42);
  border-color: rgba(255, 255, 255, 0.22);
  color: #f1f1f3;
}

/* Thumbnail */
.hh-linkPreviewThumb {
  width: 110px;
  min-width: 110px;
  background-size: cover;
  background-position: center;
  border-right: 1px solid rgba(255,255,255,0.28);
}

/* Dark mode thumb border */
html[data-theme="dark"] .hh-linkPreviewThumb {
  border-right-color: rgba(255,255,255,0.15);
}

/* Body */
.hh-linkPreviewBody {
  flex: 1;
  padding: 12px 14px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  justify-content: center;
}

/* Website name */
.hh-linkPreviewSite {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  opacity: 0.75;
  font-weight: 500;
}

/* Title */
.hh-linkPreviewTitle {
  font-size: 14px;
  font-weight: 600;
  line-height: 1.35;
  overflow: hidden;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}
/* ==========================================================
   DARK MODE — LUXURY LINKS (Guaranteed Override)
   ========================================================== */

html[data-theme="dark"] .hh-postBody a,
html[data-theme="dark"] .hh-commentText a,
html[data-theme="dark"] .hh-linkPreviewBody a,
html[data-theme="dark"] a[href] {
  color: #5eb3ff !important; /* sapphire electric */
  font-weight: 500 !important;
  text-decoration: none !important;

  border-bottom: 1px solid rgba(94, 179, 255, 0.55) !important;

  /* soft neon glow */
  text-shadow:
    0 0 4px rgba(94, 179, 255, 0.55),
    0 0 8px rgba(94, 179, 255, 0.35) !important;

  transition: all 0.22s ease !important;
}

html[data-theme="dark"] .hh-postBody a:hover,
html[data-theme="dark"] .hh-commentText a:hover,
html[data-theme="dark"] .hh-linkPreviewBody a:hover,
html[data-theme="dark"] a[href]:hover {
  color: #b8ddff !important; /* high-end bright */
  border-bottom-color: rgba(184, 221, 255, 0.9) !important;

  text-shadow:
    0 0 6px rgba(184, 221, 255, 0.85),
    0 0 14px rgba(184, 221, 255, 0.5) !important;

  opacity: 1 !important;
}

/* ===========================
   UNIVERSAL LOAD MORE BUTTON FIX
   =========================== */

.hh-load-more {
  margin: 22px auto;
  padding: 10px 16px;
  font-size: 14px;
  font-weight: 600;
  border-radius: 50px;
  display: flex;
  align-items: center;
  justify-content: center;

  /* Visible on both themes */
  background: var(--card-light, rgba(255,255,255,0.85));
  border: 1px solid rgba(0,0,0,0.2);
  color: #000;

  /* Don’t let it get clipped */
  position: relative;
  z-index: 5;
}

html[data-theme="dark"] .hh-load-more {
  background: rgba(0,0,0,0.55);
  color: #fff;
  border: 1px solid rgba(255,255,255,0.25);
}

/* MOBILE FIX */
@media (max-width: 768px) {
  .hh-load-more {
    width: 95%;
  }
}
/* --- Search Container --- */
.hh-search-container {
  position: relative;
  width: 100%;
}

/* --- Dropdown List --- */
.hh-search-dropdown {
  position: absolute;
  top: 46px; /* Enough space below the input */
  left: 0;
  right: 0;

  background: var(--hh-card-bg, #fff);
  border-radius: 12px;
  padding: 10px 0;
  box-shadow: 0 4px 22px rgba(0, 0, 0, 0.25);
  z-index: 9999;

  max-height: 260px;
  overflow-y: auto;
}

/* Dark theme mode */
html[data-theme="dark"] .hh-search-dropdown {
  background: rgba(30, 30, 30, 0.95);
  box-shadow: 0 4px 22px rgba(255, 255, 255, 0.08);
}

/* --- Dropdown Items --- */
.hh-search-item {
  padding: 12px 16px;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 12px;
}

.hh-search-item:hover {
  background: rgba(0, 0, 0, 0.06);
}

html[data-theme="dark"] .hh-search-item:hover {
  background: rgba(255, 255, 255, 0.1);
}

/* ============================================================
   DARK MODE FIX — Make all action buttons + icons WHITE
   ============================================================ */
html[data-theme="dark"] .hh-icon-btn svg,
html[data-theme="dark"] .hh-btn svg {
  stroke: #ffffff !important;
  color: #ffffff !important;
}

html[data-theme="dark"] .hh-icon-btn,
html[data-theme="dark"] .hh-btn {
  color: #ffffff !important;
  border-color: rgba(255, 255, 255, 0.3) !important;
}

html[data-theme="dark"] .hh-input {
  color: #ffffff !important;
}

html[data-theme="dark"] .hh-comment-bubble {
  background: rgba(255, 255, 255, 0.08) !important;
}

html[data-theme="dark"] .hh-card {
  background: rgba(255, 255, 255, 0.06) !important;
  border: 1px solid rgba(255, 255, 255, 0.12) !important;
}
html[data-theme="dark"] .hh-header {
  background: rgba(0, 0, 0, 0.75) !important;
  backdrop-filter: blur(8px);
}
html[data-theme="light"] .hh-header {
  background: rgba(255, 255, 255, 0.9) !important;
  backdrop-filter: blur(8px);
}

/* =========================================================
   NOTIFICATIONS PAGE — LAYOUT + BUTTON POLISH
   ========================================================= */

/* Overall feed */
html[data-route="notifications"] .ntf-feed {
  display: flex;
  flex-direction: column;
  gap: 16px;
  margin-top: 24px;
}

/* Frosted cards, dark text so they're readable on the light map */
html[data-route="notifications"] .ntf-feed .card {
  background: rgba(255, 255, 255, 0.82);
  color: #111;
  border-radius: 22px;
  padding: 16px 18px;
  border: 1px solid rgba(255, 255, 255, 0.95);
  box-shadow:
    0 18px 40px rgba(0, 0, 0, 0.35),
    0 0 0 1px rgba(0, 0, 0, 0.03) inset;
  backdrop-filter: blur(22px) saturate(160%);
  -webkit-backdrop-filter: blur(22px) saturate(160%);
}

/* Section titles + meta text */
html[data-route="notifications"] .ntf-feed .sectionTitle {
  font-weight: 600;
  font-size: 14px;
  margin-bottom: 8px;
}

html[data-route="notifications"] .ntf-feed .meta,
html[data-route="notifications"] .ntf-feed .dim {
  font-size: 12px;
  color: #555;
  opacity: 0.9;
}

/* List + rows */
html[data-route="notifications"] .ntf-feed .list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

html[data-route="notifications"] .ntf-feed .row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

/* ---------------- BUTTONS (All/Unread/Mentions/Mark read/Delete) ---------- */

/* Base button style for this page – this *does* control Mark as read */
html[data-route="notifications"] .ntf-feed .btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 7px 16px;
  border-radius: 999px;
  border: 1px solid rgba(0, 0, 0, 0.12);
  background: rgba(255, 255, 255, 0.95);
  color: #111;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  cursor: pointer;
  text-decoration: none;
  box-shadow: 0 12px 26px rgba(0, 0, 0, 0.18);
  transition:
    background 0.18s ease,
    border-color 0.18s ease,
    box-shadow 0.18s ease,
    transform 0.12s ease;
}

html[data-route="notifications"] .ntf-feed .btn:hover {
  background: rgba(255, 255, 255, 1);
  border-color: rgba(0, 0, 0, 0.20);
  box-shadow: 0 16px 34px rgba(0, 0, 0, 0.26);
  transform: translateY(-1px);
}

html[data-route="notifications"] .ntf-feed .btn:disabled {
  opacity: 0.5;
  cursor: pointer;
  transform: none;
  box-shadow: none;
}

/* Primary action (Mark all as read / Mark read) */
html[data-route="notifications"] .ntf-feed .btn-primary {
  background: #111;
  color: #fff;
  border-color: #111;
  box-shadow:
    0 14px 32px rgba(0, 0, 0, 0.55),
    0 0 0 1px rgba(255, 255, 255, 0.15) inset;
}

html[data-route="notifications"] .ntf-feed .btn-primary:hover {
  background: #000;
  box-shadow:
    0 18px 42px rgba(0, 0, 0, 0.65),
    0 0 0 1px rgba(255, 255, 255, 0.18) inset;
}

/* =========================================================
   MOBILE TIGHTENING — CARDS UP UNDER HEADER + BUTTON LAYOUT
   ========================================================= */

@media (max-width: 768px) {
  /* Pull the content up so first card sits right under the header bar */
  html[data-route="notifications"] .hh-main {
    padding-top: 96px; /* just enough room for the orbit header */
  }

  html[data-route="notifications"] .ntf-feed {
    margin-top: 8px;
    padding: 0 12px 24px;
  }

  html[data-route="notifications"] .ntf-feed .card {
    padding: 14px 14px;
    border-radius: 20px;
  }

  /* Stack text + buttons nicely on small screens */
  html[data-route="notifications"] .ntf-feed .row {
    flex-direction: column;
    align-items: flex-start;
    gap: 10px;
  }

  /* Filters row stays scrollable instead of squished */
  html[data-route="notifications"] .ntf-feed .filters {
    display: flex;
    gap: 8px;
    overflow-x: auto;
    padding-bottom: 4px;
  }

  /* Buttons: slightly bigger tap targets, but still pill-shaped */
  html[data-route="notifications"] .ntf-feed .btn {
    padding: 8px 16px;
    font-size: 11px;
    white-space: nowrap;
  }

  /* For rows with multiple actions (Mark read / Delete), line them up to the right */
  html[data-route="notifications"] .ntf-feed .actionsRow {
    width: 100%;
    display: flex;
    justify-content: flex-end;
    gap: 8px;
    flex-wrap: wrap;
  }
}

/* =========================================================
   NOTIFICATIONS — MOBILE FIXES
   ========================================================= */

@media (max-width: 768px) {

  /* Pull content right under the header */
  html[data-route="notifications"] .hh-main {
    padding-top: 82px !important; /* header is ~70px tall */
  }

  /* Remove extra auto margins pushing cards downward */
  html[data-route="notifications"] .ntf-feed {
    margin-top: 0 !important;
    padding: 0 14px 500px;
  }

  /* Fix card spacing */
  html[data-route="notifications"] .ntf-feed .card {
    margin-top: 2px !important;
    padding: 15px 16px !important;
    border-radius: 20px;
  }

  /* Fix the “mark all as read” row so it stops drifting right */
  html[data-route="notifications"] .ntf-feed .row {
    display: flex;
    flex-direction: column;
    align-items: flex-start !important;
    gap: 10px;
    width: 100%;
  }

  /* Make the mark-all button align left like a normal mobile UI */
  html[data-route="notifications"] .ntf-feed .row .btn {
    align-self: flex-start;
  }

  /* Center or stack filter buttons (All, Mentions, Likes, Other) */
  html[data-route="notifications"] .ntf-feed .filters {
    width: 100%;
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 4px;
  }

  /* Tighter text for readability on small screens */
  html[data-route="notifications"] .ntf-feed .card * {
    font-size: 13px;
    line-height: 1.32;
  }
}
/* =========================================================
   NOTIFICATIONS — BUTTON + LAYOUT POLISH
   ========================================================= */

/* Main feed layout – already good, just here for context */
.ntf-feed {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

/* Header row: title on left, mark-read pill on right */
.ntf-feed .row.header-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

/* Base buttons use your global hh styles */
.ntf-feed .btn {
  composes: hh-btn;
  white-space: nowrap;         /* no ugly text wrapping */
  padding: 8px 16px;
  font-size: 12px;
}

/* Primary pill version (Mark read / Mark read on each card) */
.ntf-feed .btn-primary {
  composes: hh-btn-primary;
}

/* Specific tweak just for the header "Mark read" pill */
.ntf-feed .ntf-mark-read {
  min-width: 0;
  max-width: 999px;
  border-radius: 999px;
}

/* Mobile: keep the header card tucked under the nav */
@media (max-width: 720px) {
  .ntf-page .hh-shell-main {
    padding-top: 110px; /* keeps cards right under the top header bar */
  }

  .ntf-feed .row.header-row {
    align-items: flex-start;
  }

  .ntf-feed .ntf-mark-read {
    font-size: 11px;
    padding: 8px 14px;
  }
}
.hh-icon-btn {
  background: transparent;
  border: none;
  padding: 6px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 8px;
  cursor: pointer;
}
.hh-icon-btn:hover {
  background: rgba(255,255,255,0.1);
}

/* =========================================================
   HASH HUMANITY — MESSAGES PAGE
   Scoped via #messages so nothing else gets touched
   ========================================================= */

#messages {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

/* ---------- Controls card (search + language) ---------- */

#messages .hh-messages-controls {
  margin: 0 auto;
  max-width: 640px;
  padding: 14px 18px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

#messages .hh-messages-controls-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

#messages .hh-messages-searchWrap {
  flex: 1;
  display: flex;
  gap: 8px;
}

#messages .hh-messages-search {
  flex: 1;
}

#messages .hh-messages-searchBtn {
  white-space: nowrap;
}

#messages .hh-messages-langSel {
  display: flex;
  align-items: center;
}

/* Suggestions dropdown */

#messages .hh-messages-suggestions {
  margin-top: 6px;
  border-radius: 16px;
  padding: 6px;
  max-height: 260px;
  overflow-y: auto;
}

#messages .hh-messages-suggestionRow {
  width: 100%;
  border: none;
  background: transparent;
  display: flex;
  align-items: center;
  text-align: left;
  padding: 6px 8px;
  border-radius: 12px;
  cursor: pointer;
}

#messages .hh-messages-suggestionRow:hover {
  background: rgba(0, 0, 0, 0.03);
}

/* ---------- Inbox + Chat layout ---------- */

#messages .hh-messages-layout {
  margin-top: 4px;
}

/* Inbox card */

#messages .hh-messages-inbox {
  display: flex;
  flex-direction: column;
  padding: 16px 14px 18px;
}

#messages .hh-messages-inboxList {
  margin-top: 12px;
  display: flex;
  flex-direction: column;
  gap: 10px;             /* <— main spacing between users */
}

/* Inbox row */

#messages .hh-messages-row {
  border: none;
  background: transparent;
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  column-gap: 10px;
  padding: 8px 10px;      /* inner padding for each user row */
  border-radius: 999px;
  cursor: pointer;
  min-height: 52px;
}

#messages .hh-messages-row--active {
  background: #000;
  color: #fff;
}

#messages .hh-messages-row--active .hh-messages-rowSub {
  opacity: 0.9;
}

#messages .hh-messages-row:hover:not(.hh-messages-row--active) {
  background: rgba(0, 0, 0, 0.03);
}

/* Inbox bits */

#messages .hh-messages-avatar {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #f2f2f2;
  font-size: 18px;
}

#messages .hh-messages-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

#messages .hh-messages-rowContent {
  display: flex;
  flex-direction: column;
  gap: 2px;
  overflow: hidden;
}

#messages .hh-messages-rowName {
  font-size: 13px;
  font-weight: 600;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

#messages .hh-messages-rowSub {
  font-size: 11px;
  color: #777;
  display: flex;
  gap: 4px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

#messages .hh-messages-rowHandle {
  font-weight: 500;
}

#messages .hh-messages-rowLast {
  opacity: 0.8;
}

#messages .hh-messages-rowTime {
  font-size: 11px;
  color: #999;
  padding-left: 6px;
}

#messages .hh-messages-dot {
  display: inline-block;
  width: 7px;
  height: 7px;
  border-radius: 999px;
  background: #06c;
  margin-left: 4px;
}

/* ---------- Chat pane ---------- */

#messages .hh-messages-chat {
  display: flex;
  flex-direction: column;
  padding: 14px 14px 12px;
}

#messages .hh-messages-chatHead {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 4px 2px 10px;
  border-bottom: 1px solid rgba(0, 0, 0, 0.05);
}

#messages .hh-messages-avatar--small {
  width: 28px;
  height: 28px;
  font-size: 16px;
}

#messages .hh-messages-chatName {
  font-weight: 600;
  font-size: 13px;
}

/* Chat scroll area */

#messages .hh-messages-chatScroll {
  flex: 1;
  min-height: 260px;
  max-height: 520px;
  overflow-y: auto;
  padding: 10px 6px 6px;
}

/* Message list */

#messages .hh-messages-group {
  display: flex;
  flex-direction: column;
  gap: 10px;    /* spacing between messages on right side */
}

/* “New messages” divider */

#messages .hh-messages-dividerWrap {
  display: flex;
  justify-content: center;
  margin: 8px 0;
}

#messages .hh-messages-dividerBadge {
  font-size: 11px;
  padding: 3px 10px;
  border-radius: 999px;
  background: rgba(0, 0, 0, 0.05);
}

/* Individual message row */

#messages .hh-messages-rowMsg {
  display: flex;
  justify-content: flex-start;
}

#messages .hh-messages-rowMsg--me {
  justify-content: flex-end;
}

/* Bubbles */

#messages .hh-messages-bubble {
  max-width: 70%;
  padding: 10px 12px 8px;
  border-radius: 18px;
  font-size: 13px;
  background: #f4f4f4;
  box-shadow: 0 8px 22px rgba(15, 23, 42, 0.12);
}

#messages .hh-messages-bubble--me {
  background: #000;
  color: #fff;
}

#messages .hh-messages-img {
  display: block;
  margin-bottom: 6px;
  max-width: 100%;
  border-radius: 16px;
}

/* Timestamp + actions */

#messages .hh-messages-stamp {
  margin-top: 4px;
  font-size: 10px;
  opacity: 0.7;
}

#messages .hh-messages-msgActions {
  margin-top: 6px;
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
}

/* ---------- Composer ---------- */

#messages .hh-messages-composer {
  border-top: 1px solid rgba(0, 0, 0, 0.05);
  margin-top: 10px;
  padding-top: 10px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

#messages .hh-messages-compRow {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  column-gap: 10px;
}

#messages .hh-messages-clip {
  width: 32px;
  height: 32px;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  background: #f5f5f5;
}

#messages .hh-messages-clip svg {
  width: 18px;
  height: 18px;
}

#messages .hh-messages-hiddenFile {
  display: none;
}

#messages .hh-messages-ta {
  resize: none;
  min-height: 38px;
}

#messages .hh-messages-send {
  white-space: nowrap;
}

/* Attachment preview */

#messages .hh-messages-previewRow {
  display: flex;
  align-items: center;
  gap: 8px;
}

#messages .hh-messages-previewImg {
  height: 60px;
  width: auto;
  border-radius: 10px;
  object-fit: cover;
}

/* ---------- Inbox card list: give each row its own card ---------- */

#messages .hh-messages-inboxList {
  margin-top: 12px;
  display: flex;
  flex-direction: column;
  gap: 12px;                     /* more space between people */
}

/* Each person = its own pill-card */
#messages .hh-messages-row {
  position: relative;
  border: none;
  background: #ffffff;          /* white card */
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  column-gap: 10px;
  padding: 10px 12px;
  border-radius: 999px;
  cursor: pointer;
  min-height: 56px;
  box-shadow: 0 10px 24px rgba(15, 23, 42, 0.06); /* soft card shadow */
}

/* Hover state for inactive rows */
#messages .hh-messages-row:hover:not(.hh-messages-row--active) {
  background: #f7f7f7;
}

/* Active row stays black, but still its own card */
#messages .hh-messages-row--active {
  background: #000000;
  color: #ffffff;
}

#messages .hh-messages-row--active .hh-messages-rowSub {
  color: rgba(255, 255, 255, 0.8);
}

#messages .hh-messages-row--active .hh-messages-rowTime {
  color: #f5f5f5;
}

#messages .hh-messages-row--active .hh-messages-avatar {
  background: #111;
}
.hh-icon {
  color: var(--hh-icon);
  stroke: var(--hh-icon);
}
:root {
  --hh-icon: #000; /* light mode default */
}

html[data-theme="dark"] {
  --hh-icon: #fff; /* dark mode icons */
}

/* =========================================================
   HASH HUMANITY — MESSAGES PAGE (ROUTE-SCOPED)
   Only active when <html data-route="messages">
   ========================================================= */

/* ----- Base route styling ----- */
html[data-route="messages"],
html[data-route="messages"] body,
html[data-route="messages"] #root {
  background: #f5f5f5;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* Slightly narrower shell on big screens */
html[data-route="messages"] .hh-shell {
  max-width: 1120px;
  margin: 0 auto;
}

/* =========================================================
   TOP CONTROLS (SEARCH + LANG)
   ========================================================= */

html[data-route="messages"] .hh-messages {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

html[data-route="messages"] .hh-messages-controls {
  padding: 12px 16px;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.97);
  box-shadow: 0 18px 40px rgba(15, 15, 25, 0.14);
}

html[data-route="messages"] .hh-messages-controls-row {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: center;
}

html[data-route="messages"] .hh-messages-searchWrap {
  display: flex;
  flex: 1;
  min-width: 0;
  gap: 8px;
}

html[data-route="messages"] .hh-messages-search {
  flex: 1;
  min-width: 0;
}

html[data-route="messages"] .hh-messages-searchBtn {
  white-space: nowrap;
  padding-inline: 18px;
}

html[data-route="messages"] .hh-messages-langSel {
  display: flex;
  align-items: center;
  gap: 6px;
}

/* Suggestions dropdown */
html[data-route="messages"] .hh-messages-suggestions {
  margin-top: 10px;
  border-radius: 16px;
  background: #ffffff;
  box-shadow: 0 18px 40px rgba(15, 15, 25, 0.18);
  max-height: 260px;
  overflow-y: auto;
}

html[data-route="messages"] .hh-messages-suggestionRow {
  width: 100%;
  padding: 8px 14px;
  display: flex;
  gap: 10px;
  align-items: center;
  border: 0;
  background: transparent;
  cursor: pointer;
}

html[data-route="messages"] .hh-messages-suggestionRow:hover {
  background: rgba(0, 0, 0, 0.03);
}

html[data-route="messages"] .hh-messages-avatar {
  width: 32px;
  height: 32px;
  border-radius: 999px;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #f0f0f0;
  flex-shrink: 0;
}

html[data-route="messages"] .hh-messages-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* =========================================================
   LAYOUT: INBOX + CHAT
   ========================================================= */

html[data-route="messages"] .hh-messages-layout {
  display: flex;
  gap: 16px;
  align-items: stretch;
}

/* Inbox column */
html[data-route="messages"] .hh-messages-inbox {
  width: 320px;
  max-width: 100%;
  padding: 14px 6px 14px 14px;
  border-radius: 22px;
  background: rgba(255, 255, 255, 0.98);
  box-shadow: 0 18px 40px rgba(15, 15, 25, 0.14);
  display: flex;
  flex-direction: column;
}

html[data-route="messages"] .hh-messages-inbox .hh-title {
  padding: 0 4px 8px;
  font-size: 14px;
  font-weight: 600;
}

html[data-route="messages"] .hh-messages-inboxList {
  overflow-y: auto;
  max-height: 540px;
  padding-right: 8px;
}

/* Inbox rows */
html[data-route="messages"] .hh-messages-row {
  width: 100%;
  border: 0;
  background: transparent;
  padding: 8px 10px;
  display: flex;
  gap: 10px;
  align-items: center;
  border-radius: 14px;
  cursor: pointer;
}

html[data-route="messages"] .hh-messages-row:hover {
  background: rgba(0, 0, 0, 0.03);
}

html[data-route="messages"] .hh-messages-row.active {
  background: #ffffff;
  box-shadow: 0 0 0 2px #3b82f6;
}

html[data-route="messages"] .hh-messages-rowContent {
  flex: 1;
  min-width: 0;
}

html[data-route="messages"] .hh-messages-rowName {
  font-size: 13px;
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 6px;
}

html[data-route="messages"] .hh-messages-rowSub {
  font-size: 11px;
  color: #777;
  display: flex;
  gap: 4px;
  overflow: hidden;
}

html[data-route="messages"] .hh-messages-rowHandle {
  flex-shrink: 0;
}

html[data-route="messages"] .hh-messages-rowLast {
  flex: 1;
  min-width: 0;
  text-overflow: ellipsis;
  white-space: nowrap;
  overflow: hidden;
}

html[data-route="messages"] .hh-messages-rowTime {
  font-size: 11px;
  color: #999;
  flex-shrink: 0;
}

html[data-route="messages"] .hh-messages-dot {
  width: 8px;
  height: 8px;
  border-radius: 999px;
  background: #22c55e;
}

/* Chat column */
html[data-route="messages"] .hh-messages-chat {
  flex: 1;
  min-width: 0;
  padding: 12px 14px 10px;
  border-radius: 22px;
  background: rgba(255, 255, 255, 0.98);
  box-shadow: 0 18px 40px rgba(15, 15, 25, 0.14);
  display: flex;
  flex-direction: column;
}

/* Chat header */
html[data-route="messages"] .hh-messages-chatHead {
  display: flex;
  align-items: center;
  gap: 10px;
  padding-bottom: 10px;
  border-bottom: 1px solid rgba(0, 0, 0, 0.06);
  min-height: 44px;
}

html[data-route="messages"] .hh-messages-avatar--small {
  width: 30px;
  height: 30px;
}

html[data-route="messages"] .hh-messages-chatName {
  font-size: 14px;
  font-weight: 600;
}

/* Scroll area */
html[data-route="messages"] .hh-messages-chatScroll {
  flex: 1;
  min-height: 0;
  overflow-y: auto;
  padding: 10px 2px 8px;
}

/* Group container */
html[data-route="messages"] .hh-messages-group {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

/* “New messages” divider */
html[data-route="messages"] .hh-messages-dividerWrap {
  display: flex;
  justify-content: center;
  margin: 8px 0;
}

html[data-route="messages"] .hh-messages-dividerBadge {
  font-size: 11px;
  padding: 3px 10px;
  border-radius: 999px;
  background: rgba(0, 0, 0, 0.06);
  color: #555;
}

/* =========================================================
   BUBBLES (THIS IS WHERE WE KILL THE BLACK)
   ========================================================= */

html[data-route="messages"] .hh-messages-rowMsg {
  display: flex;
  padding: 0 4px;
}

html[data-route="messages"] .hh-messages-rowMsg.me {
  justify-content: flex-end;
}

/* default bubble */
html[data-route="messages"] .hh-messages-bubble {
  max-width: 88%;
  border-radius: 18px;
  padding: 8px 10px 6px;
  font-size: 13px;
  line-height: 1.35;
  color: #111 !important;
  background: #f3f4f6 !important;     /* <<< NO MORE BLACK */
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.1);
}

/* my bubble */
html[data-route="messages"] .hh-messages-bubble.me {
  background: #111827 !important;      /* dark but not pure black */
  color: #f9fafb !important;
}

/* timestamp + actions */
html[data-route="messages"] .hh-messages-stamp {
  margin-top: 4px;
  font-size: 10px;
  opacity: 0.7;
}

html[data-route="messages"] .hh-messages-msgActions {
  display: flex;
  gap: 6px;
  margin-top: 4px;
}

html[data-route="messages"] .hh-messages-img {
  display: block;
  max-width: 260px;
  border-radius: 14px;
  margin-bottom: 4px;
}

/* =========================================================
   COMPOSER
   ========================================================= */

html[data-route="messages"] .hh-messages-composer {
  border-top: 1px solid rgba(0, 0, 0, 0.06);
  padding-top: 8px;
  margin-top: 4px;
}

html[data-route="messages"] .hh-messages-compRow {
  display: flex;
  align-items: flex-end;
  gap: 8px;
}

html[data-route="messages"] .hh-messages-clip {
  width: 32px;
  height: 32px;
  border-radius: 999px;
  border: 1px solid rgba(0, 0, 0, 0.12);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
}

html[data-route="messages"] .hh-messages-hiddenFile {
  display: none;
}

html[data-route="messages"] .hh-messages-ta {
  flex: 1;
  min-height: 32px;
  max-height: 140px;
  resize: none;
}

html[data-route="messages"] .hh-messages-send {
  align-self: stretch;
  padding-inline: 18px;
}

/* preview */
html[data-route="messages"] .hh-messages-previewRow {
  margin-top: 8px;
  display: flex;
  align-items: center;
  gap: 8px;
}

html[data-route="messages"] .hh-messages-previewImg {
  max-width: 120px;
  border-radius: 12px;
}
/* ============================================
   MESSAGES PAGE — LIGHT THEME
   ============================================ */

/* Page background (world map still shows via ::before) */
html[data-theme="light"][data-route="messages"] .hh-page {
  background: #ffffff !important;
}

/* Frosted cards: inbox, chat, top controls */
html[data-theme="light"][data-route="messages"] .hh-messages-inbox,
html[data-theme="light"][data-route="messages"] .hh-messages-chat,
html[data-theme="light"][data-route="messages"] .hh-messages-controls,
html[data-theme="light"][data-route="messages"] .hh-card,
html[data-theme="light"][data-route="messages"] .hh-feed-card {
  background: rgba(255, 255, 255, 0.82) !important;
  backdrop-filter: blur(22px) !important;
  -webkit-backdrop-filter: blur(22px) !important;
  box-shadow: 0 20px 60px rgba(15, 15, 25, 0.18);
  border: 1px solid rgba(0, 0, 0, 0.04);
}

/* Usernames + chat header text = black */
html[data-theme="light"][data-route="messages"] .hh-messages-rowName,
html[data-theme="light"][data-route="messages"] .hh-messages-chatName {
  color: #000000 !important;
}

/* Sub text / handles a bit softer but still dark */
html[data-theme="light"][data-route="messages"] .hh-messages-rowSub,
html[data-theme="light"][data-route="messages"] .hh-messages-rowHandle {
  color: #555555 !important;
}

/* Search bar + bottom message bar: light, not black */
html[data-theme="light"][data-route="messages"] .hh-messages-search input,
html[data-theme="light"][data-route="messages"] .hh-input,
html[data-theme="light"][data-route="messages"] .hh-textarea,
html[data-theme="light"][data-route="messages"] .hh-input-shell,
html[data-theme="light"][data-route="messages"] .hh-message-bar {
  background: rgba(255, 255, 255, 0.96) !important;
  color: #000000 !important;
  border: 1px solid rgba(0, 0, 0, 0.08);
}

/* Placeholder text darker so it’s readable */
html[data-theme="light"][data-route="messages"] .hh-input::placeholder,
html[data-theme="light"][data-route="messages"] .hh-textarea::placeholder {
  color: rgba(0, 0, 0, 0.45);
}

/* Paperclip button visible in light mode */
html[data-theme="light"][data-route="messages"] .hh-messages-clip {
  background: rgba(248, 248, 248, 0.98);
  border: 1px solid rgba(0, 0, 0, 0.10);
}

html[data-theme="light"][data-route="messages"] .hh-messages-clip svg {
  fill: #111111;
  stroke: #111111;
}
/* ============================================
   MESSAGES PAGE — BUTTONS (LIGHT THEME)
   ============================================ */

html[data-theme="light"][data-route="messages"] .hh-btn,
html[data-theme="light"][data-route="messages"] .hh-btn-ghost,
html[data-theme="light"][data-route="messages"] .hh-btn-xs,
html[data-theme="light"][data-route="messages"] .hh-messages-chat button,
html[data-theme="light"][data-route="messages"] .hh-messages-inbox button {
  color: #000000 !important;                      /* <-- black text */
  background: rgba(255, 255, 255, 0.96) !important;
  border: 1px solid rgba(0, 0, 0, 0.18) !important;
  box-shadow: 0 0 5px 1px rgba(0, 0, 0, 0.5);     /* matches your light shadow */
}

/* If you want ghost buttons totally flat but still black text: */
html[data-theme="light"][data-route="messages"] .hh-btn-ghost {
  background: transparent !important;
}

/* =========================================================
   MOBILE STACKING
   ========================================================= */

@media (max-width: 768px) {
  html[data-route="messages"] .hh-shell {
    padding-inline: 10px;
  }

  html[data-route="messages"] .hh-messages-layout {
    flex-direction: column;
  }

  html[data-route="messages"] .hh-messages-inbox,
  html[data-route="messages"] .hh-messages-chat {
    width: 100%;
    max-width: none;
    border-radius: 20px;
  }

  html[data-route="messages"] .hh-messages-inboxList {
    max-height: 260px;
  }

  html[data-route="messages"] .hh-messages-chatScroll {
    max-height: calc(100vh - 360px);
  }

  html[data-route="messages"] .hh-messages-bubble {
    max-width: 92%;
    font-size: 12px;
  }
}

/* ============================
   Messages layout centering
   (desktop + mobile)
   ============================ */

html[data-route="messages"] .hh-main {
  display: flex;
  justify-content: center;
  padding: 16px 12px 32px;
  box-sizing: border-box;
}

/* DESKTOP: push the search bar down below the header */
html[data-route="messages"] .hh-messages-controls {
  margin-top: 80px;   /* tweak this until it clears the nav the way you like */
}

/* MOBILE: give it even more space under the header */
@media (max-width: 768px) {
  html[data-route="messages"] .hh-messages-controls {
    margin-top: 130px;  /* bump up/down as needed */
  }
}

/* =========================================================
   MOBILE — COMPACT CONTROLS & LAYOUT (≤ 768px)
   ========================================================= */
@media (max-width: 768px) {
  /* keep the shell inset a bit from the edges */
  html[data-route="messages"] .hh-shell {
    padding-inline: 10px;
  }

  /* search bar card a bit lower + tighter padding */
  html[data-route="messages"] .hh-messages-controls {
    margin-top: 150px;          /* distance under nav */
    padding: 10px 12px;
  }

  /* stack search+lang vertically instead of one long row */
  html[data-route="messages"] .hh-messages-controls-row {
    flex-direction: column;
    align-items: stretch;
    gap: 8px;
  }

  /* search row: input + Start a bit smaller */
  html[data-route="messages"] .hh-messages-searchWrap {
    gap: 6px;
  }

  html[data-route="messages"] .hh-messages-search {
    font-size: 12px;
    padding-block: 6px;
  }

  html[data-route="messages"] .hh-messages-searchBtn {
    padding: 4px 10px;
    font-size: 12px;
    border-radius: 999px;
  }

  /* language selector: shrink label + select */
  html[data-route="messages"] .hh-messages-langSel {
    justify-content: flex-start;
    gap: 4px;
  }

  html[data-route="messages"] .hh-messages-langSel .hh-muted {
    font-size: 10px;
  }

  html[data-route="messages"] .hh-messages-langSel .hh-input {
    font-size: 12px;
    padding: 4px 8px;
    height: 32px;
  }

  /* stack inbox above chat on mobile */
  html[data-route="messages"] .hh-messages-layout {
    flex-direction: column;
  }

  html[data-route="messages"] .hh-messages-inbox,
  html[data-route="messages"] .hh-messages-chat {
    width: 100%;
    max-width: none;
    border-radius: 20px;
  }

  /* make lists & bubbles a bit more compact vertically */
  html[data-route="messages"] .hh-messages-inboxList {
    max-height: 260px;
  }

  html[data-route="messages"] .hh-messages-chatScroll {
    max-height: calc(100vh - 360px);
  }

  html[data-route="messages"] .hh-messages-bubble {
    max-width: 92%;
    font-size: 12px;
  }
}

/* ============================
   MOBILE LAYOUT FIX
   ============================ */
@media (max-width: 768px) {
  html[data-route="messages"] .hh-shell {
    padding: 0 !important;
    display: flex;
    justify-content: center;
  }

 


  /* Inbox + Chat cards stay centered */
  html[data-route="messages"] .hh-messages-controls,
  html[data-route="messages"] .hh-messages-inbox,
  html[data-route="messages"] .hh-messages-chat {
    width: 100%;
    max-width: 430px;
    margin: 0 auto;
  }

  /* NO translateX (this was the layout killer) */
  html[data-route="messages"] .hh-messages {
    width: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
  }
}

html[data-route="messages"] .hh-messages-chat {
  flex: 1;
  min-width: 0;
  padding: 12px 14px 10px;
  border-radius: 22px;

  /* ✨ FROSTED GLASS */
  background: rgba(255, 255, 255, 0.14) !important;
  backdrop-filter: blur(18px) saturate(180%) !important;
  -webkit-backdrop-filter: blur(18px) saturate(180%) !important;

  border: 1px solid rgba(255, 255, 255, 0.26);
  box-shadow: 0 18px 40px rgba(15, 15, 25, 0.22);

  display: flex;
  flex-direction: column;
}

/* =========================================
   MESSAGES — DARK MODE OVERRIDES
   Make the whole page + cards actually dark
   ========================================= */

html[data-theme="dark"][data-route="messages"] .hh-page {
  background: #000000;
  color: #f5f5f5;
}

/* Main cards (inbox + conversation panel) */
html[data-theme="dark"][data-route="messages"] .hh-card {
  background: rgba(10, 10, 10, 0.92);
  border: 1px solid rgba(255, 255, 255, 0.08);
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.75);
}

/* Inner “sub” cards/bubbles, if you’re using them */
html[data-theme="dark"][data-route="messages"] .hh-card-sub,
html[data-theme="dark"][data-route="messages"] .hh-card-inset {
  background: rgba(18, 18, 18, 0.96);
  border-color: rgba(255, 255, 255, 0.08);
}

/* Inputs / message bar */
html[data-theme="dark"][data-route="messages"] .hh-input,
html[data-theme="dark"][data-route="messages"] .hh-textarea {
  background: rgba(15, 15, 15, 1);
  border: 1px solid rgba(255, 255, 255, 0.18);
  color: #f5f5f5;
}

html[data-theme="dark"][data-route="messages"] .hh-input::placeholder,
html[data-theme="dark"][data-route="messages"] .hh-textarea::placeholder {
  color: rgba(245, 245, 245, 0.55);
}

/* Message-bar shell (the long black bar at the bottom) */
html[data-theme="dark"][data-route="messages"] .hh-input-shell,
html[data-theme="dark"][data-route="messages"] .hh-message-bar {
  background: #000000;
  border-color: rgba(255, 255, 255, 0.18);
}

/* Send button + pills in dark */
html[data-theme="dark"][data-route="messages"] .hh-button-primary {
  background: #ffffff;
  color: #000000;
}

html[data-theme="dark"][data-route="messages"] .hh-pill {
  background: rgba(35, 35, 35, 1);
  color: #f5f5f5;
  border-color: rgba(255, 255, 255, 0.12);
}
.hh-messages-controls {
  margin-bottom: 20px;
  padding: 16px 20px;
}
.hh-icon-btn {
  background: none;
  border: none;
  padding: 6px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  color: var(--ink);
}

.hh-icon-btn:hover {
  color: var(--ink-bright);
}

.hh-icon {
  font-size: 20px;
  line-height: 1;
}
/* Tool buttons inside message bubble */
html[data-route="messages"] .hh-msg-tools {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-top: 6px;
}

/* Each icon button */
html[data-route="messages"] .hh-msg-tool-btn {
  width: 26px;
  height: 26px;
  display: flex;
  justify-content: center;
  align-items: center;
  background: var(--card);
  border-radius: 8px;
  box-shadow: var(--shadow-1);
  cursor: pointer;
  transition: 0.2s ease;
}

html[data-route="messages"] .hh-msg-tool-btn:hover {
  background: var(--card-strong);
  transform: scale(1.05);
}

/* Icon inside */
html[data-route="messages"] .hh-msg-tool-btn svg {
  width: 18px;
  height: 18px;
  color: var(--ink);
}
/* ============================================
   GLOBAL MESSAGES PAGE LAYOUT FIX
   ============================================ */
html[data-route="messages"] .hh-messages {
  width: 100%;
  max-width: 1200px;
  margin: 40px auto 80px;
  display: flex;
  flex-direction: column;
  gap: 32px;
  padding: 0 16px;
}

/* ============================================
   SEARCH BAR CARD — FIX WIDTH + CENTERING
   ============================================ */
html[data-route="messages"] .hh-messages-controls {
  max-width: 780px !important;      /* reduce LONG width */
  width: 100%;
  margin: 0 auto;
  padding: 20px 28px !important;     /* better side padding */
  border-radius: 18px;
}

/* search row cleaner spacing */
html[data-route="messages"] .hh-messages-controls-row {
  display: flex;
  justify-content: center;
  width: 100%;
  margin-bottom: 10px;
}

html[data-route="messages"] .hh-messages-searchWrap {
  max-width: 600px;                /* shorten the bar */
  width: 100%;
  display: flex;
  align-items: center;
  gap: 10px;
}

html[data-route="messages"] .hh-messages-search {
  height: 44px !important;
  border-radius: 12px !important;
  padding: 0 16px !important;
}

/* ============================================
   MAIN LAYOUT: INBOX + CHAT SIDEBY SIDE
   ============================================ */
html[data-route="messages"] .hh-messages-layout {
  display: flex;
  gap: 32px;
  justify-content: center;
  width: 100%;
}

/* inbox column */
html[data-route="messages"] .hh-messages-inbox {
  width: 300px !important;
  min-width: 280px;
  padding: 20px !important;
}

/* chat panel */
html[data-route="messages"] .hh-messages-chat {
  width: 100%;
  max-width: 720px;
  padding: 22px !important;
}

/* fix chat top spacing */
html[data-route="messages"] .hh-messages-chatHead {
  padding-bottom: 16px !important;
}

/* ============================================
   COMPOSER SPACING FIX
   ============================================ */
html[data-route="messages"] .hh-messages-composer {
  margin-top: 18px;
  padding: 16px !important;
  border-radius: 16px;
}

html[data-route="messages"] .hh-messages-ta {
  padding: 12px 14px !important;
  border-radius: 12px !important;
}

/* ============================================================
   MESSAGES PAGE — MOBILE LAYOUT & GENERAL FIXES
   ============================================================ */

@media (max-width: 768px) {
  html[data-route="messages"] .hh-messages-layout {
    flex-direction: column;
    gap: 20px;
  }

  html[data-route="messages"] .hh-messages-inbox,
  html[data-route="messages"] .hh-messages-chat {
    width: 100% !important;
    max-width: 440px;
    margin: 0 auto;
  }

  html[data-route="messages"] .hh-messages-controls {
    max-width: 440px !important;
  }

  html[data-route="messages"] .hh-messages-searchWrap {
    max-width: 380px;
  }
}

/* Light mode wrapper */
html:not(.dark) .messages-wrapper {
  background: rgba(255,255,255,0.32);
  border: 1px solid rgba(0,0,0,0.08);
}

/* Light mode panels */
html:not(.dark) .hh-inbox-panel,
html:not(.dark) .hh-chat-panel {
  background: rgba(255,255,255,0.22) !important;
}

/* Darken Messages cards */
html[data-route="messages"] .glass,
html[data-route="messages"] .panel,
html[data-route="messages"] .hh-card {
  background: rgba(0,0,0,0.78) !important;
}

/* ============================================================
   ICON COLORING — UNIVERSAL + THEME SAFE
   ============================================================ */

/* Messages → base icon logic (all icons inherit --hh-text) */
#messages svg,
#messages .iconify {
  color: var(--hh-text) !important;
  stroke: var(--hh-text) !important;
  fill: var(--hh-text) !important;
}

/* Light mode text token */
[data-theme="light"] #messages {
  --hh-text: #000 !important;
}

/* Dark mode text token */
[data-theme="dark"] #messages {
  --hh-text: #fff !important;
}

/* Explicit Messages icon size */
html[data-route="messages"] .iconify,
html[data-route="messages"] .hh-icon {
  width: 18px;
  height: 18px;
}

/* Messages SVGs inherit correctly */
html[data-route="messages"] .iconify > svg,
html[data-route="messages"] .hh-icon > svg {
  fill: currentColor !important;
  stroke: currentColor !important;
}


/* =========================================
   LANDING PAGE ONLY (data-route="landing")
   ========================================= */

/* Full-height flex column */
html[data-route="landing"] body,
html[data-route="landing"] .hh-page {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

/* Main section layout */
html[data-route="landing"] .hh-page > main {
  flex: 1 0 auto;
  display: flex;
  justify-content: flex-start !important;
  align-items: flex-start !important;
  padding: 48px 16px 32px;
}

/* Center big white panel */
html[data-route="landing"] .hh-page > main .hh-column {
  margin: 0 auto;
  max-width: 960px;
  width: 100%;
  display: flex;
  justify-content: center;
  padding: 40px 24px;
  border-radius: 32px;
  background: rgba(255, 255, 255, 0.9);
  box-shadow: 0 40px 120px rgba(0, 0, 0, 0.35);
}

/* Header spacing */
html[data-route="landing"] .hh-page-header {
  margin-bottom: 24px !important;
}


/* Dark mode frosted card */
html[data-route="landing"][data-theme="dark"] .hh-card {
  background: rgba(18,18,22,0.55) !important;
  border-color: rgba(255,255,255,0.14) !important;
  box-shadow:
    0 20px 58px rgba(0,0,0,0.45),
    0 8px 20px rgba(0,0,0,0.35) !important;
}

/* ============================================================
   CTA BUTTONS (unified, consistent)
   ============================================================ */
html[data-route="landing"] .hh-card button,
html[data-route="landing"] .hh-card a[href="/why-verify"] {
  display: inline-flex;
  align-items: center;
  justify-content: center;

  padding: 12px 22px !important;
  min-width: 180px !important;
  max-width: 210px !important;
  border-radius: 999px;

  font-size: 14px;
  font-weight: 700;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}

html[data-route="landing"] .hh-card button:hover,
html[data-route="landing"] .hh-card a[href="/why-verify"]:hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 28px rgba(0,0,0,0.18);
}

/* Ensure second CTA has spacing */
html[data-route="landing"] .hh-card button + a[href="/why-verify"] {
  margin-top: 10px;
}

/* ============================================================
   HASH HUMANITY TITLE (never wrap)
   ============================================================ */
html[data-route="landing"] .hh-page-header .hh-section-title {
  white-space: nowrap;
  text-align: center;
  font-size: clamp(36px, 4vw, 52px);
  letter-spacing: 0.12em;
  margin-bottom: 8px;
}

/* ============================================================
   FOOTER
   ============================================================ */
html[data-route="landing"] footer.hh-meta {
  margin-top: auto;
  padding: 10px 16px 22px;
}

html[data-route="landing"] footer.hh-meta nav a {
  background: transparent !important;
  padding: 0 !important;
  border: none !important;
  text-decoration: none;
  font-size: 11px;
}

/* ============================================================
   MOBILE (safe, minimal)
   ============================================================ */
@media (max-width: 480px) {
  html[data-route="landing"] .hh-page > main .hh-column {
    padding: 24px 12px;
    border-radius: 24px;
  }

  html[data-route="landing"] .hh-card {
    max-width: 480px !important;
    margin-top: 16px;
  }
}

/* ============================================================
   GLOBAL BASE — RESETS, TOKENS, ICON SYSTEM, TEXT, LINKS
   ============================================================ */

/* ---- Base link reset ---- */
a {
  background: transparent !important;
  padding: 0 !important;
  border: none !important;
  text-decoration: none;
}

a.hh-link,
a.hh-linkified,
a.hh-pill,
a.hh-chip,
.hh-post-body a,
.hh-discussion-body a,
.hh-card-body a:not(.hh-cta),
.hh-meta a:not(.hh-cta) {
  text-decoration: underline;
  text-underline-offset: 2px;
  font-weight: 500;
}

/* ---- Global Ink Tokens ---- */
:root {
  --ink: #000;
  --ink-light: #444;
  --hh-icon-color: #000; /* light mode */
}

[data-theme="dark"] {
  --ink: #fff;
  --ink-light: #ddd;
  --hh-icon-color: #fff;
}

/* ============================================================
   UNIVERSAL ICON FIX — applies to ALL tabs, buttons, nav, profile
   ============================================================ */

svg,
svg * {
  stroke: var(--hh-icon-color) !important;
  color: var(--hh-icon-color) !important;
  fill: none !important;
  opacity: 1 !important;
}

/* Prevent hover opacity bugs */
.hh-icon-btn:hover svg,
.hh-tab:hover svg {
  opacity: 1 !important;
}

/* ---- IconButton component ---- */
.hh-icon-btn {
  background: none !important;
  border: none !important;
  cursor: pointer;
  padding: 6px !important;
  border-radius: 50% !important;
  display: inline-flex !important;
  justify-content: center !important;
  align-items: center !important;
  transition: opacity 0.2s ease, transform 0.2s ease;
}

.hh-icon-btn:hover {
  opacity: 0.7;
  transform: scale(1.08);
}

.hh-icon-btn svg {
  pointer-events: none;
}

/* ============================================================
   GLOBAL DARK MODE STRUCTURE
   ============================================================ */
html.dark,
html.dark body,
html.dark * {
  color: #ffffff !important;
}

/* Inputs */
html.dark input,
html.dark textarea,
html.dark select {
  background: rgba(255,255,255,0.05) !important;
  border-color: rgba(255,255,255,0.4) !important;
  color: #fff !important;
}

html.dark input::placeholder,
html.dark textarea::placeholder {
  color: rgba(255,255,255,0.55) !important;
}

/* Buttons */
[data-theme="dark"] button,
[data-theme="dark"] .hh-btn,
[data-theme="dark"] .hh-pill,
[data-theme="dark"] [class*="btn"] {
  background: none !important;
  border: none !important;
  color: var(--hh-icon-color) !important;
  box-shadow: none !important;
  border-radius: 0 !important; /* as you requested globally */
}

/* ============================================================
   GLOBAL GLASS CARDS
   ============================================================ */
html.dark .hh-card,
html.dark .hh-panel,
html.dark .hh-glass,
html.dark .settings-card,
html.dark .messages-pane,
html.dark .profile-card {
  background: rgba(10, 10, 15, 0.85) !important;
  backdrop-filter: blur(22px) saturate(140%) !important;
  border: 1px solid rgba(255,255,255,0.10) !important;
}

/* ============================================================
   GLOBAL SHADOW SYSTEM
   ============================================================ */
html:not([data-theme="dark"]) .hh-card,
html:not([data-theme="dark"]) .hh-post,
html:not([data-theme="dark"]) .hh-btn {
  box-shadow: 0 0 5px rgba(0,0,0,0.5) !important;
}

html[data-theme="dark"] .hh-card,
html[data-theme="dark"] .hh-post,
html[data-theme="dark"] .hh-btn {
  box-shadow: 0 0 5px rgba(255,255,255,0.5) !important;
}
/* ============================================================
   LANDING PAGE — CTA, CARD, MOBILE FIXES
   Route: html[data-route="landing"]
   ============================================================ */

html[data-route="landing"] .hh-cta {
  display: inline-flex !important;
  align-items: center;
  justify-content: center;
  width: 240px !important;
  height: 46px !important;
  line-height: 46px !important;
  padding: 0 !important;
  margin: 0 !important;

  font-size: 14px !important;
  font-weight: 700 !important;
  border-radius: 9999px !important;
  text-decoration: none !important;

  background: initial !important;
  border: initial !important;
  box-shadow: initial !important;
  box-sizing: border-box !important;
}

html[data-route="landing"] .hh-cta--primary {
  background: linear-gradient(135deg, #181818, #000) !important;
  color: #fff !important;
  border: 1px solid rgba(0,0,0,0.4) !important;
}

html[data-route="landing"] .hh-cta--secondary {
  background: rgba(255,255,255,0.75) !important;
  border: 1px solid rgba(0,0,0,0.25) !important;
  color: #000 !important;
}

html[data-route="landing"] .hh-cta:hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 28px rgba(0,0,0,0.18) !important;
}

/* ---- CTA row ---- */
html[data-route="landing"] .hh-cta-row {
  display: flex !important;
  justify-content: center !important;
  align-items: center !important;
  gap: 14px !important;
}

/* ---- Mobile Scaling ---- */
@media (max-width: 480px) {
  html[data-route="landing"] .hh-page {
    padding: 6px 8px 12px !important;
    gap: 10px !important;
  }

  html[data-route="landing"] .hh-page > main {
    padding: 10px 8px 16px !important;
    gap: 16px !important;
  }

  html[data-route="landing"] .hh-card {
    padding: 14px 12px 16px !important;
    border-radius: 18px !important;
    max-width: 360px !important;
  }

  html[data-route="landing"] .hh-section-title {
    font-size: 22px !important;
    letter-spacing: 0.14em !important;
  }

  html[data-route="landing"] .hh-meta {
    font-size: 9px !important;
  }

  html[data-route="landing"] .hh-card button,
  html[data-route="landing"] .hh-card a[href="/why-verify"] {
    padding: 10px 0 !important;
    font-size: 13px !important;
    min-width: 100% !important;
  }

  html[data-route="landing"] .hh-landingCard {
    margin-top: 40px !important;
  }
}

/* ---- Ticker positioning ---- */
@media (max-width: 600px) {
  html[data-route="landing"] .hh-ticker,
  html[data-route="landing"] .ticker {
    margin-top: 40px !important;
  }

  html[data-route="landing"] .hh-card,
  html[data-route="landing"] .hh-landingCard {
    margin-top: 60px !important;
  }
}
/* ============================================================
   UNIVERSE PAGE — LUXE PACK
   Route: html[data-route="universe"]
   ============================================================ */

html[data-route="universe"] {
  --uv-card-r: 22px;
  --uv-blur: 22px;
  --uv-border-neutral: rgba(120,130,140,0.28);
  --uv-ink-darkmode: #e8edf2;
  --uv-surface-dark: rgba(17,18,20,0.62);
  --uv-surface-soft: rgba(17,18,20,0.55);
}

/* ---- Composer ---- */
html[data-route="universe"] .hh-card.composer {
  padding: 14px 16px !important;
}

/* ---- Search ---- */
html[data-route="universe"] .universe-search-wrap input {
  padding-right: 48px !important;
  border-radius: 999px;
}

html[data-route="universe"][data-theme="dark"] .universe-search-wrap input {
  background: var(--uv-surface-dark) !important;
  color: var(--uv-ink-darkmode) !important;
  border-color: var(--uv-border-neutral) !important;
}

/* ---- Posts ---- */
html[data-route="universe"] .hh-post {
  padding: 16px 18px 20px;
  border-radius: var(--uv-card-r);
}

html[data-route="universe"] .hh-postImage {
  width: 100%;
  border-radius: 18px;
  margin-top: 8px;
  object-fit: cover;
  box-shadow: 0 10px 24px rgba(0,0,0,0.10);
}

/* ---- Reactions ---- */
html[data-route="universe"] .hh-emojiPopover {
  position: absolute;
  top: 50%;
  left: calc(100% + 8px);
  transform: translateY(-50%);
  padding: 6px 8px;
  z-index: 80;
}

html[data-route="universe"][data-theme="dark"] .hh-emojiPopover {
  background: var(--uv-surface-dark) !important;
  border: 1px solid var(--uv-border-neutral) !important;
}

/* ---- Pills ---- */
html[data-route="universe"] .hh-pill {
  padding: 8px 12px !important;
  border-radius: 9999px;
  border: 1.5px solid rgba(148,163,184,.45);
}

html[data-route="universe"][data-theme="dark"] .hh-pill {
  background: var(--uv-surface-soft) !important;
  color: var(--uv-ink-darkmode) !important;
  border-color: var(--uv-border-neutral) !important;
}

/* ---- Background Map ---- */
html[data-route="universe"] .hh-world-bg {
  filter: grayscale(100%) contrast(.9) brightness(.9);
}
/* ============================================================
   PROFILE PAGE — ULTRA POLISHED PACK
   Route: html[data-route="profile"]
   ============================================================ */

/* ---- Tokens ---- */
html[data-route="profile"] {
  --pf-ink: #0b1220;
  --pf-muted: #64748b;
  --pf-ring: #ffffff;
  --pf-shadow: 0 18px 40px rgba(15,23,42,0.18);
  --pf-name-fs: 22px;
  --pf-meta-fs: 12px;
  --pf-body-fs: 14px;
  --pf-r-lg: 22px;
}

/* ---- Banner ---- */
html[data-route="profile"] .hh-profileBanner {
  position: relative;
  border-radius: var(--pf-r-lg) var(--pf-r-lg) 0 0;
  overflow: hidden;
}

html[data-route="profile"] .hh-profileBanner > img {
  width: 100%;
  height: clamp(180px, 26vw, 260px);
  object-fit: cover;
}

/* ---- Avatar ---- */
html[data-route="profile"] .hh-profileAvatarWrap {
  margin-top: -48px;
}

html[data-route="profile"] .hh-profileAvatar {
  width: 104px;
  height: 104px;
  border-radius: 9999px;
  overflow: hidden;
  outline: 3px solid var(--pf-ring);
  box-shadow: var(--pf-shadow);
  background: #0a0a0a;
}

/* ---- Identity ---- */
html[data-route="profile"] .hh-profileName {
  font-size: var(--pf-name-fs);
  font-weight: 700;
  color: var(--ink-light);
}

html[data-route="profile"] .hh-profileHandle {
  font-size: var(--pf-meta-fs);
  color: var(--pf-muted);
}

html[data-route="profile"] .hh-profileBio {
  font-size: var(--pf-body-fs);
  line-height: 1.45;
  color: var(--ink-light);
}

/* ---- Stats ---- */
html[data-route="profile"] .hh-profileStats {
  display: flex;
  gap: 14px;
  align-items: center;
}

/* ---- Links ---- */
html[data-route="profile"] .hh-profileLinks a {
  font-size: 12px;
  border-bottom: 1px dashed rgba(148,163,184,0.45);
}

html[data-route="profile"] .hh-profileLinks a:hover {
  border-bottom-style: solid;
}

/* ---- Buttons ---- */
html[data-route="profile"] .hh-btn,
html[data-route="profile"] .hh-pill {
  transition: transform .12s ease, box-shadow .12s ease;
}

html[data-route="profile"] .hh-btn:hover,
html[data-route="profile"] .hh-pill:hover {
  transform: translateY(-1px);
}

/* ---- Photos grid ---- */
html[data-route="profile"] .hh-photosGrid {
  display: grid;
  gap: 12px;
  grid-template-columns: repeat(2, 1fr);
}

@media (min-width: 900px) {
  html[data-route="profile"] .hh-photosGrid {
    grid-template-columns: repeat(3, 1fr);
  }
}

html[data-route="profile"] .hh-photosGrid img {
  width: 100%;
  aspect-ratio: 4/3;
  object-fit: cover;
  border-radius: 14px;
  transition: transform .15s ease;
}

/* -----------------------------------------
   Links row
   ----------------------------------------- */
html[data-route="profile"] .hh-profileLinks a {
  font-size: 12px;
  color: var(--ink-light);
  text-decoration: none;
  border-bottom: 1px dashed rgba(148,163,184,0.45);
  transition: border .15s ease;
}

html[data-route="profile"] .hh-profileLinks a:hover {
  border-bottom-style: solid;
}

/* -----------------------------------------
   Stats row (Followers / Following)
   ----------------------------------------- */
html[data-route="profile"] .hh-profileStats {
  display: flex;
  gap: 14px;
  font-size: var(--pf-meta-fs);
  color: var(--ink-light);
}

html[data-route="profile"] .hh-profileStats b {
  font-weight: 700;
}

/* -----------------------------------------
   Buttons — luxury movement
   ----------------------------------------- */
html[data-route="profile"] .hh-pill,
html[data-route="profile"] .hh-btn {
  transition: transform .12s ease, box-shadow .12s ease;
}

html[data-route="profile"] .hh-pill:hover,
html[data-route="profile"] .hh-btn:hover {
  transform: translateY(-1px);
}

html[data-route="profile"] .hh-pill.hh-primary,
html[data-route="profile"] .hh-btn-primary {
  box-shadow: 0 10px 22px rgba(15,23,42,.22);
}

/* -----------------------------------------
   Accessibility polish
   ----------------------------------------- */
html[data-route="profile"] a:focus-visible,
html[data-route="profile"] button:focus-visible {
  outline: 2px solid #60a5fa;
  outline-offset: 2px;
}

/* -----------------------------------------
   Identity text contrast on busy banners
   ----------------------------------------- */
html[data-route="profile"] .hh-profileIdentity {
  text-shadow:
    0 1px 2px rgba(0,0,0,.25),
    0 0 1px rgba(0,0,0,.25);
}

/* -----------------------------------------
   Posts inside the profile feed
   ----------------------------------------- */
html[data-route="profile"] .hh-post {
  border-radius: var(--pf-r-lg);
  overflow: hidden;
}

html[data-route="profile"] .hh-postImage {
  width: 100%;
  height: 260px;
  object-fit: cover;
  border-radius: 18px;
  margin-top: 6px;
}

/* Smaller pills in post footers */
html[data-route="profile"] .hh-postFooterActions .hh-pill {
  font-size: 12px;
  padding: 4px 10px;
}

/* ===================================================================
   HH-SHELL — PROFILE PAGE STYLE SYSTEM
   scoped to: html[data-route="profile"]
   =================================================================== */

/* -----------------------------------------
   Avatar + overlap
   ----------------------------------------- */
html[data-route="profile"] .hh-profileAvatar {
  position: relative;
  border-radius: 9999px;
  outline: 3px solid var(--pf-ring);
  box-shadow: 0 10px 24px rgba(0,0,0,.28);
}

html[data-route="profile"] .hh-profileAvatarWrap {
  margin-top: -48px;
}

/* -----------------------------------------
   Name / handle / bio
   ----------------------------------------- */
html[data-route="profile"] .hh-profileName {
  font-size: var(--pf-name-fs);
  font-weight: 700;
  letter-spacing: .2px;
}

html[data-route="profile"] .hh-profileHandle {
  color: var(--pf-muted);
  font-size: var(--pf-meta-fs);
}

html[data-route="profile"] .hh-profileBio {
  font-size: var(--pf-body-fs);
  line-height: 1.45;
  color: var(--pf-ink);
}

/* -----------------------------------------
   Links row
   ----------------------------------------- */
html[data-route="profile"] .hh-profileLinks a {
  text-decoration: none;
  border-bottom: 1px dashed rgba(148,163,184,.55);
}

html[data-route="profile"] .hh-profileLinks a:hover {
  border-bottom-style: solid;
}

/* -----------------------------------------
   Stats row
   ----------------------------------------- */
html[data-route="profile"] .hh-profileStats {
  display: flex;
  gap: 14px;
  align-items: center;
  font-size: var(--pf-meta-fs);
}

html[data-route="profile"] .hh-profileStats b {
  font-weight: 700;
}

/* -----------------------------------------
   “This is you” chip
   ----------------------------------------- */
html[data-route="profile"] .hh-selfChip {
  background: rgba(15,23,42,.06);
  border: 1px solid rgba(148,163,184,.35);
  padding: 4px 10px;
  border-radius: 999px;
  font-size: 11px;
}

/* -----------------------------------------
   Buttons on profile only
   ----------------------------------------- */
html[data-route="profile"] .hh-btn,
html[data-route="profile"] .hh-pill {
  transition: transform .12s ease, box-shadow .12s ease, background-color .12s ease;
}

html[data-route="profile"] .hh-btn-primary,
html[data-route="profile"] .hh-pill.hh-primary {
  box-shadow: 0 10px 22px rgba(15,23,42,.22);
}

html[data-route="profile"] .hh-btn:hover,
html[data-route="profile"] .hh-pill:hover {
  transform: translateY(-1px);
}

html[data-route="profile"] .hh-btn:focus-visible,
html[data-route="profile"] .hh-pill:focus-visible {
  outline: 2px solid #60a5fa;
  outline-offset: 2px;
}

/* -----------------------------------------
   Photos grid
   ----------------------------------------- */
html[data-route="profile"] .hh-photosGrid {
  display: grid;
  gap: 12px;
  grid-template-columns: repeat(2, 1fr);
}

@media (min-width: 900px) {
  html[data-route="profile"] .hh-photosGrid {
    grid-template-columns: repeat(3, 1fr);
  }
}

html[data-route="profile"] .hh-photosGrid img,
html[data-route="profile"] .hh-photosGrid video {
  width: 100%;
  aspect-ratio: 4/3;
  object-fit: cover;
  border-radius: 14px;
  box-shadow: var(--pf-shadow);
  transition: transform .15s ease, box-shadow .15s ease;
}

html[data-route="profile"] .hh-photosGrid a:hover img,
html[data-route="profile"] .hh-photosGrid a:hover video {
  transform: translateY(-2px) scale(1.01);
  box-shadow: var(--pf-shadow-strong);
}

/* -----------------------------------------
   Header spacing layouts
   ----------------------------------------- */
html[data-route="profile"] .hh-profileHeader {
  display: grid;
  gap: var(--pf-gap);
}

html[data-route="profile"] .hh-profileActions {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

/* -----------------------------------------
   Tappable icon buttons
   ----------------------------------------- */
html[data-route="profile"] .hh-topIconBtn {
  width: 36px;
  height: 36px;
  display: inline-grid;
  place-items: center;
  border-radius: 999px;
}

/* -----------------------------------------
   Accessibility
   ----------------------------------------- */
html[data-route="profile"] a:focus-visible,
html[data-route="profile"] button:focus-visible {
  outline: 2px solid #60a5fa;
  outline-offset: 2px;
}

/* -----------------------------------------
   Identity text contrast on banners
   ----------------------------------------- */
html[data-route="profile"] .hh-profileIdentity {
  text-shadow:
    0 1px 2px rgba(0,0,0,.25),
    0 0 1px rgba(0,0,0,.25);
}

/* -----------------------------------------
   Post and image scaling
   ----------------------------------------- */
.hh-post {
  width: 100%;
}

.hh-postImage {
  display: block;
  width: 100%;
  height: 260px;
  object-fit: cover;
  border-radius: 18px;
  margin-top: 6px;
  overflow: hidden;
}

.hh-postFooterActions .hh-pill {
  font-size: 5px;
  padding: 2px 10px;
}

/* ============================================================
   HH-SHELL — REPOST MEDIA
============================================================ */
.hh-postRepostCard .hh-postImage {
  width: 100%;
  height: 240px;
  object-fit: cover;
  border-radius: 16px;
}

/* ============================================================
   PROFILE PAGE — DARK MODE
   (Does NOT nuke global colors anymore)
============================================================ */
html[data-theme="dark"][data-route="profile"] .hh-page {
  color: #f9fafb;
}

/* ============================================================
   GLOBAL SHADOW SYSTEM
============================================================ */

/* Light mode unified shadow */
html:not([data-theme="dark"]) 
  .hh-header,
  .hh-navRow,
  .hh-card,
  .hh-post,
  .hh-btn,
  .hh-pill,
  .ntf-feed .card,
  #messages .hh-messages-bubble,
  #messages .hh-messages-row,
  .hh-pulse-btn {
  box-shadow: 0 0 5px 1px rgba(0,0,0,0.45);
}

/* Dark mode unified shadow */
html[data-theme="dark"] 
  .hh-header,
  .hh-navRow,
  .hh-card,
  .hh-post,
  .hh-btn,
  .hh-pill,
  .ntf-feed .card,
  #messages .hh-messages-bubble,
  #messages .hh-messages-row,
  .hh-pulse-btn {
  box-shadow: 0 0 5px 1px rgba(255,255,255,0.28);
}

/* ============================================================
   LINKIFIED PILL COMPONENT
============================================================ */
.hh-linkified-pill {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 4px 10px;
  border-radius: 999px;
  text-decoration: none;
  font-size: 0.85rem;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  border: 1px solid rgba(255,255,255,0.35);
  background: rgba(15,15,15,0.9);
  color: #f5f5f5;
}

.hh-linkified-icon {
  font-size: 0.75rem;
  opacity: 0.7;
}

.hh-linkAction:hover {
  opacity: 0.75;
}

/* ============================================================
   PROFILE PAGE — MOBILE FIXES
============================================================ */
@media (max-width: 600px) {
  #profile-page .hh-card {
    width: 100%;
    max-width: 92vw;
    margin-left: auto;
    margin-right: auto;
    border-radius: 16px;
    overflow: visible;
    box-sizing: border-box;
  }

  #profile-page .hh-profileHeader {
    position: relative;
    width: 100%;
    overflow: hidden;
  }

  #profile-page .hh-profileBannerImg {
    width: 100%;
    height: auto;
    object-fit: cover;
  }

  #profile-page .hh-profileAvatarWrapper {
    position: absolute;
    bottom: -40px;
    left: 16px;
    z-index: 10;
  }
}

/* ============================================================
   PROFILE AVATAR ALIGNMENT
============================================================ */
.profile-page .hh-profile-avatar {
  display: flex;
  align-items: center;
  justify-content: center;
}

.hh-avatar {
  width: 42px;
  height: 42px;
  border-radius: 9999px;
  object-fit: cover;
}

/* Comment text */
.hh-comment-text {
  font-size: 14px;
  line-height: 1.4;
  white-space: pre-wrap;
}

/* ============================================================
   VIDEO STABILITY FIX
============================================================ */
video {
  transform: translateZ(0);
  backface-visibility: hidden;
}

/* ============================================================
   TWO-COLUMN (2A) LAYOUT
============================================================ */
.hh-2a-center {
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.hh-2a-scroll {
  overflow-y: auto;
  scrollbar-width: thin;
  max-height: calc(100vh - 110px);
  padding-right: 4px;
}

/* ============================================================
   SETTINGS PAGE — CENTER COLUMN
============================================================ */
html[data-route="settings"] .hh-center {
  max-width: 650px;
  padding: 0 16px;
  margin: 0 auto;
}

@media (max-width: 768px) {
  html[data-route="settings"] .hh-center {
    padding: 0 10px;
  }
}

/* ============================================================
   SETTINGS PAGE — GLOBAL LAYOUT
============================================================ */
.hh-settings-page {
  width: 100%;
}

.hh-settings-container {
  width: 100%;
  display: flex;
  justify-content: center;
  padding-top: 108px;
  padding-bottom: 60px;
}

.hh-settings-inner {
  width: 100%;
  max-width: 900px;
  display: flex;
  flex-direction: column;
  gap: 32px;
}



/* =======================================
   SETTINGS PAGE — LAYOUT BASICS
======================================= */
.hh-settingsPage {
  display: flex;
  flex-direction: column;
  gap: 22px;
  padding: 12px 0 40px;
}

.hh-settingsBlock {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.hh-settingsTitle {
  font-size: 20px;
  font-weight: 600;
}

.hh-subTitle {
  font-size: 16px;
  font-weight: 600;
  margin-top: 4px;
}

.hh-settingsRow {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.hh-settingsChecks {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.hh-label {
  font-weight: 500;
}

/* =======================================
   UNIVERSAL ICON BUTTON (NO PILL)
======================================= */
.hh-icon-btn {
  background: none !important;
  border: none !important;
  cursor: pointer;
  padding: 6px !important;
  border-radius: 6px;
  display: inline-flex !important;
  justify-content: center !important;
  align-items: center !important;
  transition: opacity 0.2s ease, transform 0.2s ease;
  color: var(--hh-icon-color);
}

.hh-icon-btn:hover {
  opacity: 0.75;
  transform: scale(1.08);
}

.hh-icon-btn svg {
  pointer-events: none;
}

/* Tooltip */
.hh-icon-btn[data-tip]::after {
  content: attr(data-tip);
  position: absolute;
  top: calc(100% + 2px);
  left: 50%;
  transform: translateX(-50%);
  font-size: 11px;
  opacity: 0;
  white-space: nowrap;
  transition: opacity 0.2s ease;
  color: var(--hh-icon-color);
}

.hh-icon-btn:hover::after {
  opacity: 1;
}

/* =======================================
   SIMPLE ACTION LIST
======================================= */
.hh-actionList {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.hh-actionRow {
  display: flex;
  align-items: center;
  gap: 10px;
  background: transparent;
  border: none;
  padding: 8px 0;
  font-size: 15px;
  font-weight: 500;
  color: var(--ink-light);
  cursor: pointer;
  text-align: left;
  transition: opacity 0.2s ease;
}

.hh-actionRow:hover {
  opacity: 0.7;
}

/* =======================================
   DARK MODE COLOR LOGIC — OPTION A
   Light = black icons, Dark = white icons
======================================= */
:root {
  --hh-icon-color: #000;     /* light mode icon color */
  --ink-light: #333;         /* text tint light mode */
}

[data-theme="dark"] {
  --hh-icon-color: #fff;     /* dark mode icon color */
  --ink-light: #ddd;
}

/* Lucide + SVG icons respect the theme */
svg,
svg * {
  stroke: var(--hh-icon-color) !important;
  color: var(--hh-icon-color) !important;
  fill: none !important;
  opacity: 1 !important;
  transition: stroke 0.2s ease, color 0.2s ease;
}

/* Iconify icons also follow theme */
.iconify,
.lucide,
.hh-icon {
  color: var(--hh-icon-color) !important;
}

/* =======================================
   SETTINGS PAGE MOBILE LAYOUT FIX
======================================= */
html[data-route="settings"] .hh-page {
  padding: 8px 10px 20px !important;
  width: 100% !important;
  max-width: 100% !important;
  overflow-x: hidden !important;
}

html[data-route="settings"] .hh-card {
  width: 100% !important;
  max-width: 100% !important;
  margin: 0 0 14px !important;
  border-radius: 14px !important;
  padding: 18px !important;
}

/* Hide left/right rails */
@media (max-width: 820px) {
  html[data-route="settings"] .hh-left,
  html[data-route="settings"] .hh-right {
    display: none !important;
  }
}

/* =======================================
   MOBILE SCALING (480px and down)
======================================= */
@media (max-width: 480px) {
  html[data-route="settings"] .hh-settingsPage {
    transform: scale(0.94);
    transform-origin: top center;
    width: 108%;
  }

  html[data-route="settings"] .hh-card {
    padding: 16px !important;
  }

  html[data-route="settings"] .hh-settingsTitle {
    font-size: 1.1rem !important;
  }

  html[data-route="settings"] .hh-label {
    font-size: 0.85rem !important;
  }

  html[data-route="settings"] .hh-muted {
    font-size: 0.8rem !important;
  }

  html[data-route="settings"] .hh-icon-btn svg {
    width: 20px !important;
    height: 20px !important;
  }
}


/* ======================  
   TAB BUTTONS  
====================== */
.hh-tab-btn {
  background: none !important;
  border: none !important;
  padding: 8px !important;
  border-radius: 50% !important;
  cursor: pointer;
  display: flex;
  justify-content: center;
  align-items: center;
  opacity: 0.5;
  transition: opacity .2s, transform .2s;
}

.hh-tab-btn.active {
  opacity: 1;
  transform: scale(1.15);
}

.hh-tab-btn:hover {
  opacity: .8;
}

/* ======================  
   SAVE / CANCEL ICON BTNS  
====================== */
.hh-save-btn,
.hh-cancel-btn {
  background: none !important;
  border: none !important;
  padding: 12px !important;
  border-radius: 50% !important;
  display: flex;
  justify-content: center;
  align-items: center;
  margin: auto;
}

/* ======================  
   MODAL OVERLAY  
====================== */
.hh-modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,.55);
  z-index: 900;
}

/* ======================  
   MODAL PANEL  
====================== */
.hh-profile-modal {
  position: fixed;
  top: 50%; left: 50%;
  transform: translate(-50%,-50%);
  width: 92%; max-width: 560px;
  padding: 38px 38px 48px;
  border-radius: 22px;
  background: rgba(25,25,25,.78);
  backdrop-filter: blur(22px) saturate(1.3);
  border: 1px solid rgba(255,255,255,.08);
  box-shadow: 0 35px 70px rgba(0,0,0,.65);
  z-index: 1001;
}

.hh-profile-title {
  font-size: 26px;
  font-weight: 800;
  margin-bottom: 26px;
  color: #fff;
}

.hh-close-btn {
  position: absolute;
  top: 18px; right: 22px;
  font-size: 24px;
  color: #fff;
  opacity: .85;
  cursor: pointer;
  transition: .2s;
}

.hh-close-btn:hover {
  opacity: 1;
  transform: scale(1.12);
}

/* ======================  
   TABS  
====================== */
.hh-tabs {
  display: flex;
  justify-content: center;
  gap: 14px;
  margin-bottom: 26px;
}

.hh-tab {
  padding: 10px 18px;
  border-radius: 12px;
  background: rgba(255,255,255,.08);
  color: rgba(255,255,255,.75);
  cursor: pointer;
  transition: .25s;
  font-weight: 600;
  backdrop-filter: blur(6px);
}

.hh-tab:hover {
  background: rgba(255,255,255,.15);
}

.hh-tab.active {
  background: #fff;
  color: #000;
}

/* ======================  
   INPUTS  
====================== */
.hh-input,
.hh-textarea {
  width: 100%;
  padding: 14px 16px;
  margin-top: 18px;
  background: rgba(255,255,255,.14);
  border-radius: 14px;
  border: 1px solid rgba(255,255,255,.22);
  color: #fff;
  font-size: 15px;
  backdrop-filter: blur(6px);
  transition: .25s;
}

.hh-input:focus,
.hh-textarea:focus {
  border-color: #fff;
  background: rgba(255,255,255,.24);
  outline: none;
}

.hh-textarea {
  min-height: 110px;
  resize: vertical;
}

/* ======================  
   SAVE BUTTON  
====================== */
.hh-save-btn {
  margin-top: 30px;
  width: 100%;
  padding: 15px 0;
  font-size: 17px;
  font-weight: 700;
  background: linear-gradient(90deg, #000, #222);
  color: #fff;
  border: none;
  border-radius: 14px;
  cursor: pointer;
  transition: .25s;
}

.hh-save-btn:hover {
  background: linear-gradient(90deg,#111,#333);
  transform: translateY(-2px);
}

.hh-save-btn:active {
  transform: translateY(1px);
}

/* ======================  
   FOLLOWERS MODAL  
====================== */
.hh-follow-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,.55);
  backdrop-filter: blur(14px);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 99999;
}

.hh-follow-modal {
  width: 92%; max-width: 420px;
  max-height: 80vh;
  background: rgba(20,20,20,.75);
  border-radius: 20px;
  padding: 20px 24px;
  border: 1px solid rgba(255,255,255,.08);
  box-shadow: 0 20px 60px rgba(0,0,0,.65);
  overflow-y: auto;
}

.hh-follow-item {
  display: flex;
  justify-content: space-between;
  padding: 12px 0;
  border-bottom: 1px solid rgba(255,255,255,.06);
}

.hh-follow-user {
  display: flex;
  align-items: center;
  gap: 12px;
  cursor: pointer;
}

.hh-follow-user img {
  width: 40px; height: 40px;
  border-radius: 999px;
  object-fit: cover;
  border: 1px solid rgba(255,255,255,.15);
}

.hh-follow-close {
  background: rgba(255,255,255,.08);
  padding: 10px 16px;
  border-radius: 12px;
  margin-top: 14px;
  text-align: center;
  cursor: pointer;
  font-weight: 600;
  transition: .2s;
}

.hh-follow-close:hover {
  background: rgba(255,255,255,.12);
}

/* ======================  
   ICON SYSTEM  
====================== */

/* universal icon var */
:root { --hh-icon-color: #000; }
[data-theme="dark"] { --hh-icon-color: #fff; }

/* Apply icon color everywhere */
svg,
svg * {
  stroke: var(--hh-icon-color) !important;
  color: var(--hh-icon-color) !important;
  fill: none !important;
  opacity: 1 !important;
}
/* COMMENT BUBBLE FIX */
.hh-comment-bubble {
  background: rgba(255, 255, 255, 0.85);      /* Light mode */
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  border-radius: 14px;
  padding: 8px 12px;
  color: #111;
}

[data-theme="dark"] .hh-comment-bubble {
  background: rgba(0, 0, 0, 0.55);           /* Dark mode */
  color: #f1f5f9;
}
.hh-tab:hover {
  opacity: 0.75;
  color: var(--hh-icon-color);
}
/* =========================================================
   HH HEADER — DO NOT LET ANYTHING HIDE EVER AGAIN
   Nuclear override
========================================================= */

.hh-header-force, .hh-navRow-force, .hh-tab, .hh-icon {
  opacity: 1 !important;
  visibility: visible !important;
  pointer-events: auto !important;
}

/* Icon color always driven by theme */
:root[data-theme="light"] {
  --hh-nav-icon: #111;
}
:root[data-theme="dark"] {
  --hh-nav-icon: #fff;
}

.hh-icon {
  stroke: var(--hh-nav-icon) !important;
  color: var(--hh-nav-icon) !important;
}

/* Logo swap rules */
.hh-brand-light { display: block !important; }
.hh-brand-dark { display: none !important; }

[data-theme="dark"] .hh-brand-light { display: none !important; }
[data-theme="dark"] .hh-brand-dark { display: block !important; }

/* Avatar stability */
.hh-navAvatar {
  width: 28px;
  height: 28px;
  border-radius: 999px;
  object-fit: cover;
  border: 1px solid rgba(255,255,255,0.3);
  background: #000;
}
/* ===========================================
   🔥 COMMENT BUBBLE READABILITY FIX
   Works for dark & light themes
=========================================== */

/* Wrapper comment cards */
.hh-comment,
.hh-reply,
.hh-postComment {
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  padding: 10px 14px;
  border-radius: 14px;
  margin: 6px 0;
}

/* Light mode */
:root[data-theme="light"] .hh-comment,
:root[data-theme="light"] .hh-reply,
:root[data-theme="light"] .hh-postComment {
  background: rgba(255, 255, 255, 0.85) !important;
  color: #111 !important;
}

/* Dark mode */
:root[data-theme="dark"] .hh-comment,
:root[data-theme="dark"] .hh-reply,
:root[data-theme="dark"] .hh-postComment {
  background: rgba(0, 0, 0, 0.45) !important;
  color: #fff !important;
}

/* Username text */
.hh-comment .username,
.hh-reply .username {
  font-weight: 600;
  color: var(--hh-header-icon) !important;
}

/* Timestamp */
.hh-comment .time,
.hh-reply .time {
  opacity: 0.75;
  font-size: 12px;
}
/* =========================================================
   DARK MODE — FORCE ALL TEXT WHITE
   ========================================================= */
:root[data-theme="dark"] {
  --hh-text-primary: #ffffff !important;
  --hh-text-secondary: #e6e6e6 !important;
  --hh-text-muted: #cccccc !important;

  color: #ffffff !important;
}

:root[data-theme="dark"] * {
  color: #ffffff !important;
  text-shadow: none !important;
}

/* Comments */
:root[data-theme="dark"] .hh-commentBody,
:root[data-theme="dark"] .hh-commentTime,
:root[data-theme="dark"] .hh-commentUser {
  color: #ffffff !important;
}

/* Universe posts body text */
:root[data-theme="dark"] .hh-postBody,
:root[data-theme="dark"] .hh-postUsername,
:root[data-theme="dark"] .hh-postTime {
  color: #ffffff !important;
}

/* Header icons */
:root[data-theme="dark"] .hh-icon,
:root[data-theme="dark"] svg {
  stroke: #ffffff !important;
  fill: #ffffff !important;
}

/* Buttons */
:root[data-theme="dark"] .hh-btn,
:root[data-theme="dark"] .hh-tab {
  color: #ffffff !important;
}
html[data-route="discussions"] {
  --hh-header-offset: 64px;
}

html[data-route="discussions"] .hh-page,
html[data-route="discussions"] .hh-content,
html[data-route="discussions"] main {
  padding-top: var(--hh-header-offset) !important;
}
.hh-navBtn {
  background: none;
  border: none;
  padding: 6px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--hh-icon-color);
}

.hh-navBtn svg {
  stroke: var(--hh-icon-color);
}
/* FILE: src/styles/universe.css */

/* --------- Design tokens --------- */
:root {
  --hh-bg-glass: rgba(255,255,255,0.65);
  --hh-bg-deck: rgba(248,250,252,0.65);
  --hh-border: rgba(15,23,42,0.12);
  --hh-text: #0f172a;
  --hh-muted: #64748b;
  --hh-shadow: 0 10px 30px rgba(2,6,23,0.12);
  --hh-radius: 16px;
  --hh-radius-lg: 22px;
  --hh-icon-color: #000; /* updated by JS */
  --hh-card-blur: saturate(160%) blur(12px);
}

:root.dark, [data-theme="dark"] {
  --hh-bg-glass: rgba(17,18,22,0.6);
  --hh-bg-deck: rgba(17,18,22,0.5);
  --hh-border: rgba(255,255,255,0.12);
  --hh-text: #f1f5f9;
  --hh-muted: rgba(255,255,255,0.7);
  --hh-shadow: 0 18px 50px rgba(0,0,0,0.55);
}

/* --------- Generic helpers --------- */
.hh-muted { color: var(--hh-muted); }
.hh-pill {
  display:inline-flex; align-items:center; gap:6px;
  padding:4px 10px; font-size:12px;
  background: var(--hh-deck, var(--hh-bg-deck));
  border: 1px solid var(--hh-border);
  border-radius: 999px;
}

/* --------- Card --------- */
.hh-card {
  background: var(--hh-bg-glass);
  -webkit-backdrop-filter: var(--hh-card-blur);
  backdrop-filter: var(--hh-card-blur);
  border: 1px solid var(--hh-border);
  border-radius: var(--hh-radius-lg);
  box-shadow: var(--hh-shadow);
  color: var(--hh-text);
}

/* --------- Inputs / buttons --------- */
.hh-input {
  width:100%; padding:10px 12px; border-radius:12px;
  border:1px solid var(--hh-border); background: var(--hh-bg-deck);
  color: var(--hh-text); outline: none;
}
.hh-input:focus { box-shadow: 0 0 0 3px rgba(99,102,241,0.25); }

.hh-btn {
  padding:8px 12px; border-radius:12px; border:1px solid var(--hh-border);
  background: var(--hh-bg-deck); color: var(--hh-text); cursor:pointer;
}
.hh-btn-primary {
  background:#0f172a; color:#fff; border-color:#0f172a;
}
.hh-btn-ghost {
  background: transparent; border:1px solid var(--hh-border);
}

/* --------- Post --------- */
.hh-post { padding:12px; }
.hh-postHeader { }
.hh-postUserBtn {
  display:flex; gap:10px; align-items:center; border:none; background:transparent;
  padding:6px 2px; cursor:pointer;
}
.hh-postAvatar {
  width:36px; height:36px; border-radius:50%; object-fit:cover; flex-shrink:0;
  border:1px solid var(--hh-border);
}
.hh-postUserMeta { display:flex; flex-direction:column; gap:2px; }
.hh-postUsername { font-weight:700; font-size:13px; opacity:.95; }
.hh-postTime { font-size:12px; color:var(--hh-muted); }

.hh-postBody { font-size:14px; line-height:1.5; }
.hh-postImage {
  display:block; width:100%; height:260px; object-fit:cover; border-radius:12px;
}
.hh-postVideo {
  display:block; width:100%; max-height:260px; border-radius:12px;
  background:#000;
}

/* --------- Link preview --------- */
.hh-linkPreviewCard {
  display:flex; gap:10px; margin-top:8px; padding:10px;
  border:1px solid var(--hh-border); border-radius:12px;
  text-decoration:none; color:var(--hh-text);
  background: var(--hh-bg-deck);
}
.hh-linkPreviewThumb {
  width:80px; height:80px; border-radius:10px; background:#e2e8f0;
  background-size:cover; background-position:center;
}
.hh-linkPreviewBody { min-width:0; display:flex; flex-direction:column; gap:4px; }
.hh-linkPreviewSite { font-size:11px; text-transform:uppercase; opacity:.75; }
.hh-linkPreviewTitle {
  font-size:13px; font-weight:700; overflow:hidden; display:-webkit-box;
  -webkit-line-clamp:2; -webkit-box-orient:vertical;
}

/* --------- Post footer actions --------- */
.hh-postFooterActions button { transition: transform .1s ease; }
.hh-postFooterActions button:hover { transform: translateY(-1px); }

/* --------- Comments --------- */
.hh-postComments {
  max-height:220px; overflow:auto; padding-right:4px; margin-top:8px;
}
.hh-postComments::-webkit-scrollbar { width:8px; }
.hh-postComments::-webkit-scrollbar-thumb {
  background: rgba(100,116,139,0.35);
  border-radius: 8px;
}

.hh-comment-row { display:flex; align-items:flex-start; gap:10px; padding:8px 0; position:relative; }
.hh-avatar {
  width:38px; height:38px; border-radius:50%; object-fit:cover; flex-shrink:0;
  border:1px solid var(--hh-border);
}
.hh-comment-bubble {
  background: var(--hh-bg-glass); border-radius:14px; padding:8px 12px;
  max-width:85%; box-shadow:0 4px 14px rgba(0,0,0,0.06); border:1px solid var(--hh-border);
}
.hh-comment-author { font-size:12px; font-weight:700; margin-bottom:2px; color:var(--hh-text); }
.hh-comment-text { font-size:14px; line-height:1.4; color:var(--hh-text); }

/* comment emoji chips */
.hh-comment-reaction-btn {
  font-size:14px; padding:2px 8px; border-radius:999px; cursor:pointer;
  background: rgba(255,255,255,0.6);
  border:1px solid var(--hh-border);
}
.hh-comment-reaction-btn:hover {
  box-shadow: 0 0 0 2px rgba(99,102,241,0.18) inset;
}

/* emoji picker popover inside comment (absolutely positioned container) */
.hh-comment-row .emoji-pop {
  position:absolute; bottom:100%; left:48px; display:flex; gap:6px; padding:8px;
  background: var(--hh-bg-deck); border:1px solid var(--hh-border);
  border-radius:10px; box-shadow: var(--hh-shadow); z-index:20;
}
.hh-comment-row .emoji-pop span { font-size:20px; cursor:pointer; }

/* --------- Composer --------- */
.hh-commentComposer {
  display:flex; gap:8px; align-items:center; margin-top:8px;
}
.hh-commentInput { height:38px; }

/* --------- Repost card --------- */
.hh-postRepostCard {
  border:1px solid var(--hh-border); border-radius:12px; padding:10px;
  background: var(--hh-bg-deck);
}
.hh-postRepostHeader { display:flex; align-items:center; gap:10px; cursor:pointer; }
.hh-postRepostAvatar { width:28px; height:28px; border-radius:50%; object-fit:cover; border:1px solid var(--hh-border); }
.hh-postRepostName { font-weight:700; font-size:13px; }
.hh-postRepostTime { font-size:12px; color:var(--hh-muted); }

/* --------- Pulse modal (already inline-styled) --------- */

/* --------- Image lightbox (already inline-styled) --------- */

/* --------- Sticky “Load more” on mobile --------- */
@media (max-width: 640px) {
  .hh-loadMoreWrap {
    position: sticky; bottom: 10px; z-index: 5;
    display:flex; justify-content:center; pointer-events:none;
  }
  .hh-loadMoreWrap .hh-btn {
    pointer-events:auto; border-radius:999px; padding:10px 16px;
    background: var(--hh-bg-glass);
    -webkit-backdrop-filter: var(--hh-card-blur);
    backdrop-filter: var(--hh-card-blur);
  }
}

/* --------- Mini profile hover (render a sibling .hh-miniProfile next to avatar) --------- */
.hh-miniProfile {
  position:absolute; left:46px; top:0;
  transform: translateY(-110%); opacity:0; pointer-events:none;
  min-width:200px; padding:12px; border-radius:14px; border:1px solid var(--hh-border);
  background: var(--hh-bg-glass); box-shadow: var(--hh-shadow);
  transition: opacity .12s ease, transform .12s ease;
}
.hh-postUserBtn:hover + .hh-miniProfile,
.hh-miniProfile:hover {
  opacity:1; transform: translateY(-118%); pointer-events:auto;
}

/* --------- Utility for reaction trigger --------- */
.hh-reactionTrigger {
  border:none; background:transparent; padding:2px 6px; border-radius:999px;
}
.hh-reactionTrigger:hover { background: rgba(148,163,184,0.15); }

/* --------- Reduce double-username risk on profile line --------- */
.hh-postUserMeta .dup { display:none; }
/* --- PUT THE BACKGROUND MAP BACK IN LIGHT MODE --- */
html:not([data-theme="dark"]) .hh-page::before {
  display: block !important;       /* undo the 'display: none' */
  opacity: 1 !important;           /* keep it visible */
}

/* Keep the page base white so cards don't pick up gray */
html:not([data-theme="dark"]) body,
html:not([data-theme="dark"]) #root,
html:not([data-theme="dark"]) .hh-page {
  background: #ffffff !important;
}

/* Keep cards/buttons/inputs opaque in light mode (no gray cast) */
html:not([data-theme="dark"]) .hh-card,
html:not([data-theme="dark"]) .hh-post,
html:not([data-theme="dark"]) .hh-messages-inbox,
html:not([data-theme="dark"]) .hh-messages-chat,
html:not([data-theme="dark"]) .hh-messages-controls,
html:not([data-theme="dark"]) .hh-input,
html:not([data-theme="dark"]) .hh-textarea,
html:not([data-theme="dark"]) select {
  background: #ffffff !important;
  border-color: rgba(15,23,42,0.12) !important;
  backdrop-filter: none !important;
  -webkit-backdrop-filter: none !important;
  color: #0f172a !important;
}

/* Light header stays crisp white over the map */
html:not([data-theme="dark"]) .hh-header {
  background: rgba(255,255,255,0.9) !important;
  border-bottom: 1px solid rgba(15,23,42,0.06) !important;
  backdrop-filter: blur(8px) !important;
}
/* ============================
   NAV ICONS — ALWAYS VISIBLE
   (place at the very end)
   ============================ */

/* 1) Theme-safe color just for the nav */
:root { --hh-nav-icon: #111; }
[data-theme="dark"] { --hh-nav-icon: #fff; }

/* 2) Force nav elements to use the nav color */
.hh-header,
.hh-navRow,
.hh-navRow .hh-tab,
.hh-navRow .avatar-tab,
.hh-navRow .hh-themeTab button {
  color: var(--hh-nav-icon) !important;
}

/* 3) Undo global "fill:none" and make icons inherit color */
.hh-header svg,
.hh-header .iconify,
.hh-navRow svg,
.hh-navRow .iconify {
  color: var(--hh-nav-icon) !important;
  stroke: currentColor !important;
  fill: currentColor !important;     /* <— critical: some icons rely on fill */
  opacity: 1 !important;
}

/* also fix inner paths/groups the global rule hit */
.hh-header svg *,
.hh-navRow svg * {
  stroke: currentColor !important;
  fill: currentColor !important;
  opacity: 1 !important;
}

/* 4) Kill opacity tricks that make icons vanish */
.hh-tab,
.hh-tab-btn,
.hh-icon-btn {
  opacity: 1 !important;
}

/* keep a subtle hover without hiding icons */
.hh-tab:hover,
.hh-tab-btn:hover,
.hh-icon-btn:hover {
  opacity: 0.85 !important;
}

/* 5) Prevent accidental “transparent” nav pills hiding icons */
.hh-navRow .hh-tab,
.hh-navRow .avatar-tab,
.hh-navRow .hh-themeTab button {
  background: transparent !important;
  box-shadow: none !important;
}

/* (Optional) If your brand uses two stacked images, keep them visible */
.hh-brand .hh-brand-icon { opacity: 1 !important; }
/* === Mobile-first base tweaks for LandingPage === */

:root {
  --landing-maxw: 620px;
  --card-radius: 26px;
  --card-pad: 26px 24px 24px;
  --text: #0f172a;
  --muted: #334155;
  --border: rgba(15,23,42,0.08);
}

/* Container */
.hh-page {
  background: #fff;
  color: var(--text);
}

/* Header + brand spacing */
.hh-page-header {
  margin-bottom: 0 !important;
}

/* Make HASH HUMANITY text wrap nicer on small screens */
.hh-section-title {
  word-break: break-word;
  line-height: 1.05;
}

/* Ticker spacing (a little closer on mobile) */
.hh-page-header + .hh-meta,
.hh-page-header + div .hh-meta {
  margin-top: 14px !important;
}

/* Card (frosted look already inline; here we handle responsive spacing) */
.hh-card {
  width: 100%;
  max-width: min(520px, 92vw);
  border-radius: var(--card-radius);
  border: 1px solid var(--border);
}

/* Buttons */
.hh-cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;          /* touch target */
  padding: 10px 16px;
  border-radius: 12px;
  font-weight: 700;
  letter-spacing: .02em;
  text-decoration: none;
  cursor: pointer;
  line-height: 1;
  white-space: nowrap;
}

/* Force black primary CTA w/ white text (World ID) */
.hh-cta--primary {
  background: #0b1220 !important;    /* black/dark */
  color: #fff !important;
  border: 1px solid rgba(2,8,23,0.15) !important;
  box-shadow: 0 6px 16px rgba(2,8,23,0.22);
}

/* Secondary stays white */
.hh-cta--secondary {
  background: #fff;
  color: var(--text);
  border: 1px solid rgba(2,8,23,0.15);
  box-shadow: 0 3px 10px rgba(2,8,23,0.08);
}

/* Footer links wrap cleanly */
footer[aria-label="Legal"],
footer nav[aria-label="Legal"] {
  gap: 6px;
  row-gap: 6px;
}

/* Secret dev backdrop tap area */
.hh-secret-backdrop {
  padding: 14px;
}

/* === Breakpoint: <= 640px (phones) === */
@media (max-width: 640px) {
  /* Constrain page content & center */
  .hh-page main > div {
    max-width: 92vw;
  }

  /* Logo scale down slightly */
  .hh-page-header img[alt="Hash Humanity"] {
    width: 76px !important;
    height: 76px !important;
  }

  /* Title sizing */
  .hh-section-title {
    font-size: clamp(28px, 8vw, 40px) !important;
  }

  /* “Powered by World ID” darker and smaller */
  .hh-page-header .hh-meta {
    font-size: 10.5px !important;
    color: #1f2937 !important; /* darker */
    letter-spacing: 0.18em;
  }

  /* Card spacing tighter and pulled down a touch */
  .hh-card {
    margin: 16px auto 0 !important;
    padding: 20px 16px 18px !important;
    border-radius: 20px !important;
  }

  /* Buttons: full width stack */
  .hh-cta {
    width: 100%;
    min-width: unset;
    padding: 12px 14px;
    font-size: 14px;
  }

  /* Language select full width */
  #lang-select {
    width: 100% !important;
    padding: 8px 12px !important;
    font-size: 14px !important;
    border-radius: 12px !important;
  }

  /* Footer spacing */
  footer.hh-meta {
    padding: 12px 10px 20px !important;
    font-size: 11px !important;
  }

  /* Secret dev modal: edge padding & comfortable fields */
  .hh-secret-backdrop > div[role="document"] {
    width: 100%;
    max-width: 520px;
    padding: 20px 16px 18px !important;
    border-radius: 14px !important;
  }

  .hh-secret-backdrop input[type="email"],
  .hh-secret-backdrop input[type="password"] {
    padding: 12px 12px !important;
    font-size: 14px !important;
    border-radius: 12px !important;
  }

  .hh-secret-backdrop button[type="submit"],
  .hh-secret-backdrop button[type="button"] {
    min-height: 44px;
    padding: 10px 14px !important;
    font-size: 12px !important;
    border-radius: 999px !important;
  }
}

/* === Very small phones: <= 380px === */
@media (max-width: 380px) {
  .hh-page-header img[alt="Hash Humanity"] {
    width: 66px !important;
    height: 66px !important;
  }

  .hh-section-title {
    font-size: clamp(24px, 8.5vw, 34px) !important;
  }

  .hh-card {
    margin-top: 14px !important;
    padding: 16px 12px 16px !important;
    border-radius: 14px !important;
  }

  /* Tighten ticker */
  .hh-page-header + .hh-meta,
  .hh-page-header + div .hh-meta {
    margin-top: 10px !important;
    font-size: 12px !important;
  }

  footer.hh-meta {
    padding: 10px 8px 16px !important;
  }
}

/* === Motion-safe fade-in on mount === */
@media (prefers-reduced-motion: no-preference) {
  .hh-page {
    animation: hhFadeIn 300ms ease-out both;
  }
  @keyframes hhFadeIn {
    from { opacity: 0; transform: translateY(6px); }
    to   { opacity: 1; transform: translateY(0); }
  }
}
/* ==== LandingPage compact fit ================================================= */
:root{
  --landing-maxw: 520px;
  --card-maxw: 460px;
  --card-pad: 14px 12px 12px;
  --radius-lg: 14px;
  --text: #0f172a;
}

/* page + center column */
.hh-page{ background:#fff; color:var(--text); }
.hh-page main{ padding: 8px 10px 10px !important; }
.hh-page main > div{ max-width:min(var(--landing-maxw), 94vw); }

/* header / brand */
.hh-page-header{ margin-bottom:0 !important; }
.hh-section-title{
  line-height:1.04;
  font-size:clamp(28px, 5.2vw, 44px) !important;
  letter-spacing:.12em !important;
  margin: 0 0 2px !important;
}
.hh-page-header .hh-meta{
  margin-top:6px !important;
  font-size:10px !important;
  letter-spacing:.16em;
  color:#1f2937 !important;
}

/* logo smaller */
.hh-page-header img[alt="Hash Humanity"]{
  width:60px; height:60px; display:block;
  margin: 0 auto 10px;
}

/* ticker smaller/tighter */
.hh-page-header + .hh-meta,
.hh-page-header + div .hh-meta{
  margin-top:8px !important;
  font-size:clamp(11px, 3vw, 13px) !important;
  color:#1f2937 !important;
}

/* card sizing */
.hh-card{
  width:100%;
  max-width:min(var(--card-maxw), 94vw);
  margin:10px auto 0 !important;
  padding:var(--card-pad) !important;
  border-radius:var(--radius-lg) !important;
  border:1px solid rgba(15,23,42,0.08);
}

/* card title & body text smaller */
.hh-card .hh-card-title{ font-size:clamp(18px, 3.6vw, 22px) !important; margin:0 0 4px !important; }
.hh-card .hh-meta{ font-size:12px !important; }

/* CTAs = compact & full-width on phones */
.hh-cta{
  width:100%;
  min-height:40px;
  padding:8px 10px;
  border-radius:10px;
  font-weight:700;
  letter-spacing:.02em;
  font-size:13px;
}
.hh-cta--primary{ background:#0b1220 !important; color:#fff !important; border:1px solid rgba(2,8,23,.15) !important; }
.hh-cta--secondary{ background:#fff; color:var(--text); border:1px solid rgba(2,8,23,.15); }

/* language select compact */
#lang-select{
  width:100% !important;
  padding:8px 10px !important;
  border-radius:10px !important;
  font-size:13px !important;
}

/* footer tighter */
footer.hh-meta{ padding:8px 8px 14px !important; font-size:10px !important; }
footer.hh-meta nav{ gap:4px; row-gap:4px; }

/* ===== Secret Dev Modal (compact) =========================================== */
.hh-secret-backdrop{ padding:10px; }
.hh-secret-backdrop > div[role="document"]{
  width:min(460px, 94vw);
  border-radius:14px !important;
  padding:16px 14px 14px !important;
}
.hh-secret-backdrop label{ font-size:11px !important; }
.hh-secret-backdrop input[type="email"],
.hh-secret-backdrop input[type="password"]{
  padding:8px 10px !important;
  font-size:13px !important;
  border-radius:10px !important;
}
.hh-secret-backdrop button[type="submit"],
.hh-secret-backdrop button[type="button"]{
  min-height:38px; padding:8px 12px !important; border-radius:999px !important; font-size:12px !important;
}

/* ===== breakpoints ========================================================== */
@media (min-width: 641px){
  .hh-cta{ width:auto; min-height:38px; padding:8px 12px; }
  .hh-page main > div{ max-width:min(720px, 92vw); }
}

@media (max-width: 380px){
  .hh-section-title{ font-size:clamp(24px, 7vw, 32px) !important; }
  .hh-page-header img[alt="Hash Humanity"]{ width:54px; height:54px; }
  .hh-card{ margin-top:8px !important; padding:12px 10px 10px !important; border-radius:12px !important; }
}

/* subtle fade-in */
@media (prefers-reduced-motion: no-preference){
  .hh-page{ animation: lpFade .22s ease-out both; }
  @keyframes lpFade{ from{opacity:0; transform:translateY(4px)} to{opacity:1; transform:translateY(0)} }
}
/* --- Lock the world map; kill parallax & movement --- */
.hh-page::before {
  transform: none !important;
  will-change: auto !important;
  position: fixed !important;
  inset: 0 !important;
}
html, body, #root { height: 100%; overflow: hidden !important; }
.hh-shell { height: 100vh; overflow-y: auto; }
/* Hide scrollbars but keep scrolling */
.hh-shell,
.hh-scrollArea,
.hh-postComments,
.hh-2a-scroll {
  -ms-overflow-style: none;   /* IE/Edge */
  scrollbar-width: none;      /* Firefox */
}
.hh-shell::-webkit-scrollbar,
.hh-scrollArea::-webkit-scrollbar,
.hh-postComments::-webkit-scrollbar,
.hh-2a-scroll::-webkit-scrollbar {
  width: 0;
  height: 0;
}
/* ============================================================
   LIGHT MODE — FORCE ALL ICONS BLACK
   ============================================================ */

.light svg,
.light svg *,
.light [class*="icon"],
.light [class*="-icon"],
.light .hh-icon,
.light .hh-icon *,
.light .post-card svg,
.light .post-card svg *,
.light .comment-card svg,
.light .comment-card svg * {
  fill: #000000 !important;
  stroke: #000000 !important;
  color: #000000 !important;
}

/* Light mode text enforcement */
.light .post-card,
.light .post-card *,
.light .comment-card,
.light .comment-card *,
.light .hh-post,
.light .hh-post * {
  color: #000000 !important;
}
html[data-route="universe"][data-editprofile="1"] {
  background-attachment: fixed !important;
  background-position: center top !important;
  background-size: cover !important;
}
/* Make the landing container transparent so frost can blur what's behind it */
html[data-route="landing"] .hh-page {
  background: transparent !important;
}

/* Frosted glass card — overrides inline styles */
html[data-route="landing"] .hh-card {
  /* shape + border */
  border-radius: 22px !important;
  border: 1px solid rgba(15, 23, 42, 0.12) !important;

  /* translucent surface */
  background: linear-gradient(
    180deg,
    rgba(255, 255, 255, 0.80),
    rgba(255, 255, 255, 0.58)
  ) !important;

  /* the frost */
  backdrop-filter: blur(16px) saturate(135%) !important;
  -webkit-backdrop-filter: blur(16px) saturate(135%) !important;

  /* depth */
  box-shadow: 0 14px 36px rgba(2, 8, 23, 0.16) !important;
}

/* Fallback for browsers without backdrop-filter support */
@supports not ((backdrop-filter: blur(1px)) or (-webkit-backdrop-filter: blur(1px))) {
  html[data-route="landing"] .hh-card {
    background: rgba(255, 255, 255, 0.96) !important;
  }
}

/* Ensure text stays readable over busy backgrounds */
html[data-route="landing"] .hh-card .hh-card-title { color: #0f172a !important; }
html[data-route="landing"] .hh-card p,
html[data-route="landing"] .hh-card .hh-meta { color: #334155 !important; }
/* ============================
   FIX: Light mode wipes nav tabs
   ============================ */
html:not([data-theme="dark"]) .hh-navRow .hh-tab {
  display: inline-flex !important;
  opacity: 1 !important;
  visibility: visible !important;
  color: #000 !important;
}

html:not([data-theme="dark"]) .hh-navRow svg {
  stroke: #000 !important;
  fill: #000 !important;
  color: #000 !important;
}
.hh-navRow {
  background: rgba(255, 255, 255, 0.9);
  border: 1px solid rgba(0, 0, 0, 0.35);  /* thin black border */
  border-radius: 50px;
  padding: 10px 20px;
  box-shadow: 0 4px 10px rgba(0,0,0,0.15);
}
.hh-card {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.25);
  backdrop-filter: blur(20px) brightness(1.2);
}
/* Tight offset for Discussions page (clean, minimal) */
html[data-route="discussions"] {
  --hh-top-offset: 72px; /* sweet spot */
}

html[data-route="discussions"] .grid,
html[data-route="discussions"] main,
html[data-route="discussions"] .content,
html[data-route="discussions"] .container,
html[data-route="discussions"] .hh-shell,
html[data-route="discussions"] .hh-page {
  padding-top: var(--hh-top-offset) !important;
}
/* =======================================================
   FIX — Messages page sits too high under the header
   ======================================================= */

html[data-route="messages"] .hh-page,
html[data-route="messages"] .hh-shell,
html[data-route="messages"] main {
  padding-top: 32px !important;   /* sweet spot */
}
/* =======================================================
   FIX — Messages page should sit closer to the navbar
   ======================================================= */

/* Remove all extra spacing applied by global grid/layout */
html[data-route="messages"] .hh-page,
html[data-route="messages"] .hh-shell,
html[data-route="messages"] main,
html[data-route="messages"] .grid {
  padding-top: 8px !important;   /* SUPER tight — right under nav */
  margin-top: 0 !important;
}
.hh-comment-send-icon {
  background: none !important;
  border: none !important;
  padding: 0 !important;
  margin-left: 8px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  color: var(--ink-muted, #666);
  transition: 0.15s ease;
}

.hh-comment-send-icon:hover {
  color: var(--ink, #000);
  transform: translateY(-1px);
}

.hh-comment-send-icon:active {
  transform: scale(0.9);
}

.hh-comment-send-icon[disabled] {
  opacity: 0.3;
  cursor: default;
  transform: none;
}
/* ======================================================
   🔥 SETTINGS PAGE — BULLETPROOF KEYBOARD + STICKY HEADER FIX
   ====================================================== */

/* The settings page becomes the ONLY scroll container */
.hh-settings-page {
  position: relative;
  overflow-y: auto !important;
  overflow-x: hidden !important;

  height: 100dvh !important;
  min-height: 100dvh !important;
  display: flex;
  flex-direction: column;
}

/* Make sure the header is INSIDE the scroll container */
.hh-settings-page .hh-header,
.hh-settings-page header,
.hh-settings-page .HeaderNav {
  position: sticky !important;
  top: 0;
  z-index: 99999;
  background: var(--bg-page, rgba(0,0,0,0.65));
  backdrop-filter: blur(14px);
}

/* Content area grows under header */
.hh-settings-content {
  flex: 1 1 auto;
  padding: 20px;
  overflow-y: visible !important;
}

/* Bigger textbox fix */
.hh-settings-page textarea {
  min-height: 140px !important;
  padding: 14px !important;
  font-size: 16px !important;
  line-height: 1.5;
  resize: vertical;

}
/* ===========================================
   PROFILE PAGE — MAKE CARDS WIDER
=========================================== */
[data-route="profile"] .hh-center {
  max-width: 960px !important;   /* widen center column */
  width: 100% !important;
}

[data-route="profile"] .hh-card {
  max-width: 900px !important;   /* widen actual cards */
  width: 100% !important;
  margin-left: auto !important;
  margin-right: auto !important;
}

/* ===========================================================
   Notifications Page — Card Width Override (Scoped)
   =========================================================== */

#notifications-page .hh-card,
#notifications-page .hh-notif-card,
#notifications-page .notif-item {
  width: 92%;
  max-width: 720px;
  margin: 0 auto 14px auto;
}
/* ==============================================
   BEAUTIFUL LOAD MORE BUTTON (UNIVERSE ONLY)
   ============================================== */

#universe-page .hh-btn {
  display: block;
  margin: 28px auto;
  padding: 10px 26px;
  font-size: 15px;
  font-weight: 600;
  border-radius: 14px;
  cursor: pointer;

  background: rgba(255, 255, 255, 0.75);
  border: 1px solid rgba(0, 0, 0, 0.12);
  color: #000;

  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);

  transition: all 0.18s ease;
}

/* Dark mode */
.dark #universe-page .hh-btn {
  background: rgba(30, 30, 30, 0.6);
  border: 1px solid rgba(255, 255, 255, 0.15);
  color: #fff;
}

/* Hover animation */
#universe-page .hh-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.25);
}

/* Active (pressed) */
#universe-page .hh-btn:active {
  transform: translateY(0);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.18);
}
/* ===== Global theme ink color for buttons & icons ===== */
:root {
  --ui-ink: #0f172a;            /* light: near-black */
}
html.dark,
[data-theme="dark"] {
  --ui-ink: #ffffff;            /* dark: white */
}

/* Buttons (all variants) */
button,
.hh-btn,
.hh-btn-primary,
.hh-btn-secondary,
.hh-icon-btn {
  color: var(--ui-ink) !important;
}

/* Lucide & other SVG icons inherit currentColor */
button svg,
.hh-btn svg,
.hh-icon-btn svg,
svg.lucide,
svg[class*="lucide"] {
  color: var(--ui-ink) !important;   /* for libs that read color */
  stroke: currentColor !important;   /* lucide-react uses stroke */
  fill: none;                        /* keep icons outlined */
}

/* Icons not inside buttons (standalone icons in headers, cards, etc.) */
.hh-card svg,
.hh-page svg,
svg.icon {
  color: var(--ui-ink) !important;
  stroke: currentColor !important;
}

/* Optional: disabled buttons still obey theme color but look disabled */
button:disabled,
.hh-btn:disabled {
  opacity: 0.6;
}

/* Optional: keep hover/focus from changing ink color */
button:hover,
button:focus,
.hh-btn:hover,
.hh-btn:focus {
  color: var(--ui-ink) !important;
}
/* FILE: src/Styles/MessagesPage.css */
/* ===================== THEME TOKENS ===================== */
/* Default → DARK (black) */
:root {
  --bg: #000;              /* pure black */
  --panel: #0c0c0c;
  --panel-2: #121212;
  --text: #f2f4f8;
  --muted: #aab0bd;
  --brand: #6b8cff;
  --brand-2: #2c63ff;
  --line: #1e1e20;
  --danger: #ff6b6b;
  --radius: 6px;
  --gap-xs: 6px;
  --gap-sm: 10px;
  --gap: 14px;
  --gap-lg: 18px;
  --shadow: 0 1px 0 rgba(0,0,0,.7), 0 10px 28px rgba(0,0,0,.55);
  --elev: drop-shadow(0 2px 0 rgba(0,0,0,.6)) drop-shadow(0 18px 36px rgba(0,0,0,.55));
}

/* Light override → WHITE */
@media (prefers-color-scheme: light) {
  :root {
    --bg: #fff;            /* pure white */
    --panel: #ffffff;
    --panel-2: #fafbfc;
    --text: #111318;
    --muted: #6b7280;
    --brand: #335cff;
    --brand-2: #1847ff;
    --line: #e6e8ee;
    --danger: #d93c3c;
    --shadow: 0 1px 0 rgba(17,19,24,.05), 0 10px 28px rgba(17,19,24,.08);
    --elev: drop-shadow(0 1px 0 rgba(0,0,0,.04)) drop-shadow(0 20px 32px rgba(0,0,0,.08));
  }
}

/* Manual override: set <html data-theme="dark|light"> to force */
html[data-theme="dark"] :root,
html[data-theme="dark"] {
  --bg: #000;
  --panel: #0c0c0c;
  --panel-2: #121212;
  --text: #f2f4f8;
  --muted: #aab0bd;
  --brand: #6b8cff;
  --brand-2: #2c63ff;
  --line: #1e1e20;
  --danger: #ff6b6b;
  --shadow: 0 1px 0 rgba(0,0,0,.7), 0 10px 28px rgba(0,0,0,.55);
  --elev: drop-shadow(0 2px 0 rgba(0,0,0,.6)) drop-shadow(0 18px 36px rgba(0,0,0,.55));
}
html[data-theme="light"] :root,
html[data-theme="light"] {
  --bg: #fff;
  --panel: #ffffff;
  --panel-2: #fafbfc;
  --text: #111318;
  --muted: #6b7280;
  --brand: #335cff;
  --brand-2: #1847ff;
  --line: #e6e8ee;
  --danger: #d93c3c;
  --shadow: 0 1px 0 rgba(17,19,24,.05), 0 10px 28px rgba(17,19,24,.08);
  --elev: drop-shadow(0 1px 0 rgba(0,0,0,.04)) drop-shadow(0 20px 32px rgba(0,0,0,.08));
}

/* Base */
html, body, #root { background: var(--bg); color: var(--text); }
.hh-messages { color: var(--text); }
* { box-sizing: border-box; }
:focus-visible {
  outline: 2px solid var(--brand);
  outline-offset: 2px;
  border-radius: 4px;
}
::selection { background: color-mix(in oklab, var(--brand) 30%, transparent); }

/* ===================== STRUCTURE ===================== */
.hh-card{
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  filter: var(--elev);
  transition: background .25s ease, border-color .25s ease, box-shadow .25s ease;
}
.hh-card:hover { box-shadow: 0 1px 0 rgba(0,0,0,.25), 0 14px 34px rgba(0,0,0,.45); }
@media (prefers-color-scheme: light){
  .hh-card:hover { box-shadow: 0 1px 0 rgba(17,19,24,.06), 0 14px 34px rgba(17,19,24,.12); }
}
.hh-title{
  padding: 12px var(--gap);
  font-weight: 600;
  border-bottom: 1px solid var(--line);
}
.hh-muted{ color: var(--muted); }

/* ===================== CONTROLS ===================== */
.hh-input, .hh-textarea, select.hh-input{
  width: 100%;
  background: var(--panel-2);
  color: var(--text);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  height: 40px;
  padding: 10px 12px;
  outline: none;
  transition: border-color .2s ease, box-shadow .2s ease, background .2s ease;
}
.hh-textarea{ resize: none; min-height: 40px; line-height: 1.35; }
.hh-input:focus, .hh-textarea:focus, select.hh-input:focus{
  border-color: var(--brand);
  box-shadow: 0 0 0 2px color-mix(in oklab, var(--brand) 35%, transparent);
}

/* ===================== BUTTONS ===================== */
.hh-btn{
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  height: 40px; padding: 0 12px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--panel-2);
  color: var(--text);
  cursor: pointer;
  transition: background .15s ease, border-color .15s ease, transform .06s ease;
}
.hh-btn:hover{ background: color-mix(in oklab, var(--panel-2) 85%, var(--text) 15%); }
.hh-btn:active{ transform: translateY(1px); }
.hh-btn:disabled{ opacity:.55; cursor: not-allowed; }

.hh-btn-primary{
  background: var(--brand);
  border-color: var(--brand);
  color: color-mix(in oklab, var(--bg) 90%, #ffffff 10%);
}
.hh-btn-primary:hover{ filter: brightness(1.05); }
.hh-btn-ghost{ background: transparent; }
.hh-btn.hh-btn-xs{ height: 28px; padding: 0 8px; }

/* Square the legacy pill utility */
.hh-pill{ border-radius: var(--radius) !important; }

/* ===================== SEARCH + LANGUAGE ===================== */
.hh-messages-controls{ padding: var(--gap); margin-bottom: var(--gap-lg); }
.hh-messages-controls-row{ display:flex; gap: var(--gap); align-items: end; }
.hh-messages-searchWrap{ display:flex; gap: var(--gap-sm); flex: 1; }
.hh-messages-searchBtn{ width: 44px; }

/* Suggestions */
.hh-messages-suggestions{
  margin-top: var(--gap-sm);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
}
.hh-messages-suggestionRow{
  width: 100%;
  display: grid; grid-template-columns: 36px 1fr; gap: var(--gap-sm);
  padding: 10px var(--gap);
  background: var(--panel-2);
  border: 0; border-bottom: 1px solid var(--line);
  text-align: left; cursor: pointer;
  transition: background .15s ease;
}
.hh-messages-suggestionRow:last-child{ border-bottom: 0; }
.hh-messages-suggestionRow:hover{ background: color-mix(in oklab, var(--panel-2) 80%, var(--brand) 20%); }

/* ===================== LAYOUT ===================== */
.hh-messages-layout{
  display: grid;
  grid-template-columns: 300px 1fr;
  gap: var(--gap);
}
@media (max-width: 900px){
  .hh-messages-layout{ grid-template-columns: 1fr; }
}

/* ===================== INBOX ===================== */
.hh-messages-inbox{ padding: 0; overflow: hidden; }
.hh-messages-inboxList{ max-height: 62vh; overflow: auto; }
.hh-messages-row{
  width: 100%;
  display: grid; grid-template-columns: 40px 1fr auto; gap: var(--gap-sm);
  align-items: center;
  padding: 10px var(--gap);
  background: var(--panel);
  border: 0; border-bottom: 1px solid var(--line);
  text-align: left; cursor: pointer;
  transition: background .15s ease;
}
.hh-messages-row:hover{ background: color-mix(in oklab, var(--panel) 80%, var(--brand) 20%); }
.hh-messages-row.active{ background: color-mix(in oklab, var(--panel) 75%, var(--brand) 25%); }
.hh-messages-rowName{ font-weight: 600; }
.hh-messages-rowTime{ font-size: 12px; color: var(--muted); }

/* Unread indicator → square */
.hh-messages-dot{
  display: inline-block; width: 8px; height: 8px; margin-left: 6px;
  background: var(--brand); border-radius: 0 !important;
}

/* Avatars (round by default; uncomment to square them) */
.avatar{ width: 32px; height: 32px; border-radius: 50%; overflow: hidden; background: #222; display:grid; place-items:center; }
.avatar.small{ width: 28px; height: 28px; }
.avatar img{ width: 100%; height: 100%; object-fit: cover; }
/* To make avatars square too:
.avatar, .avatar.small, .avatar img{ border-radius: 4px; }
*/

/* ===================== CHAT PANE ===================== */
.hh-messages-chat{ display: flex; flex-direction: column; }
.chatHead{
  display: flex; align-items: center; gap: var(--gap-sm);
  padding: 10px var(--gap); border-bottom: 1px solid var(--line);
}
.chatScroll{ flex: 1; overflow: auto; background: var(--panel-2); }
.group{ padding: var(--gap); }

/* message row */
.rowMsg{ display:flex; margin-bottom: var(--gap-xs); }
.rowMsg.me{ justify-content: flex-end; }

/* bubble */
.hh-messages-bubble{
  position: relative;
  max-width: min(72ch, 86%);
  padding: 10px 12px;
  background: color-mix(in oklab, var(--panel-2) 90%, var(--text) 10%);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  transition: background .2s ease, border-color .2s ease;
}
.hh-messages-bubble.me{
  background: color-mix(in oklab, var(--brand) 18%, var(--panel-2) 82%);
  border-color: color-mix(in oklab, var(--brand) 35%, var(--line) 65%);
}

/* images in message */
.hh-messages-img{
  display:block; width: 100%; max-width: 420px; height: auto;
  border: 1px solid var(--line); border-radius: var(--radius);
  margin-bottom: var(--gap-xs);
}

/* timestamp + actions */
.hh-messages-stamp{ color: var(--muted); font-size: 12px; margin-top: 6px; }
.hh-messages-msgActions{ position: absolute; right: 6px; top: 6px; display: flex; gap: 6px; }

/* divider */
.hh-messages-dividerWrap{ text-align: center; margin: var(--gap) 0; }
.hh-messages-dividerBadge{
  display: inline-block;
  padding: 4px 8px;
  background: color-mix(in oklab, var(--panel-2) 85%, var(--brand) 15%);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  color: var(--muted); font-size: 12px;
}

/* ===================== COMPOSER ===================== */
.hh-messages-composer{ border-top: 1px solid var(--line); background: var(--panel); }
.hh-messages-compRow{
  display: flex; gap: var(--gap-sm); align-items: flex-end;
  padding: var(--gap);
}
.hh-messages-clip{
  width: 40px; height: 40px; display: grid; place-items: center;
  background: var(--panel-2);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  cursor: pointer;
  transition: background .15s ease;
}
.hh-messages-clip:hover{ background: color-mix(in oklab, var(--panel-2) 80%, var(--brand) 20%); }
.hh-messages-hiddenFile{ display: none; }

.hh-messages-previewRow{ display: flex; align-items: center; gap: var(--gap-sm); padding: 0 var(--gap) var(--gap); }
.hh-messages-previewImg{
  height: 80px; width: auto;
  border: 1px solid var(--line); border-radius: var(--radius);
}

/* ===================== UTILITIES ===================== */
.flexFill{ flex: 1; }
.rowSub{ font-size: 14px; }
.pad{ padding: var(--gap); }

/* Scrollbars */
*::-webkit-scrollbar{ height: 10px; width: 10px; }
*::-webkit-scrollbar-thumb{ background: color-mix(in oklab, var(--text) 12%, transparent); border-radius: 4px; border: 2px solid transparent; background-clip: padding-box; }
*::-webkit-scrollbar-track{ background: transparent; }
@media (prefers-color-scheme: dark) {
  .hh-btn svg * { stroke: currentColor !important; fill: none !important; }
}
html[data-theme="dark"] .hh-btn svg * { stroke: currentColor !important; fill: none !important; }
/* ========= MOBILE CHAT CLEANUP ========= */
@media (max-width: 768px){
  /* Bubbles: tighter, square-ish, no floaty badges */
  .hh-messages-bubble{
    border-radius: 8px !important;
    padding: 12px 14px;
    box-shadow: none;
  }
  .hh-messages-bubble.me{
    border-color: color-mix(in oklab, var(--brand) 35%, var(--line) 65%);
  }

  /* Place timestamp + actions on their own row (no overlay) */
  .hh-messages-stamp{
    margin-top: 6px;
    line-height: 1;
    display: inline-block;
  }
  .hh-messages-msgActions{
    position: static;              /* no absolute on mobile */
    display: inline-flex;
    gap: 8px;
    margin-left: 10px;             /* sit to the right of timestamp */
    vertical-align: middle;
  }

  /* Action buttons: compact, neutral, square */
  .hh-messages-msgActions .hh-btn{
    height: 32px;
    padding: 0 8px;
    border-radius: 8px;
    border-color: var(--line);
    background: transparent;
  }

  /* Composer: clean 3-column grid (clip | textarea | send) */
  .hh-messages-composer{
    border-top: 1px solid var(--line);
    background: var(--panel);
    padding: 0;
  }
  .hh-messages-compRow{
    display: grid;
    grid-template-columns: 52px 1fr 52px;
    gap: 12px;
    padding: 16px;
    align-items: center;
  }
  .hh-messages-clip,
  .hh-messages-send{
    height: 52px;
    border-radius: 8px;
    display: grid;
    place-items: center;
  }
  .hh-messages-ta{
    width: 100%;
    min-height: 52px;
    max-height: 160px;
    height: 52px;
    padding: 12px 14px;
    border-radius: 8px;
    line-height: 1.35;
  }

  /* Remove any “card in card” look under composer area */
  .hh-messages-previewRow{
    padding: 0 16px 16px;
    gap: 12px;
  }
  .hh-messages-previewImg{
    height: 110px;
    border-radius: 25px;
  }

  /* Make empty-state area breathe and avoid tiny box */
  .chatScroll{ min-height: 60vh; }
}

/* ========= GENERAL POLISH (all sizes) ========= */
/* Keep icon color in sync with theme */
.hh-btn svg,
.hh-messages-clip svg,
.hh-messages-send svg { stroke: currentColor !important; fill: none !important; }

@media (prefers-color-scheme: dark){
  .hh-btn, .hh-messages-clip, .hh-messages-send { color: #fff; }
  .hh-btn svg, .hh-messages-clip svg, .hh-messages-send svg { stroke:#fff !important; }
}
html[data-theme="dark"] .hh-btn,
html[data-theme="dark"] .hh-messages-clip,
html[data-theme="dark"] .hh-messages-send { color:#fff; }
html[data-theme="dark"] .hh-btn svg,
html[data-theme="dark"] .hh-messages-clip svg,
html[data-theme="dark"] .hh-messages-send svg { stroke:#fff !important; }

/* Make small action buttons square + subtle everywhere */
.hh-btn.hh-btn-xs{
  height: 14px;
  padding: 0 1px;
  border-radius: 6px;
}

/* Prevent super-rounded inner bubbles from reappearing */
.hh-pill{ border-radius: 8px !important; }
/* ===== FINAL FIX: Dark mode → white bubbles with black text ===== */

/* System dark */
@media (prefers-color-scheme: dark){
  /* Bubble + text */
  .hh-messages-bubble:not(.me){
    background: #ffffff !important;
    border-color: #e6e8ee !important;
    color: #0b0d12 !important;
    opacity: 1 !important;                /* guard against inherited opacity */
  }
  .hh-messages-bubble:not(.me) * {
    color: #0b0d12 !important;            /* ensure strong text inside bubble */
  }
  .hh-messages-bubble:not(.me) .hh-messages-stamp{
    color: #6b7280 !important;            /* softer time text */
  }

  /* Action buttons inside white bubbles */
  .hh-messages-bubble:not(.me) .hh-messages-msgActions .hh-btn{
    background: transparent !important;
    border-color: #e6e8ee !important;
    color: #0b0d12 !important;
  }
  .hh-messages-bubble:not(.me) .hh-messages-msgActions .hh-btn svg,
  .hh-messages-bubble:not(.me) .hh-messages-msgActions .hh-btn svg *{
    stroke: currentColor !important;
    fill: none !important;
  }

  /* Links & inline elements */
  .hh-messages-bubble:not(.me) a{
    color: #0b0d12 !important;
    text-decoration: underline;
  }
}

/* Manual override: <html data-theme="dark"> */
html[data-theme="dark"] .hh-messages-bubble:not(.me){
  background: #ffffff !important;
  border-color: #e6e8ee !important;
  color: #0b0d12 !important;
  opacity: 1 !important;
}
html[data-theme="dark"] .hh-messages-bubble:not(.me) *{ color:#0b0d12 !important; }
html[data-theme="dark"] .hh-messages-bubble:not(.me) .hh-messages-stamp{ color:#6b7280 !important; }
html[data-theme="dark"] .hh-messages-bubble:not(.me) .hh-messages-msgActions .hh-btn{
  background: transparent !important; border-color:#e6e8ee !important; color:#0b0d12 !important;
}
html[data-theme="dark"] .hh-messages-bubble:not(.me) .hh-messages-msgActions .hh-btn svg,
html[data-theme="dark"] .hh-messages-bubble:not(.me) .hh-messages-msgActions .hh-btn svg *{
  stroke: currentColor !important; fill: none !important;
}

/* (Optional) add a subtle lift on white bubbles against dark bg */
@media (prefers-color-scheme: dark){
  .hh-messages-bubble:not(.me){
    box-shadow: 0 1px 0 rgba(0,0,0,.05), 0 10px 20px rgba(0,0,0,.15) !important;
  }
}
html[data-theme="dark"] .hh-messages-bubble:not(.me){
  box-shadow: 0 1px 0 rgba(0,0,0,.05), 0 10px 20px rgba(0,0,0,.15) !important;
}
/* ===============================
   HASH HUMANITY — EDIT PROFILE PAGE
   Frosted glass, centered card,
   dark/light theme adaptive
   =============================== */

.editprofile-wrapper {
  min-height: 100vh;
  width: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 40px 20px;
  overflow-y: auto;
  background: var(--bg-page, rgba(0,0,0,0.75));
}

/* HH Logo */
.editprofile-logo {
  width: 110px;
  height: auto;
  margin-bottom: 20px;
  filter: drop-shadow(0 0 15px rgba(255,255,255,0.15));
}

/* TITLE */
.editprofile-title {
  font-size: 26px;
  font-weight: 700;
  margin-bottom: 25px;
  text-align: center;
  color: var(--ink, #fff);
  letter-spacing: 0.5px;
}

/* CARD */
.editprofile-card {
  width: 100%;
  max-width: 520px;
  padding: 28px;
  border-radius: 20px;

  background: rgba(255,255,255,0.06);
  backdrop-filter: blur(14px);

  box-shadow: 0 8px 30px rgba(0,0,0,0.4);
  border: 1px solid rgba(255,255,255,0.12);

  display: flex;
  flex-direction: column;
  gap: 18px;
}

/* LABELS */
.editprofile-section {
  font-size: 15px;
  font-weight: 600;
  color: var(--ink, #fff);
  margin-top: 8px;
}

/* INPUTS */
.editprofile-input,
.editprofile-textarea {
  width: 100%;
  padding: 12px 14px;
  border-radius: 12px;
  border: 1px solid rgba(255,255,255,0.15);

  background: rgba(0,0,0,0.25);
  color: var(--ink, #fff);
  font-size: 14px;

  transition: 0.25s ease;
}

.editprofile-input:focus,
.editprofile-textarea:focus {
  border-color: #6bb6ff;
  background: rgba(255,255,255,0.22);
  outline: none;
}

/* TEXTAREA */
.editprofile-textarea {
  min-height: 120px;
  resize: vertical;
}

/* FILE INPUT */
.editprofile-file {
  color: var(--ink, #ddd);
}

/* MUSIC PREVIEW */
.editprofile-music {
  margin-top: 10px;
  width: 100%;
}

.editprofile-music audio {
  width: 100%;
}

/* SAVE BUTTON */
.editprofile-save {
  width: 100%;
  padding: 12px 0;
  border-radius: 14px;

  background: linear-gradient(135deg, #3b82f6, #60a5fa);
  color: white;

  font-size: 15px;
  font-weight: 700;
  cursor: pointer;

  border: none;
  transition: 0.25s ease;
}

.editprofile-save:hover {
  filter: brightness(1.12);
}

/* CANCEL */
.editprofile-cancel {
  width: 100%;
  padding: 10px 0;

  border-radius: 14px;
  background: rgba(255,255,255,0.12);
  color: var(--ink, #fff);

  border: 1px solid rgba(255,255,255,0.25);
  cursor: pointer;

  transition: 0.25s ease;
}

.editprofile-cancel:hover {
  background: rgba(255,255,255,0.22);
}
/* ===========================================================
   FORCE LIGHT UI FOR EDIT PROFILE FORM
   =========================================================== */

/* Make section labels black */
.editprofile-section {
  color: #000 !important;
  font-weight: 600;
}

/* Make all main text black */
.editprofile-title,
.editprofile-card,
.editprofile-card * {
  color: #000 !important;
}

/* Inputs */
.editprofile-input,
.editprofile-textarea {
  background: #ffffff !important;
  color: #000 !important;
  border: 1px solid rgba(0,0,0,0.2) !important;
  box-shadow: 0 2px 8px rgba(0,0,0,0.08);
}

/* File inputs */
.editprofile-file {
  background: #ffffff !important;
  color: #000 !important;
  border: 1px solid rgba(0,0,0,0.25) !important;
}

/* Audio preview area */
.editprofile-music {
  background: #fff !important;
  border-radius: 12px;
  padding: 10px;
}

.editprofile-save {
  background: #000;
  color: #fff;
}


.editprofile-cancel {
  background: #eee !important;
  color: #000 !important;
  border: 1px solid rgba(0,0,0,0.3) !important;
}

/* Frosted card stays frosted but inner UI is bright */
.editprofile-card {
  backdrop-filter: blur(20px) saturate(180%);
  background: rgba(255,255,255,0.65) !important;
}
/* =============================================
   FIX BUTTONS — Clean, Black, Centered, Smaller
   ============================================= */

.editprofile-buttons {
  width: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  margin-top: 20px;
}

/* Save (black pill) */
.editprofile-save {
  width: 60% !important;
  max-width: 260px !important;
  height: 46px !important;              /* Fixed height */
  border-radius: 30px !important;
  background: #000 !important;
  color: #fff !important;
  font-weight: 600;
  font-size: 16px;
  border: none !important;
  cursor: pointer;
  transition: 0.2s ease;

  /* FIXED: perfect centering */
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;

  margin: 16px auto 0 auto !important;  /* centered */
}

.editprofile-save:hover {
  background: #111 !important;
  transform: translateY(-1px);
}

/* Cancel (light grey pill) */
.editprofile-cancel {
  width: 60% !important;
  max-width: 260px !important;
  height: 46px !important;               /* FIXED HEIGHT */
  border-radius: 30px !important;
  background: #e6e6e6 !important;
  color: #000 !important;
  font-weight: 500;
  font-size: 15px;
  border: 1px solid #ccc !important;
  cursor: pointer;
  transition: 0.2s ease;

  /* PERFECT CENTERING */
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;

  margin: 12px auto 20px auto !important; /* centered + spacing */
}

.editprofile-cancel:hover {
  background: #dcdcdc !important;
  transform: translateY(-1px);
}
.editprofile-wrapper {
  min-height: 100vh;
  width: 100%;
  padding: 40px 0;
  overflow-y: auto;        /* <-- FIX: allow page to scroll */
  display: flex;
  flex-direction: column;
  align-items: center;
}
.editprofile-save,
.editprofile-cancel {
  width: 70%;
  max-width: 240px;
  margin: 0 auto;          /* <-- centers them */
  display: block;
}
#logo {
  border: none !important;
}
/* FREEZE BACKGROUND WHEN EDIT PROFILE IS OPEN */
html[data-route="universe"][data-editprofile="1"] {
  background-attachment: fixed !important;
  background-position: center top !important;
  background-size: cover !important;
  background-repeat: no-repeat !important;
}
/* ============================================
   GLOBAL LAYOUT
   ============================================ */
.reg-page {
  min-height: 100vh;
  background: #f5f6f8;
  display: flex;
  flex-direction: column;
  font-family: Inter, -apple-system, BlinkMacSystemFont, sans-serif;
  overflow-y: auto;
  margin: 0;
  padding: 0;
}

/* Top-left logo */
.reg-top {
  width: 100%;
  padding: 20px 24px;
  display: flex;
  justify-content: flex-start;
}
.reg-corner-logo {
  width: 50px;
  height: 50px;
  opacity: 0.9;
  transition: opacity .25s ease;
}
.reg-corner-logo:hover {
  opacity: 1;
}

/* ============================================
   MAIN CONTENT
   ============================================ */
.reg-main {
  flex: 1;
  width: 100%;
  display: flex;
  justify-content: center;
  padding: 40px 0 90px; /* bottom padding fixes clipped button */
}

.reg-shell {
  width: 100%;
  max-width: 720px;
  padding: 0 24px;
}

/* ============================================
   CARD
   ============================================ */
.card {
  background: rgba(255, 255, 255, 0.85);
  backdrop-filter: blur(12px) saturate(150%);
  -webkit-backdrop-filter: blur(12px) saturate(150%);
  border-radius: 28px;
  padding: 40px 42px;
  width: 100%;
  box-shadow:
    0 20px 60px rgba(0,0,0,0.15),
    0 6px 20px rgba(0,0,0,0.10);
}

.card h1 {
  margin: 0 0 6px;
  font-size: 30px;
  font-weight: 700;
  color: #111;
}

.lead {
  margin: 0 0 24px;
  font-size: 15px;
  color: #666;
}

/* ============================================
   PHOTO UPLOADER
   ============================================ */
.photo-row {
  margin-bottom: 24px;
}
.photo-uploader {
  display: flex;
  gap: 18px;
  align-items: center;
  cursor: pointer;
}
.photo-circle {
  width: 70px;
  height: 70px;
  border: 2px dashed #bbb;
  border-radius: 50%;
  background: #fafafa;
  display: flex;
  justify-content: center;
  align-items: center;
  font-size: 26px;
  color: #999;
}
.photo-circle img {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  object-fit: cover;
}
.photo-meta {
  display: flex;
  flex-direction: column;
}
.photo-title {
  font-size: 14px;
  color: #222;
}
.hint {
  font-size: 12px;
  color: #777;
}

/* ============================================
   GRID (first + last name)
   ============================================ */
.grid2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 18px;
  margin-bottom: 18px;
}

/* ============================================
   FORM FIELDS
   ============================================ */
.field {
  display: flex;
  flex-direction: column;
  margin-bottom: 18px;
}
.field span {
  font-size: 14px;
  margin-bottom: 6px;
  color: #222;
}
.field input {
  padding: 12px 14px;
  border-radius: 12px;
  font-size: 15px;
  background: #f9fafb;
  border: 1px solid #d1d5db;
  transition: .2s border ease;
}
.field input:focus {
  border-color: #111;
  background: #fff;
}

/* ============================================
   AGREEMENT CHECKBOX
   ============================================ */
.agree {
  display: flex;
  gap: 12px;
  margin: 10px 0 4px;
  align-items: center;
  font-size: 13.5px;
}
.agree input {
  width: 18px;
  height: 18px;
  accent-color: #111;
}

/* ============================================
   ALERTS
   ============================================ */
.alert {
  padding: 12px 14px;
  border-radius: 12px;
  font-size: 14px;
  margin-bottom: 12px;
}
.alert.error {
  background: #fee2e2;
  border: 1px solid #fca5a5;
  color: #b91c1c;
}
.alert.ok {
  background: #e0fbea;
  border: 1px solid #34d399;
  color: #065f46;
}

/* ============================================
   BUTTONS
   ============================================ */
.btn.primary {
  width: 100%;
  max-width: 360px;
  margin: 22px auto 0 auto;
  display: block;
  background: #000;
  color: #fff;
  padding: 14px;
  font-size: 16px;
  font-weight: 600;
  border-radius: 999px;
  transition: .25s ease;
}
.btn.primary:hover {
  background: #222;
}

.btn.ghost {
  text-align: center;
  font-size: 14.5px;
  color: #333;
  text-decoration: underline;
  margin-top: 10px;
}

/* ============================================
   MOBILE OPTIMIZATION
   ============================================ */
@media (max-width: 480px) {
  .card {
    padding: 28px 26px;
  }
  .grid2 {
    grid-template-columns: 1fr;
  }
}
/* MAIN PAGE WRAPPER */
.reg-main {
  width: 100%;
  display: flex;
  justify-content: center;
  padding: 20px;
  margin-top: 20px;
}

/* CENTER COLUMN */
.reg-center {
  width: 100%;
  max-width: 640px;
  display: flex;
  justify-content: center;
}

/* CLEAN, MODERN FORM CARD */
.reg-card {
  background: #ffffff;
  padding: 40px 48px;
  border-radius: 22px;
  width: 100%;
  box-shadow: 0 12px 35px rgba(0,0,0,0.08);
  overflow: visible;
}

.reg-card h1 {
  margin-bottom: 10px;
  font-size: 28px;
  font-weight: 600;
}

.reg-card .lead {
  margin-bottom: 28px;
  color: #555;
  font-size: 15px;
}
/* PAGE BACKGROUND + GLOBAL WRAPPER */
.reg-page {
  background: #f7f7f7;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
}

/* CENTERED LOGO */
.reg-top {
  padding: 40px 0 20px;
  width: 100%;
  display: flex;
  justify-content: center;
}

.reg-logo-wrapper {
  display: flex;
  justify-content: center;
}

.reg-logo {
  width: 58px;
  height: auto;
  opacity: 0.9;
}

/* MAIN CONTAINER */
.reg-main.clean {
  width: 100%;
  display: flex;
  justify-content: center;
  padding: 20px;
}

.reg-center {
  width: 100%;
  max-width: 640px;
}

/* CLEAN WHITE FORM CARD */
.reg-card {
  background: #fff;
  padding: 40px 48px;
  border-radius: 22px;
  box-shadow: 0 12px 35px rgba(0,0,0,0.08);
  overflow: visible !important;
  width: 100%;
}
@media (max-width: 600px) {
  .reg-card {
    padding-bottom: 90px; /* more safety padding for small screens */
  }
}
/* Lift the button and give breathing room */
.reg-card .actions {
  margin-top: 32px;
  padding-bottom: 40px; /* <-- ensures button never touches bottom */
}

.reg-card .btn.primary {
  display: block;
  width: 100%;
  padding: 14px 0;
  border-radius: 12px;
  font-size: 1rem;
}
html, body {
  overflow-y: auto !important;
  height: auto !important;
}
/* ============================================
   HASH HUMANITY — Premium Register Button
   ============================================ */

.hh-reg-btn {
  width: 100%;
  max-width: 360px;
  padding: 14px 0;

  /* Typography */
  font-size: 16px;
  font-weight: 600;
  letter-spacing: 0.3px;

  /* Shape */
  border-radius: 999px;
  border: none;
  cursor: pointer;

  /* Fancy Glassy Background */
  background: linear-gradient(
      135deg,
      rgba(255, 255, 255, 0.15),
      rgba(255, 255, 255, 0.05)
    ),
    var(--ink);
  color: var(--card);

  backdrop-filter: blur(12px) saturate(180%);
  -webkit-backdrop-filter: blur(12px) saturate(180%);

  /* Shadows */
  box-shadow:
    0 4px 15px rgba(0, 0, 0, 0.18),
    inset 0 0 0 1px rgba(255, 255, 255, 0.12);

  transition: 0.25s ease;
}

/* Hover (only when enabled) */
.hh-reg-btn:not(.disabled):hover {
  transform: translateY(-2px);
  box-shadow:
    0 6px 20px rgba(0, 0, 0, 0.25),
    inset 0 0 0 1px rgba(255, 255, 255, 0.16);
  opacity: 1;
}

/* Disabled State */
.hh-reg-btn.disabled,
.hh-reg-btn:disabled {
  opacity: 0.45;
  cursor: not-allowed;
  transform: none;
  box-shadow:
    0 0 0 rgba(0,0,0,0),
    inset 0 0 0 1px rgba(255, 255, 255, 0.08);
}
/* Lift the heading upward for perfect visual balance */
.reg-card h1 {
  margin-top: -10px;   /* pulls the title upward */
  margin-bottom: 6px;  /* keeps spacing tight */
}

/* Pull the lead text up into alignment */
.reg-card .lead {
  margin-top: 0;
  margin-bottom: 20px;  /* reduced gap so it aligns with the button layout */
}
