/* ─── Dazzling Fight Operations – Master Stylesheet ──────────────── */
:root {
  --navy-900: #0a0f17;
  --navy-800: #0f1923;
  --navy-700: #131e2b;
  --navy-600: #172638;
  --navy-500: #1e3250;
  --navy-400: #2a4a6b;
  --navy-300: #3d6a8c;
  --cyan-500: #00d4ff;
  --cyan-400: #2edcff;
  --cyan-300: #70e8ff;
  --cyan-100: #d6f9ff;
  --green-500: #10b981;
  --green-100: #d1fae5;
  --yellow-500: #f59e0b;
  --yellow-100: #fef3c7;
  --red-500: #ef4444;
  --red-100: #fee2e2;
  --blue-500: #3b82f6;
  --gray-50: #f9fafb;
  --gray-100: #f3f4f6;
  --gray-200: #e5e7eb;
  --gray-300: #d1d5db;
  --gray-400: #9ca3af;
  --gray-500: #6b7280;
  --gray-600: #4b5563;
  --gray-700: #374151;
  --white: #ffffff;
  --sidebar-width: 250px;
  --radius-sm: 6px;
  --radius-md: 10px;
  --radius-lg: 16px;
  --shadow-sm: 0 1px 2px rgba(0,0,0,0.05);
  --shadow-md: 0 4px 12px rgba(0,0,0,0.08);
  --shadow-lg: 0 8px 30px rgba(0,0,0,0.12);
  --font: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
}

