:root {
  --bg-color: #121212;
  --primary-color: #facc15;
  --secondary-color: #1e293b;
  --text-color: #f1f5f9;
  --accent: #3b82f6;
  --header-color: #f7f7ed;
  --color2: #1e293b;
  --white1: #f7f7ed;
}
* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: 'Segoe UI', sans-serif;
  background-color: var(--bg-color);
  color: var(--text-color);
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

html, body {
  max-width: 100%;
  overflow-x: hidden;
}
h1,
h2 {
    color: var(--primary-color);
}


header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: var(--header-color);
  padding: 0 1rem 0 2rem;
  height: 100px;
}

.logo {
  display: flex;
  align-items: center;
  gap: 1rem;

}

a {
  text-decoration: none;
}

.logo img {
  height: 70px;
}

main {
  width: 100%;
  max-width: 1200px;      /* largura máxima em ecrãs grandes */
  min-width: 360px;       /* largura mínima para evitar layout apertado */
  padding: 1rem 2rem;
  margin: 0 auto;
  box-sizing: border-box;
}
@media (max-width: 768px) {
  main {
    padding: 1rem;
  }
}


.hero {
  text-align: center;
  padding: 3rem 2rem;
}

.hero h1 {
  font-size: 2.5rem;
  margin-bottom: 1rem;
  color: var(--primary-color);
}

.hero p {
  font-size: 1.2rem;
  max-width: 700px;
  margin: auto;
  color: #cbd5e1;
}

.jam-form {
  margin-top: 2rem;
}

.jam-form input {
  padding: 0.7rem 1rem;
  font-size: 1.1rem;
  border-radius: 5px;
  border: none;
  margin-right: 1rem;
}

.jam-form button {
  background: var(--primary-color);
  border: none;
  padding: 0.7rem 1.2rem;
  font-weight: bold;
  font-size: 1rem;
  border-radius: 5px;
  cursor: pointer;
}

.features {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 24px;
  padding: 48px 24px;
  background-color: var(--white1);
  color: white;
  text-align: center;
}

.feature {
  background-color: #222;
  border-radius: 12px;
  padding: 24px;
  max-width: 300px;
  flex: 1 0 250px;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.3);
  transition: transform 0.3s ease;
}

.feature:hover {
  transform: translateY(-4px);
}

.feature h3 {
  font-size: 20px;
  margin-bottom: 12px;
}

.feature p {
  font-size: 16px;
  line-height: 1.5;
}

.feature-cards {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 24px;
  padding: 40px 20px;
  background-color: #fefefe;
}

.card {
  background-color: #111;
  color: #fff;
  border-radius: 12px;
  padding: 24px;
  max-width: 320px;
  flex: 1 1 280px;
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.3);
  text-align: center;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.card:hover {
  transform: translateY(-6px);
  box-shadow: 0 12px 25px rgba(255, 193, 7, 0.2);
}

.card img {
  width: 64px;
  height: 64px;
  margin-bottom: 16px;
}

.card h3 {
  font-size: 18px;
  margin-bottom: 12px;
  color: #ffc107;
}

.card p {
  font-size: 15px;
  line-height: 1.5;
}

/* Responsivo */
@media (max-width: 768px) {
  .feature-cards {
    flex-direction: column;
    align-items: center;
  }
}



.screenshot {
  margin: 2rem auto;
  max-width: 90%;
  display: block;
  border: 2px solid var(--primary-color);
  border-radius: 8px;
}

footer {
  margin-top: auto;
  text-align: center;
  padding: 2rem;
  font-size: 0.9rem;
  background-color: var(--secondary-color);
}

.site-footer a {
  color: #ffc107;
  text-decoration: none;
}

.site-footer a:hover {
  text-decoration: underline;
}

.header-title {
  color: var(--color2);
}

nav {
  display: flex;
  gap: 1.5rem;
}

nav {
  display: flex;
  gap: 1.5rem;
}

nav a {
  color: var(--color2);
  text-decoration: none;
  font-weight: bold;
  font-size: 1rem;
  transition: color 0.2s ease;
}

nav a:hover {
  color: var(--accent);
}

.menu-toggle {
  display: none;
  font-size: 2rem;
  background: none;
  border: none;
  cursor: pointer;
  color: var(--color2);
}

.menu-container {
  position: relative;
}

.menu-button {
  background: none;
  border: none;
  font-size: 1.8rem;
  cursor: pointer;
  color: #1e293b;
  display: none;
}

