@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@300;500;700;900&display=swap');

:root {
  --primary-color: #88E6A7;
  --primary-hover: #6BD98F;
  --bg-darker: #05070a;
  --bg-dark: #0b101e;
  --bg-Middle: #c5c5c5;
  --bg-dark-middle: #1b2131;
  --bg-muted: #9ca3af;
  --text-light: #ffffff;
  --text-dark: #1b2131;
  /* Added for dark text on bright background */
  --text-muted: #9ca3af;
  --accent: rgba(136, 230, 167, 0.5);
  --error: #ff4b4b;
  --border-radius: 12px;
  --transition: all 0.3s ease;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

.content.hidden {
  display: none !important;
}

body {
  font-family: 'Outfit', sans-serif;
  background-color: var(--bg-darker);
  background:
    radial-gradient(circle at center, transparent 0%, rgba(0, 0, 0, 0.2) 100%),
    linear-gradient(110deg, #1b2131 0%, #3a4150 40%, #878c9a 100%);
  color: var(--text-light);
  line-height: 1.6;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  padding: 2rem;
}

/* Container */
.anfrage-box {
  background: var(--bg-dark-middle);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: var(--border-radius);
  padding: 3rem 2.5rem;
  width: 100%;
  max-width: 800px;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.5);
  text-align: center;
  position: relative;
  overflow: hidden;
}

.anfrage-box::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: linear-gradient(90deg, transparent, var(--primary-color), transparent);
}

/* Sponsoren und Marken Bilder verkleinern */
.img-button {
  width: 100%;
  max-width: 130px;
  /* Kleinere Bilder auf Knöpfen */
  height: auto;
  object-fit: contain;
  border-radius: 8px;
  transition: transform 0.3s ease;
}

.img-button-icon {
  width: 100%;
  max-width: 130px;
  /* Marken-Logos etwas kleiner */
  height: auto;
  object-fit: contain;
  border-radius: 8px;
  transition: transform 0.3s ease;
}

.img-button-styles {
  width: 100%;
  max-width: 220px;
  /* Trikot-Bilder groß genug zum Erkennen */
  height: auto;
  object-fit: contain;
  border-radius: 8px;
  margin-top: 10px;
}

/* Header & Logo */
.logo-container {
  margin-bottom: 2rem;
}

.logo-container img {
  max-width: 180px;
  height: auto;
  display: block;
  margin: 0 auto;
}

.anfrage-box h2 {
  font-size: 1.8rem;
  font-weight: 700;
  margin-bottom: 0.5rem;
  text-transform: uppercase;
  letter-spacing: 1px;
}

.anfrage-box p.subtitle {
  color: var(--text-muted);
  font-size: 1rem;
  margin-bottom: 2.5rem;
}

/* Form Styles */
.form-group {
  margin-bottom: 1.5rem;
  text-align: left;
}

input[type="text"],
input[type="number"],
input[type="email"],
input[type="tel"],
textarea {
  width: 100%;
  padding: 1rem 1.25rem;
  background: rgba(0, 0, 0, 0.3);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 8px;
  color: var(--text-light);
  font-family: 'Outfit', sans-serif;
  font-size: 1rem;
  transition: var(--transition);
  resize: vertical;
}

input[type="text"]:focus,
input[type="number"]:focus,
input[type="email"]:focus,
input[type="tel"]:focus,
textarea:focus {
  outline: none;
  border-color: var(--primary-color);
  box-shadow: 0 0 0 2px rgba(136, 230, 167, 0.1);
  background: rgba(0, 0, 0, 0.5);
}

input::placeholder,
textarea::placeholder {
  color: rgba(255, 255, 255, 0.3);
}

/* Chrome, Safari, Edge, Opera: Hide arrows on number input */
input::-webkit-outer-spin-button,
input::-webkit-inner-spin-button {
  -webkit-appearance: none;
  margin: 0;
}

input[type=number] {
  -moz-appearance: textfield;
  appearance: textfield;
}

/* Error Messages */
.input-error {
  color: var(--error);
  font-size: 0.85rem;
  margin-top: 0.5rem;
  min-height: 1.2rem;
}

.form-error {
  color: var(--error);
  font-weight: 500;
  margin-top: 1rem;
}

hr {
  border: none;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  margin: 1.5rem 0;
}


.checkbox-title {
  text-align: left;
  font-size: 1.2rem;
  margin-bottom: 0.5rem;
  color: var(--text-muted);
}

.form-group label a {
  color: var(--primary-color);
  text-decoration: none;
  transition: var(--transition);
}

.form-group label a:hover {
  text-decoration: underline;
  color: var(--primary-hover);
}

