/* onROCKY — page Entretien (sauvegarde, restauration, remise à zéro), forme « Galet » : une vitrine sur le fond uni,
   sœur de la page Licence (mêmes règles .vitrine-*), une seule carte centrée en surface avec l'ombre douce, une seule
   action principale (Télécharger la sauvegarde). Aucun contour : les zones sont des blocs arrondis séparés par le ton ;
   celles qui remplacent ou effacent les données sont teintées de rubis, avec leur mot et le pictogramme d'alerte (jamais
   la couleur seule) ; le bouton rubis plein n'apparaît qu'à l'étape de confirmation, posée en surface dans la zone.
   Composants de rapport/bilan.css ; jetons de styles/theme.css seulement. */

/* ------------------------------------------------------------------------------------------------ Vitrine (comme licence.css) */

body.vitrine { min-height: 100vh; background: var(--oaa-fond); }
.vitrine-barre {
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  max-width: 1180px; margin: 0 auto; padding: 24px 28px 0;
}
.vitrine-logo { --oaa-taille-symbole: 36px; }
.vitrine-liens { display: flex; align-items: center; gap: 10px; }
.vitrine-liens .bouton { text-decoration: none; }

.vitrine-colonne { width: min(600px, 100% - 32px); margin: 0 auto; padding: 36px 0 64px; }
.vitrine-titre { margin: 0 0 22px; padding: 0 4px; }
.vitrine-titre .surtitre { margin-bottom: 6px; }
.vitrine-titre h1 { font-size: 26px; line-height: 32px; letter-spacing: -.03em; }
.vitrine-titre .direct { margin-top: 6px; min-height: 0; font-size: 14px; line-height: 1.5; }

.vitrine-carte {
  padding: 28px 32px 32px; border: 1px solid transparent; border-radius: 28px;
  background: var(--oaa-surface); box-shadow: var(--oaa-ombre);
  animation: oaa-apparition var(--oaa-duree-lente) var(--oaa-courbe) both;
}

/* Le message se pose au-dessus de la carte, sur un fond teinté arrondi, sans liseré ni bordure : réussite en turquoise
   doux avec le point rond et son halo, erreur en rubis doux avec le pictogramme d'alerte ; le texte à l'encre. */
#message {
  display: flex; align-items: flex-start; gap: 12px; margin: 0 0 16px; padding: 12px 18px 12px 16px;
  border: 1px solid transparent; border-radius: var(--oaa-rayon);
  background: var(--ton-doux, var(--oaa-surface)); color: var(--oaa-encre); font-size: 13.5px; line-height: 1.5; overflow-wrap: anywhere;
}
#message::before { content: ""; flex: none; width: 8px; height: 8px; margin: 6px 5px 0; border-radius: 50%; background: var(--oaa-info); box-shadow: 0 0 0 4px var(--info-halo); }
#message:not([hidden]) { animation: oaa-apparition var(--oaa-duree) var(--oaa-courbe); }
#message.succes { --ton-doux: var(--oaa-info-doux); font-weight: 550; }
#message.erreur { --ton-doux: var(--oaa-danger-doux); }
#message.erreur::before { width: 18px; height: 18px; margin: 1px 0 0; border-radius: 0; box-shadow: none; background: var(--oaa-danger); -webkit-mask: var(--oaa-ic-alerte) center / contain no-repeat; mask: var(--oaa-ic-alerte) center / contain no-repeat; }

/* ------------------------------------------------------------------------------------------------ Contenu de la carte */

/* Teinte des zones qui remplacent ou effacent : le rubis à 6 % sur la surface (plus légère que le rubis doux des
   blocages, qui reste lisible dessus). */
.vitrine-carte { --zone-rubis: color-mix(in srgb, var(--oaa-danger) 6%, var(--oaa-surface)); }
.vitrine-carte p { margin: 10px 0 0; color: var(--oaa-secondaire); font-size: 13.5px; line-height: 1.6; }
.vitrine-carte .date { color: var(--oaa-encre); font-weight: 600; }

/* Conserver une copie : le pictogramme dans un rond accent doux, puis l'action principale en pleine largeur. */
.volet-tete { display: flex; align-items: center; gap: 12px; }
.volet-ic { display: grid; place-items: center; flex: none; width: 36px; height: 36px; border-radius: 50%; background: var(--oaa-accent-doux); color: var(--oaa-accent-fonce); }
.volet-ic .oaa-ic { --oaa-taille-ic: 18px; }
#exporter { width: 100%; height: 44px; margin-top: 20px; font-size: 14px; }

/* Les zones : des blocs arrondis (20 px) posés dans la carte, sans trait. Neutre (copies de secours) : surface-alt ;
   dangereuse : la teinte rubis, et le mot en capitales (jamais la couleur seule). Leurs boutons secondaires passent en
   surface, pour se détacher du bloc. */
