/* GosRadar — Interactive Cartoon Grumpy Panda Sprite Mascot on /auth, /auth/google-start, /auth/onboarding */

.lumi-auth-wrap {
  max-width: 920px;
}

/* 2-column split card: Panda mascot on the left, clean form on the right */
.lumi-split-card {
  display: grid;
  grid-template-columns: 340px minmax(0, 1fr);
  gap: 0;
  padding: 0;
  overflow: hidden;
  border-radius: 18px;
}

.lumi-side-panel {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 26px 22px;
  background: radial-gradient(circle at 50% 34%, rgba(16, 185, 129, 0.14), rgba(15, 23, 42, 0.45) 75%);
  border-right: 1px solid var(--line);
  text-align: center;
}

html[data-theme="light"] .lumi-side-panel {
  background: radial-gradient(circle at 50% 34%, rgba(22, 163, 74, 0.12), rgba(241, 245, 249, 0.94) 76%);
}

.lumi-form-panel {
  padding: 26px 28px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  min-width: 0;
}

.lumi-auth-header {
  text-align: center;
  margin-bottom: 4px;
}

.lumi-brand-row {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 4px;
}

.lumi-brand-title {
  font-size: 20px;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: var(--text);
}

.lumi-brand-tag {
  margin: 0;
  font-size: 12px;
  color: var(--muted);
}

.lumi-welcome-title {
  margin: 0 0 4px;
  font-size: 22px;
  font-weight: 800;
  letter-spacing: -0.02em;
  text-align: center;
}

.lumi-welcome-sub {
  margin: 0;
  font-size: 13.5px;
  color: var(--muted);
  text-align: center;
}

/* Panda Mascot Stage + Comic Speech Bubble */
.lumi-hero {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  margin: 4px 0;
  width: 100%;
}

.lumi-cat-stage {
  --lumi-eye-x: 0px;
  --lumi-eye-y: 0px;
  --lumi-head-rot: 0deg;
  --panda-tilt-x: 0deg;
  --panda-tilt-y: 0deg;
  --panda-shift-x: 0px;
  --panda-shift-y: 0px;
  position: relative;
  width: 244px;
  height: 244px;
  display: flex;
  align-items: center;
  justify-content: center;
  user-select: none;
  cursor: pointer;
  touch-action: manipulation;
  -webkit-tap-highlight-color: transparent;
  perspective: 720px;
  transition: transform 0.2s cubic-bezier(0.22, 1, 0.36, 1);
}

.lumi-cat-stage:hover {
  transform: scale(1.035);
}

.lumi-cat-stage:active {
  transform: scale(0.96);
}

.panda-sprite-rig {
  position: relative;
  width: 236px;
  height: 236px;
  transform-style: preserve-3d;
  transform:
    translate3d(var(--panda-shift-x), var(--panda-shift-y), 0)
    rotateX(var(--panda-tilt-x))
    rotateY(var(--panda-tilt-y))
    rotate(var(--lumi-head-rot));
  transition: transform 0.09s ease-out;
  will-change: transform;
}

.panda-sprite-img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: contain;
  opacity: 0;
  transform: scale(0.88);
  pointer-events: none;
  filter: drop-shadow(0 12px 22px rgba(2, 6, 23, 0.34));
  transition: opacity 0.16s ease, transform 0.24s cubic-bezier(0.22, 1.25, 0.36, 1);
  will-change: opacity, transform;
}

html[data-theme="light"] .panda-sprite-img {
  filter: drop-shadow(0 10px 18px rgba(15, 23, 42, 0.16));
}

.panda-sprite-img.is-active {
  opacity: 1;
  transform: scale(1);
}

/* Lively per-scene motion on active sprite */
.lumi-cat-stage.scene-idle .panda-sprite-img.is-active {
  animation: pandaIdleBreathe 3.2s ease-in-out infinite;
}

.lumi-cat-stage.scene-eat_bamboo .panda-sprite-img.is-active {
  animation: pandaChompBounce 0.36s ease-in-out infinite;
}

