/* ==========================================================
   Magazine archive: Empire Editions
   ========================================================== */
.magazine-archive-page {
  --ink: #1f1a14;
  --ink-soft: #2c251d;
  --muted: #6b6254;
  --line: #e6ded3;
  --paper: #fffdf9;
  --cream: #f6f1e9;
  --gold: #b5892a;
  --gold-light: #d9b35a;
  --gold-dark: #8f6a1a;
  background: var(--cream);
  color: var(--ink);
}

.magazine-archive-page [hidden] { display: none !important; }
.magazine-archive-page ul { list-style: none; margin: 0; padding: 0; }
.magazine-archive-page a { text-decoration: none; }

/* ---------- Hero ---------- */
.arc-hero {
  position: relative;
  overflow: hidden;
  padding: clamp(56px, 9vw, 110px) 24px clamp(48px, 7vw, 80px);
  color: #fff;
  background:
    radial-gradient(900px 400px at 85% -10%, rgba(181, 137, 42, 0.28), transparent 60%),
    linear-gradient(135deg, #14100b 0%, var(--ink-soft) 100%);
  border-bottom: 4px solid var(--gold);
}

/* oversized outlined word behind the title */
.arc-hero::before {
  content: "ARCHIVE";
  position: absolute;
  right: -2vw;
  bottom: -0.28em;
  font: 900 clamp(7rem, 22vw, 20rem)/1 "Playfair Display", serif;
  letter-spacing: 0.02em;
  color: transparent;
  -webkit-text-stroke: 1px rgba(255, 255, 255, 0.07);
  pointer-events: none;
  user-select: none;
}

/* thin gold rules */
.arc-hero::after {
  content: "";
  position: absolute;
  inset: 0;
  background: repeating-linear-gradient(90deg, transparent 0 119px, rgba(255, 255, 255, 0.03) 119px 120px);
  pointer-events: none;
}

.arc-hero__inner {
  position: relative;
  z-index: 1;
  max-width: 1180px;
  margin: 0 auto;
}

.arc-kicker {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 8px 14px;
  font: 600 0.72rem/1 "Inter", sans-serif;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--gold-light);
  border: 1px solid rgba(217, 179, 90, 0.5);
}

.arc-hero__title {
  margin: 22px 0 18px;
  font: 900 clamp(2.8rem, 8vw, 6rem)/0.98 "Playfair Display", serif;
  letter-spacing: -0.02em;
  text-transform: uppercase;
}

.arc-hero__title em {
  display: block;
  font-style: italic;
  font-weight: 400;
  text-transform: none;
  color: var(--gold-light);
}

.arc-hero__text {
  max-width: 620px;
  margin: 0;
  font: 300 1.08rem/1.75 "Inter", sans-serif;
  color: rgba(255, 255, 255, 0.78);
}

.arc-hero__cta {
  margin-top: 28px;
}

.arc-hero__stats {
  display: flex;
  flex-wrap: wrap;
  gap: 0;
  margin-top: 40px;
  border-top: 1px solid rgba(255, 255, 255, 0.18);
}

.arc-hero__stats > div {
  padding: 18px 40px 0 0;
  margin-right: 40px;
  border-right: 1px solid rgba(255, 255, 255, 0.14);
}

.arc-hero__stats > div:last-child { border-right: 0; }

.arc-hero__stats strong {
  display: block;
  font: 700 2rem/1 "Playfair Display", serif;
  color: #fff;
}

.arc-hero__stats span {
  display: block;
  margin-top: 6px;
  font: 500 0.7rem/1 "Inter", sans-serif;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.55);
}

/* ---------- Controls ---------- */
.arc-controls {
  position: sticky;
  top: 0;
  z-index: 20;
  background: rgba(255, 253, 249, 0.96);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--line);
  box-shadow: 0 8px 24px rgba(76, 61, 45, 0.06);
}

