.client-preview-banner {
  margin: 0;
  padding: 10px 20px;
  background: #0b1b4a;
  color: #f7faff;
  font-size: 0.875rem;
  line-height: 1.4;
  border-bottom: 1px solid #ffffff22;
}

.client-preview-banner strong {
  font-weight: 650;
  margin-right: 6px;
}

body.is-portal-preview .is-preview-inert {
  pointer-events: none;
  opacity: 0.55;
}

body.is-portal-preview .client-form input:disabled,
body.is-portal-preview .client-form textarea:disabled,
body.is-portal-preview .client-form select:disabled,
body.is-portal-preview .client-form button:disabled,
body.is-portal-preview [data-proposal-decide]:disabled {
  cursor: not-allowed;
  opacity: 0.65;
}

/* Client portal — content styles on top of admin-shell layout */

.client-app .adm-nav-item {
  width: 100%;
  text-align: left;
  cursor: pointer;
  font-family: inherit;
}

.client-panel {
  background: #fff;
  border: 1px solid #e2e8f0;
  border-radius: 14px;
  padding: 20px;
}

.client-section {
  margin-top: 24px;
}

.client-section:first-child {
  margin-top: 0;
}

.client-section h3 {
  margin: 0 0 12px;
  font-size: 1rem;
}

.client-dl {
  display: grid;
  gap: 12px;
}

.client-dl div {
  display: grid;
  gap: 4px;
}

.client-dl dt {
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: #64748b;
}

.client-dl dd {
  margin: 0;
}

.client-form {
  display: grid;
  gap: 14px;
}

.client-form textarea,
.client-form input,
.client-form select {
  width: 100%;
  border: 1px solid #cbd5e1;
  border-radius: 10px;
  padding: 10px 12px;
  font: inherit;
}

.client-timeline {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 12px;
}

.client-timeline li {
  padding: 12px 14px;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  background: #f8fafc;
}

.client-timeline time {
  display: block;
  font-size: 0.75rem;
  color: #64748b;
  margin-bottom: 4px;
}

.client-timeline strong {
  display: block;
  margin-bottom: 4px;
}

.client-timeline p {
  margin: 0;
  font-size: 0.9rem;
  color: #334155;
}

.client-deal-card {
  display: grid;
  gap: 4px;
  padding: 14px 16px;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  margin-bottom: 10px;
}

.client-deal-stage {
  display: inline-flex;
  width: fit-content;
  padding: 2px 8px;
  border-radius: 999px;
  background: #eef3ff;
  color: #245bdb;
  font-size: 0.75rem;
  font-weight: 600;
}

.client-deal-meta {
  margin: 8px 0 0;
  font-size: 0.875rem;
}

.client-deal-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin-top: 10px;
}

.client-deal-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  padding: 0;
  border: 1px solid #dbe3f0;
  border-radius: 10px;
  background: #fff;
  color: #334155;
  cursor: pointer;
}

.client-deal-icon iconify-icon {
  font-size: 18px;
}

.client-deal-icon:hover {
  border-color: #245bdb;
  color: #245bdb;
}

.client-deal-icon.is-ok {
  color: #059669;
  border-color: #10b98155;
  background: #ecfdf5;
}

.client-deal-icon.is-ok:hover {
  border-color: #059669;
}

.client-deal-icon.is-err {
  color: #dc2626;
  border-color: #f8717155;
  background: #fef2f2;
}

.client-deal-icon.is-err:hover {
  border-color: #dc2626;
}

.client-deal-badge {
  display: inline-flex;
  align-items: center;
  padding: 4px 10px;
  border-radius: 999px;
  font-size: 0.75rem;
  font-weight: 700;
}

.client-deal-badge.is-ok {
  background: #ecfdf5;
  color: #059669;
}

.client-deal-badge.is-err {
  background: #fef2f2;
  color: #dc2626;
}

.client-support-item {
  padding: 12px 0;
  border-bottom: 1px solid #e2e8f0;
}

.client-support-item:last-child {
  border-bottom: 0;
}

