:root {
  --color-text-primary: #000000;
  --color-title: #6f6f6f;
  --color-text-secondary: rgba(0, 0, 0, 0.5);
  --color-text-white: #fff;
  --color-text-red: #ff3b30;
  --btn-bg: #007aff;
  --color-basic-bg: #f6f6f6;
  --font-family: 'SF Pro Display', sans-serif;
  --color-divide: #e7e7e7;
  --color-bg-line-after: rgba(35, 38, 47, 0.15);
  --color-bg-line-before: #23262f;

  padding-top: env(safe-area-inset-top, 110px);
  /* top: calc(env(safe-area-inset-top, 0px) + 11px);  <-- use */
  padding-bottom: env(safe-area-inset-bottom, 110px);
  /* bottom: calc( env(safe-area-inset-bottom, 0px) + 16px);  <-- use */
}

@media (prefers-color-scheme: dark) {
  :root {
    --color-text-primary: #ffffff;
    --color-basic-bg: #000000;
    --color-basic-secondary-bg: #1e1e1e;
    --color-border: #272727;
    --color-text-white: #1a1a1a;
    --color-divide: #3d3d3d;
    --color-text-secondary: rgb(255, 255, 255);
    --color-bg-line-after: #ffffff26;
    --color-bg-line-before: white;
  }
}

* {
  padding: 0;
  margin: 0;
  box-sizing: border-box;
  border: none;
  outline: none;
  list-style-type: none;
  text-decoration: none;
  font-family: var(--font-family);
  color: var(--color-text-primary);
  -webkit-tap-highlight-color: rgba(0, 0, 0, 0);
}

input[type='radio'] {
  display: none;
}

img {
  display: block;
}

body {
  background: var(--color-basic-bg);

  -webkit-user-select: none;
  -moz-user-select: none;
  -ms-user-select: none;
  user-select: none;
  -webkit-touch-callout: none;

  touch-action: none;
}

img,
svg {
  user-select: none;
  -webkit-user-drag: none;
  -webkit-touch-callout: none;
  -moz-user-select: none;
  -ms-user-select: none;
  pointer-events: auto;
}

.none {
  display: none !important;
}

.hidden {
  opacity: 0;
}

.app {
  position: relative;
  z-index: 1;
  touch-action: none;
}

.app__container {
  max-width: 500px;
  margin: 0 auto;
  text-align: center;
  display: flex;
  flex-direction: column;
  height: 100vh;

  position: relative;
  bottom: calc(env(safe-area-inset-bottom, 0px) + 16px);
}

.header {
  flex-shrink: 0;

  padding-top: 10px;
  background-color: var(--color-basic-bg);
  z-index: 5;
  margin-top: -10px;
}

.container {
  position: relative;
  padding-top: calc(env(safe-area-inset-top, 0px) + 11px);
}

.logo {
  font-weight: 590;
  font-size: 16px;
  line-height: 21px;
  letter-spacing: -0.31%;
}

.tab {
  flex: 1;
  display: flex;
  flex-direction: column;
  touch-action: none;
}

.first-screen {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 16px;
  gap: 20px;
  flex: 1;
  z-index: 4;
  background-color: var(--color-basic-bg);
}

.banner {
  border-radius: 14px;
  background-color: var(--color-text-white);
  display: flex;
  flex-direction: column;
  gap: 24px;
  padding: 20px 0;
  width: 100%;
}

.banner__img,
.banner-second__img {
  display: flex;
  justify-content: center;
  position: relative;
}

.banner__img img {
  max-width: 100px;
  min-width: 80px;
}

.banner-second__img img {
  max-width: 120px;
  min-width: 100px;
}

.banner__img span {
  position: absolute;
  top: 8%;
  left: 50%;
  transform: translate(80%, -50%);
  background-color: var(--color-text-red);
  color: white;
  border-radius: 50%;
  padding: 3px;
  font-size: 12px;
  display: flex;
  justify-content: center;
  width: 23px;
  height: 23px;
  align-items: center;
  text-align: center;
  margin-left: 10px;
}

.banner__title {
  font-weight: 590;
  font-size: 22px;
  line-height: 34px;
  letter-spacing: -0.26%;
  position: relative;
}

.banner__title::after {
  position: absolute;
  content: '';
  width: 100%;
  height: 1px;

  background: var(--color-divide);

  left: 50%;
  bottom: -12px;
  transform: translateX(-50%);
}

.banner-scan__text,
.banner-scan-process__text {
  font-weight: 510;
  font-size: 12px;
  line-height: 16px;
  letter-spacing: 0%;

  color: var(--color-text-secondary);
}

.capitalize {
  text-transform: capitalize;
}

.banner-scan__text span {
  color: var(--color-text-red);
}

