/* Goods Trolley — Auth / Login (aligned with landing + GTex card) */
@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@400;500;600;700;800&family=Source+Serif+4:opsz,wght@8..60,500;8..60,600&display=swap');

:root {
  --gt-ink: #0b1f33;
  --gt-ink-soft: #1a334d;
  --gt-slate: #3d566e;
  --gt-muted: #5c738a;
  --gt-surface: #f4f7fb;
  --gt-lime: #9fd400;
  --gt-lime-deep: #7fb000;
  --gt-lime-glow: rgba(159, 212, 0, 0.35);
  --gt-hero-start: #071825;
  --gt-hero-mid: #0d2a40;
  --gt-hero-end: #13405c;
  --gt-radius-lg: 22px;
  --gt-font: 'Outfit', system-ui, sans-serif;
  --gt-serif: 'Source Serif 4', Georgia, serif;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  height: 100%;
}

body.gt-auth {
  margin: 0;
  min-height: 100%;
  min-height: 100dvh;
  font-family: var(--gt-font);
  color: var(--gt-ink);
  background: var(--gt-hero-start);
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

img {
  max-width: 100%;
  display: block;
}

a {
  color: inherit;
  text-decoration: none;
}

/* —— Shell —— */
.gt-auth-shell {
  position: relative;
  min-height: 100vh;
  min-height: 100dvh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1.5rem 1.25rem;
  overflow: hidden;
}

.gt-auth-bg {
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background:
    radial-gradient(ellipse 80% 60% at 85% 20%, rgba(159, 212, 0, 0.16), transparent 55%),
    radial-gradient(ellipse 70% 50% at 10% 80%, rgba(74, 125, 184, 0.22), transparent 50%),
    linear-gradient(155deg, var(--gt-hero-start) 0%, var(--gt-hero-mid) 48%, var(--gt-hero-end) 100%);
}

.gt-auth-bg__grid {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.04) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.04) 1px, transparent 1px);
  background-size: 64px 64px;
  mask-image: radial-gradient(ellipse 70% 70% at 50% 50%, #000 20%, transparent 75%);
  animation: gt-auth-grid-drift 28s linear infinite;
}

.gt-auth-bg__orbs {
  position: absolute;
  inset: 0;
  overflow: hidden;
}

.gt-auth-bg__orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(40px);
  opacity: 0.55;
}

.gt-auth-bg__orb--a {
  width: 340px;
  height: 340px;
  top: -8%;
  right: 10%;
  background: rgba(159, 212, 0, 0.18);
  animation: gt-auth-orb-a 18s ease-in-out infinite alternate;
}

.gt-auth-bg__orb--b {
  width: 420px;
  height: 420px;
  bottom: -12%;
  left: -6%;
  background: rgba(74, 125, 184, 0.28);
  animation: gt-auth-orb-b 22s ease-in-out infinite alternate;
}

.gt-auth-bg__orb--c {
  width: 220px;
  height: 220px;
  top: 42%;
  left: 38%;
  background: rgba(159, 212, 0, 0.1);
  animation: gt-auth-orb-c 14s ease-in-out infinite alternate;
}

@keyframes gt-auth-grid-drift {
  from { transform: translate3d(0, 0, 0); }
  to { transform: translate3d(-64px, -32px, 0); }
}

@keyframes gt-auth-orb-a {
  from { transform: translate(0, 0) scale(1); }
  to { transform: translate(-40px, 30px) scale(1.08); }
}

@keyframes gt-auth-orb-b {
  from { transform: translate(0, 0) scale(1); }
  to { transform: translate(50px, -24px) scale(1.05); }
}

@keyframes gt-auth-orb-c {
  from { transform: translate(0, 0); }
  to { transform: translate(30px, -40px); }
}

/* —— Centered card (matches GTex) —— */
.gt-auth-card {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: 920px;
  display: flex;
  border-radius: var(--gt-radius-lg);
  overflow: hidden;
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.35);
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(255, 255, 255, 0.98);
}

