Agregando variables de color y dándoles uso
[salamandradevs.site/.git] / themes / droda / assets / css / main.css
1 /* ESTILOS CSS PARA EL SITIO WEB DE SALAMANDRADEVS */
2
3 /* Copyright GNU LGPL. 
4    Puedes copiar, modificar y usar este software bajo los términos de la licencia general de uso público reducida de GNU.
5    Encontrarás una copia de la licencia aquí https://www.gnu.org/licenses/lgpl-3.0.html */
6
7 /* Metodología mobile first o pantallas pequeñas primero.
8    Primero se escriben las reglas para el ancho de portview
9    más pequeño a considerar */
10
11 /* VARIABLES Y REGLAS GENERALES */
12 @charset "UTF-8";
13
14 * {
15    box-sizing: border-box;
16 }
17
18 :root {
19    --bgColorDark: #242930;
20    --bgColorMidDark: #353b43;
21    --bgColorLightDark: #4f5864;
22    --bgColorLight: #D2D2D2;
23    --globalScale: 1;
24 }
25
26 h1 {
27    font-size: 6rem;
28 }
29
30 h2 {
31    font-size: 4rem;
32 }
33
34 h3 {
35    font-size: 3rem;
36 }
37
38 h4 {
39    font-size: 2rem;
40 }
41
42 p {
43    font-size: 1.5rem;
44 }
45
46 h1, h2, h3, h4, p {
47    padding: 0.5rem 0;
48    margin: 0;
49 }
50
51 a:link,
52 a:visited,
53 a:hover,
54 a:active {
55    text-decoration: none;
56    font-size: 1.5rem;
57 }
58
59 html {
60    font-size: calc(62.5% * var(--globalScale));
61    background-color: var(--bgColorLight);
62 }
63
64 /* REGLAS DEL HOME */
65
66 body {
67    display: grid;
68    grid-template-columns: 1fr;
69    grid-template-rows: 5rem 1fr 5rem;
70    grid-template-areas: /* No mostramos el aside en móbiles */
71       "navbar"
72       "main"
73       "footer";
74    height: 100vh;
75    margin: 0;
76 }
77
78 aside {
79    grid-area: aside;
80    display: none;
81    flex-flow: column nowrap;
82    align-items: flex-start;
83    justify-content: flex-start;
84    width: 100%;
85    padding: 0 1rem;
86    background-color: var(--bgColorDark);
87 }
88
89 aside .item {
90    display: flex;
91    flex-flow: row nowrap;
92    align-items: center;
93    justify-content: space-between;
94    font-size: 1.5rem;
95    width: 100%;
96    padding: 1rem 0;
97 }
98
99 nav {
100    grid-area: navbar;
101    display: flex;
102    flex-flow: row nowrap;
103    align-items: center;
104    justify-content: space-between;
105    width: 100%;
106    padding: 0 2rem;
107    background-color: var(--bgColorLightDark);
108 }
109
110 main {
111    grid-area: main;
112    padding: 2rem;
113    background-color: var(--bgColorMidDark);
114 }
115
116 main hr {
117    width: 100%;
118 }
119
120 .articles {
121    display: flex;
122    flex-flow: row wrap;
123    align-items: flex-start;
124    justify-content: space-between;
125 }
126
127 .articles article {
128    width: 30rem;
129    border: 1px solid;
130    border-radius: 0.5rem;
131    padding: 1rem;
132    margin: 1rem;
133 }
134
135 .content table {
136    padding-top: 2rem;
137    margin: 0 auto;
138 }
139
140 .content table img {
141    width: 3rem;
142 }
143
144 .content table td {
145    padding: 0 0.3rem;
146 }
147
148 footer {
149    grid-area: footer;
150    display: flex;
151    align-items: center;
152    width: 100%;
153    padding: 0 2rem;
154    background-color: var(--bgColorLightDark);
155 }
156
157 .greetings {
158    background-color: var(--bgColorMidDark);
159    width: 80%;
160    height: 80%;
161    margin: 0 auto;
162 }
163
164 @media screen and (min-width: 780px) {
165    :root {
166       --globalScale: 1.5;
167    }
168
169    body {
170       grid-template-columns: 11rem 1fr;
171       grid-template-areas: /* Tabletas se muestra el aside */
172          "navbar navbar"
173          "aside main"
174          "footer footer";
175    }
176
177    aside {
178       display: flex;
179    }
180 }
181
182 @media screen and (min-width: 1280px) {
183    :root {
184       --globalScale: 2;
185    }
186 }
187