/**
 * Electrisim download-gate + exit-intent modals
 */
.dg-modal {
    position: fixed;
    inset: 0;
    z-index: 10050;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 16px;
}
.dg-modal.is-open {
    display: flex;
}
.dg-modal__backdrop {
    position: absolute;
    inset: 0;
    background: rgba(15, 23, 42, 0.55);
}
.dg-modal__dialog {
    position: relative;
    z-index: 1;
    width: 100%;
    max-width: 440px;
    background: #fff;
    border-radius: 14px;
    box-shadow: 0 24px 60px rgba(15, 23, 42, 0.28);
    padding: 28px 28px 24px;
    font-family: Helvetica, Arial, sans-serif;
}
.dg-modal__close {
    position: absolute;
    top: 10px;
    right: 14px;
    border: 0;
    background: transparent;
    font-size: 28px;
    line-height: 1;
    color: #9ca3af;
    cursor: pointer;
    padding: 4px 8px;
}
.dg-modal__close:hover { color: #4b5563; }
.dg-modal__title {
    font-size: 22px;
    font-weight: 700;
    color: #111827;
    margin: 0 0 8px;
    padding-right: 28px;
}
.dg-modal__subtitle {
    font-size: 14px;
    color: #6b7280;
    margin: 0 0 18px;
    line-height: 1.5;
}
.dg-modal__label {
    display: block;
    font-size: 13px;
    font-weight: 700;
    color: #374151;
    margin-bottom: 6px;
}
.dg-modal__input {
    width: 100%;
    border: 1px solid #d1d5db;
    border-radius: 8px;
    padding: 12px 14px;
    font-size: 15px;
    margin-bottom: 14px;
    outline: none;
    transition: border-color 0.15s ease, box-shadow 0.15s ease;
}
.dg-modal__input:focus {
    border-color: #2f5bea;
    box-shadow: 0 0 0 3px rgba(47, 91, 234, 0.15);
}
.dg-modal__error {
    display: none;
    font-size: 13px;
    color: #b91c1c;
    background: #fef2f2;
    border-radius: 6px;
    padding: 8px 10px;
    margin: -6px 0 12px;
}
.dg-modal__error.is-visible { display: block; }
.dg-modal__submit {
    display: block;
    width: 100%;
    border: 0;
    border-radius: 8px;
    padding: 13px 16px;
    font-size: 15px;
    font-weight: 700;
    color: #fff;
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
    cursor: pointer;
    transition: transform 0.15s ease, box-shadow 0.15s ease;
}
.dg-modal__submit:hover {
    transform: translateY(-1px);
    box-shadow: 0 8px 20px rgba(5, 150, 105, 0.3);
}
.dg-modal__submit:disabled {
    opacity: 0.7;
    cursor: wait;
    transform: none;
    box-shadow: none;
}
.dg-modal__skip {
    display: block;
    text-align: center;
    margin-top: 14px;
    font-size: 13px;
    color: #6b7280;
    background: none;
    border: 0;
    cursor: pointer;
    text-decoration: underline;
    width: 100%;
    padding: 4px;
}
.dg-modal__skip:hover { color: #374151; }
.dg-modal__note {
    margin-top: 14px;
    font-size: 12px;
    color: #9ca3af;
    text-align: center;
    line-height: 1.4;
}
.dg-modal__note a { color: #6b7280; }

/* Exit-intent variant */
.dg-modal--exit .dg-modal__dialog { max-width: 480px; }
.dg-modal__actions {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-top: 4px;
}
.dg-modal__btn {
    display: block;
    text-align: center;
    border-radius: 8px;
    padding: 13px 16px;
    font-size: 15px;
    font-weight: 700;
    text-decoration: none !important;
    transition: transform 0.15s ease, box-shadow 0.15s ease;
}
.dg-modal__btn:hover {
    transform: translateY(-1px);
}
.dg-modal__btn--primary {
    color: #fff;
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
    box-shadow: 0 4px 14px rgba(5, 150, 105, 0.25);
}
.dg-modal__btn--secondary {
    color: #1f2937;
    background: #f3f4f6;
    border: 1px solid #e5e7eb;
}
.dg-modal__btn--secondary:hover {
    background: #e5e7eb;
}
.dg-modal__trust {
    margin-top: 16px;
    font-size: 12px;
    color: #6b7280;
    text-align: center;
}
.dg-modal__trust i {
    color: #10b981;
    margin-right: 4px;
}

@media (max-width: 480px) {
    .dg-modal__dialog { padding: 24px 20px 20px; }
    .dg-modal__title { font-size: 20px; }
}