.checkbox-container {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
}

.checkbox-container label,
.checkbox-label {
  display: flex;
  align-items: flex-start;
  /* Aligns with first line of text */
  gap: 0.75rem;
  cursor: pointer;
  color: var(--text-muted);
  text-align: left;
}

.checkbox-label span {
  flex: 1;
  /* Takes up remaining space */
  font-size: 0.95rem;
  line-height: 1.4;
}

input[type="checkbox"].checkbox {
  flex-shrink: 0;
  /* Prevents the checkbox from being squashed */
  margin-top: 0.2rem;
  /* Fine-tune alignment with first line of text */
  -webkit-appearance: none;
  /* Für Safari/Chrome */
  appearance: none;
  width: 1.2rem;
  height: 1.2rem;
  background: rgba(0, 0, 0, 0.3);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 4px;
  cursor: pointer;
  display: grid;
  place-content: center;
}


/* Der Haken, wenn ausgewählt */
input[type="checkbox"].checkbox::before {
  content: "";
  width: 0.65rem;
  height: 0.65rem;
  transform: scale(0);
  transition: 120ms transform ease-in-out;
  box-shadow: inset 1em 1em var(--primary-color);
  /* Haken-Farbe */
  clip-path: polygon(14% 44%, 0 65%, 50% 100%, 100% 16%, 80% 0%, 43% 62%);
}


input[type="checkbox"].checkbox:checked::before {
  transform: scale(1);
}


/* Button */
.bt-submit {
  width: 100%;
  padding: 1.1rem;
  background: var(--primary-color);
  color: var(--bg-darker);
  border: none;
  border-radius: 8px;
  font-size: 1.1rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
  cursor: pointer;
  transition: var(--transition);
  margin-top: 1rem;
  font-family: 'Outfit', sans-serif;
}

.bt-submit:hover {
  background: var(--primary-hover);
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(136, 230, 167, 0.1);
}

.bt-submit:active {
  transform: translateY(0);
}

/* Footer Links */
.anfrage-footer {
  margin-top: 2rem;
  text-align: center;
  font-size: 0.85rem;
  color: var(--text-muted);
}

.anfrage-footer a {
  color: var(--text-muted);
  text-decoration: none;
  transition: var(--transition);
  margin: 0 0.5rem;
  display: inline-block;
  margin-top: 0.5rem;
}

.anfrage-footer a:hover {
  color: var(--primary-color);
}

.anfrage-footer .instagram-link {
  position: relative;
  display: inline-block;
  width: 50px;
  height: 50px;
  margin: 0.5rem auto;
}

.anfrage-footer .instagram-link img {
  position: absolute;
  top: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 50px;
  height: 50px;
  transition: opacity var(--transition);
}

.anfrage-footer .instagram-link img.instagram-hover {
  opacity: 0;
}

.anfrage-footer .instagram-link:hover img.instagram-default {
  opacity: 0;
}

.anfrage-footer .instagram-link:hover img.instagram-hover {
  opacity: 1;
}

/* -------------------------------------------
   Wizard Specific Styles
------------------------------------------- */
.flex-container {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  /* This enables items to wrap down instead of staying in a single row */
  gap: 15px;
  /* Better spacing between cards */
  margin: 20px auto;
}

.flex-container .content {
  background-color: var(--bg-muted);
  /* Dark blue from the wrapper */
  color: var(--text-dark);
  padding: 15px;
  border-radius: var(--border-radius);
  width: 30%;
  /* Etwas schmaler für Bilder */
  min-width: 140px;
  /* Verhindert, dass sie auf dem Handy zu extrem schrumpfen */
  max-width: 180px;
  /* Verhindert riesige Boxen auf Desktop */
  text-align: center;
  cursor: pointer;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.3);
  border: 2px solid transparent;
  transition: all 0.3s ease;
}

.flex-container .content:hover {
  border-color: var(--primary-color);
  transform: scale(1.05);
}

.flex-container .content.selected {
  background-color: var(--primary-color);
  border-color: var(--primary-color);
  color: var(--bg-darker);
  transform: scale(1.05);
}

.button-row {
  display: flex;
  justify-content: space-between;
  margin-top: 20px;
}

.bt-back {
  background-color: #f1f1f1;
  color: #333;
  border: 1px solid #ddd;
  padding: 10px 20px;
  cursor: pointer;
  border-radius: 4px;
}

.bt-back:hover {
  background-color: #e1e1e1;
}

.summary {
  width: 100%;
  margin-bottom: 20px;
}

.summary td {
  padding: 8px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}