.lumi-cat-stage.scene-snap_bamboo .panda-sprite-img.is-active {
  animation: pandaRageShake 0.28s ease-in-out infinite;
}

.lumi-cat-stage.scene-tear_tz .panda-sprite-img.is-active {
  animation: pandaTearShake 0.42s ease-in-out infinite;
}

.lumi-cat-stage.scene-roll_joy .panda-sprite-img.is-active {
  animation: pandaJoyWiggle 0.9s ease-in-out infinite;
}

.lumi-cat-stage.is-covering .panda-sprite-img.is-active {
  animation: pandaCoverShiver 0.7s ease-in-out infinite;
}

.lumi-cat-stage.is-peeking .panda-sprite-img.is-active {
  animation: pandaPeekLean 1.8s ease-in-out infinite;
}

@keyframes pandaIdleBreathe {
  0%, 100% { transform: scale(1, 1) translateY(0); }
  50% { transform: scale(1.02, 0.985) translateY(-3px); }
}

@keyframes pandaChompBounce {
  0%, 100% { transform: scale(1, 1) rotate(0deg); }
  50% { transform: scale(1.045, 0.96) rotate(-1.5deg) translateY(2px); }
}

@keyframes pandaRageShake {
  0%, 100% { transform: translate(0, 0) rotate(0deg) scale(1.02); }
  25% { transform: translate(-3.5px, -1.5px) rotate(-2.5deg) scale(1.04); }
  50% { transform: translate(3.5px, 1.5px) rotate(2.5deg) scale(1.02); }
  75% { transform: translate(-2.5px, 1px) rotate(-1.8deg) scale(1.04); }
}

@keyframes pandaTearShake {
  0%, 100% { transform: rotate(0deg) scale(1); }
  25% { transform: rotate(-4deg) scale(1.035) translateX(-2px); }
  75% { transform: rotate(4deg) scale(1.035) translateX(2px); }
}

@keyframes pandaJoyWiggle {
  0%, 100% { transform: rotate(-7deg) translateY(0) scale(1.02); }
  50% { transform: rotate(7deg) translateY(-8px) scale(1.05); }
}

@keyframes pandaCoverShiver {
  0%, 100% { transform: translateY(2px) rotate(0deg); }
  35% { transform: translateY(4px) rotate(-1.2deg); }
  70% { transform: translateY(3px) rotate(1.2deg); }
}

@keyframes pandaPeekLean {
  0%, 100% { transform: translateX(0) rotate(0deg); }
  50% { transform: translateX(4px) rotate(2deg); }
}

/* Comic Speech Bubble pointing directly to Panda */
.lumi-speech-bubble {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
  width: 100%;
  max-width: 100%;
  padding: 12px 15px;
  border-radius: 15px;
  border: 1.5px solid var(--line);
  background: var(--panel-2);
  color: var(--text);
  font-size: 13px;
  line-height: 1.44;
  text-align: center;
  box-shadow: 0 8px 20px rgba(2, 6, 23, 0.14);
  transition: border-color 0.2s ease, background-color 0.2s ease;
}

.lumi-speech-bubble::before {
  content: "";
  position: absolute;
  top: -7px;
  left: 50%;
  width: 12px;
  height: 12px;
  background: var(--panel-2);
  border-left: 1.5px solid var(--line);
  border-top: 1.5px solid var(--line);
  transform: translateX(-50%) rotate(45deg);
  transition: border-color 0.2s ease, background-color 0.2s ease;
}

.lumi-speech-bubble.is-error {
  border-color: rgba(248, 113, 113, 0.65);
  background: rgba(239, 68, 68, 0.1);
}
.lumi-speech-bubble.is-error::before {
  border-color: rgba(248, 113, 113, 0.65);
  background: var(--panel-2);
}

