:root {
  color-scheme: light;
  font-family:
    Inter, "SF Pro Display", "PingFang SC", "Microsoft YaHei", system-ui,
    sans-serif;
  color: #172033;
  background: #d9dde1;
  font-synthesis: none;
}

* {
  box-sizing: border-box;
}

html,
body {
  min-height: 100%;
  margin: 0;
}

body {
  min-height: 100dvh;
  background: url("/assets/showroom-hero.jpg") center / cover fixed;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -1;
  background: rgba(234, 237, 239, 0.72);
}

button,
input {
  font: inherit;
}

button,
a {
  -webkit-tap-highlight-color: transparent;
}

.portal {
  min-height: 100dvh;
  display: grid;
  place-items: center;
  padding: 24px;
}

.portal-shell {
  width: min(980px, 100%);
  min-height: min(620px, calc(100dvh - 48px));
  display: grid;
  grid-template-columns: minmax(0, 1.08fr) minmax(300px, 0.92fr);
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.82);
  border-radius: 32px;
  background: rgba(248, 249, 250, 0.82);
  box-shadow:
    0 28px 80px rgba(32, 40, 48, 0.18),
    inset 0 1px 0 rgba(255, 255, 255, 0.8);
  backdrop-filter: blur(24px) saturate(120%);
}

.portal-shell,
.guest-loader {
  transform-origin: center;
}

.portal-content {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 44px;
  padding: clamp(34px, 5vw, 68px);
}

.portal-brand {
  display: flex;
  align-items: center;
  gap: 14px;
}

.portal-brand img {
  width: 86px;
  height: 44px;
  object-fit: contain;
  border-radius: 4px;
  background: #fff;
}

.portal-brand span {
  color: #172033;
  font-size: 24px;
  font-weight: 800;
  line-height: 1;
}

.portal-copy {
  max-width: 540px;
}

.portal-kicker {
  margin: 0 0 14px;
  color: #677384;
  font-size: 14px;
  font-weight: 650;
}

.portal-copy h1 {
  margin: 0;
  max-width: 12ch;
  font-size: clamp(38px, 5vw, 64px);
  line-height: 1.08;
  letter-spacing: 0;
}

.portal-copy p {
  margin: 20px 0 0;
  max-width: 30em;
  color: #657184;
  font-size: 17px;
  line-height: 1.75;
}

.portal-access-notes {
  display: grid;
  gap: 8px;
  margin-top: 20px;
}

.portal-copy .portal-access-notes p {
  display: flex;
  align-items: baseline;
  gap: 12px;
  margin: 0;
}

.portal-access-notes strong {
  flex: 0 0 5em;
  color: #283446;
  font-size: 16px;
  font-weight: 750;
}

.portal-access-notes span {
  min-width: 0;
}

.portal-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.portal-action,
.form-submit {
  min-height: 56px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid rgba(23, 32, 51, 0.12);
  border-radius: 16px;
  color: #172033;
  background: rgba(255, 255, 255, 0.66);
  font-weight: 700;
  text-decoration: none;
  cursor: pointer;
  transition:
    transform 160ms ease,
    background-color 160ms ease,
    border-color 160ms ease;
}

.portal-action.primary,
.form-submit {
  border-color: #202b3c;
  color: #fff;
  background: #202b3c;
}

.portal-action:hover,
.form-submit:hover {
  transform: translateY(-1px);
}

.portal-action:not(.primary):hover {
  border-color: rgba(23, 32, 51, 0.28);
  background: rgba(255, 255, 255, 0.92);
}

.portal-action:active,
.form-submit:active {
  transform: translateY(0);
}

.portal-action:focus-visible,
.form-submit:focus-visible,
.field input:focus-visible {
  outline: 3px solid rgba(42, 111, 92, 0.28);
  outline-offset: 2px;
}

.portal-image {
  min-height: 420px;
  background: url("/assets/veij-stair.jpg") center / cover;
}

.login-shell {
  grid-template-columns: minmax(320px, 0.9fr) minmax(0, 1.1fr);
}

.login-shell .portal-image {
  order: -1;
}

.login-panel {
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: clamp(34px, 5vw, 68px);
}

.login-back {
  width: fit-content;
  margin-bottom: 46px;
  color: #667285;
  font-size: 14px;
  text-decoration: none;
}

.login-panel h1 {
  margin: 22px 0 8px;
  font-size: 34px;
  line-height: 1.2;
  letter-spacing: 0;
}

.login-panel > p {
  margin: 0 0 30px;
  color: #687386;
  line-height: 1.7;
}

.login-form {
  display: grid;
  gap: 18px;
}

.field {
  display: grid;
  gap: 8px;
}

.field span {
  color: #4f5b6c;
  font-size: 14px;
  font-weight: 650;
}

.field input {
  width: 100%;
  min-height: 52px;
  border: 1px solid rgba(23, 32, 51, 0.14);
  border-radius: 14px;
  padding: 0 16px;
  color: #172033;
  background: rgba(255, 255, 255, 0.72);
  outline: none;
}

.field input:focus {
  border-color: rgba(42, 111, 92, 0.64);
  background: #fff;
}

.form-submit {
  margin-top: 6px;
}

