/* Reset básico */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: 'Segoe UI', sans-serif;
  background-color: #f4f6f8;
  color: #333;
  padding-top: 70px;
  padding-bottom: 60px;
}

/* Cabeçalho fixo */
.main-header {
  width: 100%;
  background-color: #1a2b4c;
  color: white;
  box-shadow: 0 2px 5px rgba(0,0,0,0.1);
  position: fixed;
  top: 0;
  left: 0;
  z-index: 1000;
}

.nav-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 15px 30px;
  max-width: 1200px;
  margin: 0 auto;
}

.nav-left a {
  margin-right: 20px;
  color: white;
  text-decoration: none;
  font-weight: bold;
  transition: color 0.3s;
}

.nav-left a:hover {
  color: #f1c40f;
}

.nav-right {
  font-size: 0.95em;
}

.nav-right a {
  color: #ecf0f1;
  text-decoration: underline;
  margin-left: 10px;
}

.nav-right a:hover {
  color: #f1c40f;
}

/* Rodapé fixo */
.bottom-footer {
  width: 100%;
  height: 60px;
  background-color: #ecf0f1;
  color: #555;
  display: flex;
  justify-content: center;
  align-items: center;
  position: fixed;
  bottom: 0;
  left: 0;
  font-size: 0.9em;
  box-shadow: 0 -2px 5px rgba(0,0,0,0.05);
}

/* Container principal */
.container {
  max-width: 1000px;
  margin: 0 auto;
  padding: 30px;
}

/* Títulos */
.container h2 {
  text-align: center;
  margin-bottom: 30px;
  color: #2c3e50;
}

/* Botões */
.btn,
button[type="submit"] {
  display: inline-block;
  background-color: #3498db;
  color: white;
  padding: 10px 20px;
  border-radius: 6px;
  text-decoration: none;
  font-weight: bold;
  border: none;
  cursor: pointer;
  transition: background-color 0.3s;
}

.btn:hover,
button[type="submit"]:hover {
  background-color: #2980b9;
}

/* Dashboard */
.dashboard-container {
  display: flex;
  gap: 30px;
  max-width: 1200px;
  margin: 0 auto;
  padding: 20px;
}

.sidebar {
  width: 250px;
  background-color: #ffffff;
  padding: 20px;
  border-radius: 10px;
  box-shadow: 0 0 10px rgba(0,0,0,0.05);
}

.sidebar h3 {
  margin-bottom: 15px;
  font-size: 1.2em;
  color: #2c3e50;
}

.sidebar ul {
  list-style: none;
  padding: 0;
}

.sidebar ul li {
  margin-bottom: 12px;
}

.sidebar ul li a {
  text-decoration: none;
  color: #3498db;
  font-weight: bold;
  display: block;
  padding: 8px;
  border-radius: 5px;
  transition: background-color 0.3s;
}

.sidebar ul li a:hover {
  background-color: #ecf0f1;
}

.main-content {
  flex: 1;
  background-color: #ffffff;
  padding: 30px;
  border-radius: 10px;
  box-shadow: 0 0 10px rgba(0,0,0,0.05);
}

.main-content h2 {
  margin-bottom: 25px;
  color: #2c3e50;
  font-size: 1.5em;
}

.quick-links {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 15px;
}

.quick-links a {
  display: block;
  background-color: #3498db;
  color: white;
  text-align: center;
  padding: 15px;
  border-radius: 8px;
  text-decoration: none;
  font-weight: bold;
  transition: background-color 0.3s, transform 0.2s;
}

.quick-links a:hover {
  background-color: #2980b9;
  transform: scale(1.03);
}

/* Dieta e Refeições */
.refeicoes-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}

.refeicao-card {
  background-color: #f9f9f9;
  border: 1px solid #ccc;
  border-radius: 10px;
  padding: 20px;
  box-shadow: 0 0 8px rgba(0,0,0,0.03);
}

.refeicao-card h3 {
  margin-bottom: 10px;
  color: #3498db;
  font-size: 1.1em;
}

.refeicao-card p {
  margin: 8px 0;
  font-size: 0.95em;
  color: #333;
}

.refeicao-card label {
  display: block;
  margin-top: 10px;
  font-weight: bold;
  color: #333;
}

.refeicao-card textarea,
.refeicao-card input[type="time"] {
  width: 100%;
  padding: 8px;
  margin-top: 5px;
  border-radius: 5px;
  border: 1px solid #ccc;
  font-size: 0.95em;
  background-color: #fff;
}

/* Responsivo */
@media (max-width: 900px) {
  .refeicoes-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 600px) {
  .refeicoes-grid {
    grid-template-columns: 1fr;
  }

  .nav-bar {
    flex-direction: column;
    align-items: flex-start;
  }

  .nav-left,
  .nav-right {
    margin-top: 10px;
  }
}

/* Atividades - container principal */
.atividades-container {
  max-width: 900px;
  margin: 50px auto;
  padding: 30px;
  background-color: #ffffff;
  border-radius: 10px;
  box-shadow: 0 0 15px rgba(0,0,0,0.05);
}

/* Título da seção */
.atividades-container h2 {
  text-align: center;
  margin-bottom: 30px;
  color: #2c3e50;
}

/* Formulário de atividades */
.atividade-form label {
  display: block;
  margin-top: 15px;
  font-weight: bold;
  color: #333;
}

.atividade-form input[type="text"],
.atividade-form input[type="number"],
.atividade-form input[type="date"],
.atividade-form input[type="time"],
.atividade-form select,
.atividade-form textarea {
  width: 100%;
  padding: 10px;
  margin-top: 5px;
  border: 1px solid #ccc;
  border-radius: 5px;
  font-family: inherit;
  font-size: 1em;
  background-color: #fff;
}

