:root {
  --primary-color: #3b82f6;
  --border-color: #e2e8f0;
  --hover-border-color: #94a3b8;
  --drop-target-bg: #f0f4ff;
}

.management-container {
  padding: 20px;
  max-width: 1200px;
  margin: 0 auto;
}

.error-message {
  color: #dc3545;
  background: #f8d7da;
  padding: 10px;
  margin: 10px 0;
  border-radius: 4px;
}

.management-form {
  background: #f5f5f5;
  padding: 20px;
  border-radius: 8px;
  margin-bottom: 30px;
}

.form-row {
  display: flex;
  gap: 15px;
  margin-bottom: 15px;
}

.form-group {
  flex: 1;
}

.form-group input {
  width: 98%;
  padding: 8px;
  border: 1px solid #ddd;
  border-radius: 4px;
}

.form-actions {
  display: flex;
  gap: 10px;
  margin-top: 15px;
}

.btn-primary {
  background: #007bff;
  color: white;
  border: none;
  padding: 8px 15px;
  border-radius: 4px;
  cursor: pointer;
}

.btn-secondary {
  background: #6c757d;
  color: white;
  border: none;
  padding: 8px 15px;
  border-radius: 4px;
  cursor: pointer;
}

.btn-danger {
  background: #dc3545;
  color: white;
  border: none;
  padding: 8px 15px;
  border-radius: 4px;
  cursor: pointer;
}

/* Add to your CSS */
.btn-danger:disabled {
  opacity: 0.5;
  cursor: not-allowed;
  background-color: #dc3545;
  /* Maintain red color but faded */
}

.btn-danger:disabled:hover {
  background-color: #dc3545;
  /* Prevent hover effect */
}

/* Modify Button Styles */
.btn-modify {
  display: inline-flex;
  align-items: center;
  padding: 0px 0px;
  background-color: rgb(236, 233, 226);
  border: 1px solid rgb(179, 172, 153);
  border-radius: 6px;
  color: #374151;
  font-size: 0.875rem;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  box-shadow: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
}

.btn-modify:disabled {
  opacity: 25%;
}

.btn-modify:hover {
  background-color: #f9fafb;
  border-color: #d1d5db;
  box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.1);
  transform: translateY(-1px);
}

.btn-modify:active {
  transform: translateY(0);
  box-shadow: none;
}

.btn-modify:focus {
  outline: none;
}

.icon-edit {
  width: 24px;
  height: 24px;
  fill: #d1ad0d;
  stroke: #493d05;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.icon-delete {
  width: 24px;
  height: 24px;
  fill: #e78484;
  stroke: #580f0f;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.btn-modify:hover .icon-edit {
  stroke: #1f2937;
}

/* Header Row Alignment */
.header-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1.5rem;
  gap: 1rem;
}

.header-row h2 {
  margin: 0;
  font-size: 1.5rem;
  color: #111827;
}

/* Judges list styles */
/* Search box styles */
.list-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1rem;
}

.search-box {
  flex: 0 1 300px;
}

.search-box input {
  width: 85%;
  padding: 8px 12px;
  border: 1px solid #e2e8f0;
  border-radius: 4px;
  font-size: 14px;
  transition: all 0.2s ease;
}

.search-box input:focus {
  outline: none;
  border-color: #94a3b8;
  box-shadow: 0 0 0 2px rgba(148, 163, 184, 0.1);
}

.styled-table {
  width: 100%;
  border-collapse: collapse;
}

.styled-table th,
.styled-table td {
  padding: 12px;
  text-align: left;
  border-bottom: 1px solid #ddd;
}

.styled-table th {
  background-color: #f8f9fa;
  font-weight: 600;
}

.judge-item {
  transition: background-color 0.2s ease;
}

.judge-item:hover {
  background-color: #f8f9fa;
}

.judge-item[draggable="true"] {
  cursor: grab;
}

.judge-item:active {
  cursor: grabbing;
}

/* Competition Specific Styles */
.competition-section {
  margin-bottom: 2rem;
}

.view-mode {
  background: #fff;
  padding: 1.5rem;
  border-radius: 8px;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.header-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1rem;
}

.details-row {
  display: flex;
  gap: 2rem;
}

