:root { color-scheme: dark; font-family: system-ui, -apple-system, Segoe UI, Roboto, sans-serif; }
body { margin:0; background:#0b0c10; color:#e6e6e6; }
.wrap { max-width:1100px; margin:0 auto; padding:16px; }
h1 { margin:0 0 8px 0; font-size:18px; font-weight:600; }
.grid { display:grid; grid-template-columns: 0.9fr 1fr 1fr; gap:16px; }
@media (max-width: 900px){ .grid { grid-template-columns: 1fr; } }
.card { background:#121318; border:1px solid #1f2230; border-radius:14px; padding:16px; }
.title { font-weight:700; margin-bottom:10px; display:flex; align-items:center; gap:8px; }
.pill { background:#22283a; border:1px solid #2a2e42; border-radius:999px; padding:3px 10px; font-size:12px; opacity:.9; }
ul { list-style:none; margin:0; padding:0; display:flex; flex-direction:column; gap:8px; }
li { display:flex; align-items:center; gap:8px; background:#161a26; border:1px solid #2a2e42; border-radius:10px; padding:8px 10px; }
.badge { width:26px; height:26px; border-radius:50%; display:grid; place-items:center; font-weight:800; font-size:13px; color:#fff; }
.A,.C { background:#0039A6; } .B,.D { background:#FF6319; }
.mins { margin-left:0; font-variant-numeric: tabular-nums; font-size:16px; font-weight:600; }
.small { font-size:12px; opacity:.8; }
.alert-card { background:#1a2533; border:1px solid #2c3b52; border-left:4px solid #ffb020; border-radius:10px; padding:10px 12px; margin-bottom:8px; }
.wx-temp { font-size:28px; font-weight:700; }
.wx-sub { font-size:12px; opacity:.85; }
.wx-chip { background:#161a26; border:1px solid #2a2e42; border-radius:999px; padding:6px 10px; font-variant-numeric:tabular-nums; display:inline-block; margin:4px 6px 0 0; }
.diag { font-size:11px; opacity:.7; margin-top:6px; }
.dot { display:inline-block; width:8px; height:8px; border-radius:50%; background:#48d597; margin-right:6px; vertical-align:middle; }
.wx-row-top { display:flex; align-items:center; gap:12px; }
.wx-emoji { font-size:28px; line-height:1; }
.astro-row { display:flex; gap:10px; flex-wrap:wrap; }
.wx-chart { width:100%; height:auto; display:block; }

/* === Layout: weather left, trains right with alerts underneath === */
.grid-main {
  display: grid;
  grid-template-columns: 0.9fr 1.1fr;
  gap: 16px;
}
.trains-area {
  display: grid;
  grid-template-columns: 1fr 1fr;
  grid-template-areas:
    "up dn"
    "al al";
  gap: 16px;
}
.trains-area > section:nth-child(1) { grid-area: up; }
.trains-area > section:nth-child(2) { grid-area: dn; }
.trains-area > section.alerts       { grid-area: al; }
@media (max-width: 900px) {
  .grid-main { grid-template-columns: 1fr; }
  .trains-area { grid-template-columns: 1fr; grid-template-areas: "up" "dn" "al"; }
}

/* === Train list tightening + bigger visuals === */
.trains-list { /* optionally limit width so rows don't look sparse on huge screens */
  max-width: 520px;
}
li {
  display:flex;
  align-items:center;
  gap:10px;                 /* tighter gap between icon and time */
  background:#161a26;
  border:1px solid #2a2e42;
  border-radius:10px;
  padding:10px 12px;
}
.badge {
  width:30px; height:30px;  /* bigger icon */
  border-radius:50%;
  display:grid; place-items:center;
  font-weight:800; font-size:15px; color:#fff;
}
.mins {
  margin-left: 0;           /* no big push to the right */
  font-variant-numeric: tabular-nums;
  font-size:18px;           /* bigger time text */
  font-weight:700;
}

/* keep your existing line colors */
.A,.C { background:#0039A6; }
.B,.D { background:#FF6319; }

/* Weather layout bits (if not already present) */
.wx-row-top { display:flex; align-items:center; gap:12px; }
.wx-emoji { font-size:28px; line-height:1; }
.astro-row { display:flex; gap:10px; flex-wrap:wrap; }

/* Chart svg sizing */
.wx-chart { width:100%; height:auto; display:block; }

/* Precip chart text color */
.wx-chart text {
  fill: #fff; /* white text for better contrast */
}

/* Tighten trains list layout */
.trains-list li {
  justify-content: flex-start; /* no auto spacing that pushes content apart */
}

/* Narrow gap between Uptown/Downtown columns */
.trains-area {
  gap: 10px; /* was larger before */
}

/* 1) Make precip chart labels easy to read */
.wx-chart text { fill: #fff; }            /* axis + x‑labels white */
/* 2) Tighten train rows, remove phantom spacing, bump size a bit */
.trains-list li { justify-content: flex-start; }  /* no auto spacing */
.badge { width:32px; height:32px; font-size:16px; } /* bigger icons */
.mins  { font-size:20px; font-weight:700; margin-left:0; } /* bigger time, no push */
/* 3) Make Uptown/Downtown columns only as wide as their content
      so they sit closer together and don't hog the right side */
.trains-area {
  grid-template-columns: auto auto;  /* content-sized columns */
  justify-content: start;            /* align both to the left */
  gap: 10px;                         /* tight space between them */
}
.trains-area > section { width: max-content; }
.trains-list, .trains-list li { width: max-content; }  /* cards shrink to content */
/* Keep mobile friendly: stack normally on small screens */
@media (max-width: 900px) {
  .trains-area { grid-template-columns: 1fr; justify-content: stretch; }
  .trains-area > section,
  .trains-list, .trains-list li { width: auto; }
}


