Ver Mensaje Individual
  #13 (permalink)  
Antiguo 30/04/2014, 09:04
mblascog
 
Fecha de Ingreso: enero-2002
Ubicación: Sabadell
Mensajes: 565
Antigüedad: 22 años, 4 meses
Puntos: 4
Respuesta: Alinear texto e imagen un un <li>

Buenas,
No hay manera de encontrar donde está el error, sigo sin ser capaç de alinear verticalmente texto e imagen en una etiqueta <li>
El código css general, es el siguiente:
Código CSS:
Ver original
  1. nav{clear:both;float:left;width:100%;padding-bottom:1%;}
  2.  
  3. nav ul {background:gray;}
  4.  
  5. nav ul li{
  6.     background:gray;
  7. /*  box-sizing:border-box;
  8.     -moz-box-sizing:border-box;*/
  9.     display:inline-block;
  10.     font-size:.9em;
  11. /*  float:left; */
  12.     width:16.3%;
  13.     text-align:center;
  14.     padding:0.5%;
  15.     margin:0;
  16.     height:25px;
  17. }
  18. nav ul li:hover{
  19.     font-weight:bold;  
  20.     background:rgba(0,0,0,.6);
  21. }
  22. nav ul li a{
  23.     color:white;
  24.     text-transform:uppercase;
  25. }

Y el que en estos momentos me está llevando de cabeza, cuando la web se visualiza en un móvil, es el siguiente:

Código CSS:
Ver original
  1. @media screen and (max-width:360px) {
  2.     body {font-size:0.7em;}
  3.     #menu{display:inline;}
  4.     #bandera{display:inline;}
  5.     nav{padding:0;display:none;}
  6.     nav ul li{font-size:1.2em;width:100%;text-align:left;height:40px;border:1px solid #000;padding-left:10px;font-weight:bold;vertical-align:middle;}
  7.     nav ul li a{height:100%;vertical-align:middle;}
  8.     nav ul li img {vertical-align:middle;}
  9.     h1{font:1.5em/1.0 'Arial';font-weight:bold;background:gray;padding:3%;}
  10.     section{background:white;font:1.2em/2.0 'Arial'}
  11. }

Alguna sugerencia, por favor!!!
Gracias
__________________
Qué fácil cuando lo sabes y qué difícil cuando no