.arc-controls__inner {
  max-width: 1180px;
  margin: 0 auto;
  padding: 16px 24px;
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.arc-search {
  position: relative;
  display: flex;
  align-items: center;
  background: #fff;
  border: 1px solid var(--ink);
  border-radius: 0;
  transition: box-shadow 0.25s ease, border-color 0.25s ease;
}

.arc-search:focus-within {
  border-color: var(--gold);
  box-shadow: 4px 4px 0 var(--gold);
}

.arc-search > i {
  padding: 0 14px 0 18px;
  color: var(--gold-dark);
}

.arc-search input {
  flex: 1;
  min-width: 0;
  padding: 15px 8px;
  font: 400 0.98rem/1.2 "Inter", sans-serif;
  color: var(--ink);
  background: transparent;
  border: 0;
  outline: 0;
  border-radius: 0;
}

.arc-search__clear {
  padding: 0 18px;
  align-self: stretch;
  color: var(--muted);
  background: transparent;
  border: 0;
  border-left: 1px solid var(--line);
  border-radius: 0;
  cursor: pointer;
}

.arc-search__clear:hover { color: var(--ink); background: var(--cream); }

.arc-pills {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  padding-bottom: 2px;
  scrollbar-width: thin;
}

.magazine-archive-page .filter-pill {
  flex: 0 0 auto;
  padding: 10px 18px;
  font: 600 0.74rem/1 "Inter", sans-serif;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--ink);
  background: transparent;
  border: 1px solid var(--line);
  border-radius: 0;
  cursor: pointer;
  transition: background 0.2s ease, color 0.2s ease, border-color 0.2s ease;
}

.magazine-archive-page .filter-pill:hover { border-color: var(--ink); }

.magazine-archive-page .filter-pill.active {
  color: #fff;
  background: var(--ink);
  border-color: var(--ink);
}

.magazine-archive-page .filter-pill:focus-visible,
.arc-btn:focus-visible,
.arc-link:focus-visible,
.arc-card__cover:focus-visible,
.arc-spotlight__cover:focus-visible {
  outline: 3px solid var(--gold);
  outline-offset: 3px;
}

/* ---------- Library ---------- */
.arc-library {
  max-width: 1180px;
  margin: 0 auto;
  padding: 56px 24px 90px;
  scroll-margin-top: 92px;
}

.arc-library__head {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 36px;
  padding-bottom: 16px;
  border-bottom: 2px solid var(--ink);
}

.arc-section-kicker {
  display: block;
  margin-bottom: 8px;
  font: 600 0.72rem/1 "Inter", sans-serif;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--gold-dark);
}

.arc-library__head h2 {
  margin: 0;
  font: 700 clamp(1.5rem, 3.4vw, 2.2rem)/1.15 "Playfair Display", serif;
}

.arc-count {
  padding: 8px 14px;
  font: 600 0.74rem/1 "Inter", sans-serif;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: #fff;
  background: var(--ink);
  border-radius: 0;
}

/* ---------- Buttons ---------- */
.arc-btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 14px 24px;
  font: 600 0.78rem/1 "Inter", sans-serif;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  border: 1px solid var(--ink);
  border-radius: 0;
  cursor: pointer;
  transition: background 0.25s ease, color 0.25s ease, gap 0.25s ease, border-color 0.25s ease;
}

