@import url('https://fonts.googleapis.com/css2?family=Inter:wght@100;200;300;400;500;600;700;800;900&display=swap');

* {
  font-family: "Inter", ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans", "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol";
}

/* animacao de troca de página */

.fade-enter-active, .fade-leave-active {
  transition: opacity 0.2s ease, transform 0.1s ease-in-out;
}

.fade-enter, .fade-leave-to {
  opacity: 0;
  transform: translateY(15px);
}

.channels-page {
  background: #f8fafc;
  min-height: 100%;
}

.channels-grid-wrapper {
  padding: 24px 32px 12px;
}

.channels-grid {
  display: grid;
  grid-template-columns: repeat(1, minmax(0, 1fr));
  gap: 24px;
}

@media (min-width: 768px) {
  .channels-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (min-width: 1200px) {
  .channels-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

@media (min-width: 1600px) {
  .channels-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }
}

.channel-card-modern {
  position: relative;
  background: #fff;
  border-radius: 18px;
  padding: 22px;
  border: 1px solid #eef2f7;
  box-shadow: 0 6px 22px rgba(15, 23, 42, 0.08);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  cursor: pointer;
  overflow: clip;
}

.channel-card-modern:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 30px rgba(15, 23, 42, 0.12);
}

.channel-status-strip {
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 6px;
  background: #ef4444;
}

.channel-card-modern.is-connected .channel-status-strip {
  background: #22c55e;
}

.channel-card-modern.is-disconnected .channel-status-strip {
  background: #ef4444;
}

.channel-card-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
}

.channel-header-left {
  display: flex;
  align-items: center;
  gap: 14px;
}

.channel-icon {
  width: 44px;
  height: 44px;
  border-radius: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #f1f5f9;
  border: 1px solid #e2e8f0;
  color: #64748b;
}

.channel-icon.is-whatsapp {
  color: #22c55e;
}

.channel-icon.is-telegram {
  color: #0ea5e9;
}

.channel-icon.is-instagram {
  color: #e11d48;
}

.channel-icon.is-facebook {
  color: #2563eb;
}

.channel-icon.is-rcs {
  color: #4285F4;
}

.channel-title-block {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.channel-title-modern {
  font-size: 1.05rem;
  font-weight: 700;
  color: #0f172a;
  margin: 0;
  max-width: 220px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.channel-meta {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.channel-type-badge {
  font-size: 0.65rem;
  font-weight: 700;
  text-transform: uppercase;
  padding: 2px 8px;
  border-radius: 8px;
  background: #f1f5f9;
  color: #64748b;
}

.channel-type-badge.is-whatsapp {
  background: #dcfce7;
  color: #15803d;
}

.channel-type-badge.is-whatsapp-web {
  background: #bbf7d0;
  color: #166534;
}

.channel-type-badge.is-telegram {
  background: #e0f2fe;
  color: #0369a1;
}

.channel-type-badge.is-instagram {
  background: #ffe4e6;
  color: #be123c;
}

.channel-type-badge.is-facebook {
  background: #dbeafe;
  color: #1d4ed8;
}

.channel-type-badge.is-rcs {
  background: #dbeafe;
  color: #1a56db;
}

.channel-id-modern {
  font-size: 0.75rem;
  color: #94a3b8;
  font-weight: 500;
}

.channel-menu-button {
  border: none;
  background: transparent;
  color: #cbd5e1;
  padding: 4px;
  border-radius: 10px;
  transition: background 0.2s ease, color 0.2s ease;
}

.channel-menu-button i {
  font-size: 18px;
}

.channel-menu-button:hover {
  background: #eff6ff;
  color: #2563eb;
}

.channel-menu {
  position: absolute;
  top: 54px;
  right: 18px;
  background: #fff;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  box-shadow: 0 12px 24px rgba(15, 23, 42, 0.12);
  padding: 8px;
  display: flex;
  flex-direction: column;
  gap: 4px;
  z-index: 20;
  min-width: 180px;
}

.channel-menu-item {
  display: flex;
  align-items: center;
  gap: 10px;
  border: none;
  background: transparent;
  font-size: 0.85rem;
  color: #334155;
  padding: 8px 10px;
  border-radius: 10px;
  cursor: pointer;
  transition: all 0.2s ease;
}

.channel-menu-item i {
  font-size: 16px;
}

.channel-menu-item:hover {
  background: #f1f5f9;
}

.channel-menu-item.is-danger {
  color: #e11d48;
}

.channel-menu-item.is-danger:hover {
  background: #ffe4e6;
}

.channel-menu-item:disabled {
  opacity: 0.55;
  cursor: not-allowed;
}

.channel-card-body {
  margin-top: 18px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.channel-info-row {
  display: flex;
  align-items: center;
  gap: 10px;
}

.channel-info-icon {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #f1f5f9;
  border: 1px solid #e2e8f0;
  color: #94a3b8;
}

.channel-info-text {
  font-size: 0.9rem;
  color: #475569;
  font-weight: 500;
}

.channel-status-pill {
  align-self: flex-start;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 0.7rem;
  font-weight: 700;
  padding: 4px 10px;
  border-radius: 999px;
  background: #fee2e2;
  color: #b91c1c;
  border: 1px solid #fecaca;
}

.channel-status-pill.is-connected {
  background: #dcfce7;
  color: #15803d;
  border-color: #bbf7d0;
}

.channel-status-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: currentColor;
}

.channel-card-stats {
  margin-top: 20px;
  padding-top: 16px;
  border-top: 1px solid #f1f5f9;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  text-align: center;
}

.channel-stat-label {
  margin: 0 0 4px;
  font-size: 0.6rem;
  font-weight: 700;
  text-transform: uppercase;
  color: #94a3b8;
  letter-spacing: 0.12em;
}

.channel-stat-value {
  margin: 0;
  font-size: 1.1rem;
  font-weight: 700;
  color: #334155;
}

.channel-card-new {
  border: 2px dashed #e2e8f0;
  background: #fff;
  text-align: center;
  cursor: pointer;
  padding: 30px 22px;
  color: #64748b;
}

.channel-card-new:hover {
  border-color: #93c5fd;
  background: #f8fafc;
}

.channel-card-new-icon {
  width: 54px;
  height: 54px;
  border-radius: 50%;
  background: #eff6ff;
  color: #3b82f6;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 16px;
  font-size: 22px;
}

.channel-card-new h3 {
  font-size: 1rem;
  font-weight: 700;
  margin: 0 0 6px;
  color: #334155;
}

.channel-card-new p {
  font-size: 0.85rem;
  margin: 0 0 16px;
  color: #94a3b8;
}

.channel-card-new-action {
  border: none;
  background: transparent;
  color: #2563eb;
  font-weight: 700;
  font-size: 0.85rem;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.channels-empty-state {
  padding: 24px 32px;
}

.channels-empty-card {
  background: transparent;
  border-radius: 0;
  border: none;
  padding: 0;
  text-align: left;
  box-shadow: none;
}

.channels-empty-icon {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  background: #f1f5f9;
  color: #94a3b8;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 16px;
  font-size: 26px;
}

.channels-empty-text {
  color: #64748b;
  font-weight: 500;
}

.channels-pagination {
  padding: 8px 0 24px;
  display: flex;
  justify-content: center;
}

@media (max-width: 768px) {
  .channels-grid-wrapper {
    padding: 16px;
  }

  .channel-card-modern {
    padding: 18px;
  }

  .channel-title-modern {
    max-width: 180px;
  }
}

@media (max-width: 480px) {
  .channel-title-modern {
    max-width: 150px;
  }
}
