/* ChaseInTech demo kit: checkout, payment hub, lens and house effects. */

/* ---------- House effects ---------- */
.fx-ready [data-fx="reveal"] { transition: opacity .9s cubic-bezier(.2,.7,.2,1) var(--fx-delay, 0ms), transform .9s cubic-bezier(.2,.7,.2,1) var(--fx-delay, 0ms), filter .9s cubic-bezier(.2,.7,.2,1) var(--fx-delay, 0ms); }
.fx-ready [data-fx="reveal"]:not(.fx-in) { opacity: 0; transform: translateY(28px); filter: blur(8px); }
.fx-ready [data-fx="reveal"][data-fx-variant="media"]:not(.fx-in) { transform: translateY(18px) scale(.97); }
.fx-ready [data-fx="words"] .fx-w { display: inline-block; overflow: clip; overflow-clip-margin: .25em; padding-bottom: .14em; margin-bottom: -.14em; vertical-align: top; }
.fx-ready [data-fx="words"] .fx-wi { display: inline-block; transition: transform 1s cubic-bezier(.2,.8,.2,1) calc(var(--w, 0) * 55ms), opacity .7s ease calc(var(--w, 0) * 55ms), filter .8s ease calc(var(--w, 0) * 55ms); }
.fx-ready [data-fx="words"]:not(.fx-in) .fx-wi { transform: translateY(108%) rotate(2deg); opacity: 0; filter: blur(6px); }
.fx-ready [data-fx="mask"] { clip-path: inset(0 0 0 0); transition: clip-path 1.2s cubic-bezier(.7,0,.2,1) var(--fx-delay, 0ms); }
.fx-ready [data-fx="mask"]:not(.fx-in) { clip-path: inset(0 100% 0 0); }
[data-fx="tilt"] { transform: perspective(1100px) rotateX(var(--tilt-x, 0deg)) rotateY(var(--tilt-y, 0deg)); transition: transform .35s cubic-bezier(.2,.7,.2,1); transform-style: preserve-3d; }
[data-fx="tilt"]::before { content: ""; position: absolute; inset: 0; z-index: 3; pointer-events: none; border-radius: inherit; opacity: 0; transition: opacity .35s; background: radial-gradient(420px circle at var(--glow-x, 50%) var(--glow-y, 50%), rgba(255,255,255,.18), transparent 45%); mix-blend-mode: soft-light; }
[data-fx="tilt"]:hover::before { opacity: 1; }
[data-fx="magnetic"] { transition: transform .25s cubic-bezier(.2,.7,.2,1); }
[data-fx="parallax"] { will-change: transform; }
[data-fx="rail"] { scrollbar-width: none; }
[data-fx="rail"]::-webkit-scrollbar { display: none; }
[data-fx="cycle"] { position: relative; overflow: hidden; }
[data-fx="cycle"] > img, [data-fx="cycle"] > picture { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; opacity: 0; transition: opacity .9s ease, transform 6s linear; transform: scale(1.04); }
[data-fx="cycle"] > .is-on { opacity: 1; transform: scale(1); }
[data-fx="pulse"] > * { transition: box-shadow .7s ease; }
[data-fx="pulse"] > .fx-breathing { box-shadow: 0 0 0 1px var(--fx-glow, #4da3ff), 0 0 34px -6px var(--fx-glow, #4da3ff); }
@media (prefers-reduced-motion: reduce) {
  .fx-ready [data-fx] , .fx-ready [data-fx] .fx-wi { transition: none !important; opacity: 1 !important; transform: none !important; filter: none !important; clip-path: none !important; }
}

/* ---------- Lens ---------- */
html.cit-lens-on [data-cap] { outline: 2px dashed rgba(119, 186, 255, .85); outline-offset: 4px; }
.ln-layer { position: fixed; inset: 0; pointer-events: none; z-index: 2147482000; }
.ln-pin { position: absolute; top: 0; left: 0; pointer-events: auto; display: inline-flex; align-items: center; gap: 8px; max-width: 200px; padding: 6px 9px 6px 7px; border: 1px solid rgba(255,255,255,.22); border-radius: 4px; background: rgba(6, 10, 18, .94); color: #eef2f8; font: 600 11.5px/1.2 system-ui, -apple-system, "Segoe UI", sans-serif; text-align: left; cursor: pointer; box-shadow: 0 8px 24px rgba(0,0,0,.35); animation: ln-in .35s cubic-bezier(.2,.7,.2,1) both; }
.ln-pin:focus-visible { outline: 2px solid #77baff; outline-offset: 2px; }
.ln-pin[hidden] { display: none !important; }
@keyframes ln-in { from { opacity: 0; transform: scale(.92); } }
.ln-ms { display: inline-flex; gap: 2px; flex: none; }
.ln-t { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ln-m { display: inline-block; width: 9px; height: 9px; background: #5ee38f; }
.ln-m.part { background: #f5c94a; }
.ln-m.no { background: #ff7a6b; }
.ln-legend { position: fixed; z-index: 2147482001; left: 50%; bottom: calc(14px + var(--cit-dock-h, 0px) + env(safe-area-inset-bottom)); transform: translateX(-50%); width: max-content; max-width: calc(100vw - 24px); padding: 9px 12px; border-radius: 6px; background: rgba(6,10,18,.96); color: #c9d4e4; font: 500 12.5px/1.35 system-ui, -apple-system, "Segoe UI", sans-serif; border: 1px solid rgba(255,255,255,.16); box-shadow: 0 10px 30px rgba(0,0,0,.4); }
.ln-legend[hidden] { display: none; }
.ln-legend span { display: inline-flex; gap: 3px; margin-right: 8px; vertical-align: -1px; }
.ln-sheet { border: 0; padding: 0; margin: auto auto 0; width: min(460px, 100%); border-radius: 16px 16px 0 0; background: #0b111b; color: #eef2f8; font: 400 15px/1.5 system-ui, -apple-system, "Segoe UI", sans-serif; }
@media (min-width: 700px) { .ln-sheet { margin: auto; border-radius: 16px; } }
.ln-sheet::backdrop { background: rgba(0,0,0,.55); backdrop-filter: blur(3px); }
.ln-sheet[open] { animation: co-up .32s cubic-bezier(.2,.7,.2,1); }
.ln-in { position: relative; padding: 22px 22px calc(22px + env(safe-area-inset-bottom)); }
.ln-x { position: absolute; top: 12px; right: 12px; width: 40px; height: 40px; border: 1px solid rgba(255,255,255,.2); border-radius: 6px; background: none; color: inherit; font-size: 20px; cursor: pointer; }
.ln-k { margin: 0 0 6px; font: 600 11px/1 ui-monospace, Consolas, monospace; letter-spacing: .12em; text-transform: uppercase; color: #77baff; }
.ln-in h3 { margin: 0 0 14px; font-size: 21px; padding-right: 44px; }
.ln-rows { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.ln-rows li { display: grid; grid-template-columns: 64px 1fr; gap: 2px 12px; padding: 12px; border-radius: 8px; background: rgba(255,255,255,.04); border: 1px solid rgba(255,255,255,.08); }
.ln-rows li.home { border-color: rgba(119,186,255,.6); background: rgba(77,163,255,.1); }
.ln-rows .ln-w { grid-row: span 2; align-self: center; font: 700 11px/1 ui-monospace, Consolas, monospace; text-transform: uppercase; letter-spacing: .06em; }
.ln-rows li.yes .ln-w { color: #5ee38f; } .ln-rows li.part .ln-w { color: #f5c94a; } .ln-rows li.no .ln-w { color: #ff7a6b; }
.ln-rows b em { font-style: normal; font: 600 10px/1 ui-monospace, Consolas, monospace; color: #77baff; margin-left: 6px; text-transform: uppercase; }
.ln-rows span:last-child { font-size: 14px; color: #aab6c8; }
.ln-foot { margin: 14px 0 0; font-size: 12.5px; color: #8492a6; }

/* ---------- Checkout ---------- */
.cit-co { --co-accent: var(--cit-accent, #111); --hub-c: #4da3ff; border: 0; padding: 0; margin: 0; width: 100%; max-width: none; height: 100dvh; max-height: none; background: #f6f7f9; color: #1a1d23; font: 400 15px/1.5 system-ui, -apple-system, "Segoe UI", Roboto, sans-serif; }
.cit-co.shopify { --hub-c: #95bf47; }
.cit-co::backdrop { background: rgba(4, 7, 12, .7); backdrop-filter: blur(6px); }
.cit-co[open] { animation: co-up .4s cubic-bezier(.2,.7,.2,1); }
@keyframes co-up { from { transform: translateY(36px); opacity: 0; } }
@media (min-width: 900px) { .cit-co { margin: auto; width: min(1020px, 94vw); height: min(760px, 92vh); border-radius: 14px; box-shadow: 0 40px 120px rgba(0,0,0,.5); } }
.co-shell { display: flex; flex-direction: column; height: 100%; }
.co-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 16px; padding: calc(14px + env(safe-area-inset-top)) 20px 12px; background: #fff; border-bottom: 1px solid #e6e8ec; }
.co-demo { margin: 0 0 4px; display: inline-flex; align-items: center; gap: 8px; font: 600 11px/1.3 ui-monospace, Consolas, monospace; letter-spacing: .04em; color: #8a5a00; background: #fff4d6; padding: 4px 8px; border-radius: 3px; }
.co-head h2 { margin: 0; font-size: 20px; display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 12px; }
.co-head h2 span { font-size: 14px; font-weight: 500; color: #69707d; }
.co-close { width: 42px; height: 42px; flex: none; border: 1px solid #d9dce2; border-radius: 8px; background: #fff; font-size: 22px; cursor: pointer; color: #1a1d23; }
.co-tabs { display: flex; gap: 4px; padding: 0 16px; background: #fff; border-bottom: 1px solid #e6e8ec; }
.co-tabs button { border: 0; background: none; padding: 14px 10px 12px; font: 600 14px/1 inherit; font-family: inherit; color: #69707d; border-bottom: 2px solid transparent; cursor: pointer; }
.co-tabs button[aria-selected="true"] { color: #1a1d23; border-color: var(--hub-c); }
.co-body { flex: 1; overflow-y: auto; overscroll-behavior: contain; }
.co-pay { display: grid; grid-template-columns: 1fr; }
@media (min-width: 900px) { .co-pay { grid-template-columns: .9fr 1.1fr; min-height: 100%; } }
.co-summary { padding: 20px; background: #eef0f3; }
@media (min-width: 900px) { .co-summary { padding: 32px; border-right: 1px solid #e3e6eb; } }
.co-h { margin: 0 0 12px; font: 600 12px/1 ui-monospace, Consolas, monospace; letter-spacing: .1em; text-transform: uppercase; color: #69707d; }
.co-summary ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 12px; }
.co-summary li { display: grid; grid-template-columns: 56px 1fr auto; gap: 12px; align-items: center; }
.co-summary img, .co-ph { width: 56px; height: 56px; border-radius: 8px; object-fit: cover; background: linear-gradient(135deg, #d9dde4, #c4cad4); border: 1px solid rgba(0,0,0,.08); }
.co-summary li b { display: block; font-size: 15px; }
.co-summary li small { color: #69707d; font-size: 13px; }
.co-summary li em { font-style: normal; font-weight: 700; text-align: right; }
.co-summary li em small { display: block; font-weight: 500; }
.co-lines { margin: 14px 0 0; display: grid; gap: 6px; font-size: 14.5px; }
.co-lines div { display: flex; justify-content: space-between; gap: 12px; }
.co-lines dt { display: grid; } .co-lines dt small { font-size: 12.5px; opacity: .65; }
.co-lines dd { margin: 0; font-weight: 600; } .co-lines .minus dd { color: #1a7f4b; }
.co-total { display: flex; justify-content: space-between; margin: 18px 0 0; padding-top: 14px; border-top: 1px solid #d9dce2; font-size: 17px; }
.co-methods { padding: 20px 20px calc(28px + env(safe-area-inset-bottom)); display: grid; gap: 14px; align-content: start; background: #fff; }
@media (min-width: 900px) { .co-methods { padding: 32px 40px; } }
.co-xs { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
.co-x { min-height: 46px; border: 1px solid var(--bd); border-radius: 6px; background: var(--bg); color: var(--fg); font: 700 15px/1 system-ui, -apple-system, "Segoe UI", sans-serif; letter-spacing: -.01em; cursor: pointer; transition: transform .15s, filter .15s; }
.co-x:hover { filter: brightness(1.06); } .co-x:active { transform: scale(.97); }
.co-x:first-child { grid-column: 1 / -1; min-height: 50px; font-size: 16px; }
.co-or { display: flex; align-items: center; gap: 12px; margin: 4px 0; color: #8a909b; font-size: 13px; }
.co-or::before, .co-or::after { content: ""; flex: 1; height: 1px; background: #e3e6eb; }
.co-card { display: grid; gap: 10px; opacity: .85; }
.co-card div { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.co-card label { display: grid; gap: 6px; font-size: 13px; font-weight: 600; color: #3b414c; }
.co-card input { height: 46px; border: 1px solid #d9dce2; border-radius: 6px; padding: 0 12px; font: 16px system-ui, sans-serif; background: #f9fafb; color: #8a909b; cursor: not-allowed; }
.co-paybtn { min-height: 52px; border: 0; border-radius: 8px; background: var(--co-accent); color: #fff; font: 700 16px/1 system-ui, -apple-system, "Segoe UI", sans-serif; cursor: pointer; }
.cit-co.shopify .co-paybtn { background: #1a1d23; }
.co-paybtn:active { transform: scale(.98); }
.co-via { margin: 0; font-size: 13px; color: #69707d; text-align: center; }
.co-link { border: 0; background: none; padding: 0; color: #2457c5; font: inherit; font-weight: 600; text-decoration: underline; text-underline-offset: 3px; cursor: pointer; }
.co-result { min-height: 0; font-size: 14px; }
.co-result.working, .co-result.done { padding: 14px; border-radius: 8px; background: #f2f6ff; color: #1b3a73; display: flex; gap: 10px; align-items: flex-start; }
.co-result.done { background: #eafaf0; color: #10512b; display: block; }
.co-spin { width: 16px; height: 16px; flex: none; border: 2px solid currentColor; border-right-color: transparent; border-radius: 50%; animation: co-spin .8s linear infinite; margin-top: 2px; }
@keyframes co-spin { to { transform: rotate(360deg); } }

/* Payment hub (under the hood, so it goes dark) */
.co-hub { background: radial-gradient(120% 80% at 50% 0%, color-mix(in srgb, var(--hub-c) 18%, transparent), transparent 60%), #070b12; color: #e8eef7; min-height: 100%; padding: 22px 20px calc(28px + env(safe-area-inset-bottom)); }
@media (min-width: 900px) { .co-hub { padding: 30px 36px; } }
.hub-kicker { margin: 0 0 6px; font: 600 11px/1 ui-monospace, Consolas, monospace; letter-spacing: .12em; text-transform: uppercase; color: var(--hub-c); }
.hub-top h3 { margin: 0; font-size: clamp(17px, 2vw, 21px); font-weight: 600; line-height: 1.35; max-width: 60ch; }
.hub-grid { display: grid; grid-template-columns: 1fr; gap: 18px; margin-top: 18px; }
@media (min-width: 900px) { .hub-grid { grid-template-columns: 1.15fr 1fr; align-items: start; } }
.hub-svg { width: 100%; height: auto; display: block; overflow: visible; }
.hub-spoke { stroke: var(--hub-c); stroke-width: 2; fill: none; stroke-dasharray: 1; stroke-dashoffset: 1; animation: hub-draw 1s cubic-bezier(.2,.7,.2,1) forwards; animation-delay: calc(var(--i) * 90ms); }
.hub-spoke.fee { stroke: #f5c94a; stroke-dasharray: .03 .03; stroke-dashoffset: 0; animation: hub-fade .8s ease both calc(var(--i) * 90ms); }
.hub-spoke.off { stroke: #5b6576; stroke-dasharray: .01 .035; stroke-dashoffset: 0; animation: hub-fade .8s ease both calc(var(--i) * 90ms); }
@keyframes hub-draw { to { stroke-dashoffset: 0; } }
@keyframes hub-fade { from { opacity: 0; } }
.hub-pulse { fill: var(--hub-c); filter: drop-shadow(0 0 6px var(--hub-c)); }
.hub-pulse.fee { fill: #f5c94a; filter: drop-shadow(0 0 6px #f5c94a); }
.hub-node rect { fill: var(--hub-c); }
.hub-node.fee rect { fill: #f5c94a; }
.hub-node.off rect { fill: #3a4252; stroke: #5b6576; }
.hub-node text { fill: #e8eef7; font: 600 14px system-ui, -apple-system, "Segoe UI", sans-serif; }
.hub-node.off text { fill: #8b95a7; }
.hub-centre rect { fill: #0f1724; stroke: var(--hub-c); stroke-width: 2; }
.hub-centre .t1 { fill: #fff; font: 700 15px system-ui, sans-serif; }
.hub-centre .t2 { fill: var(--hub-c); font: 600 12px ui-monospace, Consolas, monospace; }
.hub-glow { animation: hub-breathe 3.2s ease-in-out infinite alternate; transform-origin: center; transform-box: fill-box; }
@keyframes hub-breathe { from { opacity: .5; } to { opacity: 1; } }
.hub-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.hub-list li { display: grid; gap: 2px; padding: 10px 12px; border-radius: 8px; background: rgba(255,255,255,.04); border: 1px solid rgba(255,255,255,.08); border-left: 3px solid var(--hub-c); }
.hub-list li.fee { border-left-color: #f5c94a; }
.hub-list li.off { border-left-color: #5b6576; opacity: .85; }
.hub-state { font: 700 10.5px/1 ui-monospace, Consolas, monospace; letter-spacing: .08em; text-transform: uppercase; color: var(--hub-c); }
.hub-list li.fee .hub-state { color: #f5c94a; } .hub-list li.off .hub-state { color: #8b95a7; }
.hub-list b { font-size: 14.5px; }
.hub-items { font-size: 13.5px; color: #b9c4d4; }
.hub-list small { font-size: 12.5px; color: #8b95a7; }
.hub-note { margin: 12px 0 0; font-size: 14px; color: #c9d4e4; }
.hub-note b { color: #fff; }
.hub-checked { margin: 10px 0 0; font-size: 12px; color: #6f7a8c; }
.hub-checked a { color: inherit; text-decoration: underline; text-underline-offset: 2px; }
.hub-all { margin-top: 6px; }
.hub-all summary { cursor: pointer; font-size: 13px; font-weight: 600; color: #f5c94a; padding: 6px 0; min-height: 32px; display: flex; align-items: center; gap: 6px; list-style: none; }
.hub-all summary::-webkit-details-marker { display: none; }
.hub-all summary::before { content: "+"; display: inline-grid; place-items: center; width: 18px; height: 18px; border: 1px solid currentColor; border-radius: 3px; font-size: 13px; line-height: 1; }
.hub-all[open] summary::before { content: "\2212"; }
.hub-all ol { margin: 4px 0 0; padding: 8px 0 0 0; list-style: none; display: grid; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); column-gap: 18px; align-content: start; max-height: 320px; overflow: auto; overscroll-behavior: contain; border-top: 1px solid rgba(255,255,255,.08); -webkit-overflow-scrolling: touch; }
.hub-list .hub-all li { display: block; padding: 3px 0; margin: 0; border: 0; border-radius: 0; background: none; font-size: 12.5px; color: #b9c4d4; }
.co-flip { margin-top: 18px; min-height: 48px; padding: 0 16px; border: 1px solid rgba(255,255,255,.25); border-radius: 8px; background: rgba(255,255,255,.04); color: #fff; font: 600 14.5px/1 system-ui, sans-serif; cursor: pointer; }
.co-flip:hover { border-color: var(--hub-c); }
@media (prefers-reduced-motion: reduce) {
  .cit-co[open], .ln-sheet[open], .ln-pin { animation: none; }
  .hub-spoke { animation: none; stroke-dashoffset: 0; }
  .hub-glow { animation: none; }
}
/* Fixes: hidden panes stay hidden; nothing in the checkout can be wider than the screen */
.co-pane[hidden] { display: none !important; }
.co-pay { grid-template-columns: minmax(0, 1fr); }
@media (min-width: 900px) { .co-pay { grid-template-columns: minmax(0, .9fr) minmax(0, 1.1fr); } }
.co-summary, .co-methods, .co-card label, .co-card div > label { min-width: 0; }
.co-card input { width: 100%; min-width: 0; box-sizing: border-box; }
.cit-co, .cit-co * { box-sizing: border-box; }
.co-summary li > span { min-width: 0; }
/* Hub labels stay readable when the diagram is phone-sized */
@media (max-width: 600px) {
  .hub-node text { font-size: 25px; }
  .hub-centre .t1 { font-size: 21px; }
  .hub-centre .t2 { font-size: 15px; }
  .hub-centre rect { transform: scale(1.18); transform-origin: center; transform-box: fill-box; }
}
