
/* ---------------- HEADER LAYOUT ---------------- */

header {
    width: 100%;
    margin-bottom: 20px;
}

/* Top row: Score | Title | Timer */
.headerTop {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
    margin-bottom: 15px;
}

/* Score styled like timer */
.scoreBox {
    display: flex;
    justify-content: center;
    align-items: center;

    background: #FC6F17;
    color: white;

    padding: 8px 16px;
    border-radius: 6px;

    font-size: 24pt;
    font-weight: bold;
}

/* Title centered */
.titleBox {
    flex: 1;
    text-align: center;
    font-size: 20pt;
    font-weight: bold;
}

/* Timer styled like a badge */
.timerBox {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 12px;

    background: #FC6F17;
    color: white;

    padding: 8px 16px;
    border-radius: 6px;
    font-size: 26pt;
    font-weight: bold;
}


.timerBox #seconds {
    font-size: 26pt;
}

.timerBox #tenthseconds {
    font-size: 20pt;
}

/* ---------------- BEST ROW ---------------- */

.bestRow {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
    gap: 3px;
}

.bestBox {
    flex: 1;
    text-align: center;
    padding: 8px 10px;
    font-size: 12pt;
    border-radius: 6px;
    font-weight: bold;
}

/* Last Score (new) */
.lastScoreBox {
    background: #FF6600;
    color: white;
}

.lastTimeBox {
    background: #FF6600;
    color: white;
}


/* Best Time */
.bestTimeBox {
    background: #00CC66;
    color: white;
}

/* Best Score */
.bestScoreBox {
    background: #00CC66;
    color: white;
}

.averageScoreBox {
    background: #ff8533;
    color: white;
}


/* Clear button */
.clearButton {
    flex: 1;
    padding: 6px 12px;
    font-size: 10pt;
    background: #FF4444;
    color: white;
    border: none;
    border-radius: 6px;
    cursor: pointer;
}

/* ---------------- GAME AREA ---------------- */

.gameArea {
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 100%;
}

#question {
    font-size: 22pt;
    text-align: center;
    margin-bottom: 20px;
}

/* EXACTLY 5 ANSWER BOXES PER ROW, TOUCHING LIKE LEGO BRICKS */
#choices {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    width: 100%;
    margin: 0;
    padding: 0;
    gap: 0;
}

/* LEGO BRICK STYLE */
.choice:nth-child(odd) {
    width: 100%;
    height: 100%;
    padding: 26px 0;
    margin: 0;

    background: linear-gradient(145deg, #d32f2f 0%, #b71c1c 100%);
    color: white;

    border-radius: 8px;
    border: 3px solid #8b1515;
    line-height: 1.0;  
    text-align: center;
    font-size: 22pt;
    font-weight: bold;
    cursor: pointer;

    box-sizing: border-box;

    /* glossy plastic effect */
    box-shadow:
        inset 0 4px 6px rgba(255,255,255,0.35),
        inset 0 -4px 6px rgba(0,0,0,0.25);
}

.choice:nth-child(even) {
   width: 100%;
height: 100%;
padding: 26px 0;
margin: 0;

background: linear-gradient(145deg, #ff8a00 0%, #e65100 100%);
color: white;

border-radius: 8px;
border: 3px solid #b34700;
line-height: 1.0;  
text-align: center;
font-size: 22pt;
font-weight: bold;
cursor: pointer;

box-sizing: border-box;

/* glossy plastic effect */
box-shadow:
    inset 0 4px 6px rgba(255,255,255,0.35),
    inset 0 -4px 6px rgba(0,0,0,0.25);
}




/* Correct / Incorrect */
.green {
    background: #00CC66 !important;
    color: white !important;
    border-color: #008844 !important;
}

.red {
    background: #CC0000 !important;
    color: white !important;
    border-color: #880000 !important;
}

.black {
    background: #000000 !important;
    color: white !important;
    border-color: #000000 !important;
}

.ms-small {
    font-size: 0.6em;   /* smaller text */
    opacity: 0.7;       /* optional: slightly faded */
    margin-left: 4px;   /* optional spacing */
}

.sound-control {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  font-size: 20px;
  margin: 0 auto;
  width: fit-content;
}

/* Slider container */
.switch {
  position: relative;
  display: inline-block;
  width: 50px;
  height: 26px;
}

/* Hide checkbox */
.switch input {
  opacity: 0;
  width: 0;
  height: 0;
}

/* Slider background */
.slider {
  position: absolute;
  cursor: pointer;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: #ccc;
  transition: .4s;
  border-radius: 26px;
}

/* Slider circle */
.slider:before {
  position: absolute;
  content: "";
  height: 20px;
  width: 20px;
  left: 3px;
  bottom: 3px;
  background-color: white;
  transition: .4s;
  border-radius: 50%;
}

/* When checked */
input:checked + .slider {
  background-color: #4CAF50;
}

input:checked + .slider:before {
  transform: translateX(24px);
}