/* Pixel3DLab global theme for existing forum, tools, dashboard and account pages.
   Loaded by index.php after the original page CSS; no legacy PHP logic is changed. */
:root {
  --pl-legacy-accent: #3487f6;
  --pl-legacy-cyan: #55e1ff;
  --pl-legacy-glass-light: rgba(255,255,255,.67);
  --pl-legacy-glass-strong-light: rgba(255,255,255,.86);
  --pl-legacy-line-light: rgba(100,116,139,.20);
}
[data-theme="dark"] {
  --pl-legacy-glass-light: rgba(15,23,42,.68);
  --pl-legacy-glass-strong-light: rgba(15,23,42,.90);
  --pl-legacy-line-light: rgba(148,163,184,.18);
}
html:has(body.pxh-legacy-page) { scroll-behavior: smooth; }
body.pxh-legacy-page {
  min-height: 100vh !important;
  padding-top: 76px !important;
  padding-bottom: 0 !important;
  color: var(--text-main) !important;
  background:
    radial-gradient(circle at 8% 0%, rgba(62,160,255,.10), transparent 27%),
    radial-gradient(circle at 94% 18%, rgba(122,134,255,.08), transparent 25%),
    var(--bg-color) !important;
  overflow-x: clip !important;
}
body.pxh-legacy-page::before {
  background-image: linear-gradient(to right, rgba(71,115,166,.055) 1px, transparent 1px), linear-gradient(to bottom, rgba(71,115,166,.055) 1px, transparent 1px) !important;
  background-size: 34px 34px !important;
  opacity: .7;
  pointer-events: none !important;
}
body.pxh-legacy-page a { text-underline-offset: 3px; }
body.pxh-legacy-page a:not(.btn):not(.nav-btn):not(.dropdown-item):not(.m-nav-btn) { color: var(--color-blue); }