.zone {
  position: relative; margin: 12px 0 0; padding: 20px 22px 22px;
  border: 1px solid transparent; border-radius: 20px; background: var(--oaa-surface-alt);
}
.volet + .zone { margin-top: 28px; }
.zone-rubis { background: var(--zone-rubis); }
.zone > .bouton { margin-top: 16px; }
.zone .bouton:not(.principal, .irise, .danger-plein, .danger-doux, .fantome) { height: 40px; padding: 0 18px; background: var(--oaa-surface); }
.zone .bouton:not(.principal, .irise, .danger-plein, .danger-doux, .fantome):hover:not(:disabled) { background: color-mix(in srgb, var(--oaa-encre) 5%, var(--oaa-surface)); }
.vitrine-carte .zone-mot {
  display: flex; align-items: center; gap: 6px; margin: 0 0 8px;
  color: var(--oaa-danger); font: 750 11px/16px var(--oaa-police); letter-spacing: .06em; text-transform: uppercase;
}
.zone-mot .oaa-ic { --oaa-taille-ic: 15px; }
/* Accent des indications d’installation. */
.vitrine-carte .zone-mot-essai { color: var(--oaa-accent-fonce); }

/* Choisir le fichier : le bouton du sélecteur dessiné comme un .bouton secondaire (pilule en surface dans la zone). */
.fichier { display: grid; grid-template-columns: minmax(0, 1fr); justify-items: start; gap: 8px; margin: 18px 0 0; }
.fichier > input { justify-self: stretch; width: 100%; min-width: 0; }
input[type="file"] {
  max-width: 100%; padding: 0; border: 0; border-radius: var(--oaa-rayon-pilule); background: transparent;
  color: var(--oaa-secondaire); font: 500 13px var(--oaa-police);
}
input[type="file"]::file-selector-button {
  height: 40px; margin-right: 14px; padding: 0 18px; border: 1px solid transparent; border-radius: var(--oaa-rayon-pilule);
  background: var(--oaa-surface); color: var(--oaa-encre); font: 600 13.5px/1 var(--oaa-police); box-shadow: none; cursor: pointer;
  transition: background-color var(--oaa-duree-rapide) ease;
}
input[type="file"]:hover:not(:disabled)::file-selector-button { background: color-mix(in srgb, var(--oaa-encre) 5%, var(--oaa-surface)); }
input[type="file"]:disabled { opacity: .5; }

/* L'étape de confirmation : un bloc en surface posé dans la zone (plus de filet au-dessus) ; elle seule porte le bouton
   rubis plein. Dedans, les boutons secondaires reprennent le surface-alt de bilan.css. */
