:root {
  /** Override Bootstrap Variables **/
  --bs-body-font-family: 'Inter', system-ui, -apple-system, "Segoe UI", Roboto,
    "Helvetica Neue", "Noto Sans", "Liberation Sans", Arial, sans-serif,
    "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol", "Noto Color Emoji";
  --bs-danger-text: #FF5353;
  --app-muted-color: #B4B4B4;
  --app-gray-color: #D7D7D6;
  --primary-color: #F28A31;
  --base-color: #FFFFFF;
  --font-title-desktop: 28px;
  --font-title-mobile: 22px;
  --font-base-desktop: 16px;
  --font-base-mobile: 14px;
  --font-caption-desktop: 14px;
  --font-caption-mobile: 12px;
  --background-color: #171717;
  --dark-color:#161618;
  --border-color: #3C3C3C;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: var(--bs-body-font-family);
}

a {
  text-decoration: none;
  color: var(--base-color);
}

a:hover {
  color: var(--base-color);
  text-decoration: none;
}


.app-login body {
  background-image: url('../img/via-bg-dark.jpg');
  background-size: cover;
  background-position: center;
  min-height: 100vh;
  display: flex;
  justify-content: center;
  align-items: center;
  position: relative;
  color: var(--base-color);
}

#kc-header {
  display: none;
}

#kc-page-title {
  margin: 1rem 0 !important;
}

.page-title{
  font-weight: 500;
  font-size: 28px
}

.esotap-subtitle{
  font-size: var(--font-base-mobile);
  font-weight: normal;
  font-size: 12px;
  margin-top: .5rem;
  color: var(--app-gray-color);
}

.app-page {
  position: relative;
  padding: 2rem 2rem;
  width: 96%;
  min-height: auto;
  text-align: center;
  background: var(--background-color);
  border: 1px solid var(--border-color);
  box-shadow: 1px 1px 7.4px 1px rgba(101, 101, 101, 0.26);
}

#kc-content {
  position: relative;
  min-height: 514px;
}



#kc-registration {
  font-size: var(--font-base-mobile);
  color: var(--app-muted-color);
  position: absolute;
  left: 50%;
  transform: translate(-50%, -50%);
  bottom: 13rem;
  width: 100%;
}

#kc-registration a {
  color: var(--base-color);
  font-weight: 600;
  text-decoration: none;
}

/* #kc-registration a:hover {
  text-decoration: underline;
} */

#kc-content-wrapper {
  margin-top: 2rem;
}

#vc-decryption-code-container{
  display: flex;
  justify-content: center;
  align-items: center;
  flex-direction: column;
   text-align: center; 
   margin-top: 2rem;
}

.btn-copy-code {
  padding: 8px 20px;
  background: var(--primary-color);
  color: var(--background-color);
  font-size: var(--font-caption-mobile);
  font-weight: 500;
  border: none;
  margin-top: 1rem;
  width: 300px;
}

.back-to-login {
  position: absolute;
  left: 50%;
  transform: translate(-50%, -50%);
  bottom: 0;
  width: 100%;
}

#kc-form-options span {
  font-size: var(--font-base-mobile);
  color: var(--base-color);
}

#kc-form-options span a {
  color: var(--base-color);
  font-weight: bold;
  text-decoration: none;
}

/* #kc-form-options span a:hover {
  text-decoration: underline;
} */

#kc-logout-confirm>#kc-info-message {
  display: block;
  margin: 1rem auto;
  width: 100%;
  max-width: 325px;
  padding: 7px;
  border: 1px solid var(--border-color);
  border-radius: 5px;
  color: var(--base-color);
  font-size: var(--font-caption-mobile);
  font-weight: 600;
  cursor: pointer;
  background-color: var(--background-color);
  transition: background-color 0.3s;
}

#kc-logout-confirm>#kc-info-message>p {
  margin: 0 auto !important;
}

#kc-logout-confirm>#kc-info-message>p>a {
  color: var(--base-color);
  text-decoration: none;
}

.alert-error {
  max-width: 324px;
  margin: 0 auto;
  color: var(--bs-danger-text);
}

.form-control {
  display: flex;
  flex-direction: column;
  margin: 0 auto;
  max-width: 324px;
  font-size: .9rem !important;
  --bs-form-control-bg: var(--dark-color) !important;
  color: var(--base-color) !important;
  padding: 1rem .75rem;
  text-align: center;
  border: 1px solid var(--border-color);
  border-radius: 0;
}

