/* AMCO Contact + Map – contact-map.css v1.2.0 */

/* ── Two-column wrapper ────────────────────────────────────── */
.r4d-cm-wrapper {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 24px;
    align-items: stretch;
    width: 100%;
    box-sizing: border-box;
}

/* ═══════════════════════════════════════════════════════════ */
/* MAP PANEL                                                    */
/* ═══════════════════════════════════════════════════════════ */
.r4d-cm-map-wrap {
    position: relative;
    border-radius: 20px;
    overflow: hidden;
    min-height: 500px;
    background: #e5e7eb;
}

.r4d-cm-map-embed {
    width: 100%;
    height: 500px;
    border: none;
    display: block;
}

/* ── Location card overlay ────────────────────────────────── */
.r4d-cm-loc-card {
    position: absolute;
    bottom: 24px;
    left: 24px;
    right: 24px;
    background: #ffffff;
    border-radius: 16px;
    padding: 20px 22px;
    box-shadow: 0 4px 24px rgba(0, 0, 0, 0.12);
    display: flex;
    flex-direction: column;
    gap: 5px;
    animation: r4d-slide-up 0.5s cubic-bezier(0.22, 1, 0.36, 1) 0.2s both;
}

@keyframes r4d-slide-up {
    from { opacity: 0; transform: translateY(14px); }
    to   { opacity: 1; transform: translateY(0); }
}

.r4d-cm-loc-header {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 4px;
}

.r4d-cm-loc-icon {
    color: #4CAF50;
    display: flex;
    align-items: center;
    flex-shrink: 0;
}

.r4d-cm-loc-title {
    font-size: 15px;
    font-weight: 700;
    color: #111827;
}

.r4d-cm-loc-addr {
    font-size: 13.5px;
    color: #6B7280;
    margin: 0;
    line-height: 1.5;
    padding-left: 26px;
}

.r4d-cm-phone-link {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 13.5px;
    font-weight: 600;
    color: #4CAF50;
    text-decoration: none;
    padding-left: 26px;
    margin-top: 2px;
    transition: opacity 0.2s ease;
}
.r4d-cm-phone-link:hover { opacity: 0.75; }

/* ═══════════════════════════════════════════════════════════ */
/* FORM PANEL                                                   */
/* ═══════════════════════════════════════════════════════════ */
.r4d-cm-form-wrap {
    background: #ffffff;
    border-radius: 20px;
    padding: 44px 40px;
    box-shadow: 0 4px 32px rgba(0, 0, 0, 0.07);
    display: flex;
    flex-direction: column;
    justify-content: center;
    box-sizing: border-box;
}

.r4d-cm-form-title {
    font-size: 34px;
    font-weight: 800;
    color: #111827;
    line-height: 1.15;
    margin: 0 0 14px;
}

.r4d-cm-form-subtitle {
    font-size: 15px;
    color: #6B7280;
    line-height: 1.65;
    margin: 0 0 28px;
}

/* ── CF7 wrapper reset ────────────────────────────────────── */
.r4d-cm-cf7-wrap .wpcf7 {
    margin: 0;
    padding: 0;
}

/* ═══════════════════════════════════════════════════════════ */
/* CF7 CUSTOM STRUCTURE: .cf7-form / .cf7-row / .cf7-col       */
/* ═══════════════════════════════════════════════════════════ */

.r4d-cm-cf7-wrap .cf7-form {
    display: flex;
    flex-direction: column;
    gap: 0;
    width: 100%;
}

/* Each row */
.r4d-cm-cf7-wrap .cf7-row {
    display: flex;
    flex-direction: column;
    margin-bottom: 18px;
    width: 100%;
}

.r4d-cm-cf7-wrap .cf7-row:last-child {
    margin-bottom: 0;
}

/* Two-column row */
.r4d-cm-cf7-wrap .cf7-row-2cols {
    flex-direction: row;
    gap: 14px;
}

.r4d-cm-cf7-wrap .cf7-col {
    display: flex;
    flex-direction: column;
    flex: 1;
    min-width: 0;
}

/* ── Labels ───────────────────────────────────────────────── */
.r4d-cm-cf7-wrap .cf7-form label,
.r4d-cm-cf7-wrap .cf7-col label,
.r4d-cm-cf7-wrap .cf7-row > label {
    display: block;
    font-size: 10.5px;
    font-weight: 700;
    letter-spacing: 0.09em;
    text-transform: uppercase;
    color: #6B7280;
    margin-bottom: 7px;
    line-height: 1;
}

/* ── CF7 span wrappers (wpcf7-form-control-wrap) ─────────── */
.r4d-cm-cf7-wrap .wpcf7-form-control-wrap {
    display: block;
    width: 100%;
}

