/* AGENDE-ME - ajustes sobre o AdminLTE 3.2 */

/* Marca */
.ag-logo {
  float: left; display: inline-flex; align-items: center; justify-content: center;
  width: 33px; height: 33px; margin: 0 .5rem 0 .8rem; border-radius: 50%;
  background: #007bff; color: #fff; font-size: 1rem; line-height: 1;
}
.login-logo a, .register-logo a { color: #343a40; }
.login-logo .fa-calendar-check, .register-logo .fa-calendar-check { color: #007bff; }

/* Avatar com iniciais (substitui foto enquanto não houver upload) */
.ag-avatar {
  display: inline-flex; align-items: center; justify-content: center;
  border-radius: 50%; background: #6f42c1; color: #fff; font-weight: 700;
}
.ag-avatar-sm { width: 30px; height: 30px; font-size: .8rem; }
.ag-avatar-md { width: 42px; height: 42px; font-size: 1rem; }
.ag-avatar-lg { width: 90px; height: 90px; font-size: 2rem; border: 3px solid rgba(255,255,255,.4); }
.user-header .ag-avatar-lg { margin: 0 auto .5rem; display: flex; }
.user-panel .ag-avatar-sm { margin-left: .4rem; }
.ag-avatar.bg-teal { background: #20c997; }
.ag-avatar.bg-orange { background: #fd7e14; }
.ag-avatar.bg-pink { background: #e83e8c; }
.ag-avatar.bg-info { background: #17a2b8; }

/* Código de verificação */
.otp-input { letter-spacing: .6em; font-size: 1.75rem; text-align: center; font-weight: 700; }

/* Badges das flags do cliente */
.badge-flag { font-weight: 500; font-size: 78%; margin: 1px 2px 1px 0; }

/* Status de agendamento (mesmas cores da agenda) */
.status-PENDENTE   { background: #ffc107; color: #1f2d3d; }
.status-CONFIRMADO { background: #007bff; color: #fff; }
.status-CONCLUIDO  { background: #28a745; color: #fff; }
.status-CANCELADO, .status-RECUSADO { background: #6c757d; color: #fff; }
.status-FALTOU     { background: #dc3545; color: #fff; }
.legend-dot { display: inline-block; width: 10px; height: 10px; border-radius: 50%; margin-right: 4px; }

/* Assistente de agendamento (T21) */
.wizard-progress { display: flex; gap: .25rem; margin-bottom: 1rem; }
.wizard-progress .step { flex: 1; text-align: center; font-size: .8rem; color: #6c757d; }
.wizard-progress .step .bar { height: 4px; border-radius: 2px; background: #dee2e6; margin-bottom: .35rem; }
.wizard-progress .step.done .bar, .wizard-progress .step.current .bar { background: #007bff; }
.wizard-progress .step.current { color: #007bff; font-weight: 600; }
.wizard-pane { display: none; }
.wizard-pane.active { display: block; }
.choice-card { cursor: pointer; transition: box-shadow .15s, border-color .15s; border: 2px solid transparent; }
.choice-card:hover { box-shadow: 0 0 0 1px #007bff33; }
.choice-card.selected { border-color: #007bff; }
.day-strip { display: flex; overflow-x: auto; gap: .5rem; padding-bottom: .5rem; -webkit-overflow-scrolling: touch; }
.day-chip { flex: 0 0 auto; width: 64px; text-align: center; border: 1px solid #dee2e6; border-radius: .5rem; padding: .4rem 0; cursor: pointer; background: #fff; }
.day-chip small { display: block; color: #6c757d; text-transform: uppercase; font-size: .7rem; }
.day-chip strong { font-size: 1.25rem; }
.day-chip.selected { background: #007bff; border-color: #007bff; color: #fff; }
.day-chip.selected small { color: #e3f0ff; }
.day-chip.disabled { opacity: .4; pointer-events: none; }
.slot-btn { min-width: 76px; margin: 0 .35rem .5rem 0; }

/* Linhas da grade editável de horários */
.table-edit td { vertical-align: middle; }
.table-edit .form-control, .table-edit .custom-select { min-width: 96px; }

/* Grade de agenda */
#calendar { min-height: 600px; }
.fc .fc-toolbar-title { font-size: 1.25rem; }
.fc .fc-button-primary { background: #007bff; border-color: #007bff; }
.fc .fc-non-business { background: rgba(108,117,125,.08); }

/* Camada de API */
.ag-modo-demo {
  position: fixed; left: 12px; bottom: 12px; z-index: 2000; padding: .25rem .6rem;
  font-size: .75rem; border-radius: 1rem; background: #6f42c1; color: #fff; opacity: .85; pointer-events: none;
}
.ag-carregando { opacity: .55; transition: opacity .2s; }
tbody.ag-carregando:empty::after, div.ag-carregando:empty::after { content: 'Carregando…'; display: block; padding: 1.5rem; text-align: center; color: #6c757d; }
.table-edit tr.is-invalid td { background: #fbe9eb; }

/* Tabelas viram cards no celular: <table class="table table-cards"> + data-label em cada <td> */
@media (max-width: 575.98px) {
  .table-cards thead { display: none; }
  .table-cards tbody tr {
    display: block; margin: 0 0 .75rem; padding: .5rem .75rem;
    border: 1px solid #dee2e6; border-radius: .5rem; background: #fff;
  }
  .table-cards tbody td {
    display: flex; justify-content: space-between; align-items: center;
    border: 0; padding: .3rem 0; text-align: right;
  }
  .table-cards tbody td::before {
    content: attr(data-label); font-weight: 600; color: #6c757d;
    margin-right: 1rem; text-align: left;
  }
  .table-cards tbody td.td-main { font-size: 1.05rem; font-weight: 600; text-align: left; }
  .table-cards tbody td.td-main::before { content: none; }
  .table-cards tbody td.td-actions { justify-content: flex-end; padding-top: .5rem; }
  .table-cards tbody td.td-actions::before { content: none; }
  .card-body.table-responsive.p-0 .table-cards { margin: .75rem; width: calc(100% - 1.5rem); }
  .content-header h1 { font-size: 1.4rem; }
  .small-box .inner h3 { font-size: 1.6rem; }
  .btn-block-xs { display: block; width: 100%; }
}
