:root {
    --blue: #01a0e2;
    --blue-deep: #0180b5;
    --blue-soft: rgba(1, 160, 226, 0.12);
    --sky-1: #b9e6f9;
    --sky-2: #ddf3fc;
    --white: #fdfefe;
    --ink: #0b3c54;
    --muted: #5f8498;
    --danger: #d6455d;
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}
html,
body {
    height: 100%;
}

body {
    font-family: "Manrope", system-ui, sans-serif;
    color: var(--ink);
    /* min-height: 100vh; */
    display: grid;
    place-items: center;
    padding: 20px;
    overflow-x: hidden;
    position: relative;
    background: var(--sky-2);
}

.bg {
    position: fixed;
    inset: 0;
    z-index: 0;
    overflow: hidden;
    background:
        radial-gradient(
            900px 600px at 15% 20%,
            rgba(1, 160, 226, 0.3),
            transparent 62%
        ),
        radial-gradient(
            900px 700px at 90% 85%,
            rgba(1, 160, 226, 0.34),
            transparent 62%
        ),
        linear-gradient(
            135deg,
            var(--sky-1) 0%,
            var(--sky-2) 48%,
            var(--white) 100%
        );
}

#waves {
    position: absolute;
    left: -5%;
    width: 110%;
    bottom: -6%;
    height: 78%;
    opacity: 0.9;
}
#waves g {
    animation: waveSlide 14s ease-in-out infinite alternate;
}
#waves g.g2 {
    animation-duration: 19s;
    animation-direction: alternate-reverse;
}
@keyframes waveSlide {
    from {
        transform: translateX(-45px);
    }
    to {
        transform: translateX(45px);
    }
}

#icons {
    position: absolute;
    inset: 0;
}
.ico {
    position: absolute;
    color: var(--white);
    opacity: 0;
    animation:
        icoIn 0.9s ease forwards,
        floaty var(--dur) ease-in-out var(--delay) infinite alternate;
    animation-delay: var(--in), var(--delay);
    will-change: transform;
}
.ico.dark {
    color: var(--blue);
}
.ico svg {
    width: 100%;
    height: 100%;
    fill: none;
    stroke: currentColor;
    stroke-width: 1.6;
    stroke-linecap: round;
    stroke-linejoin: round;
}
@keyframes icoIn {
    to {
        opacity: var(--op);
    }
}
@keyframes floaty {
    0% {
        transform: translate3d(0, 0, 0) rotate(var(--rot));
    }
    100% {
        transform: translate3d(var(--dx), var(--dy), 0)
            rotate(calc(var(--rot) + var(--spin)));
    }
}

.capsule {
    position: absolute;
    border-radius: 999px;
    background: linear-gradient(
        160deg,
        rgba(1, 160, 226, 0.3),
        rgba(253, 254, 254, 0.55)
    );
    border: 14px solid rgba(1, 160, 226, 0.28);
    box-shadow: 0 30px 60px -30px rgba(1, 160, 226, 0.7);
    display: grid;
    place-items: center;
    overflow: hidden;
    animation: capFloat 8s ease-in-out infinite alternate;
}
.capsule::before {
    /* inner glow */
    content: "";
    position: absolute;
    inset: 0;
    background: radial-gradient(
        circle at 30% 20%,
        rgba(253, 254, 254, 0.7),
        transparent 55%
    );
}
.capsule svg {
    position: relative;
    width: 38%;
    height: auto;
    aspect-ratio: 1;
    fill: none;
    stroke: var(--blue);
    stroke-width: 1.3;
    stroke-linecap: round;
    stroke-linejoin: round;
    filter: drop-shadow(0 8px 14px rgba(1, 160, 226, 0.35));
}
.capsule.c1 {
    width: 190px;
    height: 380px;
    left: 7vw;
    top: 12vh;
}
.capsule.c2 {
    width: 210px;
    height: 410px;
    right: 6vw;
    bottom: 7vh;
    animation-delay: -4s;
}
.capsule.c3 {
    width: 110px;
    height: 220px;
    right: 17vw;
    top: 6vh;
    border-width: 9px;
    animation-delay: -2s;
    opacity: 0.85;
}
@keyframes capFloat {
    from {
        transform: translateY(0) rotate(-2deg);
    }
    to {
        transform: translateY(-18px) rotate(2deg);
    }
}

