* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  background: #080808;
  color: #fff;
  font-family: "Helvetica Neue", Arial, sans-serif;
}

a {
  color: inherit;
  text-decoration: none;
}

/* APP */
.lucro-app {
  min-height: 100vh;
  display: flex;
}

/* SIDEBAR IGUAL AO FINANCEIRO */
.financeiro-sidebar {
  width: 280px;
  min-height: 100vh;
  background: #0d0d0d;
  border-right: 1px solid #1a1a1a;
  padding: 28px;
  position: fixed;
  left: 0;
  top: 0;
}

.sidebar-logo-area {
  display: flex;
  align-items: center;
  gap: 14px;
  padding-bottom: 32px;
  border-bottom: 1px solid #1a1a1a;
  margin-bottom: 32px;
}

.sidebar-logo-area img {
  height: 46px;
  filter: invert(1);
}

.sidebar-logo-area span {
  color: #c9a84c;
  letter-spacing: 4px;
  font-size: 12px;
}

.sidebar-menu {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.sidebar-menu a {
  padding: 14px 16px;
  border-radius: 12px;
  color: #777;
  font-size: 12px;
  letter-spacing: 2px;
  text-transform: uppercase;
  transition: .25s;
}

.sidebar-menu a:hover,
.sidebar-menu a.ativo {
  background: #161616;
  color: #fff;
}

.sidebar-menu a.ativo {
  border: 1px solid #c9a84c;
}

.btn-sair {
  position: absolute;
  bottom: 28px;
  left: 28px;
  right: 28px;
  padding: 14px;
  background: transparent;
  border: 1px solid #2a2a2a;
  color: #777;
  border-radius: 12px;
  letter-spacing: 3px;
  cursor: pointer;
}

.btn-sair:hover {
  border-color: #ff4444;
  color: #ff4444;
}

/* CONTEÚDO */
.main {
  margin-left: 280px;
  width: calc(100% - 280px);
  padding: 40px;
}

.topo {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 36px;
}

.page-tag {
  color: #c9a84c;
  font-size: 11px;
  letter-spacing: 4px;
}

.topo h1 {
  font-size: 34px;
  font-weight: 300;
  letter-spacing: 2px;
  margin: 8px 0;
}

.topo p {
  color: #666;
  font-size: 14px;
}

.header-actions {
  display: flex;
  gap: 12px;
}

.header-actions a,
.header-actions button {
  padding: 12px 22px;
  background: #111;
  border: 1px solid #242424;
  color: #ddd;
  border-radius: 12px;
  font-size: 11px;
  letter-spacing: 2px;
  text-transform: uppercase;
  cursor: pointer;
}

.header-actions button:hover,
.header-actions a:hover {
  border-color: #c9a84c;
  color: #c9a84c;
}

button {
  border: none;
  background: #c9a84c;
  color: #111;
  padding: 12px 18px;
  border-radius: 12px;
  font-weight: bold;
  cursor: pointer;
}

button:hover {
  filter: brightness(1.08);
}

button:disabled {
  opacity: 0.7;
  cursor: not-allowed;
}

button.secundario {
  background: #222;
  color: #fff;
}

.cards {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 18px;
  margin-bottom: 20px;
}

.card,
.box,
.painel-andamento {
  background: #111;
  border: 1px solid #202020;
  border-radius: 22px;
}

.card {
  padding: 26px;
}

.card span {
  display: block;
  color: #777;
  font-size: 11px;
  letter-spacing: 2px;
  text-transform: uppercase;
  margin-bottom: 18px;
}

.card strong {
  display: block;
  color: #fff;
  font-size: 30px;
  font-weight: 400;
}

.painel-andamento {
  padding: 28px;
  margin-bottom: 24px;
}

.painel-andamento h2 {
  font-size: 18px;
  font-weight: 300;
  margin-bottom: 8px;
}

.painel-andamento p {
  margin-bottom: 18px;
  color: #666;
  font-size: 14px;
}

.barra {
  height: 18px;
  background: #292929;
  border-radius: 999px;
  overflow: hidden;
}

.barra div {
  width: 0%;
  height: 100%;
  background: linear-gradient(90deg, #c9a84c, #27c36a);
  transition: 0.4s;
}

#percentualRecuperado {
  display: block;
  margin-top: 10px;
  color: #c9a84c;
  font-weight: bold;
}

.grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
  margin-bottom: 24px;
}

.box {
  padding: 28px;
}

.box h2 {
  font-size: 18px;
  font-weight: 300;
  margin-bottom: 24px;
}

.formulario form {
  display: grid;
  gap: 14px;
}

label {
  display: grid;
  gap: 8px;
  color: #ccc;
  font-size: 13px;
}

input,
select,
textarea {
  width: 100%;
  border: 1px solid #333;
  background: #0c0c0c;
  color: #fff;
  padding: 12px;
  border-radius: 12px;
  outline: none;
}

textarea {
  min-height: 80px;
  resize: vertical;
}

input:focus,
select:focus,
textarea:focus {
  border-color: #c9a84c;
}

.acoes-form {
  display: flex;
  gap: 10px;
}

.grafico-box canvas {
  width: 100%;
  max-height: 320px;
  background: #101010;
  border-radius: 14px;
  padding: 10px;
}

.lista-categorias {
  display: grid;
  gap: 12px;
}

.categoria-item {
  display: flex;
  justify-content: space-between;
  background: #101010;
  border: 1px solid #252525;
  padding: 14px;
  border-radius: 12px;
}

.categoria-item strong {
  color: #c9a84c;
}

.resumo-extra {
  display: grid;
  gap: 14px;
}

.resumo-extra p {
  display: flex;
  justify-content: space-between;
  margin: 0;
  background: #101010;
  padding: 14px;
  border-radius: 12px;
}

.resumo-extra span {
  color: #aaa;
}

.resumo-extra strong {
  color: #c9a84c;
}

.titulo-linha {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.titulo-linha h2 {
  font-size: 18px;
  font-weight: 300;
}

.titulo-linha span {
  color: #777;
  font-size: 12px;
}

.tabela-scroll {
  overflow-x: auto;
}

table {
  width: 100%;
  border-collapse: collapse;
}

th,
td {
  padding: 18px 14px;
  border-bottom: 1px solid #1c1c1c;
  text-align: left;
}

th {
  color: #777;
  font-size: 11px;
  letter-spacing: 2px;
  text-transform: uppercase;
}

td {
  color: #ccc;
  font-size: 13px;
}

tr:hover {
  background: #141414;
}

.acoes {
  display: flex;
  gap: 8px;
}

.btn-mini {
  padding: 8px 10px;
  border-radius: 10px;
  font-size: 12px;
}

.btn-delete {
  background: #7a1f1f;
  color: #fff;
}

.valor-negativo {
  color: #ff5c5c !important;
}

.valor-positivo {
  color: #27c36a !important;
}

/* RESPONSIVO */
@media (max-width: 1100px) {
  .cards,
  .grid {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 800px) {
  .financeiro-sidebar {
    position: static;
    width: 100%;
    min-height: auto;
  }

  .lucro-app {
    flex-direction: column;
  }

  .main {
    margin-left: 0;
    width: 100%;
    padding: 24px;
  }

  .topo {
    flex-direction: column;
    gap: 20px;
  }

  .cards,
  .grid {
    grid-template-columns: 1fr;
  }

  .btn-sair {
    position: static;
    margin-top: 28px;
    width: 100%;
  }
}