/* =========================================================
   CCA — folha de estilos
   Todas as cores, fontes e espaçamentos ficam em variáveis
   aqui no topo. Para editar a identidade visual, mude só
   os valores abaixo — o resto do CSS usa essas variáveis.
   ========================================================= */
:root {
  /* --- Cores da marca (edite aqui) --- */
  --color-header: #101e4a;          /* barra superior */
  --color-bg: #f3f5f9;              /* fundo geral */
  --color-card-1: #1ea354;          /* card "Condutor" (verde) */
  --color-card-1-dark: #158341;
  --color-card-2: #d8a411;          /* card "Veículos" (amarelo/ouro) */
  --color-card-2-dark: #b98b0c;
  --color-card-3: #16215c;          /* card "Infrações" (azul-marinho) */
  --color-card-3-dark: #0f1740;
  --color-card-4: #5197e8;          /* card "Educação" (azul claro) */
  --color-card-4-dark: #3d7cd1;
  --color-alert-bg: #ffc94d;        /* banner de aviso */
  --color-text-dark: #14193a;
  --color-text-muted: #8a93a8;
  --color-white: #ffffff;

  /* --- Tipografia --- */
  --font-main: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif;
  /* EDITÁVEL: fonte usada em todo o site (Inter tem vários pesos: 400 a 900) */
  /* EDITÁVEL: fonte usada em todo o site */

  /* --- Layout --- */
  --max-width: 420px;
  --radius-lg: 18px;
  --radius-md: 14px;
  --footer-logo-height: 100px;      /* EDITÁVEL: altura das 3 imagens do rodapé */
  --footer-images-height: 48px;   /* EDITÁVEL: altura das 3 imagens do rodapé */
}

* { box-sizing: border-box; }

body {
  margin: 0;
  font-family: var(--font-main);
  background: var(--color-bg);
  color: var(--color-text-dark);
  display: flex;
  justify-content: center;
}

.app {
  width: 100%;
  max-width: var(--max-width);
  min-height: 100vh;
  background: var(--color-bg);
  position: relative;
  overflow: hidden;
}

/* ---------- Header ---------- */
.header {
  background: var(--color-header);
  color: var(--color-white);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px 20px;
  position: relative;
  z-index: 2;
}

.header .header-title {
  font-size: 18px;
  font-weight: 700;
  letter-spacing: 0.5px;
  /* EDITÁVEL: troque "ELLEN" no HTML pelo nome que quiser mostrar aqui */
}

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

.icon-btn {
  width: 22px;
  height: 22px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  background: none;
  border: none;
  padding: 0;
  transition: opacity 0.15s ease, transform 0.15s ease;
}
.icon-btn img { width: 100%; height: 100%; }
.icon-btn:hover { opacity: 0.75; }
.icon-btn:active { transform: scale(0.9); }

/* ---------- Círculo cinza ao redor da seta de voltar ---------- */
.back-btn-circle {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: #5b6478;
  /* EDITÁVEL: cor do círculo atrás da seta */
  flex-shrink: 0;
}
.back-btn-circle img {
  width: 16px;
  height: 16px;
  /* EDITÁVEL: tamanho da seta dentro do círculo */
}

/* ---------- Menu de opções (ícone de 3 pontos, canto superior esquerdo) ---------- */
.menu-dropdown {
  position: relative;
}
.menu-dropdown > summary {
  list-style: none;
  width: 22px;
  height: 22px;
  cursor: pointer;
  transition: opacity 0.15s ease, transform 0.15s ease;
}
.menu-dropdown > summary::-webkit-details-marker { display: none; }
.menu-dropdown > summary img { width: 100%; height: 100%; }
.menu-dropdown > summary:hover { opacity: 0.75; }
.menu-dropdown[open] > summary { transform: scale(0.92); }

.dropdown-panel {
  position: absolute;
  top: 32px;
  left: 0;
  background: var(--color-white);
  color: var(--color-text-dark);
  border-radius: var(--radius-md);
  box-shadow: 0 10px 26px rgba(20, 25, 58, 0.22);
  min-width: 190px;
  padding: 8px;
  z-index: 10;
  animation: dropdown-in 0.15s ease;
}

