:root {
  font-family: Inter, Arial, sans-serif;
  color: #0f172a;
  background: #f8fafc;
  --blue: #2563eb;
  --line: #e2e8f0;
  --muted: #64748b;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-width: 320px;
  background: linear-gradient(180deg, rgba(37, 99, 235, 0.07), transparent 300px), #f8fafc;
}

button,
input {
  font: inherit;
}

button {
  cursor: pointer;
}

.login {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(340px, 430px);
  min-height: 100vh;
}

.login-left {
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 64px;
  background: linear-gradient(135deg, #0f172a, #1d4ed8);
  color: white;
}

.login-left h1 {
  max-width: 720px;
  margin: 18px 0;
  font-size: clamp(38px, 6vw, 70px);
  line-height: 1.04;
}

.login-left p {
  max-width: 620px;
  color: rgba(255, 255, 255, 0.78);
  font-size: 18px;
  line-height: 1.7;
}

.login-card {
  align-self: center;
  width: min(430px, calc(100% - 36px));
  margin: 36px auto;
  padding: 32px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: white;
  box-shadow: 0 18px 45px rgba(15, 23, 42, 0.1);
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  font-weight: 900;
}

.brand-mark {
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  border-radius: 8px;
  background: #2563eb;
  color: white;
}

.field {
  display: grid;
  gap: 8px;
  margin-top: 16px;
  font-weight: 800;
}

.field input {
  min-height: 46px;
  padding: 10px 13px;
  border: 1px solid var(--line);
  border-radius: 8px;
  outline: none;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 42px;
  padding: 10px 14px;
  border: 1px solid transparent;
  border-radius: 8px;
  background: #2563eb;
  color: white;
  font-weight: 900;
}

.btn.soft {
  border-color: #bfdbfe;
  background: #eff6ff;
  color: #1d4ed8;
}

.btn.ghost {
  border-color: rgba(255, 255, 255, 0.18);
  background: rgba(255, 255, 255, 0.08);
}

.btn.full {
  width: 100%;
  margin-top: 22px;
}

.shell {
  display: grid;
  grid-template-columns: 280px minmax(0, 1fr);
  min-height: 100vh;
}

.sidebar {
  position: sticky;
  top: 0;
  height: 100vh;
  padding: 22px;
  background: #0f172a;
  color: #e2e8f0;
}

.sidebar nav {
  display: grid;
  gap: 8px;
  margin-top: 28px;
}

.sidebar button {
  display: flex;
  align-items: center;
  min-height: 42px;
  padding: 10px 12px;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: #cbd5e1;
  font-weight: 800;
  text-align: left;
}

.sidebar button.active,
.sidebar button:hover {
  background: rgba(37, 99, 235, 0.24);
  color: white;
}

.sidebar-foot {
  position: absolute;
  right: 22px;
  bottom: 22px;
  left: 22px;
}

.main {
  min-width: 0;
}

.topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 72px;
  padding: 14px 28px;
  border-bottom: 1px solid var(--line);
  background: rgba(248, 250, 252, 0.9);
  backdrop-filter: blur(14px);
}

.avatar {
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: #dbeafe;
  color: #1d4ed8;
  font-weight: 900;
}

.content {
  display: grid;
  gap: 22px;
  width: min(1480px, 100%);
  margin: 0 auto;
  padding: 28px;
}

.hero {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 24px;
  min-height: 210px;
  padding: 32px;
  border-radius: 8px;
  background: linear-gradient(135deg, #0f172a, #1d4ed8);
  color: white;
}

.hero p {
  max-width: 760px;
  color: rgba(255, 255, 255, 0.76);
}

h1,
h2,
h3,
p {
  margin-top: 0;
}

h1 {
  margin-bottom: 10px;
  font-size: clamp(30px, 4vw, 44px);
}

p {
  color: var(--muted);
  line-height: 1.62;
}

.eyebrow {
  color: #2563eb;
  font-size: 12px;
  font-weight: 900;
  text-transform: uppercase;
}

.hero .eyebrow {
  color: #bfdbfe;
}

.grid {
  display: grid;
  gap: 16px;
}

.stats {
  grid-template-columns: repeat(5, minmax(170px, 1fr));
}

.two {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.three {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.panel,
.stat,
.reward {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: white;
  box-shadow: 0 12px 28px rgba(15, 23, 42, 0.04);
}

.panel {
  padding: 22px;
}

.stat {
  display: grid;
  gap: 8px;
  min-height: 122px;
  padding: 18px;
}

.stat span,
.muted {
  color: var(--muted);
}

.stat strong {
  font-size: 30px;
}

.progress {
  display: grid;
  gap: 7px;
}

.progress div {
  overflow: hidden;
  height: 10px;
  border-radius: 999px;
  background: #e2e8f0;
}

.progress b {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: #2563eb;
}

.badge {
  display: inline-flex;
  width: fit-content;
  padding: 5px 9px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 900;
}

.blue {
  background: #dbeafe;
  color: #1d4ed8;
}

.green {
  background: #dcfce7;
  color: #166534;
}

.yellow {
  background: #fef3c7;
  color: #92400e;
}

.red {
  background: #fee2e2;
  color: #991b1b;
}

.purple {
  background: #ede9fe;
  color: #5b21b6;
}

table {
  width: 100%;
  min-width: 900px;
  border-collapse: collapse;
}

.table-wrap {
  overflow-x: auto;
}

th,
td {
  padding: 14px 10px;
  border-bottom: 1px solid #edf2f7;
  text-align: left;
  vertical-align: top;
}

th {
  color: var(--muted);
  font-size: 12px;
  text-transform: uppercase;
}

td small {
  display: block;
  margin-top: 5px;
  color: var(--muted);
}

.reward-grid {
  grid-template-columns: repeat(4, minmax(190px, 1fr));
}

.reward {
  display: grid;
  gap: 12px;
  padding: 18px;
}

.assistant {
  display: grid;
  gap: 14px;
}

.chat {
  min-height: 240px;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #f8fafc;
}

.chat p {
  width: fit-content;
  max-width: 780px;
  margin: 0 0 10px;
  padding: 12px 14px;
  border-radius: 8px;
  background: #dbeafe;
  color: #0f172a;
}

.chat-form {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
}

@media (max-width: 1050px) {
  .stats,
  .three,
  .reward-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 840px) {
  .login,
  .shell,
  .two,
  .stats,
  .three,
  .reward-grid {
    grid-template-columns: 1fr;
  }

  .login-left {
    padding: 34px 24px;
  }

  .sidebar {
    position: relative;
    height: auto;
  }

  .sidebar-foot {
    position: static;
    margin-top: 24px;
  }

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

