:root {
  color-scheme: light;
  --ink: #16191f;
  --muted: #69707d;
  --line: #dfe4ec;
  --panel: #ffffff;
  --blue: #145cff;
  --blue-dark: #0f3fab;
  --mint: #c7f3e4;
  --coral: #ff715b;
  --soft: #f5f7fb;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  font-family:
    Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI",
    sans-serif;
  color: var(--ink);
  background:
    radial-gradient(circle at 18% 20%, rgba(199, 243, 228, 0.85), transparent 28rem),
    radial-gradient(circle at 84% 80%, rgba(255, 113, 91, 0.16), transparent 24rem),
    var(--soft);
}

button,
input {
  font: inherit;
}

.login-page {
  width: min(1080px, calc(100% - 32px));
  min-height: 100vh;
  margin: 0 auto;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 420px;
  gap: 56px;
  align-items: center;
  padding: 48px 0;
}

.brand-panel {
  display: grid;
  gap: 34px;
  align-content: center;
}

.brand-panel h1 {
  max-width: 640px;
  margin: 0;
  font-size: clamp(48px, 7vw, 92px);
  line-height: 0.95;
  letter-spacing: 0;
}

.brand-panel p {
  max-width: 540px;
  margin: 20px 0 0;
  color: #404754;
  font-size: 18px;
  line-height: 1.6;
}

.qr-card {
  width: 184px;
  aspect-ratio: 1;
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 10px;
  padding: 18px;
  border: 1px solid rgba(22, 25, 31, 0.12);
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 24px 60px rgba(20, 92, 255, 0.14);
  transform: rotate(-3deg);
}

.qr-card div,
.qr-card span,
.qr-card i,
.qr-card b {
  display: block;
  border-radius: 4px;
  background: var(--ink);
}

.qr-card div {
  background: var(--blue);
}

.qr-card i {
  background: var(--mint);
}

.qr-card b {
  background: var(--coral);
}

.login-panel {
  display: grid;
  gap: 20px;
  padding: 30px;
  border: 1px solid rgba(22, 25, 31, 0.1);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.9);
  box-shadow: 0 28px 80px rgba(22, 25, 31, 0.12);
  backdrop-filter: blur(18px);
}

.panel-heading h2 {
  margin: 0;
  font-size: 30px;
  line-height: 1.15;
}

.panel-heading p {
  margin: 8px 0 0;
  color: var(--muted);
  line-height: 1.5;
}

.fake-form {
  display: grid;
  gap: 14px;
}

label {
  display: grid;
  gap: 7px;
  color: #3c4350;
  font-size: 13px;
  font-weight: 700;
}

input {
  width: 100%;
  min-height: 46px;
  padding: 0 13px;
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--ink);
  background: #fff;
}

.primary-button,
.secondary-button {
  width: 100%;
  min-height: 48px;
  border: 0;
  border-radius: 8px;
  font-size: 15px;
  font-weight: 800;
  cursor: pointer;
}

.primary-button {
  color: #fff;
  background: var(--blue);
  box-shadow: 0 14px 30px rgba(20, 92, 255, 0.26);
}

.primary-button:hover {
  background: var(--blue-dark);
}

.secondary-button {
  color: var(--ink);
  background: #eef2f7;
}

.secondary-button:hover {
  background: #e3e8f0;
}

.provider-button {
  text-align: center;
}

.divider {
  position: relative;
  display: grid;
  place-items: center;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
  text-transform: uppercase;
}

.divider::before {
  position: absolute;
  inset-inline: 0;
  top: 50%;
  height: 1px;
  content: "";
  background: var(--line);
}

.divider span {
  position: relative;
  padding: 0 12px;
  background: #fff;
}

.config-list {
  display: grid;
  grid-template-columns: 104px minmax(0, 1fr);
  gap: 8px 12px;
  margin: 6px 0 0;
  padding-top: 18px;
  border-top: 1px solid var(--line);
  font-size: 12px;
}

.config-list dt {
  color: var(--muted);
  font-weight: 800;
}

