/* 
 * Competition Detail Page Specific Styles
 * Luxury Modern Midnight Refactor
 */

:root {
  --card-radius: 24px;
  --inner-radius: 16px;
}

.skeleton-glow {
  position: relative;
  overflow: hidden;
  background: rgba(255, 255, 255, 0.03) !important;
}

.shimmer {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg,
      transparent 0%,
      rgba(255, 255, 255, 0.05) 50%,
      transparent 100%);
  animation: shimmer-swipe 2s infinite;
}

@keyframes shimmer-swipe {
  0% {
    transform: translateX(-100%);
  }

  100% {
    transform: translateX(100%);
  }
}

.bg-card {
  background: var(--card-bg);
}

.tracking-widest {
  letter-spacing: 0.15em;
}

/* Cashback Display Styles */
.cashback-info {
  animation: slideDown 0.3s ease-out;
  display: flex;
  justify-content: center;
  align-items: center;
}

.cashback-info .alert {
  border-radius: 8px;
  padding: 0.75rem 1rem;
  border: 1px solid rgba(34, 197, 94, 0.3);
  background: rgba(34, 197, 94, 0.1);
  width: fit-content;
  margin: 0 auto;
}

.dark-theme .cashback-info .alert {
  background: rgba(34, 197, 94, 0.15);
  border-color: rgba(34, 197, 94, 0.4);
  color: #86efac;
}

.light-theme .cashback-info .alert {
  background: rgba(34, 197, 94, 0.1);
  border-color: rgba(34, 197, 94, 0.3);
  color: #15803d;
}


.cashback-info .alert strong {
  font-size: 1.1rem;
  font-weight: 700;
}

@keyframes slideDown {
  from {
    opacity: 0;
    transform: translateY(-10px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* User Tickets Notice Styles */
.user-tickets-notice {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 8px 12px;
  margin-left: auto;
  margin-right: auto;
  border-radius: 8px;
  font-size: 13px;
  font-weight: 500;
  text-align: center;
  animation: slideDown 0.5s ease-out;
  width: fit-content;
  max-width: 100%;
  grid-column: 1 / -1;
  margin-bottom: 1rem;
}

.user-tickets-notice .fas.fa-ticket-alt {
  color: #f59e0b;
  font-size: 14px;
}

.user-tickets-notice .tickets-count {
  font-weight: 700;
  color: #374151;
}

.user-tickets-notice .tickets-text {
  color: #6b7280;
}

/* Dark Theme */
.dark-theme .user-tickets-notice {
  background: linear-gradient(135deg, rgba(75, 85, 99, 0.15), rgba(55, 65, 81, 0.15));
  border: 1px solid rgba(75, 85, 99, 0.25);
  color: #f3f4f6;
}

.dark-theme .user-tickets-notice .tickets-count {
  color: #f3f4f6;
}

.dark-theme .user-tickets-notice .tickets-text {
  color: #d1d5db;
}

/* Light Theme */
.light-theme .user-tickets-notice {
  background: linear-gradient(135deg, rgba(243, 244, 246, 0.8), rgba(229, 231, 235, 0.8));
  border: 1px solid rgba(209, 213, 219, 0.8);
  color: #374151;
}

.light-theme .user-tickets-notice .tickets-count {
  color: #374151;
}

.light-theme .user-tickets-notice .tickets-text {
  color: #6b7280;
}

/* Responsive adjustments for larger screens */
@media (min-width: 768px) {
  .user-tickets-notice {
    padding: 6px 10px;
    font-size: 12px;
    border-radius: 6px;
  }

  .user-tickets-notice .fas.fa-ticket-alt {
    font-size: 13px;
  }
}

/* Description content styling for HTML content */
.description-content {
  line-height: 1.6;
  color: var(--text-color);
}

.description-content h1,
.description-content h2,
.description-content h3,
.description-content h4,
.description-content h5,
.description-content h6 {
  margin-top: 1.5rem;
  margin-bottom: 1rem;
  color: var(--text-color);
  font-weight: 600;
}

.description-content h1 {
  font-size: 1.8rem;
}

.description-content h2 {
  font-size: 1.6rem;
}

.description-content h3 {
  font-size: 1.4rem;
}

.description-content h4 {
  font-size: 1.2rem;
}

.description-content h5 {
  font-size: 1.1rem;
}

.description-content h6 {
  font-size: 1rem;
}

.description-content p {
  margin-bottom: 1rem;
  line-height: 1.6;
}

.description-content ul,
.description-content ol {
  margin-bottom: 1rem;
  padding-left: 2rem;
}

.description-content li {
  margin-bottom: 0.5rem;
}

.description-content blockquote {
  border-left: 4px solid var(--primary);
  padding-left: 1rem;
  margin: 1.5rem 0;
  font-style: italic;
  color: var(--text-muted);
}

.description-content code {
  background: rgba(78, 84, 200, 0.1);
  padding: 0.2rem 0.4rem;
  border-radius: 3px;
  font-family: 'Courier New', monospace;
  font-size: 0.9em;
}

.description-content pre {
  background: rgba(0, 0, 0, 0.1);
  padding: 1rem;
  border-radius: 5px;
  overflow-x: auto;
  margin: 1rem 0;
}

.description-content pre code {
  background: none;
  padding: 0;
}

.description-content a {
  color: var(--primary);
  text-decoration: none;
}

.description-content a:hover {
  text-decoration: underline;
}

.description-content img {
  max-width: 100%;
  height: auto;
  border-radius: 5px;
  margin: 1rem 0;
}

.description-content table {
  width: 100%;
  border-collapse: collapse;
  margin: 1rem 0;
}

.description-content th,
.description-content td {
  padding: 0.75rem;
  border: 1px solid rgba(255, 255, 255, 0.1);
  text-align: left;
}

.description-content th {
  background: rgba(78, 84, 200, 0.1);
  font-weight: 600;
}

/* Light theme adjustments for description content */
:root.light-theme .description-content {
  color: var(--text-color);
}

:root.light-theme .description-content h1,
:root.light-theme .description-content h2,
:root.light-theme .description-content h3,
:root.light-theme .description-content h4,
:root.light-theme .description-content h5,
:root.light-theme .description-content h6 {
  color: var(--text-color);
}

:root.light-theme .description-content blockquote {
  border-left-color: var(--primary);
  color: var(--text-muted);
}

:root.light-theme .description-content code {
  background: rgba(78, 84, 200, 0.1);
}

:root.light-theme .description-content pre {
  background: rgba(0, 0, 0, 0.05);
}

:root.light-theme .description-content th,
:root.light-theme .description-content td {
  border-color: rgba(0, 0, 0, 0.1);
}

:root.light-theme .description-content th {
  background: rgba(78, 84, 200, 0.1);
}

/* Main competition container */
.competition-detail {
  background: var(--dark-bg);
  color: var(--text-color);
}

.competition-detail-container {
  max-width: 1400px;
  margin: 0 auto;
}

/* Prevent iOS zoom on button clicks */
.competition-detail-container button {
  -webkit-tap-highlight-color: rgba(0, 0, 0, 0);
  -webkit-touch-callout: none;
  touch-action: manipulation;
}

/* Prevent iOS zoom on input focus */
.competition-detail-container input[type="number"] {
  font-size: 16px !important;
  /* Minimum 16px to prevent zoom */
  -webkit-text-size-adjust: 100% !important;
}

.bg-gradient-primary {
  background: linear-gradient(90deg, #ff6b35, #ff8c5a) !important;
}

/* Ticket limit info styling */
.ticket-limit-info {
  color: var(--text-color);
}

.ticket-limit-info small {
  color: var(--text-color);
}

/* Dark theme - make ticket limit info white */
.dark-theme .ticket-limit-info,
.dark-theme .ticket-limit-info small {
  color: white !important;
}

/* Light theme - keep it readable */
.light-theme .ticket-limit-info,
.light-theme .ticket-limit-info small {
  color: #333 !important;
}

/* Skeleton loader alignment fix */
.competition-skeleton {
  animation: fade-in 0.5s ease-out;
}

@keyframes fade-in {
  from {
    opacity: 0;
  }

  to {
    opacity: 1;
  }
}

/* Ensure skeleton product-title-row matches actual content spacing */
#competition-skeleton .product-title-row {
  margin-bottom: 0.5rem !important;
  display: flex !important;
  justify-content: space-between !important;
  align-items: baseline !important;
}

/* Ensure skeleton product-title-row first element (title) uses flex like actual h1 */
#competition-skeleton .product-title-row>div:first-child {
  width: auto !important;
  flex: 1 !important;
  /* Match actual h1 which has flex: 1 */
  min-width: 0 !important;
  /* Allow shrinking if needed */
  max-width: calc(100% - 120px) !important;
  /* Leave space for price */
}

/* Ensure skeleton product-title-row second element (price) has proper spacing like actual price */
#competition-skeleton .product-title-row>div:nth-child(2) {
  margin-left: 1rem !important;
  /* Match actual .product-price margin-left */
  flex-shrink: 0 !important;
  /* Prevent shrinking like actual price span */
  width: auto !important;
  /* Let it size naturally */
  min-width: 100px !important;
  /* Maintain minimum width */
}

/* Ensure skeleton product-metadata matches actual content spacing */
#competition-skeleton .product-metadata {
  margin-bottom: 0 !important;
  /* Remove the extra margin-bottom from inline style */
}

