/* ======================================================
   Shared layout (panel width like status page)
====================================================== */

.shell{ padding: 28px 18px; }
.panel{
  width: min(1120px, calc(100vw - 36px));
  margin: 0 auto;
}

/* Category pages a bit tighter */
body[data-cat] .panel{
  width: min(980px, calc(100vw - 36px));
}

/* Section title */
.section-title{
  margin-top: 10px;
  margin-bottom: 10px;
  font-weight: 900;
  letter-spacing: .04em;
  text-transform: uppercase;
  font-size: 12px;
  color: rgba(255,255,255,.62);
}

/* Optional subtitle (use in template if you want) */
.section-subtitle{
  margin-top: -6px;
  margin-bottom: 12px;
  color: rgba(255,255,255,.52);
  font-weight: 800;
  font-size: 13px;
}

/* ======================================================
   Index page category cards (fixed layout + 2-column)
====================================================== */

.cl-cat-cards{
  display: grid;
  grid-template-columns: 1fr;
  gap: 14px;
  margin-top: 8px;
}

/* 2 columns on bigger screens */
@media (min-width: 900px){
  .cl-cat-cards{
    grid-template-columns: 1fr 1fr;
  }
}

.cl-cat-card{
  display:flex;
  align-items:center;
  gap: 14px;
  padding: 16px 18px;
  border-radius: 20px;
  border: 1px solid rgba(255,255,255,.10);
  background: radial-gradient(900px 220px at 35% -30%, rgba(0,170,37,.10), transparent 60%),
              rgba(0,0,0,.22);
  text-decoration:none !important;
  transition: transform .10s ease, border-color .15s ease, box-shadow .15s ease, background .15s ease;
}

.cl-cat-card:hover{
  transform: translateY(-2px);
  border-color: rgba(0,170,37,.35);
  box-shadow: 0 0 0 4px rgba(0,170,37,.06);
  background: radial-gradient(900px 220px at 35% -30%, rgba(0,170,37,.16), transparent 60%),
              rgba(0,0,0,.28);
}

.cl-cat-card-ico{
  width: 46px;
  height: 46px;
  border-radius: 16px;
  border: 1px solid rgba(255,255,255,.10);
  background: rgba(0,0,0,.22);
  display:flex;
  align-items:center;
  justify-content:center;
  color: rgba(0,170,37,.95);
  filter: drop-shadow(0 0 10px rgba(0,170,37,.20));
  flex: 0 0 auto;
}

.cl-cat-card-ico i{ font-size: 18px; }

.cl-cat-card-txt{ min-width: 0; flex: 1; }

.cl-cat-card-title{
  font-weight: 950;
  font-size: 16px;
  color: rgba(255,255,255,.92);
  line-height: 1.15;
}

.cl-cat-card-sub{
  margin-top: 5px;
  font-weight: 800;
  font-size: 13px;
  color: rgba(255,255,255,.62);
  line-height: 1.25;
}

.cl-cat-card-go{
  color: rgba(255,255,255,.40);
  flex: 0 0 auto;
  opacity: .7;
  transition: transform .12s ease, color .12s ease, opacity .12s ease;
}

.cl-cat-card:hover .cl-cat-card-go{
  transform: translateX(2px);
  color: rgba(255,255,255,.80);
  opacity: 1;
}

/* ======================================================
   Category page controls
====================================================== */

.cl-controls{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap: 14px;
  flex-wrap:wrap;
  margin: 14px 0 14px;
}

.cl-controls-cat{
  gap: 10px;
}

.cl-back{
  border: 1px solid rgba(255,255,255,.10);
  background: rgba(0,0,0,.22);
  color: rgba(255,255,255,.86);
  border-radius: 999px;
  display:inline-flex;
  align-items:center;
  gap: 8px;
  height: 40px;
  padding: 0 14px;
  font-weight: 900;
  font-size: 13px;
  text-decoration:none !important;
  transition: transform .08s ease, border-color .15s ease, box-shadow .15s ease;
}

