:root {
  --bg: #f4f7f6;
  --surface: #fff;
  --ink: #17211f;
  --muted: #64736f;
  --line: #d8e1de;
  --primary: #0f766e;
  --blue: #2563eb;
  --red: #b42318;
  --red-bg: #fee4e2;
  --green-bg: #e3f7eb;
  --amber-bg: #fff7df;
  --shadow: 0 16px 40px rgba(23, 33, 31, .10);
}

* { box-sizing: border-box; }
body {
  margin: 0;
  min-height: 100vh;
  background: var(--bg);
  color: var(--ink);
  font-family: Arial, Helvetica, sans-serif;
}
button, input, select, textarea { font: inherit; }
button {
  border: 0;
  border-radius: 8px;
  cursor: pointer;
  font-weight: 800;
}
button:disabled { opacity: .55; cursor: not-allowed; }
input, select, textarea {
  width: 100%;
  min-height: 46px;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 10px 12px;
  background: #fff;
}
label {
  display: grid;
  gap: 7px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
}
h1, h2, p { margin: 0; }
h1 { font-size: clamp(25px, 5vw, 42px); line-height: 1.05; }
h2 { font-size: 20px; }
.shell {
  width: min(1180px, 100%);
  margin: 0 auto;
  padding: 18px 14px 28px;
}
.topbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  margin-bottom: 14px;
}
.kicker {
  color: var(--primary);
  font-size: 12px;
  font-weight: 900;
  text-transform: uppercase;
}
.grid { display: grid; grid-template-columns: minmax(0, 1fr) 380px; gap: 16px; }
.panel, .card {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  box-shadow: var(--shadow);
  padding: 18px;
}
.clock {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 16px;
  padding: 16px;
  border-radius: 8px;
  background: #eef6f4;
}
.clock strong { color: #0b5f59; font-size: clamp(34px, 10vw, 64px); line-height: .95; }
.form-grid { display: grid; grid-template-columns: 1fr 180px; gap: 12px; }
.status {
  margin: 14px 0;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fbfdfc;
  color: #0b5f59;
  font-weight: 900;
  text-align: center;
}
.actions { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin-bottom: 14px; }
.big-action {
  display: grid;
  min-height: 150px;
  padding: 18px;
  color: #fff;
  text-align: left;
}
.big-action span { align-self: start; font-size: clamp(30px, 9vw, 56px); line-height: 1; }
.big-action strong { align-self: end; }
.in { background: var(--primary); }
.out { background: var(--blue); }
.section-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  margin-bottom: 12px;
}
.button-row { display: flex; flex-wrap: wrap; gap: 8px; }
.quiet, .solid, .danger, .small {
  min-height: 40px;
  padding: 0 14px;
}
.quiet, .small { background: #e6eeeb; color: var(--ink); }
.solid { background: var(--primary); color: #fff; }
.danger { background: var(--red-bg); color: var(--red); }
.metrics { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; margin-bottom: 16px; }
.metric {
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fbfdfc;
}
.metric span { display: block; color: var(--muted); font-size: 12px; font-weight: 900; }
.metric strong { color: #0b5f59; font-size: 28px; }
.list { display: grid; gap: 10px; }
.item {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}
.item-main { display: grid; gap: 4px; }
.item span { color: var(--muted); font-size: 13px; }
.badge {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 0 10px;
  border-radius: 999px;
  background: #e6eeeb;
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
}
.badge.Pendiente { background: var(--amber-bg); color: #98690f; }
.badge.Aprobado { background: var(--green-bg); color: #0b5f59; }
.badge.Abierto { background: #e8f0ff; color: var(--blue); }
.employee-grid { display: grid; grid-template-columns: 1.4fr 1fr 90px 90px; gap: 8px; align-items: center; }
.filters { display: grid; grid-template-columns: 160px 160px 1fr; gap: 10px; margin-bottom: 14px; }
.toast {
  position: fixed;
  left: 50%;
  bottom: 18px;
  transform: translate(-50%, 16px);
  min-width: min(420px, calc(100vw - 32px));
  padding: 13px 16px;
  border-radius: 8px;
  background: var(--ink);
  color: #fff;
  font-weight: 800;
  text-align: center;
  opacity: 0;
  pointer-events: none;
  transition: 160ms ease;
}
.toast.show { opacity: 1; transform: translate(-50%, 0); }
@media (max-width: 800px) {
  .grid, .form-grid, .actions, .metrics, .filters, .employee-grid { grid-template-columns: 1fr; }
  .item { flex-direction: column; }
  .big-action { min-height: 118px; }
}
