/*
 * Contact Form 7 — Estilo do Tema Andorinha
 * Cobre todos os campos, validações e mensagens de feedback.
 * Fonte: Epilogue | Cor primária: #020873
 */

/* ============================================================
   WRAPPER GERAL
============================================================ */
.wpcf7 {
    width: 100%;
    font-family: 'Epilogue', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
}

.wpcf7-form {
    display: block;
}

/* ============================================================
   LABELS
============================================================ */
.wpcf7 label,
.wpcf7 .wpcf7-form-control-wrap + label {
    display: block;
    font-size: 13px;
    font-weight: 700;
    color: #444;
    margin-bottom: 6px;
    letter-spacing: .2px;
    font-family: 'Epilogue', sans-serif;
}

/* ============================================================
   CAMPOS DE TEXTO, EMAIL, TEL, URL, NUMBER, DATE, SEARCH
============================================================ */
.wpcf7 input[type="text"],
.wpcf7 input[type="email"],
.wpcf7 input[type="tel"],
.wpcf7 input[type="url"],
.wpcf7 input[type="number"],
.wpcf7 input[type="date"],
.wpcf7 input[type="search"],
.wpcf7 input[type="password"] {
    width: 100%;
    height: 50px;
    padding: 0 16px;
    font-size: 15px;
    font-family: 'Epilogue', sans-serif;
    color: #232323;
    background: #ffffff;
    border: 1.5px solid #d8dce4;
    border-radius: 8px;
    box-sizing: border-box;
    transition: border-color .2s, box-shadow .2s;
    outline: none;
    -webkit-appearance: none;
    appearance: none;
}

.wpcf7 input[type="text"]:focus,
.wpcf7 input[type="email"]:focus,
.wpcf7 input[type="tel"]:focus,
.wpcf7 input[type="url"]:focus,
.wpcf7 input[type="number"]:focus,
.wpcf7 input[type="date"]:focus,
.wpcf7 input[type="search"]:focus,
.wpcf7 input[type="password"]:focus {
    border-color: #020873;
    box-shadow: 0 0 0 3px rgba(2, 8, 115, .12);
}

.wpcf7 input[type="text"]::placeholder,
.wpcf7 input[type="email"]::placeholder,
.wpcf7 input[type="tel"]::placeholder,
.wpcf7 input[type="url"]::placeholder,
.wpcf7 input[type="number"]::placeholder,
.wpcf7 input[type="date"]::placeholder,
.wpcf7 input[type="search"]::placeholder {
    color: #aab0bc;
    font-size: 14px;
}

/* ============================================================
   TEXTAREA
============================================================ */
.wpcf7 textarea,
.wpcf7 .wpcf7-textarea {
    width: 100%;
    min-height: 140px;
    padding: 14px 16px;
    font-size: 15px;
    font-family: 'Epilogue', sans-serif;
    color: #232323;
    background: #ffffff;
    border: 1.5px solid #d8dce4;
    border-radius: 8px;
    box-sizing: border-box;
    resize: vertical;
    transition: border-color .2s, box-shadow .2s;
    outline: none;
    line-height: 1.6;
}

.wpcf7 textarea:focus {
    border-color: #020873;
    box-shadow: 0 0 0 3px rgba(2, 8, 115, .12);
}

.wpcf7 textarea::placeholder {
    color: #aab0bc;
    font-size: 14px;
}

/* ============================================================
   SELECT
============================================================ */
.wpcf7 select,
.wpcf7 .wpcf7-select {
    width: 100%;
    height: 50px;
    padding: 0 40px 0 16px;
    font-size: 15px;
    font-family: 'Epilogue', sans-serif;
    color: #232323;
    background: #ffffff url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24'%3E%3Cpath fill='%23888' d='M7 10l5 5 5-5z'/%3E%3C/svg%3E") no-repeat right 12px center;
    background-size: 20px;
    border: 1.5px solid #d8dce4;
    border-radius: 8px;
    box-sizing: border-box;
    -webkit-appearance: none;
    appearance: none;
    transition: border-color .2s, box-shadow .2s;
    outline: none;
    cursor: pointer;
}

.wpcf7 select:focus {
    border-color: #020873;
    box-shadow: 0 0 0 3px rgba(2, 8, 115, .12);
}

