:root {
  --primary: #6EBFD1;
  --primary-dark: #5AA6B7;
  --bg: #f5f7f6;
  --card-bg: #ffffff;
  --border: #dfe5e2;
  --text: #263229;
  --muted: #6b7a71;
  --error: #c0392b;
  --success: #2f7a5f;
  --info: #2b6ea3;
}

* { box-sizing: border-box; }

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

body {
  margin: 0;
  font-family: 'Fira Sans', sans-serif;
  background-color: var(--bg);
  background-image: url('images/background.png');
  background-repeat: repeat;
  background-size: 750px 1500px;
  color: var(--text);
}

.topbar {
  background: var(--primary);
  padding: 16px 24px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  color: white;
  font-family: 'McLaren', cursive;
  font-size: 1.25rem;
  font-weight: 700;
  text-decoration: none;
}

.brand-logo {
  height: 40px;
  width: auto;
  border-radius: 4px;
}

.container {
  max-width: 640px;
  margin: 0 auto;
  padding: 32px 20px 60px;
}

h1 { font-family: 'McLaren', cursive; font-size: 1.6rem; margin-bottom: 4px; }
h2 { font-family: 'McLaren', cursive; font-size: 1.2rem; margin-top: 32px; }
p.subtitle { color: var(--muted); margin-top: 0; }

p.note {
  font-size: 0.8rem;
  color: #9aa79f;
  font-style: italic;
  margin-top: 4px;
  margin-bottom: 20px;
}

p.slotinfo {
  font-size: 0.8rem;
  color: #9aa79f;
  font-style: italic;
  margin-top: 4px;
  margin-bottom: 4px;
}

.admin-tabs {
  display: flex;
  gap: 6px;
  border-bottom: 1px solid var(--border);
  margin-bottom: 20px;
}

.admin-tab {
  padding: 10px 16px;
  color: var(--muted);
  text-decoration: none;
  font-weight: 600;
  font-size: 0.95rem;
  border-bottom: 2px solid transparent;
  margin-bottom: -1px;
}

.admin-tab:hover { color: var(--text); }

.admin-tab.active {
  color: var(--primary-dark);
  border-bottom-color: var(--primary);
}

.card {
  background: var(--card-bg);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 24px;
  margin-bottom: 20px;
}

label {
  display: block;
  font-weight: 600;
  font-size: 0.9rem;
  margin-bottom: 6px;
  margin-top: 14px;
}

label:first-child { margin-top: 0; }

input[type="text"],
input[type="email"],
input[type="tel"],
input[type="number"],
input[type="date"],
select,
textarea {
  width: 100%;
  padding: 10px 12px;
  border: 1px solid var(--border);
  border-radius: 8px;
  font-size: 1rem;
  background: white;
  font-family: inherit;
}

input:focus, select:focus, textarea:focus {
  outline: none;
  border-color: var(--primary);
}

.btn {
  display: inline-block;
  background: var(--primary);
  color: white;
  border: none;
  padding: 11px 20px;
  border-radius: 8px;
  font-size: 0.95rem;
  font-weight: 600;
  cursor: pointer;
  text-decoration: none;
  margin-top: 18px;
}

.btn:hover { background: var(--primary-dark); }

.btn-secondary {
  background: white;
  color: var(--primary);
  border: 1px solid var(--primary);
}

.btn-secondary:hover { background: #eef6f2; }

.btn-danger {
  background: white;
  color: var(--error);
  border: 1px solid var(--error);
  padding: 6px 12px;
  font-size: 0.85rem;
  margin-top: 0;
}

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

.divider {
  text-align: center;
  color: var(--muted);
  margin: 22px 0;
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.pet-list, .slot-list, .signup-list { list-style: none; padding: 0; margin: 0; }

.pet-list li, .signup-list li {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 12px 14px;
  border: 1px solid var(--border);
  border-radius: 8px;
  margin-bottom: 10px;
  background: white;
}

.pet-list a { color: var(--text); text-decoration: none; font-weight: 600; }
.pet-list a:hover { color: var(--primary); }
.pet-meta, .signup-meta { color: var(--muted); font-size: 0.85rem; }

.event-block {
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 16px;
  margin-bottom: 16px;
  background: white;
}

.event-block h3 { margin: 0 0 2px; font-size: 1.05rem; }
.event-type-description { color: var(--muted); font-size: 0.85rem; margin-bottom: 12px; }
.event-date { color: var(--muted); font-size: 0.85rem; margin-bottom: 12px; }

.slot-option {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px;
  border: 1px solid var(--border);
  border-radius: 8px;
  margin-bottom: 8px;
}

.slot-option.full { opacity: 0.5; }
.slot-remaining { margin-left: auto; font-size: 0.8rem; color: var(--muted); }

.flash-wrap { margin-bottom: 20px; }

.flash {
  padding: 12px 16px;
  border-radius: 8px;
  margin-bottom: 10px;
  font-size: 0.92rem;
}

.flash-error { background: #fdecea; color: var(--error); border: 1px solid #f5c6c0; }
.flash-success { background: #eaf5ef; color: var(--success); border: 1px solid #bfe3cd; }
.flash-info { background: #eaf2f8; color: var(--info); border: 1px solid #bcd9ec; }

.empty-state { color: var(--muted); font-style: italic; padding: 8px 0; }

.banner {
  background: #eaf2f8;
  border: 1px solid #bcd9ec;
  border-radius: 10px;
  padding: 14px 16px;
  margin-bottom: 20px;
}

.banner strong { display: block; margin-bottom: 2px; }

.status-pill {
  display: inline-block;
  padding: 2px 10px;
  border-radius: 999px;
  font-size: 0.78rem;
  font-weight: 600;
}

.status-active { background: #eaf5ef; color: var(--success); }
.status-inactive { background: #f1f1f1; color: var(--muted); }

.toggle {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 600;
  font-size: 0.9rem;
  color: var(--text);
  cursor: pointer;
  margin: 0;
}

.toggle input {
  position: absolute;
  opacity: 0;
  width: 0;
  height: 0;
}

.toggle-track {
  position: relative;
  flex-shrink: 0;
  width: 40px;
  height: 22px;
  background: var(--border);
  border-radius: 999px;
  transition: background 0.15s ease;
}

.toggle-track::after {
  content: "";
  position: absolute;
  top: 2px;
  left: 2px;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: white;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.25);
  transition: transform 0.15s ease;
}

.toggle input:checked + .toggle-track {
  background: var(--primary);
}

.toggle input:checked + .toggle-track::after {
  transform: translateX(18px);
}
