@import url('https://fonts.googleapis.com/css2?family=Jacquard+12&display=swap');

:root{
  --font-body: "Times New Roman", serif;
  --font-heading: "Jacquard 12", system-ui;
  --text: #000;
  --muted: rgba(0,0,0,0.55);
  --grid-gap: 15px;
  --card-pad: 0px;
  --thumb-size: 50px; /* small square thumbnail */
  --max-width: 1200px;
  --page-pad: 16px;
  --border: none; /* optional: used for separators only */
  --focus: 2px dotted #000;
}

* { box-sizing: border-box; }
body { color: var(--text); font-family: var(--font-body); }

.browse-wrap{
  max-width: var(--max-width);
  margin: 0 auto;
  padding: calc(var(--page-pad) + 8px) var(--page-pad) var(--page-pad);
}

.browse-header{
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 12px;
}

.browse-title{
  font-family: var(--font-heading);
  font-size: 28px;
  line-height: 1;
}

.browse-subtitle{
  font-family: var(--font-body);
  font-style: italic;
  font-size: 14px;
  line-height: 1.25;
  letter-spacing: -0.2px;
  margin-top: 2px;          /* tuck it closer to the title */
  margin-bottom: 8px;
}

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

select.browse-sort{
  font-family: var(--font-body);
  font-size: 14px;
  padding: 2px 6px;
  border: none;
  background: #fff;
}

.browse-featured{
  margin: 8px 0 16px 0;
  display: none; /* becomes block if a feature is found */
}

.feature-card{
  display: grid;
  grid-template-columns: var(--thumb-size) 1fr auto;
  gap: 12px;
  padding: var(--card-pad);
  border-top: var(--border);
  border-bottom: var(--border);
}

.feature-card img{
  width: var(--thumb-size);
  height: var(--thumb-size);
  object-fit: cover;
}

.feature-card .f-meta{
  display: flex; flex-direction: column; gap: 2px;
}
.feature-card .f-title{
  font-family: var(--font-heading);
  font-size: 20px;
  text-decoration: none;
}
.feature-card .f-title:hover,
.feature-card .f-title:focus{ text-decoration: underline; outline: none; }
.feature-card .f-sub{ font-size: 14px; }
.feature-card .f-by{ font-size: 13px; color: var(--muted); }
.feature-card .f-right{
  text-align: right;
  display: flex; flex-direction: column; gap: 4px; justify-content: center;
}
.feature-card .f-date{ font-size: 12px; color: var(--muted); }
.feature-card .f-read{ font-size: 11px; color: var(--muted); }

.browse-grid{
  display: grid;
  grid-template-columns: repeat(2, 1fr); /* 2 on mobile */
  gap: var(--grid-gap);
}

@media (min-width: 760px){
  .browse-grid{ grid-template-columns: repeat(3, 1fr); }
}
@media (min-width: 1100px){
  .browse-grid{ grid-template-columns: repeat(4, 1fr); }
}

/* --- Card look to match the screenshot --- */
:root{
  --thumb-size: 80px;
  --border: none;
  --card-pad: 6px;
}

.card{
  display: grid;
  grid-template-columns: var(--thumb-size) 1fr auto;
  gap: 12px;
  align-items: center;         /* vertical center like your mock */
  padding: var(--card-pad) 0;
  border-top: var(--border);
}

.card img{
  width: var(--thumb-size);
  height: var(--thumb-size);
  object-fit: cover;
  background:#000;             /* gives a black square if img missing */
  display:block;
}

.card .title {
  line-height: 1 !important;   /* force override */
  display: block;                 /* ensure the browser respects the line box */
}

.card .title{
  font-size: 14px;
  margin: 0 0 1px 0;
  text-decoration: none;
  font-weight: bold;
}

.card .title:hover,
.card .title:focus{ text-decoration: underline; outline: none; }

.card .sub{
  font-size: 12px;
  margin: 2px 0 0 0;
  line-height: 1.1; /* tighten spacing */
    font-style: italic;
}

.card .by{
  font-size: 10px;
  color: rgba(0,0,0,.55);
}

.card .right{
  text-align: right;
  white-space: nowrap;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 4px;
}

.card .date{ font-size: 10px; color: #ffffff; }
.card .read{ font-size: 10px; color: #ffffff; }

/* optional: thin bottom separators so each card is boxed top+bottom */
.card:not(:last-child){ border-bottom: var(--border); }


/* Pagination */
.pagination{
  display:flex; flex-wrap: wrap; gap: 6px;
  align-items:center; justify-content:center;
  margin-top: 18px; padding-top: 12px; border-top: var(--border);
}
.pagination button{
  font-family: var(--font-body);
  font-size: 14px;
  padding: 2px 8px;
  background:#fff; border:1px solid #000; cursor:pointer;
}
.pagination button[aria-current="page"]{
  outline: var(--focus);
}
.pagination button:focus{ outline: var(--focus); }

/* A11y helpers */
.sr-only{
  position:absolute; width:1px; height:1px; padding:0; margin:-1px; overflow:hidden;
  clip:rect(0,0,0,0); white-space:nowrap; border:0;
}


