/* =========================
   VERHALEN PAGE
========================= */

.stories-hero {
  max-width: 1100px;
  margin: 3rem auto 2rem;
  padding: 0 1rem;
}

.stories-hero-content {
  padding: 3rem 2rem;
  border-radius: 30px;
  text-align: center;
  color: white;
  background:
    radial-gradient(circle at top left, rgba(255, 59, 59, 0.35), transparent 35%),
    radial-gradient(circle at top right, rgba(31, 111, 235, 0.45), transparent 35%),
    linear-gradient(145deg, #07152e, #102f5f 45%, #06101f);
  border: 3px solid rgba(255, 255, 255, 0.22);
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.35);
}

.stories-badge {
  display: inline-block;
  margin-bottom: 1rem;
  padding: 0.6rem 1.2rem;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.14);
  border: 2px solid rgba(255, 255, 255, 0.22);
  font-weight: 900;
}

.stories-hero h2 {
  font-size: clamp(2rem, 5vw, 3.5rem);
  margin-bottom: 1rem;
}

.stories-hero p {
  max-width: 700px;
  margin: 0 auto;
  line-height: 1.7;
  color: #dceaff;
}

/* =========================
   SECTION + FILTERS
========================= */

.stories-section {
  max-width: 1200px;
  margin: 0 auto 4rem;
  padding: 0 1rem;
}

.stories-section-header {
  margin-bottom: 1.5rem;
  color: white;
  text-align: center;
}

.stories-section-header h2 {
  font-size: 2rem;
  margin-bottom: 0.4rem;
}

.story-filters {
  margin: 1.5rem auto 0;
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 0.7rem;
}

.story-filters button {
  padding: 0.65rem 1rem;
  border: 2px solid rgba(255, 255, 255, 0.25);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.12);
  color: white;
  font-weight: 800;
  cursor: pointer;
  transition: background 0.2s ease, transform 0.2s ease;
}

.story-filters button.active,
.story-filters button:hover {
  background: #1f6feb;
  border-color: white;
  transform: translateY(-2px);
}

/* =========================
   STORY GRID
========================= */

.verhalen-container {
  display: grid;
  grid-template-columns: repeat(
    auto-fit,
    minmax(220px, 1fr)
  );
  gap: 1rem;
}

.story-card {
  min-height: 0;

  display: flex;
  flex-direction: column;

  position: relative;
  overflow: hidden;

  border: 1px solid rgba(78, 161, 255, 0.24);
  border-radius: 14px;

  background:
    linear-gradient(
      180deg,
      rgba(255, 255, 255, 0.06),
      rgba(255, 255, 255, 0.015)
    ),
    rgba(5, 15, 32, 0.94);

  color: var(--text);
  cursor: pointer;

  box-shadow:
    0 12px 26px rgba(0, 0, 0, 0.28),
    inset 0 1px 0 rgba(255, 255, 255, 0.08);

  transition:
    transform 0.18s ease,
    border-color 0.18s ease,
    box-shadow 0.18s ease;
}

.story-card-image {
  width: 100%;
  height: 145px;

  display: grid;
  place-items: center;

  overflow: hidden;

  border-bottom:
    1px solid rgba(78, 161, 255, 0.18);

  background:
    rgba(2, 10, 24, 0.72);
}

.story-card::before {
  content: "";
  position: absolute;
  inset: 0 auto 0 0;
  width: 4px;

  background:
    linear-gradient(
      180deg,
      var(--yellow),
      var(--blue)
    );
}

.story-card:hover,
.story-card:focus-visible {
  transform: translateY(-5px);

  border-color:
    rgba(78, 161, 255, 0.6);

  filter: brightness(1.04);

  box-shadow:
    0 24px 48px rgba(0, 0, 0, 0.42),
    0 0 28px rgba(31, 111, 235, 0.13),
    inset 0 1px 0 rgba(255, 255, 255, 0.12);
}

.story-card:focus-visible {
  outline:
    3px solid rgba(39, 211, 255, 0.35);
  outline-offset: 3px;
}

.story-card:nth-child(1) {
  animation-delay: 0.05s;
}

.story-card:nth-child(2) {
  animation-delay: 0.1s;
}

.story-card:nth-child(3) {
  animation-delay: 0.15s;
}

.story-card:nth-child(4) {
  animation-delay: 0.2s;
}

.story-card:nth-child(5) {
  animation-delay: 0.25s;
}

.story-card:nth-child(6) {
  animation-delay: 0.3s;
}

