/* ===== LEGALITY OS™ 5.3 · Build v36 — Centered Login, Light-to-Dark Purple Flicker & Working Light/Dark Theme ===== */

/* 1. Perfectly Centered Login Screen */
html[data-nx-build] #gate,
html[data-nx-build] #gate.nx-gate {
  position: fixed !important;
  inset: 0 !important;
  width: 100vw !important;
  height: 100vh !important;
  min-height: 100vh !important;
  display: flex !important;
  flex-direction: column !important;
  align-items: center !important;
  justify-content: center !important;
  padding: 24px !important;
  margin: 0 !important;
  box-sizing: border-box !important;
  z-index: 100 !important;
}
html[data-nx-build] #gate[hidden],
html[data-nx-build] #gate.nx-gate[hidden] {
  display: none !important;
}

/* Hide legacy side-art & hide the unwanted footer disclaimer */
html[data-nx-build] #gate .gate-art,
html[data-nx-build] #gate .nx-gate-floor,
html[data-nx-build] #gate .nx-gate-scan,
html[data-nx-build] #gate .orb,
html[data-nx-build] #gate .nx-gate-mark,
html[data-nx-build] #gate .gate-fine {
  display: none !important;
}

html[data-nx-build] #gate .gate-panel {
  width: min(520px, 92vw) !important;
  max-width: 520px !important;
  margin: auto !important;
  padding: 38px 40px 34px !important;
  border-radius: 20px !important;
  background: linear-gradient(180deg, rgba(11, 16, 33, 0.94), rgba(16, 12, 38, 0.96)) !important;
  border: 1px solid rgba(192, 132, 252, 0.45) !important;
  box-shadow:
    0 0 0 1px rgba(168, 85, 247, 0.18),
    0 0 60px rgba(126, 34, 206, 0.32),
    0 28px 80px rgba(0, 0, 0, 0.78) !important;
  text-align: center !important;
  position: relative !important;
}

:root:not([data-theme="dark"]) html[data-nx-build] #gate .gate-panel,
html:not([data-theme="dark"]) #gate .gate-panel {
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.96), rgba(245, 240, 255, 0.96)) !important;
  border: 1.5px solid rgba(126, 34, 206, 0.45) !important;
  box-shadow: 0 24px 68px rgba(88, 28, 135, 0.22), 0 0 40px rgba(168, 85, 247, 0.2) !important;
  color: #141229 !important;
}

.v35-gate-brand {
  border-bottom: 1px solid rgba(192, 132, 252, 0.28);
  padding-bottom: 14px;
  margin-bottom: 16px;
  text-align: center !important;
}
.v35-gate-corp {
  display: block;
  font: 700 15px/1.35 "Times New Roman", Times, serif;
  letter-spacing: 0.05em;
  color: #d8b4fe;
  text-transform: uppercase;
  margin-bottom: 6px;
}
html:not([data-theme="dark"]) .v35-gate-corp {
  color: #581c87;
}

/* 2. Light-to-Dark Purple Flickering Glow for LEGALITY OS™ 5.3 */
@keyframes losPurpleFlicker {
  0%, 100% {
    color: #f3e8ff;
    text-shadow:
      0 0 8px #e9d5ff,
      0 0 18px #c084fc,
      0 0 34px #9333ea,
      0 0 58px #581c87;
    opacity: 1;
  }
  18% {
    color: #d8b4fe;
    text-shadow:
      0 0 6px #c084fc,
      0 0 14px #7e22ce,
      0 0 28px #4c1d95;
    opacity: 0.92;
  }
  22% {
    color: #9333ea;
    text-shadow:
      0 0 4px #6b21a8,
      0 0 12px #3b0764;
    opacity: 0.76;
  }
  26% {
    color: #f5d0fe;
    text-shadow:
      0 0 10px #f0abfc,
      0 0 24px #a855f7,
      0 0 46px #6b21a8;
    opacity: 1;
  }
  54% {
    color: #c084fc;
    text-shadow:
      0 0 7px #a855f7,
      0 0 20px #581c87,
      0 0 38px #2e1065;
    opacity: 0.88;
  }
  58% {
    color: #6b21a8;
    text-shadow:
      0 0 4px #4c1d95,
      0 0 10px #2e1065;
    opacity: 0.72;
  }
  63% {
    color: #f3e8ff;
    text-shadow:
      0 0 12px #e9d5ff,
      0 0 26px #c084fc,
      0 0 50px #7e22ce;
    opacity: 1;
  }
}

.v35-gate-os {
  display: block;
  font: 700 32px/1.15 "Times New Roman", Times, serif !important;
  letter-spacing: 0.08em !important;
  color: #f3e8ff;
  animation: losPurpleFlicker 3.2s infinite ease-in-out !important;
}

