/* TikTok-Style Puzzle – FINAL style.css */

body {
  margin: 0;
  font-family: 'Open Sans', sans-serif;
  background-color: #111;
  color: #E0E0E0;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 20px;
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

h1 {
  font-family: 'Playfair Display', serif;
  font-size: 28px;
  color: #D4AF37;
  margin-bottom: 10px;
  text-align: center;
}

#puzzleCanvas {
  width: 100%;
  max-width: 480px;
  aspect-ratio: 3 / 4;
  image-rendering: crisp-edges;
  border: 3px solid #D4AF37;
  border-radius: 12px;
  margin-top: 20px;
  box-shadow: 0 0 15px rgba(212, 175, 55, 0.3);
  transition: box-shadow 0.3s ease;
}

#puzzleCanvas:hover {
  box-shadow: 0 0 20px rgba(212, 175, 55, 0.5);
}

#timerDisplay {
  font-size: 18px;
  color: #D4AF37;
  text-align: center;
  margin-top: 15px;
}

#message-container {
  margin-top: 30px;
  font-size: 20px;
  color: #D4AF37;
  text-align: center;
  background: #1a1a1a;
  padding: 20px;
  border-radius: 16px;
  border: 2px solid #D4AF37;
  max-width: 480px;
  box-shadow: 0 0 20px rgba(212, 175, 55, 0.2);
  animation: pulseGlow 2s ease-in-out infinite;
}

@keyframes pulseGlow {
  0%, 100% { box-shadow: 0 0 10px rgba(212,175,55,0.2); }
  50%      { box-shadow: 0 0 25px rgba(212,175,55,0.5); }
}

.hidden {
  display: none;
}

button,
.cta-button {
  background-color: #D4AF37;
  color: #111;
  border: none;
  padding: 10px 24px;
  border-radius: 30px;
  font-weight: bold;
  font-size: 16px;
  cursor: pointer;
  margin-top: 15px;
  transition: background 0.3s ease, box-shadow 0.3s ease;
  text-decoration: none;
  display: inline-block;
}

button:hover,
.cta-button:hover {
  background-color: #FFD700;
  box-shadow: 0 0 12px #FFD700;
}

input[type="file"] {
  display: block;
  margin: 10px auto;
  padding: 10px;
  background: #1a1a1a;
  color: #E0E0E0;
  border: 1px solid #444;
  border-radius: 8px;
  font-size: 14px;
}

label {
  color: #D4AF37;
  font-weight: 600;
  margin-bottom: 6px;
  display: block;
  text-align: center;
  font-size: 15px;
}

#message-container > div {
  margin-top: 25px;
  text-align: center;
}

.puzzle-swap {
  transition: transform 0.25s ease-in-out;
}

/* Passwort-Formular Styling */
.pw-form {
  background: #1a1a1a;
  padding: 25px;
  border-radius: 15px;
  border: 2px solid #D4AF37;
  max-width: 360px;
  margin: 30px auto;
  text-align: center;
}

.pw-form input[type="password"] {
  padding: 10px;
  font-size: 16px;
  width: 80%;
  margin: 10px 0;
  border-radius: 10px;
  border: 1px solid #444;
  background-color: #111;
  color: #E0E0E0;
}

/* Fehleranzeige */
.error {
  color: #FF6B6B;
  font-weight: bold;
  margin-top: 10px;
}

/* Responsive Optimierung */
@media screen and (max-width: 600px) {
  h1 {
    font-size: 22px;
  }

  button,
  .cta-button {
    font-size: 14px;
    padding: 8px 18px;
  }

  input[type="file"] {
    width: 90%;
    font-size: 13px;
  }

  #timerDisplay {
    font-size: 16px;
  }

  #message-container {
    font-size: 16px;
    padding: 16px;
  }
}

