
/* responsive.css - injected per user request */

/* 1) Avatar enlarged 3x (assumes original approx 84px -> now 252px) */
.profile-avatar-circle, .profile-avatar, .topbar-avatar, .user-avatar, .nav-avatar {
  width: 252px !important;
  height: 252px !important;
  min-width: 252px !important;
  min-height: 252px !important;
  border-radius: 50% !important;
  overflow: hidden !important;
  display: inline-block !important;
}

/* Ensure inner image covers and is circular */
.profile-avatar-circle img, .profile-avatar img, .topbar-avatar img, .user-avatar img, .nav-avatar img {
  width: 100% !important;
  height: 100% !important;
  object-fit: cover !important;
  object-position: center center !important;
  border-radius: 50% !important;
  display: block !important;
}

/* 2) Global responsive helpers (minimal) */
:root {
  --fut-menu-height: 72px;
}
body.responsive-enabled {
  box-sizing: border-box;
  padding-top: var(--fut-menu-height);
}

/* 3) Fix all menus top-right and bold */
/* Apply to common menu selectors; place them fixed at top-right */
.topbar, .header, .navbar, .menu-bar, .menu, #topbar, .site-header, .nav, .navigation {
  position: fixed !important;
  top: 12px !important;
  right: 12px !important;
  z-index: 99999 !important;
  background: rgba(0,0,0,0.35) !important;
  padding: 8px 12px !important;
  border-radius: 10px !important;
  display: flex !important;
  gap: 8px !important;
  align-items: center !important;
  font-weight: 700 !important; /* bold */
  box-shadow: 0 8px 24px rgba(0,0,0,0.5) !important;
  backdrop-filter: blur(6px) !important;
}

/* Ensure menu links are visible and not wrapped awkwardly */
.topbar a, .header a, .navbar a, .menu a, .nav a, .navigation a {
  color: #ffffff !important;
  text-decoration: none !important;
  padding: 6px 10px !important;
  border-radius: 6px !important;
}

/* Responsive: on small screens, make menu full width across top but still fixed and bold */
@media (max-width: 720px) {
  .topbar, .header, .navbar, .menu-bar, .menu, #topbar, .site-header, .nav, .navigation {
    left: 0 !important;
    right: 0 !important;
    top: 0 !important;
    width: 100% !important;
    justify-content: space-between !important;
    padding: 10px 12px !important;
    border-radius: 0 !important;
  }
  body.responsive-enabled { padding-top: calc(var(--fut-menu-height) + 8px); }
}

/* Safety: ensure content isn't hidden under menu */
main, .page, .site-container, .content, #app { box-sizing: border-box; padding-top: calc(var(--fut-menu-height) + 16px); }


/* === UnipayWeb futuristic brand & spacing optimizations === */

/* Brand in topbar (left) - large, futuristic */
.unipay-brand {
  font-family: 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
  font-weight: 800 !important;
  color: #E6F7FF !important;
  letter-spacing: 0.6px;
  text-shadow: 0 6px 18px rgba(34,211,238,0.06);
  display: inline-block;
  align-self: center;
  margin-right: 12px;
  line-height: 1;
  transform-origin: left center;
  /* size ~ 2x menu link size */
  font-size: calc(0.95rem * 4) !important;
  padding: 4px 8px;
  border-radius: 8px;
  background: linear-gradient(90deg, rgba(58,141,255,0.06), rgba(124,58,237,0.04));
  border: 1px solid rgba(255,255,255,0.04);
  box-shadow: 0 8px 24px rgba(58,141,255,0.06);
}

/* Slight glow accent for brand */
.unipay-brand .logo-mark {
  display:inline-block;
  width:18px; height:18px; border-radius:4px;
  margin-right:8px;
  vertical-align:middle;
  background: linear-gradient(135deg, rgba(58,141,255,1), rgba(124,58,237,1));
  box-shadow: 0 6px 18px rgba(58,141,255,0.18), inset 0 -4px 8px rgba(255,255,255,0.06);
}

/* Reduce spacing between topbar and main content to millimeter-precise small gap */
:root { --unipay-gap-mm: 6px; } /* approximate small gap */
body.responsive-enabled { padding-top: calc(var(--fut-menu-height) + var(--unipay-gap-mm)); }
main, .page, .site-container, .content, #app {
  padding-top: 6px !important;
  padding-bottom: 6px !important;
  margin-top: 0 !important;
  margin-bottom: 0 !important;
  max-height: calc(100vh - (var(--fut-menu-height) + 32px)) !important;
  
}