.card {
    position: relative;
    z-index: 2;
    width: 100%;
    max-width: 400px;
    background: var(--white);
    border-radius: 26px;
    overflow: hidden;
    box-shadow:
        0 36px 70px -28px rgba(1, 160, 226, 0.65),
        0 0 0 1px rgba(1, 160, 226, 0.14),
        0 8px 20px rgba(1, 160, 226, 0.12);
    animation: cardIn 0.95s ease-out both;
}
@keyframes cardIn {
    0% {
        opacity: 0;
        transform: translateY(-120px);
    }
    28% {
        opacity: 1;
    }
    50% {
        transform: translateY(18px);
    } /* lands, dips down */
    68% {
        transform: translateY(-9px);
    } /* bounces up */
    84% {
        transform: translateY(4px);
    } /* small settle */
    100% {
        opacity: 1;
        transform: none;
    }
}

.top {
    position: relative;
    padding: 26px 24px 52px;
    text-align: center;
    color: var(--white);
    background:
        radial-gradient(
            260px 160px at 85% 0%,
            rgba(255, 255, 255, 0.3),
            transparent 65%
        ),
        linear-gradient(
            150deg,
            #2bb6ee 0%,
            var(--blue) 45%,
            var(--blue-deep) 100%
        );
    overflow: hidden;
    isolation: isolate;
}

.top.no-logo {
    padding: 58px 24px 82px;
}
.top.no-logo .pill {
    margin-top: 0;
    font-size: 15.5px;
    padding: 10px 22px;
}

.top .ring {
    position: absolute;
    border-radius: 50%;
    z-index: -1;
    border: 1.5px solid rgba(253, 254, 254, 0.3);
    animation: pulseRing 5s ease-out infinite;
}
.top .r1 {
    width: 150px;
    height: 150px;
    left: -50px;
    top: -50px;
}
.top .r2 {
    width: 220px;
    height: 220px;
    right: -90px;
    top: -70px;
    animation-delay: 1.8s;
}
@keyframes pulseRing {
    0% {
        transform: scale(0.85);
        opacity: 0.9;
    }
    100% {
        transform: scale(1.2);
        opacity: 0;
    }
}

.top .mini {
    position: absolute;
    z-index: -1;
    width: 26px;
    height: 26px;
    fill: none;
    stroke: rgba(253, 254, 254, 0.5);
    stroke-width: 1.6;
    stroke-linecap: round;
    stroke-linejoin: round;
    animation: floaty2 4.5s ease-in-out infinite alternate;
}
.top .m1 {
    left: 22px;
    top: 70px;
}
.top .m2 {
    right: 24px;
    top: 78px;
    animation-delay: -2s;
}
.top .m3 {
    right: 70px;
    top: 18px;
    width: 20px;
    height: 20px;
    animation-delay: -1s;
}
.top .m4 {
    left: 70px;
    top: 16px;
    width: 20px;
    height: 20px;
    animation-delay: -3s;
}
@keyframes floaty2 {
    from {
        transform: translateY(0) rotate(-8deg);
    }
    to {
        transform: translateY(-9px) rotate(10deg);
    }
}

.logo {
    position: relative;
    width: 68px;
    height: 68px;
    margin: 0 auto 12px;
    border-radius: 50%;
    background: var(--white);
    display: grid;
    place-items: center;
    box-shadow: 0 10px 24px -6px rgba(0, 60, 100, 0.45);
}
.logo::after {
    content: "";
    position: absolute;
    inset: -4px;
    border-radius: 50%;
    border: 2px solid rgba(253, 254, 254, 0.7);
    animation: ping 2.6s ease-out infinite;
}
@keyframes ping {
    0% {
        transform: scale(1);
        opacity: 0.8;
    }
    100% {
        transform: scale(1.45);
        opacity: 0;
    }
}
@keyframes pop {
    from {
        transform: scale(0.3);
        opacity: 0;
    }
    to {
        transform: scale(1);
        opacity: 1;
    }
}
.logo img {
    width: 80%;
    height: 80%;
    object-fit: contain;
    border-radius: 50%;
}
.logo svg {
    width: 34px;
    height: 34px;
    stroke: var(--blue);
    fill: none;
    stroke-width: 1.8;
    stroke-linecap: round;
    stroke-linejoin: round;
}
.logo img ~ svg {
    display: none;
}

