/* =========================================================
   CARZE · Login
   Motion principles: ease-out for enter, transform/opacity only,
   UI transitions < 300ms, subtle stagger, reduced-motion aware.
   ========================================================= */

:root {
  /* Brand */
  --navy-950: #040822;
  --navy-900: #060b2b;
  --navy-800: #0b1645;
  --navy-700: #13236b;
  --blue-600: #1f4fe0;
  --blue-500: #2f6bff;   /* azul eléctrico */
  --blue-400: #5b8cff;
  --violet-500: #6a4dff;
  --orange-500: #ff5a0a; /* acento del logo */
  --orange-400: #ff7a33;

  /* Neutrals */
  --ink-900: #0b1233;
  --ink-700: #2a3358;
  --ink-500: #5d6688;
  --ink-400: #8a92b0;
  --line: #e3e7f2;
  --line-strong: #cfd5e6;
  --surface: #ffffff;
  --surface-2: #f6f8fd;

  /* Feedback */
  --danger: #e5484d;
  --danger-bg: #fff1f1;
  --success: #12a150;
  --success-bg: #ecfbf2;
  --info: var(--blue-600);
  --info-bg: #eef3ff;

  /* Motion */
  --ease-out: cubic-bezier(0.23, 1, 0.32, 1);
  --ease-in-out: cubic-bezier(0.77, 0, 0.175, 1);
  --ease-soft: cubic-bezier(0.25, 0.1, 0.25, 1);

  /* Type & shape */
  --font: "Plus Jakarta Sans", "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --radius-sm: 10px;
  --radius: 14px;
  --radius-lg: 24px;
  --control-h: 52px;
}

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

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  min-height: 100vh;
  min-height: 100dvh;
  font-family: var(--font);
  font-size: 15px;
  line-height: 1.5;
  color: var(--ink-900);
  background: var(--navy-950);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}

[hidden] { display: none !important; }

button, input { font: inherit; color: inherit; }
button { cursor: pointer; background: none; border: 0; padding: 0; }
svg { flex-shrink: 0; }

:focus-visible {
  outline: 2px solid var(--blue-500);
  outline-offset: 3px;
  border-radius: 6px;
}

/* =========================================================
   Layout
   ========================================================= */
.auth {
  display: grid;
  grid-template-columns: minmax(0, 48fr) minmax(0, 52fr);
  min-height: 100vh;
  min-height: 100dvh;
}

/* =========================================================
   Brand
   ========================================================= */
.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  border-radius: 8px;
}
.brand__mark {
  width: 34px;
  height: 34px;
  color: var(--orange-500);
}
.brand__word {
  font-weight: 800;
  font-size: 22px;
  letter-spacing: -0.02em;
  font-style: italic;
  line-height: 1;
}
.brand--light .brand__word { color: #fff; }
.brand--dark .brand__word { color: var(--navy-800); }

/* =========================================================
   Hero (left)
   ========================================================= */
.hero {
  position: relative;
  overflow: hidden;
  isolation: isolate;
  background:
    radial-gradient(120% 80% at 80% 10%, rgba(106, 77, 255, 0.35), transparent 60%),
    linear-gradient(160deg, var(--navy-800), var(--navy-950));
  color: #fff;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: clamp(24px, 3.2vw, 44px);
}

.hero__media {
  position: absolute;
  inset: -2%;
  z-index: -3;
  will-change: transform;
}
.hero__img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 50% 62%;
  display: block;
  opacity: 0;
  transform: scale(1.06);
  animation:
    heroIn 1400ms var(--ease-out) 60ms forwards,
    heroFloat 9s var(--ease-soft) 1500ms infinite alternate;
}

@keyframes heroIn {
  to { opacity: 1; transform: scale(1); }
}
@keyframes heroFloat {
  from { transform: scale(1) translate3d(0, 0, 0); }
  to   { transform: scale(1.025) translate3d(0, -8px, 0); }
}

