/* =========================================================
   NYRABets — custom layer
   Sits on top of the production Tailwind build (app.css).
   Brand tokens (--color-green-100 …) come from app.css :root.
   ========================================================= */

:root {
  --ease-brand: cubic-bezier(.4, 0, .2, 1);
}

html { scroll-behavior: smooth; }

/* ---------- Header dropdown (CSS-only hover, JS for mobile) ---------- */
.nav-dropdown { display: none; }
.nav-group:hover .nav-dropdown,
.nav-group.is-open .nav-dropdown { display: flex; }

/* ---------- Carousel (minimal, replaces slick JS) ---------- */
.cz-track {
  display: flex;
  transition: transform .5s var(--ease-brand);
  will-change: transform;
}
.cz-slide { flex: 0 0 100%; }
.cz-dots { display: flex; gap: .5rem; justify-content: center; }
.cz-dot {
  height: 5px; width: 30px; border-radius: 9999px;
  background: var(--color-gray-200); border: 0; cursor: pointer; padding: 0;
  transition: background-color .25s var(--ease-brand);
}
.cz-dot[aria-selected="true"] { background: var(--color-green-100); }

/* ---------- Footer accordion (mobile) ---------- */
.ft-col[data-open="false"] .ft-links { display: none; }
@media (min-width: 1024px) {
  .ft-col .ft-links { display: block !important; }
  .ft-toggle { display: none !important; }
}

/* =========================================================
   AUTH PAGES (login / join)
   ========================================================= */
.auth-shell {
  min-height: 100vh;
  display: grid;
  grid-template-columns: 1fr;
  background: var(--color-slate-900);
  color: #fff;
}
@media (min-width: 1024px) {
  .auth-shell { grid-template-columns: 1.05fr .95fr; }
}

/* Left visual panel */
.auth-visual {
  position: relative;
  display: none;
  overflow: hidden;
  background: #0b1f2c;
}
@media (min-width: 1024px) { .auth-visual { display: block; } }
.auth-visual__img {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  object-fit: cover; object-position: 60% 30%;
  filter: saturate(1.05);
}
.auth-visual__scrim {
  position: absolute; inset: 0;
  background:
    linear-gradient(180deg, rgba(11,31,44,.15) 0%, rgba(11,31,44,.55) 60%, rgba(11,31,44,.92) 100%),
    linear-gradient(90deg, rgba(11,31,44,.25), rgba(11,31,44,0) 45%);
}
.auth-visual__content {
  position: absolute; inset: auto 0 0 0;
  padding: 3.5rem 3rem;
  z-index: 2;
}
.auth-visual__bolt {
  position: absolute; top: -4%; right: -6%;
  width: 46%; opacity: .9; z-index: 1;
  transform: rotate(8deg);
}
.auth-quote {
  font-weight: 800; text-transform: uppercase; line-height: 1;
  font-size: clamp(2.25rem, 3.4vw, 3.75rem);
  letter-spacing: -.01em;
}
.auth-quote em {
  font-style: normal; color: var(--color-green-100);
  display: block;
}
.auth-quote__sub {
  margin-top: 1.25rem; max-width: 30rem;
  font-weight: 600; color: var(--color-gray-300); text-transform: none;
  font-size: 1rem; line-height: 1.6; letter-spacing: 0;
}

/* Right form panel */
.auth-panel {
  display: flex; flex-direction: column;
  padding: 1.5rem 1.5rem 3rem;
}
@media (min-width: 768px) { .auth-panel { padding: 2rem 3rem; } }
@media (min-width: 1280px) { .auth-panel { padding: 2.5rem 5rem; } }

.auth-topbar {
  display: flex; align-items: center; justify-content: space-between;
  height: 7.5rem;
}
.auth-logo {
  font-weight: 800; text-transform: uppercase; letter-spacing: .02em;
  font-size: 1.5rem; line-height: 1; color: #fff;
}
.auth-logo span { color: var(--color-green-100); }
.auth-topbar__link {
  font-size: .8125rem; font-weight: 700; text-transform: uppercase;
  letter-spacing: .04em; color: var(--color-gray-400);
}
.auth-topbar__link a { color: var(--color-green-100); }

.auth-form-wrap {
  flex: 1;
  display: flex; flex-direction: column; justify-content: center;
  max-width: 27rem; width: 100%; margin: 0 auto;
  padding: 2rem 0;
}
.auth-eyebrow {
  font-weight: 800; text-transform: uppercase; letter-spacing: .08em;
  font-size: .75rem; color: var(--color-green-300); margin-bottom: .75rem;
}
.auth-title {
  font-weight: 800; text-transform: uppercase; line-height: 1;
  font-size: clamp(2.25rem, 5vw, 3rem); margin-bottom: .75rem;
}
.auth-sub {
  color: var(--color-gray-400); font-weight: 600;
  line-height: 1.5; margin-bottom: 2rem;
}

