.form-floating > .form-control-plaintext::placeholder, .form-floating > .form-control::placeholder {
  color: var(--bs-secondary-color);
  text-align: end;
}

.form-floating > .form-control-plaintext:focus::placeholder, .form-floating > .form-control:focus::placeholder {
  text-align: start;
}
/* Who else has the plan open */
.presence-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 2px 10px 2px 6px;
  border: 1px solid var(--stp-border);
  border-radius: 999px;
  font-size: 13px;
  background: var(--stp-surface);
}

.presence-chip .g-dot {
  margin-left: 0;
}

.stp-toast {
  position: fixed;
  left: 50%;
  bottom: 24px;
  transform: translateX(-50%);
  max-width: min(520px, calc(100vw - 32px));
  padding: 10px 16px;
  border-radius: 6px;
  background: var(--stp-text);
  color: var(--stp-bg);
  font-size: 14px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s;
  z-index: 1080;
}

.stp-toast.show {
  opacity: 1;
}

/* Naming a new plan while ticking its tasks on the master programme */
.plan-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  gap: 12px;
  padding: 8px 12px;
  margin-bottom: 8px;
  border: 1px solid color-mix(in srgb, var(--stp-accent) 45%, var(--stp-surface));
  border-radius: 6px;
  background: color-mix(in srgb, var(--stp-accent) 8%, var(--stp-surface));
}

.plan-bar .form-label {
  margin-bottom: 2px;
  font-size: 12px;
  color: var(--stp-muted);
}

/* List or tiles: a page holds both and shows the one chosen (js/site.js sets data-view). */
[data-view="list"] .view-tiles,
[data-view="tiles"] .view-list {
  display: none;
}

.view-tiles {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 16px;
}

.tile-title {
  font-size: 1.05rem;
  font-weight: 600;
  margin-bottom: 2px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.tile-facts {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 2px 12px;
  margin: 0;
  font-size: 14px;
}

.tile-facts dt {
  font-weight: 400;
  color: var(--stp-muted);
}

.tile-facts dd {
  margin: 0;
}

/* The view in use stands out on its switch. */
[data-view-switch] .btn.active,
.seg .btn.active {
  background: var(--stp-accent);
  border-color: var(--stp-accent);
  color: var(--stp-on-accent);
}

/* The Vision import list: the heading stays while the programmes scroll under it. */
/* .panel clips its contents (layout.css); this one must scroll them instead, hence the stronger selector. */
.panel.vision-scroll {
  max-height: calc(100vh - 290px);
  min-height: 240px;
  overflow: auto;
}

.vision-table thead th {
  position: sticky;
  top: 0;
  z-index: 1;
  background: var(--stp-surface-2);
  box-shadow: inset 0 -1px 0 var(--stp-border);
}

.vision-table tr.vision-group th {
  position: sticky;
  top: 41px;
  z-index: 1;
  padding-top: 6px;
  padding-bottom: 6px;
  background: color-mix(in srgb, var(--stp-accent) 10%, var(--stp-surface));
  font: 650 13px/18px var(--font-display);
}

/* The Vision list as tiles: one card per programme under its group heading. */
[data-view="list"] .view-tiles-host {
  display: none;
}

.vision-tiles-scroll {
  max-height: calc(100vh - 290px);
  min-height: 240px;
  overflow: auto;
  padding: 2px;
}

.vision-tiles {
  grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
  gap: 12px;
}

.vision-tile-group {
  grid-column: 1 / -1;
  margin: 6px 0 -4px;
  padding-bottom: 4px;
  border-bottom: 1px solid var(--stp-border);
  font: 650 14px/20px var(--font-display);
}

.vision-tile-group:first-child {
  margin-top: 0;
}

.vision-tile {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 12px 14px;
  border-radius: 8px;
  background: var(--stp-surface);
  box-shadow: var(--shadow-1);
}

.vision-tile.archived {
  opacity: 0.6;
}

.vision-tile-fields {
  font-size: 12px;
  color: var(--stp-muted);
}

.vision-tile .btn {
  align-self: flex-start;
  margin-top: auto;
}
