/* Kezdőlapi bajnokság-kártyák: állapot, haladás, következő forduló, éllovasok */
.hv-champs {
  --hv-red: #e10600;
  --hv-card: #1c1c1c;
  --hv-line: rgba(255, 255, 255, 0.09);
  display: grid;
  grid-template-columns: repeat(var(--hv-cols, 3), minmax(0, 1fr));
  gap: 24px;
  margin: 0 auto;
}

/* Kevesebb kártyánál nem nyúlnak szét a teljes szélességre */
.hv-champs[data-count="1"] { --hv-cols: 1; max-width: 520px; }
.hv-champs[data-count="2"] { --hv-cols: 2; max-width: 920px; }

.hv-champ {
  display: flex;
  flex-direction: column;
  min-width: 0;
  background: var(--hv-card);
  border: 1px solid var(--hv-line);
  border-radius: 8px;
  overflow: hidden;
  transition: border-color 0.2s ease, transform 0.2s ease;
}

.hv-champ:hover {
  border-color: rgba(225, 6, 0, 0.6);
  transform: translateY(-3px);
}

.hv-champ__media {
  position: relative;
  display: block;
  aspect-ratio: 16 / 9;
  background: #000;
  overflow: hidden;
}

.hv-champ__media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.hv-champ__media-empty {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 100%;
  color: rgba(255, 255, 255, 0.25);
  font-size: 3rem;
}

.hv-status {
  position: absolute;
  top: 12px;
  left: 12px;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 4px 10px;
  font-family: 'Rajdhani', 'Arial Narrow', Arial, sans-serif;
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #fff;
  background: rgba(18, 18, 18, 0.88);
  border-radius: 3px;
}

.hv-status--ongoing {
  background: var(--hv-red);
}

.hv-status--ongoing::before {
  content: '';
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #fff;
  animation: hv-pulse 1.6s ease-in-out infinite;
}

.hv-status--completed {
  background: rgba(70, 70, 70, 0.92);
  color: #ddd;
}

@keyframes hv-pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.25; }
}

.hv-champ__body {
  display: flex;
  flex-direction: column;
  flex: 1;
  gap: 16px;
  padding: 18px 20px 20px;
}

.hv-champ__title {
  margin: 0;
  font-family: 'Rajdhani', 'Arial Narrow', Arial, sans-serif;
  font-size: 1.4rem;
  font-weight: 700;
  line-height: 1.15;
}

.hv-champ__title a {
  color: #fff;
  text-decoration: none;
}

.hv-champ__title a:hover {
  color: #fff;
  text-decoration: underline;
  text-decoration-color: var(--hv-red);
  text-underline-offset: 4px;
}

.hv-champ__sim {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 6px;
  font-size: 0.88rem;
  color: #a8a8a8;
}

.hv-champ__sim img {
  width: 18px;
  height: 18px;
  object-fit: contain;
}

.hv-label {
  display: block;
  margin-bottom: 6px;
  font-family: 'Rajdhani', 'Arial Narrow', Arial, sans-serif;
  font-size: 0.74rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #8f8f8f;
}

.hv-progress__head {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
}

.hv-progress__count {
  font-family: 'Rajdhani', 'Arial Narrow', Arial, sans-serif;
  font-size: 0.95rem;
  font-weight: 700;
  color: #fff;
  font-variant-numeric: tabular-nums;
}

.hv-progress__track {
  height: 4px;
  background: rgba(255, 255, 255, 0.12);
  border-radius: 2px;
  overflow: hidden;
}

.hv-progress__fill {
  height: 100%;
  background: var(--hv-red);
  border-radius: 2px;
}

.hv-next {
  padding: 10px 12px;
  background: rgba(255, 255, 255, 0.04);
  border-left: 3px solid var(--hv-red);
  border-radius: 0 4px 4px 0;
}

.hv-next__when {
  font-family: 'Rajdhani', 'Arial Narrow', Arial, sans-serif;
  font-size: 1.1rem;
  font-weight: 700;
  color: #fff;
}

.hv-next__when--today {
  color: #ff5a55;
}

.hv-next__where {
  font-size: 0.9rem;
  color: #c4c4c4;
}

.hv-leaders {
  margin: 0;
  padding: 0;
  list-style: none;
}

.hv-leaders li {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 6px 0;
  border-top: 1px solid var(--hv-line);
  font-size: 0.93rem;
  color: #e6e6e6;
}

