

/* Standard-Stil (Light Mode) */
body {
  background-color: white;
  color: black;
}

/* Dark Mode bei aktivierter Klasse */
body.dark {
  background-color: black;
  color: #e0e0e0;
}

body.dark .btn {
  background-color: #333;
  color: white;
}
body.dark .table-container {
    background-color: black;  /* z. B. dunkelgrau für Dark Mode */
    border-color: white;
    box-shadow: 0 4px 6px rgba(255, 255, 255, 0.1);
}
body.dark input[type="text"],
body.dark input[type="tel"],
body.dark input[type="number"],
body.dark textarea {
    background-color: #666666;
    color: #ffffff;
    border: 1px dashed #ffffff;
    caret-color: #ffffff;
}

body.dark input::placeholder {
    color: #aaa;
}
body.dark table {
    background-color: #1e1e1e;
    color: #f0f0f0;
    border-collapse: collapse;
}

body.dark th,
body.dark td {
    border: 1px solid #333;
    padding: 0px;
}

body.dark tr:nth-child(even) {
    background-color: #2a2a2a;
}
body.dark tr:nth-child(odd) {
    background-color: #444444;
}
body.dark tr:hover {
    background-color: #333;
}

body.dark th {
    background-color: #2a2a2a !important;
}

body.dark table {
  border-collapse: separate;
  border-spacing: 0;
     border: 0px ;
}

body.dark td.startnummer {
    color: white;
    background-color: transparent;


    border: 1px solid white; /* <-- Weißer Rahmen */
}


body.dark tr:hover {
    background-color: grey !important; 
}


body.dark  #rundenzahl_output {

    color: yellow !important;

    
}


.dark-toggle {
  cursor: pointer;
  font-size: 24px;
  padding: 5px;
}


/* Container der Reihen */
.keypad-row {
  display: flex;
  justify-content: center;
  gap: 6px;             /* Abstand zwischen Buttons */
  margin-top: 6px;
}
#keypad_touchOnly {
    display: none; ausblenden beim Laden
}

/* Buttons */
.keypad-btn {
  flex: 1 1 33%;        /* nimmt 1/3 der Breite ein */
  max-width: 120px;     /* maximale Breite pro Button */
  aspect-ratio: 1.8 / 1;/* Verhältnis Breite:Höhe (kannst du anpassen) */
  
  font-family: Arial, sans-serif;
  font-weight: bold;

  /*font-size: calc(1.2vw + 35px);*/ /* 👈 dynamisch abhängig von der Fensterbreite */
  font-size: 5vh; /* Schriftgröße orientiert sich an der Bildschirmhöhe */
  color: white;
  border: 3px solid #28a745;
  border-radius: 6px;
 
  border-radius: 6px;
  background-color: black;
  cursor: pointer;
  
  transition: all 0.1s ease;
}

/* gedrückt-Effekt */
.keypad-btn:active {
  background-color: grey;
  transform: scale(0.9);
  box-shadow: inset 0 0 10px #ffffff80;
}


/* Fokus-Handling */
.keypad-btn:focus,
.keypad-btn:focus-visible {
  outline: none;
}


.text-mobile { display: none; } /* Standardmäßig nur Desktop-Text anzeigen */
/* Standard CSS für den Container */

@font-face {
    font-family: 'DSEG7';
    src: url('../rc_images/DSEG7Classic-Bold.ttf') format('truetype');
}

.digital {
    font-family: 'DSEG7', sans-serif;

    text-align: center;
}

.lastentry{
    font-size: 18px;
    
}
.button_small {
   font-size: 14px;
   width: auto;
    height: auto;
    padding:2;
    border-radius: 5px;
    
    padding: 8px 8px; /* Kleineres Padding für eine kompakte Größe */
     font-size: clamp(8px, 4vw, 14px);
    background-color: #28a745;
    color: white;
    border: none;
    cursor: pointer;
    display: inline-block; /* Damit der Button nur so breit wie der Text ist */

    text-align: center;
    vertical-align: middle; /* Vertikale Zentrierung des Buttons */
    
    width: auto;
    
}
body {
   font-size: clamp(8px, 4vw, 16px);
}
#container {
    width: 100%;
    max-width: 800px;
    border: 0px solid #000000; /* Rahmen */
    margin: 0 auto;
    padding: 0px;
}

