/* SAHNE · İNDİRİM VE BURS (includes/scenes/discount.php) — bento + modül sayfası sahnesi, adımlar:
   s1 Kardeş İndirimi (%10) · s2 Peşin Ödeme İndirimi (%8, sıralı: kalan tutara) · s3 Yönetim Kurulu İndirimi →
   Onay bekliyor, Aşama 1/2 · s4 Aşama 2/2 · s5 Onaylı. Net ileri sayar: 195.000,00 → 141.460,00 ₺.
   Küçük düzen (<440 px kap, ana sayfa bento kutusu) 216 px; büyük düzen (≥440, modül sayfası) 396 px. */
@property --dsc-ik { syntax: '<integer>'; inherits: false; initial-value: 0; }
@property --dsc-ir { syntax: '<integer>'; inherits: false; initial-value: 0; }
@property --dsc-nk { syntax: '<integer>'; inherits: false; initial-value: 0; }
@property --dsc-nr { syntax: '<integer>'; inherits: false; initial-value: 0; }
@counter-style dsc-pad3 { system: extends decimal; pad: 3 "0"; }
.dsc { container-type: inline-size; }
.dsc-win { display: flex; flex-direction: column; height: 216px; border-radius: 12px;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .7), 0 1px 2px rgba(16, 37, 64, .07), 0 6px 14px -6px rgba(16, 37, 64, .14), 0 22px 44px -24px rgba(16, 37, 64, .34); }
.dsc svg { fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }

/* başlık bandı: öğrenci + şube · ürün satırı + tutarı */
.dsc-head { flex: none; display: flex; align-items: center; gap: 8px; height: 40px; padding: 0 12px; color: #fff;
  background: linear-gradient(120deg, var(--navy-night), var(--navy) 55%, var(--navy-soft)); box-shadow: inset 0 -1px 0 rgba(255, 255, 255, .08); }
