/* Voltropa: the tech side of Europe. One stylesheet, no framework, no inline
   styles (the CSP blocks them).
   Brand: black #0A0A0A, white, turquoise #00C2A8; League Spartan (OFL).

   One rule on every page: one big, two medium, the rest small.
   Front page: the lead post (big), two posts (medium), then the headlines
   (small). Section pages: the top story (big), two stories (medium), then the
   list (small). Structure comes from type, space and hairlines, not boxes. */

@font-face {
  font-family: "League Spartan";
  src: url("/fonts/league-spartan-400.woff2") format("woff2");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "League Spartan";
  src: url("/fonts/league-spartan-700.woff2") format("woff2");
  font-weight: 700;
  font-style: normal;
  font-display: swap;
}

:root {
  --ink: #0a0a0a;
  --white: #ffffff;
  --text: #f2f2f0;
  --soft: #c4c4c0;
  --muted: #8e8e8a;
  --accent: #00c2a8;
  --accent-hover: #3cd6c0;
  --line: rgba(255, 255, 255, 0.1);
  --line-strong: rgba(255, 255, 255, 0.22);
  --wrap: 1280px;
  --gutter: clamp(20px, 4vw, 48px);
  --radius: 10px;
  --header: 64px;
  --ease: cubic-bezier(0.2, 0.7, 0.2, 1);
  color-scheme: dark;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
  background: var(--ink);
  scroll-padding-top: calc(var(--header) + 20px);
  scrollbar-color: #2a2a2a var(--ink);
}

@media (prefers-reduced-motion: no-preference) {
  html {
    scroll-behavior: smooth;
  }
}

body {
  margin: 0;
  min-height: 100vh;
  min-height: 100svh;
  display: flex;
  flex-direction: column;
  background: var(--ink);
  color: var(--text);
  font-family: "League Spartan", system-ui, -apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  font-size: 1.0625rem;
  line-height: 1.5;
  font-kerning: normal;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

main {
  flex: 1;
}

a {
  color: inherit;
}

::selection {
  background: var(--accent);
  color: var(--ink);
}

:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
}

h1,
h2,
h3 {
  color: var(--white);
  text-wrap: balance;
}

p {
  text-wrap: pretty;
}

.wrap {
  width: min(100% - 2 * var(--gutter), var(--wrap));
  margin-inline: auto;
}

.kw {
  color: var(--accent);
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
  border: 0;
}

.icon {
  flex: none;
  width: 20px;
  height: 20px;
}

.arrow {
  flex: none;
  width: 0.95em;
  height: 0.95em;
  vertical-align: -0.08em;
}

/* ── buttons ─────────────────────────────────────────────── */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 46px;
  padding: 0.14em 24px 0;
  border: 0;
  border-radius: 999px;
  font: inherit;
  font-size: 0.9375rem;
  font-weight: 700;
  line-height: 1;
  text-decoration: none;
  white-space: nowrap;
  cursor: pointer;
  transition: background-color 0.18s ease, color 0.18s ease, box-shadow 0.18s ease;
}

.btn-sm {
  min-height: 36px;
  padding-inline: 18px;
  font-size: 0.875rem;
}

.btn-block {
  width: 100%;
}

.btn-accent {
  background: var(--accent);
  color: var(--ink);
}

.btn-accent:hover {
  background: var(--accent-hover);
}

.btn-light {
  background: var(--white);
  color: var(--ink);
}

.btn-light:hover {
  background: #dcdcd8;
}

.btn-quiet {
  background: transparent;
  box-shadow: inset 0 0 0 1px var(--line-strong);
  color: var(--white);
}

.btn-quiet:hover {
  box-shadow: inset 0 0 0 1px var(--white);
}

.kicker {
  margin: 0 0 14px;
  color: var(--muted);
  font-size: 0.9375rem;
  font-weight: 700;
}

/* ── header ─────────────────────────────────────────────── */

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  border-bottom: 1px solid var(--line);
  background: rgba(10, 10, 10, 0.8);
  -webkit-backdrop-filter: saturate(150%) blur(16px);
  backdrop-filter: saturate(150%) blur(16px);
}

.header-row {
  display: flex;
  align-items: center;
  gap: 36px;
  height: var(--header);
}

.brand {
  display: inline-flex;
  border-radius: 6px;
  color: var(--white);
}

.wordmark {
  display: block;
  height: auto;
}

.brand .wordmark {
  width: 116px;
}

.nav {
  display: flex;
  align-self: stretch;
  gap: 30px;
}

.nav a {
  position: relative;
  display: flex;
  align-items: center;
  color: var(--soft);
  font-size: 0.9375rem;
  text-decoration: none;
  white-space: nowrap;
  transition: color 0.15s ease;
}

.nav a:hover,
.nav a[aria-current="page"] {
  color: var(--white);
}

/* the current section: a turquoise line on the header's bottom edge */
.nav a[aria-current="page"]::after {
  content: "";
  position: absolute;
  right: 0;
  bottom: -1px;
  left: 0;
  height: 2px;
  background: var(--accent);
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-left: auto;
}

.social-mini {
  display: flex;
  gap: 2px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.social-mini a {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border-radius: 999px;
  color: var(--muted);
  transition: color 0.15s ease;
}

.social-mini a:hover {
  color: var(--white);
}

.social-mini .icon {
  width: 17px;
  height: 17px;
}

@media (max-width: 1040px) {
  .social-mini {
    display: none;
  }
}

@media (max-width: 760px) {
  .header-row {
    flex-wrap: wrap;
    gap: 0 16px;
    height: auto;
    padding-top: 12px;
  }

  .nav {
    order: 3;
    width: calc(100% + 2 * var(--gutter));
    height: 44px;
    margin: 6px calc(-1 * var(--gutter)) 0;
    padding: 0 var(--gutter);
    gap: 24px;
    overflow-x: auto;
    scrollbar-width: none;
  }

  .nav::-webkit-scrollbar {
    display: none;
  }
}

/* ── masthead (front page and section pages) ────────────── */

.masthead {
  padding-block: clamp(36px, 5.4vw, 80px) clamp(28px, 3.4vw, 48px);
}

.dateline {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px 14px;
  margin: 0 0 clamp(14px, 1.8vw, 22px);
  color: var(--muted);
  font-size: 0.9375rem;
}

.live {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--text);
  font-weight: 700;
}