/* Formulare und Buttons */
.form-container {
    width: 100%;
    margin-bottom: 10px;
    border: 0px solid red; /* Rahmen */
}

label {
    font-size: clamp(8px, 3vw, 18px);
    margin-right: 10px;
}
.durchgestrichen {
    text-decoration: line-through;
    color: gray;
}

select, input[type="number"], button {
    padding: 2px;
    margin: 5px;
     font-size: clamp(8px, 3vw, 15px);
}

button {
    padding: 10px;
     font-size: clamp(8px, 3vw, 16px);
    width: 95%;
    max-width: 200px;
    background-color: #28a745;
    color: white; /* Textfarbe weiß */
    border: none; /* Entfernt die Standard-Umrandung */
    border-radius: 10px; /* Optionale Rundung der Ecken */
    cursor: pointer; /* Zeigt den Mauscursor als Hand-Symbol */
}

button:hover {
    background-color: black; /*die Farbe bleibt bei mobbil nach dem drücken! */
}

button:disabled {
    background-color: #ccc;
    cursor: not-allowed;
}

.button_mini {
    padding: 2px 5px; /* Kleineres Padding für eine kompakte Größe */
    font-size: 10px;
    background-color: grey;
    color: white;
    border: none;
    cursor: pointer;
    display: inline-block; /* Damit der Button nur so breit wie der Text ist */

    text-align: center;
    vertical-align: middle; /* Vertikale Zentrierung des Buttons */
    
    width: auto;
    margin:0px;
}
.button_mini:hover {
    background-color: red !important; 
}

/* Tabellen-Stile */
table {
    max-width: 1900px;
    width: 650px;
    margin: 20px 0;
    border-collapse: collapse;
}


.tab_runde {
    max-width: 900px;
    width: 350px;
    margin: 20px 0;
    border-collapse: collapse;
}

.tab_ausfall {
    max-width: 900px;
    width: 350px;
    margin: 20px 0;
    border-collapse: collapse;
}


.tab_auswertung {
    max-width: 900px;
    width: 350px;
    margin: 20px 0;
    border-collapse: collapse;
}
tabletr:nth-child(even) {
    background-color: #f2f2f2; 
}
table tr:nth-child(odd) {
    background-color: #ffffff;
}
table, th, td {
    border: 1px solid #ddd;
    white-space: nowrap; /* Verhindert Zeilenumbrüche */
}
	


th {
    background-color: #f2f2f2;
    padding: 0px;
    text-align: center !important;
}

td {
    padding: 0px;
    text-align: center ;
}

/* Highlighting von Zeilen basierend auf Rundenanzahl */
tr {
    transition: background-color 0.3s ease;
    text-align: center !important;
}



/* Hintergrundfarben für unterschiedliche Runden */
tr[style*="background-color: #ffe9e9"] {
    background-color: #ffe9e9;
}

tr[style*="background-color: #cdffd2"] {
    background-color: #cdffd2;
}

tr[style*="background-color: #fffec7"] {
    background-color: #fffec7;
}

/* Versteckte Eingabefelder innerhalb von Formularen */
form input[type="hidden"] {
    display: none;
}




#neue_startnummer {
 font-family: Arial, sans-serif;

     font-size:30px !important;
    padding: 0px 5px;
    width: 60px;
    text-align: right;
    vertical-align: middle;

}


/* Für die Schaltflächen zum Bearbeiten und Löschen */
button.btn_edit {
    background-color: #28a745; /*#28a745;*/
    padding: 5px 10px 5px 5px  ;
    border-radius: 5px;
    font-size: clamp(8px, 3vw, 16px) !important;
    color: white;
    max-width: 90px;
    height:32px;
}

button.btn_edit:hover {
    background-color: #218838;
}
button.btn_edit:disabled {
    background-color: #ccc;
    cursor: not-allowed;
}



/* Für die Schaltflächen zum Bearbeiten und Löschen */
button.btn_undel {
    background-color: #28a745; /*#28a745;*/
    padding: 5px 10px 5px 5px  ;
    border-radius: 5px;
    font-size: clamp(8px, 3vw, 16px) !important;
    color: white;
    max-width: 130px;
    height:32px;
}