.detail-item {
  display: flex;
  gap: 0.5rem;
  align-items: baseline;
}

.detail-label {
  font-weight: 600;
  color: #666;
}

/* Category Cards */
.category-card, .device-card {
  background: white;
  border-radius: 8px;
  padding: 1.5rem;
  margin-bottom: 1.5rem;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.category-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1rem;
}

/* Status Indicators */
.status, .register-ip {
  padding: 4px 8px;
  border-radius: 4px;
  font-size: 0.8rem;
  font-weight: 500;
}

.status {
  text-transform: uppercase;
}

.status.not-started {
  background-color: #f3f4f6;
  color: #6b7280;
  border: 1px solid #e5e7eb;
}

.status.in-progress {
  background-color: #fef3c7;
  color: #d97706;
  border: 1px solid #fcd34d;
}

.status.finalized {
  background-color: #dcfce7;
  color: #15803d;
  border: 1px solid #86efac;
}

.register-ip.offline {
  background-color: #dc3545;
  color: white;
  border: 1px solid #dd727e;
}

.register-ip.online {
  background-color: #dcfce7;
  color: #031108;
  border: 1px solid #86efac;
}

/* Judges Display */
.judges-container {
  margin-top: 1rem;
}

.judges-row {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
}

.judge-name {
  font-weight: 500;
  margin-bottom: 0.25rem;
  color: #FFFFFF;
}

.judge-box, .device-box {
  position: relative;
  background: #007bff;
  border-radius: 8px;
  padding: 1rem;
  min-width: 120px;
  min-height: 50px;
  text-align: center;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
  border: 1px solid #dee2e6;
  transition: all 0.2s ease;
  justify-content: center;
  /* Center content vertically */
  align-items: center;
  /* Center content horizontally */
}

.device-box:hover {
  cursor: pointer;
  transform: translateY(-2px);
}

.device-box.pending {
background: #fef3c7;
/*color: #d97706;
border: 1px solid #fcd34d;*/
}

.device-box.approved {
  background: #dcfce7;
/*color: #15803d;
border: 1px solid #86efac;*/
}

.judge-box.unassigned, .device-box.unassigned {
  background: #a1a3a5;
  opacity: 0.7;
}

/* Select element styling */
.judge-box select {
  width: 100%;
  height: 100%;
  padding: 12px 40px 12px 15px;
  /* Right padding for arrow space */
  border: none;
  background: transparent;
  appearance: none;
  font-size: 1rem;
  text-align: center;
  /* Center text horizontally */
  line-height: 1.5;
  /* Better text vertical alignment */
  cursor: pointer;
  transition: all 0.2s ease;
}

.judge-box.filled select {
  color: #ffffff;
}

/* Content alignment for drag zones */
.judge-box>* {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.judge-box:hover {
  transform: translateY(-2px);
  border-color: #94a3b8;
}

.judge-box.drop-target {
  border-color: #3b82f6;
  background-color: #f0f4ff;
}

/* Add this rule for text elements */
.judge-box > *:not(select) {
  color: #ffffff; /* Inherit parent color */
}

/* Update select element colors */
.judge-box select {
  color: #ffffff;
}

.judge-box select option {
  color: #000000; /* Dark text for dropdown options */
}

.form-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 1.5rem;
  align-items: start;
}

.form-group {
  display: grid;
  grid-template-columns: max-content 1fr;
  align-items: center;
  gap: 0.75rem;
}

/* Responsive adjustments */
@media (min-width: 768px) {
  .form-grid {
    grid-template-columns: repeat(3, 1fr);
  }

  .form-group {
    grid-template-columns: 1fr;
    grid-template-rows: max-content 1fr;
  }

  .form-group label {
    margin-bottom: 0.5rem;
  }
}

.btn-small {
  align-self: flex-end;
  padding: 0.1rem 0.4rem;
  font-size: 0.8rem;
  line-height: 1;
  border-radius: 50%;
  position: absolute;
  top: -8px;
  right: -8px;
}

.btn-danger {
  background: #dc3545;
  color: white;
  border: none;
}

.btn-danger:hover {
  background: #bb2d3b;
}

/* Position number styling */
.judge-position {
  font-size: 0.8rem;
  color: #e9ecef;
  margin-top: 0.25rem;
}