/* Reduce vertical padding inside common sections for less scrolling */
section, .section, .card, .panel {
  padding-top: 8px !important;
  padding-bottom: 8px !important;
  margin-bottom: 8px !important;
}

/* Reduce heading margins */
h1, h2, h3 { margin-top: 6px !important; margin-bottom: 6px !important; line-height: 1.1 !important; }

/* Ensure images do not force vertical growth */
img { max-height: 60vh; object-fit: contain; }

/* Keep menus bold and top-right fixed (reinforce) */
.topbar, .header, .navbar, .menu-bar, .menu, #topbar, .site-header, .nav, .navigation {
  font-weight: 800 !important;
  right: 12px !important;
  top: 12px !important;
}

/* Slightly reduce avatar big size on very small screens to avoid overflow */
@media (max-width:420px){
  .profile-avatar-circle, .profile-avatar, .topbar-avatar, .user-avatar, .nav-avatar {
    width: 160px !important;
    height: 160px !important;
  }
  .unipay-brand { font-size: calc(0.95rem * 4) !important; padding:4px 6px; }
}


/* Apply blinking background on hover to menu links */
.fut-topbar .menu a:hover, .topbar .menu a:hover, .menu a:hover, .navigation a:hover, .nav a:hover {
  animation: futBlink 800ms ease-in-out 1;
  background: linear-gradient(90deg, rgba(58,141,255,0.06), rgba(124,58,237,0.04));
  color: #fff !important;
}


/* Persistent active menu flame effect */
@keyframes blueFlame {
  0% { box-shadow: 0 0 0 rgba(58,141,255,0); transform: translateY(0); }
  20% { box-shadow: 0 0 12px rgba(58,141,255,0.12), 0 0 24px rgba(124,58,237,0.06); transform: translateY(-2px); }
  40% { box-shadow: 0 0 20px rgba(58,141,255,0.16), 0 0 36px rgba(124,58,237,0.08); transform: translateY(-3px); }
  60% { box-shadow: 0 0 12px rgba(58,141,255,0.12), 0 0 24px rgba(124,58,237,0.06); transform: translateY(-2px); }
  100% { box-shadow: 0 0 0 rgba(58,141,255,0); transform: translateY(0); }
}

/* active menu item persistent flame */
.menu a.active, .fut-topbar .menu a.active, .topbar .menu a.active {
  position: relative !important;
  color: #E6F7FF !important;
  animation: blueFlame 1.2s ease-in-out infinite !important;
  background: linear-gradient(90deg, rgba(58,141,255,0.06), rgba(124,58,237,0.04)) !important;
  border-radius: 8px !important;
  z-index: 100000 !important;
}

/* ensure topbar is transparent and content visible underneath */
.fut-topbar, .topbar, .menu-bar, .header, .navbar {
  background: transparent !important;
  border: none !important;
  box-shadow: none !important;
  backdrop-filter: blur(8px) !important;
  -webkit-backdrop-filter: blur(8px) !important;
}

/* Make sure body content flows under the transparent menu */
body.responsive-enabled, body.fut-content-offset {
  padding-top: calc(var(--fut-menu-height,72px) + 8px) !important;
}

/* Main fills viewport to show menu floating over content */
main, .page, .site-container, .content, #app {
  min-height: 100vh !important;
  box-sizing: border-box !important;
  padding-top: 8px !important;
  padding-bottom: 8px !important;
  overflow: visible !important;
}

/* Ensure only one scrollbar: body */
html, body { height: 100% !important; overflow-x: hidden !important; }



/* Intensified bluish flame highlight for active menu items (strong, visible) */
@keyframes futFlame {
  0% { filter: drop-shadow(0 0 0 rgba(58,141,255,0)); transform: translateY(0) scale(1); box-shadow: 0 0 0 rgba(58,141,255,0); }
  20% { transform: translateY(-2px) scale(1.02); box-shadow: 0 6px 22px rgba(58,141,255,0.18); }
  50% { transform: translateY(-4px) scale(1.04); box-shadow: 0 12px 40px rgba(58,141,255,0.28); }
  80% { transform: translateY(-2px) scale(1.02); box-shadow: 0 6px 22px rgba(58,141,255,0.18); }
  100% { transform: translateY(0) scale(1); box-shadow: 0 0 0 rgba(58,141,255,0); }
}

