/* ==========================================================================
   mejoras.css — Mejoras visuales y correcciones frontend AVSIM
   Se carga al final de header.php. 100% reversible.
   ========================================================================== */

/* --------------------------------------------------------------------------
   1. MENÚ FLOTANTE — links visibles (eran #FCAA12 sobre fondo #FCAA12)
   -------------------------------------------------------------------------- */
#floating-menu ul li a,
#floating-menu .nav-item.nav-link {
    color: #3d2080;
    font-weight: 600;
    transition: color 0.2s ease;
}

#floating-menu ul li a:hover,
#floating-menu .nav-item.nav-link:hover {
    color: #fff;
    text-decoration: none;
}

/* Barra social — gradiente y items sociales */
.social-bar {
    background: linear-gradient(90deg, #5633C1 0%, #4026a0 100%) !important;
    display: flex !important;
    align-items: center;
    gap: 10px;
}
.social-bar a { transition: opacity 0.2s ease; }
.social-bar a:hover { opacity: 0.75; }

/* --------------------------------------------------------------------------
   2. BOTONES AFILIADOS / PRESTADORES — pill violeta con hover lift
   -------------------------------------------------------------------------- */
.btn-secondarybis {
    background-color: #5633C1 !important;
    color: #fff !important;
    border: none !important;
    border-radius: 20px !important;
    padding: 5px 16px !important;
    font-weight: 700 !important;
    letter-spacing: 0.3px;
    box-shadow: 0 2px 8px rgba(86, 51, 193, 0.3);
    transition: background-color 0.3s ease, transform 0.2s ease, box-shadow 0.2s ease !important;
}

.btn-secondarybis:hover {
    background-color: #3d2080 !important;
    color: #fff !important;
    transform: translateY(-2px);
    box-shadow: 0 4px 16px rgba(86, 51, 193, 0.45) !important;
    text-decoration: none !important;
}

/* --------------------------------------------------------------------------
   3. BLOQUES DE ACCIÓN — más profundidad y hover elegante
   -------------------------------------------------------------------------- */
.menu_bloque_item {
    border-radius: 16px !important;
    box-shadow: 0 4px 18px rgba(86, 51, 193, 0.15) !important;
    transition: transform 0.25s ease, box-shadow 0.25s ease, background-color 0.25s ease !important;
}

.menu_bloque_item:hover {
    transform: translateY(-6px) scale(1.03) !important;
    box-shadow: 0 12px 30px rgba(86, 51, 193, 0.32) !important;
    cursor: pointer;
}

/* --------------------------------------------------------------------------
   4. TÍTULOS DE SECCIÓN — decorador degradado debajo del h1
   -------------------------------------------------------------------------- */
.section-title h1.display-4 {
    position: relative;
    display: inline-block;
}

.section-title h1.display-4::after {
    content: '';
    display: block;
    width: 64px;
    height: 4px;
    background: linear-gradient(to right, #FCAA12, #5633C1);
    border-radius: 4px;
    margin: 10px auto 0;
}

/* --------------------------------------------------------------------------
   5. CARDS DE PLANES — hover translateY (más elegante que scale)
   -------------------------------------------------------------------------- */
.plan-card {
    border-radius: 16px !important;
    box-shadow: 0 2px 14px rgba(0, 0, 0, 0.08) !important;
    transition: box-shadow 0.3s ease, transform 0.3s ease !important;
}

.plan-card:hover {
    transform: translateY(-8px) !important;
    box-shadow: 0 10px 36px rgba(86, 51, 193, 0.22) !important;
}

.plan-card-title-container {
    border-radius: 12px 12px 0 0 !important;
}

/* --------------------------------------------------------------------------
   6. BOTÓN "CONOCÉ MÁS" — pill violeta visible
   -------------------------------------------------------------------------- */
.button.blanco {
    background-color: transparent !important;
    color: #5633C1 !important;
    border: 2px solid #5633C1 !important;
    border-radius: 30px !important;
    padding: 10px 28px !important;
    font-weight: 700 !important;
    letter-spacing: 0.5px;
    transition: all 0.3s ease !important;
}

.button.blanco:hover {
    background-color: #5633C1 !important;
    color: #fff !important;
    border-color: #5633C1 !important;
    transform: translateY(-2px) !important;
    box-shadow: 0 5px 16px rgba(86, 51, 193, 0.35) !important;
    text-decoration: none !important;
    opacity: 1 !important;
}

/* --------------------------------------------------------------------------
   7. QUIÉNES SOMOS — jerarquía de texto e imágenes con sombra
   -------------------------------------------------------------------------- */
.avsim-header p {
    color: #5633C1;
    font-weight: 700;
    font-size: 1.55rem;
    border-left: 5px solid #FCAA12;
    padding-left: 18px;
    line-height: 1.5;
    margin-bottom: 0;
}

.avsim-text p {
    line-height: 1.85 !important;
    border-left: 3px solid rgba(252, 170, 18, 0.4);
    padding-left: 16px;
    color: #444;
}

/* Imágenes con borde redondeado y sombra suave */
.avsim-image-left,
img.avsim-image-right {
    border-radius: 16px;
    box-shadow: 0 6px 24px rgba(86, 51, 193, 0.15);
    transition: transform 0.35s ease, box-shadow 0.35s ease;
}

.avsim-image-left:hover,
img.avsim-image-right:hover {
    transform: scale(1.04);
    box-shadow: 0 10px 32px rgba(86, 51, 193, 0.28);
}

/* --------------------------------------------------------------------------
   8. NOVEDADES — altura fija de imagen, animación entrada, hover zoom
   -------------------------------------------------------------------------- */
@keyframes fadeInUp {
    from { opacity: 0; transform: translateY(28px); }
    to   { opacity: 1; transform: translateY(0); }
}

.novedad-card                { animation: fadeInUp 0.55s ease both; }
.novedad-card:nth-child(2)   { animation-delay: 0.15s; }
.novedad-card:nth-child(3)   { animation-delay: 0.30s; }

.novedades-container .card-img-top {
    height: 220px !important;
    max-width: 100% !important;
    max-height: none !important;
    object-fit: cover;
    border-radius: 8px 8px 0 0;
    transition: transform 0.4s ease;
}

.novedad-card .card {
    overflow: hidden;
    border-radius: 10px;
    border: none;
    box-shadow: 0 3px 16px rgba(0, 0, 0, 0.09);
    transition: box-shadow 0.3s ease;
}

.novedad-card .card:hover {
    box-shadow: 0 8px 28px rgba(86, 51, 193, 0.18);
}

.novedad-card .card:hover .card-img-top {
    transform: scale(1.05);
}

/* Subtítulo Novedades — mejor contraste sobre fondo crema */
#novedades .section-title h4.text-uppercase {
    color: #5633C1 !important;
    font-weight: 600;
    font-size: 1rem;
    letter-spacing: 1.5px;
    opacity: 0.85;
}

/* --------------------------------------------------------------------------
   9. FORMULARIO CONTACTO — radio buttons pill personalizados
      (inputs dentro del label → usamos :has())
   -------------------------------------------------------------------------- */
.opciones-container label {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 7px 16px;
    border: 2px solid #FCAA12;
    border-radius: 30px;
    cursor: pointer;
    font-weight: 600 !important;
    font-size: 1rem !important;
    color: #5633C1 !important;
    margin-bottom: 8px;
    transition: all 0.22s ease;
    background: transparent;
}

.opciones-container label:hover {
    background-color: rgba(252, 170, 18, 0.12);
}

.opciones-container label:has(input[type="radio"]:checked) {
    background-color: #FCAA12;
    color: #fff !important;
    border-color: #FCAA12;
}

/* Ocultar radio nativo dentro del label */
.opciones-container label input[type="radio"] {
    width: 0;
    height: 0;
    opacity: 0;
    margin: 0;
    padding: 0;
    position: absolute;
}

/* Título "Contacto" — text-primary mapeaba a #DA9F5B (marrón) por error */
#contacto h1.text-primary {
    color: #5633C1 !important;
}