@keyframes dropdown-in {
  from { opacity: 0; transform: translateY(-6px); }
  to { opacity: 1; transform: translateY(0); }
}

.dropdown-panel a {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  border-radius: 10px;
  text-decoration: none;
  color: var(--color-text-dark);
  font-size: 13.5px;
  font-weight: 600;
  transition: background 0.15s ease;
}
.dropdown-panel a:hover {
  background: var(--color-bg);
}
.dropdown-panel a img {
  width: 18px;
  height: 18px;
}
/* Os ícones do menu usam a cor escura por padrão (icons/*.svg com stroke branco
   ficam invisíveis em fundo branco) — por isso este menu usa a classe
   .icon-dark, que aplica um filtro para escurecer os SVGs brancos. */
.dropdown-panel a img.icon-dark {
  filter: brightness(0) saturate(100%) invert(9%) sepia(35%) saturate(2500%) hue-rotate(215deg);
}

.avatar {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background: #3a4677;
  color: var(--color-white);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 14px;
  /* EDITÁVEL: troque a letra/imagem do avatar no HTML */
}

.header-title-with-back {
  display: flex;
  align-items: center;
  gap: 16px;
  font-size: 18px;
  font-weight: 700;
}

.header-stack {
  display: flex;
  flex-direction: column;
  gap: 1px;
}

.header-stack span:first-child {
  font-size: 18px;
  font-weight: 700;
  letter-spacing: 0.5px;
  line-height: 1.2;
  /* EDITÁVEL: mesmo tamanho/peso do título usado nas outras páginas */
}

.header-subtitle {
  font-size: 10px;
  font-weight: 600;
  opacity: 0.85;
  /* EDITÁVEL: texto do subtítulo (ex: data/hora) */
}

/* ---------- Link "adicione fotos aqui" ---------- */
.add-photos-link {
  text-align: center;
  margin: 0 0 18px;
  font-size: 15px;
  font-weight: 300;
  color: var(--color-text-dark);
  /* EDITÁVEL: "adicione fotos" fica fino; só "aqui" (abaixo) é destacado */
}
.add-photos-link a {
  color: #2456d1;
  font-weight: 700;
  text-decoration: none;
  /* EDITÁVEL: cor do link (só a palavra "aqui") */
}
.add-photos-link a:hover {
  text-decoration: underline;
}

.alert-banner-yellow {
  background: var(--color-alert-bg);
  margin: 0 0 18px;
  max-width: none;
  padding-top: 4px;
  padding-bottom: 4px;
  padding-left: 22px;
  padding-right: 22px;
  border-radius: 16px;
  justify-content: flex-start;
  /* EDITÁVEL: padding-top/padding-bottom controla só a altura da caixa */
}
.alert-banner-yellow img {
  width: 26px;
  height: 26px;
}
.alert-banner-yellow span {
  font-size: 15px;
  font-weight: 700;
  /* EDITÁVEL: tamanho/peso da letra do texto "NOVIDADE" */
}

/* ---------- Fundo decorativo (tela inicial) ---------- */
/* Cobre todo o lado direito da tela, do topo até embaixo */
.road-bg {
  position: absolute;
  top: 0;
  right: 0;
  width: 62%;
  height: 100%;
  opacity: 0.55;
  z-index: 0;
  pointer-events: none;
  object-fit: cover;
  transform: scaleX(-1); /* espelha o desenho pra "curvar" a partir da direita */
}

/* ---------- Cards do menu principal ---------- */
.menu {
  position: relative;
  z-index: 1;
  padding: 22px 18px;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.menu-card {
  border-radius: var(--radius-lg);
  padding: 20px 22px;
  color: var(--color-white);
  display: flex;
  align-items: center;
  justify-content: space-between;
  text-decoration: none;
  box-shadow: 0 8px 18px rgba(20, 25, 58, 0.12);
  min-height: 90px;
  transition: transform 0.18s ease, box-shadow 0.18s ease, filter 0.18s ease;
  will-change: transform;
}

.menu-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 12px 24px rgba(20, 25, 58, 0.18);
  filter: brightness(1.04);
}