.dateline-sep {
  width: 4px;
  height: 4px;
  border-radius: 999px;
  background: var(--line-strong);
}

.masthead-title {
  margin: 0;
  font-size: clamp(2.75rem, 1rem + 6.2vw, 7rem);
  font-weight: 700;
  line-height: 0.93;
  letter-spacing: -0.045em;
}

.section-intro {
  max-width: 54ch;
  margin: clamp(18px, 2vw, 26px) 0 0;
  color: var(--soft);
  font-size: clamp(1.125rem, 1rem + 0.5vw, 1.375rem);
  line-height: 1.45;
}

.pulse {
  position: relative;
  width: 8px;
  height: 8px;
  border-radius: 999px;
  background: var(--accent);
}

.pulse::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: 999px;
  background: var(--accent);
  opacity: 0;
}

@media (prefers-reduced-motion: no-preference) {
  .pulse::after {
    animation: pulse 2.4s ease-out infinite;
  }
}

@keyframes pulse {
  from {
    opacity: 0.6;
    transform: scale(1);
  }
  to {
    opacity: 0;
    transform: scale(3);
  }
}

/* ── hero (front page): the title and the live map ──────── */

/* The map is the page's one moving picture: a dotted Europe (the EU a step
   brighter), the places in this week's stories pulsing in turquoise, a few
   dots flickering like current. The title rises line by line once. */
.hero {
  position: relative;
  overflow: hidden;
}

.hero-inner {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  min-height: clamp(440px, 41vw, 600px);
  padding-block: clamp(36px, 4.4vw, 64px);
  pointer-events: none; /* the map behind the text stays clickable */
}

.hero-copy {
  max-width: 600px;
  pointer-events: auto;
}

.hero-title {
  margin: 0;
  font-size: clamp(3rem, 1.1rem + 6vw, 6.5rem);
  font-weight: 700;
  line-height: 0.92;
  letter-spacing: -0.045em;
}

.hero-title .ln {
  display: block;
  overflow: hidden;
  /* room inside the clip for the descender of the p */
  padding-bottom: 0.12em;
  margin-bottom: -0.12em;
}

.hero-title .ln > span {
  display: inline-block;
}

.hero-lede {
  max-width: 34ch;
  margin: clamp(20px, 2.2vw, 30px) 0 0;
  color: var(--soft);
  font-size: clamp(1.125rem, 1rem + 0.45vw, 1.375rem);
  line-height: 1.45;
}

.hero-note {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 4px 10px;
  margin: 22px 0 0;
  color: var(--muted);
  font-size: 0.9375rem;
}

.hero-note:empty {
  display: none;
}

.hero-note strong {
  color: var(--text);
  font-weight: 700;
}

