/* "Mon planning": the app's week grid (cookai_mobile/src/planning/WeekGrid.js)
   and YouChef motion, shared by the quiz result (quiz.css) and "Mon espace" (espace.css). */
.planner { max-width: 720px; margin: 0 auto; }
.planner-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 14px; }
.planner-title { margin: 0; font: 800 28px/1.15 var(--display); }
.planner-title em { font-size: 31px; }
.planner-week { margin: 0; padding: 10px 18px; border: 1.5px solid var(--rule); border-radius: 22px; background: var(--card); font-weight: 800; font-size: 15px; white-space: nowrap; }
.week-grid { display: grid; gap: 8px; }
.week-row { display: grid; grid-template-columns: 58px 1fr 1fr; gap: 8px; }
.week-col { text-align: center; color: var(--mute); font-size: 12px; font-weight: 800; letter-spacing: .6px; text-transform: uppercase; }
.week-day { display: grid; place-content: center; justify-items: center; border-radius: 16px; background: var(--flour); padding: 8px 0; }
.week-weekday { color: var(--mute); font-size: 11.5px; font-weight: 700; text-transform: uppercase; }
.week-date { font: 800 20px/1.1 var(--display); color: var(--ink); }
.week-day.is-today { background: var(--tomato); }
.week-day.is-today .week-weekday { color: rgba(255,255,255,.8); }
.week-day.is-today .week-date { color: #fff; }
.week-cell { position: relative; display: flex; align-items: flex-end; min-height: 96px; border-radius: 16px; overflow: hidden; }
.week-cell.is-free { border: 1.5px dashed #E2D6C3; }
.week-cell.is-planned { color: #fff; background: var(--flour); transition: transform .25s cubic-bezier(.3,1.6,.5,1), box-shadow .25s; }
.week-cell.is-planned:hover { transform: translateY(-3px) rotate(-.6deg); box-shadow: 0 14px 26px -16px rgba(27,26,23,.55); }
.week-cell.is-planned img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.week-cell.is-planned::after { content: ""; position: absolute; inset: 30% 0 0; background: linear-gradient(rgba(20,14,10,0), rgba(20,14,10,.78)); }
.week-recipe { position: relative; z-index: 1; margin: 0 8px 8px; font-size: 13px; line-height: 1.25; font-weight: 800; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.week-price { position: absolute; top: 7px; right: 7px; z-index: 1; padding: 2px 8px; border-radius: 9px; background: rgba(255,255,255,.94); color: var(--basil); font-size: 12px; font-weight: 800; }
.planner-note { margin: 14px 0 0; color: var(--mute); font-size: 14.5px; text-align: center; }

/* YouChef motion (cookai_mobile/src/ui/motion.js): 350 ms ease-out entrances
   rising 12 px, a spring pop for what lands, one pulse for the total. */
.is-revealing .week-row { animation: yc-appear .35s cubic-bezier(.33,1,.68,1) both; animation-delay: calc(var(--row, 0) * 60ms); }
.is-revealing .week-cell.is-planned { animation: yc-pop .5s cubic-bezier(.3,1.6,.5,1) both; animation-delay: calc(var(--row, 0) * 60ms + 220ms); }
.is-revealing .week-price { animation: yc-appear .25s cubic-bezier(.33,1,.68,1) both; animation-delay: calc(var(--row, 0) * 60ms + 480ms); }
.is-revealing .result-sum { animation: yc-pulse .6s ease-in-out .5s both; }
.is-revealing .planner-head, .is-revealing .result-head > div { animation: yc-appear .35s cubic-bezier(.33,1,.68,1) both; }
@keyframes yc-appear { from { opacity: 0; transform: translateY(12px); } }
@keyframes yc-pop { from { opacity: 0; transform: scale(.82); } }
@keyframes yc-pulse { 50% { transform: scale(1.04); } }

@media (prefers-reduced-motion: reduce) {
  .is-revealing * { animation: none !important; }
  .week-cell.is-planned:hover { transform: none; }
}

@media (max-width: 680px) {
  /* Phone: the app's own proportions (46 px day pill, 6 px gaps, 78 px cells). */
  .planner-title { font-size: 24px; }
  .planner-title em { font-size: 26px; }
  .planner-week { padding: 8px 14px; font-size: 14px; }
  .week-grid { gap: 6px; }
  .week-row { grid-template-columns: 46px 1fr 1fr; gap: 6px; }
  .week-day { border-radius: 14px; padding: 6px 0; }
  .week-weekday { font-size: 10.5px; }
  .week-date { font-size: 17px; }
  .week-cell { min-height: 78px; border-radius: 14px; }
  .week-recipe { margin: 0 6px 6px; font-size: 11px; line-height: 1.2; }
  .week-price { top: 5px; right: 5px; padding: 1px 6px; font-size: 10.5px; }
}
