/* =========================================================
   GYD Lead Modal - Captación de leads por WhatsApp
   GuerreroyDoncel (guerreroydoncel.com)
   Color de marca: #2775FF  |  WhatsApp: #25D366
   ========================================================= */

.gyd-lm-overlay,
.gyd-lm-overlay * {
    box-sizing: border-box;
}

.gyd-lm-overlay {
    position: fixed;
    inset: 0;
    z-index: 999999;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 16px;
    background: rgba(15, 23, 42, 0.62);
    -webkit-backdrop-filter: blur(2px);
    backdrop-filter: blur(2px);
    opacity: 0;
    transition: opacity .22s ease;
    font-family: "Montserrat", "Open Sans", Arial, sans-serif;
}

.gyd-lm-overlay.gyd-lm-open {
    display: flex;
    opacity: 1;
}

.gyd-lm-modal {
    width: 100%;
    max-width: 440px;
    max-height: 92vh;
    overflow-y: auto;
    background: #ffffff;
    border-radius: 16px;
    box-shadow: 0 24px 60px rgba(0, 0, 0, .35);
    transform: translateY(18px) scale(.98);
    transition: transform .24s ease;
    -webkit-overflow-scrolling: touch;
}

.gyd-lm-overlay.gyd-lm-open .gyd-lm-modal {
    transform: translateY(0) scale(1);
}