.top h1 {
    font-family: "Ubuntu", "Manrope", sans-serif;
    font-size: 21px;
    font-weight: 500;
    letter-spacing: 0.01em;
    line-height: 1.25;
}
.pill {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    margin-top: 10px;
    padding: 6px 14px;
    font-size: 12.5px;
    font-weight: 700;
    border-radius: 999px;
    background: rgba(253, 254, 254, 0.18);
    border: 1px solid rgba(253, 254, 254, 0.45);
    backdrop-filter: blur(6px);
}
.pill i {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: var(--white);
    animation: blink 1.4s ease-in-out infinite;
}
@keyframes blink {
    50% {
        opacity: 0.25;
    }
}

.wave {
    color: var(--white);
    position: absolute;
    left: 0;
    bottom: -2px;
    width: 100%;
    height: 36px;
    display: block;
}

.body {
    position: relative;
    z-index: 1;
    margin-top: -1px;
    background: var(--white);
    padding: 12px 38px 36px;
}

.welcome {
    text-align: center;
    margin-bottom: 28px;
}
.welcome b {
    font-family: "Ubuntu", "Manrope", sans-serif;
    font-weight: 500;
    font-size: 21px;
}
.welcome span {
    display: block;
    margin-top: 4px;
    font-size: 14px;
    color: var(--muted);
}

.alert {
    margin-bottom: 14px;
    padding: 10px 12px;
    border-radius: 12px;
    font-size: 13px;
    background: rgba(214, 69, 93, 0.08);
    border: 1px solid rgba(214, 69, 93, 0.3);
    color: var(--danger);
}
.alert.ok {
    background: var(--blue-soft);
    border-color: rgba(1, 160, 226, 0.35);
    color: var(--blue-deep);
    animation: none;
}

form {
    display: grid;
    gap: 2px;
}

.field {
    position: relative;
}

.input-container {
    position: relative;
    height: 58px;
}

.input-container input {
    width: 100%;
    height: 100%;
    padding: 0 46px 0 44px;
    font: inherit;
    font-size: 16px;
    font-weight: 500;
    color: var(--ink);
    background: transparent;
    caret-color: var(--blue);
    border: 1.5px solid rgba(1, 160, 226, 0.45);
    border-radius: 12px;
    outline: none;
    transition:
        border-color 0.2s,
        box-shadow 0.2s;
}
.input-container:hover input {
    border-color: var(--blue);
}
.input-container input:focus {
    border-color: var(--blue);
    box-shadow: 0 0 0 1px var(--blue);
}

.input-container label {
    position: absolute;
    top: 0;
    left: 44px;
    height: 20px;
    line-height: 20px;
    padding: 0 6px;
    background: var(--white);
    font-size: 16px;
    font-weight: 600;
    color: var(--muted);
    transform: translate(0, 19px);
    transform-origin: left center;
    pointer-events: none;
    user-select: none;
    will-change: transform;
    transition:
        transform 0.22s cubic-bezier(0.4, 0, 0.2, 1),
        color 0.22s ease;
}

.input-container input:focus + label,
.input-container input.is-valid + label,
.input-container input:not(:placeholder-shown) + label,
.input-container input:-webkit-autofill + label {
    transform: translate(-32px, -10px) scale(0.8);
    color: var(--blue);
}
.input-container input:-webkit-autofill {
    -webkit-box-shadow: 0 0 0 40px var(--white) inset;
    -webkit-text-fill-color: var(--ink);
}

.input-container .lead {
    position: absolute;
    left: 14px;
    top: 50%;
    transform: translateY(-50%);
    width: 19px;
    height: 19px;
    stroke: var(--blue);
    fill: none;
    stroke-width: 1.8;
    stroke-linecap: round;
    stroke-linejoin: round;
    pointer-events: none;
    transition: transform 0.2s;
}
.input-container:focus-within .lead {
    transform: translateY(-50%) scale(1.12);
}

.preload .input-container label {
    transition: none;
}

.field.invalid .input-container input {
    border-color: var(--danger);
}
.field.invalid .input-container input:focus {
    box-shadow: 0 0 0 1px var(--danger);
}
.field.invalid .input-container label,
.field.invalid .input-container input:focus + label {
    color: var(--danger);
}
.field.invalid .lead {
    stroke: var(--danger);
}

