:root {
  --primary: #163e35;
  --primary-2: #0f2d26;
  --accent: #d6aa5d;
  --bg: #f5f6f3;
  --card: #ffffff;
  --text: #1f2723;
  --muted: #66726d;
  --line: #e4e8e5;
  --danger: #b42318;
  --success: #147a50;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  font-family: Arial, Helvetica, sans-serif;
  background: var(--bg);
  color: var(--text);
}

a { color: inherit; text-decoration: none; }

.site-header {
  background: var(--primary);
  color: #fff;
  padding: 22px 0;
}

.wrap {
  width: min(1080px, calc(100% - 32px));
  margin: auto;
}

.brand {
  font-weight: 800;
  letter-spacing: .02em;
}

.brand small {
  display: block;
  color: #dce7e2;
  font-weight: 400;
  margin-top: 4px;
}

.hero {
  padding: 72px 0;
  background: linear-gradient(135deg, var(--primary), var(--primary-2));
  color: #fff;
}

.hero h1 {
  font-size: clamp(34px, 7vw, 66px);
  margin: 0 0 16px;
}

.hero p {
  max-width: 650px;
  color: #dfe9e5;
  font-size: 18px;
  line-height: 1.6;
}

.button {
  display: inline-block;
  border: 0;
  border-radius: 10px;
  padding: 13px 18px;
  background: var(--accent);
  color: #1b211e;
  font-weight: 800;
  cursor: pointer;
}

.button.secondary {
  background: var(--primary);
  color: #fff;
}

.button.danger {
  background: #fff1f0;
  color: var(--danger);
}

main { padding: 34px 0 60px; }

.card {
  background: var(--card);
  border-radius: 18px;
  box-shadow: 0 12px 35px rgba(20, 45, 36, .08);
  padding: 26px;
}

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

.login-art {
  background: linear-gradient(160deg, var(--primary), var(--primary-2));
  color: white;
  display: flex;
  align-items: center;
  padding: 60px;
}

.login-art h1 {
  font-size: clamp(36px, 6vw, 64px);
  margin: 0 0 16px;
}

.login-art p {
  color: #dce7e2;
  max-width: 560px;
  line-height: 1.6;
}

.login-form-wrap {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 32px;
}

.login-card {
  width: min(430px, 100%);
}

label {
  display: block;
  font-weight: 700;
  margin-bottom: 7px;
}

input {
  width: 100%;
  border: 1px solid #cfd7d3;
  border-radius: 10px;
  padding: 13px 14px;
  font-size: 16px;
}

.field { margin-bottom: 18px; }

.alert {
  border-radius: 10px;
  padding: 13px 15px;
  margin-bottom: 18px;
}

.alert.error {
  background: #fff1f0;
  color: var(--danger);
}

.alert.success {
  background: #eaf7f0;
  color: var(--success);
}

.panel-layout {
  min-height: 100vh;
  display: grid;
  grid-template-columns: 250px 1fr;
}

.sidebar {
  background: var(--primary-2);
  color: white;
  padding: 26px 18px;
}

.sidebar .menu {
  margin-top: 34px;
  display: grid;
  gap: 8px;
}

.sidebar .menu a {
  padding: 12px 14px;
  border-radius: 9px;
  color: #dce7e2;
}

.sidebar .menu a:hover,
.sidebar .menu a.active {
  background: rgba(255,255,255,.1);
  color: white;
}

.panel-main {
  padding: 34px;
}

.panel-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 18px;
  margin-bottom: 26px;
}

.panel-top h1 { margin: 0; }

.grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
}

.stat {
  background: white;
  border-radius: 16px;
  padding: 22px;
  border: 1px solid var(--line);
}

.stat span {
  color: var(--muted);
  display: block;
  margin-bottom: 8px;
}

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

.empty-state {
  margin-top: 20px;
  text-align: center;
  padding: 50px 20px;
  border: 1px dashed #cfd7d3;
  border-radius: 16px;
  background: white;
}

.install-shell {
  width: min(760px, calc(100% - 32px));
  margin: 40px auto;
}

.install-shell h1 { margin-top: 0; }

.help {
  color: var(--muted);
  line-height: 1.6;
}

@media (max-width: 820px) {
  .login-shell,
  .panel-layout {
    grid-template-columns: 1fr;
  }

  .login-art { display: none; }
  .sidebar { min-height: auto; }
  .grid { grid-template-columns: 1fr; }
  .panel-main { padding: 24px 16px; }
}
