/* ============================================================
   Timevis vejrudsigt — ana-ora.css
   vejretodense.com · Nordic Blue/Danish Red theme
   ============================================================ */

/* ── PAGE LAYOUT ── */
.ao-wrap {
  max-width: 1080px;
  margin: 0 auto;
  padding: 28px 24px 60px;
  display: grid;
  grid-template-columns: 1fr 280px;
  gap: 28px;
}

/* ── LOADING ── */
.ao-loading {
  text-align: center;
  padding: 80px 20px;
  color: var(--subtle);
}
.ao-spinner {
  width: 40px;
  height: 40px;
  margin: 0 auto 16px;
  border: 3px solid var(--foam);
  border-top-color: var(--forest);
  border-radius: 50%;
  animation: ao-spin 0.8s linear infinite;
}
@keyframes ao-spin { to { transform: rotate(360deg); } }

/* ── CURRENT WEATHER HERO ── */
.ao-hero {
  background: var(--white);
  border-radius: 14px;
  border: 1px solid #dde5dd;
  padding: 24px 28px;
  display: flex;
  align-items: center;
  gap: 28px;
  box-shadow: 0 1px 3px rgba(42,62,45,.06);
  margin-bottom: 4px;
}
.ao-hero-icon svg { width: 72px; height: 72px; }
.ao-hero-temp {
  display: flex;
  flex-direction: column;
}
.ao-hero-degrees {
  font-size: 48px;
  font-weight: 300;
  line-height: 1;
  color: var(--forest-dark);
  letter-spacing: -2px;
}
.ao-hero-degrees sup {
  font-size: 22px;
  vertical-align: super;
  font-weight: 400;
}
.ao-hero-condition {
  font-size: 15px;
  font-weight: 500;
  color: var(--forest-light);
  margin-top: 4px;
}
.ao-hero-feels {
  font-size: 12px;
  color: var(--subtle);
  margin-top: 2px;
}
.ao-hero-details {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px 28px;
  margin-left: auto;
  font-size: 13px;
}
.ao-hero-label {
  color: var(--subtle);
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}
.ao-hero-value {
  color: var(--text);
  font-weight: 500;
}

/* ── TAB STRIP ── */
.ao-tabs {
  display: flex;
  gap: 0;
  margin-top: 24px;
  margin-bottom: 2px;
}
.ao-tab {
  padding: 12px 22px;
  font-size: 13px;
  color: var(--subtle);
  cursor: pointer;
  border: 1px solid transparent;
  border-bottom: none;
  border-radius: 10px 10px 0 0;
  background: transparent;
  transition: all .2s;
  font-family: inherit;
  font-weight: 400;
}
.ao-tab:hover { color: var(--text); background: var(--muted-bg); }
.ao-tab.active {
  background: var(--white);
  color: var(--forest);
  font-weight: 500;
  border-color: #dde5dd;
  position: relative;
}
.ao-tab.active::after {
  content: '';
  position: absolute;
  bottom: -1px;
  left: 0;
  right: 0;
  height: 2px;
  background: var(--white);
}

/* ── HOURLY TABLE ── */
.ao-table {
  background: var(--white);
  border: 1px solid #dde5dd;
  border-radius: 0 14px 14px 14px;
  box-shadow: 0 1px 3px rgba(42,62,45,.06);
  overflow: hidden;
}

.ao-table-header {
  display: grid;
  grid-template-columns: 62px 1fr 64px 64px 72px 72px 56px;
  align-items: center;
  padding: 12px 20px;
  background: var(--muted-bg);
  border-bottom: 1px solid #eaf0ea;
  font-size: 11px;
  font-weight: 500;
  color: var(--subtle);
  text-transform: uppercase;
  letter-spacing: 0.6px;
}
.ao-table-header span:nth-child(n+3) { text-align: center; }

/* ── DAY GROUPS ── */
.ao-day-group { display: none; }
.ao-day-group.active { display: block; }

