:root{
  --bg-1:#07111d;
  --bg-2:#0f172a;
  --panel:rgba(15, 23, 42, 0.72);
  --border:rgba(255,255,255,0.10);
  --text:#f1f5ff;
  --muted:#a1afc4;
  --accent:#5fbdf8;
  --accent-2:#89a6ff;
  --accent-soft:rgba(95, 189, 248, 0.16);
  --danger:#ff8080;
  --danger-soft:rgba(255, 128, 128, 0.12);
  --shadow:0 28px 90px rgba(0,0,0,.40);
  --radius:28px;
}

*{ box-sizing:border-box; }
html,body{ margin:0; min-height:100%; }

body{
  min-height:100vh;
  font-family: Inter, system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  color:var(--text);
  background:
    radial-gradient(circle at 18% 18%, rgba(95,189,248,.14), transparent 28%),
    radial-gradient(circle at 82% 80%, rgba(137,166,255,.12), transparent 30%),
    linear-gradient(145deg, var(--bg-1), var(--bg-2));
  overflow:hidden;
}

.bg-orb{
  position:fixed;
  border-radius:999px;
  filter: blur(20px);
  pointer-events:none;
}

.bg-orb-1{
  width:340px;
  height:340px;
  left:-90px;
  top:-90px;
  background:radial-gradient(circle, rgba(95,189,248,.22), transparent 70%);
}

.bg-orb-2{
  width:420px;
  height:420px;
  right:-140px;
  bottom:-150px;
  background:radial-gradient(circle, rgba(137,166,255,.16), transparent 72%);
}

.grid-overlay{
  position:fixed;
  inset:0;
  background-image:
    linear-gradient(rgba(255,255,255,.035) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,.035) 1px, transparent 1px);
  background-size:64px 64px;
  mask-image:radial-gradient(circle at center, black 46%, transparent 100%);
  pointer-events:none;
  opacity:.65;
}

.auth-shell{
  position:relative;
  z-index:1;
  width:min(1120px, calc(100% - 40px));
  min-height:calc(100vh - 40px);
  margin:20px auto;
  display:grid;
  grid-template-columns:1.05fr .95fr;
  gap:24px;
  align-items:stretch;
}

.brand-panel,
.login-panel{
  border:1px solid var(--border);
  border-radius:var(--radius);
  background:linear-gradient(180deg, var(--panel), rgba(10, 16, 30, 0.72));
  box-shadow:var(--shadow);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
}

.brand-panel{
  padding:44px;
  display:flex;
  flex-direction:column;
  justify-content:space-between;
  position:relative;
  overflow:hidden;
}

.brand-panel::after{
  content:"";
  position:absolute;
  inset:auto -120px -120px auto;
  width:360px;
  height:360px;
  border-radius:50%;
  background:radial-gradient(circle, rgba(95,189,248,.10), transparent 68%);
  pointer-events:none;
}

.brand-lockup{
  display:flex;
  align-items:center;
  gap:16px;
}

.brand-mark{
  width:60px;
  height:60px;
  border-radius:18px;
  display:grid;
  place-items:center;
  font-weight:800;
  font-size:26px;
  color:white;
  background:linear-gradient(135deg, var(--accent), var(--accent-2));
  box-shadow:0 18px 32px rgba(95,189,248,.24);
}

.eyebrow,
.panel-kicker,
.status-label{
  margin:0 0 6px 0;
  text-transform:uppercase;
  letter-spacing:.16em;
  font-size:.74rem;
  color:var(--muted);
}

.brand-panel h1{
  margin:0;
  font-size:clamp(2rem, 4vw, 3.3rem);
  line-height:1.02;
  letter-spacing:-0.04em;
}

.lead{
  max-width:54ch;
  margin:28px 0 0;
  color:#cbd7ea;
  line-height:1.75;
  font-size:1.02rem;
}

.feature-list{
  display:grid;
  gap:14px;
  margin:32px 0 28px;
}

.feature{
  display:flex;
  align-items:flex-start;
  gap:12px;
  padding:14px 16px;
  border-radius:18px;
  background:rgba(255,255,255,.045);
  border:1px solid rgba(255,255,255,.06);
}

.feature-dot{
  width:10px;
  height:10px;
  margin-top:6px;
  flex:0 0 10px;
  border-radius:999px;
  background:linear-gradient(135deg, var(--accent), var(--accent-2));
  box-shadow:0 0 0 6px rgba(95,189,248,.08);
}

.status-card{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:16px;
  padding:18px 20px;
  border-radius:20px;
  background:rgba(255,255,255,.05);
  border:1px solid rgba(255,255,255,.08);
}

.status-card strong{
  font-size:1.05rem;
  letter-spacing:.01em;
}

