@font-face {
  font-family: "VictorMonoAll";
  src: url("/fonts/VictorMonoAll/OTF/VictorMono-Regular.otf") format("opentype");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "VictorMonoAll";
  src: url("/fonts/VictorMonoAll/OTF/VictorMono-Italic.otf") format("opentype");
  font-weight: 400;
  font-style: italic;
  font-display: swap;
}

@font-face {
  font-family: "VictorMonoAll";
  src: url("/fonts/VictorMonoAll/OTF/VictorMono-SemiBold.otf") format("opentype");
  font-weight: 600;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "VictorMonoAll";
  src: url("/fonts/VictorMonoAll/OTF/VictorMono-SemiBoldItalic.otf") format("opentype");
  font-weight: 600;
  font-style: italic;
  font-display: swap;
}

@font-face {
  font-family: "VictorMonoAll";
  src: url("/fonts/VictorMonoAll/OTF/VictorMono-Bold.otf") format("opentype");
  font-weight: 700;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "VictorMonoAll";
  src: url("/fonts/VictorMonoAll/OTF/VictorMono-BoldItalic.otf") format("opentype");
  font-weight: 700;
  font-style: italic;
  font-display: swap;
}

@font-face {
  font-family: "instruction";
  src: url("/fonts/instruction/Instruction.otf") format("opentype");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "instruction";
  src: url("/fonts/instruction/Instruction Bold.otf") format("opentype");
  font-weight: 700;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "instruction";
  src: url("/fonts/instruction/Instruction Italic.otf") format("opentype");
  font-weight: 400;
  font-style: italic;
  font-display: swap;
}

@font-face {
  font-family: "instruction";
  src: url("/fonts/instruction/Instruction Bold Italic.otf") format("opentype");
  font-weight: 700;
  font-style: italic;
  font-display: swap;
}

:root {
  /* Vue Dark: deep slate base + Vue green accents (OLED friendly) */
  --bg: #0b1220;
  --panel: #0f1a2c;
  --panel2: #0c1626;
  --border: rgba(255, 255, 255, 0.085);

  --text: #e7eef9;

  /* Sub/meta text should use Vue Dark's green variant */
  --muted: rgba(66, 184, 131, 0.86);
  --muted2: rgba(66, 184, 131, 0.66);

  /* Vue brand-ish */
  --accent: #42b883;   /* Vue green */
  --accent2: #35495e;  /* Vue slate */
  --danger: #ff5c7a;

  --shadow: 0 18px 60px rgba(0, 0, 0, 0.50);
  --radius: 14px;
}

* { box-sizing: border-box; }

html, body {
  height: 100%;
}

body {
  margin: 0;
  background:
    radial-gradient(900px 700px at 20% 0%, rgba(66, 184, 131, 0.16), transparent 55%),
    radial-gradient(850px 620px at 92% 8%, rgba(53, 73, 94, 0.35), transparent 62%),
    var(--bg);
  background-repeat: no-repeat;
  background-size: cover;
  color: var(--text);
  font-family: "VictorMonoAll", ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
  line-height: 1.35;
}

a {
  color: inherit;
  text-decoration: none;
}

a:hover {
  text-decoration: underline;
  text-decoration-color: rgba(66, 184, 131, 0.78);
}

code {
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid var(--border);
  padding: 0.1rem 0.35rem;
  border-radius: 8px;
}

.masthead {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 16px;
  padding: 26px 22px 16px;
  border-bottom: 1px solid var(--border);
  background: linear-gradient(to bottom, rgba(15, 22, 35, 0.55), rgba(15, 22, 35, 0.18));
  backdrop-filter: blur(8px);
}

.brand {
  font-family: "VictorMonoAll", ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
  font-size: 40px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  line-height: 1.0;
}

.tagline {
  color: var(--muted);
  margin-top: 4px;
  font-style: italic;
}

.meta {
  border: 1px solid var(--border);
  background: rgba(13, 19, 32, 0.72);
  border-radius: var(--radius);
  padding: 10px 12px;
  box-shadow: var(--shadow);
}

.meta__row {
  display: flex;
  gap: 10px;
  align-items: baseline;
  justify-content: flex-end;
}

.meta__label {
  color: var(--muted2);
  font-size: 12px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  font-style: italic;
}

.meta__value {
  color: var(--text);
  font-size: 13px;
}

.meta__link {
  color: var(--accent);
  font-size: 13px;
}

.meta__link:hover {
  text-decoration-color: rgba(66, 184, 131, 0.78);
}

