/* TABLE CARDS v6 (FLT) - optionnel de flotte, 2026-11-13 ; v4 2026-11-16 = Photos only ; v5 2026-11-18 = Meta sur la carte */
.ttc-wrap { position: relative; }
.ttc-legend { display: flex; flex-wrap: wrap; justify-content: center; gap: 6px 18px; margin-bottom: 10px; font-size: .875rem; }
.ttc-legend-item { display: inline-flex; align-items: center; gap: 7px; }
/* Legende cliquable (filtre) */
.ttc-filter .ttc-legend-item { font: inherit; color: inherit; cursor: pointer; padding: 4px 12px; border-radius: 20px; background: transparent; border: 1px solid color-mix(in srgb, currentColor 25%, transparent); opacity: .65; transition: opacity .2s, border-color .2s; }
.ttc-filter .ttc-legend-item:hover { opacity: 1; }
.ttc-filter .ttc-legend-item.ttc-active { opacity: 1; font-weight: 600; border-color: currentColor; }
.ttc-dot { display: inline-block; width: 10px; height: 10px; border-radius: 50%; background: var(--ttc-c, currentColor); box-shadow: 0 0 6px var(--ttc-c, transparent); flex: none; }

/* Sans JS (robots, IA) : une grille simple de cartes, tout le texte dans le DOM */
.ttc-items { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 16px; }
.ttc-card { position: relative; display: flex; flex-direction: column; overflow: hidden; height: 100%; cursor: pointer; border-radius: 6px; padding: 0; }
.ttc-card-bordered { border: 1px solid currentColor; border-color: color-mix(in srgb, currentColor 25%, transparent); background: transparent; }
.ttc-card-media { flex: none; height: var(--ttc-img, 62%); min-height: 90px; overflow: hidden; }
.ttc-card-media picture, .ttc-card-media img, .ttc-card-media video { display: block; width: 100%; height: 100%; object-fit: cover; }
.ttc-card-text { padding: 6px 8px; min-height: 0; overflow: hidden; }
.ttc-card-title { margin: 0; font-size: calc(var(--ttc-fs, 13px) * var(--ttc-ts, 1)); line-height: 1.15; font-weight: 600; }
.ttc-card-meta { font-size: calc(var(--ttc-fs, 13px) * .82 * var(--ttc-ms, 1)); line-height: 1.2; margin: 2px 0 0; }
/* v6 : le Style de la meta garde son effet sur la carte, a l'echelle de la table */
.ttc-card-meta.uk-text-small { font-size: calc(var(--ttc-fs, 13px) * .7 * var(--ttc-ms, 1)); line-height: 1.25; }
.ttc-card-meta.uk-text-large, .ttc-card-meta.uk-text-lead { font-size: calc(var(--ttc-fs, 13px) * 1.05 * var(--ttc-ms, 1)); }
.ttc-card-group { font-size: calc(var(--ttc-fs, 13px) * .78); opacity: .7; margin-top: 2px; }
.ttc-card .ttc-dot { position: absolute; top: 7px; left: 7px; z-index: 1; }
.ttc-card-more { display: none; }
.ttc-card:focus-visible { outline: 2px solid currentColor; outline-offset: 2px; }

/* Avec JS : la scene 3D (les cartes y sont deplacees) */
.ttc-js .ttc-items { position: absolute; visibility: hidden; height: 0; overflow: hidden; }
.ttc-js .ttc-stage { position: relative; height: var(--ttc-stage, 60vh); overflow: hidden; }
.ttc-stage .ttc-item { width: var(--ttc-w, 150px); height: var(--ttc-h, 150px); }
/* v6 : photo a hauteur fixe (part de la hauteur REGLEE), la carte s'allonge pour que tout le texte rentre */
.ttc-stage .ttc-card-media { height: var(--ttc-mh, var(--ttc-img, 62%)); }
.ttc-stage .ttc-card { transition: box-shadow .2s, transform .2s; box-shadow: 0 0 10px color-mix(in srgb, var(--ttc-c, currentColor) 30%, transparent); }
.ttc-stage .ttc-card:hover { box-shadow: 0 0 22px color-mix(in srgb, var(--ttc-c, currentColor) 75%, transparent); }
.ttc-small .ttc-card-group { display: none; }
.ttc-stage .ttc-item { transition: opacity .4s; }
.ttc-stage .ttc-item.ttc-off { opacity: 0; pointer-events: none; }
.ttc-js .ttc-items .ttc-item.ttc-off { display: none; }

