/* "Equipo" panel — public/team.js. Reuses .modal-overlay / .modal-input / .btn-*; only
   the roster table, the multi-row review form and the status badges live here. */

.team-modal-content { width: 900px; }
.team-modal-content .modal-body { overflow-y: auto; padding: 18px 24px 24px; }

/* .btn-secondary is styled for the dark header; give it a light-surface look here. */
#team-modal .btn-secondary {
  background: var(--white); color: var(--gray-700); border: 1px solid var(--gray-200);
}
#team-modal .btn-secondary:hover { background: var(--gray-50); color: var(--gray-900); }

.team-toolbar { display: flex; justify-content: flex-end; margin: 4px 0 12px; }

.team-table { width: 100%; border-collapse: collapse; font-size: 13px; }
.team-table th {
  text-align: left; font-weight: 600; color: var(--gray-600);
  padding: 8px 10px; border-bottom: 1px solid var(--gray-200);
}
.team-table td { padding: 10px; border-bottom: 1px solid var(--gray-100); vertical-align: middle; }
.team-email { color: var(--gray-600); min-width: 170px; overflow-wrap: anywhere; }
.team-you { color: var(--gray-400); font-size: 12px; }
.team-actions { text-align: right; }
.team-action { font-size: 12px; padding: 5px 10px; margin: 2px 0 2px 4px; color: var(--gray-700); white-space: nowrap; }
#team-modal .team-action-danger { color: #b91c1c; }

.team-role-badge, .team-status {
  display: inline-block; padding: 2px 8px; border-radius: 999px;
  font-size: 12px; font-weight: 600; white-space: nowrap;
}
.team-role-badge { background: var(--gray-100); color: var(--gray-700); }
.team-role-admin { background: #e0e7ff; color: #3730a3; }
.team-status-active { background: #dcfce7; color: #166534; }
.team-status-invited { background: #fef3c7; color: #92400e; }
.team-status-inactive { background: var(--gray-100); color: var(--gray-500); }

.team-form-title { font-size: 15px; margin: 0 0 6px; }
.team-member-row {
  position: relative; border: 1px solid var(--gray-200); border-radius: 10px;
  padding: 14px 16px 2px; margin: 0 0 12px;
}
.team-row-remove { position: absolute; top: 6px; right: 6px; font-size: 16px; }
#team-modal input[readonly] { background: var(--gray-50); color: var(--gray-500); cursor: default; }
.team-optional { font-weight: 400; color: var(--gray-400); }
.team-field-error { color: #b91c1c; font-size: 12px; min-height: 0; }
.team-field-error:empty { display: none; }
.team-input-error { border-color: #dc2626 !important; }
.team-add-row { margin-bottom: 12px; }
.team-form-error { color: #b91c1c; font-size: 13px; margin: 4px 0 12px; }
.team-form-actions { display: flex; justify-content: flex-end; gap: 10px; }

@media (max-width: 720px) {
  /* style.css's own phone rule for .form-row-2col sits ABOVE its desktop rule, so the
     desktop two columns win and the review form overflows a phone. Scoped fix. */
  #team-modal .form-row-2col { grid-template-columns: 1fr; gap: 0; }
  .team-table thead { display: none; }
  .team-table, .team-table tbody, .team-table tr, .team-table td { display: block; width: 100%; }
  .team-table tr { border-bottom: 1px solid var(--gray-200); padding: 8px 0; }
  .team-table td { border: none; padding: 4px 0; }
  .team-table td[data-label]::before {
    content: attr(data-label); display: block; font-size: 11px; color: var(--gray-400);
  }
  .team-actions { text-align: left; white-space: normal; }
  .team-action { margin: 2px 4px 2px 0; }
}

/* Team chat (public/team.js): the banner above the chat input while an admin is adding
   someone, and the drafted-people summary inside the chat's help bubble. */
.team-chat-banner {
  display: flex; align-items: center; gap: 8px;
  margin: 0 0 8px; padding: 8px 12px; border-radius: 10px;
  background: #e0e7ff; color: #3730a3; font-size: 13px;
}
.team-chat-banner.hidden { display: none; }
.team-chat-banner span { flex: 1; }
.team-chat-banner-cancel {
  border: 1px solid #6366f1; background: var(--white); color: #3730a3;
  border-radius: 8px; padding: 4px 10px; font-size: 12px; cursor: pointer;
}
.team-chat-summary { margin: 8px 0 0; padding-left: 18px; font-size: 13px; }
.team-chat-summary li { margin: 2px 0; overflow-wrap: anywhere; }
.team-chat-email { font-weight: 600; }
.team-chat-warn { color: #92400e; }
.team-chat-actions { display: flex; flex-wrap: wrap; gap: 8px; }
.team-chat-actions .team-chat-cancel { border-color: var(--gray-300); color: var(--gray-700); }
