/* ==========================================================
   FARMACOVIGILANCIA.CSS
   Torrent Pharma México — Página de Farmacovigilancia
   Depende de: general.css
   ========================================================== */


.qs-hero__title {
    font-size: 1.8rem;
}

/* ----------------------------------------------------------
   MODAL — Tooltip de Lote / Caducidad
   ---------------------------------------------------------- */

.fv-modal {
    display: none;
    position: fixed;
    inset: 0;
    z-index: 9999;
    align-items: center;
    justify-content: center;
}

.fv-modal--open {
    display: flex;
}

.fv-modal__backdrop {
    position: absolute;
    inset: 0;
    background: rgba(18, 17, 58, 0.65);
    backdrop-filter: blur(3px);
    cursor: pointer;
}

.fv-modal__box {
    position: relative;
    z-index: 1;
    background: transparent;
    border-radius: var(--radius-lg);
    max-width: 90vw;
    max-height: 90vh;
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 10px;
    animation: fvModalIn 0.25s ease;
}

@keyframes fvModalIn {
    from { opacity: 0; transform: scale(0.94); }
    to   { opacity: 1; transform: scale(1); }
}

.fv-modal__close {
    background: var(--color-white);
    color: var(--color-primary);
    border: none;
    border-radius: 50%;
    width: 36px;
    height: 36px;
    font-size: 1rem;
    font-weight: 700;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    transition: var(--transition-smooth);
    box-shadow: 0 2px 8px rgba(0,0,0,0.25);
}

.fv-modal__close:hover {
    background: var(--color-primary);
    color: var(--color-white);
}

.fv-modal__img {
    border-radius: var(--radius-md);
    max-width: min(680px, 88vw);
    max-height: 80vh;
    object-fit: contain;
    display: block;
    box-shadow: 0 12px 40px rgba(0,0,0,0.4);
}


/* ----------------------------------------------------------
   INTRO
   ---------------------------------------------------------- */

.fv-intro {
    background-color: var(--color-white);
    padding-bottom: 30px;
}

.fv-intro__text {
    font-size: 0.92rem;
    color: var(--color-text-dark);
    line-height: 1.85;
    margin-bottom: 18px;
}

.fv-intro__text:last-of-type {
    margin-bottom: 24px;
}

.fv-intro__contact-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
    padding-left: 0;
    list-style: none;
}

.fv-intro__contact-item {
    font-size: 0.92rem;
    color: var(--color-text-dark);
    line-height: 1.6;
}

.fv-intro__contact-item a {
    color: var(--color-primary);
    text-decoration: underline;
}

.fv-intro__contact-item a:hover {
    color: var(--color-lila);
}


/* ----------------------------------------------------------
   SECCIÓN FORMULARIO
   ---------------------------------------------------------- */

.fv-form-section {
    background-color: var(--color-blue-light);
    padding-top: 50px;
    padding-bottom: 60px;
}

.fv-form-section__title {
    font-size: 1.4rem;
    font-weight: 700;
    color: var(--color-primary);
    margin-bottom: 10px;
    line-height: 1.3;
}

.fv-form-section__subtitle {
    font-size: 0.9rem;
    color: var(--color-text-dark);
    margin-bottom: 32px;
}


/* ----------------------------------------------------------
   FORMULARIO
   ---------------------------------------------------------- */

.fv-form {
    display: flex;
    flex-direction: column;
    gap: 0;
}


/* ── Bloques (fieldsets) ── */

.fv-block {
    border: none;
    background-color: var(--color-white);
    padding: 28px 24px;
    margin-bottom: 2px;
}

.fv-block:first-of-type {
    border-radius: var(--radius-lg) var(--radius-lg) 0 0;
}

.fv-block:last-of-type {
    border-radius: 0 0 var(--radius-lg) var(--radius-lg);
    margin-bottom: 0;
}

.fv-block__legend {
    font-size: 0.7rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--color-primary);
    background-color: var(--color-blue-light);
    padding: 6px 14px;
    border-radius: var(--radius-sm);
    margin-bottom: 22px;
    display: block;
    width: 100%;
}

.fv-block__note {
    font-size: 0.85rem;
    color: var(--color-text-dark);
    margin-bottom: 20px;
    line-height: 1.6;
}


/* ── Grids internos ── */