/* ── Inputs, textarea, select ─────────────────────────────── */
.r4d-cm-cf7-wrap input[type="text"],
.r4d-cm-cf7-wrap input[type="email"],
.r4d-cm-cf7-wrap input[type="tel"],
.r4d-cm-cf7-wrap input[type="number"],
.r4d-cm-cf7-wrap input[type="url"],
.r4d-cm-cf7-wrap textarea,
.r4d-cm-cf7-wrap select {
    width: 100%;
    box-sizing: border-box;
    border: 1.5px solid #E5E7EB;
    border-radius: 10px;
    padding: 12px 16px;
    font-size: 14px;
    color: #111827;
    background: #ffffff;
    outline: none;
    font-family: inherit;
    transition: border-color 0.22s ease, box-shadow 0.22s ease;
    appearance: none;
    -webkit-appearance: none;
}

.r4d-cm-cf7-wrap input::placeholder,
.r4d-cm-cf7-wrap textarea::placeholder {
    color: #9CA3AF;
}

.r4d-cm-cf7-wrap input:focus,
.r4d-cm-cf7-wrap textarea:focus,
.r4d-cm-cf7-wrap select:focus {
    border-color: #4CAF50;
    box-shadow: 0 0 0 3px rgba(76, 175, 80, 0.13);
}

/* ── Select custom arrow ──────────────────────────────────── */
.r4d-cm-cf7-wrap select {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%236B7280' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 14px center;
    padding-right: 40px;
    cursor: pointer;
}

/* ── Submit button ────────────────────────────────────────── */
.r4d-cm-cf7-wrap input[type="submit"] {
    width: 100%;
    background-color: #4CAF50;
    color: #ffffff !important;
    font-size: 15px;
    font-weight: 700;
    border: none !important;
    border-radius: 10px;
    padding: 15px 24px;
    cursor: pointer;
    transition: background-color 0.22s ease, transform 0.18s ease, box-shadow 0.22s ease;
    box-sizing: border-box;
    letter-spacing: 0.01em;
    font-family: inherit;
    box-shadow: none;
}

.r4d-cm-cf7-wrap input[type="submit"]:hover {
    background-color: #43a047;
    transform: translateY(-1px);
    box-shadow: 0 6px 20px rgba(76, 175, 80, 0.30);
}

.r4d-cm-cf7-wrap input[type="submit"]:active {
    transform: translateY(0);
    box-shadow: none;
}

/* ── Validation & response messages ──────────────────────── */
.r4d-cm-cf7-wrap .wpcf7-not-valid-tip {
    font-size: 11.5px;
    color: #ef4444;
    margin-top: 4px;
    display: block;
}

.r4d-cm-cf7-wrap .wpcf7-response-output {
    border-radius: 8px !important;
    padding: 10px 14px !important;
    font-size: 13px !important;
    margin-top: 12px !important;
    border: none !important;
}

.r4d-cm-cf7-wrap .wpcf7-mail-sent-ok {
    background: #f0fdf4 !important;
    color: #16a34a !important;
}

.r4d-cm-cf7-wrap .wpcf7-mail-sent-ng,
.r4d-cm-cf7-wrap .wpcf7-spam-blocked {
    background: #fef2f2 !important;
    color: #dc2626 !important;
}

/* ── Remove default CF7 <p> spacing ──────────────────────── */
.r4d-cm-cf7-wrap .wpcf7-form > p {
    margin: 0;
}

.r4d-cm-cf7-wrap .wpcf7-form br {
    display: none;
}

/* ── Spinner ──────────────────────────────────────────────── */
.r4d-cm-cf7-wrap .wpcf7-spinner {
    margin-left: 8px;
    vertical-align: middle;
}

/* ═══════════════════════════════════════════════════════════ */
/* RESPONSIVE                                                   */
/* ═══════════════════════════════════════════════════════════ */
@media (max-width: 900px) {
    .r4d-cm-wrapper {
        grid-template-columns: 1fr;
    }

    .r4d-cm-map-wrap {
        min-height: 360px;
    }

    .r4d-cm-map-embed {
        height: 360px;
    }

    .r4d-cm-form-wrap {
        padding: 32px 28px;
    }

    .r4d-cm-form-title {
        font-size: 26px;
    }
}

@media (max-width: 540px) {
    .r4d-cm-cf7-wrap .cf7-row-2cols {
        flex-direction: column;
        gap: 18px;
    }

    .r4d-cm-form-wrap {
        padding: 24px 20px;
    }

    .r4d-cm-loc-card {
        left: 12px;
        right: 12px;
        bottom: 12px;
    }
}