input::placeholder {
  font-style: normal !important;
  color: var(--app-muted-color) !important;
}

input:-webkit-autofill,
input:-webkit-autofill:hover,
input:-webkit-autofill:focus,
input:-webkit-autofill:active {
    /* Change background color */
    -webkit-box-shadow: 0 0 0px 1000px var(--dark-color) inset !important; 
    /* Change text color */
    -webkit-text-fill-color: var(--base-color) !important;
    /* Add a custom border */
    border: 1px solid var(--border-color) !important;
}

.form-control:focus {
  box-shadow: none;
  border-color: var(--border-color);

}

.form-label {
  display: none;
}

.invalid-feedback {
  display: block;
  width: 324px;
  margin: .5rem auto .4rem auto;
}

.invalid-feedback>a {
  color: #FF5353;
  text-decoration: underline;
  font-weight: 600;
}

.btn-disabled {
  background: var(--border-color) !important;
  cursor: not-allowed;
  margin: auto !important;
}

.subtitle {
  display: none
}

.instruction {
  font-size: var(--font-base-mobile);
  font-weight: normal;
  max-width: 324px;
  margin: 0 auto;
  a{
    color: var(--base-color) !important;
    text-decoration: underline;
  }
}

.card-pf {
  background: none;
  border-top: none;
  box-shadow: none;
  margin: 0;
  padding: 0;
}

/* // outside default ========================= */

.via-logo {
  position: absolute;
  top: 2rem;
  left: 50%;
  transform: translate(-50%, -50%);
}

.title-header-wrapper {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  width: 100%;
  margin: .5rem 0;
}

h1 {
  margin: 1rem 0;
  text-align: center;
  font-size: var(--font-title-mobile);
  font-style: normal;
  font-weight: 500;
  line-height: 30px;
  max-width: 375px;
  color: var(--base-color);
}

p {
  font-size: var(--font-base-mobile);
}

.btn-copy-qr {
  padding: 8px 20px;
  background: var(--primary-color);
  color: var(--background-color);
  font-size: var(--font-caption-mobile);
  font-weight: 500;
  border: none;
  margin-top: 1rem;
}

.sign-in-btn {
  display: block;
  margin: 1rem auto;
  width: 100%;
  max-width: 325px;
  padding: 8px 7px;
  border: none;
  color: var(--background-color);
  font-size: var(--font-caption-mobile);
  font-weight: 500;
  cursor: pointer;
  transition: background-color 0.3s;
  background: var(--primary-color);
}
.btn-disabled{
  display: block;
  margin: 1rem auto !important;
  width: 100%;
  max-width: 325px;
  padding: 8px 7px;
  border: none;
  color: var(--app-gray-color) !important;
  font-size: var(--font-caption-mobile);
  font-weight: 500;
  cursor: pointer;
  transition: background-color 0.3s;
  background: var(--border-color) !important;
}

.sign-out-btn-outlined {
  display: block;
  margin: 1rem auto;
  width: 100%;
  max-width: 325px;
  border: 2.5px solid var(--border-color);
  padding: 6px 7px;
  border-radius: 5px;
  color: var(--base-color);
  font-size: var(--font-caption-mobile);
  font-weight: 500;
  cursor: pointer;
  transition: background-color 0.3s;
  background-color: var(--background-color);
}

.sign-in-btn-outlined {
  display: block;
  margin: 1rem auto;
  width: 100%;
  max-width: 325px;
  padding: 8px 7px;
  border: 1.5px solid var(--border-color);
  border-radius: 5px;
  color: var(--base-color);
  font-size: var(--font-caption-mobile);
  font-weight: 500;
  cursor: pointer;
  background-color: var(--background-color);
  transition: background-color 0.3s;
}

.sign-in-btn-outlined-small {
  display: block;
  margin: 2rem auto;
  padding: 1px 8px;
  border: 2.5px solid var(--app-muted-color);
  color: var(--app-muted-color);
  font-size: var(--font-caption-mobile);
  font-weight: 500;
  cursor: pointer;
  background-color: var(--background-color);
  transition: background-color 0.3s;
}

/* .sign-in-btn:hover {
  background-color: #f5f5f5;
} */

