-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathejercicio3.html
127 lines (125 loc) · 2.66 KB
/
ejercicio3.html
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
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<title>ejercicio3</title>
<style media="screen">
.contenedor{
width: 50%;
float: left;
min-height: 300px;
}
.espana{
width: 200px;
height: 100px;
position: relative;
background-color: red;
}
.amarillo{
height: 30px;
position: absolute;
top: calc(50% - 15px);
background-color: yellow;
width: 100%;
}
.dinamarca{
width: 200px;
height: 100px;
position: relative;
background-color: red;
}
.vertical{
width: 10px;
height: 100%;
background-color: #fff;
position: absolute;
left: 30px;
top: 0;
}
.horizontal{
width: 100%;
height: 10px;
background-color: #fff;
position: absolute;
left: 0;
top: calc(50% - 5px);
}
.emiratos{
width: 200px;
height: 100px;
position: relative;
background-color: #fff;
}
.roja{
width: 40px;
height: 100%;
position: absolute;
top: 0;
left: 0;
background-color: red;
z-index: 1;
}
.verde{
width: 100%;
height: 33%;
position: absolute;
top: 0;
left: 0;
background-color: green;
}
.negra{
width: 100%;
height: 33%;
position: absolute;
bottom: 0;
left: 0;
background-color: #000;
}
.japon{
width: 200px;
height: 100px;
position: relative;
background-color: #fff;
border: 1px solid #ccc;
}
.circulo{
background-color: red;
height: 50px;
width: 50px;
border-radius: 50%;
position: absolute;
top: calc(50% - 25px);
left: calc(50% - 25px);
}
</style>
</head>
<body>
<div class="contenedor">
<div class="espana">
<span class="amarillo"></span>
</div>
<p>Espana</p>
</div>
<div class="contenedor">
<div class="dinamarca">
<span class="vertical"></span>
<span class="horizontal"></span>
</div>
<p>Dinamarca</p>
</div>
<div class="contenedor">
<div class="emiratos">
<span class="negra"></span>
<span class="verde"></span>
<span class="roja"></span>
</div>
<p>Emiratos Arabes</p>
</div>
<div class="contenedor">
<div class="japon">
<span class="circulo"></span>
</div>
<p>Japon</p>
</div>
</body>
</html>