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

:root {
  --bg: #f5f4ef;
  --surface: #ffffff;
  --surface-muted: #efeee7;
  --surface-strong: #e6e4db;
  --border: #dbd8ce;
  --border-strong: #c9c4b7;
  --text: #171715;
  --text-secondary: #606158;
  --muted: #808278;
  --accent: #111111;
  --accent-soft: #efeee8;
  --success-bg: #ecf4ee;
  --success-text: #2f5338;
  --warn-bg: #f7f0e1;
  --warn-text: #7a5c22;
  --danger-bg: #f7ecea;
  --danger-text: #8b3731;
  --radius: 18px;
  --radius-sm: 14px;
  --radius-xs: 999px;
  --shadow: 0 8px 22px rgba(17, 17, 17, 0.05);
  --font: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --transition: 180ms ease;
  --player-offset: 88px;
}

html {
  font-size: 15px;
  scroll-behavior: smooth;
}

body {
  font-family: var(--font);
  background: var(--bg);
  color: var(--text);
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

a {
  color: inherit;
  text-decoration: none;
}

img {
  display: block;
  max-width: 100%;
}

button,
input,
select {
  font: inherit;
}

button {
  cursor: pointer;
  border: none;
  background: none;
}

.container {
  width: min(100% - 24px, 1160px);
  margin: 0 auto;
}

.header {
  position: sticky;
  top: 0;
  z-index: 40;
  background: rgba(245, 244, 239, 0.96);
  border-bottom: 1px solid var(--border);
  backdrop-filter: blur(10px);
}

.header-inner {
  display: grid;
  gap: 12px;
  padding: 12px 0;
}

.logo {
  font-size: 1rem;
  font-weight: 800;
  letter-spacing: -0.03em;
}

.logo span {
  color: var(--text-secondary);
  font-weight: 600;
}

.header-nav {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  scrollbar-width: none;
  padding-bottom: 2px;
}

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

.header-nav a {
  flex: 0 0 auto;
  min-height: 38px;
  padding: 0 14px;
  border-radius: var(--radius-xs);
  display: inline-flex;
  align-items: center;
  border: 1px solid transparent;
  background: transparent;
  color: var(--text-secondary);
  font-size: 0.84rem;
  font-weight: 700;
  transition: border-color var(--transition), background var(--transition), color var(--transition);
}

.header-nav a.active,
.header-nav a:hover {
  border-color: var(--border-strong);
  background: var(--surface);
  color: var(--text);
}

main {
  padding-bottom: calc(var(--player-offset) + 28px);
}

.page-shell {
  padding: 24px 0 44px;
}

.home-hero {
  min-height: calc(100vh - 110px);
  display: flex;
  align-items: center;
  padding: 28px 0 40px;
}

.hero-shell {
  display: grid;
  gap: 18px;
}

.hero-copy {
  display: grid;
  gap: 12px;
}

.hero-kicker {
  width: fit-content;
  min-height: 34px;
  padding: 0 12px;
  display: inline-flex;
  align-items: center;
  border-radius: var(--radius-xs);
  background: var(--surface);
  border: 1px solid var(--border);
  color: var(--text-secondary);
  font-size: 0.74rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-weight: 700;
}

.home-hero h1 {
  font-size: clamp(2.1rem, 12vw, 4.1rem);
  line-height: 0.96;
  letter-spacing: -0.07em;
}

.home-hero p {
  color: var(--text-secondary);
  font-size: 0.95rem;
  max-width: 680px;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.button-link,
.load-more-btn,
.search-submit,
.player-primary-btn {
  min-height: 46px;
  padding: 0 16px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius-xs);
  background: var(--surface);
  border: 1px solid var(--border-strong);
  color: var(--text);
  font-weight: 700;
  transition: border-color var(--transition), background var(--transition);
}

.button-link:hover,
.load-more-btn:hover,
.search-submit:hover,
.player-primary-btn:hover {
  border-color: var(--accent);
  background: var(--accent-soft);
}

.button-link:disabled,
.load-more-btn:disabled,
.search-submit:disabled,
.player-primary-btn:disabled {
  opacity: 0.55;
  cursor: not-allowed;
}

.lang-grid {
  display: grid;
  gap: 12px;
}

.lang-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 20px;
  padding: 18px;
  min-height: 150px;
  display: grid;
  gap: 18px;
  transition: border-color var(--transition), transform var(--transition);
}

