/* ALAP RESET */
* { box-sizing: border-box; margin: 0; padding: 0; }

/* TESTRESZABOTT BETŰK ÉS HŰSÉG */
body {
  font-family: 'Segoe UI', sans-serif;
  background: #f9f9f9;
  color: #333;
  min-height: 100vh;
  transition: background 0.3s, color 0.3s;
}
a {
  text-decoration: none;
  color: inherit;
}

/* HIDE/SHOW ANIMÁCIÓK */
.hidden { opacity: 0; transform: translateY(20px); }
.visible { opacity: 1; transform: translateY(0); transition: opacity 0.6s, transform 0.6s; }

/* NAVBAR */
.navbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1rem 2rem;
  color: #fff;
  background: #f9f9f9;
  position: sticky;
  top: 0;
  z-index: 1000;
}
.navbar-left .navbar-brand {
  font-size: 1.4rem;
  font-weight: bold;
}
.navbar a,
.theme-btn {
  color: #ffa726;
  margin-left: 1rem;
  transition: color 0.3s;
}
.navbar a:hover {
  color: #ff9100;
}
.theme-btn {
  background: #ffa726;
  border: none;
  cursor: pointer;
  font-size: 1.2rem;
  transition: transform 0.2s;
}
.theme-btn:hover { transform: scale(1.2); }

/* HAMBURGER */
.hamburger {
  display: none;
  background: none;
  border: none;
  font-size: 1.5rem;
  color: #ffa726;
  cursor: pointer;
  transition: transform 0.2s;
}
.hamburger:hover { transform: scale(1.2); }

@media (max-width: 768px) {
  .hamburger { display: block; margin-left: auto; }
  .navbar-right {
    display: none;
    flex-direction: column;
    width: 100%;
    background: inherit;
    margin-top: 0.5rem;
  }
  .navbar.open .navbar-right {
    display: flex;
    animation: fadeIn 0.3s ease forwards;
  }
}

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(-10px); }
  to { opacity: 1; transform: translateY(0); }
}

/* FORM, BUTTON */
form {
  margin: 1rem 0;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  max-width: 300px;
}
input,
textarea,
select,
button {
  padding: 10px;
  border: 1px solid #ccc;
  border-radius: 6px;
  font-size: 1rem;
  transition: transform 0.2s, background 0.2s;
}
button,
input[type="submit"] {
  background: #ff6a00;
  color: #fff;
  border: none;
  cursor: pointer;
}
button:hover {
  transform: scale(1.05);
  background: #e25900;
}
button:active { transform: scale(1); }

/* KÁRTYÁK */
.teamCard {
  background: #fff;
  padding: 1rem;
  margin: 1rem 0;
  border-radius: 10px;
  transition: transform 0.4s;
}
.teamCard:hover { transform: scale(1.03); }

/* LISTÁK */
ul {
  list-style: disc;
  padding-left: 1.5rem;
  margin: 1rem 0;
}
li { margin: 0.5rem 0; }

/* STATISZTIKA TÁBLÁZAT */
.stats-table {
  width: 100%;
  border-collapse: collapse;
  margin: 2rem 0;
  background: #fff;
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
}
.stats-table th,
.stats-table td {
  border: 1px solid #eee;
  padding: 0.75rem 1rem;
  text-align: left;
  font-size: 0.95rem;
}
.stats-table th {
  background-color: #f0f0f0;
  font-weight: 600;
}
.stats-table td:last-child { text-align: center; }

.delete-btn {
  background: #e53935;
  color: #fff;
  border: none;
  padding: 0.5rem 0.8rem;
  border-radius: 4px;
  cursor: pointer;
  transition: transform 0.1s;
}
.delete-btn:hover { transform: scale(1.1); }

