/* Portal header colours from digihitch.com (~2001–2010); content area stays readable */
:root {
  --bg: #ddd;
  --surface: #fff;
  --text: #333;
  --muted: #555;
  --accent: #8b7500;
  --accent-hover: #6b5a00;
  --border: #bbb;
  --portal-bg: #333;
  --portal-border: #1a331a;
  --portal-gold: #bdb76b;
  --portal-yellow: #e6d200;
  --portal-red: #c00;
  --spot: #166534;
  --layout-max: 76rem;
  --layout-pad: clamp(1rem, 2.5vw, 2rem);
  font-family: Verdana, "Bitstream Vera Sans", "Segoe UI", system-ui, sans-serif;
  font-size: 12px;
  line-height: 1.55;
  color: var(--text);
  background: var(--bg);
}

@media (min-width: 1400px) {
  :root {
    --layout-max: 88rem;
  }
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

.layout-wrap {
  width: 100%;
  max-width: var(--layout-max);
  margin-left: auto;
  margin-right: auto;
  padding-left: var(--layout-pad);
  padding-right: var(--layout-pad);
}

.site-header {
  background: var(--portal-bg);
  border-top: 3px solid var(--portal-border);
  border-bottom: 3px solid var(--portal-border);
  position: sticky;
  top: 0;
  z-index: 10;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.25);
}

.header-inner {
  padding-top: 0.35rem;
  padding-bottom: 0.5rem;
}

.banner-link {
  display: block;
  line-height: 0;
  padding: 0.35rem 0 0.15rem;
}

.site-banner {
  display: block;
  width: 100%;
  max-width: 30.25rem;
  height: auto;
}

.site-toolbar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.65rem 1.25rem;
  padding-top: 0.65rem;
  padding-bottom: 0.35rem;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  margin-top: 0.35rem;
}

.archive-badge {
  margin: 0;
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--portal-red);
}

.nav {
  display: flex;
  flex-wrap: wrap;
  gap: 0.65rem 1rem;
  flex: 1;
}

.nav a {
  color: var(--portal-yellow);
  text-decoration: none;
  font-size: 0.95rem;
  font-weight: 600;
}

.nav a:hover {
  color: #fff;
}

.nav a.active {
  color: var(--portal-bg);
  background: var(--portal-yellow);
  padding: 0.2rem 0.55rem;
  border-radius: 3px;
  text-decoration: none;
}

.search-wrap {
  flex: 1 1 14rem;
  min-width: 10rem;
  max-width: 22rem;
  margin-left: auto;
}

#search-input {
  width: 100%;
  padding: 0.45rem 0.75rem;
  border: 1px solid var(--border);
  border-radius: 4px;
  font-size: 0.95rem;
  background: #fff;
}

#app {
  flex: 1;
  padding-top: 1.75rem;
  padding-bottom: 3rem;
  font-size: 1rem;
}

.loading {
  color: var(--muted);
}

.hero {
  margin-bottom: 2rem;
}

.hero h1 {
  font-size: 1.75rem;
  margin: 0 0 0.5rem;
  line-height: 1.25;
}

.hero .lead {
  color: var(--muted);
  font-size: 1.05rem;
}

.stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(10rem, 1fr));
  gap: 1rem;
  margin: 1.5rem 0;
}

.stat {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 1rem 1.15rem;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.06);
}

.stat strong {
  display: block;
  font-size: 1.4rem;
  color: var(--accent);
}

.stat span {
  font-size: 0.85rem;
  color: var(--muted);
}

.notice {
  background: #fff8e6;
  border: 1px solid #e8d48a;
  border-radius: 8px;
  padding: 1rem 1.25rem;
  margin: 1.5rem 0;
  font-size: 0.95rem;
}

.notice strong {
  color: #854d0e;
}

.list-header {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  flex-wrap: wrap;
  gap: 0.5rem 1rem;
  margin-bottom: 1.25rem;
  padding-bottom: 0.75rem;
  border-bottom: 2px solid #ccc;
}

.list-header h1 {
  margin: 0;
  font-size: 1.85rem;
  font-weight: 700;
}

.list-header .meta {
  font-size: 1rem;
  color: var(--muted);
  white-space: nowrap;
}

.card-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  gap: 0.85rem;
  grid-template-columns: 1fr;
}