.lumi-speech-bubble.is-success {
  border-color: rgba(52, 211, 153, 0.65);
  background: rgba(16, 185, 129, 0.1);
}
.lumi-speech-bubble.is-success::before {
  border-color: rgba(52, 211, 153, 0.65);
  background: var(--panel-2);
}

.lumi-speech-bubble.is-loading {
  border-color: rgba(96, 165, 250, 0.65);
  background: rgba(59, 130, 246, 0.1);
}
.lumi-speech-bubble.is-loading::before {
  border-color: rgba(96, 165, 250, 0.65);
  background: var(--panel-2);
}

.lumi-speech-text {
  margin: 0;
  font-weight: 600;
  color: var(--text);
}

/* Google CTA Button */
.lumi-google-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  width: 100%;
  padding: 13px 16px;
  border-radius: 12px;
  border: 1px solid #cbd5e1;
  background: #ffffff;
  color: #0f172a !important;
  font-weight: 700;
  font-size: 14.5px;
  text-decoration: none !important;
  box-shadow: 0 3px 10px rgba(15, 23, 42, 0.12);
  transition: transform 0.15s ease, box-shadow 0.15s ease, background-color 0.15s ease;
}

.lumi-google-btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 6px 16px rgba(15, 23, 42, 0.18);
  background: #f8fafc;
}

.lumi-google-title {
  font-size: 14.5px;
  font-weight: 700;
  color: #0f172a;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* Password Eye Toggle */
.lumi-pw-wrap {
  position: relative;
  display: flex;
  align-items: center;
}

.lumi-pw-wrap input {
  width: 100%;
  padding-right: 44px;
}

.lumi-pw-toggle {
  position: absolute;
  right: 6px;
  top: 50%;
  transform: translateY(-50%);
  width: 32px;
  height: 32px;
  border-radius: 8px;
  border: 1px solid transparent;
  background: transparent;
  color: var(--muted);
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 15px;
  transition: color 0.15s ease, background-color 0.15s ease;
}

.lumi-pw-toggle:hover {
  color: var(--text);
  background: rgba(148, 163, 184, 0.14);
}

/* Mode Tabs Grid */
.lumi-mode-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  margin-bottom: 14px;
}

.lumi-mode-tab {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 9px 10px;
  border-radius: 10px;
  border: 1px solid var(--line);
  background: transparent;
  color: var(--muted);
  font-size: 12.5px;
  font-weight: 600;
  text-decoration: none;
  text-align: center;
  transition: border-color 0.15s ease, color 0.15s ease, background-color 0.15s ease;
}

.lumi-mode-tab:hover {
  color: var(--text);
  border-color: var(--accent);
}

.lumi-mode-tab.active {
  background: var(--accent);
  border-color: var(--accent);
  color: #ffffff !important;
}

.lumi-divider {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 14px 0;
}

.lumi-divider-line {
  flex: 1;
  height: 1px;
  background: var(--line);
}

/* Compact variant for onboarding */
.lumi-hero-compact .lumi-cat-stage {
  width: 176px;
  height: 176px;
}

.lumi-hero-compact .panda-sprite-rig {
  width: 172px;
  height: 172px;
}

@media (max-width: 780px) {
  .lumi-split-card {
    grid-template-columns: 1fr;
  }
  .lumi-side-panel {
    border-right: 0;
    border-bottom: 1px solid var(--line);
    padding: 20px 16px;
  }
  .lumi-form-panel {
    padding: 20px 16px;
  }
  .lumi-cat-stage {
    width: 196px;
    height: 196px;
  }
  .panda-sprite-rig {
    width: 190px;
    height: 190px;
  }
}

@media (max-width: 480px) {
  .lumi-mode-grid {
    grid-template-columns: 1fr;
  }
  .lumi-cat-stage {
    width: 176px;
    height: 176px;
  }
  .panda-sprite-rig {
    width: 170px;
    height: 170px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .lumi-cat-stage,
  .panda-sprite-rig,
  .panda-sprite-img {
    animation: none !important;
    transition: none !important;
  }
}
