.contest-slider {
  width: 100%;
  position: relative;
  z-index: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
}
.contest-swiper {
  width: 100%;
}
.contest-swiper-container {
  width: 100%;
  display: flex;
  justify-content: center;
  align-items: center;
  padding-top: 1rem;
  margin-top: -1rem;
  overflow: hidden;
  -webkit-mask-image: linear-gradient(
    to right,
    transparent 0%,
    black 20%,
    black 80%,
    transparent 100%
  );
  mask-image: linear-gradient(
    to right,
    transparent 0%,
    black 20%,
    black 80%,
    transparent 100%
  );
}
.contest-swiper-width-setter {
  width: 110vw;
}
.contest-swipers {
  padding-top: 1rem;
  margin-top: -1rem;
}
.cerita {
  width: 100%;
  aspect-ratio: 0.562 / 1;
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  border-radius: var(--global-radius);
  padding: 16px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  overflow: hidden;
}
.cerita::before {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 40%; /* adjust how much gradient covers */
  background: linear-gradient(to top, rgba(0, 0, 0, 0.9), transparent);
  pointer-events: none; /* allow button clicks through overlay */
  border-radius: inherit; /* match parent rounding */
  border-top-left-radius: 0;
  border-top-right-radius: 0;
}
.cerita-vote {
  display: flex;
  justify-content: flex-end;
  align-items: center;
  gap: 8px;
  z-index: 1;
}
.vote-count {
  font-weight: 600;
}
.cerita-vote button {
  border-radius: 50%;
  width: 40px;
  height: 40px;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  border: none;
  cursor: pointer;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.2);
  transition:
    transform 0.2s ease,
    box-shadow 0.2s ease;
}
.cerita-vote button:hover {
  transform: translateY(-3px);
  box-shadow: 0 8px 12px rgba(0, 0, 0, 0.3);
}
.cerita-vote button svg {
  width: 27px;
  height: 30px;
  color: crimson;
}
.cerita-meta {
  display: flex;
  flex-direction: column;
  text-align: start;
  gap: 8px;
  z-index: 1;
}
.cerita-meta h4 {
  margin: 0;
  font-size: 20px;
  text-transform: uppercase;
  line-height: 1;
}
.cerita-meta p {
  font-size: 16px;
}
#rcsSubmitBtn,
.rcs-submit-btn {
  margin-top: 24px;
  border-radius: 9999px;
  background: var(--header-color);
  text-transform: uppercase;
  color: #fff;
  font-size: 16px;
  font-weight: 600;
  padding: 0.75rem 1.25rem;
  border: none;
  cursor: pointer;
  box-shadow:
    0 4px 6px -1px rgba(0, 0, 0, 0.1),
    0 2px 4px -1px rgba(0, 0, 0, 0.06);
  transition:
    background 0.2s ease,
    transform 0.1s ease;
  line-height: 1.5;
  text-align: center;
  display: inline-flex;
  justify-content: center;
}
#rcsSubmitBtn:hover,
#rcs-submit-btn:hover {
  background: #03403a;
  transform: translateY(-1px);
}
#rcsSubmitBtn:focus,
#rcs-submit-btn:focus {
  outline: 2px solid #09a394;
  outline-offset: 2px;
}

