@font-face {
  font-family: 'Nura';
  src: url('../fonts/Nura-SemiBold.ttf') format('truetype');
  font-weight: normal;
  font-style: normal;
}

* {
  box-sizing: border-box;
  font-family: 'Nura', sans-serif;
}

body {
  background-image: url('../img/what_the_hex.png');
  margin: 0;
  font-family: 'Arial', sans-serif;
  background-color: #1a1a1a;
  color: white;
  /* padding-top: 320px; */
}

header {
  width: 100%;
  height: 310px;
  background-image: url('../img/header_bg.jpg');
  background-size: cover;
  background-position: center -160px;
  position: relative;
  z-index: 1;
}

.nav-container {
  display: flex;
  justify-content: center;
  position: absolute;
  top: 20px;
  width: 100%;
  z-index: 10;
}

nav {
  background-color: #2a2a2a;
  padding: 1rem 3rem;
  border-radius: 40px;
  display: flex;
  justify-content: space-between; /* <- changement ici */
  align-items: center; /* <- pour aligner verticalement */
  width: 60%;
  max-width: 800px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.5);
  gap: 3rem; /* <- ESPACEMENT UNIFORME ENTRE TOUS LES ÉLÉMENTS */
}

/* Zone des liens gauche */
.nav-links,
.steam-login {
  display: flex;
  align-items: center;
  gap: 3rem; /* même écart entre chaque lien */
}

nav a,
.steam-text-link,
.logout-link {
  color: white;
  text-decoration: none;
  font-weight: bold;
  font-size: 1.1rem;
  text-transform: uppercase;
  position: relative;
  transition: color 0.3s ease;
  background-size: 200% auto;
  background-position: right center;
}



nav a::after,
.steam-text-link::after,
.logout-link::after {
  content: "";
  position: absolute;
  bottom: -6px;
  left: 0;
  width: 0%;
  height: 2px;
  background: white;
  transition: width 0.8s ease;
}

nav a:hover::after {
  width: 100%;
}

