/* Charte commune : les trois familles et leurs seules graisses embarquées. */
:root {
  --ivory: #f5f2e8;
  --sage: #a5b99c;
  --forest: #355a43;
  --green: #24672e;
  --ink: #203627;
  --muted: #506345;
  --line: #d4cfb1;
  --panel: #fffdf5;
  --active: #dce6b9;
  --sand: #d7c9a7;
  --terracotta: #c98562;
  --error: #a52f2f;
  --shadow: 0 2px 5px #263b251a;
  --radius-panel: 14px;
  --radius-control: 9px;
  --font-body: 'Nunito Sans', sans-serif;
  --font-heading: 'Libre Baskerville', serif;
  font-family: var(--font-body);
  font-synthesis: none;
  color: var(--ink);
  background: var(--ivory);
  line-height: 1.55;
}
* { box-sizing: border-box; }
body { margin: 0; }
a { color: var(--forest); }
button, input, select, textarea { font: inherit; }
button, a, input { -webkit-tap-highlight-color: transparent; }
button { cursor: pointer; }
button:focus-visible, a:focus-visible, input:focus-visible,
select:focus-visible, textarea:focus-visible {
  outline: 3px solid #168bd4;
  outline-offset: 3px;
}
h1, h2, h3, .plant-name, .dicton, blockquote {
  font-family: var(--font-heading);
  line-height: 1.3;
}
h1, h2, h3 { font-weight: 700; color: #173b22; }
h1 { font-size: clamp(1.4rem, 2.2vw, 1.75rem); }
h2 { font-size: 1.15rem; }
h3 { font-size: 1rem; }
p { margin: .6rem 0 1rem; }
.skip-link { position: fixed; top: -100px; z-index: 20; background: var(--panel); padding: 1rem; }
.skip-link:focus { top: 0; }
.app-layout { display: grid; grid-template-columns: 210px minmax(0, 1fr); }
.guest-layout { display: block; }
main { width: 100%; max-width: 1240px; margin: 0 auto; padding: 1.6rem 2rem 3rem; min-width: 0; }
.page-heading { margin-bottom: 1.5rem; }
.page-heading h1 { margin: .2rem 0; }
.panel {
  background: linear-gradient(145deg, var(--panel), #faf7eb);
  border: 1px solid var(--line);
  border-radius: var(--radius-panel);
  padding: 1.4rem;
  box-shadow: var(--shadow);
  margin-bottom: 1.5rem;
}
.panel h2 { margin-top: 0; }
.intro-panel { border-top: 8px solid var(--active); }
.status-note { font-size: .95rem; border-left: 3px solid var(--sage); padding-left: .8rem; }
/* Accès provisoires conservés ; ils ne définissent pas le futur tableau de bord. */
.quick-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 1rem; }
.quick-card {
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  text-align: center; gap: .4rem; text-decoration: none; background: var(--panel);
  border: 1px solid var(--line); border-radius: var(--radius-panel); padding: 1rem; box-shadow: var(--shadow);
}
.quick-card:hover { border-color: var(--green); }
.quick-card img { max-width: 100%; object-fit: contain; }
.quick-card span { font-weight: 700; }
.quick-card small { color: var(--muted); }
.login-panel { max-width: 480px; margin: 2rem auto; }
.login-form { display: grid; gap: .7rem; }
.login-form input {
  width: 100%; min-height: 44px; border: 1px solid #8a998e;
  border-radius: var(--radius-control); padding: .7rem; background: #fffef9;
}
.login-form label { font-weight: 700; }
.button {
  display: inline-block; min-height: 44px;
  background: linear-gradient(#355f3e, var(--green)); color: #fff;
  border: 1px solid var(--green); border-radius: var(--radius-control);
  padding: .7rem 1rem; text-decoration: none; text-align: center; font-weight: 700;
  box-shadow: 0 1px 2px #20362712;
}
.button:hover { background: var(--forest); }
.button.secondary { background: transparent; color: var(--forest); }
.button.secondary:hover { background: #e9eedb; }
.form-error { color: var(--error); background: #fff1ed; border: 1px solid #c84c45; padding: .75rem; border-radius: var(--radius-control); }
.error-panel, .empty-state { max-width: 720px; margin: 2rem auto; }
.error-code { font-size: 2rem; color: var(--green); font-weight: 700; }
@media (max-width: 1050px) {
  .quick-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  main { padding: 1.3rem; }
}
@media (max-width: 700px) {
  .app-layout { display: block; }
  main { padding: 1rem 1rem 7rem; }
  .panel { padding: 1rem; border-radius: 12px; }
  .quick-grid { gap: .7rem; }
  .quick-card { padding: .6rem; }
  .quick-card img { width: 120px; height: 105px; }
  .login-panel { margin: 1rem auto; }
}
@media (prefers-reduced-motion: no-preference) {
  .quick-card { transition: border-color .15s ease; }
}