.rcs-modal {
  display: none;
  position: fixed;
  z-index: 10001;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.7);
  color: #333;
}
.rcs-modal-container {
  overflow: auto;
  height: 100%;
  width: 100%;
  display: flex;
  flex-direction: column;
  padding-top: 60px;
  padding-bottom: 60px;
}
.rcs-modal-content {
  max-width: 420px;
  border-radius: 12px;
  position: relative;
  padding: 20px;
  text-align: center;
  display: flex;
  flex-direction: column;
  gap: 16px;
  justify-content: center;
  align-items: center;
  margin: auto;
}
.rcs-modal-content h2 {
  font-weight: 700;
  font-size: 20px;
  margin: 0;
}
/* .rcs-modal-content {
  background: #fff;
  padding: 20px;
  width: 500px;
  max-width: 90%;
  position: relative;
  border-radius: 16px;
} */
.rcs-close {
  position: absolute;
  top: 12px;
  right: 14px;
  background: transparent;
  border: none;
  font-size: 28px;
  font-weight: 700;
  cursor: pointer;
}
#rcsForm {
  display: flex;
  flex-direction: column;
  height: 100%;
  text-align: start;
  gap: 16px;
}
#rcsForm.rcs-loading {
  position: relative;
  pointer-events: none;
  opacity: 0.6;
}
#rcsForm.rcs-loading::after {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  width: 28px;
  height: 28px;
  border: 3px solid #000;
  border-top-color: transparent;
  border-radius: 50%;
  transform: translate(-50%, -50%);
  animation: rcsSpin 0.8s linear infinite;
}
@keyframes rcsSpin {
  to {
    transform: translate(-50%, -50%) rotate(360deg);
  }
}
#rcsForm label {
  font-size: 14px;
  font-weight: 600;
}
#rcsForm input {
  padding: 8px 16px;
  border: 1px solid #d1d5db;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.5);
  font-size: 16px;
}
#rcsForm textarea {
  padding: 8px 16px;
  border: 1px solid #d1d5db;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.5);
  font-size: 16px;
}
#rcsForm select {
  padding: 8px 16px;
  border: 1px solid #d1d5db;
  border-radius: 8px;
  font-size: 16px;
  background: rgba(255, 255, 255, 0.5);
  cursor: pointer;
}
.rcs-img-container {
  display: flex;
  align-items: center;
  justify-content: center;
}
.rcs-img-container img {
  display: none;
  max-width: 250px;
  max-height: 330px;
  margin: 10px 0px;
}

.voting-loading {
  position: relative;
  pointer-events: none;
}
.voting-loading::after {
  content: "";
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.5);
  border-radius: var(--global-radius);
}
.voting-loading::before {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  width: 28px;
  height: 28px;
  border: 3px solid #fff;
  border-top-color: transparent;
  border-radius: 50%;
  transform: translate(-50%, -50%);
  animation: rcsSpin 0.8s linear infinite;
}
@keyframes rcsSpin {
  to {
    transform: translate(-50%, -50%) rotate(360deg);
  }
}

.rcs-status {
  font-weight: 600;
}

.rcs-status option[value="publish"] {
  color: green;
}
.rcs-status option[value="draft"] {
  color: orange;
}
.rcs-status option[value="rejected"] {
  color: red;
}

.cerita-link {
  color: unset;
}

.show-cerita-btn {
  background: none;
  border: none;
  padding: 0;
  margin: 0;
  margin-top: 16px;

  font-size: 16px;
  color: #00864a;
  text-decoration: none;
  cursor: pointer;

  font-weight: 500;
}
.show-cerita-btn:hover {
  filter: brightness(1.3);
  text-decoration: underline;
}
.see-more-btn-wrapper {
  display: flex;
  justify-content: flex-end;
}
.see-more-btn {
  text-align: right;
  color: #00ff8d;
  background: transparent;
  border: none;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
}
.see-more-btn:hover {
  filter: brightness(1.5);
}
.show-cerita-btn:focus {
  outline: none;
}
.rcs-full-cerita-wrapper {
  width: 100%;
}
#rcsFullCeritaModal .rcs-modal-content {
  max-width: min(600px, 90%);
  width: 100%;
}
.rcs-full-cerita-wrapper #modal-votes {
  margin-bottom: 16px;
  font-weight: 600;
}
.rcs-full-cerita-wrapper #modal-caption {
  max-height: 500px;
  overflow: auto;
  display: flex;
  flex-direction: column;
  text-align: start;
  gap: 16px;
}

.rcs-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
}

.rcs-grid-card {
  flex: 0.5;
}

.rcs-grid-card .cerita {
  height: 220px;
  background-size: cover;
  background-position: center;
  border-radius: 10px;
  position: relative;
  overflow: hidden;
}

.rcs-grid-card .cerita-meta {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 10px;
  background: linear-gradient(transparent, rgba(0, 0, 0, 0.8));
  color: white;
}

#rcsGridModal .cerita-meta-title {
  font-size: 20px;
}
#rcsGridModal .cerita-meta-description {
  font-size: 14px;
}

@media (min-width: 768px) {
  .cerita-meta h4 {
    font-size: 1.7vw;
  }
  .cerita-meta p {
    font-size: 1.2vw;
  }
}

@media (min-width: 1536px) {
  .cerita-meta h4 {
    font-size: 26px;
  }
  .cerita-meta p {
    font-size: 16px;
  }
}