:root {
  --bg: #f8fafc;
  --panel: #ffffff;
  --panel-2: #f1f5f9;
  --text: #0f172a;
  --muted: #64748b;
  --line: #e2e8f0;
  --brand: #2563eb;
  --brand-2: #16a34a;
  --danger: #dc2626;
  --warning: #d97706;
  --dark: #0f172a;
  --sidebar: #0b1220;
  --sidebar-2: #111827;
  --shadow: 0 12px 40px rgba(15,23,42,.08);
  --radius: 16px;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Arial, sans-serif;
  background: var(--bg);
  color: var(--text);
}

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

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

button {
  border: 0;
  cursor: pointer;
}

.landing {
  min-height: 100vh;
  background:
    radial-gradient(circle at 20% 10%, rgba(37,99,235,.16), transparent 32%),
    radial-gradient(circle at 90% 20%, rgba(22,163,74,.14), transparent 30%),
    #f8fafc;
}

.landing-nav {
  max-width: 1180px;
  margin: 0 auto;
  padding: 22px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.logo {
  display: flex;
  gap: 10px;
  align-items: center;
  font-weight: 900;
  letter-spacing: -.04em;
  font-size: 22px;
}

.logo-mark {
  width: 34px;
  height: 34px;
  border-radius: 12px;
  background: linear-gradient(135deg, var(--brand), var(--brand-2));
  display: grid;
  place-items: center;
  color: white;
  font-weight: 900;
}

.landing-actions {
  display: flex;
  gap: 10px;
  align-items: center;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 42px;
  padding: 0 16px;
  border-radius: 12px;
  font-weight: 800;
  background: var(--brand);
  color: white;
  box-shadow: 0 10px 24px rgba(37,99,235,.22);
}

.btn.secondary {
  background: white;
  color: var(--text);
  border: 1px solid var(--line);
  box-shadow: none;
}

.btn.green { background: var(--brand-2); }
.btn.danger { background: var(--danger); }
.btn.ghost { background: transparent; color: var(--muted); box-shadow: none; }

.hero {
  max-width: 1180px;
  margin: 0 auto;
  padding: 70px 22px 40px;
  display: grid;
  grid-template-columns: 1.05fr .95fr;
  gap: 40px;
  align-items: center;
}

.hero h1 {
  font-size: clamp(42px, 6vw, 76px);
  line-height: .94;
  letter-spacing: -.07em;
  margin: 0 0 22px;
}

.hero p {
  color: var(--muted);
  font-size: 19px;
  line-height: 1.7;
  max-width: 640px;
}

.hero-card {
  background: rgba(255,255,255,.78);
  border: 1px solid var(--line);
  border-radius: 28px;
  padding: 22px;
  box-shadow: var(--shadow);
  backdrop-filter: blur(16px);
}

.metric-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0,1fr));
  gap: 14px;
}

.metric-preview {
  background: white;
  border: 1px solid var(--line);
  border-radius: 18px;
  padding: 18px;
}

.metric-preview strong {
  display: block;
  font-size: 30px;
  letter-spacing: -.04em;
}

.metric-preview span { color: var(--muted); font-size: 13px; }

.features {
  max-width: 1180px;
  margin: 0 auto;
  padding: 35px 22px 80px;
  display: grid;
  grid-template-columns: repeat(3, minmax(0,1fr));
  gap: 16px;
}

.feature {
  background: white;
  border: 1px solid var(--line);
  border-radius: 22px;
  padding: 22px;
  box-shadow: 0 8px 22px rgba(15,23,42,.04);
}

.feature h3 { margin: 0 0 8px; }
.feature p { color: var(--muted); line-height: 1.6; margin: 0; }

.login-page {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 22px;
  background:
    radial-gradient(circle at 15% 15%, rgba(37,99,235,.14), transparent 30%),
    radial-gradient(circle at 90% 80%, rgba(22,163,74,.14), transparent 30%),
    #f8fafc;
}

.login-card {
  width: 100%;
  max-width: 430px;
  background: white;
  border: 1px solid var(--line);
  border-radius: 26px;
  padding: 28px;
  box-shadow: var(--shadow);
}

.login-card h1 {
  margin: 22px 0 8px;
  letter-spacing: -.05em;
}

.form-group { margin: 16px 0; }
.form-group label { display: block; font-weight: 800; margin-bottom: 8px; }

.input {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 13px 14px;
  outline: none;
  background: white;
}

.input:focus {
  border-color: var(--brand);
  box-shadow: 0 0 0 4px rgba(37,99,235,.1);
}

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

.sidebar {
  background: var(--sidebar);
  color: #cbd5e1;
  padding: 20px 16px;
  position: sticky;
  top: 0;
  height: 100vh;
  overflow-y: auto;
}

.sidebar .logo {
  color: white;
  padding: 4px 8px 20px;
}

.nav-section {
  margin: 18px 0;
}

.nav-title {
  color: #64748b;
  font-size: 11px;
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: .12em;
  padding: 0 10px 8px;
}

.nav-link {
  display: flex;
  align-items: center;
  gap: 10px;
  color: #cbd5e1;
  padding: 11px 12px;
  border-radius: 12px;
  margin: 3px 0;
  font-weight: 700;
}

