/* ===== Admin only ===== */

/* Region selection modal */
#regionModal {
  position: fixed; inset: 0;
  background: rgba(0,0,0,.6);
  display: flex; align-items: center; justify-content: center;
}
#regionModal .box {
  background: #fff; padding: 20px; border-radius: 8px;
  max-width: 400px; width: 90%;
}
#regionModal ul { list-style: none; padding: 0; margin: 0; }
#regionModal li { margin: 10px 0; }
#regionModal a {
  display: block; padding: 10px 15px; background: #007BFF; color: #fff;
  border-radius: 4px; text-align: center; text-decoration: none;
}
#regionModal a:hover { background: #0056b3; }

/* Toolbar */
.toolbar { display:flex; gap:.75rem; align-items:center; flex-wrap:wrap; margin-bottom:1rem; }

/* Utilities */
.index-btn { margin-left: auto; }
.index-form, .index-form-2, .index-form-3,
.seasons-form, .seasons-form-2, .seasons-form-3,
.login-btn { display: inline; }

.key { color: #666; }
.badge-cell span { display: inline-block; }
.badge-wrap { margin-left: .5rem; }

/* Page specifics */
.logs table { background: #fff; } /* keep local table bg */

.actions { margin-top: 1rem; display: flex; gap: .5rem; } /* request details */
.request-div { display:flex; gap:.5rem; margin-top:.5rem; }

.table { width: 100%; border-collapse: collapse; }          /* seasons detail */
.table th, .table td { padding:.6rem; border-bottom:1px solid #eee; text-align:left; }
.form-inline { display:flex; gap:.5rem; flex-wrap:wrap; }
.season-detail-h3 { margin-top: 1rem; }

/* Theming parity stripe bound to vars */
:root {
  --admin-leftbar-color: var(--leftbar-color, #0a66c2);
  --admin-leftbar-width: var(--leftbar-width, 6px);
}

/* ===== Admin index: filters (single source of truth) ===== */
/* Apply to both legacy .filter-row and current .filters */
.filter-row,
.filters{
  display:flex;
  align-items:flex-end;     /* bottom align all controls */
  gap:.75rem;
  flex-wrap:wrap;
}

/* Labels wrap their control vertically, with no extra margins */
.filter-row label,
.filters label{
  display:flex;
  flex-direction:column;
  margin:0;
}

/* Normalize control heights and padding */
.filter-row select,
.filter-row input[type="text"],
.filter-row .btn,
.filters select,
.filters input[type="text"],
.filters .btn{
  height:38px;
  padding:.45rem .75rem;
  line-height:1;
}

/* Kill stray margins on the action button so it aligns */
.filter-row .btn,
.filters .btn{
  margin:0;
}

/* Search field width and behavior */
.filter-row input[name="q"],
.filters input[name="q"]{
  flex:1 1 650px;   /* allow grow/shrink; 650px base */
  max-width:50%;
  padding:.45rem .75rem; /* keep height normalised */
}

@media (max-width:760px){
  .filter-row input[name="q"],
  .filters input[name="q"]{
    flex:1 1 100%;
    max-width:100%;
  }
}
/* Column targets */
/* Narrow round number field; column hooks for styling */
.table .col-roundnum input[name="round_number"] { width: 6ch; }
.table .col-roundname input[name="round_name"] { max-width: 32rem; width: min(40vw, 32rem); }
.table .col-rounddate input[name="round_date"] { width: 16ch; }
/* Optional: align action buttons tightly */
.table .col-roundactions .btn { white-space: nowrap; }