button.btn_undel:hover {
    background-color: #218838;
}
button.btn_undel:disabled {
    background-color: #ccc;
    cursor: not-allowed;
}

/* Formatierung der Überschriften */
h2 {
    font-size: clamp(8px, 6vw, 25px) !important;
    margin-top: 20px;
    margin-bottom: 10px;
}

h3 {
    font-size: clamp(8px, 4vw, 18px) !important;
    margin-top: 5px;
    margin-bottom: 5px;
}

/* Stil für die Links */
a {
    text-decoration: none;
}

/* Spezifische Stilregeln für den Bereich zur PDF-Generierung */
a button {
    background-color: #28a745;
    font-size: clamp(8px, 3vw, 16px) !important;
}

a button:hover {
    background-color: #218838;
}

/* Stil für das Input-Feld zur Startnummer */
input[type="number"] {
    width: 100px;
}

#startnummer,
#absenden {
    height: 75px;
    font-size: 46px;
    padding: 5px 10px;
    box-sizing: border-box;
    vertical-align: middle;
    
}

#startnummer {
 font-family: Arial, sans-serif;
  font-weight: bold;
    width: 110px;
     padding: 5px 10px;
    text-align: center;
    
}
input::placeholder {
    font-family: 'Arial', sans-serif;
    font-size: 14px;
    color: #999;
    font-style: italic;
    text-align: center;
    vertical-align: middle;
}

#absenden {
    width: 90px;
    padding: 0px 10px; /* Optional für optischen Ausgleich */
    
    
}

#absenden:active {
  background-color: black;     /* sehr starker Kontrast */
  transform: scale(0.85);      /* optisches "Eindrücken" */
  box-shadow: inset 0 0 10px #ffffff80; /* heller Lichtschein von innen */
}

	#absenden:focus {
	  outline: none;
	  background-color: #28a745; 
	}
	#absenden:focus-visible {
	  outline: none;
	}

.absenden_small {
   font-size: 14px;
   width: auto;
    height: 20px;
    padding:0;
    padding-left: 5px;
    padding-right: 5px;

}
label[for="startnummer"] {
    font-size: clamp(8px, 4vw, 22px) !important;
    font-weight: bold; /* Optional: Fettdruck */
}

td.startnummer{
    color: white;
 font-family: Arial, sans-serif;
  font-weight: bold;
    background-color: black;
    font-size: 35px;
    text-align: center;
padding-right: 10px !important;
  padding-left: 10px !important;
}



/* Kleinere Abstände für den "rundenanzahl_output" */
#rundenzahl_output {
    display: block;
    margin-top: 0px;
    font-weight: bold;
    color: blue;

    
}
#teilnehmerInfo {
    display: block;
    margin-top: 0px;
    font-weight: bold;
    max-width: 700px;
    white-space: nowrap;        /* verhindert Zeilenumbruch */
    overflow: hidden;           /* versteckt überlaufenden Text */
    text-overflow: ellipsis;    /* zeigt … bei Überlauf */
}

#Info {
  min-height: 40px;
}

/* Button-Stil */
#toggleTableButton {
    background-color: #4CAF50;
    color: white;
    border: none;
    padding: 10px;
    cursor: pointer;
}

#toggleTableButton:hover {
    background-color: #45a049;
}

/* Stil für den Container, falls gewünscht */
#tableContainer_hide {
    margin-top: 20px;
}
.tab_startnummer{
     font-size: 23px;
    background-color: black;
    color: white;
    font-weight: bold;
    text-align: center;
    min-width: 40px;
    
}
.table-container {
    width: 750px; /* Feste Breite */
     /* margin: 20px auto; Zentrierung auf der Seite */
    margin-top:10px;
    padding: 15px; /* Innenabstand */
    border: 2px solid #ccc; /* Rahmen um den Container */
    border-radius: 8px; /* Abgerundete Ecken */
    background-color: #f9f9f9; /* Leichtes Hintergrundfarbe */
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1); /* Schatten für einen leichten 3D-Effekt */
}