/* ─── Reset ──────────────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { font-size: 15px; scroll-behavior: smooth; }
body {
  font-family: var(--font);
  color: var(--navy-700);
  line-height: 1.6;
  background: var(--gray-100);
  -webkit-font-smoothing: antialiased;
}
a { color: var(--cyan-500); text-decoration: none; }
a:hover { color: var(--navy-400); }
img { max-width: 100%; display: block; }
button { cursor: pointer; font-family: var(--font); }
input, textarea, select { font-family: var(--font); }

/* ─── Auth Layout ────────────────────────────────────────────────── */
.auth-layout {
  background: var(--navy-900);
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
}
.login-page { width: 100%; padding: 20px; display: flex; justify-content: center; }
.login-card {
  width: 100%; max-width: 420px;
  background: var(--navy-800);
  border: 1px solid var(--navy-600);
  border-radius: var(--radius-lg);
  padding: 40px 32px;
  box-shadow: 0 20px 60px rgba(0,0,0,0.3);
}
.login-header { text-align: center; margin-bottom: 32px; }
.login-logo { margin-bottom: 16px; }
.logo-diamond {
  display: inline-block;
  width: 48px; height: 48px;
  background: linear-gradient(135deg, var(--cyan-500), var(--cyan-300));
  clip-path: polygon(50% 0%, 100% 50%, 50% 100%, 0% 50%);
  box-shadow: 0 0 30px rgba(0,212,255,0.3);
}
.logo-diamond.large { width: 64px; height: 64px; }
.login-header h1 {
  color: var(--white);
  font-size: 1.5rem;
  font-weight: 800;
  letter-spacing: -0.03em;
  line-height: 1.15;
}
.login-subtitle {
  color: var(--navy-300);
  font-size: 0.85rem;
  margin-top: 6px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
.login-form { display: grid; gap: 16px; }
.login-form .field { display: grid; gap: 6px; }
.login-form label {
  color: var(--gray-300);
  font-size: 0.82rem;
  font-weight: 600;
}
.login-form .input {
  width: 100%; padding: 11px 14px;
  background: var(--navy-700);
  border: 1px solid var(--navy-500);
  border-radius: var(--radius-sm);
  color: var(--white);
  font-size: 0.95rem;
  outline: none;
  transition: border-color 0.2s;
}
.login-form .input:focus { border-color: var(--cyan-500); box-shadow: 0 0 0 3px rgba(0,212,255,0.1); }
.field-error { color: var(--red-500); font-size: 0.78rem; }
.demo-credentials {
  margin-top: 20px;
  padding: 14px;
  background: var(--navy-700);
  border: 1px dashed var(--navy-500);
  border-radius: var(--radius-sm);
  font-size: 0.82rem;
  color: var(--gray-300);
}
.demo-credentials code {
  color: var(--cyan-300);
  background: var(--navy-800);
  padding: 2px 6px;
  border-radius: 3px;
  font-size: 0.85rem;
}
.login-footer-notice {
  margin-top: 20px;
  font-size: 0.7rem;
  color: var(--gray-500);
  text-align: center;
  line-height: 1.4;
}

/* ─── Sidebar Layout ─────────────────────────────────────────────── */
.sidebar-layout { display: flex; min-height: 100vh; }
.sidebar {
  position: fixed; top: 0; left: 0;
  width: var(--sidebar-width); height: 100vh;
  background: var(--navy-900);
  border-right: 1px solid var(--navy-700);
  display: flex; flex-direction: column;
  z-index: 100;
  overflow-y: auto;
  transition: transform 0.25s ease;
}
.sidebar-brand {
  padding: 20px 20px 12px;
  border-bottom: 1px solid var(--navy-700);
}
.sidebar-logo {
  display: flex;
  align-items: center;
  gap: 12px;
}
.logo-text strong {
  display: block;
  color: var(--white);
  font-size: 1rem;
  font-weight: 800;
  letter-spacing: -0.02em;
}
.logo-text small {
  display: block;
  color: var(--navy-300);
  font-size: 0.65rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  margin-top: 2px;
}
.sidebar-subtitle {
  padding: 8px 20px;
  color: var(--navy-400);
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  border-bottom: 1px solid var(--navy-700);
}
.sidebar-nav {
  list-style: none;
  flex: 1;
  padding: 8px 0;
}
.sidebar-nav li { margin: 1px 0; }
.sidebar-nav li a {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 20px;
  color: var(--gray-400);
  font-size: 0.88rem;
  font-weight: 500;
  transition: all 0.15s;
  border-left: 3px solid transparent;
}
.sidebar-nav li a:hover {
  color: var(--white);
  background: var(--navy-700);
}
.sidebar-nav li a.active {
  color: var(--cyan-500);
  background: rgba(0,212,255,0.06);
  border-left-color: var(--cyan-500);
}
.nav-icon { font-size: 0.7rem; opacity: 0.5; width: 16px; text-align: center; }
.sidebar-nav li a.active .nav-icon { opacity: 1; color: var(--cyan-500); }
.sidebar-footer {
  padding: 12px 20px;
  border-top: 1px solid var(--navy-700);
}
.demo-notice {
  display: block;
  font-size: 0.65rem;
  color: var(--yellow-500);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-weight: 600;
}

/* ─── Main Content ───────────────────────────────────────────────── */
.main-content {
  margin-left: var(--sidebar-width);
  flex: 1;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}
.top-bar {
  position: sticky; top: 0;
  z-index: 50;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 28px;
  background: var(--white);
  border-bottom: 1px solid var(--gray-200);
  min-height: 56px;
}
.sidebar-toggle {
  display: none;
  background: none;
  border: none;
  color: var(--gray-600);
  padding: 4px;
}
.top-bar-right {
  display: flex;
  align-items: center;
  gap: 16px;
}
.top-bar-user {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--gray-600);
}
.top-bar-logout {
  font-size: 0.82rem;
  color: var(--gray-500);
  padding: 6px 12px;
  border: 1px solid var(--gray-200);
  border-radius: var(--radius-sm);
  transition: all 0.15s;
}
.top-bar-logout:hover {
  color: var(--red-500);
  border-color: var(--red-100);
  background: var(--red-100);
}
.content-area {
  flex: 1;
  padding: 24px 28px;
  max-width: 1400px;
}

/* ─── Flash Messages ─────────────────────────────────────────────── */
.flash-container { margin-bottom: 16px; }
.alert {
  padding: 12px 16px;
  border-radius: var(--radius-sm);
  font-size: 0.88rem;
  margin-bottom: 8px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}