.form-submit:disabled {
  cursor: wait;
  opacity: 0.65;
}

.form-status {
  min-height: 24px;
  margin: 0;
  color: #a23d34;
  font-size: 14px;
  line-height: 1.6;
}

.guest-loader {
  width: min(520px, 100%);
  padding: 50px;
  border: 1px solid rgba(255, 255, 255, 0.82);
  border-radius: 28px;
  text-align: center;
  background: rgba(248, 249, 250, 0.86);
  box-shadow: 0 24px 70px rgba(32, 40, 48, 0.17);
  backdrop-filter: blur(24px);
}

.guest-loader img {
  width: 90px;
  border-radius: 4px;
}

.guest-loader h1 {
  margin: 26px 0 10px;
  font-size: 28px;
  letter-spacing: 0;
}

.guest-loader p {
  margin: 0;
  color: #687386;
  line-height: 1.7;
}

.loader-line {
  width: 100%;
  height: 3px;
  margin-top: 30px;
  overflow: hidden;
  border-radius: 2px;
  background: rgba(23, 32, 51, 0.1);
}

.loader-line::after {
  content: "";
  display: block;
  width: 38%;
  height: 100%;
  background: #2a6f5c;
  animation: loader 1.2s ease-in-out infinite;
}

@keyframes loader {
  from {
    transform: translateX(-110%);
  }
  to {
    transform: translateX(300%);
  }
}

@media (prefers-reduced-motion: no-preference) {
  .portal-shell,
  .guest-loader {
    opacity: 0;
    transform: translateY(24px) scale(0.985);
    animation: portal-float-in 920ms cubic-bezier(0.16, 1, 0.3, 1) 80ms forwards;
    will-change: opacity, transform;
  }

  .portal-image {
    opacity: 0;
    transform: translateX(18px) scale(1.015);
    animation: portal-image-in 980ms cubic-bezier(0.16, 1, 0.3, 1) 180ms forwards;
    will-change: opacity, transform;
  }

  .login-shell .portal-image {
    transform: translateX(-18px) scale(1.015);
    animation-name: portal-image-in-reverse;
  }

  .portal-brand,
  .portal-copy,
  .portal-actions,
  .login-back,
  .login-panel h1,
  .login-panel > p,
  .login-form .field,
  .form-submit,
  .guest-loader img,
  .guest-loader h1,
  .guest-loader p,
  .loader-line {
    opacity: 0;
    transform: translateY(16px);
    animation: portal-soft-rise 760ms cubic-bezier(0.16, 1, 0.3, 1) both;
    will-change: opacity, transform;
  }

  .portal-brand,
  .login-back,
  .guest-loader img {
    animation-delay: 180ms;
  }

  .portal-copy,
  .login-panel .portal-brand,
  .guest-loader h1 {
    animation-delay: 260ms;
  }

  .login-panel h1,
  .guest-loader p {
    animation-delay: 340ms;
  }

  .login-panel > p,
  .loader-line {
    animation-delay: 420ms;
  }

  .login-form .field:nth-of-type(1) {
    animation-delay: 500ms;
  }

  .login-form .field:nth-of-type(2) {
    animation-delay: 570ms;
  }

  .portal-actions,
  .form-submit {
    animation-delay: 640ms;
  }
}

@keyframes portal-float-in {
  from {
    opacity: 0;
    transform: translateY(24px) scale(0.985);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

@keyframes portal-soft-rise {
  from {
    opacity: 0;
    transform: translateY(16px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes portal-image-in {
  from {
    opacity: 0;
    transform: translateX(18px) scale(1.015);
  }
  to {
    opacity: 1;
    transform: translateX(0) scale(1);
  }
}

@keyframes portal-image-in-reverse {
  from {
    opacity: 0;
    transform: translateX(-18px) scale(1.015);
  }
  to {
    opacity: 1;
    transform: translateX(0) scale(1);
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}

@media (max-width: 760px) {
  body {
    background-attachment: scroll;
  }

  .portal {
    align-items: stretch;
    padding: 12px;
  }

  .portal-shell,
  .login-shell {
    min-height: calc(100dvh - 24px);
    grid-template-columns: 1fr;
    grid-template-rows: minmax(220px, 34dvh) 1fr;
    border-radius: 26px;
  }

  .portal-content,
  .login-panel {
    order: 2;
    gap: 30px;
    padding: 30px 24px 26px;
  }

  .portal-image,
  .login-shell .portal-image {
    min-height: 220px;
    order: 1;
  }

  .entry-page .portal-image {
    background-position: center 66%;
  }

  .portal-copy h1 {
    max-width: none;
    font-size: 38px;
  }

  .portal-copy p {
    margin-top: 14px;
    font-size: 15px;
  }

  .portal-access-notes {
    gap: 6px;
    margin-top: 14px;
  }

  .portal-access-notes strong {
    font-size: 15px;
  }

  .portal-actions {
    grid-template-columns: 1fr;
  }

  .login-back {
    margin-bottom: 10px;
  }

  .login-panel h1 {
    margin-top: 18px;
    font-size: 30px;
  }

  .guest-loader {
    align-self: center;
    padding: 38px 24px;
  }
}
