:root {
  --primary-color: #0072bc;
  --accent-color: #ff8c00;
  --bg-color: #f4f6f9;
  --card-bg: #ffffff;
  --text-color: #333333;
}

body {
  font-family: Arial, sans-serif;
  margin: 0;
  padding: 0;
  background-color: var(--bg-color);
  color: var(--text-color);
}

/* Layout da Aplicação */
.app-container {
  display: flex;
  min-height: 100vh;
}

/* Menu Lateral (Sidebar) */
.sidebar {
  width: 240px;
  background-color: #001a75;
  color: #fff;
  padding: 20px 10px;
  display: flex;
  flex-direction: column;
  gap: 15px;
}

.sidebar h2 {
  font-size: 1.2rem;
  text-align: center;
  margin-bottom: 20px;
  border-bottom: 1px solid rgba(255,255,255,0.2);
  padding-bottom: 10px;
}

.sidebar button {
  background: none;
  border: 1px solid transparent;
  color: white;
  padding: 12px;
  text-align: left;
  cursor: pointer;
  border-radius: 4px;
  font-size: 0.95rem;
  transition: background 0.3s;
}

.sidebar button:hover, .sidebar button.active {
  background-color: rgba(255, 255, 255, 0.2);
  border-color: #fff;
}

/* Área Principal */
.main-content {
  flex: 1;
  padding: 10px;
  overflow-y: auto;
}

.card {
  background: var(--card-bg);
  border-radius: 8px;
  padding: 25px;
  box-shadow: 0 2px 10px rgba(0,0,0,0.08);
  margin-bottom: 20px;
}

/* Fluxo Visual de Etapas */
.steps-container {
  display: flex;
  justify-content: space-between;
  margin-top: 30px;
  position: relative;
}

.step-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  flex: 1;
  position: relative;
}

.step-icon {
  width: 60px;
  height: 60px;
  border-radius: 50%;
  background-color: #001a75;
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: bold;
  margin-bottom: 10px;
  border: 3px solid var(--accent-color);
}

.step-title {
  font-size: 0.85rem;
  font-weight: bold;
}

/* Formulários e Componentes */
.form-group {
  margin-bottom: 15px;
  display: flex;
  flex-direction: column;
}

.form-group label {
  margin-bottom: 5px;
  font-weight: bold;
  font-size: 0.9rem;
}

.form-group input, .form-group select {
  padding: 10px;
  border: 1px solid #ccc;
  border-radius: 4px;
  font-size: 1rem;
}

.btn-action {
  background-color: var(--accent-color);
  color: white;
  border: none;
  padding: 12px 25px;
  font-size: 1rem;
  border-radius: 4px;
  cursor: pointer;
  font-weight: bold;
}

.btn-action:hover {
  background-color: #e07b00;
}

.view-section {
  display: none;
}

.view-section.active {
  display: block;
}

/* Dashboard Admin */
.metrics-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 15px;
  margin-top: 20px;
}

.metric-card {
  background: #f0f4f8;
  border-left: 5px solid var(--accent-color);
  padding: 15px;
  border-radius: 4px;
}

.logo-container {
  display: flex;
  align-items: center;
}

.logo-container img {
  width: 162px;
  height: 55px;
  object-fit: contain;
}

/* Regras padrão Desktop para o Mobile Nav */
.mobile-nav-cards {
  display: none;
}

.desktop-home-content {
  display: block;
}

/* Esconde o botão hambúrguer no Desktop */
.hamburger-btn {
display: none;
}

/* ==========================================================================
 AJUSTES MOBILE (Telas até 768px)
 ========================================================================== */
@media screen and (max-width: 768px) {

.app-container {
  flex-direction: column !important;
  width: 100% !important;
}

.sidebar {
  width: 100% !important;
  padding: 10px 15px !important;
  box-sizing: border-box !important;
  position: relative !important;
}

/* Cabeçalho da Sidebar no Mobile (Apenas Logo) */
.sidebar-header {
  display: flex !important;
  justify-content: center !important;
  align-items: center !important;
  width: 100% !important;
}

/* Desativa Botão Hambúrguer e Menu Suspenso Antigo */
.hamburger-btn,
.sidebar-menu {
  display: none !important;
}

/* Desativa o modulos/home.php no mobile */
.desktop-home-content {
  display: none !important;
}

/* Exibe os Cards de Navegação em Grade 2x2 no Mobile */
/* Cards de Navegação Quadrados e Grandes no Mobile */
.mobile-nav-cards {
  display: flex !important;
  flex-direction: column !important;
  gap: 16px;
  margin-bottom: 25px;
  width: 100%;
  box-sizing: border-box;
}

.mobile-card {
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 16px;
  aspect-ratio: 1 / 1; /* Garante que o card seja um quadrado perfeito */
  padding: 24px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  cursor: pointer;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.06);
  transition: all 0.2s ease;
}

