.internal-body {
  min-height: 100vh;
  background: var(--bg);
}

.auth-shell {
  width: min(1120px, calc(100% - 48px));
  min-height: 100vh;
  display: grid;
  grid-template-columns: 0.95fr 1.05fr;
  align-items: center;
  gap: 36px;
  margin: 0 auto;
  padding: 70px 0;
}

.auth-brand {
  animation: authRise 760ms cubic-bezier(0.2, 0.8, 0.2, 1) both;
}

.auth-brand img {
  width: 84px;
  height: 84px;
  object-fit: contain;
  margin-bottom: 24px;
  filter: drop-shadow(0 18px 34px rgba(145, 255, 91, 0.18));
}

.auth-brand h1,
.dashboard-top h1 {
  margin: 0;
  font-family: var(--font-display);
  font-size: clamp(3rem, 7vw, 6.8rem);
  line-height: 0.9;
}

.auth-brand p:not(.eyebrow),
.dashboard-top p:not(.eyebrow) {
  max-width: 620px;
  color: var(--muted);
  font-size: 1.08rem;
  font-weight: 720;
}

.auth-legal-frame {
  position: relative;
  width: min(100%, 430px);
  margin-top: 28px;
  padding: 18px;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 8px;
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.11), rgba(255, 255, 255, 0.018) 48%),
    rgba(255, 255, 255, 0.035);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.24),
    0 24px 68px rgba(0, 0, 0, 0.34);
  backdrop-filter: blur(26px) saturate(155%);
  -webkit-backdrop-filter: blur(26px) saturate(155%);
}

.auth-legal-frame::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(110deg, transparent, rgba(255, 255, 255, 0.16), transparent);
  transform: translateX(-120%);
  animation: authSheen 4.2s ease-in-out infinite;
}

.auth-legal-frame span,
.auth-legal-frame small {
  position: relative;
  display: block;
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 900;
  text-transform: uppercase;
}

.auth-legal-frame strong {
  position: relative;
  display: block;
  margin: 8px 0;
  font-family: var(--font-display);
  font-size: clamp(2.1rem, 5vw, 4rem);
  line-height: 0.9;
}

.auth-back {
  width: fit-content;
  min-height: 46px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin-top: 18px;
  padding: 0 18px;
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.055);
  color: var(--ink);
  font-weight: 920;
  transition: transform 180ms ease, border-color 180ms ease, background 180ms ease;
}

.auth-back:hover {
  transform: translateY(-2px);
  border-color: rgba(145, 255, 91, 0.48);
  background: rgba(145, 255, 91, 0.09);
}

.auth-panel,
.dash-panel,
.dashboard-side {
  border: 1px solid rgba(255, 255, 255, 0.13);
  border-radius: 8px;
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.105), rgba(255, 255, 255, 0.024) 40%),
    rgba(255, 255, 255, 0.032);
  box-shadow: 0 28px 90px rgba(0, 0, 0, 0.42);
  backdrop-filter: blur(28px) saturate(160%);
  -webkit-backdrop-filter: blur(28px) saturate(160%);
}

.auth-panel {
  padding: 26px;
  animation: authRise 760ms 120ms cubic-bezier(0.2, 0.8, 0.2, 1) both;
}

.auth-tabs {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  margin-bottom: 18px;
}

.auth-tabs button,
.panel-head button,
.mini-form button,
.captcha-line button,
.side-logout {
  min-height: 44px;
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.065);
  color: var(--ink);
  font-weight: 900;
  cursor: pointer;
}

.auth-tabs button.is-active,
.mini-form button {
  background: var(--ink);
  color: #050506;
}

.auth-form {
  display: none;
  gap: 14px;
}

.auth-form.is-active {
  display: grid;
}

.auth-form label,
.mini-form input,
.mini-form select,
.auth-form input {
  min-width: 0;
}

.auth-form label {
  display: grid;
  gap: 8px;
  color: var(--muted);
  font-size: 0.8rem;
  font-weight: 950;
  text-transform: uppercase;
}

.auth-form input,
.mini-form input,
.mini-form select {
  min-height: 48px;
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 8px;
  background: rgba(0, 0, 0, 0.24);
  color: var(--ink);
  padding: 0 13px;
  font-weight: 780;
}

.captcha-line {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 10px;
  align-items: end;
}

.captcha-question,
.auth-status {
  margin: 0;
  color: var(--muted);
  font-weight: 780;
}