.hero-map {
  position: absolute;
  z-index: 0;
  top: 50%;
  right: max(0px, calc((100% - var(--wrap)) / 2 - 64px));
  width: min(54%, 740px);
  transform: translateY(-50%);
  -webkit-mask-image: linear-gradient(to bottom, transparent 0, #000 13%, #000 78%, transparent 100%);
  mask-image: linear-gradient(to bottom, transparent 0, #000 13%, #000 78%, transparent 100%);
}

.emap {
  display: block;
  width: 100%;
  height: auto;
  overflow: visible;
}

.emap-eu,
.emap-eur {
  fill: none;
  stroke: #fff;
  stroke-linecap: round;
  stroke-width: 8.2;
}

.emap-eu {
  stroke-opacity: 0.34;
}

.emap-eur {
  stroke-opacity: 0.15;
}

.tw {
  fill: var(--accent);
  opacity: 0;
}

.pin {
  cursor: pointer;
}

.pin-dot,
.pin-ring {
  transform-box: fill-box;
  transform-origin: center;
}

.pin-dot {
  fill: var(--accent);
  transition: fill 0.2s ease;
}

.pin-ring {
  fill: none;
  stroke: var(--accent);
  stroke-width: 2.5;
  opacity: 0;
}

.pin-label {
  fill: #fff;
  fill-opacity: 0.85;
  font-size: 26px;
  font-weight: 700;
  letter-spacing: -0.01em;
  paint-order: stroke;
  stroke: var(--ink);
  stroke-width: 7px;
  stroke-linejoin: round;
  transition: fill-opacity 0.2s ease;
}

.pin:hover .pin-dot {
  fill: var(--white);
}

.pin:hover .pin-label {
  fill-opacity: 1;
}

/* between tablet and desktop the text needs the room: a narrower map */
@media (min-width: 900px) and (max-width: 1099px) {
  .hero-map {
    width: 50%;
  }

  .hero-lede {
    max-width: 30ch;
  }
}

@media (max-width: 899px) {
  .hero {
    display: flex;
    flex-direction: column;
  }

  .hero-inner {
    order: 1;
    min-height: 0;
    padding-bottom: 12px;
  }

  .hero-map {
    order: 2;
    position: relative;
    top: auto;
    right: auto;
    width: calc(100% - 2 * var(--gutter));
    max-width: 640px;
    margin: 0 auto;
    transform: none;
    -webkit-mask-image: none;
    mask-image: none;
  }

  .pin-label {
    display: none;
  }

  /* the map is drawn smaller here; the pins stay big enough to see */
  .pin-dot,
  .pin-ring {
    scale: 2;
  }
}

@media (prefers-reduced-motion: no-preference) {
  .hero-title .ln > span {
    animation: lineup 1s var(--ease) backwards;
  }

  .hero-title .ln + .ln > span {
    animation-delay: 0.08s;
  }

  .hero-copy > :not(.hero-title) {
    animation: rise 0.8s var(--ease) 0.25s backwards;
  }

  .led {
    animation: led 3.2s ease-in-out 1.4s infinite;
  }

  .emap {
    animation: mapin 1.6s var(--ease) 0.1s backwards;
  }

  .tw {
    animation: twinkle 6s ease-in-out infinite;
  }

  .tw:nth-child(3n) {
    animation-duration: 7.6s;
  }

  .tw:nth-child(4n + 1) {
    animation-duration: 5.1s;
  }

  .t1 { animation-delay: -0.9s; }
  .t2 { animation-delay: -1.8s; }
  .t3 { animation-delay: -2.7s; }
  .t4 { animation-delay: -3.6s; }
  .t5 { animation-delay: -4.5s; }
  .t6 { animation-delay: -5.4s; }

  .pin-dot {
    animation: pinin 0.7s var(--ease) 0.5s backwards;
  }

  .pin-ring {
    animation: ring 3.2s ease-out 1s infinite;
  }

  .pd1 .pin-dot { animation-delay: 0.6s; }
  .pd2 .pin-dot { animation-delay: 0.7s; }
  .pd3 .pin-dot { animation-delay: 0.8s; }
  .pd4 .pin-dot { animation-delay: 0.9s; }
  .pd5 .pin-dot { animation-delay: 1s; }

  .pd1 .pin-ring { animation-delay: 1.5s; }
  .pd2 .pin-ring { animation-delay: 2s; }
  .pd3 .pin-ring { animation-delay: 2.6s; }
  .pd4 .pin-ring { animation-delay: 3.1s; }
  .pd5 .pin-ring { animation-delay: 3.7s; }
}

@keyframes lineup {
  from {
    transform: translateY(105%);
  }
}

@keyframes mapin {
  from {
    opacity: 0;
    transform: scale(0.97);
  }
}

@keyframes twinkle {
  0%,
  100% {
    opacity: 0;
  }
  50% {
    opacity: 0.9;
  }
}

@keyframes pinin {
  from {
    opacity: 0;
    transform: scale(0);
  }
}

@keyframes ring {
  0% {
    opacity: 0.75;
    transform: scale(1);
  }
  100% {
    opacity: 0;
    transform: scale(3.4);
  }
}

@keyframes led {
  0%,
  100% {
    text-shadow: none;
  }
  50% {
    text-shadow: 0 0 18px rgba(0, 194, 168, 0.9), 0 0 3px rgba(0, 194, 168, 0.9);
  }
}

/* ── front page: big + two medium + the latest headlines ── */

/* Each column keeps its own height, so no image is ever stretched or cropped.
   The big post and the two stacked medium ones line up because their widths
   are in a 2.07 : 1 ratio (two 4:5 posts + a 20px gap ≈ one 4:5 post). */
.front {
  display: grid;
  gap: 24px;
  align-items: start;
  margin-top: clamp(28px, 4vw, 56px);
}

.med-stack {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

@media (min-width: 700px) {
  .front {
    grid-template-columns: minmax(0, 2.07fr) minmax(0, 1fr);
    gap: 20px;
  }

  .med-stack {
    grid-template-columns: minmax(0, 1fr);
    gap: 20px;
  }

  .latest {
    grid-column: 1 / -1;
    margin-top: 36px;
  }
}

/* three columns; the posts sit 20px apart, the headlines 44px away */
@media (min-width: 1100px) {
  .front {
    grid-template-columns: minmax(0, 2.07fr) 20px minmax(0, 1fr) 44px minmax(0, 1.9fr);
    column-gap: 0;
  }

  .card-big {
    grid-column: 1;
  }

  .med-stack {
    grid-column: 3;
  }

  .latest {
    grid-column: 5;
    margin-top: 0;
  }
}

.card {
  position: relative;
  display: block;
  overflow: hidden;
  border-radius: var(--radius);
  background: #111;
  isolation: isolate;
}

/* a hairline over the image, so dark posts keep an edge on the black page */
.card::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.09);
  pointer-events: none;
}

.card picture {
  display: block;
}

.card img {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 4 / 5;
  transition: transform 0.9s var(--ease);
}

.card:hover img {
  transform: scale(1.035);
}

.card-go {
  position: absolute;
  top: 14px;
  right: 14px;
  z-index: 1;
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  border-radius: 999px;
  background: var(--white);
  color: var(--ink);
  opacity: 0;
  transform: translateY(4px) scale(0.9);
  transition: opacity 0.25s ease, transform 0.4s var(--ease);
}

.card-go .arrow {
  width: 18px;
  height: 18px;
}

.card-med .card-go {
  top: 10px;
  right: 10px;
  width: 32px;
  height: 32px;
}

.card-med .card-go .arrow {
  width: 15px;
  height: 15px;
}

.card:hover .card-go,
.card:focus-visible .card-go {
  opacity: 1;
  transform: none;
}

/* ── the three live cards: the story's picture, the headline over it ─── */

.card-news {
  color: var(--white);
  text-decoration: none;
}

.card-news .pic {
  aspect-ratio: 4 / 5;
  border-radius: 0;
}

.card-news .pic img {
  aspect-ratio: auto;
  height: 100%;
}

/* dark at the bottom, so the headline reads on any picture */
.card-news .pic::after {
  box-shadow: none;
  background: linear-gradient(to bottom, rgba(0, 0, 0, 0.35) 0%, transparent 26%, transparent 42%, rgba(0, 0, 0, 0.88) 100%);
}

.card-news .pic-tile {
  place-items: start start;
  padding: 18% 9%;
}

.card-chip {
  position: absolute;
  top: 14px;
  left: 14px;
  z-index: 1;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 5px 11px 5px 9px;
  border-radius: 999px;
  background: rgba(10, 10, 10, 0.72);
  font-size: 0.8125rem;
  font-weight: 700;
}

.card-dot {
  width: 7px;
  height: 7px;
  border-radius: 999px;
  background: var(--accent);
}

.card-text {
  position: absolute;
  inset: auto 0 0;
  z-index: 1;
  display: grid;
  gap: 10px;
  padding: clamp(18px, 2.4vw, 30px);
}

.card-title {
  font-size: clamp(1.5rem, 1rem + 1.6vw, 2.25rem);
  font-weight: 700;
  line-height: 1.06;
  letter-spacing: -0.03em;
  text-wrap: balance;
}

.card-source {
  color: rgba(255, 255, 255, 0.72);
  font-size: 0.8125rem;
  font-variant-numeric: tabular-nums;
}

.card-med .card-chip {
  top: 10px;
  left: 10px;
  padding: 4px 9px 4px 8px;
  font-size: 0.75rem;
}

.card-med .card-text {
  gap: 7px;
  padding: 14px;
}

.card-med .card-title {
  font-size: clamp(1rem, 0.85rem + 0.5vw, 1.1875rem);
  line-height: 1.15;
  letter-spacing: -0.015em;
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 4;
  overflow: hidden;
}

.card-med .card-source {
  font-size: 0.75rem;
}

/* on a phone the two medium cards sit side by side: smaller headline */
@media (max-width: 699px) {
  .card-med .card-title {
    font-size: 0.875rem;
    -webkit-line-clamp: 4;
  }

  .card-med .card-text {
    padding: 12px;
  }

  .card-med .pic::after {
    background: linear-gradient(to bottom, transparent 30%, rgba(0, 0, 0, 0.92) 100%);
  }

  .card-med .card-chip {
    display: none;
  }
}

.card-news:hover .card-title {
  text-decoration: underline;
  text-decoration-color: var(--accent);
  text-decoration-thickness: 2px;
  text-underline-offset: 4px;
}

/* ── headlines (small) ───────────────────────────────────── */

.latest,
.section-main {
  min-width: 0;
}

.latest-head {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 4px 16px;
  padding-bottom: 14px;
  border-bottom: 1px solid var(--line-strong);
}

.latest-head h2 {
  margin: 0;
  font-size: 1.125rem;
  font-weight: 700;
  letter-spacing: -0.01em;
}

.live-meta {
  margin: 0;
  color: var(--muted);
  font-size: 0.8125rem;
  font-variant-numeric: tabular-nums;
}

.wire {
  margin: 0;
  padding: 0;
  list-style: none;
}

.wire li {
  padding: 13px 0 14px;
  border-bottom: 1px solid var(--line);
}

/* ── pictures ────────────────────────────────────────────── */

/* The newsroom's picture over a drawn tile: the tile (the topic's name on
   the map's dot grid) shows while the picture loads, when a story has none,
   and when the newsroom's server refuses it. */
.pic {
  position: relative;
  display: block;
  overflow: hidden;
  border-radius: 8px;
  background: #151716;
  isolation: isolate;
}

.pic::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.08);
  pointer-events: none;
}

