/* Agama callback modal */
:root {
    --agama-primary: #2e5b80;
    --agama-primary-hover: #244766;
    --agama-text: #1a1a1a;
    --agama-muted: #6b7785;
    --agama-border: #d8dee5;
    --agama-error: #c0392b;
}

.agama-cb-overlay {
    position: fixed;
    inset: 0;
    background: rgba(20, 30, 45, 0.55);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 9999999999;
    padding: 16px;
    opacity: 0;
    transition: opacity 0.18s ease;
}
.agama-cb-overlay.is-open {
    display: flex;
    opacity: 1;
}

.agama-cb-modal {
    background: #fff;
    color: var(--agama-text);
    width: 100%;
    max-width: 420px;
    border-radius: 12px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.25);
    padding: 28px 24px 24px;
    position: relative;
    box-sizing: border-box;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    transform: translateY(8px);
    transition: transform 0.18s ease;
}
.agama-cb-overlay.is-open .agama-cb-modal { transform: translateY(0); }

.agama-cb-close {
    position: absolute;
    top: 10px;
    right: 10px;
    width: 32px;
    height: 32px;
    border: 0;
    background: transparent;
    cursor: pointer;
    border-radius: 50%;
    color: var(--agama-muted);
    font-size: 22px;
    line-height: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.15s ease;
}
.agama-cb-close:hover { background: #f1f4f7; color: var(--agama-text); }

.agama-cb-title {
    margin: 0 0 6px;
    font-size: 20px;
    font-weight: 600;
    color: var(--agama-primary);
}
.agama-cb-subtitle {
    margin: 0 0 18px;
    font-size: 14px;
    color: var(--agama-muted);
}

.agama-cb-form { display: flex; flex-direction: column; gap: 12px; }
.agama-cb-field { display: flex; flex-direction: column; gap: 4px; }
.agama-cb-field label {
    font-size: 13px;
    color: var(--agama-muted);
}
.agama-cb-field input {
    box-sizing: border-box;
    width: 100%;
    height: 44px;
    padding: 10px 12px;
    border: 1px solid var(--agama-border);
    border-radius: 8px;
    font-size: 15px;
    color: var(--agama-text);
    background: #fff;
    transition: border-color 0.15s ease, box-shadow 0.15s ease;
    font-family: inherit;
}

.agama-cb-fixed {
    position: fixed;
    bottom: 30px;
    right: 30px;
    z-index: 9999;
    width: 55px;
    height: 55px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 12px rgba(0,0,0,0.3);
    transition: transform 0.2s;
    text-decoration: none;
    background: #2f5b80;
    border: 1px solid #ffffff;
}

.agama-cb-fixed:hover {
    transform: scale(1.1);
}

.agama-cb-fixed img {
    width: 45px;
    height: 45px;
}


.agama-cb-field input:focus {
    outline: none;
    border-color: var(--agama-primary);
    box-shadow: 0 0 0 3px rgba(46, 91, 128, 0.15);
}
.agama-cb-field.is-invalid input { border-color: var(--agama-error); }

/* honeypot */
.agama-cb-hp {
    position: absolute !important;
    left: -10000px !important;
    width: 1px !important;
    height: 1px !important;
    opacity: 0 !important;
    pointer-events: none !important;
}

.agama-cb-agree {
    display: flex;
    align-items: flex-start;
    gap: 8px;
    font-size: 13px;
    color: var(--agama-muted);
    line-height: 1.4;
    cursor: pointer;
    user-select: none;
}
.agama-cb-agree input[type="checkbox"] {
    margin: 2px 0 0;
    width: 16px;
    height: 16px;
    accent-color: var(--agama-primary);
    cursor: pointer;
    flex-shrink: 0;
}
.agama-cb-agree a {
    color: var(--agama-primary);
    text-decoration: underline;
}
.agama-cb-agree a:hover { text-decoration: none; }

.agama-cb-submit {
    margin-top: 6px;
    height: 46px;
    border: 0;
    border-radius: 8px;
    background: var(--agama-primary);
    color: #fff;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.15s ease;
    font-family: inherit;
}
.agama-cb-submit:hover:not(:disabled) { background: var(--agama-primary-hover); }
.agama-cb-submit:disabled { opacity: 0.6; cursor: not-allowed; }

.agama-cb-note {
    margin: 10px 0 0;
    font-size: 12px;
    color: var(--agama-muted);
    text-align: center;
}

.agama-cb-error {
    display: none;
    margin: 0;
    padding: 10px 12px;
    background: #fdecea;
    color: var(--agama-error);
    border-radius: 8px;
    font-size: 13px;
}
.agama-cb-error.is-visible { display: block; }

.agama-cb-success {
    text-align: center;
    padding: 20px 0 4px;
}
.agama-cb-success-icon {
    width: 54px;
    height: 54px;
    border-radius: 50%;
    background: var(--agama-primary);
    color: #fff;
    margin: 0 auto 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 28px;
    line-height: 1;
}
.agama-cb-success-text {
    font-size: 16px;
    color: var(--agama-text);
    margin: 0;
}

@media (max-width: 480px) {
    .agama-cb-modal { padding: 24px 18px 20px; border-radius: 10px; }
    .agama-cb-title { font-size: 18px; }
	.hideonmobile {display:none}
}

/* блокировка скролла фона */
html.agama-cb-locked, body.agama-cb-locked { overflow: hidden; }
