/* Checkbox admin Prijave */
.wp-list-table th:first-child,
.wp-list-table td:first-child {
    width: 50px;
    text-align: center;
}

/* Lightbox za admin */
#pc-lightbox {
  display: none;
  position: fixed;
  top: 0; left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.85);
  justify-content: center;
  align-items: center;
  z-index: 10000;
  flex-direction: column;
}

#pc-lightbox-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
}


#pc-lightbox img {
  max-width: 90%;
  max-height: 80vh;
  border: 4px solid white;
  border-radius: 6px;
  background: white;
  box-shadow: 0 0 15px black;
}


#pc-lightbox-caption {
  color: white;
  margin-top: 1em;
  font-size: 1.1em;
  font-weight: 500;
}

#pc-lightbox-close {
  position: absolute;
  top: 20px;
  right: 30px;
  font-size: 32px;
  color: white;
  cursor: pointer;
  z-index: 10001;
  background: rgba(0, 0, 0, 0.5);
  padding: 4px 12px;
  border-radius: 4px;
}

#pc-lightbox-close:hover {
  background: rgba(255, 255, 255, 0.2);
}

.pc-thumb-admin {
  max-width: 80px;
}


.pc-thumb {
  max-width: 80px;
  cursor: pointer;
  transition: transform 0.2s ease-in-out;
}

.pc-thumb:hover {
  transform: scale(1.05);
}

/* Forma za registraciju */
.pc-form-wrapper {
  max-width: 500px;
  margin: 0 auto;
  padding: 1em;
  background: #ffffff;
  border: 1px solid #ddd;
  border-radius: 8px;
}

.pc-form-wrapper label {
  display: block;
  margin-top: 1em;
  font-weight: 500;
}

.pc-form-wrapper input[type="text"],
.pc-form-wrapper input[type="email"],
.pc-form-wrapper input[type="file"],
#opis-fotografije {
  width: 100%;
  padding: 0.5em;
  margin-top: 0.25em;
  border: 1px solid #ccc;
  border-radius: 4px;
}

.forma-zvjezdica-obavezno{
    color:red;
}

#opis-fotografije {
    resize: none;
    min-width: 70px;
    max-width: 100%;
}

.pc-form-wrapper button {
  margin-top: 1.5em;
  background-color: #0073aa;
  color: white;
  border: none;
  padding: 0.75em 1.5em;
  font-size: 1em;
  border-radius: 4px;
  cursor: pointer;
}

.pc-form-wrapper button:hover {
  background-color: #005f8d;
}

/* Galerija fotografija */
.pc-gallery {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 2em;
  margin: 2em;
}

/* Frontend galerija thumbnail */
.pc-gallery .pc-thumb {
  max-width: 100%;
  height: auto;
  object-fit: cover;
  cursor: pointer;
  transition: transform 0.2s ease-in-out;
}

.pc-photo-card {
  border: 1px solid #ddd;
  border-radius: 8px;
  overflow: hidden;
  background: #fff;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  height: 100%;
  transition: transform 0.2s ease;
}

