/* Slide 4 · How it works. Three columns revealed one click at a time (.b0 … .b2 on the slide).
   Every rule is scoped under [data-slide="tech"]. */

[data-slide="tech"] {
  --success: #17763F;
  --rise: .7s cubic-bezier(.16, 1, .3, 1);
}

[data-slide="tech"] .tech-head {
  position: absolute;
  left: 100px;
  right: 100px;
  top: 92px;
}

[data-slide="tech"] .tech-title {
  margin-top: 14px;
  font-size: 58px;
  font-weight: 800;
  line-height: 1.05;
  letter-spacing: -0.035em;
  color: var(--label);
}

/* ── Columns ── */

[data-slide="tech"] .tech-cols {
  position: absolute;
  left: 100px;
  top: 290px;
  width: 1720px;
  height: 520px;
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 124px;
}

[data-slide="tech"] .tech-col {
  position: relative;
  padding: 34px 34px 30px;
  border-radius: 28px;
  background: var(--card);
  box-shadow: 0 1px 2px rgba(20, 28, 32, .05), 0 18px 40px -24px rgba(20, 40, 50, .3);
}

[data-slide="tech"] .tech-col.is-device {
  box-shadow: 0 0 0 3px var(--tint), 0 24px 50px -24px rgba(51, 118, 145, .55);
}

[data-slide="tech"] .col-kicker {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 20px;
  font-weight: 700;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--tint-text);
}

[data-slide="tech"] .col-num {
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: var(--tint);
  color: #fff;
  font-size: 17px;
  letter-spacing: 0;
}

[data-slide="tech"] .tech-list {
  list-style: none;
  margin-top: 28px;
  display: grid;
  gap: 26px;
}

[data-slide="tech"] .tech-list li {
  display: grid;
  grid-template-columns: 48px 1fr auto;
  align-items: start;
  gap: 16px;
}

[data-slide="tech"] .tech-list b {
  display: block;
  font-size: 25px;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--label);
}

[data-slide="tech"] .tech-list span {
  display: block;
  margin-top: 3px;
  font-size: 18px;
  line-height: 1.35;
  color: var(--secondary);
}