/* Ambient overlays: hide the artwork's own header, ground the copy */
.hero__shade {
  position: absolute;
  inset: 0;
  z-index: -2;
  pointer-events: none;
  background:
    linear-gradient(180deg, #050a2c 0%, rgba(5, 10, 44, 0.97) 14%, rgba(5, 10, 44, 0.6) 26%, rgba(5, 10, 44, 0) 40%),
    linear-gradient(0deg, rgba(4, 8, 34, 0.96) 0%, rgba(4, 8, 34, 0.72) 22%, rgba(4, 8, 34, 0) 48%),
    linear-gradient(90deg, rgba(4, 8, 34, 0) 70%, rgba(4, 8, 34, 0.35) 100%);
}

.hero__grid {
  position: absolute;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.05) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.05) 1px, transparent 1px);
  background-size: 44px 44px;
  -webkit-mask-image: radial-gradient(70% 45% at 30% 100%, #000 0%, transparent 70%);
          mask-image: radial-gradient(70% 45% at 30% 100%, #000 0%, transparent 70%);
  opacity: 0;
  animation: fadeIn 1200ms var(--ease-out) 500ms forwards;
}

.hero__glow {
  position: absolute;
  z-index: -1;
  border-radius: 50%;
  filter: blur(60px);
  pointer-events: none;
  opacity: 0;
}
.hero__glow--blue {
  width: 46%;
  aspect-ratio: 1;
  left: -12%;
  bottom: -10%;
  background: radial-gradient(circle, rgba(47, 107, 255, 0.55), transparent 70%);
  animation: fadeIn 1600ms var(--ease-out) 300ms forwards, glowDrift 12s var(--ease-soft) 2s infinite alternate;
}
.hero__glow--orange {
  width: 26%;
  aspect-ratio: 1;
  right: 6%;
  bottom: 22%;
  background: radial-gradient(circle, rgba(255, 106, 30, 0.35), transparent 70%);
  animation: fadeIn 1600ms var(--ease-out) 500ms forwards, glowDrift 14s var(--ease-soft) 2s infinite alternate-reverse;
}
@keyframes glowDrift {
  from { transform: translate3d(0, 0, 0) scale(1); }
  to   { transform: translate3d(18px, -14px, 0) scale(1.08); }
}
@keyframes fadeIn { to { opacity: 1; } }

.hero__top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  opacity: 0;
  animation: riseIn 700ms var(--ease-out) 200ms forwards;
}

.hero__chip {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 7px 12px;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.01em;
  color: rgba(255, 255, 255, 0.86);
  background: rgba(255, 255, 255, 0.07);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 999px;
  -webkit-backdrop-filter: blur(10px);
          backdrop-filter: blur(10px);
}
.hero__chip-dot {
  position: relative;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #35d07f;
}
.hero__chip-dot::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background: inherit;
  animation: ping 2.4s var(--ease-out) infinite;
}
@keyframes ping {
  0%   { transform: scale(1); opacity: 0.6; }
  70%, 100% { transform: scale(2.8); opacity: 0; }
}

