/*
 * CVDB — Justificativas progressivas da Declaração Reversa
 * Versão: 20260714_10 (V225)
 */

.lista-declaracao .cvdb-declaracao-info-head,
.lista-declaracao .cvdb-declaracao-info-cell {
  width: 66px;
  min-width: 66px;
  text-align: center;
}

.lista-declaracao .cvdb-declaracao-justificar-head,
.lista-declaracao .cvdb-declaracao-justificar-cell {
  width: 142px;
  min-width: 142px;
  text-align: center;
}

.lista-declaracao .cvdb-declaracao-info-cell .motivo-btn {
  margin: 0 auto;
}

.lista-declaracao .cvdb-declaracao-info-empty {
  color: var(--muted);
  opacity: 0.55;
}

.lista-declaracao .status-cell {
  gap: 0;
}

.cvdb-declaracao-justificar-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  min-height: 34px;
  padding: 0 11px;
  border: 1px solid rgba(77, 139, 255, 0.45);
  border-radius: 11px;
  background: linear-gradient(180deg, rgba(21, 43, 88, 0.78), rgba(12, 28, 58, 0.88));
  color: #dce9ff;
  box-shadow: inset 0 0 0 1px rgba(124, 165, 255, 0.05);
  font: inherit;
  font-size: 12px;
  font-weight: 760;
  cursor: pointer;
  white-space: nowrap;
  transition: transform 0.16s ease, border-color 0.16s ease, box-shadow 0.16s ease;
}

.cvdb-declaracao-justificar-btn:hover {
  transform: translateY(-1px);
  border-color: rgba(96, 154, 255, 0.78);
  box-shadow: 0 8px 18px rgba(0, 10, 30, 0.24);
}

.cvdb-declaracao-justificar-btn:focus-visible {
  outline: 3px solid rgba(68, 125, 246, 0.3);
  outline-offset: 2px;
}

.cvdb-declaracao-justificar-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 21px;
  height: 21px;
  border: 1px solid rgba(111, 159, 255, 0.36);
  border-radius: 999px;
  background: rgba(58, 106, 209, 0.2);
}

.cvdb-declaracao-justificar-count {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 20px;
  height: 20px;
  padding: 0 5px;
  border-radius: 999px;
  background: #2f6fea;
  color: #fff;
  font-size: 10px;
  line-height: 1;
}

.cvdb-declaracao-justificar-count[hidden] {
  display: none !important;
}

body.cvdb-just-modal-open {
  overflow: hidden;
}

.cvdb-just-modal[hidden] {
  display: none !important;
}

.cvdb-just-modal {
  position: fixed;
  inset: 0;
  z-index: 99999;
  display: grid;
  place-items: center;
  padding: 24px;
}

.cvdb-just-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(1, 7, 20, 0.78);
  backdrop-filter: blur(6px);
}

.cvdb-just-dialog {
  position: relative;
  z-index: 1;
  width: min(860px, 96vw);
  max-height: 92vh;
  overflow: auto;
  border: 1px solid rgba(80, 136, 241, 0.38);
  border-radius: 22px;
  background: linear-gradient(180deg, #111c34, #0b1428);
  color: var(--text);
  box-shadow: 0 28px 80px rgba(0, 5, 18, 0.62);
}

.cvdb-just-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 20px;
  padding: 22px 24px 18px;
  border-bottom: 1px solid rgba(93, 133, 205, 0.2);
  background: linear-gradient(135deg, rgba(29, 66, 137, 0.28), rgba(15, 31, 67, 0.08));
}

.cvdb-just-kicker {
  display: block;
  margin-bottom: 5px;
  color: #75a8ff;
  font-size: 11px;
  font-weight: 850;
  letter-spacing: 0.09em;
  text-transform: uppercase;
}

.cvdb-just-header h2 {
  margin: 0;
  font-size: 25px;
}

.cvdb-just-header p {
  margin: 7px 0 0;
  color: var(--muted);
}

.cvdb-just-close {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  border: 1px solid rgba(104, 148, 235, 0.3);
  border-radius: 12px;
  background: rgba(11, 25, 53, 0.72);
  color: #dce9ff;
  font-size: 24px;
  cursor: pointer;
}

.cvdb-just-message {
  margin: 18px 24px 0;
  padding: 12px 14px;
  border-left: 4px solid #4b82ee;
  border-radius: 10px;
  background: rgba(55, 104, 205, 0.14);
  color: #dce8ff;
  font-size: 13px;
  font-weight: 700;
}

.cvdb-just-message-success {
  border-left-color: #2ecf8e;
  background: rgba(30, 166, 111, 0.12);
}

.cvdb-just-message-error {
  border-left-color: #f05d68;
  background: rgba(215, 61, 75, 0.12);
}

.cvdb-just-message-info {
  border-left-color: #4b82ee;
}