.password-meter {
  --strength: 25%;
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: center;
  gap: 12px;
  min-height: 36px;
  padding: 8px 10px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 999px;
  background: rgba(0, 0, 0, 0.22);
}

.password-meter i {
  position: relative;
  height: 8px;
  overflow: hidden;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.08);
}

.password-meter i::before {
  content: "";
  position: absolute;
  inset: 0 auto 0 0;
  width: var(--strength);
  border-radius: inherit;
  background: #ff5f45;
  transition: width 220ms ease, background 220ms ease;
}

.password-meter span {
  color: var(--muted);
  font-size: 0.74rem;
  font-weight: 920;
  text-transform: uppercase;
}

.password-meter.score-2 i::before {
  background: #f4c84a;
}

.password-meter.score-3 i::before,
.password-meter.score-4 i::before {
  background: var(--acid);
}

.password-meter.score-4 span {
  color: var(--ink);
}

.dashboard-shell {
  min-height: 100vh;
  display: grid;
  grid-template-columns: 280px 1fr;
}

.dashboard-side {
  position: sticky;
  top: 0;
  height: 100vh;
  display: flex;
  flex-direction: column;
  gap: 22px;
  padding: 22px;
  border-top: 0;
  border-bottom: 0;
  border-left: 0;
  border-radius: 0;
}

.dashboard-logo {
  display: flex;
  align-items: center;
  gap: 12px;
  font-weight: 950;
}

.dashboard-logo img {
  width: 46px;
  height: 46px;
  object-fit: contain;
}

.dashboard-side nav {
  display: grid;
  gap: 8px;
}

.dashboard-side nav a,
.user-chip {
  padding: 13px 14px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.035);
  color: var(--muted);
  font-weight: 860;
}

.user-chip {
  margin-top: auto;
  color: var(--ink);
}

.dashboard-main {
  padding: 44px;
}

.panel-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
  margin-top: 34px;
}

.dash-panel {
  padding: 20px;
}

.dash-panel.wide {
  grid-column: 1 / -1;
}

.panel-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  margin-bottom: 16px;
}

.panel-head h2 {
  margin: 0;
  font-family: var(--font-display);
  font-size: 1.55rem;
}

.mini-form {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin-bottom: 16px;
}

.checkline {
  min-height: 48px;
  display: flex;
  align-items: center;
  gap: 9px;
  color: var(--muted);
  font-weight: 850;
}

.dash-list {
  display: grid;
  gap: 8px;
  max-height: 360px;
  overflow: auto;
}

.dash-row {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 12px;
  align-items: center;
  padding: 12px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 8px;
  background: rgba(0, 0, 0, 0.18);
}

.dash-row-edit {
  align-items: start;
}

.dash-row strong {
  display: block;
}

.dash-row span,
.dash-row small {
  display: block;
  color: var(--muted);
  font-size: 0.86rem;
  font-weight: 760;
}

.dash-row small {
  max-width: 900px;
  margin-top: 5px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.dash-inline {
  display: grid;
  grid-template-columns: repeat(4, minmax(130px, 1fr));
  gap: 8px;
  margin-top: 10px;
}

.dash-inline input,
.dash-inline select {
  min-height: 38px;
  min-width: 0;
  border: 1px solid rgba(255, 255, 255, 0.13);
  border-radius: 8px;
  background: rgba(0, 0, 0, 0.24);
  color: var(--ink);
  padding: 0 10px;
  font-weight: 760;
}

.dash-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: flex-end;
}

.dash-row button {
  min-height: 36px;
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.06);
  color: var(--ink);
  font-weight: 880;
}

@keyframes authRise {
  from {
    opacity: 0;
    transform: translateY(28px) scale(0.985);
  }

  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

@keyframes authSheen {
  0%,
  45% {
    transform: translateX(-120%);
  }

  70%,
  100% {
    transform: translateX(120%);
  }
}

@media (max-width: 980px) {
  .auth-shell,
  .dashboard-shell {
    grid-template-columns: 1fr;
  }

  .dashboard-side {
    position: relative;
    height: auto;
  }

  .panel-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 620px) {
  .auth-shell,
  .dashboard-main {
    width: min(100% - 28px, 1120px);
    padding-left: 0;
    padding-right: 0;
  }

  .mini-form,
  .captcha-line,
  .dash-inline {
    grid-template-columns: 1fr;
  }

  .dash-row {
    grid-template-columns: 1fr;
  }

  .dash-actions {
    justify-content: flex-start;
  }
}
