/* Contact Sales modal — feature-scoped (.cs-*) so it can't collide. */
.cs-modal {
    position: fixed;
    inset: 0;
    z-index: 10050;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 20px;
}
.cs-modal.is-open { display: flex; }
.cs-modal__backdrop {
    position: absolute;
    inset: 0;
    background: rgba(2, 6, 23, 0.72);
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
}
.cs-modal__panel {
    position: relative;
    width: 100%;
    max-width: 640px;
    max-height: calc(100vh - 40px);
    overflow-y: auto;
    background: #ffffff;
    color: #0f172a;
    border-radius: 16px;
    box-shadow: 0 30px 80px rgba(0, 0, 0, 0.45);
    padding: 28px 28px 22px;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Arial, sans-serif;
}
.cs-modal__close {
    position: absolute;
    top: 12px;
    right: 14px;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    border: none;
    background: transparent;
    color: #64748b;
    font-size: 26px;
    line-height: 1;
    cursor: pointer;
    transition: background 0.15s ease, color 0.15s ease;
}
.cs-modal__close:hover { background: #f1f5f9; color: #0f172a; }

.cs-modal__header { margin-bottom: 18px; }
.cs-modal__eyebrow {
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: #ea580c;
    margin-bottom: 6px;
}
.cs-modal__title {
    margin: 0 0 6px;
    font-size: 24px;
    font-weight: 700;
    line-height: 1.2;
    color: #0f172a;
}
.cs-modal__subtitle {
    margin: 0;
    font-size: 14px;
    color: #475569;
    line-height: 1.5;
}

.cs-modal__form { display: flex; flex-direction: column; gap: 14px; }

.cs-section {
    display: flex;
    flex-direction: column;
    gap: 12px;
    padding: 14px 14px 16px;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    background: #f8fafc;
}
.cs-section__title {
    font-size: 11px;
    font-weight: 800;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: #ea580c;
}

.cs-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 14px;
}
.cs-field { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.cs-field--full { grid-column: 1 / -1; }
.cs-field__label {
    font-size: 12px;
    font-weight: 600;
    color: #334155;
    letter-spacing: 0.02em;
}
.cs-field__label em {
    font-style: normal;
    color: #ea580c;
    margin-left: 2px;
}
.cs-field input,
.cs-field select,
.cs-field textarea {
    width: 100%;
    box-sizing: border-box;
    padding: 10px 12px;
    border: 1px solid #cbd5e1;
    border-radius: 8px;
    background: #ffffff;
    color: #0f172a;
    font-size: 14px;
    font-family: inherit;
    transition: border-color 0.15s ease, box-shadow 0.15s ease;
}
.cs-field textarea { resize: vertical; min-height: 96px; }
.cs-field input:focus,
.cs-field select:focus,
.cs-field textarea:focus {
    outline: none;
    border-color: #f97316;
    box-shadow: 0 0 0 3px rgba(249, 115, 22, 0.18);
}

.cs-modal__status {
    min-height: 18px;
    font-size: 13px;
    line-height: 1.4;
}
.cs-modal__status.is-error { color: #b91c1c; }
.cs-modal__status.is-success { color: #15803d; }

.cs-modal__actions {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
    margin-top: 4px;
}
.cs-btn {
    appearance: none;
    border: none;
    font-family: inherit;
    font-size: 14px;
    font-weight: 600;
    padding: 11px 20px;
    border-radius: 9px;
    cursor: pointer;
    transition: filter 0.15s ease, background 0.15s ease, transform 0.05s ease;
}
.cs-btn--ghost {
    background: transparent;
    color: #475569;
}
.cs-btn--ghost:hover { background: #f1f5f9; color: #0f172a; }
.cs-btn--primary {
    background: linear-gradient(135deg, #f97316, #ea580c);
    color: #ffffff;
    box-shadow: 0 8px 18px rgba(234, 88, 12, 0.32);
}
.cs-btn--primary:hover { filter: brightness(1.05); }
.cs-btn--primary:active { transform: translateY(1px); }
.cs-btn[disabled] { opacity: 0.6; cursor: not-allowed; }

.cs-modal__fineprint {
    margin: 4px 0 0;
    font-size: 12px;
    color: #94a3b8;
    text-align: center;
}
.cs-modal__fineprint a { color: #64748b; text-decoration: underline; }

/* Success / "Try it right now" panel — shown after form submit OK. */
.cs-success {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    padding: 28px 24px 22px;
    gap: 14px;
}
.cs-success__check {
    width: 56px;
    height: 56px;
    border-radius: 50%;
    background: linear-gradient(135deg, #22c55e, #15803d);
    color: #fff;
    font-size: 30px;
    line-height: 56px;
    font-weight: 700;
    box-shadow: 0 8px 18px rgba(21, 128, 61, 0.28);
}
.cs-success__title {
    margin: 0;
    font-size: 22px;
    font-weight: 700;
    color: #0f172a;
}
.cs-success__sub {
    margin: 0;
    max-width: 460px;
    font-size: 14px;
    line-height: 1.55;
    color: #475569;
}
.cs-success__sub strong { color: #0f172a; }
.cs-success__cta-wrap {
    width: 100%;
    max-width: 460px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    margin-top: 4px;
}
.cs-success__cta {
    display: inline-block;
    padding: 14px 28px;
    font-size: 15px;
    text-decoration: none;
    text-align: center;
}
.cs-success__hint {
    margin: 0;
    font-size: 12.5px;
    color: #64748b;
    line-height: 1.5;
}
.cs-success__close {
    margin-top: 4px;
    font-size: 13px;
}

/* Secondary CTA — "Speak to a live representative now" with a live presence dot. */
.cs-success__chat {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 9px;
    width: 100%;
    max-width: 460px;
    margin-top: 10px;
    padding: 12px 22px;
    font-size: 14.5px;
    font-weight: 600;
    color: #0f172a;
    background: #ffffff;
    border: 1.5px solid #cbd5e1;
    border-radius: 9px;
    cursor: pointer;
    transition: border-color 0.15s ease, box-shadow 0.15s ease, background 0.15s ease;
}
.cs-success__chat:hover {
    background: #f8fafc;
    border-color: #94a3b8;
}
.cs-success__chat.is-online {
    border-color: #16a34a;
    box-shadow: 0 6px 16px rgba(22, 163, 74, 0.18);
}
.cs-success__chat.is-online:hover { background: #f0fdf4; }
.cs-success__chat-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: #94a3b8;
    flex: 0 0 auto;
}
.cs-success__chat.is-online .cs-success__chat-dot {
    background: #22c55e;
    box-shadow: 0 0 0 0 rgba(34, 197, 94, 0.55);
    animation: cs-pulse 1.6s ease-out infinite;
}
@keyframes cs-pulse {
    0%   { box-shadow: 0 0 0 0 rgba(34, 197, 94, 0.55); }
    70%  { box-shadow: 0 0 0 7px rgba(34, 197, 94, 0); }
    100% { box-shadow: 0 0 0 0 rgba(34, 197, 94, 0); }
}
.cs-success__chat-status {
    margin: 2px 0 0;
    font-size: 12.5px;
    color: #64748b;
    line-height: 1.45;
}
.cs-success__chat-status.is-online {
    color: #15803d;
    font-weight: 600;
}

/* Honeypot — visually hidden but still in the DOM for bots. */
.cs-hp {
    position: absolute !important;
    left: -10000px !important;
    top: auto !important;
    width: 1px !important;
    height: 1px !important;
    overflow: hidden !important;
}

@media (max-width: 560px) {
    .cs-modal { padding: 0; align-items: stretch; }
    .cs-modal__panel {
        max-width: none;
        max-height: 100vh;
        height: 100vh;
        border-radius: 0;
        padding: 20px 16px 24px;
        -webkit-overflow-scrolling: touch;
    }
    .cs-modal__title { font-size: 20px; }
    .cs-modal__subtitle { font-size: 13px; }
    .cs-row { grid-template-columns: 1fr; gap: 12px; }
    .cs-section { padding: 12px 12px 14px; gap: 10px; }
    /* 16px input font prevents iOS Safari from auto-zooming on focus. */
    .cs-field input,
    .cs-field select,
    .cs-field textarea { font-size: 16px; padding: 12px 12px; }
    .cs-modal__actions { flex-direction: column-reverse; gap: 8px; }
    .cs-modal__actions .cs-btn { width: 100%; padding: 14px 20px; }
}