.alert-success { background: var(--green-100); color: #065f46; border: 1px solid #a7f3d0; }
.alert-error { background: var(--red-100); color: #991b1b; border: 1px solid #fecaca; }
.alert-warning { background: var(--yellow-100); color: #92400e; border: 1px solid #fde68a; }
.alert-info { background: var(--cyan-100); color: #0e6b7a; border: 1px solid #a5f3fc; }
.alert-dismissible { align-items: flex-start; }
.alert-close {
  background: none; border: none;
  font-size: 1.2rem; line-height: 1;
  color: inherit; opacity: 0.6;
  padding: 0 4px;
}
.alert-close:hover { opacity: 1; }

/* ─── Buttons ────────────────────────────────────────────────────── */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 9px 18px;
  font-size: 0.88rem;
  font-weight: 600;
  border: 1px solid transparent;
  border-radius: var(--radius-sm);
  transition: all 0.15s;
  white-space: nowrap;
  line-height: 1.4;
}
.btn-primary {
  background: var(--cyan-500);
  color: var(--navy-900);
}
.btn-primary:hover { background: var(--cyan-400); color: var(--navy-900); }
.btn-secondary {
  background: var(--white);
  color: var(--gray-700);
  border-color: var(--gray-200);
}
.btn-secondary:hover { background: var(--gray-50); border-color: var(--gray-300); }
.btn-danger {
  background: var(--red-500);
  color: var(--white);
}
.btn-danger:hover { background: #dc2626; }
.btn-success {
  background: var(--green-500);
  color: var(--white);
}
.btn-success:hover { background: #059669; }
.btn-warning {
  background: var(--yellow-500);
  color: var(--white);
}
.btn-sm { padding: 6px 12px; font-size: 0.82rem; }
.btn-block { width: 100%; }

/* ─── Cards ──────────────────────────────────────────────────────── */
.card {
  background: var(--white);
  border: 1px solid var(--gray-200);
  border-radius: var(--radius-md);
  padding: 20px;
  box-shadow: var(--shadow-sm);
}
.card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 16px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--gray-100);
}
.card-title {
  font-size: 1rem;
  font-weight: 700;
  color: var(--navy-700);
}
.card-body { }
.card + .card { margin-top: 16px; }

/* ─── Stats Cards Grid ───────────────────────────────────────────── */
.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 16px;
  margin-bottom: 24px;
}
.stat-card {
  background: var(--white);
  border: 1px solid var(--gray-200);
  border-radius: var(--radius-md);
  padding: 18px 20px;
  box-shadow: var(--shadow-sm);
}
.stat-card .stat-label {
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--gray-500);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 4px;
}
.stat-card .stat-value {
  font-size: 1.8rem;
  font-weight: 800;
  color: var(--navy-700);
  line-height: 1.1;
}
.stat-card .stat-sub {
  font-size: 0.8rem;
  color: var(--gray-400);
  margin-top: 2px;
}
.stat-card.accent { border-left: 3px solid var(--cyan-500); }
.stat-card.warning { border-left: 3px solid var(--yellow-500); }
.stat-card.danger { border-left: 3px solid var(--red-500); }
.stat-card.success { border-left: 3px solid var(--green-500); }
.stat-card-link {
  display: block;
  text-decoration: none;
  color: inherit;
  transition: transform 0.18s ease, box-shadow 0.18s ease, border-color 0.18s ease;
}
.stat-card-link:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
  border-color: var(--cyan-300);
}
.row-highlight td {
  background: rgba(0, 212, 255, 0.08);
}

/* ─── Badges ─────────────────────────────────────────────────────── */
.badge {
  display: inline-flex;
  align-items: center;
  padding: 3px 10px;
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  border-radius: 999px;
  white-space: nowrap;
}
.badge-green { background: var(--green-100); color: #065f46; }
.badge-yellow { background: var(--yellow-100); color: #92400e; }
.badge-red { background: var(--red-100); color: #991b1b; }
.badge-blue { background: #dbeafe; color: #1e40af; }
.badge-gray { background: var(--gray-100); color: var(--gray-600); }
.badge-cyan { background: var(--cyan-100); color: #0e6b7a; }

/* ─── Tables ─────────────────────────────────────────────────────── */
.table-container { overflow-x: auto; }
table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.88rem;
}
thead th {
  background: var(--gray-50);
  color: var(--gray-600);
  font-weight: 600;
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  text-align: left;
  padding: 10px 14px;
  border-bottom: 2px solid var(--gray-200);
  white-space: nowrap;
}
tbody td {
  padding: 10px 14px;
  border-bottom: 1px solid var(--gray-100);
  vertical-align: middle;
}
tbody tr:hover { background: var(--gray-50); }
.table-actions { display: flex; gap: 6px; }

/* ─── Forms ──────────────────────────────────────────────────────── */
.form-card {
  background: var(--white);
  border: 1px solid var(--gray-200);
  border-radius: var(--radius-md);
  padding: 24px;
  box-shadow: var(--shadow-sm);
  max-width: 800px;
}
.form-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}
.form-grid .field-full { grid-column: 1 / -1; }
.form-group { display: grid; gap: 5px; }
.form-group label {
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--gray-600);
}
.form-control {
  width: 100%;
  padding: 9px 12px;
  font-size: 0.92rem;
  border: 1px solid var(--gray-200);
  border-radius: var(--radius-sm);
  background: var(--white);
  color: var(--navy-700);
  outline: none;
  transition: border-color 0.15s;
}
.form-control:focus { border-color: var(--cyan-500); box-shadow: 0 0 0 3px rgba(0,212,255,0.1); }
textarea.form-control { min-height: 100px; resize: vertical; }
select.form-control { appearance: auto; }
.form-hint { font-size: 0.75rem; color: var(--gray-400); }
.form-actions {
  display: flex;
  gap: 10px;
  margin-top: 20px;
  padding-top: 16px;
  border-top: 1px solid var(--gray-100);
}

/* ─── Filters Bar ────────────────────────────────────────────────── */
.filters-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
  margin-bottom: 16px;
  padding: 14px 16px;
  background: var(--white);
  border: 1px solid var(--gray-200);
  border-radius: var(--radius-md);
}
.filters-bar .form-control { width: auto; min-width: 150px; }
.filters-bar .search-input { min-width: 200px; flex: 1; }

/* ─── Page Header ────────────────────────────────────────────────── */
.page-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 20px;
  flex-wrap: wrap;
  gap: 12px;
}
.page-header h1 {
  font-size: 1.5rem;
  font-weight: 800;
  color: var(--navy-700);
  letter-spacing: -0.02em;
}
.page-header .page-subtitle {
  font-size: 0.85rem;
  color: var(--gray-500);
  margin-top: 2px;
}

