:root {
  --bg: #161a1f;
  --surface: #1d232b;
  --surface2: #252d37;
  --surface3: #2f3945;
  --border: #384454;
  --border2: #445365;
  --accent: #f7931a;
  --accent-glow: rgba(247,147,26,.24);
  --live: #ff4f6f;
  --zap: #f7931a;
  --zap-dim: rgba(247,147,26,.15);
  --text: #edf2f7;
  --text2: #b3c0cf;
  --muted: #76879a;
  --green: #16c784;
  --purple: #8f5bff;
  --nip05: #8f5bff;
  --sidebar-w: 320px;
  --font-display: 'DM Sans', sans-serif;
}
*{margin:0;padding:0;box-sizing:border-box;}
body{background:var(--bg);color:var(--text);font-family:'DM Sans',sans-serif;min-height:100vh;overflow-x:hidden;}

/* ======== NAV ======== */
nav {
  display:flex;align-items:center;gap:.6rem;
  height:68px;padding:0 1.25rem;
  background:rgba(22,26,31,.97);
  border-bottom:1px solid var(--border);
  position:fixed;top:0;left:0;right:0;z-index:500;
  backdrop-filter:blur(16px);
}
nav .btn{
  font-family:var(--font-display);
  font-weight:700;
  letter-spacing:.01em;
}


/* Logo with JS-controlled dropdown */
.logo-wrap{position:relative;flex-shrink:0;}
.logo {
  font-family:'DM Mono',monospace;font-weight:800;font-size:1rem;
  letter-spacing:.02em;display:flex;align-items:center;gap:.55rem;
  color:var(--text);cursor:pointer;padding:.3rem .55rem;
  border-radius:10px;transition:background .15s;user-select:none;
  background:none;border:none;
}
.logo:hover{background:var(--surface2);}
.logo.dd-open{background:var(--surface2);}
.logo-bolt{color:var(--zap);}
.logo-text-8bit{
  font-family:"Press Start 2P","VT323","DM Mono",monospace;
  font-size:.8rem;
  text-transform:uppercase;
  letter-spacing:.08em;
  line-height:1;
  text-shadow:0 0 0 #000, 1px 1px 0 rgba(0,0,0,.35);
}
.logo-live-pill{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  background:#c42121;
  color:#fff;
  border:1px solid rgba(255,255,255,.25);
  border-radius:4px;
  padding:.18rem .44rem;
  font-family:"Press Start 2P","VT323","DM Mono",monospace;
  font-size:.62rem;
  letter-spacing:.1em;
  line-height:1;
  box-shadow:0 0 0 1px rgba(0,0,0,.28) inset;
}

/* Shared dropdown style */
.nav-dropdown {
  position:absolute;
  background:var(--surface);border:1px solid var(--border2);
  border-radius:12px;padding:.5rem;
  box-shadow:0 20px 60px rgba(0,0,0,.8),0 0 0 1px rgba(255,255,255,.03);
  opacity:0;pointer-events:none;
  transform:translateY(-4px);
  transition:opacity .16s ease, transform .16s ease;
  z-index:600;
  min-width:190px;
}
.nav-dropdown.open {
  opacity:1;pointer-events:all;transform:translateY(0);
}
#logoDropdown { top:calc(100% + 6px); left:0; }
#profileDropdown { top:calc(100% + 6px); right:0; min-width:210px; }

.dd-item {
  display:flex;align-items:center;gap:.75rem;
  padding:.58rem .85rem;border-radius:8px;
  font-size:.83rem;color:var(--text2);cursor:pointer;
  transition:background .1s;background:none;border:none;width:100%;text-align:left;font-family:var(--font-display);font-weight:650;letter-spacing:.01em;
}
.dd-item:hover{background:var(--surface2);color:var(--text);}
.ddi{font-size:1rem;width:1.2rem;text-align:center;flex-shrink:0;}
.dd-count{margin-left:auto;font-family:'DM Mono',monospace;font-size:.65rem;color:var(--live);}
.dd-sep{height:1px;background:var(--border);margin:.3rem 0;}