.device-position {
  font-size: 0.8rem;
  color: #1e1e1f;
  margin-top: 0.25rem;
}

/** Navigation **/
.navigation {
  background: #2585d8;
  padding: 1rem;
  border-bottom: 2px solid #dee2e6;
  margin-bottom: 2rem;
}

.nav-logo {
  height: 40px;
  width: auto;
  display: block;
}

.nav-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  align-items: center;
  gap: 1.5rem;
}

.nav-link {
  text-decoration: none;
  color: #e9ecef;
  font-weight: 500;
  padding: 0.5rem 1rem;
  border-radius: 6px;
  transition: all 0.2s ease;
  border: 1px solid transparent;
}

.nav-link:hover {
  background: #e9ecef;
  color: #212529;
}

.nav-link.active {
  background: #252BD9;
  color: white;
  border-color: #007bff;
}

.nav-link.active:hover {
  background: #D97925;
}

/** Pairs **/
.management-card {
  background: white;
  padding: 2rem;
  border-radius: 8px;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.form-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
  margin-bottom: 2rem;
}

.data-table-container {
  margin-top: 2rem;
  overflow-x: auto;
}

.data-table {
  width: 100%;
  border-collapse: collapse;
}

.data-table th,
.data-table td {
  padding: 0.4rem;
  text-align: left;
  border-bottom: 1px solid #eee;
}

.data-table tr:hover {
  background-color: #f9f9f9;
}

.placeholder {
  color: #666;
  text-align: center;
  padding: 1rem;
}

/** Scoresheet **/
.scoresheet-container {
  width: 210mm;
  /* A4 width */
  min-height: 297mm;
  /* A4 height */
  margin: 0px auto;
  padding: 20px;
  background: white;
  box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
  box-sizing: border-box;
}

.tori-uke-line,
.competition-info-line {
  display: flex;
  justify-content: space-between;
  margin-bottom: 10px;
}

.competitor-info,
.competition-name {
  flex: 0 0 48%;
  text-align: center;
}

.competition-logo {
  flex: 0 0 24%;
}

.competition-details {
  flex: 0 0 24%;
  text-align: right;
}

.competition-info {
  padding: 1rem;
  flex: 0 0 48%;
  text-align: right;
}

.technique-table,
.scores-table,
.results-table {
  width: 100%;
  border-collapse: collapse;
  margin: 10px 0;
  margin-top: 20px;
}

.technique-table td,
.technique-table th,
.scores-table td,
.scores-table th,
.results-table td,
.results-table th {
  border: 1px solid #ddd;
  padding: 8px;
  text-align: center;
}

/* 🔲 Fix outlines showing on top */
.technique-row.pending-changes {
  outline: 2px solid red;
  position: relative;
  z-index: 1;
}

.technique-row.unscored-technique {
  outline: 2px solid #ff0000;
  background-color: #ffe6e6 !important;
  position: relative;
  z-index: 1;
}

.group-break-row td {
  padding: 0;
  height: 3px;
  background: black;
  border: none;
}

.group-label {
  position: absolute;
  top: -8px;
  left: 80px;
  background: white;
  padding: 2px 6px;
  border-radius: 999px;
  border: 1px solid black;
  font-weight: bold;
  font-size: 0.85em;
  line-height: 1;
  z-index: 2;
}

.group-label-wrapper {
  position: relative;
  width: 100%;
  height: 100%;
}

.judge-info,
.competitor-info {
  margin: 10px 0;
}

/* Allow multiple classes on a row */
.technique-row.pending-changes.unscored-technique {
  outline: 2px dashed #ff0000;
}

.unscored-technique td {
  position: relative;
}

.unscored-technique::after {
  content: "N/A";
  position: absolute;
  right: 10px;
  color: #ff0000;
  font-size: 0.8em;
  font-weight: bold;
}

.scoresheet-footer {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-top: 8px;
}

.lock-controls {
  display: flex;
  align-items: center;
}

.lock-icon {
  font-size: 1.6em;
  margin-left: 0rem;
}

.total-score {
  font-weight: bold;
  font-size: 1.2em;
  margin: 0px;
}

