/* ==========================================================================
   Messenger Desktop & Mobile UI Stylesheet
   ========================================================================== */

:root {
  --primary-color: #0084ff;
  --primary-hover: #0073e6;
  --primary-gradient: linear-gradient(135deg, #0084ff 0%, #00c6ff 100%);
  --theme-glow: rgba(0, 132, 255, 0.35);
  --theme-tint: rgba(0, 132, 255, 0.08);

  --bubble-outgoing: #0084ff;
  --bubble-outgoing-text: #ffffff;
  --bubble-incoming: #f0f2f5;
  --bubble-incoming-text: #050505;
  
  --bg-app: #f0f2f5;
  --bg-surface: #ffffff;
  --bg-surface-translucent: rgba(255, 255, 255, 0.88);
  --bg-surface-secondary: #f0f2f5;
  --bg-hover: #e4e6eb;
  --bg-active: #d8dadf;
  
  --text-primary: #050505;
  --text-secondary: #65676b;
  --text-muted: #8a8d91;
  --border-color: #e4e6eb;
  --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.1);
  --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.15);
  --shadow-lg: 0 12px 28px rgba(0, 0, 0, 0.2);
  
  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 18px;
  --radius-full: 9999px;

  --search-highlight-bg: #ffe066;
  --search-highlight-text: #000000;
  
  --font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  --header-height: 58px;
  --input-height: 52px;
}

/* ==========================================================================
   Theme Color Palettes (Accents & Bubble Gradients)
   ========================================================================== */

