html {
  scrollbar-gutter: stable;
}

* {
  box-sizing: border-box;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  margin: 0;
  padding: 0;
  background: var(--bg);
  color: var(--fg);
  line-height: 1.5;
}

a {
  color: var(--link);
  text-decoration: none;
}

a:hover {
  color: var(--link-hover);
  text-decoration: underline;
}

ul,
ol {
  padding-left: 40px;
}

table {
  width: 100%;
  border-collapse: collapse;
}

th {
  color: var(--fg);
  padding: 0.75rem;
  text-align: left;
  font-weight: 600;
  border-bottom: 2px solid var(--border);
}

th.sortable {
  cursor: pointer;
  user-select: none;
}

th.sortable[data-dir="asc"]::after {
  content: " ↑";
  color: var(--link);
}

th.sortable[data-dir="desc"]::after {
  content: " ↓";
  color: var(--link);
}

td {
  padding: 0.75rem;
  border-top: 1px solid var(--border);
}

td:has(.badge) {
  white-space: nowrap;
}

td[data-label="Najnowszy"] {
  white-space: nowrap;
}

tr:first-child td {
  border-top: none;
}

.hidden {
  display: none;
}

.muted {
  color: var(--fg-muted);
  font-size: 0.9rem;
}

.badge {
  display: inline-block;
  padding: 0.25rem 0.5rem;
  border-radius: 3px;
  font-size: 0.85rem;
  margin-right: 0.5rem;
  color: white;
}

.badge-rss {
  background: #ff6600;
}

.badge-atom {
  background: #666;
}

.feed {
  display: inline-flex;
  align-items: center;
  margin-right: 1rem;
}

.feed:last-child {
  margin-right: 0;
}

.feed .badge {
  margin-right: 0.4rem;
}

.validate {
  color: var(--fg);
  font-size: 1.05rem;
  font-weight: 700;
  text-decoration: none;
  transition: color 0.15s ease;
}

.validate:hover {
  color: var(--link);
  text-decoration: none;
}

.page {
  max-width: 760px;
  margin: 0 auto;
  padding: 24px 16px;
  box-sizing: content-box;
}

@media (max-width: 768px) {
  th {
    display: none;
  }

  td {
    display: block;
    padding: 0.5rem;
    border-top: none;
    border-bottom: 1px solid var(--border);
  }

  td:last-child {
    border-bottom: none;
  }

  td::before {
    content: attr(data-label) ": ";
    font-weight: 600;
    display: inline-block;
    min-width: 100px;
  }
}

.info-content,
.content,
.summary {
  line-height: 1.7;
}

.info-content a,
.content a,
.summary a {
  color: var(--link);
}

.info-content img,
.content img,
.summary img {
  max-width: 100%;
  height: auto;
}

.info-content pre,
.content pre,
.summary pre {
  padding: 0.75rem;
  overflow-x: auto;
  border-radius: 6px;
  background: var(--bg);
}

.info-content code,
.content code,
.summary code {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
}

.info-content blockquote,
.content blockquote,
.summary blockquote {
  margin: 0;
  padding-left: 1rem;
  border-left: 3px solid var(--border);
  color: var(--fg-muted);
}

.info-content table,
.content table,
.summary table {
  width: 100%;
  border-collapse: collapse;
}

.info-content th,
.info-content td,
.content th,
.content td,
.summary th,
.summary td {
  padding: 0.35rem 0.5rem;
  border: 1px solid var(--border);
  text-align: left;
}