/* Header */
.gyd-lm-header {
    position: relative;
    padding: 22px 24px 18px;
    background: linear-gradient(135deg, #2775FF 0%, #1657c8 100%);
    color: #fff;
    border-radius: 16px 16px 0 0;
}

.gyd-lm-header h3 {
    margin: 0;
    font-size: 19px;
    line-height: 1.25;
    font-weight: 700;
    color: #fff;
    display: flex;
    align-items: center;
    gap: 9px;
}

.gyd-lm-header .gyd-lm-wa {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 28px;
    background: #25D366;
    border-radius: 50%;
    flex: 0 0 28px;
}

.gyd-lm-header .gyd-lm-wa svg { width: 17px; height: 17px; fill: #fff; }

.gyd-lm-header p {
    margin: 8px 0 0;
    font-size: 13.5px;
    line-height: 1.4;
    opacity: .92;
    font-weight: 400;
}

.gyd-lm-close {
    position: absolute;
    top: 12px;
    right: 12px;
    width: 32px;
    height: 32px;
    border: none;
    border-radius: 50%;
    background: rgba(255, 255, 255, .18);
    color: #fff;
    font-size: 20px;
    line-height: 1;
    cursor: pointer;
    transition: background .15s ease;
}

.gyd-lm-close:hover { background: rgba(255, 255, 255, .32); }

/* Body / form */
.gyd-lm-body { padding: 20px 24px 24px; }

.gyd-lm-field { margin-bottom: 14px; }

.gyd-lm-field label {
    display: block;
    margin: 0 0 6px;
    font-size: 12.5px;
    font-weight: 600;
    color: #334155;
    letter-spacing: .2px;
}

.gyd-lm-field label .gyd-lm-req { color: #e11d48; }

.gyd-lm-field input,
.gyd-lm-field select,
.gyd-lm-field textarea {
    width: 100%;
    padding: 11px 13px;
    font-size: 14.5px;
    font-family: inherit;
    color: #0f172a;
    background: #f8fafc;
    border: 1.5px solid #e2e8f0;
    border-radius: 10px;
    outline: none;
    transition: border-color .15s ease, background .15s ease;
    appearance: none;
}

.gyd-lm-field select {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath fill='%2364748b' d='M6 8 0 0h12z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 14px center;
    padding-right: 34px;
    cursor: pointer;
}

.gyd-lm-field textarea { min-height: 74px; resize: vertical; }

.gyd-lm-field input:focus,
.gyd-lm-field select:focus,
.gyd-lm-field textarea:focus {
    border-color: #2775FF;
    background: #fff;
}

/* Honeypot - oculto para humanos, visible para bots */
.gyd-lm-hp {
    position: absolute !important;
    left: -9999px !important;
    top: -9999px !important;
    width: 1px;
    height: 1px;
    opacity: 0;
    overflow: hidden;
}

/* Submit */
.gyd-lm-submit {
    width: 100%;
    margin-top: 6px;
    padding: 13px 16px;
    font-size: 15.5px;
    font-weight: 700;
    font-family: inherit;
    color: #fff;
    background: #25D366;
    border: none;
    border-radius: 10px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 9px;
    transition: background .15s ease, transform .05s ease;
}

.gyd-lm-submit svg { width: 19px; height: 19px; fill: #fff; }
.gyd-lm-submit:hover { background: #1ebe5a; }
.gyd-lm-submit:active { transform: scale(.99); }
.gyd-lm-submit:disabled { opacity: .7; cursor: default; }

.gyd-lm-note {
    margin: 12px 0 0;
    font-size: 11.5px;
    line-height: 1.45;
    color: #94a3b8;
    text-align: center;
}

.gyd-lm-error {
    display: none;
    margin: 0 0 12px;
    padding: 9px 12px;
    font-size: 13px;
    color: #b91c1c;
    background: #fef2f2;
    border: 1px solid #fecaca;
    border-radius: 8px;
}

.gyd-lm-error.gyd-lm-show { display: block; }

@media (max-width: 480px) {
    .gyd-lm-modal { max-width: 100%; border-radius: 14px; }
    .gyd-lm-header h3 { font-size: 17.5px; }
}

/* =========================================================
   Botón flotante de WhatsApp (dispara el modal GYD)
   Reemplaza el widget del plugin whatsapp-chat-support.
   ========================================================= */
.gyd-wa-float {
    position: fixed;
    bottom: 12px;
    right: 20px;
    z-index: 9998;
    display: flex;
    align-items: center;
    gap: 10px;
    text-decoration: none;
    cursor: pointer;
}

.gyd-wa-float__label {
    background: #ffffff;
    color: #0f172a;
    font-family: "Montserrat", "Open Sans", Arial, sans-serif;
    font-size: 13px;
    font-weight: 600;
    line-height: 1.2;
    padding: 9px 13px;
    border-radius: 22px;
    box-shadow: 0 6px 18px rgba(0, 0, 0, .18);
    white-space: nowrap;
    opacity: 0;
    transform: translateX(10px);
    transition: opacity .25s ease, transform .25s ease;
    pointer-events: none;
}

.gyd-wa-float:hover .gyd-wa-float__label {
    opacity: 1;
    transform: translateX(0);
}

.gyd-wa-float__btn {
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 60px;
    height: 60px;
    background: #25D366;
    border-radius: 50%;
    box-shadow: 0 6px 20px rgba(37, 211, 102, .45);
    transition: transform .15s ease, background .15s ease;
}

.gyd-wa-float__btn svg { width: 34px; height: 34px; fill: #fff; }
.gyd-wa-float:hover .gyd-wa-float__btn { transform: scale(1.06); background: #1ebe5a; }

/* Pulso */
.gyd-wa-float__btn::after {
    content: "";
    position: absolute;
    inset: 0;
    border-radius: 50%;
    box-shadow: 0 0 0 0 rgba(37, 211, 102, .55);
    animation: gyd-wa-pulse 2.2s infinite;
}

@keyframes gyd-wa-pulse {
    0%   { box-shadow: 0 0 0 0 rgba(37, 211, 102, .55); }
    70%  { box-shadow: 0 0 0 16px rgba(37, 211, 102, 0); }
    100% { box-shadow: 0 0 0 0 rgba(37, 211, 102, 0); }
}

@media (max-width: 480px) {
    .gyd-wa-float__btn { width: 54px; height: 54px; }
    .gyd-wa-float__btn svg { width: 30px; height: 30px; }
    .gyd-wa-float__label { display: none; }
}

@media (prefers-reduced-motion: reduce) {
    .gyd-wa-float__btn::after { animation: none; }
}

/* =========================================================
   Desplegable propio de "Servicio" (reemplaza el <select>
   nativo para evitar que el CSS de la plantilla lo deforme)
   ========================================================= */
.gyd-lm-select { position: relative; width: 100%; }

.gyd-lm-select__btn {
    width: 100% !important;
    display: flex !important;
    align-items: center;
    justify-content: space-between;
    text-align: left;
    margin: 0 !important;
    padding: 11px 13px !important;
    font-size: 14.5px !important;
    font-family: inherit !important;
    font-weight: 400 !important;
    line-height: 1.3 !important;
    color: #0f172a !important;
    background: #f8fafc !important;
    border: 1.5px solid #e2e8f0 !important;
    border-radius: 10px !important;
    box-shadow: none !important;
    text-transform: none !important;
    letter-spacing: normal !important;
    cursor: pointer;
    -webkit-appearance: none;
    appearance: none;
}

.gyd-lm-select__btn:focus { outline: none; border-color: #2775FF !important; background: #fff !important; }

.gyd-lm-select__value { flex: 1 1 auto; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.gyd-lm-select__value.gyd-lm-placeholder { color: #94a3b8; }

.gyd-lm-select__arrow {
    flex: 0 0 auto;
    width: 0; height: 0;
    margin-left: 10px;
    border-left: 5px solid transparent;
    border-right: 5px solid transparent;
    border-top: 6px solid #64748b;
    transition: transform .15s ease;
}
.gyd-lm-select--open .gyd-lm-select__arrow { transform: rotate(180deg); }

.gyd-lm-select__list {
    display: none;
    position: absolute;
    left: 0; right: 0; top: calc(100% + 6px);
    z-index: 30;
    max-height: 220px;
    overflow-y: auto;
    margin: 0 !important;
    padding: 6px !important;
    list-style: none !important;
    background: #ffffff;
    border: 1.5px solid #e2e8f0;
    border-radius: 10px;
    box-shadow: 0 14px 34px rgba(0, 0, 0, .18);
    -webkit-overflow-scrolling: touch;
}
.gyd-lm-select--open .gyd-lm-select__list { display: block; }

.gyd-lm-select__list li.gyd-lm-opt {
    list-style: none !important;
    margin: 0 !important;
    padding: 9px 11px !important;
    font-size: 14px !important;
    line-height: 1.3 !important;
    color: #0f172a !important;
    background: transparent !important;
    border-radius: 7px;
    cursor: pointer;
}
.gyd-lm-select__list li.gyd-lm-opt:hover,
.gyd-lm-select__list li.gyd-lm-opt--sel {
    background: #eef4ff !important;
    color: #1657c8 !important;
}
.gyd-lm-select__list li.gyd-lm-opt::before { content: none !important; }