/* 1. Messenger Blue (Default) */
body.color-messenger-blue {
  --primary-color: #0084ff;
  --primary-hover: #0073e6;
  --primary-gradient: linear-gradient(135deg, #0084ff 0%, #00c6ff 100%);
  --theme-glow: rgba(0, 132, 255, 0.4);
  --theme-tint: rgba(0, 132, 255, 0.1);
}

/* 2. Sunset Peach */
body.color-sunset-peach {
  --primary-color: #ff5858;
  --primary-hover: #e64a4a;
  --primary-gradient: linear-gradient(135deg, #ff5858 0%, #f09819 100%);
  --theme-glow: rgba(255, 88, 88, 0.4);
  --theme-tint: rgba(255, 88, 88, 0.1);
}

/* 3. Cyberpunk Violet */
body.color-cyberpunk-violet {
  --primary-color: #b800e6;
  --primary-hover: #9c00c4;
  --primary-gradient: linear-gradient(135deg, #7928ca 0%, #ff0080 100%);
  --theme-glow: rgba(255, 0, 128, 0.4);
  --theme-tint: rgba(121, 40, 202, 0.12);
}

/* 4. Emerald Teal */
body.color-emerald-teal {
  --primary-color: #0ba360;
  --primary-hover: #09874f;
  --primary-gradient: linear-gradient(135deg, #0ba360 0%, #3cba92 100%);
  --theme-glow: rgba(11, 163, 96, 0.4);
  --theme-tint: rgba(11, 163, 96, 0.1);
}

/* 5. Ocean Wave */
body.color-ocean-wave {
  --primary-color: #0052d4;
  --primary-hover: #0044b3;
  --primary-gradient: linear-gradient(135deg, #0052d4 0%, #4364f7 60%, #6fb1fc 100%);
  --theme-glow: rgba(67, 100, 247, 0.4);
  --theme-tint: rgba(0, 82, 212, 0.1);
}

/* 6. Crimson Rose */
body.color-crimson-rose {
  --primary-color: #eb3349;
  --primary-hover: #cc2539;
  --primary-gradient: linear-gradient(135deg, #eb3349 0%, #f45c43 100%);
  --theme-glow: rgba(235, 51, 73, 0.4);
  --theme-tint: rgba(235, 51, 73, 0.1);
}

/* 7. Midnight Cyan */
body.color-midnight-cyan {
  --primary-color: #00d2ff;
  --primary-hover: #00b4dc;
  --primary-gradient: linear-gradient(135deg, #00f2fe 0%, #4facfe 100%);
  --theme-glow: rgba(0, 242, 254, 0.45);
  --theme-tint: rgba(0, 242, 254, 0.12);
}

/* 8. Lavender Dream */
body.color-lavender-dream {
  --primary-color: #8e2de2;
  --primary-hover: #7924c2;
  --primary-gradient: linear-gradient(135deg, #8e2de2 0%, #4a00e0 100%);
  --theme-glow: rgba(142, 45, 226, 0.4);
  --theme-tint: rgba(142, 45, 226, 0.1);
}

/* Dark Theme Variables */
body.theme-dark {
  --bg-app: #18191a;
  --bg-surface: #242526;
  --bg-surface-translucent: rgba(36, 37, 38, 0.88);
  --bg-surface-secondary: #3a3b3c;
  --bg-hover: #3a3b3c;
  --bg-active: #4e4f50;
  
  --bubble-incoming: #303030;
  --bubble-incoming-text: #e4e6eb;

  --text-primary: #e4e6eb;
  --text-secondary: #b0b3b8;
  --text-muted: #8a8d91;
  --border-color: #393a3b;
  --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.3);
  --shadow-md: 0 4px 16px rgba(0, 0, 0, 0.4);
  --shadow-lg: 0 12px 32px rgba(0, 0, 0, 0.5);

  --search-highlight-bg: #ffd13b;
  --search-highlight-text: #1a1a1a;
}

/* Base Reset */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html, body {
  width: 100%;
  height: 100%;
  overflow: hidden;
  font-family: var(--font-family);
  background-color: var(--bg-app);
  color: var(--text-primary);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* App Wrapper */
.messenger-app {
  position: relative;
  width: 100vw;
  height: 100vh;
  height: 100dvh;
  display: flex;
  overflow: hidden;
}

/* Background Wallpaper & Overlay */
.chat-wallpaper {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  z-index: 0;
  transition: all 0.35s ease;
}

.chat-wallpaper-overlay {
  position: absolute;
  inset: 0;
  background: var(--bg-app);
  opacity: 0.45;
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  z-index: 1;
  pointer-events: none;
  transition: opacity 0.3s ease, backdrop-filter 0.3s ease;
}

/* Wallpaper Presets */
.chat-wallpaper.wp-sunset {
  background: linear-gradient(135deg, #1d0e2e 0%, #4a154b 45%, #ff5e62 100%) !important;
}

.chat-wallpaper.wp-aurora {
  background: linear-gradient(135deg, #091a28 0%, #004d40 50%, #00bfa5 100%) !important;
}

.chat-wallpaper.wp-cyber {
  background: linear-gradient(135deg, #090014 0%, #1e0836 50%, #3a0ca3 100%) !important;
}

.chat-wallpaper.wp-doodle {
  background-color: #1a1c23 !important;
  background-image: radial-gradient(#313749 1px, transparent 1px), radial-gradient(#313749 1px, #1a1c23 1px) !important;
  background-size: 24px 24px !important;
  background-position: 0 0, 12px 12px !important;
}

.chat-wallpaper.wp-none {
  background: transparent !important;
}

/* Screen Flash Animation Overlay for Screenshot */
.screen-flash-overlay {
  position: fixed;
  inset: 0;
  background: #ffffff;
  z-index: 9999;
  pointer-events: none;
  opacity: 0;
}

.screen-flash-overlay.flash {
  animation: cameraFlash 0.35s cubic-bezier(0.1, 0.9, 0.2, 1) forwards;
}

@keyframes cameraFlash {
  0% { opacity: 0.75; }
  100% { opacity: 0; }
}

/* Floating Hearts Explosion Container */
.heart-burst-container {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 500;
  overflow: hidden;
}

.floating-heart {
  position: absolute;
  user-select: none;
  pointer-events: none;
  will-change: transform, opacity;
  animation: floatHeartAnim 2.2s cubic-bezier(0.25, 0.8, 0.25, 1) forwards;
  filter: drop-shadow(0 2px 8px rgba(255, 51, 102, 0.45));
}

@keyframes floatHeartAnim {
  0% {
    transform: translate(0, 0) scale(0.4) rotate(0deg);
    opacity: 0.95;
  }
  20% {
    transform: translate(var(--dx), -15vh) scale(1.15) rotate(var(--rot));
    opacity: 1;
  }
  60% {
    transform: translate(calc(var(--dx) * 1.6), -45vh) scale(1) rotate(calc(var(--rot) * 1.5));
    opacity: 0.85;
  }
  100% {
    transform: translate(calc(var(--dx) * 2), -75vh) scale(0.7) rotate(calc(var(--rot) * 2));
    opacity: 0;
  }
}

/* Main Chat Container */
.messenger-container {
  position: relative;
  z-index: 2;
  flex: 1;
  display: flex;
  flex-direction: column;
  height: 100%;
  max-width: 100%;
  overflow: hidden;
  background: transparent;
}

/* Header */
.chat-header {
  height: var(--header-height);
  padding: 0 16px;
  background: var(--bg-surface-translucent);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border-color);
  display: flex;
  align-items: center;
  justify-content: space-between;
  box-shadow: var(--shadow-sm);
  z-index: 10;
}

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

.avatar-wrapper {
  position: relative;
  flex-shrink: 0;
}

.avatar {
  width: 40px;
  height: 40px;
  border-radius: var(--radius-full);
  background: var(--primary-gradient);
  color: #fff;
  font-weight: 600;
  font-size: 14.5px;
  display: flex;
  align-items: center;
  justify-content: center;
  user-select: none;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.15);
  overflow: hidden;
  position: relative;
}

.avatar-img {
  width: 100%;
  height: 100%;
  border-radius: inherit;
  object-fit: cover;
  object-position: center 18%;
  display: block;
}

.avatar-fallback {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 600;
}

.avatar.lg {
  width: 68px;
  height: 68px;
  font-size: 24px;
}

.avatar.sm {
  width: 26px;
  height: 26px;
  font-size: 11px;
}

.online-badge {
  position: absolute;
  bottom: 0px;
  right: 0px;
  width: 11px;
  height: 11px;
  background-color: #31a24c;
  border: 2px solid var(--bg-surface);
  border-radius: var(--radius-full);
}

.header-user-info {
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.header-name {
  font-size: 15.5px;
  font-weight: 700;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  color: var(--text-primary);
}

.header-status {
  font-size: 11.5px;
  color: var(--text-secondary);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-shrink: 0;
}

/* Action Buttons */
.icon-btn {
  background: var(--bg-surface-secondary);
  color: var(--text-primary);
  border: none;
  border-radius: var(--radius-full);
  width: 36px;
  height: 36px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: background-color 0.15s ease, transform 0.1s ease, color 0.15s ease;
  position: relative;
}

.icon-btn:hover {
  background: var(--bg-hover);
  color: var(--primary-color);
}

.icon-btn:active {
  transform: scale(0.93);
  background: var(--bg-active);
}

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

/* Theme Icons Toggle */
body.theme-light .sun-icon { display: none; }
body.theme-light .moon-icon { display: block; }
body.theme-dark .sun-icon { display: block; }
body.theme-dark .moon-icon { display: none; }

/* Context Banner (When jumped from search or oldest) */
.context-banner {
  background: var(--primary-gradient);
  color: #ffffff;
  padding: 8px 16px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 13px;
  font-weight: 600;
  box-shadow: var(--shadow-sm);
  z-index: 9;
  animation: slideDown 0.25s ease-out;
}

.context-banner-btn {
  background: rgba(255, 255, 255, 0.25);
  border: none;
  color: #fff;
  padding: 4px 12px;
  border-radius: var(--radius-full);
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.15s;
}
.context-banner-btn:hover {
  background: rgba(255, 255, 255, 0.4);
}

@keyframes slideDown {
  from { transform: translateY(-100%); opacity: 0; }
  to { transform: translateY(0); opacity: 1; }
}

/* Messages Container */
.chat-messages-container {
  flex: 1;
  overflow-y: auto;
  overflow-x: hidden;
  padding: 12px 16px;
  scroll-behavior: auto;
  display: flex;
  flex-direction: column;
  position: relative;
}

/* Custom Scrollbars */
.chat-messages-container::-webkit-scrollbar,
.search-results-list::-webkit-scrollbar,
.info-sidebar-content::-webkit-scrollbar,
.theme-modal-body::-webkit-scrollbar {
  width: 6px;
}
.chat-messages-container::-webkit-scrollbar-thumb,
.search-results-list::-webkit-scrollbar-thumb,
.info-sidebar-content::-webkit-scrollbar-thumb,
.theme-modal-body::-webkit-scrollbar-thumb {
  background: rgba(0, 0, 0, 0.2);
  border-radius: 4px;
}
body.theme-dark .chat-messages-container::-webkit-scrollbar-thumb,
body.theme-dark .search-results-list::-webkit-scrollbar-thumb,
body.theme-dark .info-sidebar-content::-webkit-scrollbar-thumb,
body.theme-dark .theme-modal-body::-webkit-scrollbar-thumb {
  background: rgba(255, 255, 255, 0.2);
}

/* Loading State */
.chat-loading-state {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  height: 100%;
  gap: 16px;
  color: var(--text-secondary);
}

.messenger-spinner {
  width: 40px;
  height: 40px;
  border: 3.5px solid var(--border-color);
  border-top-color: var(--primary-color);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}

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

.loading-title {
  font-size: 16px;
  font-weight: 600;
  color: var(--text-primary);
}
.loading-subtitle {
  font-size: 12.5px;
}

/* Messages Stream */
.chat-stream {
  display: flex;
  flex-direction: column;
  gap: 3px;
  width: 100%;
  max-width: 900px;
  margin: 0 auto;
}

/* Date Header Divider */
.date-divider {
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 16px 0 10px;
  user-select: none;
}

.date-divider-badge {
  background: var(--bg-surface-translucent);
  border: 1px solid var(--border-color);
  color: var(--text-secondary);
  font-size: 11px;
  font-weight: 600;
  padding: 3px 12px;
  border-radius: var(--radius-full);
  box-shadow: var(--shadow-sm);
  backdrop-filter: blur(8px);
}

/* Message Item Row */
.msg-row {
  display: flex;
  align-items: flex-end;
  gap: 8px;
  position: relative;
  margin-bottom: 2px;
  transition: background-color 0.2s ease;
}

.msg-row.outgoing {
  justify-content: flex-end;
}

.msg-row.incoming {
  justify-content: flex-start;
}

/* Sender Avatar alongside message */
.msg-avatar-slot {
  width: 26px;
  height: 26px;
  flex-shrink: 0;
  margin-bottom: 2px;
}

.msg-row.outgoing .msg-avatar-slot {
  display: none;
}

/* Message Wrapper & Content */
.msg-bubble-wrap {
  display: flex;
  flex-direction: column;
  max-width: 70%;
  position: relative;
}

.msg-row.outgoing .msg-bubble-wrap {
  align-items: flex-end;
}

.msg-row.incoming .msg-bubble-wrap {
  align-items: flex-start;
}

/* Bubble Styling */
.msg-bubble {
  position: relative;
  padding: 9px 13px;
  font-size: 14px;
  line-height: 1.45;
  word-break: break-word;
  white-space: pre-wrap;
  border-radius: var(--radius-lg);
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.08);
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}

/* Messenger Corner Grouping */
.msg-row.incoming .msg-bubble {
  background-color: var(--bubble-incoming);
  color: var(--bubble-incoming-text);
  border-bottom-left-radius: 4px;
}

.msg-row.outgoing .msg-bubble {
  background: var(--primary-gradient);
  color: var(--bubble-outgoing-text);
  border-bottom-right-radius: 4px;
}

/* Highlighting Search Result with Context */
.msg-bubble.jump-highlight {
  animation: jumpHighlightPulse 2.8s ease-out forwards;
}

@keyframes jumpHighlightPulse {
  0% {
    box-shadow: 0 0 0 4px #ffd13b, 0 8px 24px rgba(255, 209, 59, 0.7);
    transform: scale(1.03);
  }
  30% {
    box-shadow: 0 0 0 5px #ffd13b, 0 10px 28px rgba(255, 209, 59, 0.85);
    transform: scale(1.04);
  }
  70% {
    box-shadow: 0 0 0 3px #ffd13b, 0 6px 18px rgba(255, 209, 59, 0.5);
    transform: scale(1.01);
  }
  100% {
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.08);
    transform: scale(1);
  }
}

/* Search Term Highlight Inside Bubble */
mark.search-highlight {
  background-color: var(--search-highlight-bg);
  color: var(--search-highlight-text);
  padding: 0 3px;
  border-radius: 3px;
  font-weight: 700;
}

/* Timestamp on hover */
.msg-time {
  font-size: 10.5px;
  color: var(--text-muted);
  margin-top: 3px;
  padding: 0 4px;
  display: none;
  user-select: none;
}

.msg-row:hover .msg-time {
  display: block;
}

/* Removed / Unsent Message */
.msg-bubble.unsent {
  background: transparent !important;
  border: 1.5px dashed var(--text-muted);
  color: var(--text-muted) !important;
  font-style: italic;
  display: flex;
  align-items: center;
  gap: 6px;
  box-shadow: none;
}

.unsent-icon {
  width: 14px;
  height: 14px;
  flex-shrink: 0;
  stroke: var(--text-muted);
}

/* Reactions Pill Badge */
.reaction-pill-badge {
  position: absolute;
  bottom: -9px;
  background: var(--bg-surface);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-full);
  padding: 1px 6px;
  display: inline-flex;
  align-items: center;
  gap: 3px;
  font-size: 12px;
  cursor: pointer;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.12);
  user-select: none;
  z-index: 3;
  transition: transform 0.15s ease, background 0.15s ease;
}

.msg-row.incoming .reaction-pill-badge {
  right: -8px;
}

.msg-row.outgoing .reaction-pill-badge {
  left: -8px;
}

.reaction-pill-badge:hover {
  transform: scale(1.12);
  background: var(--bg-hover);
}

.reaction-pill-badge .emoji-icons {
  display: inline-flex;
  align-items: center;
  gap: 1px;
}

.reaction-pill-badge .reaction-total {
  font-size: 11px;
  font-weight: 600;
  color: var(--text-secondary);
  margin-left: 2px;
}

/* ==========================================================================
   Facebook / Messenger Emoji Pack Styling
   ========================================================================== */
.fb-emoji,
.emoji,
img.fb-emoji,
img.emoji,
.msg-bubble img.fb-emoji,
.msg-bubble img.emoji,
.msg-bubble img {
  width: 1.3em !important;
  height: 1.3em !important;
  max-width: 1.3em !important;
  max-height: 1.3em !important;
  vertical-align: -0.22em !important;
  display: inline-block !important;
  object-fit: contain !important;
  pointer-events: none;
  user-select: none;
}

.reaction-pill-badge .fb-emoji,
.reaction-pill-badge img.emoji,
.reaction-pill-badge img {
  width: 15px !important;
  height: 15px !important;
  max-width: 15px !important;
  max-height: 15px !important;
  vertical-align: middle !important;
}

.actor-reaction .fb-emoji,
.actor-reaction img.emoji,
.actor-reaction img {
  width: 22px !important;
  height: 22px !important;
  max-width: 22px !important;
  max-height: 22px !important;
  vertical-align: middle !important;
}

.reaction-tab .fb-emoji,
.reaction-tab img.emoji,
.reaction-tab img {
  width: 17px !important;
  height: 17px !important;
  max-width: 17px !important;
  max-height: 17px !important;
  vertical-align: -3px !important;
  margin-right: 4px;
}

/* Jumbo Emojis (when message consists only of 1-3 emojis) */
.msg-bubble.only-emojis {
  background: transparent !important;
  box-shadow: none !important;
  padding: 4px 6px !important;
}

.msg-bubble.only-emojis .fb-emoji,
.msg-bubble.only-emojis img.emoji,
.msg-bubble.only-emojis img {
  width: 36px !important;
  height: 36px !important;
  max-width: 36px !important;
  max-height: 36px !important;
  margin: 0 2px !important;
}

/* Media Cards */
.media-attachment-card {
  display: flex;
  align-items: center;
  gap: 10px;
  background: rgba(0, 0, 0, 0.05);
  border: 1px solid rgba(0, 0, 0, 0.08);
  border-radius: 10px;
  padding: 8px 12px;
  margin-top: 4px;
}

body.theme-dark .media-attachment-card {
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.1);
}

.msg-row.outgoing .media-attachment-card {
  background: rgba(255, 255, 255, 0.18);
  border-color: rgba(255, 255, 255, 0.25);
}

.media-icon-wrap {
  width: 32px;
  height: 32px;
  border-radius: 8px;
  background: var(--theme-tint);
  color: var(--primary-color);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.msg-row.outgoing .media-icon-wrap {
  background: rgba(255, 255, 255, 0.25);
  color: #fff;
}

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

.media-details {
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.media-title {
  font-weight: 600;
  font-size: 13px;
}

.media-sub {
  font-size: 11px;
  opacity: 0.75;
}

/* Links */
.chat-link {
  color: inherit;
  text-decoration: underline;
  word-break: break-all;
  transition: opacity 0.15s;
}

.msg-row.incoming .chat-link {
  color: var(--primary-color);
}

.chat-link:hover {
  opacity: 0.85;
}

.link-preview-box {
  display: flex;
  flex-direction: column;
  gap: 2px;
  margin-top: 6px;
  padding: 8px 10px;
  border-radius: 8px;
  background: rgba(0, 0, 0, 0.05);
  border-left: 3px solid var(--primary-color);
}

body.theme-dark .link-preview-box {
  background: rgba(255, 255, 255, 0.07);
}

.msg-row.outgoing .link-preview-box {
  background: rgba(255, 255, 255, 0.2);
  border-left-color: #ffffff;
}

.link-domain {
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  opacity: 0.85;
  display: flex;
  align-items: center;
  gap: 4px;
}

.link-domain svg {
  width: 11px;
  height: 11px;
}

/* Top and Bottom Load More Buttons */
.top-load-container,
.bottom-load-container {
  display: flex;
  justify-content: center;
  padding: 10px 0;
}

.load-more-btn {
  background: var(--bg-surface-translucent);
  backdrop-filter: blur(8px);
  border: 1px solid var(--border-color);
  color: var(--primary-color);
  padding: 6px 16px;
  border-radius: var(--radius-full);
  font-size: 12.5px;
  font-weight: 600;
  cursor: pointer;
  box-shadow: var(--shadow-sm);
  display: inline-flex;
  align-items: center;
  gap: 6px;
  transition: all 0.2s ease;
}

.load-more-btn:hover {
  background: var(--primary-color);
  color: #fff;
  border-color: var(--primary-color);
  box-shadow: var(--shadow-md);
  transform: translateY(-1px);
}

.load-more-counter {
  font-size: 11px;
  opacity: 0.8;
  font-weight: 400;
}

/* ==========================================================================
   Compact Floating Jump Buttons (Top & Bottom)
   ========================================================================== */

.floating-controls {
  position: fixed;
  bottom: 64px;
  right: 14px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  z-index: 100;
}

.floating-btn {
  width: 32px;
  height: 32px;
  border-radius: var(--radius-full);
  background: var(--bg-surface);
  border: 1px solid var(--border-color);
  color: var(--text-primary);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.16);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  opacity: 0.85;
  transition: opacity 0.2s, transform 0.15s, background 0.15s, color 0.15s;
}

.floating-btn:hover {
  opacity: 1;
  background: var(--bg-hover);
  color: var(--primary-color);
  transform: scale(1.1);
}

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

/* ==========================================================================
   Messenger Desktop Bottom Input Bar (Sleeker & More Compact)
   ========================================================================== */

.chat-input-bar {
  height: var(--input-height);
  padding: 0 12px;
  display: flex;
  align-items: center;
  gap: 6px;
  z-index: 10;
  transition: all 0.3s ease;
}

/* 1. Frosted Glass (Default) */
body.chatbar-frosted .chat-input-bar {
  background: var(--bg-surface-translucent);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-top: 1px solid var(--border-color);
}

/* 2. Theme Neon Glow */
body.chatbar-glow .chat-input-bar {
  background: var(--bg-surface-translucent);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-top: 1.5px solid var(--primary-color);
  box-shadow: 0 -4px 18px var(--theme-glow);
}

/* 3. Deep Obsidian Dark */
body.chatbar-dark .chat-input-bar {
  background: #111215;
  border-top: 1px solid #282a30;
  color: #fff;
}
body.chatbar-dark .chat-input {
  background: #1c1d22;
  color: #fff;
  border-color: #2e3038;
}

/* 4. Theme Color Tinted */
body.chatbar-tint .chat-input-bar {
  background: var(--theme-tint);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-top: 1px solid var(--primary-color);
}
body.chatbar-tint .chat-input {
  background: rgba(255, 255, 255, 0.45);
}
body.theme-dark.chatbar-tint .chat-input {
  background: rgba(0, 0, 0, 0.35);
}

/* 5. Clean Minimalist */
body.chatbar-clean .chat-input-bar {
  background: var(--bg-surface);
  border-top: 1px solid var(--border-color);
  box-shadow: none;
}

.input-actions-left,
.input-actions-right {
  display: flex;
  align-items: center;
  gap: 3px;
}

/* Smaller & Sleeker Action Buttons */
.input-icon-btn {
  background: transparent;
  border: none;
  width: 30px;
  height: 30px;
  border-radius: var(--radius-full);
  color: var(--primary-color);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: background 0.15s, color 0.15s, transform 0.15s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.input-icon-btn:hover {
  background: var(--bg-hover);
  transform: scale(1.08);
}

.input-icon-btn:active {
  transform: scale(0.92);
}

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

/* Screenshot Button (+) */
.plus-screenshot-btn {
  color: var(--primary-color);
}

.plus-screenshot-btn:hover {
  color: #00c6ff;
}

/* Heart Button (Replaces Like Thumb) */
.heart-btn {
  color: #ff3366 !important;
}

.heart-btn:hover {
  background: rgba(255, 51, 102, 0.12);
  color: #ff1a53 !important;
  transform: scale(1.18);
}

.heart-btn.popping {
  animation: heartPop 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.4) forwards;
}

@keyframes heartPop {
  0% { transform: scale(1); }
  45% { transform: scale(1.45); }
  100% { transform: scale(1); }
}

.input-field-wrapper {
  flex: 1;
  position: relative;
  display: flex;
  align-items: center;
}

.chat-input {
  width: 100%;
  height: 36px;
  padding: 0 38px 0 12px;
  background: var(--bg-surface-secondary);
  border: 1px solid transparent;
  border-radius: var(--radius-full);
  color: var(--text-primary);
  font-family: inherit;
  font-size: 13.5px;
  outline: none;
  cursor: default;
  transition: border-color 0.2s, background-color 0.2s;
}

.chat-input:focus {
  border-color: var(--primary-color);
}

.emoji-picker-btn {
  position: absolute;
  right: 5px;
  background: transparent;
  border: none;
  width: 28px;
  height: 28px;
  border-radius: var(--radius-full);
  color: var(--primary-color);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: color 0.15s, transform 0.15s;
}

.emoji-picker-btn:hover {
  transform: scale(1.1);
}

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

/* Sidebar Info Drawer */
.chat-info-sidebar {
  width: 340px;
  height: 100%;
  background: var(--bg-surface-translucent);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-left: 1px solid var(--border-color);
  display: flex;
  flex-direction: column;
  position: absolute;
  right: 0;
  top: 0;
  bottom: 0;
  z-index: 20;
  transform: translateX(100%);
  transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  box-shadow: var(--shadow-lg);
}

.chat-info-sidebar.open {
  transform: translateX(0);
}

.info-sidebar-header {
  height: var(--header-height);
  padding: 0 16px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid var(--border-color);
}

.info-sidebar-header h3 {
  font-size: 16px;
  font-weight: 700;
}

.close-sidebar-btn {
  font-size: 15px;
  font-weight: 700;
}

.info-sidebar-content {
  flex: 1;
  overflow-y: auto;
  padding: 20px 16px;
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.info-profile-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 8px;
  padding-bottom: 16px;
  border-bottom: 1px solid var(--border-color);
}

.info-user-name {
  font-size: 17px;
  font-weight: 700;
}

.info-user-badge {
  font-size: 11.5px;
  color: var(--text-secondary);
  background: var(--bg-surface-secondary);
  padding: 2px 10px;
  border-radius: var(--radius-full);
}

.info-section {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.info-section-title {
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  color: var(--text-secondary);
  letter-spacing: 0.5px;
}

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

.participant-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px;
  border-radius: var(--radius-sm);
  background: var(--bg-surface-secondary);
}

.participant-name {
  font-size: 13.5px;
  font-weight: 600;
}

.participant-role {
  font-size: 11px;
  color: var(--text-secondary);
  margin-left: auto;
}

.form-select {
  width: 100%;
  padding: 8px 12px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border-color);
  background: var(--bg-surface-secondary);
  color: var(--text-primary);
  font-family: inherit;
  font-size: 13.5px;
  outline: none;
  cursor: pointer;
}

.sidebar-action-btn {
  width: 100%;
  padding: 9px 14px;
  background: var(--bg-surface-secondary);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-sm);
  color: var(--text-primary);
  font-weight: 600;
  font-size: 13px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  transition: all 0.15s;
}

.sidebar-action-btn:hover {
  background: var(--primary-color);
  color: #fff;
  border-color: var(--primary-color);
}

/* Stats Grid */
.stats-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 8px;
}

.stat-card {
  background: var(--bg-surface-secondary);
  padding: 9px;
  border-radius: 8px;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
}

.stat-num {
  font-size: 15px;
  font-weight: 700;
  color: var(--primary-color);
}

.stat-lbl {
  font-size: 11px;
  color: var(--text-secondary);
}

/* ==========================================================================
   Theme & Chat Colors Customizer Modal
   ========================================================================== */

.theme-customizer-modal {
  width: 90%;
  max-width: 600px;
  max-height: 85vh;
  background: var(--bg-surface);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  border: 1px solid var(--border-color);
  transform: translateY(-20px) scale(0.98);
  transition: transform 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

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

.theme-modal-header {
  padding: 16px 20px;
  border-bottom: 1px solid var(--border-color);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.theme-modal-title {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--text-primary);
}

.theme-modal-title h3 {
  font-size: 16.5px;
  font-weight: 700;
}

.theme-modal-body {
  padding: 16px 20px;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.customizer-group h4 {
  font-size: 13px;
  font-weight: 700;
  margin-bottom: 10px;
  color: var(--text-secondary);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

/* Color Palettes Grid */
.color-palette-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 10px;
}

.color-swatch-btn {
  background: var(--bg-surface-secondary);
  border: 2px solid transparent;
  border-radius: var(--radius-md);
  padding: 9px 8px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  cursor: pointer;
  transition: all 0.15s ease;
}

.color-swatch-btn:hover {
  background: var(--bg-hover);
  transform: translateY(-2px);
}

.color-swatch-btn.active {
  border-color: var(--primary-color);
  background: var(--theme-tint);
  box-shadow: 0 0 0 2px var(--theme-glow);
}

.swatch-circle {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.2);
}

.swatch-label {
  font-size: 11px;
  font-weight: 600;
  color: var(--text-primary);
  text-align: center;
}

/* Chat Bar Styles Grid */
.chatbar-style-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 8px;
}

.chatbar-btn {
  background: var(--bg-surface-secondary);
  border: 1.5px solid var(--border-color);
  border-radius: var(--radius-sm);
  padding: 8px 12px;
  display: flex;
  align-items: center;
  gap: 10px;
  cursor: pointer;
  font-size: 12.5px;
  font-weight: 600;
  color: var(--text-primary);
  transition: all 0.15s;
}

.chatbar-btn:hover {
  border-color: var(--primary-color);
}

.chatbar-btn.active {
  border-color: var(--primary-color);
  background: var(--theme-tint);
  box-shadow: 0 0 0 1px var(--primary-color);
}

.chatbar-thumb {
  width: 18px;
  height: 18px;
  border-radius: 4px;
  flex-shrink: 0;
  border: 1px solid rgba(0,0,0,0.15);
}

.bar-frosted { background: rgba(255, 255, 255, 0.6); backdrop-filter: blur(4px); }
.bar-glow { background: var(--primary-color); box-shadow: 0 0 8px var(--primary-color); }
.bar-dark { background: #121316; }
.bar-tint { background: var(--primary-color); opacity: 0.65; }
.bar-clean { background: #ffffff; }

/* Wallpaper Presets Grid */
.wallpaper-preset-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
}

.wallpaper-card {
  background: var(--bg-surface-secondary);
  border: 2px solid transparent;
  border-radius: var(--radius-sm);
  padding: 6px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  cursor: pointer;
  transition: all 0.15s;
}

.wallpaper-card:hover {
  background: var(--bg-hover);
  transform: translateY(-2px);
}

.wallpaper-card.active {
  border-color: var(--primary-color);
  background: var(--theme-tint);
}

.wp-card-preview {
  width: 100%;
  height: 50px;
  border-radius: 6px;
  background-size: cover;
  background-position: center;
  border: 1px solid rgba(0,0,0,0.1);
}

.wp-sunset-bg {
  background: linear-gradient(135deg, #1d0e2e 0%, #4a154b 45%, #ff5e62 100%);
}
.wp-aurora-bg {
  background: linear-gradient(135deg, #091a28 0%, #004d40 50%, #00bfa5 100%);
}
.wp-cyber-bg {
  background: linear-gradient(135deg, #090014 0%, #1e0836 50%, #3a0ca3 100%);
}
.wp-doodle-bg {
  background-color: #1a1c23;
  background-image: radial-gradient(#40475b 1px, transparent 1px);
  background-size: 8px 8px;
}
.wp-none-bg {
  background: var(--bg-surface);
}

.wp-card-name {
  font-size: 11px;
  font-weight: 600;
  color: var(--text-primary);
}

/* Sliders */
.slider-row {
  display: flex;
  flex-direction: column;
  gap: 4px;
  font-size: 12px;
  color: var(--text-secondary);
  margin-bottom: 8px;
}

.slider-row input {
  accent-color: var(--primary-color);
  cursor: pointer;
}

/* ==========================================================================
   Modals & Overlays (Search, Reactions, Lightbox)
   ========================================================================== */

.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.55);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s ease;
}

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

/* Search Modal */
.search-modal {
  width: 90%;
  max-width: 680px;
  height: 82vh;
  background: var(--bg-surface);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  transform: translateY(-20px) scale(0.98);
  transition: transform 0.25s cubic-bezier(0.16, 1, 0.3, 1);
  border: 1px solid var(--border-color);
}

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

.search-modal-header {
  padding: 14px 16px;
  border-bottom: 1px solid var(--border-color);
  display: flex;
  align-items: center;
  gap: 12px;
}

.search-input-box {
  flex: 1;
  position: relative;
  display: flex;
  align-items: center;
  background: var(--bg-surface-secondary);
  border-radius: var(--radius-full);
  padding: 0 12px 0 38px;
  border: 1.5px solid transparent;
  transition: border-color 0.15s;
}

.search-input-box:focus-within {
  border-color: var(--primary-color);
  background: var(--bg-surface);
}

.search-box-icon {
  position: absolute;
  left: 12px;
  width: 18px;
  height: 18px;
  color: var(--text-secondary);
}

#searchInput {
  width: 100%;
  height: 38px;
  background: transparent;
  border: none;
  outline: none;
  font-family: inherit;
  font-size: 14.5px;
  color: var(--text-primary);
}

.clear-search-btn {
  background: transparent;
  border: none;
  color: var(--text-secondary);
  font-size: 14px;
  cursor: pointer;
  padding: 4px;
  display: none;
}

.clear-search-btn.visible {
  display: block;
}

.close-modal-btn {
  background: transparent;
  border: none;
  color: var(--primary-color);
  font-size: 13.5px;
  font-weight: 600;
  cursor: pointer;
  padding: 6px 10px;
  border-radius: var(--radius-sm);
  transition: background 0.15s;
}

.close-modal-btn:hover {
  background: var(--bg-hover);
}

/* Filter Bar */
.search-filter-bar {
  padding: 10px 16px;
  background: var(--bg-surface-secondary);
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid var(--border-color);
  gap: 10px;
}

.filter-chips {
  display: flex;
  gap: 6px;
  overflow-x: auto;
}

.filter-chip {
  background: var(--bg-surface);
  border: 1px solid var(--border-color);
  color: var(--text-secondary);
  padding: 4px 12px;
  border-radius: var(--radius-full);
  font-size: 12px;
  font-weight: 500;
  cursor: pointer;
  white-space: nowrap;
  transition: all 0.15s;
}

.filter-chip.active {
  background: var(--primary-color);
  color: #fff;
  border-color: var(--primary-color);
}

.search-meta {
  font-size: 12px;
  font-weight: 600;
  color: var(--text-secondary);
  white-space: nowrap;
}

/* Search Results List */
.search-results-list {
  flex: 1;
  overflow-y: auto;
  padding: 10px 12px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.search-empty-state {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  height: 100%;
  text-align: center;
  gap: 12px;
  color: var(--text-secondary);
  padding: 20px;
}

.search-empty-state svg {
  width: 44px;
  height: 44px;
  opacity: 0.5;
}

.search-hint {
  font-size: 12px;
  color: var(--text-muted);
}

/* Result Card */
.search-result-card {
  padding: 12px 14px;
  border-radius: var(--radius-md);
  background: var(--bg-surface);
  border: 1px solid var(--border-color);
  cursor: pointer;
  display: flex;
  flex-direction: column;
  gap: 6px;
  transition: all 0.15s ease;
}

.search-result-card:hover {
  background: var(--bg-hover);
  border-color: var(--primary-color);
  transform: translateY(-1px);
  box-shadow: var(--shadow-sm);
}

.result-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.result-sender {
  font-size: 13px;
  font-weight: 700;
  display: flex;
  align-items: center;
  gap: 6px;
}

.result-date {
  font-size: 11px;
  color: var(--text-muted);
}

.result-snippet {
  font-size: 13px;
  color: var(--text-primary);
  line-height: 1.45;
  word-break: break-word;
}

/* Reactions Modal */
.reaction-modal {
  width: 90%;
  max-width: 420px;
  max-height: 70vh;
  background: var(--bg-surface);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  border: 1px solid var(--border-color);
}

.reaction-modal-header {
  padding: 14px 16px;
  border-bottom: 1px solid var(--border-color);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.reaction-modal-header h3 {
  font-size: 15.5px;
  font-weight: 700;
}

.reaction-tabs {
  display: flex;
  gap: 6px;
  padding: 8px 16px;
  border-bottom: 1px solid var(--border-color);
  background: var(--bg-surface-secondary);
  overflow-x: auto;
}

.reaction-tab {
  background: transparent;
  border: none;
  font-size: 12.5px;
  font-weight: 600;
  color: var(--text-secondary);
  padding: 5px 11px;
  border-radius: var(--radius-full);
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.reaction-tab.active {
  background: var(--bg-surface);
  color: var(--primary-color);
  box-shadow: var(--shadow-sm);
}

.reaction-actors-list {
  flex: 1;
  overflow-y: auto;
  padding: 10px 16px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.actor-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 8px 6px;
}

.actor-name {
  font-size: 14px;
  font-weight: 600;
}

.actor-reaction {
  margin-left: auto;
  font-size: 19px;
}

/* Lightbox Modal */
.lightbox-modal {
  position: relative;
  max-width: 90vw;
  max-height: 90vh;
  display: flex;
  align-items: center;
  justify-content: center;
}

.lightbox-close-btn {
  position: absolute;
  top: -40px;
  right: 0;
  background: rgba(255, 255, 255, 0.2);
  border: none;
  color: #fff;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  font-size: 17px;
  cursor: pointer;
}

.lightbox-content img {
  max-width: 100%;
  max-height: 85vh;
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-lg);
}

/* Toast */
.toast {
  position: fixed;
  bottom: 80px;
  left: 50%;
  transform: translateX(-50%) translateY(20px);
  background: rgba(0, 0, 0, 0.85);
  color: #fff;
  padding: 9px 18px;
  border-radius: var(--radius-full);
  font-size: 12.5px;
  font-weight: 500;
  box-shadow: var(--shadow-md);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s, transform 0.25s;
  z-index: 2000;
  backdrop-filter: blur(8px);
}

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

/* ==========================================================================
   Mobile Responsive Rules
   ========================================================================== */

@media (max-width: 768px) {
  :root {
    --header-height: 54px;
    --input-height: 50px;
  }

  .header-name {
    font-size: 14.5px;
  }

  .icon-btn {
    width: 34px;
    height: 34px;
  }

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

  .msg-bubble-wrap {
    max-width: 84%;
  }

  .chat-info-sidebar {
    width: 100%;
  }

  .search-modal {
    width: 100%;
    height: 100%;
    max-width: 100%;
    border-radius: 0;
  }

  .theme-customizer-modal {
    width: 100%;
    height: 100%;
    max-width: 100%;
    border-radius: 0;
  }

  .color-palette-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .wallpaper-preset-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .chatbar-style-grid {
    grid-template-columns: 1fr;
  }

  .reaction-modal {
    width: 95%;
  }

  .floating-controls {
    bottom: 58px;
    right: 10px;
  }
}

/* ==========================================================================
   Screenshot Export Card Styling
   ========================================================================== */
.messenger-screenshot-card {
  position: fixed;
  top: 0;
  left: 0;
  z-index: -9999;
  pointer-events: none;
  opacity: 1;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  box-sizing: border-box;
  background-color: var(--bg-app);
  color: var(--text-primary);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  border-radius: 12px;
}

.screenshot-bg-layer {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  z-index: 1;
}

.screenshot-overlay-layer {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: #000;
  z-index: 2;
}

.screenshot-content {
  position: relative;
  z-index: 3;
  display: flex;
  flex-direction: column;
  width: 100%;
}

.screenshot-header {
  height: 54px;
  padding: 0 16px;
  background: var(--bg-surface-translucent);
  border-bottom: 1px solid var(--border-color);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.screenshot-header-left {
  display: flex;
  align-items: center;
  gap: 10px;
}

.screenshot-name {
  font-size: 15px;
  font-weight: 700;
  color: var(--text-primary);
  display: block;
}

.screenshot-status {
  font-size: 11px;
  color: #31a24c;
  font-weight: 500;
  display: block;
}

.screenshot-header-right {
  display: flex;
  align-items: center;
  gap: 14px;
  color: var(--primary-color);
}

.screenshot-header-right svg {
  width: 19px;
  height: 19px;
}

.screenshot-stream {
  padding: 12px 14px 16px;
  display: flex;
  flex-direction: column;
  gap: 4px;
  width: 100%;
  box-sizing: border-box;
}

.screenshot-stream .msg-bubble-wrap {
  max-width: 80%;
}

.screenshot-footer {
  padding: 8px 14px 10px;
  background: var(--bg-surface-translucent);
  border-top: 1px solid var(--border-color);
  display: flex;
  align-items: center;
}

.screenshot-fake-input {
  flex: 1;
  height: 34px;
  border-radius: 17px;
  background: var(--bg-surface-secondary);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 14px;
  color: var(--text-muted);
  font-size: 13.5px;
}

.screenshot-heart {
  color: #ff3366;
  font-size: 16px;
}

