/* =============================================
   Regform — попап
   ============================================= */
.gs-regform-popup {
    position: fixed;
    inset: 0;
    z-index: 10000;
    align-items: center;
    justify-content: center;
}

.gs-regform-popup--open {
    display: flex !important;
}

.gs-regform-popup__overlay {
    position: absolute;
    inset: 0;
    background: rgba(15, 25, 60, 0.55);
}

.gs-regform-popup__window {
    position: relative;
    background: #fff;
    border-radius: 16px;
    width: min(560px, calc(100% - 32px));
    max-height: calc(100vh - 32px);
    display: flex;
    flex-direction: column;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.25);
    overflow: hidden;
}

.gs-regform-popup__header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 20px 28px;
    border-bottom: 1px solid #eef0f5;
}

.gs-regform-popup__title {
    font-size: 20px;
    font-weight: 700;
    color: #003baa;
    text-transform: uppercase;
    letter-spacing: 0.02em;
}

.gs-regform-popup__close {
    background: none;
    border: 0;
    font-size: 28px;
    line-height: 1;
    color: #888;
    cursor: pointer;
    padding: 0;
    width: 32px;
    height: 32px;
}

.gs-regform-popup__close:hover {
    color: #003baa;
}

.gs-regform-popup__body {
    padding: 24px 28px 28px;
    overflow-y: auto;
}

/* =============================================
   Regform — алерты
   ============================================= */
.gs-regform__alert {
    border-radius: 10px;
    padding: 14px 18px;
    margin-bottom: 16px;
    font-size: 14px;
    line-height: 1.5;
}

.gs-regform__alert--error {
    background: #fdecea;
    color: #b3261e;
}

.gs-regform__alert--success {
    background: #e6f4ea;
    color: #1d643b;
    text-align: center;
    flex-direction: column;
    align-items: center;
}

/* =============================================
   Regform — форма
   ============================================= */
.gs-regform__group {
    margin-bottom: 16px;
}

.gs-regform__group:last-of-type {
    margin-bottom: 20px;
}

.gs-regform__label {
    display: block;
    font-size: 13px;
    color: #666;
    margin-bottom: 6px;
}

.gs-regform__star {
    color: #d93b3b;
}

.gs-regform__input {
    width: 100%;
    border: 1px solid #d6dae2;
    border-radius: 8px;
    padding: 10px 14px;
    font-size: 15px;
    line-height: 1.4;
    background: #fff;
    color: #1a1a2e;
    transition: border-color 0.15s;
    font-family: inherit;
}

.gs-regform__input::placeholder {
    color: #b8bcc6;
}

.gs-regform__input:focus {
    outline: none;
    border-color: #003baa;
}

.gs-regform__group.has-error .gs-regform__input,
.gs-regform__group.has-error .gs-regform__captcha-word {
    border-color: #d93b3b;
}

.gs-regform__error {
    display: none;
    margin-top: 6px;
    font-size: 12px;
    color: #d93b3b;
}

.gs-regform__group.has-error .gs-regform__error {
    display: block;
}

/* Captcha */
.gs-regform__captcha {
    display: flex;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
}

.gs-regform__captcha-img {
    height: 42px;
    border-radius: 6px;
    background: #f4f6fa;
}

.gs-regform__captcha-reload {
    background: none;
    border: 1px solid #d6dae2;
    border-radius: 8px;
    width: 36px;
    height: 36px;
    cursor: pointer;
    font-size: 18px;
    color: #003baa;
    line-height: 1;
}

.gs-regform__captcha-reload:hover {
    border-color: #003baa;
}

.gs-regform__captcha-word {
    flex: 1;
    min-width: 140px;
}

/* Policy */
.gs-regform__group--policy {
    margin-bottom: 20px;
}

.gs-regform__check {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    cursor: pointer;
    font-size: 14px;
    line-height: 1.5;
    color: #1a1a2e;
}

.gs-regform__check input[type="checkbox"] {
    margin-top: 2px;
    flex-shrink: 0;
    width: 16px;
    height: 16px;
    cursor: pointer;
}

.gs-regform__check a {
    color: #003baa;
    text-decoration: underline;
}

.gs-regform__check a:hover {
    text-decoration: none;
}

/* Submit */
.gs-regform__submit.btn {
    width: 100%;
    border-radius: 8px;
    min-height: 48px;
    padding: 12px 24px;
    font-size: 15px;
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.gs-regform__submit:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}