@keyframes shake {
    0%,
    100% {
        transform: translateX(0);
    }
    20% {
        transform: translateX(-7px);
    }
    40% {
        transform: translateX(6px);
    }
    60% {
        transform: translateX(-4px);
    }
    80% {
        transform: translateX(3px);
    }
}

.toggle {
    position: absolute;
    right: 6px;
    top: 50%;
    transform: translateY(-50%);
    width: 38px;
    height: 38px;
    border: 0;
    border-radius: 10px;
    background: transparent;
    cursor: pointer;
    display: grid;
    place-items: center;
}
.toggle:hover {
    background: var(--blue-soft);
}
.toggle:focus-visible {
    outline: 2px solid var(--blue);
}
.toggle svg {
    width: 19px;
    height: 19px;
    stroke: var(--muted);
    fill: none;
    stroke-width: 1.8;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.err {
    min-height: 34px;
    padding: 6px 6px 0;
    font-size: 12.5px;
    font-weight: 600;
    color: var(--danger);
    opacity: 0;
    transition: opacity 0.2s;
}
.field.invalid .err {
    opacity: 1;
    transform: none;
}
.caps {
    position: absolute;
    right: 6px;
    top: 64px;
    min-height: 0;
    padding: 0;
    color: #b7791f;
    pointer-events: none;
}
.caps.show {
    opacity: 1;
}

.row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 13px;
    margin: 2px 0 12px;
}
.check {
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    color: var(--muted);
    user-select: none;
}
.check input {
    accent-color: var(--blue);
    width: 16px;
    height: 16px;
}
.row a {
    color: var(--blue-deep);
    font-weight: 600;
    text-decoration: none;
}
.row a:hover {
    text-decoration: underline;
}

.btn {
    position: relative;
    height: 54px;
    border: 0;
    border-radius: 999px;
    font: inherit;
    font-size: 16px;
    font-weight: 700;
    letter-spacing: 0.01em;
    color: var(--white);
    background: linear-gradient(
        135deg,
        #2bb6ee,
        var(--blue) 50%,
        var(--blue-deep)
    );
    cursor: pointer;
    overflow: hidden;
    box-shadow: 0 14px 26px -10px rgba(1, 160, 226, 0.8);
    transition:
        transform 0.2s,
        box-shadow 0.2s;
}
.btn::after {
    content: "";
    position: absolute;
    top: 0;
    left: -80%;
    width: 50%;
    height: 100%;
    background: linear-gradient(
        100deg,
        transparent,
        rgba(253, 254, 254, 0.55),
        transparent
    );
    transform: skewX(-20deg);
    animation: shine 3.6s ease-in-out 1.6s infinite;
}
@keyframes shine {
    0% {
        left: -80%;
    }
    35%,
    100% {
        left: 140%;
    }
}
.btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 20px 32px -12px rgba(1, 160, 226, 0.9);
}
.btn:active {
    transform: translateY(0);
}
.btn:focus-visible {
    outline: 3px solid rgba(1, 160, 226, 0.45);
    outline-offset: 3px;
}
.btn .spin {
    display: none;
    width: 21px;
    height: 21px;
    margin: auto;
    border: 3px solid rgba(253, 254, 254, 0.4);
    border-top-color: var(--white);
    border-radius: 50%;
    animation: rot 0.7s linear infinite;
}
.btn.loading {
    pointer-events: none;
}
.btn.loading .label {
    display: none;
}
.btn.loading .spin {
    display: block;
}
.btn.loading::after {
    display: none;
}
@keyframes rot {
    to {
        transform: rotate(360deg);
    }
}

.foot {
    margin-top: 16px;
    text-align: center;
    font-size: 12px;
    color: var(--muted);
}

@media (max-width: 1100px) {
    .capsule.c3 {
        display: none;
    }
    .capsule.c1 {
        left: 2vw;
    }
    .capsule.c2 {
        right: 2vw;
    }
}
@media (max-width: 820px) {
    .capsule {
        display: none;
    }
}
@media (max-width: 440px) {
    .body {
        padding: 10px 22px 28px;
    }
}
@media (max-height: 660px) {
    .top {
        padding: 18px 20px 44px;
    }
    .logo {
        width: 56px;
        height: 56px;
        margin-bottom: 8px;
    }
    .welcome {
        display: none;
    }
    .body {
        padding-top: 16px;
    }
}
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
    }
    .ico {
        opacity: var(--op);
    }
    .seq > * {
        opacity: 1;
    }
}