.client-status {
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.client-status.is-sent {
  color: #0f7a45;
}

.client-status.is-ready {
  color: #245bdb;
}

.client-status.is-draft {
  color: #b45309;
}

.client-empty {
  margin: 0;
  color: #64748b;
}

/* —— Perfil —— */
.client-profile-subnav {
  margin-bottom: 20px;
}

.client-profile-panel {
  display: grid;
  gap: 20px;
}

.client-profile-hero {
  display: grid;
  gap: 14px;
  padding: 20px;
  border-radius: 16px;
  background: linear-gradient(135deg, #001038 0%, #0c2d6b 55%, #1a4dad 100%);
  color: #fff;
}

.client-profile-hero-top {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  min-width: 0;
}

.client-profile-avatar-col {
  display: grid;
  gap: 8px;
  justify-items: center;
  flex-shrink: 0;
}

.client-profile-avatar {
  display: grid;
  place-items: center;
  width: 56px;
  height: 56px;
  border-radius: 16px;
  background: #ffffff24;
  border: 1px solid #ffffff40;
  font-size: 1.2rem;
  font-weight: 700;
  letter-spacing: 0.04em;
}

.client-id-row {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  max-width: 100%;
}

.client-id-text {
  margin: 0;
  padding: 0;
  border: 0;
  background: transparent;
  color: #c5d8ff;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  line-height: 1.2;
  white-space: nowrap;
}

.client-id-copy {
  display: inline-grid;
  place-items: center;
  width: 22px;
  height: 22px;
  padding: 0;
  border: 0;
  border-radius: 6px;
  background: transparent;
  color: #c5d8ff;
  cursor: pointer;
}

.client-id-copy iconify-icon {
  width: 14px;
  height: 14px;
  pointer-events: none;
}

.client-id-copy:hover,
.client-id-copy.is-copied {
  color: #fff;
  background: #ffffff18;
}

.client-profile-hero-id {
  min-width: 0;
  flex: 1;
}

.client-profile-hero-id h3 {
  margin: 0 0 4px;
  font-size: 1.25rem;
  line-height: 1.2;
}

.client-profile-hero-id p {
  margin: 0;
  color: #ffffffc7;
  font-size: 0.925rem;
}

.client-manager-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px 10px;
  margin-top: 10px;
  font-size: 0.8125rem;
  color: #dbe7ff;
}

.client-manager-label {
  font-size: 0.65rem;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #9ec5ff;
}

.client-manager-name {
  font-weight: 700;
  color: #fff;
}

.client-manager-actions {
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.client-manager-icon {
  position: relative;
  display: inline-grid;
  place-items: center;
  width: 28px;
  height: 28px;
  border-radius: 8px;
  color: #c5d8ff;
  text-decoration: none;
  transition: background 0.15s ease, color 0.15s ease;
}

.client-manager-icon iconify-icon {
  width: 16px;
  height: 16px;
  pointer-events: none;
}

.client-manager-icon:hover {
  color: #fff;
  background: #ffffff18;
}

.client-manager-icon.is-whatsapp:hover {
  color: #6ee7b7;
}

.client-manager-icon[title]::after {
  content: attr(title);
  position: absolute;
  left: 50%;
  bottom: calc(100% + 8px);
  transform: translateX(-50%) translateY(4px);
  padding: 6px 10px;
  border-radius: 8px;
  background: #001038;
  color: #f7faff;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.01em;
  line-height: 1.3;
  white-space: nowrap;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  z-index: 40;
  box-shadow: 0 8px 24px #00103833;
  transition: opacity 0.12s ease, transform 0.12s ease, visibility 0.12s ease;
}

.client-manager-icon:hover::after,
.client-manager-icon:focus-visible::after {
  opacity: 1;
  visibility: visible;
  transform: translateX(-50%) translateY(0);
}

.client-stat-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
}

.client-stat-card {
  display: grid;
  gap: 4px;
  padding: 14px 16px;
  border-radius: 14px;
  border: 1px solid #e2e8f0;
  background: #f8fafc;
}

.client-stat-card.is-blue {
  border-color: #c7d7fb;
  background: #eef3ff;
}

.client-stat-card.is-green {
  border-color: #a7e0c0;
  background: #edf9f2;
}

.client-stat-card.is-amber {
  border-color: #fcd9a8;
  background: #fff8ed;
}

.client-stat-value {
  font-size: 1.5rem;
  font-weight: 700;
  line-height: 1.1;
  color: #001038;
}

.client-stat-label {
  font-size: 0.75rem;
  color: #64748b;
  line-height: 1.35;
}

.client-info-grid,
.client-security-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.client-info-card {
  padding: 16px 18px;
  border: 1px solid #e2e8f0;
  border-radius: 14px;
  background: #fff;
}

.client-info-card h4 {
  margin: 0 0 12px;
  font-size: 0.95rem;
}

.client-inline-code {
  font-size: 0.9rem;
  padding: 2px 8px;
  border-radius: 8px;
  background: #f1f5f9;
}

.client-profile-note {
  margin: 0;
  font-size: 0.875rem;
}

.client-email-list {
  display: grid;
  gap: 12px;
}

.client-email-item {
  padding: 14px 16px;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  background: #f8fafc;
}

.client-email-head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin-bottom: 6px;
}