.pic img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.9s var(--ease);
}

.pic-tile {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: end start;
  padding: 10%;
  background:
    radial-gradient(circle at 1px 1px, rgba(255, 255, 255, 0.13) 1px, transparent 1.6px) 0 0 / 9px 9px,
    radial-gradient(120% 90% at var(--tx, 85%) var(--ty, 10%), var(--tc, rgba(0, 194, 168, 0.32)), transparent 70%),
    #121413;
  color: var(--white);
  font-weight: 700;
  line-height: 0.95;
  letter-spacing: -0.03em;
}

.pic-tile > span {
  font-size: clamp(1.25rem, 0.8rem + 1.6vw, 2.25rem);
}

.pic-thumb .pic-tile {
  padding: 9px;
}

.pic-thumb .pic-tile > span {
  font-size: 0.8125rem;
  letter-spacing: -0.01em;
}

/* one light per topic, so a run of tiles does not look like one repeated picture */
.t-rules { --tx: 15%; --ty: 0%; --tc: rgba(0, 194, 168, 0.3); }
.t-security { --tx: 90%; --ty: 90%; --tc: rgba(255, 92, 92, 0.26); }
.t-ai { --tx: 80%; --ty: 5%; --tc: rgba(0, 194, 168, 0.4); }
.t-chips { --tx: 10%; --ty: 95%; --tc: rgba(120, 140, 255, 0.28); }
.t-space { --tx: 50%; --ty: 0%; --tc: rgba(150, 110, 255, 0.3); }
.t-startups { --tx: 95%; --ty: 30%; --tc: rgba(255, 196, 80, 0.24); }
.t-gadgets { --tx: 30%; --ty: 100%; --tc: rgba(0, 194, 168, 0.24); }
.t-tech { --tx: 70%; --ty: 70%; --tc: rgba(255, 255, 255, 0.12); }

a:hover > .pic img,
.row:hover .pic img,
.lead:hover .pic img,
.story:hover .pic img {
  transform: scale(1.04);
}

.pic-thumb {
  aspect-ratio: 3 / 2;
}

.pic-lead,
.pic-big,
.pic-med {
  aspect-ratio: 16 / 9;
}

/* a headline row: thumbnail left, headline and source right */
.row {
  display: grid;
  grid-template-columns: 112px minmax(0, 1fr);
  gap: 16px;
  align-items: start;
}

.row-pic {
  display: block;
}

.row-body {
  min-width: 0;
}

/* the newest story of a section column: picture on top, headline below */
.lead {
  padding: 18px 0 16px;
  border-bottom: 1px solid var(--line);
}

.lead-pic {
  display: block;
  margin-bottom: 14px;
}

.index-col .lead-title {
  font-size: 1.1875rem;
  font-weight: 700;
  line-height: 1.22;
  letter-spacing: -0.012em;
}

/* Next to the posts the list ends where they end: any spare height is shared
   out evenly below each headline, so the two columns close on one line. */
@media (min-width: 1100px) {
  .latest {
    display: flex;
    flex-direction: column;
    align-self: stretch;
  }

  .latest .wire-latest {
    display: flex;
    flex: 1;
    flex-direction: column;
  }

  .latest .wire-latest li {
    flex: 1 1 auto;
  }

  .latest .wire-latest li:nth-child(5) {
    border-bottom: 0;
  }

  /* five rows fill the posts' height; the sixth is for the narrower layouts */
  .latest .wire-latest li:nth-child(n + 6) {
    display: none;
  }
}

/* full width under the posts: two columns of rows */
@media (min-width: 700px) and (max-width: 1099px) {
  .latest .wire-latest {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    column-gap: 36px;
  }
}

/* on a phone the newest story opens big, the rest follow as rows */
@media (max-width: 699px) {
  .latest .wire-latest li:first-child {
    grid-template-columns: minmax(0, 1fr);
    gap: 14px;
  }

  .latest .wire-latest li:first-child .pic {
    aspect-ratio: 16 / 9;
  }

  .latest .wire-latest li:first-child .w-title {
    font-size: 1.3125rem;
    font-weight: 700;
    line-height: 1.2;
    letter-spacing: -0.015em;
  }

  .latest .wire-latest li:first-child .pic-tile {
    padding: 7%;
  }

  .latest .wire-latest li:first-child .pic-tile > span {
    font-size: 2rem;
  }

  .row {
    grid-template-columns: 96px minmax(0, 1fr);
    gap: 14px;
  }

  .w-title {
    font-size: 1rem;
  }
}

.w-title,
.s-title {
  color: var(--white);
  text-decoration: none;
  text-wrap: pretty;
  background-image: linear-gradient(var(--accent), var(--accent));
  background-position: 0 100%;
  background-repeat: no-repeat;
  background-size: 0 1.5px;
  transition: background-size 0.25s var(--ease);
}