.menu-card:active {
  transform: translateY(0px) scale(0.98);
  box-shadow: 0 6px 14px rgba(20, 25, 58, 0.14);
  filter: brightness(0.97);
}

.menu-card:focus-visible {
  outline: 3px solid #ffffff;
  outline-offset: 3px;
}

.menu-card .card-icon {
  transition: transform 0.25s ease;
}

.menu-card:hover .card-icon {
  transform: scale(1.08) rotate(-2deg);
}

.menu-card .card-text h2 {
  margin: 0 0 6px;
  font-size: 17px;
  letter-spacing: 0.3px;
}

.menu-card .card-text p {
  margin: 0;
  font-size: 13px;
  opacity: 0.92;
  line-height: 1.35;
  max-width: 220px;
}

.menu-card .card-icon {
  width: 40px;
  height: 40px;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}
.menu-card .card-icon img { width: 100%; height: 100%; }

.card-condutor  { background: linear-gradient(135deg, var(--color-card-1), var(--color-card-1-dark)); }
.card-veiculos  { background: linear-gradient(135deg, var(--color-card-2), var(--color-card-2-dark)); }
.card-infracoes { background: linear-gradient(135deg, var(--color-card-3), var(--color-card-3-dark)); }
.card-educacao  { background: linear-gradient(135deg, var(--color-card-4), var(--color-card-4-dark)); }

/* ---------- Rodapé de marca ---------- */
.brand-footer {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 16px 20px 22px;
  text-align: center;
  z-index: 1;
}

.brand-footer .brand-name {
  font-weight: 800;
  font-size: 15px;
  letter-spacing: 1px;
  color: var(--color-header);
  /* EDITÁVEL: nome/marca exibida no rodapé — troque "CCA" no HTML */
}

.brand-footer .brand-sub {
  margin-top: 2px;
  font-size: 11px;
  color: var(--color-text-muted);
  /* EDITÁVEL: texto pequeno abaixo da marca, opcional */
}

.brand-footer .brand-logo {
  height: 28px;
  margin-bottom: 4px;
  /* EDITÁVEL: coloque aqui o logotipo real (troque o src no HTML) */
}

/* ---------- Faixa de 3 imagens no rodapé (parceiros/selos) ----------
   3 posições: canto esquerdo, centro inferior e canto direito.
   Para vincular suas imagens, troque o "src" de cada <img class="partner-logo">
   no HTML, ou coloque os arquivos em images/rodape/ com os nomes indicados. */
.partner-logos {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  align-items: center;
  gap: 8px;
  padding: 0 18px;
  margin-bottom: 10px;
}

.partner-logos .slot {
  display: flex;
  align-items: center;
  min-height: var(--footer-logo-height);
}
.partner-logos .slot-left   { justify-content: flex-start; }
.partner-logos .slot-center { justify-content: center; }
.partner-logos .slot-right  { justify-content: flex-end; }

.partner-logos img {
  height: var(--footer-logo-height);
  max-width: 100%;
  object-fit: contain;
  opacity: 0.9;
}

/* ---------- Página Condutor ---------- */
.content {
  position: relative;
  z-index: 1;
  padding: 20px 18px 40px;
}

.content-tight {
  padding-top: 3px;
  /* EDITÁVEL: espaço entre o cabeçalho e o conteúdo abaixo dele */
}

.alert-banner {
  background: var(--color-alert-bg);
  border-radius: var(--radius-md);
  padding: 14px 16px;
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 18px;
  font-size: 13.5px;
  font-weight: 600;
  color: var(--color-text-dark);
  cursor: pointer;
  transition: filter 0.15s ease, transform 0.15s ease;
}
.alert-banner img { width: 20px; height: 20px; flex-shrink: 0; }
.alert-banner:hover { filter: brightness(0.97); }
.alert-banner:active { transform: scale(0.99); }

.info-card {
  background: var(--color-white);
  border-radius: var(--radius-lg);
  padding: 20px;
  box-shadow: 0 4px 14px rgba(20, 25, 58, 0.06);
  position: relative;
  margin-bottom: 18px;
}