.meta__dot {
  color: var(--muted2);
}

.masonry3 {
  padding: 18px 22px 22px;
  display: grid;
  grid-template-columns: minmax(260px, 1fr) minmax(520px, 1.4fr) minmax(260px, 1fr);
  gap: 18px;
  align-items: start;
}

.center {
  min-width: 0;
}

.rail {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: rgba(13, 19, 32, 0.55);
  padding: 14px 14px 10px;
  box-shadow: var(--shadow);
}

/* Pool is only for initial render; JS will distribute sections into the 3 columns. */
.masonry3__pool {
  grid-column: 1 / -1;
  margin-top: 0;
}

/* Once packed, hide the pool to avoid duplicate content. */
.masonry3--ready .masonry3__pool {
  display: none;
}

/* On small screens we disable packing and show the pool in normal document order. */
@media (max-width: 1100px) {
  .masonry3--ready .masonry3__pool {
    display: block;
  }
}

.masonry__item {
  margin: 0 0 18px;
}

@media (max-width: 1320px) {
  .masonry3 { grid-template-columns: minmax(240px, 1fr) minmax(520px, 1.4fr) minmax(240px, 1fr); }
}

@media (max-width: 1100px) {
  /* On small screens, use a simple vertical flow.
     This avoids any grid-area/grid-column interactions with the masonry pool and ensures
     Situational Awareness (left rail) is directly under Headlines. */
  .masonry3 {
    display: flex;
    flex-direction: column;
  }

  .center { order: 1; }
  .rail--left { order: 2; }
  .rail--right { order: 3; }
  .masonry3__pool { order: 4; }

  .masthead { align-items: flex-start; flex-direction: column; }
  .meta__row { justify-content: flex-start; }
}

.section-title {
  color: var(--muted2);
  font-size: 12px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  margin: 6px 0 10px;
}

.lead__card {
  border: 1px solid var(--border);
  background: linear-gradient(180deg, rgba(15, 22, 35, 0.92), rgba(13, 19, 32, 0.86));
  border-radius: var(--radius);
  padding: 16px 16px 14px;
  box-shadow: var(--shadow);
}

.lead__kicker {
  display: flex;
  gap: 10px;
  align-items: center;
  margin-bottom: 10px;
}

.media {
  position: relative;
  display: block;
  overflow: hidden;
  border-radius: 12px;
  border: 1px solid rgba(255, 255, 255, 0.10);
  background: rgba(53, 73, 94, 0.18);
}

.media__img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transform: scale(1.02);
}

.media__shade {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    to bottom,
    rgba(11, 18, 32, 0.10),
    rgba(11, 18, 32, 0.55)
  );
}

.lead__layout {
  display: flex;
  gap: 14px;
  align-items: stretch;
}

.lead__text {
  min-width: 0;
  flex: 1 1 auto;
}

.media--lead {
  margin: 0;
  width: 42%;
  min-width: 220px;
  aspect-ratio: 4 / 3;
  flex: 0 0 auto;
}

@media (max-width: 820px) {
  .lead__layout { flex-direction: column; }
  .media--lead { width: 100%; min-width: 0; aspect-ratio: 16 / 9; }
}

.media--thumb {
  width: 120px;
  aspect-ratio: 1 / 1;
  border-radius: 14px;
  flex: 0 0 auto;
  align-self: flex-start;
}

.lead__headline {
  display: block;
  font-family: "VictorMonoAll", ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
  font-size: 30px;
  font-weight: 700;
  line-height: 1.05;
  letter-spacing: 0.01em;
}

.lead__dek {
  /* Keep descriptions/content as normal text color */
  color: var(--text);
  margin: 10px 0 8px;
  font-size: 15px;
  font-style: italic;
}

.lead__meta {
  display: flex;
  gap: 12px;
  align-items: center;
  color: var(--muted2);
  font-size: 12px;
}

.pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 10px;
  border-radius: 999px;
  background: rgba(66, 184, 131, 0.16);
  border: 1px solid rgba(66, 184, 131, 0.28);
  color: rgba(231, 238, 249, 0.94);
  font-size: 12px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.pill--thin {
  padding: 2px 8px;
  font-size: 11px;
}

.muted { color: var(--muted); }

/* Ensure common meta blocks follow the Vue Dark slate */
.lead__meta,
.toplist__meta,
.card__meta,
.footer {
  color: var(--muted2);
}

.toplist {
  margin-top: 14px;
  padding-left: 8px;
  padding-bottom: 18px;
}