/* make active menu item glow persistently with animated flame and neon outline */
.menu a.active, .fut-topbar .menu a.active, .topbar .menu a.active, .navigation a.active {
  position: relative !important;
  color: #ffffff !important;
  z-index: 100000 !important;
  animation: futFlame 1400ms ease-in-out infinite !important;
  background: linear-gradient(90deg, rgba(58,141,255,0.08), rgba(124,58,237,0.05)) !important;
  box-shadow: 0 12px 40px rgba(58,141,255,0.28) !important;
  transform-origin: center;
}

/* add pseudo-element for flickering flame overlay */
.menu a.active::after, .fut-topbar .menu a.active::after, .topbar .menu a.active::after {
  content: "";
  position: absolute;
  inset: -6% -10% -30% -10%;
  background: radial-gradient(ellipse at 50% 0%, rgba(80,180,255,0.28), rgba(20,60,120,0.06) 40%, rgba(0,0,0,0) 60%);
  filter: blur(8px) saturate(140%);
  pointer-events: none;
  mix-blend-mode: screen;
  border-radius: 10px;
  opacity: 0.95;
  animation: flicker 900ms ease-in-out infinite;
}

/* flicker for pseudo-element */
@keyframes flicker {
  0% { opacity: 0.85; transform: translateY(0) scale(1); }
  25% { opacity: 1; transform: translateY(-2px) scale(1.02); }
  50% { opacity: 0.9; transform: translateY(-4px) scale(1.04); }
  75% { opacity: 1; transform: translateY(-2px) scale(1.02); }
  100% { opacity: 0.85; transform: translateY(0) scale(1); }
}

/* Ensure active menu remains readable: stronger text shadow for contrast */
.menu a.active span, .menu a.active, .fut-topbar .menu a.active, .topbar .menu a.active {
  text-shadow: 0 4px 18px rgba(0,0,40,0.45);
  font-weight: 900 !important;
}

/* Make hover also slightly stronger (but not same as active) */
.menu a:hover, .fut-topbar .menu a:hover, .topbar .menu a:hover {
  box-shadow: 0 10px 28px rgba(58,141,255,0.12);
  transform: translateY(-2px);
}



/* === Secondary background bar with UnipayWeb title === */
.fut-secondary-bar {
  position: fixed !important;
  top: 12px;
  left: 50% !important;
  transform: translateX(-50%) !important;
  width: min(1200px, calc(100% - 32px));
  height: var(--fut-menu-height, 88px);
  z-index: 99980 !important; /* behind primary menu (which uses higher z-index) */
  pointer-events: none; /* do not block clicks */
  display: flex;
  align-items: center;
  justify-content: flex-start;
  padding: 0 18px;
  border-radius: 14px;
  background: transparent;
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
  mix-blend-mode: normal;
  opacity: 1;
}

/* Secondary brand element inside secondary bar */
.fut-secondary-bar .unipay-brand-secondary {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: #E6F7FF;
  font-weight: 900;
  font-size: calc(0.95rem * 4) !important; /* keep same size as primary brand */
  letter-spacing: 0.8px;
  padding: 6px 10px;
  border-radius: 8px;
  background: transparent;
  pointer-events: none; /* ensure clicks pass through to primary menu */
  mix-blend-mode: screen;
  text-shadow: 0 6px 24px rgba(58,141,255,0.12);
}

/* Logo mark */
.fut-secondary-bar .logo-mark-secondary {
  width:20px; height:20px; border-radius:5px;
  background: linear-gradient(135deg, rgba(58,141,255,1), rgba(124,58,237,1));
  box-shadow: 0 8px 30px rgba(58,141,255,0.12), inset 0 -4px 8px rgba(255,255,255,0.06);
  pointer-events: none;
}

/* Eruption flame animation for the secondary brand (strong, translucent blinking) */
@keyframes unipayEruption {
  0% { transform: translateY(0) scale(1); opacity: 0.85; filter: drop-shadow(0 0 0 rgba(58,141,255,0)); }
  20% { transform: translateY(-3px) scale(1.02); opacity: 1; filter: drop-shadow(0 10px 40px rgba(58,141,255,0.25)); }
  50% { transform: translateY(-6px) scale(1.04); opacity: 1; filter: drop-shadow(0 18px 60px rgba(58,141,255,0.35)); }
  80% { transform: translateY(-3px) scale(1.02); opacity: 1; filter: drop-shadow(0 10px 40px rgba(58,141,255,0.25)); }
  100% { transform: translateY(0) scale(1); opacity: 0.9; filter: drop-shadow(0 0 0 rgba(58,141,255,0)); }
}

