/* ============================================================
   Mobil Esnaf — telefon çerçevesi, örnek uygulama arayüzü, örnek penceresi
   Uygulamanın içi "em" ile ölçülür: çerçeve büyüdükçe arayüz de büyür.
   ============================================================ */

/* Sektör fotoğrafları (her adres yalnızca burada geçer) */
.ph { background-repeat: no-repeat; background-position: center; background-size: cover; }
.ph-kuruyemis { background-image: url("../img/kuruyemis.webp"); }
.ph-bakkal { background-image: url("../img/bakkal.webp"); }
.ph-cicekci { background-image: url("../img/cicekci.webp"); }
.ph-manav { background-image: url("../img/manav.webp"); }
.ph-pastane { background-image: url("../img/pastane.webp"); }
.ph-su-bayisi { background-image: url("../img/su-bayisi.webp"); }
.ph-kafe { background-image: url("../img/kafe.webp"); }
.ph-kuafor { background-image: url("../img/kuafor.webp"); }
.ph-oto { background-image: url("../img/oto.webp"); }

/* ---------- Telefon ---------- */
.phone { position: relative; flex: none; display: grid; width: 20rem; max-width: 100%; aspect-ratio: 9 / 19; padding: .6rem; border-radius: 3rem; background: #0f1724; box-shadow: inset 0 0 0 2px #3b475a, 0 2.4rem 3.4rem -1.6rem rgb(11 37 69 / .55), 0 1rem 1.5rem -1rem rgb(11 37 69 / .4); }
.phone::before { content: ""; position: absolute; z-index: 4; top: 1.15rem; left: 50%; width: 5.2rem; height: 1.45rem; margin-left: -2.6rem; border-radius: 1rem; background: #0f1724; pointer-events: none; }
.phone-screen { position: relative; display: grid; min-width: 0; min-height: 0; overflow: hidden; border-radius: 2.42rem; background: #f4f2ee; container-type: inline-size; isolation: isolate; }
.win-bar { display: none; }

/* ---------- Uygulama ---------- */
.app {
  --b: #a14b12;
  --b-ink: #fff;
  --b-soft: #f6ede8;
  --b-line: #dfc3b0;
  --b-deep: #a14b12;
  --b-veil: rgb(255 255 255 / .2);
  display: flex;
  flex-direction: column;
  min-width: 0;
  min-height: 0;
  overflow: hidden;
  background: #f4f2ee;
  color: #17202e;
  font: 500 14px/1.4 Inter, system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  letter-spacing: 0;
  text-align: left;
}
@supports (font-size: 1cqw) {
  .app { font-size: clamp(13.5px, 4.5cqw, 16.5px); }
}
.app.is-preview { pointer-events: none; -webkit-user-select: none; user-select: none; }
.app *, .app *::before, .app *::after { box-sizing: border-box; }
.app button { margin: 0; padding: 0; border: 0; background: none; color: inherit; font: inherit; text-align: inherit; cursor: pointer; -webkit-tap-highlight-color: transparent; touch-action: manipulation; }
.app button:disabled { opacity: .45; cursor: default; }
.app :focus-visible { outline: 3px solid #1f54d1; outline-offset: 2px; }
.app h4, .app p, .app ul, .app fieldset, .app legend { margin: 0; padding: 0; border: 0; min-width: 0; }
.app ul { list-style: none; }
.app h4 { font-size: 1em; font-weight: 700; line-height: 1.25; }
.app small, .app .meta { display: block; font-size: .82em; font-weight: 500; color: #667080; }
.app .i { flex: none; width: 1.25em; height: 1.25em; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }

.app-status { flex: none; display: flex; align-items: center; justify-content: space-between; height: 2.55rem; padding: 0 1.7rem; background: var(--b); color: var(--b-ink); font-size: .76rem; font-weight: 700; }
.app-status-r { display: flex; align-items: center; gap: .35rem; }
.app-status svg { height: .68rem; width: auto; fill: currentColor; }

.app-bar { flex: none; display: flex; align-items: center; gap: .7em; padding: .35em .9em .8em; background: var(--b); color: var(--b-ink); }
.app-logo { flex: none; display: grid; place-items: center; width: 2.9em; height: 2.9em; border-radius: .9em; background: var(--b-ink); color: var(--b); font-size: .9em; font-weight: 800; letter-spacing: -.02em; }
.app .app-titles { flex: 1; display: block; min-width: 0; border-radius: .5em; }
.app-name { display: flex; align-items: center; gap: .4em; font-size: 1.12em; font-weight: 750; line-height: 1.25; }
.app-name > span { min-width: 0; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.app .app-name .i { width: .85em; height: .85em; opacity: .75; }
.app-sub { display: block; overflow: hidden; font-size: .8em; white-space: nowrap; text-overflow: ellipsis; opacity: .9; }
.app .app-round { flex: none; position: relative; display: grid; place-items: center; width: 2.7em; height: 2.7em; border-radius: 50%; background: var(--b-veil); }
.app-round b { position: absolute; top: -.35em; right: -.35em; display: grid; place-items: center; min-width: 1.75em; height: 1.75em; padding: 0 .35em; border-radius: 1em; background: var(--b-ink); color: var(--b); font-size: .72em; font-weight: 800; }

/* Dükkân ekranı: koyu başlık, marka rengi vurgu */
.app.v-b:not(.k-stock) .app-status, .app.v-b:not(.k-stock) .app-bar { background: #162032; color: #fff; }
.app.v-b:not(.k-stock) .app-logo { background: var(--b); color: var(--b-ink); }
.app.v-b:not(.k-stock) .app-name .i { display: none; }

.app-body { flex: 1; display: flex; flex-direction: column; gap: .65em; min-height: 0; padding: .8em; overflow-y: auto; overscroll-behavior: contain; -webkit-overflow-scrolling: touch; scrollbar-width: thin; scrollbar-color: #cfc9bf transparent; outline: none; }
.app-body > * { flex: none; }
.app-foot { flex: none; padding: .65em .8em .8em; border-top: 1px solid #e6e1d8; background: #fff; }

.a-title { margin: .35em .2em 0; font-size: .74em; font-weight: 750; letter-spacing: .07em; text-transform: uppercase; color: #667080; }
.banner { position: relative; height: 6.2em; overflow: hidden; border-radius: 1.1em; background-position: center; background-size: cover; }
.banner span { position: absolute; bottom: .7em; left: .7em; padding: .3em .8em; border-radius: 2em; background: #fff; box-shadow: 0 1px 3px rgb(0 0 0 / .16); color: var(--b-deep); font-size: .76em; font-weight: 750; }
.thumb { flex: none; display: block; width: 3.6em; height: 3.6em; border-radius: .9em; background-color: #ece7df; background-repeat: no-repeat; }
.thumb-s { width: 2.9em; height: 2.9em; border-radius: .75em; }

/* Ürün satırı */
.prod { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; align-items: center; gap: .55em .7em; padding: .65em; border-radius: 1.1em; background: #fff; box-shadow: 0 1px 0 #e6e1d8; }
.prod-w .add { grid-column: 3; grid-row: 1; }
.prod-w .chips { grid-column: 1 / -1; grid-row: 2; flex-wrap: nowrap; }
.prod-w .chips .chip { flex: 1; padding-inline: .3em; }
.app .add { display: inline-flex; align-items: center; gap: .4em; min-height: 2.6em; padding: .3em .45em .3em .9em; border-radius: 2em; background: var(--b); color: var(--b-ink); font-size: .92em; font-weight: 750; white-space: nowrap; }
.app .add .i { width: 1.6em; height: 1.6em; padding: .3em; border-radius: 50%; background: var(--b-veil); stroke-width: 2.8; }

.chips { display: flex; flex-wrap: wrap; gap: .4em; }
.app .chip { min-height: 2.5em; padding: .3em .85em; border-radius: 2em; background: #fff; box-shadow: inset 0 0 0 1.5px #d8d2c8; font-size: .86em; font-weight: 650; text-align: center; white-space: nowrap; }
.app .chip.on { background: var(--b-soft); box-shadow: inset 0 0 0 2px var(--b); color: var(--b-deep); }
.app .chip i { margin-left: .15em; font-style: normal; font-weight: 500; opacity: .8; }
.app .chip:disabled { background: #ece9e3; box-shadow: none; text-decoration: line-through; }
.slots { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); }
.app .slots .chip { padding-inline: .2em; }

.stepper { flex: none; display: inline-flex; align-items: center; gap: .15em; padding: .2em; border-radius: 2em; background: var(--b-soft); }
.app .stepper button { display: grid; place-items: center; width: 2.25em; height: 2.25em; border-radius: 50%; background: #fff; box-shadow: 0 1px 2px rgb(0 0 0 / .14); color: var(--b-deep); }
.app .stepper .i { width: 1.05em; height: 1.05em; stroke-width: 2.8; }
.stepper output { min-width: 1.5em; font-weight: 750; font-variant-numeric: tabular-nums; text-align: center; }

.app .cta { display: flex; align-items: center; justify-content: center; gap: .5em; width: 100%; min-height: 3.2em; padding: .6em 1em; border-radius: 1.1em; background: var(--b); color: var(--b-ink); font-weight: 750; text-align: center; }
.app .cartbar { justify-content: flex-start; }
.cartbar b { margin-left: auto; }
.cartbar-n { display: grid; place-items: center; min-width: 1.8em; height: 1.8em; padding: 0 .3em; border-radius: 1em; background: var(--b-ink); color: var(--b); font-size: .86em; font-weight: 800; }
.cartbar.bump { animation: a-bump .4s ease; }
@keyframes a-bump { 40% { transform: scale(1.04); } }
.foot-hint { padding: .6em 0; font-size: .84em; text-align: center; color: #667080; }

.app .card { display: grid; gap: .75em; padding: .75em; border-radius: 1.1em; background: #fff; box-shadow: 0 1px 0 #e6e1d8; }
.line { display: flex; align-items: center; gap: .65em; }
.line-main { flex: 1; display: grid; min-width: 0; }
.line-main b { font-weight: 650; }
.opt legend { margin-bottom: .5em; font-size: .86em; font-weight: 700; }
.opt legend span { font-weight: 500; color: #667080; }
.app-body > .opt { padding: .75em; border-radius: 1.1em; background: #fff; box-shadow: 0 1px 0 #e6e1d8; }
.total { display: flex; align-items: baseline; justify-content: space-between; padding: .2em .4em; font-weight: 650; }
.total b { font-size: 1.3em; font-weight: 800; }

/* Seçenek kartları */
.optcards { display: grid; gap: .45em; }
.app .optcard { display: flex; align-items: center; gap: .65em; width: 100%; padding: .5em .6em; border-radius: .95em; background: #fff; box-shadow: inset 0 0 0 1.5px #e0dbd2; }
.app .optcard.on { background: var(--b-soft); box-shadow: inset 0 0 0 2px var(--b); }
.optcard-main { flex: 1; display: grid; min-width: 0; }
.optcard-main b { font-weight: 700; }
.optcard-price { font-weight: 700; color: var(--b-deep); }
.radio { flex: none; width: 1.3em; height: 1.3em; border-radius: 50%; box-shadow: inset 0 0 0 2px #c9c2b6; }
.optcard.on .radio { background: var(--b); box-shadow: inset 0 0 0 2px var(--b), inset 0 0 0 .34em #fff; }
.app .frow { grid-template-columns: minmax(0, 1fr) auto; align-items: center; }
.frow b { display: block; font-weight: 700; }
.app textarea { display: block; width: 100%; min-height: 4.3em; padding: .65em .75em; border: 0; border-radius: .9em; background: #f4f2ee; box-shadow: inset 0 0 0 1.5px #d8d2c8; color: inherit; font: inherit; resize: none; }
.app textarea::placeholder, .app input::placeholder { color: #7d8794; opacity: 1; }
.notecard { margin-top: .7em; padding: .7em .85em; border-radius: .6em; background: #fffdf6; box-shadow: 0 1px 4px rgb(0 0 0 / .12), inset 0 0 0 1px #efe6d2; transform: rotate(-1deg); }
.notecard p { color: #3a2f25; font: 600 1.12em/1.3 "Bricolage Grotesque", Inter, sans-serif; overflow-wrap: anywhere; }
.notecard.empty p { opacity: .4; }
.app .break { gap: .35em; }
.break div { display: flex; justify-content: space-between; gap: 1em; }

/* Sipariş tamam */
.done { display: grid; justify-items: center; gap: .35em; padding: 1.1em .5em .4em; text-align: center; }
.done-check { display: grid; place-items: center; width: 3.6em; height: 3.6em; border-radius: 50%; background: var(--b); color: var(--b-ink); animation: a-pop .5s cubic-bezier(.2, 1.4, .4, 1); }
.app .done-check .i { width: 1.9em; height: 1.9em; stroke-width: 2.8; }
.app .done h4 { font-size: 1.25em; }
.done p { font-size: .92em; color: #566072; }
@keyframes a-pop { from { opacity: 0; transform: scale(.4); } }
.next { display: grid; gap: .65em; padding: .85em; border-radius: 1.1em; background: var(--b-soft); box-shadow: inset 0 0 0 1.5px var(--b-line); }
.next p { font-size: .92em; }
.app .ghost { min-height: 2.8em; padding: .4em 1em; border-radius: 1em; background: #fff; box-shadow: inset 0 0 0 1.5px #cfc8bc; font-size: .92em; font-weight: 700; text-align: center; }
.app .ghost.wide { width: 100%; }

/* Dükkân ekranı */
.stats { display: grid; grid-template-columns: 1fr 1fr; gap: .6em; }
.stats div { padding: .65em .8em; border-radius: 1em; background: #fff; box-shadow: 0 1px 0 #e6e1d8; }
.stats b { font-size: 1.15em; font-weight: 800; }
.tip { display: grid; gap: .6em; padding: .8em; border-radius: 1.1em; background: #fff8e1; box-shadow: inset 0 0 0 1.5px #f0dfa8; font-size: .92em; }
.ord { display: grid; gap: .5em; padding: .8em; border-radius: 1.1em; background: #fff; box-shadow: 0 1px 0 #e6e1d8; }
.ord.mine { box-shadow: inset 0 0 0 2px var(--b); }
.ord.drop { animation: a-drop .6s cubic-bezier(.2, 1.2, .4, 1); }
@keyframes a-drop { from { opacity: 0; transform: translateY(-1.2em) scale(.96); } }
.ord-head { display: flex; align-items: center; justify-content: space-between; gap: .5em; font-size: .8em; font-weight: 600; color: #667080; }
.ord-who { font-weight: 750; }
.ord-lines li { position: relative; padding-left: .95em; }
.ord-lines li::before { content: ""; position: absolute; top: .56em; left: 0; width: .38em; height: .38em; border-radius: 50%; background: var(--b); }
.ord-tags { display: flex; flex-wrap: wrap; gap: .35em; }
.ord-tags span { padding: .2em .65em; border-radius: 2em; background: #f1eee8; font-size: .8em; font-weight: 650; }
.ord-note { padding: .55em .7em; border-radius: .7em; background: #fffdf6; box-shadow: inset 0 0 0 1px #efe6d2; }
.ord-note p { font: 600 1.04em/1.3 "Bricolage Grotesque", Inter, sans-serif; overflow-wrap: anywhere; }
.ord-foot { display: flex; align-items: center; justify-content: space-between; gap: .6em; padding-top: .15em; }
.ord-foot b { font-size: 1.1em; font-weight: 800; }
.app .ord-act { min-height: 2.5em; padding: .3em .95em; border-radius: 2em; background: var(--b); color: var(--b-ink); font-size: .86em; font-weight: 750; }
.badge { padding: .2em .7em; border-radius: 2em; background: #e9edf3; color: #3b4a5f; font-size: .95em; font-weight: 750; white-space: nowrap; }
.badge.new { background: #ffe1c7; color: #8a3a05; }
.badge.done { background: #dff1e3; color: #1d5b2f; }
.badge.warn { margin-left: auto; background: #ffe0dc; color: #9b2218; font-size: .76em; }

/* Stok programı */
.search { position: sticky; top: 0; z-index: 1; display: flex; align-items: center; gap: .5em; min-height: 3em; padding: 0 .85em; border-radius: 1em; background: #fff; box-shadow: inset 0 0 0 1.5px #d8d2c8, 0 0 0 .5em #f4f2ee; }
.search:focus-within { box-shadow: inset 0 0 0 2px var(--b), 0 0 0 .5em #f4f2ee; }
.app .search .i { color: #667080; }
.app .search input { flex: 1; min-width: 0; padding: .6em 0; border: 0; outline: none; background: none; color: inherit; font: inherit; -webkit-appearance: none; appearance: none; }
.search input::-webkit-search-cancel-button { -webkit-appearance: none; }
.parts { display: grid; gap: .4em; }
.app .part { display: flex; align-items: center; gap: .65em; width: 100%; padding: .5em .6em; border-radius: 1em; background: #fff; box-shadow: 0 1px 0 #e6e1d8; }
.app .part.on { background: var(--b-soft); box-shadow: inset 0 0 0 2px var(--b); }
.part-main { flex: 1; display: grid; min-width: 0; }
.part-main b { overflow: hidden; font-weight: 700; white-space: nowrap; text-overflow: ellipsis; }
.qty { flex: none; min-width: 2.5em; padding: .25em .5em; border-radius: .7em; background: #eef1f5; font-weight: 800; font-variant-numeric: tabular-nums; text-align: center; }
.qty.low { background: #ffe0dc; color: #9b2218; }
.none { padding: 1.2em .5em; text-align: center; color: #667080; }
.det { display: grid; gap: .6em; }
.det-head { display: flex; align-items: center; gap: .65em; }
.det-head b { display: block; font-weight: 750; }
.det-facts { display: grid; grid-template-columns: 1fr 1fr; gap: .5em; }
.det-facts div { padding: .45em .75em .55em; border-radius: .9em; background: var(--b-soft); }
.det-facts strong { display: block; color: var(--b-deep); font: 800 1.75em/1.1 "Bricolage Grotesque", Inter, sans-serif; font-variant-numeric: tabular-nums; }
.det-facts i { color: #566072; font: 600 .5em/1 Inter, sans-serif; }
.det-acts { display: grid; grid-template-columns: 1fr 1fr; gap: .5em; }
.app .det-acts button { display: flex; align-items: center; justify-content: center; gap: .4em; min-height: 3em; border-radius: 1em; background: #fff; box-shadow: inset 0 0 0 1.5px #cfc8bc; font-weight: 750; }
.app .det-acts button:first-child { background: var(--b); box-shadow: none; color: var(--b-ink); }
.app .log { gap: 0; padding: .2em .75em; }
.logrow { display: flex; align-items: center; gap: .7em; padding: .6em 0; border-bottom: 1px solid #eeeae3; }
.logrow:last-child { border-bottom: 0; }
.logrow > div { flex: 1; min-width: 0; }
.logrow b { display: block; font-weight: 700; }
.delta { flex: none; display: grid; place-items: center; min-width: 2.7em; height: 2.2em; border-radius: .7em; background: #ffe0dc; color: #9b2218; font-weight: 800; }
.delta.in { background: #dff1e3; color: #1d5b2f; }
.left { flex: none; font-size: .82em; font-weight: 650; color: #566072; }

/* Geniş çerçevede (bilgisayar programı) liste solda, ayrıntı sağda */
@container (min-width: 560px) {
  .app.k-stock.v-a { display: grid; grid-template-columns: minmax(0, 1fr) 19em; grid-template-rows: auto minmax(0, 1fr); }
  .app.k-stock.v-a .app-bar { grid-column: 1 / -1; }
  .app.k-stock.v-a .app-foot { padding: 1em; overflow-y: auto; border-top: 0; border-left: 1px solid #e6e1d8; }
  .app.k-stock .det { gap: .85em; }
}

/* ============================================================
   Örnek penceresi
   ============================================================ */
dialog.demo { width: min(66rem, calc(100vw - 2.5rem)); height: min(47rem, calc(100vh - 2.5rem)); height: min(47rem, calc(100dvh - 2.5rem)); max-width: none; max-height: none; margin: auto; padding: 0; overflow: hidden; border: 2px solid var(--ink); border-radius: 1.75rem; background: var(--cream); color: var(--ink); }
dialog.demo::backdrop { background: rgb(7 26 51 / .76); }
dialog.demo[open] { animation: demo-in .28s cubic-bezier(.2, .9, .3, 1); }
@keyframes demo-in { from { opacity: 0; transform: translateY(1.2rem) scale(.98); } }
.demo-shell { position: relative; display: grid; grid-template-columns: minmax(0, 1fr) 24rem; grid-template-rows: minmax(0, 1fr); height: 100%; }

.demo-stage { grid-column: 1; grid-row: 1; display: flex; align-items: center; justify-content: center; min-width: 0; min-height: 0; padding: 1.5rem; overflow: hidden; border-right: 2px solid var(--ink); background: var(--tint, #f7d6b5); transition: background-color .3s ease; }
.demo-stage .phone { width: auto; height: 100%; max-height: 44rem; }

.demo-side { grid-column: 2; grid-row: 1; display: flex; flex-direction: column; gap: .9rem; min-height: 0; padding: 1.4rem 1.5rem 1.15rem; overflow-y: auto; }
.demo-x { position: absolute; z-index: 6; top: .9rem; right: .9rem; display: grid; place-items: center; width: 2.75rem; height: 2.75rem; padding: 0; border: 2px solid var(--ink); border-radius: 50%; background: #fff; box-shadow: 0 3px 0 var(--ink); font-size: 1.05rem; }
.demo-head { display: grid; gap: .45rem; padding-right: 3rem; }
.demo-head h2 { font-size: 2rem; }
.demo-head p:not(.eyebrow) { font-size: .98rem; line-height: 1.5; color: var(--ink-2); }

.seg { display: grid; grid-template-columns: 1fr 1fr; padding: .22rem; border: 2px solid var(--ink); border-radius: 999px; background: #fff; }
.seg button { min-height: 2.5rem; padding: .2rem .6rem; border: 0; border-radius: 999px; background: none; font-size: .9rem; font-weight: 700; line-height: 1.15; -webkit-tap-highlight-color: transparent; }
.seg button[aria-pressed="true"] { background: var(--ink); color: #fff; }
.demo-edit { display: none; }

.demo-brand { display: grid; gap: .55rem; padding: .8rem .9rem .9rem; border: 2px solid var(--ink); border-radius: 1.1rem; background: #fff; }
.demo-brand label { font-size: .95rem; font-weight: 750; line-height: 1.3; }
.demo-brand label span { display: block; font-size: .84rem; font-weight: 500; color: var(--ink-2); }
.demo-brand input { width: 100%; height: 2.9rem; padding: 0 .8rem; border: 2px solid var(--ink); border-radius: .8rem; background: var(--cream); font: 800 1.1rem/1 var(--display); letter-spacing: -.01em; }
.demo-brand input::placeholder { color: #98a1ae; font-weight: 600; opacity: 1; }
.demo-brand input:focus { outline: none; background: #fff; box-shadow: 0 0 0 3px var(--orange); }
.swatches { display: flex; flex-wrap: wrap; gap: .5rem; }
.swatch { width: 2rem; height: 2rem; padding: 0; border: 2px solid var(--ink); border-radius: 50%; background: var(--c); -webkit-tap-highlight-color: transparent; }
.swatch[aria-checked="true"] { box-shadow: 0 0 0 2px #fff, 0 0 0 4.5px var(--ink); }
.brand-ok { display: none; }
.demo.is-done .demo-cta .btn { animation: cta-pulse 1.4s ease 2; }
@keyframes cta-pulse { 50% { transform: translateY(-3px); box-shadow: 0 7px 0 var(--ink); } }
@keyframes nudge { 0%, 100% { transform: none; } 30% { transform: scale(1.18) rotate(-8deg); } 60% { transform: scale(1.1) rotate(6deg); } }

.demo-steps > p { margin-bottom: .55rem; font-size: .78rem; font-weight: 750; letter-spacing: .08em; text-transform: uppercase; color: var(--ink-2); }
.demo-steps ol { display: grid; gap: .5rem; }
.demo-steps li { display: flex; align-items: flex-start; gap: .6rem; font-size: .92rem; line-height: 1.38; }
.demo-steps li::before { content: attr(data-n); flex: none; display: grid; place-items: center; width: 1.55rem; height: 1.55rem; border: 2px solid var(--ink); border-radius: 50%; background: #fff; font-size: .76rem; font-weight: 800; line-height: 1; }
.demo-steps li[data-current] { font-weight: 650; }
.demo-steps li[data-current]::before { background: var(--orange); }
.demo-steps li[data-done] { color: var(--ink-2); }
.demo-steps li[data-done]::before { content: "✓"; background: var(--green); }
.demo-steps li.fin { display: none; padding: .7rem .8rem; border: 2px solid var(--ink); border-radius: .9rem; background: var(--orange-soft); font-weight: 650; }
.demo-steps li.fin::before { background: var(--orange); }
.demo-steps li.fin[data-current] { display: flex; }

.demo-cta { display: grid; gap: .5rem; margin-top: auto; padding-top: .3rem; }
.demo-later { justify-self: center; padding: .3rem .4rem; font-size: .92rem; font-weight: 650; text-decoration: underline; text-underline-offset: .22em; text-decoration-thickness: 1.5px; }
.fine { font-size: .78rem; line-height: 1.45; text-align: center; color: var(--ink-2); }

/* Bilgisayar programı çerçevesi (yalnızca geniş ekranda) */
@media (min-width: 68.75rem) and (min-height: 37rem) {
  .demo-stage .phone.as-window { display: flex; flex-direction: column; width: 100%; max-width: 44rem; height: auto; max-height: 100%; aspect-ratio: 4 / 3; padding: 0; overflow: hidden; border: 2px solid var(--ink); border-radius: .9rem; background: #fff; box-shadow: 8px 8px 0 rgb(11 37 69 / .22); }
  .phone.as-window::before { display: none; }
  .phone.as-window .win-bar { flex: none; display: flex; align-items: center; gap: .55rem; padding: .45rem .7rem; border-bottom: 2px solid var(--ink); background: #e9edf3; color: #2c3a4e; font: 650 .8rem/1 Inter, sans-serif; }
  .win-bar b { display: grid; place-items: center; width: 1.3rem; height: 1.3rem; border-radius: .35rem; background: var(--ink); color: #fff; font-size: .52rem; font-weight: 800; }
  .win-bar span { flex: 1; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
  .win-bar i { width: .8rem; height: .8rem; border: 1.5px solid #6b7a8f; border-radius: .2rem; }
  .win-bar i:first-of-type { height: 0; border-width: 1.5px 0 0; border-radius: 0; align-self: flex-end; margin-bottom: .1rem; }
  .win-bar i:last-of-type { border-color: #b3261e; background: #f2b8b5; }
  .phone.as-window .phone-screen { flex: 1; border-radius: 0; }
  .phone.as-window .app { font-size: 14.5px; }
  .phone.as-window .app-status { display: none; }
  .phone.as-window .app-bar { padding-top: .7em; }
}

/* Telefon ve tablet: örnek tam ekran açılır, gerçek bir uygulama gibi */
@media (max-width: 53.74rem) {
  dialog.demo { width: 100vw; height: 100vh; height: 100dvh; margin: 0; border: 0; border-radius: 0; background: #f4f2ee; }
  dialog.demo[open] { animation: demo-up .26s cubic-bezier(.2, .9, .3, 1); }
  @keyframes demo-up { from { opacity: 0; transform: translateY(5%); } }
  .demo-shell { grid-template-columns: auto minmax(0, 1fr) auto; grid-template-rows: auto auto minmax(0, 1fr) auto; }
  .demo-shell::before { content: ""; grid-column: 1 / -1; grid-row: 1; background: var(--navy); }
  .demo-side { display: contents; }

  .demo-x { position: static; grid-column: 1; grid-row: 1; align-self: center; width: 2.5rem; height: 2.5rem; margin: .5rem .25rem .5rem .6rem; border-color: transparent; background: rgb(255 255 255 / .14); box-shadow: none; color: #fff; }
  .seg { grid-column: 2; grid-row: 1; align-self: center; justify-self: center; width: min(100%, 19rem); margin: .5rem 0; border-color: transparent; background: rgb(255 255 255 / .14); }
  .seg button { min-height: 2.2rem; color: #fff; font-size: .82rem; }
  .seg button[aria-pressed="true"] { background: #fff; color: var(--ink); }
  .demo-edit { grid-column: 3; grid-row: 1; align-self: center; display: grid; place-items: center; width: 2.5rem; height: 2.5rem; margin: .5rem .6rem .5rem .25rem; padding: 0; border: 0; border-radius: 50%; background: var(--orange); color: var(--ink); font-size: 1rem; }
  .demo-head { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }

  .demo-steps { grid-column: 1 / -1; grid-row: 2; padding: .5rem .9rem; border-bottom: 2px solid var(--ink); background: var(--orange-soft); }
  .demo-steps > p { display: none; }
  .demo-steps li { display: none; font-size: .88rem; line-height: 1.3; }
  .demo-steps li[data-current] { display: flex; align-items: center; }
  .demo-steps li.fin { padding: 0; border: 0; background: none; }

  .demo-stage { grid-column: 1 / -1; grid-row: 3; padding: 0; border: 0; background: none; }
  .demo-stage .phone { width: 100%; height: 100%; max-height: none; aspect-ratio: auto; padding: 0; border-radius: 0; background: none; box-shadow: none; }
  .demo-stage .phone::before, .demo-stage .app-status { display: none; }
  .demo-stage .phone-screen { border-radius: 0; }
  .demo-stage .app-bar { padding-top: .75em; }
  .demo-stage .app textarea, .demo-stage .app input { font-size: 16px; }

  .demo-cta { grid-column: 1 / -1; grid-row: 4; margin: 0; padding: .6rem .9rem max(.7rem, env(safe-area-inset-bottom)); border-top: 2px solid var(--ink); background: #fff; }
  .demo-cta .btn { min-height: 3.1rem; }
  .demo-later, .fine { display: none; }

  .demo-brand { position: absolute; z-index: 7; top: 3.7rem; right: .6rem; left: .6rem; display: none; box-shadow: 0 6px 0 var(--ink), 0 0 0 100vmax rgb(7 26 51 / .45); }
  .demo-brand.open { display: grid; }
  .brand-ok { display: inline-flex; justify-self: end; }
  .demo-edit.nudge { animation: nudge 1.1s ease 1.2s 2; }
}