.fv-grid {
    display: grid;
    gap: 16px 20px;
    grid-template-columns: 1fr;
}

.fv-mt { margin-top: 20px; }
.fv-mb { margin-bottom: 20px; }

/* Span helpers */
.fv-field--span2 { grid-column: span 1; }
.fv-field--span1 { grid-column: span 1; }


/* ── Campos ── */

.fv-field {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.fv-label {
    font-size: 0.78rem;
    font-weight: 600;
    color: var(--color-text-dark);
    line-height: 1.4;
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 4px;
}

.fv-label-hint {
    font-size: 0.7rem;
    font-weight: 400;
    color: var(--color-gray-medium);
    font-style: italic;
}

.fv-input {
    width: 100%;
    padding: 10px 14px;
    font-family: inherit;
    font-size: 0.88rem;
    color: var(--color-text-dark);
    background-color: var(--color-white);
    border: 1px solid var(--color-gray-light);
    border-radius: var(--radius-sm);
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
    outline: none;
    appearance: none;
}

.fv-input::placeholder {
    color: var(--color-gray-medium);
    font-size: 0.82rem;
}

.fv-input:focus {
    border-color: var(--color-lila);
    box-shadow: 0 0 0 3px rgba(146, 131, 190, 0.18);
}

.fv-select {
    cursor: pointer;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 16 16'%3E%3Cpath fill='%23949494' d='M7.247 11.14L2.451 5.658C1.885 5.013 2.345 4 3.204 4h9.592a1 1 0 0 1 .753 1.659l-4.796 5.48a1 1 0 0 1-1.506 0z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 14px center;
    padding-right: 36px;
}

.fv-textarea {
    resize: vertical;
    min-height: 120px;
    line-height: 1.6;
}


/* ── Botón tooltip ? ── */

.fv-tooltip-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background-color: var(--color-lila);
    border: none;
    cursor: pointer;
    padding: 0;
    flex-shrink: 0;
    transition: background-color 0.2s ease;
    vertical-align: middle;
}

.fv-tooltip-btn:hover {
    background-color: var(--color-primary);
}

.fv-tooltip-icon {
    color: var(--color-white);
    font-size: 0.65rem;
    font-weight: 800;
    line-height: 1;
    font-style: normal;
    pointer-events: none;
}


/* ── Radio buttons ── */

.fv-radio-group {
    display: flex;
    flex-direction: column;
    gap: 10px;
    padding: 10px 14px;
    border: 1px solid var(--color-gray-light);
    border-radius: var(--radius-sm);
    background-color: var(--color-white);
}

.fv-radio-group--inline {
    flex-direction: row;
    gap: 24px;
}

.fv-radio-label {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.85rem;
    color: var(--color-text-dark);
    cursor: pointer;
}

.fv-radio-label input[type="radio"] {
    accent-color: var(--color-primary);
    width: 16px;
    height: 16px;
    cursor: pointer;
    flex-shrink: 0;
}


/* ── Pie del formulario ── */

.fv-form__footer {
    background-color: var(--color-white);
    border-top: 2px solid var(--color-blue-light);
    border-radius: 0 0 var(--radius-lg) var(--radius-lg);
    padding: 28px 24px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 20px;
}

.fv-check-label {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 0.88rem;
    color: var(--color-text-dark);
    cursor: pointer;
}

.fv-check-label input[type="checkbox"] {
    accent-color: var(--color-primary);
    width: 16px;
    height: 16px;
    cursor: pointer;
    flex-shrink: 0;
}

.fv-check-label a {
    color: var(--color-primary);
    text-decoration: underline;
}

.fv-check-label a:hover {
    color: var(--color-lila);
}

.fv-submit-btn,  .wpcf7-submit{
    background-color: var(--color-primary);
    color: var(--color-white);
    font-family: inherit;
    font-size: 0.95rem;
    font-weight: 700;
    padding: 14px 40px;
    border: none;
    border-radius: var(--radius-md);
    cursor: pointer;
    transition: var(--transition-smooth);
    letter-spacing: 0.02em;
    margin-left:20px;
}

.fv-submit-btn:hover {
    background-color: var(--color-lila);
    transform: translateY(-2px);
    box-shadow: 0 6px 18px rgba(146, 131, 190, 0.4);
}

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

