Repository navigation
Expand file tree
/
Copy pathindex.html
More file actions
443 lines (416 loc) · 24.5 KB
/
Copy pathindex.html
File metadata and controls
443 lines (416 loc) · 24.5 KB
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
<!DOCTYPE html>
<html lang="en">
<head>
<script async src="https://www.googletagmanager.com/gtag/js?id=G-C4TVS1004P"></script>
<script>
window.dataLayer = window.dataLayer || [];
function gtag(){dataLayer.push(arguments);}
gtag('js', new Date());
gtag('config', 'G-C4TVS1004P');
</script>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<title>Daniel de Oliveira - Home Page</title>
<meta name="description" content="The Home Page of Professor Daniel de Oliveira">
<meta name="keywords" content="IC-UFF, Data Science, Cloud Computing, Bioinformatics">
<link rel="icon" href="arquivos/uff.png">
<link rel="stylesheet" href="assets/site.css">
<style>
/* ---------- Two-level navigation (move to assets/site.css to share across pages) ---------- */
.main-nav {
--nav-menu-bg: #ffffff;
--nav-menu-fg: #1f2933;
--nav-menu-border: rgba(0,0,0,.08);
--nav-menu-hover: rgba(0,0,0,.06);
--nav-menu-shadow: 0 12px 32px rgba(0,0,0,.14);
}
.nav-group { position: relative; display: inline-flex; }
.nav-toggle {
font: inherit; color: inherit; letter-spacing: inherit; text-transform: inherit;
background: none; border: 0; margin: 0; padding: 0; cursor: pointer;
display: inline-flex; align-items: center; gap: 4px;
}
.nav-toggle svg { width: 14px; height: 14px; transition: transform .2s ease; }
.nav-group.is-open > .nav-toggle svg { transform: rotate(180deg); }
.nav-group.has-current > .nav-toggle { font-weight: 600; }
.nav-menu {
position: absolute; top: calc(100% + 10px); left: 50%;
min-width: 190px; margin: 0; padding: 6px; list-style: none;
background: var(--nav-menu-bg); color: var(--nav-menu-fg);
border: 1px solid var(--nav-menu-border); border-radius: 10px;
box-shadow: var(--nav-menu-shadow);
opacity: 0; visibility: hidden; transform: translate(-50%, -4px);
transition: opacity .18s ease, transform .18s ease, visibility .18s;
z-index: 50;
}
/* invisible bridge so the menu doesn't close while the mouse crosses the gap */
.nav-menu::before { content: ""; position: absolute; left: 0; right: 0; top: -12px; height: 12px; }
.nav-group.is-open > .nav-menu { opacity: 1; visibility: visible; transform: translate(-50%, 0); }
@media (hover: hover) {
.nav-group:hover > .nav-menu { opacity: 1; visibility: visible; transform: translate(-50%, 0); }
.nav-group:hover > .nav-toggle svg { transform: rotate(180deg); }
}
.nav-menu li { margin: 0; padding: 0; }
.nav-menu a {
display: block; padding: 8px 12px; border-radius: 6px;
color: inherit; text-decoration: none; white-space: nowrap;
}
.nav-menu a:hover, .nav-menu a:focus-visible { background: var(--nav-menu-hover); }
.nav-menu a[aria-current="page"] { font-weight: 600; }
@media (max-width: 760px) {
.nav-group { flex-wrap: wrap; }
.nav-group.is-open { flex-basis: 100%; }
.nav-menu {
position: static; transform: none; display: none;
min-width: 0; width: 100%; margin-top: 6px;
box-shadow: none; transition: none;
}
.nav-menu::before { display: none; }
.nav-group.is-open > .nav-menu { display: block; transform: none; }
.nav-group:hover > .nav-menu { transform: none; }
}
@media (prefers-reduced-motion: reduce) {
.nav-menu, .nav-toggle svg { transition: none; }
}
/* ---------- Photo carousel (hero) ---------- */
.carousel { position: relative; }
.carousel-track { display: grid; }
.carousel-track > figure {
grid-area: 1 / 1;
margin: 0;
opacity: 0;
visibility: hidden;
transition: opacity .7s ease, visibility .7s;
}
.carousel-track > figure.is-active { opacity: 1; visibility: visible; }
.carousel-track > figure img { width: 100%; height: 100%; object-fit: cover; display: block; }
.carousel-btn {
position: absolute; top: 50%; transform: translateY(-50%);
width: 40px; height: 40px; border: 0; border-radius: 50%;
background: rgba(0,0,0,.45); color: #fff; cursor: pointer;
display: grid; place-items: center; z-index: 2;
opacity: 0; transition: opacity .25s, background .25s;
}
.carousel:hover .carousel-btn, .carousel-btn:focus-visible { opacity: 1; }
.carousel-btn:hover { background: rgba(0,0,0,.7); }
.carousel-btn.prev { left: 12px; }
.carousel-btn.next { right: 12px; }
.carousel-btn svg { width: 20px; height: 20px; }
.carousel-dots {
display: flex; justify-content: center; gap: 8px; margin-top: 12px;
}
.carousel-dots button {
width: 10px; height: 10px; padding: 0; border: 0; border-radius: 50%;
background: currentColor; opacity: .3; cursor: pointer;
transition: opacity .25s, transform .25s;
}
.carousel-dots button[aria-current="true"] { opacity: .9; transform: scale(1.2); }
@media (hover: none) { .carousel-btn { opacity: 1; } }
@media (prefers-reduced-motion: reduce) {
.carousel-track > figure { transition: none; }
}
/* ---------- Location / mailing address ---------- */
.location-grid {
display: grid; grid-template-columns: minmax(240px, 1fr) 2fr;
gap: 28px; align-items: stretch; margin-top: 18px;
}
.location-card {
display: flex; flex-direction: column; gap: 14px;
padding: 22px 24px; border-radius: 12px;
border: 1px solid rgba(127,127,127,.28);
}
.location-card address { font-style: normal; line-height: 1.6; margin: 0; }
.location-card address strong { display: block; font-weight: 600; margin-bottom: 2px; }
.location-label {
font-size: .78em; font-weight: 600; letter-spacing: .06em;
text-transform: uppercase; opacity: .65; margin: 0 0 4px;
}
.location-contact { margin: 0; line-height: 1.7; }
.location-actions { display: flex; flex-wrap: wrap; gap: 10px 18px; margin-top: auto; }
.location-map {
position: relative; min-height: 340px; overflow: hidden;
border-radius: 12px; border: 1px solid rgba(127,127,127,.28);
background: rgba(127,127,127,.1);
}
.location-map iframe {
position: absolute; inset: 0; width: 100%; height: 100%; border: 0;
}
@media (max-width: 760px) {
.location-grid { grid-template-columns: 1fr; gap: 18px; }
.location-map { min-height: 280px; }
}
</style>
</head>
<body>
<header class="site-header">
<a class="logo-link" href="index.html" aria-label="Daniel de Oliveira — home">
<img src="arquivos/uff.png" alt="Universidade Federal Fluminense" width="72" height="72">
<span>Daniel de Oliveira<small>Institute of Computing / UFF</small></span>
</a>
<!-- Same block can be pasted unchanged on every page: the current page is marked by the script at the bottom. -->
<nav class="main-nav" aria-label="Main navigation">
<a href="index.html">Home</a>
<div class="nav-group">
<button class="nav-toggle" type="button" aria-expanded="false" aria-controls="menu-publications">
Publications
<svg viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" aria-hidden="true"><path d="m6 9 6 6 6-6"/></svg>
</button>
<ul class="nav-menu" id="menu-publications">
<li><a href="cv.html">Papers</a></li>
<li><a href="books.html">Books</a></li>
</ul>
</div>
<div class="nav-group">
<button class="nav-toggle" type="button" aria-expanded="false" aria-controls="menu-research">
Research
<svg viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" aria-hidden="true"><path d="m6 9 6 6 6-6"/></svg>
</button>
<ul class="nav-menu" id="menu-research">
<li><a href="ap.html">Research Areas</a></li>
<li><a href="collab.html">Collaborations</a></li>
<li><a href="li.html">Students</a></li>
<li><a href="awards.html">Awards</a></li>
<li><a href="projects.html">Projects</a></li>
<li><a href="software.html">Software</a></li>
</ul>
</div>
<a href="cur.html">Teaching</a>
<a href="personal.html">Personal</a>
<a href="per.html">News</a>
</nav>
<a class="header-group" href="https://uffescience.ic.uff.br" target="_blank" rel="noreferrer">
<svg class="icon" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" aria-hidden="true"><circle cx="12" cy="12" r="1"/><path d="M20.2 20.2c2.04-2.03.02-7.36-4.5-11.9-4.54-4.52-9.87-6.54-11.9-4.5-2.04 2.03-.02 7.36 4.5 11.9 4.54 4.52 9.87 6.54 11.9 4.5Z"/><path d="M15.7 15.7c4.52-4.54 6.54-9.87 4.5-11.9-2.03-2.04-7.36-.02-11.9 4.5-4.52 4.54-6.54 9.87-4.5 11.9 2.03 2.04 7.36.02 11.9-4.5Z"/></svg><span>UFFeScience</span><svg class="icon" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" aria-hidden="true"><path d="M7 7h10v10"/><path d="M7 17 17 7"/></svg>
</a>
</header>
<main id="inicio">
<section class="campus-hero">
<div class="intro-copy">
<div class="kicker"><span></span> UNIVERSIDADE FEDERAL FLUMINENSE</div>
<h1>Daniel de Oliveira<br><span>Associate Professor</span></h1>
<p>Welcome to my home page! I am an Associate Professor at the <a href="http://www.ic.uff.br">Institute of Computing</a> at Fluminense Federal University (IC/UFF), where I have been teaching and researching since 2013. I received my D.Sc. (2012) and M.Sc. (2008) in Systems and Computer Engineering from COPPE/UFRJ.</p>
<p>My research interests include Data Science, Cloud Computing, Provenance Data Management, Workflow Management, Data Parallelism, Bioinformatics, and Machine Learning. I have published over 200 papers in indexed journals and top international conferences, and I regularly serve on program committees of venues such as VLDB, EDBT, ICDE, CIKM, IPAW, and SBBD.</p>
<div class="intro-actions">
<a class="primary-button" href="cv.html">Publications <svg class="icon" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" aria-hidden="true"><path d="M5 12h14"/><path d="m12 5 7 7-7 7"/></svg></a>
<a class="quiet-link" href="li.html">Meet the students <svg class="icon" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" aria-hidden="true"><path d="M7 7h10v10"/><path d="M7 17 17 7"/></svg></a>
</div>
<div class="intro-location">Institute of Computing · Niterói, Rio de Janeiro</div>
</div>
<aside class="intro-campus">
<div class="carousel" aria-roledescription="carousel" aria-label="Photos">
<div class="carousel-track">
<figure aria-roledescription="slide" aria-label="2 of 2">
<img src="assets/Carrossel0.jpeg" alt="Anime-style illustration of Daniel de Oliveira at UFF">
<figcaption><span>Prof. Daniel @ UFF</span><small>Institute of Computing · UFF</small></figcaption>
</figure>
<figure class="is-active" aria-roledescription="slide" aria-label="1 of 2">
<img src="assets/Carrossel1.jpeg" alt="Institute of Computing at Universidade Federal Fluminense">
<figcaption><span>Prof. Daniel @ Bordeaux'26</span><small>Bordeaux, France</small></figcaption>
</figure>
<figure aria-roledescription="slide" aria-label="2 of 2">
<img src="assets/Carrossel2.jpeg" alt="Anime-style illustration of Daniel de Oliveira at UFF">
<figcaption><span>UFFeScience Team @ SBBD'26</span><small>ICMC/USP - São Carlos</small></figcaption>
</figure>
</div>
<button class="carousel-btn prev" type="button" aria-label="Previous photo"><svg viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" aria-hidden="true"><path d="m15 18-6-6 6-6"/></svg></button>
<button class="carousel-btn next" type="button" aria-label="Next photo"><svg viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" aria-hidden="true"><path d="m9 18 6-6-6-6"/></svg></button>
<div class="carousel-dots" role="group" aria-label="Choose photo"></div>
</div>
</aside>
</section>
<section class="section" id="about">
<div class="kicker">ABOUT / ROLES / RESEARCH</div>
<h2>About me</h2>
<div class="people-lead">
<img src="arquivos/Daniel.jpeg" alt="Daniel de Oliveira">
<div>
<p>At UFF, I lead the <a href="https://uffescience.ic.uff.br/">eScience Research Group (UFFeScience)</a>. I am a CNPq Productivity Fellow Level C (since 2016), a Scientist of the State (FAPERJ, since 2024), and was a Young Scientist of the State (FAPERJ, 2016–2023).</p>
<p>Chair of the <a href="https://www.sbc.org.br/biologia-computacional/">Special Commission on Computational Biology (2020-2022)</a> of the <a href="https://www.sbc.org.br/">Brazilian Computer Society</a>. Member of the <a href="https://www.sbc.org.br/bancos-de-dados/">Special Commissions on Databases (2022-2025, 2026-Current)</a> . Editor-in-Chief of the <a href="https://journals-sol.sbc.org.br/index.php/jidm">Journal of Information and Data Management (2022-2025)</a>.</p>
<p>If you are a graduate or undergraduate student, searching for academic orientation on some of the topics I am interested in, <a href="guidelines.html">let's talk!</a></p>
</div>
</div>
</section>
<section class="section tinted" id="profiles">
<div class="section-heading">
<div>
<div class="kicker">PROFILES / PUBLICATIONS</div>
<h2>Find my work</h2>
</div>
</div>
<p class="section-description">Most of my publications are available online on the platforms listed below (DBLP, IEEE, ACM, Google Scholar). If any paper is not accessible, feel free to <a href="mailto:danielcmo@ic.uff.br?subject=Publication Request&body=Hello, I would like to request a copy of your paper.">contact me</a> directly.</p>
<ul class="profile-links">
<li><a href="https://dblp.org/pid/68/7553-1.html" target="_blank" rel="noreferrer"><img src="arquivos/dblp.png" alt="">DBLP</a></li>
<li><a href="https://scholar.google.com/citations?user=T_YePXEAAAAJ&hl=pt-BR&oi=ao" target="_blank" rel="noreferrer"><img src="arquivos/scholar.jpeg" alt="">Google Scholar</a></li>
<li><a href="http://lattes.cnpq.br/0743793296062293" target="_blank" rel="noreferrer"><img src="arquivos/lattes.jpeg" alt="">Lattes</a></li>
<li><a href="https://orcid.org/0000-0001-9346-7651" target="_blank" rel="noreferrer"><img src="arquivos/ORCID.png" alt="">ORCID</a></li>
<li><a href="https://www.linkedin.com/in/daniel-de-oliveira-b258368/" target="_blank" rel="noreferrer"><img src="arquivos/linkedin.jpg" alt="">LinkedIn</a></li>
<li><a href="https://github.com/danielcmo" target="_blank" rel="noreferrer"><img src="arquivos/github.png" alt="">GitHub</a></li>
<li><a href="https://ieeexplore.ieee.org/author/37547810400" target="_blank" rel="noreferrer"><img src="arquivos/ieee.webp" alt="">IEEE Xplore</a></li>
<li><a href="https://dl.acm.org/profile/81350594654" target="_blank" rel="noreferrer"><img src="arquivos/acm.jpg" alt="">ACM DL</a></li>
</ul>
<form class="catalog-search" action="https://dblp.org/search" method="get" target="_blank" role="search">
<input type="text" name="q" placeholder="Search DBLP…" aria-label="Search DBLP">
<button type="submit"><svg class="icon" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" aria-hidden="true"><circle cx="11" cy="11" r="7"/><path d="m20 20-3.5-3.5"/></svg> Search</button>
</form>
</section>
<section class="section" id="group">
<div class="kicker">RESEARCH GROUP / COMMUNITY</div>
<h2>UFFeScience Research Group</h2>
<div class="banner-card">
<img src="arquivos/UFFeScience_LinkedIn_Banner.jpeg" alt="UFFeScience Research Group banner">
<div>
<p>Follow the <a href="https://www.linkedin.com/company/uffescience-research-group/about/" target="_blank">UFFeScience page on LinkedIn</a> and connect with our dynamic research community!</p>
<blockquote class="quote">“...without clean data, or clean enough data, your data science is worthless.”<cite>— Michael Stonebraker</cite></blockquote>
<div class="intro-actions">
<a class="quiet-link" href="https://uffescience.ic.uff.br" target="_blank" rel="noreferrer">Visit uffescience.ic.uff.br <svg class="icon" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" aria-hidden="true"><path d="M7 7h10v10"/><path d="M7 17 17 7"/></svg></a>
</div>
</div>
</div>
</section>
<section class="section tinted" id="location">
<div class="kicker">CONTACT / MAILING ADDRESS / LOCATION</div>
<h2>Where to find me</h2>
<div class="location-grid">
<div class="location-card">
<div>
<p class="location-label">Mailing address</p>
<address>
<strong>Daniel de Oliveira</strong>
Institute of Computing (IC/UFF)<br>
Universidade Federal Fluminense<br>
Av. Gal. Milton Tavares de Souza, s/n<br>
Campus da Praia Vermelha, Boa Viagem<br>
Niterói, RJ, 24210-346, Brazil
</address>
</div>
<div>
<p class="location-label">Contact</p>
<p class="location-contact">
Phone <b>+55 (21) 2629-5637</b><br>
<b>danielcmo (at) ic (dot) uff (dot) br</b>
</p>
</div>
<div class="location-actions">
<a class="quiet-link" href="https://www.google.com/maps/search/?api=1&query=Instituto+de+Computa%C3%A7%C3%A3o+UFF+Campus+Praia+Vermelha+Niter%C3%B3i" target="_blank" rel="noreferrer">Open in Google Maps <svg class="icon" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" aria-hidden="true"><path d="M7 7h10v10"/><path d="M7 17 17 7"/></svg></a>
<a class="quiet-link" href="https://www.google.com/maps/dir/?api=1&destination=Instituto+de+Computa%C3%A7%C3%A3o+UFF+Campus+Praia+Vermelha+Niter%C3%B3i" target="_blank" rel="noreferrer">Get directions <svg class="icon" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" aria-hidden="true"><path d="M7 7h10v10"/><path d="M7 17 17 7"/></svg></a>
</div>
</div>
<div class="location-map">
<iframe
src="https://maps.google.com/maps?q=Instituto%20de%20Computa%C3%A7%C3%A3o%20UFF%2C%20Av.%20Gal.%20Milton%20Tavares%20de%20Souza%2C%20Niter%C3%B3i&z=16&hl=en&output=embed"
title="Map showing the Institute of Computing at UFF, Campus Praia Vermelha, Niterói"
loading="lazy"
referrerpolicy="no-referrer-when-downgrade"
allowfullscreen></iframe>
</div>
</div>
</section>
</main>
<footer>
<div class="footer-brand">
<img src="arquivos/Daniel.jpeg" alt="" width="60" height="60" style="border-radius:50%;object-fit:cover">
<p>Daniel de Oliveira
<small>Associate Professor · Institute of Computing · Universidade Federal Fluminense</small>
</p>
</div>
<div class="footer-contact">
Phone <b>+55 (21) 2629-5637</b> · Fax <b>+55 (21) 2629-5627</b><br>
<b>danielcmo (at) ic (dot) uff (dot) br</b>
</div>
<div class="footer-institutions" aria-label="Institutional affiliations">
<a href="https://uffescience.ic.uff.br" target="_blank" rel="noreferrer"><img src="assets/uffescience-logo.png" alt="UFFeScience Research Group" width="52" height="52"></a>
<a href="https://www.ic.uff.br/" target="_blank" rel="noreferrer"><img src="assets/ic-uff-logo.png" alt="Institute of Computing — UFF" width="69" height="52"></a>
<a href="https://www.uff.br/" target="_blank" rel="noreferrer"><img src="assets/uff-logo.svg" alt="Universidade Federal Fluminense" width="84" height="40" style="height:40px"></a>
</div>
<a href="#inicio">Back to top ↑</a>
</footer>
<script>
/* ---------- Two-level navigation (move to a shared assets/nav.js to reuse on every page) ---------- */
(function () {
const nav = document.querySelector('.main-nav');
if (!nav) return;
const groups = Array.from(nav.querySelectorAll('.nav-group'));
// Mark the current page automatically, so the same nav markup works on every page
const here = (location.pathname.split('/').pop() || 'index.html').toLowerCase();
nav.querySelectorAll('a[href]').forEach(a => {
if (a.getAttribute('href').toLowerCase() === here) {
a.setAttribute('aria-current', 'page');
const g = a.closest('.nav-group');
if (g) g.classList.add('has-current');
}
});
function setOpen(group, open) {
group.classList.toggle('is-open', open);
group.querySelector('.nav-toggle').setAttribute('aria-expanded', open ? 'true' : 'false');
}
function closeAll(except) { groups.forEach(g => { if (g !== except) setOpen(g, false); }); }
groups.forEach(group => {
const toggle = group.querySelector('.nav-toggle');
toggle.addEventListener('click', () => {
const open = !group.classList.contains('is-open');
closeAll(group);
setOpen(group, open);
});
group.addEventListener('keydown', e => {
if (e.key === 'Escape' && group.classList.contains('is-open')) {
setOpen(group, false);
toggle.focus();
}
});
group.addEventListener('focusout', e => {
if (!group.contains(e.relatedTarget)) setOpen(group, false);
});
if (window.matchMedia('(hover: hover)').matches) {
group.addEventListener('mouseleave', () => setOpen(group, false));
}
});
document.addEventListener('click', e => { if (!nav.contains(e.target)) closeAll(); });
})();
/* ---------- Photo carousel ---------- */
(function () {
const root = document.querySelector('.carousel');
if (!root) return;
const slides = Array.from(root.querySelectorAll('.carousel-track > figure'));
const dotsBox = root.querySelector('.carousel-dots');
const INTERVAL = 6000;
const reduceMotion = window.matchMedia('(prefers-reduced-motion: reduce)').matches;
let current = 0, timer = null;
const dots = slides.map((_, i) => {
const b = document.createElement('button');
b.type = 'button';
b.setAttribute('aria-label', 'Show photo ' + (i + 1));
b.addEventListener('click', () => { go(i); restart(); });
dotsBox.appendChild(b);
return b;
});
function go(i) {
current = (i + slides.length) % slides.length;
slides.forEach((s, k) => {
s.classList.toggle('is-active', k === current);
s.setAttribute('aria-hidden', k === current ? 'false' : 'true');
});
dots.forEach((d, k) => d.setAttribute('aria-current', k === current ? 'true' : 'false'));
}
function start() { if (!reduceMotion && slides.length > 1) timer = setInterval(() => go(current + 1), INTERVAL); }
function stop() { clearInterval(timer); timer = null; }
function restart() { stop(); start(); }
root.querySelector('.prev').addEventListener('click', () => { go(current - 1); restart(); });
root.querySelector('.next').addEventListener('click', () => { go(current + 1); restart(); });
root.addEventListener('mouseenter', stop);
root.addEventListener('mouseleave', start);
root.addEventListener('focusin', stop);
root.addEventListener('focusout', start);
// swipe on touch screens
let x0 = null;
root.addEventListener('touchstart', e => { x0 = e.touches[0].clientX; }, { passive: true });
root.addEventListener('touchend', e => {
if (x0 === null) return;
const dx = e.changedTouches[0].clientX - x0;
if (Math.abs(dx) > 40) { go(current + (dx < 0 ? 1 : -1)); restart(); }
x0 = null;
});
go(0);
start();
})();
</script>
</body>
</html>