:root {
  --navy: #1f3d4d;
  --navy-deep: #16313d;
  --ink: #1c2b33;
  --muted: #4e656f;
  --line: #d5e3dc;
  --paper: #f3f6f5;
  --card: #fff;
  --mint: #66ccaa;
  --mint-deep: #2f9d7a;
  --yellow: #ffe666;
  --shadow: 0 10px 30px rgba(31, 61, 77, 0.08);
  --sans: "Fira Sans", "Segoe UI", sans-serif;
  --display: "Poppins", "Fira Sans", sans-serif;
  color-scheme: light;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; overflow-x: clip; }
body {
  margin: 0;
  overflow-x: clip;
  max-width: 100%;
  font-family: var(--sans);
  color: var(--ink);
  background:
    radial-gradient(1200px 400px at 90% -10%, rgba(102, 204, 170, 0.25), transparent 50%),
    var(--paper);
  line-height: 1.5;
}
img { max-width: 100%; }
a { color: var(--navy); }
a:hover { color: var(--mint-deep); }
h1, h2, h3, .logo span { font-family: var(--display); letter-spacing: -0.02em; }
h1 { font-size: clamp(1.8rem, 4vw, 3rem); line-height: 1.15; margin: 0 0 0.4rem; }
h2 { font-size: 1.4rem; margin: 0 0 0.8rem; }
h3 { font-size: 1.05rem; margin: 0 0 0.4rem; }
p { margin: 0 0 0.8rem; }

.sr {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  border: 0;
}
.skip {
  position: absolute;
  left: 1rem;
  top: -4rem;
  background: var(--yellow);
  color: var(--navy);
  padding: 0.5rem 0.8rem;
  z-index: 5;
}
.skip:focus { top: 0.5rem; }

