/* FILE-O homepage news 4×2 · 2026-11-14.
   Deliberately scoped to #homePage: catalog cards and tool workspaces unchanged.
   Roll back by restoring index.html + removing this one stylesheet. */

#homePage > .hero{
  display:grid;
  grid-template-columns:minmax(0,1fr) 340px;
  align-items:center;
  gap:10px 18px;
  min-height:0;
  padding-top:36px;
  padding-bottom:30px;
  overflow:visible;
}
#homePage > .hero .hero-content{min-width:0}
#homePage > .hero .hero-description{margin-bottom:14px}
#homePage > .hero .hero-points{margin-top:18px;margin-left:3px}
#homePage > .hero .hero-art{min-height:258px}

/* Home news is full width, not squeezed into the search input's old width. */
#homePage .home-latest{
  grid-column:1/-1;min-width:0;
  margin-top:11px;padding:21px 0 0;
  border-top:1px solid #e9e5f3;
}
#homePage .home-latest-header{
  display:flex;align-items:end;justify-content:space-between;
  gap:18px;margin:0 0 14px;
}
#homePage .home-latest-overline{
  display:block;font-size:10px;font-weight:850;line-height:1.4;
  letter-spacing:.12em;color:#7763d0;margin-bottom:5px;
}
#homePage .home-latest-header h2{
  margin:0;font-size:clamp(20px,2vw,25px);
  font-weight:830;letter-spacing:-.04em;line-height:1.22;color:#25213e;
}
#homePage .home-latest-header p{
  font-size:11px;line-height:1.6;color:#888196;
  margin:0 0 2px;max-width:420px;
}
#homePage .home-latest-grid{
  display:grid;grid-template-columns:repeat(4,minmax(0,1fr));
  gap:11px;align-items:stretch;
}
#homePage .home-latest-card{
  position:relative;min-width:0;min-height:153px;
  display:flex;flex-direction:column;align-items:flex-start;
  gap:6px;padding:17px 17px 14px;
  background:#fff;border:1px solid #e5e0f0;border-radius:14px;
  box-shadow:0 6px 21px rgba(52,38,105,.055);
  color:#302a45;text-decoration:none;
  transition:border-color .16s,transform .16s,box-shadow .16s;
}
#homePage .home-latest-card:nth-child(1){
  background:linear-gradient(135deg,#f3efff 0%,#fcfaff 100%);
  border-color:#dcd2f4;
}
#homePage .home-latest-card:nth-child(4),
#homePage .home-latest-card:nth-child(7){
  background:#faf9fd;
}
#homePage .home-latest-card .home-latest-category{
  color:#7865ad;font-weight:830;letter-spacing:.092em;
  font-size:9px;line-height:1.5;
}
#homePage .home-latest-card strong{
  display:block;color:#2d2744;font-size:15px;
  line-height:1.32;font-weight:810;letter-spacing:-.022em;
}
#homePage .home-latest-card .home-latest-description{
  color:#827b91;font-size:10.6px;line-height:1.58;
}
#homePage .home-latest-card .home-latest-action{
  color:#6b53bd;font-size:10px;font-weight:770;
  line-height:1.4;margin-top:auto;padding-top:6px;
}
#homePage .home-latest-card:is(:hover,:focus-visible){
  border-color:#bba8ed;box-shadow:0 11px 27px rgba(66,43,144,.13);
  transform:translateY(-2px);color:#261d52;
}
#homePage .home-latest-card:focus-visible{
  outline:3px solid #cbbdf5;outline-offset:3px;
}

/* Move the existing counters into a right-aligned stack.
   Keep original IDs so live statistics continue updating. */
#homePage #tools .section-heading{
  display:flex;align-items:flex-start;justify-content:space-between;
  flex-wrap:wrap;gap:12px 22px;margin-bottom:0;
}
#homePage #tools .catalog-stat-stack{
  display:flex;flex:0 0 260px;
  width:260px;max-width:100%;
  flex-direction:column;align-items:flex-end;gap:9px;
  margin-left:auto;padding-top:1px;
}
#homePage #tools .catalog-stat-stack .catalog-counter{
  width:100%;padding:0;
  display:flex;align-items:center;justify-content:flex-end;
  gap:12px;white-space:nowrap;
}
#homePage #tools .catalog-stat-stack #siteProof.proof-card{
  display:flex;width:260px;max-width:100%;
  margin:0;padding:9px 11px;min-height:65px;
}
#homePage #tools .catalog-stat-stack .proof-card-title{
  white-space:normal;
}