.w-title:hover,
.s-title:hover {
  background-size: 100% 1.5px;
}

.w-title {
  font-size: 1.0625rem;
  line-height: 1.38;
}

.w-meta {
  margin: 6px 0 0;
  color: var(--muted);
  font-size: 0.8125rem;
  font-variant-numeric: tabular-nums;
}

.w-topic {
  color: var(--accent);
  font-weight: 700;
}

.live-empty {
  margin: 16px 0 0;
  color: var(--muted);
  font-size: 0.8125rem;
}

.live-empty strong {
  color: var(--white);
}

/* ── across Europe: one column per section (small) ───────── */

.index {
  padding-top: clamp(80px, 9vw, 136px);
}

.block-title {
  margin: 0 0 clamp(24px, 3vw, 40px);
  font-size: clamp(2.25rem, 1.2rem + 3vw, 4rem);
  font-weight: 700;
  line-height: 0.95;
  letter-spacing: -0.04em;
}

.index-cols {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  border-top: 1px solid var(--line-strong);
}

.index-col {
  display: flex;
  flex-direction: column;
  min-width: 0;
  padding: 26px 26px 0;
  border-left: 1px solid var(--line);
}

.index-col:first-child {
  padding-left: 0;
  border-left: 0;
}

.index-col:last-child {
  padding-right: 0;
}

.index-col h3 {
  margin: 0 0 6px;
  font-size: 1.625rem;
  font-weight: 700;
  line-height: 1;
  letter-spacing: -0.025em;
}

.index-col h3 a {
  text-decoration: none;
}

.index-col h3 a:hover {
  color: var(--accent);
}

.index-col .wire li {
  padding: 13px 0 14px;
}

.index-col .wire li:last-child {
  border-bottom: 0;
}

.index-col .w-title {
  font-size: 0.96875rem;
}

.index-col .row {
  grid-template-columns: 76px minmax(0, 1fr);
  gap: 12px;
}

.index-col .pic-thumb {
  aspect-ratio: 1;
}

.index-col .pic-thumb .pic-tile > span {
  font-size: 0.6875rem;
}

.more-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  align-self: flex-start;
  margin-top: auto;
  padding: 14px 0 2px;
  color: var(--accent);
  font-size: 0.9375rem;
  font-weight: 700;
  text-decoration: none;
}

.more-link .arrow {
  transition: transform 0.25s var(--ease);
}

.more-link:hover .arrow {
  transform: translateX(3px);
}

@media (max-width: 1099px) {
  .index-cols {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .index-col:nth-child(odd) {
    padding-left: 0;
    border-left: 0;
  }

  .index-col:nth-child(even) {
    padding-right: 0;
  }

  .index-col:nth-child(n + 3) {
    margin-top: 28px;
    border-top: 1px solid var(--line-strong);
  }
}

@media (max-width: 640px) {
  .index-cols {
    grid-template-columns: minmax(0, 1fr);
  }

  .index-col {
    padding: 22px 0 0;
    border-left: 0;
  }

  .index-col + .index-col {
    margin-top: 28px;
    border-top: 1px solid var(--line-strong);
  }
}

/* ── newsletter ─────────────────────────────────────────── */

.newsletter {
  margin-top: clamp(88px, 10vw, 152px);
  border-block: 1px solid var(--line);
}

.nl-inner {
  display: grid;
  align-items: end;
  gap: 32px 80px;
  padding-block: clamp(52px, 6.4vw, 96px);
}

@media (min-width: 980px) {
  .nl-inner {
    grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr);
  }
}

.nl-title {
  margin: 0;
  font-size: clamp(2.25rem, 1.2rem + 3vw, 4rem);
  font-weight: 700;
  line-height: 0.95;
  letter-spacing: -0.04em;
}

.nl-text {
  max-width: 40ch;
  margin: 18px 0 0;
  color: var(--soft);
  font-size: 1.125rem;
}

.nl-form {
  min-width: 0;
}

.nl-field {
  display: flex;
  gap: 8px;
  padding: 6px;
  border-radius: 999px;
  background: #121212;
  box-shadow: inset 0 0 0 1px var(--line-strong);
  transition: box-shadow 0.18s ease;
}

.nl-field:focus-within {
  box-shadow: inset 0 0 0 1px var(--accent);
}

.nl-field input {
  flex: 1;
  min-width: 0;
  padding: 0.12em 18px 0;
  border: 0;
  background: transparent;
  color: var(--white);
  font: inherit;
  font-size: 1.0625rem;
  outline: none;
}

.nl-field input::placeholder {
  color: var(--muted);
  opacity: 1;
}

.nl-field .btn {
  min-height: 48px;
}

.nl-legal {
  margin: 14px 0 0;
  padding-left: 22px;
  color: var(--muted);
  font-size: 0.8125rem;
}

.nl-legal a {
  color: var(--soft);
  text-underline-offset: 3px;
}

.nl-legal a:hover {
  color: var(--white);
}