.status-pill{
  padding:10px 14px;
  border-radius:999px;
  background:rgba(255,255,255,.06);
  border:1px solid rgba(255,255,255,.08);
  color:#d9e7ff;
  font-size:.9rem;
  white-space:nowrap;
}

.login-panel{
  padding:36px;
  display:flex;
  flex-direction:column;
  justify-content:center;
}

.panel-header{
  display:flex;
  align-items:flex-start;
  justify-content:space-between;
  gap:16px;
}

.panel-header h2{
  margin:0;
  font-size:clamp(1.65rem, 3vw, 2.2rem);
  letter-spacing:-0.03em;
}

.mini-badge{
  padding:10px 12px;
  border-radius:999px;
  background:var(--accent-soft);
  border:1px solid rgba(95,189,248,.18);
  color:#d8f3ff;
  font-size:.85rem;
  white-space:nowrap;
}

.panel-text{
  margin:12px 0 24px;
  color:var(--muted);
  line-height:1.65;
}

.error-banner{
  display:none;
  margin-bottom:18px;
  padding:14px 16px;
  border-radius:18px;
  background:var(--danger-soft);
  border:1px solid rgba(255,128,128,.30);
  color:#ffd7d7;
  line-height:1.5;
}

.error-banner.show{ display:block; }

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

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

.field > span{
  font-size:.95rem;
  color:#dce8fb;
}

input{
  width:100%;
  height:52px;
  border-radius:16px;
  border:1px solid rgba(255,255,255,.10);
  background:rgba(255,255,255,.045);
  color:var(--text);
  padding:0 16px;
  font-size:1rem;
  outline:none;
  transition:border-color .18s ease, box-shadow .18s ease, background .18s ease;
}

input::placeholder{
  color:#8090ad;
}

input:focus{
  border-color:rgba(95,189,248,.55);
  box-shadow:0 0 0 4px rgba(95,189,248,.10);
  background:rgba(255,255,255,.06);
}

input.error{
  border-color:rgba(255,128,128,.55);
  background:rgba(255,128,128,.07);
  box-shadow:0 0 0 4px rgba(255,128,128,.10);
}

.password-wrap{
  display:flex;
  gap:10px;
  align-items:center;
}

.password-wrap input{
  flex:1;
}

.icon-button{
  height:52px;
  padding:0 14px;
  border-radius:16px;
  border:1px solid rgba(255,255,255,.10);
  background:rgba(255,255,255,.045);
  color:#dbeafe;
  cursor:pointer;
  font-size:.92rem;
}

.icon-button:hover{
  background:rgba(255,255,255,.075);
}

.field-error{
  display:none;
  color:#ffbcbc;
  font-size:.88rem;
  line-height:1.35;
}

.field-error.show{ display:block; }

.form-row{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:12px;
  flex-wrap:wrap;
  padding-top:2px;
}

.checkbox{
  display:flex;
  align-items:center;
  gap:10px;
  color:#d7e4fa;
  user-select:none;
  font-size:.95rem;
}

.checkbox input{
  width:18px;
  height:18px;
  margin:0;
  accent-color:var(--accent);
}

.link{
  color:#9fdcff;
  text-decoration:none;
  font-size:.95rem;
}

.link:hover{
  text-decoration:underline;
}

.submit-button{
  width:100%;
  height:54px;
  margin-top:4px;
  border:0;
  border-radius:16px;
  background:linear-gradient(135deg, var(--accent), var(--accent-2));
  color:white;
  font-weight:700;
  font-size:1rem;
  cursor:pointer;
  box-shadow:0 18px 34px rgba(95,189,248,.20);
  transition:transform .18s ease, box-shadow .18s ease, filter .18s ease;
}

.submit-button:hover{
  transform:translateY(-1px);
  filter:saturate(1.04);
  box-shadow:0 22px 40px rgba(95,189,248,.24);
}

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

.footer-note{
  margin:18px 0 0;
  text-align:center;
  color:var(--muted);
  font-size:.9rem;
}

@media (max-width: 980px){
  body{ overflow:auto; }

  .auth-shell{
    min-height:auto;
    grid-template-columns:1fr;
    width:min(760px, calc(100% - 24px));
    margin:12px auto;
    padding-bottom:12px;
  }

  .brand-panel,
  .login-panel{
    min-height:auto;
  }
}

@media (max-width: 640px){
  .auth-shell{
    width:calc(100% - 16px);
  }

  .brand-panel,
  .login-panel{
    padding:24px;
    border-radius:24px;
  }

  .status-card{
    flex-direction:column;
    align-items:flex-start;
  }

  .panel-header{
    flex-direction:column;
    align-items:flex-start;
  }

  .mini-badge{
    align-self:flex-start;
  }

  .password-wrap{
    flex-direction:column;
    align-items:stretch;
  }

  .icon-button{
    width:100%;
  }
}
