/* =========================================================================
   ZEN Z — the operating-model diagram (franchise page only).

   One hand-drawn inline SVG (viewBox 0 0 1000 420): the cloud kitchen on the
   left, the seven concept trolleys in the middle, and the three ways a
   customer meets the food on the right — web app, Android app, rider. The
   flow it draws is the real one; the geometry is untouched from the earlier
   site. Colours now come from zenz.css tokens and the type is Inter.

   Animation starts when zenz.js adds `.in` to `.z-flow`, runs only under
   `html.zjs`, and is switched off entirely under prefers-reduced-motion.
   ========================================================================= */

.z-flow { max-width: 1080px; margin-inline: auto; }
.z-flow-svg { width: 100%; height: auto; display: block; overflow: visible; }

.zf-t { fill: var(--ink); font-family: var(--font); font-weight: 700; font-size: 21px; letter-spacing: -0.02em; }
.zf-s { fill: var(--muted); font-family: var(--font); font-weight: 500; font-size: 14px; }
.zf-s--c { fill: var(--ink); font-size: 13px; }
.zf-trolley .zf-s { paint-order: stroke; stroke: var(--tint); stroke-width: 5; stroke-linejoin: round; }
.zf-kitchen, .zf-trolleys, .zf-customers { isolation: isolate; }
@media (max-width: 640px) {
  .zf-s { display: none; }
  .zf-t { font-size: 30px; }
}

.zf-kit-body { fill: var(--ink); }
.zf-kit-roof { fill: var(--gold); }
.zf-kit-win { fill: var(--tint); }
.zf-kit-door { fill: var(--gold); }
.zf-kit-glow { fill: var(--gold); opacity: 0.1; }
.zf-steam { fill: none; stroke: var(--gold); stroke-width: 3; stroke-linecap: round; opacity: 0.5; transform-box: fill-box; transform-origin: 50% 100%; }
.zjs .z-flow.in .zf-steam { animation: zfSteam 2.8s ease-in-out infinite; }
.zjs .z-flow.in .zf-steam:nth-child(2) { animation-delay: 0.7s; }
.zjs .z-flow.in .zf-steam:nth-child(3) { animation-delay: 1.4s; }
@keyframes zfSteam {
  0% { opacity: 0; transform: translateY(6px) scale(0.9); }
  35% { opacity: 0.6; }
  100% { opacity: 0; transform: translateY(-16px) scale(1.15); }
}