/* ─── Grid Layouts ───────────────────────────────────────────────── */
.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.grid-3 { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 16px; }
@media (max-width: 900px) { .grid-2, .grid-3 { grid-template-columns: 1fr; } }

/* ─── Dashboard Specific ─────────────────────────────────────────── */
.dashboard-grid {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 16px;
}
@media (max-width: 1100px) { .dashboard-grid { grid-template-columns: 1fr; } }
.readiness-bar {
  display: flex;
  height: 28px;
  border-radius: 999px;
  overflow: hidden;
  background: var(--gray-200);
}
.readiness-segment {
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.65rem;
  font-weight: 700;
  color: var(--white);
  transition: width 0.5s ease;
}
.readiness-labels {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 8px;
  margin-top: 8px;
  font-size: 0.72rem;
  color: var(--gray-500);
}
.readiness-labels > div { text-align: center; }
.chart-container { position: relative; height: 200px; }

.task-list-compact { list-style: none; }
.task-list-compact li {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 0;
  border-bottom: 1px solid var(--gray-100);
  gap: 12px;
}
.task-list-compact li:last-child { border-bottom: none; }
.task-list-compact .task-title { font-size: 0.88rem; font-weight: 500; flex: 1; }
.task-list-compact .task-title.critical { color: var(--red-500); }
.task-list-compact .task-title.high { color: #d97706; }

.change-list-compact { list-style: none; }
.change-list-compact li {
  padding: 8px 0;
  border-bottom: 1px solid var(--gray-100);
  font-size: 0.85rem;
}
.change-list-compact li:last-child { border-bottom: none; }
.change-list-compact .change-title { font-weight: 600; }
.change-list-compact .change-meta { color: var(--gray-500); font-size: 0.78rem; }

.dashboard-section { margin-bottom: 24px; }
.dashboard-section h2 {
  font-size: 1rem;
  font-weight: 700;
  color: var(--navy-700);
  margin-bottom: 12px;
  letter-spacing: -0.01em;
}

/* ─── Fight Card ─────────────────────────────────────────────────── */
.fight-card-view {
  display: grid;
  gap: 12px;
}
.bout-card {
  background: var(--white);
  border: 1px solid var(--gray-200);
  border-radius: var(--radius-md);
  padding: 16px 20px;
  display: grid;
  grid-template-columns: 40px 3fr 60px 3fr;
  align-items: center;
  gap: 12px;
  box-shadow: var(--shadow-sm);
  transition: box-shadow 0.15s;
}
.bout-card:hover { box-shadow: var(--shadow-md); }
.bout-number {
  font-size: 1.1rem;
  font-weight: 800;
  color: var(--gray-400);
  text-align: center;
}
.bout-fighter { font-weight: 600; font-size: 0.95rem; }
.bout-fighter.red { color: #dc2626; }
.bout-fighter.blue { color: #2563eb; }
.bout-vs {
  text-align: center;
  font-weight: 800;
  font-size: 0.85rem;
  color: var(--gray-300);
  text-transform: uppercase;
}
.bout-meta { font-size: 0.78rem; color: var(--gray-500); grid-column: 1 / -1; margin-top: -8px; }

/* ─── Sponsor Cards ──────────────────────────────────────────────── */
.sponsor-cards {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 16px;
}
.sponsor-card {
  background: var(--white);
  border: 1px solid var(--gray-200);
  border-radius: var(--radius-md);
  padding: 20px;
  box-shadow: var(--shadow-sm);
}
.sponsor-card h3 { font-size: 1.1rem; font-weight: 700; margin-bottom: 4px; }
.sponsor-card .sponsor-package { color: var(--gray-500); font-size: 0.85rem; }
.sponsor-card .sponsor-value { font-size: 1.3rem; font-weight: 800; color: var(--green-500); margin: 8px 0; }
.sponsor-card .sponsor-progress { margin-top: 12px; }

/* ─── Kanban ─────────────────────────────────────────────────────── */
.kanban {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 12px;
  overflow-x: auto;
}
.kanban-column {
  background: var(--gray-50);
  border-radius: var(--radius-md);
  padding: 12px;
  min-width: 220px;
}
.kanban-column h3 {
  font-size: 0.82rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--gray-500);
  margin-bottom: 10px;
  padding-bottom: 8px;
  border-bottom: 2px solid var(--gray-200);
}
.kanban-item {
  background: var(--white);
  border: 1px solid var(--gray-200);
  border-radius: var(--radius-sm);
  padding: 12px;
  margin-bottom: 8px;
  box-shadow: var(--shadow-sm);
  font-size: 0.85rem;
}
.kanban-item .kanban-title { font-weight: 600; display: block; margin-bottom: 4px; }
.kanban-item .kanban-meta { font-size: 0.75rem; color: var(--gray-400); }
@media (max-width: 1000px) { .kanban { grid-template-columns: repeat(2, 1fr); } }

/* ─── Briefing ───────────────────────────────────────────────────── */
.briefing-card {
  background: var(--white);
  border: 1px solid var(--gray-200);
  border-radius: var(--radius-md);
  padding: 24px;
  max-width: 800px;
}
.briefing-header {
  padding-bottom: 16px;
  border-bottom: 2px solid var(--navy-700);
  margin-bottom: 20px;
}
.briefing-header h2 { font-size: 1.2rem; font-weight: 800; color: var(--navy-700); }
.briefing-header .briefing-meta {
  font-size: 0.78rem;
  color: var(--gray-500);
  margin-top: 4px;
}
.briefing-section { margin-bottom: 20px; }
.briefing-section h3 {
  font-size: 0.9rem;
  font-weight: 700;
  color: var(--navy-500);
  margin-bottom: 8px;
  padding-bottom: 4px;
  border-bottom: 1px solid var(--gray-100);
}
.briefing-section ul { padding-left: 18px; color: var(--gray-600); font-size: 0.88rem; }
.briefing-section li { margin: 4px 0; }
.briefing-actions { display: flex; gap: 10px; margin-top: 20px; padding-top: 16px; border-top: 1px solid var(--gray-100); }

/* ─── Detail Sidebar Layout ──────────────────────────────────────── */
.detail-layout {
  display: grid;
  grid-template-columns: 1fr 320px;
  gap: 20px;
  align-items: start;
}
@media (max-width: 900px) { .detail-layout { grid-template-columns: 1fr; } }
.detail-table {
  display: grid;
  gap: 12px;
  margin: 0;
}
.detail-table div {
  display: grid;
  grid-template-columns: 130px 1fr;
  gap: 12px;
  align-items: start;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--gray-100);
}
.detail-table dt {
  margin: 0;
  font-weight: 700;
  color: var(--gray-700);
}
.detail-table dd {
  margin: 0;
  color: var(--gray-600);
}
.suggestion-list {
  display: grid;
  gap: 12px;
  margin-top: 16px;
}
.selection-row {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  padding: 12px 14px;
  border: 1px solid var(--gray-200);
  border-radius: var(--radius-sm);
  background: var(--gray-50);
}
.selection-row input {
  margin-top: 3px;
}
.detail-sidebar {
  position: sticky;
  top: 80px;
}
.detail-sidebar .card + .card { margin-top: 12px; }

/* ─── Tabs ───────────────────────────────────────────────────────── */
.tabs {
  display: flex;
  gap: 0;
  border-bottom: 2px solid var(--gray-200);
  margin-bottom: 20px;
}
.tab {
  padding: 10px 20px;
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--gray-500);
  border-bottom: 2px solid transparent;
  margin-bottom: -2px;
  cursor: pointer;
  transition: all 0.15s;
  background: none;
}
.tab:hover { color: var(--navy-600); }
.tab.active {
  color: var(--cyan-500);
  border-bottom-color: var(--cyan-500);
}
.tab-content { display: none; }
.tab-content.active { display: block; }

