@font-face {
  font-family: "Monetor Plex";
  src: url("/assets/fonts/IBMPlexSans-Regular.woff2") format("woff2");
  font-style: normal;
  font-weight: 400;
  font-display: swap;
}
@font-face {
  font-family: "Monetor Armenian UI";
  src: url("/assets/fonts/noto-sans-armenian.woff2") format("woff2");
  font-style: normal;
  font-weight: 400 600;
  font-display: swap;
  unicode-range: U+0308, U+0530-058F, U+2010, U+2024, U+25CC, U+FB13-FB17;
}
.merchant-story__scan-label,
.merchant-story__correction {
  font-family: var(--sans), "Monetor Armenian UI", sans-serif;
  font-feature-settings: normal;
}
/* Merchant story: a pinned, scroll-driven demonstration, with editable demo UI. */
.merchant-story {
  position: relative;
  isolation: isolate;
  width: 100%;
  max-width: none;
  height: 440svh;
  padding: 0;
  margin: 0;
  background: #1f1f1f;
  scroll-margin-top: 82px;
}
.merchant-story__anchor { position: absolute; top: 0; left: 0; scroll-margin-top: 82px; }
.merchant-story__pin { position: sticky; top: 82px; height: calc(100svh - 82px); min-height: 650px; overflow: hidden; }
.merchant-story__layout { display: grid; grid-template-columns: .95fr 1.05fr; align-items: center; gap: 64px; width: min(1170px, calc(100% - 112px)); height: 100%; margin: 0 auto; }
.merchant-story__copy { position: relative; z-index: 3; }
.merchant-story__eyebrow { margin: 0 0 18px; font-size: var(--type-label, 14px); font-weight: 500; letter-spacing: -0.01em; line-height: 1.35; text-transform: none; color: var(--ink-3, #8c8c8c); }
.merchant-story h2 { margin: 0; font-size: var(--type-h2, clamp(42px, 4.2vw, 64px)); line-height: var(--type-h2-leading, 1.04); letter-spacing: var(--type-h2-track, -.045em); font-weight: var(--type-h2-weight, 550); color: #fff; }
.merchant-story__steps { display: grid; gap: 8px; margin: 54px 0 0; padding: 0; list-style: none; }
.merchant-story__steps button { position: relative; display: block; width: 100%; min-height: 57px; padding: 10px 0 10px 23px; border: 0; border-radius: 0; background: transparent; text-align: left; font: inherit; line-height: 1.22; cursor: pointer; color: #949494; }
.merchant-story__steps button::before { content: ''; position: absolute; left: 0; top: 10px; bottom: 10px; width: 2px; border-radius: 2px; background: #ffffff16; }
.merchant-story__steps button[aria-current] { color: #fff; }
.merchant-story__steps button[aria-current]::before { background: #d6ff63; }
.merchant-story__step-long { display: block; font-size: 17px; letter-spacing: -.025em; }
.merchant-story__steps button[aria-current] .merchant-story__step-long { font-size: clamp(23px, 2vw, 30px); }
.merchant-story__step-short { display: none; }
.merchant-story__step-description { display: none; margin-top: 10px; max-width: 340px; font-size: 13px; line-height: 1.5; color: #adadad; }
.merchant-story__steps button[aria-current] .merchant-story__step-description { display: block; }
.merchant-story__soon { display: inline-block; margin-top: 6px; color: #c6b68b; font-size: 10px; line-height: 1.2; }
.merchant-story__steps button:focus-visible { outline: 2px solid #d6ff63; outline-offset: 5px; border-radius: 4px; }
.merchant-story__steps button:hover { color: #fff; }
.merchant-story__hint { display: flex; align-items: center; gap: 8px; margin: 25px 0 0 22px; font-size: 11px; color: #9a9a9a; }
.merchant-story__hint img { filter: invert(1); opacity: .6; }
.merchant-story__visual { position: relative; height: min(730px, 100%); min-width: 0; }
.merchant-story__panel { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; opacity: 0; transform: translateY(18px); pointer-events: none; transition: opacity 180ms ease-out, transform 180ms ease-out; }
.merchant-story[data-step="0"] .merchant-story__panel--ledger,
.merchant-story[data-step="1"] .merchant-story__panel--ledger,
.merchant-story[data-step="2"] .merchant-story__panel--email,
.merchant-story[data-step="3"] .merchant-story__panel--receipt { opacity: 1; transform: none; pointer-events: auto; }
.merchant-story__panel--ledger { display: block; overflow: hidden; mask-image: linear-gradient(transparent, #000 5%, #000 92%, transparent); }
.merchant-story__ledger { position: relative; }
.merchant-row { position: relative; --row-known: 0; display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(130px, 1fr) minmax(68px, .45fr); align-items: center; gap: 14px; height: 80px; font-size: 13px; color: #f1f1f1; transition: opacity 180ms ease-out; }
.merchant-row__identity { display: flex; align-items: center; gap: 12px; min-width: 0; }
.merchant-row__mark { position: relative; width: 43px; height: 43px; flex-shrink: 0; }
.merchant-row__logo { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; opacity: var(--row-known); }
.merchant-row__logo--local { border-radius: 50%; padding: 4px; background: #1c2923; }
.merchant-row__unknown { display: grid; place-items: center; position: absolute; inset: 3px; border-radius: 50%; background: #ffffff0b; opacity: calc(1 - var(--row-known)); }
.merchant-row__unknown img { width: 20px; height: 20px; filter: invert(1); opacity: .65; }
.merchant-row__name { position: relative; flex: 1; height: 20px; min-width: 0; }
.merchant-row__name span { position: absolute; inset: 0; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.merchant-row__raw { opacity: calc(1 - var(--row-known)); font-size: 11px; color: #bfbfbf; }
.merchant-row__clean { opacity: var(--row-known); }
.merchant-row__category { position: relative; height: 36px; min-width: 0; }
.merchant-row__badge { display: flex; align-items: center; gap: 6px; position: absolute; left: 0; top: 50%; transform: translateY(-50%); max-width: 100%; padding: 7px 10px; border-radius: 22px; border: 1px solid #ffffff12; font-size: 11px; white-space: nowrap; line-height: 1.2; }
.merchant-row__badge span { overflow: hidden; text-overflow: ellipsis; }
.merchant-row__badge img { width: 16px; height: 16px; filter: invert(1); opacity: .8; flex-shrink: 0; }
.merchant-row__badge--unknown { color: #989898; opacity: calc(1 - var(--row-known)); }
.merchant-row__badge--known { color: var(--category-color, #d6ff63); background: var(--category-bg, #d6ff6310); opacity: var(--row-known); }
.merchant-row__amount { text-align: right; font-size: 12px; font-variant-numeric: tabular-nums; white-space: nowrap; }
.merchant-story[data-step="1"] .merchant-row { opacity: .18; }
.merchant-story[data-step="1"] .merchant-row.is-focused { opacity: 1; }
/* The scan follows scroll progress; light and recognition activity continue locally. */
.merchant-row::before { content: ''; position: absolute; inset: 4px -8px; z-index: -1; border-radius: 10px; background: #ffffff06; opacity: 0; transition: opacity 180ms ease-out; }
.merchant-row.is-scanning::before { opacity: 1; }
.merchant-row__logo, .merchant-row__name span, .merchant-row__badge { transition: opacity 180ms ease-out; }
.merchant-story__scan { position: absolute; z-index: 2; top: 0; left: 0; right: 0; height: 1px; background: #d6ff6390; box-shadow: 0 0 12px #d6ff6320; pointer-events: none; }
.merchant-story__scan::before { content: ''; position: absolute; bottom: 1px; left: 0; right: 0; height: 44px; background: #d6ff6305; border-top: 1px solid #d6ff6312; animation: merchant-scan-breathe 2.4s ease-in-out infinite alternate; }
.merchant-story__scan::after { content: ''; position: absolute; left: 0; top: -1px; width: 68px; height: 3px; border-radius: 3px; background: #f1ffd0; box-shadow: 0 0 8px #d6ff6350; animation: merchant-scan-light 3.2s ease-in-out infinite alternate; }
.merchant-story__scan-label { position: absolute; right: 12px; bottom: 10px; padding: 3px 6px; color: #d0d0d0; background: #1f1f1f; font-size: 11px; font-weight: 400; line-height: 1.3; white-space: nowrap; }
.merchant-story:not([data-scanning="true"]) .merchant-story__scan::before,
.merchant-story:not([data-scanning="true"]) .merchant-story__scan::after { animation-play-state: paused; }
.merchant-story[data-step="1"] .merchant-story__scan { opacity: 0; }
@keyframes merchant-scan-breathe { from { opacity: .35; } to { opacity: 1; } }
@keyframes merchant-scan-light { from { transform: translateX(0); } to { transform: translateX(calc(var(--scan-width, 480px) - 68px)); } }
.merchant-story__correction { position: absolute; z-index: 3; top: 49%; right: 8%; width: 280px; padding: 18px; border: 1px solid #ffffff20; border-radius: 16px; background: #262626; box-shadow: 0 16px 40px #0005, inset 0 1px #ffffff06; opacity: 0; pointer-events: none; transform: translateY(8px); }
.merchant-story[data-step="1"] .merchant-story__correction { opacity: 1; pointer-events: auto; transform: none; }
.merchant-story__correction-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 12px; }
.merchant-story__correction label { color: #b7b7b7; font-size: 11px; }
.merchant-story__correction-head > span { color: #838383; font-size: 10px; }
.merchant-story__select-wrap { position: relative; display: flex; align-items: center; min-height: 48px; border: 1px solid #ffffff12; border-radius: 9px; background: #2f2f2f; }
.merchant-story__select-wrap > img { position: absolute; left: 12px; filter: invert(1); opacity: .85; pointer-events: none; }
.merchant-story__select-wrap > .merchant-story__select-chevron { left: auto; right: 12px; width: 14px; height: 14px; opacity: .6; }
.merchant-story__select-wrap select { appearance: none; flex: 1; min-width: 0; width: 100%; height: 48px; padding: 0 36px 0 44px; border: 0; border-radius: 9px; background: transparent; color: #f6f6f6; font: inherit; font-size: 14px; cursor: pointer; color-scheme: dark; }
.merchant-story__select-wrap select:focus-visible { outline: 2px solid #d6ff63; outline-offset: 3px; }
.merchant-story__select-wrap option { background: #2f2f2f; }
.merchant-story__saved { display: flex; align-items: center; gap: 6px; margin: 12px 0 0; color: #c2cab8; font-size: 10px; }
.merchant-story__saved img { filter: invert(1); opacity: .75; }
.merchant-story__transaction { position: relative; z-index: 2; width: 480px; min-height: 0; margin: 0 0 0 40px; padding: 32px; border: 1px solid #ffffff18; border-radius: 20px; background: #262626; box-shadow: 0 24px 64px #0005, inset 0 1px #ffffff06; }
.merchant-story__status { display: inline-flex; align-items: center; gap: 6px; padding: 6px 0; margin: 0 0 19px; color: #c6b68b; font-size: 10px; }
.merchant-story__status img { filter: invert(1); opacity: .6; }
.merchant-story__transaction-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 12px; }
.merchant-story__transaction-head h3 { margin: 0 0 5px; font-size: 21px; font-weight: 400; letter-spacing: -.025em; }
.merchant-story__transaction-head p { margin: 0; color: #fff; font-size: 48px; line-height: 1.1; font-weight: 550; letter-spacing: -.04em; font-variant-numeric: tabular-nums; }
.merchant-story__merchant-logo { width: 90px; height: 90px; object-fit: contain; }
.merchant-story__merchant-logo--sas { width: 50px; height: 50px; border-radius: 13px; }
.merchant-story__field-label { margin: 27px 0 8px; color: #959595; font-size: 11px; }
.merchant-story__source { display: flex; align-items: center; gap: 11px; min-height: 64px; padding: 12px; border: 1px solid #ffffff0b; border-radius: 10px; background: #2c2c2c; font-size: 12px; }
.merchant-story__source > img { flex-shrink: 0; filter: invert(1); opacity: .7; }
.merchant-story__source small { display: block; margin-top: 3px; font-size: 10px; color: #9c9c9c; }
.merchant-story__source-amount { margin-left: auto; font-size: 11px; color: #cacaca; font-variant-numeric: tabular-nums; }
.merchant-story__destination { border: 1px solid #ffffff0c; display: flex; align-items: center; gap: 10px; min-height: 60px; padding: 13px; border-radius: 10px; background: #2c2c2c; font-size: 13px; }
.merchant-story__destination img { filter: invert(1); opacity: .8; }
.merchant-story__check { margin-left: auto; }
.merchant-story__detail-toggle { display: flex; align-items: center; justify-content: space-between; gap: 10px; width: 100%; margin-top: 12px; padding: 12px 0; border: 0; background: transparent; color: #bababa; text-align: left; font: inherit; font-size: 11px; cursor: pointer; }
.merchant-story__detail-toggle img { filter: invert(1); opacity: .75; transition: transform 180ms ease-out; }
.merchant-story__detail-toggle[aria-expanded="true"] img { transform: rotate(180deg); }
.merchant-story__detail-toggle:hover { color: #d6ff63; }
.merchant-story__detail-toggle:focus-visible { outline: 2px solid #d6ff63; outline-offset: 3px; }
.merchant-story__items { margin-top: 2px; padding: 0; border-top: 1px solid #ffffff14; background: transparent; }
.merchant-story__items[hidden] { display: none; }
.merchant-story__items > div { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 13px 0; border-bottom: 1px solid #ffffff0b; color: #b0b0b0; font-size: 12px; }
.merchant-story__items > div:last-child { border-bottom: 0; }
.merchant-story__items strong { color: #e4e4e4; font-size: 12px; font-weight: 450; font-variant-numeric: tabular-nums; white-space: nowrap; }
.merchant-story__receipt-paper { position: absolute; z-index: 1; left: 5%; top: 7%; width: 225px; height: auto; transform: translateX(70px) rotate(-5deg); opacity: 0; }
.merchant-story__transaction--receipt { margin-left: 95px; min-height: 490px; padding: 27px; }
.merchant-story__receipt-summary { display: flex; align-items: center; gap: 6px; margin: 18px 0 0; color: #a6a6a6; font-size: 10px; }
.merchant-story__receipt-summary img { filter: invert(1); opacity: .8; }
@media (min-width: 1800px) { .merchant-story__layout { max-width: 1440px; gap: 100px; } .merchant-row { height: 84px; } .merchant-story h2 { font-size: 70px; } }
@media (max-width: 1100px) and (min-width: 701px) { .merchant-story__layout { width: calc(100% - 64px); gap: 30px; grid-template-columns: .85fr 1.15fr; } .merchant-story h2 { font-size: 43px; } .merchant-row { gap: 9px; grid-template-columns: minmax(0, 1fr) minmax(102px, 1fr) 66px; font-size: 11px; } .merchant-row__identity { gap: 5px; } .merchant-row__mark { width: 34px; height: 34px; } .merchant-row__badge { font-size: 9px; padding: 7px; } .merchant-story__transaction { width: 330px; padding: 22px; } .merchant-story__transaction--receipt { margin-left: 40px; } .merchant-story__receipt-paper { left: -8%; width: 190px; } }
@media (max-width: 700px) {
  .merchant-story { height: 410svh; }
  .merchant-story__pin { top: 70px; height: calc(100svh - 70px); min-height: 600px; }
  .merchant-story__layout { grid-template-columns: 1fr; grid-template-rows: auto minmax(0, 1fr); gap: 16px; align-items: start; width: calc(100% - 36px); padding: 24px 0 16px; }
  .merchant-story__eyebrow { margin-bottom: 8px; font-size: 13px; letter-spacing: -0.01em; }
  .merchant-story h2 { font-size: clamp(29px, 8.2vw, 42px); line-height: 1.03; letter-spacing: -.045em; }
  .merchant-story__steps { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; margin-top: 24px; }
  .merchant-story__steps button { min-height: 42px; padding: 0 0 11px; text-align: center; }
  .merchant-story__steps button::before { top: auto; bottom: 0; left: 0; right: 0; width: 100%; height: 2px; }
  .merchant-story__step-long, .merchant-story__step-description, .merchant-story__steps button[aria-current] .merchant-story__step-description { display: none; }
  .merchant-story__step-short { display: block; font-size: 12px; line-height: 1.4; }
  .merchant-story__soon { margin-top: 2px; font-size: 8px; }
  .merchant-story__hint { display: none; }
  .merchant-story__visual { width: 100%; height: 100%; min-height: 0; }
  .merchant-row { height: 57px; gap: 6px; grid-template-columns: minmax(0, 1.1fr) minmax(97px, 1fr) 59px; font-size: 10px; }
  .merchant-row__identity { gap: 5px; }
  .merchant-row__mark { width: 30px; height: 30px; }
  .merchant-row__name { height: 16px; }
  .merchant-row__raw { font-size: 8px; }
  .merchant-row__amount { font-size: 9px; }
  .merchant-row__badge { max-width: 100%; gap: 4px; padding: 6px; font-size: 8px; }
  .merchant-row__badge img { width: 13px; height: 13px; }
  .merchant-row__unknown { inset: 1px; }
  .merchant-row__unknown img { width: 15px; height: 15px; }
  .merchant-story__correction { top: 48%; right: 4%; width: min(250px, calc(100% - 24px)); padding: 14px; }
  .merchant-story__correction label { font-size: 10px; margin-bottom: 5px; }
  .merchant-story__saved { margin-top: 7px; font-size: 10px; }
  .merchant-story__transaction { width: min(290px, 100%); min-height: 0; margin-left: 0; padding: 20px; border-radius: 16px; }
  .merchant-story__transaction-head h3 { font-size: 14px; }
  .merchant-story__transaction-head p { font-size: 31px; }
  .merchant-story__merchant-logo { width: 47px; height: 47px; }
  .merchant-story__merchant-logo--sas { width: 40px; height: 40px; }
  .merchant-story__status { margin-bottom: 12px; font-size: 9px; }
  .merchant-story__field-label { margin-top: 17px; margin-bottom: 6px; font-size: 10px; }
  .merchant-story__source { min-height: 51px; padding: 9px; font-size: 10px; }
  .merchant-story__source small { font-size: 9px; }
  .merchant-story__source-amount { font-size: 9px; }
  .merchant-story__destination { min-height: 46px; padding: 10px; font-size: 11px; }
  .merchant-story__detail-toggle { margin-top: 6px; padding: 9px 0; font-size: 10px; }
  .merchant-story__items { padding: 0; }
  .merchant-story__items > div { padding: 8px 0; font-size: 10px; }
  .merchant-story__items strong { font-size: 10px; }
  .merchant-story__transaction--receipt { width: min(278px, calc(100% - 30px)); margin-left: 30px; padding: 17px; }
  .merchant-story__receipt-paper { width: 153px; top: 0; left: -16px; }
  .merchant-story__receipt-summary { margin-top: 12px; font-size: 9px; }
  html[lang="hy"] .merchant-story__step-short { font-size: 10px; }
  html[lang="hy"] .merchant-story__soon { font-size: 7px; }
}
@media (max-height: 760px) and (min-width: 701px) {
  .merchant-story__pin { min-height: 570px; }
  .merchant-story__eyebrow { margin-bottom: 12px; }
  .merchant-story h2 { font-size: 48px; }
  .merchant-story__steps { margin-top: 30px; }
  .merchant-story__steps button { min-height: 48px; padding-top: 8px; padding-bottom: 8px; }
  .merchant-story__steps button[aria-current] .merchant-story__step-long { font-size: 23px; }
  .merchant-story__hint { margin-top: 15px; }
  .merchant-story__transaction { min-height: 0; padding: 22px; }
  .merchant-story__field-label { margin-top: 18px; }
  .merchant-story__items > div { padding: 9px 0; }
}
@media (prefers-reduced-motion: reduce) {
  .merchant-story__panel, .merchant-row, .merchant-story__detail-toggle img { transition: none; }
  .merchant-story__scan { display: none; }
  .merchant-row::before, .merchant-row__logo, .merchant-row__name span, .merchant-row__badge { transition: none; }
  .merchant-story__scan::before, .merchant-story__scan::after, }

@media (max-width: 700px) and (max-height: 780px) {
  .merchant-story__transaction--receipt { padding: 14px; }
  .merchant-story__transaction--receipt .merchant-story__field-label { margin-top: 10px; }
  .merchant-story__transaction--receipt .merchant-story__items > div { padding: 4px 0; }
  .merchant-story__transaction--receipt .merchant-story__source { min-height: 46px; }
  .merchant-story__transaction--receipt .merchant-story__destination { min-height: 42px; }
}
/* Merchant identities use flat artwork, not the hero's former 3D coin assets. */
.merchant-row__logo {
  object-position: center;
  padding: 9px;
  border-radius: 10px;
  background: #e8ece5;
}
.merchant-row__logo--dark { background: #1c2520; }
.merchant-row__logo--local { border-radius: 10px; padding: 4px; }
.merchant-story__merchant-logo {
  object-position: center;
  padding: 20px;
  border-radius: 18px;
  background: #e8ece5;
}
.merchant-story__merchant-logo--sas { padding: 4px; border-radius: 10px; }
@media (max-width: 700px) {
  .merchant-row__logo { padding: 6px; border-radius: 7px; }
  .merchant-row__logo--local { padding: 3px; }
  .merchant-story__merchant-logo { padding: 10px; border-radius: 10px; }
  .merchant-story__merchant-logo--sas { padding: 3px; }
}

/* Category popover (EN): a compact menu under the Coffee House badge, like the app's own picker. */
.merchant-story__correction.merchant-story__correction--sheet {
  top: calc(var(--row-h, 80px) * 4 - 10px);
  left: min(calc(var(--cat-x, 50%) - 6px), calc(100% - 236px));
  right: auto;
  width: 236px;
  padding: 6px;
  border: 0;
  border-radius: 16px;
  background: #2a2a2a;
  box-shadow: 0 18px 44px rgba(0,0,0,.55), inset 0 0 0 1px var(--hairline-strong, #ffffff29);
  transform: translateY(-4px) scale(.98);
  transform-origin: 30px 0;
  transition: opacity 200ms ease, transform 260ms cubic-bezier(.2,.7,.2,1);
}
.merchant-story[data-step="1"] .merchant-story__correction--sheet { transform: none; }
.merchant-story__sheet-title { margin: 6px 10px 6px; color: var(--ink-3, #8c8c8c); font-size: 11px; font-weight: 500; }
.merchant-story__choices { display: grid; gap: 2px; }
.merchant-story__choices button {
  position: relative;
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
  min-height: 34px;
  padding: 0 34px 0 10px;
  border: 0;
  border-radius: 10px;
  background: transparent;
  color: var(--ink-2, #bdbdbd);
  font: inherit;
  font-size: 13px;
  text-align: left;
  cursor: pointer;
  transition: background 160ms ease, color 160ms ease;
}
.merchant-story__choices button img { width: 15px; height: 15px; filter: invert(1); opacity: .65; }
.merchant-story__choices button:hover { background: #ffffff0a; color: var(--ink-1, #fff); }
.merchant-story__choices button[aria-checked="true"] { background: rgba(214,255,99,.12); color: var(--accent, #d6ff63); font-weight: 500; }
.merchant-story__choices button[aria-checked="true"] img { filter: invert(91%) sepia(56%) saturate(659%) hue-rotate(20deg) brightness(104%); opacity: 1; }
.merchant-story__choices button[aria-checked="true"]::after { content: ''; position: absolute; right: 11px; top: 50%; width: 12px; height: 7px; border: solid var(--accent, #d6ff63); border-width: 0 0 2px 2px; transform: translateY(-70%) rotate(-45deg); }
.merchant-story__choices button:focus-visible { outline: 2px solid var(--accent, #d6ff63); outline-offset: -2px; }
.merchant-story__correction--sheet .merchant-story__saved { gap: 6px; margin: 4px 0 0; padding: 9px 10px 6px; border-top: 1px solid var(--hairline, #ffffff17); color: var(--ink-3, #8c8c8c); font-size: 11px; }
.merchant-story__correction--sheet .merchant-story__saved img { width: 14px; height: 14px; }
@media (max-width: 900px) {
  .merchant-story__correction.merchant-story__correction--sheet { top: calc(var(--row-h, 57px) * 4 - 6px); left: auto; right: 0; width: 200px; padding: 5px; }
  .merchant-story__choices button { min-height: 30px; font-size: 12px; }
}
@media (prefers-reduced-motion: reduce) {
  .merchant-story__correction--sheet, .merchant-story__choices button { transition: none; }
}

/* AI recognition lens (EN): settles on one row, reads the raw descriptor, then resolves it. */
.merchant-story__scan.merchant-story__scan--lens {
  left: -10px;
  right: -10px;
  height: var(--row-h, 80px);
  border-radius: 14px;
  background:
    linear-gradient(100deg, transparent 20%, rgba(214,255,99,.10) 45%, transparent 70%) 0 0 / 250% 100%,
    rgba(214,255,99,.035);
  box-shadow: inset 0 0 0 1px rgba(214,255,99,.32), 0 0 30px rgba(214,255,99,.06);
  transition: transform 420ms cubic-bezier(.2,.7,.2,1), opacity 200ms ease;
  animation: merchant-lens-sweep 1.6s linear infinite;
}
.merchant-story__scan--lens::before,
.merchant-story__scan--lens::after { display: none; }
.merchant-story:not([data-scanning="true"]) .merchant-story__scan--lens { animation-play-state: paused; }
.merchant-story__scan-pill {
  position: absolute;
  top: 50%;
  left: calc(var(--cat-x, 50%) + 10px);
  display: inline-flex;
  align-items: center;
  gap: 8px;
  height: 34px;
  max-width: calc(100% - var(--cat-x, 50%) - 110px);
  padding: 0 13px 0 7px;
  border-radius: 999px;
  background: #171717;
  box-shadow: inset 0 0 0 1px rgba(214,255,99,.38);
  color: var(--ink-2, #bdbdbd);
  font-size: 12px;
  line-height: 1;
  white-space: nowrap;
  transform: translateY(-50%);
  transition: opacity 200ms ease, transform 260ms cubic-bezier(.2,.7,.2,1);
}
.merchant-story__scan-pill [data-scan-text] { overflow: hidden; text-overflow: ellipsis; }
.merchant-story__scan--lens[data-matched="false"] [data-scan-text] { color: transparent; background: linear-gradient(90deg, #8c8c8c, #fff, #8c8c8c) 0 0 / 200% 100%; -webkit-background-clip: text; background-clip: text; animation: merchant-text-shimmer 1.1s linear infinite; }
/* once matched, the pill steps aside and the category badge lands in its place */
.merchant-story__scan--lens[data-matched="true"] .merchant-story__scan-pill { opacity: 0; transform: translateY(-50%) scale(.94); }
.merchant-row.is-scanning .merchant-row__badge--unknown { opacity: 0; }
.merchant-story__scan-orb { display: block; flex: none; width: 20px; height: 20px; }

/* inside the row being read: the merchant token lights up, the descriptor noise falls away */
.merchant-row__raw mark { background: none; color: inherit; border-radius: 4px; transition: background 220ms ease, color 220ms ease, box-shadow 220ms ease; }
.merchant-row__raw i { font-style: normal; transition: opacity 260ms ease; }
.merchant-row.is-scanning .merchant-row__raw mark { background: rgba(214,255,99,.16); color: var(--accent, #d6ff63); box-shadow: 0 0 0 3px rgba(214,255,99,.16); }
.merchant-row.is-scanning .merchant-row__raw i { opacity: .3; }
.merchant-row.is-scanning .merchant-row__unknown img { opacity: 0; }
.merchant-row.is-scanning .merchant-row__unknown::after { content: ''; position: absolute; inset: 3px; border-radius: 50%; border: 1.5px solid #ffffff1c; border-top-color: var(--accent, #d6ff63); animation: merchant-spin .8s linear infinite; }
.merchant-row.is-scanning::before { opacity: 0; }
.merchant-row__badge--known { transform: translateY(-50%) scale(calc(.9 + var(--row-known) * .1)); transition: opacity 260ms ease, transform 360ms cubic-bezier(.3,1.5,.5,1); }
.merchant-row__clean { font-variant-numeric: tabular-nums; }

@keyframes merchant-lens-sweep { to { background-position: -250% 0, 0 0; } }
@keyframes merchant-text-shimmer { to { background-position: -200% 0; } }
@keyframes merchant-orb { 50% { transform: scale(.82); } }
@keyframes merchant-spin { to { transform: rotate(360deg); } }

@media (max-width: 900px) {
  .merchant-story__scan.merchant-story__scan--lens { left: -6px; right: -6px; border-radius: 12px; }
  .merchant-story__scan-pill { left: calc(var(--cat-x, 50%) + 6px); height: 28px; gap: 6px; padding: 0 10px 0 5px; font-size: 10px; max-width: none; }
  .merchant-story__scan-orb { width: 18px; height: 18px; }
}
@media (prefers-reduced-motion: reduce) {
  .merchant-story__scan--lens, .merchant-row__unknown::after { animation: none !important; }
}