.lang-card:hover {
  border-color: var(--border-strong);
  transform: translateY(-1px);
}

.lang-card-top {
  display: flex;
  justify-content: space-between;
  gap: 14px;
}

.lang-label {
  font-size: 1.2rem;
  font-weight: 800;
  letter-spacing: -0.03em;
}

.lang-sub {
  color: var(--text-secondary);
  font-size: 0.86rem;
}

.lang-chip,
.pill {
  min-height: 28px;
  padding: 0 10px;
  display: inline-flex;
  align-items: center;
  border-radius: var(--radius-xs);
  background: var(--surface-muted);
  color: var(--text-secondary);
  font-size: 0.72rem;
  font-weight: 700;
}

.lang-card-foot {
  display: flex;
  justify-content: space-between;
  align-items: center;
  color: var(--text-secondary);
  font-size: 0.82rem;
}

.page-header,
.category-page-header,
.search-page-header {
  display: grid;
  gap: 8px;
  margin-bottom: 20px;
}

.page-header h1,
.category-page-header h1,
.search-page-header h1 {
  font-size: clamp(1.9rem, 8vw, 3rem);
  line-height: 0.98;
  letter-spacing: -0.05em;
}

.page-intro,
.category-page-header p,
.search-page-header p {
  color: var(--text-secondary);
  font-size: 0.92rem;
  max-width: 760px;
}

.breadcrumb {
  color: var(--muted);
  font-size: 0.8rem;
}

.feed-section {
  display: grid;
  gap: 28px;
}

.category-block {
  display: grid;
  gap: 14px;
}

.category-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.category-title {
  font-size: 1.06rem;
  font-weight: 800;
  letter-spacing: -0.02em;
}

.view-more-link {
  min-height: 34px;
  padding: 0 12px;
  display: inline-flex;
  align-items: center;
  border-radius: var(--radius-xs);
  border: 1px solid var(--border);
  color: var(--text-secondary);
  font-size: 0.78rem;
  font-weight: 700;
  transition: border-color var(--transition), background var(--transition);
}

.view-more-link:hover {
  border-color: var(--border-strong);
  background: var(--surface);
}

.scroll-row {
  display: flex;
  gap: 12px;
  overflow-x: auto;
  scroll-snap-type: x proximity;
  padding-bottom: 4px;
  scrollbar-width: none;
}

.scroll-row::-webkit-scrollbar {
  display: none;
}

.article-card,
.view-more-card,
.skeleton-card {
  flex: 0 0 248px;
  scroll-snap-align: start;
}

.article-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 20px;
  overflow: hidden;
  display: grid;
  transition: border-color var(--transition), transform var(--transition);
}

.article-card:hover {
  border-color: var(--border-strong);
  transform: translateY(-1px);
}

.article-card-processing {
  border-style: dashed;
}

.article-card-media {
  background: var(--surface-muted);
}

.article-card-image {
  width: 100%;
  height: 152px;
  object-fit: cover;
  background: var(--surface-muted);
}

.article-card-body {
  padding: 14px;
  display: grid;
  gap: 10px;
}

.article-card-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.pill.ready {
  background: var(--success-bg);
  color: var(--success-text);
}

.pill.processing {
  background: var(--warn-bg);
  color: var(--warn-text);
}

.pill.failed {
  background: var(--danger-bg);
  color: var(--danger-text);
}

