* {
  box-sizing: border-box;
  font-family: din_next_lt_proregular, sans-serif;
}

@font-face {
    font-family: 'din_next_lt_proregular';
    src: url('../../fonts/linotype_-_dinnextltpro-regular-webfont.woff2') format('woff2'),
         url('../../fonts/linotype_-_dinnextltpro-regular-webfont.woff') format('woff');
    font-weight: normal;
    font-style: normal;

}

@font-face {
    font-family: 'din_next_lt_proregular';
    src: url('../../fonts/linotype_-_dinnextltpro-bold-webfont.woff2') format('woff2'),
		 url('../../fonts/linotype_-_dinnextltpro-bold-webfont.woff') format('woff');
    font-weight: bold;
    font-style: normal;

}




@font-face {
    font-family: 'futura_ptbold';
    src: url('../../fonts/futuraptbold-webfont.woff2') format('woff2'),
         url('../../fonts/futuraptbold-webfont.woff') format('woff');
    font-weight: normal;
    font-style: normal;

}

body {
  margin: 25px;
  font-family: din_next_lt_proregular, sans-serif;
  color: #F4F4F4;
  background-color: #291C5E
}

h1 {
	text-transform: Uppercase;
    font-family: futura_ptbold, sans-serif;
    color: #F4F4F4;
	font-size: 50px;
}

.sparky-logo {
	height: 50px;
	vertical-align: middle;
	margin-right: 10px;
}

h2 { 
	text-transform: Uppercase;
    font-family: futura_ptbold, sans-serif;
    color: #F4F4F4;
	font-size: 35px;
}

h3 { 
	text-transform: Uppercase;
    font-family: futura_ptbold, sans-serif;
    color: #291C5E;
	font-size: 20px;
    background: #00DAD8;
    padding: 10px 16px;
    border-radius: 6px 6px 0 0;
    margin-bottom: 0;
    letter-spacing: 1px;
}

a {
  color: #00DAD8;
  text-decoration: none;
}

a:hover {
  color: #CF23CA;
  text-decoration: underline;
}

ul {
  margin-top: 0;
  background: rgba(244,244,244,0.06);
  border-radius: 0 0 6px 6px;
  padding: 16px 16px 16px 40px;
  border: 1px solid rgba(244,244,244,0.08);
  border-top: none;
}

li {
  padding: 6px 0;
}

img {
  height: 100px;
}

td {
    margin:auto;
    text-align:center;
    vertical-align: top;
    width:200px;
    padding: 15px;
    border: 1px solid #F4F4F4;
}
/* Style the top navigation bar */
.topnav {
  overflow: hidden;
  background-color: #291C5E;
}

/* Style the topnav links */
.topnav a {
  float: left;
  display: block;
  color: #F4F4F4;
  text-align: center;
  padding: 14px 16px;
  text-decoration: none;
  font-family: futura_ptbold, sans-serif;
  text-transform: uppercase;
}

/* Change color on hover */
.topnav a:hover {
  background-color: #00DAD8;
  color: #291C5E;
}

/* Style the content */
.content {
  background-color: #C9CCF0;
  padding: 10px;
  height: 200px; /* Should be removed. Only for demonstration */
}

.tab { margin-left: 40px; }

/* Style the footer */
.footer {
  background-color: #F4F4F4;
  padding: 10px;
}