/* Fixed glass navigation */
body.pxh-legacy-page .top-bar {
  position: fixed !important;
  inset: 0 0 auto 0 !important;
  z-index: 11000 !important;
  display: flex !important;
  align-items: center !important;
  justify-content: flex-end !important;
  width: 100% !important;
  height: 76px !important;
  padding: 0 24px 0 194px !important;
  background: var(--header-bg) !important;
  border-bottom: 1px solid var(--header-border) !important;
  box-shadow: 0 8px 28px rgba(15,23,42,.055) !important;
  backdrop-filter: blur(22px) saturate(140%) !important;
  -webkit-backdrop-filter: blur(22px) saturate(140%) !important;
}
body.pxh-legacy-page .logo-container {
  position: absolute !important;
  top: 50% !important;
  left: 22px !important;
  transform: translateY(-50%) !important;
  z-index: 11002 !important;
  display: flex !important;
  align-items: center !important;
  gap: 9px !important;
  white-space: nowrap !important;
}
body.pxh-legacy-page .logo-container img {
  display: block !important;
  width: 44px !important;
  height: 44px !important;
  max-width: 44px !important;
  object-fit: contain !important;
  filter: none !important;
}
body.pxh-legacy-page .logo-container::after {
  content: "Pixel3DLab";
  color: var(--text-main) !important;
  font-size: 18px !important;
  line-height: 1 !important;
  font-weight: 850 !important;
  letter-spacing: -.045em !important;
}
body.pxh-legacy-page .desktop-nav { display: flex !important; align-items: center !important; justify-content: flex-end !important; gap: 5px !important; min-width: 0 !important; }
body.pxh-legacy-page .nav-btn {
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  gap: 7px !important;
  min-height: 40px !important;
  padding: 9px 11px !important;
  border: 1px solid transparent !important;
  border-radius: 10px !important;
  background: transparent !important;
  color: var(--text-main) !important;
  box-shadow: none !important;
  font-size: 13px !important;
  font-weight: 700 !important;
  text-decoration: none !important;
  white-space: nowrap !important;
  cursor: pointer !important;
  transition: background .2s ease, border-color .2s ease, color .2s ease !important;
}
body.pxh-legacy-page .nav-btn:hover,
body.pxh-legacy-page .nav-btn:focus-visible {
  background: rgba(62,160,255,.095) !important;
  border-color: rgba(62,160,255,.2) !important;
  color: var(--color-blue) !important;
  transform: none !important;
}
body.pxh-legacy-page .dropdown { position: relative !important; display: inline-flex !important; align-items: center !important; }
body.pxh-legacy-page .dropdown::after {
  content: "" !important;
  position: absolute !important;
  top: 100% !important;
  left: 0 !important;
  right: 0 !important;
  height: 13px !important;
  display: block !important;
  background: transparent !important;
}
body.pxh-legacy-page .dropdown-content {
  position: absolute !important;
  top: calc(100% + 8px) !important;
  right: 0 !important;
  z-index: 12000 !important;
  min-width: 235px !important;
  max-height: min(72vh, 620px) !important;
  overflow-y: auto !important;
  padding: 8px !important;
  gap: 3px !important;
  border: 1px solid var(--pl-legacy-line-light) !important;
  border-radius: 14px !important;
  background: var(--pl-legacy-glass-strong-light) !important;
  box-shadow: 0 22px 60px rgba(15,23,42,.18) !important;
  backdrop-filter: blur(24px) saturate(135%) !important;
  -webkit-backdrop-filter: blur(24px) saturate(135%) !important;
}
body.pxh-legacy-page .dropdown-item {
  display: flex !important;
  align-items: center !important;
  gap: 10px !important;
  padding: 10px 12px !important;
  border-radius: 9px !important;
  color: var(--text-main) !important;
  font-size: 13px !important;
  text-decoration: none !important;
}
body.pxh-legacy-page .dropdown-item:hover,
body.pxh-legacy-page .dropdown-item:focus-visible { background: rgba(62,160,255,.10) !important; color: var(--color-blue) !important; }
body.pxh-legacy-page .dropdown-item svg { width: 17px !important; height: 17px !important; color: var(--color-blue) !important; flex: 0 0 auto !important; }

/* Page layout and transparent glass surfaces */
body.pxh-legacy-page .container {
  position: relative !important;
  z-index: 1 !important;
  width: min(1240px, calc(100% - 36px)) !important;
  max-width: 1240px !important;
  margin: 34px auto 54px !important;
  padding: 0 !important;
  display: flex !important;
  flex-wrap: wrap !important;
  align-items: flex-start !important;
  gap: 20px !important;
}
body.pxh-legacy-page .card {
  background: var(--pl-legacy-glass-light) !important;
  color: var(--text-main) !important;
  border: 1px solid var(--pl-legacy-line-light) !important;
  border-radius: 16px !important;
  box-shadow: 0 18px 48px rgba(15,23,42,.075) !important;
  backdrop-filter: blur(18px) saturate(125%) !important;
  -webkit-backdrop-filter: blur(18px) saturate(125%) !important;
  transition: border-color .2s ease, box-shadow .2s ease, background .25s ease !important;
}
body.pxh-legacy-page .card:hover { box-shadow: 0 22px 58px rgba(15,23,42,.11) !important; }
body.pxh-legacy-page .card h2,
body.pxh-legacy-page .card h3,
body.pxh-legacy-page .card h4 { color: var(--text-main) !important; letter-spacing: -.02em; }
body.pxh-legacy-page .card p,
body.pxh-legacy-page .card label { color: var(--text-muted); }
body.pxh-legacy-page .card [style*="background:#f8fafc"],
body.pxh-legacy-page .card [style*="background: #f8fafc"],
body.pxh-legacy-page .card [style*="background:#fff"],
body.pxh-legacy-page .card [style*="background: #fff"],
body.pxh-legacy-page .card [style*="background:#ffffff"],
body.pxh-legacy-page .card [style*="background: #ffffff"],
body.pxh-legacy-page .card [style*="background:#f1f5f9"],
body.pxh-legacy-page .card [style*="background: #f1f5f9"] {
  background: var(--pl-legacy-glass-strong-light) !important;
  color: var(--text-main) !important;
  border-color: var(--pl-legacy-line-light) !important;
}
body.pxh-legacy-page .card [style*="color:#475569"],
body.pxh-legacy-page .card [style*="color: #475569"],
body.pxh-legacy-page .card [style*="color:#334155"],
body.pxh-legacy-page .card [style*="color: #334155"] { color: var(--text-main) !important; }
body.pxh-legacy-page .forum-list-item { border-color: var(--pl-legacy-line-light) !important; color: var(--text-main) !important; }
body.pxh-legacy-page .forum-list-item:hover { background: rgba(62,160,255,.06) !important; }
body.pxh-legacy-page .forum-icon-box { background: var(--pl-legacy-glass-strong-light) !important; border: 1px solid var(--pl-legacy-line-light) !important; }
body.pxh-legacy-page .forum-post { border-color: var(--pl-legacy-line-light) !important; }
body.pxh-legacy-page .forum-user-col { border-color: var(--pl-legacy-line-light) !important; }
body.pxh-legacy-page .forum-signature { border-color: var(--pl-legacy-line-light) !important; }

