.top-bar-container {
  width: 100%;
  display: flex;
  justify-content: flex-end;
  padding: 10px 0px;
  margin-bottom: 15px;
}
.user-controls-block {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
}
.language-selector-container {
  display: flex;
  align-items: center;
  margin-bottom: 8px;
}
.language-selector-container label {
  margin-right: 8px;
  color: darkgray;
  font-family: "Source Sans 3", sans-serif;
}
.language-selector-container select {
  padding: 5px 8px;
  border-radius: 5px;
  border: 1px solid lightgray;
  background-color: #fff;
  font-family: "Source Sans 3", sans-serif;
  cursor: pointer;
}
.language-selector-container select:focus {
  outline: none;
  border-color: #35b9ab;
  box-shadow: 0 0 0 2px rgba(53, 185, 171, 0.5);
}
.slim-stats-btn {
  color: #ffffff !important;
  padding: 8px 15px !important;
  font-size: 0.9em !important;
  max-width: 150px;
  background: linear-gradient(135deg, #6da741 0%, #61953a 100%) !important;
  border: 2px solid #35b9ab !important;
  font-weight: 600 !important;
}
.slim-stats-btn:hover {
  background: linear-gradient(135deg, #61953a 0%, #6da741 100%) !important;
  transform: translateY(-2px) !important;
  box-shadow: 0 4px 10px rgba(109, 167, 65, 0.3) !important;
}
.slim-stats-btn .quiz-btn-icon {
  font-size: 1.1em !important;
  margin-right: 5px;
}
.slim-stats-btn .quiz-btn-title {
  text-align: left;
}
.opensuse-quiz-logo-header {
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 10px;
  font-family: "Source Sans 3", sans-serif;
}
.opensuse-quiz-logo-header__image {
  height: 100px;
  width: auto;
  margin-right: 20px;
}
.opensuse-quiz-logo-header__text-block {
  line-height: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
}
.opensuse-quiz-logo-header__text--opensuse {
  font-size: 2.5em;
  color: #000000;
  font-weight: 400;
  margin-bottom: -0.2em;
}
.opensuse-quiz-logo-header__text--quiz {
  font-size: 2.7em;
  font-weight: 700;
  color: #2c5a6c;
  /* Dark teal/blue from image */
}
.quiz-main-header .quiz-main-subtitle {
  text-align: center;
  font-family: "Source Sans 3", sans-serif;
  margin-top: 0;
  font-size: 1.3em;
  color: darkgray;
}
@media (max-width: 768px) {
  .opensuse-quiz-logo-header {
    flex-direction: column;
    text-align: center;
  }
  .opensuse-quiz-logo-header__image {
    height: 60px;
    margin-right: 0;
    margin-bottom: 10px;
  }
  .opensuse-quiz-logo-header__text--opensuse {
    font-size: 2.2em;
  }
  .opensuse-quiz-logo-header__text--quiz {
    font-size: 2.4em;
  }
  .quiz-main-header .quiz-main-subtitle {
    font-size: 1.1em;
  }
}
.switch {
  position: relative;
  display: inline-block;
  width: 60px;
  height: 34px;
}
.switch input {
  opacity: 0;
  width: 0;
  height: 0;
}
.slider {
  position: absolute;
  cursor: pointer;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: #ccc;
  transition: 0.4s;
  border-radius: 34px;
}
.slider:before {
  position: absolute;
  content: "";
  height: 26px;
  width: 26px;
  left: 4px;
  bottom: 4px;
  background-color: white;
  transition: 0.4s;
  border-radius: 50%;
}
input:checked + .slider {
  background: linear-gradient(135deg, #35b9ab 0%, #2fa599 100%);
}
input:checked + .slider:before {
  transform: translateX(26px);
}
@keyframes slideIn {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}
.quiz-btn.slide-in {
  animation: slideIn 0.6s ease-out forwards;
}
footer {
  background-color: #333;
  /* Dark background for the footer */
  color: #fff;
  /* Light text color */
  text-align: center;
  padding: 1em 0;
  font-size: 0.9em;
  width: 100%;
  position: fixed;
  /* Make it stay at the bottom */
  bottom: 0;
  left: 0;
  box-shadow: 0 -2px 5px rgba(0, 0, 0, 0.2);
  /* Optional: adds a subtle shadow */
  z-index: 1000;
  /* Ensure footer is above other content */
}
footer p {
  margin: 0.5em 0;
}
footer a {
  color: #73ba25;
  /* openSUSE green for links */
  text-decoration: none;
  font-weight: 500;
  /* Match previous style for Help translate */
}
footer a:hover {
  text-decoration: underline;
}
/* Responsive adjustments for the footer */
@media (max-width: 768px) {
  footer {
    font-size: 0.8em;
    padding: 0.8em 0;
  }
  footer p {
    margin: 0.3em 0;
  }
}
@media (max-width: 300px) {
  footer {
    position: static;
    font-size: 0.75em;
    margin-left: -1rem;
    margin-right: -1rem;
    padding: 2.75rem 1rem;
  }
}
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}
body {
  width: 100%;
  min-height: 100vh;
  font-family: Lato, sans-serif;
  font-size: 1em;
  line-height: 1.5;
  background: linear-gradient(135deg, #73ba25 0%, #6da741 25%, #35b9ab 75%, #173f4f 100%);
  background-size: 400% 400%;
  animation: gradientShift 60s ease infinite;
  padding: 1em;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}
body.small-screen {
  justify-content: space-between;
  /* Changed from default 'center' for small screens */
}
@keyframes gradientShift {
  0% {
    background-position: 0% 50%;
  }
  50% {
    background-position: 100% 50%;
  }
  100% {
    background-position: 0% 50%;
  }
}
h1 {
  margin: 0.4em 0;
  display: inline-block;
  text-align: center;
}
.quiz-subtitle {
  display: block;
  font-size: 1em;
  font-weight: 300;
  color: #173f4f;
  text-align: center;
  margin-bottom: 10px;
}
button {
  color: #fff;
  background: #73ba25;
  font-family: Lato, sans-serif;
  font-size: 1.3em;
  border: none;
  padding: 10px 15px;
  cursor: pointer;
  outline: 0;
  border-radius: 8px;
}
button:hover {
  background: #173f4f;
}
button:active {
  background: #173f4f;
}
.back-btn {
  background: #173f4f;
}
.back-btn:hover {
  background: #2a9186;
}
.quit-btn {
  background: #ff3e51;
}
.quit-btn:hover {
  background: #ff0b23;
}
.container {
  width: 90%;
  max-width: 1100px;
  margin: 1em auto;
  background: #fff;
  padding: 20px;
  border-radius: 8px;
  box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
  z-index: 1;
}
.main-page-container {
  width: 100%;
  max-width: 800px;
  margin: 0 auto;
  padding: 20px;
  display: flex;
  flex-direction: column;
  align-items: center;
  background: rgba(255, 255, 255, 0.95);
  border-radius: 20px;
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
  backdrop-filter: blur(10px);
}
.quiz-header {
  display: flex;
  flex-direction: column;
  align-items: center;
  margin-bottom: 20px;
}
.status-container {
  display: flex;
  flex-wrap: wrap;
  gap: 15px;
  margin: 20px 0;
  justify-content: center;
  align-items: center;
}
#timer {
  background: #173f4f;
  color: #fff;
  padding: 12px 20px;
  border-radius: 8px;
  font-weight: bold;
  font-size: 1.1em;
  display: flex;
  align-items: center;
  gap: 8px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
  border: 2px solid #35b9ab;
  min-width: 160px;
  justify-content: center;
}
#timer.warning {
  background: #f57900;
  border-color: #c26000;
  animation: pulse 1s infinite;
}
#timer.critical {
  background: #ff3e51;
  border-color: #ff0b23;
  animation: pulse 0.5s infinite;
}
@keyframes pulse {
  0% {
    transform: scale(1);
  }
  50% {
    transform: scale(1.05);
  }
  100% {
    transform: scale(1);
  }
}
.correct-count {
  margin: 0.5em 0;
  font-size: 1.2em;
  padding: 12px 20px;
  border-radius: 8px;
  background: #fff;
  color: #173f4f;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
  border: 2px solid #6da741;
  min-width: 200px;
  text-align: center;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
}
.correct-count .username-display {
  font-weight: bold;
  margin-right: 10px;
  color: #173f4f;
}
.correct-count .score {
  font-style: italic;
}
.quizzes {
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: 20px 0;
  align-items: center;
  width: 100%;
  max-width: 600px;
  margin: 0 auto;
}
.quiz-link {
  text-decoration: none;
  width: 100%;
  max-width: 500px;
}
.quiz-btn {
  width: 100%;
  padding: 25px 20px;
  border: none;
  border-radius: 15px;
  font-family: "Lato", sans-serif;
  font-size: 1.2em;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.3s ease;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 15px;
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.15);
  position: relative;
  overflow: hidden;
  color: #fff;
}
.quiz-btn::before {
  content: "";
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
  transition: left 0.5s;
}
.quiz-btn:hover::before {
  left: 100%;
}
.quiz-btn-icon {
  font-size: 1.5em;
  display: block;
}
.quiz-btn-title {
  flex: 1;
  text-align: center;
}
.quiz-btn-color-0 {
  background: linear-gradient(135deg, #173f4f 0%, #112f3b 100%);
  border: 3px solid #35b9ab;
}
.quiz-btn-color-0:hover {
  background: linear-gradient(135deg, #112f3b 0%, #173f4f 100%);
  transform: translateY(-5px);
  box-shadow: 0 12px 30px rgba(23, 63, 79, 0.4);
}
.quiz-btn-color-1 {
  background: linear-gradient(135deg, #35b9ab 0%, #2fa599 100%);
  border: 3px solid #173f4f;
}
.quiz-btn-color-1:hover {
  background: linear-gradient(135deg, #2fa599 0%, #35b9ab 100%);
  transform: translateY(-5px);
  box-shadow: 0 12px 30px rgba(53, 185, 171, 0.4);
}
.quiz-btn-color-2 {
  background: linear-gradient(135deg, #6da741 0%, #61953a 100%);
  border: 3px solid #f57900;
}
.quiz-btn-color-2:hover {
  background: linear-gradient(135deg, #61953a 0%, #6da741 100%);
  transform: translateY(-5px);
  box-shadow: 0 12px 30px rgba(109, 167, 65, 0.4);
}
.quiz-btn-color-3 {
  background: linear-gradient(135deg, #f57900 0%, #dc6c00 100%);
  border: 3px solid #6da741;
}
.quiz-btn-color-3:hover {
  background: linear-gradient(135deg, #dc6c00 0%, #f57900 100%);
  transform: translateY(-5px);
  box-shadow: 0 12px 30px rgba(245, 121, 0, 0.4);
}
/* Responsive Design for Quiz Main Page from styles.css */
@media screen and (max-width: 768px) {
  .quiz-main-header h1 {
    font-size: 2.2em;
  }
  .quiz-main-subtitle {
    font-size: 1.1em;
  }
  .quizzes {
    gap: 10px;
    padding: 15px;
  }
  .quiz-btn {
    padding: 20px 15px;
    font-size: 1.1em;
  }
}
@media screen and (max-width: 480px) {
  .quiz-main-header h1 {
    font-size: 1.8em;
  }
  .quizzes {
    gap: 8px;
  }
  .quiz-btn {
    padding: 18px 12px;
    font-size: 1em;
    gap: 10px;
  }
  .quiz-btn-icon {
    font-size: 1.3em;
  }
  body {
    justify-content: space-between;
    /* Changed from default 'center' for small screens */
  }
}
.q-container .btn-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  grid-gap: 10px;
  margin: 20px 0;
}
.q-container .btn-grid button {
  display: block;
  width: 100%;
  padding: 15px;
  font-size: 1.1em;
  border-radius: 5px;
  transition: background-color 0.3s ease;
  color: #fff;
}
.q-container .btn-grid button:not(.correct):not(.wrong):nth-child(4n + 1) {
  background-color: #173f4f;
}
.q-container .btn-grid button:not(.correct):not(.wrong):nth-child(4n + 1):hover {
  background-color: #0c2028;
}
.q-container .btn-grid button:not(.correct):not(.wrong):nth-child(4n + 2) {
  background-color: #35b9ab;
}
.q-container .btn-grid button:not(.correct):not(.wrong):nth-child(4n + 2):hover {
  background-color: #2a9186;
}
.q-container .btn-grid button:not(.correct):not(.wrong):nth-child(4n + 3) {
  background-color: #6da741;
}
.q-container .btn-grid button:not(.correct):not(.wrong):nth-child(4n + 3):hover {
  background-color: #558233;
}
.q-container .btn-grid button:not(.correct):not(.wrong):nth-child(4n + 4) {
  background-color: #f57900;
}
.q-container .btn-grid button:not(.correct):not(.wrong):nth-child(4n + 4):hover {
  background-color: #c26000;
}
p.question {
  font-size: 1.8rem;
  /* bigger font */
  font-weight: 600;
  padding-left: 14px;
  border-left: 6px solid #35b9ab;
  color: #333;
  margin: 0;
}
.question-container {
  background-color: #f0f0f0;
  /* light grey */
  padding: 16px 20px;
  border-radius: 8px;
  margin: 20px 0;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.1);
}
.btn-container {
  margin: 10px 0;
}
input[type="text"] {
  outline: none;
  border: 1px solid #ccc;
  font-family: Lato, sans-serif;
  padding: 10px;
  display: block;
  width: 100%;
  max-width: 300px;
  height: 45px;
  margin: 0 auto 10px;
  border-radius: 5px;
}
input[type="text"]:disabled {
  background-color: #f0f0f0;
  cursor: not-allowed;
}
.controls-container {
  display: flex;
  flex-direction: column;
  align-items: center;
  margin-top: 20px;
}
.submit-form-bottom {
  display: flex;
  flex-direction: column;
  align-items: center;
  width: 100%;
  max-width: 350px;
}
.submit-form-bottom input[type="text"].input-error {
  border-color: #ff3e51;
  box-shadow: 0 0 5px rgba(255, 62, 81, 0.5);
}
.submit-form-bottom input[type="text"] {
  margin-bottom: 10px;
}
.submit-form-bottom button,
.next-btn {
  width: 100%;
  max-width: 200px;
  margin-bottom: 10px;
}
.check-btn {
  height: 40px;
  line-height: 40px;
  padding: 0 10px;
}
.hide {
  display: none !important;
}
.correct {
  background: #23a833 !important;
  color: #fff !important;
}
.wrong {
  background: #ff3e51 !important;
  color: #fff !important;
}
#loggedInBanner {
  background: #f0f0f0;
  padding: 6px 12px;
  font-size: 0.9em;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-radius: 4px;
  margin: 10px 0;
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  z-index: 10;
  max-width: 90vw;
  box-sizing: border-box;
  flex-wrap: wrap;
}
#loggedInUserText {
  margin-right: 10px;
  word-break: break-word;
}
#logoutBtn {
  background: #ff3e51;
  border: none;
  color: #fff;
  border-radius: 3px;
  padding: 5px 10px;
  margin-left: 10px;
  cursor: pointer;
  font-size: 0.8em;
  flex-shrink: 0;
  min-width: 60px;
}
/* Responsive adjustments for smaller screens */
@media (max-width: 600px) {
  .top-bar-container {
    flex-direction: column;
    align-items: center;
  }
  #loggedInBanner {
    position: static;
    transform: none;
    flex-direction: column;
    /* Stack items vertically */
    align-items: stretch;
    /* Stretch items to fill width */
    text-align: center;
    padding: 10px;
    margin-bottom: 10px;
  }
  #loggedInUserText {
    margin-right: 0;
    /* Remove right margin when stacked */
    margin-bottom: 8px;
    /* Add bottom margin when stacked */
  }
  #logoutBtn {
    width: 100%;
    /* Make button full width */
    margin-top: 5px;
    /* Add some space above the button */
    margin-left: 0;
  }
  .user-controls-block {
    width: 100%;
    align-items: center;
    margin-top: 10px;
  }
  .language-selector-container {
    flex-direction: column;
    align-items: center;
    width: auto;
  }
  .language-selector-container label {
    margin-right: 0;
    margin-bottom: 5px;
  }
  .language-selector-container select {
    width: auto;
  }
  .stats-link-container {
    width: auto;
    display: flex;
    justify-content: center;
    margin-top: 10px;
  }
}
@media screen and (max-width: 894px) {
  .container {
    width: 90%;
  }
  .q-container .btn-grid {
    grid-template-columns: 1fr;
  }
  .correct-count {
    float: none;
    width: 100%;
    text-align: center;
    margin-top: 10px;
  }
  .controls-container {
    width: 100%;
  }
  .submit-form-bottom input[type="text"],
  .submit-form-bottom button,
  .next-btn {
    max-width: 100%;
  }
}
/* results */
table .results {
  border: 0;
}
table.results th,
td {
  border-bottom: 1px solid black;
}
/* Add padding to the main content containers to prevent overlap with the fixed footer */
.main-page-container,
.container {
  /* Apply to both common content wrappers */
  padding-bottom: 12em;
  /* Increased base padding, adjust if needed */
}
@media (max-width: 768px) {
  .main-page-container,
  .container {
    padding-bottom: 11em;
    /* Adjusted for medium screens */
  }
}
@media (max-width: 480px) {
  .main-page-container,
  .container {
    /* Adjust padding-bottom as footer is now in normal flow.
       This adds a bit more space above the static footer.
    */
    padding-bottom: 3em;
    /* Spacing for when footer is static */
  }
}