.story-card-content {
  flex: 1;

  display: flex;
  flex-direction: column;

  padding: 0.85rem;
}

.story-card-meta {
  gap: 0.35rem;
  margin-bottom: 0.6rem;
}

.story-series,
.story-category {
  padding: 0.2rem 0.5rem;

  font-size: 0.6rem;
  letter-spacing: 0.04em;
}

.story-card h2 {
  margin: 0 0 0.4rem;

  font-size: 1rem;
  line-height: 1.25;
}

.story-subtitle {
  display: -webkit-box;
  overflow: hidden;

  margin: 0 0 0.7rem;

  color: var(--text);
  font-size: 0.82rem;
  line-height: 1.45;

  -webkit-box-orient: vertical;
  -webkit-line-clamp: 3;
}

.story-card time {
  padding-top: 0.5rem;

  font-size: 0.7rem;
}

.story-read-more {
  margin-top: 0.55rem;

  font-size: 0.78rem;
}

/* Load more */

.stories-load-more {
  display: block;

  min-width: 220px;
  min-height: 46px;

  margin: 1.5rem auto 0;
  padding: 0.7rem 1.2rem;

  border: 1px solid rgba(78, 161, 255, 0.55);
  border-radius: 10px;

  background:
    linear-gradient(
      180deg,
      rgba(255,255,255,.1),
      rgba(255,255,255,.02)
    ),
    rgba(20, 66, 140, 0.92);

  color: #fff;
  font-weight: 900;
  cursor: pointer;
}

.stories-load-more:hover {
  filter: brightness(1.08);
  transform: translateY(-2px);
}

/* =========================
   STORY IMAGE
========================= */

.story-card-image {
  width: 100%;
  aspect-ratio: 16 / 9;

  display: grid;
  place-items: center;

  overflow: hidden;

  border-bottom:
    1px solid rgba(78, 161, 255, 0.18);

  background:
    radial-gradient(
      circle at center,
      rgba(31, 111, 235, 0.14),
      transparent 65%
    ),
    rgba(2, 10, 24, 0.72);
}

.story-card-image img {
  width: 100%;
  height: 100%;

  display: block;

  object-fit: cover;

  transition:
    transform 0.3s ease,
    filter 0.3s ease;
}

.story-card:hover .story-card-image img {
  transform: scale(1.045);
  filter: brightness(1.06);
}

.story-card-placeholder {
  color: rgba(234, 244, 255, 0.72);
  font-size: 4rem;

  text-shadow:
    0 0 22px rgba(31, 111, 235, 0.25);
}

/* =========================
   STORY CARD CONTENT
========================= */

.story-card-content {
  flex: 1;

  display: flex;
  flex-direction: column;

  padding: 1.15rem 1.15rem 1.2rem;
}

.story-card-meta {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.45rem;

  margin-bottom: 0.85rem;
}