/* Which demo scene this piece powers. */
[data-slide="tech"] .scene {
  margin-top: 4px;
  padding: 4px 11px;
  border-radius: 999px;
  background: var(--tint-fill);
  color: var(--tint-text);
  font-size: 14px;
  font-style: normal;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

[data-slide="tech"] .device-badge {
  position: absolute;
  left: 34px;
  right: 34px;
  bottom: 30px;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 18px;
  border-radius: 999px;
  background: color-mix(in srgb, var(--success) 10%, transparent);
  color: var(--success);
  font-size: 19px;
  font-weight: 700;
}

[data-slide="tech"] .device-badge .ti { width: 24px; height: 24px; background: currentColor; }

/* ── Icons (line icons as masks, one tint) ── */

[data-slide="tech"] .ti {
  width: 48px;
  height: 48px;
  border-radius: 14px;
  background: var(--tint-fill);
  position: relative;
}

[data-slide="tech"] .tech-list .ti::after {
  content: "";
  position: absolute;
  inset: 11px;
  background: var(--tint);
  mask: center / contain no-repeat var(--icon);
}

[data-slide="tech"] .device-badge .ti { mask: center / contain no-repeat var(--icon); border-radius: 0; }

[data-slide="tech"] .ti-beacon { --icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round'%3E%3Ccircle cx='12' cy='12' r='2.5'/%3E%3Cpath d='M7.8 7.8a6 6 0 0 0 0 8.4M16.2 7.8a6 6 0 0 1 0 8.4M4.9 4.9a10 10 0 0 0 0 14.2M19.1 4.9a10 10 0 0 1 0 14.2'/%3E%3C/svg%3E"); }
[data-slide="tech"] .ti-plan { --icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linejoin='round'%3E%3Cpath d='M12 3 3 7.5l9 4.5 9-4.5z'/%3E%3Cpath d='m3 12 9 4.5 9-4.5M3 16.5 12 21l9-4.5'/%3E%3C/svg%3E"); }
[data-slide="tech"] .ti-food { --icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round'%3E%3Cpath d='M7 3v8M4 3v5a3 3 0 0 0 6 0V3M7 11v10M17 21V3c-2 1-3 4-3 8h3'/%3E%3C/svg%3E"); }
[data-slide="tech"] .ti-cal { --icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round'%3E%3Crect x='3' y='5' width='18' height='16' rx='3'/%3E%3Cpath d='M3 10h18M8 3v4M16 3v4'/%3E%3C/svg%3E"); }
[data-slide="tech"] .ti-dot { --icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2'%3E%3Ccircle cx='12' cy='12' r='4' fill='black'/%3E%3Ccircle cx='12' cy='12' r='9'/%3E%3C/svg%3E"); }
[data-slide="tech"] .ti-route { --icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='6' cy='19' r='2.5'/%3E%3Ccircle cx='18' cy='5' r='2.5'/%3E%3Cpath d='M8.5 19H15a3.5 3.5 0 0 0 0-7H9a3.5 3.5 0 0 1 0-7h6.5'/%3E%3C/svg%3E"); }
[data-slide="tech"] .ti-code { --icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m8 7-5 5 5 5M16 7l5 5-5 5M14 4l-4 16'/%3E%3C/svg%3E"); }
[data-slide="tech"] .ti-db { --icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2'%3E%3Cellipse cx='12' cy='5.5' rx='8' ry='3'/%3E%3Cpath d='M4 5.5v13c0 1.7 3.6 3 8 3s8-1.3 8-3v-13M4 12c0 1.7 3.6 3 8 3s8-1.3 8-3'/%3E%3C/svg%3E"); }
[data-slide="tech"] .ti-swipe { --icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linejoin='round'%3E%3Crect x='7' y='3' width='11' height='15' rx='2.5' transform='rotate(12 12 10)'/%3E%3Cpath d='M5 7.5 3.5 18a2 2 0 0 0 1.7 2.3l7 1'/%3E%3C/svg%3E"); }
[data-slide="tech"] .ti-live { --icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round'%3E%3Ccircle cx='9' cy='8' r='3.5'/%3E%3Cpath d='M2.5 20a6.5 6.5 0 0 1 13 0'/%3E%3Ccircle cx='18.5' cy='9.5' r='2.5' fill='black'/%3E%3C/svg%3E"); }
[data-slide="tech"] .ti-lock { --icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2.2' stroke-linecap='round'%3E%3Crect x='4.5' y='10.5' width='15' height='10.5' rx='2.5'/%3E%3Cpath d='M8 10.5V7a4 4 0 0 1 8 0v3.5'/%3E%3C/svg%3E"); }

/* ── Arrows between columns ── */

[data-slide="tech"] .tech-flow {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  overflow: visible;
  pointer-events: none;
}

[data-slide="tech"] .tech-flow path {
  fill: none;
  stroke: var(--tint);
  stroke-width: 4;
  stroke-linecap: round;
  stroke-dasharray: 4 12;
}

[data-slide="tech"] .tech-flow .head { stroke-dasharray: none; stroke-linejoin: round; }

/* ── Stats strip ── */

[data-slide="tech"] .tech-stats {
  position: absolute;
  left: 100px;
  right: 100px;
  top: 858px;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 124px;
}

[data-slide="tech"] .tech-stats div {
  display: grid;
  gap: 6px;
  padding-top: 26px;
  border-top: 2px solid var(--separator);
}

[data-slide="tech"] .tech-stats b {
  font-size: 50px;
  line-height: 1;
  font-weight: 800;
  letter-spacing: -0.04em;
  color: var(--tint);
  white-space: nowrap;
}

[data-slide="tech"] .tech-stats span {
  font-size: 18px;
  line-height: 1.35;
  color: var(--secondary);
}

/* ── Beats: each [data-beat="n"] rises in when the slide reaches .bn ── */

[data-slide="tech"] .tech-head {
  opacity: 0;
  translate: 0 -14px;
  transition: opacity .6s var(--ease-out), translate var(--rise);
}

[data-slide="tech"].b0 .tech-head { opacity: 1; translate: none; }

[data-slide="tech"] [data-beat] {
  opacity: 0;
  translate: 0 36px;
  transition: opacity .55s var(--ease-out), translate var(--rise);
}

/* List items follow their column in a short cascade. */
[data-slide="tech"] .tech-col .tech-list li,
[data-slide="tech"] .device-badge {
  opacity: 0;
  translate: 0 14px;
  transition: opacity .45s var(--ease-out), translate .6s var(--ease-out);
}

[data-slide="tech"] .tech-flow g[data-beat] { translate: -24px 0; }

[data-slide="tech"].b0 [data-beat="0"],
[data-slide="tech"].b1 [data-beat="1"],
[data-slide="tech"].b2 [data-beat="2"] {
  opacity: 1;
  translate: none;
  transition-delay: .1s;
}

[data-slide="tech"].b0 [data-beat="0"] li,
[data-slide="tech"].b1 [data-beat="1"] li,
[data-slide="tech"].b1 [data-beat="1"] .device-badge,
[data-slide="tech"].b2 [data-beat="2"] li {
  opacity: 1;
  translate: none;
}

[data-slide="tech"] .tech-list li:nth-child(1) { transition-delay: .25s; }
[data-slide="tech"] .tech-list li:nth-child(2) { transition-delay: .35s; }
[data-slide="tech"] .tech-list li:nth-child(3) { transition-delay: .45s; }
[data-slide="tech"] .tech-list li:nth-child(4) { transition-delay: .55s; }
[data-slide="tech"] .device-badge { transition-delay: .65s; }

/* Arrows: a slow flowing dash once their beat is in. */
[data-slide="tech"].b1 .tech-flow [data-beat="1"] path:not(.head),
[data-slide="tech"].b2 .tech-flow [data-beat="2"] path:not(.head) { animation: tech-flow 1.2s linear infinite; }

@keyframes tech-flow { to { stroke-dashoffset: -16; } }

[data-slide="tech"].no-anim,
[data-slide="tech"].no-anim * { transition: none !important; }
