* {
  box-sizing: border-box;
  font-family: system-ui, sans-serif;
}

body {
  margin: 0;
  background: #f1f5f9;
}

.container {
  max-width: 420px;
  margin: auto;
  padding: 1.5rem;
}

h1 {
  text-align: center;
  margin-bottom: 1.5rem;
}

label {
  display: block;
  margin-bottom: 1rem;
  font-size: 0.9rem;
}

input {
  width: 100%;
  padding: 0.6rem;
  margin-top: 0.3rem;
  border-radius: 6px;
  border: 1px solid #cbd5e1;
}

button {
  width: 100%;
  padding: 0.75rem;
  margin-top: 1rem;
  background: #2563eb;
  color: white;
  border: none;
  border-radius: 6px;
  font-size: 1rem;
}

button:hover {
  background: #173f95;
}

select {
  width: 100%;
  padding: 0.6rem;
  margin-top: 0.3rem;
  border-radius: 6px;
  border: 1px solid #cbd5e1;
}

.card {
  background: #ffffff;
  border-radius: 8px;
  padding: 1rem;
  margin-bottom: 1rem;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.08);
}

.visit-row {
  display: flex;
  justify-content: space-between;
  padding: 0.3rem 0;
  font-size: 0.9rem;
}

.visit-row .label {
  font-weight: 600;
  color: #475569;
}

.table-section {
  margin-top: 20px;
  overflow-x: auto;
}

table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13px;
}

th,
td {
  padding: 8px;
  border: 1px solid #ddd;
  text-align: center;
}

thead {
  background: #f2f2f2;
}

tr.duplicate {
  background-color: #ffe0e0;
}

tr.similar {
  background-color: #fff7cc;
}

td.action {
  display: flex;
  align-items: center;
  justify-content: center;
}

.visit-header {
  background: #eef;
  padding: 10px;
  border-radius: 6px;
  font-size: 14px;
  margin-bottom: 12px;
}

.btn-export {
  width: 100%;
  margin-top: 15px;
  padding: 12px;
  font-size: 14px;
  background: #2e7d32;
  color: white;
  border: none;
  border-radius: 6px;
}

.btn-export:hover {
  background: #1e5421
}

/* Icon-only small buttons used in table actions */
.icon-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 30px;
  height: 30px;
  padding: 0;
  border-radius: 6px;
  border: none;
  cursor: pointer;
  margin-left: 6px;
}

.icon-btn svg {
  width: 16px;
  height: 16px;
  display: block;
}

.btn-edit {
  margin-top: 0;
  background: #ffb032; /* light yellow */
  color: #653f01;
}
.btn-edit:hover {
  background: #ed9a15;
}
.btn-edit svg { fill: #653f01; }

.btn-delete {
  margin-top: 0;
  background: #fa4c4c; /* light red */
  color: #6f0311;
}
.btn-delete:hover {
  background: #e14848;
}
.btn-delete svg { fill: #8b1f2d; }