.cvdb-just-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  margin: 18px 24px 0;
  padding: 14px 15px;
  border: 1px solid rgba(82, 120, 190, 0.2);
  border-radius: 14px;
  background: rgba(7, 17, 36, 0.42);
}

.cvdb-just-toolbar > div {
  display: grid;
  gap: 4px;
}

.cvdb-just-toolbar strong {
  font-size: 13px;
}

.cvdb-just-toolbar span:not([aria-hidden]) {
  color: var(--muted);
  font-size: 11px;
}

.cvdb-just-add {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  min-height: 40px;
  padding: 0 14px;
  border: 1px solid rgba(77, 139, 255, 0.52) !important;
  border-radius: 12px;
  background: rgba(29, 61, 125, 0.48) !important;
  color: #dbe8ff !important;
  font-weight: 780;
  white-space: nowrap;
}

.cvdb-just-add[hidden] {
  display: none !important;
}

.cvdb-just-fields {
  display: grid;
  gap: 14px;
  padding: 18px 24px;
}

.cvdb-just-empty {
  display: grid;
  justify-items: center;
  gap: 8px;
  padding: 34px 20px;
  border: 1px dashed rgba(91, 137, 222, 0.34);
  border-radius: 16px;
  background: rgba(5, 14, 31, 0.35);
  text-align: center;
}

.cvdb-just-empty-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border: 1px solid rgba(90, 144, 246, 0.46);
  border-radius: 999px;
  background: rgba(42, 88, 181, 0.2);
  color: #8db5ff;
  font-size: 21px;
}

.cvdb-just-empty strong {
  font-size: 15px;
}

.cvdb-just-empty p {
  margin: 0;
  color: var(--muted);
  font-size: 12px;
}

.cvdb-just-card {
  padding: 15px;
  border: 1px solid rgba(82, 120, 190, 0.22);
  border-radius: 15px;
  background: rgba(7, 17, 36, 0.46);
}

.cvdb-just-card-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 15px;
  margin-bottom: 9px;
}

.cvdb-just-card-top label {
  font-size: 13px;
  font-weight: 850;
}

.cvdb-just-card-top span {
  color: #7fa9f8;
  font-size: 11px;
  font-weight: 750;
}

.cvdb-just-card textarea {
  width: 100%;
  min-height: 104px;
  resize: vertical;
  padding: 12px 13px;
  border: 1px solid rgba(83, 121, 194, 0.28);
  border-radius: 12px;
  background: rgba(4, 11, 26, 0.6);
  color: #dbe8ff;
  font: inherit;
  line-height: 1.5;
}

.cvdb-just-card textarea[readonly] {
  cursor: default;
  opacity: 0.84;
}

.cvdb-just-card textarea:not([readonly]) {
  border-color: rgba(73, 132, 247, 0.72);
  box-shadow: 0 0 0 3px rgba(51, 111, 229, 0.14);
  background: rgba(5, 14, 32, 0.9);
}

.cvdb-just-meta {
  min-height: 18px;
  margin-top: 8px;
  color: var(--muted);
  font-size: 11px;
}

.cvdb-just-actions {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  padding: 0 24px 22px;
}

.cvdb-just-actions .btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  min-width: 122px;
  min-height: 42px;
  border-radius: 12px;
}

.cvdb-just-edit {
  border: 1px solid rgba(90, 144, 246, 0.48) !important;
  background: rgba(29, 61, 125, 0.48) !important;
  color: #dbe8ff !important;
}

.cvdb-just-save {
  border: 1px solid rgba(46, 207, 142, 0.48) !important;
  background: rgba(23, 123, 83, 0.55) !important;
  color: #e7fff5 !important;
}

.cvdb-just-cancel {
  border: 1px solid rgba(137, 157, 195, 0.3) !important;
  background: rgba(24, 34, 54, 0.72) !important;
  color: #d2d9e7 !important;
}

.cvdb-just-actions .btn[hidden] {
  display: none !important;
}

.cvdb-just-actions .btn:disabled,
.cvdb-just-add:disabled {
  cursor: not-allowed;
  opacity: 0.45;
}

@media (max-width: 760px) {
  .cvdb-just-modal {
    padding: 10px;
  }

  .cvdb-just-dialog {
    width: 100%;
    max-height: 96vh;
    border-radius: 17px;
  }

  .cvdb-just-header,
  .cvdb-just-fields {
    padding-left: 16px;
    padding-right: 16px;
  }

  .cvdb-just-message,
  .cvdb-just-toolbar {
    margin-left: 16px;
    margin-right: 16px;
  }

  .cvdb-just-toolbar {
    align-items: stretch;
    flex-direction: column;
  }

  .cvdb-just-add {
    width: 100%;
  }

  .cvdb-just-actions {
    flex-direction: column;
    padding-left: 16px;
    padding-right: 16px;
  }

  .cvdb-just-actions .btn {
    width: 100%;
  }
}
