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

body {
  background: #0f172a;
  color: #f1f5f9;
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  min-height: 100vh;
}

.site-header {
  background: #0f172a;
  border-bottom: 1px solid #1e293b;
  padding: 16px 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  position: sticky;
  top: 0;
  z-index: 10;
}
.site-name { font-size: 18px; font-weight: 700; letter-spacing: -0.3px; }
.site-name span { color: #3b82f6; }
.refresh-badge { font-size: 11px; color: #475569; background: #1e293b; padding: 4px 10px; border-radius: 99px; }

.tabs {
  display: flex;
  padding: 20px 24px 0;
  border-bottom: 1px solid #1e293b;
}
.tab {
  padding: 10px 20px;
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  border-bottom: 2px solid transparent;
  color: #64748b;
}
.tab.active { color: #f1f5f9; border-bottom-color: #3b82f6; }

.crossings { padding: 20px 24px; display: flex; flex-direction: column; gap: 10px; max-width: 800px; margin: 0 auto; }

.crossing-row {
  background: #1e293b;
  border-radius: 10px;
  padding: 14px 16px;
  display: flex;
  align-items: center;
  gap: 14px;
  border: 1px solid #334155;
}
.cam-thumb {
  width: 280px;
  border-radius: 6px;
  background: #334155;
  flex-shrink: 0;
  display: block;
}
.cam-placeholder {
  width: 280px; height: 210px;
  border-radius: 6px;
  background: #334155;
  flex-shrink: 0;
  display: flex; align-items: center; justify-content: center;
  color: #475569; font-size: 10px;
}
.crossing-info { flex: 1; min-width: 0; }
.crossing-name { font-size: 15px; font-weight: 600; margin-bottom: 2px; }
.crossing-location { font-size: 11px; color: #64748b; margin-bottom: 8px; }
.lane-times { display: flex; flex-wrap: wrap; gap: 12px; }
.lane { display: flex; flex-direction: column; gap: 1px; }
.lane-label { font-size: 9px; text-transform: uppercase; letter-spacing: 0.5px; color: #475569; }
.lane-time { font-size: 15px; font-weight: 700; }
.lane-time.green  { color: #22c55e; }
.lane-time.yellow { color: #f59e0b; }
.lane-time.red    { color: #ef4444; }
.lane-time.closed { color: #475569; font-size: 11px; font-weight: 500; }
.sources-tip { font-size: 10px; color: #475569; margin-top: 6px; }
.updated { font-size: 10px; color: #475569; white-space: nowrap; align-self: flex-start; }

@media (max-width: 600px) {
  .crossings { padding: 12px; }
  .crossing-row { gap: 10px; }
  .cam-thumb { width: 160px; }
  .cam-placeholder { width: 160px; height: 120px; }
}