.pc-photo-card:hover {
  transform: scale(1.02);
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.pc-photo-card img,
.pc-photo-card .pc-thumb {
  width: 100%;
  height: 250px;
  object-fit: cover;
  display: block;
}


.pc-photo-card .title {
  padding: 0.5em;
  font-weight: bold;
  font-size: 1em;
  text-align: center;
}

.pc-photo-author {
  font-size: 0.9em;
  color: #555;
  margin: 0 0 0.5em 0;
  text-align: center;
}

.pc-vote-count .pc-star {
  color: gold;
  margin-right: 4px;
  font-size: 1.3em;
}


.pc-photo-card .vote-button {
  background: #0073aa;
  color: white;
  padding: 0.5em 1em;
  margin: 1em auto 0.5em auto;
  border: none;
  border-radius: 4px;
  cursor: pointer;
  display: none;                 /*  ---- remove on next contest    */
}

.pc-photo-card .vote-button:hover {
  background: #004a70;
  transition: background-color 0.3s ease;
  color: #F6EB13;
}

.pc-vote-count {
  text-align: center;
  margin-bottom: 1em;
  color: #333;
  font-size: 0.95em;
}

.pc-vote-msg {
  text-align: center;
  margin-top: 0.5em;
  font-size: 0.95em;
  padding: 0.5em 1em;
  border-radius: 4px;
  display: inline-block;
  display: none;            /*  ---- remove on next contest    */
}

.pc-vote-msg.success {
  background-color: #e6f7e6;
  color: #1a6d1a;
}

.pc-vote-msg.error {
  background-color: #fdecea;
  color: #b20000;
}

.pc-placeholder-card {
  align-items: center;
  /*justify-content: center;*/
  text-align: center;
  min-height: 300px;
  background: #f9f9f9;
  border: 2px dashed #ccc;
}

.pc-placeholder-card .pc-empty-icon {
  font-size: 4em;
  color: #ccc;
  margin-top: 1em;
}

.pc-placeholder-card .vote-button {
  margin-top: 1em;
}


/* Widget */
.pc-widget-latest-photos {
  border-top: 2px solid #0073aa;
  padding-top: 1.5em;
  margin: 2em 0;
  font-family: inherit;
  border-bottom: 2px solid #0073aa;
  padding-bottom: 1.5em;
  position: relative;
  z-index: 0; /* važno za stacking context */

}

.pc-widget-latest-photos h3 {
  font-size: 1.25em;
  margin-top: 0;
  margin-bottom: 1em;
  /*color: #222;*/
  color: #2A6FA9;
}

.pc-widget-gallery {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1em;
  margin-bottom: 1em;
}

.pc-widget-photo img {
  width: 100%;
  height: 140px;
  object-fit: cover;
  border-radius: 6px;
  border: 1px solid #ddd;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.05);
}

.pc-widget-link {
  display: inline-block;
  margin-top: 0.5em;
  text-decoration: none;
  background: #0073aa;
  color: white;
  padding: 0.5em 1.2em;
  border-radius: 4px;
  font-size: 0.95em;
  transition: background 0.3s ease;
}

.pc-widget-link:hover {
  background: #004a70;
  color: #f6eb13;
}

/* Widget - image overlay - naslov fotografije */
.pc-widget-photo-inner {
  position: relative;
  overflow: hidden;
  border-radius: 6px;
}

.pc-widget-photo-inner img {
  display: block;
  width: 100%;
  height: 140px;
  object-fit: cover;
}

.pc-photo-overlay {
  position: absolute;
  bottom: 0;
  width: 100%;
  background: rgba(0, 0, 0, 0.55);
  color: #fff;
  padding: 0.3em 0.6em;
  font-size: 0.85em;
  text-align: center;
  font-weight: 500;
}

/* Widget - manji ekrani */
@media (max-width: 768px) {
  .pc-widget-gallery {
    grid-template-columns: repeat(2, 1fr);
  }

  .pc-widget-photo-inner img {
    height: 120px;
  }

  .pc-photo-overlay {
    font-size: 0.75em;
    padding: 0.2em 0.4em;
  }

  .pc-widget-link {
    display: block;
    width: 100%;
    text-align: center;
    margin-top: 1em;
    font-size: 1em;
    padding: 0.75em;
  }
}

@media (max-width: 480px) {
  .pc-widget-gallery {
    grid-template-columns: 1fr;
  }

  .pc-widget-photo-inner img {
    height: 180px;
  }
}

/* Slider na manjim ekranima */
@media (max-width: 768px) {
  .pc-widget-gallery {
    display: flex;
    overflow: hidden;
    scroll-behavior: smooth;
    scroll-snap-type: x mandatory;
    -webkit-overflow-scrolling: touch;
  }

  .pc-widget-photo {
    flex: 0 0 100%;
    scroll-snap-align: start;
  }

  .pc-widget-photo-inner {
    height: 220px; /* ili 200–250px prema ukusu */
    overflow: hidden;
    position: relative;
  }

  .pc-widget-photo-inner img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
  }
}

/* Widget overlay - link na stranicu natječaja */
.pc-widget-overlay-link {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 3;
  text-indent: -9999px; /* za pristupačnost */
  background: transparent;
  cursor: pointer;
}

.pc-widget-latest-photos > *:not(.pc-widget-overlay-link) {
  position: relative;
  z-index: 2;
}

/* DODATNE DORADE ZA BOLJI IZGLED */

/* Veći padding za formu */
.pc-form-wrapper {
  padding: 2em;
  box-shadow: 0 0 15px rgba(0, 0, 0, 0.05);
}

/* Hover efekt za gumb */
.pc-form-wrapper button:hover,
.pc-photo-card .vote-button:hover {
  background-color: #004a70;
  transition: background-color 0.3s ease;
}

/* Fallback stil ako slika nedostaje */
.pc-photo-card img {
  background-color: #f0f0f0;
  object-fit: contain;
  min-height: 200px;
}

/* Hover efekt za kartice */
.pc-photo-card {
  transition: transform 0.2s ease;
}
.pc-photo-card:hover {
  transform: scale(1.02);
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}