* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  background: radial-gradient(#111 40%, #000 100%);
  background-image: url('assets/images/apocalypse-bg.jpg');
  background-blend-mode: multiply;
  background-size: cover;
  color: #eee;
  font-family: 'Share Tech Mono', monospace;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  align-items: center;
  min-height: 100vh;
  padding: 20px;
}

main {
  flex: 1; /* ⬅️ Pousse le footer vers le bas */
}

.app-container {
  width: 100%;
  max-width: 420px;
}

.screen {
  display: flex;
  flex-direction: column;
  gap: 20px;
  text-align: center;
  animation: fadeIn 0.5s ease;
}

.hidden {
  display: none;
}

h1, h2 {
  font-size: 1.8rem;
  color: #f5f5f5;
}

p {
  font-size: 1rem;
  color: #bbb;
}

button {
  background-color: transparent;
  color: #76ff03;
  border: 2px solid #76ff03;
  text-transform: uppercase;
  letter-spacing: 1px;
  padding: 12px 16px;
  font-weight: bold;
  font-family: 'Share Tech Mono', monospace;
  box-shadow: 0 0 5px #76ff03;
  transition: all 0.3s ease;
}

button:hover {
  background-color: #76ff03;
  color: #000;
  box-shadow: 0 0 10px #76ff03;
}

button:active {
  transform: scale(0.98);
  filter: brightness(120%);
}

button:focus {
  outline: none !important;
  box-shadow: none !important;
}

.result-image {
  width: 100%;
  height: auto;
  object-fit: cover; /* facultatif */
  border-radius: 8px 8px 0 0;
  display: block;
}

.card-content {
  padding: 20px;
  text-align: center;
}

.answer-button {
  width: 100%;
  margin-bottom: 10px;
}

#progress {
  font-size: 0.9rem;
  color: #888;
}

.lang-switch {
  position: absolute;
  top: 10px;
  right: 10px;
}

#loading-text {
  font-size: 1.2rem;
  color: #ccc;
}

.loading-bar {
  width: 100%;
  height: 12px;
  background-color: #222;
  border: 1px solid #555;
  border-radius: 6px;
  overflow: hidden;
  margin-top: 20px;
}

.loading-fill {
  width: 0%;
  height: 100%;
  background-color: #76ff03;
  animation: loadingAnim 3s forwards;
}

#share-button {
  background-color: #444;
  color: #fff;
  border: 2px solid #666;
}

#share-button:hover {
  background-color: #555;
  border-color: #999;
}

#result-card {
  max-width: 400px;
  background: #1c1c1c;
  border-radius: 10px;
  overflow: hidden;
  margin: 20px auto;
  box-shadow: 0 0 10px #000;
  padding: 0; /* supprime le padding global pour coller à l’image */
}

#result-card h3 {
  font-size: 1.3rem;
  margin-bottom: 10px;
  color: #76ff03;
}

#card-result, #card-profile {
  font-size: 1rem;
  margin: 6px 0;
}

.card-footer {
  font-size: 0.8rem;
  margin-top: 15px;
  color: #888;
}

.hidden {
  display: none;
}

h1, h2 {
  animation: flicker 3s infinite alternate;
}

@keyframes flicker {
  0% { opacity: 1; }
  45% { opacity: 0.8; }
  60% { opacity: 1; }
  70% { opacity: 0.7; }
  100% { opacity: 1; }
}

@keyframes loadingAnim {
  from { width: 0%; }
  to { width: 100%; }
}

select {
  background: #000;
  color: #fff;
  border: 1px solid #444;
  padding: 4px 8px;
  border-radius: 6px;
  font-size: 0.8rem;
}

@keyframes cardGlow {
  0% {
    opacity: 0;
    box-shadow: 0 0 0px #76ff03;
    transform: scale(0.98);
  }
  50% {
    opacity: 0.6;
    box-shadow: 0 0 20px #76ff03;
    transform: scale(1.01);
  }
  100% {
    opacity: 1;
    box-shadow: 0 0 6px #76ff03;
    transform: scale(1);
  }
}

.card-glow {
  animation: cardGlow 1.2s ease-out;
}

footer {
  text-align: center;
  padding: 20px 0;
  font-size: 14px;
  opacity: 0.7;
}

footer a {
  color: #76ff03;
  text-decoration: none;
  margin: 0 10px;
  transition: opacity 0.2s ease;
}

footer a:hover {
  opacity: 1;
}

footer a::after {
  content: "↗";
  font-size: 10px;
  margin-left: 4px;
  opacity: 0.5;
}

/* Supprime les effets actifs sur mobile */
@media (hover: none) and (pointer: coarse) {
  .answer-button:focus,
  .answer-button:active,
  .answer-button:hover {
    background-color: transparent !important;
    box-shadow: none !important;
    outline: none !important;
    transform: none !important;
    filter: none !important;
  }
}