.story-series,
.story-category {
  display: inline-flex;
  align-items: center;
  justify-content: center;

  padding: 0.28rem 0.65rem;

  border-radius: 999px;

  font-size: 0.68rem;
  font-weight: 900;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.story-series {
  border:
    1px solid rgba(240, 236, 7, 0.4);

  background:
    rgba(240, 236, 7, 0.08);

  color: var(--yellow);
}

.story-category {
  border:
    1px solid rgba(39, 211, 255, 0.36);

  background:
    rgba(39, 211, 255, 0.08);

  color: var(--cyan);
}

.story-card h2 {
  margin: 0 0 0.55rem;

  color: var(--white);
  font-size: 1.2rem;
  line-height: 1.3;
}

.story-subtitle {
  margin: 0 0 1rem;

  color: var(--text);
  font-size: 0.92rem;
  line-height: 1.6;
}

.story-card time {
  display: block;

  margin-top: auto;
  padding-top: 0.75rem;

  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 700;
}

.story-read-more {
  margin-top: 0.85rem;

  display: inline-flex;
  align-items: center;

  color: var(--cyan);
  font-size: 0.86rem;
  font-weight: 900;

  transition:
    transform 0.16s ease,
    color 0.16s ease;
}

.story-card:hover .story-read-more {
  transform: translateX(4px);
  color: var(--white);
}

/* =========================
   EMPTY STATE
========================= */

.empty-story {
  grid-column: 1 / -1;

  min-height: 180px;
  padding: 2rem;

  display: grid;
  place-items: center;

  text-align: center;
  cursor: default;
}

.empty-story h2 {
  margin-bottom: 0.5rem;
}

.empty-story p {
  margin: 0;
  color: var(--muted);
}

/* =========================
   FILTERS
========================= */

.story-filters {
  width: 100%;

  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}

.series-filter,
.category-filter {
  width: 100%;
}

.category-filter {
  margin-top: 0.5rem;
}

/* =========================
   FULLSCREEN MODAL
========================= */

.story-modal {
  position: fixed;
  inset: 0;
  z-index: 9999;

  padding: 1.5rem;

  display: grid;
  place-items: center;

  background:
    rgba(0, 0, 0, 0.82);

  backdrop-filter: blur(8px);
}

.story-modal-content {
  width: min(100%, 980px);
  max-height: 92vh;

  position: relative;
  overflow-y: auto;

  padding: 2rem;

  border:
    1px solid rgba(78, 161, 255, 0.35);

  border-radius: 22px;

  background:
    linear-gradient(
      180deg,
      rgba(255, 255, 255, 0.075),
      rgba(255, 255, 255, 0.02)
    ),
    rgba(5, 15, 32, 0.98);

  color: var(--text);

  box-shadow:
    0 30px 90px rgba(0, 0, 0, 0.68),
    inset 0 1px 0 rgba(255, 255, 255, 0.12);
}

.story-modal-close {
  position: sticky;
  top: 0;
  z-index: 5;

  width: 44px;
  height: 44px;

  margin-left: auto;

  display: grid;
  place-items: center;

  border:
    1px solid rgba(255, 90, 90, 0.65);

  border-radius: 12px;

  background:
    linear-gradient(
      180deg,
      rgba(255, 255, 255, 0.1),
      rgba(255, 255, 255, 0.02)
    ),
    rgba(140, 22, 31, 0.95);

  color: #ffffff;
  font-size: 1.1rem;
  font-weight: 900;

  cursor: pointer;

  box-shadow:
    0 8px 18px rgba(0, 0, 0, 0.35);
}

.story-full-meta {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.55rem;

  margin-bottom: 1rem;
}

.story-full-meta time {
  margin-left: auto;

  color: var(--muted);
  font-size: 0.82rem;
  font-weight: 800;
}

.story-full h1 {
  margin: 0 0 0.75rem;

  color: var(--white);
  font-size: clamp(2rem, 5vw, 3.4rem);
  line-height: 1.1;
}

.story-full-subtitle {
  margin-bottom: 1.5rem;

  color: var(--cyan);
  font-size: 1.15rem;
  font-weight: 800;
  line-height: 1.5;
}

.story-content {
  color: var(--text);
  font-size: 1.04rem;
  line-height: 1.85;
}

.story-content p {
  margin: 0;
}

.story-content p + p {
  margin-top: 1rem;
}

.story-content img {
  max-width: 100%;
  height: auto;
  max-height: 650px;

  display: block;

  margin: 1.5rem auto;

  object-fit: contain;

  border-radius: 16px;

  box-shadow:
    0 18px 38px rgba(0, 0, 0, 0.34);
}

.story-content iframe {
  width: 100%;
  max-width: 780px;
  aspect-ratio: 16 / 9;

  display: block;

  margin: 1.5rem auto;

  border: none;
  border-radius: 16px;

  box-shadow:
    0 18px 38px rgba(0, 0, 0, 0.34);
}

@media (max-width: 700px) {
  .verhalen-container {
    grid-template-columns: 1fr;
  }

  .story-modal {
    padding: 0.5rem;
  }

  .story-modal-content {
    padding: 1.2rem;
    border-radius: 16px;
  }

  .story-full-meta time {
    width: 100%;
    margin-left: 0;
  }
}

/* =========================
   ANIMATIONS
========================= */

@keyframes storyCardEnter {
  from {
    opacity: 0;
    transform: translateY(24px) scale(0.98);
  }

  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

/* =========================
   RESPONSIVE
========================= */

@media (max-width: 600px) {
  .stories-hero-content {
    padding: 2rem 1.2rem;
  }

  .verhalen-container {
    grid-template-columns: 1fr;
  }

  .story-modal-content {
    padding: 1.2rem;
  }

  .story-full-meta {
    flex-direction: column;
  }
}

@media (prefers-reduced-motion: reduce) {
  .story-card,
  .story-thumb img,
  .story-filters button {
    animation: none;
    transition: none;
  }

  .story-card:hover,
  .story-card:hover .story-thumb img,
  .story-filters button:hover {
    transform: none;
    filter: none;
  }
}