/* wa-lint: skip */
/* ==== Forside news strip — scene 3 =========================================
   4 cards from Serie B (the most delbare blog posts), shown in a row on
   desktop, 2 columns on tablet, 1 on mobile. Each card carries a status
   badge: "Læst nu" for published, "Kommer snart" for udkast.

   Visual language matches the rest of the forside: cream paper bg, white
   cards, rounded corners, subtle shadows. Tokens come from cd-app.css.
=========================================================================== */

.scene--news {
  background:
    radial-gradient(circle at 80% 20%, rgba(127, 190, 198, 0.10), transparent 55%),
    radial-gradient(circle at 15% 85%, rgba(184, 90, 58, 0.08), transparent 50%),
    var(--bg);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 6vh clamp(20px, 4vw, 56px) 4vh;
  overflow-y: auto;
}

.news-strip {
  width: 100%;
  max-width: 1180px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: clamp(18px, 2.4vw, 28px);
}

.news-strip__head {
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
}

.news-strip__kicker {
  display: inline-block;
  font-size: var(--fs-xs);
  font-weight: var(--fw-bold);
  letter-spacing: var(--ls-section);
  text-transform: uppercase;
  color: var(--accent);
  padding: 6px 14px;
  border: 1px solid rgba(184, 90, 58, 0.3);
  border-radius: 999px;
  background: rgba(247, 226, 216, 0.4);
}

.news-strip__title {
  font-size: var(--fs-display-xl);
  font-weight: var(--fw-light);
  letter-spacing: -0.025em;
  color: var(--primary);
  margin: 0;
  line-height: 1.1;
  text-wrap: balance;
  max-width: 22ch;
}
.news-strip__title b {
  font-weight: var(--fw-bold);
  color: var(--accent);
}

.news-strip__subhead {
  font-size: var(--fs-display-sm);
  line-height: 1.55;
  color: var(--brand-30, rgb(38, 66, 78));
  margin: 0;
  max-width: 56ch;
  text-wrap: balance;
}

/* Grid */
.news-strip__grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: clamp(14px, 1.8vw, 22px);
  align-items: stretch;
}
@media (max-width: 980px) {
  .news-strip__grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 560px) {
  .news-strip__grid { grid-template-columns: 1fr; }
}

/* Card */
.news-card {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding: 18px 18px 16px;
  background: var(--surface, rgb(255, 255, 255));
  border: 1px solid var(--line);
  border-radius: var(--radius-lg, 20px);
  box-shadow: 0 6px 22px -10px rgba(50, 79, 89, 0.18);
  text-decoration: none;
  color: inherit;
  transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
  overflow: hidden;
  min-height: 220px;
}
.news-card:hover {
  transform: translateY(-3px);
  border-color: rgba(184, 90, 58, 0.35);
  box-shadow: 0 12px 30px -10px rgba(50, 79, 89, 0.28);
}
.news-card:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

.news-card__top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.news-card__num {
  font-size: var(--fs-xs);
  font-weight: var(--fw-bold);
  letter-spacing: var(--ls-section);
  color: var(--muted);
  font-feature-settings: "tnum";
}

.news-card__status {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: var(--fs-xs);
  font-weight: var(--fw-bold);
  letter-spacing: var(--ls-section);
  text-transform: uppercase;
  padding: 4px 9px;
  border-radius: 999px;
  white-space: nowrap;
}
.news-card__status--published {
  background: rgba(0, 136, 60, 0.10);
  color: rgb(0, 136, 60);
  border: 1px solid rgba(0, 136, 60, 0.22);
}
/* Kategori-chip (serie) for udgivne indlæg — neutral, signalerer emne ikke
   handling. Erstatter den gamle "Læs nu"-status der dublerede CTA'en. */
.news-card__status--kategori {
  background: rgba(0, 0, 0, 0.05);
  color: var(--muted);
  border: 1px solid var(--border, rgba(0, 0, 0, 0.12));
}
.news-card__status--published::before {
  content: "";
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: rgb(0, 136, 60);
}

@keyframes news-card-pulse {
  0%, 100% { opacity: 1; }
  50%      { opacity: 0.72; }
}
@keyframes news-card-pulse-dot {
  0%, 100% { transform: scale(1); }
  50%      { transform: scale(1.35); }
}

/* Reduced motion — slå udkast-pulse fra og fjern hover-lift */
@media (prefers-reduced-motion: reduce) {
  .news-card,
  .news-card:hover,
  .news-strip__alle,
  .news-strip__alle:hover,
  .news-card__more::after,
  .news-strip__alle::after {
    animation: none !important;
    transition: none !important;
    transform: none !important;
  }
}