/* Forms, buttons, alerts and chat */
body.pxh-legacy-page input[type="text"],
body.pxh-legacy-page input[type="password"],
body.pxh-legacy-page input[type="email"],
body.pxh-legacy-page input[type="number"],
body.pxh-legacy-page input[type="file"],
body.pxh-legacy-page select,
body.pxh-legacy-page textarea {
  color: var(--text-main) !important;
  background: var(--input-bg) !important;
  border: 1px solid var(--input-border) !important;
  border-radius: 10px !important;
  box-shadow: none !important;
}
body.pxh-legacy-page input:focus,
body.pxh-legacy-page select:focus,
body.pxh-legacy-page textarea:focus { border-color: var(--pl-legacy-accent) !important; box-shadow: 0 0 0 3px rgba(52,135,246,.16) !important; outline: none; }
body.pxh-legacy-page .btn {
  border-radius: 10px !important;
  min-height: 40px;
  padding: 11px 17px !important;
  box-shadow: 0 5px 14px rgba(52,135,246,.12) !important;
  font-weight: 700 !important;
  text-decoration: none !important;
  transition: transform .18s ease, filter .18s ease, box-shadow .18s ease !important;
}
body.pxh-legacy-page .btn:hover { filter: brightness(1.04); transform: translateY(-1px) !important; }
body.pxh-legacy-page .alert { border-radius: 12px !important; }
body.pxh-legacy-page .ticket-chat,
body.pxh-legacy-page .chat-container,
body.pxh-legacy-page .chat-users,
body.pxh-legacy-page .chat-box,
body.pxh-legacy-page .ticket-input,
body.pxh-legacy-page .chat-input-area {
  background: var(--pl-legacy-glass-light) !important;
  color: var(--text-main) !important;
  border-color: var(--pl-legacy-line-light) !important;
}
body.pxh-legacy-page .chat-user-item { color: var(--text-main) !important; border-color: var(--pl-legacy-line-light) !important; }
body.pxh-legacy-page .chat-user-item:hover { background: rgba(62,160,255,.075) !important; }
body.pxh-legacy-page .tmsg-customer { background: var(--pl-legacy-glass-strong-light) !important; color: var(--text-main) !important; border-color: var(--pl-legacy-line-light) !important; }