.gt-auth-card__brand {
  position: relative;
  flex: 0 0 38%;
  min-height: 480px;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 2.5rem;
  color: #fff;
  overflow: hidden;
  background: linear-gradient(155deg, var(--gt-hero-start), var(--gt-hero-end));
  border-right: 1px solid rgba(255, 255, 255, 0.1);
}

.gt-auth-card__scene {
  position: absolute;
  inset: 0;
  background-image: url('/images/supply_chain_network.svg');
  background-size: cover;
  background-position: center 30%;
  background-repeat: no-repeat;
  opacity: 0.55;
  transform: scale(1.08);
  animation: gt-auth-scene-breathe 14s ease-in-out infinite alternate;
}

.gt-auth-card__brand-veil {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(180deg, rgba(7, 24, 37, 0.35) 0%, rgba(7, 24, 37, 0.82) 55%, rgba(7, 24, 37, 0.94) 100%),
    linear-gradient(160deg, rgba(255, 255, 255, 0.06), transparent 50%);
  pointer-events: none;
}

@keyframes gt-auth-scene-breathe {
  from { transform: scale(1.08) translateY(0); }
  to { transform: scale(1.12) translateY(-6px); }
}

.gt-auth-card__brand-body {
  position: relative;
  z-index: 1;
}

.gt-auth-card__pill {
  display: inline-block;
  margin: 0 0 1rem;
  padding: 0.35rem 0.85rem;
  border-radius: 999px;
  border: 1px solid rgba(159, 212, 0, 0.35);
  background: rgba(159, 212, 0, 0.1);
  color: var(--gt-lime);
  font-size: 0.72rem;
  font-weight: 650;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.gt-auth-card__brand h1 {
  margin: 0 0 0.85rem;
  font-family: var(--gt-serif);
  font-size: clamp(1.45rem, 2.2vw, 1.85rem);
  font-weight: 600;
  line-height: 1.25;
  letter-spacing: -0.02em;
  color: #fff;
}

.gt-auth-card__brand h1 em {
  font-style: normal;
  color: var(--gt-lime);
}

.gt-auth-card__lead {
  margin: 0;
  font-size: 0.95rem;
  line-height: 1.65;
  color: rgba(255, 255, 255, 0.72);
}

.gt-auth-card__tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem 1.15rem;
  margin-top: 1.5rem;
  padding-top: 1.15rem;
  border-top: 1px solid rgba(255, 255, 255, 0.12);
}

.gt-auth-card__tags span {
  font-size: 0.8rem;
  font-weight: 500;
  color: rgba(255, 255, 255, 0.65);
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
}

.gt-auth-card__tags span::before {
  content: '';
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--gt-lime);
  box-shadow: 0 0 10px var(--gt-lime-glow);
}

.gt-auth-card__form {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: clamp(1.75rem, 3vw, 2.75rem);
  background: rgba(255, 255, 255, 0.98);
}

.gt-auth-card__logo {
  display: flex;
  justify-content: center;
  margin-bottom: 1.5rem;
}

.gt-auth-card__logo img {
  height: 42px;
  width: auto;
}

.gt-auth-header {
  text-align: center;
  margin-bottom: 1.5rem;
}

.gt-auth-header h2 {
  margin: 0 0 0.35rem;
  font-family: var(--gt-serif);
  font-size: 1.45rem;
  font-weight: 600;
  letter-spacing: -0.02em;
  color: var(--gt-ink);
  line-height: 1.2;
}

.gt-auth-header p {
  margin: 0;
  color: var(--gt-muted);
  font-size: 0.9rem;
}

/* —— Form controls —— */
.gt-auth-field {
  margin-bottom: 1.05rem;
}

.gt-auth-field label {
  display: block;
  margin-bottom: 0.4rem;
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--gt-ink-soft);
}

.gt-auth-field input {
  width: 100%;
  padding: 0.85rem 1rem;
  border: 1.5px solid rgba(11, 31, 51, 0.12);
  border-radius: 12px;
  background: var(--gt-surface);
  font-family: var(--gt-font);
  font-size: 0.95rem;
  color: var(--gt-ink);
  transition: border-color 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
  outline: none;
}

