/* 
 * TRL Design System - Round Judgment Component 
 * Styling for the round judgment page with submission videos and judging controls
 */

.judgment-page {
  display: flex;
  flex-direction: column;
  align-items: center;
  background: linear-gradient(135deg, var(--trl-primary), var(--trl-secondary));
  border-radius: 15px;
  overflow: scroll;
  position: relative;
  height: 100%;
}

.judgment-page .trl-app-menu {
  width: 100%;
  max-width: none;
  background-color: rgba(0, 0, 0, 0.2);
  border-radius: 0;
}

.judgment-page__header {
  padding: 20px;
  text-align: center;
  background-color: rgba(0, 0, 0, 0.3);
  position: relative;
  z-index: 1;
  width: 100%;
}

.judgment-page__title {
  font-size: 28px;
  font-weight: 900;
  margin: 0 0 5px;
  color: #ffffff;
  text-transform: uppercase;
  letter-spacing: 1px;
  text-shadow: 2px 2px 0 rgba(0, 0, 0, 0.3);
}

.judgment-page__subtitle {
  font-size: 16px;
  color: rgba(255, 255, 255, 0.8);
}

.judgment-page__song-name {
  font-size: 28px;
  font-weight: 900;
  text-align: center;
  padding: 15px 20px;
  margin: 0;
  background: rgba(0, 0, 0, 0.4);
  color: var(--trl-accent);
  text-shadow: 2px 2px 0 rgba(0, 0, 0, 0.5);
  width: 100%;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.judgment-page__content {
  width: 100%;
  padding: 24px;
  position: relative;
  z-index: 1;
  background: linear-gradient(135deg, var(--trl-primary), var(--trl-secondary));
  border-radius: 0 0 15px 15px;
  display: flex;
  flex-direction: column;
}

/* Instruction card */
.judgment-page__instructions {
  background-color: rgba(0, 0, 0, 0.2);
  border-radius: 10px;
  padding: 16px;
  position: relative;
  border: 1px solid rgba(255, 221, 0, 0.3);
}

.judgment-page__instructions-header {
  display: flex;
  align-items: center;
  margin-bottom: 8px;
}

.judgment-page__instructions-icon {
  font-size: 24px;
  margin-right: 8px;
  color: var(--trl-accent);
}

.judgment-page__instructions-title {
  font-size: 18px;
  font-weight: 700;
  color: var(--trl-white);
}

.judgment-page__instructions-list {
  list-style-type: none;
  margin: 0;
  padding: 0;
}

.judgment-page__instructions-list li {
  position: relative;
  padding-left: 24px;
  margin-bottom: 8px;
  color: rgba(255, 255, 255, 0.8);
  font-size: 14px;
}

.judgment-page__instructions-list li::before {
  content: "•";
  position: absolute;
  left: 8px;
  color: var(--trl-accent);
  font-size: 16px;
}

.judgment-page__instructions-list ul {
  list-style-type: none;
  margin: 8px 0 8px 8px;
  padding: 0;
}

.judgment-page__instructions-list ul li {
  padding-left: 20px;
}

.judgment-page__instructions-list ul li::before {
  content: "◦";
  left: 5px;
}

.judgment-page__instructions-list strong {
  color: var(--trl-white);
}

/* Judging control section */
.judgment-page__controls {
  margin-bottom: 24px;
}

.judgment-page__waiting-message {
  background-color: rgba(255, 50, 50, 0.1);
  border: 1px solid rgba(255, 50, 50, 0.3);
  border-radius: 8px;
  padding: 16px;
  text-align: center;
  margin-bottom: 16px;
}

.judgment-page__waiting-icon {
  font-size: 24px;
  margin-bottom: 8px;
  color: rgba(255, 100, 100, 0.8);
}

.judgment-page__waiting-text {
  font-size: 16px;
  font-weight: 700;
  color: rgba(255, 100, 100, 0.9);
  margin-bottom: 4px;
}

.judgment-page__info-message {
  background-color: rgba(0, 150, 255, 0.1);
  border: 1px solid rgba(0, 150, 255, 0.3);
  border-radius: 8px;
  padding: 16px;
  text-align: center;
  margin-bottom: 16px;
}

.judgment-page__info-title {
  font-size: 16px;
  font-weight: 700;
  color: var(--trl-primary);
  margin-bottom: 8px;
}

.judgment-page__info-text {
  font-size: 14px;
  color: rgba(255, 255, 255, 0.8);
}

/* Submissions grid */
.judgment-page__submissions {
  display: grid;
  grid-template-columns: 1fr;
  gap: 24px;
  margin-bottom: 24px;
  padding-right: 8px;
}

/* Custom scrollbar styling for better visibility */
.judgment-page__submissions::-webkit-scrollbar {
  width: 8px;
}

.judgment-page__submissions::-webkit-scrollbar-track {
  background: rgba(0, 0, 0, 0.2);
  border-radius: 4px;
}

.judgment-page__submissions::-webkit-scrollbar-thumb {
  background: rgba(255, 255, 255, 0.3);
  border-radius: 4px;
}

.judgment-page__submissions::-webkit-scrollbar-thumb:hover {
  background: rgba(255, 255, 255, 0.5);
}

.judgment-page__submission-card {
  background-color: rgba(0, 0, 0, 0.2);
  border-radius: 10px;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.1);
  transition: all 0.3s ease;
  height: auto;
  display: flex;
  flex-direction: column;
}