.hero__copy {
  max-width: 460px;
  opacity: 0;
  animation: riseIn 800ms var(--ease-out) 380ms forwards;
}
.hero__eyebrow {
  margin: 0 0 12px;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--orange-400);
}
.hero__title {
  margin: 0;
  font-size: clamp(28px, 2.9vw, 42px);
  line-height: 1.1;
  font-weight: 800;
  letter-spacing: -0.03em;
  text-wrap: balance;
}
.hero__title span {
  background: linear-gradient(90deg, #ffffff, #b9c8ff 60%, #c7b8ff);
  -webkit-background-clip: text;
          background-clip: text;
  color: transparent;
}
.hero__subtitle {
  margin: 14px 0 0;
  font-size: clamp(15px, 1.15vw, 17px);
  color: rgba(226, 232, 255, 0.78);
}

@keyframes riseIn {
  from { opacity: 0; transform: translate3d(0, 12px, 0); }
  to   { opacity: 1; transform: translate3d(0, 0, 0); }
}

/* =========================================================
   Panel (right)
   ========================================================= */
.panel {
  position: relative;
  display: flex;
  flex-direction: column;
  background:
    radial-gradient(60% 40% at 100% 0%, rgba(47, 107, 255, 0.07), transparent 70%),
    radial-gradient(50% 35% at 0% 100%, rgba(106, 77, 255, 0.06), transparent 70%),
    var(--surface);
  padding: clamp(24px, 4vw, 56px) clamp(20px, 5vw, 72px) 24px;
}

.panel__inner {
  flex: 1;
  width: 100%;
  max-width: 420px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 36px;
}

.panel__footer {
  margin-top: 32px;
  text-align: center;
  font-size: 12.5px;
  color: var(--ink-400);
}

/* Page entrance: fade + subtle rise, staggered */
.reveal {
  opacity: 0;
  animation: riseIn 560ms var(--ease-out) forwards;
  animation-delay: calc(140ms + var(--i, 0) * 55ms);
}

/* =========================================================
   Card & views
   ========================================================= */
.card { position: relative; }

.card.is-shake { animation: shake 420ms cubic-bezier(0.36, 0.07, 0.19, 0.97); }
@keyframes shake {
  10%, 90% { transform: translate3d(-1px, 0, 0); }
  20%, 80% { transform: translate3d(3px, 0, 0); }
  30%, 50%, 70% { transform: translate3d(-5px, 0, 0); }
  40%, 60% { transform: translate3d(5px, 0, 0); }
}

.view { display: flex; flex-direction: column; }

.view__head { margin-bottom: 28px; }
.view__head--center { text-align: center; margin-top: 18px; }

.view__title {
  margin: 0;
  font-size: clamp(26px, 2.3vw, 32px);
  line-height: 1.15;
  font-weight: 800;
  letter-spacing: -0.03em;
  color: var(--ink-900);
}
.view__text {
  margin: 8px 0 0;
  font-size: 15px;
  color: var(--ink-500);
}
.view__text strong { color: var(--ink-900); font-weight: 700; word-break: break-all; }

.view__foot {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin: 28px 0 0;
  font-size: 12.5px;
  color: var(--ink-400);
}
.view__foot svg {
  width: 15px; height: 15px;
  fill: none; stroke: currentColor; stroke-width: 1.8;
  stroke-linecap: round; stroke-linejoin: round;
}

.back {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin: 0 0 20px -6px;
  padding: 6px 10px 6px 6px;
  font-size: 13.5px;
  font-weight: 600;
  color: var(--ink-500);
  border-radius: 8px;
  transition: color 160ms ease, background-color 160ms ease, transform 160ms var(--ease-out);
}
.back svg {
  width: 18px; height: 18px;
  fill: none; stroke: currentColor; stroke-width: 2;
  stroke-linecap: round; stroke-linejoin: round;
}
.back:active { transform: scale(0.97); }

/* =========================================================
   Form
   ========================================================= */
.form { display: flex; flex-direction: column; gap: 18px; }

.field { display: flex; flex-direction: column; }

.field__label {
  margin-bottom: 8px;
  font-size: 13.5px;
  font-weight: 600;
  color: var(--ink-700);
}

.field__control { position: relative; }

/* Focus ring as a pseudo-element: animates opacity + scale only */
.field__control::after {
  content: "";
  position: absolute;
  inset: -4px;
  border-radius: calc(var(--radius) + 4px);
  box-shadow: 0 0 0 4px rgba(47, 107, 255, 0.16);
  opacity: 0;
  transform: scale(0.985);
  transition: opacity 200ms var(--ease-out), transform 200ms var(--ease-out);
  pointer-events: none;
}
.field__control:focus-within::after { opacity: 1; transform: scale(1); }
.field.is-invalid .field__control::after { box-shadow: 0 0 0 4px rgba(229, 72, 77, 0.14); }

.field__icon {
  position: absolute;
  left: 16px;
  top: 50%;
  width: 19px;
  height: 19px;
  transform: translateY(-50%);
  fill: none;
  stroke: var(--ink-400);
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
  pointer-events: none;
  transition: stroke 200ms ease;
}
.field__control:focus-within .field__icon { stroke: var(--blue-500); }
.field.is-invalid .field__icon { stroke: var(--danger); }

.field__input {
  width: 100%;
  height: var(--control-h);
  padding: 0 16px 0 46px;
  font-size: 16px; /* evita zoom en iOS */
  font-weight: 500;
  color: var(--ink-900);
  background: var(--surface-2);
  border: 1.5px solid var(--line);
  border-radius: var(--radius);
  outline: none;
  transition: border-color 200ms ease, background-color 200ms ease;
  -webkit-appearance: none;
          appearance: none;
}
.field__input--pw { padding-right: 52px; }
.field__input::placeholder { color: #a7aec7; font-weight: 400; }
.field__input:focus { border-color: var(--blue-500); background: #fff; }
.field.is-invalid .field__input { border-color: var(--danger); background: #fffafa; }
.field__input[readonly] { cursor: progress; }

/* Autofill: keep brand surface */
.field__input:-webkit-autofill {
  -webkit-box-shadow: 0 0 0 40px #f2f6ff inset;
  -webkit-text-fill-color: var(--ink-900);
  caret-color: var(--ink-900);
}

/* Inline error: grid-rows reveal + opacity/translate on content */
.field__error {
  display: grid;
  grid-template-rows: 0fr;
  transition: grid-template-rows 220ms var(--ease-out);
}
.field__error > p {
  min-height: 0;
  overflow: hidden;
  margin: 0;
  font-size: 13px;
  font-weight: 500;
  color: var(--danger);
  opacity: 0;
  transform: translate3d(0, -4px, 0);
  transition: opacity 200ms var(--ease-out), transform 200ms var(--ease-out);
}
.field.is-invalid .field__error { grid-template-rows: 1fr; }
.field.is-invalid .field__error > p {
  padding-top: 7px;
  opacity: 1;
  transform: translate3d(0, 0, 0);
}

.field__hint {
  margin: 7px 0 0;
  font-size: 12.5px;
  font-weight: 600;
  color: #b4690e;
  animation: riseIn 200ms var(--ease-out);
}

/* Show / hide password */
.pw-toggle {
  position: absolute;
  right: 6px;
  top: 50%;
  width: 40px;
  height: 40px;
  display: grid;
  place-items: center;
  border-radius: 10px;
  color: var(--ink-400);
  transform: translateY(-50%);
  transition: color 160ms ease, background-color 160ms ease, transform 160ms var(--ease-out);
}
.pw-toggle:active { transform: translateY(-50%) scale(0.92); }
.pw-toggle svg {
  grid-area: 1 / 1;
  width: 20px;
  height: 20px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
  transition: opacity 180ms var(--ease-out), transform 180ms var(--ease-out), filter 180ms var(--ease-out);
}
.pw-toggle__off { opacity: 0; transform: scale(0.75); filter: blur(2px); }
.pw-toggle[aria-pressed="true"] .pw-toggle__eye { opacity: 0; transform: scale(0.75); filter: blur(2px); }
.pw-toggle[aria-pressed="true"] .pw-toggle__off { opacity: 1; transform: scale(1); filter: blur(0); }
.pw-toggle[aria-pressed="true"] { color: var(--blue-500); }

/* Row: remember + forgot */
.form__row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  margin-top: -2px;
}

/* Custom checkbox */
.check {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-height: 40px;
  cursor: pointer;
  user-select: none;
  -webkit-tap-highlight-color: transparent;
}
.check__input {
  position: absolute;
  opacity: 0;
  width: 1px;
  height: 1px;
  pointer-events: none;
}
.check__box {
  width: 20px;
  height: 20px;
  display: grid;
  place-items: center;
  border-radius: 6px;
  border: 1.5px solid var(--line-strong);
  background: #fff;
  transition: background-color 180ms ease, border-color 180ms ease, transform 160ms var(--ease-out);
}
.check:active .check__box { transform: scale(0.9); }
.check__box svg {
  width: 14px;
  height: 14px;
  fill: none;
  stroke: #fff;
  stroke-width: 2.4;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-dasharray: 16;
  stroke-dashoffset: 16;
  transition: stroke-dashoffset 220ms var(--ease-out);
}
.check__input:checked + .check__box { background: var(--blue-500); border-color: var(--blue-500); }
.check__input:checked + .check__box svg { stroke-dashoffset: 0; transition-delay: 40ms; }
.check__input:focus-visible + .check__box { outline: 2px solid var(--blue-500); outline-offset: 3px; }
.check__label { font-size: 14px; font-weight: 500; color: var(--ink-700); }

/* Text link */
.link {
  position: relative;
  padding: 8px 0;
  font-size: 14px;
  font-weight: 600;
  color: var(--blue-600);
  transition: color 160ms ease;
}
.link::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 5px;
  height: 1.5px;
  background: currentColor;
  transform: scaleX(0);
  transform-origin: right;
  transition: transform 220ms var(--ease-out);
}

/* =========================================================
   Buttons
   ========================================================= */
.btn {
  position: relative;
  display: grid;
  place-items: center;
  width: 100%;
  height: var(--control-h);
  border-radius: var(--radius);
  font-size: 15.5px;
  font-weight: 700;
  letter-spacing: -0.005em;
  text-decoration: none;
  overflow: hidden;
  isolation: isolate;
  -webkit-tap-highlight-color: transparent;
  transition: transform 160ms var(--ease-out), box-shadow 200ms ease, opacity 200ms ease;
}
.btn:active:not([data-state="loading"]):not([data-state="success"]) { transform: scale(0.97); }
.btn[data-state="loading"],
.btn[data-state="success"] { cursor: default; }

.btn--primary {
  margin-top: 6px;
  color: #fff;
  background: linear-gradient(135deg, var(--blue-500) 0%, var(--blue-600) 55%, var(--violet-500) 130%);
  box-shadow:
    0 1px 0 rgba(255, 255, 255, 0.25) inset,
    0 10px 24px -10px rgba(47, 107, 255, 0.7),
    0 2px 6px -2px rgba(11, 22, 69, 0.3);
}
/* Success tint layer */
.btn--primary::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: linear-gradient(135deg, #18b45c, #0e9447);
  opacity: 0;
  transition: opacity 260ms var(--ease-out);
}
.btn--primary[data-state="success"]::before { opacity: 1; }
.btn--primary[data-state="success"] { box-shadow: 0 10px 24px -10px rgba(18, 161, 80, 0.7); }

/* Hover sheen */
.btn--primary::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: linear-gradient(105deg, transparent 30%, rgba(255, 255, 255, 0.22) 50%, transparent 70%);
  transform: translateX(-110%);
  transition: transform 600ms var(--ease-out);
  pointer-events: none;
}

.btn--ghost {
  color: var(--ink-700);
  background: #fff;
  border: 1.5px solid var(--line);
  transition: transform 160ms var(--ease-out), border-color 160ms ease, background-color 160ms ease;
}

.btn:disabled { cursor: not-allowed; }

/* Layered button content: crossfade with blur bridge */
.btn__layer {
  grid-area: 1 / 1;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  transition: opacity 200ms var(--ease-out), transform 240ms var(--ease-out), filter 200ms var(--ease-out);
}
.btn__layer--loading,
.btn__layer--success { opacity: 0; transform: translate3d(0, 10px, 0); filter: blur(3px); }

.btn[data-state="loading"] .btn__layer--idle,
.btn[data-state="success"] .btn__layer--idle,
.btn[data-state="success"] .btn__layer--loading { opacity: 0; transform: translate3d(0, -10px, 0); filter: blur(3px); }

.btn[data-state="loading"] .btn__layer--loading,
.btn[data-state="success"] .btn__layer--success { opacity: 1; transform: translate3d(0, 0, 0); filter: blur(0); }

.btn__arrow,
.btn__icon {
  width: 18px;
  height: 18px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
  transition: transform 200ms var(--ease-out);
}

.btn__check {
  width: 20px;
  height: 20px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2.6;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-dasharray: 24;
  stroke-dashoffset: 24;
}
.btn[data-state="success"] .btn__check {
  transition: stroke-dashoffset 320ms var(--ease-out) 120ms;
  stroke-dashoffset: 0;
}

/* Spinner: fast rotation feels faster */
.spinner {
  width: 18px;
  height: 18px;
  border-radius: 50%;
  border: 2.2px solid rgba(255, 255, 255, 0.3);
  border-top-color: #fff;
  animation: spin 620ms linear infinite;
}
.spinner--dark { border-color: rgba(11, 18, 51, 0.15); border-top-color: var(--ink-700); }
@keyframes spin { to { transform: rotate(360deg); } }

/* Hover only on real pointers */
@media (hover: hover) and (pointer: fine) {
  .btn--primary:hover::after { transform: translateX(110%); }
  .btn--primary:hover .btn__arrow { transform: translateX(3px); }
  .btn--primary:hover { box-shadow: 0 1px 0 rgba(255,255,255,.25) inset, 0 14px 30px -12px rgba(47,107,255,.85), 0 2px 6px -2px rgba(11,22,69,.3); }
  .btn--ghost:hover { border-color: var(--line-strong); background: var(--surface-2); }
  .link:hover { color: var(--blue-500); }
  .link:hover::after { transform: scaleX(1); transform-origin: left; }
  .pw-toggle:hover { color: var(--ink-700); background: rgba(11, 18, 51, 0.05); }
  .back:hover { color: var(--ink-900); background: var(--surface-2); }
  .field__input:hover:not(:focus) { border-color: var(--line-strong); }
  .check:hover .check__box { border-color: var(--blue-400); }
}

/* =========================================================
   Alerts
   ========================================================= */
.alert {
  display: grid;
  grid-template-rows: 0fr;
  transition: grid-template-rows 240ms var(--ease-out);
}
.alert__inner { min-height: 0; overflow: hidden; }
.alert__box {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  margin-bottom: 20px;
  padding: 12px 14px;
  border-radius: 12px;
  font-size: 14px;
  font-weight: 500;
  line-height: 1.45;
  border: 1px solid transparent;
  opacity: 0;
  transform: translate3d(0, -6px, 0) scale(0.98);
  transition: opacity 200ms var(--ease-out), transform 240ms var(--ease-out);
}
.alert.is-visible { grid-template-rows: 1fr; }
.alert.is-visible .alert__box { opacity: 1; transform: translate3d(0, 0, 0) scale(1); }
.alert__text { margin: 0; }
.alert__icon {
  width: 18px;
  height: 18px;
  margin-top: 1px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.alert[data-type="error"] .alert__box   { color: #b4232a; background: var(--danger-bg); border-color: #ffd9da; }
.alert[data-type="success"] .alert__box { color: #0b7a3b; background: var(--success-bg); border-color: #c8f0d7; }
.alert[data-type="info"] .alert__box    { color: var(--info); background: var(--info-bg); border-color: #d8e3ff; }

/* =========================================================
   Session view
   ========================================================= */
.session {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 14px;
}
.session__avatar {
  width: 72px;
  height: 72px;
  display: grid;
  place-items: center;
  border-radius: 22px;
  font-size: 26px;
  font-weight: 800;
  color: #fff;
  background: linear-gradient(135deg, var(--blue-500), var(--violet-500));
  box-shadow: 0 14px 30px -12px rgba(47, 107, 255, 0.75);
}
.session__status {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 5px 11px;
  font-size: 12.5px;
  font-weight: 700;
  color: #0b7a3b;
  background: var(--success-bg);
  border-radius: 999px;
}
.session__dot { width: 7px; height: 7px; border-radius: 50%; background: var(--success); }
.session__role {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin: 12px auto 0;
  padding: 7px 14px;
  font-size: 14px;
  font-weight: 600;
  color: var(--navy-700);
  background: linear-gradient(135deg, rgba(47, 107, 255, 0.08), rgba(106, 77, 255, 0.08));
  border: 1px solid rgba(47, 107, 255, 0.18);
  border-radius: 999px;
}
.session__role-label { color: var(--ink-500); font-weight: 500; }
.session__role-value { color: var(--orange-500); font-weight: 800; letter-spacing: -0.01em; }
.view__head--center { display: flex; flex-direction: column; align-items: center; }
.stack { display: flex; flex-direction: column; gap: 12px; }
.stack .btn--primary { margin-top: 0; }

/* =========================================================
   Responsive
   ========================================================= */
@media (max-width: 1180px) {
  .auth { grid-template-columns: minmax(0, 45fr) minmax(0, 55fr); }
  .hero__chip { display: none; }
}

@media (max-width: 900px) {
  body { background: var(--surface); }

  .auth {
    grid-template-columns: 1fr;
    grid-template-rows: auto 1fr;
  }

  .hero {
    min-height: clamp(240px, 38vh, 340px);
    padding: 20px 20px 44px;
  }
  .hero__img { object-position: 30% 66%; }
  .hero__shade {
    background:
      linear-gradient(180deg, rgba(4, 8, 34, 0.9) 0%, rgba(4, 8, 34, 0.25) 40%, rgba(4, 8, 34, 0) 55%),
      linear-gradient(0deg, rgba(4, 8, 34, 0.94) 0%, rgba(4, 8, 34, 0.55) 35%, rgba(4, 8, 34, 0) 65%);
  }
  .hero__chip { display: inline-flex; }
  .hero__eyebrow { display: none; }
  .hero__title { font-size: clamp(22px, 5.6vw, 30px); }
  .hero__subtitle { margin-top: 6px; font-size: 14px; }
  .hero__glow--orange { display: none; }

  .panel {
    margin-top: -24px;
    border-radius: var(--radius-lg) var(--radius-lg) 0 0;
    padding: 32px 20px calc(20px + env(safe-area-inset-bottom));
    box-shadow: 0 -12px 30px -18px rgba(4, 8, 34, 0.5);
    z-index: 1;
  }
  .panel__inner { justify-content: flex-start; gap: 0; }
  .panel__brand { display: none; }
}

@media (max-width: 380px) {
  .hero__chip { display: none; }
  .form__row { flex-direction: column; align-items: flex-start; gap: 0; }
}

@media (max-height: 640px) and (min-width: 901px) {
  .panel__inner { gap: 24px; }
  .view__head { margin-bottom: 20px; }
}

/* =========================================================
   Reduced motion: keep opacity/color, drop movement
   ========================================================= */
@media (prefers-reduced-motion: reduce) {
  .reveal,
  .hero__top,
  .hero__copy {
    animation: fadeIn 300ms ease forwards;
    animation-delay: 0ms;
    transform: none;
  }
  .hero__img {
    transform: none;
    animation: fadeIn 400ms ease forwards;
  }
  .hero__glow { animation: fadeIn 400ms ease forwards; }
  .hero__chip-dot::after { animation: none; }
  .card.is-shake { animation: none; }
  .field__hint { animation: none; }

  .btn__layer,
  .alert__box,
  .field__error > p,
  .pw-toggle svg,
  .field__control::after { transform: none !important; }

  .btn:active,
  .back:active,
  .check:active .check__box { transform: none !important; }
  .pw-toggle:active { transform: translateY(-50%) !important; }

  .btn--primary::after { display: none; }
  .spinner { animation-duration: 1.2s; }
}
