/* World Cup 2026 — Weather Operations.
   Mirrors the digital-signs architecture: a 16:9 root, an __inner wrapper that
   is the container-query context, and type/spacing sized in `cqw` so the whole
   board scales with the frame. Class names follow the signs' BEM convention
   (`aw-events__<block>`), e.g. __loc-block ~ ds-lightning's __dsl-loc-block.
   Dynamic values (data-driven colors, flag image, temperatures) stay inline in
   JS; layout + type live here. */

/* ── Root: 16:9 stage, centered, sizing only ─────────────────────── */
.aw-events {
  aspect-ratio: 16 / 10;
  width: min(100vw, calc(100vh * 16 / 10));
  max-width: 100vw;
  margin: 0 auto;
  overflow: hidden;
  background: #131415;
  color: #fff;
  font-family: "Solis", "Inter", system-ui, -apple-system, sans-serif;
  font-weight: 500;
  line-height: 1.2;
}

/* Inner wrapper: the container-query context + header/body grid. Padding lives
   here so cqw resolves against a stable content-box inline-size. */
.aw-events__inner {
  display: grid;
  grid-template-rows: auto 1fr;
  row-gap: 1.2cqw;
  width: 100%;
  height: 100%;
  padding: 1.25%;
  box-sizing: border-box;
  container-type: inline-size;
}

/* ── Header ──────────────────────────────────────────────────────── */
.aw-events__header {
  display: flex;
  align-items: start;
  justify-content: space-between;
  gap: 1.25cqw;
}
.aw-events__brand { display: flex; align-items: center; }
.aw-events__brand-logo { display: block; height: 2.6cqw; width: auto; flex: 0 0 auto; }
.aw-events__meta { display: flex; align-items: start; gap: 1.1cqw; min-width: 0; }

/* same treatment AND size as ds-lightning .aw-widget__dsl-loc-block / __dsl-loc
   / __dsl-datetime (loc 2.5cqw, datetime 1.25cqw). */
