HTML - hacer reponsive la barra y desplegar los cuadros logueo

 
Vista:
Imágen de perfil de jhon
Val: 9
Ha disminuido su posición en 2 puestos en HTML (en relación al último mes)
Gráfica de HTML

hacer reponsive la barra y desplegar los cuadros logueo

Publicado por jhon (3 intervenciones) el 18/09/2020 15:41:36
hola quisiera saber como corregir el diseño responsivo de la barra que estoy haciendo trate de hacer un menu hamburguesa pero no se despliega y solo una parte se oculta de la barra puuse un pequeño scripdel java script , también hice dos pequeños cuadros para el registro pero aun no puedo hacer que se desplieguen y se oculten al hacer click en los botones carrito y registro.
gracias por la ayuda
estas son las imágenes de la idea


barra
menu
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
<!-----html------>
<body>
	<div class="barra">
		<div class="contenedor_nav clearfix">
			<div class="logoC">
				<img src="img/logo.svg" alt="logo empresa">
			</div>
			<div class="menu-movil2">
				<span></span>
				<span></span>
				<span></span>
			</div>
			<nav class="navegacion_sorteo">
 
				<a href="">Asociados</a>
				<a href="">Sorteos</a>
			</nav>
			<div class="barra2 clearfix">
			<div class="log-cart"><span><a href="">Carrito</a>
			</span><span><i class="fa fa-cart-arrow-down" aria-hidden="true"></i><span>0</span></span>
		    </div>
		    <span class="ingrese"><i class="fa fa-user" aria-hidden="true"></i>Ingrese</span>
		    <span class="registro">Registrese</span>
		 </div>
		 </div>
		</div>
 
<div class="container mlogin">
	<div id="login">
		<h1>Login</h1>
		<form name="loginform" id="loginform" action="" method="POST">
			<p>
			<label for="user_login">Nombre De Usuario<br />
			<input type="text" name="username" id="username" class="input" value="" size="20" required="" /></label>
			</p>
			<p>
			<label for="user_pass">Contraseña<br />
			<input type="password" name="password" id="password" class="input" value="" size="20" required=""/></label>
			</p>
			<p class="submit">
			<input type="submit" name="login" class="button" value="Entrar" />
			</p>
			<p class="regtext">No estas registrado? <a href="register.php" >Registrate Aquí</a>!</p>
		</form>
	</div>
</div>
 
 
<div class="cart-pop">
		<table border="1">
		<caption>Resumen de Compra</caption>
		<tr>
			<th>Item</th>
			<th>Imgn</th>
			<th>Name</th>
			<th>Price</th>
		</tr>
		<tr>
			<td>1</td>
			<td><img src="../imagenes/store/1.jpg"class="img-tumb";></img></td>
			<td>Resindencial 1</td>
			<td><span>Us</span>3000</td>
		</tr>
		<tr>
			<td>2</td>
			<td><img src="../imagenes/store/2.jpg"class="img-tumb";></img></td>
			<td>Resindencial 2</td>
			<td><span>Us</span>3000</td>
		</tr>
		</table>
		es esta seccion se agregaran los productos del carro para luego pasar a la compra de pay
		<a class="button" style="font-size: 15px; margin-top: 40px;" href="" >
		<span class="fa fa-paypal" aria-hidden="true"></span>Confirma tu pedido
		</a>
 
</div>
 
 
 
 
	<script type="text/javascript">
	var mostrar = document.getElementsByClassName("next-secc");
	mostrar.style.display='block' //o el de tu preferencia
	//Y viceversa
	var mostrar = document.getElementsByClassName("next-secc");
	mostrar.style.display='none'
	</script>
 
 
</body>
 
 
<!-----html------>
 
<style>
 
body{
	background-color: #f2f2f2;
	font-family: 'Oswald', sans-serif;
}
h2{
	font-family: 'Oswald', sans-sherif;
}
.clearfix:before,
 .clearfix:after{
 	content: '';
 	display: table;
 }
