.ecmn-wrap,
.ecmn-wrap * { box-sizing: border-box; }

.ecmn-wrap {
    width: auto;
    max-width: none;
    margin: 42px 0 0;
    padding: var(--ecmn-padding, 28px);
    border: var(--ecmn-border-width, 1px) solid var(--ecmn-border, #E1E5EA);
    border-radius: var(--ecmn-radius, 12px);
    background: var(--ecmn-bg, #F7F8FA);
    color: inherit;
    font-family: inherit;
    line-height: 1.5;
}

.ecmn-wrap--overlay { margin: 0; border: 0; border-radius: 14px; background: #fff; }
.ecmn-inner { width: 100%; max-width: none; }
.ecmn-kicker { margin: 0 0 7px; color: var(--ecmn-accent, #020452); font-size: 12px; font-weight: 800; letter-spacing: .09em; text-transform: uppercase; }
.ecmn-title { margin: 0 0 10px; color: inherit; font: inherit; font-size: clamp(22px, 2.4vw, 30px); font-weight: 800; line-height: 1.15; }
.ecmn-description { max-width: 850px; margin: 0 0 24px; color: color-mix(in srgb, currentColor 78%, transparent); font-size: 16px; line-height: 1.55; }
.ecmn-field { margin: 0 0 16px; }
.ecmn-field label { display: block; margin: 0 0 7px; color: inherit; font-size: 13px; font-weight: 700; }
.ecmn-field input[type="email"], .ecmn-field select { width: 100%; min-height: 48px; margin: 0; padding: 10px 12px; border: 1px solid #cfd5dc; border-radius: 8px; background: #fff; color: #17191d; font: inherit; font-size: 15px; line-height: 1.2; box-shadow: none; outline: none; }
.ecmn-field input[type="email"]:focus, .ecmn-field select:focus { border-color: var(--ecmn-accent, #020452); box-shadow: 0 0 0 3px color-mix(in srgb, var(--ecmn-accent, #020452) 12%, transparent); }
.ecmn-consent { display: flex; align-items: flex-start; gap: 9px; margin: 2px 0 18px; color: color-mix(in srgb, currentColor 78%, transparent); cursor: pointer; font-size: 13px; font-weight: 400; line-height: 1.45; }
.ecmn-consent input[type="checkbox"] { flex: 0 0 auto; width: 17px; height: 17px; margin: 2px 0 0; accent-color: var(--ecmn-accent, #020452); }
.ecmn-consent a, .ecmn-note a { color: var(--ecmn-accent, #020452); text-decoration: underline; text-underline-offset: 2px; }
.ecmn-submit { display: inline-flex; min-height: 48px; align-items: center; justify-content: center; margin: 0; padding: 12px 22px; border: 1px solid var(--ecmn-accent, #020452); border-radius: 8px; background: var(--ecmn-accent, #020452); color: #fff; cursor: pointer; font: inherit; font-size: 14px; font-weight: 700; letter-spacing: .035em; line-height: 1.2; text-transform: uppercase; box-shadow: none; transition: transform .12s ease, filter .16s ease; }
.ecmn-submit:hover { filter: brightness(.9); }
.ecmn-submit:focus-visible { outline: 3px solid color-mix(in srgb, var(--ecmn-accent, #020452) 24%, transparent); outline-offset: 2px; }
.ecmn-submit:active { transform: translateY(1px); }
.ecmn-submit[disabled] { cursor: wait; opacity: .68; }
.ecmn-note { margin: 12px 0 0; color: color-mix(in srgb, currentColor 60%, transparent); font-size: 12px; line-height: 1.45; }
.ecmn-message { display: none; margin: 16px 0 0; padding: 11px 13px; border-radius: 8px; font-size: 14px; line-height: 1.45; }
.ecmn-message.is-visible { display: block; }
.ecmn-message.is-success { border: 1px solid #b9dbc4; background: #eef8f1; color: #165c2d; }
.ecmn-message.is-error { border: 1px solid #e8b9b9; background: #fff2f2; color: #8b1e1e; }
.ecmn-hp { position: absolute !important; width: 1px !important; height: 1px !important; overflow: hidden !important; clip: rect(1px,1px,1px,1px) !important; white-space: nowrap !important; }

@media (min-width: 700px) {
    .ecmn-form { display: grid; grid-template-columns: minmax(0,1.15fr) minmax(0,1fr); column-gap: 16px; }
    .ecmn-consent, .ecmn-submit, .ecmn-note, .ecmn-message, .ecmn-hp { grid-column: 1 / -1; }
    .ecmn-field { margin-bottom: 16px; }
}
@media (max-width: 699px) {
    .ecmn-wrap { margin-top: 30px; padding: max(20px, min(var(--ecmn-padding, 28px), 24px)); border-radius: min(var(--ecmn-radius, 12px), 10px); }
    .ecmn-wrap--overlay { margin: 0; }
    .ecmn-title { font-size: 22px; }
    .ecmn-description { margin-bottom: 20px; font-size: 15px; }
    .ecmn-submit { width: 100%; }
}

.ecmn-overlay, .ecmn-overlay * { box-sizing: border-box; }
.ecmn-overlay { position: fixed; inset: 0; z-index: 999999; display: none; align-items: center; justify-content: center; padding: 24px; }
.ecmn-overlay.is-open { display: flex; }
.ecmn-overlay-backdrop { position: absolute; inset: 0; background: rgba(10,14,24,.66); backdrop-filter: blur(2px); }
.ecmn-overlay-dialog { position: relative; z-index: 1; width: min(100%, var(--ecmn-overlay-max, 640px)); max-height: calc(100vh - 48px); overflow: auto; border-radius: 14px; background: #fff; box-shadow: 0 24px 70px rgba(0,0,0,.28); overscroll-behavior: contain; }
.ecmn-overlay-close { position: absolute; z-index: 3; top: 10px; right: 10px; display: inline-flex; width: 38px; height: 38px; align-items: center; justify-content: center; padding: 0; border: 0; border-radius: 999px; background: rgba(255,255,255,.94); color: #17191d; cursor: pointer; font: inherit; font-size: 27px; line-height: 1; box-shadow: 0 2px 12px rgba(0,0,0,.12); }
body.ecmn-overlay-open { overflow: hidden; }
@media (max-width: 699px) { .ecmn-overlay { align-items: flex-end; padding: 12px; } .ecmn-overlay-dialog { width: 100%; max-height: calc(100vh - 24px); } }
@media (prefers-reduced-motion: reduce) { .ecmn-submit, .ecmn-field select, .ecmn-field input[type="email"] { transition: none; } }