.nav-link:hover, .nav-link.active {
  background: rgba(255,255,255,.08);
  color: white;
}

.app-main {
  min-width: 0;
}

.topbar {
  height: 72px;
  background: rgba(255,255,255,.86);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(14px);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 28px;
  position: sticky;
  top: 0;
  z-index: 5;
}

.page-title h1 {
  margin: 0;
  font-size: 24px;
  letter-spacing: -.04em;
}

.page-title p {
  margin: 4px 0 0;
  color: var(--muted);
  font-size: 13px;
}

.profile {
  display: flex;
  align-items: center;
  gap: 12px;
  background: white;
  border: 1px solid var(--line);
  padding: 8px 12px;
  border-radius: 999px;
  box-shadow: 0 4px 16px rgba(15,23,42,.05);
}

.avatar {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  color: white;
  background: linear-gradient(135deg, var(--brand), var(--brand-2));
  font-weight: 900;
}

.content {
  padding: 28px;
  max-width: 1500px;
}

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

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

.card {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 20px;
  box-shadow: 0 8px 22px rgba(15,23,42,.04);
}

.card h2, .card h3 { margin-top: 0; letter-spacing: -.03em; }

.stat {
  min-height: 126px;
}

.stat-label {
  color: var(--muted);
  font-weight: 800;
  font-size: 13px;
}

.stat-value {
  font-size: 36px;
  font-weight: 950;
  letter-spacing: -.06em;
  margin-top: 12px;
}

.stat-sub {
  color: var(--muted);
  margin-top: 6px;
  font-size: 13px;
}

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

table {
  width: 100%;
  border-collapse: collapse;
}

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

th {
  color: var(--muted);
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: .08em;
}

.badge {
  display: inline-flex;
  align-items: center;
  padding: 5px 9px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 900;
  background: var(--panel-2);
  color: var(--muted);
}

.badge.good { background: #dcfce7; color: #166534; }
.badge.bad { background: #fee2e2; color: #991b1b; }
.badge.warn { background: #fef3c7; color: #92400e; }
.badge.blue { background: #dbeafe; color: #1e40af; }

.actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

pre {
  background: #020617;
  color: #e2e8f0;
  padding: 16px;
  border-radius: 14px;
  overflow: auto;
  max-height: 500px;
  white-space: pre-wrap;
  word-break: break-word;
}

.empty {
  color: var(--muted);
  padding: 18px;
  background: var(--panel-2);
  border-radius: 12px;
}

.toast {
  position: fixed;
  right: 24px;
  bottom: 24px;
  background: #0f172a;
  color: white;
  padding: 14px 16px;
  border-radius: 14px;
  box-shadow: var(--shadow);
  z-index: 20;
  max-width: 420px;
}

@media (max-width: 980px) {
  .hero, .features { grid-template-columns: 1fr; }
  .app-shell { grid-template-columns: 1fr; }
  .sidebar { position: relative; height: auto; }
  .grid.cols-2, .grid.cols-3, .grid.cols-4 { grid-template-columns: 1fr; }
  .topbar { position: relative; height: auto; gap: 12px; align-items: flex-start; flex-direction: column; padding: 18px; }
  .content { padding: 18px; }
}

/* DROPESTER_REDESIGN_R6_DASHBOARD_COMMAND_CENTER */
.quick-card {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: var(--panel);
}

.quick-card strong {
  display: block;
  margin-bottom: 6px;
}

.quick-card p {
  color: var(--muted);
  margin: 0;
  line-height: 1.5;
  font-size: 13px;
}

.task {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  padding: 14px 0;
  border-bottom: 1px solid var(--line);
}

.task:last-child {
  border-bottom: 0;
}

.task-title {
  font-weight: 900;
}

.task-sub {
  color: var(--muted);
  font-size: 13px;
  margin-top: 3px;
}

.progress {
  height: 10px;
  background: var(--panel-2);
  border-radius: 999px;
  overflow: hidden;
}

.progress span {
  display: block;
  height: 100%;
  background: linear-gradient(90deg, var(--brand), var(--brand-2));
  border-radius: 999px;
}

.kpi-note {
  color: var(--muted);
  font-size: 12px;
  margin-top: 6px;
}

/* DROPESTER_REDESIGN_R7_ROUTING_POLISH */
.profile .btn {
  min-height: 34px;
  padding: 0 10px;
  font-size: 13px;
}

.system-pill {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 7px 10px;
  border-radius: 999px;
  background: #dcfce7;
  color: #166534;
  font-size: 12px;
  font-weight: 900;
  border: 1px solid #bbf7d0;
}

.system-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #22c55e;
}

.redirect-page {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 24px;
  background:
    radial-gradient(circle at 20% 20%, rgba(37,99,235,.12), transparent 30%),
    radial-gradient(circle at 80% 70%, rgba(22,163,74,.12), transparent 30%),
    #f8fafc;
}

.redirect-card {
  width: 100%;
  max-width: 520px;
  background: white;
  border: 1px solid var(--line);
  border-radius: 24px;
  padding: 28px;
  box-shadow: var(--shadow);
  text-align: center;
}

.redirect-card h1 {
  margin: 16px 0 8px;
  letter-spacing: -.04em;
}

.redirect-card p {
  color: var(--muted);
  line-height: 1.6;
}
