/* ===== Algemene instellingen ===== */

@font-face {
  font-family: LED; /* set name */
  src: url(fonts/LED-Regular.ttf); /* url of the font */
}

body {
  background-color: #333;
  color: #fff;
  font-family: 'Orbitron', 'Digital-7', monospace;
  margin: 0;
  padding: 0;
  align-content: center;
  user-select: none;
}

h3, h4, h5, h6 {margin:0;}
.btn { font-size: 32px;}

#footer {
  display:block;
  position: relative;
  float:left;
  width:98vw;
  text-align:center;
  color:#AAA;
}

#footer a { color:#bbb;}
/* ===== Team panelen ===== */
.team {
  display: block;
  position: relative;
  float:left;
  width: 47vw;
  height: 80%;
  border-radius: 10px;
  box-shadow: 0 0 30px rgba(255,255,255,0.3);
  padding: 20px;
}

.player-card.home {
  background: linear-gradient(180deg, #f7d708 0%, #d4a90b 100%);
  color: #000;
}

.player-card.away {
  background: linear-gradient(180deg, #0057e7 0%, #003ea1 100%);
  color: #fff;
}

.player-card {
    display:block; 
    width:100px;
    height:120px;
    margin:5px;
    float:left; 
    position:relative;
    border:1px #000 solid; 
}

.player-card .number, .referee .number { 
    font-size: 68px; 
    text-align: center; 
    display:block;
    margin:2px 5px;
}
.player-card .name, .referee .name { 
    font-size: 12px; 
    text-align: center; 
    width: 80px; 
    display:block;
    margin:2px 5px;
}

.player-row, .referee-row, .goalie-row {display:block; line-height: 30px; padding: 0 20px;}

.player-row.home {
  background: linear-gradient(180deg, #f7d708 0%, #d4a90b 100%);
  color:#003ea1;
}
.goalie-row.home {
  display:block;
  background: linear-gradient(180deg, #f7e25c 0%, #edce5f 100%);
  color:#003ea1;
}
.player-row.away {
  display:block;
  background: linear-gradient(180deg, #0057e7 0%, #003ea1 100%);
}
.goalie-row.away {
  display:block;
  background: linear-gradient(180deg, #4188fb 0%, #1969ea 100%);
}

#referees .player-card .name { background : #000; padding: 2px; display: block;}
#referees .player-card .number { color: #000;background : #FFF; display: block; text-shadow: 5px 2px 5px #FFF; padding:0px;}

#referees .player-card {
  background:repeating-linear-gradient(90deg, #fff 0 10px, #333 10px 30px);
}

.player .goalie { border: dashed 3px #000; width: 100%; }
.goalie .number {
    font-size: 32px; 
    text-align: left; 
    margin:20px 5px;
}


.team h1 {
  font-size: 14px;
  margin: 0;
  letter-spacing: 2px;
  text-transform: uppercase;
}


#clock-container {
    display:grid;
    align-items:center;
    justify-items: center;
    height: 80vh;
    width: 94vw;
    position:relative;
    font-family: LED; 
    float:left;
    margin:10px;
    padding:5px;
    background:linear-gradient(180deg, #1e00b4 0%, #111 100%);
    border:2px #999 solid;
}

.scores {
  display:flex; 
  position: absolute; 
  align-content:center; 
  height:38vh;
  border:1px #fff solid;
top:20px;
background:#ffbe00;
}

#goal-home, #goal-away { display: block; float:left;}

.score, .scores {
  font-size: min(50vh,  36vw);
  text-shadow: 0 0 1px rgba(255,255,255,0.6);
}



.score {margin-top:-50px;}

/* ===== Centrale klok en periode ===== */
.center {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
}


#clock {
  color: #333;
  text-align:center;
  width: 40vw;
  margin:-10vh auto;
}

#clock-time {
background:#ffbe00; 
color:#000; 
text-shadow: #000 1px 1px;;
display: block;
width: 37vw;
height: 11vw;
padding:0;
margin:-8vh auto;
cursor: pointer;
}

#clock-time span
{
  float:left;
  font-size: 15vw;;
padding: 0;
margin-top: -7vh ;
margin-left: 10px;
}

#clock.small {  font-size: 18px; padding:0;}

#period {
    margin:200px auto 0 auto;
    padding:2px 2px;
    height: 13vh;
  font-size: min(20vh,  26vw);
  display:grid;
  color: #333;
  background:#FFF;
  z-index:9;
}

#period span {
    margin-top:-40px; display:grid;;
}

/* ===== Strafbank sectie ===== */
#scoreboard .btn {height: auto; width: auto;}
#scoreboard .btn.left {
left: -600px;
position: absolute;
bottom: 0;
}

#scoreboard .btn.right {
right: -600px;
position: absolute;
bottom: 0;
float: right;
}
.penalties {
  display:flex;
  position:absolute;
  top:100px;
  font-weight: bold;
}

.penalties .spacer {width: 140px;}

.penalty-box {
  position:static;
  font-size:42px;
  background:#000;
}

#penalties-away {left:0; bottom:0; display:block; position:fixed ; text-align:right !important;}
#penalties-home {right:0; bottom:0; display:block;position:fixed; float:right; }
#penalties-away div {display:block; position:relative;}
#penalties-home div {display:block; position:relative;}

.penalty {
  background-color: rgba(255,255,255,0.1);
  border: 2px solid rgba(255,255,255,0.3);
  border-radius: 10px;
  padding: 5px 10px;
  font-size: 5vw;
  font-weight: bold;
  display: flex;
  width:  30vw;
}

.penalty .player {
  font-weight: bold;
}

.penalty .timer {
  color: #ff4444;
  font-weight: bold;
}

#away-team-controls {left:0;position: relative; display: grid; width: 47vw; float:left; }
#home-team-controls {right:0;position: relative; display: grid; width: 47vw; float:left;}

#away-team-controls button, 
#home-team-controls button {
  width:45vw !important;
}

