/* CSS variables */
:root {
    --bg: #002B75;
    --bg-gradient: linear-gradient(0deg, rgba(0,46,186,1) 0%, rgba(0,43,117,1) 100%);
    --bg-overlay: #002b75cd;
  
    --primary-text: #050505;
    --secondary-text: #65676B;
    --footer-text: #EFEDFC;
  
    --gray-bar: #9F9F9F;
    
    --correct-color: #5CC183;
    --correct-color-fill: #CDFFCD;
    --incorrect-color: #FF7971;
  
    /* primary color buttons */
    --button-fill: #002B75;
    --button-fill-pressed: #506C9C;
    --button-fill-share: #002B75;
    --button-text: white;
  }
  
  html {
    min-height: 100%;
  }
  
  body {
    margin: 0;
    padding: 0;
    min-height: 100%;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif;
    background: var(--bg-gradient);
  }
  
  /* header styling */
  h1 {
    font-weight: 800;
  }
  
  .correct {
    background-color: var(--correct-color)
  }
  
  .incorrect {
    background-color: var(--incorrect-color)
  }
  
  .wrapper {
    max-width: 440px;
    
    padding: 0px 20px 0px 20px;
    margin-left: auto;
    margin-right: auto;
  }
  
  header{
    padding: 20px 0px 20px 0px;
    width: 100%;
    text-align: center;
    color: white;
  
    display: flex;
    justify-content: center;
    align-items: center;
  }
  
  header h1 {
    margin: 0;
    padding: 0;
    flex-grow: 1;
  }
  
  .header-icons {
    font-size: 24px;
    cursor: pointer;
  }
  
  .header-icons:active{
    opacity: 50%;
  }
  
  .guesses {
    margin: 16px 0px 0px 0px;
  
    display: flex;
    flex-direction: row;
    justify-content: center;
    gap: 20px;
  }
  
  .guess{
    width: 16px;
    height: 16px;
    border-radius: 20px;
  
    box-sizing: border-box;
    -moz-box-sizing: border-box;
    -webkit-box-sizing: border-box;
    border: 2px solid white;
  
    display: flex;
    justify-content: center;
    align-items: center;
  
    opacity: .5;
  }
  
  .guess.active {
    opacity: 1;
    background-color: white;
    border: none;
  
    animation: active-blinking 1.5s ease infinite;
  }
  
  .guess.incorrect {
    color: white;
    opacity: 1;
    border: none;
    background-color: var(--incorrect-color);
  }
  
  .guess.correct {
    color: white;
    opacity: 1;
    border: none;
    background-color: var(--correct-color);
  }
  
  #sortable_container {
    font-family: arial;
    font-size: 24px;
    width: 100%;
    margin-left: auto;
    margin-right: auto;
    /* Center child horizontally*/
    gap: 12px;
  
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
  }
  
  p#shuffled {
    display: none;
  }
  
  .displayed-event {
    font-size: 16px;
    padding: 16px;
  
    color: var(--primary-text);
    background-color: white;
    font-weight: 600;
    min-width: 240px;
    width: 100%;
  
    border-radius: 16px;
    -webkit-touch-callout: none;
    -webkit-user-select: none;
    -khtml-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
    user-select: none;
  
    -webkit-box-sizing: border-box; 
    -moz-box-sizing: border-box;    
    box-sizing: border-box;   
    box-shadow: 0px 4px 24px rgba(0, 0, 0, 0.1);
  }
  
  .correctly-placed {
    background-color: var(--correct-color-fill);
  }
  
  .displayed-event:hover {
    cursor: grab;
  }
  
  .displayed-event a {
    color: var(--primary-text);
    text-decoration: none;
  }
  
  .event-more-info {
    display: flex;
    flex-direction: row;
    align-content: center;
  
    font-size: 16px;
    font-weight: 500;
  }
  
  .event-more-info a {
    width: 100%;
    display: flex;
    flex-direction: row;
    align-content: center;
    justify-content: center;
  
    margin-top: 8px;
  
    background-color: rgba(255, 255, 255, 0.7);
    border-radius: 8px;
    padding: 8px;
  }
  
  .event-more-info i {
    padding-top: 1px;
  }
  
  .sortable-ghost {
    visibility: hidden;
  }
  
  #results {
    color: var(--primary-text);
    font-weight: 600;
  
    border-radius: 12px;
    border-style: solid;
    border-width: 2px;
  
    margin-bottom: 10px;
    padding: 8px;
    margin-left: 20%;
    margin-right: 20%;
  
    font-size:large;
  }
  
  button {
    font-size: 17px;
    font-weight: 600;
  
    color: var(--button-text);
    background-color: var(--button-fill);
  
    border-radius: 5px;
    border: 0;
    box-shadow: none;
  
    padding: 10px 32px 10px 32px;
    margin-left: auto;
    margin-right: auto;
  
    cursor: pointer;
  }
  
  button:active {
    background-color: var(--button-fill-pressed);
  }
  
  .reset-button {
    font-size: 14px;
  }
  
  .check-answers-footer {
    width: 100%;
    display: flex;
    justify-content: center;
  
    margin-top: 12px;
  }
  
  .related-game-wrap span {
  color: #ededed;
  display: block;
  text-align: center;
  font-weight: bold;
}
.related-game-wrap a {
  color: #ededed;
  text-decoration: none;
}
.related-game-wrap {
  margin-top: 20px;
  padding: 10px 0px;
  border: 1px solid #999999;
  border-radius: 20px;
  padding-bottom: 30px;
}
.related-game {
  display: flex;
  justify-content: space-evenly;
  margin-top: 12px;
  flex-direction: row;
  flex-wrap: wrap;
}
.related-game button {
  margin: inherit;
  margin-top: 10px;
}
  footer{
    color: var(--footer-text);
    text-align: center;
    padding: 32px 0px 32px 0px;
  }
  
  footer a {
    text-decoration: none;
    color: var(--footer-text);
  }
  
  /**************************************/
  /* Modal */
  /**************************************/
  .modal {
    display: none;
    position: fixed; /* Stay in place */
    z-index: 1; /* Sit on top */
    left: 0;
    top: 0;
    width: 100%; /* Full width */
    height: 100%; /* Full height */
    overflow: auto; /* Enable scroll if needed */
    background-color: var(--bg-overlay); 
  
    flex-direction: column;
    gap: 20px;
    justify-content: center;
    align-items: center;
  }
  
  .modal-content {
    background-color: #fefefe;
    padding: 20px;
    width: 80%; /* Could be more or less, depending on screen size */
    max-width: 280px;
    border-radius: 16px;
    position: relative;
  }
  
  .modal-content h3 {
    margin: 12px 0px 20px 0px;
  }
  
  .modal-header {
    position: absolute;
    right: 20px;
  }
  
  .bi-x-lg {
    color: var(--secondary-text);
  }
  
  .modal-toggle {
    display: flex;
    flex-direction: row;
    gap: 12px;
    padding: 12px 0px 20px 0px;
  }
  
  .toggle-option {
    color: var(--primary-text);
    background: none;
    border-radius: 0;
    width: 120px;
    text-align: center;
    cursor: pointer;
  }
  
  .toggle-option:focus {
     background-color: white;
  }
  
  .toggle-option.active {
    border-bottom: 3px solid var(--button-fill-share);
  }
  
  #share-modal-stats-today {
    display: flex;
    flex-direction: column;
    align-items: center;
  } 
  
  #share-modal-stats-lifetime {
    display: flex;
    flex-direction: column;
    align-items: center;
  }
  
  .modal-section {
    display: flex;
    flex-direction: column;
    align-items: center;
  }
  
  /* Intro NUX */
  #nux_content {
    width: 300px;
  }
  
  #nux_content {
    text-align: center;
  }
  
  #nux_content img {
    width: 100%;
    border-radius: 8px;
  }
  
  /* Stats NUX */
  .statistics {
    display: flex;
    flex-direction: row;
    gap: 20px;
    margin-top: 12px;
  }
  
  .today-stat-group {
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 80px;
  }
  
  .stat-label{
    font-size: 14px;
  }
  
  .stat {
    font-size: 24px;
    font-weight: 600;
  }
  
  .stat-medal {
    font-size: 36px;
    font-weight: 600;
  }
  
  .distribution {
    width: 100%
  }
  
  .distribution-group {
    display: flex;
    flex-direction: row;
    align-items: center;
  
    font-size: 24px;
  }
  
  .modal-footer {
    display: flex;
    flex-direction: column;
    gap: 8px;
    justify-content: center;
    margin: 20px 0px 0px 0px;
  }
  
  .modal-footer button:active{
    opacity: .7;
  }
  
  .modal-footer button{
    background-color: var(--button-fill-share);
    display: block;
  }
  
  .modal-footer a {
    color: var(--button-fill-share);
    text-decoration: none;
    font-size: 17px;
    font-weight: 600;
    padding: 10px 32px 5px 32px;
  }
  
  .modal-close {
    cursor: pointer;
  }
  
  #snackbar-wrapper {
    visibility: hidden;
    position: fixed;
    top: 0;
    left: 0;
    height: 100%;
    width: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
    pointer-events: none;
    z-index: 2;
  }
  
  #success-snackbar {
    min-width: 250px;
    background-color: #333; 
    color: #fff; 
    text-align: center;
    border-radius: 8px; 
    padding: 16px;
    position: absolute;
    top: 40px;
  }
  
  #snackbar-wrapper.show {
    visibility: visible;
    -webkit-animation: fadein 0.5s, fadeout 0.5s 1.75s;
    animation: fadein 0.5s, fadeout 0.5s 1.75s;
  }
  
  /* Lifetime stats section */
  .lifetime-stat-group {
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 8px;
    padding-bottom: 8px;
    width: 100%;
  }
  
  .liftetime-stat-medal-label {
    font-size: 16px;
    width: 136px;
    text-align: right;
  }
  
  .liftetime-stat-label {
    font-size: 12px;
    width: 136px;
    text-align: right;
  }
  
  .lifetime-stat {
    width: 136px;
    font-size: 16px;
    font-weight: 600;
  }
  
  #lifetime-gold-bar {
    display: flex;
    align-items: center;
    height: 24px;
    width: 20%;
    color: white;
    background-color: var(--gray-bar);
    border-radius: 5px;
    padding-left: 4px;
  }
  
  #lifetime-silver-bar {
    display: flex;
    align-items: center;
    height: 24px;
    width: 50%;
    color: white;
    background-color: var(--gray-bar);
    border-radius: 5px;
    padding-left: 4px;
  }
  
  #lifetime-bronze-bar {
    display: flex;
    align-items: center;
    height: 24px;
    width: 30%;
    color: white;
    background-color: var(--gray-bar);
    border-radius: 5px;
    padding-left: 4px;
  }
  
  
  /***************************************/
  /* MEDIA QUERIES */
  /***************************************/
  
  /* shorter phones */
  @media (max-height: 600px){
    .displayed-event {
      font-size: 12px;
      padding: 12px;
    }
  }
  
  /* bigger screens */
  @media (min-width: 900px){
    .displayed-event {
      font-size: large;
      padding: 20px;
    }
  
    .guesses {
      margin: 24px 0px 16px 0px;
    }
  
    .guess{
      /* font-size: 20px; */
      width: 20px;
      height: 20px; 
    }
  
    .check-answers-footer {
      margin-top: 20px;
    }
  
    .event-more-info a {
      margin-top: 12px;
    }
  }
  
  /***************************************/
  /* ANIMATIONS */
  /***************************************/
  @-webkit-keyframes active-blinking {
    50% {
      opacity: .5;
    }
    100% {
      opacity: 1;
    }
  }
  
  /* Animations to fade the snackbar in and out */
  @-webkit-keyframes fadein {
    from {bottom: 0; opacity: 0;}
    to {bottom: 30px; opacity: 1;}
  }
  
  @keyframes fadein {
    from {bottom: 0; opacity: 0;}
    to {bottom: 30px; opacity: 1;}
  }
  
  @-webkit-keyframes fadeout {
    from {bottom: 30px; opacity: 1;}
    to {bottom: 0; opacity: 0;}
  }
  
  @keyframes fadeout {
    from {bottom: 30px; opacity: 1;}
    to {bottom: 0; opacity: 0;}
  }