.confirmation { margin-top: 18px; padding: 18px 20px 20px; border: 1px solid transparent; border-radius: var(--oaa-rayon); background: var(--oaa-surface); }
.confirmation:not([hidden]) { animation: oaa-apparition var(--oaa-duree) var(--oaa-courbe); }
.zone .confirmation .bouton:not(.principal, .irise, .danger-plein, .danger-doux, .fantome) { background: var(--oaa-surface-alt); }
.zone .confirmation .bouton:not(.principal, .irise, .danger-plein, .danger-doux, .fantome):hover:not(:disabled) { background: color-mix(in srgb, var(--oaa-encre) 6%, var(--oaa-surface-alt)); }
.vitrine-carte :is(#date-fichier, #resume-remise-zero) { margin-top: 0; color: var(--oaa-encre); font-weight: 600; font-variant-numeric: tabular-nums; }

/* Le tableau de comparaison : sans cadre ni filet. La légende en surtitre, les en-têtes de colonne en secondaire, puis
   des rangées arrondies séparées par le fond alterné très doux de bilan.css ; l'en-tête de rangée suit sa rangée. */
.table-defile { margin-top: 14px; overflow-x: auto; }
.table-defile table { font-variant-numeric: tabular-nums; }
.table-defile caption { padding: 0 14px 8px; text-align: left; color: var(--oaa-secondaire); font: 650 11px/16px var(--oaa-police); letter-spacing: .06em; text-transform: uppercase; }
/* Les en-têtes de colonne peuvent passer à la ligne (bilan.css les garde sur une ligne) : le tableau tient dans la
   carte, sans barre de défilement de 2 px sous Windows ni avec une police plus large ; sur un écran étroit, il défile. */
.table-defile thead th { position: static; padding-top: 4px; padding-bottom: 8px; white-space: normal; vertical-align: bottom; background: transparent; }
.table-defile th:not(:first-child), .table-defile td { text-align: right; }
.table-defile tbody th {
  padding: 11px 14px; border-top-left-radius: var(--oaa-rayon-petit); border-bottom-left-radius: var(--oaa-rayon-petit);
  background: transparent; color: var(--oaa-encre); font: 600 13px var(--oaa-police); letter-spacing: 0; text-transform: none;
  transition: background-color var(--oaa-duree-rapide) ease;
}
.table-defile tbody tr:nth-child(even) th { background: var(--rangee-alternee); }
.table-defile tbody tr:hover th { background: var(--oaa-surface-alt); }
.table-defile td:last-child { color: var(--oaa-encre); font-weight: 700; }

/* Blocage : un fond rubis doux arrondi et le pictogramme d'alerte, sans bordure. */
.vitrine-carte .blocage {
  display: flex; align-items: flex-start; gap: 10px; padding: 12px 18px 12px 14px;
  border: 1px solid transparent; border-radius: var(--oaa-rayon);
  background: var(--oaa-danger-doux); color: var(--oaa-encre);
}
.blocage::before { content: ""; flex: none; width: 18px; height: 18px; margin-top: 2px; background: var(--oaa-danger); -webkit-mask: var(--oaa-ic-alerte) center / contain no-repeat; mask: var(--oaa-ic-alerte) center / contain no-repeat; }

/* La case d'accord : la case Galet de bilan.css (carré arrondi sur fond gris doux, sans contour) ; cochée, elle passe
   en rubis plein, la couleur de l'action qu'elle déverrouille. */
.accord { display: flex; align-items: flex-start; gap: 10px; margin: 16px 0 0; color: var(--oaa-encre); font: 550 13.5px/1.5 var(--oaa-police); cursor: pointer; }
.accord input { flex: none; margin: 1px 0 0; cursor: pointer; }
.accord input:checked { background: var(--oaa-danger); }
.accord input::before { background: var(--oaa-sur-danger); }
.zone .actions { margin-top: 16px; gap: 8px; }
.zone .actions .bouton { height: 40px; padding: 0 18px; }

/* ------------------------------------------------------------------------------------------------ Écrans étroits */

/* Écran bas (1366×768 : 657 px utiles) : la vitrine se resserre comme sur la page Licence (mêmes règles .vitrine-*). */
@media (max-height: 820px) {
  .vitrine-barre { padding-top: 16px; }
  .vitrine-colonne { padding-top: 22px; }
  .vitrine-titre { margin-bottom: 16px; }
  .vitrine-carte { padding-top: 24px; }
  #message { margin-bottom: 12px; }
}
@media (max-width: 600px) {
  .vitrine-barre { flex-wrap: wrap; row-gap: 12px; padding: 16px 16px 0; }
  .vitrine-liens { flex-wrap: wrap; }
  .vitrine-logo { --oaa-taille-symbole: 30px; }
  .vitrine-colonne { padding-top: 24px; }
  .vitrine-titre h1 { font-size: 24px; line-height: 30px; }
  .vitrine-carte { padding: 22px 16px 22px; border-radius: var(--oaa-rayon-grand); }
  .zone { padding: 18px 16px 18px; }
  .confirmation { padding: 16px 14px 16px; }
  .vitrine-carte .bouton { max-width: 100%; min-height: 44px; height: auto; padding-block: 10px; white-space: normal; overflow-wrap: anywhere; line-height: 1.4; text-align: center; }
  .zone .bouton:not(.principal, .irise, .danger-plein, .danger-doux, .fantome), .zone .actions .bouton, #exporter { height: auto; min-height: 44px; padding-block: 10px; }
  .zone .actions .bouton { flex: 1 1 auto; }
}
@media (max-width: 460px) {
  .vitrine-liens .bouton { padding: 0 10px; }
  .vitrine-liens .bouton::before { display: none; }
}
/* Couleurs forcées (contraste élevé de Windows) : les bordures transparentes redeviennent des contours ; points et
   pictogrammes dessinés en fond prennent la couleur du texte. */
@media (forced-colors: active) {
  #message::before, .blocage::before { forced-color-adjust: none; background: CanvasText; box-shadow: none; }
  .accord input:checked { background: Highlight; }
  .accord input::before { background: HighlightText; }
}

/* Récupération locale : sélection explicite, dans la page de sauvegardes. */
.recuperation-liste { display:flex; gap:12px; align-items:flex-start; padding:14px 0; cursor:pointer; }
.recuperation-liste > input { margin-top:4px; flex:0 0 auto; }
.recuperation-liste > span { display:grid; gap:4px; min-width:0; overflow-wrap:anywhere; }
.recuperation-liste strong { color:var(--encre); }
.recuperation-liste > span > span { font-size:13px; line-height:1.5; }
.recuperation-destination { overflow-wrap:anywhere; font-weight:600; }
#recuperation-message:empty { display:none; }