.article-card-title {
  font-size: 0.92rem;
  font-weight: 800;
  line-height: 1.42;
  letter-spacing: -0.02em;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.article-card-summary {
  color: var(--text-secondary);
  font-size: 0.8rem;
  line-height: 1.55;
  min-height: 3.3em;
  display: -webkit-box;
  -webkit-line-clamp: 4;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.article-card-summary.muted {
  color: var(--muted);
}

.article-card-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
}

.audio-btn,
.player-icon-btn {
  min-height: 36px;
  padding: 0 12px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border-radius: var(--radius-xs);
  background: var(--surface);
  border: 1px solid var(--border);
  color: var(--text-secondary);
  transition: border-color var(--transition), background var(--transition), color var(--transition);
}

.audio-btn:hover,
.player-icon-btn:hover,
.audio-btn.playing {
  border-color: var(--border-strong);
  background: var(--accent-soft);
  color: var(--text);
}

.audio-btn svg,
.player-icon-btn svg,
.view-more-inner svg {
  width: 14px;
  height: 14px;
  flex-shrink: 0;
}

/* ── Natural Voice toggle ────────────────────────────── */
.natural-voice-btn {
  background: linear-gradient(135deg, #f0eaff, #e8f0ff);
  border-color: #c7b8f0;
  color: #5b3fa0;
  font-size: 0.76rem;
  font-weight: 700;
  gap: 5px;
  transition: border-color var(--transition), background var(--transition),
    color var(--transition), transform var(--transition);
}

.natural-voice-btn:hover {
  background: linear-gradient(135deg, #e4d8ff, #d4e4ff);
  border-color: #9b7fdb;
  color: #3d1f8e;
  transform: translateY(-1px);
}

.natural-voice-btn:disabled {
  opacity: 0.65;
  cursor: wait;
  transform: none;
}

.natural-voice-btn.natural-voice-cached {
  background: linear-gradient(135deg, #e4f0e8, #dff0ea);
  border-color: #92c9a4;
  color: #2a6844;
}

.natural-voice-btn.natural-voice-cached:hover {
  background: linear-gradient(135deg, #d4eadb, #c8e8d6);
  border-color: #6db887;
  color: #1f5034;
}

.natural-voice-btn svg {
  width: 12px;
  height: 12px;
}



.article-detail-summary-card .natural-voice-btn {
  min-height: 46px;
  padding: 0 16px;
  border-radius: var(--radius-xs);
}

.inline-status {
  color: var(--muted);
  font-size: 0.76rem;
}

.view-more-card {
  min-height: 100%;
  border-radius: 20px;
  border: 1px dashed var(--border-strong);
  background: var(--surface);
  display: flex;
  align-items: center;
  justify-content: center;
}

.view-more-inner {
  display: grid;
  gap: 8px;
  justify-items: center;
  color: var(--text-secondary);
  font-size: 0.8rem;
  font-weight: 800;
}

.articles-grid,
.search-results-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 14px;
  padding-bottom: 22px;
}

.articles-grid .article-card,
.articles-grid .skeleton-card,
.search-results-grid .article-card,
.search-results-grid .skeleton-card {
  flex: none;
}

.batch-note,
.search-note {
  color: var(--text-secondary);
  font-size: 0.84rem;
  margin-bottom: 14px;
}

.empty-state {
  min-height: 120px;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 24px;
  border-radius: 20px;
  border: 1px dashed var(--border);
  background: var(--surface);
  color: var(--text-secondary);
}

.empty-state.compact {
  min-height: 220px;
  flex: 0 0 248px;
}

.search-layout {
  display: grid;
  gap: 18px;
}

.search-panel {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 20px;
  padding: 14px;
  display: grid;
  gap: 14px;
}

.search-form-grid {
  display: grid;
  gap: 10px;
}

.search-input,
.search-select {
  min-height: 46px;
  border-radius: 14px;
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--text);
  padding: 0 14px;
}

.search-input:focus,
.search-select:focus {
  outline: none;
  border-color: var(--border-strong);
}

.search-footer {
  display: flex;
  justify-content: center;
}

.article-detail {
  display: grid;
  gap: 20px;
}

.article-detail-hero {
  display: grid;
  gap: 14px;
}

.article-detail-media,
.article-detail-summary-card,
.article-detail-body {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 22px;
  overflow: hidden;
}

.article-detail-media img {
  width: 100%;
  max-height: 280px;
  object-fit: cover;
  background: var(--surface-muted);
}

.article-detail-summary-card,
.article-detail-body {
  padding: 18px;
  display: grid;
  gap: 14px;
}

.article-detail-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.article-detail-summary-card h2 {
  font-size: 1.05rem;
  letter-spacing: -0.02em;
}

.article-detail-summary {
  color: var(--text-secondary);
  font-size: 0.94rem;
}

.article-section-label,
.player-section-label {
  color: var(--muted);
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-weight: 800;
}

.article-prose {
  display: grid;
  gap: 14px;
}

.article-prose p {
  font-size: 0.95rem;
  line-height: 1.75;
}

.global-player {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 90;
  pointer-events: none;
}

.global-player:not([hidden]) {
  display: block;
}

.player-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(17, 17, 17, 0.28);
  opacity: 0;
  pointer-events: none;
  transition: opacity 240ms ease;
}

.global-player.expanded .player-backdrop {
  opacity: 1;
  pointer-events: auto;
}

.player-mini {
  width: min(100% - 16px, 760px);
  margin: 0 auto 12px;
  background: rgba(17, 17, 17, 0.96);
  color: #ffffff;
  border-radius: 22px;
  padding: 10px 12px 12px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  grid-template-areas:
    "main actions"
    "progress progress";
  gap: 10px 12px;
  align-items: center;
  pointer-events: auto;
  box-shadow: 0 10px 24px rgba(17, 17, 17, 0.18);
  transition: transform 220ms ease, box-shadow 220ms ease;
}

.global-player.expanded .player-mini {
  transform: translateY(8px) scale(0.985);
  box-shadow: 0 8px 18px rgba(17, 17, 17, 0.12);
}

.player-mini-main {
  grid-area: main;
  display: grid;
  grid-template-columns: 52px minmax(0, 1fr);
  gap: 12px;
  align-items: center;
  min-width: 0;
  background: transparent;
  border: 0;
  padding: 0;
  color: inherit;
  text-align: left;
}

.player-mini-art img,
.player-sheet-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 16px;
  background: #2b2b2b;
}

.player-mini-art {
  width: 52px;
  height: 52px;
}

.player-mini-copy {
  min-width: 0;
  display: grid;
  gap: 3px;
}

.player-mini-title,
.player-mini-subtitle,
.player-sheet-title,
.player-sheet-kicker {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.player-mini-title {
  font-weight: 700;
  font-size: 0.88rem;
}

.player-mini-subtitle {
  color: rgba(255,255,255,0.74);
  font-size: 0.74rem;
}

.player-mini-actions {
  grid-area: actions;
  display: flex;
  align-items: center;
  gap: 8px;
}

.player-mini-actions .player-icon-btn {
  background: rgba(255,255,255,0.08);
  border-color: rgba(255,255,255,0.18);
  color: #fff;
}

.player-sheet-header .player-icon-btn {
  background: rgba(17, 17, 17, 0.05);
  border: 1px solid transparent;
  color: var(--text-secondary);
  font-weight: 600;
  font-size: 0.8rem;
  padding: 6px 14px;
  min-height: 30px;
  border-radius: 999px;
  box-shadow: none;
  transition: all 180ms ease;
}

.player-sheet-header .player-icon-btn:hover {
  background: rgba(17, 17, 17, 0.09);
  color: var(--text);
  border-color: transparent;
}

.player-mini-actions .player-mini-close-btn {
  background: transparent;
  border-color: transparent;
  color: rgba(255,255,255,0.6);
}

.player-mini-actions .player-mini-close-btn:hover {
  background: rgba(255,255,255,0.1);
  color: #fff;
}

.player-mini-progress {
  grid-area: progress;
  display: grid;
  gap: 6px;
}

.player-mini-progress-bar {
  width: 100%;
  height: 4px;
  border-radius: 999px;
  background: rgba(255,255,255,0.14);
  overflow: hidden;
}

.player-mini-progress-bar span {
  display: block;
  width: 0;
  height: 100%;
  border-radius: inherit;
  background: rgba(255,255,255,0.92);
  transition: width 140ms linear;
}

.player-mini-times {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  color: rgba(255,255,255,0.64);
  font-size: 0.7rem;
}

.player-sheet {
  position: fixed;
  inset: auto 0 0 0;
  background: rgba(245, 244, 239, 0.98);
  border-top-left-radius: 28px;
  border-top-right-radius: 28px;
  padding: 10px 14px calc(22px + env(safe-area-inset-bottom));
  transform: translateY(102%);
  transition: transform 280ms cubic-bezier(0.22, 1, 0.36, 1);
  pointer-events: auto;
  max-height: min(88vh, 760px);
  overflow: hidden;
  box-shadow: 0 -18px 42px rgba(17, 17, 17, 0.18);
  display: grid;
  grid-template-rows: auto auto 1fr;
}

.global-player.expanded .player-sheet {
  transform: translateY(0);
}

.player-sheet-handle {
  width: 52px;
  height: 5px;
  border-radius: 999px;
  background: rgba(17, 17, 17, 0.14);
  margin: 0 auto 10px;
}

.player-sheet-header {
  display: flex;
  justify-content: flex-end;
  margin-bottom: 8px;
  position: sticky;
  top: 0;
  z-index: 2;
  padding-bottom: 6px;
  background: linear-gradient(to bottom, rgba(245, 244, 239, 0.98), rgba(245, 244, 239, 0.88), rgba(245, 244, 239, 0));
}

.player-sheet-body {
  display: grid;
  gap: 20px;
  overflow: auto;
  padding: 2px 4px 0;
  overscroll-behavior: contain;
}

.player-hero {
  display: grid;
  gap: 16px;
  align-items: start;
}

.player-sheet-image {
  width: 100%;
  aspect-ratio: 1 / 1;
  box-shadow: 0 18px 34px rgba(17, 17, 17, 0.08);
}

.player-hero-copy {
  display: grid;
  gap: 8px;
}

.player-sheet-kicker {
  color: var(--muted);
  font-size: 0.76rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-weight: 800;
}

.player-sheet-title {
  font-size: 1.32rem;
  letter-spacing: -0.03em;
  line-height: 1.18;
  white-space: normal;
  overflow: visible;
  text-overflow: unset;
}

.player-controls {
  display: grid;
  gap: 12px;
  padding: 18px;
  border-radius: 24px;
  background: rgba(255,255,255,0.58);
  border: 1px solid rgba(17, 17, 17, 0.06);
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.38);
}

.player-timeline {
  display: grid;
  grid-template-columns: 44px minmax(0, 1fr) 44px;
  align-items: center;
  gap: 10px;
  color: var(--text-secondary);
  font-size: 0.76rem;
}

#player-seek {
  width: 100%;
  accent-color: var(--text);
}

