/* ================= prihlásenie / registrácia ================= */
.auth {
  min-height: 100dvh;
  background:
    radial-gradient(ellipse at 15% 0%, rgba(124, 77, 255, .4), transparent 50%),
    radial-gradient(ellipse at 90% 20%, rgba(255, 64, 129, .3), transparent 45%),
    radial-gradient(ellipse at 50% 110%, rgba(255, 193, 7, .25), transparent 55%),
    #0a0614;
  display: grid; place-items: center;
  overflow-x: hidden;
}
.auth-bg { position: fixed; inset: 0; z-index: 0; pointer-events: none; overflow: hidden; }
.fl { position: absolute; font-size: clamp(40px, 7vw, 90px); opacity: .16; filter: blur(.5px) drop-shadow(0 10px 20px rgba(0, 0, 0, .6)); animation: flo 14s ease-in-out infinite; }
.f1 { left: 6%; top: 12%; } .f2 { right: 8%; top: 8%; animation-delay: -3s; } .f3 { left: 12%; bottom: 10%; animation-delay: -6s; }
.f4 { right: 12%; bottom: 14%; animation-delay: -9s; } .f5 { left: 44%; top: 4%; animation-delay: -2s; } .f6 { right: 30%; bottom: 4%; animation-delay: -5s; }
.f7 { left: 28%; top: 40%; animation-delay: -7s; } .f8 { right: 22%; top: 42%; animation-delay: -11s; }
@keyframes flo { 50% { transform: translateY(-30px) rotate(12deg); } }
#ambient-canvas { z-index: 0 !important; }

.auth-wrap { position: relative; z-index: 1; width: min(460px, 100%); padding: 24px 16px; display: flex; flex-direction: column; align-items: center; gap: 18px; }
.auth.leaving .auth-wrap { animation: leave .5s ease forwards; }
@keyframes leave { to { transform: scale(1.08); opacity: 0; filter: blur(6px); } }
.auth-brand { text-align: center; }
.auth-brand .coin { font-size: 56px; display: inline-block; animation: coinFlip 3s ease-in-out infinite; filter: drop-shadow(0 0 20px rgba(255, 193, 7, .6)); }
@keyframes coinFlip { 0%, 70% { transform: rotateY(0); } 85% { transform: rotateY(180deg); } 100% { transform: rotateY(360deg); } }
.auth-brand h1 {
  margin: 6px 0 4px; font: clamp(32px, 8vw, 46px) 'Bungee', sans-serif; letter-spacing: 1px;
  background: linear-gradient(90deg, #fff, #ffe082 30%, #ffb300 50%, #fff8e1 60%, #ffd54f 80%, #fff);
  background-size: 200% 100%; -webkit-background-clip: text; background-clip: text; color: transparent;
  animation: shimmer 4s linear infinite; filter: drop-shadow(0 0 18px rgba(255, 193, 7, .5));
}
.auth-brand h1 b { font-weight: 400; }
@keyframes shimmer { to { background-position: -200% 0; } }
.auth-brand p { margin: 0; color: var(--muted); font-size: 14px; }

.auth-card {
  width: 100%; padding: 22px; border-radius: 24px;
  background: linear-gradient(180deg, rgba(40, 20, 64, .92), rgba(16, 8, 28, .95));
  border: 1px solid rgba(255, 213, 79, .25);
  box-shadow: 0 30px 80px rgba(0, 0, 0, .65), 0 0 60px rgba(124, 77, 255, .25), inset 0 1px 0 rgba(255, 255, 255, .08);
  backdrop-filter: blur(10px);
}
.auth-tabs { position: relative; display: grid; grid-template-columns: 1fr 1fr; padding: 4px; border-radius: 14px; background: rgba(0, 0, 0, .4); margin-bottom: 18px; }
.auth-tabs button { position: relative; z-index: 1; padding: 10px; border: 0; background: none; cursor: pointer; font-weight: 800; color: var(--muted); transition: color .25s; }
.auth-tabs button.on { color: #2a1600; }
.tab-ind { position: absolute; top: 4px; bottom: 4px; left: 4px; width: calc(50% - 4px); border-radius: 10px; background: linear-gradient(180deg, #ffe082, #ffb300); box-shadow: 0 0 18px rgba(255, 193, 7, .5); transition: transform .3s cubic-bezier(.3, 1.4, .5, 1); }
.auth-tabs[data-tab="register"] .tab-ind { transform: translateX(100%); }

.auth-form { display: flex; flex-direction: column; gap: 12px; animation: formIn .3s ease; }
@keyframes formIn { from { opacity: 0; transform: translateY(8px); } }
.auth-form label { display: flex; flex-direction: column; gap: 6px; font-weight: 700; font-size: 13px; color: rgba(255, 255, 255, .85); }
.auth-form label small { font-weight: 400; color: var(--muted); }
.auth-form input {
  padding: 13px 14px; border-radius: 12px; border: 1px solid var(--line); background: rgba(0, 0, 0, .45);
  color: #fff; font: 16px var(--ui); outline: none; transition: border-color .2s, box-shadow .2s;
}
.auth-form input:focus { border-color: #ffd54f; box-shadow: 0 0 0 3px rgba(255, 213, 79, .2); }
.av-label { font-weight: 700; font-size: 13px; color: rgba(255, 255, 255, .85); margin-top: 4px; }
.av-grid { display: grid; grid-template-columns: repeat(8, 1fr); gap: 6px; }
.av {
  aspect-ratio: 1; border-radius: 12px; border: 1px solid var(--line); background: rgba(0, 0, 0, .35); cursor: pointer;
  font-size: 22px; line-height: 1; transition: transform .15s, background .2s, box-shadow .2s;
}
.av:hover { transform: scale(1.12); background: rgba(255, 255, 255, .08); }
.av.on { background: linear-gradient(180deg, rgba(255, 224, 130, .35), rgba(255, 179, 0, .25)); border-color: #ffd54f; box-shadow: 0 0 14px rgba(255, 213, 79, .55); transform: scale(1.08); }
.auth-err { min-height: 18px; color: #ff8a80; font-weight: 700; font-size: 14px; }
.auth-btn {
  padding: 15px; border-radius: 14px; border: 0; cursor: pointer;
  font: 800 15px var(--ui); letter-spacing: 1px; color: #2a1600;
  background: linear-gradient(180deg, #fff3c4, #ffc400 45%, #e09a00);
  box-shadow: 0 5px 0 #8a5a00, 0 12px 26px rgba(0, 0, 0, .5), 0 0 30px rgba(255, 196, 0, .35);
  transition: transform .08s, filter .2s;
}
.auth-btn:hover { filter: brightness(1.08); }
.auth-btn:active { transform: translateY(4px); box-shadow: 0 1px 0 #8a5a00; }
.auth-btn:disabled { filter: grayscale(.6) brightness(.7); cursor: wait; }
.auth-switch { margin: 2px 0 0; text-align: center; font-size: 14px; color: var(--muted); }
.auth-switch a { color: #ffd54f; font-weight: 700; }
.auth-foot { margin: 0; font-size: 12px; color: var(--muted); text-align: center; }
@media (max-width: 420px) { .av-grid { grid-template-columns: repeat(6, 1fr); } }