/* Existing search input, preserved with its working JS handlers. */
#homePage #tools .catalog-search-row{
  margin:18px 0 22px;max-width:760px;
}
#homePage #tools .catalog-search-row .hero-search{
  display:flex;width:100%;max-width:none;min-height:60px;
  box-shadow:0 8px 24px rgba(41,42,99,.07);
}
#homePage #tools .catalog-search-row .hero-search:focus-within{
  border-color:#aa96ee;box-shadow:0 0 0 3px rgba(121,99,234,.09);
}

/* The old 3-card promo section is replaced by quiet, non-duplicated links. */
#homePage .home-latest-more{
  display:flex;align-items:center;flex-wrap:wrap;
  gap:8px 11px;padding:12px 15px;
  margin:0 auto 13px;
  background:#faf9fc;border:1px solid #eae5f2;
  border-radius:12px;
}
#homePage .home-latest-more > span{
  flex:0 0 auto;color:#6d6482;
  font-size:11px;font-weight:800;margin-right:7px;
}
#homePage .home-latest-more :is(button,a){
  min-height:34px;display:inline-flex;align-items:center;
  justify-content:center;margin:0;padding:8px 12px;
  color:#655580;text-decoration:none;
  background:#fff;border:1px solid #e5def0;border-radius:8px;
  font:700 11px/1.35 system-ui,-apple-system,sans-serif;
  cursor:pointer;box-shadow:none;
}
#homePage .home-latest-more :is(button,a):hover{
  color:#5633ab;background:#f3effc;border-color:#cfc1ef;
  text-decoration:none;
}
#homePage .home-latest-more :is(button,a):focus-visible{
  outline:2px solid #baa7eb;outline-offset:2px;
}

@media(max-width:1060px){
  #homePage .home-latest-grid{gap:9px}
  #homePage .home-latest-card{padding:14px 13px;min-height:174px}
  #homePage .home-latest-card strong{font-size:14px}
  #homePage .home-latest-header p{max-width:260px}
}
@media(max-width:960px){
  #homePage > .hero{
    display:block;min-height:0;padding-top:35px;
    padding-bottom:22px;
  }
  #homePage > .hero .hero-art{display:none}
  #homePage .home-latest{margin-top:23px;padding-top:20px}
  #homePage .home-latest-header{align-items:start}
  #homePage .home-latest-grid{
    grid-template-columns:repeat(2,minmax(0,1fr));
    gap:10px;
  }
  #homePage .home-latest-card{min-height:144px;padding:16px}
  #homePage .home-latest-card strong{font-size:15px}
}
@media(max-width:720px){
  #homePage .home-latest-header{display:block}
  #homePage .home-latest-header p{max-width:none;margin-top:8px}
  #homePage #tools .section-heading{
    display:flex;flex-direction:column;
    align-items:stretch;gap:10px;
  }
  #homePage #tools .catalog-stat-stack{
    margin:0 0 0 auto;width:240px;flex-basis:auto;
    align-items:flex-end;gap:7px;
  }
  #homePage #tools .catalog-stat-stack .catalog-counter{
    display:flex!important;max-width:240px;
    gap:9px;
  }
  #homePage #tools .catalog-stat-stack .catalog-counter > span{font-size:25px}
  #homePage #tools .catalog-stat-stack .catalog-counter small{font-size:10px}
  #homePage #tools .catalog-stat-stack #siteProof.proof-card{
    width:240px;min-height:56px;
    padding:7px 10px;
  }
  #homePage #tools .catalog-stat-stack #siteProof #completedFilesCount{font-size:21px}
  #homePage #tools .catalog-search-row{margin:15px 0 23px;max-width:none}
  #homePage #tools .catalog-search-row .hero-search{min-height:55px}
}
@media(max-width:420px){
  #homePage .home-latest{margin-top:20px}
  #homePage .home-latest-grid{gap:8px}
  #homePage .home-latest-card{
    padding:13px 11px 12px;min-height:165px;
    border-radius:12px;gap:6px;
  }
  #homePage .home-latest-card .home-latest-category{font-size:8.5px}
  #homePage .home-latest-card strong{font-size:13.3px;line-height:1.32}
  #homePage .home-latest-card .home-latest-description{font-size:10.3px;line-height:1.55}
  #homePage .home-latest-card .home-latest-action{font-size:10px}
  #homePage .home-latest-more{gap:7px;padding:11px}
  #homePage .home-latest-more > span{width:100%}
  #homePage .home-latest-more :is(button,a){flex:1 1 140px;font-size:10px}
}
@media(max-width:350px){
  #homePage .home-latest-card strong{font-size:11.5px}
  #homePage .home-latest-card .home-latest-description{font-size:9px}
  #homePage #tools .catalog-stat-stack{max-width:100%;width:220px}
  #homePage #tools .catalog-stat-stack #siteProof.proof-card{width:220px}
}
@media(prefers-reduced-motion:reduce){
  #homePage .home-latest-card{transition:none}
  #homePage .home-latest-card:hover{transform:none}
}
