* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}
body {
  font-family:
    -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  background: #f9f3e6;
  color: #222;
  min-height: 100vh;
}
.container {
  max-width: 1400px;
  margin: 0 auto;
  padding: 20px;
}
header {
  background: #000;
  padding: 16px 0;
  text-align: center;
  border-bottom: 3px solid #e4cc8f;
  margin-bottom: 24px;
}
header h1 {
  font-size: 1.8em;
  letter-spacing: 2px;
  color: #fff;
}
header a {
  color: #fff;
  text-decoration: none;
}
nav {
  margin-top: 8px;
  display: flex;
  justify-content: center;
  align-items: center;
}
nav a {
  color: #e4cc8f;
  text-decoration: none;
  margin: 0 12px;
  font-size: 0.95em;
}
nav a:hover {
  color: #fff;
}
nav a.nav-admin {
  color: #d32f2f;
  font-weight: 700;
}
nav a.nav-admin:hover {
  color: #ff8a80;
}
nav a.nav-help {
  color: #4caf50;
  font-weight: 700;
  margin-left: auto;
}
nav a.nav-help:hover {
  color: #81c784;
}
.card {
  background: #fff;
  border-radius: 8px;
  padding: 20px;
  margin-bottom: 16px;
  border: 1px solid #e4cc8f;
}
.card h2 {
  color: #222;
  margin-bottom: 12px;
  font-size: 1.2em;
}
table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.9em;
}
th,
td {
  padding: 8px 10px;
  text-align: center;
  border: 1px solid #d4c4a0;
}
th {
  background: #000;
  color: #fff;
  font-weight: 600;
}
/* Alternating row colors matching the spreadsheet */
tr.row-light td {
  background: #f9f3e6;
}
tr.row-tan td {
  background: #f0e2c1;
}
td {
  background: #f9f3e6;
}
tr:nth-child(even) td {
  background: #f0e2c1;
}
tr:nth-child(odd) td {
  background: #f9f3e6;
}
.gold-label {
  background: #e4cc8f !important;
  font-weight: 700;
  font-size: 1.05em;
}
input[type="text"],
input[type="number"],
input[type="password"] {
  background: #fff;
  border: 1px solid #d4c4a0;
  color: #222;
  padding: 6px 10px;
  border-radius: 4px;
  width: 100%;
  font-size: 0.95em;
}
input[type="number"] {
  width: 50px;
  text-align: center;
  background: transparent;
}
.btn {
  display: inline-block;
  background: #e4cc8f;
  color: #000;
  padding: 10px 24px;
  border: none;
  border-radius: 4px;
  cursor: pointer;
  font-weight: 600;
  font-size: 1em;
  text-decoration: none;
}
.btn:hover {
  background: #d4b96a;
}
.btn-sm {
  padding: 6px 14px;
  font-size: 0.85em;
}
.status-pending {
  color: #999;
}
.status-in_progress {
  color: #b8860b;
}
.status-complete {
  color: #2e7d32;
}
.match-status {
  font-size: 1.1em;
  font-weight: 700;
  padding: 4px 12px;
  border-radius: 4px;
}
.team-a-up {
  color: #1565c0;
}
.team-b-up {
  color: #c62828;
}
.all-square {
  color: #666;
}
.grid-2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}
.flash {
  border-radius: 8px;
  padding: 12px 16px;
  margin-bottom: 16px;
  border: 1px solid #d4c4a0;
  font-weight: 600;
}
.flash-success {
  background: #edf7ed;
  color: #1b5e20;
  border-color: #a5d6a7;
}
.flash-error {
  background: #fdecea;
  color: #b71c1c;
  border-color: #ef9a9a;
}
.session-note {
  margin-top: 10px;
  color: #fff;
  font-size: 0.9em;
}
.session-note a {
  color: #e4cc8f;
  text-decoration: none;
  margin-left: 10px;
}
.session-note a:hover {
  color: #fff;
}
.audit-details {
  white-space: pre-wrap;
  text-align: left;
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 0.9em;
  line-height: 1.5;
  background: #f9f3e6;
  border: 1px solid #d4c4a0;
  border-radius: 6px;
  padding: 12px;
  margin-top: 12px;
}
details.visit-session {
  border: 1px solid #d4c4a0;
  border-radius: 8px;
  background: #fff;
  margin-bottom: 16px;
  overflow: hidden;
}
details.visit-session summary {
  list-style: none;
  cursor: pointer;
  padding: 16px 20px;
  background: #f9f3e6;
}
details.visit-session summary::-webkit-details-marker {
  display: none;
}
.result-bar {
  background: #e4cc8f;
  padding: 12px 20px;
  border-radius: 6px;
  font-size: 1.1em;
  font-weight: 600;
}
@media (max-width: 640px) {
  .grid-2 {
    grid-template-columns: 1fr;
  }
  .container {
    padding: 12px;
  }
  table {
    font-size: 0.8em;
  }
  input[type="number"] {
    width: 40px;
  }
}
