/* ============================================================
   stride.css — STRIDE Checkout Flow case study
   Builds on portfolio.css tokens. Loaded alongside living-bog.css
   (shared editorial components: .insights, .decisions, .acc-grid).
   ============================================================ */

/* ---- Hero filmstrip: the full journey ---- */
.stride-strip {
  display: flex; gap: 16px; justify-content: flex-start; align-items: flex-start;
  padding: clamp(20px, 3vw, 36px);
  background: var(--paper-2); border: 1px solid var(--line); border-radius: var(--r-xl);
  overflow-x: auto; scroll-snap-type: x proximity;
}
.stride-strip::-webkit-scrollbar { height: 6px; }
.stride-strip::-webkit-scrollbar-thumb { background: var(--line-2); border-radius: 3px; }
.stride-strip figure { margin: 0; flex: 0 0 auto; scroll-snap-align: center; }
.stride-strip img {
  height: clamp(240px, 34vw, 340px); width: auto; display: block;
  border-radius: 18px; border: 1px solid var(--line-2);
  box-shadow: 0 10px 34px rgba(34,34,30,0.10);
}
.stride-strip figcaption {
  font-family: var(--mono); font-size: 10.5px; letter-spacing: 0.08em; text-transform: uppercase;
  color: var(--ink-3); text-align: center; margin-top: 10px;
}

/* ---- Process: 4-stage interaction workflow ---- */
.flow4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: 0; }
.flow4 .stg { position: relative; padding: 0 24px; }
.flow4 .stg:first-child { padding-left: 0; }
.flow4 .stg:not(:last-child) { border-right: 1px solid var(--line); }
.flow4 .stg .k { font-family: var(--mono); font-size: 11px; letter-spacing: 0.1em; text-transform: uppercase; color: var(--ink-3); }
.flow4 .stg h4 { font-family: var(--serif); font-size: 1.5rem; font-weight: 600; letter-spacing: -0.02em; margin: 10px 0 0; }
.flow4 .stg .dot { width: 11px; height: 11px; border-radius: 50%; background: var(--accent); margin: 16px 0; }
.flow4 .stg p { color: var(--ink-2); font-size: 0.96rem; line-height: 1.5; margin: 0; }

/* ---- 07 Checkout Journey: horizontal flow ---- */
.journey-meta { display: flex; align-items: center; gap: 12px; margin-bottom: 20px; color: var(--ink-3); }
.journey-meta .hint { font-family: var(--mono); font-size: 11px; letter-spacing: 0.08em; text-transform: uppercase; display: inline-flex; align-items: center; gap: 8px; }
.journey-meta .bar { flex: 1; height: 1px; background: var(--line); }
.journey {
  display: flex; gap: 24px; overflow-x: auto; scroll-snap-type: x proximity;
  padding: 4px 4px 26px; margin: 0 calc(-1 * var(--gutter));
  padding-left: var(--gutter); padding-right: var(--gutter);
}
.journey::-webkit-scrollbar { height: 8px; }
.journey::-webkit-scrollbar-track { background: var(--paper-2); border-radius: 4px; }
.journey::-webkit-scrollbar-thumb { background: var(--line-2); border-radius: 4px; }
.j-step { flex: 0 0 clamp(260px, 78vw, 300px); scroll-snap-align: start; display: flex; flex-direction: column; }
.j-phone { position: relative; border-radius: 16px; overflow: hidden; border: 1px solid var(--line); background: var(--paper-2); }
.j-phone img { width: 100%; display: block; }
.j-step .j-head { display: flex; align-items: baseline; gap: 10px; margin-top: 18px; }
.j-step .j-num { font-family: var(--mono); font-size: 12px; color: var(--accent); letter-spacing: 0.04em; }
.j-step .j-stepk { font-family: var(--mono); font-size: 10px; letter-spacing: 0.1em; text-transform: uppercase; color: var(--ink-3); margin-left: auto; }
.j-step h4 { font-family: var(--serif); font-size: 1.25rem; font-weight: 600; letter-spacing: -0.02em; margin: 4px 0 0; }
.j-step .j-purpose { color: var(--ink-2); font-size: 0.95rem; line-height: 1.5; margin: 10px 0 0; }
.j-step .j-decision { margin: 14px 0 0; padding-top: 14px; border-top: 1px solid var(--line); font-size: 0.92rem; color: var(--ink-2); line-height: 1.5; }
.j-step .j-decision .dk { display: block; font-family: var(--mono); font-size: 10px; letter-spacing: 0.1em; text-transform: uppercase; color: var(--accent); margin-bottom: 6px; }