html[data-nx-build] #gate .gate-panel h2 {
  text-align: center !important;
  margin: 0 0 10px !important;
  font: 700 30px/1.12 "Times New Roman", Times, serif !important;
  letter-spacing: 0.08em !important;
}
html:not([data-theme="dark"]) #gate .gate-panel h2 {
  color: #2e1065 !important;
  text-shadow: none !important;
}
html:not([data-theme="dark"]) .v35-gate-auth {
  color: #2e1065 !important;
}
html:not([data-theme="dark"]) #gate .gate-panel label {
  color: #1e1b4b !important;
}
html:not([data-theme="dark"]) #gate .gate-panel input {
  background: #ffffff !important;
  color: #141229 !important;
  border-color: rgba(126, 34, 206, 0.4) !important;
}

/* 3. Fix Light Mode vs Dark Mode Across Body, Panels & Navigation */
html[data-los-v33]:not([data-theme="dark"]) {
  --v33-bg: #eef3fb;
  --v33-glass: rgba(255, 255, 255, 0.9);
  --v33-glass2: rgba(246, 249, 255, 0.94);
  --v33-edge: rgba(39, 82, 194, 0.28);
  --v33-edge2: rgba(39, 82, 194, 0.16);
  --v33-text: #101c33;
  --v33-muted: #3b4a63;
  --v33-teal: #0b6c4f;
  --v33-cyan: #2752c2;
  --v33-btn: #2752c2;
}
html[data-los-v33]:not([data-theme="dark"]) body {
  background:
    radial-gradient(ellipse 60% 45% at 10% 5%, rgba(168, 85, 247, 0.14), transparent 70%),
    radial-gradient(ellipse 55% 45% at 92% 12%, rgba(39, 82, 194, 0.12), transparent 70%),
    linear-gradient(180deg, #f6f9fe 0%, #eaf0fa 100%) fixed !important;
  background-color: #eef3fb !important;
  color: #101c33 !important;
}
html[data-los-v33]:not([data-theme="dark"]) #gate.nx-gate {
  background:
    radial-gradient(ellipse 65% 55% at 20% 20%, rgba(168, 85, 247, 0.22), transparent 68%),
    radial-gradient(ellipse 60% 50% at 80% 75%, rgba(59, 130, 246, 0.18), transparent 66%),
    linear-gradient(160deg, #f3e8ff 0%, #eef2ff 50%, #e0e7ff 100%) !important;
}
html[data-los-v33]:not([data-theme="dark"]) .nx-shell .top {
  background: rgba(255, 255, 255, 0.88) !important;
  border-bottom: 1px solid rgba(39, 82, 194, 0.2) !important;
  color: #101c33 !important;
}
html[data-los-v33]:not([data-theme="dark"]) .panel,
html[data-los-v33]:not([data-theme="dark"]) .nx-panel,
html[data-los-v33]:not([data-theme="dark"]) .mc-panel,
html[data-los-v33]:not([data-theme="dark"]) .v32-hud-card {
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.94), rgba(246, 250, 255, 0.9)) !important;
  border: 1px solid rgba(39, 82, 194, 0.22) !important;
  box-shadow: 0 10px 28px rgba(39, 82, 194, 0.08) !important;
  color: #101c33 !important;
}
html[data-los-v33]:not([data-theme="dark"]) .v32-nav-dd-menu {
  background: #ffffff !important;
  border-color: #2752c2 !important;
  box-shadow: 0 16px 40px rgba(16, 28, 51, 0.18) !important;
}
html[data-los-v33]:not([data-theme="dark"]) .v34-qbtn {
  background: linear-gradient(165deg, #ffffff, #f3f7ff) !important;
  border-color: rgba(39, 82, 194, 0.28) !important;
  color: #101c33 !important;
}
html[data-los-v33]:not([data-theme="dark"]) .v34-qbtn strong {
  color: #101c33 !important;
}
html[data-los-v33]:not([data-theme="dark"]) .v34-qbtn small {
  color: #581c87 !important;
}
html[data-los-v33]:not([data-theme="dark"]) .v34-qbtn span {
  color: #3b4a63 !important;
}
html[data-los-v33]:not([data-theme="dark"]) .v34-stat-box {
  background: #f5f8ff !important;
  border-color: rgba(39, 82, 194, 0.22) !important;
}
html[data-los-v33]:not([data-theme="dark"]) .v34-stat-box b {
  color: #581c87 !important;
}
html[data-los-v33]:not([data-theme="dark"]) .v34-stat-box small {
  color: #3b4a63 !important;
}

/* ===== v36.3 Compact Eye-Friendly Neon Login, Justified Text & Duplicate Removal ===== */
html[data-nx-build] #gate .gate-panel {
  width: min(420px, 90vw) !important;
  max-width: 420px !important;
  padding: 26px 28px 22px !important;
  border-radius: 16px !important;
  border: 1.5px solid rgba(168, 85, 247, 0.55) !important;
  box-shadow:
    0 0 14px rgba(139, 92, 246, 0.32),
    0 0 38px rgba(45, 212, 191, 0.16),
    0 20px 55px rgba(0, 0, 0, 0.68) !important;
}