.qr-box {
  margin: 2rem auto 0 auto;
  width: 100%;
  max-width: 385px;
  height: 100%;
  max-height: 385px;
  background-color: #ffffff;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
  aspect-ratio: 1 / 1;
}

.qr-code-loading {
  margin: 0 auto;
  width: 100%;
  height: 100%;
  background-color: #e0e0e0;
  position: relative;
  overflow: hidden;
}

#qr-code img {
  margin: 0 auto;
  background: var(--base-color);
}

.qr-code-loading::after {
  content: "";
  position: absolute;
  top: 0;
  right: 0;
  bottom: 0;
  left: 0;
  transform: translateX(-100%);
  background-image: linear-gradient(90deg,
      rgba(255, 255, 255, 0) 0,
      rgba(255, 255, 255, 0.2) 20%,
      rgba(255, 255, 255, 0.5) 60%,
      rgba(255, 255, 255, 0));
  animation: shimmer 1000ms infinite;
}

.btn-loading::after {
  content: "Loading...";
  color: var(--dark-color);
}

@keyframes shimmer {
  100% {
    transform: translateX(100%);
  }
}

#menu-icon {
  position: absolute;
  top: .8rem;
  right: 20px;
  font-size: 24px;
  color: #333;
}

.hamburger {
  display: inline-block;
  cursor: pointer;
  width: 30px;
  height: 22px;
  position: relative;
  z-index: 2;
}

.hamburger span {
  background: var(--base-color);
  display: block;
  height: 4px;
  margin: 4px 0;
  border-radius: 2px;
  transition: 0.3s ease;
}

.menu-popup {
  position: absolute;
  top: 70px;
  border-radius: 0;
  background: var(--background-color);
  border: 1px solid var(--border-color);
  box-shadow: 1px 1px 7.4px 1px rgba(101, 101, 101, 0.26);
  right: 20px;
  padding: 12px 3rem 12px 1.5rem;
  z-index: 1000;
  opacity: 0;
  transform: translateY(-10px);
  pointer-events: none;
  transition: opacity 0.3s ease, transform 0.3s ease;
}

.menu-popup ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.menu-popup li {
  margin: 8px 0;
}

.menu-popup a {
  text-decoration: none;
  color: var(--base-color);
  font-weight: normal;
  font-size: var(--font-base-mobile);
}

/* Visible state */
.menu-popup.show {
  opacity: 1;
  transform: translateY(0);
  pointer-events: auto;
}

#tnc-login {
  position: absolute;
  bottom: 2rem;
  font-size: 12px !important;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 100%;
}

#tnc-login p a {
  color: var(--base-color) !important;
  font-size: var(--font-base-mobile) !important;
  font-weight: 600 !important;
}

#tnc-login p {
  font-size: var(--font-base-mobile) !important;
}

#tnc-register {
  margin: 0 auto;
  font-size: 12px !important;
  max-width: 324px;
  text-align: center;
  color: var(--app-muted-color) !important;
  font-size: var(--font-base-mobile) !important;
  font-weight: 600 !important;
}

#tnc-register a {
  color: var(--app-muted-color) !important;
  text-decoration: underline !important;
}

#tnc-register p {
  font-size: var(--font-base-mobile) !important;
}

.user-exists{
  color: var(--app-muted-color) !important;
  a{
    color: var(--base-color);
  }
}

.trouble-signing-in {
  text-align: center;
  position: absolute;
  bottom: -2rem;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 100%;
}

