/* =====================================================================
   Dyskretny widzet oceny i licznika pobran na podstronie projektu.
   Osobny plik - nie modyfikuje assets/css/styles.css. Korzysta ze
   zmiennych motywu (--border, --text-muted, --accent itd.) zdefiniowanych
   w styles.css, dzieki czemu wyglada spojnie w trybie jasnym i ciemnym.
   ===================================================================== */

.vs-extras {
  margin-top: 1rem;
  padding-top: 1rem;
  border-top: 1px solid var(--border);
  display: grid;
  gap: 1rem;
}

.vs-meta {
  margin: 0;
  display: grid;
  gap: .5rem;
}
.vs-meta > div {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 1rem;
}
.vs-meta dt {
  color: var(--text-muted);
  font-size: .85rem;
}
.vs-meta dd {
  margin: 0;
  font-weight: 600;
  font-size: .9rem;
}

.vs-rating {
  display: grid;
  gap: .45rem;
}
.vs-rating-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: .75rem;
}
.vs-rating-label {
  font-weight: 600;
  font-size: .9rem;
}
.vs-rating-summary {
  color: var(--text-muted);
  font-size: .82rem;
}

.vs-stars {
  display: inline-flex;
  gap: .15rem;
}
.vs-star {
  border: none;
  background: transparent;
  cursor: pointer;
  padding: 0 .05rem;
  font-size: 1.5rem;
  line-height: 1;
  color: color-mix(in srgb, var(--text-muted) 45%, transparent);
  transition: color .12s ease, transform .12s ease;
}
.vs-star:hover { transform: scale(1.08); }
.vs-star.is-on { color: #f5b301; }
.vs-star:disabled { cursor: default; }

.vs-rating-msg {
  margin: 0;
  font-size: .82rem;
  color: var(--green);
}

/* --------------------------------------------------------------------
   Bloki tresci projektu (tekst / zdjecie) ukladane w panelu.
   Renderowane pod sekcja "O projekcie", nad instrukcja instalacji.
   -------------------------------------------------------------------- */
.project-bloki {
  display: grid;
  gap: 1.1rem;
  margin: 1.5rem 0;
}
.project-bloki:empty {
  margin: 0;
}
.project-blok-p {
  margin: 0;
  font-size: 18px;
  line-height: 1.75;
  color: var(--text-muted);
}
.project-blok-img {
  display: block;
  width: 100%;
  height: auto;
  border-radius: 16px;
  border: 1px solid var(--border);
  cursor: zoom-in;
}
.project-detail-cover { cursor: zoom-in; }

/* Lightbox - powiekszone zdjecie na pelnym ekranie. */
.vs-lightbox {
  position: fixed;
  inset: 0;
  z-index: 200;
  display: grid;
  place-items: center;
  padding: 24px;
  background: rgba(8, 9, 13, 0.92);
  cursor: zoom-out;
}
.vs-lightbox[hidden] { display: none !important; }
.vs-lightbox img {
  max-width: 96vw;
  max-height: 92vh;
  border-radius: 10px;
  box-shadow: 0 24px 70px rgba(0, 0, 0, 0.55);
}
.vs-lightbox-close {
  position: fixed;
  top: 14px;
  right: 20px;
  background: transparent;
  border: none;
  color: #fff;
  font-size: 42px;
  line-height: 1;
  cursor: pointer;
}

/* Przyciski udostepniania pod kartą statusu. */
.vs-share { display: flex; gap: 8px; margin-top: 10px; }
.vs-share-btn {
  flex: 1;
  padding: 9px 10px;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: transparent;
  color: var(--text-muted);
  font: inherit;
  font-weight: 600;
  font-size: 13px;
  cursor: pointer;
  transition: border-color .12s ease, color .12s ease;
}
.vs-share-btn:hover { border-color: var(--accent); color: var(--accent); }

/* --------------------------------------------------------------------
   Formularz "Zglos blad w tlumaczeniu" w karcie bocznej projektu.
   -------------------------------------------------------------------- */
.vs-report {
  margin-top: 1rem;
  padding-top: 1rem;
  border-top: 1px solid var(--border);
}
.vs-report-toggle {
  width: 100%;
  border: 1px solid var(--border);
  background: transparent;
  color: var(--text-muted);
  border-radius: 12px;
  padding: .6rem .8rem;
  font-size: .9rem;
  font-weight: 600;
  cursor: pointer;
  transition: border-color .12s ease, color .12s ease;
}
.vs-report-toggle:hover {
  border-color: var(--accent);
  color: var(--accent);
}
.vs-report-form {
  display: grid;
  gap: .6rem;
  margin-top: .75rem;
}
.vs-report-field {
  display: grid;
  gap: .25rem;
}
.vs-report-field span {
  font-size: .82rem;
  font-weight: 600;
  color: var(--text-muted);
}
.vs-report-field input,
.vs-report-field textarea {
  width: 100%;
  padding: .55rem .7rem;
  border-radius: 10px;
  border: 1px solid var(--border);
  background: var(--bg, transparent);
  color: inherit;
  font: inherit;
}
.vs-report-field textarea { resize: vertical; }
.vs-report-note { color: var(--text-muted); font-size: .76rem; }
.vs-report-send {
  border: none;
  background: var(--accent);
  color: #fff;
  border-radius: 10px;
  padding: .6rem .8rem;
  font-weight: 600;
  font-size: .9rem;
  cursor: pointer;
}
.vs-report-send:disabled { opacity: .6; cursor: default; }
.vs-report-msg { margin: 0; font-size: .85rem; }
.vs-report-msg.is-ok { color: var(--green); }
.vs-report-msg.is-err { color: #e0566f; }

/* --------------------------------------------------------------------
   "Polecane spolszczenia" na dole podstrony projektu.
   -------------------------------------------------------------------- */
.recommended {
  margin: 28px clamp(16px, 5vw, 56px) 12px;
}
.recommended > h2 {
  margin: 0 0 16px;
  font-size: 20px;
  letter-spacing: -0.02em;
}
.recommended-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(230px, 1fr));
  gap: 14px;
}
.rec-card {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px;
  border: 1px solid var(--border);
  border-radius: 14px;
  background: var(--surface);
  text-decoration: none;
  color: inherit;
  transition: border-color .15s ease, transform .15s ease;
}
.rec-card:hover {
  border-color: var(--accent);
  transform: translateY(-2px);
}
.rec-cover {
  display: block;
  width: 66px;
  height: 48px;
  flex: none;
  overflow: hidden;
  border-radius: 9px;
  background: var(--surface-soft);
}
.rec-cover img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.rec-info {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}
.rec-info strong {
  font-size: 15px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.rec-info small {
  color: var(--text-muted);
  font-size: 12px;
}
