:root {
  --primary-color: #2c3e50;
  --secondary-color: #3498db;
  --background-color: #f5f6fa;
  --text-color: #2c3e50;
  --highlight-color: #e74c3c;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
  background-color: var(--background-color);
  color: var(--text-color);
  line-height: 1.6;
}

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

header {
  background-color: var(--primary-color);
  color: white;
  padding: 1rem;
  border-radius: 8px;
  margin-bottom: 2rem;
}

#server-time {
  display: flex;
  justify-content: space-around;
  align-items: center;
  text-align: center;
}

#current-time {
  font-size: 1rem;

}

.route-selector, .date-selector {
  margin-bottom: 1rem;
}

.route-additional-info {
  margin-top: 2rem;
  padding-top: 1rem;
  border-top: 1px solid #ddd;
}

.route-additional-info h3 {
  color: #333;
  margin-bottom: 0.5rem;
  font-size: 1.1rem;
}

.route-details, .service-notes {
  margin-bottom: 1rem;
}

.route-additional-info {
  margin-top: 2rem;
  padding-top: 1rem;
  border-top: 1px solid #ddd;
}

.route-details-content p {
  margin-bottom: 1rem;
  line-height: 1.6;
}

.route-images {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 1rem;
  margin: 1.5rem 0;
}

.route-images figure {
  margin: 0;
}

.route-images img {
  max-width: 100%;
  height: auto;
  border-radius: 4px;
}

.route-images figcaption {
  font-size: 0.9rem;
  color: #666;
  margin-top: 0.5rem;
}

.route-links {
  margin: 1rem 0;
}

.route-links a {
  display: inline-block;
  margin-right: 1rem;
  color: #0066cc;
  text-decoration: none;
}

.route-links a:hover {
  text-decoration: underline;
}

.service-alerts {
  list-style: none;
  padding: 0;
  margin: 0;
}

.service-alerts li {
  padding: 0.5rem 0;
  border-bottom: 1px solid #eee;
}

.service-alerts li:last-child {
  border-bottom: none;
}

.effective-date {
  margin-top: 1rem;
  font-style: italic;
  color: #666;
}

.fares-table {
  width: 100%;
  border-collapse: collapse;
  margin: 1rem 0;
}

.fares-table th,
.fares-table td {
  padding: 0.5rem;
  text-align: left;
  border-bottom: 1px solid #eee;
}

.fares-table th {
  background-color: var(--primary-color);
  color: white;
}

.fares-table tr:nth-child(even) {
  background-color: #f9f9f9;
}

.fares-table td:last-child {
  text-align: right;
  font-weight: bold;
}

.holiday-fare-notice {
  font-size: 0.8rem;
  color: #e74c3c;
  font-style: italic;
  margin-top: 0.5rem;
}

.holiday-info {
  text-align: center;
  margin-top: 8px;
  color: #e74c3c;
  font-weight: 600;
}

select, input[type="date"] {
  width: 100%;
  padding: 0.5rem;
  border: 1px solid #ddd;
  border-radius: 2px;
  font-size: 1rem;
  margin-top: 0.5rem;
}

.schedule-container {
  background: white;
  padding: 1rem;
  border-radius: 4px;
  box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

#schedule-title {
  margin-bottom: 1rem;
  font-size: 0.9em;
  text-align: center;
  color: var(--primary-color);
}

.schedule-item {
  padding: 1rem;
  border-bottom: 1px solid #eee;
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: var(--background-color);
  border-radius: 4px;
  margin-bottom: 0.5rem;
  border: 2px solid transparent;
}

.schedule-item:hover {
  border-color: var(--secondary-color);
}

.schedule-item .time {
  font-size: 2rem;
  font-weight: bold;
  color: var(--secondary-color);
}

.schedule-item .label {
  color: var(--primary-color);
  font-size: 1rem;
}

.schedule-item.next {
  background-color: #f1c40f;
  border-color: #f1c40f;
}

.schedule-item.next .time,
.schedule-item.next .label {
  color: var(--primary-color);
}

#next-departure {
  margin-top: 0.5rem;
  padding: 1rem;
  background: var(--background-color);
  color: var(--primary-color);
  border-radius: 4px;
  text-align: center;
  font-size: 1.1rem;
  border: 2px solid var(--primary-color);
}

@media (max-width: 768px) {
  .container {
    padding: 1rem;
  }
  
  #server-time {
    flex-direction: column;
    gap: 0.5rem;
  }
}

#overview-container {
  background: white;
  padding: 1rem;
  border-radius: 4px;
  box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

#overview-container h2 {
  text-align: center;
  color: var(--primary-color);
  margin-bottom: 1rem;
}

.next-departures-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1rem;
}

.next-departure-card {
  background: var(--background-color);
  padding: 1rem;
  border-radius: 4px;
  border: 2px solid transparent;
  cursor: pointer;
  transition: all 0.2s ease;
}

.next-departure-card:hover {
  border-color: var(--secondary-color);
  transform: translateY(-2px);
  box-shadow: 0 4px 8px rgba(0,0,0,0.1);
}

.next-departure-card h3 {
  color: var(--primary-color);
  margin-bottom: 0.5rem;
  font-size: 1rem;
}

.next-departure-card .next-time {
  font-size: 2rem;
  font-weight: bold;
  color: var(--secondary-color);
}

.next-departure-card .time-until {
  font-size: 0.9rem;
  color: #666;
  margin-top: 0.25rem;
}

.back-btn {
  background: var(--secondary-color);
  color: white;
  border: none;
  padding: 0.75rem 1.5rem;
  border-radius: 4px;
  cursor: pointer;
  font-size: 1rem;
  margin-bottom: 1rem;
  transition: all 0.2s ease;
}

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