.progress-wrapper {
  position: fixed;
  right: 20px;
  top: 50%;
  transform: translateY(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 15px;
  background: rgba(11, 16, 30, 0.9);
  padding: 20px 10px;
  border-radius: 20px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  z-index: 1000;
  backdrop-filter: blur(5px);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
}

.progress-container {
  width: 6px;
  height: 150px;
  background: rgba(255, 255, 255, 0.1);
  border-radius: 3px;
  overflow: hidden;
  display: flex;
  align-items: flex-start;
}

.progress-bar-fill {
  width: 100%;
  background: var(--primary-color, #88E6A7);
  height: 11.1%;
  transition: height 0.4s ease;
}

.progress-text {
  font-size: 0.9em;
  color: #fff;
  font-weight: bold;
  text-align: center;
}

/* Keep steps visible but add some separation */
.wizard-step {
  margin-bottom: 30px;
  padding-bottom: 30px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}


.wizard-step:last-child {
  border-bottom: none;
}

/* -------------------------------------------
   Veredelung Preview Styles
------------------------------------------- */
.veredelung-preview-container {
  display: flex;
  flex-direction: column;
  gap: 2rem;
  margin-top: 1rem;
  align-items: center;
}

.veredelung-options.flex-container {
  width: 85%;
  margin: 0 auto;
  display: grid !important;
  grid-template-columns: repeat(2, 1fr);
  gap: 10px !important;
  text-align: center;
}

@media (min-width: 600px) {
  .veredelung-options.flex-container {
    width: 75%;
    grid-template-columns: repeat(3, 1fr);
  }
}

.veredelung-preview {
  flex: 1;
  min-width: 300px;
  display: flex;
  gap: 1rem;
  justify-content: center;
}

.checkbox-card {
  user-select: none;
  display: flex !important;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  width: 100% !important;
  min-width: 0 !important;
  max-width: none !important;
  padding: 8px !important;
}

.checkbox-card small {
  color: rgba(27, 33, 49, 0.7);
  transition: all 0.3s ease;
  font-size: 0.85rem;
}

.checkbox-card.selected small {
  color: rgba(5, 7, 10, 0.7);
}

.jersey-preview {
  position: relative;
  width: 170px;
  /* Slightly larger for mobile */
  background: rgba(255, 255, 255, 0.05);
  border-radius: 8px;
  padding: 10px;
}

.jersey-preview img {
  width: 100%;
  height: auto;
  display: block;
}

.preview-overlay {
  position: absolute;
  display: none;
  text-align: center;
  width: 100%;
  left: 0;
  color: #fff;
  font-family: 'Outfit', sans-serif;
  text-shadow: 1px 1px 2px #000, -1px -1px 2px #000, 1px -1px 2px #000, -1px 1px 2px #000;
  pointer-events: none;
  z-index: 10;
}

#preview-wappen {
  top: 25%;
  left: 55%;
  width: 20px;
  height: 25px;
}

.wappen-icon {
  width: 90%;
  height: 90%;
  filter: drop-shadow(0px 2px 2px rgba(0, 0, 0, 0.5));
}

#preview-verein {
  top: 20%;
  font-weight: 700;
  font-size: 0.6rem;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

#preview-ruecken {
  top: 27%;
  font-weight: 900;
  font-size: 3rem;
  line-height: 1;
}

#preview-eigenname {
  top: 60%;
  font-weight: 700;
  font-size: 0.35rem;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

#preview-sponsor {
  top: 30%;
  left: 35%;
  width: 30%;
  height: auto;
  pointer-events: none;
}

#preview-klnummer {
  top: 70%;
  left: 35%;
  width: auto;
  transform: translateX(-50%);
  font-weight: 700;
  font-size: 1.2rem;
}

#preview-pants-custom {
  top: 30%;
  left: 42%;
  width: auto;
  transform: translateX(-50%);
  font-weight: 700;
  font-size: 0.6rem;
}

#preview-jacket-custom {
  top: 30%;
  left: 40%;
  font-size: 0.7rem;
  width: auto;
  font-weight: bold;
  transform: translateX(-50%);
}

@media (min-width: 600px) {
  .jersey-preview {
    width: 350px;
    padding: 20px;
  }

  #preview-wappen {
    width: 45px;
    height: 45px;
  }

  #preview-verein {
    font-size: 1rem;
  }

  #preview-ruecken {
    font-size: 6.5rem;
  }

  #preview-eigenname {
    font-size: 0.8rem;
  }

  #preview-klnummer {
    font-size: 2.2rem;
  }

  #preview-pants-custom {
    font-size: 1rem;
  }

  #preview-jacket-custom {
    font-size: 1rem;
  }
}