/* Panolar (v1) — PallMac/MacPanolarView.swift + EfeaktifApp/SmartWidgets.swift +
   PallMac/MacCharts.swift + EfeaktifApp/PAL/PALTodos.swift + PallMac/MacDroneCard.swift +
   PallMac/BantWidget.swift + PallMac/MacPanoDetail.swift + FactoryOpsViews (Toplantı).
   Pano v2 YOK. Yazı boyları macOS metin stilleri (satır yükseklikleriyle):
   largeTitle 26/32 · title3 15/20 · title2 17/22 · headline 13/16 bold · body 13/16 ·
   callout 12/15 · subheadline 11/14 · footnote 10/13 · caption 10/13 · caption2 10/13 (500). */

.pp-root {
  --pp-top-inset: 60px;               /* Mac araç çubuğu alanı 52 px; web: ortadaki Sohbet|Pano düğmesi için 60 px boşluk */
  position: relative;
  height: 100%;
  overflow-y: auto;
  overflow-x: hidden;
  background: var(--pal-bg);
  color: var(--pal-text);
  font-family: var(--font);
  scrollbar-width: none;
}
.pp-root::-webkit-scrollbar { display: none; }

/* ── Başlık (safeAreaInset top): padding 18/22/12, zemin %92 ───────────────── */
.pp-header {
  position: sticky; top: 0; z-index: 5;
  display: flex; align-items: baseline; gap: 12px;
  padding: calc(var(--pp-top-inset) + 18px) 22px 12px;
  background: rgba(242,245,250,.92);
}
.pp-header__txt { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.pp-title { font: 700 26px/31px var(--font); color: var(--pal-text); }
.pp-sub { font: 400 11px/14px var(--font); color: var(--pal-text2); }
.pp-spacer { flex: 1 1 auto; }
.pp-btn-bordered {                    /* .buttonStyle(.bordered).tint(accentBlue) */
  display: inline-block;
  height: 24px; line-height: 24px; padding: 0 12px;
  border-radius: 6px;
  background: #E8EFFB;
  color: #0A7EFF;
  font-size: 13px; font-weight: 400;
  white-space: nowrap;
  transition: filter .12s;
}
/* İkon, yazının büyük harf ortasına ortalı (Mac HStack varsayılan hizası) */
.pp-btn-bordered > .ni { vertical-align: -2px; margin-right: 6px; }
.pp-btn-bordered:active { filter: brightness(.94); }
.pp-live { display: inline-block; font: 500 10px/13px var(--font); color: #0A7EFF; white-space: nowrap; }
.pp-live > .ni { vertical-align: -3px; margin-right: 8px; }
.pp-status { display: inline-flex; align-items: baseline; min-width: 20px; }

/* ── Gövde: VStack(spacing 14) padding 20 ─────────────────────────────────── */
.pp-body { display: flex; flex-direction: column; gap: 14px; padding: 20px; }
.pp-body > :empty { display: none; }

/* ── Kart zemini (glassCard) ──────────────────────────────────────────────── */
.pp-card {
  position: relative;
  border-radius: 20px;
  background: #FBFCFF;
  box-shadow: 0 0 1px rgba(0,0,0,.02), 0 0 32px rgba(0,0,0,.085);
  padding: 16px;
  min-width: 0;
}
.pp-card.is-em {                      /* emphasis == critical */
  background: #E9EBEF;
  box-shadow: inset 0 0 0 1px rgba(20,23,31,.45), 0 0 1px rgba(0,0,0,.02), 0 0 32px rgba(0,0,0,.085);
}
.pp-card.is-tile { border-radius: 18px; }
.pp-tap { cursor: default; }

/* SWCard / PalCard başlığı: HStack(firstTextBaseline) · VStack(spacing 2) */
.pp-card__col { display: flex; flex-direction: column; gap: 12px; min-width: 0; }
.pp-hd { display: flex; align-items: baseline; gap: 8px; }
.pp-hd__txt { display: flex; flex-direction: column; gap: 2px; min-width: 0; flex: 1 1 auto; }
.pp-hd__t { font: 600 10px/13px var(--font); letter-spacing: 1px; color: var(--pal-text2); }
.pp-hd__c { font: 500 10px/13px var(--font); color: var(--pal-text3); }
.pp-hd .ni { align-self: baseline; }

/* ── Yazı yardımcıları ────────────────────────────────────────────────────── */
/* .monospacedDigit() — `font` kısaltması bunu sıfırladığı için !important */
.pp-r { font-family: var(--font-rounded); font-variant-numeric: tabular-nums !important; }
.pp-tn { font-variant-numeric: tabular-nums !important; }
.pp-t1 { color: var(--pal-text); }
.pp-t2 { color: var(--pal-text2); }
.pp-t3 { color: var(--pal-text3); }
.pp-cap { font: 400 10px/13px var(--font); }
.pp-cap2 { font: 500 10px/13px var(--font); }
.pp-foot { font: 400 10px/13px var(--font); }
.pp-sub11 { font: 400 11px/14px var(--font); }
.pp-callout { font: 400 12px/15px var(--font); }
.pp-bodytxt { font: 400 13px/16px var(--font); }
.pp-t3x { font: 400 15px/19px var(--font); }
.pp-ell { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

/* ── Pall'ın kartları bölümü ──────────────────────────────────────────────── */
.pp-smart { display: flex; flex-direction: column; gap: 12px; }
.pp-smart__hd { display: flex; align-items: center; gap: 8px; padding-top: 2px; }
.pp-row { display: flex; gap: 12px; align-items: stretch; }
.pp-row > .pp-cell { flex: 1 1 0; min-width: 0; display: flex; }
.pp-row > .pp-cell > .pp-card { flex: 1 1 auto; }
.pp-cell { transition: opacity .55s cubic-bezier(.25,.1,.25,1), transform .55s cubic-bezier(.25,.1,.25,1); }
.pp-cell.is-in { opacity: 0; transform: scale(.96); }
.pp-cell.is-out { opacity: 0; transform: scale(.97); pointer-events: none; }
.pp-note { display: flex; gap: 8px; align-items: flex-start; }
.pp-offline { padding: 12px; border-radius: 14px; background: rgba(0,0,0,.032); }
.pp-empty-role { display: flex; gap: 10px; align-items: flex-start; padding: 14px; }

/* Kart gövdeleri — number */
.pp-num-s { display: flex; flex-direction: column; gap: 2px; }
.pp-num-s__v { font: 600 34px/41px var(--font-rounded); }
.pp-num-m { display: flex; flex-direction: column; gap: 4px; }
.pp-num-m__v { font: 700 56px/67px var(--font-rounded); }
.pp-num-w { display: flex; align-items: center; gap: 16px; }
.pp-num-w__v { font: 700 64px/76px var(--font-rounded); }
.pp-bl { display: flex; align-items: baseline; }
.pp-rule-v { width: 1px; background: var(--pal-stroke); align-self: stretch; max-height: 54px; min-height: 30px; }

/* dailyTarget */
.pp-dt { display: flex; flex-direction: column; gap: 12px; }
.pp-dt__head { display: flex; align-items: baseline; gap: 8px; margin-top: .5px; }
.pp-dt__v { font: 700 52px/60px var(--font-rounded); }
.pp-chip {
  font: 600 9px/11px var(--font); letter-spacing: .8px; color: var(--pal-text);
  padding: 3px 7px; border-radius: 99px; box-shadow: inset 0 0 0 1px rgba(20,23,31,.35);
  white-space: nowrap;
}
.pp-hr { height: 1px; background: var(--pal-stroke); }
.pp-dtrow { display: flex; flex-direction: column; gap: 5px; }
.pp-dtlab { display: flex; align-items: center; gap: 6px; }
.pp-lab { font: 600 10px/13px var(--font); letter-spacing: 1.1px; color: var(--pal-text2); white-space: nowrap; }
.pp-mk { width: 7px; height: 7px; border-radius: 1.5px; box-shadow: inset 0 0 0 1px rgba(20,23,31,.55); flex: none; }
.pp-mk.on { background: var(--pal-ink); }
.pp-dot7 { width: 7px; height: 7px; border-radius: 50%; background: var(--pal-ink); flex: none; }
.pp-dtbar { display: flex; align-items: center; gap: 10px; }
.pp-track { position: relative; flex: 1 1 auto; height: 14px; border-radius: 3px; background: rgba(20,23,31,.08); }
.pp-fill { position: absolute; left: 0; top: 0; bottom: 0; border-radius: 3px; background: rgba(20,23,31,.88); transition: width .5s cubic-bezier(.25,.1,.25,1); }
.pp-hatch {
  position: absolute; top: 0; bottom: 0; border-radius: 3px; overflow: hidden;
  background: rgba(20,23,31,.06);
}
.pp-hatch svg { position: absolute; inset: 0; width: 100%; height: 100%; }
.pp-tick { position: absolute; top: 0; width: 4px; height: 14px; background: rgba(255,255,255,.9); }
.pp-tick::after { content: ""; position: absolute; left: 1px; top: 0; width: 2px; height: 14px; background: var(--pal-text); }
.pp-fig { width: 60px; flex: none; text-align: right; font: 600 11px/14px var(--font); font-variant-numeric: tabular-nums; color: var(--pal-text); }
.pp-fig.b { font-weight: 700; }

/* list / insight / timeline / checklist / quote */
.pp-list { display: flex; flex-direction: column; gap: 8px; }
.pp-li { display: flex; align-items: flex-start; gap: 8px; }
.pp-li .ni { margin-top: 2px; }
.pp-li__t { font: 400 13px/16px var(--font); color: var(--pal-text); display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.pp-tl__step { display: flex; align-items: flex-start; gap: 10px; }
.pp-tl__rail { width: 12px; display: flex; flex-direction: column; align-items: center; flex: none; }
.pp-tl__dot { border-radius: 50%; flex: none; }
.pp-tl__bar { width: 1.5px; height: 22px; background: rgba(0,0,0,.14); }
.pp-ck { display: flex; flex-direction: column; gap: 7px; }
.pp-ck__i { display: flex; align-items: baseline; gap: 9px; }
.pp-ck__i.done .pp-ck__t { color: var(--pal-text3); text-decoration: line-through; text-decoration-color: var(--pal-text3); }
.pp-quote { display: flex; gap: 10px; align-items: stretch; }
.pp-quote__bar { width: 3px; border-radius: 2px; background: var(--pal-ink); flex: none; }

/* compare / progress / stack / waffle / stat grid / people */
.pp-cmp { display: flex; flex-direction: column; gap: 10px; }
.pp-cmp__top { display: flex; align-items: flex-start; gap: 12px; padding-top: 1px; }
.pp-cmp__side { flex: 1 1 0; min-width: 0; display: flex; flex-direction: column; gap: 1px; }
.pp-cmp__side.r { align-items: flex-end; text-align: right; }
.pp-cmp__v { font: 700 28px/33px var(--font-rounded); font-variant-numeric: tabular-nums; }
.pp-cmp__side > :last-child { margin-top: -1px; }
.pp-cmp__rule { width: 1px; height: 46px; background: var(--pal-stroke); flex: none; }
.pp-cap-bar { display: flex; gap: 2px; height: 8px; border-radius: 99px; overflow: hidden; }
.pp-prog { position: relative; height: 10px; border-radius: 99px; background: rgba(0,0,0,.08); overflow: hidden; }
.pp-prog > i { position: absolute; left: 0; top: 0; bottom: 0; border-radius: 99px; background: var(--pal-ink); transition: width .5s ease-in-out; }
.pp-waffle { display: grid; grid-template-columns: repeat(10, 8px); gap: 3px; flex: none; }
.pp-waffle i { width: 8px; height: 8px; border-radius: 1.5px; background: rgba(0,0,0,.10); }
.pp-waffle i.on { background: var(--pal-ink); }
.pp-grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.pp-people { display: flex; }
.pp-people i {
  width: 30px; height: 30px; border-radius: 50%; margin-right: -8px; flex: none;
  display: flex; align-items: center; justify-content: center;
  font: 700 10px/13px var(--font); font-style: normal; color: var(--pal-bg);
  box-shadow: inset 0 0 0 1.5px var(--pal-bg);
}
.pp-flow { display: grid; grid-template-columns: repeat(auto-fill, minmax(96px, 1fr)); gap: 5px 8px; }
.pp-flow span { display: flex; align-items: center; gap: 6px; min-width: 0; }
.pp-dot { border-radius: 50%; flex: none; display: inline-block; }

/* route */
.pp-route { display: flex; flex-direction: column; gap: 8px; }
.pp-road { position: relative; height: 18px; }
.pp-road .ni { position: absolute; top: .5px; transition: left .6s ease-in-out; }
.pp-road b { position: absolute; top: 8px; height: 2px; }
.pp-road b.solid { left: 0; background: var(--pal-ink); }
.pp-road b.dash { background: repeating-linear-gradient(90deg, rgba(0,0,0,.2) 0 4px, transparent 4px 8px); }

/* ── Sabit kartlar ────────────────────────────────────────────────────────── */
.pp-kpi { display: flex; flex-direction: column; gap: 8px; min-height: 96px; }
.pp-kpi__hd { display: flex; align-items: center; }
.pp-kpi__v { font: 600 38px/45px var(--font-rounded); font-variant-numeric: tabular-nums; white-space: nowrap; }
.pp-kpi__g { flex: 1 1 auto; }
.pp-empty { font: 400 12px/15px var(--font); color: var(--pal-text3); min-height: 80px; display: flex; align-items: center; justify-content: center; text-align: center; }
.pp-lbl { display: flex; align-items: center; gap: 6px; }
.pp-hero { display: flex; align-items: baseline; gap: 10px; }
.pp-hero__v { font: 700 64px/76px var(--font-rounded); font-variant-numeric: tabular-nums; white-space: nowrap; }
.pp-mini__v { font: 700 40px/48px var(--font-rounded); font-variant-numeric: tabular-nums; }
.pp-two { display: flex; gap: 14px; align-items: flex-start; }
.pp-two > * { flex: 1 1 0; min-width: 0; }
.pp-masonry { display: flex; gap: 14px; align-items: flex-start; }
.pp-masonry__col { flex: 1 1 0; min-width: 0; display: flex; flex-direction: column; gap: 14px; }

/* Tarih seçici: padding 4/6, menü */
.pp-date { display: flex; align-items: center; gap: 10px; padding: 4px 6px; position: relative; }
.pp-date__btn { display: inline-flex; align-items: center; gap: 5px; font: 600 12px/15px var(--font); color: var(--pal-text); }
.pp-date__btn svg { width: 8px; height: 5px; }
.pp-date__back { font: 600 10px/13px var(--font); color: #0A7EFF; }
.pp-menu {
  position: absolute; top: 26px; left: 26px; z-index: 20; min-width: 200px;
  padding: 5px; border-radius: 10px;
  background: rgba(246,246,248,.92); -webkit-backdrop-filter: blur(20px) saturate(1.8); backdrop-filter: blur(20px) saturate(1.8);
  box-shadow: 0 0 0 .5px rgba(0,0,0,.15), 0 10px 30px rgba(0,0,0,.18);
  font: 400 13px/16px var(--font);
}
.pp-menu button { display: block; width: 100%; text-align: left; padding: 3px 10px; border-radius: 5px; }
.pp-menu button:hover { background: #0A7EFF; color: #fff; }

/* Drone */
.pp-drone { display: flex; align-items: center; gap: 18px; padding: 18px; }
.pp-drone__ring { position: relative; width: 78px; height: 78px; flex: none; }
.pp-drone__ring svg { width: 78px; height: 78px; }
.pp-drone__pct { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; font: 600 18px/22px var(--font-rounded); color: var(--pal-text); font-variant-numeric: tabular-nums; }
.pp-drone__txt { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.pp-drone__t { display: flex; align-items: center; gap: 8px; font: 600 15px/20px var(--font); }
.pp-pill-ink {
  display: inline-flex; align-items: center; gap: 6px; padding: 10px 16px; border-radius: 99px;
  background: var(--pal-ink); color: #fff; font: 600 11px/14px var(--font); white-space: nowrap;
}

/* Görevlerin */
.pp-todo__row { display: flex; align-items: baseline; gap: 9px; padding: 5px 0; transition: opacity .2s; }
.pp-todo__row.busy { opacity: .4; pointer-events: none; }
.pp-todo__dot { width: 5px; height: 5px; border-radius: 50%; background: var(--pal-ink); flex: none; position: relative; top: -3px; }
.pp-todo__msg { flex: 1 1 auto; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.pp-todo__msg > span:first-child { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.pp-todo__b { width: 30px; height: 30px; border-radius: 50%; display: inline-flex; align-items: center; justify-content: center; flex: none; align-self: center; }

/* Üretim bandı */
.pp-bant { position: relative; height: 380px; border-radius: 20px; overflow: hidden; background: #F7F7F7; box-shadow: 0 0 1px rgba(0,0,0,.02), 0 0 32px rgba(0,0,0,.085); }
.pp-bant canvas { position: absolute; inset: 0; width: 100%; height: 100%; display: block; }
.pp-bant__fallback { position: absolute; inset: 0; }
.pp-mat {                               /* .ultraThinMaterial */
  background: rgba(255,255,255,.55);
  -webkit-backdrop-filter: blur(12px) saturate(1.6); backdrop-filter: blur(12px) saturate(1.6);
}
.pp-bant__title { position: absolute; left: 14px; top: 14px; padding: 9px 12px; border-radius: 12px; display: flex; flex-direction: column; gap: 3px; max-width: calc(100% - 28px); }
.pp-bant__lanes { position: absolute; right: 14px; top: 14px; display: flex; flex-direction: column; align-items: flex-end; gap: 6px; }
.pp-bant__lane { display: flex; align-items: center; gap: 8px; padding: 6px 10px; border-radius: 99px; }
.pp-bant__status { position: absolute; left: 14px; bottom: 14px; display: flex; align-items: center; gap: 8px; padding: 8px 12px; border-radius: 99px; }
.pp-badge-b { font: 700 10px/13px var(--font); font-variant-numeric: tabular-nums; padding: 2px 6px; border-radius: 99px; background: rgba(0,122,255,.12); color: #0A7EFF; }

/* Grafikler (Swift Charts karşılığı, SVG) */
.pp-chart { position: relative; width: 100%; }
.pp-chart svg { display: block; width: 100%; overflow: visible; }
.pp-chart text { font-family: var(--font); }
.pp-legend-top { display: flex; gap: 8px; margin-bottom: 8px; font: 400 10px/13px var(--font); color: var(--pal-text2); }
.pp-legend-top span { display: inline-flex; align-items: center; gap: 4px; }
.pp-legend { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.pp-legend__r { display: flex; align-items: center; gap: 7px; }
.pp-donut { position: relative; flex: none; }
.pp-donut svg { width: 100%; height: 100%; display: block; }
.pp-donut__c { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 0; pointer-events: none; }

/* ── Detay sayfası (MacPanoDetailSheet) ve Toplantı Modu ──────────────────── */
.pp-sheet-bg {
  position: fixed; inset: 0; z-index: 60; display: flex; align-items: center; justify-content: center;
  background: rgba(0,0,0,.18); opacity: 0; transition: opacity .25s ease;
}
.pp-sheet-bg.on { opacity: 1; }
.pp-sheet {
  position: relative; width: 540px; min-height: 580px; max-height: calc(100vh - 80px);
  background: var(--pal-bg); border-radius: 16px; overflow: hidden; display: flex; flex-direction: column;
  box-shadow: 0 0 0 .5px rgba(0,0,0,.2), 0 20px 60px rgba(0,0,0,.28);
  transform: translateY(12px) scale(.985); transition: transform .3s cubic-bezier(.2,.8,.2,1);
}
.pp-sheet-bg.on .pp-sheet { transform: none; }
.pp-sheet__art { position: relative; height: 250px; flex: none; background: center / cover no-repeat; }
.pp-sheet__art::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 90px; background: linear-gradient(rgba(242,245,250,0), var(--pal-bg)); }
.pp-sheet__body { padding: 28px; display: flex; flex-direction: column; gap: 16px; overflow-y: auto; }
.pp-sheet__t { font: 700 30px/36px var(--font-rounded); color: var(--pal-text); }
.pp-sheet__x {
  position: absolute; top: 14px; right: 14px; width: 30px; height: 30px; border-radius: 50%;
  background: rgba(0,0,0,.38); display: flex; align-items: center; justify-content: center; z-index: 2;
}
.pp-sheet__txt { font: 400 15px/20px var(--font); color: var(--pal-text2); white-space: pre-wrap; animation: pp-fade .4s ease-out; }
@keyframes pp-fade { from { opacity: 0; } to { opacity: 1; } }

.pp-meet {
  position: absolute; inset: 0; z-index: 30; background: rgb(247,247,247);
  display: flex; flex-direction: column; opacity: 0; transition: opacity .3s ease;
}
.pp-meet.on { opacity: 1; }
.pp-meet__hd { display: flex; align-items: center; gap: 8px; padding: calc(var(--pp-top-inset, 52px) + 28px) 28px 28px; }
.pp-meet__hd h2 { margin: 0; font: 700 26px/32px var(--font); color: var(--pal-text); }
.pp-meet__grid { flex: 1 1 auto; display: grid; grid-template-columns: 1fr 1fr; grid-template-rows: 1fr 1fr; gap: 18px; padding: 0 28px 28px; min-height: 0; }
.pp-meet__tile {
  background: #fff; border-radius: 22px; box-shadow: inset 0 0 0 1px rgba(0,0,0,.048);
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 10px; min-height: 0; overflow: hidden;
}
.pp-meet__tile h3 { margin: 0; font: 700 13px/16px var(--font); letter-spacing: .4px; color: var(--pal-text2); }
.pp-meet__v { font: 700 96px/1.1 var(--font-rounded); font-variant-numeric: tabular-nums; white-space: nowrap; }

@media (prefers-reduced-motion: reduce) {
  .pp-cell, .pp-fill, .pp-prog > i, .pp-road .ni { transition: none; }
}