nav a:hover,
.steam-text-link:hover,
.logout-link:hover {
  background: linear-gradient(to right, #00aaff, #023562);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  text-fill-color: transparent;
  background-size: 200% auto;
  background-position: left center;
  transition: background-position 2.5s ease;
}

.steam-user {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.steam-avatar {
  width: 32px;
  height: 32px;
  border-radius: 50%;
}

.steam-name {
  color: white;
  font-weight: bold;
  font-size: 1rem;
}


.container {
  display: flex;
  justify-content: flex-start;
  align-items: flex-start;
  padding: 2rem;
}


.box {
  background-color: #202020;
  border-radius: 1rem;
  padding: 1.5rem;
  width: 300px;
  min-height: 300px;
}

.box h2 {
  text-align: center;
  font-size: 1.5rem;
  margin-bottom: 1rem;
}

.divider {
  position: absolute;
  bottom: -4px;
  left: 0;
  width: 100%;
  height: 4px;
  background: linear-gradient(to right, #00aaff, #023562);
  z-index: 2;
}

.cards-container {
  display: flex;
  justify-content: center;
  align-items: flex-start;
  gap: 2rem;
  margin-top: 3rem;
  flex-wrap: wrap;
}

.project-card {
  background: linear-gradient(to bottom, #1a1a1a, #132f50);
  border-radius: 1rem;
  padding: 1.5rem;
  text-align: center;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.5);
  color: white;
  transition: transform 0.4s ease, box-shadow 0.4s ease
}


.project-card:hover {
  transform: translateY(-10px) scale(1.03);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.6);
}

.project-card h2 {
  font-size: 1rem;
  margin-bottom: 1rem;
  font-family: 'Nura', sans-serif;
}

.project-card .btn {
  display: inline-block;
  padding: 0.5rem 1.2rem;
  background: #2d2d2d;
  color: white;
  font-weight: bold;
  border-radius: 20px;
  text-decoration: none;
  margin-top: 1.2rem;
  font-size: 0.85rem;
  transition: background 0.3s ease;
}

.project-card .btn:hover {
  background: #444;
}

.project-card .project-img {
  width: 100%;
  max-width: 120px;
  margin: auto;
}


.project-card.small {
  width: 220px;
}

.project-card.large {
  width: 300px;
}

.page-wrapper {
  min-height: calc(100vh - 80px);
}

.site-footer {
  position: relative;
  background: linear-gradient(to bottom, #1a1a1a, #132f50);
  padding: 1rem 2rem;
  text-align: center;
  font-family: 'Nura', sans-serif;
  font-size: 0.85rem;
  color: #888;
  height: 80px;
  overflow: hidden;
}

/* Dégradé sur le footer
.site-footer::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 4px; 
  background: linear-gradient(to right, #00aaff, #023562); 
}
*/

.footer-content a.footer-link {
  color: #888;
  text-decoration: none;
  font-weight: 500;
  transition: background-position 0.5s ease;
  background: linear-gradient(to right, #888, #888);
  background-clip: text;
  -webkit-background-clip: text;
  color: transparent;
  -webkit-text-fill-color: transparent;
  background-size: 200% auto;
  background-position: right center;
}

.footer-content a.footer-link:hover {
  background: linear-gradient(to right, #00aaff, #023562);
  background-clip: text;
  -webkit-background-clip: text;
  background-size: 200% auto;
  background-position: left center;
  -webkit-text-fill-color: transparent;
  text-fill-color: transparent;
}


.footer-content {
  display: flex;
  justify-content: center;
  gap: 4rem;
  flex-wrap: wrap;
  padding-top: 1.2rem;
}

.admin-card-link {
  display: block;
  text-decoration: none;
  max-width: 900px;
  margin: 1rem auto;
}

.admin-card-link:hover .admin-card {
  transform: scale(1.02);
}

.admin-card {
  display: flex;
  background: linear-gradient(to right, #333, #22577A);
  border-radius: 20px;
  overflow: hidden;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.5);
  transition: transform 0.2s ease;
}

/* Partie gauche (icône avec fond sombre et séparation) */
.admin-card-icon {
  background: linear-gradient(to right, #333, #22577A); /* bleu foncé à bleu */
  padding: 15px;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 70px;
  border-right: 3px solid #000000; /* séparateur vertical visible */
}

.admin-card-icon img {
  width: 30px;
  height: 30px;
  filter: brightness(0) invert(1);
}

/* Texte */
.admin-card-text {
  display: flex;
  align-items: center;
  padding: 0 20px;
  flex-grow: 1;
}

.admin-card-text h2 {
  color: #fff;
  font-size: 1.3rem;
  font-weight: bold;
  margin: 0;
}


/* Container général */
.ranks-container {
  display: flex;
  flex-wrap: wrap;
  gap: 1.5rem;
  justify-content: center;
  margin: 2rem auto;
  max-width: 1200px;
}

/* Carte individuelle */
.rank-card {
  background-color: #1f1f1f;
  border: 3px solid #00aa00;
  border-radius: 20px;
  padding: 1.5rem;
  width: 300px;
  color: white;
  box-shadow: 0 0 10px #00000055;
  position: relative;
  transition: border-color 0.3s ease, box-shadow 0.3s ease;
}

.rank-card.red {
  border-color: #ff4444;
}

/* En-tête de carte */
.rank-card-header {
  display: inline-block;
  padding: 0.4rem 1.2rem;
  font-weight: bold;
  border-radius: 999px;
  background-color: #111; /* fond noir */
  border: 2px solid transparent; /* sera override inline */
  color: white;
  font-size: 1rem;
  margin: 1rem auto;
}



/* Boutons */
.rank-btn,
.modifier-btn {
  display: block;
  margin: 0.5rem auto;
  padding: 0.5rem 1rem;
  border-radius: 30px;
  border: none;
  background: linear-gradient(90deg, #004080, #0077cc);
  color: white;
  cursor: pointer;
  font-weight: bold;
  transition: background 0.3s;
}

.rank-btn:hover,
.modifier-btn:hover {
  background: linear-gradient(90deg, #0066aa, #0099ff);
}

.rank-btn.red {
  background: linear-gradient(90deg, #aa0000, #ff4444);
}

.rank-btn.red:hover {
  background: linear-gradient(90deg, #ff0000, #ff7777);
}

/* Inputs */
.rank-card input[type="text"] {
  padding: 0.5rem;
  width: 100%;
  border: none;
  border-radius: 6px;
  background: #2f2f2f;
  color: white;
  margin-bottom: 0.5rem;
}

.rank-card input[type="color"] {
  width: 100%;
  height: 35px;
  border: none;
  border-radius: 6px;
  margin-bottom: 0.5rem;
}

/* Alertes */
.alert-success {
  text-align: center;
  background-color: #2e7d32;
  color: white;
  padding: 0.75rem;
  margin-bottom: 1rem;
  max-width: 600px;
  margin-left: auto;
  margin-right: auto;
  border-radius: 6px;
}

/* Titre */
.admin-title {
  text-align: center;
  margin-top: 2rem;
  font-size: 2rem;
  color: white;
}

/* Permissions (fake switchs et labels) */
.permissions {
  margin-top: 1rem;
}

.permissions h3 {
  font-size: 1.1rem;
  text-align: center;
  margin-bottom: 0.5rem;
  text-decoration: underline;
}

.permission-item {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.95rem;
  margin: 0.3rem 0;
}

.permission-color {
  width: 18px;
  height: 18px;
  border-radius: 3px;
  display: inline-block;
}

.permission-toggle {
  width: 40px;
  height: 20px;
  background-color: #007bff;
  border-radius: 10px;
  position: relative;
}

.permission-toggle.off {
  background-color: #aa0000;
}

.permission-toggle::after {
  content: '';
  position: absolute;
  top: 2px;
  left: 2px;
  width: 16px;
  height: 16px;
  background-color: white;
  border-radius: 50%;
  transition: all 0.2s ease-in-out;
}

.permission-toggle.off::after {
  left: 22px;
}

.users-wrapper {
  margin: 20px auto;
  padding: 20px;
  background: #1e1e1e;
  border-radius: 20px;
  max-width: 1200px;
  color: white;
}
.users-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}
.users-header input[type="text"] {
    padding: 6px 12px;
    border-radius: 8px;
    border: none;
}
.user-row {
    display: flex;
    align-items: center;
    background-color: #2c2c2c;
    padding: 10px;
    border-radius: 12px;
    margin-bottom: 12px;
}
.user-row > div {
    flex: 1;
    text-align: center;
}
.user-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
}
.rank-badge {
    padding: 5px 10px;
    border-radius: 8px;
    color: #fff;
    font-weight: bold;
    cursor: pointer;
}
.rank-form select {
  padding: 5px;
  border-radius: 6px;
  border: none;
}

.shop-container {
  max-width: 1200px;
  margin: auto;
  padding: 40px 20px;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 30px;
}

.shop-card-wrapper {
  background: linear-gradient(135deg, #00aaff, #023562); /* tu gardes la couleur dynamiquement via le style inline */
  border-radius: 30px;
  padding: 2px;
  display: inline-flex; /* <- remplace inline-block par inline-flex */
  border: none;
  width: fit-content;
}


.shop-card {
  height: 100%;
  background: #1b1b1b;
  border-radius: 28px;
  width: 260px;
  padding: 20px;
  text-align: center;
  box-shadow: 0 0 12px #000000aa;
  transition: transform 0.3s ease;
  display: flex;
  flex-direction: column;
  align-items: center;
}
.shop-card:hover {
  transform: translateY(-6px);
}

.logo-container img {
  max-width: 100%;
  max-height: 120px;
  object-fit: contain;
  display: block;
  border-radius: 20px;
}

.shop-card h3 {
  margin-bottom: 15px;
  font-size: 1.1em;
  font-weight: 600;
}

.buy-button-wrapper {
  background: linear-gradient(90deg, #00aaff, #023562);
  border-radius: 50px;
  padding: 3px;
  display: inline-block;
  margin: 15px auto;
  width: 90%;
}

.shop-card .buy-button {
  position: relative;
  background-color: #102e49;
  border: none;
  border-radius: 50px;
  color: #00aaff;
  padding: 6px 16px;
  font-size: 1em;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: bold;
  width: 100%;
  height: 56px;
  transition: background 0.3s;
  overflow: hidden;
}

.shop-card .buy-button:hover {
  background-color: #0d2539;
}

.buy-content {
  display: flex;
  align-items: center;
  gap: 10px;
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  transition: all 0.3s ease;
  opacity: 1;
}

.buy-icon {
  width: 50px;
  height: 50px;
  object-fit: contain;
  filter: brightness(0) saturate(100%) invert(55%) sepia(78%) saturate(700%) hue-rotate(170deg) brightness(98%) contrast(102%);
}

.separator {
  font-size: 1.5em;
  color: #00aaff;
  line-height: 1;
  position: relative;
  top: -2px;
}

.buy-price {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, 10px);
  opacity: 0;
  transition: all 0.3s ease;
  color: #00ffaa;
  white-space: nowrap;
  pointer-events: none;
}

/* Animation */
.buy-button:hover .buy-content {
  opacity: 0;
  transform: translate(-50%, -20px);
}

.buy-button:hover .buy-price {
  opacity: 1;
  transform: translate(-50%, -50%);
}

.features-list {
  list-style: none;
  padding: 15px 15px;
  background: #2a2a2a;
  border-radius: 20px;
  margin-top: 10px;
  text-align: left;
  font-size: 0.95em;
  line-height: 1.6em;
  width: 100%;
}

.features-list li {
  padding: 6px 0;
  border-bottom: 1px solid #3a3a3a;
}

.features-list li:last-child {
  border-bottom: none;
}

.features-list strong {
  color: #00aaff;
  font-weight: 600;
}

/* Gestion Boutique */

.admin-container {
  display: flex;
  gap: 30px;
  padding: 40px;
  background: #2a2a2a;
  border-radius: 20px;
  max-width: 1200px;
  margin: 40px auto;
  color: #fff;
  flex-wrap: wrap;
}

.admin-form {
  background: #1e1e1e;
  border-radius: 15px;
  padding: 20px;
  flex: 1;
  min-width: 300px;
  border: 2px solid #007bff;
}

.admin-form h2 {
  text-align: center;
  margin-bottom: 20px;
}

.admin-form label {
  display: block;
  margin-top: 10px;
  font-weight: bold;
}

.admin-form input,
.admin-form textarea {
  width: 100%;
  padding: 8px;
  margin-top: 5px;
  border-radius: 8px;
  border: none;
  background: #333;
  color: #fff;
}

.admin-form button {
  margin-top: 15px;
  padding: 10px 20px;
  background-color: #007bff;
  border: none;
  border-radius: 10px;
  color: #fff;
  width: 100%;
  font-weight: bold;
  cursor: pointer;
}

.admin-list {
  flex: 2;
  min-width: 400px;
}

.admin-list h2 {
  margin-bottom: 20px;
}

.pack-item {
  background: #1b1b1b;
  border: 1px solid #333;
  padding: 12px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  margin-bottom: 12px;
  gap: 15px;
}

.pack-item img {
  width: 60px;
  height: 60px;
  object-fit: contain;
  border-radius: 10px;
}

.delete-btn {
  margin-left: auto;
  color: #ff4d4d;
  text-decoration: none;
  font-weight: bold;
  transition: color 0.2s;
}
.delete-btn:hover {
  color: #ff0000;
}

/* ===== TOGGLE SWITCHES ===== */
.toggle-section {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-top: 15px;
  margin-bottom: 20px;
}

.toggle-container {
  position: relative;
  display: flex;
  align-items: center;
  cursor: pointer;
}

.toggle-container input {
  opacity: 0;
  width: 0;
  height: 0;
}

.toggle-slider {
  position: relative;
  width: 40px;
  height: 20px;
  background-color: #444;
  border-radius: 34px;
  transition: background-color 0.3s;
  margin-right: 12px;
}

.toggle-slider::before {
  content: "";
  position: absolute;
  height: 14px;
  width: 14px;
  left: 3px;
  top: 3px;
  background-color: white;
  border-radius: 50%;
  transition: transform 0.3s;
}

.toggle-container input:checked + .toggle-slider {
  background-color: #00aaff;
}

.toggle-container input:checked + .toggle-slider::before {
  transform: translateX(20px);
}

.toggle-label {
  font-weight: bold;
  color: #00aaff;
}

/* ===== MODALES ===== */
.modal {
  display: none;
  position: fixed;
  z-index: 1000;
  top: 0; left: 0;
  width: 100%; height: 100%;
  background: rgba(0, 0, 0, 0.6);
  justify-content: center;
  align-items: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
}

.modal.active {
  display: flex;
  opacity: 1;
  pointer-events: auto;
}

.modal-content {
  background: #1e1e1e;
  padding: 30px;
  border-radius: 12px;
  width: 90%;
  max-width: 400px;
  box-shadow: 0 0 20px #00aaff88;
  animation: modal-slide-in 0.3s ease-out;
  text-align: center;
}

.modal-content h3 {
  margin-bottom: 20px;
  color: #00aaff;
}

.modal-content input,
.modal-content textarea {
  width: 100%;
  padding: 10px;
  border: 2px solid #00aaff;
  border-radius: 6px;
  background: #2c2c2c;
  color: white;
  margin-bottom: 15px;
}

.modal-content button {
  background: #00aaff;
  border: none;
  padding: 10px 20px;
  border-radius: 6px;
  color: white;
  font-weight: bold;
  cursor: pointer;
  transition: background 0.2s;
}
.modal-content button:hover {
  background: #0088cc;
}

/* ===== Animation ===== */
@keyframes modal-slide-in {
  from {
    transform: translateY(-30px);
    opacity: 0;
  }
  to {
    transform: translateY(0px);
    opacity: 1;
  }
}

/* ===== BOUTONS MODERNES (TOGGLE) ===== */
.modern-buttons {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-bottom: 20px;
}

.modern-toggle-btn {
  display: flex;
  align-items: center;
  background: #111;
  border: 1px solid #333;
  padding: 10px 15px;
  border-radius: 12px;
  cursor: pointer;
  color: #ccc;
  transition: all 0.2s ease;
  font-weight: 500;
  user-select: none;
}

.modern-toggle-btn .toggle-circle {
  width: 14px;
  height: 14px;
  background: #222;
  border: 2px solid #555;
  border-radius: 50%;
  margin-right: 12px;
  transition: all 0.3s ease;
  box-shadow: 0 0 0 transparent;
}

.modern-toggle-btn:not(.inactive) {
  background: #1a1a1a;
  color: #fff;
  border-color: #00aaff;
}

.modern-toggle-btn:not(.inactive) .toggle-circle {
  background: #00aaff;
  border-color: #00aaff;
  box-shadow: 0 0 10px #00aaff88;
}

.modern-toggle-btn.validated {
  border: 2px solid #28a745 !important;
  box-shadow: 0 0 6px rgba(40, 167, 69, 0.5);
}

.edit-btn {
 margin-left: 10px;
 color: #fff;
 background: #007acc;
 padding: 4px 10px;
 border-radius: 5px;
 text-decoration: none;
}
.edit-btn:hover {
  background: #005fa3;
}

.forum-container {
  max-width: 900px;
  margin: 40px auto;
  padding: 0 20px;
}

.category {
  margin-bottom: 30px;
  border-top: 3px solid #1e90ff;
  background-color: #2b2b2b;
  box-shadow: 0 0 3px #000;
}

.category-header {
  display: flex;
  align-items: center;
  background-color: #2f2f2f;
  padding: 15px 20px;
  border-bottom: 1px solid #444;
  color: white;
}

.category-icon,
.subcategory-icon {
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 6px;
  flex-shrink: 0;
}

.category-icon img,
.subcategory-icon img {
  max-width: 36px;
  max-height: 36px;
}

.category-separator,
.subcategory-separator {
  width: 2px;
  height: 36px;
  margin: 0 15px;
  background: linear-gradient(to bottom, #1e90ff, transparent);
  border-radius: 2px;
  flex-shrink: 0;
}

.category-info {
  display: flex;
  flex-direction: column;
}

.category-title {
  font-size: 20px;
  font-weight: bold;
}

.category-description {
  font-size: 13px;
  color: #ccc;
  margin-top: 4px;
}

.subcategory {
  display: flex;
  align-items: center;
  padding: 12px 20px;
  border-top: 1px solid #3a3a3a;
  transition: background-color 0.2s;
}

.subcategory:hover {
  background-color: #3a3a3a;
  cursor: pointer;
}

.subcategory-content {
  flex: 1;
}

.subcategory-title {
  font-size: 16px;
  font-weight: bold;
  color: white;
}

.subcategory-description {
  font-size: 13px;
  color: #bfbfbf;
  margin-top: 3px;
}
