/* ==========================================================
   ScoutBase - feedback (poll) specific styling
   ==========================================================
   Whatever's left after extracting the shared layout
   primitives (header/nav/buttons/panel/forms) into base.css.
   Loaded on every feedback page; not used by the calendar
   pages.
   ========================================================== */

textarea {
  width: 100%;
  min-height: 90px;
}

.input-small {
  max-width: 120px;
}

/* Listing tables (feedback/users/manage/platform admin pages) - these
   used to live under a ".admin" wrapper div from the pre-M4 /admin
   area; M4 unified everything into /manage without anyone re-adding
   that wrapper, so every table in the app (audit log, system health,
   integrations, units, users, polls...) was silently rendering with
   zero styling, just bare browser table defaults. Unscoped here so it
   actually reaches all of them - the whole app only has tables of this
   one kind, so there's no scope to protect it from. */
table {
  width: 100%;
  border-collapse: collapse;
}

th,
td {
  padding: 10px 12px;
  border-bottom: 1px solid var(--border);
  text-align: left;
  vertical-align: top;
}

thead th {
  color: var(--muted);
  font-weight: 600;
}

th.col-actions,
td.col-actions {
  text-align: center;
  white-space: nowrap;
}

td.col-actions {
  padding-right: 16px;
}

.col-nowrap {
  white-space: nowrap;
}

/* System health's per-tenant CalDAV column (platform/health.html) -
   one unit per line instead of a single run-on, comma/middot-separated
   paragraph, which read as an unscannable wall of text once a tenant
   had more than one or two units. */
.health-unit-list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.health-unit-list li {
  padding: 2px 0;
}

.status-ok {
  color: var(--success-strong);
  font-weight: 700;
}

.status-fail {
  color: var(--danger-strong);
  font-weight: 700;
}

.inline-form {
  display: inline-block;
  margin: 0;
}

.link-action {
  margin-right: 8px;
}

.panel-head .actions form {
  display: inline-block;
  margin-left: 8px;
}

.panel-head .actions form:first-child {
  margin-left: 0;
}

/* Poll view (public) */
.poll-card {
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 16px;
  margin-bottom: 16px;
  box-shadow: var(--shadow);
}

.qr-wrapper {
  margin: 20px 0;
  display: flex;
  justify-content: center;
}

.qr-wrapper img {
  max-width: 100%;
  height: auto;
}

.actions-cell form {
  display: inline-block;
  margin-right: 6px;
}

.actions-cell button.btn-secondary {
  padding: 4px 10px;
  font-size: 0.85rem;
  border-radius: 6px;
}

.actions-cell .btn-link {
  font-size: 0.85rem;
  color: var(--accent);
}

@media (max-width: 720px) {
  table {
    display: block;
    width: 100%;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
  }

  th,
  td {
    font-size: 14px;
    padding: 8px;
  }

  th.col-actions,
  td.col-actions {
    white-space: nowrap;
  }

  textarea {
    min-height: 80px;
  }

  .input-small {
    max-width: 100px;
  }

  .panel-head .actions {
    width: 100%;
  }

  .panel-head .actions form {
    width: 100%;
  }

  .panel-head .actions button {
    width: 100%;
    text-align: center;
  }
}