/* desktop view  */
@media screen and (min-width: 768px) {
  h1 {
    margin: 2rem 0;
    font-size: var(--font-title-desktop);
    line-height: 34px;
  }

  p {
    font-size: var(--font-base-desktop);
  }

  .app-page {
    width: 95%;
    max-width: 583px;
  }

  .menu-popup {
    top: 60px;
  }

  .menu-popup a {
    font-size: var(--font-base-desktop);
  }

  #kc-content {
    position: relative;
    min-height: 584px;
  }

  .via-logo {
    position: absolute;
    top: 15px;
    left: 19px;
    transform: translate(0, 0);
  }

  .qr-box {
    margin: 1rem auto 0 auto;
    display: flex;
    justify-content: center;
    align-items: center;
    width: 100%;
    max-width: 425px;
    height: 100%;
    max-height: 425px;
    border: .4rem solid transparent; /* The width of the gradient border */
    border-image: linear-gradient(
    35deg, 
    #F18930 0%,
    #F88821 30%,
    #F18930 45%, 
    #4CD5FA 70%,
    #50D3F5 100%
  ) 1;
  }

  #kc-registration {      
    font-size: var(--font-base-desktop);
  }

  .sign-in-btn-outlined {
    font-size: var(--font-caption-desktop);
  }

  .sign-in-btn-outlined-small {
    font-size: var(--font-caption-desktop);
  }

  .sign-out-btn-outlined {
    font-size: var(--font-caption-desktop);
  }

  .sign-in-btn {
    font-size: var(--font-caption-desktop);
  }

  #kc-form-options span {
    font-size: var(--font-base-desktop);
  }

  .instruction {
    font-size: var(--font-base-desktop);
  }

  #kc-logout-confirm>#kc-info-message {
    font-size: var(--font-caption-desktop);
  }

}

@keyframes shake {
  0% {
    transform: translateX(0);
  }

  25% {
    transform: translateX(-5px);
  }

  50% {
    transform: translateX(5px);
  }

  75% {
    transform: translateX(-5px);
  }

  100% {
    transform: translateX(0);
  }
}

.text-button {
  background: none;
  border: none;
  color: var(--base-color);
  font-size: var(--font-base-mobile);
  font-weight: 600;
  cursor: pointer;
  text-decoration: none;
  padding: 0;
  margin: 1rem auto;
  display: inline;
}

.text-button:hover {
  text-decoration: none;
}

@media screen and (min-width: 768px) {
  .text-button {
    font-size: var(--font-base-desktop);
  }
}

.custom-modal-overlay {
  display: none;
  position: fixed;
  z-index: 1000;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  overflow: auto;
  background-color: rgba(0, 0, 0, 0.6);
  backdrop-filter: blur(2px);
}

.custom-modal-download-content {
  background-color: var(--background-color);
  margin: 10% auto;
  padding: 36px;
  border-radius: 0;
  width: 100%;
  max-width: 583px;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
  position: relative;
  font-family: inherit;
  color: var(--app-muted-color);
  text-align: center;
}

.custom-modal-close {
  color: var(--app-muted-color);
  float: right;
  font-size: 28px;
  font-weight: bold;
  cursor: pointer;
  position: absolute;
  top: 10px;
  right: 20px;
  line-height: 1;
}

.custom-modal-close:hover,
.custom-modal-close:focus {
  text-decoration: none;
}

.custom-modal-download-title {
  font-size: var(--font-title-desktop);
  color: var(--base-color);
  font-weight: 500;
  line-height: 32px;
  margin: 2rem 0;
  text-align: center;
}

.custom-modal-list {
  list-style-type: disc;
  padding-left: 20px;
  margin-bottom: 20px;
  font-size: 16px;
  line-height: 1.5;
}

.custom-modal-list li {
  margin-bottom: 15px;
}

.custom-modal-sublist {
  list-style-type: disc;
  margin-top: 5px;
  padding-left: 20px;
}

.custom-modal-sublist li {
  margin-bottom: 5px;
}

.custom-modal-footer {
  font-size: 16px;
  line-height: 1.5;
  margin-top: 20px;
  color: var(--app-muted-color);
}



.store-links {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 50px;
  margin-top: 2rem;
}

.spaced-input {
  letter-spacing: 0.3rem;
  /* adds space between characters */
  font-family: var(--bs-body-font-family);
   --bs-form-control-bg: var(--dark-color) !important;
  color: var(--base-color) !important;
  background-color: var(--dark-color);
  border: 1px solid var(--border-color);
}

.code-container {
  display: flex;
  justify-content: center;
  gap: 10px; /* Space between the boxes */
}

.code-container input {
    width: 46px;
    height: 50px;
    text-align: center;
    font-size: 1.5em;
    background: var(--dark-color);
    border: 1px solid var(--border-color);
    font-family: var(--bs-body-font-family);
    &:focus {
      outline: none;
      border-color: var(--base-color);
    }
}

input::-webkit-outer-spin-button,
input::-webkit-inner-spin-button {
  -webkit-appearance: none;
  margin: 0;
}

/* Firefox */
input[type=number] {
  -moz-appearance: textfield;
}