/* --------------------------------------------------------------------------
   10. BOTÓN PWA — gradiente ámbar + animación pulse
   -------------------------------------------------------------------------- */
@keyframes pulse-pwa {
    0%, 100% { box-shadow: 0 4px 16px rgba(252, 170, 18, 0.4); }
    50%       { box-shadow: 0 4px 28px rgba(252, 170, 18, 0.75); }
}

#floating-button {
    background: linear-gradient(135deg, #FCAA12, #e09800) !important;
    color: #fff !important;
    font-weight: 700 !important;
    border: none !important;
    box-shadow: 0 4px 16px rgba(252, 170, 18, 0.4);
    animation: pulse-pwa 2.2s ease-in-out infinite;
}

/* --------------------------------------------------------------------------
   11. FOOTER — hover ámbar en botones de gestión e íconos sociales
   -------------------------------------------------------------------------- */
#footer .btn-outline-light {
    border-radius: 20px !important;
    font-weight: 600;
    letter-spacing: 0.2px;
    transition: all 0.28s ease !important;
}

#footer .btn-outline-light:hover {
    background-color: #FCAA12 !important;
    border-color: #FCAA12 !important;
    color: #1a1a1a !important;
    transform: translateY(-2px);
    box-shadow: 0 4px 14px rgba(252, 170, 18, 0.35);
}

