:root {
  color-scheme: dark;
  --updates-void: #0f1117;
  --updates-paper: #16181f;
  --updates-lift: #1d202a;
  --updates-rule: #303544;
  --updates-text: #eceef5;
  --updates-muted: #9da3b6;
  --updates-yellow: #f5c542;
  --updates-green: #3ecf8e;
  --updates-blue: #6c8ff5;
}

* { box-sizing: border-box; }
html { min-width: 320px; background: var(--updates-void); }
body.updates-page {
  min-height: 100vh; margin: 0; color: var(--updates-text);
  background:
    radial-gradient(circle at 88% 8%, rgba(245, 197, 66, .07), transparent 28rem),
    linear-gradient(rgba(108, 143, 245, .035) 1px, transparent 1px),
    linear-gradient(90deg, rgba(108, 143, 245, .035) 1px, transparent 1px),
    var(--updates-void);
  background-size: auto, 48px 48px, 48px 48px, auto;
  font: 400 15px/1.55 "Jost", system-ui, sans-serif;
}

.updates-masthead,
.updates-hero,
.updates-controls,
.updates-departments,
.updates-content,
.updates-footer {
  width: min(1180px, calc(100% - 44px)); margin-inline: auto;
}

.updates-masthead {
  min-height: 84px; display: flex; align-items: center; justify-content: space-between;
  gap: 24px; border-bottom: 1px solid var(--updates-rule);
}
.updates-brand { display: flex; align-items: center; gap: 12px; color: inherit; text-decoration: none; }
.updates-brand img { width: 42px; height: 42px; }
.updates-brand span { display: grid; }
.updates-brand strong { font: 700 19px/1.1 "Playfair Display", Georgia, serif; }
.updates-brand small,
.updates-nav a,
.updates-kicker,
.updates-controls label > span,
.updates-departments h2,
.updates-now span,
.updates-footer {
  color: var(--updates-muted); font-size: 11px; font-weight: 600;
  letter-spacing: .11em; text-transform: uppercase;
}
.updates-nav { display: flex; gap: 6px; }
.updates-nav a {
  min-height: 44px; display: inline-flex; align-items: center; padding: 0 12px;
  border-radius: 6px; color: var(--updates-muted); text-decoration: none;
}
.updates-nav a:hover, .updates-nav a:focus-visible { color: var(--updates-text); background: rgba(255,255,255,.04); outline: none; }
.updates-nav a[aria-current="page"] { color: var(--updates-yellow); background: rgba(245,197,66,.08); }

