:root {
  --bg: #f8fafc;
  --fg: #0f172a;
  --muted: #64748b;
  --card: #ffffff;
  --accent: #0d9488;
  --accent-hover: #0f766e;
  --border: #e2e8f0;
  --sand: #fefce8;
}

* { box-sizing: border-box; }
body {
  margin: 0;
  font-family: system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  background: var(--bg);
  color: var(--fg);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}
.main { flex: 1; }

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255,255,255,.92);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--border);
}
.site-header .inner {
  max-width: 72rem;
  margin: 0 auto;
  padding: .75rem 1rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
}
.brand { text-decoration: none; color: inherit; line-height: 1.2; }
.brand-sub { display: block; font-size: .7rem; text-transform: uppercase; letter-spacing: .12em; color: var(--accent); }
.brand-title { font-size: 1.1rem; font-weight: 600; }
.site-header nav { display: flex; flex-wrap: wrap; gap: .5rem; align-items: center; }
.site-header nav a {
  padding: .35rem .65rem;
  border-radius: .5rem;
  text-decoration: none;
  color: var(--muted);
  font-size: .9rem;
}
.site-header nav a:hover { background: #f1f5f9; color: var(--fg); }
.btn-nav {
  background: var(--accent) !important;
  color: #fff !important;
  font-weight: 500;
}
.btn-nav:hover { background: var(--accent-hover) !important; }

.hero {
  position: relative;
  min-height: 22rem;
  display: flex;
  align-items: flex-end;
  padding: 2rem 1rem 4rem;
  background-size: cover;
  background-position: center;
  color: #fff;
}
.hero::after {
  content: "";
  position: absolute; inset: 0;
  background: linear-gradient(to top, rgba(15,23,42,.88), rgba(15,23,42,.35));
}
.hero .inner { position: relative; z-index: 1; max-width: 72rem; margin: 0 auto; width: 100%; }
.hero h1 { font-size: clamp(1.75rem, 4vw, 2.75rem); margin: 0 0 .5rem; max-width: 32rem; }
.hero p { max-width: 28rem; opacity: .95; }
.hero .cta {
    display: inline-block; margin-top: 1.25rem;
    padding: .85rem 1.75rem;
    background: #14b8a6;
    color: #fff; font-weight: 600; text-decoration: none;
    border-radius: 0.375rem;
}
.hero .cta:hover { background: #2dd4bf; color: #0f172a; }

.section { max-width: 72rem; margin: 0 auto; padding: 3rem 1rem; }
.section h2 { text-align: center; font-size: 1.75rem; margin-bottom: .5rem; }
.section .lead { text-align: center; color: var(--muted); max-width: 40rem; margin: 0 auto 2rem; }

.grid-cards {
  display: grid;
  gap: 1.5rem;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
}
.card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 1rem;
  overflow: hidden;
  box-shadow: 0 1px 3px rgba(0,0,0,.06);
}
.card img { width: 100%; height: 12rem; object-fit: cover; display: block; }
.card .body { padding: 1rem 1.25rem; }
.card h3 { margin: 0 0 .5rem; font-size: 1.1rem; }
.card .price { color: var(--accent); font-weight: 600; font-size: .95rem; }

.form-box, .panel {
  max-width: 36rem;
  margin: 0 auto;
  padding: 2rem 1rem;
}
.panel-wide { max-width: 72rem; }
.card-form {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 1rem;
  padding: 1.5rem;
  margin-bottom: 1rem;
}
label { display: block; font-size: .85rem; color: var(--muted); margin-bottom: .25rem; }
input[type=text], input[type=email], input[type=password], input[type=date], input[type=number],
select, textarea {
  width: 100%; max-width: 100%;
  padding: .5rem .75rem;
  border: 1px solid var(--border);
  border-radius: .5rem;
  font-size: 1rem;
}
textarea { min-height: 5rem; }
button, .button {
  cursor: pointer;
  padding: .65rem 1.25rem;
  border: none;
  border-radius: .5rem;
  background: var(--accent);
  color: #fff;
  font-weight: 500;
  font-size: 1rem;
  text-decoration: none;
  display: inline-block;
}
button:hover, .button:hover { background: var(--accent-hover); }
button:disabled { opacity: .5; cursor: not-allowed; }
.err { color: #b91c1c; font-size: .9rem; margin: .5rem 0; }
.ok { color: #15803d; font-size: .9rem; margin: .5rem 0; }
.muted { color: var(--muted); font-size: .9rem; }

.site-footer {
  border-top: 1px solid var(--border);
  background: #fff;
  margin-top: auto;
}
.site-footer .inner {
  max-width: 72rem;
  margin: 0 auto;
  padding: 2rem 1rem;
  display: grid;
  gap: 1.5rem;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
}
.site-footer .copy {
  text-align: center;
  font-size: .75rem;
  color: #94a3b8;
  padding: 1rem;
  border-top: 1px solid #f1f5f9;
}

/* Admin */
.admin-layout { display: flex; flex-wrap: wrap; gap: 0; min-height: 60vh; }
.admin-nav {
  width: 100%;
  max-width: 14rem;
  border-right: 1px solid var(--border);
  background: #fff;
  padding: 1rem;
}
.admin-nav a { display: block; padding: .4rem .5rem; color: var(--fg); text-decoration: none; border-radius: .35rem; font-size: .9rem; }
.admin-nav a:hover { background: #f1f5f9; }
.admin-content { flex: 1; padding: 1.5rem; min-width: 0; }
table.data { width: 100%; border-collapse: collapse; font-size: .875rem; background: #fff; border: 1px solid var(--border); border-radius: .5rem; overflow: hidden; }
table.data th, table.data td { padding: .6rem .75rem; text-align: left; border-bottom: 1px solid var(--border); }
table.data th { background: #f8fafc; color: var(--muted); font-weight: 500; }
.pick-product {
  display: flex; gap: 1rem; border: 2px solid var(--border); border-radius: 1rem; overflow: hidden;
  cursor: pointer; text-align: left; background: #fff;
}
.pick-product.selected { border-color: var(--accent); box-shadow: 0 0 0 3px rgba(13,148,136,.2); }
.pick-product img { width: 8rem; height: 7rem; object-fit: cover; flex-shrink: 0; }
.pick-product .body { padding: .75rem; flex: 1; }

/* Planning mensuel (admin) */
.cal-nav {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1.25rem;
}
.cal-nav h1 { margin: 0; font-size: 1.35rem; }
.cal-nav-links { display: flex; align-items: center; gap: .5rem; }
.cal-nav-links a {
  padding: .4rem .85rem;
  border: 1px solid var(--border);
  border-radius: .5rem;
  text-decoration: none;
  color: var(--fg);
  font-size: .9rem;
  background: #fff;
}
.cal-nav-links a:hover { background: #f1f5f9; }
.cal-scroll { overflow-x: auto; -webkit-overflow-scrolling: touch; }
.cal-table {
  width: 100%;
  min-width: 720px;
  border-collapse: collapse;
  table-layout: fixed;
  background: #fff;
  border: 1px solid var(--border);
  border-radius: .5rem;
  overflow: hidden;
}
.cal-table th {
  padding: .5rem .35rem;
  font-size: .75rem;
  font-weight: 600;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: .04em;
  background: #f8fafc;
  border-bottom: 1px solid var(--border);
}
.cal-table td {
  vertical-align: top;
  border: 1px solid var(--border);
  height: 7.5rem;
  padding: 0;
  width: 14.28%;
  background: #fff;
}
.cal-table td.cal-empty {
  background: #f8fafc;
  height: 7.5rem;
}
.cal-table td.cal-today {
  background: #f0fdfa;
  box-shadow: inset 0 0 0 2px var(--accent);
}
.cal-day-inner {
  min-height: 100%;
  padding: .35rem .4rem .5rem;
  display: flex;
  flex-direction: column;
  gap: .2rem;
}
.cal-day-num {
  font-size: .85rem;
  font-weight: 600;
  color: var(--fg);
  margin-bottom: .15rem;
}
.cal-day-num.muted { color: #94a3b8; font-weight: 500; }
.cal-events { flex: 1; display: flex; flex-direction: column; gap: .2rem; min-height: 0; overflow: hidden; }
.cal-event {
  font-size: .68rem;
  line-height: 1.25;
  padding: .2rem .35rem;
  border-radius: .25rem;
  text-decoration: none;
  color: #0f172a;
  display: block;
  border-left: 3px solid var(--accent);
  background: #f0fdfa;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  max-width: 100%;
}
.cal-event:hover { filter: brightness(0.97); }
.cal-event--pending { border-left-color: #d97706; background: #fffbeb; }
.cal-event--confirmed { border-left-color: #059669; background: #ecfdf5; }
.cal-event--cancelled { border-left-color: #94a3b8; background: #f8fafc; opacity: .85; text-decoration: line-through; }
.cal-legend {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  margin-top: 1rem;
  font-size: .8rem;
  color: var(--muted);
}
.cal-legend span { display: inline-flex; align-items: center; gap: .35rem; }
.cal-dot { width: .65rem; height: .65rem; border-radius: 2px; display: inline-block; }
.cal-dot.pending { background: #d97706; }
.cal-dot.confirmed { background: #059669; }
.cal-dot.cancelled { background: #94a3b8; }
.cal-count { font-size: .85rem; color: var(--muted); margin-top: .25rem; }