/* staggered entrance */
.reveal { opacity: 0; transform: translateY(12px); animation: reveal .6s var(--ease-brand) forwards; }
.reveal:nth-child(1) { animation-delay: .05s; }
.reveal:nth-child(2) { animation-delay: .12s; }
.reveal:nth-child(3) { animation-delay: .19s; }
.reveal:nth-child(4) { animation-delay: .26s; }
.reveal:nth-child(5) { animation-delay: .33s; }
.reveal:nth-child(6) { animation-delay: .40s; }
.reveal:nth-child(7) { animation-delay: .47s; }
@keyframes reveal { to { opacity: 1; transform: none; } }

/* Fields */
.field { margin-bottom: 1.1rem; }
.field-row { display: grid; grid-template-columns: 1fr; gap: 0; }
.field-label {
  display: block; font-size: .75rem; font-weight: 700;
  text-transform: uppercase; letter-spacing: .05em;
  color: var(--color-gray-400); margin-bottom: .5rem;
}
.field-input {
  width: 100%; padding: .95rem 1rem;
  background: #0c1416; color: #fff;
  border: 2px solid #232a2b; border-radius: .875rem;
  font-size: 1rem; line-height: 1.2;
  transition: border-color .15s var(--ease-brand), box-shadow .15s var(--ease-brand), background-color .15s var(--ease-brand);
}
.field-input::placeholder { color: var(--color-gray-600); }
.field-input:focus {
  outline: none; background: #0e191b;
  border-color: var(--color-green-100);
  box-shadow: 0 0 0 4px rgba(179, 239, 84, .14);
}
.field-input:-webkit-autofill { -webkit-text-fill-color: #fff; transition: background-color 9999s; }
.field.has-error .field-input {
  border-color: var(--color-red-100);
  box-shadow: 0 0 0 4px rgba(255, 62, 38, .12);
}
.field-error {
  display: none; align-items: center; gap: .35rem;
  color: var(--color-red-100); font-size: .8125rem; font-weight: 600;
  margin-top: .5rem;
}
.field.has-error .field-error { display: flex; }

/* password wrapper with toggle */
.field-pass { position: relative; }
.field-pass .field-input { padding-right: 3.25rem; }
.pass-toggle {
  position: absolute; right: .5rem; top: 50%; transform: translateY(-50%);
  background: transparent; border: 0; cursor: pointer; padding: .5rem;
  color: var(--color-gray-500); font-size: .7rem; font-weight: 800;
  text-transform: uppercase; letter-spacing: .05em;
}
.pass-toggle:hover { color: var(--color-green-100); }

/* checkbox row */
.auth-aux {
  display: flex; align-items: center; justify-content: space-between;
  gap: 1rem; margin: -.2rem 0 1.4rem; flex-wrap: wrap;
}
.auth-check {
  display: inline-flex; align-items: center; gap: .55rem;
  font-size: .875rem; color: var(--color-gray-300); cursor: pointer; user-select: none;
}
.auth-check input { width: 1.05rem; height: 1.05rem; accent-color: var(--color-green-200); }
.auth-link { font-size: .875rem; font-weight: 700; color: var(--color-green-100); }
.auth-link:hover { text-decoration: underline; }

/* submit (brand pill) */
.auth-submit {
  width: 100%; display: inline-flex; align-items: center; justify-content: center;
  gap: .6rem; padding: 1.1rem 1.25rem;
  font-weight: 800; text-transform: uppercase; letter-spacing: .02em; line-height: 1;
  border: 0; border-radius: 9999px; cursor: pointer;
  background: var(--color-green-100); color: #000;
  transition: background-color .2s var(--ease-brand), transform .12s var(--ease-brand);
}
.auth-submit:hover { background: #fff; }
.auth-submit:active { transform: translateY(1px) scale(.995); }

.auth-switch {
  margin-top: 1.6rem; text-align: center;
  color: var(--color-gray-400); font-weight: 600; font-size: .9rem;
}
.auth-switch a { color: var(--color-green-100); font-weight: 800; }
.auth-switch a:hover { text-decoration: underline; }

.auth-disclaimer {
  margin-top: 2rem; padding-top: 1.25rem; border-top: 1px solid #232a2b;
  color: var(--color-gray-600); font-size: .75rem; line-height: 1.5;
}
.auth-disclaimer a { color: var(--color-gray-400); text-decoration: underline; }

/* =========================================================
   OTP MODAL + ACCESS OVERLAY
   ========================================================= */
.modal { position: fixed; inset: 0; z-index: 9999; display: none; }
.modal.is-open { display: block; }
.modal__backdrop {
  position: absolute; inset: 0;
  background: rgba(0, 0, 0, .78); backdrop-filter: blur(6px);
  animation: fade .25s var(--ease-brand);
}
.modal__card {
  position: relative; z-index: 1;
  width: calc(100% - 2.5rem); max-width: 30rem;
  margin: 8vh auto 0;
  background: #10191b; color: #fff;
  border: 1px solid #232a2b; border-radius: 1.25rem;
  padding: 2.25rem 2rem 2rem;
  box-shadow: 0 30px 80px rgba(0, 0, 0, .55);
  animation: pop .3s var(--ease-brand);
}
@keyframes fade { from { opacity: 0; } }
@keyframes pop { from { opacity: 0; transform: translateY(16px) scale(.97); } }

.modal__close {
  position: absolute; top: 1rem; right: 1rem;
  background: transparent; border: 0; color: var(--color-gray-500);
  cursor: pointer; padding: .4rem; line-height: 0;
}
.modal__close:hover { color: #fff; }

.otp-badge {
  width: 3.25rem; height: 3.25rem; border-radius: 9999px;
  display: grid; place-items: center; margin-bottom: 1.1rem;
  background: rgba(179, 239, 84, .14); color: var(--color-green-100);
}
.modal__title {
  font-weight: 800; text-transform: uppercase; line-height: 1;
  font-size: 1.75rem; margin-bottom: .5rem;
}
.modal__text { color: var(--color-gray-400); font-weight: 600; line-height: 1.5; margin-bottom: 1.5rem; }
.modal__text b { color: #fff; }

.otp-inputs { display: flex; gap: .6rem; justify-content: space-between; margin-bottom: .5rem; }
.otp-digit {
  width: 100%; aspect-ratio: 1 / 1.15; min-width: 0;
  text-align: center; font-size: 1.5rem; font-weight: 800;
  background: #0c1416; color: #fff;
  border: 2px solid #232a2b; border-radius: .75rem;
  transition: border-color .15s var(--ease-brand), box-shadow .15s var(--ease-brand);
}
.otp-digit:focus {
  outline: none; border-color: var(--color-green-100);
  box-shadow: 0 0 0 4px rgba(179, 239, 84, .14);
}
.otp-digit.filled { border-color: var(--color-green-300); }
.otp-inputs.shake { animation: shake .4s var(--ease-brand); }
@keyframes shake {
  10%, 90% { transform: translateX(-2px); }
  20%, 80% { transform: translateX(4px); }
  30%, 50%, 70% { transform: translateX(-8px); }
  40%, 60% { transform: translateX(8px); }
}
.otp-hint { min-height: 1.2rem; font-size: .8125rem; font-weight: 600; color: var(--color-gray-500); margin-bottom: 1.25rem; }
.otp-hint.error { color: var(--color-red-100); }
.otp-resend { margin-top: 1.1rem; text-align: center; font-size: .85rem; color: var(--color-gray-500); }
.otp-resend button { background: 0; border: 0; color: var(--color-green-100); font-weight: 800; cursor: pointer; }

/* Access (DB) overlay — visual only */
.access {
  position: absolute; inset: 0; z-index: 2;
  display: none; flex-direction: column; align-items: center; justify-content: center;
  gap: 1.1rem; text-align: center;
  background: #10191b; border-radius: 1.25rem; padding: 2rem;
}
.access.is-on { display: flex; }
.spinner {
  width: 3rem; height: 3rem; border-radius: 9999px;
  border: 4px solid rgba(255, 255, 255, .12);
  border-top-color: var(--color-green-100);
  animation: spin .8s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }
.access__title { font-weight: 800; text-transform: uppercase; font-size: 1.25rem; }
.access__steps { font-size: .85rem; color: var(--color-gray-500); font-weight: 600; min-height: 1.2rem; }

/* success check */
.access__check {
  width: 3.5rem; height: 3.5rem; border-radius: 9999px;
  display: none; place-items: center;
  background: var(--color-green-100); color: #000;
  animation: pop .35s var(--ease-brand);
}
.access.done .spinner { display: none; }
.access.done .access__check { display: grid; }

@media (prefers-reduced-motion: reduce) {
  .reveal, .modal__card, .modal__backdrop, .access__check { animation: none; opacity: 1; transform: none; }
  html { scroll-behavior: auto; }
}