.gt-auth-field input::placeholder {
  color: #94a3b8;
}

.gt-auth-field input:focus {
  border-color: rgba(159, 212, 0, 0.65);
  background: #fff;
  box-shadow: 0 0 0 4px rgba(159, 212, 0, 0.15);
}

.gt-auth-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1.25rem;
  flex-wrap: wrap;
}

.gt-auth-check {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.85rem;
  color: var(--gt-slate);
  cursor: pointer;
  user-select: none;
}

.gt-auth-check input {
  width: 16px;
  height: 16px;
  accent-color: var(--gt-lime-deep);
  cursor: pointer;
}

.gt-auth-forgot {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--gt-muted);
  transition: color 0.2s ease;
}

.gt-auth-forgot:hover {
  color: var(--gt-ink);
}

.gt-auth-errors {
  margin-bottom: 1rem;
}

.gt-auth-error {
  padding: 0.7rem 0.9rem;
  border-radius: 10px;
  background: #fef2f2;
  border: 1px solid #fecaca;
  color: #991b1b;
  font-size: 0.85rem;
  font-weight: 500;
}

.gt-auth-error + .gt-auth-error {
  margin-top: 0.45rem;
}

.gt-auth-submit {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  width: 100%;
  min-height: 52px;
  padding: 0.85rem 1.25rem;
  border: none;
  border-radius: 999px;
  background: var(--gt-lime);
  color: var(--gt-ink);
  font-family: var(--gt-font);
  font-size: 0.98rem;
  font-weight: 700;
  cursor: pointer;
  box-shadow: 0 10px 28px var(--gt-lime-glow);
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.gt-auth-submit:hover {
  background: #b4e820;
  transform: translateY(-1px);
  box-shadow: 0 14px 32px rgba(159, 212, 0, 0.45);
}

.gt-auth-submit:active {
  transform: translateY(0);
}

.gt-auth-submit svg {
  width: 18px;
  height: 18px;
}

.gt-auth-footer {
  margin-top: 1.5rem;
  text-align: center;
  font-size: 0.85rem;
  color: var(--gt-muted);
}

.gt-auth-footer a {
  color: var(--gt-ink);
  font-weight: 650;
  text-decoration: underline;
  text-underline-offset: 3px;
  transition: color 0.2s ease;
}

.gt-auth-footer a:hover {
  color: var(--gt-lime-deep);
}

/* —— Enter animations —— */
.gt-auth-enter {
  opacity: 0;
  transform: translateY(18px);
}

body.gt-auth.is-ready .gt-auth-enter {
  animation: gt-auth-enter 0.9s cubic-bezier(0.22, 1, 0.36, 1) forwards;
  animation-delay: calc(var(--enter, 0) * 80ms);
}

@keyframes gt-auth-enter {
  from {
    opacity: 0;
    transform: translateY(18px);
    filter: blur(4px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
    filter: blur(0);
  }
}

@media (prefers-reduced-motion: reduce) {
  .gt-auth-bg__grid,
  .gt-auth-bg__orb,
  .gt-auth-card__scene,
  .gt-auth-enter,
  body.gt-auth.is-ready .gt-auth-enter {
    animation: none !important;
    opacity: 1 !important;
    transform: none !important;
    filter: none !important;
  }
}

/* —— Responsive —— */
@media (max-width: 820px) {
  .gt-auth-card {
    flex-direction: column;
    max-width: 440px;
  }

  .gt-auth-card__brand {
    flex: none;
    min-height: 0;
    padding: 1.75rem 1.5rem;
    border-right: none;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  }

  .gt-auth-card__scene {
    opacity: 0.35;
  }

  .gt-auth-card__brand h1 {
    font-size: 1.35rem;
  }

  .gt-auth-card__lead {
    display: none;
  }

  .gt-auth-card__tags {
    margin-top: 1rem;
    padding-top: 0.85rem;
  }

  .gt-auth-card__form {
    padding: 1.75rem 1.5rem 2rem;
  }
}
