/* ============================================================
   Private Chat — dark Instagram-style theme (matches the app's
   original dark UI). Mobile-first: the app is used on phones.
   ============================================================ */
* { box-sizing: border-box; }
:root {
  --bg: #000000;
  --panel: #1c1e22;
  --panel-2: #141519;
  --panel-3: #26282e;
  --line: #26282e;
  --line-soft: #1a1b1f;
  --text: #f5f5f7;
  --muted: #9b9ea7;
  --blue: #2b7fff;
  --blue-deep: #1f6bff;
  --danger: #ff5964;
  --green: #31a24c;
  --grad-avatar: linear-gradient(45deg, #feda75, #fa7e1e, #d62976, #962fbf, #4f5bd5);
  --tabbar-h: 58px;
}
html { -webkit-tap-highlight-color: transparent; overflow-x: hidden; }
body {
  margin: 0;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", sans-serif;
  background: var(--bg);
  color: var(--text);
  overflow-x: hidden;
  max-width: 100%;
}
.hidden { display: none !important; }
.view { min-height: 100vh; min-height: 100dvh; display: flex; flex-direction: column; }
img { max-width: 100%; }

/* ---------- form controls (16px font = no iOS auto-zoom) ---------- */
input {
  width: 100%;
  padding: 12px 14px;
  margin: 6px 0;
  border: 1px solid #2e3038;
  border-radius: 12px;
  background: var(--panel);
  color: var(--text);
  font-size: 16px;
  font-family: inherit;
  outline: none;
  transition: border-color .15s, box-shadow .15s;
}
input::placeholder { color: #6d7078; }
input:focus { border-color: var(--blue); box-shadow: 0 0 0 3px rgba(43, 127, 255, .22); }
button {
  cursor: pointer;
  border: 1px solid #2e3038;
  background: var(--panel);
  color: var(--text);
  border-radius: 12px;
  padding: 10px 16px;
  font-size: 15px;
  font-family: inherit;
  transition: transform .08s, opacity .15s;
}
button:active { transform: scale(.97); }
button.primary {
  background: linear-gradient(135deg, #3a8bff, var(--blue-deep));
  border: none;
  color: #fff;
  font-weight: 700;
  letter-spacing: .2px;
  box-shadow: 0 6px 16px rgba(31, 107, 255, .35);
}
button.primary.small { padding: 10px 16px; width: auto; }
button.danger { color: var(--danger); }
.icon-btn {
  border: none; background: none; color: var(--text);
  width: 40px; height: 40px; padding: 0; flex: none;
  display: inline-flex; align-items: center; justify-content: center;
}
.icon-btn svg { width: 22px; height: 22px; }
.error { color: #ff7b84; min-height: 18px; font-size: 14px; margin: 6px 0 0; }
.hint { color: var(--muted); font-size: 13px; }
.helper { color: var(--muted); font-size: 12.5px; line-height: 1.5; margin: 8px 2px 6px; }
a { color: var(--blue); text-decoration: none; font-weight: 600; }

/* ---------- circular / pill header buttons ---------- */
.circle-btn {
  width: 38px; height: 38px; border-radius: 50%; flex: none;
  background: var(--panel); border: 1px solid #2e3038; color: var(--text);
  display: inline-flex; align-items: center; justify-content: center; padding: 0;
}
.circle-btn svg { width: 19px; height: 19px; }
.pill-btn {
  background: var(--panel); border: 1px solid #2e3038; color: var(--text);
  border-radius: 999px; padding: 9px 15px; font-size: 14px; font-weight: 600; flex: none;
}

/* ---------- avatars ---------- */
.avatar {
  width: 46px; height: 46px; border-radius: 50%;
  background: var(--grad-avatar); color: #fff;
  display: flex; align-items: center; justify-content: center;
  font-weight: 700; font-size: 17px; flex: none; position: relative;
}
.avatar { overflow: hidden; }
.avatar-img { width: 100%; height: 100%; object-fit: cover; display: block; border-radius: 50%; }
.pbio { color: var(--text); font-size: 14px; margin-top: 2px; max-width: 300px; }
#editProfileBtn { margin-top: 12px; }
.ep-preview { width: 96px; height: 96px; border-radius: 50%; object-fit: cover; display: block; margin: 0 auto 10px; }
.ep-preview.hidden { display: none; }
.avatar.sm { width: 34px; height: 34px; font-size: 14px; }
.avatar.xl { width: 86px; height: 86px; font-size: 34px; }
.avatar.chat-avatar { width: 36px; height: 36px; font-size: 14px; }
.dot {
  width: 12px; height: 12px; border-radius: 50%;
  background: var(--green); border: 2px solid #000;
  position: absolute; right: 0; bottom: 0;
}
.badge { background: var(--danger); color: #fff; font-size: 10px; padding: 3px 7px; border-radius: 6px; font-weight: 700; flex: none; }
.presence { color: var(--muted); font-size: 12px; }

/* ============================ AUTH ============================ */
#authView { background: var(--bg); align-items: center; justify-content: center; padding: 24px 20px calc(24px + env(safe-area-inset-bottom)); }
/* Boot splash: shown while a saved login is being restored, so the login
   form never flashes on refresh. The html.booting rules apply only before
   app.js takes over (it removes the class on the first screen change). */
html.booting #bootView { display: flex !important; }
html.booting #authView { display: none !important; }
#bootView { background: var(--bg); align-items: center; justify-content: center; padding: 24px 20px; }
.boot-box { text-align: center; }
.boot-logo { width: 76px; height: 76px; margin: 0 auto 20px; border-radius: 20px; background: linear-gradient(135deg, #962fbf, #d62976, #fa7e1e); color: #fff; font-size: 42px; font-weight: 800; display: flex; align-items: center; justify-content: center; }
.boot-spinner { width: 30px; height: 30px; margin: 0 auto 14px; border-radius: 50%; border: 3px solid #333; border-top-color: #d62976; animation: bootspin 0.8s linear infinite; }
@keyframes bootspin { to { transform: rotate(360deg); } }
#bootRetryBtn { margin: 10px auto 4px; }
.auth-box { width: 100%; max-width: 360px; margin: auto; text-align: center; padding: 12px 0; }
.auth-box .logo { font-size: 54px; line-height: 1; }
.auth-box h1 { font-size: 30px; font-weight: 800; letter-spacing: .2px; margin: 14px 0 20px; }
.auth-box input { background: var(--panel); text-align: left; }
.auth-box .primary { width: 100%; padding: 13px; font-size: 16px; border-radius: 12px; margin-top: 10px; }
.auth-box .switch { color: var(--muted); font-size: 14px; margin: 22px 0 0; }

/* ========================== APP SHELL ========================== */
#appView { background: var(--bg); }
.tab { flex: 1; display: flex; flex-direction: column; width: 100%; max-width: 680px; margin: 0 auto; min-width: 0; }
.tab-body { padding: 12px 14px calc(var(--tabbar-h) + 122px + env(safe-area-inset-bottom)); }
.tab-head {
  position: sticky; top: 0; z-index: 8;
  display: flex; align-items: center; gap: 10px;
  padding: calc(10px + env(safe-area-inset-top)) 14px 10px;
  background: rgba(0, 0, 0, .92); backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line-soft);
}
.tab-head.centered { display: grid; grid-template-columns: 1fr auto 1fr; }
.tab-head.end { justify-content: flex-end; }
.head-cell { min-width: 0; }
.head-title { font-size: 19px; font-weight: 800; letter-spacing: .2px; white-space: nowrap; }
.head-actions { display: inline-flex; align-items: center; gap: 9px; justify-self: end; margin-left: auto; }
.tab-head.centered .head-actions { margin-left: 0; }

/* bottom tab bar */
.tabbar {
  position: fixed; bottom: 0; left: 0; right: 0; z-index: 12;
  display: flex;
  background: rgba(8, 8, 10, .96); backdrop-filter: blur(12px);
  border-top: 1px solid var(--line);
  /* 46px dead strip at the very bottom: the injected "Powered by Netlify"
     badge floats over this strip instead of over the tab buttons. */
  padding-bottom: calc(46px + env(safe-area-inset-bottom));
}
.tab-btn {
  position: relative;
  flex: 1; border: none; background: none; color: #7c7f87;
  min-height: var(--tabbar-h); padding: 7px 0 8px;
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px;
}
.tab-btn svg { width: 24px; height: 24px; }
.tab-btn span { font-size: 11px; font-weight: 600; }
.tab-btn.active { color: #fff; }
.tab-dot {
  position: absolute; top: 9px; right: calc(50% - 19px);
  width: 9px; height: 9px; border-radius: 50%;
  background: var(--blue); border: 2px solid #050506;
}
.tab-avatar {
  width: 26px; height: 26px; border-radius: 50%;
  background: var(--grad-avatar); color: #fff !important;
  display: inline-flex; align-items: center; justify-content: center;
  font-size: 12px !important; font-weight: 700;
  border: 2px solid transparent; overflow: hidden;
}
.tab-btn.active .tab-avatar { border-color: #fff; }

/* floating panic (Lecture) pill — above the tab bar, never over it */
.lecture-float {
  position: fixed; right: 14px; z-index: 11;
  bottom: calc(var(--tabbar-h) + 62px + env(safe-area-inset-bottom));
  background: linear-gradient(135deg, #3a8bff, var(--blue-deep));
  color: #fff; border: none; border-radius: 999px;
  padding: 12px 20px; font-size: 15px; font-weight: 700;
  display: inline-flex; align-items: center; gap: 8px;
  box-shadow: 0 8px 22px rgba(31, 107, 255, .45);
  touch-action: none; cursor: grab; user-select: none; -webkit-user-select: none;
  -webkit-tap-highlight-color: transparent;
}
.lecture-float.dragging { cursor: grabbing; opacity: .92; }
.lecture-float svg { width: 19px; height: 19px; }
#chatView .lecture-float { display: none; } /* chat screen uses its own layout; float lives in appView only */

/* ============================= POSTS ============================= */
#postsFeed { display: flex; flex-direction: column; gap: 16px; }
.empty-state { text-align: center; padding: 56px 22px; }
.empty-state .empty-title { font-size: 19px; font-weight: 800; margin-bottom: 8px; }
.empty-state p { color: var(--muted); font-size: 14px; line-height: 1.55; margin: 0; }
.post { background: var(--panel-2); border: 1px solid #1f2126; border-radius: 16px; overflow: hidden; }
.post-head { display: flex; align-items: center; gap: 10px; padding: 11px 12px; font-size: 15px; }
.post img { width: 100%; display: block; max-height: 520px; object-fit: cover; background: #1a1b1f; }
.post .pbody { padding: 10px 12px 12px; font-size: 14.5px; line-height: 1.45; }
.post .actions { display: flex; gap: 14px; align-items: center; margin-bottom: 6px; }
.post .actions button { border: none; background: none; padding: 2px 0; font-size: 15px; color: var(--text); }
.post .actions span { color: var(--muted); font-size: 14px; }
.post .comment { font-size: 14px; margin-top: 4px; }
.post .comment-form { display: flex; gap: 6px; margin-top: 9px; }
.post .comment-form input { flex: 1; margin: 0; padding: 9px 12px; border-radius: 999px; }
.post .comment-form button { border-radius: 999px; padding: 8px 14px; }

/* ============================ MESSAGES ============================ */
.section-title { font-size: 16px; font-weight: 800; margin: 20px 2px 2px; }
.search-wrap { position: relative; }
.search-wrap .search-ico {
  position: absolute; left: 13px; top: 50%; transform: translateY(-50%);
  width: 18px; height: 18px; color: #6d7078; pointer-events: none;
}
.search-wrap input { padding-left: 40px; border-radius: 12px; margin: 2px 0 0; }
.inbox-item, .search-item, .account-item, .adminchat-item {
  display: flex; align-items: center; gap: 12px;
  padding: 11px 4px; border-bottom: 1px solid var(--line-soft); cursor: pointer;
  min-width: 0;
}
.inbox-item .meta, .account-item .meta, .adminchat-item .meta { flex: 1; min-width: 0; }
.inbox-item .name { font-weight: 700; font-size: 15.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.inbox-item .last { color: var(--muted); font-size: 13px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; margin-top: 2px; }
.inbox-item .presence { text-align: right; flex: none; max-width: 38%; }
.inbox-item .unread-text { color: var(--text); font-weight: 800; }
.unread-dot {
  width: 11px; height: 11px; border-radius: 50%; flex: none;
  background: var(--blue); box-shadow: 0 0 0 3px rgba(43, 127, 255, .18);
}

/* ============================== CHAT ============================== */
/* Bottom strip keeps the composer + Send button clear of the injected
   "Powered by Netlify" badge, which floats at the viewport's bottom-right. */
#chatView { height: 100vh; height: 100dvh; background: var(--bg); padding-bottom: calc(48px + env(safe-area-inset-bottom)); }
.topbar {
  display: flex; align-items: center; gap: 10px;
  padding: calc(8px + env(safe-area-inset-top)) 10px 8px;
  border-bottom: 1px solid var(--line-soft);
  background: rgba(0, 0, 0, .94); backdrop-filter: blur(10px);
  position: sticky; top: 0; z-index: 9; flex: none;
}
.chat-title { flex: 1; min-width: 0; }
.chat-title #chatName { font-weight: 700; font-size: 16px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
#messagesList {
  flex: 1; overflow-y: auto; overflow-x: hidden;
  padding: 14px 12px; display: flex; flex-direction: column; gap: 5px;
  width: 100%; max-width: 680px; margin: 0 auto;
}
.msg-row { display: flex; align-items: flex-end; gap: 2px; position: relative; max-width: 100%; touch-action: pan-y; user-select: none; -webkit-user-select: none; -webkit-touch-callout: none; }
.msg-row.swiping { transition: none; }
.msg-row.snap { transition: transform .18s ease; }
.swipe-icon { position: absolute; left: 2px; top: 14px; opacity: 0; font-size: 17px; color: #a8a8a8; pointer-events: none; }
.msg-row.mine { flex-direction: row-reverse; }
.bubble {
  max-width: 74%; padding: 9px 13px; border-radius: 19px;
  background: var(--panel-3); color: var(--text);
  font-size: 15.5px; line-height: 1.4; overflow-wrap: break-word; word-break: break-word;
}
.msg-row.mine .bubble { background: linear-gradient(135deg, #962fbf, #d62976, #fa7e1e); color: #fff; }
.msg-col { display: flex; flex-direction: column; max-width: 74%; min-width: 0; }
.msg-row.mine .msg-col { align-items: flex-end; }
.msg-col .bubble { max-width: 100%; }
.bubble.img-bubble { padding: 3px; }
.msg-img { display: block; max-width: 230px; width: 100%; border-radius: 16px; -webkit-user-drag: none; }
.bubble.emoji-big { background: transparent; font-size: 44px; line-height: 1.15; padding: 2px 4px; }
.reaction-badge { display: inline-flex; gap: 2px; align-items: center; background: #22242a; border: 1px solid #34363f; border-radius: 999px; padding: 1px 7px; font-size: 12px; margin-top: -7px; margin-left: 10px; position: relative; z-index: 1; }
.msg-row.mine .reaction-badge { margin-left: 0; margin-right: 10px; }
.time-divider { text-align: center; color: var(--muted); font-size: 12px; margin: 16px 0 10px; }
.typing-row { color: var(--muted); font-size: 13px; padding: 8px 6px 2px; }
.typing-row .tdots span { animation: tblink 1.2s infinite; display: inline-block; }
.typing-row .tdots span:nth-child(2) { animation-delay: 0.2s; }
.typing-row .tdots span:nth-child(3) { animation-delay: 0.4s; }
@keyframes tblink { 0%, 60%, 100% { opacity: 0.25; } 30% { opacity: 1; } }
.composer-icon { background: none; border: none; font-size: 19px; padding: 6px 4px; cursor: pointer; line-height: 1; width: auto; flex: none; }
.post-preview { width: 100%; border-radius: 12px; margin-top: 8px; display: block; }
.post-preview.hidden { display: none; }
#postPickBtn { width: 100%; }
.react-emojis { display: flex; gap: 2px; padding: 4px; border-bottom: 1px solid #34363f; margin-bottom: 4px; }
.msg-menu.open-up { top: auto; bottom: calc(100% + 4px); }
.react-emojis button { background: none; border: none; font-size: 21px; padding: 4px 5px; cursor: pointer; width: auto; }
.bubble .quote {
  font-size: 12.5px; opacity: .9; background: rgba(0, 0, 0, .18);
  border-radius: 9px; padding: 5px 8px; margin-bottom: 5px; overflow-wrap: break-word;
}
.bubble .edited { font-size: 11px; opacity: .65; font-style: italic; margin-top: 2px; }
.bubble-foot { text-align: right; font-size: 10.5px; opacity: .6; margin-top: 3px; }
.bubble-foot .edited { font-size: 10.5px; margin-top: 0; }
.photo-viewer { position: fixed; inset: 0; z-index: 95; background: rgba(0, 0, 0, .96); display: flex; align-items: center; justify-content: center; }
.photo-viewer img { max-width: 100%; max-height: 100%; object-fit: contain; }
.photo-viewer-close { position: absolute; top: calc(12px + env(safe-area-inset-top)); right: 14px; width: 38px; height: 38px; border-radius: 50%; border: none; background: rgba(255, 255, 255, .14); color: #fff; font-size: 17px; }
.bubble .deleted-flag { font-size: 11px; color: #ffb3ab; font-weight: 700; margin-top: 2px; }
.seen-row {
  align-self: flex-end; color: var(--muted); font-size: 11.5px;
  margin: 1px 30px 3px 0; font-weight: 600;
}
.msg-dots { border: none; background: none; font-size: 16px; color: #6d7078; padding: 4px 5px; width: auto; flex: none; }
.msg-menu {
  position: absolute; top: calc(100% + 4px); right: 0; z-index: 40;
  background: #22242a; border: 1px solid #34363f; border-radius: 13px;
  box-shadow: 0 12px 30px rgba(0, 0, 0, .55); padding: 4px; min-width: 158px;
}
.msg-row.mine .msg-menu { right: auto; left: 0; }
.msg-menu button { display: block; width: 100%; text-align: left; border: none; background: none; padding: 10px 12px; border-radius: 9px; font-size: 14.5px; }
.msg-menu button:active { background: #2e3038; }
#replyBar {
  display: flex; align-items: center; gap: 8px; flex: none;
  padding: 8px 14px; background: #121317; border-top: 1px solid var(--line-soft);
  font-size: 13px; color: var(--muted);
}
#replyBar span { flex: 1; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
#recBar { display: flex; align-items: center; gap: 10px; flex: none; padding: 8px 14px; background: #121317; border-top: 1px solid var(--line-soft); font-size: 14px; }
#recBar .rec-hint { flex: 1; color: var(--muted); font-size: 13px; }
.rec-dot { width: 10px; height: 10px; border-radius: 50%; background: #ed4956; animation: recPulse 1s infinite; }
@keyframes recPulse { 0%, 100% { opacity: 1; } 50% { opacity: .25; } }
.msg-audio { display: block; width: 232px; max-width: 62vw; height: 38px; }
#chatSearchBar { display: flex; align-items: center; gap: 6px; flex: none; padding: 7px 10px; background: #121317; border-bottom: 1px solid var(--line-soft); }
#chatSearchBar input { flex: 1; }
#chatSearchCount { color: var(--muted); font-size: 13px; min-width: 34px; text-align: center; }
.msg-row.search-hit .bubble { outline: 2px solid #f5c04e; outline-offset: 1px; }
#outboxBar { flex: none; padding: 6px 14px; background: #1d1a12; color: #e8cf8f; font-size: 12.5px; border-top: 1px solid var(--line-soft); }
.gi-member { display: flex; align-items: center; gap: 9px; padding: 6px 0; }
.gi-meta { flex: 1; font-size: 14px; }
.gi-meta span { color: var(--muted); font-size: 12.5px; }
.gi-member button { border: none; background: #2a2c33; color: #ff8f98; padding: 6px 11px; border-radius: 8px; font-size: 13px; }
#giAvatar { display: flex; }
.modal-box select { flex: 1; background: #1c1e24; color: #fff; border: 1px solid var(--line); border-radius: 10px; padding: 10px; }
#replyBar .icon-btn { width: 30px; height: 30px; font-size: 14px; }
.composer {
  display: flex; gap: 8px; align-items: center; flex: none;
  padding: 10px 12px calc(10px + env(safe-area-inset-bottom));
  border-top: 1px solid var(--line-soft); background: rgba(0, 0, 0, .96);
}
.composer input { flex: 1; border-radius: 999px; margin: 0; min-width: 0; }
.composer .primary { border-radius: 999px; flex: none; }

/* ====================== MENUS / PROFILE / MODALS ====================== */
.menu {
  background: var(--panel); border: 1px solid #2e3038; border-radius: 14px;
  box-shadow: 0 12px 28px rgba(0, 0, 0, .5); padding: 6px; margin: 4px 0 10px;
}
#chatMenu { margin: 8px 12px 0; }
.menu-row { display: flex; justify-content: space-between; align-items: center; padding: 11px 10px; font-size: 15px; gap: 10px; }
.menu-row input[type="checkbox"] { width: 22px; height: 22px; margin: 0; accent-color: var(--blue); flex: none; }
.menu-row-btn { display: block; width: 100%; text-align: left; border: none; background: none; padding: 11px 10px; border-radius: 9px; font-size: 15px; }
.menu-row-btn.flex { display: flex; justify-content: space-between; align-items: center; }
.menu-state { color: var(--muted); font-size: 13.5px; }
.profile-center { display: flex; flex-direction: column; align-items: center; text-align: center; padding: 14px 0 4px; }
.pname { font-weight: 800; font-size: 21px; margin-top: 12px; }
.puname { color: var(--muted); font-size: 14.5px; margin-top: 2px; }
.profile-note { color: var(--muted); font-size: 13.5px; line-height: 1.55; text-align: center; margin: 12px 6px 18px; }
.panic-card {
  background: #0d1622; border: 1px solid rgba(64, 132, 255, .5); border-radius: 16px;
  padding: 16px; margin-bottom: 18px;
}
.panic-card-head { display: flex; align-items: center; gap: 11px; margin-bottom: 10px; }
.panic-ico {
  width: 38px; height: 38px; border-radius: 50%; flex: none;
  background: linear-gradient(135deg, #3a8bff, var(--blue-deep)); color: #fff;
  display: inline-flex; align-items: center; justify-content: center;
}
.panic-ico svg { width: 19px; height: 19px; }
.panic-card-title { font-weight: 800; font-size: 16.5px; }
.panic-card p { color: #c3c7cf; font-size: 13.8px; line-height: 1.6; margin: 0 0 10px; }
.panic-card p b, .panic-card p i { color: #fff; }
.panic-card .panic-try { width: 100%; padding: 13px; font-size: 15.5px; border-radius: 12px; margin-top: 4px; }
.off-note {
  color: var(--muted); font-size: 13.5px; line-height: 1.55;
  background: var(--panel-2); border: 1px solid var(--line-soft); border-radius: 14px;
  padding: 13px 14px; margin: 0 0 18px;
}
.off-note b { color: var(--text); }
.logout-btn {
  display: block; width: 100%; margin-top: 26px; padding: 13px;
  background: transparent; border: 1.5px solid rgba(255, 89, 100, .55); color: #ff6b74;
  border-radius: 13px; font-size: 15.5px; font-weight: 700;
}
#adminPanel h3 { font-size: 16px; margin: 22px 0 6px; }
.account-item button, .adminchat-item button { padding: 8px 12px; font-size: 13.5px; flex: none; }
.modal {
  position: fixed; inset: 0; z-index: 50;
  background: rgba(0, 0, 0, .66); backdrop-filter: blur(3px);
  display: flex; align-items: center; justify-content: center;
  padding: 16px;
}
.modal-box {
  background: #17181c; border: 1px solid #2b2d34; border-radius: 18px;
  padding: 20px; width: min(92vw, 400px); max-height: 86vh; max-height: 86dvh;
  overflow-y: auto; box-shadow: 0 18px 44px rgba(0, 0, 0, .6);
}
.modal-box h3 { margin: 0 0 10px; font-size: 18px; }
.modal-box .row { display: flex; justify-content: flex-end; gap: 8px; margin-top: 14px; }
.modal-box .row .primary { flex: 1; }
.member-check { display: flex; align-items: center; gap: 10px; padding: 8px 0; font-size: 15px; }
.member-check input { width: 20px; height: 20px; margin: 0; accent-color: var(--blue); flex: none; }

/* ====================== PANIC LECTURE (disguise — stays a light study page) ====================== */
#lectureView { background: #f8f9fa; color: #202124; overflow-y: auto; }
.lecture-top { background: #202124; color: #fff; padding: calc(16px + env(safe-area-inset-top)) 16px 16px; }
.lecture-logo { font-size: 22px; font-weight: 800; user-select: none; -webkit-user-select: none; touch-action: manipulation; color: #fff; }
.lecture-sub { color: #9aa0a6; font-size: 13px; margin-top: 2px; }
.lecture-player { margin: 16px; background: #000; color: #fff; border-radius: 12px; padding: 64px 16px; text-align: center; font-size: 17px; }
.yt-btn { display: block; margin: 0 16px 16px; background: #ff0000; color: #fff; text-align: center; padding: 13px; border-radius: 10px; font-weight: 700; }
.lecture-list { list-style: none; margin: 0 16px; padding: 0; }
.lecture-list li { background: #fff; border: 1px solid #dadce0; border-radius: 10px; padding: 13px; margin-bottom: 8px; color: #202124; }
.lecture-notes { margin: 16px 16px calc(20px + env(safe-area-inset-bottom)); background: #fff; border: 1px solid #dadce0; border-radius: 10px; padding: 14px; color: #202124; }
