/* Arkansas High School Football History – Directory Styles */
#arkfb-root {
  font-family: 'Segoe UI', Arial, sans-serif;
  color: #212121;
  background: #fff;
  font-size: 14px;
}
#arkfb-root * { box-sizing: border-box; margin: 0; padding: 0; }
#arkfb-root a { color: #2e7d32; text-decoration: none; cursor: pointer; }
#arkfb-root a:hover { text-decoration: underline; }

/* Header */
#arkfb-header { padding: 18px 20px 0; border-bottom: 2px solid #ddd; }
#arkfb-header h1 { font-size: 26px; font-weight: 700; color: #1a2744; margin-bottom: 10px; }
#arkfb-top-nav { display: flex; gap: 0; }
#arkfb-top-nav button {
  background: none; border: none; padding: 8px 18px; font-size: 14px; cursor: pointer;
  color: #555; border-bottom: 3px solid transparent; font-weight: 500;
}
#arkfb-top-nav button.active { color: #1a2744; font-weight: 700; border-bottom-color: #1a2744; }
#arkfb-top-nav button:hover { color: #1565c0; }

/* Content area */
#arkfb-content { padding: 20px; }

/* Loading */
#arkfb-loading { padding: 60px 20px; text-align: center; color: #555; font-size: 16px; }
#arkfb-loading .arkfb-spinner {
  width: 40px; height: 40px; border: 4px solid #e0e0e0;
  border-top-color: #1976d2; border-radius: 50%;
  animation: arkfb-spin 0.8s linear infinite; margin: 0 auto 16px;
}
@keyframes arkfb-spin { to { transform: rotate(360deg); } }

/* Error */
#arkfb-error { background: #fff3e0; border: 1px solid #ff9800; padding: 16px; border-radius: 4px; margin: 20px 0; display: none; }