.hidden-row {
    display: none; /* Standardmäßig ausgeblendet */
}
.startnummer-rot {
    color: red;
    font-weight: bold;
}
.rot-zeile {
    background-color: #ffe9e9;
    
}



    #lapTimeInput {
        width: 35px; /* Kleinere Breite */
        text-align: center; /* Zentrierter Text */
    }
    
    /* Entfernt die Hoch-/Runter-Pfeile in Chrome, Safari, Edge, Opera */
    #lapTimeInput::-webkit-inner-spin-button,  
    #lapTimeInput::-webkit-outer-spin-button {  
        -webkit-appearance: none;  
        margin: 0;  
    }

    /* Entfernt die Pfeile in Firefox */
    #lapTimeInput {
        -moz-appearance: textfield;
    }
.checkbox-container {
    display: flex;
    justify-content: flex-end;
    margin-top: 10px;
}

.checkbox-container label {
    margin-right: 5px;
}


/*
    #logout-btn {
        position: fixed;
        bottom: 10px;
        right: 10px;
        background-color: red;
        color: white;
        border: none;
        padding: 10px 20px;
        cursor: pointer;
        border-radius: 5px;
        font-size: 16px;
    }
    #logout-btn:hover {
        background-color: darkred;
    }

*/
    #logout-btn {
  
		width: 90px;
        background-color: red;
        color: white;
        border: none;
        padding: 10px 20px;
        cursor: pointer;
        border-radius: 5px;
        font-size: 12px;
  float: right;		
    }
    #logout-btn:hover {
        background-color: darkred;
    }


.rd_minus span, .rd_ok span, .rd_plus span {             
    display: inline-flex; /* Flexbox für perfekte Zentrierung, aber inline */
    justify-content: center;
    align-items: center;
    padding: 0px 0px; /* Abstand um den Buchstaben */             
    font-weight: bold;             
    border-radius: 15px;  
    
    min-width: 24px; /* Mindestbreite */
    min-height: 24px; /* Mindesthöhe */
    margin: -3px;
    text-align: center; 
    color: black;   
    color: black;   
    border: 1px solid black; /* Dünner schwarzer Rahmen um den Kreis */
}  