/* ============================================================
   CHECKBOX E RADIO
============================================================ */
.wpcf7 .wpcf7-checkbox,
.wpcf7 .wpcf7-radio {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.wpcf7 .wpcf7-list-item {
    display: flex;
    align-items: center;
    gap: 8px;
    margin: 0 !important;
}

.wpcf7 .wpcf7-list-item input[type="checkbox"],
.wpcf7 .wpcf7-list-item input[type="radio"] {
    width: 18px;
    height: 18px;
    min-width: 18px;
    accent-color: #020873;
    cursor: pointer;
    margin: 0;
    border-radius: 4px;
}

.wpcf7 .wpcf7-list-item-label {
    font-size: 14px;
    color: #444;
    cursor: pointer;
    font-family: 'Epilogue', sans-serif;
    line-height: 1.4;
}

/* ============================================================
   FILE UPLOAD
============================================================ */
.wpcf7 input[type="file"] {
    width: 100%;
    padding: 12px 16px;
    font-size: 14px;
    font-family: 'Epilogue', sans-serif;
    color: #555;
    background: #f8f9fc;
    border: 1.5px dashed #d8dce4;
    border-radius: 8px;
    box-sizing: border-box;
    cursor: pointer;
    transition: border-color .2s;
}

.wpcf7 input[type="file"]:hover {
    border-color: #020873;
}

/* ============================================================
   WRAPS DOS CAMPOS (para ocupar largura total)
============================================================ */
.wpcf7 .wpcf7-form-control-wrap {
    display: block;
    width: 100%;
}

/* ============================================================
   BOTÃO DE ENVIO
============================================================ */
.wpcf7 input[type="submit"],
.wpcf7 .wpcf7-submit {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 14px 36px;
    background: #020873;
    color: #ffffff !important;
    font-size: 15px;
    font-weight: 700;
    font-family: 'Epilogue', sans-serif;
    letter-spacing: .3px;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    transition: background .2s, transform .15s, box-shadow .2s;
    outline: none;
    -webkit-appearance: none;
    appearance: none;
    box-shadow: 0 4px 14px rgba(2, 8, 115, .25);
    width: 100%;
}

.wpcf7 input[type="submit"]:hover,
.wpcf7 .wpcf7-submit:hover {
    background: #030a8c;
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(2, 8, 115, .32);
}

.wpcf7 input[type="submit"]:active {
    transform: translateY(0);
}

.wpcf7 input[type="submit"]:disabled,
.wpcf7 .wpcf7-submit:disabled {
    opacity: .6;
    cursor: not-allowed;
    transform: none;
}

/* ============================================================
   SPINNER DE CARREGAMENTO
============================================================ */
.wpcf7-spinner {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 2px solid rgba(2, 8, 115, .2);
    border-top-color: #020873;
    border-radius: 50%;
    animation: andCf7Spin .7s linear infinite;
    vertical-align: middle;
    margin-left: 8px;
}

@keyframes andCf7Spin {
    to { transform: rotate(360deg); }
}

/* ============================================================
   MENSAGENS DE VALIDAÇÃO POR CAMPO
============================================================ */
.wpcf7-not-valid-tip {
    display: block;
    margin-top: 5px;
    font-size: 12px;
    font-weight: 600;
    color: #c0392b;
    font-family: 'Epilogue', sans-serif;
}

/* Campo inválido */
.wpcf7 .wpcf7-not-valid {
    border-color: #e74c3c !important;
    box-shadow: 0 0 0 3px rgba(231, 76, 60, .12) !important;
}

/* ============================================================
   MENSAGEM DE RESPOSTA GLOBAL (sucesso / erro)
============================================================ */
.wpcf7-response-output {
    margin: 18px 0 0 !important;
    padding: 14px 18px !important;
    border-radius: 8px !important;
    font-size: 14px !important;
    font-weight: 600 !important;
    font-family: 'Epilogue', sans-serif !important;
    border: none !important;
    display: block;
}

/* Enviado com sucesso */
.wpcf7-form.sent .wpcf7-response-output {
    background: #e8f8f1 !important;
    color: #1a7f4b !important;
    border-left: 4px solid #27ae60 !important;
}

/* Erro de validação */
.wpcf7-form.invalid .wpcf7-response-output,
.wpcf7-form.unaccepted .wpcf7-response-output {
    background: #fef0ee !important;
    color: #c0392b !important;
    border-left: 4px solid #e74c3c !important;
}

/* Erro de e-mail */
.wpcf7-form.failed .wpcf7-response-output {
    background: #fff8e1 !important;
    color: #7d5a00 !important;
    border-left: 4px solid #f39c12 !important;
}

/* Spam */
.wpcf7-form.spam .wpcf7-response-output {
    background: #fef0ee !important;
    color: #c0392b !important;
    border-left: 4px solid #e74c3c !important;
}

/* ============================================================
   RESPONSIVIDADE — GRIDS INTERNOS DO CF7
============================================================ */
@media (max-width: 600px) {
    .wpcf7 input[type="submit"],
    .wpcf7 .wpcf7-submit {
        width: 100%;
        text-align: center;
    }
}
