/*
Theme Name:     Newsmag Child theme
Theme URI: 		http://themeforest.net/user/tagDiv/portfolio
Description:    Child theme made by tagDiv
Author:         tagDiv
Author URI: 	http://themeforest.net/user/tagDiv/portfolio
Template:       Newsmag                             
Version:        3.3c
*/

/* Ajusta el contenedor del logo para que no sea rectangular */
.td-header-wrap .td-header-sp-logo {

    max-width: 200px; /* Cambia este valor según el ancho que desees para tu logo */
}

.td-header-wrap .td-header-sp-logo img {
    max-height: 160px !important; /* Cambia este valor según el alto que prefieras */
    width: auto;
}

/* ==========================================================
   Corrección de alta especificidad para el logo móvil en Newsmag
   ========================================================== */
@media (max-width: 767px) {
  /* Permitir desbordamiento en filas y contenedores móviles */
  body .td-header-menu-wrap .td-header-row,
  body .td-mobile-header-wrap {
    overflow: visible !important;
  }

  /* Forzar contenedor centrado y visible */
  body .td-main-menu-logo,
  body .td-mobile-logo {
    display: inline-block !important;
    position: relative !important;
    overflow: visible !important;
    text-align: center !important;
    width: 100% !important;
  }

  /* Selector con mayor especificidad (agregando "body") para ganarle al tema */
  body .td-header-menu-wrap .td-main-menu-logo img,
  body .td-mobile-header-wrap .td-mobile-logo img {
    max-height: none !important;
    height: 95px !important;     /* <--- Cambia este valor si lo quieres más grande o pequeño (ej. 90px o 110px) */
    width: auto !important;
    position: relative !important;
    top: -70px !important;         /* <--- Ajusta este valor en negativo (-5px, -10px) para subirlo o bajarlo */
    z-index: 99999 !important;
    display: inline-block !important;
  }
}

/* ==========================================================
   Control de visibilidad de ítems del menú (Escritorio vs Móvil)
   ========================================================== */

/* 1. Elementos que solo deben verse en Escritorio (se ocultan en móvil) */
@media (max-width: 767px) {
  .menu-item.solo-desktop {
    display: none !important;
  }
}

/* 2. Elementos que solo deben verse en Móvil (se ocultan en escritorio por defecto) */
.menu-item.solo-movil {
  display: none !important;
}

@media (max-width: 767px) {
  .menu-item.solo-movil {
    display: block !important;
  }
}

/* 1. Oculta los contadores y textos de "Fans" / "Seguidores" */
div.td_social_type span.td_social_info_counter,
div.td_social_type span.td_social_info_name {
    display: none !important;
}

/* 2. Centra completamente toda la lista de iconos en el widget */
div.td-social-list {
    display: flex !important;
    justify-content: center !important;
    align-items: center !important;
    flex-wrap: wrap !important;
    gap: 12px !important;
    width: 100% !important;
    float: none !important;
}

div.td_social_type {
    float: none !important;
    width: auto !important;
    margin: 0 !important;
}

/* 3. Centra y da estilo a la caja del icono */
div.td-social-box {
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    justify-content: center !important;
    width: 50px !important;
    height: 50px !important;
    padding: 0 !important;
    background: #f7f7f7 !important;
    border-radius: 4px !important;
    position: relative !important;
    box-shadow: none !important;
}

/* 4. Anula los elementos internos del tema tagDiv que generan el halo */
div.td-sp::before,
div.td-sp::after {
    display: none !important;
}

/* 5. Iconos uniformes y más grandes (26px x 26px) */
div.td-sp {
    display: block !important;
    position: absolute !important;
    top: 50% !important;
    left: 50% !important;
    transform: translate(-50%, -50%) !important;
    margin: 0 !important;
    width: 26px !important;
    height: 26px !important;
    background-size: contain !important;
    background-repeat: no-repeat !important;
    background-position: center !important;
    background-color: transparent !important;
    filter: none !important;
    box-shadow: none !important;
}

/* SVG específico para Facebook en #102153 */
div.td-sp-facebook {
    background-image: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="%23102153"><path d="M12 2C6.477 2 2 6.477 2 12c0 4.991 3.657 9.128 8.438 9.878v-6.987h-2.54V12h2.54V9.797c0-2.506 1.492-3.89 3.777-3.89 1.094 0 2.238.195 2.238.195v2.46h-1.26c-1.243 0-1.63.771-1.63 1.562V12h2.773l-.443 2.89h-2.33v6.988C18.343 21.128 22 16.991 22 12c0-5.523-4.477-10-10-10z"/></svg>') !important;
}

/* SVG específico para Instagram en #102153 */
div.td-sp-instagram {
    background-image: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="%23102153"><path d="M12 2.163c3.204 0 3.584.012 4.85.07 3.252.148 4.771 1.691 4.919 4.919.058 1.265.069 1.645.069 4.849 0 3.205-.012 3.584-.069 4.849-.149 3.225-1.664 4.771-4.919 4.919-1.266.058-1.644.07-4.85.07-3.204 0-3.584-.012-4.849-.07-3.26-.149-4.771-1.699-4.919-4.92-.058-1.265-.07-1.644-.07-4.849 0-3.204.013-3.583.07-4.849.149-3.227 1.664-4.771 4.919-4.919 1.266-.057 1.645-.069 4.849-.069zm0-2.163c-3.259 0-3.667.014-4.947.072-4.358.2-6.78 2.618-6.98 6.98-.059 1.281-.073 1.689-.073 4.948 0 3.259.014 3.668.072 4.948.2 4.358 2.618 6.78 6.98 6.98 1.281.058 1.689.072 4.948.072 3.259 0 3.668-.014 4.948-.072 4.354-.2 6.782-2.618 6.979-6.98.059-1.28.073-1.689.073-4.948 0-3.259-.014-3.667-.072-4.947-.196-4.354-2.617-6.78-6.979-6.98-1.281-.059-1.69-.073-4.949-.073zm0 5.838c-3.403 0-6.162 2.759-6.162 6.162s2.759 6.163 6.162 6.163 6.162-2.759 6.162-6.163c0-3.403-2.759-6.162-6.162-6.162zm0 10.162c-2.209 0-4-1.79-4-4 0-2.209 1.791-4 4-4s4 1.791 4 4c0 2.21-1.791 4-4 4zm6.406-11.845c-.796 0-1.441.645-1.441 1.44s.645 1.44 1.441 1.44c.795 0 1.439-.645 1.439-1.44s-.644-1.44-1.439-1.44z"/></svg>') !important;
}

/* SVG específico para Twitter/X en #102153 */
div.td-sp-twitter {
    background-image: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="%23102153"><path d="M18.244 2.25h3.308l-7.227 8.26 8.502 11.24H16.17l-5.214-6.817L4.99 21.75H1.68l7.73-8.835L1.254 2.25H8.08l4.713 6.231zm-1.161 17.52h1.833L7.084 4.126H5.117z"/></svg>') !important;
}

/* 6. Mantiene el área del enlace activa y funcional en todo el cuadro */
span.td_social_button {
    position: absolute !important;
    top: 0 !important;
    left: 0 !important;
    width: 100% !important;
    height: 100% !important;
    margin: 0 !important;
    z-index: 2 !important;
}

span.td_social_button a {
    display: block !important;
    width: 100% !important;
    height: 100% !important;
    font-size: 0 !important;
    text-indent: -9999px !important;
}


/*  ----------------------------------------------------------------------------
    This file will load automatically when the child theme is active. You can use it
    for custom CSS.
*/