@media (min-width: 720px) {
  .card-list {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (min-width: 1100px) {
  .card-list {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

.card-list li {
  margin: 0;
  min-width: 0;
}

.card {
  display: flex;
  flex-direction: column;
  height: 100%;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 1rem 1.15rem;
  text-decoration: none;
  color: inherit;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.08);
  transition: border-color 0.15s, box-shadow 0.15s;
}

.card:hover {
  border-color: var(--accent);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.card h2 {
  margin: 0.35rem 0 0.3rem;
  font-size: 1.05rem;
  font-weight: 700;
  line-height: 1.3;
}

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

.card .excerpt {
  margin: 0.35rem 0 0;
  font-size: 0.88rem;
  color: var(--muted);
  line-height: 1.45;
  flex: 1;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.badge {
  display: inline-block;
  font-size: 0.7rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  padding: 0.15rem 0.45rem;
  border-radius: 4px;
  margin-right: 0.35rem;
}

.badge-spot {
  background: #dcfce7;
  color: var(--spot);
}

.badge-eu {
  background: #dbeafe;
  color: #1e40af;
}

.badge-can {
  background: #fce7f3;
  color: #9d174d;
}

.article-header {
  margin-bottom: 1.5rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid var(--border);
}

.article-header h1 {
  margin: 0 0 0.5rem;
  font-size: 1.65rem;
  line-height: 1.25;
}

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

.article-meta .views-frozen {
  font-size: 0.85em;
  white-space: nowrap;
}

.spot-facts {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(10rem, 1fr));
  gap: 0.5rem 1rem;
  background: #ecfdf5;
  border: 1px solid #a7f3d0;
  border-radius: 8px;
  padding: 1rem;
  margin-bottom: 1.5rem;
  font-size: 0.9rem;
}

.spot-facts dt {
  font-weight: 600;
  color: var(--spot);
  margin: 0;
}

.spot-facts dd {
  margin: 0 0 0.5rem;
}

.article-body {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 1.5rem clamp(1.25rem, 3vw, 2.5rem);
  font-size: 1.05rem;
  line-height: 1.6;
  max-width: none;
}

.article-body img {
  max-width: 100%;
  height: auto;
}

.article-body a {
  color: var(--accent);
}

.back-link {
  display: inline-block;
  margin-bottom: 1rem;
  color: var(--muted);
  text-decoration: none;
  font-size: 0.9rem;
}

.back-link:hover {
  color: var(--accent);
}

.forum-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.9rem;
  background: var(--surface);
  border-radius: 8px;
  overflow: hidden;
  border: 1px solid var(--border);
}

.forum-table th,
.forum-table td {
  padding: 0.5rem 0.75rem;
  text-align: left;
  border-bottom: 1px solid var(--border);
}

.forum-table th {
  background: #dce1e5;
  font-weight: 600;
  color: var(--text);
}

.site-footer {
  border-top: 1px solid var(--border);
  padding: 1.25rem 0;
  font-size: 0.85rem;
  color: var(--muted);
  background: var(--surface);
}

.site-footer a {
  color: var(--accent);
}

.footer-inner p {
  margin: 0 0 0.5rem;
}

.footer-links {
  font-size: 0.8rem;
}

.legal-hint {
  font-size: 0.9rem;
  color: var(--muted);
  margin: 1rem 0;
}

.legal-page .article-body h2 {
  font-size: 1.1rem;
  margin: 1.25rem 0 0.5rem;
}

.legal-page .article-body ul {
  padding-left: 1.25rem;
}

.empty {
  color: var(--muted);
  font-style: italic;
}

.serve-cmd {
  background: #1a1a1a;
  color: #f6f3ed;
  padding: 0.75rem 1rem;
  border-radius: 6px;
  overflow-x: auto;
  font-size: 0.85rem;
  margin: 0.75rem 0;
}

.salman-page .salman-photo {
  float: right;
  margin: 0 0 1.25rem 1.5rem;
  max-width: min(100%, 220px);
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 0.5rem;
}

.salman-page .salman-photo img {
  display: block;
  width: 100%;
  height: auto;
  border-radius: 4px;
}

.salman-page .salman-photo figcaption {
  margin-top: 0.5rem;
  font-size: 0.8rem;
  line-height: 1.4;
  color: var(--muted);
}

.salman-page .salman-body h2 {
  font-size: 1.15rem;
  margin: 1.5rem 0 0.5rem;
  clear: both;
}

.salman-page .salman-body ul {
  padding-left: 1.25rem;
}

@media (max-width: 520px) {
  .salman-page .salman-photo {
    float: none;
    margin: 0 auto 1.25rem;
  }
}

@media (max-width: 600px) {
  .site-toolbar {
    flex-direction: column;
    align-items: stretch;
  }
  .search-wrap {
    margin-left: 0;
    max-width: none;
  }
  .nav {
    width: 100%;
    justify-content: flex-start;
  }
  .card-list {
    grid-template-columns: 1fr;
  }
}