.client-email-head time {
  font-size: 0.75rem;
  color: #64748b;
}

.client-email-item strong {
  display: block;
  font-size: 0.95rem;
  margin-bottom: 4px;
}

.client-email-note {
  margin: 6px 0 0;
  font-size: 0.8125rem;
  color: #64748b;
}

.client-project-columns {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 16px;
}

.client-project-col h3 {
  margin: 0 0 12px;
  font-size: 0.95rem;
  color: #334155;
}

.client-security-tips ul {
  margin: 0;
  padding-left: 18px;
  color: #475569;
  font-size: 0.875rem;
  line-height: 1.55;
}

.client-security-tips li + li {
  margin-top: 8px;
}

.client-security-link {
  margin: 12px 0 0;
  font-size: 0.875rem;
}

.client-security-link a {
  color: #245bdb;
  font-weight: 600;
}

@media (max-width: 960px) {
  .client-stat-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .client-info-grid,
  .client-security-grid,
  .client-project-columns {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 640px) {
  .client-profile-hero-top {
    align-items: flex-start;
  }

  .client-stat-grid {
    grid-template-columns: 1fr;
  }
}

/* Login / access pages (keep brand panel tweaks) */
.client-brand-panel .adm-brand-bg img,
body[data-client-page="login"] .adm-brand-bg img {
  object-position: 42% 38%;
}

.client-access-creds {
  gap: 16px;
}

.client-access-row {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.client-access-link {
  color: #245bdb;
  word-break: break-all;
  font-weight: 600;
}

.client-access-password {
  display: inline-block;
  font-size: 1.1rem;
  letter-spacing: 0.04em;
  padding: 6px 10px;
  background: #f1f5f9;
  border-radius: 8px;
}

.client-access-copy {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  padding: 0;
  border: 1px solid #dbe3f0;
  border-radius: 10px;
  background: #fff;
  color: #245bdb;
  cursor: pointer;
  flex-shrink: 0;
  transition: background 0.15s ease, border-color 0.15s ease, color 0.15s ease;
}

.client-access-copy:hover {
  background: #eef3ff;
  border-color: #b8c9f0;
}

.client-access-copy:focus-visible {
  outline: 2px solid #245bdb;
  outline-offset: 2px;
}

.client-access-copy.is-copied {
  color: #0f7a45;
  border-color: #a7e0c0;
  background: #edf9f2;
}

.client-access-copy.is-copied .client-access-copy-icon {
  display: none;
}

.client-access-copy.is-copied .client-access-copy-check {
  display: block;
}

.client-access-copy-check {
  display: none;
}

.client-access-note {
  margin: 16px 0;
  font-size: 0.875rem;
  line-height: 1.5;
}

/* Confirm / alert modal (shared adm-modal styles) */
.client-app .adm-modal-actions .adm-btn {
  width: auto;
  margin-top: 0;
  min-width: 110px;
}

.client-app .adm-confirm-modal-card .adm-btn:not(.adm-btn-ghost):not(.adm-btn-danger) {
  color: #fff;
  background: linear-gradient(135deg, #0060f8 0%, #0047b8 100%);
  border-color: transparent;
}

.client-app .adm-confirm-modal-card .adm-btn:not(.adm-btn-ghost):not(.adm-btn-danger):hover {
  filter: brightness(1.05);
}

.client-billing-wait {
  margin: 0 0 16px;
  padding: 12px 14px;
  border: 1px solid #c7d2fe;
  background: #eef2ff;
  border-radius: 8px;
  font-size: 14px;
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
}
.client-finance-table td,
.client-finance-table th {
  font-size: 13px;
}

.client-invoice-lines {
  margin: 6px 0 0;
  padding-left: 1.1em;
  font-size: 0.9em;
  color: #4a5568;
  line-height: 1.45;
}
.client-invoice-lines li {
  margin: 0 0 2px;
}