.info-card h3 {
  margin: 0 0 12px;
  font-size: 16px;
  font-weight: 700;
}

.info-divider {
  height: 1px;
  background: #e6e9f0;
  margin: 0 0 18px;
  /* EDITÁVEL: cor/espessura da linha divisória */
}

.info-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px 20px;
}

.info-grid .field-full {
  grid-column: 1 / -1;
}

.info-grid .field label {
  display: block;
  font-size: 11.5px;
  color: var(--color-text-muted);
  margin-bottom: 3px;
}
.info-grid .field .value {
  font-size: 14.5px;
  font-weight: 700;
}

.action-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
}

.action-grid.grid-2x2 .action-box {
  min-height: 118px;
  justify-content: center;
}

.action-box {
  background: var(--color-white);
  border-radius: var(--radius-md);
  padding: 22px 12px;
  text-align: center;
  box-shadow: 0 4px 14px rgba(20, 25, 58, 0.06);
  text-decoration: none;
  color: var(--color-text-dark);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  border: 1px solid transparent;
  transition: transform 0.18s ease, box-shadow 0.18s ease, border-color 0.18s ease, background 0.18s ease;
}
.action-box img {
  width: 30px;
  height: 30px;
  transition: transform 0.2s ease;
}
.action-box span {
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.2px;
  transition: color 0.18s ease;
}

.action-box:hover {
  transform: translateY(-3px);
  box-shadow: 0 10px 20px rgba(20, 25, 58, 0.12);
  border-color: rgba(22, 33, 92, 0.12);
}

.action-box:hover img {
  transform: scale(1.1);
}

.action-box:hover span {
  color: var(--color-header);
}

.action-box:active {
  transform: translateY(0) scale(0.97);
  box-shadow: 0 4px 10px rgba(20, 25, 58, 0.08);
}

.action-box:focus-visible {
  outline: 3px solid var(--color-header);
  outline-offset: 2px;
}

.action-box.full {
  grid-column: 1 / -1;
  max-width: 200px;
  margin: 4px auto 0;
}

.circle-badge {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  border: 2px solid #2456d1;
  color: #2456d1;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 13px;
  /* EDITÁVEL: letra/ícone/cor do selo — troque "E" no HTML, cor aqui */
}

/* ---------- Carrossel genérico de imagens ----------
   Sem moldura, borda, sombra ou fundo — a foto se mescla
   direto com o fundo da página. */
.carousel {
  margin-bottom: 18px;
}

.carousel-track {
  overflow: hidden;
  position: relative;
}

.carousel-inner {
  display: flex;
  width: 100%;
  transition: transform 0.28s ease;
  /* A posição é controlada via JS (transform: translateX), um slide por vez */
}

.carousel-slide {
  flex: 0 0 100%;
  aspect-ratio: 3 / 4;
}

.carousel-slide img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  display: block;
  -webkit-user-drag: none;
  user-select: none;
  /* EDITÁVEL: "contain" mostra a foto inteira sem cortar; troque pra "cover" se preferir preencher o quadro cortando as bordas */
}

.carousel-dots {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 6px;
  margin-bottom: 22px;
}

.carousel-dots .dot {
  width: 8px;
  height: 8px;
  border-radius: 50px;
  border: none;
  padding: 0;
  background: #c7cbd8;
  /* EDITÁVEL: cor do marcador inativo */
  cursor: pointer;
  transition: background 0.2s ease, width 0.2s ease;
}

.carousel-dots .dot.active {
  background: #2456d1;
  /* EDITÁVEL: cor do marcador ativo */
  width: 22px;
}

.carousel-options {
  display: flex;
  flex-direction: column;
  gap: 12px;

  /* Variáveis de fonte só pra esta área (não afeta o resto do site) */
  --font-main: 'Baloo 2', sans-serif;
  --font-size-base: 16px;  /* tamanho base */
  --font-size-large: 20px; /* tamanho para títulos */
  --font-size-small: 12px; /* tamanho para textos pequenos */
}