/* the field only bots fill in */
.hp {
  position: absolute;
  left: -10000px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

@media (max-width: 480px) {
  .nl-field {
    flex-direction: column;
    border-radius: 18px;
  }

  .nl-field input {
    min-height: 48px;
  }

  .nl-legal {
    padding-left: 0;
  }
}

/* ── why Voltropa ────────────────────────────────────────── */

.why {
  display: grid;
  align-items: center;
  gap: 40px 80px;
  padding-block: clamp(88px, 10vw, 152px) 0;
}

@media (min-width: 960px) {
  .why {
    grid-template-columns: minmax(0, 5fr) minmax(0, 7fr);
  }
}

.why-figure {
  max-width: 520px;
  margin: 0;
}

.why-figure img {
  display: block;
  width: 100%;
  height: auto;
  border-radius: var(--radius);
}

/* On phones the full 4:5 engraving fills the screen; a square crop keeps the
   head and collar and halves the scroll. */
@media (max-width: 639px) {
  .why-figure img {
    aspect-ratio: 1;
    object-fit: cover;
    object-position: 50% 22%;
  }
}

.why-figure figcaption {
  margin-top: 12px;
  color: var(--muted);
  font-size: 0.8125rem;
}

.why-copy {
  min-width: 0;
}

.why-title {
  margin: 0;
  font-size: clamp(2.25rem, 1.1rem + 3.6vw, 4.5rem);
  font-weight: 700;
  line-height: 0.95;
  letter-spacing: -0.04em;
}

.why-copy > p:not(.kicker) {
  max-width: 48ch;
  margin: 20px 0 0;
  color: var(--soft);
  font-size: 1.125rem;
  line-height: 1.55;
}

.why-copy > .why-lede {
  margin-top: 28px;
  color: var(--text);
  font-size: clamp(1.1875rem, 1.05rem + 0.45vw, 1.375rem);
  line-height: 1.45;
}

.principles {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  margin: 40px 0 0;
  padding: 0;
  list-style: none;
  border-top: 1px solid var(--line-strong);
  counter-reset: principle;
}

.principles li {
  counter-increment: principle;
  display: flex;
  align-items: baseline;
  gap: 14px;
  padding: 18px 16px 18px 0;
  border-bottom: 1px solid var(--line);
  color: var(--white);
  font-size: 1.125rem;
  font-weight: 700;
  letter-spacing: -0.01em;
}

.principles li::before {
  content: counter(principle, decimal-leading-zero);
  color: var(--muted);
  font-size: 0.8125rem;
  font-variant-numeric: tabular-nums;
}

.principles li:nth-child(even) {
  padding-left: 20px;
  border-left: 1px solid var(--line);
}

@media (max-width: 420px) {
  .principles {
    grid-template-columns: minmax(0, 1fr);
  }

  .principles li:nth-child(even) {
    padding-left: 0;
    border-left: 0;
  }
}

/* ── section pages ──────────────────────────────────────── */

.section-body {
  display: grid;
  gap: 56px;
}

@media (min-width: 1000px) {
  .section-body {
    grid-template-columns: minmax(0, 1fr) 320px;
    align-items: start;
    gap: 72px;
  }

  .follow-card {
    position: sticky;
    top: calc(var(--header) + 28px);
  }
}

.top-stories {
  display: grid;
  margin-bottom: 4px;
  border-bottom: 1px solid var(--line);
}

.story {
  display: flex;
  flex-direction: column;
  padding: 24px 0 26px;
}

.story + .story {
  border-top: 1px solid var(--line);
}

.story h3 {
  margin: 0;
  font-weight: 700;
}

.story .w-meta {
  margin: 0 0 12px;
}

.story-pic {
  display: block;
  margin-bottom: 18px;
}

.story-big h3 {
  font-size: clamp(1.875rem, 1.1rem + 2.1vw, 2.875rem);
  line-height: 1.02;
  letter-spacing: -0.035em;
}

.story-med h3 {
  font-size: 1.3125rem;
  line-height: 1.2;
  letter-spacing: -0.015em;
}

@media (min-width: 760px) {
  .top-stories {
    grid-template-columns: minmax(0, 1.55fr) minmax(0, 1fr);
  }

  .story-big {
    grid-row: 1 / span 2;
    padding-right: 36px;
    border-right: 1px solid var(--line);
  }

  .story-med {
    padding-left: 36px;
  }

  .story-big + .story-med {
    border-top: 0;
  }
}

.section-main .wire .w-title {
  font-size: 1.125rem;
}

.follow-card {
  overflow: hidden;
  border-radius: var(--radius);
  box-shadow: inset 0 0 0 1px var(--line);
}

.follow-card picture {
  display: block;
}

.follow-card img {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 1;
  object-fit: cover;
  object-position: 50% 100%;
}

.follow-card-body {
  padding: 22px 22px 24px;
}

.follow-card h2 {
  margin: 0 0 10px;
  font-size: 1.5rem;
  line-height: 1.02;
  letter-spacing: -0.025em;
}

.follow-card p {
  margin: 0 0 20px;
  color: var(--soft);
  font-size: 0.9375rem;
}

@media (max-width: 999px) {
  .follow-card picture {
    display: none;
  }
}

/* ── simple pages: privacy, newsletter, 404 ─────────────── */

.page {
  padding-block: clamp(40px, 6vw, 96px) 0;
}

.page-lede {
  max-width: 50ch;
  margin: clamp(18px, 2vw, 26px) 0 0;
  color: var(--soft);
  font-size: clamp(1.125rem, 1rem + 0.5vw, 1.375rem);
  line-height: 1.45;
}

.page-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin: clamp(28px, 3.4vw, 40px) 0 0;
}

.prose {
  max-width: 70ch;
  margin-top: clamp(40px, 5vw, 64px);
  padding-top: 8px;
  border-top: 1px solid var(--line-strong);
  color: var(--soft);
  font-size: 1.0625rem;
  line-height: 1.65;
}

.prose h2 {
  margin: 44px 0 10px;
  font-size: 1.5rem;
  line-height: 1.1;
  letter-spacing: -0.02em;
}

.prose p {
  margin: 0 0 14px;
}

.prose a {
  color: var(--white);
  text-decoration-color: var(--accent);
  text-decoration-thickness: 1.5px;
  text-underline-offset: 3px;
}

.prose a:hover {
  color: var(--accent);
}

.facts {
  display: grid;
  margin: 18px 0 0;
  border-top: 1px solid var(--line);
}

.facts div {
  display: grid;
  grid-template-columns: minmax(0, 13rem) minmax(0, 1fr);
  gap: 4px 20px;
  padding: 11px 0;
  border-bottom: 1px solid var(--line);
}

.facts dt {
  color: var(--muted);
  font-size: 0.9375rem;
}

.facts dd {
  margin: 0;
  color: var(--text);
}

@media (max-width: 560px) {
  .facts div {
    grid-template-columns: minmax(0, 1fr);
  }
}

.prose-date {
  margin-top: 40px;
  color: var(--muted);
  font-size: 0.875rem;
}

/* ── footer ─────────────────────────────────────────────── */

.site-footer {
  margin-top: clamp(96px, 11vw, 168px);
  border-top: 1px solid var(--line);
  padding-block: clamp(56px, 7vw, 96px) calc(28px + env(safe-area-inset-bottom));
  color: var(--muted);
  font-size: 0.9375rem;
}

.footer-follow {
  display: grid;
  gap: 24px 48px;
}

/* Side by side only where both fit on one line (the title + five links need
   ~1100px); below that the links sit under the title instead of wrapping. */