.aw-events__loc-block { display: flex; flex-direction: column; align-items: flex-end; min-width: 0; text-align: right; }
.aw-events__loc {
  font-size: 2.5cqw;
  font-weight: 700;
  line-height: 1.25;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 46cqw;
}
.aw-events__datetime {
  display: inline-flex;
  align-items: center;
  gap: 1cqw;
  margin-top: 0.3cqw;
  font-size: 1.25cqw;
  font-weight: 500;
  line-height: 1.25;
  color: rgba(255, 255, 255, 0.7);
  white-space: nowrap;
}
.aw-events__live-dot {
  width: 0.7cqw; height: 0.7cqw; border-radius: 50%;
  background: var(--wc-accent, #F05514);
  box-shadow: 0 0 0 0.25cqw rgba(240, 85, 20, 0.25);
  flex: 0 0 auto;
}
.aw-events__live { color: var(--wc-accent, #F05514); font-weight: 700; }

/* ── Toggles (Today/Week, °F/°C) ─────────────────────────────────── */
.aw-events__toggle {
  display: flex; gap: 0.21cqw; padding: 0.21cqw;
  background: rgba(255, 255, 255, 0.05); border-radius: 0.56cqw;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.08);
}
.aw-events__toggle-btn {
  border: none; cursor: pointer; font-family: inherit;
  padding: 0.56cqw 1.25cqw; border-radius: 0.42cqw;
  font-size: 0.94cqw; font-weight: 700; letter-spacing: 0.2px;
  background: transparent; color: rgba(255, 255, 255, 0.7);
  transition: background .15s, color .15s;
}
.aw-events__toggle-btn--unit { padding: 0.56cqw 0.9cqw; }
.aw-events__toggle-btn.is-active { background: #fff; color: #131415; }
/* Daily/Weekly mode toggle: full rail width, shorter than the others. */
.aw-events__toggle--mode { width: 9cqw; }
.aw-events__toggle--mode .aw-events__toggle-btn { flex: 1 1 0; padding: 0.3cqw 0.5cqw; font-size: 0.83cqw; text-align: center; }

/* ── Hamburger menu ──────────────────────────────────────────────── */
.aw-events__menu { position: relative; }
.aw-events__menu-btn {
  display: inline-flex; align-items: center; justify-content: center;
  width: 2.78cqw; height: 2.78cqw; border: none; border-radius: 0.56cqw; cursor: pointer;
  background: rgba(255, 255, 255, 0.05); box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.08);
}
.aw-events__menu-btn.is-open { background: rgba(255, 255, 255, 0.10); }
.aw-events__menu-btn svg { width: 1.67cqw; height: 1.67cqw; display: block; }
.aw-events__menu-panel {
  position: absolute; right: 0; top: calc(100% + 0.7cqw); z-index: 50; min-width: 12.8cqw;
  background: #1b1c1e; border: 1px solid rgba(255, 255, 255, 0.12); border-radius: 0.7cqw;
  padding: 0.97cqw 1.11cqw; box-shadow: 0 0.7cqw 2cqw rgba(0, 0, 0, 0.45);
  display: flex; flex-direction: column; gap: 0.69cqw;
}
.aw-events__menu-label { font-size: 0.73cqw; font-weight: 700; letter-spacing: 0.6px; text-transform: uppercase; color: rgba(255, 255, 255, 0.5); }

/* ── Body fills the 16:9 stage; columns scroll internally ────────── */
.aw-events__body { min-height: 0; overflow: hidden; }
.aw-events__center { min-height: 40cqh; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 0.7cqw; }
.aw-events__center-title { font-size: 1.2cqw; font-weight: 700; color: #fff; }
.aw-events__center-detail { font-size: 0.95cqw; color: rgba(255, 255, 255, 0.5); max-width: 32cqw; text-align: center; }

/* ── Today: left day rail + scrollable card area ─────────────────── */
.aw-events__today { display: flex; gap: 1.1cqw; height: 100%; min-height: 0; }
.aw-events__today-main { flex: 1 1 auto; min-width: 0; min-height: 0; overflow-y: auto; padding-right: 0.4cqw; }
/* vertical day rail: Daily/Weekly toggle pinned at top, scrollable day list
   below (no visible scrollbar via .wc-noscrollbar). */
.aw-events__daystrip { flex: 0 0 auto; width: 9cqw; display: flex; flex-direction: column; gap: 0.56cqw; min-height: 0; }
.aw-events__daylist { flex: 1 1 auto; min-height: 0; overflow-y: auto; display: flex; flex-direction: column; gap: 0.56cqw; }
.aw-events__day {
  width: 100%; padding: 0.83cqw 0.97cqw; border-radius: 0.42cqw;
  background: rgba(255, 255, 255, 0.04);
  display: flex; align-items: center; justify-content: space-between; cursor: pointer; transition: background .15s;
}
.aw-events__day.is-active { background: rgba(255, 255, 255, 0.09); box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.22); }
.aw-events__day-dow { font-size: 0.73cqw; font-weight: 700; letter-spacing: 0.6px; color: rgba(255, 255, 255, 0.55); }
.aw-events__day.is-active .aw-events__day-dow { color: #fff; }
.aw-events__day-num { font-size: 1.53cqw; font-weight: 700; line-height: 1.1; color: rgba(255, 255, 255, 0.8); }
.aw-events__day.is-active .aw-events__day-num { color: #fff; }
.aw-events__day-count { font-size: 0.76cqw; color: rgba(255, 255, 255, 0.45); }

/* ── Today: match cards ──────────────────────────────────────────── */
.aw-events__grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.11cqw; }
.aw-events__card { border-radius: 0.42cqw; background: rgba(255, 255, 255, 0.05); overflow: hidden; box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.04); display: flex; flex-direction: column; }
.aw-events__card-inner { padding: 1.11cqw 1.25cqw 1.25cqw; display: flex; flex-direction: column; gap: 0.97cqw; }
.aw-events__card-top { display: flex; align-items: center; justify-content: space-between; }
.aw-events__kick { display: flex; align-items: baseline; gap: 0.56cqw; }
.aw-events__kick-time { font-size: 1.18cqw; font-weight: 700; }
.aw-events__kick-tz { font-size: 0.8cqw; color: rgba(255, 255, 255, 0.45); font-weight: 700; letter-spacing: 0.4px; }
.aw-events__tier { font-size: 0.66cqw; font-weight: 700; letter-spacing: 0.5px; text-transform: uppercase; color: rgba(255, 255, 255, 0.35); }
.aw-events__teams { display: flex; align-items: center; gap: 0.83cqw; }
.aw-events__vs { font-size: 0.83cqw; color: rgba(255, 255, 255, 0.35); font-weight: 700; }
.aw-events__group { margin-left: auto; font-size: 0.76cqw; color: rgba(255, 255, 255, 0.4); font-weight: 700; letter-spacing: 0.4px; }
.aw-events__venue { font-size: 0.87cqw; color: rgba(255, 255, 255, 0.55); display: flex; align-items: center; gap: 0.42cqw; }
.aw-events__venue-name { font-weight: 700; color: rgba(255, 255, 255, 0.8); }
.aw-events__wxrow { display: flex; align-items: center; gap: 0.83cqw; padding: 0.42cqw 0 0.14cqw; }
.aw-events__cond { margin-left: auto; text-align: right; }
.aw-events__cond-text { font-size: 0.9cqw; color: rgba(255, 255, 255, 0.85); }
.aw-events__realfeel { font-size: 0.9cqw; color: rgba(255, 255, 255, 0.6); margin-top: 0.21cqw; }
.aw-events__realfeel b { font-weight: 700; }
.aw-events__stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 0.83cqw; padding-top: 0.83cqw; border-top: 1px solid rgba(255, 255, 255, 0.07); }
.aw-events__hourly { padding-top: 0.83cqw; border-top: 1px solid rgba(255, 255, 255, 0.07); }

/* ── Weekly: rows of [day tile | chips left-to-right] ────────────── */
.aw-events__weekly { height: 100%; min-height: 0; display: flex; flex-direction: column; gap: 0.83cqw; }
.aw-events__weekly-toolbar { flex: 0 0 auto; display: flex; align-items: center; gap: 1cqw; }
.aw-events__weekly-range { font-size: 0.83cqw; font-weight: 700; letter-spacing: 0.7px; text-transform: uppercase; color: rgba(255, 255, 255, 0.5); }
.aw-events__weekly-rows { flex: 1 1 auto; min-height: 0; overflow-y: auto; display: flex; flex-direction: column; gap: 0.69cqw; }
/* one row per matchday; the day tile stretches to the chips' height. */
.aw-events__wrow { display: flex; align-items: stretch; gap: 0.83cqw; }
.aw-events__wrow .aw-events__day { width: 9cqw; flex: 0 0 auto; }
.aw-events__wrow-chips { flex: 1 1 auto; min-width: 0; display: flex; flex-wrap: wrap; gap: 0.69cqw; align-content: flex-start; }
.aw-events__wrow-chips .aw-events__chip { width: 11cqw; flex: 0 0 auto; }
.aw-events__chip { display: flex; border-radius: 0.35cqw; background: rgba(255, 255, 255, 0.05); overflow: hidden; cursor: pointer; padding: 0.63cqw 0.69cqw; flex-direction: column; gap: 0.49cqw; }
.aw-events__chip-time { font-family: var(--font-mono); font-size: 0.8cqw; font-weight: 700; letter-spacing: 0.3px; color: rgba(255, 255, 255, 0.85); }
.aw-events__chip-tz { color: rgba(255, 255, 255, 0.4); }
.aw-events__chip-row { display: flex; align-items: center; gap: 0.42cqw; }
.aw-events__chip-code { font-size: 0.9cqw; font-weight: 700; }
.aw-events__chip-v { font-size: 0.69cqw; color: rgba(255, 255, 255, 0.3); margin: 0 0.07cqw; }
.aw-events__chip-temp { font-size: 1.18cqw; font-weight: 700; letter-spacing: -0.02em; }
.aw-events__chip-city { margin-left: auto; font-size: 0.76cqw; color: rgba(255, 255, 255, 0.5); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 6.7cqw; text-align: right; }

/* ── Atoms: flag, temp, stat, hourly, team ───────────────────────── */
.aw-events__team { display: inline-flex; align-items: center; gap: 0.69cqw; }
.aw-events__team-code { font-weight: 700; font-size: 1.11cqw; letter-spacing: 0.2px; }
.aw-events__flag { display: inline-flex; align-items: center; justify-content: center; border-radius: 0.28cqw; overflow: hidden; box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.18); flex: 0 0 auto; background: rgba(255, 255, 255, 0.08); }
.aw-events__flag img { display: block; width: 100%; height: 100%; object-fit: cover; }
.aw-events__flag--sm { width: 1.7cqw; height: 1cqw; }
.aw-events__flag--md { width: 2.7cqw; height: 1.67cqw; }
.aw-events__flag--lg { width: 2.08cqw; height: 2.08cqw; }
.aw-events__flag-fallback { font-size: 0.56cqw; font-weight: 700; color: rgba(255, 255, 255, 0.6); }
.aw-events__temp { position: relative; display: inline-flex; align-items: flex-start; line-height: 1; }
.aw-events__temp-val { font-weight: 700; letter-spacing: -0.02em; color: #fff; font-size: 3.2cqw; }
.aw-events__temp-unit { font-weight: 400; color: rgba(255, 255, 255, 0.4); font-size: 0.83cqw; margin-top: 0.25cqw; margin-left: 0.07cqw; }
.aw-events__stat { display: flex; flex-direction: column; gap: 0.28cqw; min-width: 0; }
.aw-events__stat-label { font-size: 0.73cqw; font-weight: 700; letter-spacing: 0.6px; text-transform: uppercase; color: rgba(255, 255, 255, 0.5); }
.aw-events__stat-value { font-size: 1.18cqw; font-weight: 700; line-height: 1.1; white-space: nowrap; }
.aw-events__stat-sub { font-size: 0.83cqw; font-weight: 400; color: rgba(255, 255, 255, 0.45); margin-left: 0.14cqw; }
.aw-events__hstrip { display: flex; gap: 0.14cqw; }
.aw-events__hcol { flex: 1; text-align: center; padding: 0.14cqw 0; }
.aw-events__htime { font-size: 0.8cqw; font-weight: 700; color: rgba(255, 255, 255, 0.65); margin-bottom: 0.42cqw; white-space: nowrap; }
.aw-events__hicon { display: flex; justify-content: center; }
.aw-events__htemp { font-size: 1.04cqw; font-weight: 700; margin-top: 0.35cqw; letter-spacing: -0.02em; }
.aw-events__hpop { font-size: 0.73cqw; color: rgba(255, 255, 255, 0.5); margin-top: 0.21cqw; display: flex; align-items: center; justify-content: center; gap: 0.14cqw; }
