.game { --operation-strip-height: 50px; }
.operation-strip {
  display: flex;
  align-items: stretch;
  flex: 0 0 var(--operation-strip-height);
  min-width: 0;
  gap: 7px;
  padding: 4px 12px;
  border-bottom: 1px solid #597aab;
  background: linear-gradient(100deg,#162944,#131a32 64%,#24223d);
  box-shadow: inset 0 1px #a4e4fd25;
}
.operation-strip[hidden] { display: none; }
.operation-tab, .operation-list-row {
  min-width: 0;
  border: 1px solid #607eb1;
  border-radius: 8px;
  color: #f1f7ff;
  background: linear-gradient(105deg,#253c5e,#202544);
}
.operation-tab {
  flex: 1 1 0;
  display: grid;
  place-content: center;
  gap: 2px;
  padding: 2px 4px;
  line-height: 1.05;
  text-align: center;
}
.operation-tab strong { font-size: clamp(11px,3vw,14px); }
.operation-tab small { color: #bfcee9; font-size: 11px; }
.operation-tab[data-kind="research"] { border-color: #9e83cb; }
.operation-tab:hover, .operation-list-row:hover { border-color: #b9e9ff; }
.operation-list-row {
  display: grid;
  grid-template-columns: auto minmax(0,1fr) auto;
  align-items: center;
  text-align: left;
  gap: 7px;
}
.operation-planet-group + .operation-planet-group { margin-top: 14px; }
.operation-planet-group h3 { margin: 0 0 6px; overflow-wrap: anywhere; }
.operation-icon { color: #a0e9ff; font-size: 16px; line-height: 1; }
.operation-time { color: #b6f1ff; font-size: 12px; font-weight: 800; font-variant-numeric: tabular-nums; white-space: nowrap; }
.operation-list { display: grid; gap: 6px; }
.operation-list-row { padding: 9px; }
.operation-list-row strong, .operation-list-row small { display: block; overflow-wrap: anywhere; }
.operation-list-row small { color: #c1cde7; font-size: 11px; }
.operation-detail-time {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
  border: 1px solid #718cbc;
  border-radius: 9px;
  padding: 10px 12px;
  background: #12223d;
}
.operation-detail-time .operation-time { font-size: 18px; }
.operation-detail-actions { margin-top: 12px; }

@media (max-width: 760px) {
  .game { --operation-strip-height: 44px; }
  .operation-strip { padding-inline: 6px; gap: 4px; }
  .operation-tab .operation-time { font-size: 11px; }
  .game:has(.operation-strip:not([hidden])) .main {
    height: calc(100dvh - var(--space-header-height) - var(--resource-strip-height) - var(--operation-strip-height) - 64px);
  }
}

.operation-filters {
  display: grid;
  gap: 9px;
  margin-bottom: 14px;
}
.operation-filters > label {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
}
.operation-filters select { width: auto; max-width: 100%; }
.operation-filters fieldset {
  min-inline-size: 0;
  margin: 0;
  padding: 8px 10px 10px;
  border: 1px solid #607eb1;
  border-radius: 8px;
}
#operationAllPlanets[aria-pressed="true"] {
  border-color: #b9e9ff;
  background: #254b6b;
}
.operation-planet-choices {
  display: flex;
  flex-wrap: wrap;
  gap: 4px 8px;
  margin-top: 6px;
  max-height: 10rem;
  overflow: auto;
}
.operation-planet-choices label {
  display: flex;
  align-items: center;
  gap: 5px;
  min-height: 36px;
  max-width: 100%;
  padding: 4px 8px;
  cursor: pointer;
}
.operation-planet-choices input {
  flex: none;
  width: auto;
  margin: 0;
  accent-color: #a0e9ff;
}
.operation-planet-choices span { overflow-wrap: anywhere; }
.operation-filter-count { color: #bfcee9; }


/* Shipyard batches are visible under the top construction tab. */
.operation-tab[data-has-ship-orders="true"]{
 border-color:#6abecb;
 background:linear-gradient(110deg,#20485a,#24314e);
}
.operation-tab[data-has-ship-orders="true"] strong{color:#c3f5ff}
.operation-tab-status{
 display:flex;align-items:center;justify-content:center;gap:5px;
 min-width:0;max-width:100%;font-size:11px;
}
.operation-tab-current{
 overflow:hidden;text-overflow:ellipsis;white-space:nowrap;
 min-width:0;max-width:65%;color:#d5e7f6;font-size:11px;
}
.operation-tab-status .operation-time{
 flex:none;color:#c0f3ff;font-size:11px;
}
@media(max-width:760px){
 .operation-tab-status{gap:3px}
 .operation-tab-current{max-width:50%;font-size:10px}
 .operation-tab-status .operation-time{font-size:10px}
 .operation-tab[data-has-ship-orders="true"] strong{font-size:11px}
}
