/* =============================================
   ZIP / State Modal
   ============================================= */

.zip-modal {
    display: none;
    position: fixed;
    z-index: 999999;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.6);
}

.zip-modal__dialog {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 100vh;
    padding: 20px;
}

.zip-modal__content {
    background-color: #fff;
    width: 90%;
    max-width: 500px;
    position: relative;
    border-radius: 10px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.25);
    animation: zipModalSlideIn 0.3s ease;
}

@keyframes zipModalSlideIn {
    from {
        opacity: 0;
        transform: translateY(-20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* --- Header --- */
.zip-modal__header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 20px 24px 16px;
    border-bottom: 1px solid #ddd;
}

.zip-modal__title {
    margin: 0;
    font-size: 22px;
    font-weight: 700;
    color: #333;
}

.zip-modal__close {
    background: transparent;
    border: none;
    font-size: 32px;
    line-height: 1;
    cursor: pointer;
    color: #666;
    padding: 0 4px;
    transition: color 0.2s;
}

.zip-modal__close:hover {
    color: #f03337;
}

/* --- Body --- */
.zip-modal__body {
    padding: 24px;
}

.zip-modal__body > p {
    margin: 0 0 20px;
    font-size: 15px;
    color: #555;
    line-height: 1.5;
}

/* --- Form fields --- */
.zip-modal__field {
    margin-bottom: 18px;
}

.zip-modal__field label {
    display: block;
    font-size: 14px;
    font-weight: 600;
    color: #333;
    margin-bottom: 6px;
}

.zip-modal__field input {
    width: 100%;
    padding: 12px 14px;
    font-size: 16px;
    border: 1px solid #ccc;
    border-radius: 6px;
    background: #fafafa;
    transition: border-color 0.2s, box-shadow 0.2s;
    box-sizing: border-box;
}

.zip-modal__field input:focus {
    outline: none;
    border-color: #3754a4;
    box-shadow: 0 0 0 3px rgba(55, 84, 164, 0.15);
    background: #fff;
}

/* --- Submit button --- */
.zip-modal__actions {
    margin-top: 24px;
}

.zip-modal__submit {
    display: block;
    width: 100%;
    padding: 14px 20px;
    font-size: 18px;
    font-weight: 700;
    color: #fff;
    background-color: #f03337;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    transition: background-color 0.3s;
}

.zip-modal__submit:hover {
    background-color: #3754a4;
}

.zip-modal__submit:disabled {
    opacity: 0.7;
    cursor: not-allowed;
}

/* --- Message area --- */
.zip-modal__message {
    margin-top: 16px;
    padding: 10px 14px;
    border-radius: 6px;
    font-size: 14px;
    line-height: 1.4;
}

.zip-modal__message--error {
    background-color: #fef2f2;
    color: #c0392b;
    border: 1px solid #f5c6cb;
}

.zip-modal__message--info {
    background-color: #ebf5fb;
    color: #2471a3;
    border: 1px solid #aed6f1;
}

/* --- [zip-modal-cta] trigger button ---
   Matches the Divi et_pb_button in the hero section
   (bg #F03337, white text, bold, FA right-arrow icon).
   Applied when the shortcode is placed in a Divi Code module. */

button.cta-zip-modal-trigger {
    background-color: #f03337 !important;
    color: #fff !important;
    border: 0 !important;
    border-radius: 3px;
    font-size: 20px;
    font-weight: 700;
    padding: 0.3em 1em;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
    display: inline-block;
}

button.cta-zip-modal-trigger::after {
    font-family: "Font Awesome 5 Free";
    content: "\f105";
    font-weight: 900;
    margin-left: 0.3em;
    display: inline-block;
    transition: all 0.3s ease;
}

button.cta-zip-modal-trigger:hover {
    background-color: rgba(240, 51, 55, 0.8) !important;
    color: #fff !important;
}

button.cta-zip-modal-trigger:hover::after {
    margin-left: 0.5em;
}

/* --- Google autocomplete dropdown z-index fix --- */
.pac-container {
    z-index: 1000000 !important;
}

/* --- Responsive --- */
@media (max-width: 480px) {
    .zip-modal__content {
        width: 95%;
    }

    .zip-modal__body {
        padding: 18px 16px;
    }

    .zip-modal__title {
        font-size: 18px;
    }

    .zip-modal__submit {
        font-size: 16px;
        padding: 12px 16px;
    }
}