@media (min-width: 1200px) {
  .footer-follow {
    grid-template-columns: auto minmax(0, 1fr);
    align-items: end;
  }
}

.follow-title {
  margin: 0;
  font-size: clamp(2.25rem, 1.1rem + 3.6vw, 4.5rem);
  font-weight: 700;
  line-height: 0.95;
  letter-spacing: -0.04em;
}

.social-links {
  display: flex;
  flex-wrap: wrap;
  gap: 14px 30px;
  margin: 0;
  padding: 0;
  list-style: none;
}

@media (min-width: 1200px) {
  .social-links {
    justify-content: flex-end;
    padding-bottom: 6px;
  }
}

.social-links a {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--white);
  font-size: 1.125rem;
  font-weight: 700;
  text-decoration: none;
  transition: color 0.15s ease;
}

.social-links a span {
  padding-top: 0.12em;
}

.social-links a:hover {
  color: var(--accent);
}

/* the wordmark across the full width, almost black: the brand's signature,
   with the turquoise dot as the only colour */
.footer-mark {
  display: block;
  margin-top: clamp(64px, 8vw, 120px);
  border-radius: 8px;
  color: #1b1b1b;
  transition: color 0.4s ease;
}

.footer-mark:hover {
  color: #242424;
}

.footer-mark .wordmark {
  width: 100%;
}

.footer-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 14px 32px;
  margin-top: clamp(28px, 3.4vw, 44px);
  padding-top: 24px;
  border-top: 1px solid var(--line);
}

.footer-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 22px;
}

.footer-nav a {
  text-decoration: none;
  transition: color 0.15s ease;
}

.footer-nav a:hover,
.footer-nav a[aria-current="page"] {
  color: var(--white);
}

.footer-copy {
  margin: 0 0 0 auto;
}

@media (max-width: 640px) {
  .footer-copy {
    width: 100%;
    margin-left: 0;
  }
}

/* ── analytics consent (only when analytics is switched on) ─ */

.consent {
  position: fixed;
  z-index: 50;
  right: 16px;
  bottom: calc(16px + env(safe-area-inset-bottom));
  left: 16px;
  max-width: 440px;
  padding: 20px 20px 18px;
  border-radius: 16px;
  background: rgba(10, 10, 10, 0.94);
  -webkit-backdrop-filter: blur(16px);
  backdrop-filter: blur(16px);
  box-shadow: inset 0 0 0 1px var(--line-strong), 0 24px 64px rgba(0, 0, 0, 0.6);
}

@media (min-width: 700px) {
  .consent {
    right: auto;
    bottom: 24px;
    left: 24px;
  }
}

.consent-text {
  margin: 0;
  color: var(--soft);
  font-size: 0.9375rem;
  line-height: 1.5;
}

.consent-text a {
  color: var(--white);
  text-underline-offset: 3px;
}

.consent-actions {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin-top: 16px;
}

.consent-actions .btn {
  min-height: 42px;
}

/* ── entrance: the top of the page settles in once ────────── */

@media (prefers-reduced-motion: no-preference) {
  .masthead > *,
  .front > *,
  .section-body > *,
  .page > * {
    animation: rise 0.6s var(--ease) backwards;
  }

  .masthead > :nth-child(2),
  .page > :nth-child(2),
  .front > :nth-child(1),
  .section-body > :nth-child(1) {
    animation-delay: 0.05s;
  }

  .masthead > :nth-child(3),
  .page > :nth-child(3),
  .front > :nth-child(2),
  .section-body > :nth-child(2) {
    animation-delay: 0.1s;
  }

  .front > :nth-child(3),
  .page > :nth-child(4) {
    animation-delay: 0.15s;
  }
}

@keyframes rise {
  from {
    opacity: 0;
    transform: translateY(12px);
  }
}

/* ── Pila under the hero text: plays the intro video ─────────
   The battery mascot of the explainers holds up the button in its raised
   hand (scripts/pila.mjs). The map stays free for the story pins. */

.meet {
  display: inline-flex;
  align-items: flex-start;
  margin-top: clamp(22px, 2.6vw, 34px);
  color: var(--ink);
  text-decoration: none;
}

.meet-pila {
  display: block;
  flex: none;
  width: 144px;
  height: 130px;
  overflow: visible;
}

/* the raised hand is at 22% of Pila's height: the button is centred there */
.meet-bubble {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  margin: 7px 0 0 -10px;
  padding: 6px 18px 6px 6px;
  border-radius: 999px;
  background: var(--accent);
  font-weight: 700;
  line-height: 1;
  transition: background-color 0.2s ease;
}

.meet-play {
  flex: none;
  width: 32px;
  height: 32px;
}

.meet-play circle {
  fill: var(--ink);
}

.meet-play path {
  fill: var(--accent);
}

.meet-say {
  font-size: 1.0625rem;
  letter-spacing: -0.01em;
}

.meet-len {
  font-size: 0.9375rem;
  opacity: 0.62;
  font-variant-numeric: tabular-nums;
}

.meet:hover .meet-bubble,
.meet:focus-visible .meet-bubble {
  background: var(--white);
}

.meet:focus-visible {
  outline: none;
}

.meet:focus-visible .meet-bubble {
  box-shadow: 0 0 0 3px var(--ink), 0 0 0 5px var(--accent);
}

.pila-in,
.pila-bob,
.pila-wave,
.pila-eye {
  transform-box: fill-box;
}

.pila-in {
  transform-origin: 50% 100%;
}

.pila-wave {
  /* the shoulder: the bottom-left corner of the raised arm */
  transform-origin: 0% 100%;
}

.pila-eye {
  transform-origin: center;
}

@media (max-width: 899px) {
  .meet-pila {
    width: 115px;
    height: 104px;
  }

  .meet-bubble {
    margin: 1px 0 0 -8px;
  }
}

@media (prefers-reduced-motion: no-preference) {
  .pila-in {
    animation: pila-in 0.8s cubic-bezier(0.3, 1.5, 0.5, 1) 0.7s backwards;
  }

  .meet-bubble {
    animation: rise 0.6s var(--ease) 1.1s backwards;
  }

  .pila-bob {
    animation: pila-bob 2.6s ease-in-out infinite;
  }

  .pila-wave {
    animation: pila-wave 5s ease-in-out 1.6s infinite;
  }

  .pila-eye {
    animation: pila-blink 4.2s linear infinite;
  }

  .meet:hover .pila-wave {
    animation-duration: 1.1s;
    animation-delay: 0s;
  }
}