.cl-back:hover{
  transform: translateY(-1px);
  border-color: rgba(255,255,255,.16);
}

.cl-filters{
  display:flex;
  gap: 10px;
  align-items:center;
  flex-wrap:wrap;
  justify-content:flex-end;
  flex: 1;
  min-width: 320px;
}

/* Pills */
.cl-pill{
  border: 1px solid rgba(255,255,255,.10);
  background: rgba(0,0,0,.22);
  color: rgba(255,255,255,.86);
  border-radius: 999px;
  display:inline-flex;
  align-items:center;
  gap: 8px;
  height: 40px;
  padding: 0 14px;
  font-weight: 900;
  font-size: 13px;
}

.cl-search{ min-width: 320px; flex: 1; }
.cl-subcat{ min-width: 240px; flex: 0; padding-right: 8px; }

.cl-search i,
.cl-subcat i{
  color: rgba(255,255,255,.55);
  font-size: 14px;
}

/* Search input */
.cl-search input{
  border: none;
  outline: none;
  background: transparent;
  color: rgba(255,255,255,.90);
  width: 100%;
  font-weight: 800;
  font-size: 13px;
}

.cl-search input::placeholder{
  color: rgba(255,255,255,.45);
}

@media (max-width: 640px){
  .cl-search{ min-width: 240px; }
  .cl-subcat{ min-width: 200px; }
}

/* ======================================================
   Custom dropdown
====================================================== */

.cl-subcat .dd{
  width: 100%;
  min-width: 0;
  position: relative;
}

.cl-subcat .dd-btn{
  width: 100%;
  height: 38px;
  border: none;
  outline: none;
  background: transparent;
  color: rgba(255,255,255,.90);
  font-weight: 950;
  font-size: 13px;

  display:flex;
  align-items:center;
  justify-content:space-between;
  gap: 10px;
  padding: 0 6px 0 0;
  cursor: pointer;
}

.cl-subcat #subcatLabel{
  overflow:hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.cl-subcat .dd-menu{
  position:absolute;
  margin-top: 10px;
  left: 0;
  right: 0;
  z-index: 40;

  border-radius: 16px;
  border: 1px solid rgba(255,255,255,.10);
  background: rgba(0,0,0,.92);
  box-shadow: 0 18px 55px rgba(0,0,0,.70);
  padding: 6px;
  display:none;
  max-height: 280px;
  overflow:auto;
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}

.cl-subcat .dd.is-open .dd-menu{ display:block; }

.cl-subcat .dd-item{
  width: 100%;
  border: 1px solid transparent;
  background: transparent;
  color: rgba(233,238,248,0.85);
  font-weight: 950;
  font-size: 13px;
  border-radius: 12px;
  padding: 10px 10px;
  text-align:left;
  cursor:pointer;
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap: 10px;
}

.cl-subcat .dd-item:hover{
  background: rgba(255,255,255,0.06);
  border-color: rgba(255,255,255,0.10);
}

.cl-subcat .dd-item.active{
  background: rgba(0,170,37,0.14);
  border-color: rgba(0,170,37,0.30);
  color: rgba(255,255,255,0.95);
}

.cl-subcat .dd-count{
  opacity: .70;
  font-weight: 950;
  font-size: 12px;
}

/* ======================================================
   Changelog views: Sub -> Version -> Entries
====================================================== */

.cl-views{
  display:flex;
  flex-direction:column;
  gap: 14px;
  margin-top: 6px;
}

/* Sub section (replaces previous cl-cat for category pages) */
.cl-sub{
  border-radius: 20px;
  border: 1px solid rgba(255,255,255,.08);
  background: rgba(0,0,0,.14);
  padding: 14px;
}

.cl-sub-head{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap: 12px;
  margin-bottom: 12px;
}