/* ── HOURLY ROW ── */
.ao-row-main {
  display: grid;
  grid-template-columns: 62px 1fr 64px 64px 72px 72px 56px;
  align-items: center;
  padding: 14px 20px;
  border-bottom: 1px solid #eaf0ea;
  transition: background .15s;
  cursor: pointer;
}
.ao-row-main:last-child { border-bottom: none; }
.ao-row-main:hover { background: var(--muted-bg); }

.ao-row--now .ao-row-main {
  background: linear-gradient(90deg, rgba(45,106,79,.06) 0%, transparent 100%);
  border-left: 3px solid var(--forest-light);
  padding-left: 17px;
}
.ao-row--rain .ao-row-main {
  background: linear-gradient(90deg, rgba(74,127,181,.04) 0%, transparent 100%);
}
.ao-row--night .ao-row-main { opacity: 0.75; }

/* Row cells */
.ao-time {
  font-size: 14px;
  font-weight: 500;
  color: var(--text);
}
.ao-now-badge {
  display: inline-block;
  font-size: 10px;
  font-weight: 600;
  color: var(--forest-light);
  background: var(--foam);
  padding: 1px 7px;
  border-radius: 20px;
  letter-spacing: 0.3px;
  text-transform: uppercase;
}

.ao-desc {
  display: flex;
  align-items: center;
  gap: 10px;
}
.ao-desc-icon { width: 32px; height: 32px; flex-shrink: 0; }
.ao-desc-icon svg { width: 32px; height: 32px; }
.ao-desc-text {
  font-size: 13px;
  color: var(--subtle);
}
.ao-row--rain .ao-desc-text { color: #4a7fb5; }

.ao-temp {
  text-align: center;
  font-size: 15px;
  font-weight: 500;
  color: var(--text);
}
.ao-feels {
  text-align: center;
  font-size: 13px;
  color: var(--subtle);
}

.ao-rain {
  text-align: center;
  font-size: 13px;
  color: var(--subtle);
}
.ao-rain.has-rain {
  color: #4a7fb5;
  font-weight: 500;
}
.ao-rain-bar {
  display: block;
  height: 3px;
  background: #4a7fb5;
  border-radius: 2px;
  margin: 4px auto 0;
  max-width: 48px;
  opacity: 0.5;
}

.ao-wind {
  text-align: center;
  font-size: 12px;
  color: var(--subtle);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
}
.ao-wind-arrow {
  width: 12px;
  height: 12px;
  opacity: 0.5;
  display: inline-block;
}

.ao-hum {
  text-align: center;
  font-size: 13px;
  color: var(--subtle);
}

/* ── EXPANDABLE DETAIL ── */
.ao-row-detail {
  max-height: 0;
  overflow: hidden;
  transition: max-height .3s ease, padding .3s ease;
  background: var(--muted-bg);
  border-bottom: 1px solid #eaf0ea;
}
.ao-row.expanded .ao-row-detail {
  max-height: 200px;
  padding: 12px 20px 16px;
}
.ao-detail-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 12px;
}
.ao-detail-label {
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: var(--subtle);
  margin-bottom: 2px;
}
.ao-detail-value {
  font-size: 13px;
  font-weight: 500;
  color: var(--text);
}

/* ── UPDATE BADGE ── */
.ao-update {
  text-align: center;
  margin-top: 16px;
  font-size: 12px;
  color: var(--subtle);
}

/* ── SIDEBAR CARDS ── */
.ao-sidebar { display: flex; flex-direction: column; gap: 20px; }

.ao-sidebar-card {
  background: var(--white);
  border: 1px solid #dde5dd;
  border-radius: 14px;
  padding: 20px;
  box-shadow: 0 1px 3px rgba(42,62,45,.06);
}
.ao-sidebar-card h3 {
  font-size: 13px;
  font-weight: 600;
  color: var(--forest);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 14px;
  display: flex;
  align-items: center;
  gap: 8px;
}
.ao-sidebar-card h3 svg { width: 16px; height: 16px; stroke: var(--forest-light); }