.player-buttons {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 12px;
}

.player-buttons .player-sheet-toggle {
  width: 56px;
  height: 56px;
  min-width: 56px;
  border-radius: 999px;
  background: var(--accent);
  color: #ffffff;
  border: 1px solid var(--accent);
  box-shadow: 0 4px 12px rgba(17, 17, 17, 0.16);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: all 200ms ease;
  padding: 0;
}

.player-buttons .player-sheet-toggle:hover {
  background: #2b2b2b;
  border-color: #2b2b2b;
  color: #ffffff;
  transform: scale(1.05);
  box-shadow: 0 6px 20px rgba(17, 17, 17, 0.24);
}

.player-buttons .player-sheet-toggle svg {
  width: 22px;
  height: 22px;
  display: block;
}

.player-buttons .player-skip-btn {
  min-width: 48px;
  min-height: 48px;
  border-radius: 999px;
  background: transparent;
  border: 1px solid rgba(17, 17, 17, 0.08);
  color: var(--text);
  transition: all 200ms ease;
}

.player-buttons .player-skip-btn:hover {
  background: rgba(17, 17, 17, 0.05);
  border-color: rgba(17, 17, 17, 0.16);
  color: var(--text);
}

.player-transcript {
  display: grid;
  gap: 10px;
}

.player-transcript-note {
  margin: 0;
  color: var(--muted);
  font-size: 0.78rem;
  line-height: 1.55;
}