/* Botão de envio */
.atividade-form button[type="submit"] {
  display: block;
  margin: 30px auto 0;
  padding: 12px 25px;
  background-color: #27ae60;
  color: white;
  border: none;
  border-radius: 6px;
  font-size: 1em;
  cursor: pointer;
  transition: background-color 0.3s;
}

.atividade-form button[type="submit"]:hover {
  background-color: #219150;
}

/* Mensagem de sucesso */
p.success-message {
  text-align: center;
  color: green;
  font-weight: bold;
  margin-bottom: 20px;
}

/* Lista de atividades registradas */
.atividade-lista {
  margin-top: 40px;
}

.atividade-item {
  background-color: #f9f9f9;
  border: 1px solid #ddd;
  border-radius: 8px;
  padding: 15px;
  margin-bottom: 15px;
  box-shadow: 0 0 5px rgba(0,0,0,0.03);
}

.atividade-item h4 {
  margin-bottom: 10px;
  color: #3498db;
}

.atividade-item p {
  margin: 5px 0;
  font-size: 0.95em;
  color: #555;
}

/* Filtro de progresso */
.filtro-box {
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
  align-items: center;
  background-color: #ffffff;
  padding: 20px;
  border-radius: 10px;
  box-shadow: 0 0 10px rgba(0,0,0,0.05);
  margin-bottom: 30px;
}

.filtro-box label {
  font-weight: bold;
  color: #2c3e50;
  margin-right: 10px;
}

.filtro-box select,
.filtro-box input[type="date"] {
  padding: 8px 12px;
  border: 1px solid #ccc;
  border-radius: 6px;
  font-size: 0.95em;
  background-color: #f9f9f9;
  min-width: 180px;
}

.filtro-box .btn {
  margin-top: 5px;
  padding: 10px 20px;
  background-color: #27ae60;
}

.filtro-box .btn:hover {
  background-color: #219150;
}

.perfil-container {
  max-width: 600px;
  margin: 40px auto;
  background-color: #fefefe;
  padding: 30px;
  border-radius: 12px;
  box-shadow: 0 0 20px rgba(0,0,0,0.05);
}

.perfil-container h2 {
  margin-bottom: 25px;
  font-size: 1.8em;
  color: #2c3e50;
  text-align: center;
}

.perfil-form {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.form-row {
  display: flex;
  flex-direction: column;
}

.form-row label {
  font-weight: 600;
  margin-bottom: 6px;
  color: #34495e;
}

.form-row input {
  padding: 10px 12px;
  border: 1px solid #ccc;
  border-radius: 8px;
  font-size: 1rem;
  background-color: #f9f9f9;
  transition: border-color 0.3s ease;
}

.form-row input:focus {
  border-color: #27ae60;
  outline: none;
}

.btn-salvar {
  background-color: #27ae60;
  color: white;
  padding: 12px;
  border: none;
  border-radius: 8px;
  font-size: 1rem;
  cursor: pointer;
  transition: background-color 0.3s ease;
}

.btn-salvar:hover {
  background-color: #219150;
}

.alert {
  padding: 12px;
  border-radius: 8px;
  margin-bottom: 20px;
  font-weight: bold;
  text-align: center;
}

.alert.success {
  background-color: #eafaf1;
  color: #2e7d32;
  border-left: 5px solid #2ecc71;
}

.alert.error {
  background-color: #fdecea;
  color: #c0392b;
  border-left: 5px solid #e74c3c;
}

.auth-container {
    max-width: 700px;
    max-height: 900px;
    margin: 30px auto;
    background-color: #ffffff;
    padding: 20px;
    border-radius: 16px;
    font-size: 18px;
}

.auth-container h2 {
  text-align: center;
  margin-bottom: 30px;
  font-size: 28px;
  color: #2c3e50;
}

.auth-form {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.auth-form label {
  font-weight: 600;
  margin-bottom: 8px;
  color: #34495e;
  font-size: 18px;
}

.auth-form input {
  padding: 14px 16px;
  border: 1px solid #ccc;
  border-radius: 10px;
  font-size: 1.05rem;
  background-color: #f9f9f9;
  transition: border-color 0.3s ease, box-shadow 0.3s ease;
}

.auth-form input:focus {
  border-color: #27ae60;
  box-shadow: 0 0 0 3px rgba(39, 174, 96, 0.2);
  outline: none;
}

.auth-form button {
  background-color: #27ae60;
  color: white;
  padding: 14px;
  border: none;
  border-radius: 10px;
  font-size: 1.1rem;
  font-weight: bold;
  cursor: pointer;
  transition: background-color 0.3s ease;
}

.auth-form button:hover {
  background-color: #219150;
}

.auth-footer {
  text-align: center;
  margin-top: 25px;
  font-size: 1rem;
}

.auth-footer a {
  color: #27ae60;
  text-decoration: none;
  font-weight: bold;
}

.auth-footer a:hover {
  text-decoration: underline;
}

.alert {
  padding: 14px;
  border-radius: 10px;
  margin-bottom: 25px;
  font-weight: bold;
  text-align: center;
  font-size: 1rem;
}

.alert.success {
  background-color: #eafaf1;
  color: #2e7d32;
  border-left: 6px solid #2ecc71;
}

.alert.error {
  background-color: #fdecea;
  color: #c0392b;
  border-left: 6px solid #e74c3c;
}