/* ----------------------------------------------------------
   Triathlon Challenge Frontend Styles
   ---------------------------------------------------------- */

:root {
  --tc-blue: #0057a4;
  --tc-darkblue: #212529;
  --tc-green: rgb(40, 167, 69);
  --tc-white: #ffffff;
  --tc-gray: #f7f7f7;
  --tc-border: #dcdcdc;
  --tc-radius: 14px;
  --tc-shadow: 0 4px 8px rgba(0,0,0,0.1);
  --tc-font: "degewo sans", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI",
             Roboto, "Helvetica Neue", Arial, sans-serif;
}

/* Alles im Formular auf Systemschrift */
.tc-wrap,
.tc-wrap input,
.tc-wrap select,
.tc-wrap button,
.tc-wrap textarea,
.tc-wrap h4 {
  font-family: var(--tc-font);
}

/* --- Karten / Container (kannst du nach Bedarf ergänzen) --- */
.tc-wrap {}

/* --- Header --- */
.tc-header {
  text-align: center;
}

.tc-header img {
  max-height: 150px;
  display: block;
  margin: 0 auto 10px;
}

.tc-title {
  text-align: center;
  font-size: 3em;
  font-weight: 700;
  color: var(--tc-darkblue);
  margin-bottom: 4px;
}

.tc-period {
  text-align: center;
  font-size: 1.5em;
  font-weight: 700;
  color: var(--tc-blue);
  margin-bottom: 20px;
}

/* --- Timeslot-Buttons --- */
.tc-slots {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px;
  margin-bottom: 30px;
}

.tc-slot {
  border: none;
  border-radius: 20px;
  padding: 6px 12px;
  font-weight: 600;
  font-size: 1.2em;
  cursor: pointer;
  transition: all 0.2s ease;
}

.tc-slot.tc-two,
.tc-slot.tc-one,
.tc-slot.tc-full {
  background: var(--tc-blue);
  color: #fff;
}

.tc-slot.tc-full {
  cursor: not-allowed;
  opacity: .7;
}

.tc-slot.tc-selected {
  outline: 0;
  background: var(--tc-green);
}

.tc-slot:hover:not(.tc-full) {
  background: var(--tc-darkblue);
}

/* --- Formular --- */
.tc-form {
  font-size: 0.9em;
}

/* 2-Spalten-Grid für alle Formularfelder */
.tc-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  column-gap: 20px;
  row-gap: 14px;
}

/* Labels: Text oben, Feld darunter (vertikal) */
.tc-grid label {
  display: flex;
  flex-direction: column;
  font-weight: 600;
}

.tc-grid label.tc-dsgvo {
  flex-direction: row;        /* statt column */
  align-items: flex-start;
  gap: 8px;
  font-weight: 600;
}

.tc-grid label.tc-dsgvo input[type="checkbox"] {
  margin-top: 3px;            /* optisch zur ersten Textzeile ausrichten */
}

.tc-grid label.tc-dsgvo span {
  display: block;
}

/* Überschrift "Kontaktdaten ..." über die komplette Breite */
.tc-grid h4 {
  grid-column: 1 / -1;
  margin: 20px 0 6px;
  font-size: 1.1em;
}

/* Inputs/Select: Standard-Feldstyle */
.tc-grid input[type="text"],
.tc-grid input[type="email"],
.tc-grid input[type="number"],
.tc-grid select {
  border: 1px solid var(--tc-border);
  border-radius: 10px;
  padding: 10px 12px;
  font-size: 1em;
  font-family: var(--tc-font);
  width: 100%;
}

/* Direkte Inputs (deine Kontakt-Felder mit Placeholdern) nehmen volle Spaltenbreite ein */
.tc-grid > input[type="text"],
.tc-grid > input[type="email"],
.tc-grid > input[type="number"],
.tc-grid > select {
  width: 100%;
}

/* Fokuszustand */
.tc-grid input:focus,
.tc-grid select:focus {
  outline: none;
  border-color: var(--tc-blue);
  box-shadow: 0 0 3px var(--tc-blue);
}

/* DSGVO-Checkbox und Info-Text sollen über beide Spalten gehen */
.tc-dsgvo,
.tc-grid > p {
  grid-column: 1 / -1;
}


/* --- Buttons --- */
.tc-submit {
  display: inline-block;
  background-color: var(--tc-blue);
  color: var(--tc-white);
  border: none;
  border-radius: 50px;
  padding: 10px 24px;
  font-weight: 700;
  font-size: 1.2em;
  margin-top: 16px;
  cursor: pointer;
  transition: all 0.2s ease;
}

.tc-submit:hover {
  background-color: var(--tc-darkblue);
}

.tc-grid a {
	color: var(--tc-blue) !important;
}

/* --- Nachrichten --- */
.tc-msg {
  margin-top: 20px;
  font-weight: 600;
  border-radius: 10px;
  padding: 10px 12px;
  color: var(--tc-green);
  background-color: var(--tc-white);

}

/* --- Breakpoint: unter 479px alles einspaltig --- */
@media (max-width: 479px) {
  .tc-grid {
    grid-template-columns: 1fr;
  }
}



/* --- Schrittzähler --- */



#tc-stepcounter-wrap{
  position: relative;
}

#tc-stepcounter-wrap .tc-stepcounter-controls{
  position: absolute;
  top: 15px;
  right: 25px;
  padding: 10px;
  border-radius: 5px;
  z-index: 10;
}


#tc-stepcounter-counter{
  position: absolute;
  top: 25px;
  left: 25px;
  background: rgb(0, 150, 63);
  padding: 5px 10px;
  border-radius: 5px;
  font-size: 24px;
  font-weight: bold;
  box-shadow: 0 0 10px rgba(0, 0, 0, 0.3);
  z-index: 10;
  font-family: 'degewo sans' !important;
  color: #fff;
}


#tc-stepcounter-start{
  background: rgb(0, 150, 63);
  padding: 10px 20px;
  border-radius: 25px;
  border: none;
  font-size: 32px;
  font-weight: bold;
  z-index: 10;
  font-family: 'degewo sans' !important;
  color: #fff;
  cursor: pointer;
  box-shadow: 0 0 10px rgba(0, 0, 0, 0.3);
}

#tc-stepcounter-start:hover{
  background: rgb(0, 76, 147);
}

#tc-stepcounter-canvas{
  position: relative;
  width: 100%;
  height: 100vh;
  border-radius: 10px;
  display: block;
}

#tc-stepcounter-runner{
  position: absolute;
  width: 100px;
  height: 100px;
  background: url('https://www.degewo-schuelertriathlon.de/karte/Kalle-animation-neu.gif');
  background-size: 300px 100px; /* Gesamtgröße: 300px breit, 100px hoch */
  background-position: 0 0;     /* Standard: Läufer sichtbar */
  transform: translate(-50px, -50px);
  z-index: 11;
  pointer-events: none;
}

/* Responsive */
@media screen and (max-width: 479px){
  #tc-stepcounter-canvas{
    height: 600px;
  }

  #tc-stepcounter-runner{
    transform: translate(-75px, -75px);
  }

  #tc-stepcounter-wrap .tc-stepcounter-controls{
    top: 520px;
    left: 15px;
    right: auto;
  }

  #tc-stepcounter-start{
    padding: 10px 20px;
    border-radius: 10px;
    font-size: 20px;
  }
}