/***header***/
div.hero{
	background-image:url('img/encabezado.jpg');
	height: 100vh;
	background-position: top center;
	background-size: cover;
}
div.contenido-header{
	padding-top: 10px;
}
@media only screen and (min-width: 768px){
	div.contenido-header{
	padding-top: 40px;
}
	}
 
nav.redes-sociales{
text-align: center;
}
 
nav.redes-sociales a{
	color: #fff;
	font-size: 2em;
	margin-right: 20px;
}
 
nav.redes-sociales a:last-child{
	margin-right: 0;
}
div.informacion-evento{
	text-align: center;
	color: #fff;
}
@media only screen and (min-width: 768px){
	div.informacion-evento{
		width: 70%;
		margin: 0 auto;
		margin-top: 50px;
	}
}
div.informacion-evento p{
	margin:0;
	display: inline;
	font-size: 20px;
	text-transform: uppercase;
}
div.informacion-evento p i{
	color: #fe4918;
}
p.fecha{
	float: left;
}
p.ciudad{
	float: right;
	text-align: right;
}
p.slogan{
	text-transform: none !important;
}
p.slogan span{
	font-weight: bold;
}
 
h1.nombre-sitio{
	font-size: 5.9vw;
	text-transform: uppercase;
	font-family: 'PT Sans', sans-serif;
}
@media only screen and (min-width: 768px){
 
h1.nombre-sitio{
	font-size: 11.5vw;
	margin: 0;
	line-height: 1;
	}
}
.contenedor_nav{
	width: 95%;
	margin: 0 auto;
}
 
@media only screen and (min-width: 480px){
	.contenedor_nav{
	width: 95%;
}
	}
@media only screen and (min-width: 768px){
 
	.contenedor_nav{
	width: 90%;
}
	}
@media only screen and (min-width: 992px){
 
	.contenedor_nav{
	width: 90%;
	max-width: 1100px;
}
	}
div.barra{
	background-color:#353535;
	padding: 20px 0;
	height: 5em;
	display: flex;
    justify-content: space-around;
 
}
div.logoC{
	width: 20%;
	float: left;
	border: 3px solid red;
}
div.logoC img{
	width: 100%;
}
@media only screen and (min-width:768px){
div.logoC{
	width: 10%;
}
	}
/*------nav principal-------*/
.navegacion_sorteo{
	display: none;
	width: 100%;
	border: 3px solid yellow;
}
.navegacion_sorteo a{
	font-family: 'Oswald', sans-serif;
	color: #fff;
	font-size: 1.1em;
	text-transform: uppercase;
	text-decoration: none;
	transition: all .6s ease;
	width: 100%;
	display: block;
	text-align: center;
	margin-bottom: 20px;
}
div.barra2{
 border:3px solid green;
 float: right;
 max-height: 70px;
}
div.log-cart{
	float: left;
	width: 130px;
	height: 45px;
	color: #fff;
	background: red;
	padding:5px auto;
}
div.log-cart span{
	margin:8px;
	text-decoration: none;
	display: inline;
 
	line-height: 40px;
}
span.ingrese, span.registro{
    float: left;
	display: block;
	color: #fff;
	margin-left: 15px;
	padding: 10px 10px;
	background: red;z
	height: 45px;
	text-align: center;
	cursor: pointer;
}
nav.login-cart {
	float: left;
	color: #fff;
	width: 200px;
	height: 200px;
	background: yellow;
	margin-top: 3.7em;
}
.sign-up{
	float: left;
	color: #fff;
	width: 200px;
	height: 200px;
	background: yellow;
	margin-top: 3.7em;
}
 
 
nav.navegacion_sorteo a:hover {
	background-color: #fe4918;
}
nav.navegacion_sorteo a:last-child {
	border: 2px solid #fe4918;
	color: 	#fe4918;
}
nav.navegacion_sorteo a:last-child:hover {
	color: #fff;
}
 