.hv-leaders li:first-child {
  border-top: 0;
}

.hv-leaders__pos {
  flex: 0 0 22px;
  height: 22px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-family: 'Rajdhani', 'Arial Narrow', Arial, sans-serif;
  font-size: 0.85rem;
  font-weight: 700;
  color: #111;
  border-radius: 3px;
  background: #cd7f32;
}

.hv-leaders li:nth-child(1) .hv-leaders__pos { background: #e8b923; }
.hv-leaders li:nth-child(2) .hv-leaders__pos { background: #c0c5cc; }

.hv-leaders__name {
  flex: 1;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.hv-leaders__pts {
  font-family: 'Rajdhani', 'Arial Narrow', Arial, sans-serif;
  font-weight: 700;
  color: #fff;
  font-variant-numeric: tabular-nums;
}

.hv-leaders__pts small {
  font-weight: 600;
  color: #8f8f8f;
}

.hv-champ__empty {
  margin: 0;
  font-size: 0.9rem;
  color: #a8a8a8;
}

.hv-champ__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: auto;
}

.hv-champ__btn {
  flex: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 10px 14px;
  font-family: 'Rajdhani', 'Arial Narrow', Arial, sans-serif;
  font-size: 0.98rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  text-decoration: none;
  color: #fff;
  white-space: nowrap;
  border: 1px solid rgba(255, 255, 255, 0.22);
  border-radius: 4px;
  transition: background-color 0.2s ease, border-color 0.2s ease;
}

.hv-champ__btn:hover {
  color: #fff;
  border-color: #fff;
  background: rgba(255, 255, 255, 0.06);
}

.hv-champ__btn--primary {
  flex: 0 0 auto;
  padding-inline: 22px;
  background: var(--hv-red);
  border-color: var(--hv-red);
}

.hv-champ__btn--primary:hover {
  background: #ff1a14;
  border-color: #ff1a14;
}

.hv-champ__btn:focus-visible,
.hv-champ__title a:focus-visible,
.hv-champ__media:focus-visible {
  outline: 2px solid #fff;
  outline-offset: 2px;
}

/* Keskenyebb hasábban (pl. oldalsáv mellett) legfeljebb két oszlop */
.hv-champs--two:not([data-count="1"]) {
  --hv-cols: 2;
  max-width: none;
}

/* Tablet: két oszlop */
@media (max-width: 991.98px) and (min-width: 768px) {
  .hv-champs:not([data-count="1"]) { --hv-cols: 2; max-width: none; }
}

/* Mobil: a kártyák egymás alatt, teljes szélességben */
@media (max-width: 767.98px) {
  .hv-champs,
  .hv-champs[data-count="2"],
  .hv-champs--two:not([data-count="1"]) {
    --hv-cols: 1;
    max-width: none;
    gap: 16px;
  }

  .hv-champ:hover {
    transform: none;
  }
}

@media (prefers-reduced-motion: reduce) {
  .hv-status--ongoing::before { animation: none; }
  .hv-champ { transition: none; }
  .hv-champ:hover { transform: none; }
}

/* ===== Bajnokságok listaoldala ===== */
.hv-list-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 16px;
  margin: 0 0 20px;
  padding-left: 16px;
  border-left: 4px solid #e10600;
}

.hv-list-head h2 {
  margin: 0;
  font-family: 'Rajdhani', 'Arial Narrow', Arial, sans-serif;
  font-size: clamp(1.5rem, 2.6vw, 1.9rem);
  font-weight: 700;
  line-height: 1.1;
  color: #fff;
}

.hv-list-head__count {
  flex: 0 0 auto;
  font-family: 'Rajdhani', 'Arial Narrow', Arial, sans-serif;
  font-size: 0.85rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: #8f8f8f;
}

.hv-list-head--archive {
  margin-top: 56px;
  border-left-color: #5a5a5a;
}

/* Archívum: évenként nyitható csoportok, tömör sorokkal */
.hv-archive {
  margin-bottom: 12px;
  background: #1c1c1c;
  border: 1px solid rgba(255, 255, 255, 0.09);
  border-radius: 8px;
  overflow: hidden;
}

.hv-archive > summary {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 14px 18px;
  cursor: pointer;
  list-style: none;
  user-select: none;
}

.hv-archive > summary::-webkit-details-marker {
  display: none;
}

.hv-archive > summary:focus-visible {
  outline: 2px solid #fff;
  outline-offset: -2px;
}

.hv-archive__year {
  font-family: 'Rajdhani', 'Arial Narrow', Arial, sans-serif;
  font-size: 1.5rem;
  font-weight: 700;
  line-height: 1;
  color: #fff;
  font-variant-numeric: tabular-nums;
}

.hv-archive__count {
  flex: 1;
  font-size: 0.9rem;
  color: #a8a8a8;
}

.hv-archive__chevron {
  color: #8f8f8f;
  transition: transform 0.2s ease;
}

.hv-archive[open] .hv-archive__chevron {
  transform: rotate(180deg);
}

.hv-archive__list {
  margin: 0;
  padding: 0 10px 10px;
  list-style: none;
}

.hv-archive-row {
  display: grid;
  grid-template-columns: 112px minmax(0, 1fr) auto;
  align-items: center;
  gap: 16px;
  padding: 8px;
  color: inherit;
  text-decoration: none;
  border-top: 1px solid rgba(255, 255, 255, 0.07);
  border-radius: 6px;
  transition: background-color 0.2s ease;
}

.hv-archive-row:hover,
.hv-archive-row:focus {
  color: inherit;
  background: #242424;
}

.hv-archive-row:focus-visible {
  outline: 2px solid #fff;
  outline-offset: -2px;
}

.hv-archive-row__thumb {
  aspect-ratio: 16 / 9;
  background: #000;
  border-radius: 4px;
  overflow: hidden;
}

.hv-archive-row__thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: saturate(0.75);
  transition: filter 0.3s ease;
}