.banner-scan__line {
  width: 287px;
  height: 4px;
  margin-top: 12px;
  background: var(--color-bg-line-after);
  border-radius: 4px;
  margin: 0 auto;
  margin-top: -6px;
}

.banner-scan__line-result {
  border-radius: 4px;
  height: 100%;
  width: 0;
  background: var(--color-bg-line-before);
}

.warning {
  border-radius: 14px;
  background-color: var(--color-text-white);
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 16px 0;
  width: 100%;
}

.warning__icon {
  display: flex;
  justify-content: center;
}

.warning__title {
  font-weight: 590;
  font-size: 17px;
  line-height: 22px;
  letter-spacing: -0.43%;
}

.warning__error {
  font-weight: 590;
  font-size: 14px;
  line-height: 18px;
  letter-spacing: -0.08%;

  color: var(--color-text-red);
}

.warning__text {
  font-weight: 400;
  font-size: 14px;
  line-height: 18px;
  letter-spacing: -0.08%;

  padding: 0 30px;
}

.inner-btn {
  width: 100%;
  margin-top: auto;
  padding-bottom: 20px;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.inner-btn__text {
  font-weight: 590;
  font-size: 13px;
  line-height: 18px;
  letter-spacing: -0.08%;

  color: var(--color-text-red);
  text-transform: uppercase;
}

.btn {
  font-weight: 590;
  font-size: 16px;
  line-height: 22px;
  letter-spacing: -0.43px;

  background-color: var(--btn-bg);
  color: white;
  border-radius: 12px;
  padding: 16px;
}

/* ############# SECOND-SCREEN ############# */
.second-screen {
  width: 100%;
  height: 100vh;
  position: absolute;
  padding: 5px 24px 24px 24px;
  max-width: 500px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  z-index: 7;
}

.second-screen::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-image: url('images.jpg');
  background-repeat: no-repeat;
  background-size: cover;
  background-position: center;
  background-clip: content-box;
  filter: blur(8px);
  z-index: 8;
}

.top-section {
  position: relative;
  z-index: 8;
  display: flex;
  align-items: center;
  justify-content: space-between;

  top: calc(env(safe-area-inset-top, 0px) + 11px);
}

.top-left {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
}

.top-left span:first-child {
  font-weight: 700;
  font-size: 33.27px;
  line-height: 51.42px;
  letter-spacing: -0.26%;
  color: var(--color-text-white);
}

.top-left span:last-child {
  font-weight: 590;
  font-size: 13.96px;
  line-height: 21.57px;
  letter-spacing: -0.26%;

  color: var(--color-text-white);
}

.top-right {
  display: flex;
  align-items: center;
  gap: 8px;
}

.search_tab {
  display: flex;
  border-radius: 40px;
  justify-content: center;
}