/* Toggle switch */
.switch {
  position: relative;
  display: inline-block;
  width: 60px;
  height: 34px;
  margin-right: 1rem;
}

.switch input {
  opacity: 0;
  width: 0;
  height: 0;
}

.slider {
  position: absolute;
  cursor: pointer;
  inset: 0;
  background-color: #ccc;
  border-radius: 34px;
  transition: 0.4s;
}

.slider:before {
  position: absolute;
  content: "";
  height: 26px;
  width: 26px;
  left: 4px;
  bottom: 4px;
  background-color: white;
  transition: 0.4s;
  border-radius: 50%;
}

input:checked+.slider {
  background-color: #2196f3;
}

input:checked+.slider:before {
  transform: translateX(26px);
}

/* Scoring overview */
.scoring-overview {
  width: 80%;
  /* A4 width */
  margin: 0px auto;
  padding: 20px;
  background: white;
  box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
  box-sizing: border-box;
}

.kata-section {
  margin-bottom: 40px;
  page-break-inside: avoid;
}

.scoring-table {
  width: 100%;
  border-collapse: collapse;
  margin: 15px 0;
}

.scoring-table th,
.scoring-table td {
  border: 1px solid #ddd;
  padding: 8px;
  text-align: center;
}

.scoring-table th {
  background-color: #f5f5f5;
  min-width: 40px;
}

.score-link {
  color: #2196F3;
  text-decoration: none;
  font-weight: bold;
}

.score-link:hover {
  text-decoration: underline;
}

.lock-indicator {
  margin-left: 5px;
  font-size: 0.8em;
}

.score-link.locked {
  color: #666;
}

.order-column {
  text-align: center;
  font-weight: bold;
  width: 50px;
}

.pair-column {
  min-width: 200px;
}

.competitor-info {
  margin: 3px 0;
  line-height: 1.3;
}

.competitor-info .name {
  font-weight: 500;
  font-size: 1.2em;
}

.competitor-info .club {
  font-size: 0.9em;
  color: #666;
}

/* Adjust table header alignment */
.scoring-table th {
  vertical-align: bottom;
}

.scoring-table th:first-child {
  width: 50px;
}

/* Scoresheet */
.pdf-button {
  margin: 2px;
  padding: 6px 12px;
  background: #007BFF;
  color: white;
  border: none;
  border-radius: 6px;
  cursor: pointer;
}

/* Media print directives */
@media print {
  body {
    margin: 0;
    padding: 0;
    overflow: visible !important;
    display: block !important;
    visibility: visible !important;
  }

  html, body {
    height: auto !important;
  }

  nav,
  header,
  footer {
    display: none !important;
  }

  .scoresheet-container {
    position: absolute;
    width: 210mm !important;
    max-height: 297mm !important;
    top: 0;
    left: 0;
    padding: 10mm;
    background: white;
    zoom:0.85;
    box-shadow: none;
    margin: 10mm;
    margin-top: 0;
  }

  .scoring-overview {
    padding: 0;
    margin: 10mm;
    width: 190mm;
    display: block !important;
    visibility: visible !important;
    height: auto !important;
    overflow: visible !important;
    page-break-after: always;
    box-shadow: none;
    font-size: 0.6rem;
  }

  .lock-controls {
    display: none !important;
  }

  .score-link {
    color: black;
    text-decoration: none;
  }

  .pdf-button,
  .lock-controls,
  .status-icon-cell {
    display: none !important;
  }

  .technique-table,
  .scores-table {
    border-collapse: collapse;
    width: 100%;
  }

  .technique-table th,
  .technique-table td,
  .scores-table td,
  .scores-table th {
    border: 1px solid black !important;
    padding: 4px;
  }
}

/* Table row styling */
.technique-table tbody tr:nth-child(odd),
.scores-table tbody tr:nth-child(odd) {
  background-color: #fffacd;
  /* Light yellow */
}

.technique-table tbody tr:nth-child(even),
.scores-table tbody tr:nth-child(even) {
  background-color: white;
}

/* Mistake columns - default (odd rows) */
.technique-table tbody tr:nth-child(odd) td:nth-child(3) {
  background-color: #fffacd;
}

/* Small */
.technique-table tbody tr:nth-child(odd) td:nth-child(4) {
  background-color: #ccffcc;
}