/* Apply continuous eruption effect with subtle pulsating transparency of text */
.unipay-brand-secondary {
  animation: unipayEruption 1600ms ease-in-out infinite;
  -webkit-animation: unipayEruption 1600ms ease-in-out infinite;
  mix-blend-mode: screen;
  color: rgba(230,247,255,0.95);
  text-shadow: 0 8px 36px rgba(58,141,255,0.24), 0 2px 8px rgba(0,0,40,0.45);
  pointer-events: none;
}

/* Flicker overlay for the text (transparent blinking) */
.unipay-brand-secondary::after {
  content: attr(data-text);
  position: absolute;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  color: rgba(200,240,255,0.15);
  filter: blur(6px);
  mix-blend-mode: overlay;
  animation: unipayEruption 1600ms ease-in-out infinite;
  pointer-events: none;
  transform-origin: left center;
}

/* ensure secondary bar does not interfere with layout on small screens */
@media (max-width: 720px){
  .fut-secondary-bar {
  position: fixed !important;
  top: 12px;
  left: 50% !important;
  transform: translateX(-50%) !important;
  width: min(1200px, calc(100% - 32px));
  height: var(--fut-menu-height, 88px);
  z-index: 99980 !important; /* behind primary menu (which uses higher z-index) */
  pointer-events: none; /* do not block clicks */
  display: flex;
  align-items: center;
  justify-content: flex-start;
  padding: 0 18px;
  border-radius: 14px;
  background: transparent;
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
  mix-blend-mode: normal;
  opacity: 1;
}
  .fut-secondary-bar .unipay-brand-secondary { font-size: calc(0.95rem * 2.2) !important; }
}

/* ensure primary menu stays interactive above secondary bar */
.fut-topbar, .topbar, .menu-bar, .menu { z-index: 99990 !important; pointer-events: auto !important; }

/* ensure content still visible under transparent bars */
body.responsive-enabled { padding-top: calc(var(--fut-menu-height) + 10px) !important; }



/* Override: pages without topbar should start at very top (no white gap) */
body.responsive-enabled.no-topbar-offset {
  padding-top: 0 !important;
}
body.responsive-enabled.no-topbar-offset main,
body.responsive-enabled.no-topbar-offset .page,
body.responsive-enabled.no-topbar-offset .site-container,
body.responsive-enabled.no-topbar-offset .content,
body.responsive-enabled.no-topbar-offset #app {
  padding-top: 0 !important;
  margin-top: 0 !important;
}


/* === CONVERSATION HEADER STRUCTURE (INJECTED – DO NOT REMOVE) === */
.conversation-header-grid {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 12px;
}

.conversation-header-center {
  display: flex;
  justify-content: center;
}

.conversation-count {
  padding: 4px 12px;
  border-radius: 14px;
  background: rgba(0, 180, 255, 0.18);
  color: #00eaff;
  font-size: 13px;
  font-weight: 600;
  white-space: nowrap;
  box-shadow: 0 0 8px rgba(0, 200, 255, 0.35);
}

.conversation-header {
  overflow: visible;
  z-index: 2;
}


/* === SIDEBAR PANELS CORE (PHASE 2) === */
.sidebar-panel {
  position: fixed;
  top: 0;
  left: 72px;
  width: calc(100% - 72px);
  height: 100vh;
  z-index: 200;
}
.sidebar-panel-active { display: block !important; }

.unipay-primary-page-title {
  margin: 12px clamp(14px, 3vw, 34px) 20px;
  color: #eafcff;
  font-size: clamp(1.35rem, 3vw, 2rem);
  line-height: 1.2;
}

@media (max-width: 900px), (pointer: coarse) {
  main button,
  main input:not([type="checkbox"]):not([type="radio"]),
  main select,
  main textarea,
  [role="dialog"] button,
  [role="dialog"] input:not([type="checkbox"]):not([type="radio"]),
  [role="dialog"] select,
  [role="dialog"] textarea { min-height: 44px; }
  main label:has(> input[type="checkbox"]),
  main label:has(> input[type="radio"]),
  [role="dialog"] label:has(input[type="checkbox"]),
  [role="dialog"] label:has(input[type="radio"]) { min-height: 44px; display: inline-flex; align-items: center; gap: 8px; }
}
