/* p-ifl-services: cluster "services" for the no-3D industry flow pages (spec homepage/tools/INDUSTRY-75-SPEC.md §2, §4.7).
   Loads after p-indflow. Accent: Sun amber #FFB81C + teal #00B2A9. Holds:
   1. tokens  2. hero "today card" (.svc-today) with a time ribbon and per-page object variants
   3. signature interactive A: punch-card checklist (.svc-punch)   4. signature interactive B: recurring route week (.svc-week)
   5. small "which business are you" chooser (.svc-fit).  Page-only tweaks go under .ifl--<slug> at the end. No 3D, no WebGL. */

/* ---------- 1. tokens ---------- */
body.pg {
  --ifl-accent: #00B2A9;
  --ifl-accent-ink: #00706A;          /* 5.96:1 on white, 5.39:1 on the tint */
  --ifl-accent-on: #fff;
  --ifl-tint: #E6F7F5;
  --ifl-band: linear-gradient(135deg, #061A2E 0%, #0B3A44 52%, #06615A 100%);
  --ifl-band-ink: #5EE0D6;
  --svc-sun: #FFB81C;
  --svc-sun-ink: #7A4F00;             /* 7.1:1 on white */
  --svc-sun-tint: #FFF4D6;
  --svc-teal: #00B2A9;
}

/* ---------- 2. hero "today card" ---------- */
.svc-hero .ifl-hero__art { --ifl-art-ratio: auto; max-width: 500px; }
.svc-today { position: relative; box-sizing: border-box; width: 100%; margin: 0; padding: 18px 18px 16px; border-radius: 22px; background: #fff;
  border: 1px solid var(--ifl-line); box-shadow: 0 40px 70px -48px rgba(8, 34, 56, .6), 0 2px 0 rgba(8, 34, 56, .04); font: 400 14px/1.45 var(--f-body); color: var(--ifl-body); }
.svc-today__head { display: flex; align-items: center; gap: 12px; }
.svc-today__t { margin: 0; font: 700 17px/1.25 var(--f-display); letter-spacing: -.01em; color: var(--ifl-ink); }
.svc-today__s { margin: 2px 0 0; font: 500 12.5px/1.35 var(--f-body); color: var(--ifl-muted); }
.svc-today__head .ifl-sample { margin-left: auto; align-self: flex-start; }
.svc-today__rows { display: grid; gap: 6px; margin: 14px 0 0; padding: 0; list-style: none; }
.svc-today__rows li { display: grid; grid-template-columns: 3.4em minmax(0, 1fr) auto; align-items: center; gap: 10px; min-height: 36px; padding: 6px 10px;
  border-radius: 10px; background: var(--ifl-paper); font-size: 13.5px; line-height: 1.35; }
.svc-today__rows time { font: 700 12.5px/1 var(--f-body); color: var(--ifl-accent-ink); font-variant-numeric: tabular-nums; }
.svc-today__rows b { font-weight: 600; color: var(--ifl-ink); }
.svc-today__rows small { display: block; font-size: 12px; color: var(--ifl-muted); }
/* time ribbon: blocks placed with --s / --e (0..1 of the day shown), optional now marker with --n */
.svc-ribbon { position: relative; margin: 16px 0 0; padding: 0 0 20px; }
.svc-ribbon__track { position: relative; height: 26px; border-radius: 8px; background: repeating-linear-gradient(90deg, #EEF2F6 0 calc(12.5% - 1px), #DDE4EC calc(12.5% - 1px) 12.5%); }
.svc-ribbon__b { position: absolute; top: 3px; bottom: 3px; left: calc(var(--s) * 100%); width: calc((var(--e) - var(--s)) * 100%); box-sizing: border-box;
  padding: 0 6px; border-radius: 6px; background: var(--ifl-accent-ink); color: #fff; font: 700 11px/20px var(--f-body); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.svc-ribbon__b--sun { background: var(--svc-sun); color: #3D2800; }
.svc-ribbon__b--gap { background: #fff; color: #9A2E12; border: 1.5px dashed #D9583A; line-height: 17px; }
.svc-ribbon__now { position: absolute; top: -4px; bottom: 16px; left: calc(var(--n) * 100%); width: 2px; background: #D9583A; border-radius: 2px; }
.svc-ribbon__now::after { content: ""; position: absolute; top: -4px; left: -3px; width: 8px; height: 8px; border-radius: 50%; background: #D9583A; }
.svc-ribbon__ticks { position: absolute; left: 0; right: 0; bottom: 0; display: flex; justify-content: space-between; margin: 0; padding: 0; list-style: none;
  font: 600 10.5px/1 var(--f-body); color: var(--ifl-muted); font-variant-numeric: tabular-nums; }
.svc-today__foot { display: flex; flex-wrap: wrap; gap: 6px; margin: 12px 0 0; }

/* variant: post order binder with a site badge (security services hub) */
.svc-today--binder { padding-left: 46px; background: linear-gradient(90deg, #F3F7F9 0 30px, #fff 30px); }
.svc-today--binder::before { content: ""; position: absolute; left: 30px; top: 0; bottom: 0; width: 1px; background: var(--ifl-line); }
.svc-binder__rings { position: absolute; left: 9px; top: 34px; bottom: 34px; display: flex; flex-direction: column; justify-content: space-between; margin: 0; padding: 0; list-style: none; }
.svc-binder__rings i { display: block; width: 14px; height: 14px; border-radius: 50%; background: radial-gradient(circle at 40% 35%, #fff 0 2px, #B8C4D0 3px, #7C8B9A 7px); box-shadow: inset 0 -1px 2px rgba(0, 0, 0, .2); }
.svc-binder__tabs { position: absolute; right: -24px; top: 84px; display: grid; gap: 6px; margin: 0; padding: 0; list-style: none; }
.svc-binder__tabs li { writing-mode: vertical-rl; padding: 10px 6px 10px 5px; border-radius: 0 8px 8px 0; font: 700 10.5px/1 var(--f-body); letter-spacing: .04em; text-transform: uppercase; color: #fff; background: var(--ifl-accent-ink); }
.svc-binder__tabs li:nth-child(2) { background: var(--svc-sun); color: #3D2800; }
.svc-binder__tabs li:nth-child(3) { background: #1D3F8F; }
.svc-badge { position: relative; flex: none; display: grid; place-items: center; width: 54px; height: 60px; }
.svc-badge svg { display: block; width: 54px; height: 60px; }
.svc-badge b { position: absolute; top: 19px; left: 0; right: 0; text-align: center; font: 800 15px/1 var(--f-display); color: #3D2800; }
.svc-badge small { position: absolute; top: 36px; left: 0; right: 0; text-align: center; font: 700 7.5px/1 var(--f-body); letter-spacing: .08em; text-transform: uppercase; color: #3D2800; }
@media (max-width: 560px) {
  .svc-binder__tabs { display: none; }
  .svc-today { padding: 16px 14px 14px; }
  .svc-today--binder { padding-left: 40px; background: linear-gradient(90deg, #F3F7F9 0 26px, #fff 26px); }
  .svc-today--binder::before { left: 26px; }
  .svc-binder__rings { left: 6px; }
  .svc-today__rows li { grid-template-columns: 3em minmax(0, 1fr); }
  .svc-today__rows li > .ifl-tag { grid-column: 2; justify-self: start; }
}

/* ---------- 3. signature A: punch-card checklist (phone frame) ----------
   <div class="svc-punch" data-svc-punch data-svc-done-say="..." >
     <div class="svc-punch__phone"> bar, <ol class="svc-punch__holes">(JS fills)</ol>, <ul class="svc-punch__list"> rows </ul> </div>
     <div class="svc-punch__side"> <p class="svc-punch__sum" aria-live="polite"></p> <ul class="svc-punch__tickets"></ul> </div>
   Row: <li class="svc-punch__row" data-state="ok|issue|" data-ticket="Ticket text" data-photo> <span class="svc-punch__q">..</span>
          <span class="svc-punch__acts"><button data-svc-set="ok">OK</button><button data-svc-set="issue">Issue</button></span> </li>
   No JS: rows show their written state, tickets written in HTML stay. */
.svc-punch { margin-top: clamp(24px, 3vw, 36px); display: grid; grid-template-columns: minmax(0, 380px) minmax(0, 1fr); gap: clamp(24px, 4vw, 48px); align-items: start; }
.svc-punch__phone { box-sizing: border-box; width: 100%; max-width: 380px; justify-self: center; padding: 14px 12px 18px; border-radius: 34px; background: #0B1B2B;
  box-shadow: 0 40px 70px -46px rgba(8, 34, 56, .7); }
.svc-punch__screen { overflow: hidden; border-radius: 24px; background: #fff; }
.svc-punch__screen .ifl-scr__bar { border-radius: 0; }
.svc-punch__notch { display: block; width: 84px; height: 6px; margin: 0 auto 10px; border-radius: 6px; background: #22364A; }
.svc-punch__card { margin: 12px 12px 0; padding: 10px 12px; border-radius: 12px; background: var(--svc-sun-tint); border: 1px solid #F3D891; }
.svc-punch__card p { margin: 0; font: 700 13.5px/1.3 var(--f-display); color: #3D2800; }
.svc-punch__card small { display: block; font: 500 12px/1.35 var(--f-body); color: var(--svc-sun-ink); }
.svc-punch__holes { display: flex; flex-wrap: wrap; gap: 6px; margin: 10px 0 0; padding: 0; list-style: none; }
.svc-punch__holes li { width: 16px; height: 16px; border-radius: 50%; background: #fff; border: 1.5px dashed #C9A54A; box-sizing: border-box; }
.svc-punch__holes li.is-ok { background: radial-gradient(circle, #fff 0 3px, var(--ifl-accent-ink) 3.5px); border: 0; }
.svc-punch__holes li.is-issue { background: #D9583A; border: 0; }
.svc-punch__list { display: grid; gap: 0; margin: 8px 0 0; padding: 0 12px 12px; list-style: none; }
.svc-punch__row { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: 4px 10px; padding: 10px 0; border-bottom: 1px solid var(--ifl-line); }
.svc-punch__row:last-child { border-bottom: 0; }
.svc-punch__q { font: 500 14px/1.4 var(--f-body); color: var(--ifl-ink); }
.svc-punch__q small { display: block; font-size: 12px; color: var(--ifl-muted); }
.svc-punch__acts { display: flex; gap: 6px; }
.svc-punch__acts button { min-width: 52px; min-height: 36px; padding: 0 10px; border-radius: 10px; border: 1.5px solid #CBD5E1; background: #fff; color: #334155; font: 700 12.5px/1 var(--f-body); cursor: pointer; transition: background .15s, border-color .15s, color .15s; }
.svc-punch__acts button:hover { border-color: var(--ifl-accent-ink); }
.svc-punch__acts button:focus-visible { outline: 3px solid var(--ifl-accent-ink); outline-offset: 2px; }
.svc-punch__row[data-state="ok"] [data-svc-set="ok"] { background: var(--ifl-accent-ink); border-color: var(--ifl-accent-ink); color: #fff; }
.svc-punch__row[data-state="issue"] [data-svc-set="issue"] { background: #9A2E12; border-color: #9A2E12; color: #fff; }
.svc-punch__row[data-state="issue"] .svc-punch__q { color: #9A2E12; }
.svc-punch__photo { grid-column: 1 / -1; display: none; align-items: center; gap: 8px; font: 600 12px/1.3 var(--f-body); color: var(--ifl-muted); }
.svc-punch__photo i { display: block; width: 46px; height: 34px; border-radius: 6px; border: 1.5px dashed #94A3B8; background: repeating-linear-gradient(135deg, #F1F5F9 0 6px, #E2E8F0 6px 12px); }
.svc-punch__row[data-photo][data-state] .svc-punch__photo { display: flex; }
.svc-punch__row[data-photo][data-state=""] .svc-punch__photo { display: none; }
.svc-punch__row[data-state="issue"] .svc-punch__photo i { border-color: #D9583A; }
.svc-punch__side { display: grid; gap: 14px; }
.svc-punch__sum { margin: 0; font: 700 18px/1.35 var(--f-display); color: var(--ifl-ink); }
.svc-punch__help { margin: 0; font-size: 15px; line-height: 1.6; color: var(--ifl-body); }
.svc-punch__tickets { display: grid; gap: 10px; margin: 0; padding: 0; list-style: none; min-height: 60px; }
.svc-punch__ticket { display: grid; grid-template-columns: 20px minmax(0, 1fr); gap: 4px 10px; padding: 12px 14px; border-radius: 14px; background: #fff; border: 1px solid #F3C3B6; border-left: 4px solid #D9583A; box-shadow: var(--ifl-shadow); }
.svc-punch__ticket img { width: 20px; height: 20px; }
.svc-punch__ticket b { font: 700 14.5px/1.35 var(--f-body); color: var(--ifl-ink); }
.svc-punch__ticket span { grid-column: 2; font-size: 13.5px; line-height: 1.45; color: var(--ifl-muted); }
.svc-punch__empty { padding: 12px 14px; border-radius: 14px; border: 1.5px dashed #CBD5E1; font-size: 14px; color: var(--ifl-muted); }
.svc-punch__reset { justify-self: start; min-height: 44px; padding: 0 16px; border-radius: 12px; border: 1.5px solid var(--ifl-accent-ink); background: #fff; color: var(--ifl-accent-ink); font: 600 14px/1 var(--f-body); cursor: pointer; }
.svc-punch__reset:focus-visible { outline: 3px solid var(--ifl-accent-ink); outline-offset: 2px; }
.svc-punch__reset[hidden] { display: none; }
.ifl-js .svc-punch__ticket.is-new { animation: svc-drop .45s cubic-bezier(.2, .8, .2, 1); }
@keyframes svc-drop { from { opacity: 0; transform: translateY(-10px); } to { opacity: 1; transform: none; } }
@media (max-width: 899px) { .svc-punch { grid-template-columns: minmax(0, 1fr); } }
@media (max-width: 400px) { .svc-punch__phone { padding: 10px 8px 14px; border-radius: 28px; } .svc-punch__acts button { min-width: 46px; padding: 0 8px; } }

/* ---------- 4. signature B: recurring route week ----------
   <div class="svc-week" data-svc-week data-days="Mon|Tue|Wed|Thu|Fri">
     <table class="svc-week__grid"> rows = crews / guards / routes, cells hold .svc-week__v visits (data-cost per cell on <td>) </table>
     <div class="svc-week__ctl"> <button data-svc-add>Add a sample customer</button> <button data-svc-skip>Skip a visit</button> </div>
     <p class="svc-week__say" aria-live="polite"></p> <ul class="svc-week__follow"></ul>
   Each <td data-cost="12"> = added minutes (or load) for a new visit on that crew/day. Add puts the next queued customer
   (<template data-svc-queue> <li data-name=".." data-note="..">) into the cheapest free cell. Skip moves the last visit to follow-ups. */
.svc-week { display: grid; gap: 14px; margin-top: clamp(24px, 3vw, 36px); }
.svc-week__wrap { overflow-x: auto; border-radius: 18px; border: 1px solid var(--ifl-line); background: #fff; box-shadow: var(--ifl-shadow); }
.svc-week__grid { width: 100%; min-width: 520px; border-collapse: collapse; font: 400 13px/1.35 var(--f-body); table-layout: fixed; }
.svc-week__grid th, .svc-week__grid td { padding: 8px; border-bottom: 1px solid var(--ifl-line); border-left: 1px solid var(--ifl-line); vertical-align: top; text-align: left; }
.svc-week__grid thead th { background: var(--ifl-paper); font: 700 12.5px/1.2 var(--f-body); color: var(--ifl-ink); }
.svc-week__grid tbody th { width: 8.5em; font: 600 13px/1.3 var(--f-body); color: var(--ifl-ink); background: #FBFCFD; }
.svc-week__grid tbody th small { display: block; font-weight: 500; font-size: 11.5px; color: var(--ifl-muted); }
.svc-week__grid tr:last-child > * { border-bottom: 0; }
.svc-week__grid td { position: relative; height: 54px; }
.svc-week__cost { display: block; font: 600 11px/1.2 var(--f-body); color: var(--ifl-muted); }
.svc-week__v { display: block; margin-top: 4px; padding: 4px 6px; border-radius: 6px; background: var(--ifl-tint); color: var(--ifl-accent-ink); font: 700 11.5px/1.25 var(--f-body); }
.svc-week__v--new { background: var(--svc-sun); color: #3D2800; }
.ifl-js .svc-week__v--new { animation: svc-drop .45s cubic-bezier(.2, .8, .2, 1); }
.svc-week__grid td.is-best { box-shadow: inset 0 0 0 2px var(--svc-sun); }
.svc-week__ctl { display: flex; flex-wrap: wrap; gap: 10px; }
.svc-week__ctl button { min-height: 44px; padding: 0 16px; border-radius: 12px; border: 1.5px solid var(--ifl-accent-ink); background: #fff; color: var(--ifl-accent-ink); font: 600 14px/1 var(--f-body); cursor: pointer; }
.svc-week__ctl button:first-child { background: var(--ifl-accent-ink); color: #fff; }
.svc-week__ctl button:disabled { opacity: 1; border-color: #CBD5E1; color: #64748B; background: #F1F5F9; cursor: default; }
.svc-week__ctl button:focus-visible { outline: 3px solid var(--ifl-accent-ink); outline-offset: 2px; }
.svc-week__say { margin: 0; min-height: 1.5em; font: 600 15px/1.5 var(--f-body); color: var(--ifl-ink); }
.svc-week__follow { display: grid; gap: 8px; margin: 0; padding: 0; list-style: none; }
.svc-week__follow li { padding: 10px 12px; border-radius: 12px; background: #fff; border: 1px solid #F3C3B6; border-left: 4px solid #D9583A; font-size: 14px; line-height: 1.45; }
.svc-week__follow li b { color: var(--ifl-ink); }
.svc-week__hint { margin: 0; font-size: 13.5px; color: var(--ifl-muted); }

/* ---------- 5. "which business are you" chooser ---------- */
.svc-fit { display: grid; grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); gap: 12px; margin: 0; padding: 0; list-style: none; }
.svc-fit > li { display: grid; align-content: start; gap: 8px; padding: 18px 18px 16px; border-radius: 18px; background: #fff; border: 1px solid var(--ifl-line); border-top: 4px solid var(--c, var(--ifl-accent-ink)); }
.svc-fit h3 { margin: 0; font: 700 18px/1.3 var(--f-display); color: var(--ifl-ink); }
.svc-fit p { margin: 0; font-size: 15px; line-height: 1.55; }
.svc-fit .ifl-chips { margin-top: 2px; }
.svc-fit a.svc-fit__go { margin-top: 4px; font: 600 14.5px/1.4 var(--f-body); color: var(--ifl-accent-ink); }

@media (prefers-reduced-motion: reduce) {
  .ifl-js .svc-punch__ticket.is-new, .ifl-js .svc-week__v--new { animation: none !important; }
  .svc-punch__acts button { transition: none; }
}

/* ---------- page-scoped tweaks ---------- */
/* .ifl--security-services: hub page; nothing beyond the shared parts yet */

/* ---------- 6. laptop fit: sample cards stay <= 340px tall (INDUSTRY-75-SPEC §1.2) ---------- */
@media (min-width: 1100px) {
  .ifl-step .ifl-scr__bar { min-height: 40px; padding: 7px 14px; }
  .ifl-step .ifl-scr__body { padding: 12px 14px; }
  .ifl-step .ifl-scr__foot { padding: 0 14px 8px; }
  .ifl-step .ifl-chk { gap: 4px; }
  .ifl-step .ifl-chk li { padding: 6px 10px; }
  .ifl-step .ifl-thread { gap: 6px; }
  .ifl-step .ifl-msg { padding: 6px 10px; line-height: 1.4; }
  .ifl-step .ifl-map { height: 150px; }
  .ifl-step .ifl-map__stops { gap: 2px; margin-top: 8px; }
  .ifl-step .ifl-doc { padding: 12px 14px; }
  .ifl-step .ifl-doc__lines { gap: 4px; margin: 6px 0 8px; }
  .ifl-step .ifl-doc__lines i:nth-child(n+3) { display: none; }
  .ifl-step .ifl-form { gap: 7px; }
  .ifl-step .ifl-form__in { min-height: 32px; padding: 6px 10px; }
  .ifl-step .ifl-inv td { padding: 6px 0; }
  .ifl-step .ifl-board__c { padding: 7px 8px; }
}
