Spaces:
Running
Running
Update index.html
Browse files- index.html +263 -208
index.html
CHANGED
|
@@ -3,19 +3,28 @@
|
|
| 3 |
<head>
|
| 4 |
<meta charset="utf-8" />
|
| 5 |
<meta name="viewport" content="width=device-width, initial-scale=1, viewport-fit=cover" />
|
| 6 |
-
<meta name="theme-color" content="#
|
| 7 |
-
<title>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 8 |
<style>
|
| 9 |
:root {
|
| 10 |
-
--
|
| 11 |
-
--blue: #
|
| 12 |
-
--
|
| 13 |
-
--
|
| 14 |
-
--
|
| 15 |
-
--
|
| 16 |
-
--
|
| 17 |
-
--
|
| 18 |
-
--
|
|
|
|
|
|
|
|
|
|
| 19 |
}
|
| 20 |
|
| 21 |
* { box-sizing: border-box; }
|
|
@@ -25,51 +34,54 @@
|
|
| 25 |
width: 100%;
|
| 26 |
min-height: 100%;
|
| 27 |
margin: 0;
|
| 28 |
-
font-family:
|
| 29 |
-
color: var(--
|
| 30 |
-
background:
|
| 31 |
overflow-x: hidden;
|
| 32 |
}
|
| 33 |
|
| 34 |
body {
|
| 35 |
min-height: 100svh;
|
| 36 |
background:
|
| 37 |
-
radial-gradient(circle at
|
| 38 |
-
radial-gradient(circle at 88%
|
| 39 |
-
radial-gradient(circle at 50%
|
| 40 |
-
linear-gradient(
|
| 41 |
}
|
| 42 |
|
| 43 |
-
body::before
|
| 44 |
-
body::after {
|
| 45 |
content: "";
|
| 46 |
position: fixed;
|
| 47 |
-
|
| 48 |
-
|
| 49 |
-
|
| 50 |
-
height: 33vh;
|
| 51 |
pointer-events: none;
|
| 52 |
-
|
| 53 |
background:
|
| 54 |
-
|
| 55 |
-
|
| 56 |
-
|
| 57 |
-
|
| 58 |
-
opacity: .75;
|
| 59 |
-
animation: wave 7s ease-in-out infinite alternate;
|
| 60 |
}
|
| 61 |
|
| 62 |
body::after {
|
| 63 |
-
|
| 64 |
-
|
| 65 |
-
|
| 66 |
-
|
| 67 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 68 |
}
|
| 69 |
|
| 70 |
-
@keyframes
|
| 71 |
-
from { transform: translateX(-
|
| 72 |
-
to { transform: translateX(
|
| 73 |
}
|
| 74 |
|
| 75 |
.app {
|
|
@@ -82,151 +94,158 @@
|
|
| 82 |
}
|
| 83 |
|
| 84 |
.card {
|
|
|
|
| 85 |
width: min(100%, 460px);
|
|
|
|
|
|
|
|
|
|
|
|
|
| 86 |
border-radius: 36px;
|
| 87 |
overflow: hidden;
|
| 88 |
-
border: 1px solid rgba(255,255,255,.
|
| 89 |
-
background:
|
|
|
|
|
|
|
| 90 |
box-shadow: var(--shadow);
|
| 91 |
-
backdrop-filter: blur(
|
| 92 |
-
-webkit-backdrop-filter: blur(
|
| 93 |
animation: enter .72s cubic-bezier(.2,.9,.2,1.12) both;
|
| 94 |
}
|
| 95 |
|
| 96 |
-
|
| 97 |
-
|
| 98 |
-
|
| 99 |
-
|
| 100 |
-
|
| 101 |
-
|
| 102 |
-
|
| 103 |
-
padding: 32px 24px 22px;
|
| 104 |
-
text-align: center;
|
| 105 |
-
isolation: isolate;
|
| 106 |
}
|
| 107 |
|
| 108 |
-
.
|
| 109 |
content: "";
|
| 110 |
position: absolute;
|
| 111 |
-
top: 8px;
|
| 112 |
left: 50%;
|
| 113 |
-
|
| 114 |
-
|
|
|
|
|
|
|
| 115 |
border-radius: 50%;
|
| 116 |
-
|
|
|
|
|
|
|
|
|
|
| 117 |
z-index: -1;
|
| 118 |
-
|
| 119 |
-
animation: sunPulse 4s ease-in-out infinite alternate;
|
| 120 |
}
|
| 121 |
|
| 122 |
-
@keyframes
|
| 123 |
-
from { opacity:
|
| 124 |
-
to { opacity: 1; transform:
|
| 125 |
}
|
| 126 |
|
| 127 |
-
|
| 128 |
-
|
| 129 |
-
|
| 130 |
-
|
| 131 |
-
|
| 132 |
-
|
| 133 |
-
|
| 134 |
-
|
| 135 |
-
|
| 136 |
-
|
| 137 |
-
font-size: 12px;
|
| 138 |
-
font-weight: 950;
|
| 139 |
-
letter-spacing: .12em;
|
| 140 |
-
text-transform: uppercase;
|
| 141 |
}
|
| 142 |
|
| 143 |
h1 {
|
| 144 |
-
margin:
|
| 145 |
max-width: 8ch;
|
| 146 |
-
|
|
|
|
| 147 |
line-height: .86;
|
| 148 |
letter-spacing: -.07em;
|
| 149 |
-
|
| 150 |
text-wrap: balance;
|
| 151 |
}
|
| 152 |
|
| 153 |
-
.
|
| 154 |
-
|
| 155 |
-
|
| 156 |
-
color:
|
| 157 |
-
font-
|
| 158 |
-
|
| 159 |
-
|
|
|
|
|
|
|
|
|
|
| 160 |
}
|
| 161 |
|
| 162 |
.islands {
|
| 163 |
display: flex;
|
| 164 |
justify-content: center;
|
| 165 |
align-items: end;
|
| 166 |
-
gap:
|
| 167 |
-
height:
|
| 168 |
-
margin-top:
|
| 169 |
}
|
| 170 |
|
| 171 |
.island {
|
| 172 |
display: block;
|
| 173 |
border-radius: 999px 999px 22px 22px;
|
| 174 |
-
background: linear-gradient(180deg, #
|
| 175 |
-
box-shadow: inset 0 -
|
| 176 |
animation: bob 3.2s ease-in-out infinite;
|
| 177 |
}
|
| 178 |
|
| 179 |
-
.island:nth-child(1) { width: 42px; height:
|
| 180 |
-
.island:nth-child(2) { width:
|
| 181 |
-
.island:nth-child(3) { width:
|
| 182 |
|
| 183 |
@keyframes bob {
|
| 184 |
0%, 100% { transform: translateY(0); }
|
| 185 |
-
50% { transform: translateY(-
|
| 186 |
}
|
| 187 |
|
| 188 |
.form {
|
| 189 |
-
padding:
|
| 190 |
}
|
| 191 |
|
| 192 |
label {
|
| 193 |
display: block;
|
| 194 |
-
margin: 0 0
|
| 195 |
-
color: rgba(
|
| 196 |
font-size: 12px;
|
| 197 |
-
font-weight:
|
| 198 |
-
letter-spacing: .
|
| 199 |
text-transform: uppercase;
|
| 200 |
}
|
| 201 |
|
| 202 |
input {
|
| 203 |
width: 100%;
|
| 204 |
-
min-height:
|
| 205 |
border: 0;
|
| 206 |
outline: none;
|
| 207 |
border-radius: 24px;
|
| 208 |
padding: 0 18px;
|
| 209 |
-
color: var(--
|
| 210 |
-
background: rgba(255,255,255,.
|
| 211 |
-
font-size:
|
| 212 |
-
font-weight:
|
| 213 |
box-shadow:
|
| 214 |
-
inset 0 0 0 1px rgba(
|
| 215 |
-
0
|
| 216 |
transition: transform .18s ease, box-shadow .18s ease, background .18s ease;
|
| 217 |
}
|
| 218 |
|
| 219 |
input::placeholder {
|
| 220 |
-
color: rgba(
|
| 221 |
-
font-weight:
|
| 222 |
}
|
| 223 |
|
| 224 |
input:focus {
|
| 225 |
transform: translateY(-1px);
|
| 226 |
background: #fff;
|
| 227 |
box-shadow:
|
| 228 |
-
inset 0 0 0 2px rgba(
|
| 229 |
-
0 18px
|
| 230 |
}
|
| 231 |
|
| 232 |
.discover {
|
|
@@ -238,14 +257,14 @@
|
|
| 238 |
border-radius: 24px;
|
| 239 |
overflow: hidden;
|
| 240 |
cursor: pointer;
|
| 241 |
-
color: #
|
| 242 |
background:
|
| 243 |
-
linear-gradient(
|
| 244 |
-
linear-gradient(135deg,
|
| 245 |
-
box-shadow: 0
|
| 246 |
-
font-size:
|
| 247 |
-
font-weight:
|
| 248 |
-
letter-spacing: -.
|
| 249 |
transition: transform .16s ease, filter .16s ease;
|
| 250 |
}
|
| 251 |
|
|
@@ -256,9 +275,9 @@
|
|
| 256 |
left: -46%;
|
| 257 |
width: 35%;
|
| 258 |
height: 280%;
|
| 259 |
-
background: rgba(255,255,255,.
|
| 260 |
transform: rotate(23deg);
|
| 261 |
-
animation: shine 3.
|
| 262 |
}
|
| 263 |
|
| 264 |
@keyframes shine {
|
|
@@ -285,15 +304,15 @@
|
|
| 285 |
}
|
| 286 |
|
| 287 |
.message-card {
|
| 288 |
-
border-radius:
|
| 289 |
-
padding:
|
| 290 |
text-align: center;
|
| 291 |
-
color: rgba(
|
| 292 |
-
background: rgba(255,255,255,.
|
| 293 |
-
border: 1px solid rgba(
|
| 294 |
-
box-shadow: 0
|
| 295 |
font-size: 14px;
|
| 296 |
-
font-weight:
|
| 297 |
line-height: 1.35;
|
| 298 |
}
|
| 299 |
|
|
@@ -303,13 +322,13 @@
|
|
| 303 |
z-index: 20;
|
| 304 |
display: grid;
|
| 305 |
place-items: center;
|
| 306 |
-
padding: max(
|
| 307 |
-
color:
|
| 308 |
background:
|
| 309 |
-
radial-gradient(circle at
|
| 310 |
-
radial-gradient(circle at
|
| 311 |
-
radial-gradient(circle at
|
| 312 |
-
linear-gradient(
|
| 313 |
opacity: 0;
|
| 314 |
pointer-events: none;
|
| 315 |
transform: scale(1.03);
|
|
@@ -323,69 +342,82 @@
|
|
| 323 |
transform: scale(1);
|
| 324 |
}
|
| 325 |
|
| 326 |
-
.reveal::before
|
| 327 |
-
.reveal::after {
|
| 328 |
content: "";
|
| 329 |
position: absolute;
|
| 330 |
-
|
| 331 |
-
|
| 332 |
-
|
| 333 |
-
|
| 334 |
background:
|
| 335 |
-
|
| 336 |
-
|
| 337 |
-
|
| 338 |
-
opacity: .56;
|
| 339 |
-
animation: revealWave 6s ease-in-out infinite alternate;
|
| 340 |
}
|
| 341 |
|
| 342 |
.reveal::after {
|
| 343 |
-
|
| 344 |
-
|
| 345 |
-
|
| 346 |
-
|
| 347 |
-
|
| 348 |
-
|
| 349 |
-
|
| 350 |
-
|
| 351 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
| 352 |
}
|
| 353 |
|
| 354 |
.reveal-content {
|
| 355 |
position: relative;
|
| 356 |
z-index: 2;
|
| 357 |
-
width: min(100%,
|
| 358 |
-
min-height: min(
|
| 359 |
display: flex;
|
| 360 |
flex-direction: column;
|
| 361 |
align-items: center;
|
| 362 |
justify-content: center;
|
| 363 |
text-align: center;
|
| 364 |
border-radius: 38px;
|
| 365 |
-
padding:
|
| 366 |
-
background:
|
| 367 |
-
border: 1px solid rgba(255,255,255,.
|
| 368 |
-
box-shadow: 0
|
| 369 |
backdrop-filter: blur(18px);
|
| 370 |
-webkit-backdrop-filter: blur(18px);
|
| 371 |
-
animation: revealPop .
|
|
|
|
| 372 |
}
|
| 373 |
|
| 374 |
-
.reveal
|
| 375 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 376 |
}
|
| 377 |
|
| 378 |
@keyframes revealPop {
|
| 379 |
-
from { opacity: 0; transform: translateY(32px) scale(.86) rotate(-1.
|
| 380 |
-
60% { opacity: 1; transform: translateY(-4px) scale(1.03) rotate(.
|
| 381 |
to { opacity: 1; transform: translateY(0) scale(1) rotate(0); filter: blur(0); }
|
| 382 |
}
|
| 383 |
|
| 384 |
.hello {
|
| 385 |
-
margin: 0 0
|
| 386 |
-
color: rgba(
|
| 387 |
-
font-size: clamp(
|
| 388 |
-
font-weight:
|
| 389 |
letter-spacing: .02em;
|
| 390 |
}
|
| 391 |
|
|
@@ -393,53 +425,62 @@
|
|
| 393 |
display: inline-flex;
|
| 394 |
align-items: center;
|
| 395 |
justify-content: center;
|
| 396 |
-
|
| 397 |
-
margin-bottom: 16px;
|
| 398 |
padding: 10px 14px;
|
| 399 |
border-radius: 999px;
|
| 400 |
-
color:
|
| 401 |
-
background:
|
| 402 |
-
box-shadow: 0
|
| 403 |
-
font-size:
|
| 404 |
-
font-weight:
|
| 405 |
-
letter-spacing: .
|
| 406 |
text-transform: uppercase;
|
| 407 |
}
|
| 408 |
|
| 409 |
.table-name {
|
| 410 |
margin: 0;
|
| 411 |
-
max-width:
|
| 412 |
-
color:
|
| 413 |
-
font-
|
| 414 |
-
|
| 415 |
-
|
| 416 |
-
|
| 417 |
-
|
| 418 |
-
0 8px 0 rgba(0,0,0,.10),
|
| 419 |
-
0 24px 52px rgba(0,0,0,.28);
|
| 420 |
text-wrap: balance;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 421 |
}
|
| 422 |
|
| 423 |
.reveal-note {
|
| 424 |
-
margin:
|
| 425 |
max-width: 26ch;
|
| 426 |
-
color: rgba(
|
| 427 |
-
font-size:
|
| 428 |
line-height: 1.35;
|
| 429 |
-
font-weight:
|
| 430 |
}
|
| 431 |
|
| 432 |
.again {
|
| 433 |
min-height: 52px;
|
| 434 |
-
margin-top:
|
| 435 |
border: 0;
|
| 436 |
border-radius: 999px;
|
| 437 |
padding: 0 22px;
|
| 438 |
-
color: #
|
| 439 |
-
background:
|
| 440 |
-
box-shadow: 0
|
| 441 |
-
font-size:
|
| 442 |
-
font-weight:
|
| 443 |
cursor: pointer;
|
| 444 |
}
|
| 445 |
|
|
@@ -463,8 +504,10 @@
|
|
| 463 |
|
| 464 |
@media (max-width: 380px) {
|
| 465 |
.app { padding-left: 12px; padding-right: 12px; }
|
| 466 |
-
.
|
| 467 |
-
.
|
|
|
|
|
|
|
| 468 |
input, .discover { min-height: 60px; border-radius: 22px; }
|
| 469 |
.reveal-content { border-radius: 32px; padding-left: 16px; padding-right: 16px; }
|
| 470 |
}
|
|
@@ -485,9 +528,8 @@
|
|
| 485 |
<main class="app">
|
| 486 |
<section class="card" aria-label="Scopri il tavolo">
|
| 487 |
<div class="hero">
|
| 488 |
-
<div class="badge">💍 Tableau de Mariage</div>
|
| 489 |
<h1>Trova la tua Cala</h1>
|
| 490 |
-
<
|
| 491 |
<div class="islands" aria-hidden="true">
|
| 492 |
<span class="island"></span>
|
| 493 |
<span class="island"></span>
|
|
@@ -508,17 +550,30 @@
|
|
| 508 |
<section id="reveal" class="reveal" aria-live="assertive" aria-hidden="true">
|
| 509 |
<div class="reveal-content">
|
| 510 |
<p class="hello" id="hello"></p>
|
| 511 |
-
<div class="small-title">
|
| 512 |
<h2 class="table-name" id="tableName"></h2>
|
| 513 |
-
<
|
|
|
|
| 514 |
<button class="again" id="again" type="button">Cerca un altro nome</button>
|
| 515 |
</div>
|
| 516 |
</section>
|
| 517 |
|
| 518 |
<script>
|
| 519 |
-
const DATA_URL = "
|
| 520 |
-
|
| 521 |
-
const SAMPLE_CSV = `
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 522 |
|
| 523 |
const els = {
|
| 524 |
input: document.getElementById("guestName"),
|
|
@@ -701,13 +756,13 @@
|
|
| 701 |
|
| 702 |
function celebrate() {
|
| 703 |
resizeCanvas();
|
| 704 |
-
const colors = ["#
|
| 705 |
const centerX = window.innerWidth / 2;
|
| 706 |
const centerY = window.innerHeight * .42;
|
| 707 |
|
| 708 |
-
confetti = Array.from({ length:
|
| 709 |
const angle = Math.random() * Math.PI * 2;
|
| 710 |
-
const speed = 4 + Math.random() *
|
| 711 |
return {
|
| 712 |
x: centerX,
|
| 713 |
y: centerY,
|
|
|
|
| 3 |
<head>
|
| 4 |
<meta charset="utf-8" />
|
| 5 |
<meta name="viewport" content="width=device-width, initial-scale=1, viewport-fit=cover" />
|
| 6 |
+
<meta name="theme-color" content="#F3EFE9" />
|
| 7 |
+
<title>Trova la tua Cala</title>
|
| 8 |
+
|
| 9 |
+
<!-- Montserrat è il font pulito del moodboard. Amsterdam One viene usato se disponibile nel device/sito. -->
|
| 10 |
+
<link rel="preconnect" href="https://fonts.googleapis.com">
|
| 11 |
+
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
|
| 12 |
+
<link href="https://fonts.googleapis.com/css2?family=Montserrat:wght@400;500;600;700;800;900&display=swap" rel="stylesheet">
|
| 13 |
+
|
| 14 |
<style>
|
| 15 |
:root {
|
| 16 |
+
--blue: #254B6B;
|
| 17 |
+
--blue-soft: #8FA3B3;
|
| 18 |
+
--olive: #939675;
|
| 19 |
+
--sage: #C2C5B2;
|
| 20 |
+
--coral: #D08A7A;
|
| 21 |
+
--rose: #EDD3CD;
|
| 22 |
+
--cream: #F3EFE9;
|
| 23 |
+
--paper: rgba(255, 253, 248, .86);
|
| 24 |
+
--white: #fffaf4;
|
| 25 |
+
--shadow: 0 28px 80px rgba(37, 75, 107, .18);
|
| 26 |
+
--font-main: "Montserrat", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
|
| 27 |
+
--font-script: "Amsterdam One", "Amsterdam", "Allura", "Great Vibes", "Snell Roundhand", "Brush Script MT", cursive;
|
| 28 |
}
|
| 29 |
|
| 30 |
* { box-sizing: border-box; }
|
|
|
|
| 34 |
width: 100%;
|
| 35 |
min-height: 100%;
|
| 36 |
margin: 0;
|
| 37 |
+
font-family: var(--font-main);
|
| 38 |
+
color: var(--blue);
|
| 39 |
+
background: var(--cream);
|
| 40 |
overflow-x: hidden;
|
| 41 |
}
|
| 42 |
|
| 43 |
body {
|
| 44 |
min-height: 100svh;
|
| 45 |
background:
|
| 46 |
+
radial-gradient(circle at 17% 13%, rgba(237, 211, 205, .72) 0 9%, transparent 31%),
|
| 47 |
+
radial-gradient(circle at 88% 11%, rgba(194, 197, 178, .58) 0 10%, transparent 30%),
|
| 48 |
+
radial-gradient(circle at 50% 94%, rgba(143, 163, 179, .18) 0 18%, transparent 48%),
|
| 49 |
+
linear-gradient(180deg, #fffaf4 0%, #f3efe9 64%, #eee7de 100%);
|
| 50 |
}
|
| 51 |
|
| 52 |
+
body::before {
|
|
|
|
| 53 |
content: "";
|
| 54 |
position: fixed;
|
| 55 |
+
inset: -10vh -20vw auto auto;
|
| 56 |
+
width: 90vw;
|
| 57 |
+
height: 88vh;
|
|
|
|
| 58 |
pointer-events: none;
|
| 59 |
+
opacity: .18;
|
| 60 |
background:
|
| 61 |
+
repeating-conic-gradient(from 198deg at 72% 48%, transparent 0deg 7deg, rgba(147,150,117,.54) 7deg 9deg, transparent 9deg 15deg);
|
| 62 |
+
transform: rotate(-10deg);
|
| 63 |
+
filter: blur(.5px);
|
| 64 |
+
z-index: 0;
|
|
|
|
|
|
|
| 65 |
}
|
| 66 |
|
| 67 |
body::after {
|
| 68 |
+
content: "";
|
| 69 |
+
position: fixed;
|
| 70 |
+
inset: auto -15vw -18vh -15vw;
|
| 71 |
+
height: 34vh;
|
| 72 |
+
pointer-events: none;
|
| 73 |
+
opacity: .26;
|
| 74 |
+
background:
|
| 75 |
+
radial-gradient(80% 90% at 50% 0%, rgba(143,163,179,.55) 0 11%, transparent 12%),
|
| 76 |
+
radial-gradient(80% 90% at 16% 7%, rgba(143,163,179,.36) 0 11%, transparent 12%),
|
| 77 |
+
radial-gradient(80% 90% at 84% 6%, rgba(143,163,179,.30) 0 11%, transparent 12%);
|
| 78 |
+
animation: softWave 8s ease-in-out infinite alternate;
|
| 79 |
+
z-index: 0;
|
| 80 |
}
|
| 81 |
|
| 82 |
+
@keyframes softWave {
|
| 83 |
+
from { transform: translateX(-3vw) rotate(-1.5deg); }
|
| 84 |
+
to { transform: translateX(3vw) translateY(-1vh) rotate(1deg); }
|
| 85 |
}
|
| 86 |
|
| 87 |
.app {
|
|
|
|
| 94 |
}
|
| 95 |
|
| 96 |
.card {
|
| 97 |
+
position: relative;
|
| 98 |
width: min(100%, 460px);
|
| 99 |
+
min-height: min(92svh, 760px);
|
| 100 |
+
display: flex;
|
| 101 |
+
flex-direction: column;
|
| 102 |
+
justify-content: center;
|
| 103 |
border-radius: 36px;
|
| 104 |
overflow: hidden;
|
| 105 |
+
border: 1px solid rgba(255,255,255,.88);
|
| 106 |
+
background:
|
| 107 |
+
linear-gradient(180deg, rgba(255,255,255,.74), rgba(255,250,244,.58)),
|
| 108 |
+
radial-gradient(circle at 50% 22%, rgba(237,211,205,.55), transparent 28%);
|
| 109 |
box-shadow: var(--shadow);
|
| 110 |
+
backdrop-filter: blur(22px);
|
| 111 |
+
-webkit-backdrop-filter: blur(22px);
|
| 112 |
animation: enter .72s cubic-bezier(.2,.9,.2,1.12) both;
|
| 113 |
}
|
| 114 |
|
| 115 |
+
.card::before {
|
| 116 |
+
content: "";
|
| 117 |
+
position: absolute;
|
| 118 |
+
inset: 26px;
|
| 119 |
+
border-radius: 29px;
|
| 120 |
+
border: 1px solid rgba(37,75,107,.10);
|
| 121 |
+
pointer-events: none;
|
|
|
|
|
|
|
|
|
|
| 122 |
}
|
| 123 |
|
| 124 |
+
.card::after {
|
| 125 |
content: "";
|
| 126 |
position: absolute;
|
|
|
|
| 127 |
left: 50%;
|
| 128 |
+
top: 24%;
|
| 129 |
+
width: 280px;
|
| 130 |
+
height: 280px;
|
| 131 |
+
transform: translate(-50%, -50%);
|
| 132 |
border-radius: 50%;
|
| 133 |
+
background:
|
| 134 |
+
radial-gradient(circle, rgba(237,211,205,.50) 0 26%, transparent 27%),
|
| 135 |
+
radial-gradient(circle, rgba(208,138,122,.18) 0 44%, transparent 45%);
|
| 136 |
+
pointer-events: none;
|
| 137 |
z-index: -1;
|
| 138 |
+
animation: halo 5s ease-in-out infinite alternate;
|
|
|
|
| 139 |
}
|
| 140 |
|
| 141 |
+
@keyframes enter {
|
| 142 |
+
from { opacity: 0; transform: translateY(24px) scale(.97); }
|
| 143 |
+
to { opacity: 1; transform: translateY(0) scale(1); }
|
| 144 |
}
|
| 145 |
|
| 146 |
+
@keyframes halo {
|
| 147 |
+
from { opacity: .64; transform: translate(-50%, -50%) scale(.96); }
|
| 148 |
+
to { opacity: 1; transform: translate(-50%, -50%) scale(1.06); }
|
| 149 |
+
}
|
| 150 |
+
|
| 151 |
+
.hero {
|
| 152 |
+
position: relative;
|
| 153 |
+
padding: 42px 28px 30px;
|
| 154 |
+
text-align: center;
|
| 155 |
+
isolation: isolate;
|
|
|
|
|
|
|
|
|
|
|
|
|
| 156 |
}
|
| 157 |
|
| 158 |
h1 {
|
| 159 |
+
margin: 0 auto;
|
| 160 |
max-width: 8ch;
|
| 161 |
+
color: var(--blue);
|
| 162 |
+
font-size: clamp(55px, 15vw, 82px);
|
| 163 |
line-height: .86;
|
| 164 |
letter-spacing: -.07em;
|
| 165 |
+
font-weight: 900;
|
| 166 |
text-wrap: balance;
|
| 167 |
}
|
| 168 |
|
| 169 |
+
.script-mark {
|
| 170 |
+
display: block;
|
| 171 |
+
margin: 10px auto 0;
|
| 172 |
+
color: var(--coral);
|
| 173 |
+
font-family: var(--font-script);
|
| 174 |
+
font-size: clamp(32px, 9vw, 54px);
|
| 175 |
+
line-height: .95;
|
| 176 |
+
font-weight: 400;
|
| 177 |
+
letter-spacing: .01em;
|
| 178 |
+
opacity: .95;
|
| 179 |
}
|
| 180 |
|
| 181 |
.islands {
|
| 182 |
display: flex;
|
| 183 |
justify-content: center;
|
| 184 |
align-items: end;
|
| 185 |
+
gap: 8px;
|
| 186 |
+
height: 42px;
|
| 187 |
+
margin-top: 28px;
|
| 188 |
}
|
| 189 |
|
| 190 |
.island {
|
| 191 |
display: block;
|
| 192 |
border-radius: 999px 999px 22px 22px;
|
| 193 |
+
background: linear-gradient(180deg, #edd3cd 0%, #d08a7a 62%, #c47c70 100%);
|
| 194 |
+
box-shadow: inset 0 -7px 0 rgba(37,75,107,.07);
|
| 195 |
animation: bob 3.2s ease-in-out infinite;
|
| 196 |
}
|
| 197 |
|
| 198 |
+
.island:nth-child(1) { width: 42px; height: 14px; animation-delay: -.15s; background: linear-gradient(180deg, #c2c5b2, #939675); }
|
| 199 |
+
.island:nth-child(2) { width: 84px; height: 27px; animation-delay: -.55s; }
|
| 200 |
+
.island:nth-child(3) { width: 36px; height: 13px; animation-delay: -.9s; background: linear-gradient(180deg, #c2c5b2, #939675); }
|
| 201 |
|
| 202 |
@keyframes bob {
|
| 203 |
0%, 100% { transform: translateY(0); }
|
| 204 |
+
50% { transform: translateY(-4px); }
|
| 205 |
}
|
| 206 |
|
| 207 |
.form {
|
| 208 |
+
padding: 2px 28px 46px;
|
| 209 |
}
|
| 210 |
|
| 211 |
label {
|
| 212 |
display: block;
|
| 213 |
+
margin: 0 0 12px;
|
| 214 |
+
color: rgba(37, 75, 107, .72);
|
| 215 |
font-size: 12px;
|
| 216 |
+
font-weight: 800;
|
| 217 |
+
letter-spacing: .14em;
|
| 218 |
text-transform: uppercase;
|
| 219 |
}
|
| 220 |
|
| 221 |
input {
|
| 222 |
width: 100%;
|
| 223 |
+
min-height: 66px;
|
| 224 |
border: 0;
|
| 225 |
outline: none;
|
| 226 |
border-radius: 24px;
|
| 227 |
padding: 0 18px;
|
| 228 |
+
color: var(--blue);
|
| 229 |
+
background: rgba(255,255,255,.88);
|
| 230 |
+
font-size: 17px;
|
| 231 |
+
font-weight: 700;
|
| 232 |
box-shadow:
|
| 233 |
+
inset 0 0 0 1px rgba(37,75,107,.08),
|
| 234 |
+
0 14px 30px rgba(37,75,107,.10);
|
| 235 |
transition: transform .18s ease, box-shadow .18s ease, background .18s ease;
|
| 236 |
}
|
| 237 |
|
| 238 |
input::placeholder {
|
| 239 |
+
color: rgba(37,75,107,.36);
|
| 240 |
+
font-weight: 700;
|
| 241 |
}
|
| 242 |
|
| 243 |
input:focus {
|
| 244 |
transform: translateY(-1px);
|
| 245 |
background: #fff;
|
| 246 |
box-shadow:
|
| 247 |
+
inset 0 0 0 2px rgba(208,138,122,.42),
|
| 248 |
+
0 18px 38px rgba(37,75,107,.14);
|
| 249 |
}
|
| 250 |
|
| 251 |
.discover {
|
|
|
|
| 257 |
border-radius: 24px;
|
| 258 |
overflow: hidden;
|
| 259 |
cursor: pointer;
|
| 260 |
+
color: #fffaf4;
|
| 261 |
background:
|
| 262 |
+
linear-gradient(110deg, rgba(255,255,255,.32), transparent 28% 70%, rgba(255,255,255,.24)),
|
| 263 |
+
linear-gradient(135deg, var(--blue) 0%, #315c7c 48%, var(--coral) 100%);
|
| 264 |
+
box-shadow: 0 18px 36px rgba(37,75,107,.22), inset 0 -3px 0 rgba(0,0,0,.10);
|
| 265 |
+
font-size: 17px;
|
| 266 |
+
font-weight: 800;
|
| 267 |
+
letter-spacing: -.01em;
|
| 268 |
transition: transform .16s ease, filter .16s ease;
|
| 269 |
}
|
| 270 |
|
|
|
|
| 275 |
left: -46%;
|
| 276 |
width: 35%;
|
| 277 |
height: 280%;
|
| 278 |
+
background: rgba(255,255,255,.54);
|
| 279 |
transform: rotate(23deg);
|
| 280 |
+
animation: shine 3.2s ease-in-out infinite;
|
| 281 |
}
|
| 282 |
|
| 283 |
@keyframes shine {
|
|
|
|
| 304 |
}
|
| 305 |
|
| 306 |
.message-card {
|
| 307 |
+
border-radius: 22px;
|
| 308 |
+
padding: 16px;
|
| 309 |
text-align: center;
|
| 310 |
+
color: rgba(37, 75, 107, .80);
|
| 311 |
+
background: rgba(255,255,255,.70);
|
| 312 |
+
border: 1px solid rgba(37,75,107,.08);
|
| 313 |
+
box-shadow: 0 12px 28px rgba(37,75,107,.10);
|
| 314 |
font-size: 14px;
|
| 315 |
+
font-weight: 700;
|
| 316 |
line-height: 1.35;
|
| 317 |
}
|
| 318 |
|
|
|
|
| 322 |
z-index: 20;
|
| 323 |
display: grid;
|
| 324 |
place-items: center;
|
| 325 |
+
padding: max(18px, env(safe-area-inset-top)) 16px max(20px, env(safe-area-inset-bottom));
|
| 326 |
+
color: var(--blue);
|
| 327 |
background:
|
| 328 |
+
radial-gradient(circle at 18% 12%, rgba(237,211,205,.78) 0 10%, transparent 32%),
|
| 329 |
+
radial-gradient(circle at 82% 14%, rgba(194,197,178,.64) 0 10%, transparent 32%),
|
| 330 |
+
radial-gradient(circle at 50% 94%, rgba(143,163,179,.20) 0 20%, transparent 54%),
|
| 331 |
+
linear-gradient(180deg, #fffaf4 0%, #f3efe9 74%, #eee7de 100%);
|
| 332 |
opacity: 0;
|
| 333 |
pointer-events: none;
|
| 334 |
transform: scale(1.03);
|
|
|
|
| 342 |
transform: scale(1);
|
| 343 |
}
|
| 344 |
|
| 345 |
+
.reveal::before {
|
|
|
|
| 346 |
content: "";
|
| 347 |
position: absolute;
|
| 348 |
+
inset: -5vh -12vw auto auto;
|
| 349 |
+
width: 90vw;
|
| 350 |
+
height: 90vh;
|
| 351 |
+
opacity: .18;
|
| 352 |
background:
|
| 353 |
+
repeating-conic-gradient(from 200deg at 70% 50%, transparent 0deg 7deg, rgba(147,150,117,.62) 7deg 9deg, transparent 9deg 16deg);
|
| 354 |
+
transform: rotate(-10deg);
|
| 355 |
+
z-index: 0;
|
|
|
|
|
|
|
| 356 |
}
|
| 357 |
|
| 358 |
.reveal::after {
|
| 359 |
+
content: "";
|
| 360 |
+
position: absolute;
|
| 361 |
+
left: -16vw;
|
| 362 |
+
right: -16vw;
|
| 363 |
+
bottom: -15vh;
|
| 364 |
+
height: 34vh;
|
| 365 |
+
opacity: .22;
|
| 366 |
+
background:
|
| 367 |
+
radial-gradient(80% 90% at 50% 0%, rgba(143,163,179,.55) 0 11%, transparent 12%),
|
| 368 |
+
radial-gradient(80% 90% at 16% 7%, rgba(143,163,179,.36) 0 11%, transparent 12%),
|
| 369 |
+
radial-gradient(80% 90% at 84% 6%, rgba(143,163,179,.30) 0 11%, transparent 12%);
|
| 370 |
+
animation: softWave 8s ease-in-out infinite alternate;
|
| 371 |
+
z-index: 0;
|
| 372 |
}
|
| 373 |
|
| 374 |
.reveal-content {
|
| 375 |
position: relative;
|
| 376 |
z-index: 2;
|
| 377 |
+
width: min(100%, 580px);
|
| 378 |
+
min-height: min(80svh, 760px);
|
| 379 |
display: flex;
|
| 380 |
flex-direction: column;
|
| 381 |
align-items: center;
|
| 382 |
justify-content: center;
|
| 383 |
text-align: center;
|
| 384 |
border-radius: 38px;
|
| 385 |
+
padding: 34px 22px;
|
| 386 |
+
background: rgba(255,250,244,.72);
|
| 387 |
+
border: 1px solid rgba(255,255,255,.86);
|
| 388 |
+
box-shadow: 0 36px 100px rgba(37,75,107,.20);
|
| 389 |
backdrop-filter: blur(18px);
|
| 390 |
-webkit-backdrop-filter: blur(18px);
|
| 391 |
+
animation: revealPop .74s cubic-bezier(.2,.9,.16,1.22) both;
|
| 392 |
+
overflow: hidden;
|
| 393 |
}
|
| 394 |
|
| 395 |
+
.reveal-content::before {
|
| 396 |
+
content: "";
|
| 397 |
+
position: absolute;
|
| 398 |
+
top: 30px;
|
| 399 |
+
left: 50%;
|
| 400 |
+
width: 210px;
|
| 401 |
+
height: 210px;
|
| 402 |
+
transform: translateX(-50%);
|
| 403 |
+
border-radius: 50%;
|
| 404 |
+
background:
|
| 405 |
+
radial-gradient(circle, rgba(237,211,205,.58) 0 27%, transparent 28%),
|
| 406 |
+
radial-gradient(circle, rgba(208,138,122,.16) 0 45%, transparent 46%);
|
| 407 |
+
z-index: -1;
|
| 408 |
}
|
| 409 |
|
| 410 |
@keyframes revealPop {
|
| 411 |
+
from { opacity: 0; transform: translateY(32px) scale(.86) rotate(-1.4deg); filter: blur(8px); }
|
| 412 |
+
60% { opacity: 1; transform: translateY(-4px) scale(1.03) rotate(.4deg); filter: blur(0); }
|
| 413 |
to { opacity: 1; transform: translateY(0) scale(1) rotate(0); filter: blur(0); }
|
| 414 |
}
|
| 415 |
|
| 416 |
.hello {
|
| 417 |
+
margin: 0 0 22px;
|
| 418 |
+
color: rgba(37, 75, 107, .72);
|
| 419 |
+
font-size: clamp(15px, 4.6vw, 21px);
|
| 420 |
+
font-weight: 700;
|
| 421 |
letter-spacing: .02em;
|
| 422 |
}
|
| 423 |
|
|
|
|
| 425 |
display: inline-flex;
|
| 426 |
align-items: center;
|
| 427 |
justify-content: center;
|
| 428 |
+
margin-bottom: 18px;
|
|
|
|
| 429 |
padding: 10px 14px;
|
| 430 |
border-radius: 999px;
|
| 431 |
+
color: var(--cream);
|
| 432 |
+
background: var(--olive);
|
| 433 |
+
box-shadow: 0 13px 28px rgba(147,150,117,.20);
|
| 434 |
+
font-size: 12px;
|
| 435 |
+
font-weight: 800;
|
| 436 |
+
letter-spacing: .15em;
|
| 437 |
text-transform: uppercase;
|
| 438 |
}
|
| 439 |
|
| 440 |
.table-name {
|
| 441 |
margin: 0;
|
| 442 |
+
max-width: 11ch;
|
| 443 |
+
color: var(--blue);
|
| 444 |
+
font-family: var(--font-main);
|
| 445 |
+
font-size: clamp(48px, 14vw, 96px);
|
| 446 |
+
line-height: .91;
|
| 447 |
+
letter-spacing: -.055em;
|
| 448 |
+
font-weight: 900;
|
|
|
|
|
|
|
| 449 |
text-wrap: balance;
|
| 450 |
+
text-shadow: 0 16px 36px rgba(37,75,107,.12);
|
| 451 |
+
}
|
| 452 |
+
|
| 453 |
+
.script-cala {
|
| 454 |
+
display: block;
|
| 455 |
+
margin-top: 16px;
|
| 456 |
+
color: var(--coral);
|
| 457 |
+
font-family: var(--font-script);
|
| 458 |
+
font-size: clamp(42px, 13vw, 82px);
|
| 459 |
+
line-height: .82;
|
| 460 |
+
font-weight: 400;
|
| 461 |
+
letter-spacing: .01em;
|
| 462 |
}
|
| 463 |
|
| 464 |
.reveal-note {
|
| 465 |
+
margin: 28px auto 0;
|
| 466 |
max-width: 26ch;
|
| 467 |
+
color: rgba(37, 75, 107, .72);
|
| 468 |
+
font-size: 15px;
|
| 469 |
line-height: 1.35;
|
| 470 |
+
font-weight: 600;
|
| 471 |
}
|
| 472 |
|
| 473 |
.again {
|
| 474 |
min-height: 52px;
|
| 475 |
+
margin-top: 28px;
|
| 476 |
border: 0;
|
| 477 |
border-radius: 999px;
|
| 478 |
padding: 0 22px;
|
| 479 |
+
color: #fffaf4;
|
| 480 |
+
background: var(--blue);
|
| 481 |
+
box-shadow: 0 16px 38px rgba(37,75,107,.22);
|
| 482 |
+
font-size: 14px;
|
| 483 |
+
font-weight: 800;
|
| 484 |
cursor: pointer;
|
| 485 |
}
|
| 486 |
|
|
|
|
| 504 |
|
| 505 |
@media (max-width: 380px) {
|
| 506 |
.app { padding-left: 12px; padding-right: 12px; }
|
| 507 |
+
.card { min-height: 90svh; border-radius: 32px; }
|
| 508 |
+
.hero { padding: 38px 20px 26px; }
|
| 509 |
+
h1 { font-size: clamp(50px, 15vw, 74px); }
|
| 510 |
+
.form { padding-left: 22px; padding-right: 22px; }
|
| 511 |
input, .discover { min-height: 60px; border-radius: 22px; }
|
| 512 |
.reveal-content { border-radius: 32px; padding-left: 16px; padding-right: 16px; }
|
| 513 |
}
|
|
|
|
| 528 |
<main class="app">
|
| 529 |
<section class="card" aria-label="Scopri il tavolo">
|
| 530 |
<div class="hero">
|
|
|
|
| 531 |
<h1>Trova la tua Cala</h1>
|
| 532 |
+
<span class="script-mark" aria-hidden="true">Tremiti</span>
|
| 533 |
<div class="islands" aria-hidden="true">
|
| 534 |
<span class="island"></span>
|
| 535 |
<span class="island"></span>
|
|
|
|
| 550 |
<section id="reveal" class="reveal" aria-live="assertive" aria-hidden="true">
|
| 551 |
<div class="reveal-content">
|
| 552 |
<p class="hello" id="hello"></p>
|
| 553 |
+
<div class="small-title">Il tuo tavolo è</div>
|
| 554 |
<h2 class="table-name" id="tableName"></h2>
|
| 555 |
+
<span class="script-cala" aria-hidden="true">buona cena</span>
|
| 556 |
+
<p class="reveal-note">Segui la tua cala e goditi la serata.</p>
|
| 557 |
<button class="again" id="again" type="button">Cerca un altro nome</button>
|
| 558 |
</div>
|
| 559 |
</section>
|
| 560 |
|
| 561 |
<script>
|
| 562 |
+
const DATA_URL = "";
|
| 563 |
+
|
| 564 |
+
const SAMPLE_CSV = `
|
| 565 |
+
Nome Cognome,Nome del tavolo
|
| 566 |
+
Gaia Pollastrini,Cala Matano
|
| 567 |
+
Matteo Bergamelli,Cala delle Arene
|
| 568 |
+
Luca Bianchi,Cala Tramontana
|
| 569 |
+
Sara Conti,Cala Spido
|
| 570 |
+
Marco De Santis,Cala Zio Cesare
|
| 571 |
+
Elena Ferri,Cala degli Inglesi
|
| 572 |
+
Davide Greco,Cala Tonda
|
| 573 |
+
Chiara Romano,Cala dei Benedettini
|
| 574 |
+
Alessandro Rinaldi,Cala Pietre di Fucile
|
| 575 |
+
Martina Esposito,Cala Sorrentino
|
| 576 |
+
`;
|
| 577 |
|
| 578 |
const els = {
|
| 579 |
input: document.getElementById("guestName"),
|
|
|
|
| 756 |
|
| 757 |
function celebrate() {
|
| 758 |
resizeCanvas();
|
| 759 |
+
const colors = ["#254B6B", "#8FA3B3", "#939675", "#C2C5B2", "#D08A7A", "#EDD3CD", "#F3EFE9"];
|
| 760 |
const centerX = window.innerWidth / 2;
|
| 761 |
const centerY = window.innerHeight * .42;
|
| 762 |
|
| 763 |
+
confetti = Array.from({ length: 180 }, () => {
|
| 764 |
const angle = Math.random() * Math.PI * 2;
|
| 765 |
+
const speed = 4 + Math.random() * 8.5;
|
| 766 |
return {
|
| 767 |
x: centerX,
|
| 768 |
y: centerY,
|