/* Ensure skeleton tag-group matches actual content spacing (gap: 0.5rem, not 1rem) */
#competition-skeleton .product-metadata>div {
  gap: 0.5rem !important;
  /* Override inline gap: 1rem */
  margin-bottom: 0 !important;
  /* Remove the extra margin-bottom from inline style */
}

/* Ensure skeleton competition-details-card matches actual content spacing */
#competition-skeleton .competition-details-card {
  padding: 1.25rem;
}

/* Ensure skeleton tabs section matches actual content spacing */
#competition-skeleton .competition-tabs {
  margin-top: 1.5rem;
  /* matches mt-4 */
  clear: both;
  border-top: 1px solid var(--border-color, #e0e0e0);
}

/* Ensure skeleton gallery image container matches actual content */
#competition-skeleton .gallery-column>div:first-child {
  margin-bottom: 1rem !important;
}

/* Ensure skeleton gallery thumbnails container matches actual content spacing */
#competition-skeleton .gallery-column>div:nth-child(2) {
  margin-top: 0 !important;
  /* Remove margin-top since main image has margin-bottom */
}

/* Enhanced two-column layout for desktop */
.competition-detail-layout {
  display: grid;
  grid-template-columns: minmax(300px, 1fr) minmax(300px, 1fr);
  gap: 0.5rem;
  margin-bottom: 1rem;
}

.gallery-column {
  min-width: 300px;
}

.details-column {
  min-width: 300px;
}

/* Enhanced Gallery Styles */
.competition-gallery {
  border-radius: var(--card-radius);
  overflow: hidden;
  box-shadow: var(--shadow-premium);
  margin-bottom: 1.5rem;
  position: relative;
  display: flex;
  flex-direction: column;
  background: var(--card-bg);
  border: 1px solid var(--border-glass);
}

.main-image-container {
  position: relative;
  overflow: hidden;
  border-radius: 10px;
  height: auto;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
  margin-bottom: 1rem;
}

.main-gallery-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.4s ease-in-out;
}

.main-image-container:hover .main-gallery-image {
  transform: scale(1.02);
}

/* Gallery navigation */
.gallery-nav {
  position: absolute;
  top: 50%;
  width: 100%;
  display: flex;
  justify-content: space-between;
  transform: translateY(-50%);
  z-index: 2;
}

.gallery-nav button {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(20, 20, 40, 0.8);
  border: 1px solid var(--glass-border);
  color: white;
  opacity: 0.7;
  transition: all 0.3s ease;
  box-shadow: 0 0 15px rgba(0, 0, 0, 0.3);
  cursor: pointer;
}

.gallery-nav button:hover {
  opacity: 1;
  background: var(--primary);
}

/* Thumbnails */
.thumbnail-gallery {
  display: flex;
  gap: 10px;
  margin-top: 15px;
  flex-wrap: wrap;
  justify-content: center;
  overflow-x: auto;
  padding-bottom: 10px;
}

.gallery-thumbnail {
  width: 60px;
  height: 45px;
  border-radius: var(--border-radius);
  overflow: hidden;
  cursor: pointer;
  opacity: 0.7;
  transition: all 0.3s ease;
  border: 2px solid transparent;
}

.gallery-thumbnail img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.gallery-thumbnail:hover {
  opacity: 0.9;
  border-color: var(--primary);
}

.gallery-thumbnail.active-thumbnail {
  opacity: 1;
  border-color: var(--primary);
  transform: scale(1.05);
  box-shadow: 0 0 10px var(--glow-color);
}

/* BRAND NEW MINIMAL PRODUCT HEADER */
.compact-product-info {
  margin-bottom: 1rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  padding-bottom: 0.5rem;
}

.product-title-row {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  margin-bottom: 0.5rem;
}

.product-title-row h1 {
  font-size: 1.4rem;
  font-weight: 800;
  margin: 0;
  padding: 0;
  color: var(--text-color);
  flex: 1;
  word-wrap: break-word;
  hyphens: auto;
}

.product-price {
  font-size: 1.6rem;
  font-weight: 800;
  color: var(--primary);
  white-space: nowrap;
  margin-left: 1rem;
  text-shadow: 0 0 8px rgba(var(--primary-rgb), 0.3);
  letter-spacing: 0.5px;
  position: relative;
  display: flex;
  align-items: center;
  gap: 0.3rem;
}

.product-price small {
  font-size: 0.9rem;
  font-weight: 500;
  opacity: 0.9;
  color: var(--text-muted);
  margin-left: 0.3rem;
}

.product-metadata {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.tag-group {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
}

.product-tag {
  background: rgba(78, 84, 200, 0.15);
  color: var(--primary);
  font-size: 0.85rem;
  padding: 0.1rem 0.5rem;
  border-radius: 2px;
  font-weight: 500;
  display: inline-block;
}

:root.dark-theme .product-tag {
  background-color: var(--primary);
  color: white;
}

.cash-tag {
  background: #28a745;
  color: #ffffff;
  font-size: 0.85rem;
  padding: 0.1rem 0.5rem;
  border-radius: 2px;
  font-weight: 500;
  border: none;
  display: inline-block;
}

:root.dark-theme .cash-tag {
  background: #28a745;
  color: #ffffff;
  border: none;
}

.cash-tag::before {
  content: "";
  margin-right: 0;
}

/* Light theme overrides */
:root.light-theme .compact-product-info {
  border-bottom-color: rgba(0, 0, 0, 0.1);
}

:root.light-theme .product-title-row h1 {
  color: #000;
}

:root.light-theme .product-price {
  color: var(--primary);
  text-shadow: 0 0 6px rgba(var(--primary-rgb), 0.2);
}

:root.light-theme .product-price small {
  color: #666;
  opacity: 0.9;
}

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

  .cashback-info .alert {
    font-size: 0.7rem;
  }

  .cashback-info .alert strong {
    font-size: 0.8rem;
  }


  .product-title-row {
    flex-direction: column;
    align-items: flex-start;
  }

  .product-title-row h1 {
    margin-bottom: 0.3rem;
    font-size: 1.3rem;
    white-space: normal;
    word-wrap: break-word;
    overflow-wrap: break-word;
  }

  .product-price {
    margin-left: 0;
    font-size: 1.5rem;
    margin-top: 0.5rem;
  }

  .product-price small {
    font-size: 0.9rem;
  }
}

