/* Login page */
.shell {
  position: relative; z-index: 1;
  width: min(1080px, calc(100% - 32px));
  margin: 72px auto 40px;
  margin-block: max(72px, calc((100vh - 600px) / 2)) 40px;
  display: grid; grid-template-columns: 1.15fr 1fr;
  border-radius: 32px;
  background: var(--card);
  box-shadow: var(--shadow), 0 0 0 1px var(--glass-line);
  overflow: hidden;
  animation: rise .7s cubic-bezier(.2,.8,.2,1) both;
}
@keyframes rise { from { opacity: 0; transform: translateY(18px) scale(.985); } to { opacity: 1; transform: none; } }

/* Left: hero band */
.hero {
  position: relative; overflow: hidden;
  padding: 44px 44px 40px;
  color: #fff;
  background:
    radial-gradient(120% 90% at 100% 0%, rgba(125, 211, 252, .55), transparent 55%),
    radial-gradient(90% 70% at 0% 100%, rgba(20, 26, 92, .9), transparent 60%),
    linear-gradient(150deg, var(--grad1) 0%, #0b6fb8 45%, var(--grad2) 100%);
  display: flex; flex-direction: column;
  min-height: 580px;
}
.hero::after { /* big soft wave */
  content: ""; position: absolute; right: -120px; bottom: -160px;
  width: 460px; height: 460px; border-radius: 50%;
  background: radial-gradient(circle, rgba(255,255,255,.18), rgba(255,255,255,0) 65%);
}
.dots { position: absolute; width: 132px; height: 84px; opacity: .55;
  background-image: radial-gradient(rgba(255,255,255,.75) 1.6px, transparent 1.8px); background-size: 14px 14px; }
.dots-a { top: 22px; right: 28px; }
.dots-b { bottom: 26px; left: 40%; width: 96px; height: 56px; opacity: .35; }

.brand { position: relative; display: flex; align-items: center; gap: 16px; }
.halo {
  width: 124px; height: 124px; border-radius: 50%; flex: none;
  background: #fff; padding: 0;
  box-shadow: 0 0 0 7px rgba(255,255,255,.22), 0 0 0 14px rgba(255,255,255,.10), 0 18px 40px -12px rgba(8, 20, 70, .6);
}
.halo img { width: 100%; height: 100%; object-fit: cover; border-radius: 50%; display: block; }
.kicker { margin: 0; font: 700 16px var(--body); letter-spacing: .02em; color: rgba(255,255,255,.88); }

.hero h1 {
  position: relative;
  margin: 34px 0 14px;
  font-family: var(--display); font-weight: 800;
  font-size: clamp(34px, 4.1vw, 50px); line-height: 1.04; letter-spacing: -.02em;
  max-width: 13ch;
  text-wrap: balance;
}
.lede { position: relative; margin: 0; max-width: 38ch; font-size: 18px; color: rgba(255,255,255,.88); }

/* Floating glass mini-cards */
.float-stack { position: relative; margin-top: auto; height: 214px; flex: none; }
.glass {
  position: absolute;
  background: rgba(255,255,255,.16);
  border: 1px solid rgba(255,255,255,.42);
  -webkit-backdrop-filter: blur(12px); backdrop-filter: blur(12px);
  border-radius: 16px; color: #fff;
  box-shadow: 0 0 0 1px rgba(255,255,255,.08), 0 18px 34px -18px rgba(5, 15, 60, .65);
  font-size: 14px;
}
.g-head { display: flex; align-items: center; gap: 8px; padding: 10px 14px; font-weight: 700; border-bottom: 1px solid rgba(255,255,255,.25); }
.g-head .dot { width: 8px; height: 8px; border-radius: 50%; background: var(--yellow); box-shadow: 0 0 10px var(--yellow); }
.g-head .dot.live { background: #6ee7b7; box-shadow: 0 0 10px #6ee7b7; }
.g-row { display: flex; justify-content: space-between; gap: 18px; padding: 8px 14px; color: rgba(255,255,255,.9); }
.g-row + .g-row { border-top: 1px solid rgba(255,255,255,.14); }
.mask { letter-spacing: .12em; opacity: .85; }
.tag { background: var(--yellow); color: var(--yellow-ink); font-weight: 700; font-size: 12px; padding: 1px 8px; border-radius: 999px; }
.g1 { left: 0; bottom: 34px; width: 250px; }
.g2 { left: 210px; bottom: 112px; width: 250px; }
.g3 { left: 236px; bottom: 6px; padding: 10px 16px; display: flex; align-items: center; gap: 10px; font-weight: 700; }
.check { width: 22px; height: 22px; border-radius: 50%; display: grid; place-items: center; background: var(--yellow); color: var(--yellow-ink); font-size: 13px; }
.g1 { animation: bob 7s ease-in-out infinite; }
.g2 { animation: bob 8s ease-in-out -2s infinite; }
.g3 { animation: bob 6s ease-in-out -4s infinite; }
@keyframes bob { 50% { transform: translateY(-6px); } }

/* Right: form panel */
.panel { display: flex; align-items: center; padding: 48px 48px; background: var(--card); }
.panel-inner { width: 100%; max-width: 380px; margin: 0 auto; }
.panel h2 { margin: 0 0 6px; font-family: var(--display); font-weight: 800; font-size: 34px; letter-spacing: -.015em; line-height: 1.1; }
.sub { margin: 0 0 26px; color: var(--muted); }

.alert {
  margin: -6px 0 18px; padding: 11px 14px; border-radius: 12px;
  background: var(--errbg); color: var(--err); font-weight: 600; font-size: 15px;
  border: 1px solid color-mix(in srgb, var(--err) 25%, transparent);
}

.field { display: block; margin-bottom: 16px; }
.f-label { display: block; margin-bottom: 6px; font-weight: 700; font-size: 15px; }
.f-wrap {
  display: flex; align-items: center; gap: 10px;
  padding: 0 6px 0 14px; height: 52px;
  border: 1.5px solid var(--line); border-radius: 14px; background: var(--field);
  color: var(--muted);
  transition: border-color .15s, box-shadow .15s;
}
.f-wrap:focus-within { border-color: var(--brand); box-shadow: 0 0 0 4px color-mix(in srgb, var(--brand) 18%, transparent); color: var(--brand); }
.f-wrap input {
  flex: 1; min-width: 0; height: 100%; border: 0; outline: 0; background: transparent;
  font: 400 17px var(--body); color: var(--ink);
}
.reveal {
  border: 0; background: var(--soft); color: var(--brand); cursor: pointer;
  font: 700 13px var(--body); padding: 7px 12px; border-radius: 10px;
}

.remember { display: flex; align-items: center; gap: 10px; margin: 6px 0 24px; cursor: pointer; font-size: 16px; color: var(--ink); user-select: none; }
.remember input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.remember .box {
  width: 22px; height: 22px; border-radius: 7px; flex: none;
  border: 1.5px solid var(--line); background: var(--field); display: grid; place-items: center;
}
.remember input:checked + .box { background: var(--brand); border-color: var(--brand); }
.remember input:checked + .box::after { content: ""; width: 10px; height: 5px; border: solid #fff; border-width: 0 0 2.5px 2.5px; transform: rotate(-45deg) translate(1px, -1px); }
.remember input:focus-visible + .box { outline: 3px solid var(--yellow); outline-offset: 2px; }

.cta {
  width: 100%; height: 54px; border: 0; border-radius: 999px; cursor: pointer;
  font: 800 18px var(--display); letter-spacing: .005em;
  color: var(--yellow-ink); background: var(--yellow);
  box-shadow: 0 12px 26px -12px rgba(230, 170, 0, .8), inset 0 -3px 0 rgba(0,0,0,.08);
  transition: transform .12s, box-shadow .12s, filter .12s;
}
.cta:hover { filter: brightness(1.03); box-shadow: 0 16px 30px -12px rgba(230, 170, 0, .9), inset 0 -3px 0 rgba(0,0,0,.08); }
.cta:active { transform: translateY(1px); }
.cta[disabled] { opacity: .7; cursor: progress; }

.foot { margin: 22px 0 0; text-align: center; color: var(--muted); font-size: 15px; }

/* Wrong password: shake the card once */
.is-error .panel-inner { animation: shake .42s cubic-bezier(.36,.07,.19,.97) both; }
@keyframes shake { 20%, 60% { transform: translateX(-8px); } 40%, 80% { transform: translateX(8px); } }

/* Tablet / mobile */
@media (max-width: 900px) {
  .shell { grid-template-columns: 1fr; margin-top: 70px; border-radius: 26px; }
  .hero { min-height: 0; padding: 30px 26px 28px; align-items: center; text-align: center; }
  .brand { flex-direction: column; gap: 12px; }
  .hero h1 { margin: 20px auto 10px; font-size: 32px; }
  .lede { margin: 0 auto; font-size: 16px; }
  .float-stack, .dots-b { display: none; }
  .panel { padding: 30px 22px 34px; }
}
@media (max-width: 420px) {
  .shell { width: calc(100% - 32px); }
  .halo { width: 104px; height: 104px; }
  .panel h2 { font-size: 28px; }
}
