/* TransHimalaya — section pages
   A lead article, then the rest of the section as cards. */

.cat{ max-width:1200px; margin:0 auto;
  padding:0 clamp(16px,4vw,40px) clamp(48px,6vw,76px); }

.cat-head{ max-width:46rem; margin:0 auto; text-align:center;
  padding:clamp(34px,5vw,58px) 0 clamp(28px,4vw,42px); }
.cat-head .k{ font-size:12px; letter-spacing:.2em; text-transform:uppercase;
  color:var(--orange); font-weight:700; margin:0; }
.cat-head h1{ font-family:"Iowan Old Style","Palatino Linotype",Palatino,Georgia,serif;
  font-size:clamp(32px,5vw,52px); line-height:1.06; font-weight:600; color:var(--ink);
  margin:12px 0 0; text-wrap:balance; }
.cat-head .lede{ font-size:17.5px; line-height:1.65; color:#4b5a63;
  margin:16px auto 0; max-width:54ch; }
.cat-count{ font-size:12px; letter-spacing:.14em; text-transform:uppercase;
  color:var(--muted); margin:18px 0 0; }

/* ---- lead article ---- */
.cat-lead{ display:grid; grid-template-columns:1.25fr 1fr; gap:clamp(24px,4vw,44px);
  align-items:center; padding-bottom:clamp(32px,4vw,46px);
  border-bottom:1px solid var(--line); margin-bottom:clamp(32px,4vw,46px); }
.cat-lead .ph{ display:block; aspect-ratio:16/10; border-radius:5px;
  background-size:cover; background-position:center; background-color:#e6ebed; }
.cat-lead .k{ font-size:11px; letter-spacing:.16em; text-transform:uppercase;
  color:var(--orange); font-weight:700; margin:0; }
.cat-lead h2{ font-family:"Iowan Old Style",Palatino,Georgia,serif;
  font-size:clamp(25px,3.4vw,38px); line-height:1.15; color:var(--ink);
  font-weight:600; margin:12px 0 0; text-wrap:balance; }
.cat-lead h2 a{ color:inherit; text-decoration:none; }
.cat-lead h2 a:hover{ color:var(--orange); }
.cat-lead .meta{ display:flex; gap:10px; align-items:center; flex-wrap:wrap;
  font-size:13px; color:var(--muted); margin-top:16px; }

/* ---- the rest of the section ---- */
.cat-grid{ grid-template-columns:repeat(3,1fr); }
.cat-grid .th-card h3 a{ color:inherit; text-decoration:none; }
.cat-grid .th-card h3 a:hover{ color:var(--orange); }
.cat-grid .th-card .ph{ display:block; background-size:cover; background-position:center; }
.cat-grid .th-card .b{ padding:16px 18px 18px; }
.cat-grid .th-card .meta{ border-top:0; padding-top:0; margin-top:10px; }

/* ---- nothing published yet ---- */
.cat-empty{ max-width:46rem; margin:0 auto; text-align:center;
  border:1px dashed var(--line); border-radius:8px; background:var(--sand);
  padding:clamp(34px,5vw,54px) clamp(20px,4vw,40px); }
.cat-empty .ttl{ font-family:"Iowan Old Style",Palatino,Georgia,serif; font-size:23px;
  color:var(--ink); font-weight:600; margin:0 0 10px; }
.cat-empty p{ font-size:15.5px; line-height:1.65; color:#5b6870; margin:0; }
.cat-empty a{ color:var(--teal); }
.cat-empty a:hover{ color:var(--orange); }

@media (max-width:900px){
  .cat-lead{ grid-template-columns:1fr; }
  .cat-grid{ grid-template-columns:repeat(2,1fr); }
}
@media (max-width:620px){
  .cat-grid{ grid-template-columns:1fr; }
}

/* ---- In Focus: topic filter + search ---- */
.cat-filter{ display:flex; flex-wrap:wrap; align-items:center; gap:12px;
  margin:0 0 26px; padding-bottom:18px; border-bottom:1px solid var(--line); }
.cf-topics{ display:flex; flex-wrap:wrap; gap:8px; }
.cf-btn{ font:inherit; font-size:12px; font-weight:700; letter-spacing:.06em;
  text-transform:uppercase; padding:7px 13px; border-radius:999px; cursor:pointer;
  border:1px solid var(--line); background:#fff; color:var(--ink);
  opacity:.55; transition:opacity .15s ease, box-shadow .15s ease; }
.cf-btn:hover{ opacity:.85; }
.cf-btn.is-on{ opacity:1; box-shadow:0 1px 6px rgba(18,40,55,.16); border-color:transparent; }
.cf-btn[data-filter="all"].is-on{ background:var(--ink); color:#fff; }
.cf-search{ margin-left:auto; }
.cf-search input{ font:inherit; font-size:14px; padding:9px 13px; width:min(260px,58vw);
  border:1px solid var(--line); border-radius:6px; color:var(--ink); background:#fff; }
.cf-search input:focus{ outline:2px solid var(--teal); outline-offset:1px; }
.cf-count{ width:100%; margin:0; font-size:13px; color:var(--muted); }
.cat-grid .th-card.is-hidden{ display:none; }
.cat-noresult{ padding:26px 0; color:var(--muted); font-size:15px; }
@media (max-width:640px){ .cf-search{ margin-left:0; width:100%; }
  .cf-search input{ width:100%; } }

/* topic pills carry their section colour: a dot when resting, a fill when on */
.cf-btn[data-filter]:not([data-filter="all"]){ padding-left:10px; }
.cf-btn[data-filter]:not([data-filter="all"])::before{
  content:""; display:inline-block; width:8px; height:8px; border-radius:50%;
  background:var(--cat,var(--muted)); margin-right:7px; vertical-align:1px; }
.cf-btn.is-on[data-filter]:not([data-filter="all"]){
  background:var(--cat,var(--ink)); color:var(--cat-fg,#fff); border-color:transparent; }
.cf-btn.is-on[data-filter]:not([data-filter="all"])::before{ background:rgba(255,255,255,.85); }