/* Tabbed Content Styles */
.competition-tabs {

  clear: both;
  border-top: 1px solid var(--border-color, #e0e0e0);

}

.nav-tabs {
  border-bottom: 1px solid var(--border-color, #e0e0e0);
  margin-bottom: 1rem;
  display: flex;
  flex-wrap: nowrap;
  width: 100%;
}

/* Custom scrollbar for tab navigation */
.nav-tabs::-webkit-scrollbar {
  height: 4px;
}

.nav-tabs::-webkit-scrollbar-track {
  background: rgba(255, 255, 255, 0.05);
  border-radius: 10px;
}

.nav-tabs::-webkit-scrollbar-thumb {
  background: rgba(255, 255, 255, 0.2);
  border-radius: 10px;
}

.nav-tabs .nav-item {
  white-space: nowrap;
  margin-bottom: 0;
}

.nav-tabs .nav-link {
  color: var(--text-muted);
  border: none;
  border-bottom: 3px solid transparent;
  border-radius: 0;
  padding: 0.75rem 1.5rem;
  font-weight: 600;
  transition: all 0.3s ease;
  background: transparent;
}

.nav-tabs .nav-link:hover {
  color: var(--text-color);
  border-bottom: 3px solid transparent;
}

.nav-tabs .nav-link.active {
  color: var(--primary);
  background: transparent;
  border-bottom: 3px solid var(--primary);
}

.tab-content {
  padding: 0;
  background: rgba(255, 255, 255, 0.05);
  border-radius: 0 0 10px 10px;
  min-height: 200px;
}

.tab-pane {
  animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(10px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Competition Details Card */
.competition-details-card {
  border-radius: var(--card-radius);
  overflow: hidden;
  padding: 2rem;
  background: var(--glass-bg);
  backdrop-filter: blur(20px);
  border: 1px solid var(--border-glass);
  box-shadow: var(--shadow-premium);
  transition: var(--transition-premium);
  display: flex;
  flex-direction: column;
}

.compact-competition-details {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  flex-grow: 1;
  min-height: 300px;
}

/* Square Countdown Timer */
.countdown-container {
  background: rgba(255, 255, 255, 0.03);
  border-radius: var(--inner-radius);
  padding: 1.5rem;
  width: 100%;
}

.countdown-title {
  text-align: center;
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--text-color);
  margin-bottom: 1.5rem;
  letter-spacing: 0.5px;
}

.countdown-timer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  width: 100%;
  gap: 1rem;
  border: none;
}

.time-unit {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  position: relative;
  transition: all 0.3s ease;
}

.time-unit:hover {
  transform: none;
  box-shadow: none;
}

.time-unit::after {
  content: none;
}

.time-unit:last-child::after {
  display: none;
}

/* Use global .countdown-timer .time-value from style.css */

.time-label {
  font-size: 0.6rem;
  text-transform: uppercase;
  font-weight: 600;
  opacity: 0.8;
}

:root.light-theme .time-label {
  color: black !important;
}




/* Progress Bar */
.progress-container {
  margin-bottom: 0.5rem;
}

.progress {
  height: 8px;
  background-color: rgba(255, 255, 255, 0.1);
  border-radius: 4px;
  overflow: hidden;
}

.progress-bar {
  background: linear-gradient(90deg, var(--primary), var(--gradient-mid));
  border-radius: 4px;
  position: relative;
  overflow: hidden;
}

.progress-bar::after {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.4), transparent);
  animation: progress-shine 2s infinite;
}

@keyframes progress-shine {
  100% {
    left: 100%;
  }
}

.tickets-info {
  display: flex;
  justify-content: space-between;
  margin-top: 5px;
  font-size: 0.85rem;
  color: var(--text-muted);
}

/* Compact Entry List */
.entry-list-container {
  max-height: 300px;
  overflow-y: auto;
  scrollbar-width: thin;
  scrollbar-color: var(--primary) rgba(255, 255, 255, 0.1);
}

.entry-list-container::-webkit-scrollbar {
  width: 8px;
}

.entry-list-container::-webkit-scrollbar-track {
  background: rgba(255, 255, 255, 0.1);
  border-radius: 4px;
}

.entry-list-container::-webkit-scrollbar-thumb {
  background-color: var(--primary);
  border-radius: 4px;
}

.entry-list-table {
  margin-bottom: 0;
}

.entry-list-table th,
.entry-list-table td {
  padding: 0.5rem 0.75rem;
  font-size: 0.9rem;
}

/* Table header styling with primary color background */
.entry-list-table thead th {
  background-color: var(--primary);
  color: white;
  border-color: rgba(255, 255, 255, 0.2);
}

/* Light theme overrides for the entry list table */
:root.light-theme .entry-list-table.table-dark {
  color: #212529;
  background-color: #f8f9fa;
  border-color: #dee2e6;
}

:root.light-theme .entry-list-table.table-dark td {
  border-color: #dee2e6;
  color: #212529;
}

/* Keep the header styling consistent across themes */
:root.light-theme .entry-list-table.table-dark th {
  background-color: var(--primary);
  color: white;
  border-color: rgba(255, 255, 255, 0.2);
}

:root.light-theme .entry-list-table.table-dark tbody tr:hover {
  background-color: rgba(0, 0, 0, 0.075);
  color: #212529;
}

:root.light-theme .entry-list-table.table-dark td.text-center em {
  color: #6c757d;
}

