body {
    font-family: system-ui, sans-serif;
    background: #111;
    color: #eee;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
    height: 100vh;
    margin: 0;
    padding-top: 1rem;
}

.topbar {
    width: 80%;
    display: flex;
    justify-content: space-between;
    margin-bottom: 1rem;
}

.topbar input {
    flex: 1;
    margin-right: 1rem;
    padding: 0.5rem;
    border-radius: 6px;
    border: none;
    background: #222;
    color: #fff;
}

.card {
    width: 60vw;
    height: 40vh;
    background: #222;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2em;
    text-align: center;
    padding: 20px;
    cursor: pointer;
    transition: transform 0.6s;
}

.face {
    display: none;
}

.face.active {
    display: block;
}

.controls {
    margin-top: 20px;
}

button {
    margin: 0 10px;
    padding: 10px 20px;
    background: #333;
    border: none;
    color: #fff;
    cursor: pointer;
    border-radius: 6px;
}

button:hover {
    background: #555;
}

#progress {
    margin-top: 1rem;
    font-size: 0.9em;
    color: #aaa;
}

.site-header {
    width: 90%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 1rem;
}

.header-left {
    display: flex;
    align-items: center;
}

.logo {
    height: 48px;
    width: 48px;
    margin-right: 12px;
}

.header-right {
    display: flex;
    align-items: center;
    gap: 10px;
}

header h1 {
    font-size: 1.5rem;
    color: #fff;
    margin: 0;
}

main {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
}

.focusbar {
    width: 80%;
    display: flex;
    align-items: center;
    justify-content: flex-start;
    margin-bottom: 1rem;
    color: #ccc;
}

.focusbar label {
    margin-right: 0.5rem;
}

#focusSelect {
    background: #222;
    color: #fff;
    border: none;
    padding: 6px 10px;
    border-radius: 6px;
}

.speed-control {
    display: inline-flex;
    align-items: center;
    margin-left: 15px;
    color: #ccc;
}

.speed-control select {
    margin-left: 5px;
    background: #222;
    color: #fff;
    border: none;
    border-radius: 6px;
    padding: 5px 10px;
}

/* --- Study Mode active visual --- */
#study.active {
  background: #27ae60;
  color: #fff;
  box-shadow: 0 0 12px #27ae60;
}

/* --- Progress bar --- */
#progress {
  text-align: center;
  margin: 10px auto;
  color: #ccc;
  font-size: 14px;
}

#progress-bar-container {
  width: 80%;
  height: 10px;
  background: #222;
  border-radius: 5px;
  margin: 6px auto 15px;
  overflow: hidden;
}

#progress-bar {
  height: 100%;
  width: 0%;
  background: #27ae60;
  transition: width 0.3s ease;
}

/* --- Progress bar for deck position --- */
#progress {
  text-align: center;
  margin: 8px auto;
  color: #ccc;
  font-size: 14px;
}

#progress-bar-container {
  width: 80%;
  height: 10px;
  background: #333;
  border-radius: 5px;
  margin: 5px auto 15px;
  overflow: hidden;
}

#progress-bar {
  height: 100%;
  width: 0%;
  background: #1abc9c;
  transition: width 0.25s ease;
}

/* --- Study Mode active visual --- */
#study.active {
  background: #1abc9c;
  color: #fff;
  box-shadow: 0 0 12px #1abc9c;
}

/* ================================
   QUIZ MODE STYLING (Centered)
================================== */
#quiz-area {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  margin-top: 40px;
  text-align: center;
  width: 100%;
}

#quiz-question {
  font-size: 2rem;
  font-weight: 700;
  text-align: center;
  color: #00e6a8; /* teal highlight */
  margin-bottom: 30px;
  border-bottom: 2px solid #00e6a8;
  padding-bottom: 10px;
  width: 80%;
  max-width: 900px;
}

/* Center answers in a vertical layout with multiple rows */
#quiz-options {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin: 20px 0;
  max-width: 600px;
}

/* Each row can have 2 options max */
.quiz-row {
  display: flex;
  justify-content: center;
  gap: 15px;
  width: 100%;
}

#quiz-options .option {
  flex: 1;
  min-width: 45%;
  max-width: 45%;
  padding: 15px 20px;
  background: #333;
  border: 2px solid #555;
  color: #eee;
  border-radius: 8px;
  cursor: pointer;
  font-size: 16px;
  transition: all 0.2s;
}

#quiz-options .option:hover {
  background: #444;
  border-color: #777;
}

#quiz-options .option:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

#quiz-feedback {
  font-size: 18px;
  font-weight: bold;
  margin: 15px 0;
  min-height: 25px;
}

#quiz-progress {
  font-size: 16px;
  color: #ccc;
  margin-top: 10px;
}

/* Add this to your style.css in the exercise-switch section */

.exercise-switch {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 1rem;
    justify-content: center;
}

.exercise-switch label {
    color: #ccc;
    font-size: 14px;
}

.exercise-switch select {
    padding: 8px 12px;
    background: #222;
    border: 1px solid #555;
    color: #eee;
    border-radius: 6px;
    font-size: 14px;
}

.exercise-switch button {
    padding: 8px 16px;
    background: #444;
    border: 1px solid #666;
    color: #eee;
    border-radius: 6px;
    cursor: pointer;
    font-size: 14px;
    transition: background-color 0.3s;
}

.exercise-switch button:hover {
    background: #555;
}

#toggleReverse {
    font-weight: bold;
    min-width: 140px;
}

