/* /demo — the try-it page around the real till screen. Smart Kassa colours, site fonts. */
:root { --green-d: #0F3D2E; --green: #1E8A4C; --green-l: #39B54A; --yellow: #FFD23F; --ink: #0B1F17; --line: rgba(255,255,255,.14); }
* { box-sizing: border-box; }
html, body { margin: 0; height: 100%; }
body.demo-page { font-family: 'Plus Jakarta Sans', system-ui, sans-serif; background: #0B2E23; color: #fff; display: flex; flex-direction: column; min-height: 100vh; }
[dir="rtl"] body.demo-page, html[lang="ar"] body.demo-page { font-family: 'Tajawal', 'Plus Jakarta Sans', system-ui, sans-serif; }

.demo-bar { position: sticky; top: 0; z-index: 5; display: flex; align-items: center; gap: 10px; padding: 8px 14px; height: 52px; background: var(--green-d); border-bottom: 1px solid var(--line); }
.demo-logo { display: inline-flex; align-items: center; gap: 8px; color: #fff; text-decoration: none; font-family: 'Archivo Black', sans-serif; font-size: 17px; }
.demo-logo img { filter: brightness(0) invert(1); }
.demo-flag { display: inline-flex; align-items: center; gap: 8px; padding: 6px 12px; border-radius: 999px; background: var(--yellow); color: var(--ink); font-weight: 800; font-size: 13px; white-space: nowrap; }
.demo-flag i { width: 8px; height: 8px; border-radius: 50%; background: #D2381F; box-shadow: 0 0 0 3px rgba(210,56,31,.25); }
.demo-sp { flex: 1; }
.demo-btn { display: inline-flex; align-items: center; justify-content: center; gap: 6px; height: 36px; padding: 0 14px; border-radius: 999px; font: inherit; font-weight: 700; font-size: 14px; text-decoration: none; cursor: pointer; border: 1px solid transparent; white-space: nowrap; }
.demo-primary { background: var(--green-l); color: #062015; }
.demo-primary:hover { background: #4cc75c; }
.demo-ghost { background: transparent; color: #fff; border-color: rgba(255,255,255,.3); }
.demo-ghost:hover { background: rgba(255,255,255,.08); }
.demo-btn:focus-visible, .demo-x:focus-visible { outline: 3px solid var(--yellow); outline-offset: 2px; }

.demo-main { flex: 1; display: flex; min-height: 0; }
.demo-stage { position: relative; flex: 1; display: flex; }
#demo-till { flex: 1; width: 100%; height: calc(100vh - 52px); border: 0; display: block; background: #f4f1ea; }
.demo-tip { position: absolute; inset-inline-end: 18px; bottom: 96px; width: 300px; padding: 16px 18px; border-radius: 16px; background: #fff; color: var(--ink); box-shadow: 0 18px 40px rgba(0,0,0,.28); font-size: 14px; line-height: 1.45; }
.demo-tip[hidden] { display: none; }
.demo-tip b { display: block; font-size: 15px; margin-bottom: 6px; }
.demo-tip ol { margin: 0 0 12px; padding-inline-start: 18px; }
.demo-tip li { margin: 3px 0; }

.demo-phone { display: none; padding: 24px 16px 40px; max-width: 640px; margin: 0 auto; }
.demo-phone h1 { font-size: 24px; line-height: 1.25; margin: 0 0 8px; }
.demo-phone p { color: rgba(255,255,255,.82); line-height: 1.5; }
.demo-shots { display: grid; gap: 14px; margin: 18px 0; }
.demo-shots figure { margin: 0; background: #fff; border-radius: 14px; overflow: hidden; }
.demo-shots img { display: block; width: 100%; height: auto; }
.demo-shots figcaption { color: var(--ink); font-weight: 700; font-size: 14px; padding: 10px 12px; }
.demo-phone-cta { display: flex; gap: 10px; flex-wrap: wrap; }

.demo-dialog { position: fixed; inset: 0; z-index: 20; display: grid; place-items: center; background: rgba(4,18,12,.55); padding: 16px; }
.demo-dialog[hidden] { display: none; }
.demo-dialog-in { width: min(380px, 100%); max-height: calc(100vh - 32px); overflow: auto; background: #fff; color: var(--ink); border-radius: 16px; padding: 16px 18px 18px; box-shadow: 0 24px 60px rgba(0,0,0,.35); display: flex; flex-direction: column; gap: 10px; }
.demo-dialog-in header { display: flex; align-items: center; justify-content: space-between; }
.demo-dialog-in h2 { margin: 0; font-size: 18px; }
.demo-x { border: 0; background: #F1EFE8; width: 34px; height: 34px; border-radius: 50%; cursor: pointer; font-size: 15px; }
.demo-note { margin: 0; font-size: 13px; color: #5b6660; }
.demo-receipt { font-family: ui-monospace, 'Cascadia Mono', Consolas, monospace; font-size: 12.5px; background: #FFFDF6; border: 1px dashed #c9c3b2; border-radius: 8px; padding: 14px 12px; direction: ltr; text-align: left; }
.rc-head { text-align: center; display: flex; flex-direction: column; gap: 2px; margin-bottom: 8px; }
.rc-head b { font-size: 14px; }
.rc-kind { text-align: center; font-weight: 700; margin: 4px 0; }
.rc-meta { display: flex; justify-content: space-between; gap: 6px; flex-wrap: wrap; color: #555; border-bottom: 1px dashed #c9c3b2; padding-bottom: 6px; margin-bottom: 6px; }
.rc-line, .rc-sub, .rc-total { display: flex; justify-content: space-between; gap: 8px; }
.rc-line { margin: 4px 0; }
.rc-line small { display: block; color: #666; }
.rc-sub { color: #1E8A4C; font-size: 12px; }
.rc-total { border-top: 1px dashed #c9c3b2; margin-top: 8px; padding-top: 6px; font-weight: 800; font-size: 15px; }
.rc-foot { text-align: center; margin: 10px 0 0; color: #555; }
.rc-demo { text-align: center; margin: 4px 0 0; letter-spacing: .3em; font-weight: 800; color: #D2381F; }

.demo-toast { position: fixed; z-index: 30; bottom: 18px; left: 50%; transform: translateX(-50%); background: var(--ink); color: #fff; padding: 12px 18px; border-radius: 12px; box-shadow: 0 12px 30px rgba(0,0,0,.3); max-width: calc(100% - 32px); }
.demo-toast[hidden] { display: none; }

/* tablets: room is tight, keep the essentials */
@media (max-width: 1100px) { .demo-lang { display: none; } .demo-tip { bottom: 84px; } }
@media (max-width: 900px) { .demo-logo span { display: none; } .demo-bar .demo-ghost:not(.demo-lang) { display: none; } }
/* phones: the till is made for a till screen — pictures instead */
@media (max-width: 759px) {
  .demo-bar { height: auto; flex-wrap: wrap; padding: 10px 16px; }
  .demo-bar .demo-ghost:not(.demo-lang) { display: none; }
  .demo-stage { display: none; }
  .demo-phone { display: block; }
}
@media (prefers-reduced-motion: no-preference) { .demo-btn { transition: background .15s; } }
/* language button (same as the site) */
.lsw { position: relative; }
.lsw summary { list-style: none; display: inline-flex; align-items: center; gap: 7px; height: 40px; padding: 0 10px 0 7px; border-radius: 999px; background: #fff; border: 1px solid #E4E7EC; box-shadow: 0 1px 2px rgba(16, 24, 40, .06); font: 800 13px "Plus Jakarta Sans", system-ui, sans-serif; color: #101828; cursor: pointer; user-select: none; }
.lsw summary::-webkit-details-marker { display: none; }
.lsw summary:hover { border-color: #D0D5DD; }
.lsw summary:focus-visible { outline: 3px solid rgba(30, 138, 76, .35); outline-offset: 2px; }
.lsw-flag { width: 24px; height: 24px; flex: none; border-radius: 50%; stroke: none; stroke-width: 0; }
.lsw-chev { width: 15px; height: 15px; color: #667085; transition: transform .2s; }
.lsw[open] .lsw-chev { transform: rotate(180deg); }
.lsw-menu { position: absolute; top: calc(100% + 8px); inset-inline-end: 0; z-index: 80; min-width: 190px; padding: 6px; display: grid; gap: 2px; border-radius: 14px; background: #fff; border: 1px solid #EAECF0; box-shadow: 0 18px 44px -12px rgba(16, 24, 40, .22); animation: lsw-in .14s ease-out; }
.lsw-menu a { display: flex; align-items: center; gap: 10px; padding: 9px 10px; border-radius: 10px; font: 600 14px "Plus Jakarta Sans", system-ui, sans-serif; color: #344054; text-decoration: none; }
.lsw-menu a[lang="ar"] span { font-family: "Tajawal", "Plus Jakarta Sans", sans-serif; font-weight: 700; }
.lsw-menu a:hover { background: #F2F4F7; }
.lsw-menu a.on { background: #FFF8DB; color: #101828; }
.lsw-menu a span { flex: 1; }
.lsw-check { width: 17px; height: 17px; color: #1E8A4C; flex: none; }
@keyframes lsw-in { from { opacity: 0; transform: translateY(-4px); } to { opacity: 1; transform: none; } }
@media (prefers-reduced-motion: reduce) { .lsw-menu { animation: none; } .lsw-chev { transition: none; } }
.demo-lsw summary { height: 36px; }