.rd_minus span { background-color: #ff9595; } 
.rd_ok span { background-color: #00FF00; } 
.rd_plus span { background-color: #ffffc5; } 



.fixed-logo_oben {
    max-width: 150px;
    height: auto;
    position: absolute;
    top: 10px; /* Abstand vom oberen Rand */
    right: 10px; /* Abstand vom rechten Rand */
    max-width: 150px; /* Optional: Maximalbreite des Logos */
    height: auto; /* Höhe automatisch an die Breite anpassen */	
	
}

#container_tabelle {
    width: 650px;
    position: relative; 
    margin: 20px auto;
    padding: 20px;
    border: 1px solid #ccc;
    border-radius: 10px;
    background-color: #f9f9f9;
    box-shadow: 0px 0px 10px rgba(0, 0, 0, 0.1);
    text-align: center; /* Zentriert den Inhalt im Container */
}
.tabelle_ergebnis{
    width: 100%;

    
}
tr:hover {
    background-color: #bcffd2 !important; 
}

#mouseoverhinweis{
    font-size: 11px;
    text-align: left;
    margin-top:  -15px;
    
}

.logged_user {
    position: absolute;
    top: 5px;   /* Abstand von oben */
    left: 10px; /* Abstand von rechts */
    font-size: 13px;
    display: flex;                /* Flexbox aktivieren */
    align-items: center;          /* Vertikale Zentrierung */
    gap: 5px;                     /* Abstand zwischen Bild und Text */
}


.linkbutton {
    display: inline-block;
    text-decoration: none;
    padding: 5px;
    border: none;
    border-radius: 5px;
    background-color: #4CAF50;
    color: white;
    font-size: 18px;
    cursor: pointer;
    margin: 5px auto;    

}



.linkbutton:hover {
    background-color: #45a049;
    color: white;
}



.linkbutton_blau {
    display: inline-block;
    text-decoration: none;
    padding: 2px;
    border: none;
    border-radius: 5px;
    background-color: blue;
    color: white;
    font-size: 14px;
    cursor: pointer;
    margin: 5px auto;    

}



.linkbutton_blau:hover {
    background-color: #0000a8;
    color: white;
}


.bemerkung-hinweis {
    display: inline-block;
    background-color: blue;
    color: white;
    font-size: 10px;
    font-weight: bold;
    padding: 2px 2px;
    border-radius: 3px;
    margin-left:-3px;
    vertical-align: super;
    position: relative;
    cursor: pointer;
}

/* Tooltip-Styling (nur für Desktop) */
.bemerkung-hinweis::after {
    content: attr(data-bemerkung);
    display: none;
    position: absolute;
    bottom: 100%;
    left: 0%;
    transform: translateX(-20%);
    background: rgba(0, 0, 0, 0.8);
    color: #fff;
    padding: 5px 10px;
    border-radius: 5px;
    font-size: 12px;
    white-space: nowrap;
    z-index: 1000;
}

/* Tooltip anzeigen beim Hover (Desktop) */
.bemerkung-hinweis:hover::after {
    display: block;
}

/* Mobilgeräte: Tooltip als kleines Popup */
.bemerkung-popup {
    position: absolute;
    background: rgba(0, 0, 0, 0.9);
    color: #fff;
    padding: 5px 10px;
    border-radius: 5px;
    font-size: 12px;
    white-space: nowrap;
    z-index: 1000;
    top: 30px;
    left: 50%;
    transform: translateX(-50%);
    display: none;
}

.btn_icon {
  background: none;
  width: 35px;
  border: none;
  color: red;
  font-size: 24px;
  cursor: pointer;
  padding: 0;
  margin: 0;
}


.btn_icon:disabled {
  background: none;
  cursor: not-allowed;
}

.btn_icon:hover {
  background-color: transparent !important;
  box-shadow: none !important;
  color: inherit !important;
}
/*################################################################################*/
/*################################################################################*/
/*################################################################################*/
/*################################################################################*/
/*################################################################################*/
/*################################################################################*/
/*################################################################################*/
/* Media Queries für kleinere Bildschirme (Tablets und Smartphones) */
@media (max-width: 980px) {
    
table {

    min-width: 100%;
    margin: 10px 0;
    border-collapse: collapse;
}    
    
    #container {
		border: 0px solid red; /* Rahmen */
        width: 100%;
        padding: 0px;
		margin:0;
    }

#container_tabelle {
    width: 100%;
    position: relative; 
    margin:2px 2px;
    padding: 2px;

}
.table-container {
    width: 95%;
	margin:10px;
	padding: 0px;

}

    #teilnehmerInfo {
    max-width: 90%;
}


    .form-container {
        width: 100%;
		
    }



    table {
        width: 100%;
        max-width: 100%;
    }

    h3 {
        font-size: 17px;
    }

    input[type="number"] {
        width: 70%;
    }
	

button.btn_edit {

	min-width: 40px;
	max-width: 70px;
    padding:0px;

}

/* Spezifische Stilregeln für den Bereich zur PDF-Generierung */
a button {
    background-color: #28a745;
   width: 150px ;
    font-size: clamp(8px, 3vw, 20px);
}

a button:hover {
    background-color: #218838;
}
	

.tab_auswertung, .tab_runde, .tab_ausfall, .tab_miss, .tab_durch {

    width: 100%;

}

}
/*################################################################################*/
@media (max-width: 900px) { 
 
.text-desktop { display: none; }
.text-mobile { display: inline; }


/*################################################################################*/
@media (max-width: 470px) { /*Archos*/ 
 
.text-desktop { display: none; }
.text-mobile { display: inline; }

button.btn_edit {
	min-width: 40px;
	max-width: 70px;
    padding:0px;

}
/*################################################################################*/

@media (max-width: 400px) { /*Huawei*/


.tab_runde {
    width: 100%; /* Stellt sicher, dass die Tabelle sich anpasst */
	max-width: 100%;
    table-layout: fixed; /* Erzwingt feste Spaltenbreiten */
}

th {
    width: 5px; /* Feste Breite für die Spalte */
    max-width: 10px; /* Sicherstellen, dass es nicht größer wird */
    overflow: hidden; /* Inhalt wird abgeschnitten */
    text-overflow: ellipsis; /* Zeigt "..." an */
   
}

button.btn_edit {
	min-width: 40px;
	max-width: 65px;
    padding:0px;

/*
  td, th {
    padding-left: 0px;
      padding-right:  0px;
    text-align: center !important;
}
  
button.btn_edit {
	min-width: 40px;
	max-width: 70px;
    padding:0px;


}
*/



}
}