:focus-visible { outline: 3px solid var(--yellow); outline-offset: 3px; }
.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  background:
    radial-gradient(900px 180px at 0% 0%, rgba(102, 204, 170, 0.28), transparent 55%),
    linear-gradient(165deg, #102833, #1b3848 48%, #245066);
  color: white;
  box-shadow: 0 12px 32px rgba(16, 40, 51, 0.22);
}
.header-bar {
  width: min(1120px, calc(100% - 1.5rem));
  margin: 0 auto;
  display: grid;
  gap: 0.85rem;
  align-items: center;
  padding: 1rem 0 0.85rem;
}
.site-header a { color: white; text-decoration: none; }
.logo { display: flex; gap: 0.85rem; align-items: center; min-height: 64px; text-decoration: none; }
.word { display: grid; gap: 0.05rem; line-height: 1; }
.wordmark { font-weight: 700; font-size: 1.9rem; letter-spacing: -0.04em; }
.tagline { font-family: var(--sans); font-weight: 600; font-size: 0.78rem; letter-spacing: 0.01em; color: #d7f3e8; }
.mark { width: 52px; height: 52px; display: block; flex: none; filter: drop-shadow(0 3px 0 rgba(255, 230, 102, 0.28)); }
.nav { display: flex; flex-wrap: wrap; gap: 0.25rem; }
.nav a { padding: 0.55rem 0.85rem; border-radius: 999px; white-space: nowrap; font-weight: 600; }
.nav a[aria-current="page"] { background: var(--yellow); color: var(--navy-deep); }
.nav a:hover { background: rgba(102, 204, 170, 0.28); }
.header-search .search input { min-height: 48px; box-shadow: inset 0 0 0 2px transparent; }
.header-search .search input:focus { outline: 3px solid var(--yellow); outline-offset: 1px; }
.header-note {
  margin: 0;
  padding: 0.45rem 0.9rem;
  text-align: center;
  font-size: 0.92rem;
  line-height: 1.35;
  color: var(--navy-deep);
  background: linear-gradient(90deg, var(--mint), #b7f0dc 45%, var(--yellow));
}

.search { position: relative; display: flex; gap: 0.4rem; }
.search input {
  flex: 1;
  min-width: 0;
  border: 0;
  border-radius: 999px;
  padding: 0.75rem 1rem;
  font: inherit;
  color: var(--ink);
  background: white;
}
.search button, .btn {
  border: 0;
  border-radius: 999px;
  padding: 0.7rem 1rem;
  font: inherit;
  font-weight: 600;
  background: var(--mint);
  color: var(--navy-deep);
  cursor: pointer;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
}
.btn-ghost { background: transparent; color: var(--navy); border: 1px solid var(--line); }
.btn-yellow { background: var(--yellow); }
.suggest {
  position: absolute;
  z-index: 30;
  top: calc(100% + 0.35rem);
  left: 0;
  right: 0;
  margin: 0;
  padding: 0.4rem;
  list-style: none;
  background: white;
  color: var(--ink);
  border-radius: 16px;
  box-shadow: var(--shadow);
}
.suggest a, .suggest button {
  width: 100%;
  text-align: left;
  background: transparent;
  border: 0;
  color: inherit;
  font: inherit;
  padding: 0.55rem 0.7rem;
  border-radius: 10px;
  display: flex;
  justify-content: space-between;
  gap: 14px;
  text-decoration: none;
  cursor: pointer;
}
.suggest a[aria-selected="true"], .suggest a:hover { background: #e7f7f1; }
.suggest .kind { color: var(--muted); font-size: 0.8rem; }
.group-label { font-size: 0.75rem; letter-spacing: 0.04em; text-transform: uppercase; color: var(--muted); padding: 0.4rem 0.7rem 0.1rem; }

.wrap { width: min(1120px, calc(100% - 2rem)); margin: 0 auto; padding: 1.2rem 0 3rem; }
.hero { padding: 1.2rem 0 0.4rem; }
.lede { font-size: 1.1rem; max-width: 42rem; color: var(--navy); }
.hero .search { margin: 1rem 0; }
.hero .search input { padding: 0.95rem 1.1rem; font-size: 1.05rem; box-shadow: var(--shadow); }
.chips { display: flex; flex-wrap: wrap; gap: 0.4rem; overflow: visible; }
.chips a, .pill {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  border-radius: 999px;
  padding: 0.35rem 0.7rem;
  background: white;
  border: 1px solid var(--line);
  text-decoration: none;
  color: var(--navy);
  white-space: nowrap;
  font-size: 0.92rem;
}
.chips.letters { flex-wrap: wrap; overflow: visible; }
.chip.quiet { display: inline-flex; align-items: center; gap: 0.3rem; border-radius: 999px; padding: 0.35rem 0.7rem; background: white; border: 1px solid var(--line); color: var(--muted); opacity: 0.55; white-space: nowrap; font-size: 0.92rem; }
.chips a[aria-current="page"], .filters a[aria-current="page"] { background: var(--navy); color: white; border-color: var(--navy); }
.pill.aktiv { background: #d9f6ec; border-color: transparent; }
.pill.oregelbunden { background: var(--yellow); border-color: transparent; }
.pill.vilande, .pill.okand { background: #e7eef1; }
.pill.avslutad { background: transparent; }

.section { margin: 1.8rem 0; }
.section-head { display: flex; justify-content: space-between; gap: 0.8rem 1rem; align-items: baseline; flex-wrap: wrap; }
.eyebrow { text-transform: uppercase; letter-spacing: 0.08em; font-size: 0.75rem; color: var(--mint-deep); font-weight: 600; margin: 0 0 0.3rem; }
.grid { display: grid; gap: 0.8rem; }
.grid.toplists { grid-template-columns: 1fr; }
.toplist-card {
  display: grid;
  grid-template-columns: 72px minmax(0, 1fr);
  gap: 14px;
  align-items: start;
  padding: 0.95rem;
  background: white;
  border-radius: 18px;
  text-decoration: none;
  color: inherit;
  box-shadow: var(--shadow);
}
.toplist-copy { display: grid; align-content: start; min-width: 0; gap: 0.2rem; }
.toplist-copy h3 { margin: 0; }
.toplist-copy .btn { justify-self: start; margin-top: 0.35rem; }
.one-line { margin: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.topic-icon { width: 72px; height: 72px; border-radius: 14px; display: block; object-fit: cover; background: var(--navy); }
.chips .topic-icon { width: 22px; height: 22px; border-radius: 6px; }
.mosaic { width: 72px; height: 72px; display: grid; gap: 2px; border-radius: 14px; overflow: hidden; background: var(--navy); }
.mosaic img { width: 100%; height: 100%; object-fit: cover; display: block; }
.mosaic-2 { grid-template-columns: 1fr 1fr; }
.mosaic-3 { grid-template-columns: 1.3fr 1fr; grid-template-rows: 1fr 1fr; }
.mosaic-3 img:first-child { grid-row: span 2; }
.card, .panel, .editorial, .episode, .person-card {
  background: var(--card);
  border-radius: 18px;
  box-shadow: var(--shadow);
}
.card { display: grid; grid-template-columns: 72px minmax(0, 1fr); gap: 14px; padding: 0.85rem; text-decoration: none; color: inherit; transition: transform 0.15s ease; }
.card:hover, .rank:hover, .episode:hover { transform: translateY(-2px); }
.card h3, .episode h3, .person-card h3 { color: var(--navy); }
.card p, .muted { color: var(--muted); }
.cover {
  position: relative;
  width: 72px;
  height: 72px;
  border-radius: 14px;
  display: grid;
  place-items: center;
  overflow: hidden;
  color: var(--yellow);
  background: linear-gradient(160deg, hsl(var(--h) 42% 28%), var(--navy) 72%);
  font-family: var(--display);
  font-weight: 600;
  flex: none;
}
.cover img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.rank .cover { width: 48px; height: 48px; border-radius: 10px; }
.episode:has(.cover) { grid-template-columns: 56px minmax(0, 1fr); column-gap: 14px; align-items: center; }
.episode .cover { width: 56px; height: 56px; }
.show-head { display: grid; grid-template-columns: 120px minmax(0, 1fr); gap: 16px; align-items: start; margin: 0.4rem 0 1rem; }
.show-head .cover { width: 120px; height: 120px; border-radius: 18px; }
.suggest a { align-items: center; }
.suggest-thumb { width: 36px; height: 36px; border-radius: 8px; object-fit: cover; flex: none; }
.meta { display: flex; flex-wrap: wrap; gap: 0.35rem; align-items: center; margin-top: 0.35rem; }
.rank-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 0.55rem; }
.rank {
  display: grid;
  grid-template-columns: auto 48px minmax(0, 1fr) auto;
  column-gap: 14px;
  row-gap: 0.15rem;
  align-items: center;
  background: white;
  border-radius: 16px;
  padding: 0.7rem 0.8rem;
  color: inherit;
  box-shadow: var(--shadow);
}
.rank-hit { display: contents; color: inherit; text-decoration: none; }
.rank .num { grid-column: 1; grid-row: 1 / span 2; }
.rank .cover { grid-column: 2; grid-row: 1 / span 2; }
.rank-text { grid-column: 3; grid-row: 1; min-width: 0; }
.hosts { grid-column: 3; grid-row: 2; margin: 0; min-width: 0; font-size: 0.92rem; }
.hosts a { color: var(--navy); }
.rank .move { grid-column: 4; grid-row: 1 / span 2; }
.num {
  width: 2.2rem;
  height: 2.2rem;
  display: grid;
  place-items: center;
  border-radius: 10px;
  background: var(--yellow);
  color: var(--navy);
  font-family: var(--display);
  font-weight: 700;
}
.move { font-size: 0.85rem; color: var(--muted); min-width: 3rem; text-align: right; }
.move.up { color: var(--mint-deep); }
.episode {
  display: grid;
  gap: 0.2rem;
  padding: 0.9rem 1rem;
  text-decoration: none;
  color: inherit;
}
.two { display: grid; gap: 1.5rem; }
.filters { display: flex; flex-wrap: wrap; gap: 0.4rem; margin: 0.6rem 0 1rem; }
.filters a { padding: 0.35rem 0.7rem; border-radius: 999px; background: white; border: 1px solid var(--line); text-decoration: none; }
.editorial, .panel { padding: 1rem 1.1rem; }
.editorial { border-top: 6px solid var(--yellow); }
.notice, .banner, .flash {
  background: #fff8d2;
  border-radius: 12px;
  padding: 0.7rem 0.9rem;
  margin: 0.8rem 0;
}
.banner { background: var(--navy); color: white; }
.empty { padding: 1.2rem; background: white; border-radius: 16px; }
.actions { display: flex; flex-wrap: wrap; gap: 0.45rem; margin: 0.8rem 0; }
.crumbs { display: flex; flex-wrap: wrap; gap: 0.35rem; color: var(--muted); font-size: 0.92rem; margin-bottom: 0.7rem; }
.crumbs a { color: var(--muted); }
audio { width: 100%; margin: 0.6rem 0 1rem; }
.cue-list { list-style: none; padding: 0; margin: 0; display: grid; gap: 0.45rem; }
.cue-list a { display: grid; grid-template-columns: 3.2rem 1fr; gap: 0.6rem; text-decoration: none; }
.cue-list time { color: var(--mint-deep); font-variant-numeric: tabular-nums; }
mark { background: var(--yellow); color: inherit; padding: 0 0.1em; border-radius: 3px; }
.form-stack { display: grid; gap: 0.6rem; max-width: 28rem; }
.form-stack input, .form-stack select, .form-stack textarea {
  font: inherit;
  padding: 0.7rem 0.8rem;
  border-radius: 12px;
  border: 1px solid var(--line);
}
.watch-list { list-style: none; padding: 0; margin: 0; display: grid; gap: 0.7rem; }
.watch-list li { display: flex; flex-wrap: wrap; gap: 0.45rem 0.7rem; align-items: center; background: white; border-radius: 14px; padding: 0.7rem 0.85rem; }
.watch-list form { display: flex; gap: 0.35rem; align-items: center; }
.watch-list select { font: inherit; border-radius: 999px; border: 1px solid var(--line); padding: 0.35rem 0.6rem; background: white; }
.pager { display: flex; gap: 0.5rem; margin-top: 1rem; }
.related-links {
  margin: 2.5rem 0 0;
  padding-top: 1rem;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 0.92rem;
}
.related-links h2 { font-size: 1rem; font-weight: 600; color: var(--navy); }
.related-links ul { margin: 0; padding-left: 1.1rem; display: grid; gap: 0.3rem; }
.site-footer {
  background: var(--navy-deep);
  color: #d5e4ea;
  padding: 1.5rem 1rem 2rem;
}
.site-footer a { color: white; }
.foot {
  width: min(1120px, 100%);
  margin: 0 auto;
  display: grid;
  gap: 0.4rem;
}
table { width: 100%; border-collapse: collapse; background: white; border-radius: 12px; overflow: hidden; }
th, td { text-align: left; padding: 0.55rem 0.7rem; border-bottom: 1px solid var(--line); vertical-align: top; }
pre { white-space: pre-wrap; font: inherit; }

@media (max-width: 640px) {
  .chips { gap: 0.28rem; }
  .chips a, .chip.quiet { padding: 0.26rem 0.48rem; font-size: 0.82rem; }
  .nav a { padding: 0.4rem 0.62rem; font-size: 0.9rem; }
  .show-head { grid-template-columns: 88px 1fr; }
  .show-head .cover { width: 88px; height: 88px; }
  .rank { grid-template-columns: auto 48px 1fr; }
  .rank .move { display: none; }
  .actions .btn, .actions form { flex: 1 1 100%; }
  .actions .btn { width: 100%; }
  .wordmark { font-size: 1.7rem; }
}
@media (min-width: 800px) {
  .header-bar {
    grid-template-columns: auto minmax(280px, 1fr);
    grid-template-areas: "logo search" "nav nav";
    padding: 1.25rem 0 0.45rem;
    gap: 0.75rem 1.6rem;
  }
  .logo { grid-area: logo; }
  .header-search { grid-area: search; width: 100%; max-width: 720px; justify-self: end; }
  .header-search .search { width: 100%; }
  .nav { grid-area: nav; padding-bottom: 0.35rem; }
  .wordmark { font-size: 2.15rem; }
  .mark { width: 60px; height: 60px; }
  .logo { min-height: 72px; }
  .grid.toplists { grid-template-columns: repeat(2, 1fr); }
  .grid.cards { grid-template-columns: repeat(2, 1fr); }
  .two { grid-template-columns: 1.2fr 0.8fr; align-items: start; }
  .wrap { padding-top: 1.6rem; }
}
@media (prefers-reduced-motion: reduce) {
  .card, .rank, .episode { transition: none; }
  .card:hover, .rank:hover, .episode:hover { transform: none; }
}
@media (min-width: 1100px) {
  .grid.toplists { grid-template-columns: repeat(3, 1fr); }
  .grid.cards { grid-template-columns: repeat(3, 1fr); }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
}