.zf-trolley { transform-box: fill-box; transform-origin: 50% 100%; }
.zf-c1 { color: var(--c-health); }
.zf-c2 { color: var(--c-breakfast); }
.zf-c3 { color: var(--c-food); }
.zf-c4 { color: var(--c-tea); }
.zf-c5 { color: var(--c-icecream); }
.zf-c6 { color: var(--c-dairy); }
.zf-c7 { color: var(--c-nonveg); }
.zf-canopy, .zf-body { fill: currentColor; }
.zf-counter, .zf-pole { fill: var(--ink); }
.zf-stripe { fill: #fff; opacity: 0.85; }
.zf-wheel { transform-box: fill-box; transform-origin: center; }
.zf-wheel circle { fill: var(--ink); stroke: var(--gold); stroke-width: 2; }
.zf-wheel path { stroke: var(--gold); stroke-width: 1.6; stroke-linecap: round; fill: none; }
.zjs .z-flow.in .zf-wheel { animation: zfSpin 7s linear infinite; }
@keyframes zfSpin { to { transform: rotate(360deg); } }

.zjs .z-flow .zf-trolley { opacity: 0; transform: translateY(10px) scale(0.9); }
.zjs .z-flow.in .zf-trolley { animation: zfPop 0.6s var(--e) both; }
.zjs .z-flow.in .zf-row:nth-child(1) .zf-trolley { animation-delay: 0.45s; }
.zjs .z-flow.in .zf-row:nth-child(2) .zf-trolley { animation-delay: 0.54s; }
.zjs .z-flow.in .zf-row:nth-child(3) .zf-trolley { animation-delay: 0.63s; }
.zjs .z-flow.in .zf-row:nth-child(4) .zf-trolley { animation-delay: 0.72s; }
.zjs .z-flow.in .zf-row:nth-child(5) .zf-trolley { animation-delay: 0.81s; }
.zjs .z-flow.in .zf-row:nth-child(6) .zf-trolley { animation-delay: 0.90s; }
.zjs .z-flow.in .zf-row:nth-child(7) .zf-trolley { animation-delay: 0.99s; }
@keyframes zfPop {
  0% { opacity: 0; transform: translateY(10px) scale(0.9); }
  100% { opacity: 1; transform: none; }
}

.zf-lines { pointer-events: none; }
.zf-line { fill: none; stroke: var(--gold); stroke-width: 2; stroke-linecap: round; opacity: 0.55; }
.zf-dots { fill: none; stroke: var(--ink); stroke-width: 5; stroke-linecap: round; stroke-dasharray: 0 18; }
.zjs .z-flow .zf-line { stroke-dasharray: 720; stroke-dashoffset: 720; }
.zjs .z-flow.in .zf-line { animation: zfDraw 1.1s var(--e) forwards; }
.zjs .z-flow.in .zf-lines--out .zf-line { animation-delay: 0.9s; }
@keyframes zfDraw { to { stroke-dashoffset: 0; } }
.zjs .z-flow .zf-dots { opacity: 0; }
.zjs .z-flow.in .zf-dots { opacity: 1; transition: opacity 0.5s 1.2s; animation: zfFlow 1.4s linear infinite; }
@keyframes zfFlow { to { stroke-dashoffset: -18; } }

.zf-screen { fill: #fff; stroke: var(--ink); stroke-width: 3; }
.zf-screen-bar { fill: var(--gold); }
.zf-screen-line { fill: var(--line); }
.zf-screen-btn { fill: var(--ink); }
.zf-android { fill: var(--c-health); }
.zf-android-eye { fill: #fff; }
.zf-house { fill: var(--ink); }
.zf-house-roof, .zf-house-door { fill: var(--gold); }

.zf-ride { fill: none; stroke: var(--ink); stroke-width: 2; stroke-dasharray: 7 9; stroke-linecap: round; opacity: 0.45; }
.zjs .z-flow.in .zf-ride { animation: zfDash 1.2s linear infinite; }
@keyframes zfDash { to { stroke-dashoffset: -16; } }
.zf-rider-wheel { fill: var(--ink); stroke: var(--gold); stroke-width: 2; }
.zf-rider-frame { fill: none; stroke: var(--ink); stroke-width: 3.5; stroke-linecap: round; stroke-linejoin: round; }
.zf-rider-box, .zf-rider-head { fill: var(--gold); }
.zf-rider-body { fill: none; stroke: var(--ink); stroke-width: 3.2; stroke-linecap: round; }
.zf-rider { offset-path: path("M0 0 C 70 -34, 150 34, 262 0"); offset-rotate: 0deg; offset-distance: 0%; }
.zjs .z-flow.in .zf-rider { animation: zfRide 6.5s cubic-bezier(0.45, 0.05, 0.55, 0.95) 1.4s infinite; }
@keyframes zfRide {
  0% { offset-distance: 0%; opacity: 0; }
  6% { opacity: 1; }
  86% { offset-distance: 100%; opacity: 1; }
  92% { offset-distance: 100%; opacity: 0; }
  100% { offset-distance: 0%; opacity: 0; }
}

/* numbered captions under the drawing — the phone reader's version of it */
.z-flow-steps { list-style: none; margin-top: 40px; display: grid; gap: 12px; grid-template-columns: minmax(0, 1fr); counter-reset: zf; }
@media (min-width: 640px) { .z-flow-steps { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (min-width: 1024px) { .z-flow-steps { grid-template-columns: repeat(5, minmax(0, 1fr)); } }
.z-flow-steps li {
  position: relative; background: var(--paper); border-radius: var(--r2);
  padding: 18px 18px 18px 58px; font-size: 14px; line-height: 1.45; color: var(--muted);
}
.z-flow-steps li b { display: block; color: var(--ink); font-size: 15px; font-weight: 600; margin-bottom: 3px; }
.z-flow-steps li::before {
  counter-increment: zf; content: counter(zf);
  position: absolute; left: 18px; top: 18px; width: 26px; height: 26px; border-radius: 50%;
  background: var(--ink); color: #fff; font-size: 13px; font-weight: 600; display: grid; place-items: center;
}

@media (prefers-reduced-motion: reduce) {
  .zjs .z-flow .zf-trolley, .zjs .z-flow.in .zf-trolley { opacity: 1; transform: none; animation: none; }
  .zjs .z-flow .zf-line, .zjs .z-flow.in .zf-line { stroke-dasharray: none; stroke-dashoffset: 0; animation: none; }
  .zjs .z-flow .zf-dots, .zjs .z-flow.in .zf-dots { opacity: 1; animation: none; transition: none; }
  .zjs .z-flow.in .zf-wheel, .zjs .z-flow.in .zf-steam, .zjs .z-flow.in .zf-ride { animation: none; }
  .zjs .z-flow.in .zf-rider { animation: none; offset-distance: 100%; }
}