.player-transcript-list {
  display: block;
  max-height: min(34vh, 280px);
  overflow: auto;
  padding-right: 2px;
}

.transcript-words-container {
  font-size: 1.15rem;
  line-height: 1.75;
  color: rgba(23, 23, 21, 0.3);
  text-align: left;
  font-weight: 500;
  padding: 18px 22px;
  background: #f8f7f5;
  border-radius: 16px;
  border: 1px solid rgba(23, 23, 21, 0.04);
  box-shadow: inset 0 2px 8px rgba(23, 23, 21, 0.02);
}

.transcript-word {
  display: inline;
  transition: color 150ms ease, font-weight 150ms ease;
  cursor: pointer;
}

.transcript-word.active {
  color: #3b3b38;
  font-weight: 700;
}

.transcript-word.spoken {
  color: rgba(23, 23, 21, 0.55);
}

.transcript-word:hover:not(.active) {
  color: rgba(23, 23, 21, 0.45);
}

.transcript-empty {
  color: var(--muted);
  font-size: 0.86rem;
}

.skeleton-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 20px;
  overflow: hidden;
}

.skeleton-img,
.skeleton-line,
.skeleton-chip,
.skeleton-action {
  background: #e5e2d9;
  animation: pulse 1.45s ease-in-out infinite;
}

