/* src/public/css/listings-invite.css */

/* ---- Post-creation invite banner (on show.ejs) ---- */
.li-invite-banner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
  padding: 14px 20px;
  margin-bottom: 18px;
  background: #eef6ff;
  border: 1px solid #b3d4f7;
  border-radius: 8px;
  font-size: 0.95rem;
}

.li-invite-banner-text {
  color: #1a3a5c;
}

.li-invite-banner-actions {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-shrink: 0;
}

.li-invite-banner-btn {
  display: inline-block;
  padding: 8px 18px;
  background: #2563eb;
  color: #fff;
  border-radius: 6px;
  font-weight: 600;
  text-decoration: none;
  font-size: 0.9rem;
  transition: background 0.15s;
}
.li-invite-banner-btn:hover { background: #1d4ed8; }

.li-invite-banner-dismiss {
  background: none;
  border: none;
  cursor: pointer;
  color: #555;
  font-size: 0.88rem;
  padding: 0;
  text-decoration: underline;
}
.li-invite-banner-dismiss:hover { color: #222; }

/* ---- Per-role invite link on role cards ---- */
.li-role-invite {
  margin: 6px 0 4px;
}

.li-invite-role-btn {
  display: inline-block;
  font-size: 0.82rem;
  font-weight: 500;
  color: #2563eb;
  text-decoration: none;
  padding: 4px 0;
  border-bottom: 1px solid transparent;
  transition: border-color 0.15s;
}
.li-invite-role-btn:hover {
  border-bottom-color: #2563eb;
}

/* ============================================================
   Invite Actors Page (invite-actors.ejs)
   ============================================================ */

.invite-actors-page {
  padding-bottom: 100px; /* room for sticky footer */
}

/* Header */
.ia-header {
  margin-bottom: 16px;
}

.ia-back-link {
  display: inline-block;
  font-size: 0.85rem;
  color: #555;
  text-decoration: none;
  margin-bottom: 8px;
}
.ia-back-link:hover { color: #111; }

.ia-title {
  font-size: 1.6rem;
  font-weight: 700;
  margin: 0 0 4px;
  color: #111;
}

.ia-subtitle {
  font-size: 1rem;
  color: #444;
  margin: 0 0 6px;
}

.ia-hint {
  font-size: 0.88rem;
  color: #666;
  margin: 0;
}

/* Filters */
.ia-filters-card {
  margin-bottom: 16px;
}

.ia-filters-form {
  width: 100%;
}

.ia-filters-row {
  display: flex;
  align-items: flex-end;
  flex-wrap: wrap;
  gap: 12px;
}

.ia-filter-label {
  display: flex;
  flex-direction: column;
  gap: 4px;
  font-size: 0.82rem;
  font-weight: 500;
  color: #444;
  min-width: 130px;
}

.ia-filter-input {
  padding: 7px 10px;
  border: 1px solid #ccc;
  border-radius: 6px;
  font-size: 0.88rem;
  background: #fff;
  color: #222;
  height: 36px;
}
.ia-filter-input:focus {
  outline: none;
  border-color: #2563eb;
  box-shadow: 0 0 0 2px rgba(37, 99, 235, 0.15);
}

.ia-filter-btn {
  height: 36px;
  padding: 0 18px;
  background: #2563eb;
  color: #fff;
  border: none;
  border-radius: 6px;
  font-size: 0.88rem;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.15s;
  align-self: flex-end;
}
.ia-filter-btn:hover { background: #1d4ed8; }

.ia-filter-clear {
  align-self: flex-end;
  font-size: 0.82rem;
  color: #888;
  text-decoration: underline;
  cursor: pointer;
  line-height: 36px;
}
.ia-filter-clear:hover { color: #444; }

/* Grid */
.ia-grid-card {
  margin-bottom: 16px;
}

.ia-grid-count {
  font-size: 0.85rem;
  color: #666;
  margin-bottom: 14px;
}

.ia-actor-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(130px, 1fr));
  gap: 16px;
}

@media (min-width: 600px) {
  .ia-actor-grid {
    grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
  }
}
@media (min-width: 900px) {
  .ia-actor-grid {
    grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
  }
}

/* Actor card */
.ia-actor-card {
  position: relative;
  cursor: pointer;
  border-radius: 10px;
  overflow: hidden;
  border: 2px solid #e5e7eb;
  background: #fafafa;
  transition: border-color 0.15s, box-shadow 0.15s;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  user-select: none;
}

.ia-actor-card:hover {
  border-color: #93c5fd;
  box-shadow: 0 2px 8px rgba(37, 99, 235, 0.12);
}

.ia-actor-card--selected {
  border-color: #2563eb;
  background: #eff6ff;
  box-shadow: 0 2px 10px rgba(37, 99, 235, 0.2);
}

/* Hide native checkbox visually, keep accessible */
.ia-actor-checkbox {
  position: absolute;
  opacity: 0;
  width: 0;
  height: 0;
  pointer-events: none;
}

/* Checkmark overlay in top-right corner */
.ia-actor-check-overlay {
  position: absolute;
  top: 8px;
  right: 8px;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: #fff;
  border: 2px solid #d1d5db;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.15s, border-color 0.15s;
  z-index: 2;
}

.ia-actor-check-overlay svg {
  width: 14px;
  height: 14px;
  color: #fff;
  opacity: 0;
  transition: opacity 0.15s;
}

.ia-actor-card--selected .ia-actor-check-overlay {
  background: #2563eb;
  border-color: #2563eb;
}

.ia-actor-card--selected .ia-actor-check-overlay svg {
  opacity: 1;
}

/* Headshot */
.ia-actor-photo {
  width: 100%;
  aspect-ratio: 3/4;
  object-fit: cover;
  display: block;
  background: #e5e7eb;
}

.ia-actor-photo-placeholder {
  width: 100%;
  aspect-ratio: 3/4;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #e9ecef;
}

.ia-actor-photo-placeholder svg {
  width: 60%;
  height: 60%;
  opacity: 0.5;
}

/* Name */
.ia-actor-name {
  font-size: 0.82rem;
  font-weight: 500;
  color: #222;
  padding: 8px 6px;
  line-height: 1.3;
  word-break: break-word;
}

/* Empty state */
.ia-empty {
  text-align: center;
  padding: 40px 20px;
  color: #666;
  font-size: 0.95rem;
}

/* Sticky footer */
.ia-footer-bar {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 24px;
  background: #fff;
  border-top: 1px solid #e5e7eb;
  box-shadow: 0 -2px 12px rgba(0, 0, 0, 0.06);
  z-index: 100;
}

.ia-skip-link {
  font-size: 0.9rem;
  color: #888;
  text-decoration: none;
  border-bottom: 1px solid transparent;
}
.ia-skip-link:hover {
  color: #333;
  border-bottom-color: #333;
}

.ia-send-btn {
  padding: 10px 24px;
  background: #2563eb;
  color: #fff;
  border: none;
  border-radius: 7px;
  font-size: 0.95rem;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.15s, opacity 0.15s;
}
.ia-send-btn:disabled {
  opacity: 0.45;
  cursor: not-allowed;
}
.ia-send-btn:not(:disabled):hover { background: #1d4ed8; }
