/* * Styles for the Tournament Showdown Block - BuzzFeed Style */
:root {
  --tournament-primary-color: #5e36ff;
  --tournament-secondary-color: #307df0;
  --tournament-accent-color: #fed501;
  --tournament-card-background: #ffffff;
  --tournament-text-color: #333;
  --tournament-vs-size: 80px;
}

.buzzeditor-poll-tournament {
  background: linear-gradient(135deg, #181818 0%, #4a4a4a 50%, #232323 100%);
  background: linear-gradient(135deg, #5e36ff 0%, #307df0 50%, #5e36ff 100%);
  padding: 20px;
  border-radius: 20px;
  position: relative;
  overflow: hidden;
  margin: 2em auto;
}

/* Tournament Header */
.tournament-title {
  font-size: 3em;
  color: #fff;
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: -2px;
  margin-bottom: 20px;
  margin-top: 0px;
  text-shadow: 0 5px 20px rgba(0, 0, 0, 0.3);
  text-align: center;
  position: relative;
  animation: slideDown 0.8s ease-out;
}

.tournament-description {
  color: #fff;
  text-align: center;
  font-size: 1.2em;
  margin-bottom: 20px;
}

@keyframes slideDown {
  from {
    transform: translateY(-30px);
    opacity: 0;
  }
  to {
    transform: translateY(0);
    opacity: 1;
  }
}

/* Sparkle elements for title */
.tournament-title::before,
.tournament-title::after {
  content: "✨";
  position: absolute;
  color: var(--tournament-accent-color);
  font-size: 1.5em;
  animation: sparkle 2s ease-in-out infinite;
}

.tournament-title::before {
  top: -20px;
  left: -30px;
}

.tournament-title::after {
  top: -10px;
  right: -20px;
  animation-delay: 0.5s;
}

@keyframes sparkle {
  0%,
  100% {
    opacity: 0;
    transform: scale(0) rotate(0deg);
  }
  50% {
    opacity: 1;
    transform: scale(1) rotate(180deg);
  }
}

/* Tournament Content */
.tournament-content {
  position: relative;
  z-index: 2;
}

.tournament-bracket {
  background: rgba(255, 255, 255, 0.98);
  border-radius: 30px;
  padding: 40px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
  backdrop-filter: blur(10px);
  animation: fadeIn 0.8s ease-out;
}

@keyframes fadeIn {
  from {
    opacity: 0;
    transform: scale(0.95);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}

/* Start Screen Styles */
.tournament-start-screen {
  text-align: center;
  padding: 20px;
  animation: fadeIn 0.8s ease-out;
}

.start-title {
  font-size: 2.2em;
  letter-spacing: -1px;
  color: #333;
  margin-bottom: 20px;
  text-transform: uppercase;
}

.start-description {
  color: #666;
  font-size: clamp(1rem, 2.4vw, 1.2em);
  line-height: clamp(1.5rem, 2.4vw, 1.4em);
  margin: 10px 0;
}

.start-info {
  color: #2e2e2e;
  font-size: 1em;
  font-weight: 500;
  margin: 20px 0 30px 0;
}

.start-button {
  background: linear-gradient(45deg, #5e36ff, #307df0);
  color: white;
  border: none;
  padding: 20px 60px;
  font-size: 1.5em;
  font-weight: 800;
  border-radius: 50px;
  cursor: pointer;
  transition: all 0.3s;
  text-transform: uppercase;
  letter-spacing: 2px;
  box-shadow: 0 10px 30px rgba(94, 54, 255, 0.3);
  position: relative;
  overflow: hidden;
}

.start-button::before {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  width: 0;
  height: 0;
  background: rgba(255, 255, 255, 0.3);
  border-radius: 50%;
  transform: translate(-50%, -50%);
  transition: width 0.6s, height 0.6s;
}

.start-button:hover::before {
  width: 300px;
  height: 300px;
}

.start-button:hover {
  transform: translateY(-3px);
  box-shadow: 0 15px 40px rgba(94, 54, 255, 0.5);
}

/* Tournament Started State */
.buzzeditor-poll-tournament.tournament-started .tournament-bracket {
  background: rgba(255, 255, 255, 0.98);
  border-radius: 30px;
  padding: 30px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
}

/* Tournament Round Indicator - Progress Bar verzió */
.tournament-round-indicator {
  background: #f3f3f3;
  color: #333;
  padding: 12px 35px;
  border-radius: 15px;
  font-size: 1.3em;
  font-weight: bold;
  display: inline-block;
  text-transform: uppercase;
  letter-spacing: 1px;
  margin-bottom: 30px;
  text-align: center;
  width: 100%;
  position: relative;
  overflow: hidden; /* Fontos a progress bar miatt */
  transition: all 0.3s ease;
}

/* Progress bar kitöltés */
.tournament-round-indicator::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  height: 100%;
  width: var(--progress, 0%);
  background: linear-gradient(90deg, #fed501 0%, #ffc107 100%);
  transition: width 0.5s ease;
  z-index: 1;
}

/* Szöveg z-index beállítása */
.tournament-round-indicator span {
  position: relative;
  z-index: 2;
  text-shadow: 0 1px 2px rgba(0,0,0,0.1);
}

/* Kész állapot esetén 
.tournament-round-indicator.completed::before {
  background: #39ae51;
}
.tournament-round-indicator.completed {
    color: #fff;
    transition: all 0.1s;
}*/
span.meccsinfo {display: none;}

/* Animáció az újratöltéskor */
@keyframes fillProgress {
  from {
    width: 0;
  }
  to {
    width: var(--progress, 0%);
  }
}

.tournament-round-indicator.animate::before {
  animation: fillProgress 0.8s ease-out;
}

@keyframes pulse {
  0%,
  100% {
    transform: scale(1);
  }
  50% {
    transform: scale(1.05);
  }
}

/* Tournament Matchup - FIXED LAYOUT */
.tournament-matchup {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 40px;
  position: relative;
  z-index: 2;
  padding: 20px 0;
  align-items: center;
}

/* VS Badge - FIXED POSITIONING */
.vs-badge {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: var(--tournament-vs-size);
  height: var(--tournament-vs-size);
  background: var(--tournament-accent-color);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 900;
  font-size: 1.2em;
  color: #333;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
  z-index: 10;
  animation: vsGlow 2s ease-in-out infinite;
}

@keyframes vsGlow {
  0%,
  100% {
    transform: translate(-50%, -50%) scale(1);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
  }
  50% {
    transform: translate(-50%, -50%) scale(1.1);
    box-shadow: 0 10px 40px rgba(254, 213, 1, 0.6);
  }
}

/* Competitor Card - ENLARGED */
.tournament-competitor {
  background: #fff;
  border-radius: 20px;
  overflow: hidden;
  cursor: pointer;
  transition: all 0.4s cubic-bezier(0.68, -0.55, 0.265, 1.55);
  position: relative;
  box-shadow: 0 5px 20px rgba(0, 0, 0, 0.1);
  border: 4px solid transparent;
  min-height: 300px;
}

/* Competitor Image - ENLARGED */
.competitor-image-wrapper {
  width: 100%;
  height: 200px;
  position: relative;
  overflow: hidden;
}

.competitor-image-wrapper img {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.4s;
}

/* No Image Placeholder */
.no-image-placeholder {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #f0f0f0;
  font-size: 4em;
  color: #ccc;
}

/* Competitor Text - ENLARGED */
.competitor-text {
  padding: 25px 20px;
  font-size: 1.8em;
  font-weight: 800;
  color: var(--tournament-text-color);
  text-align: center;
  background: linear-gradient(to bottom, #fff 0%, #f8f9fa 100%);
  min-height: 80px;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Click to Vote Overlay */
.click-overlay {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(48, 125, 240, 0);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.3s;
  pointer-events: none;
}

.click-text {
  background: var(--tournament-secondary-color);
  color: white;
  padding: 10px 15px;
  border-radius: 50px;
  font-weight: bold;
  font-size: .9em;
  opacity: 0;
  transform: scale(0.8);
  transition: all 0.3s;
}

.tournament-competitor.selected .click-text {
    transform: scale(0.8)!important;
    opacity: 1!important;
    transition: all 0.6s!important;
    background-color: #28a745;
}

/* Selected and Eliminated States - JAVÍTOTT VERZIÓ */
.tournament-competitor.selected {
  border-color: #28a745 !important;
  /* Hover transform értékek megőrzése kiválasztás után - IMPORTANT-tal megerősítve */
  transform: translateY(-10px) scale(1.02) !important;
  box-shadow: 0 20px 40px rgba(40, 167, 69, 0.5) !important;
  /* Animáció eltávolítása, mert felülírja a transform értékeket */
  animation: none !important;
}

/* First-child selected state - balra dőlés megőrzése */
.tournament-competitor.selected:first-child {
  transform: translateY(-10px) scale(1.02) rotate(-2deg) !important;
}

/* Last-child selected state - jobbra dőlés megőrzése */
.tournament-competitor.selected:last-child {
  transform: translateY(-10px) scale(1.02) rotate(2deg) !important;
}

/* Selected kártya képének nagyítása is megmarad */
.tournament-competitor.selected .competitor-image-wrapper img {
  transform: scale(1.1) !important;
}

/* Winner animáció eltávolítva, mert felülírta a transform értékeket */
@keyframes winner {
  0% {
    opacity: 1;
  }
  100% {
    opacity: 1;
  }
}

.tournament-competitor.eliminated {
  animation: loser 0.6s ease-out forwards;
}

@keyframes loser {
  to {
    opacity: 0.5;
    transform: scale(0.95);
    filter: grayscale(80%);
  }
}

ul.final-ranking.personal-ranking,
ol.final-ranking {
  padding-left: 0px !important;
}

.buzzeditor-poll-tournament.show-results .tournament-round-indicator {
  margin-bottom: 0px;
}

/* Results Screen */
.tournament-results {
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 1000;
  display: none;
  margin-top: 30px;
}

.ak-post-content h4.gyoztes-note {
    transform: translateY(-20px);
    font-size: 14px;
    color: #fff;
    font-weight: 700;
    letter-spacing: .5px;
    margin-bottom: 0px;
}

.buzzeditor-poll-tournament.wp-block-buzzeditor-tournament {
    margin-top: 12px;
}

.tournament-results-overlay {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 0px 20px 40px 20px;
}

/* Winner Section */
.winner-section {
  text-align: center;
  animation: popIn 0.5s cubic-bezier(0.68, -0.55, 0.27, 1.55) forwards;
}

@keyframes popIn {
  from {
    transform: scale(0.5);
    opacity: 0;
  }
  to {
    transform: scale(1);
    opacity: 1;
  }
}

.crown-icon {
  font-size: 4em;
  animation: bounce 2s ease-in-out infinite;
}

@keyframes bounce {
  0%,
  100% {
    transform: translateY(5px);
  }
  50% {
    transform: translateY(-15px);
  }
}

.winner-section h2 {
  font-size: 1.43em;
  color: #fff;
  text-transform: uppercase;
  margin: 10px 0 30px 0;
  text-shadow: 0 5px 20px rgba(0, 0, 0, 0.3);
}

.winner-image {
  width: 200px;
  height: 200px;
  border-radius: 50%;
  object-fit: cover;
  border: 8px solid var(--tournament-accent-color);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
  margin: 20px auto;
  display: block;
  animation: winnerGlow 2s ease-in-out infinite;
}

@keyframes winnerGlow {
  0%,
  100% {
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3), 0 0 40px rgba(254, 213, 1, 0.5);
  }
  50% {
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3), 0 0 60px rgba(254, 213, 1, 0.8);
  }
}

.ak-post-content h3.winner-name {
  font-size: clamp(1.5rem, 0.851rem + 2.597vw, 2.5rem);
  color: var(--tournament-accent-color);
  text-transform: uppercase;
  margin: 20px 0;
  text-shadow: 0 5px 20px rgba(0, 0, 0, 0.3) !important;
  font-weight: 800;
}

.winner-no-image {
  width: 300px;
  height: 300px;
  border-radius: 50%;
  font-size: 6em;
  margin: 20px auto;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #f0f0f0;
  border: 8px solid var(--tournament-accent-color);
}

/* Final Ranking */
.final-ranking-wrapper {
  background: rgba(255, 255, 255, 0.98);
  border-radius: 20px;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.2);
  width: 100%;
}
.single .ak-post-content .final-ranking-wrapper li.ranking-item {
    margin-left: 0px;
}

.final-ranking-wrapper h4 {
  font-size: 2em;
  color: #333;
  text-align: center;
  margin-bottom: 30px;
}

.tabs {
  display: flex;
  justify-content: center;
  margin-bottom: 20px;
  margin-top:25px;
}

.tab {
  padding: 10px 20px;
  cursor: pointer;
  background: #eee;
  margin: 0 5px;
  border-radius: 5px;
  font-weight: 700;
}

.tab.active {
  background: var(--tournament-accent-color);
}

.ranking-grid {
  margin: 0 auto;
}

.ranking-column h5 {
  font-size: 1.5em;
  color: #666;
  margin-bottom: 20px;
  text-align: center;
}

/* Final Ranking - JAVÍTOTT */
.final-ranking {
  list-style: none;
  padding: 0;
  margin: 0;
}

.final-ranking li {
  display: flex;
  align-items: center;
  padding: 15px 20px;
  margin-bottom: 10px;
  border-radius: 15px;
  font-weight: 700;
  font-size: 1.2em;
  transition: all 0.3s;
  animation: slideIn 0.5s ease-out backwards;
  position: relative;
  overflow: hidden;
  background: #f8f9fa;
  background: #f3f3f3;
}

.final-ranking li:hover {
  transform: translateX(5px);
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

/* Rank-specific styling */
.final-ranking li.rank-1 {
  animation-delay: 0.1s;
  background: linear-gradient(135deg, #fff3cd 0%, #ffeaa7 100%);
  border: 2px solid #f1c40f;
}

.final-ranking li.rank-1 .ranking-image {
    border: 3px solid #f1c40f;
}
.final-ranking li.rank-2 .ranking-image {
    border: 3px solid #26a69a;
}
.final-ranking li.rank-3 .ranking-image {
    border: 3px solid #e74c3c;
}

.final-ranking li.rank-2 {
  animation-delay: 0.2s;
  background: linear-gradient(135deg, #d1ecf1 0%, #b2dfdb 100%);
  border: 2px solid #26a69a;
}

.final-ranking li.rank-3 {
  animation-delay: 0.3s;
  background: linear-gradient(135deg, #f8d7da 0%, #ffcccb 100%);
  border: 2px solid #e74c3c;
}

.final-ranking li.rank-4 {
  animation-delay: 0.4s;
}

.final-ranking li.rank-5 {
  animation-delay: 0.5s;
}

.final-ranking li.rank-6 {
  animation-delay: 0.6s;
}

.final-ranking li.rank-7 {
  animation-delay: 0.7s;
}

.final-ranking li.rank-8 {
  animation-delay: 0.8s;
}

/* Rank Badge Styling */
.rank-badge {
  font-size: 1.8em;
  margin-right: 15px;
  min-width: 50px;
  text-align: center;
  display: inline-block;
}

.final-ranking li.rank-1 .rank-badge {
  color: #f1c40f;
  text-shadow: 0 2px 4px rgba(241, 196, 15, 0.3);
  animation: goldGlow 2s ease-in-out infinite;
}

.final-ranking li.rank-2 .rank-badge {
  color: #95a5a6;
  text-shadow: 0 2px 4px rgba(149, 165, 166, 0.3);
}

.final-ranking li.rank-3 .rank-badge {
  color: #e67e22;
  text-shadow: 0 2px 4px rgba(230, 126, 34, 0.3);
}

/* Ranking Medal - EREDETI STÍLUS VISSZAÁLLÍTVA */
.ranking-medal {
  position: absolute;
  top: -5px;
  right: -5px;
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5em;
  transform: rotate(15deg);
}

/* Ranking Item - EREDETI STÍLUS VISSZAÁLLÍTVA */
.ranking-item {
  display: flex;
  align-items: center;
  padding: 15px;
  background: #f8f9fa;
  border-radius: 15px;
  transition: all 0.3s;
  animation: slideIn 0.5s ease-out backwards;
  position: relative;
  overflow: hidden;
  margin-bottom: 10px;
}

.ranking-item:hover {
  transform: translateX(5px);
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

.ranking-item.rank-1 {
  animation-delay: 0.1s;
  background: #fff3cd;
}

.ranking-item.rank-2 {
  animation-delay: 0.2s;
  background: #d1ecf1;
}

.ranking-item.rank-3 {
  animation-delay: 0.3s;
  background: #f8d7da;
}

.ranking-item.rank-4 {
  animation-delay: 0.4s;
}

.ranking-item.rank-5 {
  animation-delay: 0.5s;
}

.ranking-position {
  font-size: 1.8em;
  font-weight: 900;
  color: #666;
  margin-right: 15px;
  min-width: 50px;
}

.ranking-item.rank-1 .ranking-position {
  color: #f1c40f;
}

.ranking-item.rank-2 .ranking-position {
  color: #26a69a;
}

.ranking-item.rank-3 .ranking-position {
  color: #e74c3c;
}

@keyframes goldGlow {
  0%,
  100% {
    transform: scale(1);
  }
  50% {
    transform: scale(1.1);
  }
}

/* Community Results Column */
.community-results {
  background: rgba(255, 255, 255, 0.98);
  border-radius: 20px;
  padding: 30px;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.2);
  min-width: 350px;
  animation: fadeInUp 0.5s 0.4s forwards;
  opacity: 0;
}

.community-results h5 {
  font-size: 1.5em;
  color: #666;
  margin-bottom: 20px;
  text-align: center;
  text-transform: uppercase;
  letter-spacing: 1px;
}

/* Ranking Column általános stílus */
.ranking-column {
  background: rgba(255, 255, 255, 0.98);
  border-radius: 20px;
  padding: 0px 30px 30px 30px;
  min-width: 320px;
  animation: fadeInUp 0.5s 0.4s forwards;
  opacity: 0;
}

.ranking-column h5 {
  font-size: 1.5em;
  color: #666;
  margin-bottom: 20px;
  text-align: center;
  text-transform: uppercase;
  letter-spacing: 1px;
}

@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.ranking-image {
  width: 60px;
  height: 60px;
  border-radius: 50%;
  object-fit: cover;
  margin-right: 15px;
  border: 3px solid #fff;
}

.ranking-no-image {
  width: 60px;
  height: 60px;
  border-radius: 50%;
  background: #e9ecef;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-right: 15px;
  font-size: 1.5em;
}

.ranking-name {
  font-size: 1.2em;
  font-weight: 700;
  color: #333;
  flex-grow: 1;
}

/* Stats Box */
.stats-box {
  padding: 0px 10px 0px 10px;
  margin: 20px 0 0px 0;
  text-align: center;
  font-size: 12px;
  font-weight: 500;
}
.stats-box p {
    margin-bottom: 0px;
    line-height: 15px;
}

/* Restart Button */
.restart-button {
  background: linear-gradient(45deg, #5e36ff, #307df0);
  color: white;
  border: none;
  padding: 20px 60px;
  font-size: 1.5em;
  font-weight: 800;
  border-radius: 50px;
  cursor: pointer;
  transition: all 0.3s;
  text-transform: uppercase;
  letter-spacing: 2px;
  box-shadow: 0 10px 30px rgba(94, 54, 255, 0.3);
  position: relative;
  overflow: hidden;
  margin-top: 30px;
}

.restart-button::before {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  width: 0;
  height: 0;
  background: rgba(255, 255, 255, 0.3);
  border-radius: 50%;
  transform: translate(-50%, -50%);
  transition: width 0.6s, height 0.6s;
}

.restart-button:hover::before {
  width: 300px;
  height: 300px;
}

.restart-button:hover {
  transform: translateY(-3px);
  box-shadow: 0 15px 40px rgba(94, 54, 255, 0.5);
}

/* Loading Spinner */
.loading-spinner {
  color: #666;
  font-style: italic;
  padding: 20px;
  text-align: center;
}

.loading-tournament {
  padding: 40px;
  color: #fff;
  text-align: center;
  font-size: 1.2em;
}

/* Confetti Canvas */
#confetti-canvas {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 2000;
}

/* Confetti Particle (for burst effect) */
.confetti-particle {
  position: fixed;
  width: 10px;
  height: 10px;
  pointer-events: none;
  z-index: 1000;
  animation: confettiBurst 3s ease-out forwards;
}

@keyframes confettiBurst {
  0% {
    transform: translate(0, 0) rotate(0deg);
    opacity: 1;
  }
  100% {
    transform: translate(var(--x, 100px), var(--y, 100px)) rotate(720deg);
    opacity: 0;
  }
}

/* Mobile Responsive */
@media (max-width: 768px) {
  .tournament-title {
    font-size: 2.5em;
  }

  .tournament-matchup {
    grid-template-columns: 1fr;
    gap: 30px;
  }

  .vs-badge {
    /*position: relative;*/
    /*transform: none;*/
    /*margin: 20px auto;*/
    order: 1;
    font-size: 1em;
    border-radius: 35px;
    width: 80px;
    height: 60px;
  }

  .tournament-competitor {
    min-height: 300px;
  }

  .competitor-image-wrapper {
    height: 200px;
  }

  .competitor-text {
    font-size: 1.4em;
    padding: 20px;
    min-height: 60px;
  }

  .winner-image,
  .winner-no-image {
    width: 200px;
    height: 200px;
  }

  .winner-section h2 {
    font-size: 2.5em;
  }
}

@media (max-width: 480px) {
  .tournament-title {
    font-size: 2em;
  }

  .start-title {
    font-size: 2em;
  }

  .competitor-text {
    font-size: 1.2em;
  }

  .tournament-round-indicator {
    font-size: 1.1em;
    padding: 10px 25px;
  }
}

@keyframes slideIn {
  from {
    opacity: 0;
    transform: translateX(-20px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

/* Tournament Preview Images - ÚJ STÍLUSOK */
.tournament-preview-images {
  display: flex;
  justify-content: center;
  gap: 15px;
  margin-bottom: 30px;
  flex-wrap: wrap;
}

.preview-image {
  width: 80px;
  height: 80px;
  border-radius: 50%;
  object-fit: cover;
  border: 3px solid var(--tournament-accent-color);
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
  transition: transform 0.3s ease;
  animation: previewFloat 3s ease-in-out infinite;
}

.preview-image:nth-child(2) {
  animation-delay: 0.5s;
}

.preview-image:nth-child(3) {
  animation-delay: 1s;
}

.preview-image:nth-child(4) {
  animation-delay: 1.5s;
}

.preview-image.no-image {
  display: flex;
  align-items: center;
  justify-content: center;
  background: #f0f0f0;
  font-size: 2em;
  color: #ccc;
}

.preview-image:hover {
  transform: scale(1.1);
}

@keyframes previewFloat {
  0%,
  100% {
    transform: translateY(0px);
  }
  50% {
    transform: translateY(-10px);
  }
}

/* Mobile responsive for preview images */
@media (max-width: 480px) {
  .preview-image {
    width: 60px;
    height: 60px;
  }

  .tournament-preview-images {
    gap: 10px;
    margin-bottom: 20px;
  }
}

/* Ensure two columns when space allows */
@media (min-width: 768px) {
  .community-results {
    background: unset;
    box-shadow: unset;
  }
  .tournament-competitor:hover .click-overlay {
  background: rgba(48, 125, 240, 0.1);
  }
  .tournament-competitor.selected:hover .click-overlay {
  background: unset;
  }
  .ranking-column {
    background: unset;
  }
  .tournament-competitor:hover {
  transform: translateY(-10px) scale(1.02);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.2);
  border-color: var(--tournament-secondary-color);
  }

  .tournament-competitor:first-child:hover {
    transform: translateY(-10px) scale(1.02) rotate(-2deg);
  }

  .tournament-competitor:last-child:hover {
    transform: translateY(-10px) scale(1.02) rotate(2deg);
  }
  .tournament-competitor:hover .competitor-image-wrapper img {
  transform: scale(1.1);
  }
  .tournament-competitor:hover .click-text {
  opacity: 1;
  transform: scale(1);
  }
}

@media only screen and (max-width: 991px) {
    .ak-post-content h3.tournament-title {
        font-size: clamp(1.5rem, 5vw + 14px, 3em);
    }
}


@media (min-width: 350px) and (max-width: 768px) {
.buzzeditor-poll-tournament.wp-block-buzzeditor-tournament {
    margin-left: -16px;
    margin-right: -16px;
    border-radius: 0px;
}
.tournament-matchup {
        grid-template-columns: 1fr 1fr;
        margin-left: -15px;
        margin-right: -15px;
        gap: 15px;
}
.competitor-image-wrapper {
        height: clamp(140px, 15vw + 84px, 240px);
}
.tournament-competitor {
        min-height: 210px;
}
.vs-badge {
        font-size: 0.9em;
        border-radius: 100%;
        width: 60px;
        height: 60px;
}
.click-text {
        font-size: 12px;
        padding: 5px 10px 5px 10px;
}
.tournament-matchup {
    display: flex;
    align-items: stretch;
    gap: 15px;
}

.tournament-competitor {
    flex: 1;
    display: flex;
    flex-direction: column;
}

.competitor-text {
    flex-grow: 1;
    display: flex;
    align-items: center;
    padding: 10px;
}
}

@media (max-width: 350px) {
.buzzeditor-poll-tournament.tournament-started .tournament-bracket {
    padding: 20px;
  }
.final-ranking li {
    display: flex;
    flex-direction: column;
    gap: 10px;
    align-items: center;
    justify-content: center;
    text-align: center;
  }
li.ranking-item * {
    padding: 0px !important;
    margin: 0px !important;
  }
}

/* Dinamikus tournament kártyák */
@media (min-width: 350px) {
.tournament-matchup {
    display: flex;
    align-items: stretch;
    gap: 15px;
}

.tournament-competitor {
    flex: 1;
    display: flex;
    flex-direction: column;
}

.competitor-text {
    flex-grow: 1;
    display: flex;
    align-items: center;
    padding: 10px;
  }
}

@media (max-width: 500px) {
.ranking-grid .final-ranking li{padding:15px 15px}
.preview-image:nth-child(4) {display: none;}
.ranking-name{line-height: 1.2;font-size: clamp(1rem, 4.8vw, 1.2em);}
.ranking-position {font-size: clamp(1rem, 7vw, 1.2em);min-width: unset;margin-right: 15px;}
.ranking-image {width: 40px;height: 40px;}
.ranking-column{min-width: unset;}
.tournament-results-overlay {padding-left: 10px;padding-right: 10px;}
.ranking-column.personal-column {padding-left: 20px;padding-right: 20px;}
}
.buzzeditor-poll-tournament.show-results .tournament-bracket {display: none;}



/*Színválasztó séma*/
/*PIROS*/
.buzzeditor-poll-tournament.piros {
    background: linear-gradient(135deg, #ff3636 0%, #ca1616 50%, #ff3636 100%);
}
.buzzeditor-poll-tournament.piros button.start-button {
    background: linear-gradient(45deg, #ff3636, #f03030);
    box-shadow: 0 10px 30px rgb(255 54 54 / 30%);
}
.buzzeditor-poll-tournament.piros .start-button:hover {
    box-shadow: 0 15px 40px rgb(255 54 54 / 50%);
}
.buzzeditor-poll-tournament.piros .restart-button {
    background: linear-gradient(45deg, #ff3636, #f03030);
    box-shadow: 0 10px 30px rgb(0 0 0 / 30%);
}
.buzzeditor-poll-tournament.piros .restart-button:hover {
    box-shadow: 0 15px 40px rgb(0 0 0 / 50%);
}
/*ROZSASZIN*/
.buzzeditor-poll-tournament.rozsaszin {
    background: linear-gradient(135deg, #ff36ad 0%, #ff365b 50%, #ff36ad 100%);
}
.buzzeditor-poll-tournament.rozsaszin button.start-button {
    background: linear-gradient(45deg, #ff365b, #f0309a);
    box-shadow: 0 10px 30px rgb(255 54 121 / 30%);
}
.buzzeditor-poll-tournament.rozsaszin .start-button:hover {
    box-shadow: 0 15px 40px rgb(255 54 106 / 50%);
}
.buzzeditor-poll-tournament.rozsaszin .restart-button {
    background: linear-gradient(45deg, #ff365b, #f0309a);
    box-shadow: 0 10px 30px rgb(0 0 0 / 30%);
}
.buzzeditor-poll-tournament.rozsaszin .restart-button:hover {
    box-shadow: 0 15px 40px rgb(0 0 0 / 50%);
}
/*FEKETE*/
.buzzeditor-poll-tournament.fekete {
    background: linear-gradient(135deg, #262626 0%, #3b3b3b 50%, #252121 100%);
}
.buzzeditor-poll-tournament.fekete button.start-button {
    background: linear-gradient(45deg, #2e2e2e, #2e292c);
    box-shadow: 0 10px 30px rgb(0 0 0 / 30%);
}
.buzzeditor-poll-tournament.fekete .start-button:hover {
    box-shadow: 0 15px 40px rgb(0 0 0 / 50%);
}
.buzzeditor-poll-tournament.fekete .restart-button {
    background: linear-gradient(45deg, #2e2e2e, #2e292c);
    box-shadow: 0 10px 30px rgb(0 0 0 / 30%);
}
.buzzeditor-poll-tournament.fekete .restart-button:hover {
    box-shadow: 0 15px 40px rgb(0 0 0 / 50%);
}
/*ZÖLD*/
.buzzeditor-poll-tournament.zold {
    background: linear-gradient(135deg, #04d44c 0%, #29a253 50%, #04d44c 100%);
}
.buzzeditor-poll-tournament.zold button.start-button{
    background: linear-gradient(45deg, #04d44c, #20b453);
    box-shadow: 0 10px 30px rgb(54 255 94 / 30%);
}
.buzzeditor-poll-tournament.zold .start-button:hover {
    box-shadow: 0 15px 40px rgb(35 165 0 / 50%);
}
.buzzeditor-poll-tournament.zold .restart-button {
    background: linear-gradient(45deg, #04d44c, #20b453);
    box-shadow: 0 10px 30px rgb(0 0 0 / 30%);
}
.buzzeditor-poll-tournament.zold .restart-button:hover {
    box-shadow: 0 15px 40px rgb(0 0 0 / 50%);
}
/*SÁRGA*/
.buzzeditor-poll-tournament.sarga {
    background: linear-gradient(135deg, #ffb836 0%, #f0c830 50%, #ffb836 100%);
}
.buzzeditor-poll-tournament.sarga button.start-button{
    background: linear-gradient(45deg, #e49b15, #e2bc2a);
    box-shadow: 0 10px 30px rgb(255 184 54 / 30%);
}
.buzzeditor-poll-tournament.sarga .start-button:hover {
    box-shadow: 0 15px 40px rgb(255 228 54 / 50%);
}
.buzzeditor-poll-tournament.sarga .restart-button {
    background: linear-gradient(45deg, #e49b15, #e2bc2a);
    box-shadow: 0 10px 30px rgb(0 0 0 / 30%);
}
.buzzeditor-poll-tournament.sarga .restart-button:hover {
    box-shadow: 0 15px 40px rgb(0 0 0 / 50%);
}
/*NARANCS*/
.buzzeditor-poll-tournament.narancs {
    background: linear-gradient(135deg, #ff8b36 0%, #f06530 50%, #ff8b36 100%);
}
.buzzeditor-poll-tournament.narancs button.start-button{
    background: linear-gradient(45deg, #ff8b36, #e2642a);
    box-shadow: 0 10px 30px rgb(255 95 54 / 30%);
}
.buzzeditor-poll-tournament.narancs .start-button:hover {
    box-shadow: 0 15px 40px rgb(255 125 54 / 50%);
}
.buzzeditor-poll-tournament.narancs .restart-button {
    background: linear-gradient(45deg, #ff8b36, #e2642a);
    box-shadow: 0 10px 30px rgb(0 0 0 / 30%);
}
.buzzeditor-poll-tournament.narancs .restart-button:hover {
    box-shadow: 0 15px 40px rgb(0 0 0 / 50%);
}