/* ========== Tenant login: full-page blurred image + centered sign-in card ==========
 * Loaded after auth.css by resources/views/auth/login.blade.php only; every
 * rule is scoped to .auth-page--image so the password/verify screens that
 * share auth.css are untouched.
 */
.auth-login.auth-login--image {
  background: #0f1f3a;
}

.auth-page--image {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 100dvh;
  padding: 24px 16px;
  position: relative;
}

/* ---- Background image (fixed, covers the whole screen, slightly blurred) ---- */
.auth-page--image .auth-hero {
  position: fixed;
  inset: 0;
  z-index: 0;
  display: block;
  padding: 0;
  overflow: hidden;
  background: var(--login-hero-bg, #e8f1fb);
}

.auth-page--image .hero-media {
  position: absolute;
  inset: 0;
}

.auth-page--image .hero-media img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  filter: blur(4px);
  /* scale hides the soft transparent rim a blur leaves at the edges */
  transform: scale(1.04);
}

/* light tint so the card stands out without hiding the picture */
.auth-page--image .auth-hero::after {
  content: "";
  position: absolute;
  inset: 0;
  background: rgba(10, 25, 50, 0.25);
}

.auth-page--image .hero-caption {
  display: none;
}

/* ---- Centered card ---- */
.auth-page--image .auth-panel {
  position: relative;
  z-index: 1;
  padding: 0;
  width: 100%;
  max-width: 400px;
  display: block;
}

.auth-page--image .auth-panel-inner {
  max-width: none;
  background: rgba(255, 255, 255, 0.94);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  border-radius: 20px;
  padding: 2rem 1.75rem;
  box-shadow: 0 24px 60px -12px rgba(5, 15, 35, 0.45);
  gap: 1.25rem;
}

.auth-page--image .panel-brand {
  display: block;
  max-width: 160px;
  max-height: 56px;
  object-fit: contain;
  margin: 0 auto 0.75rem;
}

.auth-page--image .auth-panel-inner header {
  text-align: center;
}

.auth-page--image .panel-title {
  font-size: 1.6rem;
}

.auth-page--image .input-shell {
  background: #ffffff;
}

.auth-page--image .input-shell input {
  padding: 0.7rem 0;
  font-size: 0.95rem;
}

.auth-page--image .auth-footer-text {
  margin: 0;
  font-size: 0.8rem;
  color: var(--auth-text-muted);
  text-align: center;
}

/* auth.css hides .auth-hero below 1024px — keep the background on every size */
@media (max-width: 1024px) {
  .auth-page--image {
    grid-template-columns: none;
  }
  .auth-page--image .auth-hero {
    display: block;
  }
}

@media (max-width: 480px) {
  .auth-login.auth-login--image {
    background: #0f1f3a;
  }
  .auth-page--image .auth-panel {
    padding: 0;
  }
  .auth-page--image .auth-panel-inner {
    padding: 1.5rem 1.25rem;
    border-radius: 16px;
  }
}

/* ---- Demo tenant: "Choose a demo shop" picker ---- */
.auth-page--image .auth-panel--demo { max-width: 520px; }
.demo-shops {
  border: 1.5px dashed rgba(76, 68, 236, 0.45);
  background: rgba(76, 68, 236, 0.06);
  border-radius: 14px;
  padding: 0.9rem;
  display: grid;
  gap: 0.7rem;
}
.demo-shops__title {
  font-size: 0.78rem; font-weight: 800; letter-spacing: 0.08em; text-transform: uppercase;
  color: var(--auth-primary, #4c44ec); display: inline-flex; align-items: center; gap: 0.45rem;
}
.demo-shops__grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 0.5rem; }
.demo-shop {
  display: flex; align-items: center; gap: 0.5rem; min-height: 46px; padding: 0.45rem 0.6rem;
  border: 2px solid transparent; border-radius: 10px; cursor: pointer; text-align: left;
  background: var(--shop-color, #4c44ec); color: #fff; font: inherit; font-size: 0.78rem; font-weight: 700; line-height: 1.15;
  transition: transform .12s ease, box-shadow .12s ease, filter .12s ease;
}
.demo-shop:hover { transform: translateY(-1px); filter: brightness(1.08); }
.demo-shop:focus-visible { outline: 3px solid rgba(76, 68, 236, 0.45); outline-offset: 2px; }
.demo-shop.is-active { border-color: #fff; box-shadow: 0 0 0 2px var(--auth-primary, #4c44ec), 0 8px 18px -8px rgba(0,0,0,.45); }
.demo-shop__icon {
  flex: 0 0 26px; width: 26px; height: 26px; border-radius: 50%; display: grid; place-items: center;
  background: rgba(255, 255, 255, 0.2); font-size: 0.85rem;
}
.demo-shops__creds {
  display: grid; grid-template-columns: auto 1fr auto 1fr; align-items: center; gap: 0.35rem 0.5rem;
  font-size: 0.7rem; font-weight: 700; letter-spacing: 0.05em; text-transform: uppercase; color: var(--auth-text-muted, #6b7280);
}
.demo-shops__creds code {
  background: #fff; border: 1px solid var(--auth-border, #e5e7eb); border-radius: 7px; padding: 0.2rem 0.5rem;
  font-size: 0.78rem; letter-spacing: 0; text-transform: none; color: var(--auth-text, #1f2937);
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.demo-shops__hint { margin: 0; font-size: 0.8rem; font-weight: 600; color: #0f5132; }
@media (max-width: 520px) {
  .demo-shops__grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .demo-shops__creds { grid-template-columns: auto 1fr; }
}

/* Demo account kind (admin preselected) */
.demo-roles { display: flex; align-items: center; gap: 0.5rem; margin: 0; }
.demo-roles__label {
  font-size: 0.7rem; font-weight: 700; letter-spacing: 0.05em; text-transform: uppercase;
  color: var(--auth-text-muted, #6b7280); white-space: nowrap;
}
.demo-roles__select {
  flex: 1; min-width: 0; height: 32px; padding: 0 0.5rem; border-radius: 8px;
  border: 1px solid var(--auth-border, #e5e7eb); background: #fff; color: var(--auth-text, #1f2937);
  font: inherit; font-size: 0.8rem; font-weight: 600; cursor: pointer;
}
.demo-roles__select:focus-visible { outline: 3px solid rgba(76, 68, 236, 0.45); outline-offset: 1px; }