.hv-archive-row:hover .hv-archive-row__thumb img {
  filter: none;
}

.hv-archive-row__thumb-empty {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 100%;
  color: rgba(255, 255, 255, 0.25);
}

.hv-archive-row__name {
  margin: 0 0 4px;
  font-family: 'Rajdhani', 'Arial Narrow', Arial, sans-serif;
  font-size: 1.15rem;
  font-weight: 700;
  line-height: 1.2;
  color: #fff;
}

.hv-archive-row__meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 4px 14px;
  font-size: 0.86rem;
  color: #a8a8a8;
}

.hv-archive-row__meta img {
  width: 16px;
  height: 16px;
  margin-right: 6px;
  object-fit: contain;
}

.hv-archive-row__winner {
  min-width: 0;
  max-width: 220px;
  text-align: right;
}

.hv-archive-row__winner .hv-label {
  margin-bottom: 2px;
}

.hv-archive-row__winner strong {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 0.97rem;
  font-weight: 600;
  color: #fff;
}

.hv-archive-row__winner strong i {
  margin-right: 6px;
  color: #e8b923;
}

@media (max-width: 575.98px) {
  .hv-archive-row {
    grid-template-columns: 88px minmax(0, 1fr);
    gap: 12px;
  }

  .hv-archive-row__winner {
    grid-column: 2;
    max-width: none;
    text-align: left;
  }

  .hv-archive-row__winner .hv-label {
    display: inline;
    margin-right: 6px;
  }

  .hv-archive-row__winner strong {
    display: inline;
    white-space: normal;
  }
}

@media (prefers-reduced-motion: reduce) {
  .hv-archive__chevron,
  .hv-archive-row,
  .hv-archive-row__thumb img {
    transition: none;
  }
}

/* Üres állapot: amikor nincs aktív bajnokság vagy futam */
.hv-empty {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 8px;
  padding: 18px 20px;
  background: #1c1c1c;
  border: 1px solid rgba(255, 255, 255, 0.09);
  border-left: 3px solid #5a5a5a;
  border-radius: 6px;
}

.hv-empty__icon {
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  font-size: 1.05rem;
  color: #a8a8a8;
  background: rgba(255, 255, 255, 0.05);
  border-radius: 6px;
}

.hv-empty__text {
  flex: 1;
  min-width: 0;
}

.hv-empty__title {
  margin: 0 0 2px;
  font-family: 'Rajdhani', 'Arial Narrow', Arial, sans-serif;
  font-size: 1.2rem;
  font-weight: 700;
  line-height: 1.2;
  color: #fff;
}

.hv-empty__text p {
  margin: 0;
  font-size: 0.93rem;
  color: #a8a8a8;
}

.hv-empty .hv-champ__btn {
  flex: 0 0 auto;
}

@media (max-width: 575.98px) {
  .hv-empty {
    flex-wrap: wrap;
  }

  .hv-empty .hv-champ__btn {
    flex: 1 1 100%;
  }
}
