/**
 * Central de Chamados - Estilos Modulares Redesign & Ticket Coupon Cards
 * BRAGO Sistema Chamador T.I.
 * Layout Ampliado e Responsivo para Área Segura + Cards de Ticket Cupom Originais
 */

/* Container Principal Ampliado */
.cc-main-grid {
  display: grid;
  grid-template-columns: 280px 1fr 300px;
  gap: 24px;
  width: 100%;
  max-width: 100%;
  margin: 0 auto;
  padding: 24px 28px 80px 28px;
  box-sizing: border-box;
}

/* ==========================================
   COLUNA ESQUERDA: PERFIL E STATUS
   ========================================== */
.cc-left-col {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

/* Card do Perfil do Solicitante */
.cc-profile-card {
  background: #ffffff;
  border-radius: 22px;
  padding: 28px 24px;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.04);
  border: 1px solid rgba(0, 0, 0, 0.06);
}

.cc-avatar-box {
  width: 90px;
  height: 90px;
  border-radius: 50%;
  background: linear-gradient(135deg, #1E4BFF 0%, #0066CC 100%);
  color: #ffffff;
  font-size: 28px;
  font-weight: 800;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 16px;
  box-shadow: 0 6px 18px rgba(30, 75, 255, 0.28);
  border: 4px solid #ffffff;
  overflow: hidden;
}

.cc-profile-name {
  font-size: 18px;
  font-weight: 800;
  color: #1a1d20;
  margin: 0 0 4px 0;
}

.cc-profile-role {
  font-size: 13px;
  font-weight: 500;
  color: #8c95a5;
  margin: 0 0 4px 0;
}

.cc-profile-filial {
  font-size: 13px;
  font-weight: 600;
  color: #5c6370;
  margin: 0 0 20px 0;
}

.cc-profile-btn {
  width: 100%;
  background: #1E4BFF;
  color: #ffffff;
  border: none;
  border-radius: 14px;
  padding: 12px 18px;
  font-size: 14px;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  cursor: pointer;
  box-shadow: 0 4px 14px rgba(30, 75, 255, 0.25);
  transition: all 0.2s ease;
}

.cc-profile-btn:hover {
  background: #1032CC;
  transform: translateY(-2px);
}

/* Cards Auxiliares da Coluna Esquerda */
.cc-card-left {
  background: #ffffff;
  border-radius: 22px;
  padding: 22px;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.04);
  border: 1px solid rgba(0, 0, 0, 0.06);
}

.cc-card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 16px;
}

.cc-card-title {
  font-size: 15px;
  font-weight: 700;
  color: #1a1d20;
  margin: 0;
}

