/* Reset básico */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}
body {
  font-family: 'Segoe UI', sans-serif;
  background-color: #f4f4f4;
  display: flex;
  min-height: 100vh;
  position: relative;
}

/* Fundo decorativo */
body::before {
  content: "";
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-image: url('fundo.jpg');
  background-size: cover;
  background-position: center;
  opacity: 0.08;
  z-index: -1;
}

/* Cabeçalho fixo */
header {
  position: fixed;
  top: 0;
  left: 240px;
  right: 0;
  height: 70px;
  background-color: #ffffff;
  border-bottom: 1px solid #ddd;
  display: flex;
  align-items: center;
  padding: 0 30px;
  z-index: 1000;
}
.logo-area {
  display: flex;
  align-items: center;
  gap: 15px;
}
.logo-area img {
  height: 40px;
}
.logo-area h1 {
  font-size: 22px;
  color: #2c3e50;
}

/* Barra lateral */
.sidebar {
  width: 240px;
  background-color: #1e2a38;
  color: white;
  position: fixed;
  height: 100%;
  padding-top: 20px;
  box-shadow: 2px 0 5px rgba(0,0,0,0.2);
  z-index: 999;
}
.sidebar .logo {
  text-align: center;
  margin-bottom: 20px;
}
.sidebar .logo img {
  max-width: 80%;
  height: auto;
  max-height: 100px;
}
.sidebar nav {
  display: flex;
  flex-direction: column;
  padding: 0 10px;
}
.sidebar nav a {
  display: flex;
  align-items: center;
  gap: 10px;
  color: white;
  padding: 12px 16px;
  text-decoration: none;
  font-weight: bold;
  border-radius: 6px;
  transition: background 0.3s;
}
.sidebar nav a:hover {
  background-color: #2c3e50;
}
.sidebar nav a::before {
  content: "📁";
  font-size: 18px;
}

/* Conteúdo principal */
.main {
  margin-left: 240px;
  margin-top: 80px;
  padding: 30px;
  flex: 1;
  background-color: #f9f9f9;
  min-height: calc(100vh - 80px);
}
.main h1, .main h2 {
  color: #2c3e50;
  margin-bottom: 20px;
}

/* Cards para painel */
.grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 20px;
  margin-top: 20px;
}
.card {
  background: white;
  padding: 20px;
  border-radius: 10px;
  text-decoration: none;
  color: #2c3e50;
  box-shadow: 0 2px 8px rgba(0,0,0,0.1);
  transition: transform 0.2s, box-shadow 0.2s;
}
.card:hover {
  transform: translateY(-5px);
  box-shadow: 0 4px 12px rgba(0,0,0,0.15);
}
.card h2 {
  margin-bottom: 10px;
  font-size: 22px;
}
.card p {
  font-size: 14px;
  color: #555;
}

/* Formulários e botões */
form {
  background: white;
  padding: 20px;
  border-radius: 8px;
  box-shadow: 0 0 10px rgba(0,0,0,0.1);
  max-width: 600px;
}
input[type="text"], input[type="file"], input[type="number"] {
  padding: 10px;
  width: 100%;
  margin-bottom: 15px;
  border: 1px solid #ccc;
  border-radius: 6px;
}
button {
  background-color: #2c3e50;
  color: white;
  border: none;
  padding: 12px 24px;
  font-weight: bold;
  cursor: pointer;
  border-radius: 6px;
  transition: background 0.3s;
}
button:hover {
  background-color: #1e2a38;
}

/* Tabela de peças */
table {
  width: 100%;
  border-collapse: collapse;
  background: white;
  box-shadow: 0 0 10px rgba(0,0,0,0.05);
}
th, td {
  padding: 12px;
  border-bottom: 1px solid #ddd;
  text-align: left;
}
th {
  background-color: #f0f0f0;
  font-weight: bold;
}
img {
  border-radius: 6px;
}

/* Botão flutuante do WhatsApp */
.whatsapp-float {
  position: fixed;
  bottom: 20px;
  right: 20px;
  background-color: #25D366;
  color: white;
  border-radius: 50%;
  width: 60px;
  height: 60px;
  text-align: center;
  font-size: 30px;
  line-height: 60px;
  box-shadow: 0 4px 10px rgba(0,0,0,0.3);
  z-index: 999;
  animation: pulse 2s infinite;
}
.whatsapp-float:hover {
  background-color: #1ebe5d;
  cursor: pointer;
}

/* Animação pulsante */
@keyframes pulse {
  0% { transform: scale(1); }
  50% { transform: scale(1.1); }
  100% { transform: scale(1); }
}