/* Pangoleads 3 Modal Styles */

.pango-modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 99999;
    display: flex;
    align-items: center;
    justify-content: center;
    visibility: hidden;
    opacity: 0;
    transition: opacity 0.3s ease, visibility 0.3s ease;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}

.pango-modal.pango-modal-open {
    visibility: visible;
    opacity: 1;
}

.pango-modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(0, 0, 0, 0.5);
    z-index: -1;
}

.pango-modal-content {
    background: white;
    border-radius: 8px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.15);
    max-width: 500px;
    width: 90%;
    max-height: 90vh;
    overflow-y: auto;
    position: relative;
    animation: pango-slide-up 0.3s ease;
    z-index: 1;
}

@keyframes pango-slide-up {
    from {
        transform: translateY(30px);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

.pango-modal-close {
    position: absolute;
    top: 12px;
    right: 12px;
    width: 32px;
    height: 32px;
    padding: 0;
    border: none;
    background: transparent;
    color: #666;
    font-size: 28px;
    cursor: pointer;
    line-height: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: color 0.2s ease;
    z-index: 10;
}

.pango-modal-close:hover {
    color: #333;
}

.pango-modal-inner {
    padding: 32px;
}

.pango-modal-title {
    margin: 0 0 8px 0;
    font-size: 20px;
    font-weight: 600;
    color: #1d2327;
    line-height: 1.3;
}

.pango-modal-subtitle {
    margin: 0 0 16px 0;
    font-size: 14px;
    color: #646970;
    line-height: 1.4;
}

.pango-modal-description {
    margin: 0 0 20px 0;
    font-size: 14px;
    color: #50575e;
    line-height: 1.5;
}

.pango-modal-form {
    margin-top: 20px;
}

/* Integração com formulário */
.pango-modal-form .pangoleads-form {
    margin: 0;
}

.pango-modal-form .pangoleads-form p {
    margin: 12px 0;
}

.pango-modal-form .pangoleads-form p:last-child {
    margin-bottom: 0;
}

.pango-modal-form .pangoleads-form label {
    display: block;
    margin-bottom: 6px;
    font-size: 13px;
    font-weight: 500;
    color: #1d2327;
}

.pango-modal-form .pangoleads-form input[type="text"],
.pango-modal-form .pangoleads-form input[type="email"],
.pango-modal-form .pangoleads-form input[type="tel"],
.pango-modal-form .pangoleads-form textarea,
.pango-modal-form .pangoleads-form select {
    width: 100%;
    padding: 8px 12px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 14px;
    line-height: 1.4;
    box-sizing: border-box;
}

.pango-modal-form .pangoleads-form input[type="text"]:focus,
.pango-modal-form .pangoleads-form input[type="email"]:focus,
.pango-modal-form .pangoleads-form input[type="tel"]:focus,
.pango-modal-form .pangoleads-form textarea:focus,
.pango-modal-form .pangoleads-form select:focus {
    outline: none;
    border-color: #0073aa;
    box-shadow: 0 0 0 2px rgba(0, 115, 170, 0.1);
}

.pango-modal-form .pangoleads-form textarea {
    resize: vertical;
    min-height: 80px;
}

.pango-modal-form .pangoleads-form button {
    background-color: #0073aa;
    border: 1px solid #005a87;
    color: white;
    padding: 10px 16px;
    border-radius: 4px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: background-color 0.2s ease;
    width: 100%;
    box-sizing: border-box;
}

.pango-modal-form .pangoleads-form button:hover {
    background-color: #005a87;
}

.pango-modal-form .pangoleads-form button:active {
    background-color: #003d5c;
}

/* Mensagens de erro/sucesso */
.pango-modal-form .pango-form-messages {
    margin-bottom: 16px;
}

.pango-modal-form .pango-form-message {
    padding: 12px;
    border-radius: 4px;
    font-size: 13px;
    line-height: 1.4;
    margin-bottom: 12px;
}

.pango-modal-form .pango-form-message.pango-msg-error {
    background-color: #fee;
    border: 1px solid #fcc;
    color: #c33;
}

.pango-modal-form .pango-form-message.pango-msg-success {
    background-color: #efe;
    border: 1px solid #cfc;
    color: #3c3;
}

/* Responsive */
@media (max-width: 600px) {
    .pango-modal-content {
        width: 95%;
        max-height: 95vh;
    }

    .pango-modal-inner {
        padding: 24px;
    }

    .pango-modal-title {
        font-size: 18px;
    }

    .pango-modal-close {
        width: 28px;
        height: 28px;
        top: 8px;
        right: 8px;
        font-size: 24px;
    }
}

/* Garantir que o modal fica acima de outros elementos */
.pango-modal {
    z-index: 999999;
}

.pango-modal-overlay {
    z-index: 999998;
}