/* Medium */
.technique-table tbody tr:nth-child(odd) td:nth-child(5) {
  background-color: #e0e0e0;
}

/* Big */
.technique-table tbody tr:nth-child(odd) .bonus-cell {
  background-color: #cce5ff;
}

/* Bonus */
.technique-table tbody tr:nth-child(odd) td:nth-child(7) {
  background-color: #ffc8c8;
}

/* Forgotten */

/* Mistake columns - lighter versions on even rows */
.technique-table tbody tr:nth-child(even) td:nth-child(3) {
  background-color: #fffbdd;
}

/* Pale yellow */
.technique-table tbody tr:nth-child(even) td:nth-child(4) {
  background-color: #e6ffe6;
}

/* Pale green */
.technique-table tbody tr:nth-child(even) td:nth-child(5) {
  background-color: #f2f2f2;
}

/* Pale gray */
.technique-table tbody tr:nth-child(even) .bonus-cell {
  background-color: #e6f2ff;
}

/* Pale blue */
.technique-table tbody tr:nth-child(even) td:nth-child(7) {
  background-color: #ffeaea;
}

/* Pale red */

/* Score columns */
.scores-table tbody tr:nth-child(odd) td:nth-child(1) {
  background-color: #e0e0e0;
}

/* Tech # */
.scores-table tbody tr:nth-child(even) td:nth-child(1) {
  background-color: #f2f2f2;
}

/* Tech # */
.scores-table tbody tr:nth-child(odd) td:nth-child(8) {
  background-color: #cce5ff;
}

/* Tech score */
.scores-table tbody tr:nth-child(even) td:nth-child(8) {
  background-color: #e6f2ff;
}

/* Tech score */
.scores-table tbody tr.group-break-row td:first-child {
  background-color: black !important;
}

/* Summary row styling */
tr.scores-header-row th {
  font-weight: bold;
  background-color: #f7b867 !important;
  border-top: 2px solid #999;
}

/* Summary row styling */
tr.summary-row td {
  font-weight: bold;
  background-color: #f7b867 !important;
  border-top: 2px solid #999;
}

tr.judges-list td {
  background-color: white !important;
}

/* Fix first column background for summary row */
.scores-table tbody tr.summary-row td:first-child {
  background-color: #e0e0e0 !important;
}

.scores-table tbody tr.summary-row td:last-child {
  background-color: #f3f027 !important;
}

/* Compact header */
.compact-header {
  text-align: center;
  margin-bottom: 1em;
}

.compact-header h1 {
  font-size: 1.5em;
  margin: 0.25em 0;
}

.compact-header h2 {
  font-size: 1.2em;
  margin: 0.2em 0;
}

.compact-header p,
.compact-header div {
  margin: 0.2em 0;
}

.status-icon-cell {
  width: 20px;
  padding: 4px;
  text-align: center;
  font-size: 1.1em;
}

.status-icon {
  user-select: none;
}

.unscored-icon {
  color: red;
}

.pending-icon {
  color: orange;
}

.pdf-hide {
  display: none !important;
}

/* Results */
.finalized-kata {
  border: 2px solid #4CAF50;
  background-color: #f8fff8;
}

.finalized-badge {
  background: #4CAF50;
  color: white;
  padding: 4px 8px;
  border-radius: 4px;
  font-size: 0.8em;
  margin-left: 12px;
}

.finalized-pair {
  background-color: #f0fff0;
}

.rank-badge {
  background: #2196F3;
  color: white;
  padding: 4px 8px;
  border-radius: 4px;
  display: inline-block;
  min-width: 30px;
  text-align: center;
  transition: transform 0.2s;
}