/* Accessible tools and modal dialogs */
body.pxh-legacy-page .a11y-widget-btn {
  position: fixed !important; left: 20px !important; bottom: 20px !important; z-index: 14000 !important;
  width: 54px !important; height: 54px !important; border-radius: 50% !important;
  background: var(--pl-legacy-glass-strong-light) !important; color: var(--text-main) !important;
  border: 1px solid rgba(62,160,255,.34) !important; backdrop-filter: blur(20px) !important;
}
body.pxh-legacy-page .a11y-panel { z-index: 14001 !important; background: var(--pl-legacy-glass-strong-light) !important; border-color: var(--pl-legacy-line-light) !important; }
body.pxh-legacy-page .modal-overlay { z-index: 15000 !important; }
body.pxh-legacy-page .modal-content { background: var(--pl-legacy-glass-strong-light) !important; color: var(--text-main) !important; border: 1px solid var(--pl-legacy-line-light) !important; backdrop-filter: blur(24px) !important; }

/* Convert the old narrow sticky footer into a proper end-of-page footer. */
body.pxh-legacy-page .site-footer {
  position: relative !important;
  inset: auto !important;
  width: 100% !important;
  min-height: 150px !important;
  height: auto !important;
  margin-top: 58px !important;
  padding: 42px max(24px, calc((100vw - 1240px)/2)) !important;
  display: flex !important;
  flex-wrap: wrap !important;
  justify-content: space-between !important;
  align-items: center !important;
  gap: 18px !important;
  background: var(--header-bg) !important;
  border-top: 1px solid var(--header-border) !important;
  box-shadow: none !important;
  color: var(--text-muted) !important;
  backdrop-filter: blur(22px) !important;
}
body.pxh-legacy-page .site-footer a { color: var(--color-blue) !important; }

@media (max-width: 1050px) {
  body.pxh-legacy-page .top-bar { padding-left: 175px !important; padding-right: 12px !important; }
  body.pxh-legacy-page .nav-btn { padding: 8px 9px !important; font-size: 12px !important; }
  body.pxh-legacy-page .logo-container::after { font-size: 16px !important; }
}
@media (max-width: 768px) {
  body.pxh-legacy-page { padding-top: 64px !important; padding-bottom: 84px !important; }
  body.pxh-legacy-page .top-bar { height: 64px !important; min-height: 64px !important; padding: 0 14px !important; justify-content: flex-end !important; }
  body.pxh-legacy-page .logo-container { left: 14px !important; top: 50% !important; transform: translateY(-50%) !important; }
  body.pxh-legacy-page .logo-container img { height: 40px !important; width: 40px !important; max-width: 40px !important; }
  body.pxh-legacy-page .logo-container::after { font-size: 16px !important; }
  body.pxh-legacy-page .desktop-nav { display: none !important; }
  body.pxh-legacy-page .mobile-nav-container { position: fixed !important; bottom: 0 !important; left: 0 !important; z-index: 13000 !important; height: 70px !important; background: var(--pl-legacy-glass-strong-light) !important; border-color: var(--pl-legacy-line-light) !important; backdrop-filter: blur(24px) !important; }
  body.pxh-legacy-page .container { width: calc(100% - 24px) !important; margin: 24px auto 35px !important; gap: 14px !important; }
  body.pxh-legacy-page .card { padding: 18px !important; }
  body.pxh-legacy-page .a11y-widget-btn { left: 12px !important; bottom: 82px !important; width: 48px !important; height: 48px !important; }
  body.pxh-legacy-page .a11y-panel { left: 12px !important; bottom: 139px !important; width: calc(100vw - 24px) !important; max-height: 68vh !important; }
  body.pxh-legacy-page .site-footer { min-height: 125px !important; padding: 28px 18px !important; margin-top: 35px !important; justify-content: flex-start !important; }
  body.pxh-legacy-page .chat-container { height: calc(100dvh - 230px) !important; }
}
@media (prefers-reduced-motion: reduce) {
  body.pxh-legacy-page *, body.pxh-legacy-page *::before, body.pxh-legacy-page *::after { scroll-behavior: auto !important; transition-duration: .01ms !important; animation-duration: .01ms !important; }
}