@media only screen and (min-width:768px) {
nav.navegacion_sorteo{
	width:60%;
	float: left;
	text-align: right;
	display: block;
}
nav.navegacion_sorteo a{
	margin-right: 10px;
	padding: 10px 10px;
	display: inline-block;
	width: auto;
	text-align:center;
	margin: 0 10px 0 0;
	}
}
/**----------menu movil---*/
div.menu-movil2{
 width: 60px;
 display: block;
 float: right;
 text-align: right;
 margin-top: 12px;
 
}
div.menu-movil2:hover{
	cursor:pointer;
}
@media only screen and (min-width:768px) {
	div.menu-movil2{
		display: none;
}
	}
div.menu-movil2 span{
 height: 8px;
 margin-bottom: 6px;
 background-color: white;
 display: block;
}
/*----login-----*/
 .regtext a {
color: #f58220;
font-weight: 400;
}
 
.mlogin {
float: left;
 
}
 
 
 
/*= CONTAINERS
——————————————————–*/
.container {
/*display: none;*/
padding: 25px 16px 25px 10px;
font-weight: 400;
overflow: hidden;
max-width: 270px;
max-height: 310px;
background: #fff;
-webkit-box-shadow: 0 1px 3px rgba(0,0,0,.13);
-moz-box-shadow: 0 1px 3px rgba(0,0,0,.13);
box-shadow: 0 1px 3px rgba(0,0,0,.13);
float: right;
margin-right: 31px;
}
 
.cart-pop {
padding:10px;
font-weight: 400;
overflow: hidden;
width: 270px;
max-height: auto;
background: #fff;
-webkit-box-shadow: 0 1px 3px rgba(0,0,0,.13);
-moz-box-shadow: 0 1px 3px rgba(0,0,0,.13);
box-shadow: 0 1px 3px rgba(0,0,0,.13);
/*display: none;*/
float: right;
margin-right: 14px;
text-align: center;
}
 
 
.container h1 {
color: #777;
text-align: center;
font-weight: 300;
border: 1px dashed #777;
margin-top: 2px;
}
 
.container label {
color: #777;
font-size: 14px;
}
 
#login {
width: 220px;
margin: auto;
padding-bottom: 5px;
}
 
.container form .input,.container input[type=text],.container input[type=password],.container input[type=e] {
background: #fbfbfb;
font-size: 20px;
line-height: 1;
width: 100%;
padding: 3px;
margin: 0 6px 5px 0;
outline: none;
border: 1px solid #d9d9d9;
}
 
.container form .input:focus {
border: 1px solid #f58220;
-webkit-box-shadow: 0 0 3px 0 rgba(245,130,32,0.75);
-moz-box-shadow: 0 0 3px 0 rgba(245,130,32,0.75);
box-shadow: 0 0 3px 0 rgba(245,130,32,0.75);
}
 
/*= BUTTONS
——————————————————–*/
 
.button{
border: solid 1px #da7c0c;
background: #f78d1d;
background: -webkit-gradient(linear, left top, left bottom, from(#faa51a), to(#f47a20));
background: -moz-linear-gradient(top, #faa51a, #f47a20);
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr=#faa51a’, endColorstr=’#f47a20′);
color: #fff;
padding: 5px 12px;
-webkit-border-radius:4px;
-moz-border-radius:4px;
border-radius:4px;
float: right;
cursor: pointer;
}
.img-tumb{
	width: 45px;
	height: 45px;
	justify-content: center;
}
.button span{
	margin:0 10px;
	font-size: 20px;
	color:#000;
}
 
.button:hover{
background: #f47c20;
background: -webkit-gradient(linear, left top, left bottom, from(#f88e11), to(#f06015));
background: -moz-linear-gradient(top, #f88e11, #f06015);
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr=#f88e11′, endColorstr=’#f06015′);
}
 
 
/*= FOOTER
——————————————————–*/
footer {
color: #777;
font-size: 12px;
text-align: center;
margin-top: 10px;
}
 
</style>
Valora esta pregunta
Me gusta: Está pregunta es útil y esta claraNo me gusta: Está pregunta no esta clara o no es útil
0
Responder