#footer .btn-lg-square:hover {
    background-color: #FCAA12;
    border-color: #FCAA12;
    transform: translateY(-2px);
    transition: all 0.25s ease;
}

/* --------------------------------------------------------------------------
   12. WHATSAPP — rebote suave, se pausa al hacer hover
   -------------------------------------------------------------------------- */
@keyframes bounce-soft {
    0%, 100% { transform: translateY(0); }
    50%       { transform: translateY(-7px); }
}

.whatsapp-button {
    animation: bounce-soft 3.2s ease-in-out infinite;
}

.whatsapp-button:hover {
    animation-play-state: paused;
}

/* --------------------------------------------------------------------------
   GENERAL — scrollbar premium (webkit)
   -------------------------------------------------------------------------- */
::-webkit-scrollbar { width: 8px; }
::-webkit-scrollbar-track { background: #f0eaf8; }
::-webkit-scrollbar-thumb {
    background: linear-gradient(180deg, #FCAA12, #5633C1);
    border-radius: 8px;
}
::-webkit-scrollbar-thumb:hover { background: #5633C1; }

/* ==========================================================================
   NUEVA SECCIÓN CONTACTO — Layout moderno dos columnas
   ========================================================================== */

.contacto-section {
    position: relative;
    background: linear-gradient(160deg, #f7f3ff 0%, #fffbf2 50%, #fff8ef 100%);
    padding: 80px 0 60px;
    overflow: hidden;
}

/* Círculo decorativo de fondo */
.contacto-section::before {
    content: '';
    position: absolute;
    top: -120px;
    right: -120px;
    width: 400px;
    height: 400px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(86,51,193,0.08) 0%, transparent 70%);
    pointer-events: none;
}

.contacto-section::after {
    content: '';
    position: absolute;
    bottom: -80px;
    left: -80px;
    width: 300px;
    height: 300px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(252,170,18,0.1) 0%, transparent 70%);
    pointer-events: none;
}

.contacto-container {
    display: flex;
    gap: 48px;
    align-items: flex-start;
    position: relative;
    z-index: 1;
}

/* ----- Panel izquierdo: INFO ----- */
.contacto-info-panel {
    flex: 0 0 320px;
    padding: 40px 32px;
    background: linear-gradient(145deg, #5633C1, #3d2080);
    border-radius: 24px;
    color: #fff;
    box-shadow: 0 16px 48px rgba(86, 51, 193, 0.35);
    position: sticky;
    top: 80px;
}

.contacto-titulo {
    font-size: 2.2rem;
    font-weight: 800;
    color: #FCAA12;
    margin-bottom: 10px;
    line-height: 1.2;
}

.contacto-bajada {
    color: rgba(255,255,255,0.82);
    font-size: 1rem;
    line-height: 1.6;
    margin-bottom: 32px;
}

.contacto-info-item {
    display: flex;
    align-items: flex-start;
    gap: 16px;
    margin-bottom: 22px;
    padding-bottom: 22px;
    border-bottom: 1px solid rgba(255,255,255,0.12);
}

.contacto-info-item:last-of-type {
    border-bottom: none;
}

.contacto-info-icon {
    width: 42px;
    height: 42px;
    background: rgba(252,170,18,0.18);
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1rem;
    color: #FCAA12;
    flex-shrink: 0;
}

.contacto-info-item strong {
    display: block;
    font-size: 0.85rem;
    color: rgba(255,255,255,0.6);
    text-transform: uppercase;
    letter-spacing: 0.8px;
    margin-bottom: 2px;
}

.contacto-info-item span {
    font-size: 0.95rem;
    color: #fff;
}

.contacto-link {
    color: #FCAA12 !important;
    text-decoration: none;
}
.contacto-link:hover { text-decoration: underline; }

.contacto-redes {
    display: flex;
    gap: 10px;
    margin-top: 28px;
    flex-wrap: wrap;
}

.contacto-red-btn {
    width: 38px;
    height: 38px;
    background: rgba(255,255,255,0.1);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-size: 0.9rem;
    transition: background 0.25s ease, transform 0.2s ease;
    text-decoration: none !important;
}

.contacto-red-btn:hover {
    background: #FCAA12;
    color: #fff !important;
    transform: translateY(-3px);
}

/* ----- Panel derecho: FORMULARIO ----- */
.contacto-form-panel {
    flex: 1;
    background: #fff;
    border-radius: 24px;
    padding: 40px 36px;
    box-shadow: 0 8px 40px rgba(86, 51, 193, 0.1);
    border: 1px solid rgba(86,51,193,0.08);
}

/* Título de campo agrupador */
.contacto-form-label-title {
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 1.2px;
    font-weight: 700;
    color: #5633C1;
    margin-bottom: 10px;
}

/* Grid de tipo de consulta (4 pills) */
.contacto-tipo-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 24px;
}

.contacto-tipo-pill {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 8px 16px;
    border: 2px solid #e4dbff;
    border-radius: 30px;
    cursor: pointer;
    font-weight: 600;
    font-size: 0.9rem !important;
    color: #5633C1 !important;
    transition: all 0.2s ease;
    background: transparent;
    user-select: none;
    margin-bottom: 0 !important;
}

.contacto-tipo-pill:hover {
    border-color: #5633C1;
    background: rgba(86,51,193,0.05);
}

.contacto-tipo-pill:has(input[type="radio"]:checked) {
    background: #5633C1;
    border-color: #5633C1;
    color: #fff !important;
    box-shadow: 0 3px 12px rgba(86,51,193,0.3);
}

.contacto-tipo-pill input[type="radio"] {
    position: absolute;
    opacity: 0;
    width: 0;
    height: 0;
}

/* Grid 2 columnas para los campos */
.contacto-fields-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
    margin-bottom: 12px;
}

/* Campo con ícono flotante */
.contacto-field {
    position: relative;
}

.contacto-field-icon {
    position: absolute;
    left: 14px;
    top: 50%;
    transform: translateY(-50%);
    color: #5633C1;
    font-size: 0.85rem;
    pointer-events: none;
    z-index: 1;
}

.contacto-input {
    width: 100%;
    padding: 12px 14px 12px 38px;
    border: 2px solid #e8e4f5;
    border-radius: 12px;
    font-size: 0.95rem;
    color: #333;
    background: #faf9ff;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
    outline: none;
    font-family: inherit;
    appearance: none;
    -webkit-appearance: none;
}

.contacto-input:focus {
    border-color: #5633C1;
    box-shadow: 0 0 0 3px rgba(86,51,193,0.12);
    background: #fff;
}

.contacto-input::placeholder { color: #aaa; }

textarea.contacto-input {
    resize: vertical;
    min-height: 110px;
    padding-top: 14px;
}

/* Servicios grid (prestador) */
.servicios-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 8px;
}

.servicios-grid input[type="checkbox"] { display: none; }

.servicios-grid label {
    padding: 7px 14px;
    border-radius: 20px;
    border: 2px solid #e4dbff;
    color: #5633C1;
    cursor: pointer;
    font-size: 0.88rem;
    background: transparent;
    transition: all 0.2s ease;
    font-weight: 600;
    user-select: none;
}

.servicios-grid label:hover { border-color: #5633C1; background: rgba(86,51,193,0.05); }

.servicios-grid input[type="checkbox"]:checked + label {
    background: #5633C1;
    border-color: #5633C1;
    color: #fff;
}

/* CAPTCHA */
.contacto-captcha {
    display: flex;
    align-items: center;
    gap: 14px;
    margin: 18px 0;
    padding: 14px 18px;
    background: #faf7ff;
    border-radius: 12px;
    border: 1px solid #e4dbff;
    flex-wrap: wrap;
}

.contacto-captcha-label {
    font-size: 0.95rem;
    font-weight: 600;
    color: #5633C1;
    flex: 1;
}

.contacto-captcha-input {
    width: 90px;
    padding: 10px 12px;
    border: 2px solid #e4dbff;
    border-radius: 10px;
    text-align: center;
    font-size: 1rem;
    font-weight: 700;
    color: #5633C1;
    background: #fff;
    outline: none;
    transition: border-color 0.2s;
}

.contacto-captcha-input:focus {
    border-color: #5633C1;
    box-shadow: 0 0 0 3px rgba(86,51,193,0.12);
}

/* Botón enviar */
.contacto-submit-btn {
    width: 100%;
    padding: 15px;
    background: linear-gradient(135deg, #5633C1, #3d2080);
    color: #fff;
    border: none;
    border-radius: 14px;
    font-size: 1.05rem;
    font-weight: 700;
    cursor: pointer;
    transition: transform 0.25s ease, box-shadow 0.25s ease;
    box-shadow: 0 6px 20px rgba(86, 51, 193, 0.35);
    letter-spacing: 0.5px;
}

.contacto-submit-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 30px rgba(86, 51, 193, 0.45);
}

.contacto-submit-btn:active { transform: translateY(0); }

/* Responsive contacto */
@media (max-width: 991px) {
    .contacto-container {
        flex-direction: column;
    }
    .contacto-info-panel {
        flex: none;
        width: 100%;
        position: static;
    }
}

@media (max-width: 600px) {
    .contacto-form-panel { padding: 28px 20px; }
    .contacto-fields-grid { grid-template-columns: 1fr; }
    .contacto-tipo-grid { justify-content: flex-start; }
}

/* ==========================================================================
   MEJORAS ADICIONALES
   ========================================================================== */

/* Smooth scroll nativo */
html { scroll-behavior: smooth; }

/* Focus visible mejorado — accesibilidad */
:focus-visible {
    outline: 3px solid #FCAA12;
    outline-offset: 3px;
    border-radius: 4px;
}

/* Sección "Quiénes Somos" — fondo alternado suave */
#avsim {
    background: linear-gradient(180deg, #fff 0%, #faf7ff 100%);
}

/* Separador decorativo entre secciones */
#planes {
    position: relative;
}
#planes::before {
    content: '';
    display: block;
    height: 4px;
    background: linear-gradient(to right, transparent, #FCAA12, #5633C1, transparent);
    margin-bottom: 24px;
}

/* CTA "Verificá cobertura" — más llamativo */
#cotizaTuPlan .p-5 {
    border-radius: 16px;
    border-left: 6px solid #FCAA12 !important;
    box-shadow: 0 4px 24px rgba(0,0,0,0.08);
}

/* Imagen del plan en el CTA — bordes redondeados */
#cotizaTuPlan .img-fluid {
    border-radius: 16px;
    box-shadow: 0 6px 24px rgba(0,0,0,0.12);
}

/* Animación reducida para usuarios con preferencia */
@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
        animation-duration: 0.01ms !important;
        transition-duration: 0.01ms !important;
    }
}
