* {
  box-sizing: border-box;
}

/* 1vw scales all rem-based sizing proportionally to viewport width, so the
   same layout looks the same on a 1080p and a 4K TV (both 16:9) without
   separate breakpoints. */
html {
  font-size: 1vw;
}

html, body {
  margin: 0;
  width: 100vw;
  height: 100vh;
  background: #000;
  color: #eee;
  font-family: system-ui, sans-serif;
  overflow: hidden;
}

body {
  display: flex;
  flex-direction: column;
}

#main {
  flex: 1;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2rem;
  min-height: 0;
}

.program-screen {
  width: 100%;
  height: 100%;
  padding: 3rem 4rem;
  display: grid;
  grid-template-rows: auto auto 1fr;
  gap: 1.5rem;
  text-align: left;
  background:
    linear-gradient(90deg, rgba(20, 30, 36, 0.96), rgba(13, 16, 18, 0.98)),
    #101418;
  color: #f5f7fa;
  overflow: hidden;
}

.program-header {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 2rem;
  border-bottom: 0.08rem solid rgba(255, 255, 255, 0.14);
  padding-bottom: 0.8rem;
}

.program-header h1 {
  margin: 0;
  font-size: 2.4rem;
  line-height: 1;
  font-weight: 760;
}

.program-header-right {
  display: flex;
  align-items: baseline;
  gap: 1.6rem;
}

.program-updated {
  color: #aeb8c4;
  font-size: 1.1rem;
  font-variant-numeric: tabular-nums;
}

.program-duty {
  color: #ffcc4d;
  font-size: 1.1rem;
  font-weight: 720;
  white-space: nowrap;
}

.program-current {
  display: grid;
  grid-template-columns: 7rem 1fr;
  grid-template-areas:
    "label title"
    "label meta";
  column-gap: 1.4rem;
  align-items: center;
  border-left: 0.45rem solid #ffcc4d;
  background: rgba(255, 255, 255, 0.08);
  padding: 1.2rem 1.5rem;
}

.program-label {
  grid-area: label;
  color: #ffcc4d;
  font-size: 1rem;
  font-weight: 800;
  text-transform: uppercase;
}

.program-current-title {
  grid-area: title;
  min-width: 0;
  font-size: 2.4rem;
  line-height: 1.05;
  font-weight: 780;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.program-current-meta {
  grid-area: meta;
  margin-top: 0.35rem;
  color: #c5ced8;
  font-size: 1rem;
  font-variant-numeric: tabular-nums;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.program-upcoming {
  min-height: 0;
  overflow: hidden;
}

.program-upcoming h2 {
  margin: 0 0 0.9rem;
  color: #aeb8c4;
  font-size: 1.05rem;
  font-weight: 750;
  text-transform: uppercase;
}

.program-event {
  display: grid;
  grid-template-columns: 6.5rem 1fr;
  gap: 1.2rem;
  align-items: center;
  min-height: 4.4rem;
  border-top: 0.08rem solid rgba(255, 255, 255, 0.1);
  padding: 0.75rem 0;
}

.program-event-time {
  color: #8fd3ff;
  font-size: 1.65rem;
  font-weight: 780;
  font-variant-numeric: tabular-nums;
}

.program-event-title {
  min-width: 0;
  font-size: 1.45rem;
  line-height: 1.1;
  font-weight: 700;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.program-event-meta {
  margin-top: 0.25rem;
  color: #9da8b5;
  font-size: 0.9rem;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.program-empty {
  align-self: center;
  justify-self: center;
  color: #aeb8c4;
  font-size: 1.6rem;
}