.config-list dd {
  min-width: 0;
  margin: 0;
  overflow-wrap: anywhere;
  color: #303743;
}

.callback-shell {
  width: min(1040px, calc(100% - 32px));
  margin: 0 auto;
  padding: 44px 0;
}

.callback-header {
  margin-bottom: 22px;
}

.back-link {
  color: var(--blue);
  font-weight: 800;
  text-decoration: none;
}

.eyebrow {
  margin: 30px 0 6px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
  letter-spacing: 0;
  text-transform: uppercase;
}

.callback-header h1 {
  margin: 0;
  font-size: clamp(34px, 5vw, 62px);
  line-height: 1;
  letter-spacing: 0;
}

.callback-header p:last-child {
  max-width: 640px;
  color: #404754;
  line-height: 1.6;
}

.profile-card {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 24px;
  align-items: start;
  padding: 26px;
  border: 1px solid rgba(22, 25, 31, 0.1);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.92);
  box-shadow: 0 22px 64px rgba(22, 25, 31, 0.1);
}

.profile-card-empty {
  display: block;
}

.profile-card-empty h2 {
  margin: 0 0 8px;
  font-size: 24px;
}

.profile-card-empty p {
  margin: 0;
  color: var(--muted);
  line-height: 1.55;
}

.profile-avatar {
  width: 76px;
  aspect-ratio: 1;
  display: grid;
  place-items: center;
  border-radius: 8px;
  color: #fff;
  background: var(--blue);
  box-shadow: 0 12px 28px rgba(20, 92, 255, 0.2);
  font-size: 28px;
  font-weight: 900;
}

.profile-main h2 {
  margin: 0;
  font-size: clamp(26px, 4vw, 42px);
  line-height: 1.05;
}

.profile-main p {
  margin: 8px 0 0;
  color: #404754;
  font-size: 17px;
  line-height: 1.45;
  overflow-wrap: anywhere;
}

.profile-badges,
.role-strip {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.profile-badges {
  margin-top: 18px;
}

.profile-badges span,
.role-strip span {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 0 10px;
  border: 1px solid #d7deea;
  border-radius: 999px;
  color: #27303c;
  background: #f7f9fc;
  font-size: 12px;
  font-weight: 800;
}

.profile-facts {
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: 120px minmax(0, 1fr);
  gap: 10px 16px;
  margin: 6px 0 0;
  padding-top: 20px;
  border-top: 1px solid var(--line);
  font-size: 14px;
}

.profile-facts dt {
  color: var(--muted);
  font-weight: 900;
}

.profile-facts dd {
  min-width: 0;
  margin: 0;
  color: #232a35;
  overflow-wrap: anywhere;
}

.role-strip {
  grid-column: 1 / -1;
}

.payload-section {
  display: grid;
  gap: 12px;
  margin-top: 22px;
}

.payload-section summary {
  cursor: pointer;
  font-size: 18px;
  font-weight: 800;
  line-height: 1.25;
}

.payload-section h2 {
  margin: 0;
  font-size: 18px;
  line-height: 1.25;
}

.payload {
  overflow: auto;
  min-height: 360px;
  margin: 0;
  padding: 22px;
  border: 1px solid #ccd4df;
  border-radius: 8px;
  color: #e8eef8;
  background: #10151f;
  font-family: "SFMono-Regular", Consolas, "Liberation Mono", monospace;
  font-size: 13px;
  line-height: 1.55;
}

@media (max-width: 840px) {
  .login-page {
    grid-template-columns: 1fr;
    gap: 30px;
    align-content: start;
  }

  .brand-panel {
    gap: 22px;
  }

  .brand-panel h1 {
    font-size: clamp(42px, 14vw, 68px);
  }

  .login-panel {
    padding: 22px;
  }

  .profile-card {
    grid-template-columns: 1fr;
    gap: 18px;
    padding: 20px;
  }

  .profile-facts {
    grid-template-columns: 1fr;
    gap: 4px;
  }
}