/* ─── Error Page ─────────────────────────────────────────────────── */
.error-page {
  display: flex;
  justify-content: center;
  align-items: center;
  min-height: 60vh;
}
.error-card { text-align: center; }
.error-card h1 {
  font-size: 5rem;
  font-weight: 800;
  color: var(--gray-200);
  line-height: 1;
}
.error-card h2 { font-size: 1.5rem; color: var(--navy-700); margin: 8px 0; }
.error-card p { color: var(--gray-500); margin-bottom: 20px; }

/* ─── Search Overlay ─────────────────────────────────────────────── */
.search-overlay:not([hidden]) {
  position: fixed; top: 0; left: 0; right: 0; bottom: 0;
  background: rgba(0,0,0,0.4);
  z-index: 200;
  display: flex;
  justify-content: center;
  padding-top: 80px;
}
.search-overlay[hidden] {
  display: none;
}
.search-panel {
  background: var(--white);
  border-radius: var(--radius-md);
  width: 90%;
  max-width: 600px;
  max-height: 70vh;
  overflow-y: auto;
  box-shadow: var(--shadow-lg);
  padding: 20px;
}
.search-panel-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 12px;
  font-weight: 600;
  font-size: 1rem;
  color: var(--gray-700);
}
.search-close-btn {
  background: none;
  border: none;
  font-size: 1.5rem;
  cursor: pointer;
  color: var(--gray-500);
  line-height: 1;
  padding: 0 4px;
}
.search-close-btn:hover {
  color: var(--gray-900);
}
.search-panel input {
  width: 100%;
  padding: 12px 16px;
  font-size: 1rem;
  border: 2px solid var(--gray-200);
  border-radius: var(--radius-sm);
  outline: none;
  margin-bottom: 12px;
}
.search-panel input:focus { border-color: var(--cyan-500); }
.search-results { list-style: none; }
.search-results li { padding: 10px 12px; border-radius: var(--radius-sm); cursor: pointer; }
.search-results li:hover { background: var(--gray-50); }
.search-results li a { color: var(--navy-700); font-weight: 500; }
.search-results li .search-type { font-size: 0.72rem; color: var(--gray-400); margin-left: 8px; }

