/* Default thread */
.onyxbb-thread__icon { 
  background: linear-gradient(135deg, #444, #222);
  color: #fff;
}

/* Pinned */
.onyxbb-thread__icon--pin {
  background: linear-gradient(135deg, #f39c12, #f1c40f); /* gold */
  color: #fff;
}

/* Unread thread */
.onyxbb-thread.is-unread .onyxbb-thread__icon {
  background: linear-gradient(135deg, #7f56d9, #9a7fe0); /* purple */
}

/* Locked thread */
.onyxbb-thread__icon--locked {
  background: linear-gradient(135deg, #e74c3c, #c0392b); /* red */
  color: #fff;
}

/* Hot thread */
.onyxbb-thread__icon--hot {
  background: linear-gradient(135deg, #e67e22, #d35400); /* orange */
  color: #fff;
}
.onyxbb-threads{list-style:none;margin:0;padding:0;display:grid;gap:8px}
.onyxbb-threadlist {
  background: var(--card-bg);
  border: 1px solid var(--border-color);
  border-radius: 16px;
  box-shadow: 0 8px 24px var(--shadow-color);
  padding: 12px;
}
/* Thread Container */
.onyxbb-thread {
  display: grid;
  grid-template-columns: 40px minmax(0,2fr) 90px 90px 90px 260px;
  grid-template-areas: "icon main replies views likes last";
  align-items: center;
  gap: 8px;
  background: var(--highlight-bg);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  padding: 8px 10px;
}

.onyxbb-thread.is-unread {
  box-shadow: 0 0 0 2px rgba(127,86,217,.28) inset;
  border-color: var(--accent-soft);
}

/* Thread icon */
.onyxbb-thread__icon {
  grid-area: icon;
  width: 40px;
  height: 40px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  background: linear-gradient(135deg,var(--accent),rgba(255,255,255,.08));
  border: 1px solid var(--border-color);
  text-decoration: none;
}

.onyxbb-thread__icon--pin {
  background: linear-gradient(135deg,var(--accent),var(--accent-soft));
}

/* Main thread info */
.onyxbb-thread__main {
  grid-area: main;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.onyxbb-thread__title {
  color: var(--text-bright,#fff);
  font-weight: 800;
  text-decoration: none;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.onyxbb-thread__title:hover { color: var(--link-color); }
.onyxbb-thread__meta { color: var(--text-muted); font-size: 12px; }

/* Counts container */
.onyxbb-thread__counts { display: flex; gap: 8px; }

.onyxbb-count {
  display: flex;
  flex-direction: column; /* stack rows */
  align-items: center;
  justify-content: center;
  /* background: var(--card-bg); */
  /* border: 1px solid var(--border-color); */
  /* border-radius: 10px; */
  padding: 6px 10px;
  min-width: 80px;
  text-align: center;
}

.onyxbb-count__top {
  display: flex;
  align-items: center;
  gap: 4px;
  font-size: 14px;
  font-weight: 700;
  color: var(--text-bright,#fff);
}

.onyxbb-count i { font-size: 14px; }
.onyxbb-count em {
  color: var(--text-muted);
  font-style: normal;
  font-size: 11px;
}

/* Specific icons */
.onyxbb-count--likes i { color: var(--link-color); }
.onyxbb-count--vouch i { color: var(--legend,#00ff88); }

/* Last post */
.onyxbb-thread__last {
  grid-area: last;
  display: flex;
  gap: 8px;
  align-items: center;
  background: var(--card-bg);
  /* border: 1px solid var(--border-color); */
  /* border-radius: 10px; */
  padding: 6px 8px;
}

.onyxbb-thread__lasticon {
  width: 26px;
  height: 26px;
  border-radius: 8px;
  background: var(--accent);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
}

.onyxbb-thread__lastbody { display: flex; flex-direction: column; }
.onyxbb-thread__lasttitle { color: var(--text-main); font-size: 13px; }
.onyxbb-thread__lastmeta { color: var(--text-muted); font-size: 11px; }

/* Responsive */
@media (max-width:1100px){
  .onyxbb-thread {
    grid-template-columns: 40px 1fr 90px 90px;
    grid-template-areas:
      "icon main replies views"
      ".    last  last    last"
      ".    counts counts counts";
  }
  .onyxbb-thread__counts { flex-wrap: wrap; }
}

@media (max-width:720px){
  .onyxbb-thread {
    grid-template-columns: 40px 1fr;
    grid-template-areas:
      "icon main"
      ".    last"
      ".    counts";
  }
}
/* Default icon style */
.onyxbb-thread__icon {
  grid-area: icon;
  width: 40px;
  height: 40px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  border: 1px solid var(--border-color);
  font-family: "Font Awesome 6 Free"; /* make pseudo work */
  font-weight: 900;
  font-size: 16px;
}

/* Normal thread */
.onyxbb-thread__icon.folder::before {
  content: "\f15c"; /* fa-regular fa-file-alt */
  color: var(--text-light);
}

/* Unread thread */
.onyxbb-thread__icon.newfolder::before {
  content: "\f0e0"; /* fa-regular fa-envelope */
  color: var(--accent);
}

/* Hot thread */
.onyxbb-thread__icon.hotfolder::before,
.onyxbb-thread__icon.newhotfolder::before {
  content: "\f06d"; /* fa-solid fa-fire */
  color: #e67e22;
}

/* Locked thread */
.onyxbb-thread__icon.lockfolder::before {
  content: "\f023"; /* fa-solid fa-lock */
  color: #e74c3c;
}

/* Moved thread */
.onyxbb-thread__icon.movefolder::before {
  content: "\f064"; /* fa-solid fa-arrows-turn-to-dots */
  color: #3498db;
}

/* Dot thread (you posted in it) */
.onyxbb-thread__icon.dot_folder::before {
  content: "\f111"; /* fa-solid fa-circle */
  color: #2ecc71;
}

/* Pinned thread (override regardless of read/unread) */
.onyxbb-thread__icon.sticky::before {
  content: "\f08d"; /* fa-solid fa-thumbtack */
  color: #f1c40f;
}