:root:not([data-theme="dark"]) html[data-nx-build] #gate .gate-panel,
html:not([data-theme="dark"]) #gate .gate-panel {
  border: 1.5px solid rgba(126, 34, 206, 0.52) !important;
  box-shadow:
    0 0 16px rgba(168, 85, 247, 0.25),
    0 0 36px rgba(39, 82, 194, 0.14),
    0 18px 48px rgba(46, 16, 101, 0.18) !important;
}

.v35-gate-brand {
  padding-bottom: 10px !important;
  margin-bottom: 12px !important;
}
.v35-gate-corp {
  font-size: 13.5px !important;
  margin-bottom: 4px !important;
}
.v35-gate-os {
  font-size: 26px !important;
}
html[data-nx-build] #gate .gate-panel h2 {
  font-size: 24px !important;
  margin: 0 0 8px !important;
}

/* Justified text under EXECUTIVE ACCESS */
html[data-nx-build] #gate .gate-panel .v35-gate-auth,
html[data-nx-build] #gate .gate-panel .v35-gate-intake-alert {
  font-size: 14px !important;
  line-height: 1.48 !important;
  text-align: justify !important;
  text-align-last: left !important;
  hyphens: auto;
}
html[data-nx-build] #gate .gate-panel .v35-gate-auth {
  margin: 6px 0 10px !important;
}
html[data-nx-build] #gate .gate-panel .v35-gate-intake-alert {
  padding: 10px 12px !important;
  margin: 0 0 12px !important;
}

/* Version & Federal Statute Footer directly under the red New Client Intake Form button */
.v36-under-intake-meta {
  margin-top: 12px;
  padding-top: 10px;
  border-top: 1px solid rgba(168, 85, 247, 0.24);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 3px;
  text-align: center !important;
}
.v36-under-intake-ver {
  font: 700 13px "Times New Roman", Times, serif;
  letter-spacing: 0.06em;
  color: #d8b4fe;
}
.v36-under-intake-statute {
  font: 600 12px ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  letter-spacing: 0.08em;
  color: #7dd3fc;
}
html:not([data-theme="dark"]) .v36-under-intake-ver {
  color: #581c87;
}
html:not([data-theme="dark"]) .v36-under-intake-statute {
  color: #1e3a8a;
}

/* Hide all duplicate bottom watermarks / footers on the login gate */
#v34WatermarkPill,
.v34-build-Watermark,
#gate .gate-fine,
#gate .gate-year,
#gate .gate-org,
#gate .wordmark {
  display: none !important;
}

/* ===== v36.4 Ultra-Compact Neon Glowing Login Box, Smaller Buttons & White Footer Meta ===== */
@keyframes losCardNeonPulse {
  0%, 100% {
    border-color: #c084fc;
    box-shadow:
      0 0 8px rgba(192, 132, 252, 0.85),
      0 0 22px rgba(168, 85, 247, 0.65),
      0 0 46px rgba(45, 212, 191, 0.38),
      inset 0 0 14px rgba(168, 85, 247, 0.22);
  }
  50% {
    border-color: #38bdf8;
    box-shadow:
      0 0 10px rgba(56, 189, 248, 0.9),
      0 0 28px rgba(139, 92, 246, 0.72),
      0 0 58px rgba(168, 85, 247, 0.48),
      inset 0 0 18px rgba(56, 189, 248, 0.25);
  }
}

html[data-nx-build] #gate .gate-panel {
  width: min(330px, 88vw) !important;
  max-width: 330px !important;
  padding: 16px 18px 14px !important;
  border-radius: 14px !important;
  background: linear-gradient(180deg, rgba(8, 13, 28, 0.94), rgba(14, 10, 34, 0.96)) !important;
  border: 2px solid #c084fc !important;
  animation: losCardNeonPulse 3.2s infinite ease-in-out !important;
}

