/* Astro Admin – minimal but warm */
:root {
  --bg: #faf8f5;
  --fg: #1f1d2e;
  --muted: #6b6478;
  --accent: #6e3ec0;
  --accent-2: #d4a44b;
  --card: #ffffff;
  --border: #ece6dc;
  --danger: #c44848;
  --success: #2f8f3d;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", sans-serif;
  background: var(--bg);
  color: var(--fg);
  font-size: 15px;
  line-height: 1.55;
}

a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }

.navbar {
  background: linear-gradient(135deg, #2d1b4e 0%, #6e3ec0 100%);
  color: white;
  padding: 12px 24px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  box-shadow: 0 2px 8px rgba(0,0,0,0.08);
}

.nav-brand { font-size: 18px; font-weight: 600; }
.nav-links { display: flex; gap: 6px; flex-wrap: wrap; }
.nav-links a {
  color: white;
  padding: 6px 12px;
  border-radius: 6px;
  font-size: 14px;
}
.nav-links a:hover {
  background: rgba(255,255,255,0.15);
  text-decoration: none;
}
.nav-links a.logout { background: rgba(255,255,255,0.1); }

.container {
  max-width: 1100px;
  margin: 0 auto;
  padding: 28px 24px;
}

h1, h2, h3 { margin-top: 0; color: var(--fg); }
h1 { font-size: 26px; font-weight: 700; }
h2 { font-size: 20px; font-weight: 600; margin-bottom: 14px; }

.card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 22px;
  margin-bottom: 18px;
  box-shadow: 0 1px 3px rgba(0,0,0,0.03);
}

.stat-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 14px;
}

.stat {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 18px;
}
.stat-label { color: var(--muted); font-size: 13px; text-transform: uppercase; letter-spacing: 0.5px; }
.stat-value { font-size: 28px; font-weight: 700; color: var(--accent); margin-top: 4px; }
.stat-value.gold { color: var(--accent-2); }

table { width: 100%; border-collapse: collapse; }
th, td { text-align: left; padding: 10px 12px; border-bottom: 1px solid var(--border); font-size: 14px; }
th { background: #f5f2ed; color: var(--muted); font-weight: 600; text-transform: uppercase; font-size: 12px; letter-spacing: 0.4px; }
tr:hover td { background: #fbf9f4; }

input[type=text], input[type=password], input[type=number], select, textarea {
  width: 100%;
  padding: 10px 12px;
  border: 1px solid var(--border);
  border-radius: 8px;
  font-size: 14px;
  background: white;
  color: var(--fg);
}
input:focus, textarea:focus, select:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(110, 62, 192, 0.12);
}

.btn {
  display: inline-block;
  background: var(--accent);
  color: white;
  border: none;
  border-radius: 8px;
  padding: 10px 18px;
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  transition: background 0.15s;
}
.btn:hover { background: #5a30a0; text-decoration: none; }
.btn-secondary { background: #e9e4dc; color: var(--fg); }
.btn-secondary:hover { background: #ddd6c9; }
.btn-danger { background: var(--danger); }
.btn-danger:hover { background: #a73838; }

.alert {
  padding: 12px 16px;
  border-radius: 8px;
  margin-bottom: 16px;
  font-size: 14px;
}
.alert-success { background: #e8f5e8; color: var(--success); border: 1px solid #b8dab8; }
.alert-error { background: #fbe7e7; color: var(--danger); border: 1px solid #efbcbc; }

.login-wrap {
  max-width: 380px;
  margin: 80px auto;
  text-align: center;
}
.login-wrap h1 { font-size: 32px; margin-bottom: 8px; }
.login-wrap .subtitle { color: var(--muted); margin-bottom: 28px; }

.muted { color: var(--muted); }
.secret-mask { font-family: monospace; background: #f3f0eb; padding: 2px 6px; border-radius: 4px; }
.field-row { display: flex; gap: 10px; align-items: stretch; margin-bottom: 8px; }
.field-row label { flex: 0 0 200px; font-weight: 500; padding-top: 10px; }
.field-row .value { flex: 1; padding-top: 10px; }
.field-row form { flex: 1; display: flex; gap: 6px; }
.field-row form input { flex: 1; }
.field-row form .btn { padding: 8px 14px; font-size: 13px; }
