﻿:root {
  --bg: #f4f7fb;
  --panel: #ffffff;
  --ink: #1f2937;
  --muted: #6b7280;
  --brand: #0f766e;
  --brand-2: #0891b2;
  --danger: #b91c1c;
  --warn: #a16207;
  --ok: #166534;
  --line: #e5e7eb;
  --shadow: 0 18px 45px rgba(15, 23, 42, 0.08);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: "Plus Jakarta Sans", "Segoe UI", sans-serif;
  color: var(--ink);
  background:
    radial-gradient(80rem 60rem at -15% -20%, #dbeafe 0%, transparent 55%),
    radial-gradient(60rem 60rem at 115% 15%, #cffafe 0%, transparent 50%),
    var(--bg);
}

a {
  color: inherit;
}

.container {
  width: min(1120px, calc(100% - 2rem));
  margin: 0 auto;
  padding: 1rem 0 2.5rem;
}

.nav {
  margin-top: 1rem;
  background: rgba(255, 255, 255, 0.9);
  border: 1px solid rgba(229, 231, 235, 0.9);
  border-radius: 18px;
  padding: 0.8rem 1rem;
  box-shadow: var(--shadow);
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  backdrop-filter: blur(8px);
}

.brand {
  font-weight: 700;
  letter-spacing: 0.2px;
}

.badge {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  border-radius: 999px;
  padding: 0.22rem 0.65rem;
  font-size: 0.76rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.3px;
}

.badge.ok { background: #dcfce7; color: var(--ok); }
.badge.warn { background: #fef3c7; color: var(--warn); }
.badge.danger { background: #fee2e2; color: var(--danger); }
.badge.info { background: #cffafe; color: #155e75; }

.grid {
  display: grid;
  gap: 1rem;
}

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

.card {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 20px;
  box-shadow: var(--shadow);
  padding: 1rem;
}

.card h2,
.card h3 {
  margin: 0;
}

.card-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  margin-bottom: 0.9rem;
}

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

table {
  border-collapse: collapse;
  width: 100%;
  font-size: 0.92rem;
}

th,
td {
  text-align: left;
  border-bottom: 1px solid var(--line);
  padding: 0.7rem 0.55rem;
  vertical-align: top;
}

th {
  font-size: 0.78rem;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.3px;
}

.hero {
  margin-top: 1rem;
  padding: 1.6rem;
  border-radius: 22px;
  background: linear-gradient(120deg, rgba(8,145,178,0.9), rgba(15,118,110,0.95));
  color: #ecfeff;
  box-shadow: var(--shadow);
}

.hero h1 {
  margin: 0 0 0.4rem;
  font-size: clamp(1.4rem, 2.1vw, 2rem);
}

.muted {
  color: var(--muted);
}

.row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
}

input,
select,
button,
textarea {
  font: inherit;
}

.input {
  width: 100%;
  border: 1px solid #cbd5e1;
  border-radius: 12px;
  background: #fff;
  padding: 0.68rem 0.78rem;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.input:focus {
  outline: none;
  border-color: var(--brand-2);
  box-shadow: 0 0 0 4px rgba(8, 145, 178, 0.14);
}

.form-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.75rem;
}

.btn {
  border: 0;
  border-radius: 12px;
  padding: 0.62rem 0.95rem;
  font-weight: 700;
  cursor: pointer;
  transition: transform 0.1s ease, filter 0.2s ease;
}

.btn:hover {
  filter: brightness(0.98);
}

.btn:active {
  transform: translateY(1px);
}

.btn.primary {
  background: linear-gradient(90deg, var(--brand), var(--brand-2));
  color: #fff;
}

.btn.light {
  background: #ecfeff;
  color: #155e75;
  border: 1px solid #bae6fd;
}

.btn.danger {
  background: #fee2e2;
  color: #991b1b;
  border: 1px solid #fecaca;
}

.auth-wrap {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 1rem;
}

.auth-card {
  width: min(440px, 100%);
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 20px;
  box-shadow: var(--shadow);
  padding: 1.35rem;
}

.flash {
  padding: 0.75rem 0.9rem;
  border-radius: 12px;
  font-size: 0.92rem;
  margin-bottom: 0.8rem;
}

.flash.success {
  background: #dcfce7;
  color: #14532d;
}

.flash.error {
  background: #fee2e2;
  color: #7f1d1d;
}

.stats {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0.75rem;
}

.stat {
  border: 1px solid var(--line);
  border-radius: 14px;
  background: #fff;
  padding: 0.7rem;
}

.stat small {
  display: block;
  color: var(--muted);
  text-transform: uppercase;
  font-size: 0.7rem;
  margin-bottom: 0.28rem;
}

.stat strong {
  font-size: 1.1rem;
}

@media (max-width: 980px) {
  .grid.cols-3,
  .form-grid,
  .stats {
    grid-template-columns: 1fr;
  }

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