/* New Expandable Instant Prizes - Theme Aware */
.instant-prizes-expandable {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.product__prize {
  background: var(--card-bg);
  border: 1px solid var(--glass-border);
  border-radius: 10px;
  overflow: hidden;
  transition: all 0.3s ease;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.product__prize:hover {
  background: var(--glass-bg-hover);
  transform: translateY(-2px);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
}

.prize-card__head {
  display: flex;
  align-items: center;
  padding: 1rem;
  gap: 1rem;
  background: var(--glass-bg);
  cursor: pointer;
  transition: background-color 0.3s ease;
}

.prize-card__head:hover {
  background: var(--glass-bg-hover);
}

.prize-card__img {
  width: 60px;
  height: 60px;
  flex-shrink: 0;
  border-radius: 8px;
  overflow: hidden;
  background: var(--glass-bg);
  border: 1px solid var(--glass-border);
}

.prize-card__img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.prize-card__name {
  flex: 1;
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--text-color);
  margin: 0;
}

.prize-card__badge {
  background: linear-gradient(90deg, var(--gradient-start), var(--gradient-mid));
  color: white;
  padding: 0.5rem 1rem;
  border-radius: 20px;
  font-size: 0.9rem;
  font-weight: 500;
  white-space: nowrap;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
}

.prize-card__badge span {
  font-weight: 700;
  font-size: 1rem;
}

.prize-card__toggle {
  background: var(--glass-bg);
  border: 1px solid var(--glass-border);
  color: var(--text-color);
  width: max-content;
  height: max-content;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.3s ease;
  flex-shrink: 0;
}

.prize-card__toggle:hover {
  background: var(--glass-bg-hover);
  transform: scale(1.1);
  border-color: var(--primary);
}

.prize-card__toggle--open {
  background: var(--primary);
  border-color: var(--primary);
  color: white;
}

.svg-icon {
  width: 20px;
  height: 20px;
  transition: transform 0.3s ease;
  fill: currentColor;
}

.prize-card__content {
  display: none;
  /* jQuery slideToggle will toggle this */
  transition: opacity 0.3s ease;
  background: var(--glass-bg);
  border-top: 1px solid var(--glass-border);
}

.prize-card__content--opened {
  /* Legacy support if needed */
  display: block;
}

.prize-card__tab-content {
  padding: 1rem;
}

.prize-card__tickets-box {
  padding: 0.5rem 0;
  max-height: 400px;
  overflow-y: auto;
  overflow-x: hidden;
}

.prize-card__tickets-box::-webkit-scrollbar {
  width: 6px;
}

.prize-card__tickets-box::-webkit-scrollbar-track {
  background: var(--glass-bg);
  border-radius: 10px;
}

.prize-card__tickets-box::-webkit-scrollbar-thumb {
  background: var(--primary);
  border-radius: 10px;
}

.prize-card__tickets-box::-webkit-scrollbar-thumb:hover {
  background: rgba(var(--primary-rgb), 0.8);
}

.prize-card__tickets-content {
  display: grid;
  grid-template-columns: repeat(10, 1fr);

  width: 100%;
  max-width: 100%;
  box-sizing: border-box;
}



.prize-ticket-card {
  width: 80px;
  height: 80px;
  background: var(--glass-bg);
  border: 2px solid var(--glass-border);
  border-radius: 8px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  transition: all 0.3s ease;
  position: relative;
  cursor: pointer;
  overflow: visible;
  margin: 10px 0;
}

.prize-ticket-card.available {
  background: rgba(40, 167, 69, 0.1);
  border-color: rgba(40, 167, 69, 0.5);
}

.prize-ticket-card.taken {
  background: rgba(220, 53, 69, 0.1);
  border-color: rgba(220, 53, 69, 0.5);
}

.prize-ticket-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

.prize-ticket-card-content {
  font-size: 1.2rem;
  font-weight: 700;
  color: var(--text-color);
  margin-bottom: 0.25rem;
}

.prize-ticket-card-footer {
  font-size: 0.7rem;
  font-weight: 600;
  text-transform: uppercase;
  color: white;
  background: rgba(0, 0, 0, 0.6);
  padding: 0.25rem 0.5rem;
  border-radius: 4px;
  white-space: nowrap;
}

/* Skeleton loading styles for ticket cards */
.prize-ticket-card-skeleton {
  background: var(--glass-bg) !important;
  border-color: var(--glass-border) !important;
  cursor: default !important;
  animation: skeleton-pulse 1.5s ease-in-out infinite;
}

.prize-ticket-card-skeleton:hover {
  transform: none !important;
  box-shadow: none !important;
}

.prize-ticket-card-content-skeleton {
  width: 40px;
  height: 20px;
  background: var(--glass-border);
  border-radius: 4px;
  margin-bottom: 0.5rem;
  animation: skeleton-shimmer 1.5s ease-in-out infinite;
}

.prize-ticket-card-footer-skeleton {
  width: 50px;
  height: 16px;
  background: var(--glass-border);
  border-radius: 4px;
  animation: skeleton-shimmer 1.5s ease-in-out infinite;
  animation-delay: 0.2s;
}

@keyframes skeleton-pulse {

  0%,
  100% {
    opacity: 1;
  }

  50% {
    opacity: 0.6;
  }
}

@keyframes skeleton-shimmer {

  0%,
  100% {
    opacity: 0.4;
    transform: scale(1);
  }

  50% {
    opacity: 0.8;
    transform: scale(1.02);
  }
}

/* Dark theme adjustments for skeletons */
.dark-theme .prize-ticket-card-skeleton {
  background: rgba(255, 255, 255, 0.05) !important;
  border-color: rgba(255, 255, 255, 0.1) !important;
}

.dark-theme .prize-ticket-card-content-skeleton,
.dark-theme .prize-ticket-card-footer-skeleton {
  background: rgba(255, 255, 255, 0.15);
}

/* Light theme adjustments for skeletons */
.light-theme .prize-ticket-card-skeleton {
  background: rgba(0, 0, 0, 0.03) !important;
  border-color: rgba(0, 0, 0, 0.1) !important;
}

.light-theme .prize-ticket-card-content-skeleton,
.light-theme .prize-ticket-card-footer-skeleton {
  background: rgba(0, 0, 0, 0.1);
}

.prize-ticket-card.available .prize-ticket-card-footer {
  background: rgba(40, 167, 69, 0.9);
}

.prize-ticket-card.taken .prize-ticket-card-footer {
  background: rgba(220, 53, 69, 0.9);
}

.winner-tooltip {
  position: absolute;
  bottom: 80% !important;
  left: 50%;
  transform: translateX(-50%);
  background-color: var(--card-bg);
  color: var(--text-color);
  padding: 8px 12px;
  border-radius: 6px;
  white-space: nowrap;
  font-size: 12px;
  z-index: 9999;
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.2s;
  font-weight: normal;
  border: 1px solid var(--glass-border);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
  min-width: 140px;
  text-align: center;
  line-height: 1.2;
  max-width: 200px;
}

.winner-tooltip:after {
  content: "";
  position: absolute;
  top: 100%;
  left: 50%;
  margin-left: -6px;
  border-width: 6px;
  border-style: solid;
  border-color: var(--card-bg) transparent transparent transparent;
}

.prize-ticket-card.show-tooltip .winner-tooltip {
  opacity: 1;
  animation: tooltipBounce 0.3s ease-out;
}

@keyframes tooltipBounce {
  0% {
    opacity: 0;
    transform: translateX(-50%) translateY(10px);
  }

  100% {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
  }
}

/* Responsive design for mobile */
@media (max-width: 768px) {
  .prize-card__head {
    flex-wrap: nowrap !important;
    gap: 0.5rem;
    padding: 0.75rem;
  }

  .prize-card__img {
    width: 50px;
    height: 50px;
  }

  .prize-card__name {
    font-size: 1rem;
    min-width: 120px;
  }



  .prize-card__badge span {
    font-size: 0.9rem;
  }


}

/* Tablet responsive design */
@media (max-width: 1024px) {
  .prize-card__tickets-content {
    grid-template-columns: repeat(7, 1fr);
    gap: 0.45rem;
  }
}

@media (max-width: 768px) {
  .prize-card__head {
    flex-wrap: nowrap !important;
    gap: 0.5rem;
    padding: 0.75rem;
  }

  .prize-card__img {
    width: 50px;
    height: 50px;
  }

  .prize-card__name {
    font-size: 1rem;
    min-width: 120px;
  }


  .prize-card__badge span {
    font-size: 0.9rem;
  }

  .prize-card__badge {
    padding: 5px;
  }

  .prize-card__tickets-content {
    grid-template-columns: repeat(5, 1fr);
    gap: 0.4rem;
    max-width: 100%;
  }

  .svg-icon {
    width: 16px;
    height: 16px;
  }

  /* Default state: arrow points down (collapsed) */
  .prize-card__badge .svg-icon {
    transform: rotate(90deg);
  }

  /* Expanded state: arrow points right */
  .prize-card__badge.prize-card__toggle--open .svg-icon {
    transform: rotate(0deg);
  }

  .prize-ticket-card {
    width: 70px;
    height: 70px;
    margin: 8px 0;
  }

  .prize-ticket-card-content {
    font-size: 1rem;
  }

  .prize-ticket-card-footer {
    font-size: 0.6rem;
    padding: 0.2rem 0.4rem;
  }

  .winner-tooltip {
    bottom: calc(100% + 12px);
    min-width: 120px;
    max-width: 180px;
    font-size: 11px;
    padding: 6px 10px;
  }
}

@media (max-width: 480px) {
  .prize-card__head {
    padding: 0.5rem;
  }

  .prize-card__name {
    font-size: 0.9rem;
    min-width: 100px;
  }



  .prize-card__tickets-content {
    grid-template-columns: repeat(4, 1fr);
    gap: 0.3rem;
  }

  .prize-ticket-card {
    width: 60px;
    height: 60px;
  }

  .prize-ticket-card-content {
    font-size: 0.9rem;
  }
}

@media (max-width: 360px) {
  .prize-card__tickets-content {
    grid-template-columns: repeat(3, 1fr);
    gap: 0.25rem;
  }
}

/* Prize Card Styles */
.prize-card__badge .svg-icon {
  width: 14px;
  height: 14px;
  transition: transform 0.3s ease;
  flex-shrink: 0;
}


/* Enhanced Skill Question */
.skill-question {
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid var(--border-glass);
  border-radius: var(--inner-radius);
  padding: 1.5rem;
  margin-bottom: 1rem;
}

.skill-question-title {
  font-weight: 700;
  margin-bottom: 0.5rem;
  color: var(--text-color);
}

.skill-answers {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
  margin-top: 0.6rem;
}

.skill-answer {
  display: flex;
  align-items: center;
  padding: 1rem 1.5rem;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--border-glass);
  border-radius: 12px;
  cursor: pointer;
  transition: var(--transition-premium);
  color: #fff;
  flex: 1 1 auto;
  min-width: 120px;
  justify-content: center;
  text-align: center;
  font-weight: 500;
}

.skill-answer:hover {
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.2);
  transform: translateY(-2px);
}

.skill-answer.selected {
  background: var(--brand-primary);
  border-color: var(--brand-primary);
  color: #000;
  font-weight: 700;
  box-shadow: 0 0 20px rgba(var(--brand-primary-rgb), 0.3);
}

