/* ---------------------------------------------------------------
   Claire Chambolle — feuille de style
   Sobre, typographique, sans dependance externe (rapide et sans traceur).
   --------------------------------------------------------------- */

:root {
  --bg:        #fdfcfa;
  --bg-soft:   #f4f2ee;
  --text:      #1c1b19;
  --muted:     #6a675f;
  --line:      #e2dfd8;
  --accent:    #1f4e79;
  --accent-bg: #eaf0f6;

  --serif: "Iowan Old Style", "Palatino Linotype", Palatino, Georgia, "Times New Roman", serif;
  --sans:  -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;

  --measure: 42rem;
  --wide:    50rem;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg:        #15171a;
    --bg-soft:   #1d2025;
    --text:      #e8e5df;
    --muted:     #9d9a92;
    --line:      #2c3036;
    --accent:    #8ab4d8;
    --accent-bg: #1e2933;
  }
}

*, *::before, *::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--serif);
  font-size: 18px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}

.wrap {
  max-width: var(--wide);
  margin: 0 auto;
  padding: 0 1.5rem;
}

.skip {
  position: absolute;
  left: -9999px;
}
.skip:focus {
  left: 1rem; top: 1rem;
  z-index: 10;
  background: var(--accent);
  color: #fff;
  padding: .5rem 1rem;
  border-radius: 4px;
}

a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; text-underline-offset: 2px; }
a:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
  border-radius: 2px;
}

/* ----------------------------- En-tete ----------------------------- */

.site-header {
  border-bottom: 1px solid var(--line);
  padding: 2.75rem 0 0;
  margin-bottom: 3rem;
}

.identity .name {
  display: inline-block;
  font-size: clamp(1.9rem, 4.5vw, 2.6rem);
  font-weight: 600;
  letter-spacing: -0.015em;
  color: var(--text);
  line-height: 1.15;
}
.identity .name:hover { text-decoration: none; color: var(--accent); }

.identity .role {
  margin: .35rem 0 0;
  font-family: var(--sans);
  font-size: .875rem;
  color: var(--muted);
  letter-spacing: .01em;
}

.nav {
  display: flex;
  flex-wrap: wrap;
  gap: 1.5rem;
  margin-top: 1.75rem;
  font-family: var(--sans);
  font-size: .875rem;
  letter-spacing: .02em;
}

.nav a {
  display: inline-block;
  padding-bottom: .75rem;
  color: var(--muted);
  border-bottom: 2px solid transparent;
}
.nav a:hover { color: var(--text); text-decoration: none; }
.nav a.active { color: var(--text); border-bottom-color: var(--accent); }

/* ------------------------------ Texte ------------------------------ */

main { min-height: 55vh; padding-bottom: 4rem; }

.prose, .intro { max-width: var(--measure); }

.page-head { margin-bottom: 2.5rem; }
.page-head h1 {
  font-size: clamp(1.6rem, 3.5vw, 2.1rem);
  font-weight: 600;
  letter-spacing: -0.01em;
  margin: 0;
}
.page-head .count {
  margin: .35rem 0 0;
  font-family: var(--sans);
  font-size: .8125rem;
  color: var(--muted);
}

.prose h2, .intro h2 {
  font-size: 1.0625rem;
  font-family: var(--sans);
  font-weight: 600;
  letter-spacing: .04em;
  text-transform: uppercase;
  color: var(--muted);
  margin: 2.75rem 0 1rem;
  padding-bottom: .5rem;
  border-bottom: 1px solid var(--line);
}

.prose h3 { font-size: 1.15rem; font-weight: 600; margin: 2rem 0 .5rem; }
.prose p  { margin: 0 0 1.15rem; }

.prose ul, .intro ul { padding-left: 1.15rem; margin: 0 0 1.25rem; }
.prose li, .intro li { margin-bottom: .55rem; }

.prose strong { font-weight: 600; }

/* ------------------------- Liste publications ------------------------ */