.ao-quick-link {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 0;
  border-bottom: 1px solid #eaf0ea;
  font-size: 13px;
  color: var(--subtle);
  text-decoration: none;
  transition: color .15s;
}
.ao-quick-link:last-child { border-bottom: none; }
.ao-quick-link:hover { color: var(--forest-light); }
.ao-quick-link svg { width: 14px; height: 14px; stroke: var(--subtle); }

.ao-region-link {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 9px 0;
  border-bottom: 1px solid #eaf0ea;
  font-size: 13px;
  color: var(--subtle);
  text-decoration: none;
  transition: color .15s;
}
.ao-region-link:last-child { border-bottom: none; }
.ao-region-link:hover { color: var(--forest-light); }
.ao-region-temp {
  font-size: 12px;
  color: var(--subtle);
  display: flex;
  align-items: center;
  gap: 4px;
}

/* ── ANIMATIONS ── */
@keyframes aoFadeIn {
  from { opacity: 0; transform: translateY(6px); }
  to   { opacity: 1; transform: translateY(0); }
}
.ao-row { animation: aoFadeIn .3s ease both; }
.ao-row:nth-child(1)  { animation-delay: .02s; }
.ao-row:nth-child(2)  { animation-delay: .04s; }
.ao-row:nth-child(3)  { animation-delay: .06s; }
.ao-row:nth-child(4)  { animation-delay: .08s; }
.ao-row:nth-child(5)  { animation-delay: .10s; }
.ao-row:nth-child(6)  { animation-delay: .12s; }
.ao-row:nth-child(7)  { animation-delay: .14s; }
.ao-row:nth-child(8)  { animation-delay: .16s; }
.ao-row:nth-child(9)  { animation-delay: .18s; }
.ao-row:nth-child(10) { animation-delay: .20s; }
.ao-row:nth-child(11) { animation-delay: .22s; }
.ao-row:nth-child(12) { animation-delay: .24s; }

/* ── RESPONSIVE ── */
@media (max-width: 840px) {
  .ao-wrap {
    grid-template-columns: 1fr;
    padding: 20px 16px 40px;
  }
  .ao-table-header,
  .ao-row-main {
    grid-template-columns: 52px 1fr 50px 50px 56px;
  }
  .ao-th-feels, .ao-feels,
  .ao-th-hum, .ao-hum { display: none; }
  .ao-hero { flex-wrap: wrap; gap: 16px; padding: 18px 20px; }
  .ao-hero-details { margin-left: 0; }
  .ao-hero-degrees { font-size: 38px; }
  .ao-detail-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 480px) {
  .ao-hero { flex-direction: column; align-items: flex-start; }
  .ao-hero-details { width: 100%; }
  .ao-tab { padding: 10px 16px; font-size: 12px; }
  .ao-table-header,
  .ao-row-main {
    grid-template-columns: 48px 1fr 44px 52px;
    padding: 12px 14px;
  }
  .ao-th-rain, .ao-rain { display: none; }
}

/* ── NIGHT MODE ── */
body.is-night .ao-hero { background: rgba(255,255,255,.04); border-color: rgba(255,255,255,.08); }
body.is-night .ao-hero-degrees { color: #fff; }
body.is-night .ao-hero-condition { color: var(--amber); }
body.is-night .ao-table { background: rgba(255,255,255,.03); border-color: rgba(255,255,255,.06); }
body.is-night .ao-table-header { background: rgba(255,255,255,.04); border-color: rgba(255,255,255,.06); }
body.is-night .ao-row-main { border-color: rgba(255,255,255,.06); }
body.is-night .ao-row-main:hover { background: rgba(255,255,255,.03); }
body.is-night .ao-row-detail { background: rgba(255,255,255,.02); }
body.is-night .ao-sidebar-card { background: rgba(255,255,255,.03); border-color: rgba(255,255,255,.06); }
body.is-night .ao-tab.active { background: rgba(255,255,255,.06); color: var(--amber); border-color: rgba(255,255,255,.08); }
body.is-night .ao-tab.active::after { background: rgba(255,255,255,.03); }