.dsc-av { flex: none; display: grid; place-items: center; width: 26px; height: 26px; border-radius: 8px; font-size: 10.5px; font-weight: 800; letter-spacing: .02em; color: var(--navy); background: #dbe7f6; box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .5), 0 1px 2px rgba(0, 0, 0, .2); }
.dsc-who { flex: 1; min-width: 0; display: flex; flex-direction: column; line-height: 1.2; }
.dsc-who b { font-size: 12.5px; font-weight: 800; letter-spacing: -.01em; white-space: nowrap; }
.dsc-who small { display: flex; align-items: center; gap: 5px; font-size: 10px; font-weight: 600; color: rgba(255, 255, 255, .8); white-space: nowrap; }
.dsc-cls { padding: 0 5px; border-radius: 999px; font-weight: 800; color: #fff; background: rgba(255, 255, 255, .16); line-height: 14px; }
.dsc-sch { display: none; }
.dsc-gross { flex: none; display: flex; flex-direction: column; align-items: flex-end; line-height: 1.2; }
.dsc-gross small { font-size: 10px; font-weight: 600; color: rgba(255, 255, 255, .8); white-space: nowrap; }
.dsc-gross b { font-size: 12.5px; font-weight: 800; white-space: nowrap; font-variant-numeric: tabular-nums; }

/* uygulanan indirimler */
.dsc-list { position: relative; flex: 1; min-height: 0; display: grid; grid-template-rows: 30px 30px 44px; row-gap: 4px; align-content: start; padding: 8px 10px 0; }
.dsc-cap { display: none; }
.dsc-row { position: relative; display: grid; grid-template-columns: 20px minmax(0, 1fr) auto; column-gap: 8px; align-items: center; padding: 0 9px 0 5px; border-radius: 8px; background: #fff;
  box-shadow: inset 0 0 0 1px var(--ui-line), 0 1px 2px rgba(16, 37, 64, .05);
  opacity: 0; transform: translateY(-6px) scale(.98); transition: opacity .3s var(--ui-ease), transform .5s cubic-bezier(.34, 1.56, .64, 1), box-shadow .4s var(--ui-ease); }
.dsc-ic { display: grid; place-items: center; width: 20px; height: 20px; border-radius: 6px; color: #e11d48; background: #fdecef; box-shadow: inset 0 0 0 1px #f9d3da; }
.dsc-ic svg { width: 11px; height: 11px; }
/* ad + (oran) tek satırda, kayıt ekranındaki gibi */
.dsc-txt { min-width: 0; display: flex; align-items: baseline; gap: 4px; line-height: 1.22; white-space: nowrap; }
.dsc-txt b { font-size: 11px; font-weight: 800; color: var(--ui-text); }
.dsc-txt small { font-size: 10.5px; font-weight: 600; color: var(--ui-muted); }
.dsc-amt { font-size: 11px; font-weight: 800; color: #be123c; white-space: nowrap; font-variant-numeric: tabular-nums; }

/* yönetim kurulu satırı: iki satır (ad + tutar · durum ve aşama çipleri) */
.dsc-r3 { grid-template-rows: auto auto; row-gap: 4px; align-content: center; }
.dsc-r3 .dsc-ic { grid-row: 1 / span 2; align-self: start; margin-top: 1px; }
.dsc-tags { grid-column: 2 / span 2; display: flex; align-items: center; gap: 5px; min-width: 0; }
.dsc-sw { position: relative; display: inline-grid; }
.dsc-sw > * { grid-area: 1 / 1; justify-self: start; }
.dsc-pill, .dsc-stage { flex: none; display: inline-flex; align-items: center; gap: 3px; height: 16px; max-width: 96px; padding: 0 6px; border-radius: 999px; font-size: 10px; font-weight: 800; white-space: nowrap; overflow: hidden;
  transition: opacity .3s var(--ui-ease), transform .4s cubic-bezier(.34, 1.56, .64, 1), max-width .45s var(--ui-ease), padding .45s var(--ui-ease), margin .45s var(--ui-ease), box-shadow .3s var(--ui-ease); }
.dsc-stage { max-width: 200px; }
/* değiş-tokuş: giden çip daralıp söner, gelen genişleyip belirir (display ile ani geçiş yok) */
.dsc-pill--ok, .dsc-stage--2 { max-width: 0; padding: 0; margin-left: -5px; opacity: 0; transform: scale(.7); }
.dsc-pill svg, .dsc-stage svg { flex: none; width: 10px; height: 10px; stroke-width: 2.4; }
.dsc-pill--wait { color: #92400e; background: #fdefd9; box-shadow: inset 0 0 0 1px #f7dcae; }
.dsc-pill--ok { color: #166534; background: #dcf3e4; box-shadow: inset 0 0 0 1px #b9e5c8; }
.dsc-stage { color: #1d4f86; background: #e1ecfb; box-shadow: inset 0 0 0 1px #c9daf3; }

/* «+ İndirim ekle» (kesik çizgili kutu) sıradaki boş yuvada durur */
.dsc-add { position: absolute; left: 10px; right: 10px; top: 8px; height: 30px; display: flex; align-items: center; justify-content: center; gap: 4px; border-radius: 8px; font-size: 10.5px; font-weight: 800; color: var(--navy-soft);
  border: 1px dashed #b6c4d6; background: rgba(240, 244, 250, .6); transition: transform .55s cubic-bezier(.34, 1.3, .64, 1), opacity .3s var(--ui-ease); }
.dsc-add svg { width: 11px; height: 11px; stroke-width: 2.4; }

/* alt şerit: indirim toplamı + net (ileri sayar, kuruşlu) */
.dsc-foot { flex: none; display: flex; align-items: center; justify-content: space-between; height: 38px; padding: 0 12px; border-top: 1px solid var(--ui-line); background: var(--ui-bg-2); }
.dsc-sum { display: flex; flex-direction: column; line-height: 1.2; }
.dsc-sum small { font-size: 10px; font-weight: 700; color: var(--ui-muted); }
.dsc-sum b { font-weight: 800; white-space: nowrap; font-variant-numeric: tabular-nums; }
.dsc-sum--ind b { font-size: 11.5px; color: #be123c; transition: opacity .3s var(--ui-ease); }
.dsc-sum--net { align-items: flex-end; }
.dsc-sum--net b { font-size: 15px; color: var(--navy); letter-spacing: -.01em; }
.dsc-none { color: var(--ui-muted) !important; }
.dsc-n--ind { opacity: 0; }
.dsc-n { transition: --dsc-ik .8s var(--ui-ease), --dsc-ir .8s var(--ui-ease), --dsc-nk .8s var(--ui-ease), --dsc-nr .8s var(--ui-ease), opacity .3s var(--ui-ease); }
.dsc-n--ind { --dsc-ik: 0; --dsc-ir: 0; counter-reset: dsc-ik var(--dsc-ik) dsc-ir var(--dsc-ir); }
.dsc-n--ind::after { content: "−\00a0" counter(dsc-ik) "." counter(dsc-ir, dsc-pad3) ",00\00a0₺"; }
.dsc-n--net { --dsc-nk: 195; --dsc-nr: 0; counter-reset: dsc-nk var(--dsc-nk) dsc-nr var(--dsc-nr); }
.dsc-n--net::after { content: counter(dsc-nk) "." counter(dsc-nr, dsc-pad3) ",00\00a0₺"; }

/* ── ADIMLAR ── */
/* s1: Kardeş İndirimi %10 → − 19.500 */
.dsc.s1 .dsc-r1 { opacity: 1; transform: none; }
.dsc.s1 .dsc-add { transform: translateY(34px); }
.dsc.s1 .dsc-none { opacity: 0; }
.dsc.s1 .dsc-n--ind { opacity: 1; --dsc-ik: 19; --dsc-ir: 500; }
.dsc.s1 .dsc-n--net { --dsc-nk: 175; --dsc-nr: 500; }
/* s2: Peşin Ödeme %8 — aynı grup, sıralı: kalan 175.500'e → − 14.040 */
.dsc.s2 .dsc-r2 { opacity: 1; transform: none; }
.dsc.s2 .dsc-add { transform: translateY(68px); }
.dsc.s2 .dsc-n--ind { --dsc-ik: 33; --dsc-ir: 540; }
.dsc.s2 .dsc-n--net { --dsc-nk: 161; --dsc-nr: 460; }
/* s3: Yönetim Kurulu İndirimi — onay akışına düşer (bekleyen indirim de kayıtta uygulanmıştır) */
.dsc.s3 .dsc-r3 { opacity: 1; transform: none; transition-delay: .1s; }
.dsc.s3 .dsc-add { opacity: 0; transform: translateY(80px) scale(.96); }
.dsc.s3 .dsc-n--ind { --dsc-ik: 53; --dsc-ir: 540; }
.dsc.s3 .dsc-n--net { --dsc-nk: 141; --dsc-nr: 460; }
/* s4: akış ikinci aşamaya geçer (Muhasebe Müdürü → Genel Müdür) */
.dsc.s4 .dsc-stage--1 { max-width: 0; padding: 0; margin-left: -5px; opacity: 0; transform: scale(.85); }
.dsc.s4 .dsc-stage--2 { max-width: 200px; padding: 0 6px; margin-left: 0; opacity: 1; transform: none; transition-delay: .1s; }
.dsc.s4:not(.s5) .dsc-stage--2 { box-shadow: inset 0 0 0 1px #9dbbe6, 0 0 0 2px rgba(29, 79, 134, .18); }
/* s5: onaylandı */
.dsc.s5 .dsc-pill--wait { max-width: 0; padding: 0; margin-left: -5px; opacity: 0; transform: scale(.85); }
.dsc.s5 .dsc-pill--ok { max-width: 96px; padding: 0 6px; margin-left: 0; opacity: 1; transform: none; transition-delay: .1s; }
.dsc.s5 .dsc-stage--2 { opacity: 0; max-width: 0; padding: 0; margin-left: -5px; transition-delay: .3s; }
.dsc.s5 .dsc-r3 { box-shadow: inset 0 0 0 1px #b9e5c8, 0 1px 2px rgba(16, 37, 64, .05), 0 0 0 3px rgba(21, 128, 61, .08); }

/* ── DAR / GENİŞ KAPLAR ── */
/* büyük düzen (modül sayfası 440 px kabı, ana sayfada tek sütun): 396 px, «Uygulanan indirimler» başlığı, okul adı,
   «İndirim ekle» kutusu s3'te de görünür kalır */
@container (min-width: 440px) {
  .dsc-win { height: 396px; border-radius: 14px; }
  .dsc-head { gap: 10px; height: 60px; padding: 0 16px; }
  .dsc-av { width: 36px; height: 36px; border-radius: 10px; font-size: 13px; }
  .dsc-who { gap: 3px; }
  .dsc-who b { font-size: 15px; }
  .dsc-who small { gap: 6px; font-size: 11px; }
  .dsc-cls { padding: 0 6px; line-height: 16px; }
  .dsc-sch { display: inline; }
  .dsc-gross { gap: 3px; }
  .dsc-gross small { font-size: 11px; }
  .dsc-gross b { font-size: 15px; }
  .dsc-list { grid-template-rows: 16px 44px 44px 68px; row-gap: 8px; padding: 16px 16px 0; }
  .dsc-cap { display: block; padding-left: 2px; font-size: 10.5px; font-weight: 800; line-height: 16px; letter-spacing: .05em; text-transform: uppercase; color: #be123c; }
  .dsc-row { grid-template-columns: 28px minmax(0, 1fr) auto; column-gap: 10px; padding: 0 14px 0 8px; border-radius: 10px; }
  .dsc-ic { width: 28px; height: 28px; border-radius: 8px; }
  .dsc-ic svg { width: 14px; height: 14px; }
  .dsc-txt { gap: 5px; }
  .dsc-txt b { font-size: 13px; }
  .dsc-txt small { font-size: 12px; }
  .dsc-amt { font-size: 13px; }
  .dsc-r3 { row-gap: 6px; }
  .dsc-r3 .dsc-ic { margin-top: 0; }
  .dsc-tags { gap: 6px; }
  .dsc-pill, .dsc-stage { gap: 4px; height: 20px; padding: 0 8px; font-size: 11px; }
  .dsc-pill--ok, .dsc-stage--2 { padding: 0; margin-left: -6px; }
  .dsc.s4 .dsc-stage--1, .dsc.s5 .dsc-pill--wait, .dsc.s5 .dsc-stage--2 { padding: 0; margin-left: -6px; }
  .dsc.s4 .dsc-stage--2, .dsc.s5 .dsc-pill--ok { padding: 0 8px; margin-left: 0; }
  .dsc.s5 .dsc-pill--ok { max-width: 110px; }
  .dsc-pill svg, .dsc-stage svg { width: 12px; height: 12px; }
  .dsc-add { left: 16px; right: 16px; top: 40px; height: 40px; gap: 6px; border-radius: 10px; font-size: 12px; }
  .dsc-add svg { width: 13px; height: 13px; }
  .dsc.s1 .dsc-add { transform: translateY(52px); }
  .dsc.s2 .dsc-add { transform: translateY(104px); }
  .dsc.s3 .dsc-add { opacity: 1; transform: translateY(180px); }
  .dsc-foot { height: 60px; padding: 0 16px; }
  .dsc-sum { gap: 2px; }
  .dsc-sum small { font-size: 11px; }
  .dsc-sum--ind b { font-size: 14px; }
  .dsc-sum--net b { font-size: 19px; }
}
/* çok geniş kap (ana sayfa 768–860 px görünüm, tek sütun): pencere yassı şeride dönmesin */
@container (min-width: 560px) {
  .dsc-win { max-width: 520px; margin-inline: auto; }
}
@container (max-width: 324px) {
  .dsc-tags { gap: 4px; }
  .dsc-row { padding-right: 7px; }
  .dsc-pill, .dsc-stage { padding-inline: 5px; }
  .dsc-pill--ok, .dsc-stage--2 { padding-inline: 0; }   /* kapalıyken genişlik 0 kalsın (adım kuralı açar) */
  .dsc-head, .dsc-foot { padding-inline: 10px; }
  .dsc-sn { display: none; }   /* «Aşama 1/2: Muhasebe Müdürü» → «Aşama 1/2» */
}
/* en dar kap (ana sayfa 1024 görünümde ≈251 px): avatar ve satır simgesi düşer, satır tutarında kuruş gizlenir (alt şeritte kalır) */
@container (max-width: 290px) {
  .dsc-row { grid-template-columns: minmax(0, 1fr) auto; padding-left: 8px; }
  .dsc-av, .dsc-ic, .dsc-kr { display: none; }
  .dsc-tags { grid-column: 1 / span 2; }
}
