/* PharmTech.AI — /resources: Archived Weekly Briefs library + search. Loaded after styles.css. */

/* Honor the [hidden] attribute even on .btn (display:inline-flex would otherwise
   override the UA [hidden]{display:none} — e.g. the Download-as-PDF button, which
   is hidden until an issue actually has a PDF). */
[hidden] { display: none !important; }

.archive-head {
  display: flex; align-items: baseline; justify-content: space-between;
  gap: 12px; flex-wrap: wrap; margin: 6px 0 14px;
}
.archive-count { font-size: .9rem; color: var(--slate-2); white-space: nowrap; }

.archive-search {
  position: relative; margin: 0 0 18px;
}
.archive-search input {
  width: 100%;
  font-family: var(--sans);
  font-size: 1rem;
  padding: 13px 16px;
  border: 1.5px solid var(--line);
  border-radius: var(--r-sm, 8px);
  background: #fff;
  color: var(--ink);
}
.archive-search input:focus { outline: none; border-color: var(--gold); box-shadow: 0 0 0 3px rgba(0,113,227,.16); }

.archive-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 10px; }
.archive-row { display: flex; align-items: stretch; gap: 8px; }

.archive-link {
  flex: 1;
  display: grid;
  grid-template-columns: minmax(120px, auto) 1fr auto;
  align-items: baseline;
  gap: 6px 18px;
  padding: 16px 18px;
  border: 1px solid var(--line);
  border-radius: var(--r, 12px);
  background: #fff;
  text-decoration: none;
  color: inherit;
  transition: border-color .15s, box-shadow .15s, transform .15s;
}
.archive-link:hover { border-color: var(--gold); box-shadow: 0 10px 24px rgba(15,17,21,.07); transform: translateY(-1px); text-decoration: none; }
.archive-date { font-weight: 700; color: var(--ink); font-size: 1rem; }
.archive-desc { color: var(--slate); font-size: .92rem; line-height: 1.45; }
.archive-go { color: var(--link); font-weight: 600; font-size: .92rem; white-space: nowrap; justify-self: end; }

.archive-pdf {
  align-self: center;
  padding: 8px 12px;
  border: 1px solid var(--line);
  border-radius: var(--r-sm, 8px);
  font-size: .82rem; font-weight: 600; color: var(--link);
  text-decoration: none; white-space: nowrap;
}
.archive-pdf:hover { border-color: var(--gold); text-decoration: none; }

.archive-empty { color: var(--slate-2); font-size: .95rem; padding: 14px 2px; }
/* Badge on the newest issue when it surfaces in archive SEARCH results. */
.archive-current { display: inline-block; vertical-align: 2px; margin-left: 8px; font-size: .68rem; font-weight: 700; letter-spacing: .05em; text-transform: uppercase; color: #0d7a4f; background: #e6f6ee; border: 1px solid #bfe8d2; border-radius: 999px; padding: 2px 8px; white-space: nowrap; }

@media (max-width: 640px) {
  .archive-link { grid-template-columns: 1fr; gap: 4px; padding: 14px 15px; }
  .archive-go { justify-self: start; }
}
