/* miapos-swipe-cards.css: a horizontal set of text cards inside a docs page (#27, 20.11.2026).
 * All text is real HTML, so search engines and AI readers see it; JS only adds the arrows and dots.
 * Rules are prefixed with .doc-body because the page resets lists inside .doc-body. */

.doc-body .sw { margin: 8px 0 40px; min-width: 0; }
.doc-body .sw__head { display: flex; align-items: center; justify-content: space-between; gap: 16px; margin-bottom: 14px; }
.doc-body .sw__label { font-family: var(--font-mono); font-size: 12px; letter-spacing: .08em; text-transform: uppercase; color: var(--teal-700); }
.doc-body .sw__ctrl { display: flex; gap: 8px; }
.doc-body .sw__btn {
  width: 40px; height: 40px; border-radius: 50%; border: 1px solid var(--ink-200); background: var(--white);
  color: var(--ink-900); font-size: 18px; line-height: 1; cursor: pointer; display: grid; place-items: center;
  transition: background-color .2s, border-color .2s, transform .15s;
}
.doc-body .sw__btn:hover { border-color: var(--teal-500); background: var(--teal-50); }
.doc-body .sw__btn:active { transform: scale(.94); }
.doc-body .sw__btn:focus-visible { outline: 2px solid var(--teal-600); outline-offset: 2px; }
.doc-body .sw__btn[disabled] { opacity: .35; cursor: default; background: var(--white); border-color: var(--ink-200); }

.doc-body .sw__track {
  list-style: none; margin: 0; padding: 4px 2px 18px; display: flex; gap: 14px;
  /* The docs grid is 1fr on phones, so the row of cards would widen the column; contain keeps it at the page width. */
  contain: inline-size; overflow-x: auto; scroll-snap-type: x mandatory; scroll-padding-left: 2px;
  scrollbar-width: thin; scrollbar-color: var(--ink-200) transparent; overscroll-behavior-x: contain;
}
.doc-body .sw__track:focus-visible { outline: 2px solid var(--teal-600); outline-offset: 4px; border-radius: 8px; }
.doc-body .sw__card {
  flex: 0 0 min(300px, 82%); margin: 0; scroll-snap-align: start; display: flex; flex-direction: column;
  padding: 22px 22px 20px; border-radius: 18px; background: var(--ink-50); border: 1px solid var(--ink-100);
  color: var(--ink-900); line-height: 1.4; min-height: 400px; position: relative; overflow: hidden;
}
.doc-body .sw__card--dark { background: var(--ink-950); border-color: var(--ink-950); color: var(--white); }
.doc-body .sw__card--dark::after {
  content: ""; position: absolute; right: -120px; top: -120px; width: 320px; height: 320px; border-radius: 50%;
  background: radial-gradient(circle, rgba(31,179,158,.28), rgba(31,179,158,0) 68%); pointer-events: none;
}
.doc-body .sw__top { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; }
.doc-body .sw__kicker { font-family: var(--font-mono); font-size: 11px; letter-spacing: .08em; text-transform: uppercase; color: var(--teal-700); }
.doc-body .sw__card--dark .sw__kicker { color: var(--teal-400); }
.doc-body .sw__num { font-family: var(--font-serif); font-style: italic; font-size: 20px; line-height: 1; color: var(--ink-400); white-space: nowrap; }
.doc-body .sw__num b { font-weight: 400; color: var(--teal-600); }
.doc-body .sw__card--dark .sw__num b { color: var(--teal-400); }
.doc-body .sw__title {
  font-family: var(--font-sans); font-weight: 800; font-size: 26px; line-height: 1.08; letter-spacing: -.03em;
  margin: 22px 0 0; color: inherit; text-wrap: balance;
}
.doc-body .sw__card--cover .sw__title, .doc-body .sw__card--end .sw__title { margin-top: auto; font-size: 30px; }
.doc-body .sw__title em { font-style: normal; color: var(--teal-600); }
.doc-body .sw__card--dark .sw__title em { color: var(--teal-400); }
.doc-body .sw__text { margin: 16px 0 0; font-size: 15px; color: var(--ink-700); }
.doc-body .sw__card--dark .sw__text { color: var(--ink-300); }
.doc-body .sw__text + .sw__text { margin-top: 8px; }
.doc-body .sw__strong { font-weight: 600; font-size: 17px; color: var(--ink-900); }
.doc-body .sw__strong--accent { color: var(--teal-700); }

.doc-body .sw__prompt {
  display: block; margin: 18px 0 0; padding: 12px 14px; border-radius: 12px; background: var(--ink-900);
  border: 1px solid var(--ink-700); color: var(--white); font-family: var(--font-mono); font-size: 13px; line-height: 1.4;
  overflow-wrap: anywhere;
}
.doc-body .sw__prompt::after { content: ""; display: inline-block; width: 2px; height: 1em; margin-left: 6px; vertical-align: -2px; background: var(--teal-400); }

.doc-body .sw__steps { list-style: none; counter-reset: sw; margin: 18px 0 0; padding: 0; display: flex; flex-direction: column; gap: 12px; }
.doc-body .sw__steps > li {
  counter-increment: sw; display: grid; grid-template-columns: 26px minmax(0, 1fr); gap: 8px; margin: 0; font-size: 15px;
}
.doc-body .sw__steps > li::before { content: counter(sw); font-family: var(--font-serif); font-style: italic; font-size: 26px; line-height: .9; color: var(--teal-600); }
.doc-body .sw__list { list-style: none; margin: 16px 0 0; padding: 0; display: flex; flex-direction: column; gap: 8px; }
.doc-body .sw__list > li { margin: 0; padding-left: 18px; position: relative; font-size: 14.5px; }
.doc-body .sw__list > li::before { content: ""; position: absolute; left: 0; top: .5em; width: 8px; height: 8px; border-radius: 2px; background: var(--teal-500); }
.doc-body .sw__note { margin: auto 0 0; padding-top: 12px; border-top: 1px solid var(--ink-200); font-family: var(--font-mono); font-size: 11.5px; color: var(--ink-500); }

.doc-body .sw__fig { margin: auto 0 0; padding-top: 16px; }
.doc-body .sw__fig img { display: block; width: auto; max-width: 100%; height: auto; max-height: 170px; border-radius: 12px; border: 1px solid var(--ink-200); }
.doc-body .sw__fig figcaption { margin-top: 6px; font-family: var(--font-mono); font-size: 11px; color: var(--ink-500); }

.doc-body .sw__links { list-style: none; margin: 18px 0 0; padding: 0; border-top: 1px solid var(--ink-700); }
.doc-body .sw__links > li { margin: 0; padding: 10px 0; border-bottom: 1px solid var(--ink-700); }
.doc-body .sw__links a { color: var(--teal-300); font-family: var(--font-mono); font-size: 13px; text-decoration: none; overflow-wrap: anywhere; }
.doc-body .sw__links a:hover { color: var(--white); text-decoration: underline; }
.doc-body .sw__links a:focus-visible { outline: 2px solid var(--teal-400); outline-offset: 2px; }

.doc-body .sw__dots { display: flex; gap: 6px; justify-content: center; margin-top: 4px; }
.doc-body .sw__dots i { width: 18px; height: 4px; border-radius: 2px; background: var(--ink-200); transition: background-color .2s; }
.doc-body .sw__dots i.is-on { background: var(--teal-500); }

@media (prefers-reduced-motion: reduce) {
  .doc-body .sw__track { scroll-behavior: auto; }
  .doc-body .sw__btn, .doc-body .sw__dots i { transition: none; }
}