.judgment-page__submission-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
}

.judgment-page__submission-header {
  background-color: rgba(0, 0, 0, 0.2);
  padding: 12px 16px;
  display: flex;
  align-items: center;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.judgment-page__submission-id {
  font-size: 16px;
  font-weight: 700;
  margin: 0;
  color: var(--trl-white);
}

.judgment-page__video-container {
  width: 100%;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  position: relative;
}

.judgment-page__video-container iframe {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.2);
}

.judgment-page__actions {
  display: flex;
  gap: 14px;
  padding: 12px 16px;
  justify-content: center;
}

.judgment-page__winner-button,
.judgment-page__finalist-button {
  flex: 1;
  border: none;
  border-radius: 6px;
  padding: 12px;
  font-size: 14px;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.3s;
  text-transform: uppercase;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

.judgment-page__winner-button {
  background-color: var(--trl-accent);
  color: var(--trl-black);
  box-shadow: 0 3px 0 rgba(0, 0, 0, 0.3);
}

.judgment-page__winner-button:hover {
  background-color: #ffffff;
  transform: translateY(-2px);
  box-shadow: 0 5px 0 rgba(0, 0, 0, 0.3);
}

.judgment-page__winner-button:active {
  transform: translateY(1px);
  box-shadow: 0 2px 0 rgba(0, 0, 0, 0.3);
}

.judgment-page__finalist-button {
  background-color: rgba(0, 150, 255, 0.3);
  color: var(--trl-white);
  box-shadow: 0 3px 0 rgba(0, 0, 0, 0.3);
}

.judgment-page__finalist-button:hover {
  background-color: rgba(0, 150, 255, 0.5);
  transform: translateY(-2px);
  box-shadow: 0 5px 0 rgba(0, 0, 0, 0.3);
}

.judgment-page__finalist-button:active {
  transform: translateY(1px);
  box-shadow: 0 2px 0 rgba(0, 0, 0, 0.3);
}

/* Finalists section */
.judgment-page__finalists {
  padding-bottom: 16px;
  margin-bottom: 50px;
}

.judgment-page__finalists-header {
  background-color: rgba(0, 0, 0, 0.2);
  padding: 12px 16px;
  display: flex;
  align-items: center;
  border-bottom: 1px solid rgba(0, 150, 255, 0.3);
  margin-bottom: 16px;
}

.judgment-page__finalists-icon {
  font-size: 20px;
  margin-right: 12px;
  color: var(--trl-primary);
}

.judgment-page__finalists-title {
  font-size: 18px;
  font-weight: 700;
  margin: 0;
  color: var(--trl-white);
}

.judgment-page__finalists-description {
  font-size: 14px;
  color: rgba(255, 255, 255, 0.8);
  padding: 0 16px 16px;
  text-align: center;
  border-bottom: 1px solid rgba(0, 150, 255, 0.3);
  margin-bottom: 16px;
}

.judgment-page__finalists-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 16px;
  padding: 0 16px;
}

.judgment-page__finalist-card {
  background-color: rgba(0, 0, 0, 0.2);
  border-radius: 10px;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.1);
}

.judgment-page__runnerup-button {
  width: 100%;
  background-color: rgba(100, 150, 255, 0.3);
  color: var(--trl-white);
  border: none;
  border-radius: 6px;
  padding: 12px;
  font-size: 14px;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.3s;
  text-transform: uppercase;
  margin-top: 12px;
  box-shadow: 0 3px 0 rgba(0, 0, 0, 0.3);
}

