/* Reset and base styles */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen, Ubuntu, Cantarell, "Open Sans",
    "Helvetica Neue", sans-serif;
  line-height: 1.6;
  color: #333;
  background-color: #f5f5f5;
  padding: 20px;
}

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 20px;
}

h1 {
  font-size: 24px;
  margin-bottom: 20px;
  color: #111;
}

h2 {
  font-size: 20px;
  margin-bottom: 15px;
  color: #111;
}

/* Navigation links */
.nav-links {
  display: flex;
  gap: 15px;
  margin-bottom: 20px;
  border-bottom: 1px solid #e2e8f0;
  padding-bottom: 10px;
}

.nav-link {
  padding: 8px 16px;
  text-decoration: none;
  color: #4a5568;
  border-radius: 4px;
  font-weight: 500;
}

.nav-link:hover {
  background-color: #f1f5f9;
}

.nav-link.active {
  background-color: #4a5568;
  color: white;
}

/* Controls */
.controls {
  margin-bottom: 20px;
  display: flex;
  flex-direction: column;
  gap: 15px;
}

.form-group {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
}

.form-group label {
  font-weight: 500;
  margin-right: 5px;
}

.form-group input,
.form-group select {
  padding: 8px 12px;
  border: 1px solid #ddd;
  border-radius: 4px;
  font-size: 14px;
}

.checkbox-group {
  display: flex;
  align-items: center;
  gap: 5px;
  margin-left: 10px;
}

.checkbox-group input[type="checkbox"] {
  margin: 0;
}

.refresh-form,
.filter-form {
  background-color: #f8fafc;
  padding: 15px;
  border-radius: 6px;
  border: 1px solid #e2e8f0;
}

.refresh-button,
.filter-button {
  padding: 10px 15px;
  background-color: #4a5568;
  color: white;
  border: none;
  border-radius: 4px;
  cursor: pointer;
  font-size: 14px;
}

.refresh-button:hover,
.filter-button:hover {
  background-color: #2d3748;
}

.refresh-button:disabled {
  background-color: #a0aec0;
  cursor: not-allowed;
}

.clear-button {
  padding: 10px 15px;
  background-color: #e2e8f0;
  color: #4a5568;
  border: none;
  border-radius: 4px;
  cursor: pointer;
  font-size: 14px;
  text-decoration: none;
  display: inline-block;
}

.clear-button:hover {
  background-color: #cbd5e1;
}

.message {
  padding: 10px;
  background-color: #dcfce7;
  color: #166534;
  border-radius: 4px;
  font-size: 14px;
}

/* MySQL container styles */
.mysql-container {
  border: 1px solid #ddd;
  border-radius: 6px;
  overflow: hidden;
  background-color: white;
  margin-bottom: 20px;
}

.mysql-prompt {
  background-color: #1a202c;
  color: white;
  padding: 10px;
  font-family: monospace;
  font-size: 14px;
  white-space: pre-wrap;
  word-break: break-word;
}

.mysql-result {
  background-color: #1a202c;
  color: white;
  padding: 10px;
  font-family: monospace;
  font-size: 14px;
}

/* Table styles */
.table-container {
  overflow-x: auto;
}

table {
  width: 100%;
  border-collapse: collapse;
}

th {
  background-color: #f1f5f9;
  text-align: left;
  padding: 12px;
  font-weight: 600;
  color: #4a5568;
  border-bottom: 1px solid #ddd;
}

td {
  padding: 12px;
  border-bottom: 1px solid #eee;
}

tr:hover {
  background-color: #f9fafb;
}

.no-results {
  text-align: center;
  padding: 40px;
  color: #666;
}

/* Score cell styles */
.score-cell {
  font-weight: 600;
}

.score-details {
  display: block;
  font-size: 12px;
  color: #666;
  font-weight: normal;
  margin-top: 4px;
}

/* Status badge styles */
.status-badge {
  display: inline-block;
  padding: 4px 8px;
  border-radius: 9999px;
  font-size: 12px;
  font-weight: 500;
}

.status-not-started {
  background-color: #e6f0fd;
  color: #1e40af;
}

.status-in-play {
  background-color: #dcfce7;
  color: #166534;
}

.status-ended {
  background-color: #fef3c7;
  color: #92400e;
}

.status-unknown {
  background-color: #e5e7eb;
  color: #4b5563;
}

/* API Info section */
.api-info {
  background-color: #f8fafc;
  padding: 20px;
  border-radius: 6px;
  border: 1px solid #e2e8f0;
}

.api-info ul {
  margin-left: 20px;
  margin-bottom: 15px;
}

.api-info li {
  margin-bottom: 5px;
}

/* Responsive adjustments */
@media (max-width: 768px) {
  .form-group {
    flex-direction: column;
    align-items: flex-start;
  }

  .form-group input,
  .form-group select {
    width: 100%;
  }

  .checkbox-group {
    margin-left: 0;
    margin-top: 10px;
  }

  .refresh-button,
  .filter-button,
  .clear-button {
    width: 100%;
    margin-top: 10px;
  }
}