.news-card__title {
  font-size: var(--fs-xl);
  font-weight: var(--fw-bold);
  line-height: 1.25;
  letter-spacing: -0.01em;
  color: var(--primary);
  margin: 0;
  text-wrap: balance;
}

.news-card__excerpt {
  font-size: var(--fs-base);
  line-height: 1.5;
  color: var(--brand-30, rgb(38, 66, 78));
  margin: 0;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.news-card__more {
  margin-top: auto;
  padding-top: 8px;
  font-size: var(--fs-sm);
  font-weight: var(--fw-semibold);
  color: var(--accent);
  letter-spacing: -0.005em;
  display: inline-flex;
  align-items: center;
  gap: 4px;
}
.news-card:hover .news-card__more { color: var(--accent-hover, rgb(154, 72, 48)); }
.news-card__more::after {
  content: "→";
  transition: transform 0.2s ease;
}
.news-card:hover .news-card__more::after { transform: translateX(3px); }

/* Udkast variant — distinct paper feel */

/* Footer link */
.news-strip__foot {
  display: flex;
  justify-content: center;
  margin-top: 4px;
}
.news-strip__alle {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: var(--fs-base);
  font-weight: var(--fw-semibold);
  color: var(--primary);
  background: rgba(255, 255, 255, 0.85);
  border: 1px solid var(--line);
  padding: 12px 18px;
  border-radius: 999px;
  min-height: 44px;
  text-decoration: none;
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  transition: all 0.2s ease;
}
.news-strip__alle:hover {
  border-color: var(--accent);
  color: var(--accent);
  transform: translateY(-1px);
  box-shadow: 0 6px 20px -8px rgba(184, 90, 58, 0.35);
}
.news-strip__alle::after { content: "→"; transition: transform 0.2s ease; }
.news-strip__alle:hover::after { transform: translateX(3px); }

/* Dark theme */
[data-theme="dark"] .news-card {
  background: rgba(20, 30, 40, 0.7);
  border-color: rgba(255, 255, 255, 0.10);
  color: var(--ink);
}
[data-theme="dark"] .news-card:hover {
  background: rgba(28, 40, 50, 0.95);
}
[data-theme="dark"] .news-card__title { color: var(--ink); }
[data-theme="dark"] .news-card__excerpt { color: rgba(255, 255, 255, 0.75); }
[data-theme="dark"] .news-strip__title { color: var(--ink); }
[data-theme="dark"] .news-strip__alle {
  background: rgba(15, 27, 31, 0.7);
  color: var(--ink);
  border-color: rgba(255, 255, 255, 0.12);
}

/* Small viewports — tighten paddings so the scene still fits 100dvh.
   Bottom-padding skal være stort nok til at scene-nav (fixed bottom 20px,
   ~50px høj) IKKE overlapper sidste news-card. R13-A-fund: pillen lå over
   "Læs indlæg →"-CTA på mobile. */
@media (max-width: 600px) {
  .scene--news { padding: 4vh 14px 100px; }
  .news-card { padding: 14px 14px 12px; min-height: 180px; }
  .news-card__title { font-size: var(--fs-lg); }
}

/* Banner shown on individual blog posts when status === 'udkast' */


/* ==========================================================================
   Dark mode — dæmper de kreme/varme tints så de ikke bryder på mørk surface
   ========================================================================== */
[data-theme="dark"] .news-strip__kicker {
  background: rgba(127, 168, 182, 0.10);
  border-color: rgba(184, 90, 58, 0.35);
}
[data-theme="dark"] .news-card {
  box-shadow: 0 6px 22px -10px rgba(0, 0, 0, 0.45);
}
[data-theme="dark"] .news-card:hover {
  box-shadow: 0 12px 30px -10px rgba(0, 0, 0, 0.55);
}
[data-theme="dark"] .news-card__status--published {
  background: rgba(0, 136, 60, 0.18);
  color: rgb(78, 181, 116);
  border-color: rgba(0, 136, 60, 0.4);
}
[data-theme="dark"] .news-card__status--kategori {
  background: rgba(255, 255, 255, 0.06);
  color: rgba(255, 255, 255, 0.72);
  border-color: rgba(255, 255, 255, 0.14);
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .news-strip__kicker {
    background: rgba(127, 168, 182, 0.10);
    border-color: rgba(184, 90, 58, 0.35);
  }
  :root:not([data-theme="light"]) .news-card {
    box-shadow: 0 6px 22px -10px rgba(0, 0, 0, 0.45);
  }
  :root:not([data-theme="light"]) .news-card:hover {
    box-shadow: 0 12px 30px -10px rgba(0, 0, 0, 0.55);
  }
  :root:not([data-theme="light"]) .news-card__status--published {
    background: rgba(0, 136, 60, 0.18);
    color: rgb(78, 181, 116);
    border-color: rgba(0, 136, 60, 0.4);
  }
}
