Files
lisette/style/main.css
T
Romulus21andClaude Opus 5.5 9aa81a22fe Anime le passage d'un article entre la liste et le panier
Le basculement passe par une View Transition : chaque tuile porte un
view-transition-name, la tuile glisse vers sa nouvelle place et les
autres se décalent. Sans support navigateur, rien ne change.

Closes #1

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-01 15:54:23 +01:00

76 lines
1.8 KiB
CSS

@import "tailwindcss";
@theme {
--color-lime: #bfe383;
--color-sky: #7fdffb;
--color-peach: #ffbd76;
--color-pink: #ffadd6;
--color-rose: #ff9b8a;
--color-sand: #f2d9a4;
--color-lilac: #cdb8ff;
--color-ink: #1c1c24;
--color-paper: #fdfcf7;
--color-mist: #efede8;
--font-sans: "Inter", ui-sans-serif, system-ui, sans-serif;
--font-display: "Unbounded", "Inter", ui-sans-serif, sans-serif;
--font-mono: "JetBrains Mono", ui-monospace, monospace;
}
/* Hard drop shadow under tiles and buttons. */
@utility tile-shadow {
box-shadow: 0 5px 0 0 var(--color-ink);
}
@utility field {
border-radius: 0.875rem;
border: 2px solid var(--color-ink);
background: white;
padding: 0.75rem 0.875rem;
font-size: 1.0625rem; /* ≥16px: no zoom on iOS focus */
outline: none;
&:focus {
box-shadow: 0 0 0 3px var(--color-lime);
}
&[aria-invalid="true"] {
border-color: var(--color-rose);
}
}
/* Torn receipt edge along the bottom of the ticket. */
@layer components {
.ticket::after {
content: "";
position: absolute;
inset-inline: 0;
top: 100%;
height: 10px;
background:
linear-gradient(135deg, var(--color-paper) 50%, transparent 50%) 0 0 / 14px 10px repeat-x,
linear-gradient(225deg, var(--color-paper) 50%, transparent 50%) 0 0 / 14px 10px repeat-x;
}
}
html {
-webkit-tap-highlight-color: transparent;
}
/* Tiles moving between the list and the basket (see src/app/transition.rs). */
::view-transition-group(*) {
animation-duration: 320ms;
animation-timing-function: cubic-bezier(0.2, 0.8, 0.2, 1);
}
::view-transition-old(*),
::view-transition-new(*) {
animation-duration: 200ms;
}
@media (prefers-reduced-motion: reduce) {
::view-transition-group(*),
::view-transition-old(*),
::view-transition-new(*) {
animation: none;
}
}