@toneflix/flipbook 0.0.0-stage → 0.2.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/style.css ADDED
@@ -0,0 +1,869 @@
1
+ /*
2
+ * Toneflix Flipbook styles, shared by the vanilla, React and Vue packages. Everything is scoped under `fb-` classes.
3
+ * Override the custom properties on `.fb-root` (or any ancestor) to restyle.
4
+ */
5
+
6
+ .fb-root,
7
+ .fb-page,
8
+ .fb-cover {
9
+ --fb-serif: 'Fraunces', ui-serif, Georgia, 'Times New Roman', serif;
10
+ --fb-sans: ui-sans-serif, system-ui, -apple-system, 'Segoe UI', sans-serif;
11
+ --fb-accent: #00afff;
12
+ --fb-highlight: #fcd34d;
13
+ }
14
+
15
+ /* ---------------------------------------------------------------- Viewer */
16
+
17
+ .fb-root {
18
+ position: relative;
19
+ display: flex;
20
+ flex-direction: column;
21
+ width: 100%;
22
+ height: 100%;
23
+ min-height: 240px;
24
+ overflow: hidden;
25
+ font-family: var(--fb-sans);
26
+ color: #fff;
27
+ user-select: none;
28
+ -webkit-user-select: none;
29
+ -webkit-tap-highlight-color: transparent;
30
+ }
31
+ .fb-root *,
32
+ .fb-page *,
33
+ .fb-cover * {
34
+ box-sizing: border-box;
35
+ }
36
+ /* Neutralise host styles for headings and paragraphs, e.g. a docs site's prose. */
37
+ .fb-root :is(h1, h2, p),
38
+ .fb-page :is(h1, h2, p),
39
+ .fb-cover :is(h1, h2, p) {
40
+ margin: 0;
41
+ padding: 0;
42
+ border: 0;
43
+ font-size: inherit;
44
+ line-height: inherit;
45
+ letter-spacing: inherit;
46
+ color: inherit;
47
+ }
48
+ .fb-root button {
49
+ font: inherit;
50
+ color: inherit;
51
+ border: 0;
52
+ cursor: pointer;
53
+ }
54
+
55
+ .fb-bar {
56
+ position: absolute;
57
+ left: 0;
58
+ right: 0;
59
+ z-index: 30;
60
+ display: flex;
61
+ align-items: center;
62
+ gap: 12px;
63
+ padding: 12px 16px;
64
+ pointer-events: none;
65
+ transition: opacity 300ms;
66
+ }
67
+ .fb-bar.is-hidden {
68
+ opacity: 0;
69
+ }
70
+ .fb-bar:not(.is-hidden) > * {
71
+ pointer-events: auto;
72
+ }
73
+ .fb-bar-top {
74
+ top: 0;
75
+ justify-content: space-between;
76
+ background: linear-gradient(to bottom, rgb(0 0 0 / 0.6), transparent);
77
+ }
78
+ .fb-bar-bottom {
79
+ bottom: 0;
80
+ justify-content: center;
81
+ padding-top: 24px;
82
+ padding-bottom: 16px;
83
+ background: linear-gradient(to top, rgb(0 0 0 / 0.6), transparent);
84
+ }
85
+ .fb-bar-group {
86
+ display: flex;
87
+ min-width: 0;
88
+ align-items: center;
89
+ gap: 8px;
90
+ }
91
+ .fb-heading {
92
+ min-width: 0;
93
+ text-align: left;
94
+ }
95
+ .fb-root .fb-title {
96
+ margin: 0;
97
+ overflow: hidden;
98
+ font-family: var(--fb-serif);
99
+ font-size: 18px;
100
+ font-weight: 400;
101
+ line-height: 1.25;
102
+ text-overflow: ellipsis;
103
+ white-space: nowrap;
104
+ }
105
+ .fb-root .fb-byline {
106
+ margin: 0;
107
+ overflow: hidden;
108
+ font-size: 12px;
109
+ color: rgb(255 255 255 / 0.6);
110
+ text-overflow: ellipsis;
111
+ white-space: nowrap;
112
+ }
113
+
114
+ .fb-button {
115
+ display: inline-flex;
116
+ padding: 10px;
117
+ border-radius: 999px;
118
+ background: rgb(255 255 255 / 0.1);
119
+ transition: background 150ms;
120
+ }
121
+ .fb-button:hover {
122
+ background: rgb(255 255 255 / 0.2);
123
+ }
124
+ .fb-button:disabled {
125
+ opacity: 0.3;
126
+ cursor: default;
127
+ }
128
+ .fb-button svg {
129
+ width: 20px;
130
+ height: 20px;
131
+ }
132
+ .fb-pages-button {
133
+ display: inline-flex;
134
+ min-width: 160px;
135
+ align-items: center;
136
+ justify-content: center;
137
+ gap: 8px;
138
+ padding: 8px 16px;
139
+ border-radius: 999px;
140
+ background: rgb(255 255 255 / 0.1);
141
+ font-size: 14px;
142
+ font-variant-numeric: tabular-nums;
143
+ color: rgb(255 255 255 / 0.9);
144
+ }
145
+ .fb-pages-button:hover {
146
+ background: rgb(255 255 255 / 0.2);
147
+ }
148
+ .fb-pages-button svg {
149
+ width: 16px;
150
+ height: 16px;
151
+ }
152
+
153
+ .fb-stage {
154
+ position: relative;
155
+ display: flex;
156
+ flex: 1;
157
+ align-items: center;
158
+ justify-content: center;
159
+ touch-action: none;
160
+ }
161
+
162
+ .fb-book {
163
+ position: relative;
164
+ transition: transform 900ms cubic-bezier(0.645, 0.045, 0.355, 1);
165
+ }
166
+ .fb-spine {
167
+ position: absolute;
168
+ top: 0;
169
+ }
170
+
171
+ /* Shadow cast by the book on the stage. */
172
+ .fb-book-shadow {
173
+ position: absolute;
174
+ bottom: -32px;
175
+ height: 48px;
176
+ border-radius: 50%;
177
+ background: rgb(0 0 0 / 0.6);
178
+ filter: blur(40px);
179
+ pointer-events: none;
180
+ transition: all 700ms;
181
+ }
182
+
183
+ /* One side of a leaf. Turning pages are clipped and moved from script. */
184
+ .fb-face {
185
+ position: absolute;
186
+ top: 0;
187
+ overflow: hidden;
188
+ backface-visibility: hidden;
189
+ -webkit-backface-visibility: hidden;
190
+ container-type: size;
191
+ }
192
+
193
+ /* Light or shadow around a turning page's fold, clipped to one region of it. */
194
+ .fb-overlay {
195
+ position: absolute;
196
+ overflow: hidden;
197
+ pointer-events: none;
198
+ }
199
+ .fb-light {
200
+ position: absolute;
201
+ left: 0;
202
+ top: 0;
203
+ transform-origin: 0 0;
204
+ }
205
+
206
+ /* Stacked page edges beside an open book. */
207
+ .fb-edge {
208
+ position: absolute;
209
+ top: 3px;
210
+ bottom: 3px;
211
+ background: repeating-linear-gradient(to right, #efe7d6 0 1px, #d9cfbb 1px 2px);
212
+ box-shadow: 0 2px 6px rgb(0 0 0 / 0.35);
213
+ }
214
+
215
+ /* Thumbnails of every spread. */
216
+ .fb-strip {
217
+ position: absolute;
218
+ left: 0;
219
+ right: 0;
220
+ bottom: 80px;
221
+ z-index: 30;
222
+ padding: 0 16px;
223
+ }
224
+ .fb-strip-list {
225
+ display: flex;
226
+ max-width: 1024px;
227
+ gap: 16px;
228
+ margin: 0 auto;
229
+ padding: 16px;
230
+ overflow-x: auto;
231
+ border-radius: 16px;
232
+ background: rgb(0 0 0 / 0.6);
233
+ backdrop-filter: blur(12px);
234
+ }
235
+ .fb-strip-stop {
236
+ display: flex;
237
+ flex-shrink: 0;
238
+ height: 96px;
239
+ padding: 0;
240
+ border-radius: 2px;
241
+ background: none;
242
+ outline: 2px solid transparent;
243
+ box-shadow: 0 10px 15px rgb(0 0 0 / 0.3);
244
+ opacity: 0.8;
245
+ transition:
246
+ opacity 150ms,
247
+ outline-color 150ms;
248
+ }
249
+ .fb-strip-stop:hover,
250
+ .fb-strip-stop[aria-current='true'] {
251
+ opacity: 1;
252
+ }
253
+ .fb-strip-stop[aria-current='true'] {
254
+ outline-color: var(--fb-highlight);
255
+ }
256
+ .fb-strip-face {
257
+ position: relative;
258
+ height: 100%;
259
+ aspect-ratio: 3 / 4;
260
+ overflow: hidden;
261
+ container-type: size;
262
+ }
263
+ @media (min-width: 640px) {
264
+ .fb-strip-stop {
265
+ height: 112px;
266
+ }
267
+ }
268
+
269
+ /* Shown on phones held upright: books are read sideways. */
270
+ .fb-rotate {
271
+ position: absolute;
272
+ inset: 0;
273
+ z-index: 40;
274
+ display: flex;
275
+ flex-direction: column;
276
+ align-items: center;
277
+ justify-content: center;
278
+ gap: 24px;
279
+ padding: 0 32px;
280
+ background: rgb(0 0 0 / 0.85);
281
+ backdrop-filter: blur(4px);
282
+ text-align: center;
283
+ }
284
+ .fb-rotate-hint {
285
+ width: 80px;
286
+ height: 80px;
287
+ animation: fb-rotate-hint 2.6s ease-in-out infinite;
288
+ }
289
+ .fb-root .fb-rotate-title {
290
+ margin: 0;
291
+ font-family: var(--fb-serif);
292
+ font-size: 24px;
293
+ }
294
+ .fb-root .fb-rotate-body {
295
+ margin: 8px 0 0;
296
+ font-size: 14px;
297
+ color: rgb(255 255 255 / 0.7);
298
+ }
299
+ .fb-rotate-primary {
300
+ padding: 10px 20px;
301
+ border-radius: 999px;
302
+ background: #fff;
303
+ font-size: 14px;
304
+ font-weight: 500;
305
+ color: #2c343e !important;
306
+ }
307
+ .fb-rotate-secondary {
308
+ background: none;
309
+ font-size: 14px;
310
+ color: rgb(255 255 255 / 0.7) !important;
311
+ text-decoration: underline;
312
+ text-underline-offset: 4px;
313
+ }
314
+ @keyframes fb-rotate-hint {
315
+ 0%,
316
+ 20% {
317
+ transform: rotate(0deg);
318
+ }
319
+ 50%,
320
+ 80% {
321
+ transform: rotate(-90deg);
322
+ }
323
+ 100% {
324
+ transform: rotate(0deg);
325
+ }
326
+ }
327
+
328
+ @media (prefers-reduced-motion: reduce) {
329
+ .fb-book {
330
+ transition-duration: 1ms;
331
+ }
332
+ .fb-rotate-hint {
333
+ animation: none;
334
+ }
335
+ }
336
+
337
+ /* ---------------------------------------------------------------- Pages */
338
+
339
+ .fb-page,
340
+ .fb-cover {
341
+ position: absolute;
342
+ inset: 0;
343
+ }
344
+ .fb-page {
345
+ display: flex;
346
+ flex-direction: column;
347
+ }
348
+ .fb-serif {
349
+ margin: 0;
350
+ font-family: var(--fb-serif);
351
+ }
352
+ .fb-italic {
353
+ font-style: italic;
354
+ }
355
+ .fb-center {
356
+ text-align: center;
357
+ }
358
+ .fb-column {
359
+ display: flex;
360
+ height: 100%;
361
+ flex-direction: column;
362
+ }
363
+ .fb-row {
364
+ display: flex;
365
+ }
366
+ .fb-grow {
367
+ position: relative;
368
+ min-height: 0;
369
+ flex: 1;
370
+ }
371
+
372
+ .fb-slot {
373
+ position: relative;
374
+ overflow: hidden;
375
+ }
376
+ .fb-slot.is-framed {
377
+ overflow: visible;
378
+ }
379
+ .fb-slot.is-editable {
380
+ cursor: pointer;
381
+ }
382
+ .fb-slot.is-active {
383
+ box-shadow: 0 0 0 0.8cqw var(--fb-accent);
384
+ }
385
+ .fb-slot[data-over='true'] {
386
+ box-shadow: 0 0 0 1cqw var(--fb-highlight);
387
+ }
388
+ .fb-slot-empty {
389
+ display: flex;
390
+ width: 100%;
391
+ height: 100%;
392
+ align-items: center;
393
+ justify-content: center;
394
+ background: color-mix(in srgb, currentColor 10%, transparent);
395
+ opacity: 0.8;
396
+ font-size: 3.2cqw;
397
+ }
398
+ .fb-slot.is-editable .fb-slot-empty {
399
+ border: 0.4cqw dashed color-mix(in srgb, currentColor 30%, transparent);
400
+ }
401
+ .fb-grid {
402
+ display: grid;
403
+ grid-template-columns: 1fr 1fr;
404
+ grid-template-rows: 1fr 1fr;
405
+ }
406
+ .fb-caption-over {
407
+ position: absolute;
408
+ left: 0;
409
+ right: 0;
410
+ bottom: 0;
411
+ padding: 14cqw 7cqw 7cqw;
412
+ background: linear-gradient(to top, rgb(0 0 0 / 0.7), rgb(0 0 0 / 0.3), transparent);
413
+ font-family: var(--fb-serif);
414
+ font-size: 4.2cqw;
415
+ font-style: italic;
416
+ line-height: 1.35;
417
+ color: #fff;
418
+ }
419
+ .fb-page-number {
420
+ position: absolute;
421
+ bottom: 0;
422
+ padding: 0 5cqw 2.6cqw;
423
+ font-family: var(--fb-serif);
424
+ font-size: 2.8cqw;
425
+ opacity: 0.6;
426
+ }
427
+ .fb-photo {
428
+ display: block;
429
+ width: 100%;
430
+ height: 100%;
431
+ object-fit: cover;
432
+ user-select: none;
433
+ -webkit-user-drag: none;
434
+ }
435
+ .fb-placeholder {
436
+ width: 100%;
437
+ height: 100%;
438
+ background: color-mix(in srgb, currentColor 15%, transparent);
439
+ }
440
+
441
+ /* The front and back covers: cloth with a hinge along the spine. */
442
+ .fb-hinge {
443
+ position: absolute;
444
+ top: 0;
445
+ bottom: 0;
446
+ width: 4cqw;
447
+ }
448
+ .fb-hinge.is-left {
449
+ left: 0;
450
+ background: linear-gradient(to right, rgb(0 0 0 / 0.35), rgb(0 0 0 / 0.1), transparent);
451
+ }
452
+ .fb-hinge.is-right {
453
+ right: 0;
454
+ background: linear-gradient(to left, rgb(0 0 0 / 0.35), rgb(0 0 0 / 0.1), transparent);
455
+ }
456
+ .fb-cover-panel {
457
+ position: absolute;
458
+ inset: 6cqw;
459
+ display: flex;
460
+ flex-direction: column;
461
+ align-items: center;
462
+ padding: 8cqw 6cqw;
463
+ border: 1px solid color-mix(in srgb, currentColor 40%, transparent);
464
+ text-align: center;
465
+ }
466
+ .fb-cover .fb-kicker {
467
+ margin: 0;
468
+ font-size: 2.6cqw;
469
+ letter-spacing: 0.3em;
470
+ text-transform: uppercase;
471
+ opacity: 0.7;
472
+ }
473
+ .fb-cover-photo {
474
+ position: relative;
475
+ width: 100%;
476
+ max-height: 62%;
477
+ flex: 1;
478
+ margin-top: 7cqw;
479
+ overflow: hidden;
480
+ border: 0.8cqw solid color-mix(in srgb, currentColor 60%, transparent);
481
+ box-shadow: inset 0 0 2cqw rgb(0 0 0 / 0.4);
482
+ }
483
+ .fb-imprint {
484
+ position: absolute;
485
+ left: 0;
486
+ right: 0;
487
+ bottom: 10cqw;
488
+ text-align: center;
489
+ }
490
+ .fb-ornament {
491
+ display: block;
492
+ width: 9cqw;
493
+ height: 9cqw;
494
+ margin: 0 auto;
495
+ }
496
+
497
+ /* ---------------------------------------------------------------- Print */
498
+
499
+ /* Ink on paper: slightly lifted blacks, warmed toward the paper colour. */
500
+ .fb-print-photo {
501
+ filter: sepia(0.06) saturate(0.94) contrast(0.94) brightness(1.01);
502
+ }
503
+ .fb-paper-kraft .fb-print-photo {
504
+ filter: sepia(0.22) saturate(0.88) contrast(0.9) brightness(0.98);
505
+ }
506
+ .fb-paper-charcoal .fb-print-photo {
507
+ filter: saturate(0.92) contrast(0.94) brightness(0.9);
508
+ }
509
+
510
+ /*
511
+ * Photo frames. Everything is ink or a press on the paper: translucent tints, printed rules and a blind
512
+ * plate mark, so the page grain shows through and nothing stands off the page. Sizes are in em, which
513
+ * PrintedPhoto sets to 1% of the page width.
514
+ */
515
+ .fb-print-frame-box {
516
+ position: absolute;
517
+ inset: 0;
518
+ display: flex;
519
+ align-items: center;
520
+ justify-content: center;
521
+ container-type: size;
522
+ }
523
+ .fb-print-frame {
524
+ --frame-pad: 0em;
525
+ --frame-line: 0px;
526
+ --frame-edge: calc(var(--frame-pad) + var(--frame-line));
527
+ position: relative;
528
+ width: 100%;
529
+ height: 100%;
530
+ border: var(--frame-line) solid transparent;
531
+ }
532
+ .fb-print-frame.is-contained {
533
+ --frame-width: min(100cqw, (100cqh - 2 * var(--frame-edge)) * var(--ratio) + 2 * var(--frame-edge));
534
+ width: var(--frame-width);
535
+ height: calc((var(--frame-width) - 2 * var(--frame-edge)) / var(--ratio) + 2 * var(--frame-edge));
536
+ }
537
+ .fb-print-frame-photo {
538
+ position: absolute;
539
+ inset: var(--frame-pad);
540
+ width: calc(100% - 2 * var(--frame-pad));
541
+ height: calc(100% - 2 * var(--frame-pad));
542
+ object-fit: cover;
543
+ }
544
+
545
+ .fb-frame-hairline {
546
+ --frame-pad: 1.6em;
547
+ --frame-line: max(1px, 0.22em);
548
+ border-color: color-mix(in srgb, currentColor 70%, transparent);
549
+ }
550
+ .fb-frame-double {
551
+ --frame-pad: 1.4em;
552
+ --frame-line: max(3px, 0.7em);
553
+ border-style: double;
554
+ border-color: color-mix(in srgb, currentColor 75%, transparent);
555
+ }
556
+ .fb-frame-mat {
557
+ --frame-pad: 4.5em;
558
+ --frame-line: max(1px, 0.7em);
559
+ border-color: color-mix(in srgb, currentColor 85%, transparent);
560
+ background: var(--frame-tint);
561
+ }
562
+ .fb-frame-mat .fb-print-frame-photo {
563
+ outline: max(1px, 0.25em) solid color-mix(in srgb, currentColor 18%, transparent);
564
+ }
565
+ .fb-frame-corners {
566
+ --frame-pad: 0.7em;
567
+ }
568
+ .fb-print-frame-corner {
569
+ position: absolute;
570
+ width: 5.5em;
571
+ height: 5.5em;
572
+ background: color-mix(in srgb, currentColor 82%, transparent);
573
+ }
574
+ .fb-print-frame-corner.is-tl {
575
+ top: 0;
576
+ left: 0;
577
+ clip-path: polygon(0 0, 100% 0, 0 100%);
578
+ }
579
+ .fb-print-frame-corner.is-tr {
580
+ top: 0;
581
+ right: 0;
582
+ clip-path: polygon(0 0, 100% 0, 100% 100%);
583
+ }
584
+ .fb-print-frame-corner.is-bl {
585
+ bottom: 0;
586
+ left: 0;
587
+ clip-path: polygon(0 0, 100% 100%, 0 100%);
588
+ }
589
+ .fb-print-frame-corner.is-br {
590
+ bottom: 0;
591
+ right: 0;
592
+ clip-path: polygon(100% 0, 100% 100%, 0 100%);
593
+ }
594
+ .fb-frame-deckle {
595
+ --frame-pad: 2.6em;
596
+ --scallop: 1.6em;
597
+ background: color-mix(in srgb, currentColor 11%, transparent);
598
+ mask:
599
+ linear-gradient(#000 0 0) center / calc(100% - var(--scallop)) calc(100% - var(--scallop)) no-repeat,
600
+ radial-gradient(closest-side, #000 97%, transparent) top left / var(--scallop) var(--scallop) repeat-x,
601
+ radial-gradient(closest-side, #000 97%, transparent) bottom left / var(--scallop) var(--scallop) repeat-x,
602
+ radial-gradient(closest-side, #000 97%, transparent) top left / var(--scallop) var(--scallop) repeat-y,
603
+ radial-gradient(closest-side, #000 97%, transparent) top right / var(--scallop) var(--scallop) repeat-y;
604
+ }
605
+ .fb-frame-plate {
606
+ --frame-pad: 3.2em;
607
+ background: var(--plate-tint);
608
+ box-shadow:
609
+ inset 0.2em 0.2em 0 var(--plate-low),
610
+ inset -0.2em -0.2em 0 var(--plate-high);
611
+ }
612
+ .fb-frame-feather .fb-print-frame-photo {
613
+ mask:
614
+ linear-gradient(to right, transparent, #000 8%, #000 92%, transparent),
615
+ linear-gradient(to bottom, transparent, #000 8%, #000 92%, transparent);
616
+ mask-composite: intersect;
617
+ }
618
+
619
+ .fb-frame-oval {
620
+ --frame-pad: 1.5em;
621
+ --frame-line: max(1px, 0.22em);
622
+ border-color: color-mix(in srgb, currentColor 70%, transparent);
623
+ border-radius: 50%;
624
+ }
625
+ .fb-frame-oval .fb-print-frame-photo {
626
+ border-radius: 50%;
627
+ }
628
+ .fb-frame-botanical {
629
+ --frame-pad: 5em;
630
+ }
631
+ .fb-frame-botanical .fb-print-frame-photo {
632
+ outline: max(1px, 0.18em) solid color-mix(in srgb, currentColor 60%, transparent);
633
+ outline-offset: 1.6em;
634
+ }
635
+ .fb-print-frame-sprig {
636
+ position: absolute;
637
+ width: 26em;
638
+ height: 10.4em;
639
+ color: color-mix(in srgb, currentColor 80%, transparent);
640
+ }
641
+ .fb-print-frame-sprig.is-tl {
642
+ top: -1.8em;
643
+ left: 1.4em;
644
+ }
645
+ .fb-print-frame-sprig.is-br {
646
+ right: 1.4em;
647
+ bottom: -1.8em;
648
+ transform: rotate(180deg);
649
+ }
650
+
651
+ /* A patterned band printed around a mat. The mask keeps the pattern to the band. */
652
+ .fb-print-frame-band {
653
+ position: absolute;
654
+ inset: 0;
655
+ padding: var(--band);
656
+ mix-blend-mode: var(--ink-blend);
657
+ mask:
658
+ linear-gradient(#000 0 0) content-box exclude,
659
+ linear-gradient(#000 0 0);
660
+ }
661
+ .fb-frame-watercolor,
662
+ .fb-frame-arcs,
663
+ .fb-frame-gilt,
664
+ .fb-frame-woodgrain {
665
+ --band: 3em;
666
+ --frame-pad: calc(var(--band) + 2.6em);
667
+ background: var(--frame-tint);
668
+ }
669
+ .fb-frame-watercolor .fb-print-frame-band {
670
+ background: linear-gradient(135deg, #f0a993, #f3d27c 30%, #9fd3bf 62%, #8fb6e2);
671
+ opacity: 0.7;
672
+ }
673
+ .fb-frame-arcs .fb-print-frame-band {
674
+ background: radial-gradient(
675
+ circle at 50% 100%,
676
+ #e9967a 0 0.3em,
677
+ #f2c95c 0.3em 0.6em,
678
+ #79c2a2 0.6em 0.9em,
679
+ #7ea7d8 0.9em 1.2em,
680
+ transparent 1.2em
681
+ )
682
+ 0 0 / 2.4em 1.3em;
683
+ opacity: 0.8;
684
+ }
685
+ .fb-frame-gilt {
686
+ --band: 2.6em;
687
+ }
688
+ .fb-frame-gilt .fb-print-frame-band {
689
+ border: max(1px, 0.35em) solid #b48a32;
690
+ background:
691
+ repeating-linear-gradient(45deg, rgb(180 138 50 / 0.75) 0 0.22em, transparent 0.22em 0.8em),
692
+ repeating-linear-gradient(-45deg, rgb(180 138 50 / 0.75) 0 0.22em, transparent 0.22em 0.8em), rgb(214 178 92 / 0.45);
693
+ }
694
+ .fb-frame-gilt .fb-print-frame-photo,
695
+ .fb-frame-watercolor .fb-print-frame-photo,
696
+ .fb-frame-arcs .fb-print-frame-photo,
697
+ .fb-frame-woodgrain .fb-print-frame-photo {
698
+ outline: max(1px, 0.2em) solid color-mix(in srgb, currentColor 22%, transparent);
699
+ }
700
+ .fb-frame-woodgrain .fb-print-frame-band {
701
+ background:
702
+ repeating-linear-gradient(
703
+ 8deg,
704
+ rgb(110 70 30 / 0.4) 0 0.12em,
705
+ transparent 0.12em 0.55em,
706
+ rgb(110 70 30 / 0.22) 0.55em 0.8em,
707
+ transparent 0.75em 1.5em
708
+ ),
709
+ #cfa874;
710
+ opacity: 0.85;
711
+ }
712
+
713
+ /* Lighting over a whole page, photos included: grain, the curve into the spine and a soft sheen where the page rises. */
714
+ .fb-page-surface,
715
+ .fb-page-surface > * {
716
+ position: absolute;
717
+ inset: 0;
718
+ pointer-events: none;
719
+ }
720
+ .fb-page-surface {
721
+ z-index: 5;
722
+ }
723
+ .fb-page-surface-grain {
724
+ background: var(--paper-grain) 0 0 / 256px 256px;
725
+ opacity: 0.45;
726
+ }
727
+ .fb-paper-kraft .fb-page-surface-grain {
728
+ opacity: 0.35;
729
+ }
730
+ .fb-paper-charcoal .fb-page-surface-grain {
731
+ opacity: 0.22;
732
+ }
733
+ .fb-page-surface-gutter {
734
+ background: linear-gradient(
735
+ var(--to-edge),
736
+ rgb(20 12 4 / 0.5) 0%,
737
+ rgb(20 12 4 / 0.3) 1.5%,
738
+ rgb(20 12 4 / 0.14) 4%,
739
+ rgb(20 12 4 / 0.05) 8%,
740
+ transparent 15%,
741
+ transparent 94%,
742
+ rgb(20 12 4 / 0.07) 100%
743
+ );
744
+ }
745
+ .fb-page-surface-sheen {
746
+ background: linear-gradient(var(--to-edge), transparent 6%, rgb(255 250 240 / 0.07) 13%, rgb(255 250 240 / 0.02) 26%, transparent 40%);
747
+ }
748
+ .fb-page-surface.is-right {
749
+ --to-edge: to right;
750
+ }
751
+ .fb-page-surface.is-left {
752
+ --to-edge: to left;
753
+ }
754
+
755
+ /* Page paper: a texture tile multiplied over the paper colour, plus soft light and vignetting. */
756
+ .fb-paper {
757
+ --paper-texture: url('./textures/paper-fine.webp');
758
+ --paper-grain: url('./textures/grain-fine.webp');
759
+ --frame-tint: rgb(255 255 255 / 0.4);
760
+ --ink-blend: multiply;
761
+ --plate-tint: rgb(90 70 40 / 0.03);
762
+ --plate-low: rgb(90 70 40 / 0.12);
763
+ --plate-high: rgb(255 255 255 / 0.6);
764
+ color: #3d372f;
765
+ background-color: #fdf9f0;
766
+ background-image:
767
+ radial-gradient(ellipse at 30% 20%, rgb(255 255 255 / 0.5), transparent 55%),
768
+ radial-gradient(ellipse at 50% 50%, transparent 60%, rgb(110 90 60 / 0.08)), var(--paper-texture);
769
+ background-size:
770
+ 100% 100%,
771
+ 100% 100%,
772
+ 256px 256px;
773
+ background-blend-mode: normal, normal, multiply;
774
+ }
775
+
776
+ .fb-paper-white {
777
+ --frame-tint: rgb(150 125 90 / 0.08);
778
+ background-color: #ffffff;
779
+ }
780
+ .fb-paper-kraft {
781
+ --paper-texture: url('./textures/paper-kraft.webp');
782
+ --paper-grain: url('./textures/grain-kraft.webp');
783
+ --frame-tint: rgb(255 248 235 / 0.35);
784
+ --plate-low: rgb(80 50 20 / 0.16);
785
+ --plate-high: rgb(255 245 225 / 0.35);
786
+ background-color: #d8c4a2;
787
+ background-image:
788
+ radial-gradient(ellipse at 30% 20%, rgb(255 255 255 / 0.18), transparent 55%),
789
+ radial-gradient(ellipse at 50% 50%, transparent 60%, rgb(80 50 20 / 0.12)), var(--paper-texture);
790
+ color: #3d2f1d;
791
+ }
792
+ .fb-paper-charcoal {
793
+ --paper-texture: url('./textures/paper-charcoal.webp');
794
+ --paper-grain: url('./textures/grain-charcoal.webp');
795
+ --frame-tint: rgb(255 255 255 / 0.07);
796
+ --ink-blend: screen;
797
+ --plate-tint: rgb(0 0 0 / 0.08);
798
+ --plate-low: rgb(0 0 0 / 0.35);
799
+ --plate-high: rgb(255 255 255 / 0.07);
800
+ background-color: #2a2826;
801
+ background-image:
802
+ radial-gradient(ellipse at 30% 20%, rgb(255 255 255 / 0.05), transparent 55%),
803
+ radial-gradient(ellipse at 50% 50%, transparent 55%, rgb(0 0 0 / 0.25)), var(--paper-texture);
804
+ background-blend-mode: normal, normal, soft-light;
805
+ color: #e8e2d6;
806
+ }
807
+
808
+ .fb-cover-classic {
809
+ background-color: #5a1d22;
810
+ background-image:
811
+ radial-gradient(circle at 30% 20%, rgb(255 255 255 / 0.08), transparent 45%),
812
+ repeating-radial-gradient(circle at 50% 50%, rgb(0 0 0 / 0.04) 0 1px, transparent 1px 3px);
813
+ color: #e2c58f;
814
+ }
815
+ .fb-cover-linen {
816
+ background-color: #e6dcc6;
817
+ background-image:
818
+ repeating-linear-gradient(0deg, rgb(90 70 40 / 0.05) 0 1px, transparent 1px 3px),
819
+ repeating-linear-gradient(90deg, rgb(90 70 40 / 0.05) 0 1px, transparent 1px 3px);
820
+ color: #3d3226;
821
+ }
822
+ .fb-cover-midnight {
823
+ background-color: #141b2e;
824
+ background-image:
825
+ radial-gradient(circle at 70% 15%, rgb(150 170 255 / 0.12), transparent 45%),
826
+ repeating-radial-gradient(circle at 50% 50%, rgb(255 255 255 / 0.02) 0 1px, transparent 1px 3px);
827
+ color: #d5dbe8;
828
+ }
829
+
830
+ .fb-fill {
831
+ width: 100%;
832
+ height: 100%;
833
+ }
834
+ .fb-grow-large {
835
+ position: relative;
836
+ min-height: 0;
837
+ flex: 1.4;
838
+ }
839
+ .fb-slot.fb-bleed {
840
+ position: absolute;
841
+ inset: 0;
842
+ }
843
+ .fb-slot.fb-placed {
844
+ position: absolute;
845
+ }
846
+ .fb-slot.fb-placed.is-loose {
847
+ overflow: visible;
848
+ box-shadow:
849
+ 0 0.4cqw 0.8cqw rgb(0 0 0 / 0.18),
850
+ 0 1.6cqw 3.2cqw -1cqw rgb(0 0 0 / 0.25);
851
+ }
852
+ .fb-page .fb-placed-caption {
853
+ position: absolute;
854
+ display: flex;
855
+ margin: 0;
856
+ align-items: center;
857
+ justify-content: center;
858
+ overflow: hidden;
859
+ font-size: 3.8cqw;
860
+ line-height: 1.35;
861
+ text-align: center;
862
+ }
863
+ .fb-page .fb-placed-caption.is-prose {
864
+ display: block;
865
+ font-size: 4.4cqw;
866
+ line-height: 1.55;
867
+ text-align: left;
868
+ text-wrap: pretty;
869
+ }