.cl-sub-title{
  display:flex;
  align-items:center;
  gap: 10px;
  font-weight: 950;
  letter-spacing: .02em;
  color: rgba(255,255,255,.92);
}

.cl-sub-title i{
  color: rgba(0,170,37,.90);
  filter: drop-shadow(0 0 10px rgba(0,170,37,.18));
}

.cl-mini-pill{
  border: 1px solid rgba(255,255,255,.10);
  background: rgba(0,0,0,.18);
  color: rgba(255,255,255,.80);
  border-radius: 999px;
  padding: 6px 10px;
  font-size: 12px;
  font-weight: 950;
  display:inline-flex;
  align-items:center;
  gap: 7px;
}

/* Versions list */
.cl-verlist{
  display:flex;
  flex-direction:column;
  gap: 10px;
}

/* Version card */
.cl-ver{
  border-radius: 18px;
  border: 1px solid rgba(0,170,37,.18);
  background: radial-gradient(1000px 250px at 50% -20%, rgba(0,170,37,.16), transparent 60%),
              rgba(0,0,0,.22);
  overflow:hidden;
}

.cl-ver-head{
  display:flex;
  align-items:flex-end;
  justify-content:space-between;
  padding: 14px 14px 10px;
  border-bottom: 1px solid rgba(255,255,255,.06);
}

.cl-ver-version{
  font-size: 26px;
  font-weight: 950;
  letter-spacing: .02em;
  color: rgba(255,255,255,.95);
  line-height: 1;
}

.cl-ver-date{
  font-weight: 950;
  font-size: 12px;
  color: rgba(255,255,255,.60);
  letter-spacing: .08em;
}

/* Entries */
.cl-ver-body{
  padding: 10px 10px 12px;
  display:flex;
  flex-direction:column;
  gap: 8px;
}

.cl-entry{
  display:flex;
  justify-content:space-between;
  align-items:flex-start;
  gap: 12px;
  padding: 10px 10px;
  border-radius: 14px;
  border: 1px solid rgba(255,255,255,.08);
  background: rgba(0,0,0,.16);
}

.cl-entry-left{
  min-width: 0;
  display:flex;
  flex-direction:column;
  gap: 6px;
}

.cl-entry-title{
  font-weight: 950;
  font-size: 13px;
  color: rgba(255,255,255,.92);
  line-height: 1.25;
}

.cl-entry-desc{
  font-weight: 800;
  font-size: 12.5px;
  color: rgba(255,255,255,.70);
  line-height: 1.35;
  word-break: break-word;
}

.cl-entry-meta{
  display:flex;
  flex-wrap:wrap;
  gap: 10px;
  color: rgba(255,255,255,.50);
  font-size: 12px;
  font-weight: 900;
}

.cl-entry-badges{
  display:flex;
  gap: 8px;
  flex-wrap:wrap;
  justify-content:flex-end;
}

/* Badge */
.cl-badge{
  border: 1px solid rgba(255,255,255,.10);
  background: rgba(0,0,0,.18);
  color: rgba(255,255,255,.86);
  border-radius: 999px;
  padding: 7px 10px;
  font-size: 12px;
  font-weight: 950;
  display:inline-flex;
  align-items:center;
  gap: 7px;
  white-space: nowrap;
}

.cl-badge.add { border-color: rgba(0,170,37,.50); background: rgba(0,170,37,.12); }
.cl-badge.fix { border-color: rgba(255,193,7,.50); background: rgba(255,193,7,.10); }
.cl-badge.chg { border-color: rgba(0,123,255,.50); background: rgba(0,123,255,.10); }
.cl-badge.rem { border-color: rgba(220,53,69,.50); background: rgba(220,53,69,.10); }

/* Empty */
.cl-empty{
  padding: 18px 16px;
  border-radius: 18px;
  border: 1px dashed rgba(255,255,255,.14);
  background: rgba(0,0,0,.14);
  color: rgba(255,255,255,.70);
  font-weight: 900;
}
