/* Espace eleve — Ounis Arts
   La charte du site tient en trois regles : deux couleurs et pas une de plus,
   des titres en serif compressee, des textes en sans dilatee. Le contraste
   entre les deux fait toute l'identite — bien plus que le choix des polices,
   qui sont ici celles du systeme (celles du site sont sous licence). */

:root {
  --sable: #a89474;
  --brun: #2c2824;
  --voile: rgba(168, 148, 116, .16);
  --trait: rgba(168, 148, 116, .28);
  --alerte: #c98b6b;
  --serif: "Bodoni Moda", Didot, Georgia, "Times New Roman", serif;
  --sans: "Helvetica Neue", Arial, sans-serif;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  min-height: 100vh;
  background: var(--brun);
  color: var(--sable);
  font-family: var(--sans);
  font-size: 13px;
  letter-spacing: .08em;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3 {
  font-family: var(--serif);
  font-weight: 400;
  letter-spacing: -.064em;
  line-height: .92;
  margin: 0;
}
h1 { font-size: clamp(44px, 7vw, 88px); }
h2 { font-size: clamp(30px, 4vw, 48px); }
h3 { font-size: clamp(22px, 2.4vw, 30px); }

a { color: inherit; }

.enseigne {
  font-family: var(--sans);
  font-size: 11px;
  letter-spacing: .32em;
  text-transform: uppercase;
  opacity: .75;
}

.page { max-width: 1080px; margin: 0 auto; padding: 6vh 24px 12vh; }

/* --- En-tete ------------------------------------------------------------ */
.tete {
  display: flex; align-items: baseline; justify-content: space-between;
  gap: 24px; flex-wrap: wrap;
  padding-bottom: 20px; margin-bottom: 44px;
  border-bottom: 1px solid var(--trait);
}
.tete .qui { font-size: 11px; letter-spacing: .18em; text-transform: uppercase; opacity: .7; }

/* --- Connexion ---------------------------------------------------------- */
.connexion {
  min-height: 100vh; display: grid; place-items: center; padding: 24px;
}
.carte {
  width: 100%; max-width: 420px;
  border: 1px solid var(--trait); border-radius: 3px;
  padding: 44px 38px 38px;
}
.carte h1 { margin-bottom: 6px; }
.carte .sous { font-size: 11px; letter-spacing: .2em; text-transform: uppercase; opacity: .6; margin-bottom: 34px; }

/* --- Champs ------------------------------------------------------------- */
label { display: block; margin-bottom: 18px; }
label span {
  display: block; font-size: 10px; letter-spacing: .22em;
  text-transform: uppercase; opacity: .65; margin-bottom: 7px;
}
input, select, textarea {
  width: 100%; padding: 11px 13px;
  background: transparent; color: var(--sable);
  border: 1px solid var(--trait); border-radius: 2px;
  font-family: var(--sans); font-size: 13px; letter-spacing: .05em;
}
input:focus, select:focus, textarea:focus, button:focus-visible {
  outline: 2px solid var(--sable); outline-offset: 3px; border-color: var(--sable);
}
select option { background: var(--brun); }
textarea { min-height: 78px; resize: vertical; }

/* --- Boutons ------------------------------------------------------------ */
button {
  min-height: 44px; padding: 0 24px;
  background: transparent; color: var(--sable);
  border: 1px solid var(--sable); border-radius: 999px;
  font-family: var(--sans); font-size: 11px; letter-spacing: .2em;
  text-transform: uppercase; cursor: pointer;
  transition: background .3s cubic-bezier(.25, 1, .5, 1), color .3s cubic-bezier(.25, 1, .5, 1);
}
button:hover { background: var(--sable); color: var(--brun); }
button.plein { background: var(--sable); color: var(--brun); }
button.plein:hover { background: transparent; color: var(--sable); }
button.discret { border-color: var(--trait); min-height: 34px; padding: 0 14px; font-size: 10px; }
button[disabled] { opacity: .45; cursor: default; }

/* --- Messages ----------------------------------------------------------- */
.mot {
  margin: 16px 0 0; padding: 11px 14px;
  border: 1px solid var(--trait); border-radius: 2px;
  font-size: 12px; letter-spacing: .05em; line-height: 1.5;
}
.mot.erreur { border-color: var(--alerte); color: var(--alerte); }
.mot.copier { font-family: ui-monospace, Consolas, monospace; letter-spacing: .12em; font-size: 15px; }
.mot:empty { display: none; }

/* --- Sections ----------------------------------------------------------- */
section { margin-bottom: 64px; }
section > h2 { margin-bottom: 22px; }
.vide { opacity: .5; font-size: 12px; }

/* --- Grille des oeuvres ------------------------------------------------- */
.toiles { display: grid; gap: 26px; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); }
.toile { border: 1px solid var(--trait); border-radius: 2px; overflow: hidden; }
.toile .cadre {
  aspect-ratio: 4 / 5; background: #241f1c;
  display: grid; place-items: center;
}
/* L'oeuvre est vue entiere : une toile ne se recadre pas. */
.toile img { width: 100%; height: 100%; object-fit: contain; display: block; }
.toile .legende { padding: 13px 15px 16px; }
.toile .legende b { font-family: var(--serif); font-size: 19px; letter-spacing: -.02em; font-weight: 400; display: block; }
.toile .legende em { font-style: normal; font-size: 10px; letter-spacing: .18em; text-transform: uppercase; opacity: .6; }