@keyframes pila-in {
  from {
    opacity: 0;
    transform: translateY(30%) scale(0.3);
  }
}

@keyframes pila-bob {
  0%,
  100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(-3%);
  }
}

@keyframes pila-wave {
  0%,
  44%,
  100% {
    transform: rotate(0deg);
  }
  8%,
  24% {
    transform: rotate(-16deg);
  }
  16%,
  32% {
    transform: rotate(10deg);
  }
}

@keyframes pila-blink {
  0%,
  94%,
  100% {
    transform: scaleY(1);
  }
  97% {
    transform: scaleY(0.1);
  }
}

/* ── explainers: in their section's column and on the section page ── */

.play-icon {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 44px;
  height: 44px;
  transform: translate(-50%, -50%);
  transition: transform 0.25s var(--ease);
}

.play-icon circle {
  fill: var(--accent);
}

.play-icon path {
  fill: var(--ink);
}

/* our own videos: a turquoise frame and the "Voltropa explains" badge, so
   they never read as one more news item */
.ex-badge {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  color: var(--accent);
  font-size: 0.8125rem;
  font-weight: 700;
  letter-spacing: 0.01em;
}

.ex-badge-mark {
  width: 20px;
  height: 13px;
  fill: currentColor;
}

/* front page: at the foot of the section's column, the picture across the
   column width, a thin frame and the badge */
.ex-mini {
  display: block;
  overflow: hidden;
  margin-top: 18px;
  border-radius: var(--radius);
  background: rgba(0, 194, 168, 0.06);
  box-shadow: inset 0 0 0 1px rgba(0, 194, 168, 0.55);
  text-decoration: none;
  transition: background-color 0.2s ease, box-shadow 0.2s ease;
}

.ex-mini-pic {
  position: relative;
  display: block;
  margin: 1px 1px 0;
  overflow: hidden;
  border-radius: calc(var(--radius) - 1px) calc(var(--radius) - 1px) 0 0;
  aspect-ratio: 16 / 9;
  background: #111;
}

.ex-mini-pic img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.ex-mini .play-icon {
  width: 40px;
  height: 40px;
}

.ex-mini-text {
  display: block;
  padding: 10px 14px 13px;
}

.ex-mini .ex-badge {
  font-size: 0.75rem;
}

.ex-mini .ex-badge-mark {
  width: 17px;
  height: 11px;
}

.ex-mini-title {
  display: block;
  margin-top: 4px;
  color: var(--white);
  font-size: 0.96875rem;
  font-weight: 700;
  line-height: 1.2;
  letter-spacing: -0.01em;
}

.ex-mini:hover {
  background: rgba(0, 194, 168, 0.12);
  box-shadow: inset 0 0 0 1px var(--accent);
}

.ex-mini:hover .play-icon,
.ex-card:hover .play-icon {
  transform: translate(-50%, -50%) scale(1.1);
}

/* section page: a card above the follow card */
.section-side {
  display: grid;
  gap: 24px;
  align-content: start;
}

@media (min-width: 1000px) {
  .section-side .follow-card {
    position: static;
  }
}

/* the video card and the follow card together are taller than a laptop
   screen: the column only sticks where both fit */
@media (min-width: 1000px) and (min-height: 1000px) {
  .section-side {
    position: sticky;
    top: calc(var(--header) + 28px);
  }
}

.ex-card {
  display: block;
  overflow: hidden;
  border-radius: var(--radius);
  background: rgba(0, 194, 168, 0.07);
  box-shadow: inset 0 0 0 2px var(--accent);
  text-decoration: none;
  transition: background-color 0.2s ease;
}

.ex-card:hover {
  background: rgba(0, 194, 168, 0.14);
}

.ex-card-pic {
  position: relative;
  display: block;
  margin: 2px 2px 0;
  overflow: hidden;
  border-radius: calc(var(--radius) - 2px) calc(var(--radius) - 2px) 0 0;
  aspect-ratio: 16 / 9;
  background: #111;
}

.ex-card-pic img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.ex-card .play-icon {
  width: 56px;
  height: 56px;
}

.ex-len {
  position: absolute;
  right: 10px;
  bottom: 10px;
  padding: 3px 8px;
  border-radius: 999px;
  background: rgba(10, 10, 10, 0.78);
  color: var(--white);
  font-size: 0.8125rem;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
}

.ex-card-body {
  display: block;
  padding: 18px 22px 22px;
}

.ex-card-title {
  display: block;
  margin-top: 8px;
  color: var(--white);
  font-size: 1.375rem;
  font-weight: 700;
  line-height: 1.08;
  letter-spacing: -0.02em;
}

.ex-card-note {
  display: block;
  margin-top: 10px;
  color: var(--muted);
  font-size: 0.875rem;
}

.ex-card:hover .ex-card-title {
  color: var(--accent);
}

/* ── the player (src/js/player.js) ───────────────────────── */

.vp {
  width: min(1100px, calc(100vw - 2 * var(--gutter)));
  max-width: none;
  max-height: none;
  margin: auto;
  padding: 0;
  border: 0;
  background: transparent;
  color: var(--text);
  overflow: visible;
}

.vp::backdrop {
  background: rgba(5, 5, 5, 0.88);
}

.vp-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 12px;
}

.vp-title {
  margin: 0;
  color: var(--white);
  font-size: clamp(1.125rem, 1rem + 0.6vw, 1.5rem);
  font-weight: 700;
  letter-spacing: -0.02em;
}

.vp-close {
  display: grid;
  place-items: center;
  flex: none;
  width: 44px;
  height: 44px;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.1);
  color: var(--white);
  cursor: pointer;
}

.vp-close:hover,
.vp-close:focus-visible {
  background: var(--accent);
  color: var(--ink);
}

.vp-close svg {
  width: 22px;
  height: 22px;
}

.vp-video {
  display: block;
  width: 100%;
  height: auto;
  max-height: calc(100vh - 160px);
  aspect-ratio: 16 / 9;
  border-radius: var(--radius);
  background: #000;
}

.vp-note {
  margin: 12px 0 0;
  color: var(--muted);
  font-size: 0.875rem;
}

@media (prefers-reduced-motion: no-preference) {
  .vp[open] {
    animation: rise 0.35s var(--ease);
  }
}