/* Page titles */
.arkfb-page-title { font-size: 24px; font-weight: 700; color: #1a2744; margin-bottom: 4px; }
.arkfb-subtitle { color: #555; font-size: 13px; margin-bottom: 16px; }

/* Tab nav */
.arkfb-tab-nav { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 18px; align-items: center; }
.arkfb-refresh-btn {
  background: #1976d2; color: #fff; border: none; border-radius: 4px;
  width: 32px; height: 32px; font-size: 16px; cursor: pointer;
  display: flex; align-items: center; justify-content: center;
}
.arkfb-tab-btn {
  background: #1976d2; color: #fff; border: none; border-radius: 4px;
  padding: 6px 14px; font-size: 13px; cursor: pointer; font-weight: 500;
}
.arkfb-tab-btn:hover { background: #1a2744; }
.arkfb-tab-btn.active { background: #1a2744; }
.arkfb-tab-btn::before { content: '▶ '; font-size: 9px; }

/* Search */
.arkfb-search { margin-bottom: 14px; }
.arkfb-search input {
  border: 1px solid #e0e0e0; padding: 6px 10px; border-radius: 4px;
  font-size: 13px; width: 240px; color: #212121; font-family: inherit;
}
.arkfb-search input:focus { outline: none; border-color: #1976d2; }

/* Tables */
#arkfb-root table { border-collapse: collapse; width: 100%; }
#arkfb-root th {
  background: #f5f5f5; border-bottom: 2px solid #ddd;
  padding: 7px 10px; text-align: left; font-size: 12px; font-weight: 600;
  color: #555; white-space: nowrap; user-select: none;
}
#arkfb-root th.sortable { cursor: pointer; }
#arkfb-root th.sortable:hover { color: #1a2744; }
#arkfb-root th .sort-icon { font-size: 10px; margin-left: 2px; opacity: 0.5; }
#arkfb-root th.sort-asc .sort-icon::after { content: '↑'; opacity: 1; color: #1a2744; }
#arkfb-root th.sort-desc .sort-icon::after { content: '↓'; opacity: 1; color: #1a2744; }
#arkfb-root th:not(.sort-asc):not(.sort-desc) .sort-icon::after { content: '↕'; }
#arkfb-root td { padding: 6px 10px; border-bottom: 1px solid #ddd; vertical-align: middle; }
#arkfb-root tr:hover > td { background: #fafafa; }
#arkfb-root td.num { text-align: right; }

/* Expandable rows */
tr.arkfb-expandable { cursor: pointer; }
tr.arkfb-expandable td.arkfb-expand-cell::before {
  content: '▶'; font-size: 9px; color: #888; margin-right: 6px;
  display: inline-block; transition: transform 0.15s;
}
tr.arkfb-expandable.open td.arkfb-expand-cell::before { transform: rotate(90deg); }
tr.arkfb-detail td { background: #f5f5f5 !important; padding: 0; }
tr.arkfb-detail { display: none; }
tr.arkfb-detail.open { display: table-row; }

/* Detail inner */
.arkfb-detail-inner { padding: 10px 20px 14px 30px; }
.arkfb-detail-inner table { background: #fff; }
.arkfb-detail-inner th { font-size: 11px; padding: 5px 8px; }
.arkfb-detail-inner td { font-size: 12px; padding: 4px 8px; }
.arkfb-detail-header { font-weight: 700; font-size: 12px; color: #1a2744; padding: 6px 0 4px; }

/* Result badges */
.arkfb-w { background: #e8f5e9; color: #2e7d32; font-weight: 700; padding: 2px 8px; border-radius: 3px; white-space: nowrap; }
.arkfb-l { background: #ffebee; color: #c62828; font-weight: 700; padding: 2px 8px; border-radius: 3px; white-space: nowrap; }
.arkfb-t { background: #fffde7; color: #f57f17; font-weight: 700; padding: 2px 8px; border-radius: 3px; white-space: nowrap; }

/* Badges */
.arkfb-badge-gold { color: #b8860b; }
.arkfb-badge-blue { color: #1565c0; }
.arkfb-playoff-tag { font-size: 11px; color: #888; margin-left: 4px; }
.arkfb-playoff-champ { color: #b8860b; font-weight: 700; }

/* Breadcrumb */
.arkfb-breadcrumb { font-size: 12px; color: #888; margin-bottom: 10px; }
.arkfb-breadcrumb a { color: #1565c0; cursor: pointer; }

/* Profile header */
.arkfb-profile-hdr { display: flex; justify-content: space-between; align-items: flex-start; }
.arkfb-profile-code { font-size: 20px; color: #bdbdbd; font-weight: 700; }

/* No data */
.arkfb-no-data { padding: 20px; color: #888; font-style: italic; }

/* Overflow scroll wrapper */
.arkfb-table-wrap { overflow-x: auto; }

@media (max-width: 768px) {
  #arkfb-content { padding: 12px; }
  .arkfb-hide-mobile { display: none !important; }
  .arkfb-search input { width: 100%; }
}

/* Class/Conference filter bar */
.arkfb-filter-bar { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; margin-bottom: 14px; }
.arkfb-filter-bar select {
  border: 1px solid #e0e0e0; padding: 6px 10px; border-radius: 4px;
  font-size: 13px; color: #212121; background: #fff; cursor: pointer;
  font-family: inherit;
}
.arkfb-filter-bar select:focus { outline: none; border-color: #1976d2; }
.arkfb-clear-btn {
  background: #f5f5f5; border: 1px solid #e0e0e0; border-radius: 4px;
  padding: 6px 12px; font-size: 12px; cursor: pointer; color: #555;
}
.arkfb-clear-btn:hover { background: #ffebee; color: #c62828; border-color: #f44336; }

/* Class tags */
.arkfb-class-tag {
  display: inline-block; font-size: 11px; font-weight: 700; padding: 2px 6px;
  border-radius: 3px; letter-spacing: 0.3px;
}
.arkfb-cls-7A  { background: #1a237e; color: #fff; }
.arkfb-cls-6A  { background: #1565c0; color: #fff; }
.arkfb-cls-5A  { background: #2e7d32; color: #fff; }
.arkfb-cls-4A  { background: #e65100; color: #fff; }
.arkfb-cls-3A  { background: #6a1b9a; color: #fff; }
.arkfb-cls-2A  { background: #558b2f; color: #fff; }
.arkfb-cls-8MAN { background: #4e342e; color: #fff; }

/* Conference tag on profile */
.arkfb-conf-tag {
  display: inline-block; font-size: 12px; font-weight: 600; padding: 2px 8px;
  border-radius: 3px; background: #f5f5f5; color: #555; border: 1px solid #e0e0e0;
  margin-left: 6px;
}
td.center { text-align: center; }

/* Extra info section (All State / Super Team / Asst Coaches) */
.arkfb-extra-section {
  display: flex; flex-wrap: wrap; gap: 6px; align-items: flex-start;
  margin-bottom: 10px; padding: 6px 0;
}
.arkfb-extra-btn {
  font-size: 11px; font-weight: 700; padding: 3px 10px; border-radius: 12px;
  border: none; cursor: pointer; letter-spacing: 0.3px; transition: opacity 0.15s;
}
.arkfb-extra-btn:hover { opacity: 0.85; }
.arkfb-btn-as          { background: #1565c0; color: #fff; }
.arkfb-btn-as.open     { background: #0d47a1; }
.arkfb-btn-st          { background: #b8860b; color: #fff; }
.arkfb-btn-st.open     { background: #7b5900; }
.arkfb-btn-ac          { background: #37474f; color: #fff; }
.arkfb-btn-ac.open     { background: #1c313a; }

/* Player list dropdowns */
.arkfb-player-list {
  width: 100%; display: flex; flex-wrap: wrap; gap: 6px;
  padding: 8px 10px; background: #e3f0ff; border-radius: 6px;
  margin-top: 2px; margin-bottom: 4px;
}
.arkfb-player-list-st  { background: #fff8e1; }
.arkfb-player-list-ac  { background: #eceff1; }

.arkfb-player-item {
  display: inline-flex; align-items: center; gap: 4px;
  background: #fff; border-radius: 4px; padding: 2px 8px;
  font-size: 12px; border: 1px solid #ddd; white-space: nowrap;
}
.arkfb-pos {
  font-size: 10px; font-weight: 700; color: #1565c0;
  background: #e3f0ff; padding: 1px 4px; border-radius: 3px;
}
.arkfb-pos-st { color: #7b5900; background: #fff8e1; }