/* ===== Fight Detail: Matchup Header ===== */
.matchup-header {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 20px;
  margin: 30px 0 40px;
  padding: 30px 20px;
  background: linear-gradient(135deg, #3a3078 0%, #2a2560 100%);
  border-radius: 8px;
  border: 1px solid rgba(244,244,244,0.1);
  position: sticky;
  top: 0;
  z-index: 100;
}

.matchup-bot {
  display: flex;
  flex-direction: column;
  align-items: center;
  flex: 1;
  max-width: 300px;
}

.bot-image-wrap {
  width: 140px;
  height: 140px;
  border-radius: 8px;
  overflow: hidden;
  background: rgba(244,244,244,0.05);
  border: 2px solid rgba(244,244,244,0.15);
  margin-bottom: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.matchup-bot-left .bot-image-wrap {
  border-color: #CF23CA;
  box-shadow: 0 0 16px rgba(207,35,202,0.35);
}

.matchup-bot-right .bot-image-wrap {
  border-color: #00DAD8;
  box-shadow: 0 0 16px rgba(0,218,216,0.35);
}

.bot-image-wrap img {
  height: 100%;
  width: 100%;
  object-fit: cover;
}

.bot-name {
  font-family: futura_ptbold, sans-serif;
  font-size: 22px;
  text-transform: uppercase;
  color: #F4F4F4;
  text-align: center;
  letter-spacing: 0.5px;
}

.bot-driver {
  font-size: 14px;
  color: #C9CCF0;
  margin-top: 4px;
  text-align: center;
}

.matchup-vs {
  font-family: futura_ptbold, sans-serif;
  font-size: 48px;
  color: #CF23CA;
  text-shadow: 0 0 20px rgba(207,35,202,0.4);
  flex-shrink: 0;
  padding: 0 10px;
}

/* ===== Fight Detail: Stat Sections ===== */
.stat-section {
  margin-bottom: 24px;
  border-radius: 6px;
  overflow: hidden;
  border: 1px solid rgba(244,244,244,0.08);
}

.stat-section-title {
  font-family: futura_ptbold, sans-serif;
  font-size: 13px;
  text-transform: uppercase;
  letter-spacing: 2px;
  color: #291C5E;
  background: #00DAD8;
  padding: 8px 16px;
}

.stat-row {
  display: flex;
  align-items: stretch;
  min-height: 42px;
}

.stat-row-even {
  background: rgba(244,244,244,0.04);
}

.stat-row-odd {
  background: rgba(244,244,244,0.08);
}

.stat-val {
  flex: 1;
  padding: 10px 16px;
  font-size: 15px;
  color: #F4F4F4;
  display: flex;
  align-items: center;
}

.stat-val-left {
  justify-content: flex-end;
  text-align: right;
  box-shadow: inset 3px 0 0 #CF23CA;
}

.stat-val-right {
  justify-content: flex-start;
  text-align: left;
  box-shadow: inset -3px 0 0 #00DAD8;
}

.stat-label {
  width: 180px;
  flex-shrink: 0;
  padding: 10px 12px;
  font-family: futura_ptbold, sans-serif;
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: #C9CCF0;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  border-left: 1px solid rgba(244,244,244,0.06);
  border-right: 1px solid rgba(244,244,244,0.06);
}

/* ===== Fight Detail: Overall stat row (spans full width) ===== */
.stat-val-overall {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 12px 16px;
  text-align: center;
}

.stat-overall-label {
  font-family: futura_ptbold, sans-serif;
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: #C9CCF0;
  margin-bottom: 4px;
}

.stat-overall-value {
  font-size: 18px;
  font-weight: bold;
  color: #00DAD8;
}

/* ===== Fight Detail: Side-by-side list columns ===== */
.stat-list-columns {
  display: flex;
  gap: 0;
}

.stat-list-col {
  flex: 1;
  min-width: 0;
}

.stat-list-col-left {
  border-right: 1px solid rgba(244,244,244,0.06);
  box-shadow: inset 3px 0 0 #CF23CA;
}

.stat-list-col-right {
  box-shadow: inset -3px 0 0 #00DAD8;
}

.stat-list-item {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 16px;
  font-size: 14px;
  color: #F4F4F4;
}

.stat-list-result {
  font-family: futura_ptbold, sans-serif;
  font-size: 13px;
  letter-spacing: 0.5px;
  width: 20px;
  flex-shrink: 0;
  text-align: center;
}

.stat-list-result-w {
  color: #00DAD8;
}

.stat-list-result-l {
  color: #CF23CA;
}

.stat-list-detail {
  flex: 1;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.stat-list-annotation {
  font-size: 12px;
  color: #C9CCF0;
  flex-shrink: 0;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.stat-list-empty {
  padding: 12px 16px;
  font-size: 14px;
  color: #C9CCF0;
  font-style: italic;
}

/* ===== Bot Search ===== */
.bot-search-container {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  max-width: 600px;
  margin-bottom: 30px;
}

.bot-search-input {
  width: 100%;
  padding: 10px 14px;
  font-size: 15px;
  font-family: din_next_lt_proregular, sans-serif;
  color: #F4F4F4;
  background: rgba(244,244,244,0.06);
  border: 1px solid rgba(244,244,244,0.15);
  border-radius: 6px;
  outline: none;
}

.bot-search-input:focus {
  border-color: #00DAD8;
}

.bot-search-dropdown {
  display: none;
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  background: #3a3078;
  border: 1px solid rgba(244,244,244,0.15);
  border-radius: 0 0 6px 6px;
  max-height: 240px;
  overflow-y: auto;
  z-index: 200;
}

.bot-search-option {
  padding: 8px 14px;
  cursor: pointer;
  font-size: 14px;
  color: #F4F4F4;
}

.bot-search-option:hover {
  background: #00DAD8;
  color: #291C5E;
}

.bot-search-btn {
  padding: 10px 20px;
  font-family: futura_ptbold, sans-serif;
  font-size: 14px;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: #291C5E;
  background: #00DAD8;
  border: none;
  border-radius: 6px;
  cursor: pointer;
  white-space: nowrap;
}

.bot-search-btn:disabled {
  opacity: 0.4;
  cursor: default;
}

/* ===== Bot Detail ===== */
.bot-detail-header {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 30px 20px;
  margin: 20px auto 30px;
  max-width: 600px;
  background: linear-gradient(135deg, #3a3078 0%, #2a2560 100%);
  border-radius: 8px;
  border: 1px solid rgba(244,244,244,0.1);
}

.bot-detail-section {
  max-width: 600px;
  margin: 0 auto 24px;
}

.bot-detail-label {
  width: 200px;
  flex-shrink: 0;
  padding: 10px 16px;
  font-family: futura_ptbold, sans-serif;
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: #C9CCF0;
  display: flex;
  align-items: center;
}

.bot-detail-val {
  flex: 1;
  padding: 10px 16px;
  font-size: 15px;
  color: #F4F4F4;
  display: flex;
  align-items: center;
}

/* ===== Events table (select event for bracket) ===== */
.events-table-wrap {
  max-width: 640px;
  max-height: 70vh;
  overflow-y: auto;
  overflow-x: auto;
  border: 1px solid rgba(244,244,244,0.08);
  border-radius: 6px;
  margin: 1rem 0;
}

.events-table {
  width: 100%;
  border-collapse: collapse;
  overflow: hidden;
}

.events-table thead tr {
  background: #00DAD8;
}

.events-table thead th {
  font-family: futura_ptbold, sans-serif;
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: #291C5E;
  padding: 10px 16px;
  text-align: left;
  border: none;
  margin: 0;
}

.events-table .events-table-choose {
  width: 2.5rem;
  text-align: center;
  padding: 10px 8px;
}

.events-table .events-table-date {
  width: 120px;
}

.events-table tbody tr {
  background: rgba(244,244,244,0.04);
}

.events-table tbody tr:nth-child(even) {
  background: rgba(244,244,244,0.08);
}

.events-table tbody tr:hover {
  background: rgba(0,218,216,0.12);
}

.events-table tbody td {
  padding: 12px 16px;
  border: 1px solid rgba(244,244,244,0.06);
  border-top: none;
  vertical-align: middle;
  width: auto;
  margin: 0;
}

.events-table tbody td:first-child {
  border-left: none;
}

.events-table tbody .events-table-choose {
  text-align: center;
}

.events-table tbody .events-table-date {
  font-variant-numeric: tabular-nums;
  color: #C9CCF0;
}

.events-table tbody .events-table-name {
  color: #F4F4F4;
}

.events-table tbody label {
  cursor: pointer;
  display: block;
}

/* ===== Replace tournament link modal ===== */
.replace-modal {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.6);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
}

.replace-modal[hidden] {
  display: none;
}

.replace-modal-content {
  background: linear-gradient(135deg, #3a3078 0%, #2a2560 100%);
  border: 1px solid rgba(244, 244, 244, 0.15);
  border-radius: 8px;
  padding: 1.5rem 2rem;
  max-width: 480px;
  width: 90%;
  position: relative;
}

.replace-modal-close {
  position: absolute;
  top: 0.75rem;
  right: 1rem;
  background: none;
  border: none;
  color: #C9CCF0;
  font-size: 1.5rem;
  cursor: pointer;
  line-height: 1;
  padding: 0;
}

.replace-modal-close:hover {
  color: #F4F4F4;
}

.replace-modal-content h3 {
  margin: 0 0 1rem;
  font-family: futura_ptbold, sans-serif;
  color: #F4F4F4;
  font-size: 1.25rem;
}

.replace-modal-warning,
.replace-modal-existing,
.replace-modal-instruction {
  margin: 0 0 0.75rem;
  color: #F4F4F4;
  font-size: 14px;
}

.replace-modal-existing {
  color: #00DAD8;
  font-family: monospace;
}

.replace-modal-instruction strong {
  color: #00DAD8;
}

.replace-modal-content label {
  display: block;
  margin-bottom: 0.25rem;
  font-size: 12px;
  color: #C9CCF0;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.replace-confirm-input {
  width: 100%;
  padding: 10px 12px;
  font-size: 15px;
  font-family: monospace, sans-serif;
  color: #F4F4F4;
  background: rgba(244, 244, 244, 0.08);
  border: 1px solid rgba(244, 244, 244, 0.2);
  border-radius: 6px;
  margin-bottom: 1.25rem;
  box-sizing: border-box;
}

.replace-confirm-input:focus {
  outline: none;
  border-color: #00DAD8;
}

.replace-modal-buttons {
  display: flex;
  gap: 12px;
  justify-content: flex-end;
}

.replace-modal-cancel,
.replace-modal-submit {
  padding: 10px 20px;
  font-family: futura_ptbold, sans-serif;
  font-size: 13px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  border-radius: 6px;
  cursor: pointer;
  border: none;
}

.replace-modal-cancel {
  background: rgba(244, 244, 244, 0.15);
  color: #F4F4F4;
}

.replace-modal-cancel:hover {
  background: rgba(244, 244, 244, 0.25);
}

.replace-modal-submit {
  background: #CF23CA;
  color: #F4F4F4;
}

.replace-modal-submit:hover:not(:disabled) {
  background: #e030d8;
}

.replace-modal-submit:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

/* ===== Tournament Settings: drag-and-drop reorder ===== */
.tournament-sort-table .tournament-drag-col {
  width: 32px;
  padding: 8px;
  vertical-align: middle;
  border: 1px solid #F4F4F4;
}

.tournament-drag-handle {
  cursor: grab;
  color: rgba(244, 244, 244, 0.6);
  font-size: 14px;
  user-select: none;
  display: inline-block;
}

.tournament-drag-handle:hover {
  color: #00DAD8;
}

.tournament-drag-handle:active {
  cursor: grabbing;
}

.tournament-row.tournament-dragging {
  opacity: 0.5;
}

.tournament-row.tournament-drop-before .tournament-drag-col {
  box-shadow: inset 0 3px 0 0 #00DAD8;
}

.tournament-row.tournament-drop-after .tournament-drag-col {
  box-shadow: inset 0 -3px 0 0 #00DAD8;
}