/* Enhanced Ticket Selector */
.ticket-selector-container {
  margin-bottom: 0.5rem;
  margin-top: 0.75rem;
}

.predefined-ticket-selector {
  background: #0e0e0e;
  border: 1px solid var(--glass-border);
  border-radius: 10px;
  padding: 1.2rem;
}

.ticket-preset-btn {
  width: 48px;
  height: 48px;
  background-color: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--border-glass);
  border-radius: 14px;
  color: white;
  font-size: 1rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: var(--transition-premium);
  padding: 0;
}

.ticket-preset-btn:hover {
  background-color: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.2);
  transform: scale(1.05);
}

.ticket-preset-btn.active {
  background-color: var(--primary);
  color: white;
  border-color: var(--primary);
  box-shadow: 0 0 15px rgba(78, 84, 200, 0.2);
}

.ticket-preset-btn:disabled {
  background-color: rgba(30, 30, 40, 0.5);
  border-color: rgba(100, 100, 140, 0.3);
  color: rgba(255, 255, 255, 0.4);
  cursor: not-allowed;
  opacity: 0.6;
}

/* Ticket slider styles */
.ticket-slider-container {
  padding: 0;
  margin-top: 55px;
  margin-bottom: 20px;
  position: relative;
  background: var(--glass-bg);
  border-radius: 4px;
  height: 8px;
  overflow: visible;
}

.ticket-slider {
  top: -7px;
}

/* Slider background effect */
.slider-background {
  position: absolute;
  height: 8px;
  background-color: var(--primary);
  top: 0;
  left: 0;
  border-radius: 4px;
  pointer-events: none;
  z-index: 1;
}

/* Override any Bootstrap styles that might interfere */
input[type="range"].ticket-slider {
  -webkit-appearance: none;
  appearance: none;
  background: transparent !important;
  width: 100%;
  margin: 0;
  padding: 0;
  height: 8px;
  border: none;
  outline: none;
  cursor: pointer;
  position: relative;
  z-index: 2;
}

.ticket-slider::-webkit-slider-runnable-track {
  background: transparent !important;
  border: none;
  height: 8px;
  border-radius: 4px;
}

.ticket-slider::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  background: var(--primary);
  box-shadow: 0 0 15px var(--glow-color);
  border: 2px solid white;
  height: 20px;
  width: 20px;
  border-radius: 50%;
  cursor: pointer;
  position: relative;
  z-index: 3;
  margin-top: -6px;
}

/* Ticket badge */
.ticket-badge {
  background: var(--card-bg);
  border: 1px solid var(--glass-border);
  border-radius: 50px;
  padding: 5px 12px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-weight: 700;
  font-size: 1rem;
  color: white;
  position: absolute;
  top: -45px;
  left: 5%;
  transform: translateX(-50%);
  z-index: 5;
  box-shadow: 0 0 10px rgba(78, 84, 200, 0.3);
  transition: left 0.1s ease;
  min-width: 60px;
  pointer-events: none;
  /* Prevent badge from interfering with slider events */
}

.ticket-badge::after {
  content: '';
  position: absolute;
  top: 100%;
  left: 50%;
  margin-left: -6px;
  border-width: 6px;
  border-style: solid;
  border-color: var(--card-bg) transparent transparent transparent;
}

.ticket-badge i {
  color: var(--primary);
}

/* Prize popup styles removed - now using expandable interface */

/* Social share section */
.social-share {
  margin-top: 1.5rem;
  background: var(--glass-bg);
  border: 1px solid var(--glass-border);
  border-radius: 10px;
  padding: 1rem;
}

.social-links {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
}

/* Social sharing buttons with brand colors */
.social-links .btn-facebook {
  background-color: #3b5998 !important;
  color: white !important;
  border-color: #3b5998 !important;
  padding: 0.5rem 0.75rem;
  border-radius: 6px;
  font-weight: 500;
  transition: all 0.3s ease;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  min-width: 40px;
}

.social-links .btn-facebook:hover {
  background-color: #2d4373 !important;
  color: white !important;
  border-color: #2d4373 !important;
  transform: translateY(-2px);
  box-shadow: 0 4px 8px rgba(59, 89, 152, 0.3);
}

/* X (formerly Twitter) brand color button */
.social-links .btn-x {
  background-color: #000000 !important;
  color: white !important;
  border-color: #000000 !important;
  padding: 0.5rem 0.75rem;
  border-radius: 6px;
  font-weight: 500;
  transition: all 0.3s ease;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  min-width: 40px;
}

.social-links .btn-x:hover {
  background-color: #000000 !important;
  color: white !important;
  border-color: #000000 !important;
  transform: translateY(-2px) scale(1.05);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.4);
}

/* WhatsApp brand color button */
.social-links .btn-whatsapp {
  background-color: #25d366 !important;
  color: white !important;
  border-color: #25d366 !important;
  padding: 0.5rem 0.75rem;
  border-radius: 6px;
  font-weight: 500;
  transition: all 0.3s ease;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  min-width: 40px;
}

.social-links .btn-whatsapp:hover {
  background-color: #1da851 !important;
  color: white !important;
  border-color: #1da851 !important;
  transform: translateY(-2px);
  box-shadow: 0 4px 8px rgba(37, 211, 102, 0.3);
}

/* Ensure icons are visible */
.social-links .btn-facebook i,
.social-links .btn-x svg,
.social-links .btn-whatsapp i {
  color: white !important;
  display: inline-block;
  vertical-align: middle;
}

/* Media Queries */
@media (max-width: 1200px) {
  .competition-detail-layout {
    grid-template-columns: 1fr 1fr;
  }

  .main-image-container {
    height: auto;
  }
}

@media (max-width: 992px) {
  .competition-detail-layout {
    grid-template-columns: 1fr;
  }

  .gallery-column,
  .details-column {
    width: 100%;
  }

  .main-image-container {
    height: auto;
  }

  /* Make tabs more mobile-friendly */
  .nav-tabs .nav-link {
    padding: 0.75rem 1rem;
  }
}

@media (max-width: 768px) {
  .competition-title {
    font-size: 1.4rem;
    margin-bottom: 0.5rem;
  }

  .competition-meta {
    flex-direction: column;
    align-items: flex-start;
    margin-bottom: 0.75rem;
    width: 100%;
  }

  .category-badge,
  .cash-alternative {
    margin-bottom: 0.25rem;
  }

  .competition-header .d-flex {
    flex-direction: column;
  }

  .price-info-container {
    align-self: flex-start;
    margin-top: 0.5rem;
  }

  .main-image-container {
    height: auto;
  }

  .time-value {
    font-size: 1.5rem;
  }

  /* Stack the nav tabs for better mobile experience */
  .nav-tabs {
    flex-direction: row;
    overflow-x: auto;
    white-space: nowrap;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
  }

  .nav-tabs::-webkit-scrollbar {
    display: none;
  }

  .nav-tabs .nav-item {
    margin-bottom: 0;
  }

  .countdown-container {
    padding: 0.8rem;
  }

  .countdown-timer {
    gap: 10px;
  }

  .time-value {
    font-size: 1.4rem;
    min-width: 2rem;
  }

  .time-unit::after {
    right: -8px;
    font-size: 1.4rem;
  }

  .time-label {
    font-size: 0.6rem;
  }
}

@media (max-width: 768px) {
  .competition-title {
    font-size: 1.2rem;
  }

  .main-image-container {
    height: auto;
  }

  .gallery-thumbnail {
    width: 50px;
    height: 40px;
  }

  .nav-tabs .nav-link {
    padding: 0.5rem 0.75rem;
    font-size: 0.9rem;
  }

  .competition-detail .social-links {
    justify-content: center;
    gap: 5px;
  }

  .social-links .btn {
    padding: 0.25rem 0.5rem;
    font-size: 0.8rem;
  }

  .social-links .btn i {
    font-size: 0.9rem;
  }

  .prize-ticket {
    width: 50px;
    height: 35px;
    font-size: 0.8rem;
  }

  .ticket-preset-btn {
    width: 35px;
    height: 35px;
  }

  /* Make countdown more compact on small screens */
  .countdown-timer {
    gap: 5px;
  }

  .competition-header {
    padding: 0.75rem !important;
  }

  .category-badge {
    font-size: 0.8rem;
    padding: 2px 8px;
  }

  .cash-alternative {
    font-size: 0.8rem;
    padding: 2px 8px;
  }

  .price-info-container {
    padding: 5px 10px;
  }
}

