html,
body {
    margin: 0;
    padding: 0;
    width: 100%;
    min-height: 100%;
    font-family: -apple-system, BlinkMacSystemFont, "SF Pro Display", "SF Pro Text", "Helvetica Neue", Arial, sans-serif;
    background: #000;
    color: #fff;
    overflow-x: hidden;
}

*,
*::before,
*::after {
    box-sizing: border-box;
}

a,
button {
    -webkit-tap-highlight-color: transparent;
}

button {
    font: inherit;
    border: 0;
    background: none;
    padding: 0;
    margin: 0;
}

img {
    display: block;
    max-width: 100%;
}

.screen {
    min-height: 100svh;
    min-height: 100vh;
    display: flex;
    align-items: stretch;
    justify-content: center;
    background:
        radial-gradient(circle at top, rgba(255, 255, 255, 0.06), transparent 32%),
        linear-gradient(180deg, #050505 0%, #0a0a0a 50%, #000000 100%);
}

.iphone-frame {
    position: relative;
    width: 100%;
    min-height: 100svh;
    min-height: 100vh;
    overflow: hidden;
    background: #000;
    padding:
        max(14px, env(safe-area-inset-top))
        14px
        max(100px, env(safe-area-inset-bottom))
        14px;
}

.screen-bg {
    position: absolute;
    inset: 0;
    z-index: 0;
    overflow: hidden;
}

.screen-bg::before {
    content: "";
    position: absolute;
    inset: 0;
    background:
        linear-gradient(
            180deg,
            rgba(0, 0, 0, 0.02) 0%,
            rgba(0, 0, 0, 0.05) 30%,
            rgba(0, 0, 0, 0.14) 62%,
            rgba(0, 0, 0, 0.28) 100%
        );
    z-index: 2;
}

.bg-image-slot {
    position: absolute;
    inset: 0;
    z-index: 1;
    background-image: url("../img/home-screen.webp");
    background-repeat: no-repeat;
    background-position: center top;
    background-size: cover;
}

/* TOP ALERT */

.fake-modal {
    position: relative;
    z-index: 3;
    width: min(100%, 398px);
    margin: clamp(20px, 2.8vh, 28px) auto 0;
    padding: 18px 18px 0;
    border-radius: 34px;
    background: #E4E4E4;
    backdrop-filter: blur(18px);
    -webkit-backdrop-filter: blur(18px);
    box-shadow:
        0 18px 40px rgba(0, 0, 0, 0.22),
        0 1px 0 rgba(255, 255, 255, 0.72) inset;
    text-align: center;
    overflow: hidden;
}

.fake-modal__icon-wrap {
    position: relative;
    width: 112px;
    height: 112px;
    margin: 0 auto 14px;
}

.fake-modal__icon-slot {
    width: 112px;
    height: 112px;
    border-radius: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.fake-modal__icon-slot img {
    width: 75%;
    height: 75%;
    object-fit: contain;
}

.fake-modal__badge {
    position: absolute;
    right: 8px;
    top: 8px;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: #ff3b30;
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    font-weight: 700;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.16);
}

.fake-modal__timer {
    font-size: 20px;
    line-height: 1;
    font-weight: 700;
    letter-spacing: -0.04em;
    margin-bottom: 16px;
    color: #ff3b30;
}

.fake-modal__title {
    margin: 0 auto 18px;
    max-width: 340px;
    font-size: clamp(20px, 5.7vw, 34px);
    line-height: 1.4;
    font-weight: 700;
    letter-spacing: -0.001em;
    color: #111111;
}

.fake-modal__text {
    margin: 0 auto 28px;
    max-width: 330px;
    font-size: clamp(16px, 3.9vw, 22px);
    line-height: 1.28;
    letter-spacing: -0.02em;
    color: #3a3a3c;
}

.fake-modal__actions {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0;
    border-top: 1px solid rgba(60, 60, 67, 0.18);
    margin: 0 -18px;
}

.fake-modal__btn {
    min-height: 80px;
    border-radius: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    font-size: 28px;
    font-weight: 600;
    letter-spacing: -0.03em;
    transition: transform 0.18s ease, opacity 0.18s ease;
}

.fake-modal__btn:active {
    transform: scale(0.985);
}

.fake-modal__btn--cancel {
    background: transparent;
    color: #ff3b30;
    border-right: 1px solid rgba(60, 60, 67, 0.18);
}

.fake-modal__btn--install {
    background: transparent;
    color: #2563ff;
    font-weight: 600;
}

.bottom-warning {
    position: absolute;
    left: 12px;
    right: 12px;
    bottom: max(12px, calc(env(safe-area-inset-bottom) + 8px));
    z-index: 3;
    padding: 20px 16px 0;
    border-radius: 26px;
    background: linear-gradient(180deg, #1c1c1e 0%, #111113 100%);
    box-shadow:
        0 20px 50px rgba(0, 0, 0, 0.5),
        inset 0 1px 0 rgba(255, 255, 255, 0.04);
    overflow: hidden;
}

.bottom-warning__top {
    display: flex;
    align-items: flex-start;
    gap: 10px;
}

.bottom-warning__icon {
    flex: 0 0 26px;
    width: 26px;
    height: 26px;
    margin-top: 2px;
    margin-left: 13px;
}

.bottom-warning__icon img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    transform: scale(2);
}

.bottom-warning__content {
    min-width: 0;
    flex: 1 1 auto;
    padding-left: 10px;
    transform: translateX(2px);
}

.bottom-warning__title-row {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 8px;
    margin-bottom: 6px;
}

.bottom-warning__title {
    margin: 0;
    font-size: 18px;
    line-height: 1.2;
    font-weight: 700;
    color: #ffffff;
}

.bottom-warning__time {
    color: rgba(255, 255, 255, 0.5);
    font-size: 14px;
    line-height: 1.2;
}

.bottom-warning__text {
    max-width: 100%;
    margin: 0;
    font-size: 14px;
    line-height: 1.35;
    letter-spacing: -0.01em;
    color: rgba(255, 255, 255, 0.75);
}

.bottom-warning__actions {
    display: grid;
    grid-template-columns: 1fr 1fr;
    margin-top: 22px;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.bottom-warning__btn {
    height: 56px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 17px;
    font-weight: 500;
    text-decoration: none;
    transition: transform 0.18s ease, opacity 0.18s ease;
}

.bottom-warning__btn:active {
    transform: scale(0.985);
}

.bottom-warning__btn--dismiss {
    color: rgba(255, 255, 255, 0.6);
    border-right: 1px solid rgba(255, 255, 255, 0.08);
}

.bottom-warning__btn--remove {
    color: #30d158;
    font-weight: 600;
}

.danger {
    color: #ff3b30;
    font-weight: 600;
}

@media (max-width: 390px) {
    .fake-modal {
        width: 100%;
        margin-top: 14px;
        padding: 16px 16px 0;
        border-radius: 30px;
    }

    .fake-modal__icon-wrap {
        width: 102px;
        height: 102px;
        margin-bottom: 12px;
    }

    .fake-modal__icon-slot {
        width: 102px;
        height: 102px;
        border-radius: 24px;
    }

    .fake-modal__badge {
        width: 18px;
        height: 18px;
        font-size: 13px;
    }

    .fake-modal__timer {
        font-size: 20px;
        margin-bottom: 14px;
    }

    .fake-modal__title {
        font-size: 23px;
        margin-bottom: 16px;
        max-width: 320px;
    }

    .fake-modal__text {
        font-size: 14px;
        margin-bottom: 22px;
        max-width: 300px;
    }

    .fake-modal__btn {
        min-height: 72px;
        font-size: 24px;
    }

    .bottom-warning {
        left: 10px;
        right: 10px;
        padding: 16px 13px 0;
        border-radius: 22px;
    }

    .bottom-warning__top {
        gap: 16px;
    }

    .bottom-warning__content {
        padding-left: 8px;
        transform: translateX(1px);
    }
}

@media (max-width: 375px) {
    .iphone-frame {
        padding-left: 10px;
        padding-right: 10px;
    }

    .fake-modal {
        margin-top: 12px;
        padding: 15px 14px 0;
        border-radius: 28px;
    }

    .fake-modal__icon-wrap {
        width: 92px;
        height: 92px;
    }

    .fake-modal__icon-slot {
        width: 92px;
        height: 92px;
        border-radius: 22px;
    }

    .fake-modal__timer {
        font-size: 20px;
        margin-bottom: 12px;
    }

    .fake-modal__title {
        font-size: 21px;
        max-width: 290px;
        margin-bottom: 14px;
    }

    .fake-modal__text {
        font-size: 15px;
        max-width: 286px;
        margin-bottom: 20px;
    }

    .fake-modal__btn {
        min-height: 66px;
        font-size: 21px;
    }

    .bottom-warning__text {
        font-size: 14px;
    }
}

@media (max-width: 320px) {
    .iphone-frame {
        padding-left: 8px;
        padding-right: 8px;
    }

    .fake-modal {
        margin-top: 10px;
        padding: 14px 12px 0;
        border-radius: 24px;
    }

    .fake-modal__icon-wrap {
        width: 82px;
        height: 82px;
        margin-bottom: 10px;
    }

    .fake-modal__icon-slot {
        width: 82px;
        height: 82px;
        border-radius: 20px;
    }

    .fake-modal__badge {
        width: 26px;
        height: 26px;
        font-size: 15px;
    }

    .fake-modal__timer {
        font-size: 28px;
        margin-bottom: 10px;
    }

    .fake-modal__title {
        font-size: 22px;
        margin-bottom: 12px;
        max-width: 260px;
    }

    .fake-modal__text {
        max-width: 100%;
        font-size: 14px;
        line-height: 1.3;
        margin-bottom: 18px;
    }

    .fake-modal__btn {
        min-height: 58px;
        font-size: 18px;
    }

    .bottom-warning {
        left: 8px;
        right: 8px;
        padding: 14px 12px 0;
        border-radius: 20px;
    }

    .bottom-warning__top {
        gap: 12px;
    }

    .bottom-warning__content {
        padding-left: 4px;
        transform: none;
    }

    .bottom-warning__title {
        font-size: 16px;
    }

    .bottom-warning__time {
        font-size: 12px;
    }

    .bottom-warning__text {
        font-size: 13px;
        line-height: 1.3;
    }

    .bottom-warning__actions {
        margin-top: 16px;
    }

    .bottom-warning__btn {
        height: 48px;
        font-size: 15px;
    }
}

@media (min-width: 414px) {
    .fake-modal {
        width: min(100%, 414px);
    }

    .bottom-warning {
        left: 16px;
        right: 16px;
    }
}

@media (min-height: 668px) {
    .fake-modal {
        margin-top: 26px;
    }

    .bottom-warning {
        bottom: calc(env(safe-area-inset-bottom) + 125px);
    }
}

.bottom-warning {
    transform: translateY(140%);
    opacity: 0;
    animation: bannerSlideUp 0.55s ease-out 1s forwards;
}

@keyframes bannerSlideUp {
    from {
        transform: translateY(140%);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

.step {
  display: none;
  width: 100%;
  min-height: 100vh;
}

.step.active {
  display: flex;
}

.step-0 {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100vh;
  z-index: 9999;
}

.step-1,
.step-2 {
  width: 100%;
  min-height: 100vh;
}

.progress {
  width: 100%;
  height: 8px;
  background: rgba(255, 255, 255, 0.15);
  border-radius: 999px;
  overflow: hidden;
}

#progress-bar {
  width: 0%;
  height: 100%;
  transition: width 1.8s linear;
}

#step2.active .title,
#step2.active .text,
#step2.active .result,
#step2.active .action__button,
#step2.active #tap_to_protect_prompt {
  opacity: 1;
  visibility: visible;
}

#step2.active .action__button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
}


#step2.active {
  display: flex;
  opacity: 1;
  flex-direction: column;
  justify-content: center;
  align-items: center;
}

