/* =============================================================================
   delta_stable_entries.css — Entries page styled to match stable list
   ============================================================================= */



/* ── Tabs ── */
.re_tabs {
  display: flex;
  gap: 0;
  border-bottom: 2px solid #c8c8a0;
  margin-bottom: 0;
  margin-top: 12px;
}

.re_tab {
  padding: 8px 18px;
  font-size: 13px;
  font-weight: 600;
  color: #4a5568;
  background: #f0f0e0;
  border: 1px solid #c8c8a0;
  border-bottom: none;
  cursor: pointer;
  text-decoration: none;
  border-radius: 4px 4px 0 0;
  margin-right: 3px;
}

.re_tab:hover {
  background: #e0e0c8;
  color: #1e293b;
}

.re_tab_active {
  background: #fff;
  color: #1e293b;
  border-bottom: 2px solid #fff;
  margin-bottom: -2px;
}

/* ── Table wrapper ── */


.re_empty {
  padding: 20px;
  color: #64748b;
  font-style: italic;
}

/* ── Table ── */
.re_table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13px;
  background-color: #fff;
}

.re_table_wrapper {
  width: 100% !important;
  max-width: 100% !important;
  display: block;
  overflow-x: auto;
  box-sizing: border-box;
}

.re_page_container {
  width: 100% !important;
  max-width: 100% !important;
  display: block;
  box-sizing: border-box;
}

.re_table thead tr {
  background-color: #E8E8D0;
}

.re_table th {
  padding: 8px 6px;
  text-align: left;
  font-size: 12px;
  font-weight: 700;
  color: #374151;
  border-bottom: 2px solid #c8c8a0;
  white-space: nowrap;
  overflow: hidden;
}

.re_table td {
  padding: 6px 6px;
  font-size: 12px;
  vertical-align: middle;
  border-bottom: 1px solid #e5e7eb;
}

.re_td_expand  { text-align: center; padding-left: 14px; white-space: nowrap; }
.re_td_horse   { font-weight: 600; }
.re_td_action  { text-align: center; white-space: nowrap; }
.re_td_trk, .re_td_type, .re_td_tag, .re_td_dist, .re_td_cond,
.re_td_sex, .re_td_age, .re_td_surf, .re_td_purse,
.re_td_ml, .re_td_cr, .re_td_num, .re_td_post { white-space: nowrap; }

/* ── Horse name ── */
.re_horse_name_wrap {
  display: flex;
  align-items: center;
}

.re_horse_name_wrap a {
  text-decoration: underline;
  text-decoration-color: #94a3b8;
  text-underline-offset: 2px;
  cursor: pointer;
  color: #166534;
}

.re_horse_name_wrap a:hover {
  text-decoration: none;
  background-color: #dbeafe;
  border-radius: 3px;
  padding: 0 2px;
}

.re_mine_tag {
  font-size: 0.85em;
  color: #6b7280;
  font-weight: 400;
}

.re_scratched {
  text-decoration: line-through;
  opacity: 0.6;
}

/* ── Expanded info — reuse stable list styles ── */
.re_expanded_info {
  display: none;
}

/* ── Alternating row colors ── */
.re_table tbody tr:nth-child(8n+1),
.re_table tbody tr:nth-child(8n+2),
.re_table tbody tr:nth-child(8n+3),
.re_table tbody tr:nth-child(8n+4) {
  background-color: #f8f8f2;
}

/* Force main_contain to establish full width for entries table */
#main_contain {
  width: 100%;
  display: block;
  box-sizing: border-box;
}

/* Responsive — hide less important cols; NEVER hide horse or track */
@media (max-width: 700px) {
  .re_th_tag,   .re_td_tag,
  .re_th_cond,  .re_td_cond,
  .re_th_purse, .re_td_purse,
  .re_th_cr,    .re_td_cr,
  .re_th_num,   .re_td_num   { display: none; }
}

@media (max-width: 520px) {
  .re_th_sex,  .re_td_sex,
  .re_th_age,  .re_td_age    { display: none; }
}

@media (max-width: 400px) {
  .re_th_surf, .re_td_surf,
  .re_th_dist, .re_td_dist   { display: none; }
}

/* Expanded info cards — wrap on small screens */
.re_expanded_info .stable_horse_list_expanded_row {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.re_expanded_info .stable_horse_list_expanded_item {
  min-width: 90px;
  flex: 1 1 90px;
}

/* ── Scratch card ── */
.re_scratch_btn {
  display: inline-block;
  padding: 3px 10px;
  background: #7c3aed;
  color: #fff;
  border-radius: 4px;
  font-size: 11px;
  font-weight: 600;
  cursor: pointer;
}
.re_scratch_btn:hover { background: #6d28d9; }

.re_scratch_confirm {
  padding: 6px 10px;
  background: #fef3c7;
  border: 1px solid #fcd34d;
  border-radius: 4px;
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 12px;
  flex-wrap: wrap;
}

.re_scratch_confirm_msg { color: #92400e; font-weight: 500; }

.re_scratch_yes {
  padding: 3px 10px;
  background: #dc2626;
  color: #fff;
  border: none;
  border-radius: 4px;
  font-size: 11px;
  font-weight: 600;
  cursor: pointer;
}
.re_scratch_yes:hover { background: #b91c1c; }

.re_scratch_no {
  padding: 3px 10px;
  background: #64748b;
  color: #fff;
  border: none;
  border-radius: 4px;
  font-size: 11px;
  font-weight: 600;
  cursor: pointer;
}
.re_scratch_no:hover { background: #475569; }

/* ── Claims page column widths ── */
.claims_th_note   { width: 50px; }
.claims_th_horse  { width: auto; min-width: 100px; }
.claims_th_wnr    { width: 30px; }
.claims_th_trk    { width: 36px; }
.claims_th_type   { width: 36px; }
.claims_th_tag    { width: 60px; }
.claims_th_dist   { width: 40px; }
.claims_th_sex    { width: 26px; }
.claims_th_age    { width: 30px; }
.claims_th_surf   { width: 44px; }
.claims_th_date   { width: 64px; }
.claims_th_num    { width: 20px; }
.claims_th_action { width: 30px; }

.claims_td_horse { font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.claims_td_action { text-align: center; }

@media (max-width: 640px) {
  .claims_th_tag,  .claims_td_tag,
  .claims_th_dist, .claims_td_dist,
  .claims_th_sex,  .claims_td_sex,
  .claims_th_age,  .claims_td_age  { display: none; }
}
