:root {
  color-scheme: light;
  --bg: #eeeeee;
  --paper: #eeeeee;
  --ink: #000000;
  --muted: #4d4d4d;
  --line: transparent;
  --accent: #336699;
  --accent-soft: #ddeeff;
  --radius: 8px;
  --shadow: none;
  font-family: Verdana, Arial, Helvetica, sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  background: var(--bg);
  color: var(--ink);
  font-size: 13px;
  font-weight: normal;
}

a {
  color: var(--accent);
  text-decoration: underline;
}

a:hover {
  color: green;
  text-decoration: none;
}

.site-header {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 18px clamp(14px, 4vw, 48px) 10px;
  background: var(--bg);
}

.brand,
.site-footer {
  display: flex;
  align-items: center;
}

.brand {
  gap: 10px;
  min-width: max-content;
  font-weight: 700;
}

.brand:hover {
  color: green;
}

main {
  width: min(760px, calc(100% - 28px));
  margin: 0 auto;
}

.section {
  padding: 18px 0 0;
}

.forecast-panel {
  padding-top: 18px;
}

.section-heading {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 8px;
}

.forecast-grid {
  display: grid;
  overflow: hidden;
  margin-top: 2px;
}

.forecast-day {
  display: grid;
  grid-template-columns: 92px 72px minmax(0, 1fr) 62px;
  gap: 10px;
  align-items: baseline;
  min-height: 26px;
  padding: 6px 0;
  border-bottom: 1px solid #d8d8d8;
}

.forecast-day:last-child {
  border-bottom: 0;
}

.forecast-date {
  display: grid;
  grid-template-columns: 34px 1fr;
  column-gap: 6px;
  color: var(--muted);
  text-transform: lowercase;
  white-space: nowrap;
}

.forecast-temp {
  line-height: 1.1;
  white-space: nowrap;
}

.forecast-condition,
.forecast-rain,
.forecast-loading {
  color: var(--muted);
  line-height: 1.35;
}

.forecast-condition {
  display: flex;
  align-items: center;
  gap: 7px;
  min-width: 0;
}

.weather-icon {
  flex: 0 0 auto;
  width: 14px;
  height: 14px;
  color: #2f6f8f;
}

.weather-icon svg {
  display: block;
  width: 100%;
  height: 100%;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.weather-icon-sun {
  color: #d88a15;
}

.weather-icon-cloud,
.weather-icon-fog {
  color: #64748b;
}

.weather-icon-cloud-sun {
  color: #c0841a;
}

.weather-icon-rain {
  color: #1d75a6;
}

.weather-icon-snow {
  color: #38a3c7;
}

.weather-icon-storm {
  color: #6d5bd0;
}

.forecast-loading {
  grid-column: 1 / -1;
  padding: 3px 0;
}

.headline-source,
.source-label,
.site-footer {
  color: var(--muted);
  font-size: 12px;
  font-weight: normal;
  letter-spacing: 0;
}

.source-label {
  font-size: 12px;
  text-align: right;
}

h1,
h2,
p {
  margin: 0;
}

h1 {
  max-width: 820px;
  font-size: inherit;
  font-weight: 500;
  line-height: 0.96;
}

h2 {
  margin-top: 0;
  font-size: inherit;
  font-weight: 700;
  line-height: 1.2;
  text-transform: lowercase;
}

.headline-list {
  display: grid;
  gap: 8px;
  overflow: hidden;
  border-radius: var(--radius);
  background: transparent;
}

.headline-list a {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 2px;
  width: fit-content;
  max-width: 100%;
  padding: 0;
  background: var(--paper);
}

.headline-list a::before {
  content: "- ";
  grid-column: 1;
  grid-row: 1;
  color: var(--ink);
}

.headline-loading {
  padding: 0;
  background: var(--paper);
  color: var(--muted);
}

.headline-list a:hover {
  background: #ffffff;
  color: green;
}

.headline-list strong {
  grid-column: 2;
  grid-row: 1;
  line-height: 1.25;
  font-weight: normal;
  overflow-wrap: anywhere;
}

.headline-source,
.headline-list span:last-child {
  display: none;
  color: var(--muted);
  line-height: 1.45;
}

.wiki-links {
  display: flex;
  flex-wrap: wrap;
  gap: 0 8px;
}

.wiki-links a {
  color: var(--accent);
  font-weight: normal;
}

.wiki-links a:not(:last-child)::after {
  content: " |";
  color: var(--ink);
}

.site-footer {
  justify-content: space-between;
  gap: 16px;
  width: min(760px, calc(100% - 28px));
  margin: 0 auto;
  padding: 28px 0 34px;
}

.content-grid {
  padding-bottom: 26px;
}

.coming-soon-panel {
  display: grid;
  gap: 12px;
  max-width: 620px;
  padding-top: 28px;
}

.coming-soon-panel p {
  color: var(--muted);
  line-height: 1.45;
}

.forecast-condition {
  overflow-wrap: anywhere;
}

@media (max-width: 820px) {
  .forecast-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 520px) {
  main,
  .site-footer {
    width: min(100% - 28px, 1120px);
  }

  .forecast-day {
    grid-template-columns: 84px 64px minmax(0, 1fr);
    gap: 8px;
    padding: 3px 0;
  }

  .forecast-date {
    grid-template-columns: 30px 1fr;
    column-gap: 5px;
  }

  .forecast-rain {
    grid-column: 3;
    justify-self: start;
    margin-left: 21px;
    font-size: 12px;
  }

  h1 {
    font-size: inherit;
  }

  .site-footer {
    flex-direction: column;
    align-items: flex-start;
  }
}