.cc-icon-btn {
  background: transparent;
  border: none;
  color: #8c95a5;
  cursor: pointer;
  padding: 6px;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.cc-icon-btn:hover {
  color: #1a1d20;
  background: #f4f6fa;
}

/* Lista de Atendimentos na Esquerda */
.cc-status-list {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.cc-status-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding-bottom: 12px;
  border-bottom: 1px solid #f4f6fa;
}

.cc-status-item:last-child {
  border-bottom: none;
  padding-bottom: 0;
}

.cc-status-info {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
}

.cc-status-logo {
  width: 38px;
  height: 38px;
  border-radius: 12px;
  background: rgba(30, 75, 255, 0.08);
  color: #1E4BFF;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 15px;
  font-weight: 800;
  flex-shrink: 0;
}

.cc-status-texts {
  min-width: 0;
}

.cc-status-name {
  font-size: 14px;
  font-weight: 700;
  color: #1a1d20;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.cc-status-sub {
  font-size: 12px;
  color: #8c95a5;
}

.cc-badge {
  font-size: 11px;
  font-weight: 700;
  padding: 4px 10px;
  border-radius: 10px;
  text-transform: capitalize;
  white-space: nowrap;
}

.cc-badge.ativo {
  background: rgba(52, 199, 89, 0.12);
  color: #34C759;
}

.cc-badge.pendente {
  background: rgba(255, 149, 0, 0.12);
  color: #FF9500;
}

.cc-badge.concluido {
  background: rgba(30, 75, 255, 0.12);
  color: #1E4BFF;
}

/* Nuvem de Tópicos / Tags */
.cc-tags-cloud {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.cc-tag-pill {
  font-size: 12px;
  font-weight: 600;
  color: #1E4BFF;
  background: rgba(30, 75, 255, 0.08);
  padding: 6px 14px;
  border-radius: 14px;
  cursor: pointer;
  transition: all 0.2s ease;
  user-select: none;
}

.cc-tag-pill:hover, .cc-tag-pill.active {
  background: #1E4BFF;
  color: #ffffff;
}


/* ==========================================
   COLUNA CENTRAL: BANNER DE BUSCA E FEED
   ========================================== */
.cc-center-col {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

/* Hero Banner Card Premium Gradient */
.cc-banner-card {
  background: linear-gradient(135deg, #1E4BFF 0%, #1032CC 50%, #0D2699 100%);
  border-radius: 26px;
  padding: 36px 32px;
  color: #ffffff !important;
  box-shadow: 0 12px 32px rgba(30, 75, 255, 0.32);
  position: relative;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.15);
}

/* Background circles decoration */
.cc-banner-card::before {
  content: '';
  position: absolute;
  top: -60px;
  right: -60px;
  width: 280px;
  height: 280px;
  background: radial-gradient(circle, rgba(255, 255, 255, 0.18) 0%, rgba(255, 255, 255, 0) 70%);
  border-radius: 50%;
  pointer-events: none;
}

.cc-banner-card::after {
  content: '';
  position: absolute;
  bottom: -80px;
  left: -40px;
  width: 220px;
  height: 220px;
  background: radial-gradient(circle, rgba(255, 255, 255, 0.12) 0%, rgba(255, 255, 255, 0) 70%);
  border-radius: 50%;
  pointer-events: none;
}

.cc-banner-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: rgba(255, 255, 255, 0.18);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  color: #ffffff !important;
  font-size: 12px;
  font-weight: 700;
  padding: 5px 14px;
  border-radius: 999px;
  margin-bottom: 14px;
  border: 1px solid rgba(255, 255, 255, 0.25);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.cc-banner-title {
  font-size: 28px;
  font-weight: 900;
  color: #ffffff !important;
  margin: 0 0 10px 0;
  letter-spacing: -0.5px;
  text-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
  line-height: 1.25;
}

.cc-banner-desc {
  font-size: 14px;
  font-weight: 500;
  color: rgba(255, 255, 255, 0.92) !important;
  margin: 0 0 26px 0;
  max-width: 620px;
  line-height: 1.5;
  text-shadow: 0 1px 4px rgba(0, 0, 0, 0.15);
}

/* Input de busca dentro do banner */
.cc-search-box {
  background: #ffffff;
  border-radius: 20px;
  padding: 8px 8px 8px 20px;
  display: flex;
  align-items: center;
  gap: 14px;
  box-shadow: 0 8px 28px rgba(0, 0, 0, 0.16);
  border: 2px solid rgba(255, 255, 255, 0.9);
  transition: all 0.2s ease;
}

.cc-search-box:focus-within {
  box-shadow: 0 10px 32px rgba(0, 0, 0, 0.22);
  transform: translateY(-1px);
}

.cc-search-box i {
  color: #64748B;
  width: 20px;
  height: 20px;
  flex-shrink: 0;
}

.cc-search-input {
  border: none;
  outline: none;
  background: transparent;
  width: 100%;
  font-size: 15px;
  font-weight: 600;
  color: #0F172A !important;
}

.cc-search-input::placeholder {
  color: #94A3B8;
  font-weight: 400;
}

.cc-search-btn {
  background: linear-gradient(135deg, #1E4BFF 0%, #1032CC 100%);
  color: #ffffff !important;
  border: none;
  border-radius: 14px;
  padding: 12px 26px;
  font-size: 14px;
  font-weight: 700;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 8px;
  box-shadow: 0 4px 14px rgba(30, 75, 255, 0.35);
  transition: all 0.2s ease;
  white-space: nowrap;
}

.cc-search-btn:hover {
  background: linear-gradient(135deg, #1032CC 0%, #0D2699 100%);
  transform: translateY(-1px);
  box-shadow: 0 6px 18px rgba(30, 75, 255, 0.45);
}

/* Feed / Lista de Cards de Chamados */
.cc-tickets-feed {
  display: flex;
  flex-direction: column;
  gap: 20px;
}


/* ==========================================
   REAL PHYSICAL TICKET STUB CARDS (COPIADO DO SISTEMA)
   ========================================== */
.real-ticket-card {
  position: relative;
  display: flex;
  min-height: 140px;
  border-radius: 22px;
  overflow: hidden;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.08);
  color: #ffffff;
  transition: transform 0.25s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.25s ease;
}

.real-ticket-card:hover {
  transform: translateY(-4px) scale(1.003);
  box-shadow: 0 16px 36px rgba(0, 0, 0, 0.14);
}

.real-ticket-card.status-active {
  background: linear-gradient(135deg, #2546ED 0%, #3B82F6 50%, #06B6D4 100%);
}

.real-ticket-card.status-pending {
  background: linear-gradient(135deg, #F59E0B 0%, #F97316 50%, #EF4444 100%);
}

.real-ticket-card.status-unassigned {
  background: linear-gradient(135deg, #6366F1 0%, #8B5CF6 50%, #EC4899 100%);
}

.real-ticket-card.status-completed {
  background: linear-gradient(135deg, #10B981 0%, #059669 50%, #047857 100%);
}

.real-ticket-stub {
  width: 54px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(0, 0, 0, 0.15);
  border-right: 2px dashed rgba(255, 255, 255, 0.4);
  position: relative;
  flex-shrink: 0;
}

.real-ticket-stub-text {
  writing-mode: vertical-rl;
  transform: rotate(180deg);
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.95);
  white-space: nowrap;
}

.real-ticket-stub::before, .real-ticket-stub::after {
  content: '';
  position: absolute;
  right: -11px;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background-color: var(--bg-main, #f4f6fa);
  z-index: 3;
}

.real-ticket-stub::before { top: -11px; }
.real-ticket-stub::after { bottom: -11px; }

.real-ticket-body {
  flex: 1;
  padding: 22px 26px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 20px;
  position: relative;
}

.real-ticket-body::after {
  content: '';
  position: absolute;
  right: -11px;
  top: 50%;
  transform: translateY(-50%);
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background-color: var(--bg-main, #f4f6fa);
  z-index: 3;
}

.ticket-barcode-wrapper {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
}

.ticket-barcode-lines {
  height: 42px;
  width: 140px;
  background: repeating-linear-gradient(
    90deg, #ffffff 0px, #ffffff 2px, transparent 2px, transparent 4px,
    #ffffff 4px, #ffffff 7px, transparent 7px, transparent 9px,
    #ffffff 9px, #ffffff 10px, transparent 10px, transparent 12px,
    #ffffff 12px, #ffffff 15px, transparent 15px, transparent 17px
  );
  opacity: 0.92;
  border-radius: 2px;
}

.ticket-barcode-num {
  font-family: monospace;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 1px;
  color: rgba(255, 255, 255, 0.9);
}

.live-pulse-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background-color: #ffffff;
  display: inline-block;
  animation: pulseDot 1.5s infinite;
}

@keyframes pulseDot {
  0% { transform: scale(0.95); opacity: 0.7; }
  50% { transform: scale(1.3); opacity: 1; }
  100% { transform: scale(0.95); opacity: 0.7; }
}


/* ==========================================
   COLUNA DIREITA: FILTROS LATERAIS
   ========================================== */
.cc-right-col {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.cc-filter-card {
  background: #ffffff;
  border-radius: 22px;
  padding: 24px;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.04);
  border: 1px solid rgba(0, 0, 0, 0.06);
  display: flex;
  flex-direction: column;
  gap: 22px;
}

.cc-filter-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.cc-filter-title {
  font-size: 17px;
  font-weight: 800;
  color: #1a1d20;
  margin: 0;
}

.cc-filter-clear-btn {
  background: transparent;
  border: none;
  color: #8c95a5;
  cursor: pointer;
  padding: 6px;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: color 0.2s ease;
}

.cc-filter-clear-btn:hover {
  color: #FF3B30;
}

.cc-filter-section {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.cc-filter-label {
  font-size: 12px;
  font-weight: 800;
  color: #1a1d20;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.cc-filter-options-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.cc-checkbox-label {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  font-weight: 500;
  color: #5c6370;
  cursor: pointer;
  user-select: none;
}

.cc-checkbox-label input[type="checkbox"] {
  width: 18px;
  height: 18px;
  border-radius: 4px;
  accent-color: #1E4BFF;
  cursor: pointer;
}

.cc-select-input {
  width: 100%;
  padding: 12px 14px;
  border-radius: 14px;
  border: 1px solid rgba(0, 0, 0, 0.1);
  background: #ffffff;
  font-size: 13px;
  font-weight: 600;
  color: #1a1d20;
  outline: none;
  cursor: pointer;
}

.cc-select-input:focus {
  border-color: #1E4BFF;
}

.cc-slider-wrapper {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.cc-range-slider {
  width: 100%;
  accent-color: #1E4BFF;
  cursor: pointer;
}

.cc-slider-values {
  display: flex;
  justify-content: space-between;
  font-size: 12px;
  font-weight: 600;
  color: #8c95a5;
}


/* ==========================================
   RESPONSIVIDADE (MOBILE & TABLET)
   ========================================== */
@media (max-width: 1280px) {
  .cc-main-grid {
    grid-template-columns: 260px 1fr 260px;
    padding: 20px;
    gap: 18px;
  }
}

@media (max-width: 1080px) {
  .cc-main-grid {
    grid-template-columns: 1fr 280px;
  }
  .cc-left-col {
    display: none;
  }
}

@media (max-width: 850px) {
  .cc-main-grid {
    grid-template-columns: 1fr;
    padding: 16px 12px 100px 12px;
    gap: 18px;
  }
  .cc-right-col {
    order: -1;
  }
  .real-ticket-body {
    flex-direction: column;
    align-items: flex-start;
  }
  .ticket-barcode-wrapper {
    align-self: flex-end;
  }
}
