:root {
  --sdl-ink: #243126;
  --sdl-muted: #687268;
  --sdl-accent: #72552d;
  --sdl-accent-dark: #4f391c;
  --sdl-paper: #fffdf7;
  --sdl-line: #e2dac9;
  --sdl-soft: #f4efe4;
}

.sdl-magazine-archive,
.sdl-issue-reader {
  color: var(--sdl-ink);
  font-family: "Noto Naskh Arabic", "Amiri", Tahoma, serif;
}

.sdl-archive-search label {
  display: block;
  margin: 0 0 .65rem;
  font-size: 1.05rem;
  font-weight: 800;
}

.sdl-search-row {
  display: flex;
  gap: .5rem;
}

.sdl-search-row input {
  min-width: 0;
  flex: 1;
  padding: .72rem .85rem;
  border: 1px solid var(--sdl-line);
  border-radius: 9px;
  background: white;
}

.sdl-search-row button,
.sdl-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: .72rem 1rem;
  border: 1px solid var(--sdl-accent);
  border-radius: 9px;
  background: var(--sdl-accent);
  color: white;
  font: inherit;
  font-weight: 700;
  text-decoration: none;
  cursor: pointer;
}

.sdl-button-secondary {
  background: white;
  color: var(--sdl-accent-dark);
}

.sdl-actions {
  display: flex;
  flex-wrap: wrap;
  gap: .75rem;
  margin-bottom: 1rem;
}

.sdl-issue-reader iframe {
  width: 100%;
  min-height: 75vh;
  border: 1px solid var(--sdl-line);
  border-radius: 12px;
  background: var(--sdl-soft);
}

.sdl-issue-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(190px, 1fr));
  gap: 1.2rem;
  margin-top: 1.5rem;
}

.sdl-issue-card {
  overflow: hidden;
  border: 1px solid var(--sdl-line);
  border-radius: 14px;
  background: var(--sdl-paper);
  box-shadow: 0 8px 22px rgba(49, 38, 24, .06);
}

.sdl-issue-card > a {
  display: block;
  height: 100%;
  padding: .8rem;
  color: inherit;
  text-decoration: none;
}

.sdl-issue-card img,
.sdl-cover-placeholder {
  display: flex;
  width: 100%;
  aspect-ratio: 3 / 4;
  align-items: center;
  justify-content: center;
  border-radius: 9px;
  object-fit: cover;
  background: linear-gradient(145deg, #a98b59, #4c321b);
  color: white;
  text-align: center;
  font-size: 1.5rem;
  font-weight: 800;
}

.sdl-issue-card h2 {
  margin: .8rem 0 .35rem;
  font-size: 1rem;
  line-height: 1.55;
}

.sdl-issue-card p {
  margin: 0;
  color: var(--sdl-muted);
  font-family: Tahoma, sans-serif;
  font-size: .78rem;
}

.sdl-pagination {
  display: flex;
  flex-wrap: wrap;
  gap: .4rem;
  justify-content: center;
  margin-top: 2rem;
}

.sdl-pagination .page-numbers {
  padding: .45rem .75rem;
  border: 1px solid var(--sdl-line);
  border-radius: 7px;
}

.sdl-pagination .current {
  background: var(--sdl-accent);
  color: white;
}

.sdl-empty {
  color: var(--sdl-muted);
}

@media (max-width: 800px) {
  .sdl-search-row {
    flex-direction: column;
  }
}
