*,
*::before,
*::after {
    box-sizing: border-box;
}

html,
body {
    margin: 0;
    padding: 0;
}

body {
    min-height: 100vh;
    font-family: Montserrat, "Segoe UI", Arial, sans-serif;
    color: #1f2937;
    -webkit-font-smoothing: antialiased;
    background: #f8eef8;
}

body::before,
body::after {
    content: "";
    position: fixed;
    inset: 0;
    pointer-events: none;
}

body::before {
    z-index: 0;
    background:
        radial-gradient(ellipse 560px 460px at 6% 8%, rgba(255, 64, 186, 0.42), transparent 68%),
        radial-gradient(ellipse 520px 420px at 96% 0%, rgba(255, 186, 222, 0.85), transparent 70%),
        radial-gradient(ellipse 640px 520px at 92% 96%, rgba(132, 92, 255, 0.28), transparent 68%),
        radial-gradient(ellipse 480px 400px at 0% 92%, rgba(255, 112, 168, 0.34), transparent 70%),
        linear-gradient(165deg, #fff6fb 0%, #f4e9ff 46%, #ffe3f3 100%);
}

body::after {
    z-index: 0;
    opacity: 0.45;
    background-image: radial-gradient(rgba(255, 78, 190, 0.28) 1.1px, transparent 1.1px);
    background-size: 22px 22px;
    mask-image: radial-gradient(circle at 50% 40%, #000 0%, transparent 78%);
}

.wrap {
    position: relative;
    z-index: 1;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 28px 16px 0;
}

.site-footer {
    width: 100%;
    margin-top: 8px;
    padding: 16px 16px 18px;
    text-align: center;
    color: rgba(90, 20, 60, 0.78);
    font-size: 13px;
    font-weight: 600;
}

.card {
    width: min(1000px, 100%);
    margin: auto;
    background: #fff;
    border-radius: 24px;
    padding: 34px 42px 30px;
    box-shadow: 0 22px 60px rgba(180, 40, 120, 0.16);
}

.brand {
    margin: 0 0 16px;
    text-align: center;
    color: #1a1a1a;
    font-weight: 800;
    font-size: 30px;
    letter-spacing: 0.04em;
    line-height: 1.15;
}

.brand::after {
    content: "";
    display: block;
    width: 58px;
    height: 3px;
    margin: 10px auto 0;
    border-radius: 999px;
    background: #ff4ebe;
}

.hero {
    margin: 0;
    text-align: center;
    color: #ff2f96;
    font-weight: 800;
    font-size: 15.5px;
    line-height: 1.45;
    letter-spacing: 0.01em;
    text-transform: uppercase;
}

.sub {
    margin: 8px 0 0;
    text-align: center;
    color: #ff2d2d;
    font-size: 13.5px;
    font-weight: 600;
    line-height: 1.45;
}

.form {
    margin-top: 22px;
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.stack {
    display: flex;
    flex-direction: column;
    gap: 7px;
}

.row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 14px;
}

.field {
    position: relative;
    display: block;
}

.field .ico {
    position: absolute;
    left: 16px;
    top: 0;
    width: 20px;
    height: 56px;
    color: #fff;
    pointer-events: none;
    display: flex;
    align-items: center;
}

.field .ico svg {
    width: 20px;
    height: 20px;
}

.field input,
.field select {
    width: 100%;
    height: 56px;
    border: none;
    border-radius: 12px;
    background-color: #3c3c3c;
    color: #fff;
    font: inherit;
    font-size: 15px;
    font-weight: 500;
    padding: 0 18px 0 50px;
    outline: none;
}

.field select {
    padding-right: 42px;
    cursor: pointer;
    color-scheme: dark;
    -webkit-appearance: none;
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='2.4' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 16px center;
    background-size: 16px;
}

.field input::placeholder {
    color: rgba(255, 255, 255, 0.78);
}

.field input:focus,
.field select:focus {
    box-shadow: 0 0 0 3px rgba(255, 78, 190, 0.45);
}

.field.invalid input,
.field.invalid select {
    box-shadow: 0 0 0 2px #ff3b30;
}

.hint {
    margin: 0;
    padding-left: 4px;
    color: #ff2d2d;
    font-size: 12.5px;
    font-weight: 600;
    line-height: 1.45;
}

.popup {
    position: fixed;
    inset: 0;
    z-index: 30;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    background: rgba(28, 10, 24, 0.48);
}

.popup-card {
    width: min(420px, 100%);
    background: #fff;
    border-radius: 22px;
    padding: 28px 24px 22px;
    text-align: center;
    box-shadow: 0 24px 60px rgba(80, 10, 50, 0.28);
}

.popup-card p {
    margin: 0 0 18px;
    color: #1a1a1a;
    font-size: 18px;
    font-weight: 800;
    line-height: 1.45;
}

.popup-close {
    width: 100%;
    height: 48px;
    border: none;
    border-radius: 999px;
    background: #ff4ebe;
    color: #fff;
    font: inherit;
    font-weight: 800;
    letter-spacing: 0.04em;
    cursor: pointer;
}

.popup-close:hover {
    filter: brightness(1.05);
}

.alert {
    background: #fff1f2;
    color: #be123c;
    border-radius: 12px;
    padding: 10px 12px;
    font-size: 13px;
    font-weight: 600;
}

.alert p {
    margin: 4px 0;
}

.submit {
    margin-top: 4px;
    height: 54px;
    width: 100%;
    border: none;
    border-radius: 999px;
    background: #ff4ebe;
    color: #fff;
    font: inherit;
    font-weight: 800;
    letter-spacing: 0.06em;
    font-size: 15px;
    cursor: pointer;
    box-shadow: 0 10px 22px rgba(255, 78, 190, 0.28);
    text-transform: uppercase;
    text-decoration: none;
    display: flex;
    align-items: center;
    justify-content: center;
}

.submit:hover {
    filter: brightness(1.05);
}

.submit:active {
    transform: translateY(1px);
}

.submit:disabled {
    opacity: 0.75;
    cursor: wait;
}

.footer-note {
    text-align: center;
    color: #9ca3af;
    font-size: 12px;
    margin: 14px 0 0;
}

.hp {
    position: absolute;
    left: -9999px;
    height: 0;
    overflow: hidden;
}

.success-card {
    text-align: center;
}

.ok-icon {
    width: 64px;
    height: 64px;
    margin: 4px auto 16px;
    border-radius: 50%;
    background: #ffe4f4;
    color: #ff2f96;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 32px;
    font-weight: 800;
}

.success-card h1 {
    margin: 0;
    color: #ff2f96;
    font-size: 26px;
    font-weight: 800;
}

.success-card .sub {
    margin: 10px 0 22px;
}

@media (max-width: 720px) {
    .wrap {
        padding: 14px;
    }

    .card {
        padding: 22px 14px 18px;
        border-radius: 18px;
    }

    .brand {
        font-size: 24px;
    }

    .hero {
        font-size: 13px;
    }

    .row {
        grid-template-columns: 1fr;
    }
}