.updates-hero {
  display: grid; grid-template-columns: minmax(0, 1fr) 280px; gap: clamp(44px, 9vw, 128px);
  align-items: end; padding: clamp(68px, 10vw, 118px) 0 clamp(52px, 7vw, 84px);
}
.updates-kicker { margin: 0 0 14px; color: var(--updates-yellow); }
.updates-hero h1 {
  max-width: 840px; margin: 0; font: 700 clamp(48px, 8vw, 94px)/.93 "Playfair Display", Georgia, serif;
  letter-spacing: -.055em;
}
.updates-hero h1 em { color: var(--updates-yellow); font-weight: inherit; }
.updates-hero-copy > p:last-child { max-width: 650px; margin: 28px 0 0; color: #c8cbd8; font-size: clamp(17px, 2vw, 21px); }
.updates-now {
  min-height: 156px; display: grid; align-content: end; gap: 8px; padding: 24px;
  border: 1px solid rgba(245,197,66,.26); border-radius: 12px;
  background: linear-gradient(145deg, rgba(245,197,66,.12), rgba(245,197,66,.025));
}
.updates-now span { color: var(--updates-yellow); }
.updates-now strong { font: 700 28px/1.05 "Playfair Display", Georgia, serif; }
.updates-now small { color: var(--updates-muted); }

.updates-controls {
  display: grid; grid-template-columns: minmax(0, 1fr) 230px auto; gap: 12px; align-items: end;
  padding: 18px 0; border-top: 1px solid var(--updates-rule); border-bottom: 1px solid var(--updates-rule);
}
.updates-controls label { display: grid; gap: 7px; }
.updates-search input, .updates-week select {
  width: 100%; min-height: 46px; padding: 10px 13px; border: 1px solid #50566b; border-radius: 8px;
  background: var(--updates-paper); color: var(--updates-text); font: inherit;
}
.updates-search input:focus, .updates-week select:focus { outline: 3px solid rgba(245,197,66,.18); border-color: var(--updates-yellow); }
.updates-clear {
  min-height: 46px; padding: 9px 14px; border: 1px solid var(--updates-rule); border-radius: 8px;
  background: transparent; color: var(--updates-text); font: inherit; cursor: pointer;
}
.updates-clear:hover { border-color: var(--updates-yellow); color: var(--updates-yellow); }

.updates-departments { padding: 22px 0 16px; }
.updates-departments h2 { margin: 0 0 10px; }
.updates-filter-row { display: flex; gap: 7px; overflow-x: auto; padding-bottom: 5px; scrollbar-width: thin; }
.updates-filter {
  flex: 0 0 auto; min-height: 44px; padding: 7px 12px; border: 1px solid var(--updates-rule);
  border-radius: 999px; background: rgba(255,255,255,.02); color: var(--updates-muted); font: inherit;
  font-size: 12px; cursor: pointer;
}
.updates-filter:hover { color: var(--updates-text); border-color: #596075; }
.updates-filter[aria-pressed="true"] { color: #15130a; border-color: var(--updates-yellow); background: var(--updates-yellow); font-weight: 700; }

.updates-content { padding: 24px 0 86px; }
.updates-edition-head { display: flex; align-items: end; justify-content: space-between; gap: 24px; margin-bottom: 22px; }
.updates-edition-head h2 { margin: 0; font: 700 clamp(31px, 5vw, 54px)/1 "Playfair Display", Georgia, serif; letter-spacing: -.035em; }
.updates-edition-head > p { max-width: 320px; margin: 0; color: var(--updates-muted); font-size: 12px; text-align: right; }
.updates-list { display: grid; gap: 30px; }
.updates-group { display: grid; grid-template-columns: 190px minmax(0, 1fr); gap: 22px; }
.updates-group-head { position: sticky; top: 18px; align-self: start; padding-top: 2px; }
.updates-group-head h3 { margin: 0 0 5px; font: 700 23px/1.1 "Playfair Display", Georgia, serif; }
.updates-group-head span { color: var(--updates-muted); font-size: 11px; text-transform: uppercase; letter-spacing: .08em; }
.updates-cards { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.update-card {
  min-width: 0; display: grid; align-content: start; gap: 12px; padding: 19px 20px 20px;
  border: 1px solid var(--updates-rule); border-radius: 10px; background: var(--updates-paper);
  box-shadow: 0 10px 34px rgba(0,0,0,.13);
}
.update-card:hover { border-color: #4a5062; background: #181b23; }
.update-card-meta { display: flex; justify-content: space-between; gap: 12px; color: var(--updates-muted); font-size: 11px; }
.update-card-category { color: var(--updates-yellow); font-weight: 700; letter-spacing: .07em; text-transform: uppercase; }
.update-card h4 { margin: 0; font: 700 20px/1.15 "Playfair Display", Georgia, serif; letter-spacing: -.015em; }
.update-card-body { margin: 0; color: #c9ccda; white-space: pre-wrap; overflow-wrap: anywhere; }
.update-card-body a { color: #9eb6fb; text-underline-offset: 3px; }

.updates-skeleton { display: grid; grid-template-columns: repeat(2, minmax(0,1fr)); gap: 10px; margin-left: 212px; }
.updates-skeleton i { min-height: 180px; border-radius: 10px; background: linear-gradient(100deg, #16181f 20%, #20232d 45%, #16181f 70%); background-size: 300% 100%; animation: updates-shimmer 1.3s linear infinite; }
.updates-skeleton i:last-child { grid-column: 1 / -1; min-height: 110px; }
.updates-empty, .updates-error { padding: 56px 22px; border: 1px solid var(--updates-rule); border-radius: 12px; text-align: center; background: var(--updates-paper); }
.updates-empty span { color: var(--updates-yellow); font: 700 36px/1 serif; }
.updates-empty h3 { margin: 12px 0 4px; font: 700 25px/1.1 "Playfair Display", Georgia, serif; }
.updates-empty p { margin: 0; color: var(--updates-muted); }
.updates-error { display: grid; justify-items: center; gap: 7px; color: #ff8585; }
.updates-error span { color: var(--updates-muted); }
.updates-error button { min-height: 44px; margin-top: 7px; padding: 8px 16px; border: 0; border-radius: 8px; background: var(--updates-yellow); color: #15130a; font: 700 13px/1 "Jost", sans-serif; cursor: pointer; }
.updates-archive-more {
  display: flex; align-items: center; justify-content: center; gap: 16px;
  margin-top: 30px; padding: 18px; border-top: 1px solid var(--updates-rule);
  color: var(--updates-muted); text-align: center;
}
.updates-archive-more p { margin: 0; }
/* Focus lands here when the last page loads and the button leaves. */
.updates-archive-more:focus-visible { outline: 3px solid rgba(245,197,66,.18); outline-offset: 4px; border-radius: 8px; }
.updates-archive-more button {
  min-height: 44px; padding: 8px 16px; border: 1px solid #596075; border-radius: 8px;
  background: var(--updates-paper); color: var(--updates-text); font: 600 13px/1 "Jost", sans-serif;
  cursor: pointer;
}
.updates-archive-more button:hover, .updates-archive-more button:focus-visible { border-color: var(--updates-yellow); color: var(--updates-yellow); }
.updates-archive-more button:disabled { cursor: wait; opacity: .65; }

.updates-footer {
  display: flex; justify-content: space-between; gap: 22px; padding: 24px 0 30px; border-top: 1px solid var(--updates-rule);
}
.updates-footer a { color: var(--updates-text); text-decoration: none; }

@keyframes updates-shimmer { to { background-position: -300% 0; } }

@media (max-width: 820px) {
  .updates-hero { grid-template-columns: 1fr; gap: 32px; }
  .updates-now { min-height: 120px; }
  .updates-controls { grid-template-columns: minmax(0, 1fr) 190px; }
  .updates-clear { grid-column: 1 / -1; }
  .updates-group { grid-template-columns: 1fr; gap: 11px; }
  .updates-group-head { position: static; display: flex; align-items: baseline; justify-content: space-between; }
  .updates-skeleton { margin-left: 0; }
}

@media (max-width: 620px) {
  .updates-masthead, .updates-hero, .updates-controls, .updates-departments, .updates-content, .updates-footer { width: min(100% - 32px, 1180px); }
  .updates-masthead { align-items: flex-start; padding: 18px 0; }
  .updates-nav { gap: 2px; }
  .updates-nav a { min-height: 44px; padding: 0 8px; font-size: 10px; }
  .updates-brand small { display: none; }
  .updates-hero { padding: 52px 0 44px; }
  .updates-hero h1 { font-size: clamp(44px, 14vw, 64px); }
  .updates-controls { grid-template-columns: 1fr; }
  .updates-cards, .updates-skeleton { grid-template-columns: 1fr; }
  .updates-skeleton i:last-child { grid-column: auto; }
  .update-card { min-height: 0; }
  .updates-edition-head { align-items: start; flex-direction: column; }
  .updates-edition-head > p { text-align: left; }
  .updates-footer { align-items: flex-start; flex-direction: column; gap: 8px; }
  .updates-archive-more { align-items: stretch; flex-direction: column; }
}

@media (prefers-reduced-motion: reduce) { .updates-skeleton i { animation: none; } }