/* Search */
.search-wrap{flex:1;max-width:420px;position:relative;}
.search-input{width:100%;background:var(--surface2);border:1px solid var(--border);border-radius:10px;padding:.44rem .85rem .44rem 2.35rem;color:var(--text);font-family:'DM Sans',sans-serif;font-size:.83rem;outline:none;transition:border-color .18s;}
.search-input:focus{border-color:var(--border2);box-shadow:0 0 0 3px rgba(232,70,10,.1);}
.search-input::placeholder{color:var(--muted);}
.search-icon{position:absolute;left:.75rem;top:50%;transform:translateY(-50%);color:var(--muted);font-size:.85rem;pointer-events:none;}
.search-results{position:absolute;top:calc(100% + 6px);left:0;right:0;background:var(--surface);border:1px solid var(--border2);border-radius:12px;padding:.5rem;box-shadow:0 16px 48px rgba(0,0,0,.75);display:none;z-index:600;}
.search-results.open{display:block;}
.sr-label{font-family:'DM Mono',monospace;font-size:.62rem;color:var(--muted);text-transform:uppercase;letter-spacing:.1em;padding:.2rem .65rem .3rem;display:block;}
.sr-item{display:flex;align-items:center;gap:.65rem;padding:.46rem .65rem;border-radius:7px;cursor:pointer;transition:background .1s;}
.sr-item:hover{background:var(--surface2);}
.sr-av{width:32px;height:32px;border-radius:50%;background:var(--surface3);display:flex;align-items:center;justify-content:center;font-size:.9rem;flex-shrink:0;}
.sr-av.rect{border-radius:5px;}
.sr-av.nip05-square{
  border-radius:5px;
  border:1.5px solid rgba(155,114,255,.7);
  background:rgba(155,114,255,.13);
  box-shadow:0 0 8px rgba(155,114,255,.55),0 0 18px rgba(155,114,255,.25),inset 0 0 6px rgba(155,114,255,.1);
  animation:nip05Pulse 2.8s ease-in-out infinite;
}
@keyframes nip05Pulse{
  0%,100%{box-shadow:0 0 6px rgba(155,114,255,.5),0 0 14px rgba(155,114,255,.2);}
  50%{box-shadow:0 0 12px rgba(155,114,255,.8),0 0 28px rgba(155,114,255,.4);}
}
.sr-title{font-size:.81rem;font-family:var(--font-display);font-weight:700;letter-spacing:.01em;}
.sr-sub{font-size:.7rem;color:var(--muted);font-family:'DM Mono',monospace;}
.sr-live{margin-left:auto;background:var(--live);color:#fff;font-family:'DM Mono',monospace;font-size:.6rem;padding:.1rem .38rem;border-radius:3px;}

/* Nav right - spacer pushes profile to far right */
.nav-mid{display:flex;align-items:center;gap:.6rem;}
.nav-spacer{flex:1;}

/* Go Live / Live button */
.btn{padding:.42rem 1rem;border-radius:8px;font-size:.82rem;font-weight:600;cursor:pointer;border:none;font-family:'DM Sans',sans-serif;transition:all .15s;display:inline-flex;align-items:center;gap:.4rem;line-height:1;white-space:nowrap;}
.btn-ghost{background:transparent;border:1px solid var(--border2);color:var(--text2);}
.btn-ghost:hover{border-color:var(--accent);color:var(--accent);}
.btn-primary{background:var(--accent);color:#fff;}
.btn-primary:hover{background:#ff5520;box-shadow:0 0 20px var(--accent-glow);}
.btn-zap{background:var(--zap);color:#000;font-weight:700;}
.btn-zap:hover{background:#ffca30;}
.btn-follow{background:var(--surface2);border:1px solid var(--border2);color:var(--text);font-weight:600;}
.btn-follow:hover{border-color:var(--accent);color:var(--accent);}
.btn-follow.following-active{
  border-color:var(--green);
  color:var(--green);
  background:rgba(0,212,138,.12);
  box-shadow:0 0 0 1px rgba(0,212,138,.3),0 0 18px rgba(0,212,138,.26);
  animation:followGlow 2.4s ease-in-out infinite;
}
@keyframes followGlow{
  0%,100%{box-shadow:0 0 0 1px rgba(0,212,138,.32),0 0 10px rgba(0,212,138,.2);}
  50%{box-shadow:0 0 0 1px rgba(0,212,138,.48),0 0 18px rgba(0,212,138,.35);}
}
.btn-live-pulse{background:var(--live);color:#fff;animation:livePulse 2.5s ease infinite;}
.btn-edit-stream-live{border:1px solid rgba(255,59,92,.6);box-shadow:0 0 0 1px rgba(255,59,92,.25),0 0 20px rgba(255,59,92,.22);}
@keyframes livePulse{0%,100%{box-shadow:0 0 0 0 rgba(255,59,92,.4)}50%{box-shadow:0 0 0 6px rgba(255,59,92,0)}}

/* Profile pill - locked to far right */
.nav-profile{position:relative;flex-shrink:0;}
.nav-user-pill{
  display:flex;align-items:center;gap:.35rem;
  padding:.22rem;border-radius:999px;
  cursor:pointer;transition:background .15s;
  border:1px solid transparent;user-select:none;
}
.nav-user-pill:hover{background:var(--surface2);border-color:var(--border);}
.nav-user-pill.dd-open{background:var(--surface2);border-color:var(--border);}
.nav-avatar{width:44px;height:44px;border-radius:50%;background:linear-gradient(135deg,var(--accent),var(--zap));display:flex;align-items:center;justify-content:center;font-size:1.1rem;overflow:hidden;flex-shrink:0;border:2px solid var(--border2);}
.nav-display-name{font-family:var(--font-display);font-size:.82rem;font-weight:700;letter-spacing:.01em;max-width:100px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;}
.nip05-badge{color:var(--nip05);font-size:.72rem;font-weight:700;opacity:.85;}

.nav-logged-in{gap:.45rem;}
.nav-notif-btn{
  width:40px;height:40px;border-radius:10px;
  border:1px solid var(--border2);background:var(--surface2);color:var(--text2);
  display:inline-flex;align-items:center;justify-content:center;cursor:pointer;
  position:relative;flex-shrink:0;transition:border-color .15s,color .15s,background .15s;
}
.nav-notif-btn:hover{border-color:var(--accent);color:var(--accent);background:rgba(232,70,10,.08);}
.nav-notif-icon{font-size:1rem;line-height:1;}
.nav-notif-count{
  position:absolute;top:-6px;right:-6px;min-width:18px;height:18px;padding:0 .25rem;
  border-radius:999px;background:var(--live);color:#fff;border:1px solid rgba(255,255,255,.3);
  display:inline-flex;align-items:center;justify-content:center;font-family:'DM Mono',monospace;font-size:.58rem;font-weight:700;
}

.pd-header{padding:.65rem .85rem .75rem;border-bottom:1px solid var(--border);display:flex;align-items:center;gap:.65rem;}
.pd-av-lg{width:44px;height:44px;border-radius:50%;background:linear-gradient(135deg,var(--accent),var(--zap));display:flex;align-items:center;justify-content:center;font-size:1.2rem;flex-shrink:0;border:2px solid var(--border2);}
.pd-name{font-family:var(--font-display);font-weight:700;font-size:.88rem;display:flex;align-items:center;gap:.3rem;}
.pd-sub{font-family:'DM Mono',monospace;font-size:.64rem;color:var(--muted);margin-top:.1rem;}
.pd-item{display:flex;align-items:center;gap:.65rem;padding:.52rem .85rem;border-radius:7px;font-size:.82rem;color:var(--text2);cursor:pointer;transition:background .1s;width:100%;border:none;background:none;text-align:left;font-family:var(--font-display);font-weight:650;letter-spacing:.01em;}
.pd-item:hover{background:var(--surface2);color:var(--text);}
.pd-signout{color:var(--live);}
.pd-signout:hover{background:rgba(255,59,92,.08)!important;}

.nav-logged-out{display:flex;align-items:center;gap:.5rem;flex-shrink:0;}
.nav-logged-in{display:none;align-items:center;flex-shrink:0;}
.nav-logged-in.on{display:flex;}
.nav-logged-out.off{display:none;}

/* ======== PAGES ======== */
.page{display:none;padding-top:68px;}
.page.active{display:block;}
#videoPage{display:none;padding-top:68px;}
#profilePage{display:none;padding-top:68px;}
#videosPage{display:none;padding-top:76px;}
#faqPage{display:none;padding-top:76px;}
#messagesPage{display:none;padding-top:76px;}
#feedPage{display:none;padding-top:76px;}
#notificationsPage{display:none;padding-top:76px;}
#myStreamsPage{display:none;padding-top:76px;}
#widgetsPage{display:none;padding-top:76px;}

.my-streams-page-wrap{
  max-width:980px;
  margin:0 auto;
  padding:0 1rem 1.8rem;
}
.my-streams-card{
  background:var(--surface);
  border:1px solid var(--border2);
  border-radius:18px;
  overflow:hidden;
  box-shadow:0 40px 120px rgba(0,0,0,.82);
  position:relative;
}
.my-streams-card::before{
  content:'';
  position:absolute;
  top:0;
  left:0;
  right:0;
  height:3px;
  background:linear-gradient(90deg,var(--accent),var(--zap));
}
.my-streams-head{
  padding:1.2rem 1.35rem .45rem;
}
.my-streams-head h2{
  margin:0;
  font-family:var(--font-display);
  font-weight:800;
  font-size:1.15rem;
}
.my-streams-head p{
  margin:.34rem 0 0;
  color:var(--text2);
  font-size:.78rem;
  line-height:1.5;
}
.my-streams-body{
  padding-top:.7rem;
}
.my-streams-status{
  margin-top:.6rem;
  min-height:1.15rem;
  font-size:.74rem;
  color:var(--muted);
}
.my-streams-status.ok{color:var(--green);}
.my-streams-status.err{color:var(--live);}

.widgets-page-wrap{
  max-width:1240px;
  margin:0 auto;
  padding:0 1rem 2rem;
}
.widgets-shell{
  display:grid;
  gap:1rem;
}
.widgets-hero,
.widgets-builder-card,
.widget-tool-card{
  position:relative;
  overflow:hidden;
  border:1px solid var(--border2);
  background:
    radial-gradient(circle at top left, rgba(247,147,26,.12), transparent 28%),
    radial-gradient(circle at 85% 18%, rgba(143,91,255,.16), transparent 22%),
    linear-gradient(180deg, rgba(37,45,55,.98), rgba(29,35,43,.98));
  box-shadow:0 30px 90px rgba(0,0,0,.48);
}
.widgets-builder-card[hidden],
.widgets-grid[hidden],
.widget-tool-card[hidden]{
  display:none !important;
}
.widgets-hero,
.widgets-builder-card{
  border-radius:24px;
}
.widgets-hero{
  padding:1.35rem 1.45rem 1.3rem;
}
.widgets-eyebrow{
  display:inline-flex;
  align-items:center;
  gap:.4rem;
  padding:.3rem .62rem;
  border-radius:999px;
  background:rgba(247,147,26,.14);
  color:var(--accent);
  font-family:'DM Mono',monospace;
  font-size:.68rem;
  letter-spacing:.08em;
  text-transform:uppercase;
}
.widgets-hero h2{
  margin:.85rem 0 .42rem;
  font-family:var(--font-display);
  font-size:clamp(1.4rem, 2.2vw, 2.25rem);
  line-height:1.05;
}
.widgets-hero p{
  max-width:760px;
  color:var(--text2);
  font-size:.88rem;
  line-height:1.65;
}
.widgets-hero-pills{
  margin-top:.95rem;
  display:flex;
  flex-wrap:wrap;
  gap:.55rem;
}
.widget-picker-btn{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  min-height:40px;
  padding:0 .86rem;
  border-radius:999px;
  border:1px solid rgba(255,255,255,.08);
  background:rgba(17,20,26,.62);
  color:var(--text);
  font-size:.74rem;
  font-family:'DM Mono',monospace;
  cursor:pointer;
  transition:transform .18s ease, border-color .18s ease, background .18s ease, box-shadow .18s ease;
}
.widget-picker-btn:hover{
  transform:translateY(-1px);
  border-color:rgba(247,147,26,.34);
  background:rgba(35,23,12,.72);
}
.widget-picker-btn.is-active{
  border-color:rgba(247,147,26,.42);
  background:linear-gradient(135deg, rgba(66,32,8,.94), rgba(38,24,12,.9));
  box-shadow:0 14px 34px rgba(247,147,26,.18);
  color:#fff6e5;
}
.widget-picker-btn:focus-visible{
  outline:none;
  box-shadow:0 0 0 2px rgba(247,147,26,.26);
}
.widgets-picker-note{
  margin-top:.72rem;
  color:var(--muted);
  font-size:.74rem;
  line-height:1.5;
}
.widgets-builder-card{
  padding:1.2rem 1.25rem 1.25rem;
}
.widgets-builder-head{
  display:flex;
  align-items:flex-start;
  justify-content:space-between;
  gap:1rem;
  margin-bottom:.95rem;
}
.widgets-builder-head h3{
  font-family:var(--font-display);
  font-size:1.02rem;
}
.widgets-builder-head p{
  margin-top:.28rem;
  color:var(--text2);
  font-size:.77rem;
  line-height:1.55;
}
.widgets-doc-link{
  min-height:40px;
}
.widgets-builder-grid{
  display:grid;
  grid-template-columns:repeat(2, minmax(0, 1fr));
  gap:.85rem;
}
.widgets-builder-grid [hidden]{
  display:none !important;
}
.widget-source-row{
  display:grid;
  grid-template-columns:minmax(0, 1fr) auto;
  gap:.55rem;
}
.widget-search-btn{
  min-height:42px;
  white-space:nowrap;
}
.widget-profile-search-results{
  margin-top:.62rem;
  display:grid;
  gap:.48rem;
  padding:.72rem;
  border:1px solid rgba(255,255,255,.08);
  border-radius:14px;
  background:rgba(10,14,19,.64);
}
.widget-profile-search-results.is-empty{
  color:var(--muted);
  font-size:.75rem;
  line-height:1.55;
}
.widget-name-style-card,
.widget-zap-style-card{
  width:100%;
  display:grid;
  gap:.78rem;
  padding:.88rem .94rem;
  border:1px solid rgba(255,255,255,.08);
  border-radius:16px;
  background:
    radial-gradient(circle at top right, rgba(143,91,255,.12), transparent 28%),
    rgba(9,13,20,.7);
}
.widget-name-style-grid,
.widget-zap-style-grid{
  display:grid;
  grid-template-columns:repeat(3, minmax(0, 1fr));
  gap:.78rem;
}
.widget-name-style-grid .fg,
.widget-zap-style-grid .fg{
  margin:0;
}
.widget-name-style-grid .fg.full,
.widget-zap-style-grid .fg.full{
  grid-column:1 / -1;
}
.widget-profile-search-item{
  display:grid;
  grid-template-columns:48px minmax(0, 1fr) auto;
  gap:.72rem;
  align-items:center;
  padding:.56rem;
  border:1px solid rgba(255,255,255,.07);
  border-radius:14px;
  background:rgba(18,24,31,.82);
}
.widget-profile-search-main{
  min-width:0;
  display:grid;
  gap:.2rem;
}
.widget-profile-search-name{
  color:#fff;
  font-size:.82rem;
  font-weight:700;
  line-height:1.35;
}
.widget-profile-search-meta{
  color:var(--text2);
  font-size:.7rem;
  font-family:'DM Mono',monospace;
  line-height:1.45;
  word-break:break-all;
}
.widget-profile-search-avatar{
  width:48px;
  height:48px;
  border-radius:14px;
  overflow:hidden;
  border:1px solid rgba(255,255,255,.08);
  background:linear-gradient(135deg, rgba(149,238,255,.16), rgba(94,46,255,.24));
  display:flex;
  align-items:center;
  justify-content:center;
  color:#fff;
  font-family:"Press Start 2P","DM Mono",monospace;
  font-size:.72rem;
}
.widget-profile-search-avatar img{
  width:100%;
  height:100%;
  object-fit:cover;
  display:block;
}
.widget-profile-search-use{
  min-height:36px;
}
.widgets-source-hint{
  min-height:52px;
  padding:.82rem .92rem;
  border:1px solid rgba(255,255,255,.08);
  border-radius:14px;
  background:rgba(13,18,24,.62);
  color:var(--text2);
  font-size:.77rem;
  line-height:1.55;
}
.widgets-source-hint.success{
  border-color:rgba(22,199,132,.3);
  color:#bdf5df;
  background:rgba(22,199,132,.11);
}
.widgets-source-hint.error{
  border-color:rgba(255,79,111,.36);
  color:#ffb2bf;
  background:rgba(255,79,111,.1);
}
.widgets-grid{
  display:grid;
  grid-template-columns:minmax(0, 1fr);
  gap:1rem;
  justify-items:start;
}
.widget-tool-card{
  border-radius:20px;
  display:flex;
  flex-direction:column;
  width:min(100%, 780px);
}
.widget-tool-card.is-active{
  border-color:rgba(247,147,26,.32);
  box-shadow:0 34px 96px rgba(0,0,0,.5), 0 0 0 1px rgba(247,147,26,.14);
}
.widget-tool-preview{
  min-height:180px;
  padding:1rem;
  border-bottom:1px solid rgba(255,255,255,.08);
  background:
    linear-gradient(135deg, rgba(8,14,36,.96), rgba(10,8,28,.92)),
    radial-gradient(circle at top left, rgba(149,238,255,.18), transparent 28%);
  display:flex;
  align-items:center;
  justify-content:center;
}
.widget-tool-preview.name-tag{
  padding:0;
  min-height:0;
  aspect-ratio:6 / 1;
  align-items:stretch;
  justify-content:stretch;
}
.widget-live-preview-shell{
  width:100%;
  min-height:0;
  height:100%;
  position:relative;
}
.widget-live-preview-frame{
  width:100%;
  height:100%;
  min-height:0;
  display:block;
  border:0;
  border-radius:0;
  background:transparent;
  box-shadow:none;
  overflow:hidden;
}
.widget-preview-nameplate{
  width:min(100%, 380px);
  min-height:96px;
  border-radius:24px;
  display:flex;
  align-items:stretch;
  gap:0;
  border:1px solid rgba(255,255,255,.08);
  background:
    radial-gradient(circle at 18% 18%, rgba(149,238,255,.14), transparent 22%),
    radial-gradient(circle at 88% 82%, rgba(94,46,255,.24), transparent 32%),
    linear-gradient(135deg, rgba(16,22,48,.95), rgba(13,10,36,.94));
  box-shadow:0 20px 50px rgba(0,0,0,.34);
}
.widget-preview-avatar{
  width:96px;
  min-width:96px;
  min-height:96px;
  border-radius:0;
  display:flex;
  align-items:center;
  justify-content:center;
  color:#fff;
  font-family:"Press Start 2P","DM Mono",monospace;
  font-size:1.1rem;
  background:linear-gradient(135deg, #95eeff, #5e2eff);
  box-shadow:0 12px 30px rgba(66,191,255,.25);
}
.widget-preview-copy{
  min-width:0;
  display:flex;
  flex-direction:column;
  justify-content:center;
  gap:.34rem;
  padding:0 1rem;
}
.widget-preview-display-name{
  display:inline-flex;
  align-items:center;
  gap:.42rem;
  font-family:"Press Start 2P","DM Mono",monospace;
  font-size:.95rem;
  line-height:1.35;
  color:#fff;
  flex-wrap:wrap;
}
.widget-preview-identity{
  display:flex;
  align-items:center;
  color:rgba(255,255,255,.8);
  font-size:.62rem;
  font-family:'DM Mono',monospace;
  line-height:1.5;
  word-break:break-all;
}
.widget-preview-identity.verified{
  color:#cda9ff;
}
.widget-preview-check{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  width:18px;
  height:18px;
  border-radius:50%;
  color:#fff;
  background:rgba(143,91,255,.92);
  box-shadow:0 0 14px rgba(143,91,255,.35);
  font-size:.72rem;
  line-height:1;
  flex-shrink:0;
}
.widget-tool-preview.zap-alerts{
  justify-content:flex-end;
  align-items:flex-start;
}
.widget-preview-alert{
  --widget-preview-zap-border: rgba(247,147,26,.28);
  --widget-preview-zap-bg: linear-gradient(135deg, rgba(44,24,8,.95), rgba(24,14,8,.94));
  --widget-preview-zap-shadow: 0 18px 42px rgba(0,0,0,.42);
  --widget-preview-zap-name-color: #fff;
  --widget-preview-zap-accent: #ffd77a;
  --widget-preview-zap-note: #f5dcc0;
  --widget-preview-zap-time: rgba(255,255,255,.54);
  --widget-preview-zap-name-font: var(--font-display);
  --widget-preview-zap-meta-font: 'DM Mono',monospace;
  --widget-preview-zap-name-size: .98rem;
  --widget-preview-zap-note-size: .76rem;
  --widget-preview-zap-time-size: .62rem;
  --widget-preview-zap-motion-ms: 450ms;
  width:min(100%, 320px);
  padding:.95rem 1rem;
  border-radius:18px;
  border:1px solid var(--widget-preview-zap-border);
  background:var(--widget-preview-zap-bg);
  box-shadow:var(--widget-preview-zap-shadow);
}
.widget-preview-zap-top{
  display:flex;
  align-items:flex-start;
  justify-content:space-between;
  gap:.65rem;
}
.widget-preview-alert strong{
  display:block;
  color:var(--widget-preview-zap-name-color);
  font-family:var(--widget-preview-zap-name-font);
  font-size:var(--widget-preview-zap-name-size);
  line-height:1.25;
}
.widget-preview-zap-amount{
  color:var(--widget-preview-zap-accent);
  font-family:var(--widget-preview-zap-meta-font);
  font-size:.75rem;
  letter-spacing:.04em;
  white-space:nowrap;
}
.widget-preview-zap-note{
  display:block;
  margin-top:.32rem;
  color:var(--widget-preview-zap-note);
  font-size:var(--widget-preview-zap-note-size);
  line-height:1.5;
}
.widget-preview-alert em{
  display:block;
  margin-top:.42rem;
  color:var(--widget-preview-zap-time);
  font-size:var(--widget-preview-zap-time-size);
  font-style:normal;
  font-family:var(--widget-preview-zap-meta-font);
  letter-spacing:.08em;
  text-transform:uppercase;
}
.widget-preview-alert.theme-violet-night{
  --widget-preview-zap-border: rgba(162,122,255,.3);
  --widget-preview-zap-bg:
    radial-gradient(circle at top left, rgba(162,122,255,.16), transparent 24%),
    linear-gradient(135deg, rgba(28,16,52,.95), rgba(15,11,33,.94));
  --widget-preview-zap-accent:#e5c9ff;
  --widget-preview-zap-note:#f3e2ff;
}
.widget-preview-alert.theme-mint-pop{
  --widget-preview-zap-border: rgba(78,229,173,.28);
  --widget-preview-zap-bg:
    radial-gradient(circle at top left, rgba(78,229,173,.16), transparent 24%),
    linear-gradient(135deg, rgba(10,39,31,.95), rgba(9,24,23,.94));
  --widget-preview-zap-accent:#b5ffd9;
  --widget-preview-zap-note:#d8fff0;
}
.widget-preview-alert.theme-glacier{
  --widget-preview-zap-border: rgba(132,189,255,.3);
  --widget-preview-zap-bg:
    radial-gradient(circle at top left, rgba(132,189,255,.18), transparent 24%),
    linear-gradient(135deg, rgba(14,30,56,.95), rgba(9,18,36,.94));
  --widget-preview-zap-accent:#d6e8ff;
  --widget-preview-zap-note:#e5f1ff;
}
.widget-preview-alert.theme-rose-spark{
  --widget-preview-zap-border: rgba(255,117,166,.28);
  --widget-preview-zap-bg:
    radial-gradient(circle at top left, rgba(255,117,166,.18), transparent 24%),
    linear-gradient(135deg, rgba(54,13,32,.95), rgba(28,9,24,.94));
  --widget-preview-zap-accent:#ffd4e8;
  --widget-preview-zap-note:#ffe4f0;
}
.widget-preview-alert.theme-graphite-ember{
  --widget-preview-zap-border: rgba(255,128,84,.28);
  --widget-preview-zap-bg:
    radial-gradient(circle at top left, rgba(255,128,84,.16), transparent 24%),
    linear-gradient(135deg, rgba(36,22,18,.95), rgba(18,16,15,.94));
  --widget-preview-zap-accent:#ffd2b9;
  --widget-preview-zap-note:#ffe6d8;
}
.widget-preview-alert.font-grotesk{
  --widget-preview-zap-name-font:'Space Grotesk','DM Sans',sans-serif;
  --widget-preview-zap-meta-font:'DM Sans',sans-serif;
}
.widget-preview-alert.font-mono{
  --widget-preview-zap-name-font:'DM Mono',monospace;
  --widget-preview-zap-meta-font:'DM Mono',monospace;
  --widget-preview-zap-name-size:.9rem;
}
.widget-preview-alert.font-orbitron{
  --widget-preview-zap-name-font:'Orbitron','DM Sans',sans-serif;
  --widget-preview-zap-meta-font:'DM Sans',sans-serif;
  --widget-preview-zap-name-size:.9rem;
}
.widget-preview-alert.font-oswald{
  --widget-preview-zap-name-font:'Oswald','DM Sans',sans-serif;
  --widget-preview-zap-meta-font:'DM Sans',sans-serif;
  --widget-preview-zap-name-size:1.08rem;
}
.widget-preview-alert.font-syne{
  --widget-preview-zap-name-font:'Syne','DM Sans',sans-serif;
  --widget-preview-zap-meta-font:'DM Sans',sans-serif;
}
.widget-preview-alert.font-arcade{
  --widget-preview-zap-name-font:"Press Start 2P","DM Mono",monospace;
  --widget-preview-zap-meta-font:'DM Mono',monospace;
  --widget-preview-zap-name-size:.8rem;
  --widget-preview-zap-note-size:.72rem;
}
.widget-preview-alert.is-preview-animating.effect-slide{
  animation:widgetPreviewZapSlideIn var(--widget-preview-zap-motion-ms) cubic-bezier(.2,.8,.2,1);
}
.widget-preview-alert.is-preview-animating.effect-fade{
  animation:widgetPreviewZapFadeIn var(--widget-preview-zap-motion-ms) ease;
}
.widget-preview-alert.is-preview-animating.effect-pop{
  animation:widgetPreviewZapPopIn var(--widget-preview-zap-motion-ms) cubic-bezier(.2,.8,.2,1);
}
@keyframes widgetPreviewZapSlideIn{
  from{
    opacity:0;
    transform:translate3d(18px,0,0) scale(.96);
  }
  to{
    opacity:1;
    transform:translate3d(0,0,0) scale(1);
  }
}
@keyframes widgetPreviewZapFadeIn{
  from{
    opacity:0;
  }
  to{
    opacity:1;
  }
}
@keyframes widgetPreviewZapPopIn{
  from{
    opacity:0;
    transform:scale(.85);
  }
  to{
    opacity:1;
    transform:scale(1);
  }
}
.widget-tool-preview.stream-chat{
  justify-content:flex-start;
}
.widget-preview-chat{
  width:min(100%, 340px);
  display:grid;
  gap:.48rem;
}
.widget-preview-chat div{
  padding:.72rem .8rem;
  border-radius:16px;
  border:1px solid rgba(255,255,255,.07);
  background:rgba(9,13,19,.78);
  color:var(--text2);
  font-size:.76rem;
  line-height:1.55;
}
.widget-preview-chat strong{
  color:#fff;
}
.widget-preview-counter{
  min-width:210px;
  padding:.92rem 1rem;
  border-radius:22px;
  border:1px solid rgba(255,255,255,.08);
  display:grid;
  gap:.32rem;
  background:
    radial-gradient(circle at top left, rgba(247,147,26,.12), transparent 24%),
    linear-gradient(135deg, rgba(18,23,30,.95), rgba(8,12,18,.95));
  box-shadow:0 20px 44px rgba(0,0,0,.36);
}
.widget-preview-counter span{
  color:transparent;
  font-family:'DM Mono',monospace;
  font-size:0;
  letter-spacing:0;
}
.widget-preview-counter span::before{
  content:'VIEWERS';
  color:var(--text2);
  font-size:.68rem;
  letter-spacing:.14em;
}
.widget-preview-counter strong{
  color:#fff;
  font-size:2rem;
  font-family:var(--font-display);
  line-height:1;
}
.widget-tool-body{
  display:grid;
  gap:.72rem;
  padding:1rem 1rem 1.05rem;
}
.widget-tool-meta{
  display:flex;
  align-items:flex-start;
  justify-content:space-between;
  gap:.8rem;
}
.widget-tool-meta h3{
  font-family:var(--font-display);
  font-size:1rem;
}
.widget-tool-meta span{
  display:inline-flex;
  align-items:center;
  min-height:28px;
  padding:0 .62rem;
  border-radius:999px;
  background:rgba(255,255,255,.06);
  color:var(--text2);
  font-family:'DM Mono',monospace;
  font-size:.67rem;
}
.widget-tool-body p{
  color:var(--text2);
  font-size:.77rem;
  line-height:1.58;
}
.widget-url-label{
  color:var(--muted);
  font-size:.68rem;
  font-family:'DM Mono',monospace;
  letter-spacing:.08em;
  text-transform:uppercase;
}
.widget-url-row{
  display:grid;
  grid-template-columns:minmax(0,1fr) auto;
  gap:.55rem;
}
.widget-url-input{
  width:100%;
  min-height:42px;
  background:rgba(10,14,19,.74);
  border:1px solid var(--border2);
  border-radius:12px;
  padding:0 .78rem;
  color:var(--text);
  font-family:'DM Mono',monospace;
  font-size:.71rem;
  outline:none;
}
.widget-url-input:focus{
  border-color:var(--accent);
}
.widget-actions{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:.8rem;
  flex-wrap:wrap;
}
.widget-status-note{
  color:var(--muted);
  font-size:.69rem;
  line-height:1.45;
}

@media (max-width:1020px){
  .widgets-grid{grid-template-columns:1fr;}
}

/* ======== VIDEOS PAGE ======== */
.videos-page-wrap{
  max-width:1320px;
  margin:0 auto;
  padding:0 1rem 1.8rem;
}
.videos-page-head{
  display:flex;
  align-items:flex-end;
  justify-content:space-between;
  gap:.9rem;
  border:1px solid var(--border2);
  border-radius:14px;
  padding:.88rem .92rem;
  background:linear-gradient(160deg,rgba(232,70,10,.13),rgba(247,183,49,.08));
  margin-bottom:.8rem;
}
.videos-page-title-wrap h2{
  margin:0;
  font-family:var(--font-display);
  font-size:1.15rem;
  letter-spacing:.01em;
}
.videos-page-title-wrap p{
  margin:.3rem 0 0;
  color:var(--text2);
  font-size:.82rem;
  line-height:1.5;
}
.videos-page-count{
  font-family:'DM Mono',monospace;
  font-size:.66rem;
  color:var(--accent);
  background:rgba(232,70,10,.12);
  border:1px solid rgba(232,70,10,.25);
  border-radius:999px;
  padding:.2rem .58rem;
  white-space:nowrap;
}
.videos-filter-row{
  display:flex;
  align-items:center;
  gap:.46rem;
  margin:0 0 .76rem;
  flex-wrap:wrap;
}
.videos-filter-btn{
  border:1px solid var(--border2);
  background:var(--surface2);
  color:var(--text2);
  border-radius:999px;
  padding:.34rem .66rem;
  font-size:.71rem;
  font-family:'DM Sans',sans-serif;
  font-weight:600;
  cursor:pointer;
  transition:all .14s;
}
.videos-filter-btn:hover{
  border-color:var(--accent);
  color:var(--text);
}
.videos-filter-btn.active{
  border-color:rgba(232,70,10,.52);
  color:#fff;
  background:linear-gradient(135deg,rgba(232,70,10,.95),rgba(247,183,49,.86));
  box-shadow:0 6px 14px rgba(232,70,10,.22);
}
.videos-grid{
  display:grid;
  grid-template-columns:repeat(auto-fill,minmax(290px,1fr));
  gap:1rem;
}
.video-archive-card{
  border-radius:12px;
  background:var(--surface);
  border:1px solid var(--border);
  overflow:hidden;
  cursor:pointer;
  transition:transform .15s,border-color .15s,box-shadow .15s;
}
.video-archive-card:hover{
  transform:translateY(-2px);
  border-color:var(--accent);
  box-shadow:0 10px 24px rgba(0,0,0,.22);
}
.video-archive-thumb-wrap{
  position:relative;
  aspect-ratio:16/9;
  background:#0d1520;
  overflow:hidden;
}
.video-archive-thumb{
  width:100%;
  height:100%;
  object-fit:cover;
  display:block;
}
.video-archive-thumb-video{
  width:100%;
  height:100%;
  object-fit:cover;
  display:block;
  background:#0d1520;
}
.video-archive-play{
  position:absolute;
  left:50%;
  top:50%;
  transform:translate(-50%,-50%);
  width:42px;
  height:42px;
  border-radius:50%;
  border:1px solid rgba(255,255,255,.45);
  background:rgba(0,0,0,.5);
  color:#fff;
  display:flex;
  align-items:center;
  justify-content:center;
  font-size:1rem;
  pointer-events:none;
}
.video-archive-badge{
  position:absolute;
  top:8px;
  left:8px;
  border-radius:999px;
  padding:.16rem .45rem;
  font-family:'DM Mono',monospace;
  font-size:.58rem;
  letter-spacing:.08em;
  color:#fff;
  background:rgba(255,59,92,.88);
}
.video-archive-badge.video-file{
  background:rgba(232,70,10,.9);
}
.video-archive-badge.watch-party{
  background:rgba(232,70,10,.92);
}
.video-archive-duration{
  position:absolute;
  right:8px;
  bottom:8px;
  border-radius:4px;
  padding:.14rem .36rem;
  font-family:'DM Mono',monospace;
  font-size:.58rem;
  color:#fff;
  background:rgba(0,0,0,.72);
}
.video-archive-meta{
  display:flex;
  gap:.58rem;
  padding:.65rem .62rem .68rem;
}
.video-archive-avatar{
  width:34px;
  height:34px;
  border-radius:50%;
  border:1px solid var(--border2);
  background:var(--surface2);
  display:flex;
  align-items:center;
  justify-content:center;
  overflow:hidden;
  flex-shrink:0;
}
.video-archive-avatar.nip05-square{
  border-radius:5px;
}
.video-archive-text{
  min-width:0;
}
.video-archive-title{
  font-size:.81rem;
  line-height:1.35;
  font-weight:700;
  color:var(--text);
  display:-webkit-box;
  -webkit-line-clamp:2;
  -webkit-box-orient:vertical;
  overflow:hidden;
}
.video-archive-host{
  margin-top:.2rem;
  color:var(--text2);
  font-size:.72rem;
}
.video-archive-sub{
  margin-top:.18rem;
  color:var(--muted);
  font-size:.67rem;
  font-family:'DM Mono',monospace;
}
.videos-empty{
  grid-column:1/-1;
  border:1px dashed var(--border2);
  border-radius:12px;
  padding:1.3rem;
  text-align:center;
  color:var(--text2);
  background:var(--surface2);
}

.video-post-modal-ov{z-index:2100;}
.video-post-modal{
  width:min(1600px,96vw);
  height:min(94vh,980px);
  background:var(--surface);
  border:1px solid var(--border2);
  border-radius:18px;
  overflow:hidden;
  position:relative;
  box-shadow:0 40px 120px rgba(0,0,0,.9);
  animation:slideUp .22s cubic-bezier(.4,0,.2,1);
  display:flex;
  flex-direction:column;
}
.video-post-modal::before{
  content:'';
  position:absolute;
  top:0;
  left:0;
  right:0;
  height:3px;
  background:linear-gradient(90deg,var(--accent),var(--zap));
  z-index:2;
}
.video-post-close{
  position:absolute;
  top:.8rem;
  right:.8rem;
  z-index:3;
}
.video-post-banner{
  height:174px;
  background:linear-gradient(140deg,rgba(232,70,10,.36),rgba(247,183,49,.28),rgba(24,34,48,.74));
  background-size:cover;
  background-position:center;
  border-bottom:1px solid var(--border2);
}
.video-post-modal.video-post-no-banner .video-post-banner{display:none;}
.video-post-host-row{
  display:flex;
  align-items:center;
  gap:.75rem;
  width:fit-content;
  max-width:calc(100% - 1.9rem);
  margin:0;
  padding:.62rem .78rem;
  position:absolute;
  top:6px;
  left:.95rem;
  z-index:3;
  background:rgba(20,26,33,.78);
  border:1px solid rgba(255,255,255,.09);
  backdrop-filter:blur(8px);
  border-radius:12px;
  pointer-events:auto;
}
.video-post-host-row.linkable{cursor:pointer;}
.video-post-host-row.linkable:focus-visible{
  outline:2px solid rgba(155,114,255,.78);
  outline-offset:2px;
}
.video-post-host-row.verified{
  background:rgba(74,50,108,.68);
  border-color:rgba(155,114,255,.62);
  box-shadow:0 0 0 1px rgba(155,114,255,.28),0 12px 26px rgba(90,54,144,.24);
}
.video-post-host-row.unverified{
  background:rgba(20,26,33,.78);
  border-color:rgba(255,255,255,.09);
}
.video-post-host-avatar{
  width:72px;
  height:72px;
  border-radius:50%;
  border:3px solid var(--surface);
  background:var(--surface2);
  overflow:hidden;
  display:flex;
  align-items:center;
  justify-content:center;
  flex-shrink:0;
}
.video-post-host-avatar.nip05-square{
  border-radius:10px;
  border:2px solid rgba(155,114,255,.72);
  background:rgba(155,114,255,.13);
  box-shadow:0 0 10px rgba(155,114,255,.58),0 0 22px rgba(155,114,255,.3),inset 0 0 8px rgba(155,114,255,.12);
  animation:nip05Pulse 2.8s ease-in-out infinite;
}
.video-post-host-meta{min-width:0;display:flex;flex-direction:column;gap:.16rem;}
.video-post-host-name-row{display:flex;align-items:center;gap:.32rem;min-width:0;}
.video-post-title{
  font-family:var(--font-display);
  font-size:1.02rem;
  font-weight:760;
  color:var(--text);
  line-height:1.3;
  display:-webkit-box;
  -webkit-line-clamp:2;
  -webkit-box-orient:vertical;
  overflow:hidden;
}
.video-post-host-name{
  font-size:.84rem;
  font-weight:700;
  color:var(--text2);
  line-height:1.35;
  cursor:pointer;
}
.video-post-host-name:hover{text-decoration:underline;}
.video-post-host-check{
  font-size:.66rem;
  line-height:1;
  opacity:.95;
  flex-shrink:0;
}
.video-post-host-id{
  font-family:'DM Mono',monospace;
  font-size:.64rem;
  color:var(--muted);
  line-height:1.4;
  max-width:min(62vw,430px);
  overflow:hidden;
  text-overflow:ellipsis;
  white-space:nowrap;
}
.video-post-host-row.verified .video-post-host-id{color:#d9c9ff;}
.video-post-modal.video-post-no-banner .video-post-host-row{
  position:relative;
  top:auto;
  left:auto;
  margin:.62rem .95rem .32rem;
}
.video-post-modal.video-post-no-banner .video-post-body{
  padding-top:.08rem;
}
.video-post-body{
  flex:1;
  min-height:0;
  display:grid;
  grid-template-columns:minmax(0,1.55fr) minmax(340px,.95fr);
  gap:.75rem;
  padding:0 .78rem .78rem;
}
.video-post-player-col{min-height:0;}
.video-post-player-wrap{
  position:relative;
  height:100%;
  min-height:340px;
  max-height:calc(94vh - 278px);
  background:#000;
  border:1px solid var(--border2);
  border-radius:12px;
  overflow:hidden;
}
.video-post-player-wrap video{
  width:100%;
  height:100%;
  object-fit:contain;
  display:block;
  background:#000;
}
.video-post-player-status{
  position:absolute;
  inset:0;
  display:none;
  align-items:center;
  justify-content:center;
  text-align:center;
  padding:1rem;
  color:var(--text2);
  font-size:.82rem;
  background:linear-gradient(180deg,rgba(7,11,16,.72),rgba(7,11,16,.84));
}
.video-post-side-col{
  min-height:0;
  overflow-y:auto;
  display:flex;
  flex-direction:column;
  gap:.7rem;
  padding-right:.18rem;
}
.video-post-side-block{
  border:1px solid var(--border);
  border-radius:12px;
  background:var(--surface2);
  padding:.68rem .72rem;
}
.video-post-side-head{
  font-family:'DM Mono',monospace;
  font-size:.63rem;
  color:var(--muted);
  letter-spacing:.09em;
  text-transform:uppercase;
  margin-bottom:.45rem;
}
.video-post-body-text{
  color:var(--text2);
  font-size:.8rem;
  line-height:1.55;
}
.video-post-body-media{margin-top:.55rem;}
.video-post-comments-status{
  font-family:'DM Mono',monospace;
  font-size:.64rem;
  color:var(--muted);
  margin-bottom:.4rem;
}
.video-post-comments-list{
  display:flex;
  flex-direction:column;
  gap:.5rem;
}
.video-post-live-chat-list{
  display:flex;
  flex-direction:column;
  gap:.42rem;
  max-height:44vh;
  overflow-y:auto;
  padding-right:.08rem;
}
.video-post-live-chat-list .cmsg{padding:.06rem .02rem;}
.video-post-live-chat-list .c-text{font-size:.75rem;}
.video-post-live-chat-list .chat-media-wrap{max-width:220px;}
.video-post-comment-form{margin-top:.62rem;}
.video-post-comment-markup button{padding:.13rem .32rem;font-size:.55rem;}
.video-post-empty{
  border:1px dashed var(--border2);
  border-radius:9px;
  padding:.62rem;
  font-size:.74rem;
  color:var(--muted);
  background:rgba(255,255,255,.02);
}
.video-post-comment-item{
  display:flex;
  align-items:flex-start;
  gap:.44rem;
  border:1px solid var(--border2);
  border-radius:10px;
  padding:.42rem;
  background:rgba(255,255,255,.02);
}
.video-post-comment-avatar{
  width:30px;
  height:30px;
  border-radius:50%;
  border:1px solid var(--border2);
  background:var(--surface3);
  overflow:hidden;
  display:flex;
  align-items:center;
  justify-content:center;
  flex-shrink:0;
  cursor:pointer;
}
.video-post-comment-avatar.nip05-square{border-radius:7px;}
.video-post-comment-main{min-width:0;flex:1;}
.video-post-comment-meta{display:flex;align-items:center;gap:.33rem;}
.video-post-comment-name{
  font-size:.72rem;
  font-weight:650;
  color:var(--text);
  cursor:pointer;
}
.video-post-comment-name:hover{text-decoration:underline;}
.video-post-comment-time{
  font-family:'DM Mono',monospace;
  font-size:.61rem;
  color:var(--muted);
}
.video-post-comment-nip05{font-size:.61rem;line-height:1;opacity:.95;}
.video-post-comment-text{
  margin-top:.18rem;
  font-size:.74rem;
  color:var(--text2);
  line-height:1.45;
  word-break:break-word;
}
.video-post-comment-media{margin-top:.34rem;}
.video-post-media-wrap,
.video-post-comment-media-wrap{
  display:grid;
  grid-template-columns:repeat(2,minmax(0,1fr));
  gap:.34rem;
}
.video-post-media-wrap.single,
.video-post-comment-media-wrap.single{
  grid-template-columns:1fr;
}
.video-post-media-item,
.video-post-comment-media-item{
  border:1px solid var(--border2);
  border-radius:8px;
  overflow:hidden;
  background:#070b10;
  min-height:112px;
}
.video-post-media-item.single,
.video-post-comment-media-item.single{min-height:156px;}
.video-post-modal.video-post-watch-party .video-post-body-media .video-post-media-wrap{
  width:min(100%,320px);
}
.video-post-modal.video-post-watch-party .video-post-body-media .video-post-media-item{
  min-height:82px;
}
.video-post-modal.video-post-watch-party .video-post-body-media .video-post-media-item.single{
  min-height:120px;
  max-height:172px;
}
.video-post-media-item img,
.video-post-comment-media-item img{
  width:100%;
  height:100%;
  display:block;
  object-fit:cover;
}
.video-post-media-item video,
.video-post-comment-media-item video{
  width:100%;
  height:100%;
  display:block;
  object-fit:contain;
  background:#000;
}
.video-post-media-item.media-audio,
.video-post-comment-media-item.media-audio{
  min-height:auto;
  padding:.4rem;
  background:var(--surface);
}

@media (max-width:1200px){
  .video-post-body{grid-template-columns:minmax(0,1fr);}
  .video-post-player-wrap{max-height:min(56vh,560px);}
  .video-post-side-col{max-height:38vh;}
}
@media (max-width:720px){
  .video-post-modal{width:100vw;height:100vh;border-radius:0;}
  .video-post-banner{height:144px;}
  .video-post-host-row{max-width:calc(100% - 1.1rem);top:6px;left:.55rem;padding:.5rem .58rem;gap:.58rem;}
  .video-post-host-avatar{width:60px;height:60px;}
  .video-post-title{font-size:.92rem;}
  .video-post-body{padding:0 .55rem .55rem;}
  .video-post-player-wrap{min-height:230px;max-height:44vh;}
  .video-post-host-id{max-width:calc(100vw - 136px);}
  .video-post-modal.video-post-watch-party .video-post-body-media .video-post-media-wrap{width:min(100%,250px);}
  .video-post-modal.video-post-no-banner .video-post-host-row{margin:.55rem .55rem .2rem;left:auto;}
}

/* ======== NOSTR FEED PAGE ======== */
.nostr-feed-wrap{
  max-width:980px;
  margin:0 auto;
  padding:0 1rem 2rem;
}
.nostr-feed-head{
  display:flex;
  align-items:flex-end;
  justify-content:space-between;
  gap:.9rem;
  border:1px solid var(--border2);
  border-radius:14px;
  padding:.88rem .92rem;
  background:linear-gradient(160deg,rgba(143,91,255,.16),rgba(232,70,10,.11));
  margin-bottom:.72rem;
}
.nostr-feed-title-wrap h2{
  margin:0;
  font-family:var(--font-display);
  font-size:1.12rem;
  letter-spacing:.01em;
}
.nostr-feed-title-wrap p{
  margin:.28rem 0 0;
  color:var(--text2);
  font-size:.81rem;
  line-height:1.5;
}
.nostr-feed-filter-wrap{
  display:flex;
  flex-direction:column;
  gap:.22rem;
  min-width:220px;
}
.nostr-feed-filter-wrap label{
  font-family:'DM Mono',monospace;
  font-size:.61rem;
  color:var(--muted);
  letter-spacing:.08em;
  text-transform:uppercase;
}
#nostrFeedListSelect{
  width:100%;
  border:1px solid var(--border2);
  background:var(--surface2);
  color:var(--text);
  border-radius:9px;
  padding:.44rem .56rem;
  font-size:.78rem;
  font-family:'DM Sans',sans-serif;
  outline:none;
}
#nostrFeedListSelect:focus{
  border-color:var(--accent);
  box-shadow:0 0 0 2px rgba(232,70,10,.15);
}
.nostr-feed-status{
  min-height:1.25rem;
  margin-bottom:.58rem;
  color:var(--muted);
  font-size:.72rem;
  font-family:'DM Mono',monospace;
  display:flex;
  align-items:center;
  gap:.46rem;
}
.nostr-feed-list .profile-feed-item{
  background:var(--surface);
}

/* ======== NOTIFICATIONS PAGE ======== */
.notifications-wrap{
  max-width:980px;
  margin:0 auto;
  padding:0 1rem 2rem;
}
.notifications-head{
  display:flex;
  align-items:flex-end;
  justify-content:space-between;
  gap:.9rem;
  border:1px solid var(--border2);
  border-radius:14px;
  padding:.88rem .92rem;
  background:linear-gradient(160deg,rgba(0,212,138,.12),rgba(155,114,255,.11));
  margin-bottom:.72rem;
}
.notifications-title-wrap h2{
  margin:0;
  font-family:var(--font-display);
  font-size:1.12rem;
  letter-spacing:.01em;
}
.notifications-title-wrap p{
  margin:.28rem 0 0;
  color:var(--text2);
  font-size:.81rem;
  line-height:1.5;
}
.notifications-actions{
  display:flex;
  align-items:center;
  gap:.45rem;
  flex-wrap:wrap;
  justify-content:flex-end;
}
.notifications-status{
  min-height:1.25rem;
  margin-bottom:.58rem;
  color:var(--muted);
  font-size:.72rem;
  font-family:'DM Mono',monospace;
  display:flex;
  align-items:center;
  gap:.46rem;
}
.notifications-list{
  display:flex;
  flex-direction:column;
  gap:.58rem;
}
.notif-item{
  border:1px solid var(--border);
  border-radius:12px;
  background:var(--surface);
  padding:.72rem .76rem;
  display:flex;
  gap:.62rem;
}
.notif-item.unread{
  border-color:rgba(247,147,26,.38);
  box-shadow:0 0 0 1px rgba(247,147,26,.18) inset;
}
.notif-av{
  width:38px;height:38px;border-radius:50%;
  background:var(--surface3);border:1px solid var(--border2);
  display:flex;align-items:center;justify-content:center;overflow:hidden;flex-shrink:0;cursor:pointer;
}
.notif-main{min-width:0;flex:1;display:flex;flex-direction:column;gap:.2rem;}
.notif-top{
  display:flex;align-items:center;justify-content:space-between;gap:.45rem;
}
.notif-label{
  font-size:.8rem;
  color:var(--text);
  line-height:1.45;
}
.notif-label strong{
  font-family:var(--font-display);
  font-weight:700;
  cursor:pointer;
}
.notif-reaction-chip{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  min-width:1.15rem;
  height:1.15rem;
  padding:0 .34rem;
  margin-left:.24rem;
  border:1px solid var(--border2);
  border-radius:999px;
  background:var(--surface2);
  font-size:.72rem;
  line-height:1;
  vertical-align:middle;
}
.notif-reaction-chip img{
  width:14px;
  height:14px;
  object-fit:contain;
  display:block;
}
.notif-time{
  font-family:'DM Mono',monospace;
  font-size:.63rem;
  color:var(--muted);
  white-space:nowrap;
}
.notif-text{
  font-size:.74rem;
  color:var(--text2);
  line-height:1.45;
  word-break:break-word;
}
.notif-post-preview{
  margin-top:.2rem;
  border:1px solid var(--border2);
  border-radius:8px;
  background:var(--surface2);
  padding:.42rem .5rem;
  font-size:.71rem;
  color:var(--text2);
  line-height:1.45;
  word-break:break-word;
}
.notif-post-preview-text .nostr-md-p{margin:.14rem 0;line-height:1.45;}
.notif-post-preview-text .nostr-md-h1,
.notif-post-preview-text .nostr-md-h2,
.notif-post-preview-text .nostr-md-h3{margin:.16rem 0 .1rem;font-size:.82rem;line-height:1.35;}
.notif-post-preview-text .nostr-md-ul,
.notif-post-preview-text .nostr-md-ol{margin:.2rem 0 .24rem;padding-left:1rem;}
.notif-post-preview-text .nostr-md-blockquote{margin:.2rem 0;padding:.14rem .42rem;}
.notif-post-preview .chat-media-wrap{max-width:min(100%,320px);}
.notif-post-preview-empty{
  font-family:'DM Mono',monospace;
  font-size:.64rem;
  color:var(--muted);
}
.notif-type-chip{
  display:inline-flex;
  align-items:center;
  width:max-content;
  border-radius:999px;
  border:1px solid var(--border2);
  background:var(--surface2);
  color:var(--muted);
  font-family:'DM Mono',monospace;
  font-size:.58rem;
  letter-spacing:.04em;
  text-transform:uppercase;
  padding:.08rem .42rem;
}
.notif-item.type-like .notif-type-chip{border-color:rgba(255,79,111,.36);color:#ff94a8;background:rgba(255,79,111,.12);}
.notif-item.type-repost .notif-type-chip{border-color:rgba(143,91,255,.42);color:#caaeff;background:rgba(143,91,255,.14);}
.notif-item.type-zap .notif-type-chip{border-color:rgba(247,147,26,.42);color:#ffd59b;background:rgba(247,147,26,.14);}
.notif-item.type-follow .notif-type-chip{border-color:rgba(22,199,132,.42);color:#8af2c3;background:rgba(22,199,132,.14);}
.notif-empty{
  border:1px dashed var(--border2);
  border-radius:12px;
  background:var(--surface2);
  padding:.9rem .95rem;
  color:var(--text2);
  font-size:.76rem;
}

/* ======== FAQ PAGE ======== */
.faq-page-wrap{max-width:920px;margin:0 auto;padding:0 1rem 2.2rem;}
.faq-page-hero{border:1px solid var(--border2);background:linear-gradient(160deg,rgba(155,114,255,.16),rgba(232,70,10,.11));border-radius:16px;padding:1.05rem 1.1rem;margin-bottom:.9rem;}
.faq-kid-hero{position:relative;overflow:hidden;}
.faq-kid-hero::after{
  content:'';
  position:absolute;
  inset:auto -45px -60px auto;
  width:180px;
  height:180px;
  border-radius:50%;
  background:radial-gradient(circle,rgba(247,147,26,.2) 0%,rgba(247,147,26,0) 72%);
  pointer-events:none;
}
.faq-page-hero h1{font-family:var(--font-display);font-size:1.5rem;line-height:1.2;margin:0 0 .45rem;}
.faq-page-hero p{margin:.28rem 0;color:var(--text);font-size:.96rem;line-height:1.6;}
.faq-card{background:var(--surface);border:1px solid var(--border);border-radius:14px;padding:1rem 1.05rem;margin-bottom:.82rem;}
.faq-card h2{font-family:var(--font-display);font-size:1.18rem;margin:0 0 .56rem;}
.faq-card h3{font-family:var(--font-display);font-size:.96rem;margin:.72rem 0 .28rem;}
.faq-card p{margin:.32rem 0;color:var(--text);font-size:.96rem;line-height:1.65;}
.faq-card ul,.faq-card ol{margin:.36rem 0 .36rem 1.15rem;padding:0;}
.faq-card li{margin:.2rem 0;color:var(--text);font-size:.93rem;line-height:1.6;}
.faq-card .muted{color:var(--muted);font-size:.88rem;}
.faq-simple-box{margin-top:.52rem;border:1px solid var(--border2);background:var(--surface2);border-radius:10px;padding:.62rem .68rem;}
.faq-simple-box p{margin:.22rem 0 0;}
.faq-diagram{border:1px dashed var(--border2);border-radius:10px;background:rgba(255,255,255,.015);padding:.68rem .72rem;margin:.42rem 0 .58rem;}
.faq-flow{display:flex;align-items:center;gap:.45rem;flex-wrap:wrap;margin-top:.5rem;}
.faq-flow-box{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  min-height:34px;
  border:1px solid var(--border2);
  border-radius:10px;
  background:var(--surface2);
  padding:.35rem .58rem;
  font-size:.8rem;
  font-weight:600;
  color:var(--text);
}
.faq-flow-arrow{
  font-family:'DM Mono',monospace;
  font-size:.78rem;
  color:var(--muted);
}
.faq-flow-big .faq-flow-box{
  min-height:38px;
  font-size:.84rem;
  padding:.42rem .72rem;
}
.faq-step-strip{
  display:grid;
  grid-template-columns:repeat(5,minmax(0,1fr));
  gap:.5rem;
  margin:.62rem 0 .58rem;
}
.faq-step-strip-compact .faq-step-item{min-height:106px;}
.faq-step-item{
  border:1px solid var(--border2);
  background:linear-gradient(170deg,rgba(255,255,255,.02),rgba(0,0,0,.12));
  border-radius:12px;
  padding:.58rem .5rem;
  min-height:98px;
  display:flex;
  flex-direction:column;
  align-items:flex-start;
  gap:.4rem;
}
.faq-step-item p{
  margin:0;
  font-size:.8rem;
  line-height:1.45;
  color:var(--text);
}
.faq-step-num{
  width:24px;
  height:24px;
  border-radius:999px;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  font-family:'DM Mono',monospace;
  font-size:.73rem;
  font-weight:700;
  color:#14181f;
  background:linear-gradient(160deg,#f7931a,#ffbc69);
}
.faq-mini-title{
  margin-top:.22rem;
  color:var(--text2);
  font-size:.86rem;
  font-weight:700;
}
.faq-do-list{
  margin:.35rem 0 .65rem 1.16rem;
  padding:0;
}
.faq-do-list li{
  margin:.24rem 0;
  color:var(--text);
  font-size:.9rem;
  line-height:1.62;
}
.faq-link-grid{
  display:grid;
  grid-template-columns:repeat(2,minmax(0,1fr));
  gap:.52rem;
  margin-top:.38rem;
}
.faq-link-card{
  display:flex;
  flex-direction:column;
  gap:.12rem;
  text-decoration:none;
  border:1px solid var(--border2);
  border-radius:10px;
  background:var(--surface2);
  padding:.58rem .66rem;
  transition:border-color .15s, transform .15s, box-shadow .15s;
}
.faq-link-card:hover{
  border-color:var(--accent);
  transform:translateY(-1px);
  box-shadow:0 8px 20px rgba(232,70,10,.14);
}
.faq-link-card strong{
  color:var(--text);
  font-size:.84rem;
  line-height:1.32;
}
.faq-link-card span{
  color:var(--text2);
  font-size:.73rem;
  line-height:1.42;
}
.faq-link-list{
  margin:.38rem 0 .18rem;
  padding:0;
  list-style:none;
}
.faq-link-list li{
  margin:.3rem 0;
}
.faq-link-list a{
  display:inline-flex;
  align-items:center;
  gap:.4rem;
  text-decoration:none;
  color:var(--text);
  font-size:.86rem;
  line-height:1.5;
}
.faq-link-list a::before{
  content:'>';
  color:var(--accent);
  font-family:'DM Mono',monospace;
  font-size:.72rem;
}
.faq-link-list a:hover{
  color:var(--accent);
}
.faq-summary-card{border-color:rgba(232,70,10,.25);}
.faq-actions{display:flex;gap:.55rem;flex-wrap:wrap;margin-top:.72rem;}

@media (max-width:760px){
  #videosPage{padding-top:72px;}
  #faqPage{padding-top:72px;}
  #messagesPage{padding-top:72px;}
  #feedPage{padding-top:72px;}
  #notificationsPage{padding-top:72px;}
  #myStreamsPage{padding-top:72px;}
  #widgetsPage{padding-top:72px;}
  #messagesRoot{min-height:calc(100vh - 72px);}
  .my-streams-page-wrap{padding:0 .72rem 1.4rem;}
  .widgets-page-wrap{padding:0 .72rem 1.4rem;}
  .my-streams-head{padding:1rem .95rem .35rem;}
  .widgets-hero{padding:1.05rem 1rem 1rem;}
  .widgets-hero-pills{display:grid;grid-template-columns:repeat(2, minmax(0, 1fr));}
  .widget-picker-btn{width:100%;}
  .widgets-builder-card{padding:1rem;}
  .widgets-builder-head{display:block;}
  .widgets-doc-link{margin-top:.9rem;}
  .widgets-builder-grid{grid-template-columns:1fr;}
  .widget-source-row{grid-template-columns:1fr;}
  .widget-name-style-grid,.widget-zap-style-grid{grid-template-columns:1fr;}
  .widget-profile-search-item{grid-template-columns:42px minmax(0, 1fr);}
  .widget-profile-search-use{grid-column:1 / -1;}
  .widgets-grid{grid-template-columns:1fr;}
  .widget-url-row{grid-template-columns:1fr;}
  .go-live-host-modes{grid-template-columns:1fr;padding:.45rem .95rem 0;}
  .go-live-host-note{padding:.38rem .95rem 0;}
  #goLiveModal .modal{width:min(98vw,98vw);height:min(98vh,980px);max-height:98vh;}
  #goLiveModal .mbody{padding:.56rem .95rem .5rem;overflow:auto;}
  #goLiveModal .go-live-self-wrap{display:block;overflow:visible;min-height:unset;}
  #goLiveModal .go-live-create-grid{grid-template-columns:1fr;height:auto;}
  #goLiveModal .go-live-col-form,
  #goLiveModal .go-live-col-preview,
  #goLiveModal .go-live-col-relays,
  #goLiveModal .go-live-create-grid.relays-open .go-live-col-preview{grid-column:auto;}
  #goLiveModal .go-live-col-preview{min-height:unset;}
  #goLiveModal .go-live-stream-preview-video{min-height:220px;height:auto;flex:0 0 auto;aspect-ratio:16/9;}
  #goLiveModal .go-live-preview-controls{grid-template-columns:1fr;}
  #goLiveModal .go-live-relay-list{max-height:260px;flex:0 0 auto;}
  #goLiveModal .mfooter{padding:.56rem .95rem .95rem;}
  #goLiveModal .go-live-third-party-grid{grid-template-columns:1fr;}
  .videos-page-wrap{padding:0 .72rem 1.4rem;}
  .videos-page-head{flex-direction:column;align-items:flex-start;padding:.76rem .74rem;}
  .videos-page-title-wrap h2{font-size:1.02rem;}
  .videos-page-title-wrap p{font-size:.76rem;}
  .videos-filter-row{gap:.36rem;}
  .videos-filter-btn{font-size:.68rem;padding:.3rem .56rem;}
  .videos-grid{grid-template-columns:1fr;gap:.84rem;}
  .nostr-feed-wrap{padding:0 .72rem 1.4rem;}
  .nostr-feed-head{flex-direction:column;align-items:stretch;padding:.76rem .74rem;}
  .nostr-feed-filter-wrap{min-width:0;}
  .nostr-feed-title-wrap h2{font-size:1rem;}
  .nostr-feed-title-wrap p{font-size:.75rem;}
  .notifications-wrap{padding:0 .72rem 1.4rem;}
  .notifications-head{flex-direction:column;align-items:stretch;padding:.76rem .74rem;}
  .notifications-title-wrap h2{font-size:1rem;}
  .notifications-title-wrap p{font-size:.75rem;}
  .notifications-actions{justify-content:flex-start;}
  .notif-item{padding:.68rem .7rem;}
  .notif-av{width:34px;height:34px;}
  .faq-page-wrap{padding:0 .72rem 1.4rem;}
  .faq-page-hero h1{font-size:1.26rem;}
  .faq-card{padding:.88rem .82rem;}
  .faq-card h2{font-size:1.05rem;}
  .faq-card p,.faq-card li{font-size:.9rem;}
  .faq-flow-arrow{display:none;}
  .faq-step-strip{grid-template-columns:1fr;gap:.42rem;}
  .faq-step-item,.faq-step-strip-compact .faq-step-item{min-height:unset;}
  .faq-link-grid{grid-template-columns:1fr;}
}

/* ======== MESSAGES PAGE ======== */
#messagesRoot{
  width:100%;
  min-height:calc(100vh - 76px);
}
.dm-wrap{
  width:100%;
  max-width:none;
  margin:0;
  min-height:calc(100vh - 76px);
  height:calc(100vh - 76px);
  display:grid;
  grid-template-columns:360px minmax(0,1fr) 320px;
  gap:0;
  padding:0;
}
.dm-wrap.dm-address-book-closed{
  grid-template-columns:360px minmax(0,1fr) 0;
}
.dm-wrap.dm-address-book-closed .dm-lists{
  display:none;
}
.dm-wrap.dm-address-book-open .dm-lists{
  display:flex;
}
.dm-panel{
  background:var(--surface);
  border:1px solid var(--border);
  border-radius:0;
  overflow:hidden;
}
.dm-lists{
  order:3;
  display:flex;
  flex-direction:column;
  min-height:calc(100vh - 122px);
  border-right:0;
}
.dm-lists-head{
  padding:.76rem .76rem .62rem;
  border-bottom:1px solid var(--border);
  display:flex;
  flex-direction:column;
  gap:.46rem;
}
.dm-lists-head h2{
  margin:0;
  font-family:var(--font-display);
  font-size:1rem;
}
.dm-side{
  order:1;
  display:flex;
  flex-direction:column;
  min-height:calc(100vh - 122px);
  border-left:0;
}
.dm-side-head{
  padding:.76rem .76rem .62rem;
  border-bottom:1px solid var(--border);
  display:flex;
  flex-direction:column;
  gap:.46rem;
}
.dm-side-title-row{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:.9rem;
  min-width:0;
}
.dm-side-head h2{
  margin:0;
  font-family:var(--font-display);
  font-size:1rem;
}
.dm-conv-inline{
  margin-left:auto;
  white-space:nowrap;
  font-size:.66rem;
}
.dm-contact-select{
  margin-left:auto;
  min-width:190px;
  max-width:62%;
  background:var(--surface2);
  border:1px solid var(--border2);
  border-radius:8px;
  color:var(--text);
  font-size:.72rem;
  padding:.36rem .5rem;
  outline:none;
}
.dm-contact-select:focus{
  border-color:var(--accent);
  box-shadow:0 0 0 2px rgba(232,70,10,.16);
}
.dm-list-select-row{
  display:flex;
}
.dm-list-select-row .dm-contact-select{
  margin-left:0;
  min-width:0;
  max-width:100%;
  width:100%;
}
.dm-sub{
  color:var(--muted);
  font-size:.7rem;
  font-family:'DM Mono',monospace;
}
.dm-new-row,.dm-list-actions-row,.dm-list-add-row,.dm-list-edit-row{
  display:flex;
  gap:.36rem;
}
.dm-list-actions-row{flex-wrap:wrap;}
.dm-new-row input,.dm-list-add-row input,.dm-list-edit-row input{
  flex:1;
  min-width:0;
  background:var(--surface2);
  border:1px solid var(--border2);
  border-radius:8px;
  color:var(--text);
  font-size:.75rem;
  padding:.42rem .52rem;
  outline:none;
}
.dm-new-row input:focus,.dm-list-add-row input:focus,.dm-list-edit-row input:focus{
  border-color:var(--accent);
  box-shadow:0 0 0 2px rgba(232,70,10,.16);
}
.dm-new-row button,.dm-list-actions-row button,.dm-list-add-row button,.dm-list-edit-row button,.dm-compose button,.dm-login-card button,.dm-main-actions button{
  background:var(--surface2);
  border:1px solid var(--border2);
  color:var(--text2);
  border-radius:8px;
  cursor:pointer;
  font-size:.72rem;
  padding:.36rem .56rem;
}
.dm-new-row button:hover,.dm-list-actions-row button:hover,.dm-list-add-row button:hover,.dm-list-edit-row button:hover,.dm-compose button:hover,.dm-login-card button:hover,.dm-main-actions button:hover{
  border-color:var(--accent);
  color:var(--text);
}
.dm-list-actions-row button,.dm-list-edit-row button{font-size:.68rem;padding:.34rem .52rem;}
.dm-list-members{
  flex:1;
  overflow:auto;
  padding:.4rem;
  display:flex;
  flex-direction:column;
  gap:.28rem;
}
.dm-list-member{
  width:100%;
  border:1px solid transparent;
  border-radius:10px;
  background:transparent;
  color:var(--text2);
  display:flex;
  align-items:flex-start;
  gap:.5rem;
  padding:.42rem .5rem;
}
.dm-list-member:hover{
  background:var(--surface2);
  border-color:rgba(255,255,255,.05);
}
.dm-list-member-main{
  min-width:0;
  flex:1;
  display:flex;
  flex-direction:column;
  gap:.1rem;
}
.dm-list-member-name{
  font-size:.78rem;
  font-weight:700;
  color:var(--text);
  overflow:hidden;
  text-overflow:ellipsis;
  white-space:nowrap;
}
.dm-list-member-sub{
  font-size:.66rem;
  color:var(--muted);
  font-family:'DM Mono',monospace;
  overflow:hidden;
  text-overflow:ellipsis;
  white-space:nowrap;
}
.dm-list-member-actions{
  display:flex;
  align-items:center;
  gap:.28rem;
}
.dm-list-member-actions .btn{
  font-size:.65rem;
  padding:.28rem .46rem;
  border-radius:7px;
}
.dm-list-member-remove{
  border-color:rgba(255,59,92,.42) !important;
  color:#ff9aac !important;
}
.dm-list-member-remove:hover{
  border-color:var(--live) !important;
  color:#ffd3dc !important;
  background:rgba(255,59,92,.12) !important;
}
.dm-convo-list{
  flex:1;
  overflow:auto;
  padding:.4rem;
  display:flex;
  flex-direction:column;
  gap:.22rem;
}
.dm-side-foot{
  border-top:1px solid var(--border);
  padding:.52rem .55rem;
}
.dm-side-foot .btn{
  width:100%;
  justify-content:center;
  font-size:.72rem;
  padding:.36rem .56rem;
}
.dm-convo{
  width:100%;
  border:1px solid transparent;
  border-radius:10px;
  background:transparent;
  color:var(--text2);
  cursor:pointer;
  display:flex;
  align-items:flex-start;
  gap:.5rem;
  text-align:left;
  padding:.42rem .5rem;
}
.dm-convo:hover{
  background:var(--surface2);
  border-color:rgba(255,255,255,.05);
}
.dm-convo.active{
  border-color:rgba(232,70,10,.42);
  background:rgba(232,70,10,.09);
  color:var(--text);
}
.dm-av{
  width:34px;
  height:34px;
  border-radius:50%;
  border:1px solid var(--border2);
  background:var(--surface3);
  color:var(--text);
  display:flex;
  align-items:center;
  justify-content:center;
  font-family:'DM Mono',monospace;
  font-size:.72rem;
  flex-shrink:0;
}
.dm-av.nip05-square{
  border-radius:6px;
  border:1.5px solid rgba(155,114,255,.7);
  background:rgba(155,114,255,.13);
  box-shadow:0 0 8px rgba(155,114,255,.55),0 0 16px rgba(155,114,255,.22);
  animation:nip05Pulse 2.8s ease-in-out infinite;
}
.dm-convo-main{
  min-width:0;
  flex:1;
  display:flex;
  flex-direction:column;
  gap:.1rem;
}
.dm-convo-top{
  display:flex;
  align-items:center;
  gap:.35rem;
}
.dm-convo-name{
  font-size:.78rem;
  font-weight:700;
  color:var(--text);
  overflow:hidden;
  text-overflow:ellipsis;
  white-space:nowrap;
}
.dm-convo-time{
  margin-left:auto;
  color:var(--muted);
  font-size:.62rem;
  font-family:'DM Mono',monospace;
}
.dm-convo-preview{
  color:var(--text2);
  font-size:.7rem;
  line-height:1.4;
  overflow:hidden;
  text-overflow:ellipsis;
  white-space:nowrap;
}
.dm-unread{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  min-width:18px;
  height:18px;
  border-radius:999px;
  background:var(--live);
  color:#fff;
  font-size:.58rem;
  font-family:'DM Mono',monospace;
  padding:0 .3rem;
}
.dm-main{
  order:2;
  display:flex;
  flex-direction:column;
  min-height:calc(100vh - 122px);
  border-left:0;
  border-right:0;
}
.dm-main-head{
  border-bottom:1px solid var(--border);
  padding:0;
  display:flex;
  align-items:stretch;
  min-height:110px;
}
.dm-main-title{
  min-width:0;
  width:100%;
}
.dm-main-title-rich{
  --dm-peer-avatar-size:92px;
  position:relative;
  overflow:hidden;
  border:0;
  border-radius:0;
  background:linear-gradient(145deg,rgba(18,24,34,.92),rgba(12,17,26,.92));
  padding:.34rem .58rem;
  min-height:calc(var(--dm-peer-avatar-size) + 18px);
  width:100%;
  display:flex;
  flex-direction:column;
  gap:.3rem;
}
.dm-peer-banner{
  position:absolute;
  inset:0 0 auto 0;
  height:calc(var(--dm-peer-avatar-size) + 10px);
  pointer-events:auto;
  display:flex;
  align-items:center;
  justify-content:flex-start;
  padding:0 .45rem;
  color:rgba(190,204,228,.58);
  font-family:'DM Mono',monospace;
  font-size:.62rem;
  letter-spacing:.04em;
  white-space:nowrap;
  overflow:hidden;
  text-overflow:clip;
  opacity:.6;
}
.dm-peer-banner.dm-peer-banner-fallback{
  background:
    radial-gradient(circle at 22% 32%, rgba(143,91,255,.22), transparent 58%),
    radial-gradient(circle at 84% 74%, rgba(247,147,26,.16), transparent 62%),
    linear-gradient(145deg, rgba(24,31,43,.94), rgba(13,18,26,.96));
}
.dm-peer-banner-img{
  position:absolute;
  inset:0;
  width:100%;
  height:100%;
  object-fit:cover;
  object-position:center;
}
.dm-peer-banner-overlay{
  position:absolute;
  inset:0;
  pointer-events:none;
  background:linear-gradient(180deg, rgba(5,8,12,.22), rgba(5,8,12,.42));
}
.dm-peer-row{
  position:relative;
  z-index:1;
  display:flex;
  align-items:flex-start;
  gap:.55rem;
  flex:1;
  min-width:0;
  margin-top:0;
}
.dm-peer-avatar{
  width:var(--dm-peer-avatar-size);
  height:var(--dm-peer-avatar-size);
  border-radius:50%;
  border:1px solid var(--border2);
  background:var(--surface3);
  color:var(--text);
  display:flex;
  align-items:center;
  justify-content:center;
  overflow:hidden;
  font-family:'DM Mono',monospace;
  font-size:1.05rem;
  flex-shrink:0;
}
.dm-peer-avatar.nip05-square{
  border-radius:8px;
  border:1.5px solid rgba(155,114,255,.72);
  background:rgba(155,114,255,.13);
  box-shadow:0 0 8px rgba(155,114,255,.55),0 0 16px rgba(155,114,255,.22);
  animation:nip05Pulse 2.8s ease-in-out infinite;
}
.dm-peer-meta{
  min-width:0;
  display:flex;
  flex-direction:column;
  justify-content:center;
}
.dm-peer-name-row{
  display:flex;
  align-items:center;
  gap:.38rem;
  min-width:0;
}
.dm-verified-check{
  width:16px;
  height:16px;
  border-radius:50%;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  background:rgba(143,91,255,.18);
  border:1px solid rgba(143,91,255,.46);
  color:#cfbcff;
  font-size:.6rem;
  line-height:1;
  flex-shrink:0;
}
.dm-main-title h3{
  margin:0;
  font-family:var(--font-display);
  font-size:1rem;
  line-height:1.2;
  overflow:hidden;
  text-overflow:ellipsis;
  white-space:nowrap;
}
.dm-main-title p{
  margin:.16rem 0 0;
  color:var(--text2);
  font-size:.68rem;
  font-family:'DM Mono',monospace;
  overflow:hidden;
  text-overflow:ellipsis;
  white-space:nowrap;
}
.dm-peer-follow-link{
  margin-top:.2rem;
  align-self:flex-start;
  font-size:.68rem;
  padding:.22rem .52rem;
}
.dm-main-actions{
  display:flex;
  align-items:center;
  gap:.42rem;
}

.dm-main-actions-col{
  display:flex;
  flex-direction:column;
  align-items:flex-end;
  gap:.34rem;
  min-width:188px;
}
.dm-main-action-row{
  display:flex;
  align-items:center;
  gap:.36rem;
}
.dm-main-action-row .btn{
  padding:.34rem .68rem;
  font-size:.72rem;
}
.dm-status-pill{
  display:inline-flex;
  align-items:center;
  justify-content:flex-start;
  width:fit-content;
  max-width:320px;
  min-height:24px;
  border:1px solid var(--border2);
  border-radius:999px;
  padding:.24rem .58rem;
  background:rgba(255,255,255,.03);
  white-space:normal;
  line-height:1.2;
  text-align:left;
  overflow:hidden;
  text-overflow:ellipsis;
}
.dm-side-meta-row{
  display:flex;
  align-items:center;
  gap:.4rem;
  min-width:0;
}
.dm-side-status{
  align-self:flex-start;
  min-height:20px;
  max-width:240px;
  padding:.16rem .44rem;
  font-size:.62rem;
  white-space:nowrap;
}
.dm-status.error{color:#ff9f9f;}
.dm-status.success{color:#9fffcf;}
.dm-thread{
  flex:1;
  overflow:auto;
  padding:.72rem .82rem 1rem;
  display:flex;
  flex-direction:column;
  gap:.52rem;
}
.dm-msg{
  max-width:min(78%,620px);
  border:1px solid var(--border2);
  border-radius:12px;
  background:var(--surface2);
  padding:.5rem .58rem;
  display:flex;
  flex-direction:column;
  gap:.3rem;
  margin-left:auto;
  margin-right:0;
}
.dm-msg.out{
  margin-left:0;
  margin-right:auto;
  border-color:rgba(232,70,10,.45);
  background:rgba(232,70,10,.12);
}
.dm-msg-top{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:.45rem;
  color:var(--muted);
  font-size:.62rem;
  font-family:'DM Mono',monospace;
}
.dm-msg-who{
  min-width:0;
  display:flex;
  align-items:center;
  gap:.4rem;
}
.dm-msg-from-av{
  width:20px;
  height:20px;
  border-radius:50%;
  border:1px solid var(--border2);
  background:var(--surface3);
  display:flex;
  align-items:center;
  justify-content:center;
  overflow:hidden;
  font-size:.56rem;
  flex-shrink:0;
}
.dm-msg-from{
  overflow:hidden;
  text-overflow:ellipsis;
  white-space:nowrap;
  color:var(--text);
  font-weight:600;
}
.dm-msg-time{
  margin-left:auto;
  white-space:nowrap;
}
.dm-msg.activity{
  border-style:dashed;
  border-color:rgba(247,183,49,.55);
  background:rgba(247,183,49,.08);
}
.dm-msg.activity.dm-zap-activity{
  position:relative;
  overflow:hidden;
  max-width:min(92%,760px);
  border-style:solid;
  border-color:rgba(247,147,26,.42);
  background:linear-gradient(135deg,rgba(247,147,26,.18),rgba(232,70,10,.08));
  box-shadow:0 10px 24px rgba(0,0,0,.2),inset 0 0 0 1px rgba(247,147,26,.08);
  padding:.72rem .82rem;
}
.dm-msg.activity.dm-zap-activity::before{
  content:'';
  position:absolute;
  inset:0;
  pointer-events:none;
  background:linear-gradient(90deg,transparent,rgba(255,214,153,.08),transparent);
  animation:hostedBySweep 3.1s linear infinite;
}
.dm-zap-activity .dm-msg-body,
.dm-zap-activity .dm-msg-lock{
  position:relative;
  z-index:1;
}
.dm-zap-card{
  display:flex;
  flex-direction:column;
  gap:.58rem;
}
.dm-zap-time{
  align-self:flex-end;
  color:#ffd7a8;
  font-size:.68rem;
  line-height:1.2;
  font-family:'DM Mono',monospace;
  opacity:.92;
}
.dm-zap-party{
  appearance:none;
  border:1px solid var(--border2);
  background:var(--surface2);
  color:var(--text);
  border-radius:20px;
  padding:.4rem .66rem .4rem .4rem;
  display:inline-flex;
  align-items:center;
  gap:.5rem;
  min-width:0;
  text-align:left;
  box-shadow:0 0 10px rgba(247,147,26,.14);
  transition:border-color .18s,box-shadow .18s,transform .18s;
}
.dm-zap-party.verified{
  border-color:rgba(155,114,255,.58);
  background:linear-gradient(135deg,rgba(155,114,255,.16),rgba(155,114,255,.08));
  box-shadow:0 0 10px rgba(155,114,255,.16);
}
.dm-zap-party.unverified{
  border-color:var(--border2);
  background:var(--surface2);
  box-shadow:0 0 10px rgba(0,0,0,.08);
}
.dm-zap-party:hover{
  border-color:rgba(155,114,255,.52);
  box-shadow:0 0 18px rgba(155,114,255,.18);
  transform:translateY(-1px);
}
.dm-zap-party.unverified:hover{
  border-color:#5c6b7b;
  box-shadow:0 0 14px rgba(0,0,0,.14);
}
.dm-zap-party-av{
  width:30px;
  height:30px;
  border-radius:50%;
  flex-shrink:0;
  border:1.5px solid var(--border2);
  background:var(--surface3);
  overflow:hidden;
  display:flex;
  align-items:center;
  justify-content:center;
}
.dm-zap-party.verified .dm-zap-party-av{
  border-color:rgba(155,114,255,.7);
  background:rgba(155,114,255,.13);
}
.dm-zap-party-av.nip05-square{
  border-radius:6px;
  box-shadow:0 0 8px rgba(155,114,255,.55),0 0 16px rgba(155,114,255,.22);
  animation:nip05Pulse 2.8s ease-in-out infinite;
}
.dm-zap-party-av img{
  width:100%;
  height:100%;
  object-fit:cover;
  display:block;
}
.dm-zap-party-inner{
  display:flex;
  flex-direction:column;
  min-width:0;
}
.dm-zap-party-name{
  font-family:var(--font-display);
  font-size:.92rem;
  line-height:1.2;
  font-weight:800;
  color:var(--text);
  white-space:nowrap;
  overflow:hidden;
  text-overflow:ellipsis;
  max-width:220px;
}
.dm-zap-amount{
  display:block;
  align-self:stretch;
  padding:.05rem .2rem;
  border:none;
  background:none;
  color:#ffd59b;
  font-family:var(--font-display);
  font-size:1rem;
  font-weight:800;
  line-height:1.2;
  text-align:center;
  text-transform:none;
}
.dm-zap-meta{
  color:#ffd9ad;
  font-size:.84rem;
  line-height:1.45;
}
.dm-zap-activity .dm-msg-lock{
  color:#ffcf93;
  font-size:.72rem;
}
.dm-msg-body{
  color:var(--text);
  font-size:.8rem;
  line-height:1.52;
  white-space:pre-wrap;
  word-break:break-word;
}
.dm-media-wrap{
  display:grid;
  grid-template-columns:repeat(2,minmax(0,1fr));
  gap:.32rem;
  margin-top:.4rem;
  max-width:min(100%,360px);
}
.dm-media-wrap.single{
  grid-template-columns:1fr;
  max-width:min(100%,420px);
}
.dm-media-item{
  display:flex;
  align-items:center;
  justify-content:center;
  border:1px solid var(--border2);
  border-radius:10px;
  overflow:hidden;
  background:#0b1118;
  min-height:110px;
  max-height:210px;
  text-decoration:none;
}
.dm-media-item.single{
  min-height:140px;
  max-height:260px;
}
.dm-media-item img,.dm-media-item video{
  width:100%;
  height:100%;
  object-fit:contain;
  display:block;
  background:#000;
}
.dm-msg-lock{
  color:var(--muted);
  font-size:.67rem;
}
.dm-msg-reactions{
  display:flex;
  align-items:center;
  gap:.34rem;
  margin-top:.22rem;
}
.dm-msg-reactions .profile-comment-like-btn{
  font-size:.6rem;
  padding:.14rem .44rem;
}
.dm-msg-emoji-bar{
  display:flex;
  align-items:center;
  gap:.3rem;
  flex-wrap:wrap;
  margin-top:.24rem;
}
.dm-msg-emoji-bar .stream-emoji-chip{
  font-size:.6rem;
  padding:.14rem .42rem;
}
.dm-compose{
  border-top:1px solid var(--border);
  padding:.62rem .74rem;
  display:flex;
  flex-direction:column;
  gap:.46rem;
}
.dm-compose textarea{
  width:100%;
  min-height:74px;
  resize:vertical;
  background:#0b1118;
  border:1px solid var(--border2);
  border-radius:10px;
  color:var(--text);
  padding:.5rem .58rem;
  font-size:.8rem;
  font-family:'DM Sans',sans-serif;
  outline:none;
}
.dm-compose textarea:focus{
  border-color:var(--accent);
  box-shadow:0 0 0 2px rgba(232,70,10,.16);
}
.dm-compose-foot{
  display:flex;
  align-items:flex-start;
  justify-content:space-between;
  gap:.5rem;
  flex-wrap:wrap;
}
.dm-compose-action-row{
  margin:0;
  flex-shrink:0;
}
.dm-compose-action-row .btn,
.dm-compose-action-row button{
  padding:.34rem .68rem;
  font-size:.72rem;
}
.dm-markup-toolbar{
  margin:0;
  flex:1;
  justify-content:flex-end;
}
.dm-empty,.dm-login-card{
  margin:auto;
  max-width:560px;
  border:1px dashed var(--border2);
  border-radius:12px;
  padding:1rem;
  color:var(--text2);
  text-align:center;
}
.dm-login-card{grid-column:1/-1;}
.dm-empty strong,.dm-login-card strong{
  display:block;
  color:var(--text);
  margin-bottom:.35rem;
}

@media (max-width:1020px){
  .dm-wrap{
    grid-template-columns:300px minmax(0,1fr) 280px;
    padding:0;
    gap:0;
  }
  .dm-msg{max-width:86%;}
  .dm-msg.activity.dm-zap-activity{max-width:100%;}
  .dm-zap-party-name{max-width:160px;}
}

@media (max-width:820px){
  .dm-wrap{
    grid-template-columns:1fr;
    min-height:calc(100vh - 72px);
    height:auto;
  }
  .dm-wrap.dm-address-book-closed{
    grid-template-columns:1fr;
  }
  .dm-contact-select{max-width:100%;min-width:140px;}
  .dm-lists,.dm-side,.dm-main{min-height:unset;}
  .dm-main{min-height:62vh;}
  .dm-main-head{min-height:92px;}
  .dm-main-title-rich{
    --dm-peer-avatar-size:66px;
    min-height:82px;
  }
  .dm-peer-avatar{
    width:var(--dm-peer-avatar-size);
    height:var(--dm-peer-avatar-size);
    font-size:.9rem;
  }
  .dm-markup-toolbar{width:100%;justify-content:flex-start;}
}
/* ======== HOME ======== */
.hero-stream{position:relative;height:450px;overflow:hidden;cursor:pointer;background:linear-gradient(160deg,#0a1520 0%,#120800 60%,#080b0f 100%);}
.hero-bg{position:absolute;inset:0;background:radial-gradient(ellipse 60% 60% at 28% 50%,rgba(232,70,10,.11) 0%,transparent 70%),radial-gradient(ellipse 40% 80% at 80% 30%,rgba(247,183,49,.05) 0%,transparent 70%);}
.hero-grid-ov{position:absolute;inset:0;background-image:linear-gradient(rgba(255,77,0,.04) 1px,transparent 1px),linear-gradient(90deg,rgba(255,77,0,.04) 1px,transparent 1px);background-size:48px 48px;mask-image:radial-gradient(ellipse 70% 100% at 40% 50%,black 0%,transparent 80%);}
.stream-visual{width:100%;height:100%;display:flex;align-items:center;justify-content:center;font-size:4rem;}
.play-ov{position:absolute;inset:0;background:rgba(0,0,0,.25);display:flex;align-items:center;justify-content:center;}
.play-btn-big{width:58px;height:58px;border-radius:50%;background:rgba(255,255,255,.12);backdrop-filter:blur(8px);border:2px solid rgba(255,255,255,.25);display:flex;align-items:center;justify-content:center;font-size:1.3rem;transition:all .2s;}
.hero-player:hover .play-btn-big{background:rgba(232,70,10,.45);border-color:var(--accent);}
.hero-info{position:absolute;right:2.5%;top:50%;transform:translateY(-50%);width:39%;}
.hero-live-badge{display:inline-flex;align-items:center;gap:.4rem;background:var(--live);color:#fff;font-family:'DM Mono',monospace;font-size:.67rem;padding:.22rem .55rem;border-radius:4px;letter-spacing:.04em;margin-bottom:.65rem;}
.live-dot{width:6px;height:6px;border-radius:50%;background:#fff;animation:dotP 1.2s ease infinite;}
@keyframes dotP{0%,100%{opacity:1;transform:scale(1)}50%{opacity:.4;transform:scale(.7)}}
.hero-title{font-family:var(--font-display);font-weight:800;font-size:1.5rem;line-height:1.2;letter-spacing:-.02em;margin-bottom:.4rem;}
.hero-host{display:flex;align-items:center;gap:.5rem;font-size:.81rem;color:var(--text2);margin-bottom:.65rem;}
.hero-av{width:30px;height:30px;border-radius:50%;background:var(--surface3);border:1px solid var(--border2);display:flex;align-items:center;justify-content:center;font-size:.88rem;}
.hero-summary{font-size:.82rem;color:var(--text2);line-height:1.6;margin-bottom:.85rem;}
.hero-stats{display:flex;gap:1.1rem;margin-bottom:1rem;}
.h-stat .val{font-family:'DM Mono',monospace;font-size:.8rem;font-weight:500;color:var(--text);}
.h-stat .lbl{font-size:.67rem;color:var(--muted);}
.h-stat.zap .val{color:var(--zap);}
.hero-actions{display:flex;gap:.5rem;}

.cat-strip{padding:.6rem 1.25rem;border-bottom:1px solid var(--border);background:var(--surface);display:flex;gap:.4rem;overflow-x:auto;scrollbar-width:none;}
.cat-strip::-webkit-scrollbar{display:none;}
.cat-chip{flex-shrink:0;padding:.28rem .75rem;border-radius:20px;font-size:.76rem;font-weight:500;cursor:pointer;border:1px solid var(--border2);color:var(--text2);background:transparent;font-family:'DM Sans',sans-serif;transition:all .15s;white-space:nowrap;}
.cat-chip:hover,.cat-chip.active{background:var(--accent);border-color:var(--accent);color:#fff;}

.stream-main{padding:1rem 1.4rem;}
.live-now-hd{display:flex;align-items:center;gap:.65rem;margin-bottom:1rem;flex-wrap:wrap;}
.live-now-hd h2{font-family:var(--font-display);font-weight:700;font-size:1rem;white-space:nowrap;}
.live-count-pill{font-family:'DM Mono',monospace;font-size:.62rem;color:var(--live);background:rgba(255,59,92,.1);border:1px solid rgba(255,59,92,.22);border-radius:4px;padding:.14rem .46rem;white-space:nowrap;}
.live-grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(220px,1fr));gap:.85rem;}
.live-grid-sentinel{height:1px;grid-column:1/-1;}
.live-grid-loading{grid-column:1/-1;display:flex;align-items:center;justify-content:center;gap:.55rem;padding:1.4rem;color:var(--muted);font-size:.8rem;}
.live-grid-end{grid-column:1/-1;text-align:center;padding:1.2rem;font-family:'DM Mono',monospace;font-size:.65rem;color:var(--muted);letter-spacing:.05em;}
.stream-card-dim{opacity:.45;}
/* sec-hd kept for video page */
.sec-hd{display:flex;align-items:center;justify-content:space-between;margin-bottom:.7rem;}
.sec-hd h2{font-family:var(--font-display);font-weight:700;font-size:.9rem;}
.see-all{font-size:.75rem;color:var(--muted);cursor:pointer;}.see-all:hover{color:var(--text);}
.grid-4{display:grid;grid-template-columns:repeat(4,1fr);gap:.75rem;margin-bottom:1.5rem;}
.stream-card{cursor:pointer;border-radius:10px;transition:transform .15s;}
.stream-card:hover{transform:translateY(-2px);}
.stream-card:hover .ct-inner{border-color:var(--accent);}
.ct{position:relative;aspect-ratio:16/9;border-radius:8px;overflow:hidden;}
.ct-inner{width:100%;height:100%;border:1px solid var(--border);border-radius:8px;overflow:hidden;transition:border-color .15s;}
.tc{width:100%;height:100%;display:flex;align-items:center;justify-content:center;font-size:2rem;}
.t1{background:linear-gradient(135deg,#12001a,#2d0040);}
.t2{background:linear-gradient(135deg,#001520,#003055);}
.t3{background:linear-gradient(135deg,#0a1200,#1e3000);}
.t4{background:linear-gradient(135deg,#1a0800,#3d1200);}
.t5{background:linear-gradient(135deg,#00101a,#002040);}
.t6{background:linear-gradient(135deg,#150020,#350055);}
.t7{background:linear-gradient(135deg,#001a10,#003520);}
.t8{background:linear-gradient(135deg,#1a0000,#3d0000);}
.cb-live{position:absolute;top:6px;left:6px;background:var(--live);color:#fff;font-family:'DM Mono',monospace;font-size:.6rem;padding:.13rem .42rem;border-radius:3px;display:flex;align-items:center;gap:.25rem;}
.cb-viewers{position:absolute;bottom:6px;left:6px;background:rgba(0,0,0,.75);color:var(--text);font-family:'DM Mono',monospace;font-size:.6rem;padding:.13rem .42rem;border-radius:3px;}
.ci{padding:.52rem .08rem .08rem;}
.ci-row{display:flex;gap:.48rem;}
.ci-av{width:34px;height:34px;border-radius:50%;background:var(--surface2);flex-shrink:0;display:flex;align-items:center;justify-content:center;font-size:1rem;border:1px solid var(--border);}
.ci-av.nip05-square{border-radius:5px;border:1.5px solid rgba(155,114,255,.7);background:rgba(155,114,255,.13);box-shadow:0 0 8px rgba(155,114,255,.55),0 0 18px rgba(155,114,255,.25),inset 0 0 6px rgba(155,114,255,.1);animation:nip05Pulse 2.8s ease-in-out infinite;}
.ci-title{font-size:.79rem;font-weight:600;line-height:1.3;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden;}
.ci-host{font-size:.71rem;color:var(--text2);margin-top:.13rem;}
.ci-tags{display:flex;gap:.3rem;margin-top:.22rem;flex-wrap:wrap;}
.tag{font-size:.62rem;color:var(--text2);background:var(--surface2);padding:.08rem .36rem;border-radius:3px;}
.tag-platform{color:var(--purple);background:rgba(155,114,255,.12);border:1px solid rgba(155,114,255,.25);}
.ci-hosted-badge:not(:empty){display:inline-block;font-size:.57rem;color:var(--purple);background:rgba(155,114,255,.12);border:1px solid rgba(155,114,255,.28);padding:.05rem .3rem;border-radius:3px;margin-left:.22rem;vertical-align:middle;}
/* Logo images */
.nav-logo-img{width:52px;height:52px;object-fit:contain;border-radius:8px;flex-shrink:0;margin-right:.05rem;}
.lm-logo-img{width:38px;height:38px;object-fit:contain;border-radius:6px;}
.footer-logo-img{width:20px;height:20px;object-fit:contain;border-radius:3px;vertical-align:middle;}
/* Hosted-by compact pill - inline in .sib-host-row */
.sib-hosted-by{margin-left:.55rem;display:flex;align-items:center;}
.hosted-by-box{
  display:inline-flex;align-items:center;gap:.46rem;
  padding:.34rem .58rem .34rem .36rem;
  background:linear-gradient(135deg,rgba(155,114,255,.13),rgba(232,70,10,.06));
  border:1px solid rgba(155,114,255,.38);
  border-radius:20px;
  animation:hostedByPulse 3s ease-in-out infinite;
  position:relative;overflow:hidden;
  cursor:pointer;transition:border-color .18s,box-shadow .18s;
}
.hosted-by-box:hover{border-color:rgba(155,114,255,.65);box-shadow:0 0 16px rgba(155,114,255,.28);}
.hosted-by-box::before{
  content:'';position:absolute;inset:0;pointer-events:none;
  background:linear-gradient(90deg,transparent,rgba(155,114,255,.06),transparent);
  animation:hostedBySweep 2.8s linear infinite;
}
@keyframes hostedByPulse{
  0%,100%{box-shadow:0 0 7px rgba(155,114,255,.14);}
  50%{box-shadow:0 0 16px rgba(155,114,255,.28);}
}
@keyframes hostedBySweep{0%{transform:translateX(-100%);}100%{transform:translateX(200%);}}
.hosted-by-av{
  width:24px;height:24px;border-radius:50%;flex-shrink:0;
  background:var(--surface3);border:1.5px solid rgba(155,114,255,.4);
  overflow:hidden;display:flex;align-items:center;justify-content:center;z-index:1;
}
.hosted-by-av img{width:100%;height:100%;object-fit:cover;display:block;}
.hosted-by-av-fallback{font-family:var(--font-display);font-weight:800;font-size:.6rem;color:var(--purple);}
.hosted-by-inner{display:flex;flex-direction:column;z-index:1;min-width:0;}
.hosted-by-label{font-family:'DM Mono',monospace;font-size:.52rem;text-transform:uppercase;letter-spacing:.08em;color:var(--purple);opacity:.75;line-height:1;}
.hosted-by-name{font-family:var(--font-display);font-weight:700;font-size:.76rem;color:var(--text);white-space:nowrap;line-height:1.25;}
@keyframes fadeUp{from{opacity:0;transform:translateY(12px)}to{opacity:1;transform:translateY(0)}}
.stream-card{animation:fadeUp .3s ease both;}
.stream-card:nth-child(1){animation-delay:.04s}.stream-card:nth-child(2){animation-delay:.08s}.stream-card:nth-child(3){animation-delay:.12s}.stream-card:nth-child(4){animation-delay:.16s}

/* ======== VIDEO PAGE ======== */
/* min-height (not height) so the page scrolls naturally on ultrawide */
.video-layout{display:grid;grid-template-columns:1fr var(--sidebar-w);min-height:calc(100vh - 68px);max-width:1920px;margin:0 auto;width:100%;align-items:start;}
.video-col{display:flex;flex-direction:column;min-width:0;}
.player-wrap{position:relative;background:#000;width:100%;aspect-ratio:16/9;flex-shrink:0;}
.player-bg{width:100%;height:100%;display:flex;align-items:center;justify-content:center;font-size:5rem;background:linear-gradient(135deg,#0a1a28,#180600,#080b12);}
.player-bg.player-bg-portrait-source{
  padding:.4rem 0;
}
.player-bg.player-bg-portrait-source video{
  width:auto !important;
  height:auto !important;
  max-height:calc(100% - .8rem);
  max-width:min(46vw,430px);
  object-fit:contain !important;
  border-radius:10px;
  box-shadow:0 0 0 1px rgba(255,255,255,.08);
}
.player-ui{position:absolute;inset:0;display:flex;flex-direction:column;justify-content:flex-end;background:linear-gradient(to top,rgba(0,0,0,.9) 0%,transparent 40%);padding:.8rem .95rem;}
.pctrl-row{display:flex;align-items:center;gap:.6rem;}
.pc{background:none;border:none;color:#fff;font-size:.95rem;cursor:pointer;padding:.2rem;opacity:.8;transition:opacity .15s;line-height:1;}
.pc:hover{opacity:1;}
.pvol{flex:0 0 68px;height:3px;background:rgba(255,255,255,.2);border-radius:2px;cursor:pointer;position:relative;}
.pvol-f{position:absolute;left:0;top:0;bottom:0;width:65%;background:#fff;border-radius:2px;}
.spacer{flex:1;}
.p-live{background:var(--live);color:#fff;font-family:'DM Mono',monospace;font-size:.62rem;padding:.17rem .45rem;border-radius:4px;display:flex;align-items:center;gap:.28rem;}
.end-stream-btn{background:rgba(255,59,92,.15);border:1px solid rgba(255,59,92,.4);color:var(--live);font-size:.72rem;font-weight:600;padding:.28rem .65rem;border-radius:6px;cursor:pointer;font-family:'DM Sans',sans-serif;transition:all .15s;align-items:center;gap:.3rem;display:none;}
.end-stream-btn.visible{display:flex;}
.end-stream-btn:hover{background:rgba(255,59,92,.3);}

/* Stream info */
.sib{padding:.85rem .95rem;border-bottom:1px solid var(--border);}

/* Top row: title left, action buttons right - directly below the video */
.sib-top-row{display:flex;align-items:flex-start;justify-content:space-between;gap:.75rem;margin-bottom:.65rem;}
.sib-title-col{flex:1;min-width:0;}

/* Title row with edit pencil */
.editable-row{display:flex;align-items:center;gap:.5rem;}
.sib-title{font-family:var(--font-display);font-weight:800;font-size:1.12rem;letter-spacing:-.02em;}
.edit-pencil{background:none;border:none;color:var(--muted);cursor:pointer;font-size:.82rem;padding:.18rem .3rem;border-radius:5px;transition:all .15s;opacity:.6;line-height:1;}
.edit-pencil:hover{background:var(--surface2);color:var(--text);opacity:1;}
.owner-only{display:none;}
.owner-only.visible{display:flex;}

/* Host row */
.sib-host-row{display:flex;align-items:center;gap:.8rem;flex-wrap:wrap;}
.sib-av{width:52px;height:52px;border-radius:50%;background:var(--surface2);display:flex;align-items:center;justify-content:center;font-size:1.3rem;border:2px solid var(--border2);flex-shrink:0;cursor:pointer;transition:border-color .15s;}
.sib-av:hover{border-color:var(--accent);}
.sib-host-info{flex:1;min-width:0;}
.sib-name{font-weight:700;font-size:.92rem;font-family:var(--font-display);display:flex;align-items:center;gap:.3rem;}
.sib-identity{font-family:'DM Mono',monospace;font-size:.67rem;color:var(--muted);margin-top:.06rem;}
.nip05-text{color:var(--nip05);}

/* Action buttons row (Follow, Zap, Share, Report) - flush right of title */
.sib-actions-row{display:flex;align-items:center;gap:.45rem;flex-wrap:wrap;flex-shrink:0;}
.action-btn{background:var(--surface2);border:1px solid var(--border);border-radius:7px;padding:.33rem .7rem;cursor:pointer;font-size:.77rem;color:var(--text2);font-family:'DM Sans',sans-serif;display:flex;align-items:center;gap:.27rem;transition:all .15s;font-weight:500;}
.action-btn:hover{border-color:var(--border2);color:var(--text);}
.action-btn.like-btn:hover,.action-btn.liked{border-color:var(--live);color:var(--live);background:rgba(255,59,92,.08);}
.action-btn.share-btn:hover{border-color:var(--green);color:var(--green);}
.action-btn.share-btn.boosted{border-color:rgba(155,114,255,.62);color:var(--purple);background:rgba(155,114,255,.1);}
.action-btn.share-btn.boosted:hover{border-color:var(--purple);color:var(--purple);background:rgba(155,114,255,.16);}
.action-btn.report-btn:hover{border-color:rgba(255,100,50,.5);color:rgba(255,100,50,.8);}
.sib-stream-link-row{display:flex;align-items:center;gap:.45rem;margin-top:.48rem;padding:.3rem .48rem;border:1px solid var(--border2);border-radius:8px;background:var(--surface2);}
.sib-stream-link-row .lbl{font-family:'DM Mono',monospace;font-size:.61rem;color:var(--muted);text-transform:uppercase;letter-spacing:.08em;flex-shrink:0;}
.sib-stream-link{font-family:'DM Mono',monospace;font-size:.68rem;color:var(--text2);text-decoration:none;word-break:break-all;}
.sib-stream-link:hover{color:var(--accent);text-decoration:underline;}
.stream-reactions-row{display:flex;align-items:center;gap:.42rem;margin-top:.7rem;padding-top:.58rem;border-top:1px solid var(--border);flex-wrap:wrap;}
.stream-emoji-list{display:flex;align-items:center;gap:.34rem;flex-wrap:wrap;}
.stream-emoji-add,.stream-emoji-chip{border:1px solid var(--border2);background:var(--surface2);color:var(--text2);border-radius:999px;font-family:'DM Mono',monospace;font-size:.68rem;display:inline-flex;align-items:center;gap:.24rem;cursor:pointer;transition:all .14s;}
.stream-emoji-add{padding:.2rem .45rem;font-weight:700;}
.stream-emoji-chip{padding:.2rem .5rem;}
.stream-emoji-add:hover,.stream-emoji-chip:hover{border-color:var(--accent);color:var(--text);}
.stream-emoji-chip.active{border-color:var(--green);color:var(--green);background:rgba(0,212,138,.1);}
.stream-emoji-chip img{width:14px;height:14px;object-fit:contain;display:block;}
.stream-emoji-count{font-size:.64rem;color:var(--text);}
.stream-like-counter{border:1px solid var(--border2);background:var(--surface2);color:var(--text2);border-radius:999px;font-family:'DM Mono',monospace;font-size:.68rem;padding:.2rem .55rem;}
.stream-zap-list{display:flex;align-items:center;gap:.34rem;flex-wrap:wrap;min-height:30px;}
.stream-zap-pill{
  display:inline-flex;align-items:center;gap:.46rem;
  padding:.3rem .58rem .3rem .36rem;
  background:linear-gradient(135deg,rgba(247,147,26,.2),rgba(247,183,49,.08));
  border:1px solid rgba(247,147,26,.55);
  border-radius:20px;
  box-shadow:0 0 10px rgba(247,147,26,.18);
  cursor:pointer;
  transition:border-color .16s,box-shadow .16s;
}
.stream-zap-pill:hover{border-color:rgba(247,147,26,.9);box-shadow:0 0 16px rgba(247,147,26,.28);}
.stream-zap-pill .hosted-by-av{border-color:rgba(247,147,26,.72);background:rgba(247,147,26,.18);}
.stream-zap-pill .hosted-by-av-fallback{color:var(--zap);}
.stream-zap-pill .hosted-by-label{color:var(--zap);}
.stream-zap-pill .hosted-by-name{color:#ffd9ad;font-family:'DM Mono',monospace;font-size:.67rem;}

/* Stats row - followers now included here */
.sib-stats-row{display:flex;gap:1rem;margin-top:.65rem;padding-top:.6rem;border-top:1px solid var(--border);align-items:center;flex-wrap:wrap;}
.ss{font-size:.78rem;display:flex;align-items:center;gap:.28rem;}
.ss .n{font-weight:600;font-family:'DM Mono',monospace;}
.ss .l{color:var(--text2);font-size:.72rem;}
.ss.zap .n{color:var(--zap);}
.ss.lv .n{color:var(--live);}
.ss.fol .n{color:var(--purple);}

/* Summary with edit pencil */
.editable-block{position:relative;}
.editable-block:hover .block-pencil{opacity:.6;}
.block-pencil{background:none;border:none;color:var(--muted);cursor:pointer;font-size:.78rem;padding:.15rem .28rem;border-radius:5px;transition:all .15s;opacity:0;line-height:1;position:absolute;top:0;right:0;}
.block-pencil:hover{background:var(--surface2);color:var(--text);opacity:1!important;}
.sib-summary{font-size:.81rem;color:var(--text2);line-height:1.6;padding-right:1.5rem;}

/* Recommended */
.reco{padding:.8rem .95rem 1rem;}
.reco-title{font-family:var(--font-display);font-weight:700;font-size:.83rem;margin-bottom:.65rem;color:var(--text2);}
.reco-grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(150px,1fr));gap:.72rem;}
.reco-card{min-width:0;}
.reco-card .ci{padding:.48rem .04rem .08rem;}
.reco-card .ci-row{align-items:flex-start;}
.reco-card .ci-av{width:30px;height:30px;font-size:.9rem;}
.reco-card .ci-title{font-size:.75rem;}
.reco-card .ci-host{font-size:.67rem;line-height:1.35;}
.reco-meta{min-width:0;}
.reco-badge{top:7px;left:7px;}
.reco-empty{grid-column:1/-1;font-size:.74rem;color:var(--muted);padding:.25rem .12rem;}

/* ======== MINI PLAYER ======== */
.mini-player{position:fixed;bottom:1.2rem;right:1.2rem;width:280px;aspect-ratio:16/9;background:#000;border-radius:10px;overflow:hidden;box-shadow:0 8px 32px rgba(0,0,0,.8),0 0 0 1px rgba(255,255,255,.08);z-index:300;cursor:pointer;display:none;transition:transform .2s;}
.mini-player:hover{transform:scale(1.02);}
.mini-player.visible{display:block;animation:popIn .25s cubic-bezier(.4,0,.2,1);}
@keyframes popIn{from{opacity:0;transform:scale(.85) translateY(20px)}to{opacity:1;transform:scale(1) translateY(0)}}
.mini-inner{width:100%;height:100%;display:flex;align-items:center;justify-content:center;font-size:2.8rem;background:linear-gradient(135deg,#0a1a28,#180600);}
.mini-bar{position:absolute;bottom:0;left:0;right:0;background:linear-gradient(to top,rgba(0,0,0,.9),transparent);padding:.45rem .6rem;display:flex;align-items:center;justify-content:space-between;}
.mini-title{font-size:.68rem;font-weight:600;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;max-width:160px;}
.mini-live{background:var(--live);color:#fff;font-family:'DM Mono',monospace;font-size:.58rem;padding:.1rem .35rem;border-radius:3px;display:flex;align-items:center;gap:.2rem;}
.mini-close{background:rgba(0,0,0,.5);border:none;color:#fff;cursor:pointer;font-size:.75rem;padding:.2rem .35rem;border-radius:4px;line-height:1;}

/* ======== SIDEBAR / CHAT ======== */
.stream-sidebar{border-left:1px solid var(--border);border-right:1px solid var(--border);display:flex;flex-direction:column;height:calc(100vh - 68px);position:sticky;top:68px;overflow:hidden;align-self:start;}
.stabs{display:flex;border-bottom:1px solid var(--border);flex-shrink:0;}
.stab{flex:1;padding:.62rem;text-align:center;font-size:.76rem;font-weight:600;cursor:pointer;color:var(--muted);border-bottom:2px solid transparent;transition:all .15s;}
.stab.active{color:var(--text);border-bottom-color:var(--accent);}
.chat-scroll{flex:1;overflow-y:auto;padding:.65rem;display:flex;flex-direction:column;justify-content:flex-end;gap:.4rem;scrollbar-width:thin;scrollbar-color:var(--border) transparent;}
::-webkit-scrollbar{width:4px;}::-webkit-scrollbar-thumb{background:var(--border);border-radius:2px;}

.cmsg{display:flex;gap:.4rem;align-items:flex-start;position:relative;}
.cmsg:hover .chat-msg-actions{opacity:1;pointer-events:all;}
.c-av{width:28px;height:28px;border-radius:50%;background:var(--surface2);flex-shrink:0;display:flex;align-items:center;justify-content:center;font-size:.78rem;border:1px solid var(--border);cursor:pointer;transition:border-color .15s;}
.c-av:hover{border-color:var(--accent);}
.c-av.nip05-square{border-radius:4px;border:1.5px solid rgba(155,114,255,.7);background:rgba(155,114,255,.13);box-shadow:0 0 6px rgba(155,114,255,.55),0 0 14px rgba(155,114,255,.22);animation:nip05Pulse 2.8s ease-in-out infinite;}
.c-body{flex:1;}
.c-name-row{display:flex;align-items:center;gap:.28rem;flex-wrap:wrap;}
.c-name{font-family:var(--font-display);font-size:.74rem;font-weight:700;letter-spacing:.01em;cursor:pointer;}
.c-name:hover{text-decoration:underline;}
.c-time{font-family:'DM Mono',monospace;font-size:.6rem;color:var(--muted);}
.c-name.co{color:var(--accent);}
.c-name.cp{color:var(--purple);}
.c-name.cg{color:var(--green);}
.c-name.cz{color:var(--zap);}
.c-nip05{color:var(--nip05);font-size:.64rem;font-weight:700;opacity:.75;}
.c-text{font-size:.77rem;line-height:1.45;color:var(--text);margin-top:.07rem;}
.chat-media-wrap{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:.28rem;margin-top:.38rem;max-width:260px;}
.chat-media-item{display:block;border:1px solid var(--border2);border-radius:8px;overflow:hidden;background:#0b1118;aspect-ratio:1/1;}
.chat-media-item.single{grid-column:1/-1;aspect-ratio:16/9;max-height:180px;}
.chat-media-item img,.chat-media-item video{width:100%;height:100%;display:block;background:#000;}
.chat-media-item img{object-fit:cover;}
.chat-media-item video{object-fit:contain;}
.spotify-preview-wrap{display:flex;flex-direction:column;gap:.36rem;margin-top:.38rem;max-width:min(100%,420px);}
.chat-spotify-wrap{max-width:260px;}
.dm-spotify-wrap{max-width:min(100%,420px);}
.spotify-preview-card{border:1px solid var(--border2);border-radius:10px;overflow:hidden;background:linear-gradient(135deg,#0f1d19,#0a131f);}
.spotify-preview-head{display:flex;align-items:center;justify-content:space-between;gap:.45rem;padding:.36rem .5rem;border-bottom:1px solid rgba(255,255,255,.06);}
.spotify-preview-label{font-family:'DM Mono',monospace;font-size:.6rem;letter-spacing:.04em;text-transform:uppercase;color:#7ee2a8;}
.spotify-preview-open{font-family:'DM Mono',monospace;font-size:.62rem;color:var(--text2);text-decoration:none;}
.spotify-preview-open:hover{color:var(--accent);text-decoration:underline;}
.spotify-preview-frame{display:block;width:100%;border:0;background:#000;}
.spotify-preview-card.compact .spotify-preview-frame{height:152px;}
.spotify-preview-card.expanded .spotify-preview-frame{height:352px;}
.chat-msg-actions{position:absolute;right:0;top:-4px;display:flex;gap:.18rem;background:var(--surface);border:1px solid var(--border2);border-radius:8px;padding:.2rem .28rem;opacity:0;pointer-events:none;transition:opacity .15s;box-shadow:0 4px 12px rgba(0,0,0,.4);z-index:10;}
.cma-btn{background:none;border:none;cursor:pointer;font-size:.73rem;padding:.1rem .18rem;border-radius:4px;color:var(--muted);transition:all .12s;line-height:1;}
.cma-btn:hover{background:var(--surface2);color:var(--text);}
.cma-btn.zap-cma:hover{color:var(--zap);}
.cma-btn.like-cma:hover{color:var(--live);}
.cma-btn.like-cma.active{color:var(--live);background:rgba(255,59,92,.1);}
.chat-like-count{font-family:'DM Mono',monospace;font-size:.62rem;}
.zap-ev{background:linear-gradient(135deg,rgba(247,183,49,.14),rgba(247,183,49,.05));border:1px solid rgba(247,183,49,.28);border-radius:8px;padding:.48rem .68rem;box-shadow:0 0 0 1px rgba(247,147,26,.08) inset,0 8px 20px rgba(0,0,0,.2);}
.zap-ev .c-av{border-color:rgba(247,147,26,.55);background:rgba(247,147,26,.14);}
.zap-ev .c-name{color:#ffd9ad;}
.zap-ev .c-text{color:var(--zap);}
.chat-zap-amount{display:inline-flex;align-items:center;gap:.2rem;font-family:'DM Mono',monospace;font-size:.62rem;color:#ffd9ad;background:linear-gradient(135deg,rgba(247,147,26,.35),rgba(247,147,26,.12));border:1px solid rgba(247,147,26,.45);border-radius:999px;padding:.08rem .45rem;line-height:1.2;white-space:nowrap;}

/* Emoji picker */
.emoji-picker{position:absolute;bottom:calc(100% + 8px);left:0;background:var(--surface);border:1px solid var(--border2);border-radius:12px;padding:.55rem;box-shadow:0 12px 40px rgba(0,0,0,.6);display:none;z-index:200;width:224px;}
.emoji-picker.open{display:block;animation:fadeUp .15s ease;}
.ep-grid{display:grid;grid-template-columns:repeat(7,1fr);gap:.15rem;}
.ep-emoji{font-size:1.1rem;text-align:center;padding:.2rem;border-radius:5px;cursor:pointer;transition:background .1s;line-height:1.4;}
.ep-emoji:hover{background:var(--surface2);}

.viewers-panel{padding:.65rem;display:none;flex-direction:column;gap:.38rem;overflow-y:auto;flex:1;}
.viewers-panel.on{display:flex;}
.vr{display:flex;align-items:center;gap:.52rem;padding:.35rem .42rem;border-radius:7px;cursor:pointer;}
.vr:hover{background:var(--surface2);}
.v-av{width:32px;height:32px;border-radius:50%;background:var(--surface2);display:flex;align-items:center;justify-content:center;font-size:.9rem;flex-shrink:0;}
.v-name{font-size:.79rem;font-weight:500;display:flex;align-items:center;gap:.28rem;}
.v-npub{font-family:'DM Mono',monospace;font-size:.62rem;color:var(--muted);}
.v-badge{margin-left:auto;font-size:.62rem;padding:.12rem .36rem;border-radius:3px;font-family:'DM Mono',monospace;}
.vb-z{background:var(--zap-dim);color:var(--zap);}
.vb-l{background:rgba(255,59,92,.12);color:var(--live);}

/* Chat bottom */
.chat-bottom{border-top:1px solid var(--border);flex-shrink:0;}
.chat-iw{padding:.55rem .65rem .32rem;}
.chat-inp{width:100%;background:var(--surface2);border:1px solid var(--border);border-radius:8px;padding:.48rem .72rem;color:var(--text);font-family:'DM Sans',sans-serif;font-size:.78rem;outline:none;transition:border-color .15s;resize:none;display:block;line-height:1.4;}
.chat-inp:focus{border-color:var(--accent);}
.chat-inp::placeholder{color:var(--muted);}
.chat-acts{display:flex;align-items:flex-start;gap:.38rem;padding:.28rem .65rem .55rem;position:relative;}

.nostr-markup-toolbar{display:flex;flex-wrap:wrap;gap:.28rem;margin:.38rem 0 .46rem;}
.nostr-markup-toolbar button{background:var(--surface2);border:1px solid var(--border);color:var(--text2);border-radius:6px;padding:.2rem .44rem;font-size:.62rem;font-family:'DM Mono',monospace;cursor:pointer;line-height:1.2;transition:border-color .15s,color .15s,background .15s;}
.nostr-markup-toolbar button:hover{border-color:var(--accent);color:var(--text);background:var(--surface3);}
.nostr-markup-toolbar-compose{margin:0 .1rem 0 0;max-width:100%;}
.nostr-markup-toolbar-chat{margin:0;flex:1;align-items:flex-start;}
.nostr-markup-toolbar-chat button{padding:.18rem .38rem;font-size:.58rem;}
.ca-btn{background:var(--surface2);border:1px solid var(--border);border-radius:7px;padding:.3rem .62rem;cursor:pointer;font-size:.75rem;color:var(--text2);font-family:'DM Sans',sans-serif;display:flex;align-items:center;gap:.25rem;transition:all .15s;font-weight:500;}
.ca-btn:hover{border-color:var(--border2);color:var(--text);}
.ca-btn.zap-ca:hover{border-color:var(--zap);color:var(--zap);}
.chat-send-btn{padding:.35rem .82rem;background:var(--accent);border:none;border-radius:7px;cursor:pointer;color:#fff;font-size:.78rem;font-weight:600;font-family:'DM Sans',sans-serif;transition:all .15s;margin-left:auto;}
.chat-send-btn:hover{background:#ff5520;}

@media (max-width:980px){
  .player-bg.player-bg-portrait-source video{
    max-width:min(72vw,340px);
    max-height:calc(100% - .42rem);
    border-radius:8px;
  }
}

/* ======== PROFILE PAGE ======== */
.profile-hero{height:170px;background:linear-gradient(135deg,#0d1e30,#1a0a00,#100015);position:relative;overflow:hidden;border-bottom:1px solid var(--border);z-index:0;}
.profile-banner-img{position:absolute;inset:0;width:100%;height:100%;object-fit:cover;opacity:.92;display:none;}
.profile-content{position:relative;z-index:2;padding:0 1.5rem 1.5rem;}
.profile-top{display:grid;grid-template-columns:minmax(0,1.7fr) minmax(290px,.95fr);gap:1rem;margin:-34px 0 .95rem;align-items:stretch;}
.profile-left-stack{display:flex;flex-direction:column;gap:.85rem;min-width:0;}
.profile-head-row{display:flex;align-items:flex-start;gap:.78rem;min-width:0;}
.profile-av-wrap{margin-top:-14px;display:inline-flex;position:relative;z-index:4;flex-shrink:0;}
.profile-av-big{width:112px;height:112px;border-radius:50%;background:linear-gradient(135deg,var(--accent),var(--zap));display:flex;align-items:center;justify-content:center;font-size:2.7rem;border:3px solid var(--bg);transition:box-shadow .18s,border-color .18s;}
.profile-identity-box,.profile-bio-box,.profile-action-box,.profile-inline-meta{
  background:rgba(20,26,33,.78);
  border:1px solid rgba(255,255,255,.09);
  backdrop-filter:blur(8px);
  border-radius:12px;
}
.profile-identity-box{padding:.72rem .82rem;min-width:0;max-width:720px;}
.profile-identity-box.nip05-verified{
  background:rgba(74,50,108,.68);
  border-color:rgba(155,114,255,.62);
  box-shadow:0 0 0 1px rgba(155,114,255,.28),0 12px 26px rgba(90,54,144,.24);
}
.profile-av-big.nip05-verified{
  border-radius:8px !important;
  box-shadow:0 0 0 2px rgba(155,114,255,.45),0 0 16px rgba(155,114,255,.35);
  border-color:rgba(155,114,255,.72);
}
.profile-nip05.nip05-invalid{color:var(--muted);}
.nip05-badge.nip05-invalid{color:#ff5a6b;opacity:1;}
.profile-name-row{display:flex;align-items:center;gap:.45rem;min-width:0;}
.profile-name{font-family:var(--font-display);font-weight:800;font-size:1.3rem;line-height:1.2;}
.profile-nip05{font-family:'DM Mono',monospace;font-size:.74rem;color:var(--nip05);display:flex;align-items:center;gap:.3rem;margin-top:.18rem;}
.profile-npub{font-family:'DM Mono',monospace;font-size:.7rem;color:var(--muted);margin-top:.2rem;word-break:break-all;}
.profile-kind30315-row{display:none;align-items:center;gap:.38rem;margin-top:.28rem;font-family:'DM Mono',monospace;font-size:.68rem;color:var(--text);word-break:break-word;}
.profile-kind30315-edit{display:flex;align-items:center;gap:.38rem;margin-top:.45rem;}
.profile-kind30315-input{flex:1;min-width:120px;background:#0d131a;border:1px solid var(--border2);border-radius:8px;padding:.32rem .5rem;color:var(--text);font-size:.71rem;font-family:'DM Sans',sans-serif;outline:none;}
.profile-kind30315-input:focus{border-color:var(--accent);box-shadow:0 0 0 2px rgba(232,70,10,.14);}
.profile-kind30315-save{background:var(--surface2);border:1px solid var(--border2);border-radius:8px;color:var(--text2);font-size:.7rem;font-weight:600;padding:.32rem .56rem;cursor:pointer;font-family:'DM Sans',sans-serif;}
.profile-kind30315-save:hover{border-color:var(--accent);color:var(--accent);}
.profile-bio-box{padding:.72rem .82rem;flex:1;display:flex;flex-direction:column;}
.profile-bio{font-size:.85rem;color:var(--text2);line-height:1.6;margin:0;max-width:none;white-space:normal;word-break:break-word;}
.profile-bio.clamped{max-height:8.2em;overflow:hidden;}
.profile-show-more{margin-top:.46rem;background:transparent;border:1px solid var(--border2);border-radius:8px;color:var(--text2);font-size:.7rem;padding:.25rem .55rem;cursor:pointer;align-self:flex-start;}
.profile-show-more:hover{border-color:var(--accent);color:var(--accent);}
.profile-bio-links{display:flex;flex-wrap:wrap;gap:.42rem;margin-top:.58rem;}
.profile-bio-links-main{display:none;margin-top:.58rem;}
.profile-bio-links-bottom{display:none;margin-top:auto;padding-top:.62rem;}
.profile-bio-meta{display:flex;align-items:center;gap:.36rem;padding:.23rem .48rem;border:1px solid var(--border);border-radius:999px;background:var(--surface2);font-size:.7rem;color:var(--text2);}
.profile-bio-meta .lbl{font-family:'DM Mono',monospace;font-size:.62rem;color:var(--muted);}
.profile-bio-meta .val{font-family:'DM Mono',monospace;font-size:.66rem;color:var(--text);word-break:break-all;}
.profile-bio-meta a{color:var(--accent);text-decoration:none;word-break:break-all;}
.profile-since{display:none;}
.profile-right-stack{display:flex;flex-direction:column;gap:.85rem;align-items:stretch;}
.profile-action-box{padding:.56rem .64rem;align-self:flex-end;width:max-content;max-width:100%;position:relative;z-index:10;}
.profile-actions-row{display:flex;align-items:center;justify-content:flex-end;gap:.38rem;flex-wrap:wrap;}
.profile-inline-meta{display:flex;flex-direction:column;gap:.5rem;max-width:none;padding:.64rem .68rem;flex:1;margin-top:3rem;}
.profile-inline-stats{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:.38rem;margin-top:.2rem;}
.pis{padding:.42rem .45rem;border:1px solid var(--border);border-radius:8px;background:var(--surface2);}
.pis .iv{font-family:'DM Mono',monospace;font-weight:600;font-size:.86rem;color:var(--text);}
.pis .il{font-size:.67rem;color:var(--muted);margin-top:.14rem;}
.profile-main-grid{display:grid;grid-template-columns:minmax(0,1.65fr) minmax(290px,.95fr);gap:1rem;margin-top:1rem;align-items:start;}
.profile-col,.profile-side{display:flex;flex-direction:column;gap:1rem;}
.profile-card{background:var(--surface);border:1px solid var(--border);border-radius:12px;padding:.9rem;}
.profile-sec-head{display:flex;align-items:center;justify-content:space-between;margin-bottom:.65rem;}
.profile-sec-head h3{font-family:var(--font-display);font-size:.92rem;font-weight:700;}
.profile-sec-head span{font-family:'DM Mono',monospace;font-size:.66rem;color:var(--muted);}
.profile-live-player{aspect-ratio:16/9;border:1px solid var(--border2);background:#000;border-radius:10px;overflow:hidden;display:flex;align-items:center;justify-content:center;font-size:.78rem;color:var(--text2);}
.profile-live-foot{display:flex;justify-content:flex-end;margin-top:.55rem;}
.profile-feed-list{display:flex;flex-direction:column;gap:.65rem;}
.profile-feed-item{padding:.72rem .75rem;border-radius:10px;border:1px solid var(--border);background:var(--surface2);}
.profile-feed-head{display:flex;align-items:flex-start;justify-content:space-between;gap:.6rem;margin-bottom:.44rem;}
.profile-feed-author{display:flex;align-items:flex-start;gap:.5rem;min-width:0;}
.profile-feed-av{width:40px;height:40px;border-radius:50%;background:var(--surface3);border:1px solid var(--border2);display:flex;align-items:center;justify-content:center;flex-shrink:0;font-size:.94rem;overflow:hidden;}
.profile-feed-meta{min-width:0;}
.profile-feed-name-row{display:flex;align-items:center;gap:.3rem;min-width:0;}
.profile-feed-name{font-family:var(--font-display);font-weight:700;color:var(--text);font-size:.82rem;letter-spacing:.01em;line-height:1.2;cursor:pointer;}
.profile-feed-name:hover{text-decoration:underline;color:var(--text);}
.profile-feed-nip05{font-size:.66rem;line-height:1;flex-shrink:0;opacity:.95;}
.profile-feed-status{font-family:'DM Mono',monospace;font-size:.63rem;color:var(--muted);margin-top:.12rem;line-height:1.35;word-break:break-word;display:none;}
.profile-feed-time{font-family:'DM Mono',monospace;font-size:.64rem;color:var(--muted);white-space:nowrap;margin-top:.12rem;}
.profile-comment-meta .n:hover{text-decoration:underline;}
.profile-feed-text{font-size:.82rem;color:var(--text2);line-height:1.55;white-space:normal;word-break:break-word;}
/* Post media: make smaller in feed */
/* Post media grid: photos square 3-col, videos 16:9 full-width */
.profile-feed-media{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:.4rem;margin-top:.56rem;}
.profile-feed-media.one{grid-template-columns:1fr;}
.profile-feed-photo{border-radius:8px;overflow:hidden;border:1px solid var(--border2);background:#090d12;aspect-ratio:1/1;max-height:200px;}
.profile-feed-photo img{width:100%;height:100%;object-fit:cover;display:block;}
.profile-feed-video{border-radius:8px;overflow:hidden;border:1px solid var(--border2);background:#090d12;grid-column:1/-1;max-height:320px;}
.profile-feed-video video{width:100%;height:100%;max-height:320px;object-fit:contain;display:block;background:#000;}
.profile-feed-video a{display:flex;align-items:center;justify-content:center;width:100%;height:100%;min-height:80px;color:var(--zap);font-size:.74rem;text-decoration:none;font-weight:600;padding:.75rem;}
.profile-feed-stats{display:flex;flex-wrap:wrap;gap:.44rem;margin-top:.55rem;}
.pfs{padding:.17rem .42rem;border:1px solid var(--border);border-radius:999px;background:rgba(255,255,255,.02);font-size:.66rem;color:var(--text2);font-family:'DM Mono',monospace;}
.pfs strong{color:var(--text);font-weight:600;}
.pfs-btn{cursor:pointer;transition:all .14s;}
.pfs-btn:hover{border-color:var(--accent);color:var(--text);}
.pfs-btn.active{border-color:var(--live);color:var(--live);background:rgba(255,59,92,.08);}
.pfs-btn.boosted{border-color:var(--purple);color:var(--purple);background:rgba(155,114,255,.12);}
.pfs-plus{font-weight:700;padding:.17rem .55rem;}
.profile-feed-emoji-bar{display:flex;flex-wrap:wrap;gap:.35rem;margin-top:.42rem;}
.profile-feed-comments{display:flex;flex-direction:column;gap:.4rem;margin-top:.56rem;padding-top:.5rem;border-top:1px solid var(--border);}
.profile-comments-indicator{
  align-self:flex-start;
  font-family:'DM Mono',monospace;
  font-size:.62rem;
  letter-spacing:.08em;
  text-transform:uppercase;
  color:var(--muted);
  border:1px solid var(--border2);
  border-radius:999px;
  padding:.16rem .46rem;
  background:rgba(255,255,255,.02);
}
.profile-comment-item{display:flex;align-items:flex-start;gap:.45rem;padding:.38rem .42rem;border:1px solid var(--border2);border-radius:10px;background:rgba(255,255,255,.02);}
.profile-comment-av{width:30px;height:30px;border-radius:50%;background:var(--surface3);border:1px solid var(--border2);display:flex;align-items:center;justify-content:center;font-size:.78rem;overflow:hidden;flex-shrink:0;}
.profile-comment-main{min-width:0;flex:1;}
.profile-comment-meta{display:flex;align-items:center;gap:.36rem;}
.profile-comment-meta .n{font-size:.7rem;font-weight:600;color:var(--text);}
.profile-comment-meta .t{font-family:'DM Mono',monospace;font-size:.62rem;color:var(--muted);}
.profile-comment-text{font-size:.75rem;color:var(--text2);line-height:1.45;word-break:break-word;white-space:normal;}
.profile-comment-media{margin-top:.38rem;}
.profile-comment-media-wrap{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:.3rem;max-width:360px;}
.profile-comment-media-wrap.single{grid-template-columns:1fr;max-width:420px;}
.profile-comment-media-item{display:flex;align-items:center;justify-content:center;border:1px solid var(--border2);border-radius:8px;overflow:hidden;background:#090f14;min-height:92px;max-height:220px;}
.profile-comment-media-item.single{min-height:130px;max-height:260px;}
.profile-comment-media-item img,.profile-comment-media-item video{width:100%;height:100%;display:block;background:#000;}
.profile-comment-media-item img{object-fit:cover;}
.profile-comment-media-item video{object-fit:contain;}
.profile-comment-actions{display:flex;align-items:center;gap:.35rem;margin-top:.34rem;}
.profile-comment-reply-btn,
.profile-comment-like-btn,
.profile-comment-zap-btn,
.profile-comment-boost-btn{background:transparent;border:1px solid var(--border2);border-radius:999px;color:var(--text2);font-size:.64rem;font-family:'DM Mono',monospace;padding:.16rem .46rem;cursor:pointer;transition:all .14s;}
.profile-comment-reply-btn:hover,
.profile-comment-like-btn:hover,
.profile-comment-zap-btn:hover,
.profile-comment-boost-btn:hover{border-color:var(--accent);color:var(--text);}
.profile-comment-like-btn.active{border-color:var(--live);color:var(--live);background:rgba(255,59,92,.08);}
.profile-comment-zap-btn.active{border-color:var(--zap);color:var(--zap);background:rgba(247,183,49,.08);}
.profile-comment-boost-btn.active{border-color:var(--purple);color:var(--purple);background:rgba(155,114,255,.12);}
.profile-comment-like-count{margin-left:.24rem;color:var(--text);}
.profile-comment-zap-count,.profile-comment-boost-count{margin-left:.24rem;color:var(--text);}
.nostr-md-p{margin:.25rem 0;line-height:1.6;}
.nostr-md-h1,.nostr-md-h2,.nostr-md-h3{margin:.3rem 0 .2rem;font-family:var(--font-display);color:var(--text);line-height:1.3;}
.nostr-md-h1{font-size:1.05rem;font-weight:800;}
.nostr-md-h2{font-size:.95rem;font-weight:760;}
.nostr-md-h3{font-size:.87rem;font-weight:720;}
.nostr-md-ul,.nostr-md-ol{margin:.3rem 0 .38rem;padding-left:1.1rem;}
.nostr-md-li{margin:.1rem 0;}
.nostr-md-blockquote{margin:.3rem 0;padding:.18rem .55rem;border-left:2px solid var(--border2);background:rgba(255,255,255,.02);color:var(--text2);}
.nostr-md-strong{font-weight:700;color:var(--text);}
.nostr-md-italic{font-style:italic;}
.nostr-md-strike{text-decoration:line-through;text-decoration-thickness:1px;}
.nostr-inline-code{font-family:'DM Mono',monospace;font-size:.84em;background:var(--surface3);border:1px solid var(--border2);border-radius:6px;padding:.04rem .3rem;color:var(--text);}
.nostr-inline-link{color:var(--accent);text-decoration:none;word-break:break-all;}
.nostr-inline-link:hover{text-decoration:underline;}
.profile-comment-empty{font-size:.7rem;color:var(--muted);}

/* ======== ADD-TO-LIST DROPDOWN ======== */
.atl-wrap{position:relative;display:inline-block;}
.atl-dropdown{
  position:absolute;top:calc(100% + 6px);right:0;
  background:var(--surface);border:1px solid var(--border2);
  border-radius:12px;padding:.5rem;
  box-shadow:0 20px 60px rgba(0,0,0,.8),0 0 0 1px rgba(255,255,255,.03);
  opacity:0;pointer-events:none;
  transform:translateY(-4px);
  transition:opacity .16s ease,transform .16s ease;
  z-index:700;min-width:220px;
}
.atl-dropdown.open{opacity:1;pointer-events:all;transform:translateY(0);}
.atl-label{font-family:'DM Mono',monospace;font-size:.62rem;color:var(--muted);text-transform:uppercase;letter-spacing:.1em;padding:.3rem .65rem .3rem;display:block;}
.atl-item{display:flex;align-items:center;gap:.65rem;padding:.5rem .75rem;border-radius:8px;font-size:.8rem;color:var(--text2);cursor:pointer;transition:background .1s;background:none;border:none;width:100%;text-align:left;font-family:var(--font-display);font-weight:650;letter-spacing:.01em;}
.atl-item:hover{background:var(--surface2);color:var(--text);}
.atl-item.atl-create{color:var(--accent);border-top:1px solid var(--border);margin-top:.3rem;padding-top:.6rem;}
.atl-item.atl-saved{color:var(--green);}
.atl-new-row{display:flex;gap:.4rem;padding:.45rem .55rem 0;}
.atl-new-input{flex:1;background:var(--surface2);border:1px solid var(--border2);border-radius:7px;padding:.35rem .55rem;color:var(--text);font-size:.76rem;font-family:'DM Sans',sans-serif;outline:none;}
.atl-new-input:focus{border-color:var(--accent);}
.atl-new-btn{background:var(--accent);border:none;border-radius:7px;color:#fff;font-size:.75rem;font-weight:600;padding:.35rem .65rem;cursor:pointer;font-family:'DM Sans',sans-serif;white-space:nowrap;}
.atl-new-btn:hover{background:#ff5520;}
.atl-empty{font-size:.75rem;color:var(--muted);padding:.45rem .75rem;}

/* ======== NOSTR BADGES ======== */
.profile-bio-grid{display:flex;flex-direction:column;gap:.85rem;flex:1;}
.profile-bio-grid.has-badges{display:grid;grid-template-columns:1fr auto;gap:.75rem;align-items:start;}
.profile-badges-panel{
  background:rgba(155,114,255,.07);
  border:1px solid rgba(155,114,255,.22);
  border-radius:10px;
  padding:.18rem .2rem;
  min-width:134px;max-width:176px;
}
.profile-badges-title{font-family:'DM Mono',monospace;font-size:.62rem;text-transform:uppercase;letter-spacing:.1em;color:var(--purple);margin:.08rem .22rem .3rem;}
.profile-badges-grid{display:grid;grid-template-columns:repeat(3,42px);gap:.38rem;}
.profile-badge-chip{
  width:42px;height:42px;border-radius:8px;
  background:var(--surface2);
  border:1px solid rgba(155,114,255,.3);
  display:flex;align-items:center;justify-content:center;
  font-size:1.45rem;cursor:pointer;
  transition:all .15s;
  overflow:hidden;
  position:relative;
}
.profile-badge-chip img{width:100%;height:100%;object-fit:cover;border-radius:6px;}
.profile-badge-chip:hover{border-color:var(--purple);box-shadow:0 0 10px rgba(155,114,255,.35);transform:scale(1.08);}
.profile-badges-empty{font-size:.72rem;color:var(--muted);}

/* ======== BADGE DETAIL POPUP ======== */
.badge-popup-ov{position:fixed;inset:0;z-index:2000;display:none;align-items:center;justify-content:center;background:rgba(5,8,12,.85);backdrop-filter:blur(14px) saturate(.6);}
.badge-popup-ov.open{display:flex;animation:fadeIn .18s ease;}
.badge-popup{
  background:var(--surface);border:1px solid var(--border2);
  border-radius:18px;width:min(380px,92vw);
  position:relative;box-shadow:0 40px 120px rgba(0,0,0,.9);
  animation:slideUp .22s cubic-bezier(.4,0,.2,1);
  overflow:hidden;
}
.badge-popup::before{content:'';position:absolute;top:0;left:0;right:0;height:3px;background:linear-gradient(90deg,var(--purple),var(--accent));border-radius:18px 18px 0 0;}
.badge-popup-img-wrap{
  width:100%;height:160px;background:linear-gradient(135deg,rgba(155,114,255,.12),rgba(232,70,10,.08));
  display:flex;align-items:center;justify-content:center;font-size:4rem;border-bottom:1px solid var(--border);overflow:hidden;
}
.badge-popup-img-wrap img{width:100%;height:100%;object-fit:contain;padding:1.5rem;}
.badge-popup-body{padding:1.15rem 1.25rem 1.35rem;}
.badge-popup-name{font-family:var(--font-display);font-weight:800;font-size:1.1rem;margin-bottom:.3rem;}
.badge-popup-desc{font-size:.82rem;color:var(--text2);line-height:1.6;margin-bottom:.75rem;}
.badge-popup-meta{display:flex;flex-direction:column;gap:.28rem;}
.badge-popup-meta-row{display:flex;gap:.5rem;font-size:.72rem;align-items:flex-start;}
.badge-popup-meta-lbl{font-family:'DM Mono',monospace;color:var(--muted);min-width:68px;flex-shrink:0;}
.badge-popup-meta-val{color:var(--text2);word-break:break-all;}
.badge-popup-close{position:absolute;top:.85rem;right:.85rem;background:none;border:none;color:var(--muted);cursor:pointer;font-size:.95rem;padding:.2rem .32rem;border-radius:6px;transition:all .15s;line-height:1;}
.badge-popup-close:hover{background:var(--surface2);color:var(--text);}
.profile-comments-more{background:transparent;border:1px solid var(--border2);border-radius:8px;color:var(--text2);font-size:.68rem;padding:.24rem .48rem;cursor:pointer;align-self:flex-start;}
.profile-comments-more:hover{border-color:var(--accent);color:var(--accent);}
.profile-comment-form{display:flex;flex-direction:column;gap:.36rem;margin-top:.5rem;}
.profile-comment-input{flex:1;min-height:36px;max-height:90px;background:#0f141b;border:1px solid var(--border2);border-radius:8px;padding:.38rem .52rem;color:var(--text);font-size:.75rem;font-family:'DM Sans',sans-serif;resize:vertical;}
.profile-comment-input:focus{outline:none;border-color:var(--accent);box-shadow:0 0 0 2px rgba(232,70,10,.18);}
.profile-comment-tools{display:flex;align-items:center;justify-content:space-between;gap:.44rem;flex-wrap:nowrap;}
.profile-comment-markup{margin:0;display:flex;flex-wrap:wrap;justify-content:flex-end;gap:.24rem;flex:1;min-width:0;}
.profile-comment-markup button{padding:.13rem .32rem;font-size:.55rem;}
.profile-comment-row{display:flex;align-items:center;justify-content:flex-start;gap:.34rem;flex-shrink:0;}
.profile-comment-attach-btn{background:var(--surface3);border:1px solid var(--border2);border-radius:8px;color:var(--text2);font-size:.68rem;padding:.27rem .58rem;cursor:pointer;font-weight:600;transition:border-color .14s,color .14s,background .14s;}
.profile-comment-attach-btn:hover{border-color:var(--accent);color:var(--accent);}
.profile-comment-btn{background:var(--surface3);border:1px solid var(--border2);border-radius:8px;color:var(--text);font-size:.72rem;padding:.33rem .62rem;cursor:pointer;font-weight:600;}
.profile-comment-btn:hover{border-color:var(--accent);color:var(--accent);}
.profile-comment-nip05{font-size:.62rem;line-height:1;opacity:.94;}
.profile-feed-photo.broken{display:flex;align-items:center;justify-content:center;background:#10151d;}
.profile-feed-photo.broken span{font-size:.7rem;color:var(--text2);font-family:'DM Mono',monospace;}
.profile-feed-empty{font-size:.78rem;color:var(--muted);padding:.75rem;border:1px dashed var(--border2);border-radius:8px;}
.profile-media-card{padding:.72rem;}
.profile-tab-row{display:flex;gap:.34rem;flex-wrap:wrap;padding:.24rem;background:var(--surface2);border:1px solid var(--border);border-radius:10px;margin-bottom:.62rem;}
.profile-tab{flex:1;background:transparent;border:1px solid transparent;border-radius:8px;padding:.38rem .5rem;cursor:pointer;color:var(--text2);font-size:.72rem;font-weight:600;}
.profile-tab.active{background:var(--surface3);border-color:var(--accent);color:var(--text);}
.profile-tab-pane{display:none;}
.profile-tab-pane.on{display:block;}
.profile-media-list{display:flex;flex-direction:column;gap:.58rem;}
.profile-stream-item{display:flex;align-items:center;justify-content:space-between;gap:.6rem;padding:.58rem .62rem;background:var(--surface2);border:1px solid var(--border);border-radius:9px;}
.profile-stream-title{font-size:.8rem;color:var(--text);font-weight:600;line-height:1.4;}
.profile-stream-meta{font-family:'DM Mono',monospace;font-size:.66rem;color:var(--muted);margin-top:.22rem;}
/* Media tab mixed feed: photos + videos together */
.profile-media-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:.5rem;}
.profile-media-card-item{display:flex;flex-direction:column;border:1px solid var(--border);border-radius:10px;overflow:hidden;background:var(--surface2);text-decoration:none;min-width:0;}
.profile-media-frame{aspect-ratio:16/9;background:#000;display:flex;align-items:center;justify-content:center;overflow:hidden;}
.profile-media-card-item.photo .profile-media-frame{aspect-ratio:1/1;}
.profile-media-frame img,.profile-media-frame video{width:100%;height:100%;display:block;background:#000;}
.profile-media-frame img{object-fit:cover;}
.profile-media-frame video{object-fit:contain;}
.profile-media-fallback-link{display:flex;align-items:center;justify-content:center;width:100%;height:100%;padding:.8rem;color:var(--zap);font-size:.72rem;font-weight:600;text-decoration:none;}
.profile-media-meta{display:flex;align-items:center;justify-content:space-between;gap:.45rem;padding:.34rem .42rem .18rem;}
.profile-media-kind{font-family:'DM Mono',monospace;font-size:.6rem;letter-spacing:.08em;text-transform:uppercase;color:var(--text2);}
.profile-media-kind.video{color:var(--purple);}
.profile-media-kind.photo{color:var(--green);}
.profile-media-time{font-family:'DM Mono',monospace;font-size:.6rem;color:var(--muted);}
.profile-media-caption{padding:0 .42rem .42rem;font-size:.68rem;color:var(--text2);line-height:1.4;max-height:2.8em;overflow:hidden;}
/* Profile compose box */
.profile-compose-box{background:var(--surface);border:1px solid var(--border);border-radius:12px;padding:.85rem;display:flex;flex-direction:column;gap:.55rem;}
.profile-compose-box.hidden{display:none;}
.profile-compose-header{display:flex;align-items:center;justify-content:space-between;gap:.55rem;flex-wrap:wrap;margin-bottom:.08rem;}
.profile-compose-ident{display:flex;align-items:center;gap:.55rem;min-width:0;}
.profile-compose-av{width:38px;height:38px;border-radius:50%;background:linear-gradient(135deg,var(--accent),var(--zap));display:flex;align-items:center;justify-content:center;font-size:1rem;overflow:hidden;flex-shrink:0;border:2px solid var(--border2);}
.profile-compose-label{font-family:var(--font-display);font-weight:700;font-size:.85rem;}
.profile-compose-toolbar{display:flex;align-items:center;gap:.45rem;margin-left:auto;flex-wrap:wrap;justify-content:flex-end;}
.profile-compose-textarea{width:100%;min-height:200px;max-height:420px;background:#0a1018;border:1px solid var(--border2);border-radius:10px;padding:.55rem .72rem;color:var(--text);font-family:'DM Sans',sans-serif;font-size:.84rem;outline:none;resize:vertical;line-height:1.5;transition:border-color .15s;flex:1;}
.profile-compose-textarea:focus{border-color:var(--accent);box-shadow:0 0 0 2px rgba(232,70,10,.15);}
.profile-compose-textarea::placeholder{color:var(--muted);}
.profile-compose-btn{padding:.38rem .95rem;background:var(--accent);border:none;border-radius:8px;cursor:pointer;color:#fff;font-size:.8rem;font-weight:600;font-family:'DM Sans',sans-serif;transition:all .15s;}
.profile-compose-btn:hover{background:#ff5520;}
.profile-compose-btn:disabled{opacity:.5;cursor:not-allowed;}
.profile-compose-gif-btn{padding:.34rem .82rem;background:linear-gradient(135deg,rgba(0,212,138,.17),rgba(155,114,255,.14));border:1px solid rgba(0,212,138,.35);border-radius:8px;cursor:pointer;color:var(--text);font-size:.76rem;font-weight:600;font-family:'DM Sans',sans-serif;transition:border-color .15s,color .15s,background .15s;}
.profile-compose-gif-btn:hover{border-color:var(--green);color:var(--green);}
.profile-compose-upload-btn{padding:.34rem .82rem;background:var(--surface3);border:1px solid var(--border2);border-radius:8px;cursor:pointer;color:var(--text);font-size:.76rem;font-weight:600;font-family:'DM Sans',sans-serif;transition:border-color .15s,color .15s,background .15s;}
.profile-compose-upload-btn:hover{border-color:var(--accent);color:var(--accent);}
.pmeta-row{display:flex;align-items:flex-start;justify-content:space-between;gap:.55rem;font-size:.76rem;color:var(--text2);}
.pmeta-row span:first-child{font-family:'DM Mono',monospace;color:var(--muted);}
.pmeta-row code{font-family:'DM Mono',monospace;color:var(--text);font-size:.68rem;word-break:break-all;}
.pmeta-row a{color:var(--accent);text-decoration:none;word-break:break-all;}

/* ======== INFINITE SCROLL SENTINEL ======== */
.feed-sentinel{
  display:flex;align-items:center;justify-content:center;
  padding:1.1rem .5rem;
}
.feed-sentinel-label{
  font-family:'DM Mono',monospace;font-size:.62rem;
  color:var(--muted);letter-spacing:.06em;
  animation:sentinelPulse 1.5s ease-in-out infinite;
}
.media-sentinel{padding:.85rem .5rem;}
@keyframes sentinelPulse{0%,100%{opacity:.4}50%{opacity:1}}
.feed-fade-item{animation:feedItemFade .24s ease both;}
@keyframes feedItemFade{from{opacity:0;transform:translateY(10px)}to{opacity:1;transform:translateY(0)}}

@media (max-width: 1024px){
  .profile-top{grid-template-columns:1fr;}
  .profile-main-grid{grid-template-columns:1fr;}
  .profile-media-grid{grid-template-columns:repeat(2,minmax(0,1fr));}
  .profile-inline-stats{grid-template-columns:repeat(2,minmax(0,1fr));}
  .profile-action-box{justify-self:start;margin-top:0;width:100%;}
  .profile-actions-row{justify-content:flex-start;}
  .profile-inline-meta{margin-top:0;}
}
@media (max-width: 860px){
  .profile-media-grid{grid-template-columns:1fr;}
}
@media (max-width: 680px){
  .profile-content{padding:0 1rem 1rem;}
  .profile-head-row{align-items:center;}
  .profile-av-wrap{margin-top:-10px;}
  .profile-av-big{width:100px;height:100px;font-size:2.3rem;}
  .profile-compose-toolbar{width:100%;justify-content:flex-end;}
  .profile-compose-textarea{min-height:170px;}
  .nostr-markup-toolbar-compose{order:3;width:100%;justify-content:flex-end;margin-top:.18rem;}
  .chat-acts{flex-wrap:wrap;}
  .nostr-markup-toolbar-chat{width:100%;}
}

/* ======== MODALS ======== */
.modal-ov{position:fixed;inset:0;z-index:1000;display:none;align-items:center;justify-content:center;background:rgba(5,8,12,.88);backdrop-filter:blur(18px) saturate(.55);}
.modal-ov.open{display:flex;animation:fadeIn .2s ease;}
@keyframes fadeIn{from{opacity:0}to{opacity:1}}
.modal{background:var(--surface);border:1px solid var(--border2);border-radius:18px;width:min(580px,94vw);max-height:90vh;overflow-y:auto;position:relative;box-shadow:0 40px 120px rgba(0,0,0,.9);animation:slideUp .25s cubic-bezier(.4,0,.2,1);}
#goLiveModal .modal{width:min(1520px,99vw);height:min(96vh,1020px);max-height:96vh;overflow:hidden;display:flex;flex-direction:column;}
#goLiveModal #mForm{display:flex;flex-direction:column;flex:1;min-height:0;}
@keyframes slideUp{from{transform:translateY(22px);opacity:0}to{transform:translateY(0);opacity:1}}
.modal::before{content:'';position:absolute;top:0;left:0;right:0;height:3px;background:linear-gradient(90deg,var(--accent),var(--zap));border-radius:18px 18px 0 0;}
.mhd{padding:1.35rem 1.35rem 0;display:flex;align-items:flex-start;justify-content:space-between;}
.mtitle{font-family:var(--font-display);font-weight:800;font-size:1.08rem;display:flex;align-items:center;gap:.42rem;}
.mi{color:var(--accent);}
.mclose{background:none;border:none;color:var(--muted);cursor:pointer;font-size:1rem;padding:.2rem .32rem;border-radius:6px;transition:all .15s;line-height:1;}
.mclose:hover{background:var(--surface2);color:var(--text);}
.msub{font-size:.77rem;color:var(--muted);padding:.18rem 1.35rem .08rem;}
.go-live-host-modes{padding:.5rem 1.35rem 0;display:grid;grid-template-columns:1fr 1fr;gap:.52rem;}
.go-live-host-btn{border:1px solid var(--border2);background:var(--surface2);color:var(--text2);border-radius:10px;padding:.52rem .6rem;font-family:'DM Sans',sans-serif;font-size:.77rem;font-weight:700;cursor:pointer;text-align:left;transition:border-color .15s,background .15s,color .15s,transform .15s;}
.go-live-host-btn:hover{border-color:var(--accent);color:var(--text);transform:translateY(-1px);}
.go-live-host-btn span{display:block;margin-top:.2rem;font-size:.64rem;font-weight:600;color:var(--muted);}
.go-live-host-btn.on{border-color:rgba(232,70,10,.5);background:linear-gradient(145deg,rgba(232,70,10,.2),rgba(247,183,49,.12));color:#fff;}
.go-live-host-note{padding:.42rem 1.35rem 0;font-size:.68rem;color:var(--muted);line-height:1.5;}
.mbody{padding:1.05rem 1.35rem;}
#goLiveModal .mhd{padding:1.02rem 1.1rem 0;}
#goLiveModal .msub{padding:.14rem 1.1rem .06rem;}
#goLiveModal .go-live-host-modes{padding:.34rem 1.1rem 0;gap:.42rem;}
#goLiveModal .go-live-host-note{padding:.26rem 1.1rem 0;font-size:.65rem;line-height:1.35;}
#goLiveModal .mbody{padding:.62rem 1.1rem .46rem;display:flex;flex:1;min-height:0;overflow:hidden;}
#goLiveModal .go-live-self-wrap{display:flex;flex:1;min-height:0;}
.fg-grid{display:grid;grid-template-columns:1fr 1fr;gap:.65rem;}
.fg{display:flex;flex-direction:column;gap:.32rem;}
.fg.full{grid-column:1/-1;}
#goLiveModal .go-live-create-grid{display:grid;grid-template-columns:minmax(0,1.35fr) minmax(0,1fr) minmax(0,.95fr);gap:.56rem;align-items:stretch;height:100%;}
#goLiveModal .go-live-col{border:1px solid var(--border2);background:var(--surface2);border-radius:12px;padding:.55rem;min-height:0;}
#goLiveModal .go-live-col-form{display:block;grid-column:1/2;}
#goLiveModal .go-live-col-preview{display:flex;flex-direction:column;grid-column:2/4;min-height:0;}
#goLiveModal .go-live-create-grid.relays-open .go-live-col-preview{grid-column:2/3;}
#goLiveModal .go-live-col-relays{display:flex;flex-direction:column;grid-column:3/4;min-height:0;}
#goLiveModal .go-live-col-title{font-family:'DM Mono',monospace;font-size:.66rem;letter-spacing:.08em;text-transform:uppercase;color:var(--muted);margin-bottom:.5rem;}
#goLiveModal .go-live-form-grid{grid-template-columns:1fr;gap:.62rem;}
#goLiveModal .go-live-form-grid .fg.full{grid-column:auto;}
#goLiveModal .go-live-thumb-preview{margin-top:.42rem;border:1px solid var(--border2);border-radius:10px;background:var(--surface3);overflow:hidden;min-height:96px;display:flex;align-items:center;justify-content:center;position:relative;}
#goLiveModal .go-live-thumb-preview img{width:100%;height:100%;display:none;object-fit:cover;max-height:190px;}
#goLiveModal .go-live-thumb-preview-empty{font-size:.68rem;color:var(--muted);padding:.65rem;text-align:center;line-height:1.45;}
#goLiveModal .go-live-stream-preview-video{width:100%;height:100%;flex:1;min-height:260px;border-radius:10px;background:#05080d;border:1px solid var(--border2);object-fit:contain;}
#goLiveModal .go-live-stream-preview-status{margin-top:.48rem;font-size:.68rem;color:var(--muted);line-height:1.45;min-height:1.4em;}
#goLiveModal .go-live-preview-controls{margin-top:.52rem;display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1fr);gap:.5rem;align-items:end;}
#goLiveModal .go-live-preview-controls .srow{flex-wrap:wrap;}
#goLiveModal .go-live-preview-controls #goLiveStartsWrap{min-width:0;}
#goLiveModal .go-live-relay-ping-help{margin-top:.38rem;font-size:.64rem;color:var(--muted);}
#goLiveModal .go-live-relay-list{margin-top:.46rem;display:flex;flex-direction:column;gap:.34rem;max-height:none;overflow:auto;padding-right:.1rem;flex:1;min-height:0;}
#goLiveModal .go-live-relay-row{display:grid;grid-template-columns:auto 1fr auto;gap:.42rem;align-items:center;font-size:.66rem;color:var(--text2);border:1px solid var(--border2);background:var(--surface3);border-radius:8px;padding:.34rem .4rem;}
#goLiveModal .go-live-relay-dot{width:8px;height:8px;border-radius:50%;background:var(--muted);}
#goLiveModal .go-live-relay-row.open .go-live-relay-dot{background:var(--green);box-shadow:0 0 0 3px rgba(0,212,138,.14);}
#goLiveModal .go-live-relay-url{font-family:'DM Mono',monospace;color:var(--text);overflow:hidden;text-overflow:ellipsis;white-space:nowrap;}
#goLiveModal .go-live-relay-ping{font-family:'DM Mono',monospace;color:var(--muted);}
#goLiveModal .go-live-third-party-wrap{border:1px solid var(--border2);background:var(--surface2);border-radius:12px;padding:.72rem;}
#goLiveModal .go-live-third-party-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:.52rem;}
#goLiveModal .go-live-third-party-btn{border:1px solid var(--border2);background:var(--surface3);color:var(--text);border-radius:10px;padding:.62rem .56rem;font-family:var(--font-display);font-size:.82rem;font-weight:700;cursor:pointer;transition:border-color .15s,transform .15s,background .15s;}
#goLiveModal .go-live-third-party-btn:hover{border-color:var(--accent);transform:translateY(-1px);background:rgba(232,70,10,.12);}
#goLiveModal .go-live-third-party-btn.on{border-color:var(--accent);background:linear-gradient(145deg,rgba(232,70,10,.2),rgba(247,183,49,.1));}
#goLiveModal .go-live-third-party-help{margin-top:.58rem;font-size:.7rem;color:var(--muted);line-height:1.5;}
label{font-size:.67rem;font-weight:600;color:var(--muted);text-transform:uppercase;letter-spacing:.08em;font-family:'DM Mono',monospace;}
.fg-static-label{font-size:.67rem;font-weight:600;color:var(--muted);text-transform:uppercase;letter-spacing:.08em;font-family:'DM Mono',monospace;}
input,select,textarea{background:var(--surface2);border:1px solid var(--border2);border-radius:9px;padding:.5rem .8rem;color:var(--text);font-family:'DM Sans',sans-serif;font-size:.83rem;outline:none;transition:border-color .18s,box-shadow .18s;width:100%;}
input:focus,select:focus,textarea:focus{border-color:var(--accent);box-shadow:0 0 0 3px var(--accent-glow);}
input::placeholder,textarea::placeholder{color:var(--muted);}
select option{background:var(--surface2);}
textarea{resize:vertical;min-height:65px;line-height:1.5;}
.srow{display:flex;gap:.42rem;}
.sc{padding:.3rem .75rem;border-radius:7px;font-size:.76rem;font-weight:500;cursor:pointer;border:1px solid var(--border2);background:transparent;color:var(--muted);transition:all .15s;font-family:'DM Sans',sans-serif;}
.sc.sl{border-color:var(--live);color:var(--live);background:rgba(255,59,92,.1);}
.relay-bar{font-family:'DM Mono',monospace;font-size:.68rem;color:var(--green);background:rgba(0,212,138,.05);border:1px solid rgba(0,212,138,.13);border-radius:8px;padding:.48rem .72rem;margin-top:.18rem;display:flex;align-items:center;gap:.32rem;}
.go-live-manage{margin-bottom:.7rem;display:none;}
.go-live-manage.on{display:block;}
.go-live-manage-help{margin-top:.28rem;font-size:.68rem;color:var(--muted);line-height:1.5;}
.go-live-manage-actions{display:flex;justify-content:flex-end;margin-top:.38rem;}
#goLiveModal .mbody.go-live-disabled{opacity:.56;}
#goLiveModal #goLiveRelaysToggleBtn.on{border-color:rgba(0,212,138,.45);color:var(--green);background:rgba(0,212,138,.12);}
.mfooter{padding:.85rem 1.35rem 1.35rem;display:flex;gap:.55rem;justify-content:flex-end;border-top:1px solid var(--border);}
#goLiveModal .mfooter{padding:.58rem 1.1rem .95rem;flex-wrap:wrap;}
#goLiveModal label{font-size:.62rem;}
#goLiveModal .fg-static-label{font-size:.62rem;}
#goLiveModal input,#goLiveModal select,#goLiveModal textarea{padding:.42rem .66rem;font-size:.79rem;}
#goLiveModal textarea{min-height:52px;}
#goLiveModal .sc{padding:.26rem .62rem;}
.msuccess{display:none;padding:1.8rem 1.5rem;text-align:center;}
.msuccess.on{display:block;}
.succ-icon{font-size:2.6rem;margin-bottom:.6rem;}
.succ-title{font-family:var(--font-display);font-weight:800;font-size:1.12rem;margin-bottom:.4rem;}
.succ-text{font-size:.82rem;color:var(--text2);line-height:1.6;}

/* Login modal */
.login-modal{background:var(--surface);border:1px solid var(--border2);border-radius:18px;width:min(1080px,96vw);position:relative;box-shadow:0 40px 120px rgba(0,0,0,.9);animation:slideUp .25s cubic-bezier(.4,0,.2,1);overflow:hidden;}
.login-modal::before{content:'';position:absolute;top:0;left:0;right:0;height:3px;background:linear-gradient(90deg,var(--purple),var(--accent));border-radius:18px 18px 0 0;}
.lm-hd{padding:1.35rem 1.35rem .85rem;text-align:center;}
.lm-logo{font-family:var(--font-display);font-weight:800;font-size:1.25rem;margin-bottom:.12rem;display:flex;align-items:center;justify-content:center;gap:.38rem;}
.lm-lb{color:var(--zap);}
.lm-sub{font-size:.78rem;color:var(--muted);}
.lm-body{padding:.2rem 1.2rem 1.2rem;}
.login-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:.75rem;align-items:stretch;}
.login-col{background:var(--surface2);border:1px solid var(--border2);border-radius:14px;padding:.75rem;}
.lm-col-title{font-family:'DM Mono',monospace;font-size:.65rem;color:var(--muted);text-transform:uppercase;letter-spacing:.1em;margin-bottom:.55rem;}
.lm-sec{font-family:'DM Mono',monospace;font-size:.65rem;color:var(--muted);text-transform:uppercase;letter-spacing:.1em;margin-bottom:.45rem;margin-top:.8rem;}
.lo{display:flex;align-items:center;gap:.82rem;padding:.82rem .95rem;border-radius:12px;cursor:pointer;border:1px solid var(--border2);background:var(--surface2);transition:all .18s;margin-bottom:.5rem;}
.lo:hover{border-color:var(--accent);background:var(--surface3);}
.lo:hover .lo-arr{opacity:1;transform:translateX(0);}
.lo-col-btn{margin-bottom:.52rem;}
.lo-ico{width:38px;height:38px;border-radius:10px;display:flex;align-items:center;justify-content:center;font-size:1.25rem;flex-shrink:0;}
.lo-ico.ext{background:linear-gradient(135deg,rgba(155,114,255,.2),rgba(155,114,255,.05));border:1px solid rgba(155,114,255,.2);}
.lo-ico.hw{background:linear-gradient(135deg,rgba(0,212,138,.15),rgba(0,212,138,.05));border:1px solid rgba(0,212,138,.2);}
.lo-ico.new{background:linear-gradient(135deg,rgba(0,212,138,.2),rgba(0,212,138,.05));border:1px solid rgba(0,212,138,.2);}
.lo-ico.remote{background:linear-gradient(135deg,rgba(27,145,255,.22),rgba(27,145,255,.06));border:1px solid rgba(27,145,255,.3);}
.lo-t{font-size:.88rem;font-weight:600;}
.lo-d{font-size:.73rem;color:var(--muted);margin-top:.08rem;line-height:1.4;}
.lo-d code{font-family:'DM Mono',monospace;font-size:.67rem;color:var(--accent);}
.lo-arr{margin-left:auto;color:var(--muted);font-size:.88rem;opacity:0;transform:translateX(-4px);transition:all .15s;}
.lm-div{display:flex;align-items:center;gap:.7rem;margin:.55rem 0;}
.lm-div span{font-size:.7rem;color:var(--muted);white-space:nowrap;}
.lm-div::before,.lm-div::after{content:'';flex:1;height:1px;background:var(--border);}
.key-wrap{display:flex;flex-direction:column;gap:.42rem;margin-bottom:.45rem;}
.remote-login-wrap{display:flex;flex-direction:column;gap:.42rem;margin:.18rem 0 .1rem;}
.remote-qr-card{border:1px solid var(--border2);border-radius:12px;background:rgba(255,255,255,.02);padding:.62rem;display:flex;flex-direction:column;align-items:center;gap:.45rem;}
.remote-qr-img{width:min(220px,100%);aspect-ratio:1/1;object-fit:contain;border-radius:10px;background:#fff;padding:.28rem;}
.remote-qr-text{font-size:.7rem;color:var(--muted);text-align:center;line-height:1.35;}
.remote-login-actions{display:flex;gap:.42rem;width:100%;}
.remote-login-actions .btn{flex:1;}
.remote-login-status{display:none;font-size:.71rem;line-height:1.4;border-radius:8px;padding:.46rem .62rem;}
.remote-login-status.is-visible{display:block;}
.remote-login-status.is-loading{color:var(--text2);border:1px solid var(--border2);background:rgba(255,255,255,.03);}
.remote-login-status.is-success{color:var(--green);border:1px solid rgba(0,212,138,.25);background:rgba(0,212,138,.08);}
.remote-login-status.is-error{color:#ff8f8f;border:1px solid rgba(255,92,92,.25);background:rgba(255,92,92,.08);}
.remote-login-status.is-info{color:var(--muted);border:1px solid var(--border);background:rgba(255,255,255,.02);}
@media (max-width:980px){
  .login-grid{grid-template-columns:1fr;}
}
@media (max-width:560px){
  .remote-login-actions{flex-direction:column;}
}
.key-inp{font-family:'DM Mono',monospace;font-size:.74rem;}
.key-inp::placeholder{font-family:'DM Mono',monospace;}
.lm-warn{font-size:.71rem;color:var(--muted);display:flex;align-items:flex-start;gap:.38rem;line-height:1.4;background:rgba(232,70,10,.06);border:1px solid rgba(232,70,10,.12);border-radius:7px;padding:.48rem .62rem;margin-top:.12rem;}
.lm-close{position:absolute;top:.95rem;right:.95rem;background:none;border:none;color:var(--muted);cursor:pointer;font-size:.95rem;padding:.2rem .32rem;border-radius:6px;transition:all .15s;line-height:1;}
.lm-close:hover{background:var(--surface2);color:var(--text);}

/* Settings / FAQ modals - legacy (kept for FAQ + onboarding) */
.settings-modal{background:var(--surface);border:1px solid var(--border2);border-radius:18px;width:min(520px,94vw);max-height:85vh;overflow-y:auto;position:relative;box-shadow:0 40px 120px rgba(0,0,0,.9);animation:slideUp .25s cubic-bezier(.4,0,.2,1);}
.settings-modal::before{content:'';position:absolute;top:0;left:0;right:0;height:3px;background:linear-gradient(90deg,var(--purple),var(--green));border-radius:18px 18px 0 0;}
.sm-hd{padding:1.35rem 1.35rem .5rem;display:flex;align-items:center;justify-content:space-between;}
.sm-title{font-family:var(--font-display);font-weight:800;font-size:1.08rem;}
.sm-body{padding:.5rem 1.35rem 1.35rem;}
.sm-section{margin-bottom:1.2rem;}
.sm-sec-title{font-family:'DM Mono',monospace;font-size:.68rem;text-transform:uppercase;letter-spacing:.1em;color:var(--muted);margin-bottom:.55rem;}
.sm-row{display:flex;align-items:center;justify-content:space-between;padding:.62rem .8rem;border-radius:9px;background:var(--surface2);border:1px solid var(--border);margin-bottom:.38rem;}
.sm-row-label{font-size:.83rem;font-weight:500;}
.sm-row-desc{font-size:.72rem;color:var(--muted);margin-top:.05rem;}
.toggle{width:38px;height:20px;border-radius:10px;background:var(--border2);cursor:pointer;position:relative;transition:background .2s;flex-shrink:0;}
.toggle.on{background:var(--accent);}
.toggle::after{content:'';position:absolute;top:3px;left:3px;width:14px;height:14px;border-radius:50%;background:#fff;transition:transform .2s;}
.toggle.on::after{transform:translateX(18px);}
.relay-tag{display:inline-flex;align-items:center;gap:.35rem;background:var(--surface3);border:1px solid var(--border2);border-radius:6px;padding:.3rem .6rem;font-family:'DM Mono',monospace;font-size:.72rem;margin:.2rem .2rem 0 0;}
.relay-tag .rem{background:none;border:none;color:var(--muted);cursor:pointer;font-size:.7rem;padding:0;line-height:1;}
.relay-tag .rem:hover{color:var(--live);}
.relay-add-row{display:flex;gap:.5rem;margin-top:.5rem;}
.relay-add-row input{flex:1;font-family:'DM Mono',monospace;font-size:.75rem;}
.sm-save-row{display:flex;justify-content:flex-end;padding-top:.2rem;}
#settingsRelayList{display:flex;flex-wrap:wrap;}
#settingsRelayList .relay-tag{margin-bottom:.35rem;}

/* ======== SETTINGS MODAL V2 ======== */
.settings-modal-v2{
  background:var(--surface);border:1px solid var(--border2);
  border-radius:18px;width:min(1040px,97vw);max-height:92vh;
  position:relative;box-shadow:0 40px 120px rgba(0,0,0,.9);
  animation:slideUp .25s cubic-bezier(.4,0,.2,1);
  display:flex;flex-direction:column;overflow:hidden;
}
.settings-modal-v2::before{
  content:'';position:absolute;top:0;left:0;right:0;height:3px;
  background:linear-gradient(90deg,var(--purple),var(--accent),var(--zap));
  border-radius:18px 18px 0 0;z-index:1;
}
.smv2-hd{
  padding:1.2rem 1.35rem .9rem;
  display:flex;align-items:center;justify-content:space-between;
  border-bottom:1px solid var(--border);flex-shrink:0;
}
.smv2-title{font-family:var(--font-display);font-weight:800;font-size:1.1rem;display:flex;align-items:center;gap:.5rem;}
.smv2-tabs{
  display:flex;gap:.25rem;padding:.65rem 1.1rem .55rem;
  flex-wrap:wrap;
  border-bottom:1px solid var(--border);flex-shrink:0;background:var(--surface);
}
.smv2-tab{
  display:flex;align-items:center;gap:.42rem;padding:.46rem 1rem;border-radius:9px;
  font-size:.8rem;font-weight:600;font-family:'DM Sans',sans-serif;
  cursor:pointer;border:1px solid transparent;color:var(--text2);background:transparent;
  transition:all .15s;white-space:nowrap;
}
.smv2-tab:hover{background:var(--surface2);color:var(--text);}
.smv2-tab.active{background:var(--surface2);border-color:var(--border2);color:var(--text);}
.smv2-tab.active.tab-profile{border-color:rgba(155,114,255,.35);color:var(--purple);}
.smv2-tab.active.tab-wallet{border-color:rgba(247,147,26,.35);color:var(--zap);}
.smv2-tab.active.tab-relays{border-color:rgba(0,212,138,.35);color:var(--green);}
.smv2-tab.active.tab-app{border-color:rgba(232,70,10,.35);color:var(--accent);}
.smv2-panel{display:none;padding:1.2rem 1.35rem 1.4rem;overflow-y:auto;flex:1;}
.smv2-panel.active{display:block;}
.smv2-panel-label{
  font-family:'DM Mono',monospace;font-size:.65rem;color:var(--muted);
  background:var(--surface2);border:1px solid var(--border);border-radius:7px;
  padding:.38rem .72rem;margin-bottom:1.1rem;display:flex;align-items:center;gap:.4rem;
}
.smv2-avatar-row{display:flex;align-items:flex-start;gap:1rem;margin-bottom:.95rem;}
.smv2-avatar-preview{
  width:80px;height:80px;border-radius:50%;
  background:linear-gradient(135deg,var(--accent),var(--zap));
  border:2px solid var(--border2);overflow:hidden;
  display:flex;align-items:center;justify-content:center;
  font-size:1.7rem;color:#fff;font-family:var(--font-display);font-weight:800;
  flex-shrink:0;transition:border-color .2s;
}
.smv2-avatar-preview img{width:100%;height:100%;object-fit:cover;display:block;}
.smv2-avatar-fields{flex:1;display:flex;flex-direction:column;gap:.55rem;}
.smv2-field-row{display:grid;grid-template-columns:1fr 1fr;gap:.65rem;margin-top:.65rem;}
.smv2-field-hint{font-family:'DM Mono',monospace;font-size:.62rem;color:var(--muted);margin-top:.22rem;}
.smv2-save-row{display:flex;justify-content:flex-end;padding-top:1rem;margin-top:.5rem;border-top:1px solid var(--border);}
.smv2-section{margin-bottom:1.25rem;}
.smv2-section-title{
  font-family:'DM Mono',monospace;font-size:.66rem;text-transform:uppercase;
  letter-spacing:.1em;color:var(--muted);margin-bottom:.55rem;
  padding-bottom:.35rem;border-bottom:1px solid var(--border);
}
.wallet-connect-card{
  border:1px solid var(--border2);
  border-radius:14px;
  background:var(--surface2);
  padding:.95rem;
}
.wallet-connect-head{
  display:flex;
  align-items:flex-start;
  justify-content:space-between;
  gap:.85rem;
  margin-bottom:.8rem;
}
.wallet-connect-title{
  margin-bottom:.32rem;
  border-bottom:none;
  padding-bottom:0;
}
.wallet-state-chip{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  min-height:32px;
  padding:.34rem .68rem;
  border-radius:999px;
  border:1px solid var(--border2);
  background:rgba(255,255,255,.04);
  color:var(--text2);
  font-family:'DM Mono',monospace;
  font-size:.66rem;
  letter-spacing:.04em;
  white-space:nowrap;
}
.wallet-state-chip.saved{
  border-color:rgba(155,114,255,.32);
  color:var(--purple);
  background:rgba(155,114,255,.08);
}
.wallet-state-chip.connected{
  border-color:rgba(0,212,138,.34);
  color:var(--green);
  background:rgba(0,212,138,.1);
}
.wallet-state-chip.disconnected{
  border-color:var(--border2);
  color:var(--muted);
  background:rgba(255,255,255,.03);
}
.wallet-connect-field textarea{
  min-height:108px;
  resize:vertical;
  font-family:'DM Mono',monospace;
  font-size:.73rem;
  line-height:1.5;
}
.wallet-connect-actions{
  display:flex;
  gap:.55rem;
  flex-wrap:wrap;
  margin-top:.78rem;
}
.wallet-connect-actions .btn{
  justify-content:center;
}
.wallet-scanner-wrap{
  display:none;
  margin-top:.82rem;
  border:1px solid var(--border2);
  border-radius:12px;
  overflow:hidden;
  background:#05080d;
}
.wallet-scanner-wrap.open{display:block;}
.wallet-scanner-video{
  display:block;
  width:100%;
  max-height:320px;
  min-height:220px;
  background:#000;
  object-fit:cover;
}
.wallet-scanner-hint{
  padding:.58rem .72rem;
  border-top:1px solid rgba(255,255,255,.06);
  font-size:.68rem;
  color:var(--text2);
  background:rgba(255,255,255,.03);
}
.wallet-summary-card{
  display:none;
  margin-top:.82rem;
  border:1px solid var(--border);
  border-radius:12px;
  background:rgba(255,255,255,.03);
  padding:.8rem .85rem;
}
.wallet-summary-card.open{display:block;}
.wallet-summary-grid{
  display:grid;
  grid-template-columns:repeat(2,minmax(0,1fr));
  gap:.62rem;
}
.wallet-summary-item{
  min-width:0;
  display:flex;
  flex-direction:column;
  gap:.18rem;
}
.wallet-summary-label{
  font-family:'DM Mono',monospace;
  font-size:.61rem;
  color:var(--muted);
  text-transform:uppercase;
  letter-spacing:.08em;
}
.wallet-summary-value{
  min-width:0;
  color:var(--text);
  font-size:.79rem;
  line-height:1.4;
  word-break:break-word;
}
.wallet-summary-value.mono{
  font-family:'DM Mono',monospace;
  font-size:.7rem;
}
.wallet-summary-note{
  margin-top:.72rem;
  padding-top:.68rem;
  border-top:1px solid rgba(255,255,255,.07);
  font-size:.69rem;
  color:var(--text2);
  line-height:1.5;
}
.wallet-connect-card .remote-login-status{
  margin-top:.82rem;
}
.relay-directory-toolbar{
  display:grid;
  grid-template-columns:minmax(0,1.2fr) minmax(240px,.8fr);
  gap:.75rem;
  align-items:stretch;
  margin-bottom:.85rem;
}
.relay-directory-copy{
  border:1px solid var(--border);
  background:var(--surface2);
  border-radius:12px;
  padding:.8rem .9rem;
  color:var(--text2);
  font-size:.76rem;
  line-height:1.55;
}
.relay-bar-settings{
  margin-top:0;
  min-height:100%;
  justify-content:center;
}
.relay-directory-summary{
  display:grid;
  grid-template-columns:repeat(4,minmax(0,1fr));
  gap:.65rem;
  margin-bottom:.85rem;
}
.relay-summary-card{
  border:1px solid var(--border);
  border-radius:12px;
  padding:.72rem .8rem;
  background:var(--surface2);
  min-width:0;
}
.relay-summary-card.pending{border-color:rgba(79,140,255,.22);}
.relay-summary-card.connected{border-color:rgba(34,197,94,.22);}
.relay-summary-card.trusted{border-color:rgba(20,184,166,.22);}
.relay-summary-card.blocked{border-color:rgba(220,38,38,.22);}
.relay-summary-label{
  font-family:'DM Mono',monospace;
  font-size:.6rem;
  color:var(--muted);
  text-transform:uppercase;
  letter-spacing:.08em;
  margin-bottom:.22rem;
}
.relay-summary-value{
  font-family:'DM Sans',sans-serif;
  font-size:1rem;
  font-weight:700;
  color:var(--text);
}
.relay-directory-actions{
  display:flex;
  align-items:flex-start;
  justify-content:space-between;
  gap:.85rem;
  margin-bottom:.92rem;
}
.relay-directory-help{
  flex:1;
  color:var(--muted);
  font-size:.68rem;
  line-height:1.5;
}
.relay-add-launch{
  min-height:40px;
  padding:0 .95rem;
  white-space:nowrap;
}
.relay-add-modal-ov{
  z-index:1105;
}
.relay-add-modal{
  width:min(560px,94vw);
}
.relay-add-modal-body{
  gap:.82rem;
}
.relay-add-modal-body input,
.relay-add-modal-body select{
  width:100%;
  min-height:42px;
  background:var(--surface2);
  border:1px solid var(--border2);
  border-radius:10px;
  padding:0 .78rem;
  color:var(--text);
  font-size:.76rem;
  outline:none;
}
.relay-add-modal-body input{
  font-family:'DM Mono',monospace;
}
.relay-add-modal-body input:focus,
.relay-add-modal-body select:focus{
  border-color:var(--accent);
}
.relay-add-modal-foot{
  display:flex;
  justify-content:flex-end;
  gap:.5rem;
}
.relay-add-modal .remote-login-status{
  margin-top:-.08rem;
}
#settingsRelayList2{
  display:block;
  margin-bottom:.2rem;
}
.relay-bucket-grid{
  display:grid;
  grid-template-columns:repeat(3,minmax(0,1fr));
  gap:1rem;
}
.relay-bucket-card{
  border:1px solid var(--border);
  border-radius:16px;
  background:
    linear-gradient(180deg, rgba(255,255,255,.03), rgba(255,255,255,.01)),
    linear-gradient(135deg, color-mix(in srgb, var(--relay-bucket-a) 14%, transparent), color-mix(in srgb, var(--relay-bucket-b) 10%, transparent));
  overflow:hidden;
}
.relay-bucket-head{
  display:flex;
  gap:.8rem;
  justify-content:space-between;
  align-items:flex-start;
  padding:.9rem .95rem .8rem;
  border-bottom:1px solid rgba(255,255,255,.06);
}
.relay-bucket-title{
  font-family:'DM Sans',sans-serif;
  font-size:.9rem;
  font-weight:700;
  color:var(--text);
}
.relay-bucket-desc{
  margin-top:.24rem;
  color:var(--text2);
  font-size:.7rem;
  line-height:1.5;
}
.relay-bucket-count{
  min-width:34px;
  height:34px;
  border-radius:999px;
  display:flex;
  align-items:center;
  justify-content:center;
  background:rgba(255,255,255,.05);
  border:1px solid rgba(255,255,255,.08);
  color:var(--text);
  font-family:'DM Mono',monospace;
  font-size:.72rem;
}
.relay-bucket-list{
  display:flex;
  flex-direction:column;
  gap:.65rem;
  padding:.9rem .95rem .95rem;
}
.relay-bucket-empty{
  border:1px dashed var(--border2);
  border-radius:12px;
  padding:.9rem;
  color:var(--muted);
  font-size:.72rem;
  background:rgba(255,255,255,.02);
}
.relay-setting-row{
  display:grid;
  grid-template-columns:auto minmax(0,1fr) auto;
  gap:.72rem;
  align-items:flex-start;
  border:1px solid var(--border2);
  border-radius:14px;
  padding:.7rem;
  background:rgba(255,255,255,.03);
}
.relay-setting-avatar{
  width:56px;
  height:56px;
  border-radius:50%;
  display:flex;
  align-items:center;
  justify-content:center;
  position:relative;
  overflow:hidden;
  font-family:'DM Mono',monospace;
  font-size:.88rem;
  font-weight:700;
  color:#fff;
  background:linear-gradient(135deg, var(--relay-avatar-a), var(--relay-avatar-b));
  border:2px solid rgba(255,255,255,.14);
  box-shadow:0 10px 24px rgba(0,0,0,.22), inset 0 1px 0 rgba(255,255,255,.18);
}
.relay-setting-avatar img{
  width:100%;
  height:100%;
  object-fit:cover;
  display:block;
}
.relay-setting-avatar-text{
  position:absolute;
  inset:0;
  display:none;
  align-items:center;
  justify-content:center;
  text-shadow:0 1px 8px rgba(0,0,0,.28);
}
.relay-setting-avatar.fallback .relay-setting-avatar-text{
  display:flex;
}
.relay-setting-main{
  min-width:0;
}
.relay-setting-head{
  display:flex;
  flex-direction:column;
  gap:.3rem;
  align-items:flex-start;
}
.relay-setting-host{
  color:var(--text);
  font-size:.86rem;
  font-weight:700;
  word-break:break-word;
}
.relay-setting-status-row{
  display:flex;
  flex-wrap:wrap;
  gap:.38rem .48rem;
  align-items:center;
}
.relay-setting-state{
  flex-shrink:0;
  border-radius:999px;
  padding:.18rem .48rem;
  font-family:'DM Mono',monospace;
  font-size:.58rem;
  letter-spacing:.04em;
  border:1px solid var(--border2);
  background:rgba(255,255,255,.05);
  color:var(--text2);
}
.relay-setting-state.connected{border-color:rgba(34,197,94,.3);color:var(--green);background:rgba(34,197,94,.08);}
.relay-setting-state.pending{border-color:rgba(79,140,255,.28);color:#7fb1ff;background:rgba(79,140,255,.08);}
.relay-setting-state.blocked{border-color:rgba(220,38,38,.28);color:#f87171;background:rgba(220,38,38,.08);}
.relay-setting-state.configured{border-color:rgba(148,163,184,.22);color:var(--text2);}
.relay-setting-state.saved{border-color:rgba(148,163,184,.18);color:var(--muted);}
.relay-setting-url{
  margin-top:.22rem;
  color:var(--muted);
  font-family:'DM Mono',monospace;
  font-size:.69rem;
  line-height:1.45;
  word-break:break-all;
}
.relay-setting-foot{
  display:flex;
  flex-wrap:wrap;
  gap:.45rem;
  align-items:center;
  justify-content:flex-start;
  margin-top:.45rem;
}
.relay-setting-detail{
  color:var(--text2);
  font-size:.67rem;
}
.relay-setting-chips{
  display:flex;
  flex-wrap:wrap;
  gap:.35rem;
  justify-content:flex-start;
}
.relay-role-chip{
  border-radius:999px;
  border:1px solid rgba(255,255,255,.08);
  background:rgba(255,255,255,.04);
  color:var(--text2);
  padding:.14rem .45rem;
  font-family:'DM Mono',monospace;
  font-size:.56rem;
  letter-spacing:.03em;
}
.relay-role-chip.current{
  border-color:rgba(79,140,255,.28);
  color:#8bb6ff;
}
.relay-setting-action{
  border:none;
  border-radius:10px;
  background:rgba(255,255,255,.06);
  color:var(--text);
  min-height:36px;
  padding:0 .78rem;
  cursor:pointer;
  font-size:.7rem;
  font-weight:600;
}
.relay-setting-action:hover{
  background:rgba(255,255,255,.1);
}

@media (max-width:1080px){
  .relay-bucket-grid{
    grid-template-columns:repeat(2,minmax(0,1fr));
  }
}

@media (max-width:760px){
  .settings-modal-v2{
    width:min(96vw,96vw);
    max-height:92vh;
  }
  .smv2-tabs{
    padding:.58rem .9rem .5rem;
    gap:.38rem;
  }
  .smv2-tab{
    flex:1 1 calc(50% - .38rem);
    justify-content:center;
  }
  .smv2-panel{
    padding:1rem .95rem 1.1rem;
  }
  .smv2-avatar-row{
    flex-direction:column;
  }
  .smv2-field-row,
  .wallet-summary-grid{
    grid-template-columns:1fr;
  }
  .relay-directory-toolbar,
  .relay-directory-summary,
  .relay-bucket-grid{
    grid-template-columns:1fr;
  }
  .relay-directory-actions{
    flex-direction:column;
    align-items:stretch;
  }
  .relay-add-launch,
  .relay-add-modal-foot .btn{
    width:100%;
  }
  .relay-add-modal-foot{
    flex-direction:column;
  }
  .relay-setting-row{
    grid-template-columns:auto minmax(0,1fr);
  }
  .relay-setting-action{
    grid-column:1 / -1;
    width:100%;
  }
  .wallet-connect-head{
    flex-direction:column;
    align-items:flex-start;
  }
  .wallet-connect-actions{
    flex-direction:column;
  }
  .wallet-connect-actions .btn{
    width:100%;
  }
  .wallet-scanner-video{
    min-height:200px;
  }
}

/* ======== ALL BADGES POPUP ======== */
.all-badges-popup-ov{
  position:fixed;inset:0;z-index:2100;display:none;align-items:center;justify-content:center;
  background:rgba(5,8,12,.87);backdrop-filter:blur(16px) saturate(.55);
}
.all-badges-popup-ov.open{display:flex;animation:fadeIn .18s ease;}
.all-badges-popup{
  background:var(--surface);border:1px solid var(--border2);border-radius:18px;
  width:min(480px,94vw);max-height:80vh;position:relative;
  box-shadow:0 40px 120px rgba(0,0,0,.9);animation:slideUp .22s cubic-bezier(.4,0,.2,1);
  display:flex;flex-direction:column;overflow:hidden;
}
.all-badges-popup::before{content:'';position:absolute;top:0;left:0;right:0;height:3px;background:linear-gradient(90deg,var(--purple),var(--accent));border-radius:18px 18px 0 0;}
.abp-hd{padding:1rem 1.2rem .8rem;display:flex;align-items:center;justify-content:space-between;border-bottom:1px solid var(--border);flex-shrink:0;}
.abp-title{font-family:var(--font-display);font-weight:800;font-size:.95rem;display:flex;align-items:center;gap:.4rem;}
.abp-body{padding:1rem 1.2rem 1.2rem;overflow-y:auto;}
.abp-grid{display:grid;grid-template-columns:repeat(4,1fr);gap:.55rem;}
.badge-see-more{
  display:flex;align-items:center;justify-content:center;
  width:42px;height:42px;border-radius:8px;
  background:rgba(155,114,255,.1);border:1px dashed rgba(155,114,255,.4);
  font-size:.62rem;font-family:'DM Mono',monospace;color:var(--purple);
  cursor:pointer;transition:all .15s;text-align:center;line-height:1.2;
}
.badge-see-more:hover{background:rgba(155,114,255,.2);border-color:rgba(155,114,255,.7);box-shadow:0 0 10px rgba(155,114,255,.3);}

/* ======== POST BOOST/REPOST BANNER ======== */
.pf-boost-banner{
  display:flex;align-items:center;gap:.4rem;font-size:.72rem;color:var(--text2);
  padding:.74rem .8rem .46rem;background:rgba(155,114,255,.08);
  border-bottom:1px solid rgba(155,114,255,.16);border-radius:10px 10px 0 0;margin:-.72rem -.75rem .62rem;
}
.pf-boost-av{width:26px;height:26px;border-radius:50%;border:1px solid rgba(155,114,255,.35);background:var(--surface3);display:flex;align-items:center;justify-content:center;font-size:.66rem;overflow:hidden;flex-shrink:0;margin-top:3px;}
.pf-boost-av.nip05-square{
  border-radius:6px;
  border:1.5px solid rgba(155,114,255,.7);
  background:rgba(155,114,255,.13);
  box-shadow:0 0 7px rgba(155,114,255,.5),0 0 14px rgba(155,114,255,.22);
  animation:nip05Pulse 2.8s ease-in-out infinite;
}
.pf-boost-label{font-family:'DM Mono',monospace;font-size:.65rem;color:var(--purple);display:flex;gap:.26rem;align-items:center;}
.pf-boost-name{color:#c9afff;font-weight:700;}
.profile-feed-item:has(.pf-boost-banner){border-color:rgba(155,114,255,.22);padding-top:0;overflow:hidden;}
/* ======== NIP-05 VERIFIED = PURPLE GLOWING SQUARE ======== */
.nav-avatar.nip05-square{
  border-radius:8px;border:2px solid rgba(155,114,255,.7);
  box-shadow:0 0 10px rgba(155,114,255,.55),0 0 22px rgba(155,114,255,.25),inset 0 0 8px rgba(155,114,255,.1);
  animation:nip05Pulse 2.8s ease-in-out infinite;
}
.pd-av-lg.nip05-square{
  border-radius:8px;border:2px solid rgba(155,114,255,.7);
  box-shadow:0 0 10px rgba(155,114,255,.55),0 0 22px rgba(155,114,255,.25);
  animation:nip05Pulse 2.8s ease-in-out infinite;
}
.profile-feed-av.nip05-square{
  border-radius:7px;border:1.5px solid rgba(155,114,255,.7);
  box-shadow:0 0 8px rgba(155,114,255,.5),0 0 16px rgba(155,114,255,.2);
  animation:nip05Pulse 2.8s ease-in-out infinite;
}
.profile-comment-av.nip05-square{
  border-radius:6px;border:1.5px solid rgba(155,114,255,.7);
  box-shadow:0 0 7px rgba(155,114,255,.5),0 0 14px rgba(155,114,255,.2);
  animation:nip05Pulse 2.8s ease-in-out infinite;
}
.sib-av.nip05-square{
  border-radius:9px;border:2px solid rgba(155,114,255,.7);
  box-shadow:0 0 10px rgba(155,114,255,.55),0 0 20px rgba(155,114,255,.25);
  animation:nip05Pulse 2.8s ease-in-out infinite;
}

body.hide-nip05 .nip05-badge,
body.hide-nip05 .c-nip05{display:none!important;}
body.hide-zap-notices .zap-ev{display:none!important;}
body.compact-chat .cmsg{padding:.38rem .46rem;}
body.no-chat-anim .cmsg{animation:none!important;}
.faq-item{border:1px solid var(--border);border-radius:9px;overflow:hidden;margin-bottom:.4rem;}
.faq-q{display:flex;align-items:center;justify-content:space-between;padding:.7rem .85rem;cursor:pointer;font-size:.83rem;font-weight:500;transition:background .12s;}
.faq-q:hover{background:var(--surface2);}
.faq-chevron{transition:transform .2s;color:var(--muted);font-size:.75rem;}
.faq-a{font-size:.79rem;color:var(--text2);line-height:1.6;padding:0 .85rem;max-height:0;overflow:hidden;transition:max-height .25s ease,padding .25s;}
.faq-item.open .faq-a{max-height:200px;padding:.1rem .85rem .75rem;}
.faq-item.open .faq-chevron{transform:rotate(180deg);}

/* End confirm */
.end-confirm-modal{background:var(--surface);border:1px solid rgba(255,59,92,.3);border-radius:16px;width:min(340px,94vw);padding:1.5rem;text-align:center;animation:slideUp .2s ease;position:relative;}
.end-confirm-modal::before{content:'';position:absolute;top:0;left:0;right:0;height:3px;background:var(--live);border-radius:16px 16px 0 0;}
.share-modal{width:min(520px,94vw);}
.share-modal-body{padding:.95rem 1rem 1rem;display:flex;flex-direction:column;gap:.75rem;}
.share-field{display:flex;flex-direction:column;gap:.28rem;}
.share-field label{font-family:'DM Mono',monospace;font-size:.64rem;color:var(--muted);letter-spacing:.08em;text-transform:uppercase;}
.share-copy-row{display:flex;gap:.45rem;}
.share-copy-row input{flex:1;background:var(--surface2);border:1px solid var(--border2);border-radius:8px;padding:.42rem .55rem;color:var(--text);font-size:.74rem;font-family:'DM Mono',monospace;outline:none;}
.share-copy-row input:focus{border-color:var(--accent);}
.share-choice-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:.45rem;}
.share-choice-btn{background:var(--surface2);border:1px solid var(--border2);border-radius:10px;padding:.58rem .42rem;cursor:pointer;display:flex;flex-direction:column;align-items:center;gap:.24rem;color:var(--text);font-size:.72rem;font-weight:600;}
.share-choice-btn:hover{border-color:var(--accent);}
.share-choice-btn .sub{font-size:.62rem;color:var(--text2);font-weight:400;}
.reaction-picker-grid{display:grid;grid-template-columns:repeat(6,minmax(0,1fr));gap:.4rem;}
.compose-upload-modal{width:min(560px,94vw);}
.compose-upload-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:.56rem;margin-bottom:.55rem;}
.compose-upload-status{min-height:20px;font-family:'DM Mono',monospace;font-size:.68rem;color:var(--text2);border:1px solid var(--border);border-radius:8px;background:var(--surface2);padding:.4rem .5rem;}
.gif-picker-modal{width:min(760px,96vw);max-height:min(88vh,820px);}
.gif-picker-controls{display:flex;align-items:center;gap:.5rem;}
.gif-picker-search{flex:1;background:var(--surface2);border:1px solid var(--border2);border-radius:9px;padding:.48rem .62rem;color:var(--text);font-size:.78rem;font-family:'DM Sans',sans-serif;outline:none;}
.gif-picker-search:focus{border-color:var(--accent);}
.gif-picker-status{min-height:20px;font-family:'DM Mono',monospace;font-size:.68rem;color:var(--text2);border:1px solid var(--border);border-radius:8px;background:var(--surface2);padding:.4rem .5rem;}
.gif-picker-results{display:grid;grid-template-columns:repeat(auto-fill,minmax(140px,1fr));gap:.55rem;max-height:min(58vh,520px);overflow:auto;padding-right:.15rem;}
.gif-picker-item{background:var(--surface2);border:1px solid var(--border2);border-radius:10px;cursor:pointer;overflow:hidden;padding:0;display:flex;align-items:center;justify-content:center;min-height:110px;position:relative;}
.gif-picker-item:hover{border-color:var(--accent);}
.gif-picker-item img{display:block;width:100%;height:100%;object-fit:cover;aspect-ratio:1/1;}
.gif-picker-empty{grid-column:1/-1;border:1px dashed var(--border2);border-radius:10px;padding:.75rem .8rem;text-align:center;font-size:.73rem;color:var(--text2);background:var(--surface2);}
.gif-picker-foot{display:flex;justify-content:center;}
@media (max-width: 680px){
  .compose-upload-grid{grid-template-columns:1fr;}
  .gif-picker-controls{flex-wrap:wrap;}
  .gif-picker-search{width:100%;}
  .gif-picker-results{grid-template-columns:repeat(2,minmax(0,1fr));max-height:min(56vh,460px);}
}
@media (max-width: 680px){
}
.reaction-opt-btn{background:var(--surface2);border:1px solid var(--border2);border-radius:8px;padding:.45rem .2rem;cursor:pointer;color:var(--text);font-size:.88rem;display:flex;align-items:center;justify-content:center;min-height:34px;}
.reaction-opt-btn img{width:18px;height:18px;object-fit:contain;display:block;}
.reaction-opt-btn:hover{border-color:var(--accent);}
.reaction-custom-row{display:flex;flex-direction:column;gap:.42rem;}
.reaction-custom-row input{background:var(--surface2);border:1px solid var(--border2);border-radius:8px;padding:.42rem .55rem;color:var(--text);font-size:.74rem;font-family:'DM Mono',monospace;outline:none;}
.reaction-custom-row input:focus{border-color:var(--accent);}
.reaction-picker-foot{display:flex;justify-content:flex-end;gap:.5rem;}

/* ======== ONBOARDING MODAL ======== */
.onboard-modal{width:min(580px,96vw);max-height:92vh;overflow-y:auto;padding:1.4rem 1.5rem 1.5rem;}
.onboard-step{display:none;}
.onboard-step.active{display:block;}

/* Step progress bar */
.onboard-steps-bar{display:flex;align-items:center;gap:0;margin-bottom:1.3rem;}
.onboard-step-dot{
  width:28px;height:28px;border-radius:50%;flex-shrink:0;
  background:var(--surface3);border:2px solid var(--border2);
  display:flex;align-items:center;justify-content:center;
  font-size:.7rem;font-weight:700;color:var(--muted);
  font-family:'DM Mono',monospace;transition:all .25s;
}
.onboard-step-dot::after{content:attr(data-n);}
.onboard-step-dot.active{background:var(--green);border-color:var(--green);color:#000;}
.onboard-step-dot.done{background:rgba(0,212,138,.2);border-color:var(--green);color:var(--green);}
.onboard-step-line{flex:1;height:2px;background:var(--border2);margin:0 .5rem;transition:background .25s;}
.onboard-step-line.done{background:var(--green);}

/* Key hero block */
.onboard-key-hero{
  background:linear-gradient(135deg,rgba(0,212,138,.05),rgba(155,114,255,.03));
  border:1px solid rgba(0,212,138,.18);
  border-radius:12px;padding:1rem 1rem .9rem;margin-bottom:1rem;
}
.onboard-key-label{
  font-family:'DM Mono',monospace;font-size:.61rem;text-transform:uppercase;
  letter-spacing:.12em;color:var(--green);margin-bottom:.55rem;
  display:flex;align-items:center;gap:.4rem;
}
.onboard-key-label::before{content:'';width:6px;height:6px;border-radius:50%;background:var(--green);flex-shrink:0;}
.onboard-nsec-row{
  display:flex;align-items:center;gap:.55rem;
  background:rgba(0,0,0,.4);border:1px solid rgba(255,255,255,.07);
  border-radius:9px;padding:.55rem .7rem;
}
.onboard-nsec-text{
  flex:1;font-family:'DM Mono',monospace;font-size:.72rem;
  color:var(--text);word-break:break-all;line-height:1.5;
  filter:blur(5px);transition:filter .3s;user-select:all;cursor:pointer;
}
.onboard-nsec-text.revealed{filter:none;}
.onboard-nsec-actions{display:flex;flex-direction:column;gap:.35rem;flex-shrink:0;}
.onboard-reveal-btn,.onboard-copy-btn{
  padding:.28rem .65rem;border-radius:7px;font-size:.7rem;font-weight:600;
  cursor:pointer;font-family:'DM Sans',sans-serif;white-space:nowrap;
  transition:all .15s;border:1px solid rgba(0,212,138,.3);color:var(--green);
}
.onboard-reveal-btn{background:transparent;}
.onboard-reveal-btn:hover{background:rgba(0,212,138,.1);}
.onboard-copy-btn{background:rgba(0,212,138,.1);}
.onboard-copy-btn:hover{background:rgba(0,212,138,.22);}
.onboard-copy-btn.copied{background:rgba(0,212,138,.25);border-color:var(--green);color:#00e89a;}

.onboard-warn-box{
  background:rgba(232,70,10,.05);border:1px solid rgba(232,70,10,.16);
  border-radius:8px;padding:.6rem .75rem;margin-top:.8rem;
  font-size:.76rem;color:var(--text2);line-height:1.55;
}
.onboard-warn-box strong{color:#ff7c5c;}

.onboard-confirm-row{
  display:flex;align-items:flex-start;gap:.6rem;margin-top:.9rem;
  padding:.65rem .75rem;border-radius:9px;
  border:1px solid var(--border);background:var(--surface2);
  cursor:pointer;transition:border-color .2s;
}
.onboard-confirm-row:has(.onboard-checkbox:checked){border-color:var(--green);background:rgba(0,212,138,.04);}
.onboard-checkbox{
  width:15px;height:15px;flex-shrink:0;margin-top:.15rem;
  accent-color:var(--green);cursor:pointer;
}
.onboard-confirm-label{font-size:.79rem;color:var(--text2);line-height:1.5;cursor:pointer;user-select:none;}

.onboard-continue-btn{
  width:100%;margin-top:.9rem;padding:.65rem 1rem;border-radius:9px;
  font-size:.84rem;font-weight:700;font-family:var(--font-display);letter-spacing:.01em;
  background:var(--green);color:#000;border:none;cursor:pointer;
  transition:all .2s;opacity:.35;pointer-events:none;
}
.onboard-continue-btn.ready{opacity:1;pointer-events:all;}
.onboard-continue-btn.ready:hover{background:#00e89a;box-shadow:0 0 22px rgba(0,212,138,.4);}

/* Profile step */
.onboard-avatar-preview-row{display:flex;align-items:flex-start;gap:.9rem;margin-bottom:.9rem;}
.onboard-avatar-circle{
  width:72px;height:72px;border-radius:50%;flex-shrink:0;
  background:linear-gradient(135deg,var(--accent),var(--zap));
  border:2px solid var(--border2);overflow:hidden;
  display:flex;align-items:center;justify-content:center;
  font-size:1.5rem;color:#fff;font-family:var(--font-display);font-weight:800;
  transition:border-color .2s;
}
.onboard-avatar-circle img{width:100%;height:100%;object-fit:cover;display:block;}
.onboard-avatar-fields{flex:1;display:flex;flex-direction:column;gap:.5rem;}
.onboard-form-grid{display:grid;grid-template-columns:1fr 1fr;gap:.6rem;margin-bottom:.3rem;}
.onboard-form-grid .fg.full{grid-column:1/-1;}
.onboard-field-hint{font-size:.63rem;color:var(--muted);margin-top:.18rem;font-family:'DM Mono',monospace;}
.onboard-footer-row{
  display:flex;gap:.5rem;justify-content:flex-end;align-items:center;
  padding-top:1rem;border-top:1px solid var(--border);margin-top:1rem;
}
.onboard-footer-row .btn-ghost:first-child{margin-right:auto;}
.sec-hd-left{display:flex;align-items:center;gap:.55rem;flex:1;min-width:0;}
.list-filter-wrap{position:relative;flex-shrink:0;}
.list-filter-btn{
  display:inline-flex;align-items:center;gap:.38rem;
  padding:.26rem .6rem .26rem .72rem;
  border-radius:8px;border:1px solid var(--border2);
  background:var(--surface2);color:var(--text2);
  font-size:.74rem;font-weight:600;cursor:pointer;
  font-family:'DM Sans',sans-serif;
  transition:all .15s;white-space:nowrap;max-width:180px;
}
.list-filter-btn:hover{border-color:var(--accent);color:var(--text);}
.list-filter-btn.open{border-color:var(--purple);color:var(--purple);background:rgba(155,114,255,.06);}
.list-filter-btn-label{overflow:hidden;text-overflow:ellipsis;white-space:nowrap;max-width:120px;}
.list-filter-caret{flex-shrink:0;font-size:.6rem;opacity:.7;transition:transform .2s;}
.list-filter-btn.open .list-filter-caret{transform:rotate(180deg);}
.list-filter-dd{
  position:absolute;top:calc(100% + 5px);left:0;
  min-width:220px;max-width:300px;
  background:var(--surface);border:1px solid var(--border2);
  border-radius:12px;padding:.45rem;
  box-shadow:0 20px 60px rgba(0,0,0,.8),0 0 0 1px rgba(255,255,255,.03);
  z-index:400;opacity:0;pointer-events:none;
  transform:translateY(-5px);transition:opacity .15s,transform .15s;
}
.list-filter-dd.open{opacity:1;pointer-events:all;transform:translateY(0);}
.lf-section-label{
  font-family:'DM Mono',monospace;font-size:.6rem;
  text-transform:uppercase;letter-spacing:.1em;
  color:var(--muted);padding:.18rem .6rem .28rem;display:block;
}
.lf-item{
  display:flex;align-items:center;gap:.6rem;
  padding:.46rem .65rem;border-radius:8px;
  font-size:.8rem;color:var(--text2);cursor:pointer;
  transition:background .1s;border:none;background:none;
  width:100%;text-align:left;font-family:'DM Sans',sans-serif;
}
.lf-item:hover{background:var(--surface2);color:var(--text);}
.lf-item.active{color:var(--purple);background:rgba(155,114,255,.08);}
.lf-item.active .lf-dot{background:var(--purple);}
.lf-dot{width:7px;height:7px;border-radius:50%;background:var(--border2);flex-shrink:0;transition:background .15s;}
.lf-item-name{flex:1;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;}
.lf-item-count{font-family:'DM Mono',monospace;font-size:.65rem;color:var(--muted);flex-shrink:0;}
.lf-sep{height:1px;background:var(--border);margin:.3rem 0;}

/* Add list row */
.lf-add-row{display:flex;align-items:center;gap:.4rem;padding:.32rem .45rem;}
.lf-add-input{
  flex:1;background:var(--surface2);border:1px solid var(--border2);
  border-radius:7px;padding:.3rem .55rem;color:var(--text);
  font-family:'DM Mono',monospace;font-size:.7rem;outline:none;
}
.lf-add-input:focus{border-color:var(--purple);}
.lf-add-input::placeholder{color:var(--muted);}
.lf-add-btn{
  flex-shrink:0;padding:.3rem .55rem;border-radius:7px;
  background:var(--surface3);border:1px solid var(--border2);
  color:var(--text2);font-size:.72rem;font-weight:600;cursor:pointer;
  font-family:'DM Sans',sans-serif;transition:all .12s;white-space:nowrap;
}
.lf-add-btn:hover{border-color:var(--purple);color:var(--purple);}
.lf-add-hint{font-family:'DM Mono',monospace;font-size:.62rem;color:var(--muted);padding:.1rem .65rem .35rem;line-height:1.4;}

/* Following grid empty state */
.following-empty{
  grid-column:1/-1;
  display:flex;flex-direction:column;align-items:center;justify-content:center;
  padding:2rem 1rem;gap:.65rem;text-align:center;
  border:1px dashed var(--border2);border-radius:10px;
}
.following-empty-icon{font-size:2rem;opacity:.4;}
.following-empty-title{font-size:.85rem;font-weight:600;color:var(--text2);}
.following-empty-sub{font-size:.75rem;color:var(--muted);line-height:1.55;max-width:300px;}
.following-loading{
  grid-column:1/-1;
  display:flex;align-items:center;justify-content:center;gap:.5rem;
  padding:1.5rem;color:var(--muted);font-size:.8rem;font-family:'DM Mono',monospace;
}
.lf-spinner{
  width:14px;height:14px;border-radius:50%;
  border:2px solid var(--border2);border-top-color:var(--purple);
  animation:spin .7s linear infinite;flex-shrink:0;
}
@keyframes spin{to{transform:rotate(360deg)}}

/* Nip51 tag chip on stream cards in following grid */
.ci-nip51-badge{
  display:inline-flex;align-items:center;gap:.25rem;
  font-family:'DM Mono',monospace;font-size:.6rem;
  color:var(--purple);background:rgba(155,114,255,.1);
  border:1px solid rgba(155,114,255,.2);border-radius:3px;
  padding:.08rem .32rem;
}

/* footer */
footer{padding:1rem 1.2rem;border-top:1px solid var(--border);display:flex;align-items:center;justify-content:space-between;background:var(--surface);}
footer .flogo{font-family:var(--font-display);font-weight:800;font-size:.95rem;display:flex;align-items:center;gap:.32rem;}
footer p{font-size:.72rem;color:var(--muted);}
.nostr-pill{font-family:'DM Mono',monospace;font-size:.66rem;color:var(--purple);background:rgba(155,114,255,.1);border:1px solid rgba(155,114,255,.2);border-radius:4px;padding:.17rem .48rem;}

/* ======== HERO FEATURED STREAM ======== */
/* Sci-fi transition overlay */
.hero-transition-ov{
  position:absolute;inset:0;z-index:30;pointer-events:none;
  display:none;
}
.hero-transition-ov.active{display:block;}

/* Scanline sweep effect */
@keyframes scanSweep{
  0%{transform:translateY(-100%);opacity:0;}
  15%{opacity:1;}
  85%{opacity:1;}
  100%{transform:translateY(100%);opacity:0;}
}
.hero-scan-line{
  position:absolute;left:0;right:0;height:2px;
  background:linear-gradient(90deg,transparent,rgba(232,70,10,.9),rgba(247,183,49,.7),rgba(232,70,10,.9),transparent);
  box-shadow:0 0 18px 4px rgba(232,70,10,.55),0 0 60px 12px rgba(232,70,10,.2);
  transform:translateY(-100%);
  animation:scanSweep 0.7s cubic-bezier(.4,0,.2,1) forwards;
}

/* Glitch slice layers */
@keyframes glitchSlice{
  0%{clip-path:inset(0 0 95% 0);transform:translateX(-8px);opacity:0;}
  10%{opacity:1;}
  30%{clip-path:inset(20% 0 60% 0);transform:translateX(6px);}
  50%{clip-path:inset(55% 0 20% 0);transform:translateX(-4px);}
  70%{clip-path:inset(80% 0 5% 0);transform:translateX(3px);}
  100%{clip-path:inset(0 0 100% 0);transform:translateX(0);opacity:0;}
}
.hero-glitch-a,.hero-glitch-b{
  position:absolute;inset:0;
  background:inherit;
  opacity:0;
}
.hero-glitch-a{
  animation:glitchSlice 0.65s steps(1) forwards;
  filter:hue-rotate(-40deg) saturate(2);
  mix-blend-mode:screen;
}
.hero-glitch-b{
  animation:glitchSlice 0.65s steps(1) 0.04s reverse forwards;
  filter:hue-rotate(80deg) saturate(1.8);
  mix-blend-mode:screen;
}

/* Grid flash */
@keyframes gridFlash{
  0%,100%{opacity:0;}
  20%,40%,60%{opacity:.18;}
  30%,50%{opacity:.05;}
}
.hero-grid-flash{
  position:absolute;inset:0;
  background-image:
    linear-gradient(rgba(232,70,10,.45) 1px,transparent 1px),
    linear-gradient(90deg,rgba(232,70,10,.45) 1px,transparent 1px);
  background-size:32px 32px;
  animation:gridFlash 0.7s ease forwards;
}

/* Data stream particles */
@keyframes dataRain{
  0%{transform:translateY(-10px);opacity:.9;}
  100%{transform:translateY(460px);opacity:0;}
}
.hero-data-particle{
  position:absolute;top:0;width:1px;
  background:linear-gradient(to bottom,rgba(232,70,10,.9),rgba(247,183,49,.4),transparent);
  border-radius:2px;
  animation:dataRain 0.6s linear forwards;
}

/* Static noise flicker */
@keyframes staticFlicker{
  0%,100%{opacity:0;}
  10%{opacity:.15;}
  20%{opacity:0;}
  30%{opacity:.1;}
  50%{opacity:.08;}
  70%{opacity:.12;}
  90%{opacity:0;}
}
.hero-static{
  position:absolute;inset:0;
  background-image:url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='1'/%3E%3C/svg%3E");
  background-size:180px 180px;
  mix-blend-mode:overlay;
  animation:staticFlicker 0.7s steps(3) forwards;
}

/* Hero nav controls */
.hero-nav-btn{
  position:absolute;top:50%;transform:translateY(-50%);
  z-index:20;width:40px;height:40px;border-radius:50%;
  background:rgba(8,11,15,.7);backdrop-filter:blur(10px);
  border:1px solid rgba(232,70,10,.3);color:rgba(255,255,255,.8);
  display:flex;align-items:center;justify-content:center;
  cursor:pointer;font-size:1.1rem;font-weight:300;
  transition:all .2s;box-shadow:0 0 0 0 rgba(232,70,10,0);
  line-height:1;font-family:system-ui,sans-serif;
}
.hero-nav-btn:hover{
  background:rgba(232,70,10,.8);border-color:var(--accent);
  color:#fff;transform:translateY(-50%) scale(1.1);
  box-shadow:0 0 20px rgba(232,70,10,.4),0 0 0 1px rgba(232,70,10,.5);
}
.hero-nav-prev{left:.85rem;}
.hero-nav-next{right:.85rem;}

/* Dot indicators */
.hero-indicators{
  position:absolute;bottom:12px;left:50%;transform:translateX(-50%);
  display:flex;align-items:center;gap:5px;z-index:20;
}
.hero-dot{
  width:6px;height:6px;border-radius:50%;
  background:rgba(255,255,255,.22);cursor:pointer;
  transition:all .3s cubic-bezier(.4,0,.2,1);
  border:none;padding:0;
}
.hero-dot.active{
  width:22px;border-radius:3px;
  background:var(--accent);
  box-shadow:0 0 8px rgba(232,70,10,.6);
}

/* Cycle progress bar */
.hero-cycle-bar-wrap{
  position:absolute;bottom:0;left:0;right:0;z-index:20;
  height:2px;background:rgba(255,255,255,.06);
}
.hero-cycle-bar-fill{
  height:100%;width:0%;
  background:linear-gradient(90deg,var(--accent),var(--zap));
  box-shadow:0 0 8px rgba(232,70,10,.5);
  transition:width linear;
}

/* Hero player inner */
.hero-player{position:absolute;left:4%;top:50%;transform:translateY(-50%);width:54%;aspect-ratio:16/9;border-radius:12px;overflow:hidden;background:#000;border:1px solid rgba(255,255,255,.07);box-shadow:0 24px 80px rgba(0,0,0,.8);z-index:5;}
.hero-player video{width:100%;height:100%;object-fit:cover;display:block;}
.hero-player-bg{width:100%;height:100%;background:linear-gradient(135deg,#0d1e30,#1a0a00,#080d18);}

/* Stream card thumbnails */
.ct-thumb{width:100%;height:100%;object-fit:cover;display:block;}
.ct-thumb-wrap{position:relative;width:100%;height:100%;background:#0a0f18;overflow:hidden;}

/* ======== NIP-21 MENTION PILLS (nostr:npub/nprofile) ======== */
.nostr-mention-pill {
  display:inline;
  color:var(--purple);
  background:rgba(155,114,255,.1);
  border-radius:4px;
  padding:.05em .28em;
  font-weight:600;
  font-size:.9em;
  cursor:pointer;
  transition:background .15s;
}
.nostr-mention-pill:hover { background:rgba(155,114,255,.22); text-decoration:underline; }

/* ======== NEVENT EMBEDDED NOTE CARDS (nostr:nevent/note) ======== */
.nevent-embed-card {
  display:block;
  margin:.5rem 0;
  border:1px solid var(--border2);
  border-radius:10px;
  padding:.6rem .85rem;
  background:var(--surface2);
  cursor:pointer;
  font-size:.8rem;
  color:var(--muted);
  transition:border-color .15s, background .15s;
}
.nevent-embed-card:hover { border-color:var(--purple); background:var(--surface3); }
.nevent-embed-header {
  display:flex;
  align-items:center;
  gap:.45rem;
  margin-bottom:.32rem;
}
.nevent-embed-av {
  width:20px;height:20px;border-radius:50%;
  overflow:hidden;flex-shrink:0;
  background:var(--surface3);
  display:flex;align-items:center;justify-content:center;
  font-size:.6rem;border:1px solid var(--border);
}
.nevent-embed-av img{width:100%;height:100%;object-fit:cover;}
.nevent-embed-name {
  font-size:.76rem;font-weight:600;color:var(--text);
}
.nevent-embed-name:hover { text-decoration:underline; }
.nevent-embed-time {
  margin-left:auto;
  font-size:.65rem;color:var(--muted);
  font-family:'DM Mono',monospace;
}
.nevent-embed-body {
  font-size:.77rem;color:var(--text2);line-height:1.5;
  display:-webkit-box;-webkit-line-clamp:3;-webkit-box-orient:vertical;
  overflow:hidden;
}

/* ======== NADDR STREAM CARD (nostr:naddr...) ======== */
.naddr-stream-card{
  display:block;
  margin:.5rem 0;
  border:1px solid var(--border2);
  border-radius:12px;
  padding:.58rem .64rem;
  background:linear-gradient(160deg,rgba(35,44,56,.9),rgba(20,28,38,.9));
  color:var(--text2);
}
.naddr-stream-badge-row{display:flex;align-items:center;justify-content:flex-start;margin-bottom:.3rem;}
.naddr-stream-badge{font-family:'DM Mono',monospace;font-size:.6rem;letter-spacing:.08em;text-transform:uppercase;color:#fff;background:rgba(255,59,92,.85);padding:.12rem .38rem;border-radius:999px;}
.naddr-stream-title{font-family:var(--font-display);font-size:.86rem;font-weight:700;color:var(--text);line-height:1.35;margin-bottom:.38rem;}
.naddr-stream-host-row{display:flex;align-items:center;gap:.42rem;margin-bottom:.42rem;}
.naddr-stream-av{width:24px;height:24px;border-radius:50%;background:var(--surface3);border:1px solid var(--border2);display:flex;align-items:center;justify-content:center;font-size:.62rem;overflow:hidden;flex-shrink:0;}
.naddr-stream-host-meta{min-width:0;}
.naddr-stream-host-name{font-size:.72rem;color:var(--text);font-weight:600;line-height:1.25;}
.naddr-stream-host-id{font-family:'DM Mono',monospace;font-size:.6rem;color:var(--muted);line-height:1.2;}
.naddr-stream-thumb-wrap{border:1px solid var(--border2);border-radius:9px;overflow:hidden;background:#000;aspect-ratio:16/9;margin-bottom:.36rem;display:flex;align-items:center;justify-content:center;}
.naddr-stream-thumb{width:100%;height:100%;object-fit:cover;display:block;}
.naddr-stream-thumb-fallback{padding:.55rem .65rem;font-size:.68rem;color:var(--text2);line-height:1.45;display:-webkit-box;-webkit-line-clamp:3;-webkit-box-orient:vertical;overflow:hidden;}
.naddr-stream-thumb-url{display:block;font-family:'DM Mono',monospace;font-size:.58rem;line-height:1.35;color:var(--muted);margin-bottom:.34rem;text-decoration:none;word-break:break-all;}
.naddr-stream-thumb-url:hover{color:var(--accent);text-decoration:underline;}
.naddr-stream-via{font-family:'DM Mono',monospace;font-size:.62rem;color:var(--muted);margin-bottom:.3rem;}
.naddr-stream-open{display:inline-flex;align-items:center;gap:.32rem;color:var(--accent);text-decoration:none;font-family:'DM Mono',monospace;font-size:.66rem;}
.naddr-stream-open:hover{text-decoration:underline;}
















