/* "Vissza" gomb */
.btn {
  display: inline-block;
  margin: 2rem 0;
  background: #ffa726;
  color: #000;
  padding: 0.8rem 1.2rem;
  border-radius: 8px;
  font-weight: bold;
  transition: background 0.3s;
}
.btn:hover { background: #ff9100; }

/* SÖTÉT MÓD */
body.dark {
  background: #121212;
  color: #eee;
}
body.dark h1,
body.dark h2 { color: #ffa726; }
body.dark .navbar { background: #121212; }
body.dark input,
body.dark textarea,
body.dark select {
  background: #1e1e1e;
  color: #eee;
  border: 1px solid #444;
}
body.dark button,
body.dark .btn {
  background: #ffa726;
  color: #000;
}
body.dark button:hover,
body.dark .btn:hover { background: #ff9100; }
body.dark .stats-table { background: #1e1e1e; color: #eee; }
body.dark .stats-table th { background-color: #2a2a2a; }

/* MOBIL */
@media (max-width: 600px) {
  body { padding: 10px; }
  main { padding: 1rem; }
  .stats-table th,
  .stats-table td {
    padding: 0.5rem;
    font-size: 0.85rem;
  }
  .navbar {
    flex-direction: column;
    align-items: flex-start;
  }
  .navbar-right a,
  .theme-btn {
    padding: 0.5rem 0;
    width: 100%;
  }
  form { max-width: 100%; }
}

/* TEAMSTATS GRID */
#teamStats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 1.5rem;
  padding: 2rem;
  max-width: 1200px;
  margin: auto;
}
#teamStats li {
  background: #121212;
  color: #333;
  border-radius: 8px 16px 16px 8px;
  padding: 2rem;
  box-shadow: 0 8px 16px rgba(0, 0, 0, 0.1);
  font-size: 1.4rem;
  font-weight: bold;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  position: relative;
  transition: transform 0.3s, box-shadow 0.3s;
}
#teamStats li:hover {
  transform: translateY(-5px);
  box-shadow: 0 12px 24px rgba(0, 0, 0, 0.15);
}
#teamStats li::before {
  content: "🏆";
  font-size: 2rem;
  margin-bottom: 1rem;
}
#teamStats li::after {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 6px;
  height: 100%;
  background-color: currentColor;
  border-top-left-radius: 16px;
  border-bottom-left-radius: 16px;
}

/* --- KÁRTYÁK (admin cardok) --- */
.card {
  background: #fff;
  border-radius: 8px;
  box-shadow: 0 2px 5px rgba(0,0,0,0.1);
  margin-bottom: 1.5rem;
}
.card-header {
  padding: 0.75rem 1rem;
  background: #f0f0f0;
  font-weight: bold;
}
.card-body {
  padding: 1rem;
}

/* --- DARK MODE kártya és táblázat--- */
body.dark .card {
  background: #1e1e1e;
  box-shadow: 0 2px 5px rgba(0,0,0,0.4);
}
body.dark .card-header {
  background: #2a2a2a;
  color: #ffa726;
}
body.dark .card-body {
  background: #1e1e1e;
  color: #ddd;
}

/* --- ADMIN TÁBLÁZAT --- */
.stats-table {
  width: 100%;
  border-collapse: collapse;
}
.stats-table th,
.stats-table td {
  padding: 0.75rem;
  border: 1px solid #e0e0e0;
}
.stats-table th {
  background: #fafafa;
  font-weight: 600;
}
.stats-table td {
  background: #fff;
}
body.dark .stats-table th {
  background: #2a2a2a;
  color: #ffa726;
}
body.dark .stats-table td {
  background: #1e1e1e;
  color: #ddd;
  border-color: #333;
}

/* --- GOMBOK --- */
.btn {
  background: #007bff;
  color: #fff;
  border-radius: 4px;
  padding: 0.5rem 1rem;
  border: none;
  cursor: pointer;
}
.btn:hover {
  background: #0056b3;
}
.delete-btn {
  background: #e53935;
}
body.dark .btn {
  background: #ffa726;
  color: #000;
}
body.dark .btn:hover {
  background: #ff9100;
}
