/* ============================================================
   VOLT & VOIE — Composants
   Tendances 2026 : container queries, kinetic type, bento grid,
   Liquid Glass, micro-interactions, scroll-driven animations.
   ============================================================ */

/* ---------------- Boutons (zones de clic ≥ 48px) ---------------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  gap: var(--space-2);
  min-height: 48px; padding: var(--space-3) var(--space-6);
  font-family: var(--font-body); font-weight: 600; font-size: var(--text-sm);
  border-radius: var(--radius-full);
  transition: transform var(--transition-interactive),
              box-shadow var(--transition-interactive),
              background var(--transition-interactive),
              color var(--transition-interactive);
  will-change: transform;
}
.btn svg { width: 1.15em; height: 1.15em; }
/* Texte = inverse du thème (clair sur bleu en mode clair, foncé sur bleu clair en mode sombre)
   -> WCAG 1.4.11/4.5:1 respecté dans les deux thèmes (le #fff fixe tombait à 2,7:1 en sombre). */
.btn--primary { background: var(--color-primary); color: var(--color-text-inverse); box-shadow: var(--shadow-sm); }
.btn--primary:hover { background: var(--color-primary-hover); transform: translateY(-2px); box-shadow: var(--shadow-md); }
.btn--primary:active { transform: translateY(0); box-shadow: var(--shadow-sm); }

.btn--signal { background: var(--color-signal); color: var(--color-signal-text); box-shadow: var(--shadow-sm); }
.btn--signal:hover { background: var(--color-signal-strong); transform: translateY(-2px); box-shadow: var(--shadow-md); }
.btn--signal:active { transform: translateY(0); }

/* Bordure = text-muted (et non --color-border, trop pâle à 1,4:1) -> contour ~6:1, conforme
   WCAG 1.4.11 (limite de composant interactif >= 3:1) dans les deux thèmes. */
