/* ==========================================================================
   The Steady Day  ·  petcharat-hospital.com
   Feuille unique. Vocabulaire de classes : le CADRAN SOLAIRE (sundial).
   Prefixe : .sdl-
   Rythme : gouttiere d'heure a gauche (date en chasse fixe + filet + cran),
            contenu a droite. Filets fins, pas d'ombres portees, angles vifs.
   ========================================================================== */

:root {
  /* Palette : la lumiere du jour sur de la pierre calcaire */
  --stone:        #e9e4d6;  /* fond de page, calcaire chaud */
  --stone-deep:   #ded7c5;  /* bandes creusees */
  --stone-lit:    #f6f3e9;  /* panneaux eclaires, vignettes */
  --umbra:        #262b26;  /* encre : l'ombre, graphite verdi */
  --umbra-soft:   #5b6058;  /* texte secondaire */
  --rule:         #cdc5b0;  /* filets */
  --rule-fine:    #dcd5c2;
  --noon:         #3d7a4e;  /* dominante : vert de feuille en plein midi */
  --noon-deep:    #2c5a3a;
  --noon-wash:    #e2ead9;
  --wheat:        #cfa63f;  /* le cran, les chiffres, le gnomon */
  --dusk:         #4b5a7e;  /* le bleu de l'ombre : liens et renvois */

  /* Teintes de section, une par rubrique */
  --hue-sleep:    #4b5a7e;
  --hue-move:     #3d7a4e;
  --hue-food:     #9a6a1e;
  --hue-desk:     #55636b;
  --hue-calm:     #6b5a86;
  --hue-home:     #2f6f6a;
  --hue-habit:    #8a4a3c;

  --court:  1160px;
  --measure: 68ch;
  --gutter: clamp(1rem, 3.4vw, 2.4rem);

  --face-title: Palatino, "Palatino Linotype", "Book Antiqua", "URW Palladio L", Georgia, serif;
  --face-text:  Corbel, Seravek, Candara, "Noto Sans", "Segoe UI", sans-serif;
  --face-mark:  "Andale Mono", Menlo, Consolas, "DejaVu Sans Mono", monospace;
}

* { box-sizing: border-box; }

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

body {
  margin: 0;
  background: var(--stone);
  color: var(--umbra);
  font-family: var(--face-text);
  font-size: 17px;
  line-height: 1.68;
}

img { max-width: 100%; display: block; }

a { color: var(--dusk); text-underline-offset: 3px; text-decoration-thickness: 1px; }
a:hover, a:focus-visible { color: var(--noon-deep); }
:focus-visible { outline: 2px solid var(--wheat); outline-offset: 2px; }

h1, h2, h3, h4 {
  font-family: var(--face-title);
  font-weight: 600;
  line-height: 1.18;
  letter-spacing: -0.005em;
  margin: 0 0 .7rem;
  text-wrap: balance;
}

/* --- utilitaires -------------------------------------------------------- */

.sdl-mute {
  position: absolute; width: 1px; height: 1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap;
}

.sdl-skip {
  position: absolute; left: -9999px; top: 0;
  background: var(--umbra); color: var(--stone-lit);
  padding: .6rem 1rem; z-index: 20;
}
.sdl-skip:focus { left: .6rem; top: .6rem; }

.sdl-court {
  width: 100%;
  max-width: var(--court);
  margin-inline: auto;
  padding-inline: var(--gutter);
}
.sdl-court--narrow { max-width: 900px; }

/* --- corniche (en-tete de site) ----------------------------------------- */

.sdl-cornice {
  background: var(--stone-lit);
  border-bottom: 1px solid var(--rule);
}
.sdl-cornice__inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 1rem .9rem;
  padding-block: .85rem;
}

.sdl-gnomon {
  display: flex; align-items: center; gap: .7rem;
  text-decoration: none; color: inherit;
}
.sdl-gnomon__mark { flex: none; }
.sdl-gnomon__name {
  display: block;
  font-family: var(--face-title);
  font-size: 1.36rem;
  line-height: 1.05;
  letter-spacing: .01em;
}
.sdl-gnomon__motto {
  display: block;
  font-family: var(--face-mark);
  font-size: .66rem;
  letter-spacing: .2em;
  text-transform: uppercase;
  color: var(--umbra-soft);
  margin-top: .28rem;
}