/* Torna visível apenas em mobile */
@media (max-width: 768px) {
  .menu-button {
    display: block;
  }

  .menu-items {
    display: none;
    /* só mostra quando ativado por JS */
  }

  .menu-items.menu-visible {
    position: absolute;
    top: 2.5rem;
    right: 0;
    background-color: #fff;
    color: #1e293b;
    border-radius: 6px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
    flex-direction: column;
    min-width: 170px;
    z-index: 999;
    text-align: center;
    margin-right: 0px;
  }
  .menu-items a {
    padding: 10px 10px;
  }
}

.menu-items {
  top: 2.5rem;
  right: 0;
  color: #1e293b;
  flex-direction: row;
  min-width: 140px;
  z-index: 999;
  margin-right: 110px;
}

.menu-items a {
  padding: 8px 8px;
  text-decoration: none;
  color: inherit;
  font-weight: bold;
  transition: background 0.2s;
}

.menu-items a:hover {
  background-color: #facc15;
  color: #1e293b;
}

.menu-visible {
  display: flex;
}

footer a {
  color: white;
  text-decoration: none;
}

footer a:hover {
  color: #cbd5e1;
}

@media (max-width: 768px) {
  nav {
    display: none;
    flex-direction: column;
    position: absolute;
    top: 80px;
    right: 20px;
    background: var(--bg-color);
    border-radius: 8px;
    padding: 1rem;
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.4);
    z-index: 100;
    min-width: 140px;
  }

  nav a {
    color: var(--text-color);
    padding: 0.5rem 0;
  }

  nav.show {
    display: flex;
  }

  .menu-toggle {
    display: block;
    font-weight: bold;
    font-size: 3rem;
  }
}

.login-body {
  margin: 0;
  background-color: #0d0d0d;
  color: white;
  font-family: 'Segoe UI', sans-serif;
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

.login-container {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 40px 20px;
}

.login-box {
  background-color: #1a1a1a;
  padding: 32px;
  border-radius: 12px;
  box-shadow: 0 0 20px rgba(255, 193, 7, 0.1);
  max-width: 400px;
  width: 100%;
  text-align: center;
}

.login-box h2 {
  color: #ffc107;
  margin-bottom: 24px;
}

.login-box input {
  width: 100%;
  padding: 12px;
  margin: 8px 0;
  border: none;
  border-radius: 8px;
  font-size: 16px;
}

.login-box button {
  width: 100%;
  padding: 12px;
  background-color: #ffc107;
  border: none;
  border-radius: 8px;
  font-weight: bold;
  font-size: 16px;
  color: #111;
  margin-top: 12px;
  cursor: pointer;
  transition: background-color 0.3s ease;
}

.login-box button:hover {
  background-color: #e0a800;
}

.register-link {
  margin-top: 16px;
  font-size: 14px;
  color: #ccc;
}

.register-link a {
  color: #ffc107;
  text-decoration: none;
}

.admin-container {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 40px 20px;
  max-width: 900px;
}

.admin-users table {
  width: 100%;
  border-collapse: collapse;
  margin-top: 20px;
  font-size: 16px;
  color: #fff;
}

.admin-users th, .admini-users td {
  padding: 12px 16px;
  text-align: left;
  border-bottom: 1px solid #333;
}

.admin-users th {
  color: #ffc107;
  font-weight: bold;
}
.admin-users td {
  padding: 5px 20px 0px 0px;
}

.admin-users tr:hover {
  background-color: #222;
  transition: background 0.2s ease;
}

.admin-users a {
  color: #ffc107;
  text-decoration: none;
  font-weight: bold;
}

.admin-users a:hover {
  text-decoration: underline;
}

/* Estilo responsivo para admin-utilizadores */
@media (max-width: 768px) {
  .admin-users {
    padding: 16px;
    box-shadow: none;
    border-radius: 0;
    max-width: 100%;
  }

  .admin-users table {
    font-size: 14px;
    width: 100%;
    display: block;
    overflow-x: auto;
  }

  .admin-users thead {
    display: none;
  }

  .admin-users tr {
    display: block;
    margin-bottom: 12px;
    border: 1px solid #333;
    border-radius: 8px;
    padding: 12px;
  }

  .admin-users td {
    display: flex;
    justify-content: space-between;
    padding: 6px 8px;
    border: none;
    border-bottom: 1px solid #333;
  }

  .admin-users td:last-child {
    border-bottom: none;
  }

  .admin-users td::before {
    content: attr(data-label);
    font-weight: bold;
    color: #ccc;
  }
}