/* ─── Misc ───────────────────────────────────────────────────────── */
.empty-state {
  text-align: center;
  padding: 48px 20px;
  color: var(--gray-400);
}
.empty-state h3 { font-size: 1.1rem; color: var(--gray-500); margin-bottom: 8px; }
.empty-state p { font-size: 0.88rem; max-width: 400px; margin: 0 auto; }
.mb-0 { margin-bottom: 0; }
.mb-8 { margin-bottom: 8px; }
.mb-16 { margin-bottom: 16px; }
.mt-16 { margin-top: 16px; }
.text-muted { color: var(--gray-500); }
.text-sm { font-size: 0.82rem; }
.text-right { text-align: right; }
.flex { display: flex; }
.flex-between { display: flex; align-items: center; justify-content: space-between; }
.gap-8 { gap: 8px; }

/* ─── Print ──────────────────────────────────────────────────────── */
@media print {
  .sidebar, .top-bar, .btn, .table-actions, .filters-bar, .form-actions { display: none; }
  .main-content { margin-left: 0; }
  .content-area { padding: 0; }
  .card { border: 1px solid #ccc; box-shadow: none; break-inside: avoid; }
}

/* ─── Responsive ─────────────────────────────────────────────────── */
@media (max-width: 768px) {
  .sidebar { transform: translateX(-100%); }
  .sidebar.open { transform: translateX(0); }
  .sidebar-toggle { display: block; }
  .main-content { margin-left: 0; }
  .content-area { padding: 16px; }
  .page-header h1 { font-size: 1.2rem; }
  .stats-grid { grid-template-columns: repeat(2, 1fr); }
  .form-grid { grid-template-columns: 1fr; }
  .filters-bar { flex-direction: column; }
  .filters-bar .form-control { width: 100%; }
  .filters-bar .search-input { width: 100%; }
  .fight-card-view { gap: 8px; }
}
@media (max-width: 480px) {
  .stats-grid { grid-template-columns: 1fr; }
}