.judgment-page__runnerup-button:hover {
  background-color: rgba(100, 150, 255, 0.5);
  transform: translateY(-2px);
  box-shadow: 0 5px 0 rgba(0, 0, 0, 0.3);
}

.judgment-page__runnerup-button:active {
  transform: translateY(1px);
  box-shadow: 0 2px 0 rgba(0, 0, 0, 0.3);
}

.judgment-page__note {
  background-color: rgba(255, 221, 0, 0.1);
  border: 1px solid rgba(255, 221, 0, 0.3);
  border-radius: 8px;
  padding: 12px 16px;
  margin: 16px 16px;
  font-size: 16px;
  color: var(--trl-accent);
  text-align: center;
  font-weight: bold;
}

/* Completed judgments section */
.judgment-page__completed {
  background-color: rgba(0, 200, 100, 0.1);
  border: 1px solid rgba(0, 200, 100, 0.3);
  border-radius: 10px;
  padding: 24px 16px;
  text-align: center;
  margin-bottom: 24px;
  animation: fadeInPulse 1s ease-out;
}

@keyframes fadeInPulse {
  0% {
    opacity: 0;
    transform: scale(0.95);
  }
  70% {
    opacity: 1;
    transform: scale(1.02);
  }
  100% {
    transform: scale(1);
  }
}

.judgment-page__completed-icon {
  font-size: 32px;
  color: rgba(0, 200, 100, 0.8);
  margin-bottom: 16px;
}

.judgment-page__completed-title {
  font-size: 24px;
  font-weight: 900;
  color: var(--trl-white);
  margin-bottom: 16px;
  text-transform: uppercase;
  letter-spacing: 1px;
  text-shadow: 2px 2px 0 rgba(0, 0, 0, 0.3);
}

.judgment-page__completed-text {
  font-size: 16px;
  color: rgba(255, 255, 255, 0.8);
  margin-bottom: 24px;
}

.judgment-page__results-item {
  background-color: rgba(0, 0, 0, 0.2);
  border-radius: 8px;
  padding: 12px;
  margin-bottom: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
}

.judgment-page__trophy {
  font-size: 24px;
  color: var(--trl-accent);
}

.judgment-page__medal {
  font-size: 24px;
  color: rgba(255, 255, 255, 0.6);
}

.judgment-page__results-text {
  font-size: 16px;
  font-weight: 700;
  color: var(--trl-white);
}

.judgment-page__results-score {
  font-size: 14px;
  background-color: rgba(0, 0, 0, 0.3);
  padding: 4px 8px;
  border-radius: 4px;
  color: var(--trl-accent);
}

.judgment-page__continue-button {
  display: inline-block;
  background-color: var(--trl-accent);
  color: var(--trl-black);
  border: none;
  border-radius: 8px;
  padding: 12px 24px;
  font-size: 16px;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.3s;
  text-transform: uppercase;
  letter-spacing: 1px;
  text-decoration: none;
  box-shadow: 0 4px 0 rgba(0, 0, 0, 0.3);
  margin-top: 16px;
}

.judgment-page__continue-button:hover {
  background-color: #ffffff;
  transform: translateY(-3px);
  box-shadow: 0 7px 0 rgba(0, 0, 0, 0.3);
  color: var(--trl-black);
  text-decoration: none;
}

.judgment-page__continue-button:active {
  transform: translateY(1px);
  box-shadow: 0 3px 0 rgba(0, 0, 0, 0.3);
}

/* Footer */
.judgment-page__footer {
  text-align: center;
  margin-top: 24px;
}

.judgment-page__back-link {
  display: inline-block;
  background-color: rgba(0, 0, 0, 0.2);
  color: var(--trl-white);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 20px;
  padding: 8px 16px;
  font-size: 14px;
  font-weight: 700;
  transition: all 0.2s;
  text-decoration: none;
}

.judgment-page__back-link:hover {
  background-color: rgba(0, 0, 0, 0.3);
  border-color: rgba(255, 255, 255, 0.3);
  color: var(--trl-white);
  text-decoration: none;
}

/* Responsive adjustments */
@media (min-width: 768px) {
}

@media (max-width: 480px) {
  .judgment-page__title {
    font-size: 24px;
  }

  .judgment-page__song-name {
    font-size: 24px;
    padding: 12px 16px;
  }

  .judgment-page__content {
    padding: 16px;
  }

  .judgment-page__actions {
    /* flex-direction: column; */
  }

  .judgment-page__submission-card {
    min-height: 280px;
  }
}