/* La fiche (2D, texte net) */
.ttc-overlay { position: fixed; inset: 0; z-index: 1000; background: rgba(3, 14, 24, .88); backdrop-filter: blur(4px); }
.ttc-overlay[hidden] { display: none; }
.ttc-sheet { position: absolute; display: grid; grid-template-columns: 1.2fr 1fr; overflow: hidden; border-radius: 10px; padding: 0;
             box-shadow: 0 20px 60px rgba(0, 0, 0, .6); transition: left .45s cubic-bezier(.2, .8, .2, 1), top .45s cubic-bezier(.2, .8, .2, 1),
             width .45s cubic-bezier(.2, .8, .2, 1), height .45s cubic-bezier(.2, .8, .2, 1); }
.ttc-sheet-media { min-height: 0; overflow: hidden; }
.ttc-sheet-media img, .ttc-sheet-media video { display: block; width: 100%; height: 100%; object-fit: cover; }
.ttc-sheet-text { overflow: auto; opacity: 0; transition: opacity .25s; }
.ttc-sheet.ttc-ready .ttc-sheet-text { opacity: 1; transition-delay: .1s; }
.ttc-sheet-title { margin: 0 0 6px; }
.ttc-sheet-meta { margin: 0 0 14px; }
.ttc-sheet-content > :last-child { margin-bottom: 0; }
.ttc-sheet-content img { cursor: zoom-in; }
.ttc-btn { position: fixed; z-index: 1001; width: 48px; height: 48px; padding: 0; border-radius: 50%; border: 1px solid rgba(255, 255, 255, .35);
           background: rgba(0, 0, 0, .35); color: #fff; cursor: pointer; display: flex; align-items: center; justify-content: center; }
.ttc-btn:hover { background: rgba(0, 0, 0, .6); }
.ttc-btn[hidden] { display: none; }
.ttc-prev { left: 16px; top: 50%; transform: translateY(-50%); }
.ttc-next { right: 16px; top: 50%; transform: translateY(-50%); }
.ttc-close { right: 16px; top: 16px; }
.ttc-counter { position: fixed; z-index: 1001; bottom: 16px; left: 50%; transform: translateX(-50%); color: rgba(255, 255, 255, .8); font-size: .8125rem; white-space: nowrap; }
@media (max-width: 759px) {
    .ttc-sheet { grid-template-columns: 1fr; grid-template-rows: 40% 1fr; }
    .ttc-sheet-text { padding-bottom: 64px; }
    .ttc-btn { width: 40px; height: 40px; }
    .ttc-prev, .ttc-next { top: auto; bottom: 10px; transform: none; }
    .ttc-counter { bottom: 22px; }
}

/* v4 - Photos only : la photo remplit la carte ; au clic, la photo ENTIERE seule (visionneuse) */
.ttc-photos .ttc-card-media { height: 100%; min-height: 0; }
.ttc-overlay.ttc-photos .ttc-sheet { grid-template-columns: 1fr; grid-template-rows: 1fr; background: transparent; box-shadow: none; border-radius: 0; }
.ttc-overlay.ttc-photos .ttc-sheet-text { display: none; }
.ttc-overlay.ttc-photos .ttc-sheet-media { display: flex; align-items: center; justify-content: center; }
.ttc-overlay.ttc-photos .ttc-sheet-media img, .ttc-overlay.ttc-photos .ttc-sheet-media video { width: auto; height: auto; max-width: 100%; max-height: 100%; object-fit: contain; border-radius: 6px; }

