/* ── MY COLLEGES PAGE-SPECIFIC CSS ──────────────────────── */

/* ── BODY OVERRIDE ───────────────────────────────────────── */
/* my-colleges uses white background instead of #f4f4f2 */
body { background: #fff; }

/* ── MAIN ────────────────────────────────────────────────── */
#mainContent {
  flex: 1;
  padding: 32px 32px;
  overflow-y: auto;
  height: 100%;
  min-height: 0;
  display: flex;
  flex-direction: column;
}

.page-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 20px;
  flex-wrap: wrap;
  gap: 10px;
}

h2 {
  font-size: 13px;
  font-weight: 800;
  letter-spacing: .12em;
  text-transform: uppercase;
}
.page-header h2 {
  font-size: 24px;
  font-weight: 800;
  color: #1a1a1a;
  letter-spacing: normal;
  text-transform: none;
}

#statusBar {
  font-size: 12px;
  color: #888;
  min-height: 18px;
}

#removeCollegesBtn {
  display: none;
  align-items: center;
  gap: 6px;
  padding: 7px 14px;
  font-size: 13px;
  font-weight: 700;
  color: #fff;
  background: #e03e3e;
  border: none;
  border-radius: 6px;
  cursor: pointer;
  transition: background 0.15s;
  white-space: nowrap;
}
#removeCollegesBtn:hover { background: #c53030; }

/* ── UNI TABLE OVERRIDES ─────────────────────────────────── */
/* my-colleges has extra table features not in ranker */
.uni-table thead th { text-align: center; }
.uni-table td { text-align: center; }

.uni-table thead th.col-sorted { color: var(--tertiary); }

.uni-table tbody tr {
  cursor: grab;
}
.uni-table tbody tr:active { cursor: grabbing; }
.uni-table tbody tr:hover td.col-check,
.uni-table tbody tr:hover td.col-rank,
.uni-table tbody tr:hover td.col-name,
.uni-table tbody tr:hover td.col-category { background: #fafafa; }

/* col-name left position for my-colleges (different from ranker) */
.col-name {
  left: 76px;
}

.uni-table thead th.col-category { z-index: 12; }

.col-category {
  width: 136px;
  text-align: center;
  position: sticky;
  left: 296px;
  background: #fff;
  z-index: 2;
  box-shadow: 3px 0 6px -2px rgba(0,0,0,.06);
}
.category-select {
  appearance: none;
  border: none;
  border-radius: 20px;
  padding: 3px 10px;
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  outline: none;
  text-align: center;
  width: 100%;
}
.category-select.top-choice { background: #e8d5f5; color: #5a1a8a; }
.category-select.safety     { background: #d1f0d8; color: #1a6630; }
.category-select.target     { background: #fef3cd; color: #7a5500; }
.category-select.reach      { background: #fde0e0; color: #7a1a1a; }
.category-select.none       { background: #f0f0f0; color: #888; }

.category-badge {
  display: inline-block;
  border-radius: 20px;
  padding: 3px 10px;
  font-size: 12px;
  font-weight: 600;
  text-align: center;
  white-space: nowrap;
  transition: opacity 0.15s;
}
.category-badge:hover { opacity: 0.8; }
.category-badge.safety  { background: #d1f0d8; color: #1a6630; }
.category-badge.likely  { background: #d1e8f0; color: #1a5066; }
.category-badge.target  { background: #fef3cd; color: #7a5500; }
.category-badge.reach   { background: #fde0e0; color: #7a1a1a; }

.uni-table tbody tr.drag-over td { background: var(--neutral); box-shadow: inset 0 0 0 2px var(--primary); }
.uni-table tbody tr.dragging { opacity: 0.35; }

/* ── RANGE BAR ───────────────────────────────────────────── */
/* my-colleges uses #164B24; ranker uses var(--primary) */
.range-bar-fill { background: #164B24; }

/* ── CHECKBOX ACCENT ─────────────────────────────────────── */
/* my-colleges uses #1a1a1a; ranker uses var(--primary) */
.col-check input[type="checkbox"] {
  accent-color: #1a1a1a;
}

/* ── MODAL OVERRIDES ─────────────────────────────────────── */
/* my-colleges compare-section-divider has slightly different padding */
.compare-section-divider {
  padding: 20px 0 12px;
  border-top: 1px solid #f0f0f0;
  margin-top: 4px;
}
.compare-section-divider.first { border-top: none; padding-top: 16px; margin-top: 0; }
.compare-section-divider.no-pad-bottom { padding-bottom: 0; }

/* compare-back-btn has different padding in my-colleges */
.compare-back-btn {
  padding: 11px 22px;
  font-size: 15px;
}

/* #compareView has different styles in my-colleges */
#compareView { display: none; max-width: 960px; margin: 0 auto; }

/* ── STATE MSG & SPINNER ─────────────────────────────────── */
.state-msg { padding: 40px 0; text-align: center; color: #aaa; font-size: 14px; }
.spinner {
  display: inline-block;
  width: 28px;
  height: 28px;
  border: 3px solid #e5e5e5;
  border-top-color: var(--primary);
  border-radius: 50%;
  animation: spin .8s linear infinite;
  margin-bottom: 12px;
}

/* ── EMPTY STATE ─────────────────────────────────────────── */
.empty-state {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 80px 24px;
  text-align: center;
}
.empty-state-icon { font-size: 48px; margin-bottom: 16px; opacity: 0.4; }
.empty-state-title { font-size: 18px; font-weight: 700; color: #555; margin-bottom: 8px; }
.empty-state-desc { font-size: 14px; color: #aaa; line-height: 1.5; margin-bottom: 20px; }
.empty-state a {
  display: inline-block;
  padding: 10px 20px;
  background: var(--primary);
  color: #fff;
  border-radius: 8px;
  text-decoration: none;
  font-size: 13px;
  font-weight: 700;
}
.empty-state a:hover { background: var(--primary-dark); }

/* ── VIEW TOGGLE ─────────────────────────────────────────── */
/* my-colleges view-btn uses font-weight: 600 (ranker uses 500) */
.view-btn {
  font-weight: 600;
}
.view-btn:first-child { border-right: 1px solid #d0d0d0; }

/* ── MAP ─────────────────────────────────────────────────── */
#mapContainer {
  display: none;
  flex: 1;
  min-height: 0;
  border-radius: 8px;
  overflow: hidden;
  margin-top: 8px;
}
#map { width: 100%; height: 100%; }

/* ── MODAL EXTRA FIELDS ──────────────────────────────────── */
.modal-wiki a { display: inline-block; margin-top: 8px; font-size: 12px; color: var(--tertiary); text-decoration: none; }

/* ── RESPONSIVE ──────────────────────────────────────────── */
@media (max-width: 768px) {
  body { height: auto; overflow: visible; }
  #topHeader { flex-direction: column; align-items: flex-start; padding: 10px 16px 0; gap: 0; height: auto; }
  .top-nav { display: flex; flex: none; height: auto; align-items: center; overflow-x: auto; -webkit-overflow-scrolling: touch; scrollbar-width: none; width: 100%; justify-content: flex-start; }
  .top-nav::-webkit-scrollbar { display: none; }
  .top-nav-tab { font-size: 12px; padding: 8px 12px; white-space: nowrap; flex-shrink: 0; height: auto; border-bottom-width: 2px; }
  #mainContent { padding: 16px; height: auto; overflow-y: visible; }
  .modal-body-cols { grid-template-columns: 1fr; overflow-y: auto; }
  .modal-main { overflow-y: visible; }
  .modal-sidebar { border-left: none; border-top: 1px solid #f0f0f0; overflow-y: visible; }
}