/* ---- 08 State Modelling: flow diagram ---- */
.flowmap { border: 1px solid var(--line); border-radius: var(--r-lg); background: var(--surface); padding: clamp(24px, 3vw, 40px); overflow-x: auto; }
.fm-row { display: flex; align-items: center; gap: 0; min-width: 680px; }
.fm-node { flex: 0 0 auto; text-align: center; }
.fm-pill { display: inline-flex; flex-direction: column; align-items: center; gap: 3px; padding: 12px 18px; border: 1px solid var(--line-2); border-radius: 12px; background: var(--paper); min-width: 92px; }
.fm-pill .n { font-family: var(--sans); font-weight: 600; font-size: 0.92rem; color: var(--ink); }
.fm-pill .s { font-family: var(--mono); font-size: 9px; letter-spacing: 0.06em; text-transform: uppercase; color: var(--ink-3); }
.fm-pill.is-key { border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-wash); }
.fm-link { flex: 1 1 16px; min-width: 16px; height: 1.5px; background: var(--accent); position: relative; }
.fm-link::after { content: ""; position: absolute; right: -1px; top: 50%; transform: translateY(-50%); border-left: 5px solid var(--accent); border-top: 4px solid transparent; border-bottom: 4px solid transparent; }
.fm-branch { margin-top: 18px; min-width: 680px; display: flex; }
.fm-branch .spacer { flex: 0 0 auto; }
.fm-fail { display: flex; align-items: center; gap: 12px; padding: 12px 16px; border: 1px dashed var(--line-2); border-radius: 12px; background: var(--paper-2); }
.fm-fail .x { width: 9px; height: 9px; border-radius: 50%; background: #C0563F; flex: none; }
.fm-fail .t { font-size: 0.86rem; color: var(--ink-2); }
.fm-fail .t b { color: var(--ink); font-weight: 600; }
.fm-legend { display: flex; flex-wrap: wrap; gap: 18px; margin-top: 22px; }
.fm-legend span { display: inline-flex; align-items: center; gap: 8px; font-size: 12.5px; color: var(--ink-2); }
.fm-legend i { width: 18px; height: 2px; border-radius: 2px; }

/* figma evidence */
.figma-shot { margin-top: 28px; border: 1px solid var(--line); border-radius: var(--r-lg); overflow: hidden; cursor: zoom-in; background: var(--paper-2); }
.figma-shot img { width: 100%; display: block; transition: opacity 0.3s var(--ease); }
.figma-shot:hover img { opacity: 0.94; }

/* ---- 09 Prototype: auto-playing phone mock ---- */
.proto { display: grid; grid-template-columns: 300px 1fr; gap: clamp(32px, 5vw, 64px); align-items: center; }
.proto-stage { display: flex; flex-direction: column; align-items: center; gap: 18px; }
.proto-phone {
  position: relative; width: 290px; aspect-ratio: 788 / 1752;
  border-radius: 44px; border: 11px solid #18181a; background: #000;
  overflow: hidden; box-shadow: 0 24px 70px rgba(34,34,30,0.22);
}
.proto-phone img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; opacity: 0; transition: opacity 0.7s var(--ease); }
.proto-phone img.active { opacity: 1; }
.proto-dots { display: flex; gap: 7px; }
.proto-dots span { width: 7px; height: 7px; border-radius: 50%; background: var(--line-2); transition: all 0.3s var(--ease); }
.proto-dots span.on { background: var(--accent); transform: scale(1.25); }
.proto-tag { display: inline-flex; align-items: center; gap: 8px; font-family: var(--mono); font-size: 11px; letter-spacing: 0.08em; text-transform: uppercase; color: var(--ink-3); }
.proto-tag .live { width: 7px; height: 7px; border-radius: 50%; background: var(--accent); animation: protopulse 1.8s ease-in-out infinite; }
@keyframes protopulse { 0%,100%{opacity:1} 50%{opacity:0.3} }
.proto-cap { font-family: var(--serif); font-size: 1.1rem; font-weight: 600; color: var(--ink); }
.proto-body h4 { font-family: var(--serif); font-size: clamp(1.4rem,2.4vw,1.9rem); font-weight: 600; letter-spacing: -0.02em; margin: 0 0 16px; }
.proto-body ul { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 12px; }
.proto-body li { position: relative; padding-left: 24px; color: var(--ink-2); font-size: 1.02rem; }
.proto-body li::before { content: ""; position: absolute; left: 4px; top: 10px; width: 6px; height: 6px; border-radius: 50%; background: var(--accent); }
.proto-note { margin-top: 20px; font-size: 0.88rem; color: var(--ink-3); }

@media (max-width: 860px) {
  .flow4 { grid-template-columns: 1fr 1fr; gap: 28px; }
  .flow4 .stg { padding: 0; border-right: 0 !important; }
  .proto { grid-template-columns: 1fr; justify-items: center; text-align: left; }
  .proto-body { width: 100%; }
}
@media (max-width: 540px) {
  .flow4 { grid-template-columns: 1fr; }
}
