:root {
  --bg: #f3efe7;
  --ink: #1b2421;
  --muted: #4d5c56;
  --card: #fffaf0;
  --line: #d9ccbb;
  --accent: #125e4a;
  --accent-2: #b85c24;
  --ok: #2f7d32;
}

* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  padding: 0;
  min-height: 100%;
}

body {
  font-family: "Space Grotesk", sans-serif;
  color: var(--ink);
  background: radial-gradient(circle at 18% 0%, #e8efe4 0%, var(--bg) 45%),
    linear-gradient(145deg, #f8f2e8 0%, #f3efe7 55%, #ebe1d3 100%);
}

.bg-shape {
  position: fixed;
  border-radius: 999px;
  filter: blur(30px);
  opacity: 0.45;
  pointer-events: none;
}

.bg-shape-a {
  width: 230px;
  height: 230px;
  background: #df8d58;
  top: -50px;
  right: 12vw;
}

.bg-shape-b {
  width: 300px;
  height: 300px;
  background: #82b79a;
  bottom: -110px;
  left: -20px;
}

.page {
  width: min(1080px, 92vw);
  margin: 28px auto 48px;
  position: relative;
  z-index: 2;
}

.hero {
  margin-bottom: 18px;
}

.eyebrow {
  margin: 0 0 6px;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--muted);
  font-weight: 700;
  font-size: 0.72rem;
}

h1 {
  margin: 0;
  font-family: "Source Serif 4", serif;
  font-size: clamp(2rem, 4.7vw, 3.2rem);
  line-height: 1;
}

.sub {
  margin: 8px 0 0;
  color: var(--muted);
}

.card {
  background: color-mix(in oklab, var(--card) 93%, white 7%);
  border: 1px solid var(--line);
  border-radius: 16px;
  box-shadow: 0 10px 28px rgba(34, 49, 44, 0.08);
  padding: 16px;
  margin-bottom: 14px;
}

.controls-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
}

label {
  display: grid;
  gap: 6px;
  font-size: 0.88rem;
  color: var(--muted);
}

input,
select {
  appearance: none;
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 10px 12px;
  font: inherit;
  color: var(--ink);
  background: #fffdf9;
}

input:focus,
select:focus {
  outline: 2px solid color-mix(in oklab, var(--accent) 40%, white 60%);
  border-color: var(--accent);
}

.actions {
  margin-top: 12px;
  display: flex;
  gap: 8px;
  align-items: center;
  flex-wrap: wrap;
}

.btn {
  border: 1px solid transparent;
  background: var(--accent);
  color: #f9fff8;
  border-radius: 10px;
  padding: 8px 12px;
  font: inherit;
  font-weight: 600;
  cursor: pointer;
}

.btn:hover {
  filter: brightness(0.95);
}

.btn-ghost {
  border-color: var(--line);
  color: var(--ink);
  background: transparent;
}

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

.hint {
  margin: 6px 0 10px;
  color: var(--muted);
  font-size: 0.85rem;
}

.admin-grid .actions {
  margin-top: 8px;
}

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

h2 {
  margin: 4px 0 2px;
  font-family: "Source Serif 4", serif;
}

.pager {
  display: flex;
  gap: 8px;
  align-items: center;
}

.articles {
  margin-top: 12px;
  display: grid;
  gap: 10px;
}

.article {
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 12px;
  background: #fffdf8;
}

.article-top {
  display: flex;
  justify-content: space-between;
  align-items: start;
  gap: 10px;
}

.article h3 {
  margin: 0;
  font-size: 1.02rem;
}

.article a {
  color: var(--ink);
  text-decoration-thickness: 1px;
  text-decoration-color: color-mix(in oklab, var(--accent) 40%, white 60%);
}

.meta {
  margin-top: 6px;
  font-size: 0.85rem;
  color: var(--muted);
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.pill {
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 2px 9px;
  font-size: 0.73rem;
}

.premium {
  border-color: #d99e73;
  color: #8a3f10;
  background: #fff2e8;
}

.empty {
  color: var(--muted);
  font-size: 0.92rem;
  border: 1px dashed var(--line);
  border-radius: 12px;
  padding: 16px;
  text-align: center;
}

@media (max-width: 900px) {
  .controls-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 640px) {
  .page {
    width: min(1100px, 95vw);
  }

  .controls-grid {
    grid-template-columns: 1fr;
  }

  .results-head {
    flex-direction: column;
    align-items: flex-start;
  }
}