/* --- Lecons en video ----------------------------------------------------- */
.lecons { display: grid; gap: 26px; grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); }
.lecon { border: 1px solid var(--trait); border-radius: 2px; overflow: hidden; }
.lecon video { width: 100%; display: block; background: #000; aspect-ratio: 16 / 9; }
.lecon .legende { padding: 13px 15px 16px; }
.lecon .legende b { font-family: var(--serif); font-size: 19px; letter-spacing: -.02em; font-weight: 400; display: block; }
.lecon .legende p { margin: 8px 0 0; font-size: 12px; letter-spacing: .05em; opacity: .8; }

/* --- Listes ------------------------------------------------------------- */
.liste { border-top: 1px solid var(--trait); }
.ligne {
  display: flex; align-items: center; justify-content: space-between; gap: 18px;
  flex-wrap: wrap; padding: 15px 2px; border-bottom: 1px solid var(--trait);
}
.ligne .principal { font-size: 13px; letter-spacing: .06em; }
.ligne .second { font-size: 11px; letter-spacing: .12em; opacity: .6; }
.ligne .date {
  font-family: var(--serif); font-size: 25px; letter-spacing: -.03em;
  min-width: 108px;
}
.actions { display: flex; gap: 8px; flex-wrap: wrap; }

/* --- Formulaires en colonnes ------------------------------------------- */
.duo { display: grid; gap: 0 20px; grid-template-columns: repeat(auto-fit, minmax(210px, 1fr)); }

.cachee { display: none !important; }

@media (max-width: 600px) {
  .page { padding: 4vh 18px 10vh; }
  .carte { padding: 32px 24px 28px; }
  .ligne .date { min-width: 0; }
}

/* --- Utilitaires --------------------------------------------------------
   Ces classes remplacent des attributs style="" ecrits directement dans le
   HTML. La politique de securite de la page interdit le style en ligne
   (style-src 'self') : c'est ce qui empeche d'injecter du contenu par une
   valeur de formulaire. Les styles vivent donc tous ici. */
.pleine-largeur { width: 100%; }
.note-discrete { border-color: transparent; padding-left: 0; opacity: .55; }
.texte-mesure { max-width: 52ch; }
.forme-etroite { max-width: 420px; margin-top: 22px; }
.espace-bas { margin-bottom: 26px; }
.espace-haut { margin-top: 26px; }
.aligne-bas { align-self: end; margin-bottom: 18px; }