/* ---------- Linha de opção (ícone + texto), estilo lista ---------- */
.option-row {
  display: flex;
  align-items: center;
  gap: 14px;
  background: var(--color-white);
  border-radius: 14px;
  padding: 16px 18px;
  box-shadow: 0 4px 14px rgba(20, 25, 58, 0.06);
  text-decoration: none;
  transition: transform 0.18s ease, box-shadow 0.18s ease;
  font-family: var(--font-main);
}
.option-row img {
  width: 22px;
  height: 22px;
  flex-shrink: 0;
}
.option-row span {
  color: #2456d1;
  font-weight: 700;
  font-size: var(--font-size-base);
  /* EDITÁVEL: cor/peso do texto da opção */
}
.option-row:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 18px rgba(20, 25, 58, 0.1);
}
.option-row:active {
  transform: translateY(0) scale(0.99);
}

/* ---------- Tela de seleção de perfil ---------- */
.profile-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px 14px;
  margin: 10px 0 26px;
}

.profile-card {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  font-family: var(--font-main);
}

.profile-select {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0;
  font-family: var(--font-main);
}

.profile-delete {
  position: absolute;
  top: -6px;
  right: 6px;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: #e34b4b;
  color: var(--color-white);
  border: 2px solid var(--color-bg);
  font-size: 14px;
  line-height: 1;
  font-weight: 700;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 2;
  transition: transform 0.15s ease, background 0.15s ease;
  /* EDITÁVEL: cor/posição do botão de excluir perfil */
}
.profile-delete:hover {
  background: #c93a3a;
  transform: scale(1.1);
}

.profile-avatar {
  width: 64px;
  height: 64px;
  border-radius: 16px;
  background: var(--color-header);
  color: var(--color-white);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 24px;
  font-weight: 800;
  transition: transform 0.18s ease, box-shadow 0.18s ease;
  /* EDITÁVEL: cor/formato do avatar de cada perfil */
}

.profile-select:hover .profile-avatar {
  transform: translateY(-3px);
  box-shadow: 0 8px 18px rgba(20, 25, 58, 0.18);
}

.profile-card span {
  font-size: 13px;
  font-weight: 700;
  color: var(--color-text-dark);
}

.profile-empty {
  text-align: center;
  color: var(--color-text-muted);
  font-size: 13.5px;
  font-family: var(--font-main);
  margin: 20px 0 26px;
  line-height: 1.5;
}

/* ---------- Cartão "+ Adicionar perfil" ---------- */
.add-profile-card {
  border-top: 1px solid #e6e9f0;
  padding-top: 20px;
}

.add-profile-toggle {
  width: 100%;
  background: var(--color-white);
  border: 1px dashed #c7cbd8;
  border-radius: 14px;
  padding: 14px;
  font-family: var(--font-main);
  font-weight: 700;
  font-size: 14px;
  color: var(--color-text-muted);
  cursor: pointer;
  transition: border-color 0.18s ease, color 0.18s ease;
}
.add-profile-toggle:hover {
  border-color: #2456d1;
  color: #2456d1;
}

.add-profile-form {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-top: 14px;
  background: var(--color-white);
  border-radius: 14px;
  padding: 18px;
  box-shadow: 0 4px 14px rgba(20, 25, 58, 0.06);
}

.add-profile-form label {
  display: flex;
  flex-direction: column;
  gap: 4px;
  font-size: 11.5px;
  color: var(--color-text-muted);
  font-weight: 600;
}

.add-profile-form input {
  font-family: var(--font-main);
  font-size: 14px;
  padding: 10px 12px;
  border: 1px solid #dfe2ea;
  border-radius: 10px;
  color: var(--color-text-dark);
  outline: none;
}
.add-profile-form input:focus {
  border-color: #2456d1;
}

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.add-profile-submit {
  margin-top: 4px;
  background: #2456d1;
  color: var(--color-white);
  border: none;
  border-radius: 10px;
  padding: 12px;
  font-family: var(--font-main);
  font-weight: 700;
  font-size: 14px;
  cursor: pointer;
  transition: filter 0.15s ease;
}
.add-profile-submit:hover {
  filter: brightness(1.08);
}
