:root {
  color-scheme: light;
  font-family: Arial, "PingFang SC", "Microsoft YaHei", sans-serif;
  color: #18212f;
  background: #f4f6f8;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
}

button,
.button {
  min-height: 40px;
  border: 0;
  border-radius: 8px;
  background: #1f7a4d;
  color: #ffffff;
  font: inherit;
  font-weight: 700;
  cursor: pointer;
  padding: 0 16px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
}

button:disabled {
  cursor: wait;
  opacity: 0.7;
}

input {
  width: 100%;
  min-height: 40px;
  border: 1px solid #cfd8e3;
  border-radius: 8px;
  padding: 8px 10px;
  font: inherit;
  background: #ffffff;
}

label {
  display: grid;
  gap: 7px;
  color: #52606d;
  font-size: 14px;
}

code {
  background: #edf2f7;
  border-radius: 6px;
  padding: 2px 5px;
}

.app-shell {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 28px 0 48px;
}

.topbar {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 22px;
}

.topbar-actions {
  display: flex;
  gap: 10px;
  align-items: center;
  flex-wrap: wrap;
  justify-content: flex-end;
}

h1,
h2,
p {
  margin-top: 0;
}

h1 {
  margin-bottom: 6px;
  font-size: clamp(28px, 4vw, 42px);
}

h2 {
  margin-bottom: 6px;
  font-size: 20px;
}

p {
  color: #637083;
  line-height: 1.55;
}

.panel,
.checkin-card {
  background: #ffffff;
  border: 1px solid #dde5ee;
  border-radius: 8px;
  box-shadow: 0 16px 40px rgba(24, 33, 47, 0.08);
}

.panel {
  padding: 22px;
  margin-bottom: 22px;
}

.narrow {
  max-width: 560px;
}

.dashboard {
  display: grid;
  gap: 22px;
}

.section-title {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 18px;
}

.actions,
.mini-actions,
.filter-row,
.form-row,
.grid-form {
  display: flex;
  gap: 10px;
  align-items: end;
  flex-wrap: wrap;
}

.grid-form {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  margin-bottom: 18px;
}

.filter-row {
  margin-bottom: 16px;
}

.form-row label,
.filter-row label,
.grid-form label {
  flex: 1 1 180px;
}

.secondary {
  background: #22577a;
}

.ghost {
  background: #eef2f6;
  color: #243447;
}

.danger {
  background: #b42318;
  color: #ffffff;
}

.hidden {
  display: none !important;
}

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

.employee-card {
  display: grid;
  grid-template-columns: 1fr 110px;
  gap: 14px;
  border: 1px solid #dde5ee;
  border-radius: 8px;
  padding: 14px;
  align-items: center;
}

.employee-card img {
  width: 110px;
  height: 110px;
}

.employee-name {
  font-size: 18px;
  font-weight: 800;
}

.link {
  color: #146c94;
  word-break: break-all;
}

.hint {
  color: #748194;
  font-size: 13px;
}

.mini-actions {
  margin-top: 12px;
}

.mini-actions button {
  min-height: 34px;
  padding: 0 10px;
  font-size: 13px;
}

.table-wrap {
  overflow-x: auto;
  border: 1px solid #dde5ee;
  border-radius: 8px;
}

table {
  width: 100%;
  border-collapse: collapse;
  min-width: 900px;
}

th,
td {
  border-bottom: 1px solid #edf1f5;
  padding: 12px;
  text-align: left;
  vertical-align: top;
}

th {
  background: #f8fafc;
  color: #52606d;
  font-size: 13px;
}

.empty {
  text-align: center;
  color: #748194;
}

.message {
  margin-top: 14px;
  border-radius: 8px;
  padding: 12px 14px;
  background: #edf2f7;
  color: #2f4358;
}

.message.info {
  background: #eef4ff;
  color: #1d4e89;
}

.message.success {
  background: #e9f7ef;
  color: #1f7a4d;
}

.message.error {
  background: #fdeeee;
  color: #a33434;
}

.center-page {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 24px;
}

.floating-lang {
  position: fixed;
  top: 18px;
  right: 18px;
  z-index: 10;
}

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

.badge {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 0 10px;
  border-radius: 8px;
  background: #eef4ff;
  color: #1d4e89;
  font-weight: 800;
  margin-bottom: 14px;
}

.checkin-card button {
  width: 100%;
  margin-top: 8px;
}

@media (max-width: 760px) {
  .topbar,
  .section-title {
    display: grid;
  }

  .grid-form {
    grid-template-columns: 1fr;
  }

  .employee-card {
    grid-template-columns: 1fr;
  }
}