/* Alineación de etiqueta e icono */
.cf7-field-group label {
  display: flex;
  align-items: center;
  gap: 6px;
  font-weight: 600;
  font-size: 15px;
}

.field-subtitle {
  font-weight: normal;
  font-style: italic;
  color: #777;
  font-size: 13px;
}

/* Botón con signo de interrogación */
.info-modal-trigger {
  background-color: #8a73b9; /* Color morado como en la captura */
  color: #ffffff;
  border: none;
  border-radius: 50%;
  width: 20px;
  height: 20px;
  font-size: 12px;
  font-weight: bold;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  line-height: 1;
  transition: background-color 0.2s ease;
}

.info-modal-trigger:hover {
  background-color: #6c549c;
}

/* Fondo oscuro del Modal */
.cf7-modal-overlay {
  display: none; /* Oculto por defecto */
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(30, 35, 60, 0.75); /* Oscurecido translúcido */
  z-index: 99999;
  justify-content: center;
  align-items: center;
  padding: 20px;
}

.cf7-modal-overlay.is-active {
  display: flex;
}

/* Caja de contenido del Modal */
.cf7-modal-content {
  position: relative;
  background-color: #233182; /* Fondo azul oscuro como en tu captura */
  padding: 30px 20px 20px;
  border-radius: 8px;
  max-width: 600px;
  width: 100%;
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.3);
}

/* Botón de Cierre (X) */
.cf7-modal-close {
  position: absolute;
  top: -15px;
  right: -15px;
  background: #ffffff;
  color: #233182;
  border: 2px solid #233182;
  border-radius: 50%;
  width: 32px;
  height: 32px;
  font-size: 20px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 2px 8px rgba(0,0,0,0.2);
}

.cf7-modal-body img {
  width: 100%;
  height: auto;
  display: block;
}


/* ----------------------------------------------------------
   REFERENCIAS
   ---------------------------------------------------------- */

.fv-refs {
    background-color: var(--color-white);
}

.fv-refs__title {
    font-size: 0.9rem;
    font-weight: 700;
    color: var(--color-text-dark);
    margin-bottom: 14px;
}

.fv-refs__list {
    list-style: disc;
    padding-left: 20px;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.fv-refs__item {
    font-size: 0.8rem;
    color: var(--color-gray-medium);
    line-height: 1.7;
}

.fv-refs__item a {
    color: var(--color-lila);
    text-decoration: underline;
    word-break: break-all;
}

.fv-refs__item a:hover {
    color: var(--color-primary);
}


/* ----------------------------------------------------------
   RESPONSIVE — TABLET (768px)
   ---------------------------------------------------------- */

@media (min-width: 768px) {

    .fv-grid--2col {
        grid-template-columns: repeat(2, 1fr);
    }

    .fv-grid--3col {
        grid-template-columns: repeat(2, 1fr);
    }

    .fv-grid--4col {
        grid-template-columns: repeat(2, 1fr);
    }

    .fv-grid--5col {
        grid-template-columns: repeat(3, 1fr);
    }

    .fv-field--span2 {
        grid-column: span 2;
    }

    .fv-form__footer {
        flex-direction: row;
        justify-content: center;
        gap: 32px;
    }

    .fv-form-section__title {
        font-size: 1.6rem;
    }
}


/* ----------------------------------------------------------
   RESPONSIVE — DESKTOP (992px)
   ---------------------------------------------------------- */

@media (min-width: 992px) {

    .fv-grid--3col {
        grid-template-columns: repeat(3, 1fr);
    }

    .fv-grid--4col {
        grid-template-columns: repeat(4, 1fr);
    }

    .fv-grid--5col {
        grid-template-columns: repeat(5, 1fr);
    }

    .fv-block {
        padding: 32px 36px;
    }

    .fv-form__footer {
        padding: 32px 36px;
    }

    .fv-form-section__title {
        font-size: 1.8rem;
    }

    .fv-intro__text,
    .fv-intro__contact-item {
        font-size: 1rem;
    }
}


/* ----------------------------------------------------------
   RESPONSIVE — LARGE DESKTOP (1200px)
   ---------------------------------------------------------- */

@media (min-width: 1200px) {

    .qs-hero__title {
        font-size: 2.8rem;
    }
}
