:root {
  --primary: #FF0000;
  --primary-dark: #CC0000;
  --primary-light: #FF6666;
  --secondary: #0066FF;
  --secondary-dark: #0052CC;
  --background: #ffffff;
  --surface: #f8f9fa;
  --text-primary: #2c3e50;
  --text-secondary: #7f8c8d;
  --border: #ecf0f1;
  --success: #27ae60;
  --warning: #f39c12;
  --error: #FF0000;
  --shadow: 0 2px 8px rgba(0,0,0,0.1);
  --shadow-lg: 0 8px 24px rgba(0,0,0,0.15);
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html,
body {
  max-width: 100%;
  overflow-x: hidden;
}

html {
  -webkit-text-size-adjust: 100%;
}

img,
svg,
video,
canvas {
  max-width: 100%;
}

body {
  font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
  background-color: var(--background);
  color: var(--text-primary);
  line-height: 1.6;
}

body.modal-open {
  overflow: hidden;
}

/* Header & Navigation moved to ../shared/topbar-admin-sync.css */

.content {
  min-height: calc(100vh - 64px);
  display: flex;
  flex-direction: column;
}

.page-header {
  background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
  color: white;
  padding: 44px 24px;
  text-align: center;
}

.page-header h1 {
  font-size: clamp(30px, 4vw, 52px);
  margin: 0;
}

.page-content {
  flex-grow: 1;
  padding: 60px 32px;
  max-width: none;
  width: 100%;
  margin: 0;
}

.placeholder {
  background: var(--surface);
  border: 2px dashed var(--border);
  border-radius: 8px;
  padding: 60px;
  text-align: center;
  color: var(--text-secondary);
  font-size: 18px;
}

.hero {
  display: block;
}

.hero-text .eyebrow {
  text-transform: uppercase;
  letter-spacing: 1px;
  font-size: 12px;
  margin-bottom: 8px;
}

.hero-text h1 {
  line-height: 1.25;
  text-wrap: balance;
}

.hero-text {
  max-width: 1120px;
  margin: 0 auto;
}

.hero-event-title {
  margin-top: 10px;
  font-size: clamp(16px, 2.4vw, 28px);
  line-height: 1.35;
  font-weight: 700;
  color: rgba(255, 255, 255, 0.95);
  text-wrap: balance;
  overflow-wrap: anywhere;
}

.info-controls {
  margin-bottom: 22px;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 14px;
}

.filter {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-weight: 600;
}

.filter select {
  background: white;
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 8px 10px;
  min-width: 320px;
}

.results-root {
  min-height: 120px;
}

.team-standings {
  background: white;
  border: 1px solid var(--border);
  border-radius: 12px;
  box-shadow: var(--shadow);
  padding: 16px;
  margin-bottom: 18px;
}

.team-standings-head h2 {
  margin: 0;
  font-size: 20px;
  color: var(--text-primary);
}

.team-standings-head {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}

.team-standings-head .muted {
  margin-top: 4px;
  color: var(--text-secondary);
}

.standings-filter {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  color: var(--text-secondary);
  font-weight: 600;
}

.standings-filter select {
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 6px 10px;
  background: #fff;
  color: var(--text-primary);
}

.team-standings-empty {
  margin-top: 12px;
}

.team-standings-table-wrap {
  margin-top: 12px;
  overflow-x: auto;
}

.standings-list {
  margin-top: 12px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.standings-item {
  border: 1px solid var(--border);
  border-radius: 10px;
  background: #fff;
  padding: 10px 12px;
  display: grid;
  grid-template-columns: 1.3fr 1fr;
  gap: 12px;
  align-items: center;
}

.standings-main {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
}

.standings-main .team-col {
  font-weight: 700;
  color: var(--text-primary);
  overflow-wrap: anywhere;
}

.standings-metrics {
  display: grid;
  grid-template-columns: repeat(4, minmax(58px, 1fr));
  gap: 8px;
}

.metric-item {
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 6px 8px;
  text-align: center;
  background: #fafafa;
}

.metric-label {
  display: block;
  font-size: 11px;
  color: var(--text-secondary);
  font-weight: 700;
}

.metric-value {
  display: block;
  margin-top: 2px;
  font-size: 16px;
  font-weight: 800;
}

.metric-value.gold { color: #d4a017; }
.metric-value.silver { color: #6b7280; }
.metric-value.bronze { color: #b45309; }
.metric-value.total { color: var(--primary); }

.metric-item.metric-total {
  background: rgba(255, 0, 0, 0.05);
  border-color: rgba(255, 0, 0, 0.15);
}

.team-standings-table {
  width: 100%;
  border-collapse: collapse;
  min-width: 620px;
  table-layout: fixed;
}

.team-standings-table .col-rank {
  width: 90px;
}

.team-standings-table .col-team {
  width: auto;
}

.team-standings-table .col-medal,
.team-standings-table .col-total {
  width: 12%;
}

.team-standings-table th,
.team-standings-table td {
  padding: 10px 12px;
  border-bottom: 1px solid var(--border);
  text-align: center;
}

.team-standings-table th {
  color: var(--text-secondary);
  font-size: 13px;
  font-weight: 700;
}

.team-standings-table td {
  color: var(--text-primary);
  font-weight: 600;
}

.team-standings-table th:nth-child(2),
.team-standings-table td.team-col {
  text-align: left;
}

.team-standings-table td.rank-col {
  text-align: center;
}

.team-standings-table .medal {
  text-align: center;
  font-weight: 700;
}

.rank-badge-chip {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 34px;
  height: 34px;
  border-radius: 999px;
  font-weight: 800;
  font-size: 16px;
  border: 1px solid var(--border);
  background: #fff;
}

.rank-badge-chip.numeric {
  font-size: 14px;
  color: var(--text-primary);
  background: #f9fafb;
}

.rank-badge-chip.top-1 {
  background: rgba(212, 160, 23, 0.12);
  border-color: rgba(212, 160, 23, 0.45);
}

.rank-badge-chip.top-2 {
  background: rgba(107, 114, 128, 0.12);
  border-color: rgba(107, 114, 128, 0.35);
}

.rank-badge-chip.top-3 {
  background: rgba(180, 83, 9, 0.12);
  border-color: rgba(180, 83, 9, 0.35);
}

.team-standings-table tr.top-row {
  background: rgba(0, 102, 255, 0.02);
}

.standings-item.top-row {
  background: rgba(0, 102, 255, 0.03);
}

.team-standings-table .medal.gold {
  color: #d4a017;
}

.team-standings-table .medal.silver {
  color: #6b7280;
}

.team-standings-table .medal.bronze {
  color: #b45309;
}

.team-standings-table .medal.total {
  color: var(--primary);
}

.result-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 14px;
}

.level-groups {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.level-group {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 12px;
  box-shadow: var(--shadow);
  padding: 14px;
}

.level-group-head {
  margin-bottom: 12px;
  padding-bottom: 8px;
  border-bottom: 1px solid var(--border);
}

.level-group-head h2 {
  margin: 0;
  font-size: 18px;
  color: var(--secondary-dark);
}

.result-card {
  background: white;
  border: 1px solid var(--border);
  border-radius: 12px;
  box-shadow: var(--shadow);
  padding: 16px;
}

.leaderboard-card {
  background: #ffffff;
  color: var(--text-primary);
  border-color: var(--border);
  overflow: hidden;
}

.leaderboard-head {
  text-align: center;
  margin-bottom: 10px;
}

.leaderboard-head h3 {
  margin: 0;
  font-size: 18px;
  color: var(--text-primary);
  font-weight: 800;
}

.leaderboard-title-male {
  color: #1d6fc4;
}

.leaderboard-title-female {
  color: #c2185b;
}

.podium-board {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  align-items: end;
}

.podium-col {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
}

.podium-col.is-published {
  cursor: pointer;
}

.podium-medal {
  font-size: 28px;
  line-height: 1;
}

.podium-stage {
  position: relative;
  overflow: hidden;
  width: 100%;
  border-radius: 12px 12px 8px 8px;
  border: 1px solid var(--border);
  background: linear-gradient(155deg, #f8fafc 0%, #e9eef5 45%, #f8fafc 100%);
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  text-align: center;
  padding: 10px 8px;
  min-height: 110px;
}

.podium-stage::before {
  content: '';
  position: absolute;
  top: -35%;
  bottom: -35%;
  left: -140%;
  width: 68%;
  background: linear-gradient(
    115deg,
    rgba(255, 255, 255, 0) 0%,
    rgba(255, 255, 255, 0.45) 48%,
    rgba(255, 255, 255, 0) 100%
  );
  transform: translateX(-120%) skewX(-16deg);
  animation: podiumShine 3.1s linear infinite;
  pointer-events: none;
}

.podium-col.place-1 .podium-stage {
  min-height: 170px;
  border-color: rgba(234, 179, 8, 0.48);
  background: linear-gradient(155deg, #fff8d8 0%, #f6d87a 42%, #f0b90b 100%);
  box-shadow: inset 0 -4px 0 rgba(234, 179, 8, 0.68), 0 8px 20px rgba(234, 179, 8, 0.15);
}

.podium-col.place-2 .podium-stage {
  min-height: 140px;
  border-color: rgba(148, 163, 184, 0.44);
  background: linear-gradient(155deg, #ffffff 0%, #e5eaf0 46%, #c8d1dc 100%);
  box-shadow: inset 0 -4px 0 rgba(148, 163, 184, 0.68), 0 6px 16px rgba(148, 163, 184, 0.15);
}

.podium-col.place-3 .podium-stage {
  min-height: 126px;
  border-color: rgba(217, 119, 6, 0.4);
  background: linear-gradient(155deg, #fff1e2 0%, #f1c29a 45%, #cc7c2f 100%);
  box-shadow: inset 0 -4px 0 rgba(217, 119, 6, 0.68), 0 6px 16px rgba(217, 119, 6, 0.14);
}

.podium-col.is-empty .podium-stage {
  opacity: 0.68;
}

.podium-col.is-empty .podium-stage::before {
  animation-duration: 3.1s;
  animation-delay: 0s;
  opacity: 0.55;
}

/* Athlete preview modal */
.preview-modal {
  position: fixed;
  inset: 0;
  z-index: 1300;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 18px;
  overflow: hidden;
}

.preview-modal.hidden {
  display: none;
}

.preview-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(15, 23, 42, 0.65);
  backdrop-filter: blur(2px);
}

.preview-dialog {
  position: relative;
  width: min(860px, 100%);
  margin: 0;
  max-height: calc(100dvh - 36px);
}

.preview-close {
  position: absolute;
  top: 10px;
  right: 10px;
  width: 34px;
  height: 34px;
  border: none;
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.78);
  color: #fff;
  font-size: 22px;
  line-height: 1;
  cursor: pointer;
  z-index: 2;
}

.athlete-preview-card {
  position: relative;
  overflow: hidden;
  isolation: isolate;
  border-radius: 16px;
  border: 1px solid var(--border);
  background: #ffffff;
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.2);
  padding: 18px;
}

.athlete-preview-card::before {
  content: '';
  position: absolute;
  top: -35%;
  bottom: -35%;
  left: -150%;
  width: 55%;
  background: linear-gradient(115deg, rgba(255,255,255,0) 0%, rgba(255,255,255,0.45) 48%, rgba(255,255,255,0) 100%);
  transform: translateX(0%) skewX(-16deg);
  animation: previewShine 3.1s linear infinite;
  pointer-events: none;
}

.athlete-preview-card.rank-1 {
  background: linear-gradient(155deg, #fff8d8 0%, #f6d87a 42%, #f0b90b 100%);
  border-color: rgba(234, 179, 8, 0.5);
}

.athlete-preview-card.rank-2 {
  background: linear-gradient(155deg, #ffffff 0%, #e5eaf0 46%, #c8d1dc 100%);
  border-color: rgba(148, 163, 184, 0.4);
}

.athlete-preview-card.rank-3 {
  background: linear-gradient(155deg, #fff1e2 0%, #f1c29a 45%, #cc7c2f 100%);
  border-color: rgba(217, 119, 6, 0.45);
}

.athlete-preview-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding-right: 36px;
}

.preview-org img {
  width: 42px;
  height: 42px;
  object-fit: contain;
  display: block;
}

.preview-event-title {
  text-align: right;
  font-weight: 700;
  color: #0f172a;
  font-size: 15px;
}

.preview-rank-highlight {
  margin-top: 8px;
  font-size: clamp(28px, 4vw, 40px);
  font-weight: 1000;
  color: transparent;
  letter-spacing: 1px;
  text-align: center;
  text-transform: uppercase;
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-stroke: 1px rgba(15, 23, 42, 0.18);
  text-shadow: 0 4px 14px rgba(15, 23, 42, 0.2);
  background-size: 220% 100%;
  animation: rankTextShimmer 2.6s linear infinite;
}

.athlete-preview-card.rank-1 .preview-rank-highlight {
  background-image: linear-gradient(110deg, #7c2d12 0%, #fbbf24 35%, #fff8d8 50%, #f59e0b 70%, #7c2d12 100%);
}

.athlete-preview-card.rank-2 .preview-rank-highlight {
  background-image: linear-gradient(110deg, #1f2937 0%, #cbd5e1 35%, #ffffff 50%, #94a3b8 70%, #1f2937 100%);
}

.athlete-preview-card.rank-3 .preview-rank-highlight {
  background-image: linear-gradient(110deg, #7c2d12 0%, #f97316 35%, #ffedd5 50%, #c2410c 70%, #7c2d12 100%);
}

.preview-entry-highlight {
  margin-top: 2px;
  font-size: clamp(11px, 1.7vw, 15px);
  font-weight: 900;
  letter-spacing: 0.6px;
  text-align: center;
  text-transform: uppercase;
  color: transparent;
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-stroke: 0.65px rgba(15, 23, 42, 0.2);
  text-shadow: 0 3px 10px rgba(15, 23, 42, 0.18);
  background-size: 220% 100%;
  animation: rankTextShimmer 2.9s linear infinite;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  width: 100%;
}

.preview-entry-label,
.preview-entry-value {
  line-height: 1.2;
}

.preview-entry-value {
  white-space: nowrap;
}

.preview-entry-highlight.is-male {
  background-image: linear-gradient(110deg, #1e3a8a 0%, #3b82f6 35%, #dbeafe 50%, #2563eb 70%, #1e3a8a 100%);
}

.preview-entry-highlight.is-female {
  background-image: linear-gradient(110deg, #9d174d 0%, #ec4899 35%, #fce7f3 50%, #db2777 70%, #9d174d 100%);
}

.preview-entry-highlight.is-neutral {
  background-image: linear-gradient(110deg, #334155 0%, #94a3b8 35%, #e2e8f0 50%, #64748b 70%, #334155 100%);
}

@keyframes rankTextShimmer {
  0% {
    background-position: 0% 50%;
    filter: brightness(0.98);
  }
  50% {
    filter: brightness(1.18);
  }
  100% {
    background-position: 100% 50%;
    filter: brightness(0.98);
  }
}

.preview-content {
  margin-top: 10px;
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 16px;
  align-items: center;
}

.preview-info-list {
  display: grid;
  gap: 8px;
}

.preview-info-item {
  border: 1px solid rgba(15, 23, 42, 0.12);
  background: rgba(255, 255, 255, 0.55);
  border-radius: 10px;
  padding: 8px 10px;
}

.preview-info-item span {
  display: block;
  font-size: 12px;
  color: rgba(15, 23, 42, 0.75);
}

.preview-info-item strong {
  display: block;
  font-size: 16px;
  color: #0f172a;
  line-height: 1.35;
}

.preview-photo-wrap {
  width: 120px;
  border-radius: 10px;
  overflow: hidden;
  border: 1px solid rgba(15, 23, 42, 0.2);
  background: #fff;
  justify-self: end;
  align-self: center;
}

.preview-photo-wrap img {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 3 / 4;
  object-fit: cover;
}

@keyframes previewShine {
  0% { transform: translateX(0%) skewX(-16deg); }
  100% { transform: translateX(520%) skewX(-16deg); }
}

.podium-name {
  font-size: 16px;
  font-weight: 800;
  color: var(--text-primary);
  line-height: 1.28;
  width: 100%;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.podium-time {
  margin-top: 6px;
  font-size: 15px;
  font-weight: 800;
  color: var(--secondary-dark);
}

.podium-time-label {
  color: #64748b;
}

.podium-time-value {
  color: #0ea5e9;
}

@keyframes podiumShine {
  0% {
    transform: translateX(0%) skewX(-16deg);
  }
  100% {
    transform: translateX(430%) skewX(-16deg);
  }
}

@media (prefers-reduced-motion: reduce) {
  .podium-stage::before {
    animation: none;
  }

  .preview-rank-highlight {
    animation: none;
  }

  .preview-entry-highlight {
    animation: none;
  }
}

.result-head h3 {
  margin: 0 0 4px;
  color: var(--text-primary);
}

.result-head p {
  margin: 0;
  color: var(--text-secondary);
  font-size: 14px;
}

.rank-list {
  margin: 10px 0 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

/* hàng kết quả kiểu chữ */
.rank-row-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 9px 12px;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: var(--surface);
  cursor: pointer;
  transition: background 0.15s, box-shadow 0.15s;
  min-width: 0;
}

.rank-row-item:not(.is-empty):hover {
  background: #f0f6ff;
  box-shadow: 0 2px 8px rgba(0, 102, 255, 0.1);
}

.rank-row-item.is-empty {
  cursor: default;
  opacity: 0.55;
}

.rank-row-item.rank-row-1 {
  border-color: rgba(234, 179, 8, 0.45);
  background: rgba(255, 248, 216, 0.55);
}

.rank-row-item.rank-row-2 {
  border-color: rgba(148, 163, 184, 0.4);
  background: rgba(229, 234, 240, 0.45);
}

.rank-row-item.rank-row-3 {
  border-color: rgba(217, 119, 6, 0.35);
  background: rgba(255, 241, 226, 0.5);
}

.rank-medal-icon {
  font-size: 22px;
  line-height: 1;
  flex-shrink: 0;
}

.rank-athlete-name {
  flex: 1 1 0;
  font-weight: 700;
  font-size: 15px;
  color: var(--text-primary);
  min-width: 0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.rank-athlete-placeholder {
  font-weight: 400;
  color: var(--text-secondary);
  font-style: italic;
}

.rank-time-value {
  font-size: 14px;
  font-weight: 700;
  color: var(--secondary-dark);
  white-space: nowrap;
  flex-shrink: 0;
}

.rank-time-empty {
  font-size: 14px;
  color: var(--text-secondary);
  flex-shrink: 0;
}

.rank-item {
  display: grid;
  grid-template-columns: 86px 1fr;
  gap: 10px;
  align-items: start;
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 10px;
  background: var(--surface);
}

.rank-badge {
  font-weight: 700;
  color: var(--primary);
}

.winner-name {
  font-weight: 700;
  color: var(--text-primary);
}

.winner-club,
.rank-time,
.team-members,
.rank-body .muted {
  font-size: 14px;
  color: var(--text-secondary);
  margin-top: 4px;
}

.team-members {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.team-members span {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 20px;
  padding: 2px 8px;
}

/* ============== Footer ============== */
.footer {
  background: var(--text-primary);
  color: white;
  padding: 60px 32px 24px;
  margin-top: 80px;
}

.footer-content {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 40px;
  max-width: none;
  width: 100%;
  margin: 0 0 40px;
}

.footer-col h4 {
  margin-bottom: 16px;
  font-size: 16px;
}

.footer-col p {
  color: rgba(255,255,255,0.7);
  margin-bottom: 8px;
  font-size: 14px;
  line-height: 1.6;
}

.footer-col ul {
  list-style: none;
}

.footer-col ul li {
  margin-bottom: 8px;
}

.footer-col a {
  color: rgba(255,255,255,0.7);
  text-decoration: none;
  transition: color 0.3s ease;
}

.footer-col a:hover {
  color: white;
}

.footer-bottom {
  border-top: 1px solid rgba(255,255,255,0.1);
  padding-top: 20px;
  text-align: center;
  color: rgba(255,255,255,0.5);
  font-size: 14px;
}

/* ============== Responsive Design ============== */
@media (max-width: 900px) {
/* Profile dropdown mobile */
.page-header {
    padding: 34px 20px;
  }

  .page-header h1 {
    font-size: clamp(24px, 6vw, 34px);
  }

  .page-content {
    padding: 40px 20px;
  }

  .hero {
    display: block;
  }

  .result-grid {
    grid-template-columns: 1fr;
  }

  .filter {
    width: 100%;
    flex-direction: column;
    align-items: stretch;
  }

  .filter select {
    min-width: 0;
    width: 100%;
  }

  .placeholder {
    padding: 40px;
  }

  .footer-content {
    grid-template-columns: repeat(2, 1fr);
    gap: 30px;
  }
}

@media (max-width: 768px) {
.brand-text {
    font-size: 16px;
  }

  .page-header {
    padding: 28px 16px;
  }

  .page-header h1 {
    font-size: clamp(22px, 7vw, 30px);
  }

  .hero-event-title {
    margin-top: 8px;
    font-size: clamp(15px, 4.4vw, 20px);
  }

  .page-content {
    padding: 30px 16px;
  }

  .placeholder {
    padding: 30px;
    font-size: 16px;
  }

  .standings-item {
    grid-template-columns: 1fr;
    gap: 10px;
  }

  .standings-metrics {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .rank-item {
    grid-template-columns: 1fr;
  }

  .leaderboard-head h3 {
    font-size: 20px;
  }

  .result-grid {
    grid-template-columns: 1fr;
  }

  .podium-board {
    grid-template-columns: 1fr;
    gap: 10px;
  }

  .podium-col.place-1 { order: 1; }
  .podium-col.place-2 { order: 2; }
  .podium-col.place-3 { order: 3; }

  .podium-col {
    width: 100%;
  }

  .podium-stage {
    min-height: 92px;
  }

  .podium-col.place-1 .podium-stage {
    min-height: 118px;
  }

  .podium-col.place-2 .podium-stage {
    min-height: 102px;
  }

  .podium-col.place-3 .podium-stage {
    min-height: 98px;
  }

  .podium-name {
    font-size: 14px;
    white-space: normal;
    overflow: visible;
    text-overflow: clip;
    line-height: 1.35;
  }

  .preview-dialog {
    width: 100%;
    margin: 0;
    max-height: calc(100dvh - 20px);
  }

  .preview-content {
    grid-template-columns: 1fr;
  }

  .preview-photo-wrap {
    width: 108px;
    justify-self: center;
    align-self: center;
    order: -1;
  }

  .athlete-preview-card {
    max-height: none;
    overflow: hidden;
  }

  .preview-event-title {
    font-size: 13px;
  }

  .preview-entry-highlight {
    font-size: clamp(10px, 3.4vw, 13px);
    display: grid;
    gap: 2px;
    justify-items: center;
    align-items: center;
  }

  .preview-entry-label {
    display: block;
    font-size: 0.92em;
  }

  .preview-entry-value {
    display: block;
    width: 100%;
    text-align: center;
    white-space: nowrap;
  }

  .podium-time {
    font-size: 13px;
  }

  .footer {
    padding: 40px 16px 20px;
  }

  .footer-content {
    grid-template-columns: 1fr;
    gap: 24px;
  }

  .footer-col h4 {
    font-size: 14px;
  }

  .footer-col p,
  .footer-col a {
    font-size: 13px;
  }
}

@media (max-width: 1024px) and (orientation: landscape) {
  .preview-modal {
    align-items: flex-start;
    padding: 10px;
    overflow-y: auto;
    overscroll-behavior: contain;
    -webkit-overflow-scrolling: touch;
  }

  .preview-dialog {
    width: min(900px, 100%);
    max-height: calc(100dvh - 20px);
  }

  .athlete-preview-card {
    max-height: calc(100dvh - 20px);
    overflow-y: auto;
    overflow-x: hidden;
  }
}

@media (max-width: 1024px) and (orientation: portrait) {
  .preview-modal {
    overflow: hidden;
  }

  .preview-dialog {
    max-height: none;
  }

  .athlete-preview-card {
    max-height: none;
    overflow: hidden;
  }
}

/* Entry content filter bar */
.results-filter-bar {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
  margin: 18px 0 16px;
  padding: 12px 16px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 10px;
}

.entry-filter {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-weight: 600;
  font-size: 14px;
  color: var(--text-secondary);
  white-space: nowrap;
}

.entry-filter select {
  background: white;
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 7px 10px;
  min-width: 220px;
  font-size: 14px;
  color: var(--text-primary);
}