.arc-btn--solid { color: #fff; background: var(--ink); }
.arc-btn--solid:hover { background: var(--gold-dark); border-color: var(--gold-dark); gap: 14px; }
.arc-btn--ghost { color: var(--ink); background: transparent; }
.arc-btn--ghost:hover { background: var(--ink); color: #fff; }
.arc-btn--sm { padding: 10px 14px; font-size: 0.68rem; }

.arc-link {
  font: 600 0.72rem/1 "Inter", sans-serif;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--ink);
  padding-bottom: 3px;
  border-bottom: 2px solid var(--gold);
}
.arc-link:hover { color: var(--gold-dark); }

/* ---------- Spotlight (latest edition) ---------- */
.arc-spotlight-wrap:not(:empty) { margin-bottom: 56px; }

.arc-spotlight {
  position: relative;
  display: grid;
  grid-template-columns: minmax(240px, 340px) minmax(0, 1fr);
  gap: clamp(28px, 5vw, 64px);
  align-items: center;
  padding: clamp(28px, 4vw, 52px);
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 0;
  box-shadow: 14px 14px 0 var(--ink);
}

/* gold corner flag */
.arc-spotlight::before {
  content: "";
  position: absolute;
  top: -1px;
  left: -1px;
  width: 72px;
  height: 72px;
  background: linear-gradient(135deg, var(--gold) 50%, transparent 50%);
}

.arc-spotlight__cover {
  position: relative;
  display: block;
  line-height: 0;
  box-shadow:
    1px 1px 0 var(--line),
    8px 10px 0 -2px rgba(31, 26, 20, 0.1),
    0 26px 44px rgba(76, 61, 45, 0.28);
  transition: transform 0.4s ease;
}

.arc-spotlight__cover::before {
  content: "";
  position: absolute;
  inset: 0 auto 0 0;
  width: 14px;
  z-index: 2;
  pointer-events: none;
  background: linear-gradient(90deg, rgba(0, 0, 0, 0.28), rgba(255, 255, 255, 0.16) 35%, transparent);
}

.arc-spotlight__cover img {
  display: block;
  width: 100%;
  height: auto;
  border-radius: 0;
}

.arc-spotlight__cover:hover { transform: translateY(-6px) rotate(-0.8deg); }

.arc-tag {
  display: inline-block;
  padding: 6px 12px;
  font: 700 0.68rem/1 "Inter", sans-serif;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: #fff;
  background: var(--gold-dark);
  border-radius: 0;
}

.arc-spotlight__body h3 {
  margin: 18px 0 10px;
  font: 800 clamp(1.7rem, 3.6vw, 2.8rem)/1.12 "Playfair Display", serif;
}

.arc-spotlight__body h3 a { color: var(--ink); }
.arc-spotlight__body h3 a:hover { color: var(--gold-dark); }

.arc-spotlight__sub {
  margin: 0 0 14px;
  font: italic 400 1.15rem/1.5 "Playfair Display", serif;
  color: var(--gold-dark);
}

.arc-spotlight__text {
  margin: 0 0 20px;
  font: 400 1rem/1.75 "Inter", sans-serif;
  color: var(--muted);
  display: -webkit-box;
  -webkit-line-clamp: 4;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.arc-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 22px;
  margin-bottom: 28px !important;
  font: 500 0.82rem/1 "Inter", sans-serif;
  color: var(--ink);
}

.arc-meta i { margin-right: 6px; color: var(--gold); }

.arc-actions { display: flex; flex-wrap: wrap; gap: 12px; }

/* ---------- Card grid ---------- */
.arc-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(230px, 1fr));
  gap: 44px 30px;
}

.arc-grid > li {
  opacity: 0;
  animation: arc-rise 0.6s ease forwards;
  animation-delay: calc(var(--i, 0) * 70ms);
}

@keyframes arc-rise {
  from { opacity: 0; transform: translateY(22px); }
  to   { opacity: 1; transform: translateY(0); }
}

.arc-card {
  display: flex;
  flex-direction: column;
  height: 100%;
  border-radius: 0;
}

.arc-card__cover {
  position: relative;
  display: block;
  overflow: hidden;
  line-height: 0;
  background: #efe8dc;
  border-radius: 0;
  box-shadow:
    1px 1px 0 var(--line),
    6px 8px 0 -2px rgba(31, 26, 20, 0.1),
    0 18px 30px rgba(76, 61, 45, 0.2);
  transition: transform 0.35s ease, box-shadow 0.35s ease;
}

.arc-card__cover::before {          /* spine */
  content: "";
  position: absolute;
  inset: 0 auto 0 0;
  width: 10px;
  z-index: 2;
  pointer-events: none;
  background: linear-gradient(90deg, rgba(0, 0, 0, 0.26), rgba(255, 255, 255, 0.16) 40%, transparent);
}

.arc-card__cover img {
  display: block;
  width: 100%;
  aspect-ratio: 3 / 4;
  object-fit: cover;
  border-radius: 0;
  transition: transform 0.5s ease;
}