:root:not([data-theme="dark"]) html[data-nx-build] #gate .gate-panel,
html:not([data-theme="dark"]) #gate .gate-panel {
  background: linear-gradient(180deg, rgba(16, 20, 42, 0.92), rgba(22, 14, 48, 0.95)) !important;
  color: #ffffff !important;
  border: 2px solid #c084fc !important;
  animation: losCardNeonPulse 3.2s infinite ease-in-out !important;
}

.v35-gate-brand {
  padding-bottom: 6px !important;
  margin-bottom: 8px !important;
}
.v35-gate-corp {
  font-size: 10.5px !important;
  line-height: 1.25 !important;
  letter-spacing: 0.04em !important;
  color: #e9d5ff !important;
  margin-bottom: 2px !important;
}
.v35-gate-os {
  font-size: 20px !important;
  line-height: 1.1 !important;
}

html[data-nx-build] #gate .gate-panel h2 {
  font-size: 17px !important;
  margin: 0 0 6px !important;
  letter-spacing: 0.07em !important;
  color: #ffffff !important;
}

html[data-nx-build] #gate .gate-panel .v35-gate-auth {
  font-size: 11.5px !important;
  line-height: 1.38 !important;
  margin: 4px 0 8px !important;
  color: #e2e8f0 !important;
  text-align: justify !important;
  text-align-last: left !important;
}

html[data-nx-build] #gate .gate-panel .v35-gate-intake-alert {
  font-size: 11.5px !important;
  line-height: 1.36 !important;
  padding: 7px 9px !important;
  margin: 0 0 8px !important;
  border-radius: 7px !important;
  text-align: justify !important;
  text-align-last: left !important;
}

html[data-nx-build] #gate .gate-panel label {
  font-size: 11.5px !important;
  margin-bottom: 3px !important;
  color: #f1f5f9 !important;
}

html[data-nx-build] #gate .gate-panel input {
  min-height: 32px !important;
  height: 32px !important;
  padding: 4px 9px !important;
  font-size: 13px !important;
  border-radius: 7px !important;
  background: rgba(3, 9, 20, 0.92) !important;
  color: #ffffff !important;
  border: 1px solid rgba(192, 132, 252, 0.5) !important;
}

/* Smaller Microsoft Sign-In Button & Smaller Red Intake Button */
html[data-nx-build] #gate .ms-btn {
  min-height: 34px !important;
  height: 34px !important;
  padding: 5px 12px !important;
  margin-top: 8px !important;
  font-size: 13px !important;
  border-radius: 7px !important;
  box-shadow: 0 0 14px rgba(45, 212, 191, 0.35) !important;
}

.v35-intake-btn {
  min-height: 34px !important;
  height: 34px !important;
  padding: 5px 12px !important;
  margin-top: 7px !important;
  font-size: 12.5px !important;
  border-radius: 7px !important;
  box-shadow: 0 0 14px rgba(239, 68, 68, 0.38) !important;
}

/* Pure White Version & Federal Statute Text Under the Red Intake Button */
.v36-under-intake-meta {
  margin-top: 8px !important;
  padding-top: 7px !important;
  border-top: 1px solid rgba(192, 132, 252, 0.3) !important;
  gap: 2px !important;
}
.v36-under-intake-ver,
.v36-under-intake-statute,
html:not([data-theme="dark"]) .v36-under-intake-ver,
html:not([data-theme="dark"]) .v36-under-intake-statute {
  color: #ffffff !important;
  font-size: 11px !important;
  line-height: 1.3 !important;
  text-shadow: 0 0 8px rgba(255, 255, 255, 0.35) !important;
}

/* ===== v36.6 White-to-Red Neon Glow on New Client Intake Notice ===== */
@keyframes losWhiteToRedGlow {
  0%, 100% {
    color: #ffffff;
    text-shadow:
      0 0 6px #ffffff,
      0 0 14px #fecaca,
      0 0 26px #ef4444;
    border-color: rgba(255, 255, 255, 0.75);
    box-shadow:
      0 0 10px rgba(255, 255, 255, 0.35),
      inset 0 0 8px rgba(239, 68, 68, 0.25);
  }
  50% {
    color: #ff4d4d;
    text-shadow:
      0 0 6px #ff4d4d,
      0 0 16px #ef4444,
      0 0 32px #dc2626,
      0 0 48px #991b1b;
    border-color: rgba(239, 68, 68, 0.9);
    box-shadow:
      0 0 16px rgba(239, 68, 68, 0.55),
      inset 0 0 12px rgba(220, 38, 38, 0.35);
  }
}

html[data-nx-build] #gate .gate-panel .v35-gate-intake-alert {
  background: rgba(127, 29, 29, 0.28) !important;
  border: 1px solid rgba(248, 113, 113, 0.75) !important;
  animation: losWhiteToRedGlow 2.4s infinite ease-in-out !important;
}