.img_wrapper::before {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: inherit;
  padding: 1px;
  background: linear-gradient(
    145deg,
    rgba(255, 255, 255, 0.9),
    rgba(255, 255, 255, 0.2) 40%,
    rgba(255, 255, 255, 0.05) 60%,
    rgba(255, 255, 255, 0.3)
  );
  -webkit-mask:
    linear-gradient(#fff 0 0) content-box,
    linear-gradient(#fff 0 0);
  -webkit-mask-composite: xor;
  mask-composite: exclude;
  pointer-events: none;
}

.img_wrapper {
  padding: 12px 15px;
  background: var(--color-liquid-bg);
  border-radius: 30px;
  backdrop-filter: blur(10px);
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.img_wrapper img {
  width: 22px;
  height: auto;
}

.top-right span {
  font-weight: 590;
  font-size: 15.86px;
  line-height: 26.12px;
  letter-spacing: 0px;
  vertical-align: middle;

  color: var(--color-text-white);
}

.bottom-section {
  position: relative;
  z-index: 8;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.bottom-left {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 4px 4px !important;
}

.img_wrapper_first {
  padding: 12px 35px;
  background: rgb(61 61 61 / 24%);
  border-radius: 30px;
  backdrop-filter: blur(10px);
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.img_wrapper_second {
  padding: 4px 30px;
}

.bottom-right .img_wrapper {
  padding: 12px 12px;
}

/* ############### LOADER ############### */

.pulse {
  animation: pulse 2s infinite;
}

@keyframes pulse {
  0% {
    transform: scale(1);
  }
  70% {
    transform: scale(0.9);
  }
  100% {
    transform: scale(1);
  }
}

/* .loader {
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  z-index: 8;
}

.loader__content rect {
  opacity: 0.3;
  animation: highlight 1.6s infinite;
}

.loader__content rect:nth-child(8) {
  animation-delay: 0s;
}
.loader__content rect:nth-child(7) {
  animation-delay: 0.2s;
}
.loader__content rect:nth-child(6) {
  animation-delay: 0.4s;
}
.loader__content rect:nth-child(5) {
  animation-delay: 0.6s;
}
.loader__content rect:nth-child(4) {
  animation-delay: 0.8s;
}
.loader__content rect:nth-child(3) {
  animation-delay: 1s;
}
.loader__content rect:nth-child(2) {
  animation-delay: 1.2s;
}
.loader__content rect:nth-child(1) {
  animation-delay: 1.4s;
}

@keyframes highlight {
  0%,
  100% {
    opacity: 0.3;
  }
  50% {
    opacity: 1;
  }
} */

/* ############### SLIDE IN RIGHT ############### */

.slideInRight {
  animation: slideInRight 0.3s both;
}

@keyframes slideInRight {
  from {
    transform: translateX(100%);
    visibility: visible;
  }
  to {
    transform: translateX(0);
  }
}

/* ############### ERRORS ############### */
.third-screen {
  position: relative;
  z-index: 1;

  gap: 15px;
  display: flex;
  flex-direction: column;
}

.third-screen::before {
  content: '';
  position: absolute;
  inset: 0;
  background: var(--color-basic-bg);
  z-index: 1;
}

.error-issues {
  display: flex;
  align-items: center;
  width: fit-content;
  gap: 3px;
  margin: 0 auto;
  border-radius: 30px;
  background: var(--color-text-red);
  padding: 12px 14px;
  position: relative;
  z-index: 3;
}

.error-issues__text,
.error-issues__cnt {
  color: white;
  font-size: 14px;
  font-style: normal;
  font-weight: 700;
  line-height: 18px;
  letter-spacing: 0.7px;
  text-transform: uppercase;
}

.error-issues__cnt {
  width: 15px;
}

.error-show {
  animation: slideInDown 4.5s 0.5s forwards;
  transform: translateY(-100%);
  position: absolute;
  z-index: 0;
  width: 100%;
}

@keyframes slideInDown {
  from {
    transform: translateY(-100%);
  }
  to {
    transform: translateY(0);
  }
}

.error-list__line {
  display: flex;
  gap: 16px;
  padding: 3px 0;

  position: relative;
  z-index: 1;
}

.error-list__header {
  border-bottom: 1px solid var(--color-divide);
  background: var(--color-text-white);
  z-index: 1;
}

.error-list__line.error-list__header .error-list__process:after {
  position: absolute;
  content: '';
  width: 9px;
  height: 100%;
  background: var(--color-divide);
}

.error-list__line.error-list__header .error-list__process:before {
  position: absolute;
  content: '';
  width: 8px;
  height: 100%;
  background: var(--color-divide);
}

.error-list__line.error-list__header .error-list__process:before {
  right: -7px;
}

.error-list__line.error-list__header .error-list__process:after {
  left: -8px;
}

.error-list__line:nth-child(even) {
  background: var(--color-text-white);
}

.error-list__line:first-child .error-list__process {
  color: var(--color-text-primary);
}

.error-list__number {
  width: 66px;
  font-size: 10px;
  font-style: normal;
  font-weight: 500;
  line-height: 14px;
  padding-left: 16px;

  flex-shrink: 0;
}

.error-list__process {
  width: 88px;
  position: relative;
  color: var(--color-text-red);
  font-size: 10px;
  font-style: normal;
  line-height: 14px;
  white-space: nowrap;

  flex-shrink: 0;

  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;

  padding: 0 0 0 15px;
  text-align: start;
}

.error-list__message {
  font-size: 10px;
  font-style: normal;
  font-weight: 500;
  line-height: 14px;

  white-space: nowrap;
  overflow: hidden;
}

.error__good {
  color: var(--color-text-primary);
}

/* ################## FOURTH SCREEN ################## */
.fourth-screen {
  height: 100%;
}

.wrapper-detect {
  display: flex;
  flex-direction: column;
  padding: 20px;
  height: 100%;
}

.system-info {
  max-width: 500px;
  display: flex;
  align-items: flex-start;
  flex-direction: column;
  gap: 16px;
  flex-grow: 1;
}

.system {
  display: flex;
  gap: 12px;
  justify-content: space-between;
  align-items: center;

  border-radius: 25px;
  background: var(--color-text-white);
  padding: 12px 5px;
}

.system * {
  margin: 0;
}

.system_device {
  display: flex;
  flex-direction: column;
  flex-grow: 1;
  text-align: start;
  gap: 5px;
}

.system_brand {
  font-weight: 600;
  font-size: 28px;
  line-height: 100%;
  letter-spacing: -2%;
}

.system_status {
  color: var(--color-text-red);

  font-weight: 400;
  font-size: 14px;
  line-height: 18px;
  letter-spacing: -0.41px;
}

.system_action {
  width: 116px;
  height: 30px;
  border-radius: 100px;
  padding: 6px 8px;
  background: var(--color-text-red);
  color: var(--color-text-white);
  border: none;

  white-space: nowrap;
  font-size: 14px;
}

.dangerous {
  border-radius: 14px;
  background: var(--color-text-white);
  width: 100%;
}

.dangerous__item {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 12px;
}

.dangerous__item:not(:last-child):before {
  position: absolute;
  content: '';
  height: 1px;
  width: 86%;
  background: var(--color-divide);
  right: 0;
  bottom: 0;
}

.dangerous__item-info {
  display: flex;
  align-items: center;
  gap: 12px;

  flex: 1;
  min-width: 0;
}

.dangerous__item-icon img {
  width: 29px;
  height: 29px;
}

.dangerous__item-name {
  font-weight: 400;
  font-size: 16px;
  line-height: 24px;
  letter-spacing: -1%;
  text-align: start;

  display: inline-block;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}

.dangerous__item-result {
  font-weight: 510;
  font-size: 16px;
  line-height: 21px;
  letter-spacing: -0.31%;

  color: var(--color-text-red);
  display: flex;
  gap: 14px;
}

.shadow {
  position: relative;
  display: inline-block;
}

.shadow::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  box-shadow: 0px 0px 5px 1px #ffffff inset;
  border-radius: 22%;
  pointer-events: none;
}

.system-alert__container {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 10px 20px;
  flex-grow: 1;
  gap: 8px;
}

.system-alert {
  font-weight: 400;
  font-size: 12px;
  line-height: 16px;
  letter-spacing: 0%;

  text-align: center;
  text-transform: capitalize;
  color: var(--color-title);
}

.btn-container {
  width: 100%;
  margin-top: auto;
  padding-bottom: 20px;
  display: flex;
  flex-direction: column;
}

/* ########## ALERT ########## */

.alert_content {
  position: fixed;
  border-radius: 20px;
  background: var(--color-text-white);

  top: calc(env(safe-area-inset-top, 0px) + 15px);
  left: 50%;
  transform: translateX(-50%);
  max-width: 500px;
  width: calc(100% - 32px);
  display: flex;
  gap: 8px;
  padding: 15px;
  z-index: 5;
}

.alert_head {
  display: flex;
  justify-content: space-between;
}

.alert_title {
  font-weight: 600;
  font-size: 16px;
}

.alert_time {
  font-size: 12px;
  color: var(--color-title);
}

.alert_status {
  font-size: 15px;
}

.alert_info {
  width: 100%;
}

.hidden {
  opacity: 1;
  visibility: hidden;
  pointer-events: none;
  transition:
    opacity 0.3s ease,
    visibility 0.3s ease;
}

.fadeInDown {
  animation: fadeInDown 0.5s both;
}

/* @keyframes fadeInDown {
  0% {
    transform: translate(-50%, -100%);
  }
  100% {
    transform: translateX(-50%);
  }
} */

@keyframes fadeInDown {
  0% {
    transform: translate(-50%, calc(-100vh - 100%));
  }
  100% {
    transform: translate(-50%, 0);
  }
}

.fadeOutUp {
  animation: fadeOutUp 0.5s both;
}

/* @keyframes fadeOutUp {
  0% {
    transform: translateX(-50%);
  }
  100% {
    transform: translate(-50%, -100%);
  }
} */

@keyframes fadeOutUp {
  0% {
    transform: translate(-50%, 0);
  }
  100% {
    transform: translate(-50%, calc(-100vh - 100%));
  }
}

.overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: #00000080;
  z-index: 3;
  pointer-events: none;
  transition: opacity 0.3s ease;
}

.overlay.active {
  pointer-events: auto;
  opacity: 1;
}

/* ########## POPUP ########## */
.popup_content {
  position: fixed;
  background: var(--color-text-white);
  border-radius: 14px;

  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 300px;
  display: flex;
  flex-direction: column;
  align-items: center;

  gap: 7px;
  padding: 15px;
  z-index: 5;
}

.popup_title {
  font-size: 17px;
  font-weight: 600;
}
.popup_description {
  font-size: 13px;
  text-align: center;
}

.popup_checkup {
  color: var(--btn-bg);
  width: 100%;
  padding-top: 10px;
  position: relative;
  cursor: pointer;
  background-color: transparent;

  font-weight: 510;
  font-size: 17px;
  line-height: 22px;
  letter-spacing: -0.43px;
  vertical-align: middle;
}

.popup_checkup::after {
  position: absolute;
  content: '';
  width: 110%;
  height: 1px;
  background: var(--color-divide);
  left: 50%;
  bottom: 29px;
  transform: translateX(-50%);
}

.popup_checkup.disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.alert_content,
.popup_content * {
  pointer-events: none;
}

.popup_checkup {
  pointer-events: auto;
}

#link {
  pointer-events: none;
}