.arc-card:hover .arc-card__cover {
  transform: translateY(-8px);
  box-shadow:
    1px 1px 0 var(--line),
    8px 10px 0 -2px var(--gold),
    0 28px 40px rgba(76, 61, 45, 0.28);
}

.arc-card:hover .arc-card__cover img { transform: scale(1.05); }

.arc-card__badge {
  position: absolute;
  top: 0;
  right: 0;
  z-index: 3;
  padding: 8px 12px;
  font: 700 0.64rem/1 "Inter", sans-serif;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #fff;
  background: var(--ink);
}

.arc-card__peek {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 3;
  display: flex;
  justify-content: center;
  gap: 10px;
  padding: 16px;
  font: 600 0.74rem/1 "Inter", sans-serif;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: #fff;
  background: linear-gradient(to top, rgba(31, 26, 20, 0.94), rgba(31, 26, 20, 0));
  transform: translateY(100%);
  transition: transform 0.3s ease;
}

.arc-card:hover .arc-card__peek,
.arc-card__cover:focus-visible .arc-card__peek { transform: translateY(0); }

.arc-card__body {
  display: flex;
  flex-direction: column;
  flex: 1;
  gap: 8px;
  padding-top: 22px;
}

.arc-card__cat {
  font: 700 0.66rem/1 "Inter", sans-serif;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--gold-dark);
}

.arc-card__title {
  margin: 0;
  font: 700 1.2rem/1.3 "Playfair Display", serif;
}

.arc-card__title a {
  color: var(--ink);
  background: linear-gradient(var(--gold), var(--gold)) 0 100% / 0 2px no-repeat;
  transition: background-size 0.3s ease;
}

.arc-card:hover .arc-card__title a { background-size: 100% 2px; }

.arc-card__date {
  margin: 0;
  font: 400 0.82rem/1 "Inter", sans-serif;
  color: var(--muted);
}

.arc-card__actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-top: auto;
  padding-top: 16px;
  border-top: 1px solid var(--line);
}

/* ---------- Empty and error ---------- */
.arc-empty {
  max-width: 520px;
  margin: 40px auto;
  padding: 56px 32px;
  text-align: center;
  background: var(--paper);
  border: 1px dashed var(--ink);
  border-radius: 0;
}

.arc-empty i { font-size: 2.4rem; color: var(--gold); }
.arc-empty h3 { margin: 16px 0 8px; font: 700 1.5rem/1.2 "Playfair Display", serif; }
.arc-empty p { margin: 0 0 22px; color: var(--muted); }

.arc-error {
  grid-column: 1 / -1;
  padding: 24px;
  color: #8a1f3d;
  background: #fff5f7;
  border: 1px solid #e8b4c2;
}

/* ---------- Responsive ---------- */
@media (max-width: 860px) {
  .arc-spotlight {
    grid-template-columns: 1fr;
    box-shadow: 8px 8px 0 var(--ink);
  }
  .arc-spotlight__cover { width: min(70%, 300px); margin: 0 auto; }
}

@media (max-width: 560px) {
  .arc-hero__stats > div { padding-right: 20px; margin-right: 20px; }
  .arc-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 32px 16px; }
  .arc-card__title { font-size: 1rem; }
  .arc-card__actions { flex-direction: column; align-items: flex-start; }
  .arc-card__actions .arc-btn--sm { width: 100%; justify-content: center; }
  .arc-library { padding-top: 40px; }
}

/* ---------- Reduced motion ---------- */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .arc-grid > li { animation: none; opacity: 1; }
  .arc-card__cover, .arc-card__cover img, .arc-card__peek,
  .arc-spotlight__cover, .arc-btn, .arc-search,
  .arc-card__title a { transition: none; }
}
.arc-controls__inner { padding: 14px 24px; }

.arc-grid {
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 48px 32px;
}

/* every cover is the same 3:4 box, whatever the source image size */
.arc-card__cover img { aspect-ratio: 3 / 4; object-fit: cover; }