/* ===== Animaties en geluidseffecten ===== */
@keyframes blink {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.3; }
}

.blink {
  animation: blink 1s infinite;
}

/* ===== Admin specifieke styling (optioneel) ===== */
.admin-panel {
  padding: 2rem;
  background-color: #111;
  color: #fff;
  font-family: sans-serif;
}

.admin-panel input, .admin-panel select, .admin-panel button {
  margin: 0.5rem;
  padding: 0.5rem;
  border-radius: 6px;
  border: none;
  font-size: 1rem;
}

.admin-panel button {
  background-color: #007bff;
  color: white;
  cursor: pointer;
}

.admin-panel button:hover {
  background-color: #0056b3;
}

body.admin-page {
  font-family: Arial, sans-serif;
  background: #111;
  color: #eee;
  padding: 20px;
}

.admin-controls {
  margin: auto;
  background: #222;
  padding: 20px;
  border-radius: 10px;
}

.admin-controls h3 {
  color: #ffb400;
  margin-top: 15px;
}

.btn {
  background: #333;
  color: #fff;
  width: 200px;
  height: 200px;
  padding: 8px 12px;
  margin: 3px;
  border: none;
  border-radius: 5px;
  cursor: pointer;
}
.btn:hover { opacity: 0.8; }
.btn.green { background: #28a745; }
.btn.orange { background: #ff9800; }
.btn.red { background: #dc3545; }
.btn.away { background: #007bff; }
.btn.gray { background: #666; }

.btn#btnAddGoal-awayteam {background: #007bff;}
.btn#btnAddGoal-hometeam {background: #eed309; Color:#003;}

input, select {
  padding: 6px;
  margin: 3px;
  border-radius: 4px;
  border: 1px solid #444;
  background: #000;
  color: #fff;
}

.btn.red {
  background: #dc3545;
}
.btn.red:hover {
  background: #b52a35;
}

.admin-container {
  max-width: 800px;
  margin: 30px auto;
  background: #111;
  color: #eee;
  padding: 20px;
  border-radius: 10px;
  box-shadow: 0 0 10px #000;
}
label {
  display:block;
  margin-top:8px;
  font-weight:bold;
}
input, select {
  width:100%;
  padding:6px;
  margin-top:4px;
  border-radius:4px;
  border:1px solid #333;
  background:#222;
  color:#fff;
}
.btn.green {
  background:#28a745;
  color:#fff;
  border:none;
  padding:10px 20px;
  border-radius:6px;
  cursor:pointer;
  margin-top:10px;
}
.btn.green:hover {
  background:#218838;
}
.ok { background:#003300; color:#00ff66; padding:8px; margin-top:10px; }
.error { background:#330000; color:#ff6666; padding:8px; margin-top:10px; }

.dialog {
  position: fixed; top: 20; left: 0;
  width: 100vw; height: vh;
  background: rgba(0,0,0,0.5);
  display: flex; align-items: center; justify-content: center;
}
.dialog.hidden { display: none; }
.dialog-content {
  background: #fff; padding: 20px; border-radius: 8px; width: 620px; color:#000;
}

.dialog-content label.team {
 display:block;
 width: 100px;
 clear:both;
}

label.player {  
  float:left;
  padding:2px;
  margin: 5px;
  width:100px;
  height:100px;
  text-align: center;
}

label.player .number {font-size:40px;display:block; clear:both;}

.dialog-content label.player-home, .dialog-content label.player-away {
  float:left;
  padding:2px;
  width:100px;
  height:100px;
  text-align:center;
  font-size:60px;
  border:1px solid #666;
}

.dialog-content input[type=radio], input[type=checkbox].hiddenBox {
  display: none; float:left;
}
.dialog-content input[type="radio"]:checked+label, input[type="checkbox"]:checked+label{ background: #090; } 
label.player-home.hidden {display:none;}
label.player-away.hidden {display:none;}

.dialog-buttons { margin-top: 15px; display: block; width:600px; justify-content: space-between; }


/* CHAT GPT CODE */ 

/* ===== Algemene stijl ===== */
body.admin-page {
  font-family: system-ui, -apple-system, Roboto, sans-serif;
  background: #f7f9fc;
  margin: 0;
  padding: 1rem;
  color: #222;
}

h1 {
  font-size: 1.5rem;
  text-align: center;
  margin-bottom: 1rem;
}

/* ===== Knoppen ===== */
.btn {
  display: inline-block;
  background: #007bff;
  color: white;
  border: none;
  padding: 0.8rem 1rem;
  margin: 0.3rem 0.2rem;
  border-radius: 0.6rem;
  font-size: 1rem;
  text-align: center;
  cursor: pointer;
  text-decoration: none;
  transition: background 0.2s;
  box-sizing: border-box;
  font-size:80px;
}

button.settings {display:grid; right:0; float:left; z-index:9;}

.btn:hover {
  background: #0069d9;
}

.btn.green {
  background: #28a745;
}
.btn.green:hover {
  background: #218838;
}

.btn.orange {
  background: #fd7e14;
}
.btn.orange:hover {
  background: #e96d0c;
}

.btn.red {
  background: #dc3545;
}
.btn.red:hover {
  background: #c82333;
}

.btn.gray {
  background: #6c757d;
}
.btn.gray:hover {
  background: #5a6268;
}

/* ===== Layout containers ===== */
.admin-controls {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.match-info {
  background: #fff;
  border-radius: 0.75rem;
  box-shadow: 0 2px 4px rgba(0,0,0,0.1);
  padding: 1rem;
  font-size: 0.95rem;
}

.buttons, .match-actions {
  display: flex;
  justify-content: space-between; /* left / right */
  align-items: center;
  gap: 1rem; /* ruimte tussen eventueel meerdere knoppen */
  margin-top: 0.5rem;
}

#away-team-controls,
#home-team-controls {
  display: flex;
  gap: 0.5rem;
  align-items: center;
}

/* ===== Dialoog (popup) ===== */
.dialog {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0,0,0,0.6);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
  overflow:scroll;
}

.dialog.hidden {
  display: none;
}

.dialog-content {
  background: #fff;
  padding: 1.5rem;
  border-radius: 1rem;
  width: 90%;
  box-shadow: 0 4px 10px rgba(0,0,0,0.25);
}

.dialog-content h3 {
  margin-top: 0;
  font-size: 1.2rem;
  text-align: center;
}

.dialog-buttons {
  display: flex;
  justify-content: space-between;
  margin-top: 1rem;
}

.dialog input[type="text"] {
  width: 100%;
  padding: 0.5rem;
  border-radius: 0.5rem;
  border: 1px solid #ccc;
  margin-bottom: 0.5rem;
  font-size: 3rem;
}
.dialog .btn {width:auto;}

/* ===== Spelerlabels ===== */
label.team {
  display: block;
  margin-top: 0.5rem;
  font-weight: bold;
}

label[class*="player-"] {
  display: inline-block;
  margin: 0.2rem;
  padding: 0.4rem 0.6rem;
  border-radius: 0.5rem;
  border: 1px solid #ddd;
  cursor: pointer;
}

.player-home {
  background: #e6f5ff;
}
.player-away {
  background: #ffe6e6;
}

/* ===== Kleine schermen ===== */
@media (max-width: 768px) {
  body.admin-page {
    padding: 0.5rem;
  }

  h1 {
    font-size: 1.3rem;
  }

  .btn {
    font-size: 1rem;
    padding: 0.7rem;
  }

  .match-info {
    font-size: 0.9rem;
  }

  .buttons,
  .match-actions {
    flex-direction: column;
  }
}

/* ===== Zeer kleine schermen (telefoon in portret) ===== */
@media (max-width: 480px) {
  h1 {
    font-size: 1.1rem;
  }

  .btn {
    font-size: 0.9rem;
  }

  .dialog-content {
    padding: 1rem;
  }
}

.buttons .btn {width:auto !important;}
.btn.auto-width {width:auto;}

#scoreboard div[id*="home"] {text-shadow:#ffbe00 5px 5px; color:#111;}
#scoreboard div[id*="away"] {text-shadow:#a5c7ff 5px 5px; color:#111;}

section.page {display:block; width: 98vw; height:100vw; clear:both;}


.scores #score-away.score, .scores #score-home.score { 
  display: block; 
  padding: 0; 
margin:-9vh 1vw 0 1vw;
  color:#000;
  text-shadow: #000 5px 5px 2px;;;
}


#score-summary  { display:block; width:600px; border:1px solid #fff; margin: 0 auto; padding:20px; position: relative; overflow: hidden;}
#score-summary div  { width:550px; clear:both; display:block;}
#score-summary div.home { background:#a5c7ff;}
#score-summary div.away { background:#ffbe00;}
#score-summary div span { margin: 0 10px; display:block; float:left;}
#score-summary div span.time { width:70px;}
#score-summary div span.type { width:100px;}
#score-summary div span.name { width:300px;}