/* Tab content responsiveness */
.tab-text-short {
  display: none;
}

@media (max-width: 768px) {
  .tab-text-full {
    display: none;
  }

  .tab-text-short {
    display: inline;
  }

  .nav-tabs .nav-link {
    padding: 0.5rem 0.5rem;
    font-size: 0.85rem;
  }

  .competition-detail .nav-item {
    flex: 1;
    text-align: center;
  }

  .nav-tabs {
    justify-content: space-between;
  }
}

/* Full Width Tabs */
.nav-tabs {
  display: flex !important;
  flex-wrap: nowrap !important;
  width: 100% !important;
}

.nav-tabs .nav-item {
  flex: 1 !important;
  min-width: 0 !important;
}

.nav-tabs .nav-link {
  width: 100% !important;
  text-align: center !important;
  white-space: nowrap !important;
  overflow: hidden !important;
  text-overflow: ellipsis !important;
}

/* Hide short text on larger screens */
@media (min-width: 768px) {
  .tab-text-short {
    display: none !important;
  }
}

/* Show short text on mobile */
@media (max-width: 767px) {
  .tab-text-full {
    display: none !important;
  }
}

/* Utility classes for spacing and alignment */
.mt-auto {
  margin-top: auto;
}

.h-100 {
  height: 100%;
}

.d-flex {
  display: flex;
}

.flex-column {
  flex-direction: column;
}

.flex-grow-1 {
  flex-grow: 1;
}

/* Light theme compatibility */
:root.light-theme .competition-header {
  background: rgba(245, 245, 250, 0.9) !important;
  border: 1px solid rgba(0, 0, 0, 0.1) !important;
}

:root.light-theme .competition-title {
  color: #000;
}

:root.light-theme .competition-details-card,
:root.light-theme .social-share {
  background: #ffffff !important;
  border: 1px solid rgba(0, 0, 0, 0.05) !important;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.03) !important;
}

:root.light-theme .countdown-container {
  background: #e3e3e3 !important;
  border: 1px solid rgba(0, 0, 0, 0.05) !important;
  box-shadow: inset 0 0 20px rgba(0, 0, 0, 0.01) !important;
}

:root.light-theme .skill-question {
  background: #e3e3e3 !important;
  border: 1px solid rgba(0, 0, 0, 0.05) !important;
  box-shadow: 0 5px 20px rgba(0, 0, 0, 0.03) !important;
}

:root.light-theme .predefined-ticket-selector {
  background: #e3e3e3 !important;
  border: 1px solid rgba(0, 0, 0, 0.05) !important;
}

:root.light-theme .ticket-badge::after {
  border-color: #e3e3e3 transparent transparent transparent !important;
}

:root.light-theme .time-value {
  color: #333 !important;
  text-shadow: none !important;
  font-size: 1.5rem;
}

@media (max-width: 768px) {
  :root.light-theme .time-value {
    font-size: 1.5rem;
  }
}

.time-value {
  font-size: 1.5rem;
}

@media (max-width: 768px) {
  .time-value {
    font-size: 1.5rem;
  }
}

:root.dark-theme .time-value {
  font-size: 1.5rem;
}

@media (max-width: 768px) {
  :root.dark-theme .time-value {
    font-size: 1.5rem;
  }
}

:root.light-theme .time-label {
  color: black !important;
}

:root.light-theme .progress {
  background-color: rgba(255 0 0 / 14%) !important
}

:root.light-theme .skill-answer {
  background: #252525 !important;
  border: 1px solid rgba(0, 0, 0, 0.05) !important;
  color: #ececec !important;
}

:root.light-theme .skill-answer:hover {
  background: var(--primary) !important;
  border-color: rgba(0, 0, 0, 0.1) !important;
}

:root.light-theme .skill-answer.selected {
  background: var(--primary) !important;
  border-color: rgba(0, 0, 0, 0.1) !important;
}

:root.light-theme .ticket-preset-btn {
  background-color: white !important;
  border: 1px solid rgba(0, 0, 0, 0.05) !important;
  color: #333 !important;
}


:root.light-theme .ticket-preset-btn.active {
  background-color: var(--primary) !important;
  color: white !important;
}

:root.light-theme .ticket-slider-container {
  background: white !important;
}

:root.light-theme .ticket-badge {
  background: white !important;
  border: 1px solid rgba(0, 0, 0, 0.05) !important;
  color: #333 !important;
}

/* Light theme overrides for expandable prizes */
:root.light-theme .product__prize {
  background: var(--card-bg);
  border-color: var(--glass-border);
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
}

:root.light-theme .prize-card__head {
  background: var(--glass-bg);
}

:root.light-theme .prize-card__head:hover {
  background: var(--glass-bg-hover);
}

:root.light-theme .prize-card__name {
  color: #333 !important;
}

:root.light-theme .prize-card__toggle {
  background: var(--glass-bg);
  border-color: var(--glass-border);
  color: var(--text-color);
}

:root.light-theme .prize-card__toggle:hover {
  background: var(--primary);
  border-color: var(--primary);
  color: white;
}

:root.light-theme .prize-card__toggle--open {
  background: var(--primary);
  border-color: var(--primary);
  color: white;
}

:root.light-theme .prize-card__content {
  background: var(--glass-bg);
  border-top-color: var(--glass-border);
}

:root.light-theme .prize-ticket-card {
  background: var(--glass-bg);
  border-color: var(--glass-border);
}

:root.light-theme .prize-ticket-card.available {
  background: rgba(40, 167, 69, 0.05);
  border-color: rgba(40, 167, 69, 0.3);
}

:root.light-theme .prize-ticket-card.taken {
  background: rgba(220, 53, 69, 0.05);
  border-color: rgba(220, 53, 69, 0.3);
}

:root.light-theme .prize-ticket-card-content {
  color: #333 !important;
}

:root.light-theme .winner-tooltip {
  background-color: var(--card-bg);
  color: var(--text-color);
  border-color: var(--glass-border);
}

:root.light-theme .tab-content,
.light-theme .tab-content {
  background: #e3e3e3 !important;
  border: 1px solid rgba(0, 0, 0, 0.03) !important;
}

/* Light theme: description and tab content text (text-dim is white in dark, invisible on light) */
:root.light-theme .tab-content .text-dim,
.light-theme .tab-content .text-dim,
:root.light-theme .description-content.text-dim,
.light-theme .description-content.text-dim {
  color: #4b5563 !important;
}

:root.light-theme .tab-content .description-content,
.light-theme .tab-content .description-content {
  color: #374151 !important;
}

:root.light-theme .tab-content .description-content p,
.light-theme .tab-content .description-content p {
  color: inherit !important;
}

/* Final responsive adjustments */

/* Prevent layout shifts on tab change */
.tab-content {
  min-height: 200px;
}

/* Make buttons more touch-friendly on mobile */
/* Skill instruction text styling */
.skill-instruction {
  font-size: 1rem;
  text-transform: uppercase;
  font-weight: 700;
  color: #d12026;
}

@media (max-width: 768px) {
  .buy-btn-container {
    margin-top: 1rem;
  }

  #buy-tickets-btn {
    padding: 1.25rem 1.5rem;
    font-family: var(--font-heading);
    font-size: 1.1rem;
    font-weight: 700;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    border-radius: 100px;
    background: var(--brand-primary);
    border: none;
    color: #000;
    box-shadow: 0 10px 30px rgba(var(--brand-primary-rgb), 0.3);
    transition: var(--transition-premium);
  }

  #buy-tickets-btn:hover:not(:disabled) {
    transform: translateY(-3px);
    box-shadow: 0 15px 40px rgba(var(--brand-primary-rgb), 0.4);
    filter: brightness(1.1);
  }

  #buy-tickets-btn:active:not(:disabled) {
    transform: translateY(-1px);
  }


  .ticket-preset-btn {
    min-width: 38px;
    min-height: 38px;
  }

  /* Adjust spacing in compact areas */
  .competition-details-card {
    padding: 1rem;
  }

  .skill-question,
  .predefined-ticket-selector {
    padding: 0.8rem;
  }

  .skill-answer {
    padding: 0.6rem 1rem;
  }

  /* Style skill instruction text on mobile */
  .skill-instruction {
    font-size: 0.75rem !important;
    color: var(--primary) !important;
    text-transform: uppercase;
    font-weight: 700;
  }
}