.sdl-bearings {
  display: flex; flex-wrap: wrap; gap: .1rem 1.05rem;
  font-size: .93rem;
}
.sdl-bearings a {
  color: var(--umbra);
  text-decoration: none;
  padding: .22rem 0;
  border-bottom: 2px solid transparent;
}
.sdl-bearings a:hover,
.sdl-bearings a:focus-visible,
.sdl-bearings a[aria-current="page"] { border-bottom-color: var(--wheat); color: var(--noon-deep); }

/* --- le cadran (heros) --------------------------------------------------- */

.sdl-face {
  position: relative;
  overflow: hidden;
  border-bottom: 1px solid var(--rule);
  isolation: isolate;
}
.sdl-face__photo {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  object-fit: cover;
  object-position: center 42%;
  z-index: 0;
}
/* Voile EN DUR : la couleur du fond de page, jamais une variable pale. */
.sdl-face__shade {
  position: absolute; inset: 0; z-index: 1;
  background: linear-gradient(178deg,
      rgba(233, 228, 214, .88) 0%,
      rgba(233, 228, 214, .78) 42%,
      rgba(233, 228, 214, .84) 72%,
      rgba(233, 228, 214, .93) 100%);
}
.sdl-face__core {
  position: relative; z-index: 2;
  padding-block: clamp(3rem, 8vw, 5.6rem);
}
.sdl-face h1 {
  font-size: clamp(2.05rem, 1.3rem + 3.1vw, 3.5rem);
  margin-bottom: 1rem;
  max-width: 900px;
}
.sdl-face__lede {
  font-size: clamp(1.02rem, .97rem + .34vw, 1.19rem);
  max-width: 62ch;
  margin: 0 0 1.1rem;
  color: #33382f;
}
.sdl-face__lede + .sdl-face__lede { color: var(--umbra-soft); font-size: 1rem; }

.sdl-motto {
  font-family: var(--face-mark);
  font-size: .72rem;
  letter-spacing: .26em;
  text-transform: uppercase;
  color: var(--noon-deep);
  margin: 0 0 .95rem;
}

.sdl-sweep {
  display: flex; align-items: center; gap: .75rem;
  margin: 0 0 1.4rem; color: var(--wheat);
  max-width: 420px;
}
.sdl-sweep::before { content: ""; height: 1px; flex: 1; background: linear-gradient(90deg, var(--wheat), rgba(207,166,63,0)); }
.sdl-sweep__pin { font-size: .8rem; letter-spacing: .3em; }

.sdl-steps { display: flex; flex-wrap: wrap; gap: .7rem; margin-top: 1.5rem; }
.sdl-step {
  display: inline-block;
  font-family: var(--face-mark);
  font-size: .8rem;
  letter-spacing: .1em;
  text-transform: uppercase;
  text-decoration: none;
  padding: .62rem 1.2rem;
  background: var(--noon-deep);
  color: var(--stone-lit);
  border: 1px solid var(--noon-deep);
}
.sdl-step:hover, .sdl-step:focus-visible { background: var(--umbra); border-color: var(--umbra); color: var(--stone-lit); }
.sdl-step--hollow { background: transparent; color: var(--umbra); border-color: var(--rule); }
.sdl-step--hollow:hover, .sdl-step--hollow:focus-visible { background: var(--stone-lit); color: var(--noon-deep); border-color: var(--noon-deep); }

/* --- bandes de section --------------------------------------------------- */

.sdl-band { padding-block: clamp(2.4rem, 5.5vw, 4rem); border-bottom: 1px solid var(--rule-fine); }
.sdl-band--sunk { background: var(--stone-deep); border-bottom-color: var(--rule); }
.sdl-band--lit  { background: var(--stone-lit); }

.sdl-band__head { margin-bottom: 1.9rem; max-width: 74ch; }
.sdl-band__head h2 { font-size: clamp(1.5rem, 1.2rem + 1.2vw, 2.1rem); }
.sdl-band__note { margin: .35rem 0 0; color: var(--umbra-soft); }
.sdl-band__kicker {
  font-family: var(--face-mark);
  font-size: .7rem; letter-spacing: .24em; text-transform: uppercase;
  color: var(--noon-deep); margin: 0 0 .5rem;
}