.section-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 1rem;
  margin: 3.5rem 0 1.25rem;
  padding-bottom: .5rem;
  border-bottom: 1px solid var(--line);
}
.section-head h2 {
  font-family: var(--sans);
  font-size: 1.0625rem;
  font-weight: 600;
  letter-spacing: .04em;
  text-transform: uppercase;
  color: var(--muted);
  margin: 0;
}
.more { font-family: var(--sans); font-size: .8125rem; white-space: nowrap; }

.year-group { margin-bottom: 2.5rem; }
.year-heading {
  font-family: var(--sans);
  font-size: .8125rem;
  font-weight: 600;
  letter-spacing: .12em;
  color: var(--muted);
  margin: 0 0 .75rem;
  padding-bottom: .4rem;
  border-bottom: 1px solid var(--line);
}

.pub-list { list-style: none; margin: 0; padding: 0; }

.pub {
  display: grid;
  grid-template-columns: 3.5rem 1fr;
  gap: 0 1rem;
  padding: 1.15rem 0;
  border-bottom: 1px solid var(--line);
}
.pub:last-child { border-bottom: none; }

.pub-year {
  font-family: var(--sans);
  font-size: .8125rem;
  color: var(--muted);
  padding-top: .3rem;
  font-variant-numeric: tabular-nums;
}

/* Sur la page Publications, les entrees sont deja regroupees par annee :
   la colonne d'annee ferait doublon avec le titre de section. */
.pub-list.grouped .pub { grid-template-columns: 1fr; }
.pub-list.grouped .pub-year { display: none; }

.pub-title {
  font-size: 1.0625rem;
  font-weight: 600;
  line-height: 1.35;
  margin: 0 0 .3rem;
}
.pub-title a { color: var(--text); }
.pub-title a:hover { color: var(--accent); text-decoration: none; }

.pub-authors {
  margin: 0 0 .2rem;
  font-size: .9375rem;
  color: var(--muted);
}
.pub-ref {
  margin: 0;
  font-size: .9375rem;
  font-style: italic;
  color: var(--muted);
}
.pub-authors.big, .pub-ref.big { font-size: 1rem; }

.pub-links { margin: .6rem 0 0; display: flex; flex-wrap: wrap; gap: .5rem; }

.tag {
  display: inline-block;
  font-family: var(--sans);
  font-size: .75rem;
  font-weight: 500;
  letter-spacing: .03em;
  padding: .2rem .6rem;
  border: 1px solid var(--line);
  border-radius: 3px;
  color: var(--muted);
}
.tag:hover { border-color: var(--accent); color: var(--accent); text-decoration: none; }
.tag-pdf { background: var(--accent-bg); border-color: transparent; color: var(--accent); }

/* --------------------- Page d'une publication --------------------- */

.pub-single { max-width: var(--measure); }
.breadcrumb { font-family: var(--sans); font-size: .8125rem; margin: 0 0 1.5rem; }
.pub-single h1 {
  font-size: clamp(1.45rem, 3.2vw, 1.9rem);
  font-weight: 600;
  line-height: 1.25;
  margin: 0 0 .75rem;
}
.abstract { margin-top: 2.5rem; }
.abstract h2 {
  font-family: var(--sans);
  font-size: .8125rem;
  font-weight: 600;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--muted);
  margin: 0 0 .75rem;
}

.plain-list { padding-left: 1.15rem; }

/* ------------------------------ Pied ------------------------------ */

.site-footer {
  border-top: 1px solid var(--line);
  padding: 2rem 0 3rem;
  font-family: var(--sans);
  font-size: .8125rem;
  color: var(--muted);
}
.site-footer p { margin: 0 0 .25rem; }

/* ----------------------------- Mobile ----------------------------- */

@media (max-width: 34rem) {
  body { font-size: 17px; }
  .site-header { padding-top: 2rem; margin-bottom: 2rem; }
  .nav { gap: 1.1rem; margin-top: 1.25rem; }
  .pub { grid-template-columns: 1fr; gap: 0; }
  .pub-year { padding-top: 0; margin-bottom: .2rem; }
  .section-head { flex-direction: column; gap: .35rem; align-items: flex-start; }
}

@media print {
  .nav, .site-footer, .breadcrumb, .more { display: none; }
  body { font-size: 11pt; color: #000; background: #fff; }
  a { color: #000; text-decoration: underline; }
}