.mobile-card:hover,
.mobile-card.active {
  border-color: var(--accent-color);
  background-color: #fffaf5;
  transform: translateY(-2px);
}

.mobile-card-icon {
  font-size: 3.5rem; /* Ícone em destaque grande */
  margin-bottom: 12px;
  line-height: 1;
}

.mobile-card-title {
  font-size: 1.2rem; /* Texto maior e centralizado */
  color: #0f172a;
  font-weight: 700;
  line-height: 1.3;
}

/* Ajustes gerais de layout no mobile */
.main-content {
  width: 100% !important;
  padding: 15px 10px !important;
  box-sizing: border-box !important;
}

.steps-container {
  display: flex !important;
  flex-direction: column !important;
  gap: 12px !important;
}

.metrics-grid {
  display: grid !important;
  grid-template-columns: 1fr !important;
  gap: 10px !important;
}
}

/* ==========================================================================
 Accordion / Relação de Documentos Moderno
 ========================================================================== */
.section-desc {
  color: #666;
  margin-bottom: 20px;
  font-size: 0.95rem;
}

.doc-group {
  margin-bottom: 25px;
}

.doc-group-title {
  font-size: 1.1rem;
  font-weight: 700;
  color: #1f3c88;
  border-bottom: 2px solid #e2e8f0;
  padding-bottom: 6px;
  margin-bottom: 12px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.accordion-item {
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  margin-bottom: 8px;
  overflow: hidden;
  background: #fff;
  transition: all 0.2s ease;
}

.accordion-item:hover {
  border-color: #cbd5e1;
}

.accordion-header {
  width: 100%;
  padding: 14px 18px;
  background: #f8fafc;
  border: none;
  display: flex;
  justify-content: space-between;
  align-items: center;
  text-align: left;
  font-size: 0.95rem;
  font-weight: 600;
  color: #334155;
  cursor: pointer;
  transition: background 0.2s ease, color 0.2s ease;
}

.accordion-header:hover {
  background: #f1f5f9;
  color: #1f3c88;
}

.accordion-header .icon {
  font-size: 1.3rem;
  font-weight: bold;
  color: #64748b;
  transition: transform 0.3s ease;
}

/* Quando expandido */
.accordion-item.active .accordion-header {
  background: #edf2f7;
  color: #1f3c88;
}

.accordion-item.active .accordion-header .icon {
  transform: rotate(45deg);
  color: #1f3c88;
}

.accordion-body {
  max-height: 0;
  overflow: hidden;
  padding: 0 18px;
  background: #ffffff;
  transition: max-height 0.3s cubic-bezier(0, 1, 0, 1), padding 0.3s ease;
  font-size: 0.9rem;
  color: #475569;
  line-height: 1.6;
}

.accordion-item.active .accordion-body {
  max-height: 1000px;
  padding: 15px 18px;
}

.accordion-body ul {
  padding-left: 20px;
  margin: 8px 0;
}

.accordion-body ul li {
  margin-bottom: 6px;
}

.two-columns {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 6px;
}

.alert-box {
  background-color: #fffbeb;
  border-left: 4px solid #f59e0b;
  padding: 10px 14px;
  margin-top: 10px;
  border-radius: 4px;
  font-size: 0.85rem;
  color: #92400e;
}

.doc-images {
  display: flex;
  gap: 10px;
  margin-bottom: 10px;
}

.doc-images img {
  max-height: 50px;
  border-radius: 4px;
  border: 1px solid #ddd;
}

/* --- ESTILOS DO MODAL --- */
.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0,0,0,0.6);
  display: none;
  justify-content: center;
  align-items: flex-start;
  z-index: 9999;
  overflow-y: auto;
  padding: 40px 0;
}

.modal-content {
  background: #fff;
  width: 90%;
  max-width: 800px;
  border-radius: 8px;
  padding: 30px;
  position: relative;
  box-shadow: 0 5px 15px rgba(0,0,0,0.3);
  margin: auto;
}

.close-modal {
  position: absolute;
  top: 15px;
  right: 20px;
  font-size: 28px;
  font-weight: bold;
  color: #aaa;
  cursor: pointer;
}

.close-modal:hover {
  color: #000;
}

.relacao_documentos {
  color: #333;
  font-size: 14px;
  line-height: 1.6;
}

.relacao_documentos h3 {
  color: #4682B4;
  margin-top: 0;
}

.relacao_documentos .input-read {
  width: 100%;
  padding: 8px;
  margin-bottom: 10px;
  border: 1px solid #ddd;
  border-radius: 4px;
  background-color: #f9f9f9;
  font-weight: bold;
  box-sizing: border-box;
}