/* Enhance fixed height areas for different screen sizes */
@media (min-width: 1200px) {
  .main-image-container {
    height: auto;
  }
}

@media (min-width: 1400px) {
  .main-image-container {
    height: auto;
  }
}

/* Ensure the layout doesn't get too compressed */
.compact-competition-details {
  min-height: 300px;
}

/* Add missing styles for minus/plus buttons in light theme */
:root.light-theme #minus-btn,
:root.light-theme #plus-btn {
  background-color: var(--primary) !important;
  color: white !important;
  border-color: var(--primary) !important;
}

:root.light-theme #minus-btn:hover,
:root.light-theme #plus-btn:hover {
  background-color: var(--primary-dark, #d12026) !important;
  border-color: var(--primary-dark, #d12026) !important;
}

.question-text {
  font-size: 1.8rem;
  font-weight: 800;
  margin-bottom: 1.2rem;
  color: var(--primary);
  text-align: center;
  letter-spacing: 0.5px;
  text-shadow: 0 0 10px rgba(var(--primary-rgb), 0.5);
  padding: 0.5rem 0;
  background: transparent;
  border: none;
  box-shadow: none;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  text-transform: capitalize;
  font-family: Orbitron;
}


/* Light theme override for question text */
:root.light-theme .question-text {
  color: var(--primary) !important;
  text-shadow: 0 0 10px rgba(var(--primary-rgb), 0.3) !important;
}

/* Free Postal Entries Text Theme Colors */
:root.light-theme .free-postal-text {
  color: black;
}

:root.dark-theme .free-postal-text {
  color: white;
}

:root.dark-theme .product-price small {
  color: white;
  opacity: 0.85;
}

#minus-btn,
#plus-btn {
  background-color: var(--primary);
  color: white;
  border-color: var(--primary);
  font-size: 1.2rem;
  width: 48px;
  height: 48px;
  min-width: 48px;
  min-height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  transition: all 0.3s ease;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
  /* Prevent iOS zoom on tap */
  -webkit-tap-highlight-color: rgba(0, 0, 0, 0);
  -webkit-touch-callout: none;
  -webkit-user-select: none;
  -moz-user-select: none;
  -ms-user-select: none;
  user-select: none;
  /* Ensure proper touch target */
  touch-action: manipulation;
}

#minus-btn:hover,
#plus-btn:hover {
  background-color: var(--primary-dark, #d12026);
  border-color: var(--primary-dark, #d12026);
  transform: translateY(-2px);
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.3);
}

#minus-btn:active,
#plus-btn:active {
  transform: translateY(0);
  box-shadow: 0 2px 3px rgba(0, 0, 0, 0.2);
}

#minus-btn i,
#plus-btn i {
  font-size: 1.5rem;
}

/* Quantity Input Styling */
.quantity-input {
  width: 60px !important;
  height: 32px !important;
  text-align: center !important;
  font-weight: bold !important;
  font-size: 16px !important;
  /* Prevent iOS zoom - minimum 16px */
  border-radius: 6px !important;
  border: 1px solid rgba(255, 255, 255, 0.2) !important;
  background: rgba(255, 255, 255, 0.1) !important;
  color: white !important;
  margin: 0 8px !important;
  padding: 0 4px !important;
  -webkit-appearance: none !important;
  -moz-appearance: textfield !important;
  appearance: textfield !important;
  /* Prevent iOS zoom on focus */
  -webkit-text-size-adjust: 100% !important;
  /* Ensure proper touch interaction */
  -webkit-tap-highlight-color: rgba(0, 0, 0, 0);
  touch-action: manipulation;
}

.quantity-input::-webkit-outer-spin-button,
.quantity-input::-webkit-inner-spin-button {
  -webkit-appearance: none !important;
  margin: 0 !important;
}

.quantity-input:focus {
  outline: none !important;
  border-color: var(--primary) !important;
  box-shadow: 0 0 8px rgba(var(--primary-rgb), 0.3) !important;
  background: rgba(255, 255, 255, 0.15) !important;
}

/* Light theme quantity input (id="quantity-input" in HTML) */
:root.light-theme #quantity-input,
.light-theme #quantity-input {
  background: transparent !important;
  color: #1f2937 !important;
}

:root.light-theme #quantity-input:focus,
.light-theme #quantity-input:focus {
  color: #111827 !important;
}

/* Legacy class selector if used elsewhere */
:root.light-theme .quantity-input {
  background: rgba(255, 255, 255, 0.9) !important;
  border: 1px solid rgba(0, 0, 0, 0.2) !important;
  color: #333 !important;
}

:root.light-theme .quantity-input:focus {
  background: white !important;
  border-color: var(--primary) !important;
}

/* Light theme: ticket selector area – "tickets" label and other muted/white text in details card */
:root.light-theme .ticket-input-group .text-muted,
.light-theme .ticket-input-group .text-muted {
  color: #6b7280 !important;
}

:root.light-theme .competition-details-card .text-muted,
.light-theme .competition-details-card .text-muted {
  color: #6b7280 !important;
}

:root.light-theme .competition-details-card .text-white,
.light-theme .competition-details-card .text-white {
  color: #1f2937 !important;
}

:root.light-theme .countdown-section .text-muted,
.light-theme .countdown-section .text-muted {
  color: #4b5563 !important;
}

:root.light-theme .progress-section .text-muted,
.light-theme .progress-section .text-muted {
  color: #6b7280 !important;
}

:root.light-theme .progress-section .text-white,
.light-theme .progress-section .text-white {
  color: #1f2937 !important;
}

/* Light theme: ensure countdown and progress sections have light background so text is readable */
:root.light-theme .countdown-section.bg-dark-subtle,
.light-theme .countdown-section.bg-dark-subtle {
  background: #e8eaed !important;
}

:root.light-theme .countdown-section .time-value,
.light-theme .countdown-section .time-value,
:root.light-theme .countdown-section .time-label,
.light-theme .countdown-section .time-label {
  color: #1f2937 !important;
}

/* Instant win "X/Y Remaining" badge: always white text on dark bg (readable in light theme and on mobile) */
:root.light-theme .instant-win-header .badge.bg-dark,
.light-theme .instant-win-header .badge.bg-dark,
:root.light-theme .instant-win-header .badge.instant-win-remaining-badge,
.light-theme .instant-win-header .badge.instant-win-remaining-badge {
  color: #fff !important;
  background-color: #212529 !important;
  border-color: #495057 !important;
}

/* Light theme: ticket selector area light background so all text is readable */
:root.light-theme .ticket-input-group,
.light-theme .ticket-input-group {
  background: #e8eaed !important;
  border-color: rgba(0, 0, 0, 0.1) !important;
}

:root.light-theme .ticket-input-group .btn-icon.text-white,
.light-theme .ticket-input-group .btn-icon.text-white,
:root.light-theme .ticket-input-group .text-white,
.light-theme .ticket-input-group .text-white,
:root.light-theme .ticket-input-group #quantity-input,
.light-theme .ticket-input-group #quantity-input {
  color: #1f2937 !important;
}

:root.light-theme .ticket-input-group .btn-icon,
.light-theme .ticket-input-group .btn-icon {
  background: rgba(0, 0, 0, 0.08) !important;
}

/* Light theme styles for prize popup removed - now using expandable interface */

/* Mobile Skill Question Styling */
@media (max-width: 768px) {
  .skill-question-title {
    text-align: center !important;
  }


  .question-text {
    line-height: 1.3 !important;
  }
}

/* REDESIGN - NEW STYLES */

.text-dim {
  color: rgba(255, 255, 255, 0.6) !important;
}

.bg-glass {
  background: rgba(255, 255, 255, 0.05) !important;
  backdrop-filter: blur(10px);
}