.btn--ghost { background: transparent; color: var(--color-text); border: 1.5px solid var(--color-text-muted); }
.btn--ghost:hover { border-color: var(--color-primary); color: var(--color-primary); transform: translateY(-2px); }
.btn--ghost:active { transform: translateY(0); }
/* Variante verre, pensée pour les fonds sombres/photos (héros) */
.btn--glass {
  background: rgba(255,255,255,0.12); color: #fff;
  border: 1.5px solid rgba(255,255,255,0.45);
  -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px);
}
.btn--glass:hover { background: rgba(255,255,255,0.22); border-color: #fff; transform: translateY(-2px); }
.btn--glass:active { transform: translateY(0); }

@media (hover: none) {
  .btn:hover { transform: none; }
}

/* ---------------- Liquid Glass ---------------- */
.glass {
  background: var(--glass-bg);
  -webkit-backdrop-filter: blur(20px) saturate(180%);
  backdrop-filter: blur(20px) saturate(180%);
  border: 1px solid var(--glass-border);
  border-radius: var(--radius-xl);
  box-shadow: var(--glass-shadow);
}

/* ---------------- En-tête / Navigation ---------------- */
.header {
  position: sticky; top: 0; z-index: 100;
  background: color-mix(in oklab, var(--color-bg) 78%, transparent);
  -webkit-backdrop-filter: blur(16px) saturate(160%);
  backdrop-filter: blur(16px) saturate(160%);
  border-bottom: 1px solid transparent;
  transition: background 0.3s var(--ease-out), color 0.3s var(--ease-out), border-color 0.3s var(--ease-out), box-shadow 0.3s var(--ease-out), transform 0.35s var(--ease-out);
}
.header--scrolled { border-bottom-color: var(--color-divider); box-shadow: var(--shadow-sm); }
.header--hidden { transform: translateY(-100%); }

/* En-tête transparent par-dessus le héros photo (page d'accueil, en haut) */
.header--over-hero {
  background: transparent; backdrop-filter: none; -webkit-backdrop-filter: none;
  border-bottom-color: transparent; box-shadow: none;
}
.header--over-hero .brand,
.header--over-hero .nav-links a,
.header--over-hero .icon-btn { color: #fff; }
.header--over-hero .nav-links a::after { background: #fff; }
.header--over-hero .nav-links a[aria-current='page'] { color: #fff; }
.header--over-hero .lang-toggle { border-color: rgba(255,255,255,0.5); }
.header--over-hero .lang-toggle button { color: rgba(255,255,255,0.85); }
.header--over-hero .lang-toggle button[aria-pressed='true'] { background: rgba(255,255,255,0.95); color: var(--color-primary); }
.header--over-hero .icon-btn:hover { background: rgba(255,255,255,0.16); }
/* Logo posé sur la photo du héros : ombre subtile (drop-shadow épouse le contour PNG)
   pour le détacher du fond — même esprit que l'ombre de texte sur image. */
.header--over-hero .brand--insq img { filter: drop-shadow(0 1px 3px rgba(0,0,0,0.45)) drop-shadow(0 1px 8px rgba(0,0,0,0.25)); }

/* Logo bi-version — lisibilité sur les deux palettes :
   COULEUR (texte rouge) sur fond pâle ; texte BLANC sur fond foncé.
   Fond foncé = header par-dessus le héros (photo foncée) OU tout en mode sombre
   (le header scrollé et le footer suivent --color-bg/--color-surface). */
.brand-logo { display: block; }
.brand-logo--white { display: none; }
.header--over-hero:not(.header--dark-text) .brand-logo--color,
[data-theme="dark"] .brand-logo--color { display: none; }
.header--over-hero:not(.header--dark-text) .brand-logo--white,
[data-theme="dark"] .brand-logo--white { display: block; }
@media (prefers-color-scheme: dark) {
  :root:not([data-theme]) .brand-logo--color { display: none; }
  :root:not([data-theme]) .brand-logo--white { display: block; }
}

/* En-tête par-dessus un héros CLAIR : texte foncé pour rester lisible */
.header--over-hero.header--dark-text .brand,
.header--over-hero.header--dark-text .nav-links a,
.header--over-hero.header--dark-text .icon-btn { color: #15222B; }
.header--over-hero.header--dark-text .nav-links a::after { background: #15222B; }
.header--over-hero.header--dark-text .nav-links a[aria-current='page'] { color: #15222B; }
.header--over-hero.header--dark-text .lang-toggle { border-color: rgba(21,34,43,0.4); }
.header--over-hero.header--dark-text .lang-toggle button { color: rgba(21,34,43,0.75); }
.header--over-hero.header--dark-text .lang-toggle button[aria-pressed='true'] { background: var(--color-primary); color: #fff; }
.header--over-hero.header--dark-text .icon-btn:hover { background: rgba(21,34,43,0.10); }

.nav { display: flex; align-items: center; justify-content: space-between; gap: var(--space-4); min-height: 68px; }
.brand { display: inline-flex; align-items: center; gap: var(--space-2); font-family: var(--font-display); font-weight: 600; font-size: var(--text-lg); letter-spacing: -0.01em; }
.brand svg { width: 34px; height: 34px; color: var(--color-primary); }

.nav-links { display: none; align-items: center; gap: var(--space-1); }
.nav-links a {
  position: relative; padding: var(--space-2) var(--space-3);
  font-size: var(--text-sm); font-weight: 500; color: var(--color-text-muted);
  border-radius: var(--radius-md); min-height: 44px; display: inline-flex; align-items: center;
}
.nav-links a:hover, .nav-links a[aria-current='page'] { color: var(--color-text); }
.nav-links a[aria-current='page']::after {
  content: ''; position: absolute; left: var(--space-3); right: var(--space-3); bottom: 6px;
  height: 2px; background: var(--color-primary); border-radius: var(--radius-full);
}

.nav-actions { display: flex; align-items: center; gap: var(--space-2); }

/* CTA pivot « S'inscrire » dans l'en-tête — compact, présent sur toutes les pages.
   Reste rouge (btn--signal) même sur l'en-tête transparent au-dessus du héros. */
.nav-cta { min-height: 40px; padding: var(--space-2) var(--space-4); font-size: var(--text-sm); white-space: nowrap; }
@media (max-width: 400px) { .nav-cta { padding: var(--space-2) var(--space-3); } }

.icon-btn {
  display: inline-flex; align-items: center; justify-content: center;
  width: 44px; height: 44px; border-radius: var(--radius-full);
  color: var(--color-text-muted);
  transition: color var(--transition-interactive), background var(--transition-interactive);
}
.icon-btn:hover { color: var(--color-text); background: var(--color-surface-2); }
.icon-btn svg { width: 20px; height: 20px; }

.lang-toggle {
  display: inline-flex; align-items: center; gap: 2px;
  border: 1.5px solid var(--color-border); border-radius: var(--radius-full); padding: 3px;
}
.lang-toggle button {
  min-width: 38px; min-height: 34px; padding: 0 var(--space-2);
  font-size: var(--text-xs); font-weight: 600; border-radius: var(--radius-full);
  color: var(--color-text-muted);
}
.lang-toggle button[aria-pressed='true'] { background: var(--color-primary); color: #fff; }

/* Menu mobile */
.menu-btn { display: inline-flex; }
@media (min-width: 900px) {
  .nav-links { display: flex; }
  .menu-btn { display: none; }
}
.mobile-menu {
  position: fixed; inset: 68px 0 auto 0; z-index: 99;
  max-height: calc(100dvh - 68px); overflow-y: auto;
  background: color-mix(in oklab, var(--color-bg) 96%, transparent);
  -webkit-backdrop-filter: blur(20px); backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--color-divider);
  padding: var(--space-4) var(--gutter) var(--space-6);
  display: flex; flex-direction: column; gap: var(--space-1);
  transform: translateY(-8px); opacity: 0; pointer-events: none;
  transition: opacity 0.25s var(--ease-out), transform 0.25s var(--ease-out);
}
.mobile-menu[data-open='true'] { transform: translateY(0); opacity: 1; pointer-events: auto; }
.mobile-menu a {
  font-family: var(--font-display); font-size: var(--text-lg); font-weight: 600;
  padding: var(--space-2) 0; border-bottom: 1px solid var(--color-divider);
}
.mobile-menu a:hover { color: var(--color-primary); }

/* ---------------- Pastille / badge ---------------- */
.eyebrow {
  display: inline-flex; align-items: center; gap: var(--space-2);
  font-size: var(--text-xs); font-weight: 600; letter-spacing: 0.08em; text-transform: uppercase;
  color: var(--color-primary);
}
.eyebrow::before { content: ''; width: 22px; height: 2px; background: var(--color-primary); border-radius: 2px; }

.badge {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 4px 10px; border-radius: var(--radius-full);
  font-size: var(--text-xs); font-weight: 600;
  background: var(--color-primary-soft); color: var(--color-primary);
}
.badge--signal { background: var(--color-signal); color: var(--color-signal-text); }

/* ---------------- Kinetic Typography ---------------- */
.kinetic h1, .display-xl { font-size: var(--text-hero); font-weight: 600; letter-spacing: -0.03em; line-height: 0.95; }
.display-lg { font-size: var(--text-3xl); font-weight: 600; letter-spacing: -0.025em; line-height: 1; }
.title-xl { font-size: var(--text-2xl); letter-spacing: -0.02em; }
.title-lg { font-size: var(--text-xl); letter-spacing: -0.015em; }
.title-md { font-size: var(--text-lg); }

/* Mots du titre — graisse fixe (Satoshi statique) ; pas d'effet de survol */
.kinetic-word { display: inline-block; }
.text-signal { color: var(--color-signal-strong); }
.text-primary { color: var(--color-primary); }
.lead { font-size: var(--text-lg); color: var(--color-text-muted); max-width: 56ch; line-height: 1.55; }

/* ---------------- Cards (container queries) ---------------- */
.card {
  background: var(--color-surface); border: 1px solid var(--color-border);
  border-radius: var(--radius-xl); overflow: hidden;
  transition: transform var(--transition-interactive), box-shadow var(--transition-interactive), border-color var(--transition-interactive);
}
a.card:hover, .card[data-href]:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); border-color: color-mix(in oklab, var(--color-primary) 40%, var(--color-border)); }
a.card:active { transform: translateY(-1px); }

.card-media { position: relative; aspect-ratio: 4/3; overflow: hidden; background: var(--color-surface-2); }
.card-media img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.5s var(--ease-out); }
a.card:hover .card-media img { transform: scale(1.05); }
.card-body { padding: var(--space-5); }

/* Carte produit responsive au conteneur (container query) */
.card-wrapper { container-type: inline-size; }
.product-card .card-body { display: flex; flex-direction: column; gap: var(--space-2); }
@container (min-width: 460px) {
  .product-card { display: grid; grid-template-columns: 42% 1fr; align-items: stretch; }
  .product-card .card-media { aspect-ratio: auto; height: 100%; }
}

.price { font-family: var(--font-display); font-weight: 600; font-size: var(--text-lg); color: var(--color-text); }
.price small { font-size: var(--text-xs); color: var(--color-text-muted); font-weight: 500; }

/* ---------------- Bento Grid ---------------- */
.bento {
  display: grid; gap: var(--space-4);
  grid-template-columns: 1fr;
}
@media (min-width: 640px) { .bento { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 960px) { .bento { grid-template-columns: repeat(4, 1fr); grid-auto-rows: minmax(180px, auto); } }

.bento-item {
  position: relative; overflow: hidden;
  border-radius: var(--radius-xl); border: 1px solid var(--color-border);
  background: var(--color-surface); padding: var(--space-6);
  display: flex; flex-direction: column; justify-content: flex-end; gap: var(--space-2);
  min-height: 180px;
  transition: transform var(--transition-interactive), box-shadow var(--transition-interactive);
}
.bento-item:hover { transform: translateY(-3px); box-shadow: var(--shadow-md); }
@media (min-width: 960px) {
  .bento-item--xl { grid-column: span 2; grid-row: span 2; }
  .bento-item--wide { grid-column: span 2; }
  .bento-item--tall { grid-row: span 2; }
}
/* Tuile phare sous le layout 4-col : hauteur mini pour que le bloc texte (ancré en bas)
   ne grimpe pas sur le sujet de la photo, même quand le paragraphe passe à 3 lignes.
   Le texte SEO reste entier — on lui réserve seulement sa place. */
@media (max-width: 959px) { .bento-item--xl { min-height: 440px; } }
.bento-item--img { color: #fff; justify-content: flex-end; }
.bento-item--img::after {
  content: ''; position: absolute; inset: 0;
  background: linear-gradient(to top, rgba(8,24,48,0.92) 0%, rgba(8,24,48,0.55) 25%, rgba(8,24,48,0.12) 44%, transparent 63%);
  z-index: 1;
}
/* Lisibilité du texte sur l'image (contraste WCAG 2.2, aligné sur le héros) :
   ombre subtile pour détacher les caractères du fond photo. */
.bento-item--img > h3,
.bento-item--img > p,
.bento-item--img > .bento-cta { text-shadow: 0 1px 3px rgba(0,0,0,0.55), 0 1px 10px rgba(0,0,0,0.30); }
.bento-item--img > img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; z-index: 0; }
.bento-item--img > picture { position: absolute; inset: 0; z-index: 0; }
.bento-item--img > picture > img { width: 100%; height: 100%; object-fit: cover; }
.bento-item--img > .bento-rotate { position: absolute; inset: 0; z-index: 0; }
.bento-item--img > * { position: relative; z-index: 2; }

/* Rotateur de fond — minuterie pilotée par CSS (cadence d'horloge, compositeur).
   Pas de setInterval : la 1re bascule n'est plus en retard. app.js ne fait que
   mettre en pause hors-écran (classe .is-offscreen). */
.bento-rotate__slide { position: absolute; inset: 0; opacity: 0; }
.bento-rotate__slide:first-child { opacity: 1; } /* repli sans JS + mouvement réduit */
.bento-rotate__slide img { width: 100%; height: 100%; object-fit: cover; }

/* Cadrage des photos du rotateur EN MOBILE — object-position dirigé par F.
   Cible chaque slide séparément sous 960px ; le desktop n'est pas touché ici.
   - slide 1 (équipe)      : sujets décalés vers la droite.
   - slide 2 (ski-alpin)   : sujet déplacé vers la gauche (70%). */
@media (max-width: 959px) {
  .bento-rotate--2 .bento-rotate__slide:nth-child(1) img { object-position: 39% center; }
  .bento-rotate--2 .bento-rotate__slide:nth-child(2) img { object-position: 70% center; }
}

@media (prefers-reduced-motion: no-preference) {
  /* 2 photos : cycle 11 s = 2 × 5,5 s d'affichage, fondu ~0,8 s, symétrique. */
  .bento-rotate--2 .bento-rotate__slide { animation: bento-rotate-2 11s ease-in-out infinite; }
  .bento-rotate--2 .bento-rotate__slide:nth-child(2) { animation-delay: -5.5s; }
  .bento-rotate.is-offscreen .bento-rotate__slide { animation-play-state: paused; }
}
@keyframes bento-rotate-2 {
  0%, 42.7%  { opacity: 1; }
  50%, 92.7% { opacity: 0; }
  100%       { opacity: 1; }
}
.bento-item--accent { background: var(--grad-hero); color: #fff; }
.bento-stat { font-family: var(--font-display); font-weight: 600; font-size: var(--text-lg); line-height: 1.1; letter-spacing: -0.02em; text-wrap: balance; }
.bento-label { font-size: var(--text-sm); opacity: 0.92; }
.bento-cta { display: inline-flex; align-items: center; gap: 4px; margin-top: var(--space-2); font-size: var(--text-sm); font-weight: 600; opacity: 0.92; }
a.bento-item:hover .bento-cta { opacity: 1; }

/* Rotateur d'image (section « Pourquoi l'INSQ ») — base toujours opaque + slide du dessus
   en fondu (pas de scintillement, contrairement au double-fondu du bento sans voile).
   Tant que le slide du dessus = la même image que la base, le rendu reste parfaitement
   statique. Cadence alignée sur le bento (cycle 11 s). */
.media-rotate { position: relative; aspect-ratio: 1 / 1; }
.media-rotate__slide { position: absolute; inset: 0; }
.media-rotate__slide img { width: 100%; height: 100%; object-fit: cover; display: block; }
.media-rotate__top { opacity: 0; }
@media (prefers-reduced-motion: no-preference) {
  .media-rotate__top { animation: media-rotate-fade 11s ease-in-out infinite; }
}
@keyframes media-rotate-fade { 0%, 40% { opacity: 0; } 50%, 90% { opacity: 1; } 100% { opacity: 0; } }
.media-rotate.is-offscreen .media-rotate__top { animation-play-state: paused; }

/* ---------------- Scroll-driven reveal (sans JS, sans CLS) ---------------- */
.reveal { opacity: 1; }
@supports (animation-timeline: view()) {
  .reveal {
    opacity: 0;
    animation: reveal-fade linear both;
    animation-timeline: view();
    animation-range: entry 0% entry 42%;
  }
}
@keyframes reveal-fade { to { opacity: 1; } }

/* Barre de progression scroll (header) */
.scroll-progress {
  position: fixed; top: 0; left: 0; height: 3px; z-index: 101;
  background: var(--grad-hero); transform-origin: 0 50%; transform: scaleX(0); width: 100%;
}
@supports (animation-timeline: scroll()) {
  .scroll-progress {
    animation: grow-progress linear both;
    animation-timeline: scroll(root);
  }
}
@keyframes grow-progress { to { transform: scaleX(1); } }

/* ---------------- Statistiques ---------------- */
.stats { display: grid; gap: var(--space-6); grid-template-columns: repeat(2, 1fr); }
@media (min-width: 760px) { .stats { grid-template-columns: repeat(4, 1fr); } }
.stat { text-align: left; }
.stat-num { font-family: var(--font-display); font-weight: 600; font-size: var(--text-2xl); color: var(--color-primary); line-height: 1; letter-spacing: -0.02em; }
.stat-label { font-size: var(--text-sm); color: var(--color-text-muted); margin-top: var(--space-1); }

/* ---------------- Formulaire (micro-interactions) ---------------- */
.field { display: flex; flex-direction: column; gap: var(--space-2); }
.field label { font-size: var(--text-sm); font-weight: 600; }
.field input, .field textarea, .field select {
  width: 100%; min-height: 48px; padding: var(--space-3) var(--space-4);
  background: var(--color-surface); border: 1.5px solid var(--color-border);
  border-radius: var(--radius-md); color: var(--color-text); font-size: var(--text-base);
}
.field textarea { min-height: 140px; resize: vertical; padding-top: var(--space-3); }
.field input:focus, .field textarea:focus, .field select:focus {
  outline: none; border-color: var(--color-primary);
  box-shadow: 0 0 0 4px color-mix(in oklab, var(--color-primary) 18%, transparent);
}
.field input:user-valid, .field textarea:user-valid { border-color: var(--color-primary); }
.field-hint { font-size: var(--text-xs); color: var(--color-text-faint); }

/* ---------------- Skeleton (performance perçue) ---------------- */
.skeleton {
  background: linear-gradient(90deg, var(--color-surface-2) 25%, var(--color-surface-offset) 37%, var(--color-surface-2) 63%);
  background-size: 400% 100%; animation: shimmer 1.5s ease-in-out infinite; border-radius: var(--radius-md);
}
@keyframes shimmer { 0% { background-position: 100% 0; } 100% { background-position: 0 0; } }

/* ---------------- Pied de page ---------------- */
.footer { background: var(--color-surface); border-top: 1px solid var(--color-divider); padding-block: var(--space-16) var(--space-12); }
.footer-grid { display: grid; gap: var(--space-10); grid-template-columns: 1fr; }
@media (min-width: 760px) { .footer-grid { grid-template-columns: 1.6fr 1fr 1fr 1fr; } }
.footer h4 { font-family: var(--font-body); font-size: var(--text-sm); font-weight: 700; text-transform: uppercase; letter-spacing: 0.06em; color: var(--color-text-faint); margin-bottom: var(--space-4); }
.footer-links { display: flex; flex-direction: column; gap: var(--space-2); }
.footer-links a { color: var(--color-text-muted); font-size: var(--text-sm); }
.footer-links a:hover { color: var(--color-primary); }
.footer-bottom { margin-top: var(--space-12); padding-top: var(--space-6); border-top: 1px solid var(--color-divider); display: flex; flex-wrap: wrap; gap: var(--space-4); justify-content: space-between; align-items: center; font-size: var(--text-xs); color: var(--color-text-faint); }
.footer-legal { display: flex; flex-wrap: wrap; gap: var(--space-2) var(--space-4); align-items: center; }
.footer-legal a { color: var(--color-text-muted); }
.footer-legal a:hover { color: var(--color-primary); }

/* ---------------- Utilitaires ---------------- */
.grid-2 { display: grid; gap: var(--space-8); grid-template-columns: 1fr; }
@media (min-width: 860px) { .grid-2 { grid-template-columns: repeat(2, 1fr); align-items: center; } }
.grid-3 { display: grid; gap: var(--space-6); grid-template-columns: 1fr; }
@media (min-width: 640px) { .grid-3 { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 960px) { .grid-3 { grid-template-columns: repeat(3, 1fr); } }
.stack > * + * { margin-top: var(--space-4); }
.center { text-align: center; }
.mx-auto { margin-inline: auto; }
.full-bleed { width: 100%; }
.rounded-img { border-radius: var(--radius-2xl); overflow: hidden; box-shadow: var(--shadow-lg); }
.section-head { max-width: 60ch; margin-bottom: var(--space-12); }
.section-head .lead { margin-top: var(--space-3); }
.divider { height: 1px; background: var(--color-divider); border: 0; }
[hidden] { display: none !important; }

/* ---------------- Bouton « retour en haut » (apparaît au pied de page) ----------------
   Position calée sur le BORD DU CONTENEUR (sous les contrôles d'en-tête), jamais un
   offset arbitraire du bord de l'écran — leçon biffusion v2.4.3 (3 défauts corrigés en prod).
   Palette neutre (tokens) : fonctionne en clair et sombre, palette intacte. */
.back-to-top {
  position: fixed;
  right: calc(max(0px, (100vw - var(--content-wide)) / 2) + var(--gutter));
  bottom: calc(var(--space-6) + env(safe-area-inset-bottom, 0px));
  z-index: 90; width: 48px; height: 48px; border-radius: var(--radius-full);
  display: inline-flex; align-items: center; justify-content: center;
  background: var(--color-surface); color: var(--color-text-muted);
  border: 1px solid var(--color-border); box-shadow: var(--shadow-md); cursor: pointer;
  opacity: 0; transform: translateY(12px); pointer-events: none;
  transition: opacity 0.3s var(--ease-out), transform 0.3s var(--ease-out), color 0.2s var(--ease-out), border-color 0.2s var(--ease-out);
}
.back-to-top svg { width: 20px; height: 20px; }
.back-to-top:hover { color: var(--color-primary); border-color: var(--color-primary); transform: translateY(-2px); }
.back-to-top.is-visible { opacity: 1; transform: translateY(0); pointer-events: auto; }
.back-to-top:focus-visible { outline: 2px solid var(--color-primary); outline-offset: 3px; }
@media (prefers-reduced-motion: reduce) {
  .back-to-top, .back-to-top:hover { transition: opacity 0.2s linear; transform: none; }
}