.footer {
  margin-top: 30px;
  padding: 10px 15px;
  border-top: 1px solid #eee;
  display: flex;
  justify-content: space-between;
  font-size: 12px;
  color: #fff;
  background: #2b2b2b;
  border-radius: 4px;
}

.main-content {
  width: 100% !important;
  max-width: 100% !important;
}

.status-card {
  width: 100% !important;
  max-width: 100% !important;
  box-sizing: border-box !important;
}

/* footer */
.footer-floating {
  position: fixed;
  bottom: 15px;
  right: 20px;
  background: #ffffff;
  padding: 8px 18px;
  border-radius: 50px;
  box-shadow: 0 4px 15px rgba(0,0,0,0.12);
  border: 1px solid #e2e8f0;
  z-index: 999;
  display: flex;
  align-items: center;
}

/* Container Geral */
.dashboard-container {
  display: flex;
  flex-direction: column;
  gap: 28px;
  max-width: 1100px;
  margin: 0 auto;
}

.card-section {
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  padding: 28px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
}

.card-header h1,
.card-header h2 {
  font-size: 1.35rem;
  color: #0f172a;
  margin: 0 0 6px 0;
  font-weight: 700;
}

.card-header p {
  color: #64748b;
  font-size: 0.92rem;
  margin: 0 0 24px 0;
}

.card-header.center {
  text-align: center;
}

.steps-mini {
  justify-content: center;
  gap: 40px;
  margin-bottom: 32px;
}

.step-icon.step-blue {
  background-color: #e0f2fe;
  color: #0284c7;
  border-color: #38bdf8;
}

.cta-banner {
  background: linear-gradient(135deg, #f8fafc 0%, #f1f5f9 100%);
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  padding: 20px 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  margin-top: 12px;
}

.cta-info h3 {
  margin: 0 0 4px 0;
  font-size: 1rem;
  color: #0f172a;
}

.cta-info p {
  margin: 0;
  font-size: 0.875rem;
  color: #64748b;
}

.features-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 16px;
}

.feature-card {
  background-color: #f8fafc;
  border: 1px solid #f1f5f9;
  border-radius: 10px;
  padding: 18px;
  display: flex;
  align-items: flex-start;
  gap: 14px;
}

.feature-icon {
  font-size: 1.6rem;
  background: #ffffff;
  border-radius: 8px;
  padding: 8px;
  box-shadow: 0 1px 3px rgba(0,0,0,0.05);
}

.feature-card h4 {
  margin: 0 0 4px 0;
  font-size: 0.95rem;
  color: #0f172a;
}

.feature-card p {
  margin: 0;
  font-size: 0.85rem;
  color: #64748b;
  line-height: 1.4;
}

@media (max-width: 768px) {
  .cta-banner {
    flex-direction: column;
    text-align: center;
  }
  
  .features-grid {
    grid-template-columns: 1fr;
  }

  .steps-container {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px 12px;
    align-items: start;
    justify-items: center;
  }

  .steps-mini {
    grid-template-columns: repeat(3, 1fr);
  }

  .step-item {
    width: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
  }

  .step-icon {
    flex-shrink: 0;
    margin-bottom: 8px;
  }

  .step-title {
    font-size: 0.75rem;
    line-height: 1.2;
  }
}

@media (max-width: 480px) {
  .steps-container {
    grid-template-columns: repeat(2, 1fr);
  }

  .steps-mini {
    grid-template-columns: 1fr;
    gap: 16px;
  }

  .steps-mini .step-item {
    flex-direction: row;
    text-align: left;
    background-color: #f8fafc;
    padding: 12px 16px;
    border-radius: 8px;
    border: 1px solid #e2e8f0;
  }

  .steps-mini .step-icon {
    margin-bottom: 0;
    margin-right: 14px;
  }
}

/* Transição suave no botão */
.btn-hover {
  transition: transform 0.2s ease-in-out, box-shadow 0.2s ease-in-out, background-color 0.2s ease-in-out;
}

/* Efeito de subir o botão e adicionar uma sombra sutil */
.btn-hover:hover {
  transform: translateY(-3px);
  box-shadow: 0 4px 10px rgba(13, 110, 253, 0.25); /* Sombra suave com a cor primária */
}

/* Efeito de elevação do card (se já estiver utilizando) */
.card-hover {
  transition: transform 0.2s ease-in-out, box-shadow 0.2s ease-in-out;
}

.card-hover:hover {
  transform: translateY(-4px);
  box-shadow: 0 0.5rem 1rem rgba(0, 0, 0, 0.1) !important;
}