.border-glass {
  border: 1px solid rgba(255, 255, 255, 0.1) !important;
}

.bg-dark-subtle {
  background-color: rgba(255, 255, 255, 0.03) !important;
}

.shadow-glow {
  box-shadow: 0 0 20px rgba(var(--primary-rgb), 0.3);
  transition: all 0.3s ease;
}

.shadow-glow:hover {
  box-shadow: 0 0 30px rgba(var(--primary-rgb), 0.5);
  transform: translateY(-2px);
}

.ticket-selector-section {
  background: transparent;
}

.ticket-input-group {
  background: rgba(0, 0, 0, 0.2);
  border: 1px solid rgba(255, 255, 255, 0.05);
}

.btn-icon {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(255, 255, 255, 0.1);
  transition: all 0.2s ease;
}

.btn-icon:hover {
  background: rgba(255, 255, 255, 0.2);
  transform: scale(1.1);
}

.cashback-simple {
  background: rgba(25, 135, 84, 0.1);
  border: 1px solid rgba(25, 135, 84, 0.2);
  border-radius: 50px;
  padding: 8px 16px;
  display: inline-block;
}

.hover-text-primary:hover {
  color: var(--primary) !important;
}

/* Adjust grid for better desktop layout */
@media (min-width: 992px) {
  .competition-detail-layout {
    grid-template-columns: 1.3fr 0.9fr;
    /* Approx 60/40 split */
    gap: 2rem;
  }
}

/* NEW INSTANT WIN REDESIGN */

.instant-win-card {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.05);
  border-radius: 12px;
  overflow: hidden;
  transition: all 0.3s ease;
}

.instant-win-card:hover {
  background: rgba(255, 255, 255, 0.05);
  border-color: rgba(255, 255, 255, 0.1);
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

.instant-win-header {
  background: transparent;
  transition: background 0.3s ease;
}

.instant-win-card:hover .instant-win-header {
  background: rgba(255, 255, 255, 0.02);
}

.prize-thumb {
  background: #000;
  border: 1px solid rgba(255, 255, 255, 0.1);
}

.prize-card__toggle {
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.prize-card__toggle:hover {
  background: rgba(255, 255, 255, 0.2) !important;
  transform: scale(1.1);
}

/* Rotate icon when open */
.prize-card__toggle--open .svg-icon {
  transform: rotate(90deg) !important;
}

/* Grid layout for tickets */
.prize-card__tickets-content {
  display: grid !important;
  grid-template-columns: repeat(auto-fill, minmax(70px, 1fr)) !important;
  gap: 0.75rem !important;
}

/* Redesign Ticket Cards */
.prize-ticket-card {
  width: 100% !important;
  height: auto !important;
  aspect-ratio: 1/1;
  margin: 0 !important;
  background: rgba(0, 0, 0, 0.3) !important;
  border: 1px solid rgba(255, 255, 255, 0.05) !important;
  border-radius: 8px !important;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  transition: all 0.2s ease;
}

.prize-ticket-card:hover {
  background: rgba(var(--primary-rgb), 0.1) !important;
  border-color: var(--primary) !important;
  transform: translateY(-2px);
}

.prize-ticket-card-content {
  font-size: 1rem !important;
  font-weight: 800 !important;
  color: white !important;
  margin-bottom: 4px !important;
}

.prize-ticket-card-footer {
  font-size: 0.6rem !important;
  letter-spacing: 0.5px;
  padding: 2px 6px !important;
  border-radius: 4px;
  background: rgba(255, 255, 255, 0.1) !important;
  color: rgba(255, 255, 255, 0.7) !important;
}

.prize-ticket-card.available .prize-ticket-card-footer {
  background: rgba(40, 167, 69, 0.2) !important;
  color: #28a745 !important;
}

.prize-ticket-card.taken {
  opacity: 0.5;
  background: rgba(220, 53, 69, 0.05) !important;
}

.prize-ticket-card.taken .prize-ticket-card-footer {
  background: rgba(220, 53, 69, 0.2) !important;
  color: #dc3545 !important;
}


/* --- THEME COMPATIBILITY FIXES FOR NEW COMPONENTS --- */

/* Light Theme Fixes for Product Page Instant Wins */
:root.light-theme .instant-win-card,
.light-theme .instant-win-card {
  background: rgba(0, 0, 0, 0.03);
  border-color: rgba(0, 0, 0, 0.1);
}

:root.light-theme .instant-win-card:hover,
.light-theme .instant-win-card:hover {
  background: rgba(0, 0, 0, 0.05);
}

:root.light-theme .instant-win-header h4,
.light-theme .instant-win-header h4 {
  color: #333 !important;
}

/* Instant win card: all muted/white text visible on light background */
:root.light-theme .instant-win-card .text-muted,
.light-theme .instant-win-card .text-muted {
  color: #6b7280 !important;
}

:root.light-theme .instant-win-card .text-white,
.light-theme .instant-win-card .text-white {
  color: #1f2937 !important;
}

:root.light-theme .progress-pill,
.light-theme .progress-pill {
  background: rgba(0, 0, 0, 0.05) !important;
  border-color: rgba(0, 0, 0, 0.1) !important;
}

:root.light-theme .progress-pill span,
.light-theme .progress-pill span {
  color: #555 !important;
}

:root.light-theme .progress-pill span.fw-bold,
.light-theme .progress-pill span.fw-bold {
  color: #000 !important;
}

:root.light-theme .progress-pill .text-muted,
.light-theme .progress-pill .text-muted {
  color: #6b7280 !important;
}

:root.light-theme .progress-pill .text-white,
.light-theme .progress-pill .text-white {
  color: #1f2937 !important;
}

/* Dark theme: ensure "Remaining" and other progress-pill muted text is visible */
:root.dark-theme .progress-pill .text-muted,
.dark-theme .progress-pill .text-muted,
:root.dark-theme .progress-pill .text-xs.text-muted,
.dark-theme .progress-pill .text-xs.text-muted {
  color: rgba(255, 255, 255, 0.85) !important;
}

:root.light-theme .prize-card__toggle,
.light-theme .prize-card__toggle {
  background: rgba(0, 0, 0, 0.1) !important;
  color: #333 !important;
}

:root.light-theme .prize-card__toggle svg,
.light-theme .prize-card__toggle svg {
  fill: #333 !important;
}

:root.light-theme .prize-card__content,
.light-theme .prize-card__content {
  border-top-color: rgba(0, 0, 0, 0.1) !important;
}

:root.light-theme .prize-card__tab-content,
.light-theme .prize-card__tab-content {
  background: #f8f9fa !important;
}

/* Light theme: tickets area background when using bg-dark-subtle */
:root.light-theme .prize-card__tab-content.bg-dark-subtle,
.light-theme .prize-card__tab-content.bg-dark-subtle {
  background: #f1f3f5 !important;
}

:root.light-theme .prize-ticket-card,
.light-theme .prize-ticket-card {
  background: #fff !important;
  border-color: rgba(0, 0, 0, 0.1) !important;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
}

:root.light-theme .prize-ticket-card-content,
.light-theme .prize-ticket-card-content {
  color: #333 !important;
}

:root.light-theme .prize-ticket-card-footer,
.light-theme .prize-ticket-card-footer {
  background: #eee !important;
  color: #666 !important;
}

/* Force display block on content when visible to override d-none */
.product__prize .prize-card__content[style*="display: block"] {
  display: block !important;
}

/* Ensure minimal height for ticket container so it shows up */
.prize-card__tickets-box {
  min-height: 100px;
}

/* Fix for Light Theme Toggle Button Visibility */
:root.light-theme .prize-card__toggle svg,
.light-theme .prize-card__toggle svg {
  fill: #333 !important;
}

:root.light-theme .prize-card__toggle.prize-card__toggle--open,
.light-theme .prize-card__toggle.prize-card__toggle--open {
  background: rgba(0, 0, 0, 0.2) !important;
}

/* Light theme: "Instant Win Prizes" heading in tab */
:root.light-theme .tab-content .text-gradient,
.light-theme .tab-content .text-gradient {
  color: var(--primary) !important;
}