.skeleton-img {
  width: 100%;
  height: 152px;
}

.skeleton-body {
  padding: 14px;
  display: grid;
  gap: 10px;
}

.skeleton-chip-row {
  display: flex;
  gap: 8px;
}

.skeleton-chip {
  width: 72px;
  height: 28px;
  border-radius: var(--radius-xs);
}

.skeleton-chip.short {
  width: 52px;
}

.skeleton-line {
  height: 12px;
  border-radius: 999px;
}

.skeleton-line.title {
  height: 16px;
  width: 88%;
}

.skeleton-line.short {
  width: 56%;
}

.skeleton-action {
  width: 112px;
  height: 36px;
  border-radius: var(--radius-xs);
}

.skeleton-stack {
  display: grid;
  gap: 8px;
}

@keyframes pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.56; }
}

.error-page {
  min-height: calc(100vh - 110px);
  display: grid;
  place-items: center;
  padding: 28px 0 40px;
}

.error-card {
  width: min(100%, 420px);
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 24px;
  padding: 24px;
  display: grid;
  gap: 12px;
  text-align: center;
}

.error-card h1 {
  font-size: 3rem;
  letter-spacing: -0.06em;
}

.error-card p {
  color: var(--text-secondary);
}

.footer {
  border-top: 1px solid var(--border);
  padding: 18px 0 calc(18px + env(safe-area-inset-bottom));
  color: var(--muted);
  font-size: 0.74rem;
}

@media (min-width: 720px) {
  :root {
    --player-offset: 96px;
  }

  .header-inner {
    grid-template-columns: auto 1fr;
    align-items: center;
  }

  .header-nav {
    justify-content: flex-end;
  }

  .hero-shell {
    gap: 24px;
  }

  .lang-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .articles-grid,
  .search-results-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .search-form-grid {
    grid-template-columns: minmax(0, 1fr) 150px 132px;
  }

  .article-detail-hero {
    grid-template-columns: minmax(0, 1.1fr) minmax(320px, 0.9fr);
    align-items: start;
  }

  .player-mini {
    width: min(100% - 24px, 860px);
  }

  .player-sheet {
    left: 50%;
    right: auto;
    width: min(100%, 860px);
    transform: translate(-50%, 102%);
    border-top-left-radius: 30px;
    border-top-right-radius: 30px;
  }

  .global-player.expanded .player-sheet {
    transform: translate(-50%, 0);
  }

  .player-hero {
    grid-template-columns: 220px minmax(0, 1fr);
    align-items: center;
  }

  .player-sheet-image {
    max-width: 220px;
  }
}

@media (max-width: 560px) {
  .player-mini {
    grid-template-columns: 1fr;
    grid-template-areas:
      "main"
      "actions"
      "progress";
  }

  .player-mini-actions {
    justify-content: space-between;
  }

  .player-buttons {
    gap: 10px;
  }



  .player-sheet {
    max-height: 90vh;
    padding-left: 12px;
    padding-right: 12px;
  }

  .player-sheet-body {
    gap: 18px;
    padding-left: 0;
    padding-right: 0;
  }
}

@media (min-width: 980px) {
  .articles-grid,
  .search-results-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}