/* --- l'anneau des heures (grille des rubriques) -------------------------- */

.sdl-hours {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1px;
  background: var(--rule);
  border: 1px solid var(--rule);
}
.sdl-hour {
  background: var(--stone-lit);
  display: flex; flex-direction: column;
  text-decoration: none; color: inherit;
  border-top: 3px solid var(--tone, var(--noon));
}
.sdl-hour--wide { grid-column: span 2; }
.sdl-hour:hover, .sdl-hour:focus-visible { background: #fffdf6; }
.sdl-hour__plate {
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  filter: saturate(.94);
}
.sdl-hour--wide .sdl-hour__plate { aspect-ratio: 32 / 11; }
.sdl-hour__body { padding: 1rem 1.1rem 1.25rem; display: flex; flex-direction: column; gap: .35rem; flex: 1; }
.sdl-hour__numeral {
  font-family: var(--face-mark);
  font-size: .68rem; letter-spacing: .2em;
  color: var(--tone, var(--noon-deep));
  text-transform: uppercase;
}
.sdl-hour__name { font-family: var(--face-title); font-size: 1.18rem; margin: 0; }
.sdl-hour__gloss { margin: 0; font-size: .93rem; color: var(--umbra-soft); }
.sdl-hour__go {
  margin-top: auto; padding-top: .6rem;
  font-family: var(--face-mark); font-size: .72rem; letter-spacing: .12em;
  color: var(--dusk); text-transform: uppercase;
}

/* --- l'arc du jour (fil date) -------------------------------------------- */

.sdl-arc { border-top: 1px solid var(--rule); }

.sdl-tick {
  display: grid;
  grid-template-columns: 6.4rem 8.6rem 1fr;
  gap: 0 1.25rem;
  padding: 1.35rem 0;
  border-bottom: 1px solid var(--rule-fine);
  align-items: start;
}
.sdl-tick__when {
  font-family: var(--face-mark);
  font-size: .84rem;
  color: var(--umbra-soft);
  position: relative;
  padding-left: .95rem;
  padding-top: .15rem;
  white-space: nowrap;
}
.sdl-tick__when::before {
  content: "";
  position: absolute; left: 0; top: .45rem;
  width: 7px; height: 7px;
  background: var(--tone, var(--wheat));
}
.sdl-tick__thumb {
  width: 100%; aspect-ratio: 4 / 3; object-fit: cover;
  border: 1px solid var(--rule);
}
.sdl-tick__body { min-width: 0; }
.sdl-tick__where {
  font-family: var(--face-mark);
  font-size: .68rem; letter-spacing: .18em; text-transform: uppercase;
  color: var(--tone, var(--noon-deep));
  display: block; margin-bottom: .3rem;
}
.sdl-tick__head { font-size: 1.24rem; margin: 0 0 .38rem; }
.sdl-tick__head a { color: var(--umbra); text-decoration: none; border-bottom: 1px solid var(--rule); }
.sdl-tick__head a:hover, .sdl-tick__head a:focus-visible { border-bottom-color: var(--noon); color: var(--noon-deep); }
.sdl-tick__lede { margin: 0; color: var(--umbra-soft); font-size: .96rem; }

.sdl-tick--noon { background: var(--stone-lit); padding-inline: 1.1rem; border-left: 3px solid var(--wheat); }
.sdl-tick--noon .sdl-tick__head { font-size: 1.46rem; }

/* --- l'equation du temps (encadre) --------------------------------------- */

.sdl-equation {
  background: var(--noon-wash);
  border-left: 3px solid var(--noon);
  padding: 1.1rem 1.25rem;
  margin: 2rem 0;
}
.sdl-equation h3 {
  font-family: var(--face-mark);
  font-size: .74rem; letter-spacing: .18em; text-transform: uppercase;
  color: var(--noon-deep); margin: 0 0 .5rem;
}
.sdl-equation p:last-child { margin-bottom: 0; }

/* --- chapelet de rappels (petits reperes) -------------------------------- */

.sdl-latitude {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
  gap: 1px;
  background: var(--rule);
  border: 1px solid var(--rule);
}
.sdl-latitude__cell { background: var(--stone-lit); padding: 1.05rem 1.15rem; }
.sdl-latitude__key {
  font-family: var(--face-mark); font-size: .68rem; letter-spacing: .2em;
  text-transform: uppercase; color: var(--noon-deep); display: block; margin-bottom: .3rem;
}
.sdl-latitude__val { margin: 0; font-size: .95rem; color: var(--umbra-soft); }

/* --- page d'article : rail d'heure + colonne de lecture ------------------ */

.sdl-crumbs {
  font-family: var(--face-mark);
  font-size: .72rem; letter-spacing: .1em;
  color: var(--umbra-soft);
  padding-block: .8rem;
  border-bottom: 1px solid var(--rule-fine);
}
.sdl-crumbs a { color: var(--umbra-soft); }
.sdl-crumbs span { padding-inline: .35rem; color: var(--wheat); }

.sdl-dialpage {
  display: grid;
  grid-template-columns: 11rem minmax(0, 1fr);
  gap: 0 2.4rem;
  padding-block: clamp(1.8rem, 4vw, 3rem);
  align-items: start;
}

.sdl-rail {
  position: sticky; top: 1.4rem;
  border-left: 2px solid var(--tone, var(--noon));
  padding-left: .9rem;
  font-family: var(--face-mark);
  font-size: .74rem;
  line-height: 1.7;
  color: var(--umbra-soft);
}
.sdl-rail__mark { display: block; margin-bottom: .85rem; }
.sdl-rail__mark b { display: block; font-weight: 400; color: var(--tone, var(--noon-deep)); letter-spacing: .16em; text-transform: uppercase; font-size: .66rem; }
.sdl-rail__list { list-style: none; margin: 0; padding: 0; }
.sdl-rail__list li { margin-bottom: .4rem; }
.sdl-rail__list a { color: var(--umbra-soft); text-decoration: none; }
.sdl-rail__list a:hover, .sdl-rail__list a:focus-visible { color: var(--noon-deep); text-decoration: underline; }

.sdl-reading { max-width: var(--measure); }
.sdl-reading h1 { font-size: clamp(1.9rem, 1.3rem + 2.4vw, 2.9rem); margin-bottom: .8rem; }
.sdl-reading h2 {
  font-size: clamp(1.32rem, 1.15rem + .7vw, 1.66rem);
  margin: 2.4rem 0 .6rem;
  padding-top: .9rem;
  border-top: 1px solid var(--rule-fine);
}
.sdl-reading h3 { font-size: 1.15rem; margin: 1.7rem 0 .4rem; }
.sdl-reading p { margin: 0 0 1.05rem; }
.sdl-reading ul, .sdl-reading ol { margin: 0 0 1.2rem; padding-left: 1.25rem; }
.sdl-reading li { margin-bottom: .45rem; }

.sdl-reading .sdl-equation h3 { margin: 0 0 .5rem; }
.sdl-reading .sdl-equation { margin: 2rem 0; }

.sdl-lede {
  font-size: 1.13rem;
  color: #33382f;
  border-bottom: 1px solid var(--rule);
  padding-bottom: 1.1rem;
  margin-bottom: 1.4rem !important;
}

.sdl-plate { margin: 1.9rem 0; }
.sdl-plate img { width: 100%; aspect-ratio: 3 / 2; object-fit: cover; border: 1px solid var(--rule); }
.sdl-plate__cap {
  font-family: var(--face-mark);
  font-size: .74rem; color: var(--umbra-soft);
  margin-top: .5rem; padding-left: .8rem;
  border-left: 2px solid var(--wheat);
}

.sdl-pull {
  font-family: var(--face-title);
  font-size: 1.32rem;
  line-height: 1.42;
  color: var(--noon-deep);
  margin: 2rem 0;
  padding: .2rem 0 .2rem 1.2rem;
  border-left: 3px solid var(--wheat);
}

.sdl-nodus {
  display: inline-block;
  font-family: var(--face-mark);
  font-size: .68rem; letter-spacing: .16em; text-transform: uppercase;
  color: var(--umbra-soft);
  border: 1px solid var(--rule);
  padding: .12rem .5rem;
  margin-bottom: .8rem;
}

.sdl-chip {
  display: inline-block;
  font-family: var(--face-mark);
  font-size: .68rem; letter-spacing: .18em; text-transform: uppercase;
  color: var(--stone-lit); background: var(--tone, var(--noon-deep));
  padding: .2rem .6rem; text-decoration: none;
}

.sdl-scroller { overflow-x: auto; margin: 1.6rem 0; border: 1px solid var(--rule); }
.sdl-scroller table { border-collapse: collapse; width: 100%; min-width: 480px; font-size: .93rem; }
.sdl-scroller th, .sdl-scroller td { text-align: left; padding: .6rem .8rem; border-bottom: 1px solid var(--rule-fine); }
.sdl-scroller th { background: var(--stone-lit); font-family: var(--face-mark); font-size: .72rem; letter-spacing: .12em; text-transform: uppercase; }

/* --- renvois croises ----------------------------------------------------- */

.sdl-onward { border-top: 1px solid var(--rule); margin-top: 2.6rem; padding-top: 1.5rem; }
.sdl-onward h2 { font-size: 1.32rem; border: 0; padding-top: 0; margin-top: 0; }
.sdl-onward__item { padding: .85rem 0; border-bottom: 1px solid var(--rule-fine); }
.sdl-onward__item p { margin: .2rem 0 0; font-size: .95rem; color: var(--umbra-soft); }

/* --- socle (pied de page) ------------------------------------------------ */

.sdl-plinth {
  background: var(--umbra);
  color: #d8d9d0;
  padding-block: 2.4rem 1.4rem;
  font-size: .93rem;
}
.sdl-plinth a { color: #cdd6c6; }
.sdl-plinth a:hover, .sdl-plinth a:focus-visible { color: var(--wheat); }
.sdl-plinth__grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
  gap: 1.6rem;
}
.sdl-plinth__col h2 {
  font-family: var(--face-mark);
  font-size: .7rem; letter-spacing: .22em; text-transform: uppercase;
  color: var(--wheat); margin-bottom: .7rem;
}
.sdl-plinth__col ul { list-style: none; margin: 0; padding: 0; }
.sdl-plinth__col li { margin-bottom: .38rem; }
.sdl-plinth__base {
  margin-top: 2rem; padding-top: 1rem;
  border-top: 1px solid #3a4139;
  font-family: var(--face-mark); font-size: .72rem; letter-spacing: .06em;
  color: #9aa094;
  display: flex; flex-wrap: wrap; gap: .5rem 1.4rem; justify-content: space-between;
}

/* --- adaptations ---------------------------------------------------------- */

@media (max-width: 1000px) {
  .sdl-hours { grid-template-columns: repeat(2, 1fr); }
  .sdl-hour--wide { grid-column: span 2; }
  .sdl-dialpage { grid-template-columns: 1fr; gap: 1.4rem; }
  .sdl-rail {
    position: static;
    border-left: 0;
    border-top: 2px solid var(--tone, var(--noon));
    padding-left: 0; padding-top: .8rem;
    display: flex; flex-wrap: wrap; gap: .4rem 1.8rem;
  }
  .sdl-rail__mark { margin-bottom: .3rem; }
  .sdl-rail__list { display: flex; flex-wrap: wrap; gap: .3rem 1.1rem; }
}

@media (max-width: 700px) {
  body { font-size: 16.5px; }
  .sdl-cornice__inner { flex-direction: column; align-items: flex-start; }
  .sdl-bearings { font-size: .88rem; gap: .1rem .85rem; }
  .sdl-hours { grid-template-columns: 1fr; }
  .sdl-hour--wide { grid-column: span 1; }
  .sdl-hour--wide .sdl-hour__plate { aspect-ratio: 16 / 9; }
  .sdl-tick {
    grid-template-columns: 7.2rem 1fr;
    gap: .5rem .9rem;
  }
  .sdl-tick__thumb { grid-column: 1 / -1; grid-row: 2; aspect-ratio: 16 / 9; max-width: 100%; }
  .sdl-tick__body { grid-column: 1 / -1; grid-row: 3; }
  .sdl-tick__when { grid-column: 1 / -1; grid-row: 1; }
  .sdl-tick--noon { padding-inline: .8rem; }
}

@media print {
  .sdl-cornice, .sdl-plinth, .sdl-rail, .sdl-steps { display: none; }
  body { background: #fff; font-size: 12pt; }
}