.toplist__list {
  margin: 0;
  padding-left: 26px;
}

.topic {
  margin-top: 10px;
  padding: 10px 10px 0;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 12px;
  background: rgba(13, 19, 32, 0.32);
}

.topic__header {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 10px;
  padding: 0 2px 8px;
}

.topic__name {
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: rgba(231, 238, 249, 0.92);
}

.topic__count {
  font-size: 12px;
  color: var(--muted2);
  font-style: italic;
}

.topic .toplist__list {
  padding-left: 22px;
}

.toplist__item {
  padding: 10px 0;
  border-bottom: 1px dashed rgba(255, 255, 255, 0.10);
}

.toplist__item:last-child {
  border-bottom: none;
  padding-bottom: 16px;
}

.toplist__item a {
  font-family: "VictorMonoAll", ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
  font-size: 17px;
  font-weight: 600;
  letter-spacing: 0.005em;
}

.toplist__meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 6px;
  font-size: 12px;
  color: var(--muted2);
}


.section {
  margin-bottom: 16px;
}

.section__header {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 12px;
  margin-bottom: 10px;
}

.section__name {
  font-family: "VictorMonoAll", ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
  font-size: 17px;
  font-weight: 700;
  letter-spacing: 0.10em;
  text-transform: uppercase;
  color: rgba(231, 237, 246, 0.92);
}

.section__link {
  color: var(--accent);
  font-size: 12px;
}

.section__hint {
  color: var(--muted2);
  font-size: 12px;
  font-style: italic;
}

.section--sa {
  margin-bottom: 14px;
  padding-left: 0;
  padding-bottom: 10px;
  border-bottom: 1px dashed rgba(255, 255, 255, 0.10);
}

.section--research {
  margin-top: 14px;
}

.research-list .sa-item__link {
  font-size: 13px;
}

.sa-block {
  margin-top: 10px;
}

.sa-block__title {
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: rgba(231, 238, 249, 0.92);
  margin: 6px 0 8px;
}

.sa-list {
  margin: 0;
  padding-left: 28px;
}

.sa-item {
  padding: 8px 0;
  border-bottom: 1px dashed rgba(255, 255, 255, 0.10);
}

.sa-item:last-child {
  border-bottom: none;
}

.sa-item__link {
  display: inline-block;
  font-weight: 600;
}

.sa-item__meta {
  margin-top: 6px;
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  font-size: 12px;
}

.cards {
  display: grid;
  grid-template-columns: 1fr;
  gap: 10px;
}

.card {
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 12px;
  background: linear-gradient(180deg, rgba(15, 22, 35, 0.75), rgba(13, 19, 32, 0.70));
  padding: 12px 12px 10px;
}

.card__top {
  display: flex;
  gap: 12px;
  align-items: flex-start;
}

/* When a card has a thumbnail, wrap text around it (newspaper-style). */
.card--with-image .card__top {
  display: block;
}

.card--with-image .card__top::after {
  content: "";
  display: block;
  clear: both;
}

.card--with-image .media--thumb {
  float: right;
  margin: 2px 0 10px 12px;
  width: 140px;
  aspect-ratio: 1 / 1;
}

/* Let inline text (headline/meta/summary) flow around the float and then expand full width below it. */
.card--with-image .card__text {
  display: contents;
}

.card--with-image .card__meta {
  margin-top: 6px;
}

.card--with-image .card__dek {
  margin-top: 8px;
}

@media (max-width: 520px) {
  .card--with-image .media--thumb {
    width: 108px;
  }
}

.card__text {
  min-width: 0;
  flex: 1 1 auto;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.card__headline {
  display: block;
  font-family: "VictorMonoAll", ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
  font-size: 15px;
  font-weight: 600;
  letter-spacing: 0.005em;
  line-height: 1.10;
}

@media (max-width: 520px) {
  .media--thumb { width: 92px; }
}

.card__meta {
  margin-top: 2px;
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  font-size: 12px;
}

.card__dek {
  /* Keep descriptions/content as normal text color */
  margin: 0;
  color: var(--text);
  font-size: 13px;
  font-style: italic;
}

.empty {
  border: 1px dashed rgba(255, 255, 255, 0.18);
  border-radius: var(--radius);
  padding: 14px;
  background: rgba(15, 22, 35, 0.40);
  color: var(--muted);
}

.footer {
  padding: 10px 22px 24px;
  color: var(--muted2);
}

.footer__row {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  border-top: 1px solid var(--border);
  padding-top: 12px;
}