.mistakes-breakdown {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.final-score {
  font-weight: bold;
  font-size: 1.1em;
  color: #2196F3;
}

/* Medal colors */
.rank-gold {
  background: #FFD700 !important;
  color: #000 !important;
}

.rank-silver {
  background: #C0C0C0 !important;
  color: #000 !important;
}

.rank-bronze {
  background: #CD7F32 !important;
  color: #fff !important;
}

/* Play button */
.play-button {
  background: #4CAF50;
  border: none;
  border-radius: 50%;
  width: 32px;
  height: 32px;
  padding: 2px;
  cursor: pointer;
  transition: all 0.2s ease;
  display: flex;
  align-items: center;
  justify-content: center;
}

.play-button:hover {
  background: #45a049;
  transform: scale(1.1);
}

.play-button:disabled {
  background: #cccccc;
  cursor: not-allowed;
  transform: none;
}

.play-icon {
  width: 20px;
  height: 20px;
  color: white;
}

.loading-dots {
  color: white;
  font-weight: bold;
}

.current-indicator {
  color: #4CAF50;
  font-size: 0.9em;
  margin-left: 8px;
  font-weight: bold;
  animation: pulse 1.5s infinite;
}

@keyframes pulse {
  0% {
    opacity: 1;
  }

  50% {
    opacity: 0.5;
  }

  100% {
    opacity: 1;
  }
}

/* Stop button */
.stop-button {
  background: #ff4444;
  border: none;
  border-radius: 50%;
  width: 32px;
  height: 32px;
  padding: 2px;
  cursor: pointer;
  transition: all 0.2s ease;
  display: flex;
  align-items: center;
  justify-content: center;
}

.stop-button:hover {
  background: #cc0000;
  transform: scale(1.1);
}

.stop-button:disabled {
  background: #cccccc;
  cursor: not-allowed;
  transform: none;
}

.stop-icon {
  width: 20px;
  height: 20px;
  color: white;
}

.active-row {
  background: yellow;
}

.action-column {
  width: 40px;
  text-align: center;
  padding: 0;
}

.action-group {
  display: flex;
  justify-content: center;
  align-items: center;
}

/* Drag and drop styling */
tr.dragging {
  opacity: 0.5;
  background: #f8f8f8;
}

tr.drop-target {
  position: relative;
}

tr.drop-target::after {
  content: "";
  position: absolute;
  top: -2px;
  left: 0;
  right: 0;
  height: 2px;
  background: #2196F3;
}

tr:hover .drag-handle {
  cursor: grab;
  opacity: 1;
}

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

tr.finalized {
  background: #f5f5f5;
  opacity: 0.5;
}

/* Shuffle button styling */
.header-actions {
  display: flex;
  justify-content: center;
}

.shuffle-button {
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px;
  font-size: 1.8em;
  opacity: 0.6;
  transition: all 0.2s ease;
}

.shuffle-button:hover {
  opacity: 1;
  transform: rotate(-90deg);
}

.shuffle-button:disabled {
  opacity: 0.3;
  cursor: not-allowed;
}

/* Category drag and drop styles */
.category-card {
  position: relative;
  transition: transform 0.2s, box-shadow 0.2s;
  cursor: grab;
}

.category-card.dragging {
  opacity: 0.5;
  transform: scale(0.98);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.category-card.drop-target {
  border-top: 2px solid #2196F3;
}

.category-card:hover {
  opacity: 1;
  transform: translateY(-2px);
}

.category-card:active {
  cursor: grabbing;
}

tr[draggable] {
  cursor: grab;
}

tr[draggable]:hover {
  cursor: grab;
  transform: translateY(-2px);
}

.competitor-names-inline {
  display: flex;
  justify-content: center;
  gap: 4px;
  font-size: 1.2em;
  font-weight: bold;
  padding: 8px;
}

.tiny-mistakes {
  font-size: 0.6em;
  color: #777;
  margin-top: 2px;
  text-align: center;
}

.competition-details-container {
  display: flex;
  gap: 2rem;
  align-items: flex-start;
}

.logo-column {
  flex: 0 0 150px;
}

.details-column {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.header-row {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin-bottom: 0.5rem;
}

.details-content {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.competition-logo {
  width: 150px;
  height: 150px;
  object-fit: contain;
  border: 1px solid #ddd;
  border-radius: 8px;
  padding: 4px;
}

.detail-item {
  display: flex;
  align-items: baseline;
  gap: 0.75rem;
}

.detail-label {
  font-weight: 600;
  min-width: 80px;
  color: #444;
}

/* For the edit mode layout */
.management-form {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.form-group.logo-upload {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 1rem;
}

.logo-preview {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.logo-preview img {
  width: 100px;
  height: 100px;
  object-fit: contain;
  border: 1px solid #ddd;
}
