main
css 548 lines 9.91 KB
Raw
1 /* MAPS Connect - Layout (header, sidebar, main) */
2
3 .app-layout {
4 display: flex;
5 min-height: 100vh;
6 }
7
8 .sidebar {
9 width: var(--sidebar-width);
10 background: var(--sidebar-bg);
11 color: var(--sidebar-text-hover);
12 position: fixed;
13 top: 0;
14 left: 0;
15 height: 100vh;
16 z-index: 100;
17 display: flex;
18 flex-direction: column;
19 transform: translateX(-100%);
20 transition: transform 0.3s ease;
21 box-shadow: 0 0 1.25rem rgba(0, 0, 0, 0.2);
22 }
23
24 .sidebar.open {
25 transform: translateX(0);
26 }
27
28 .sidebar-header {
29 padding: 1.25rem;
30 border-bottom: 1px solid var(--sidebar-border);
31 }
32
33 .sidebar-header h1 {
34 color: var(--sidebar-text-hover);
35 font-size: 1.25rem;
36 margin: 0;
37 }
38
39 .sidebar-header small {
40 color: var(--sidebar-text);
41 }
42
43 .sidebar-user {
44 display: flex;
45 align-items: center;
46 gap: 10px;
47 margin-top: 10px;
48 min-width: 0;
49 }
50
51 .sidebar-user small {
52 white-space: nowrap;
53 overflow: hidden;
54 text-overflow: ellipsis;
55 }
56
57 .sidebar-avatar {
58 width: 34px;
59 height: 34px;
60 background-color: rgba(255, 255, 255, 0.12);
61 color: #ffffff;
62 display: flex;
63 align-items: center;
64 justify-content: center;
65 font-weight: bold;
66 font-size: 0.8rem;
67 flex-shrink: 0;
68 border-radius: 0;
69 }
70
71 .sidebar-avatar.avatar-foto {
72 object-fit: cover;
73 width: 34px;
74 height: 34px;
75 }
76
77 .sidebar-nav {
78 list-style: none;
79 padding: 1rem 0;
80 overflow-y: auto;
81 flex: 1;
82 }
83
84 .sidebar-nav a {
85 display: block;
86 padding: 0.75rem 1.25rem;
87 color: var(--sidebar-text);
88 text-decoration: none;
89 border-left: 3px solid transparent;
90 }
91
92 .sidebar-nav a:hover {
93 background: var(--sidebar-item-hover-bg);
94 color: var(--sidebar-text-hover);
95 text-decoration: none;
96 }
97
98 .sidebar-nav a.active {
99 background: var(--sidebar-item-active-bg);
100 color: var(--sidebar-text-hover);
101 border-left-color: var(--sidebar-accent);
102 text-decoration: none;
103 }
104
105 .sidebar-footer {
106 padding: 1rem 1.25rem;
107 border-top: 1px solid var(--sidebar-border);
108 }
109
110 .sidebar-footer .btn {
111 width: 100%;
112 }
113
114 .main-wrapper {
115 flex: 1;
116 display: flex;
117 flex-direction: column;
118 min-width: 0;
119 transition: margin-left 0.3s ease;
120 }
121
122 .app-layout.menu-open .main-wrapper {
123 margin-left: var(--sidebar-width);
124 }
125
126 .topbar {
127 height: 0;
128 }
129
130 .menu-toggle {
131 position: fixed;
132 top: 1rem;
133 left: 1rem;
134 z-index: 110;
135 width: 2.75rem;
136 height: 2.75rem;
137 border: none;
138 border-radius: 50%;
139 background: var(--sidebar-bg);
140 color: var(--sidebar-text-hover);
141 font-size: 1.25rem;
142 cursor: pointer;
143 box-shadow: 0 0.125rem 0.5rem rgba(0, 0, 0, 0.2);
144 transition: left 0.3s ease;
145 }
146
147 .app-layout.menu-open .menu-toggle {
148 left: calc(var(--sidebar-width) + 1rem);
149 }
150
151 .menu-backdrop {
152 display: none;
153 position: fixed;
154 inset: 0;
155 z-index: 80;
156 border: 0;
157 background: rgba(0, 0, 0, 0.35);
158 cursor: pointer;
159 }
160
161 .app-layout.menu-open .menu-backdrop {
162 display: block;
163 }
164
165 .main-content {
166 flex: 1;
167 padding: 4.75rem 1.5rem 1.5rem;
168 overflow-y: auto;
169 }
170
171 /* ---------- Buscador global (topbar) ---------- */
172 .global-search {
173 position: fixed;
174 top: 0.8rem;
175 left: 50%;
176 transform: translateX(-50%);
177 z-index: 115;
178 width: min(500px, calc(100vw - 10rem));
179 }
180
181 .global-search-input {
182 width: 100%;
183 padding: 0.55rem 0.9rem;
184 border: 1px solid var(--gray-300);
185 background: #ffffff;
186 font: inherit;
187 font-size: 0.9rem;
188 box-shadow: 0 0.125rem 0.5rem rgba(0, 0, 0, 0.12);
189 border-radius: 0;
190 }
191
192 .global-search-input:focus {
193 outline: none;
194 border-color: var(--sidebar-bg);
195 }
196
197 .global-search-dropdown {
198 position: absolute;
199 top: calc(100% + 6px);
200 left: 0;
201 right: 0;
202 background: #ffffff;
203 border: 1px solid var(--gray-300);
204 box-shadow: 0 0.5rem 1.25rem rgba(0, 0, 0, 0.18);
205 max-height: 320px;
206 overflow-y: auto;
207 z-index: 116;
208 }
209
210 .global-search-item {
211 display: flex;
212 align-items: center;
213 gap: 10px;
214 padding: 8px 10px;
215 cursor: pointer;
216 border-bottom: 1px solid #f0f0f0;
217 }
218
219 .global-search-item:hover {
220 background: #f6f8fa;
221 }
222
223 .global-search-item:last-child {
224 border-bottom: none;
225 }
226
227 .global-search-item .avatar {
228 width: 36px;
229 height: 36px;
230 font-size: 0.85rem;
231 flex-shrink: 0;
232 background-color: var(--hub-accent, #0284c7);
233 color: #ffffff;
234 display: flex;
235 align-items: center;
236 justify-content: center;
237 font-weight: bold;
238 }
239
240 .global-search-item .avatar-foto {
241 width: 36px;
242 height: 36px;
243 object-fit: cover;
244 flex-shrink: 0;
245 }
246
247 .global-search-info {
248 flex: 1;
249 min-width: 0;
250 }
251
252 .global-search-info strong {
253 display: block;
254 font-size: 0.88rem;
255 color: #111111;
256 white-space: nowrap;
257 overflow: hidden;
258 text-overflow: ellipsis;
259 }
260
261 .global-search-info span {
262 display: block;
263 font-size: 0.75rem;
264 color: #666666;
265 white-space: nowrap;
266 overflow: hidden;
267 text-overflow: ellipsis;
268 }
269
270 .global-search-chat {
271 border: 1px solid var(--accent-dark, #005a2b);
272 background: transparent;
273 color: var(--accent-dark, #005a2b);
274 font-size: 0.72rem;
275 font-weight: 700;
276 padding: 5px 10px;
277 cursor: pointer;
278 border-radius: 0;
279 white-space: nowrap;
280 }
281
282 .global-search-chat:hover {
283 background: var(--accent-soft, #e8f5e9);
284 }
285
286 .global-search-empty {
287 padding: 12px;
288 font-size: 0.85rem;
289 color: #777777;
290 text-align: center;
291 }
292
293 @media (max-width: 768px) {
294 .global-search {
295 width: calc(100vw - 5.5rem);
296 }
297 }
298
299 .visually-hidden {
300 position: absolute;
301 width: 1px;
302 height: 1px;
303 padding: 0;
304 margin: -1px;
305 overflow: hidden;
306 clip: rect(0, 0, 0, 0);
307 white-space: nowrap;
308 border: 0;
309 }
310
311 .auth-layout {
312 min-height: 100vh;
313 display: flex;
314 align-items: center;
315 justify-content: center;
316 padding: 1rem;
317 }
318
319 /*fondo de pantalla de inicio de sesion y registro*/
320
321 .login-page .auth-layout,
322 .register-page .auth-layout {
323 background-image: linear-gradient(
324 rgba(0, 0, 0, 0.35),
325 rgba(0, 0, 0, 0.35)
326 ), url("../assets/bg-login.png");
327 background-size: cover;
328 background-position: center;
329 background-repeat: no-repeat;
330 }
331
332 .auth-card {
333 width: 100%;
334 max-width: 420px;
335 }
336
337 .landing-layout {
338 min-height: 100vh;
339 display: flex;
340 flex-direction: column;
341 }
342
343 .landing-header {
344 padding: 1rem 2rem;
345 background: white;
346 border-bottom: 1px solid var(--gray-200);
347 display: flex;
348 justify-content: space-between;
349 align-items: center;
350 }
351
352 .landing-hero {
353 flex: 1;
354 display: flex;
355 flex-direction: column;
356 align-items: center;
357 justify-content: center;
358 text-align: center;
359 padding: 3rem 1.5rem;
360 }
361
362 .landing-hero h1 {
363 font-size: 2.5rem;
364 margin-bottom: 1rem;
365 }
366
367 .landing-hero p {
368 color: var(--gray-600);
369 max-width: 600px;
370 margin-bottom: 2rem;
371 }
372
373 .landing-actions {
374 display: flex;
375 gap: 1rem;
376 flex-wrap: wrap;
377 justify-content: center;
378 }
379
380 @media (max-width: 768px) {
381 .app-layout.menu-open .main-wrapper {
382 margin-left: 0;
383 }
384
385 .app-layout.menu-open .menu-toggle {
386 left: 1rem;
387 }
388
389 .main-content {
390 padding: 4.75rem 1rem 1rem;
391 }
392 }
393
394 /* ---------- Notificaciones (campana global) ---------- */
395 .notif-bell {
396 position: fixed;
397 top: 0.9rem;
398 right: 1.25rem;
399 z-index: 115;
400 }
401
402 .notif-toggle {
403 position: relative;
404 width: 2.75rem;
405 height: 2.75rem;
406 border: none;
407 border-radius: 50%;
408 background: #ffffff;
409 font-size: 1.15rem;
410 cursor: pointer;
411 box-shadow: 0 0.125rem 0.5rem rgba(0, 0, 0, 0.2);
412 }
413
414 .notif-toggle:hover {
415 background: #f6f8fa;
416 }
417
418 .notif-badge {
419 position: absolute;
420 top: -2px;
421 right: -2px;
422 min-width: 1.1rem;
423 height: 1.1rem;
424 padding: 0 0.24rem;
425 border-radius: 999px;
426 background: #b3261e;
427 color: #ffffff;
428 font-size: 0.68rem;
429 font-weight: 700;
430 line-height: 1.1rem;
431 text-align: center;
432 }
433
434 .notif-panel {
435 position: absolute;
436 top: calc(100% + 0.5rem);
437 right: 0;
438 width: min(340px, calc(100vw - 2rem));
439 background: #ffffff;
440 border: 1px solid var(--gray-300);
441 box-shadow: 0 0.5rem 1.25rem rgba(0, 0, 0, 0.18);
442 z-index: 116;
443 }
444
445 .notif-panel-head {
446 display: flex;
447 justify-content: space-between;
448 align-items: center;
449 gap: 8px;
450 padding: 0.6rem 0.75rem;
451 border-bottom: 1px solid #f0f0f0;
452 }
453
454 .notif-marcar-todas {
455 background: none;
456 border: none;
457 color: var(--sidebar-bg, #0284c7);
458 font-size: 0.78rem;
459 cursor: pointer;
460 }
461
462 .notif-marcar-todas:hover {
463 text-decoration: underline;
464 }
465
466 .notif-list {
467 max-height: 340px;
468 overflow-y: auto;
469 }
470
471 .notif-item {
472 display: flex;
473 align-items: center;
474 gap: 10px;
475 padding: 0.55rem 0.75rem;
476 cursor: pointer;
477 border-bottom: 1px solid #f6f8fa;
478 text-decoration: none;
479 color: inherit;
480 }
481
482 .notif-item:hover {
483 background: #f6f8fa;
484 }
485
486 .notif-item .avatar {
487 width: 34px;
488 height: 34px;
489 font-size: 0.8rem;
490 flex-shrink: 0;
491 background-color: var(--sidebar-bg, #0284c7);
492 color: #ffffff;
493 display: flex;
494 align-items: center;
495 justify-content: center;
496 font-weight: bold;
497 }
498
499 .notif-item-info {
500 flex: 1;
501 min-width: 0;
502 }
503
504 .notif-item-info strong {
505 display: block;
506 font-size: 0.85rem;
507 color: #222;
508 }
509
510 .notif-item-info span {
511 font-size: 0.76rem;
512 color: #666;
513 display: block;
514 }
515
516 .notif-item-info .notif-preview {
517 overflow: hidden;
518 text-overflow: ellipsis;
519 white-space: nowrap;
520 }
521
522 .notif-item-badge {
523 flex-shrink: 0;
524 min-width: 1.05rem;
525 height: 1.05rem;
526 padding: 0 0.22rem;
527 border-radius: 999px;
528 background: #b3261e;
529 color: #ffffff;
530 font-size: 0.68rem;
531 font-weight: 700;
532 line-height: 1.05rem;
533 text-align: center;
534 }
535
536 .notif-vacio {
537 padding: 1rem;
538 color: #888;
539 font-size: 0.85rem;
540 text-align: center;
541 }
542
543 @media (max-width: 768px) {
544 .notif-bell {
545 right: 0.75rem;
546 }
547 }
548