/* ==========================================================================
   Ajan Ofisi: ofis sayfası (liste görünümü), ekip ve davet sayfaları
   Panelin tasarım dilini izler (panel.css, tokens.css): açık zemin, beyaz kartlar, kobalt vurgu.
   Renkler tokens.css'ten gelir; yalnızca "teslim etti" yeşili burada tanımlıdır (markada yeşil yok).
   Oda rengi --room değişkenidir: varsayılan kobalt, müşterinin paleti varsa ofis.js oda oda verir.
   ========================================================================== */

.ofis, .of-team {
  --of-ok: #1D7A4A;       /* beyaz zeminde 5.4:1 */
  --of-ok-soft: #E5F2EA;
  --room: var(--accent);
}

.sr-only {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden;
  clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}

.ofis-page .page { padding-top: clamp(20px, 4vh, 40px); gap: 20px; }
.ofis { display: grid; gap: 20px; min-width: 0; }

/* --- Üst şerit: paket, kredi, çalışan iş ------------------------------------ */
.of-strip {
  display: flex; flex-wrap: wrap; align-items: flex-end; gap: 16px 32px;
  padding-bottom: 20px; border-bottom: 1px solid var(--line);
}
.of-strip__title { display: grid; gap: 6px; margin-right: auto; }
.of-strip h1 { font-size: clamp(32px, 4vw, 52px); }
.of-meta { display: flex; flex-wrap: wrap; gap: 8px 28px; margin: 0; }
.of-meta div { display: grid; gap: 2px; }
.of-meta dt { font-size: 13px; color: var(--muted); }
.of-meta dd { margin: 0; font-size: 17px; font-weight: 500; font-variant-numeric: tabular-nums; }
.of-strip__team { align-self: center; }

/* --- Marka kimliği kartı ve ücretsiz çağrı ---------------------------------- */
.of-brandcard, .of-upsell {
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 16px 32px;
  padding: clamp(20px, 3vw, 28px); border-radius: var(--sa-radius-l);
  background: var(--surface); border: 1px solid color-mix(in srgb, var(--accent) 35%, var(--line));
}
.of-brandcard > div:first-child, .of-upsell > div { display: grid; gap: 8px; max-width: 62ch; }
.of-brandcard h2, .of-upsell h2 { font-size: clamp(20px, 2vw, 26px); }
.of-brandcard p:not(.eyebrow), .of-upsell p { color: var(--ink-2); font-size: 15px; }
.of-brandcard form { margin: 0; }

/* --- Yerleşim: liste + sağ panel --------------------------------------------- */
.of-layout { display: grid; grid-template-columns: minmax(0, 1fr) 360px; gap: 20px; align-items: start; }
.of-layout--solo { grid-template-columns: minmax(0, 1fr); }
.of-main { display: flex; flex-direction: column; gap: 16px; min-width: 0; }
.of-scene {
  position: relative; min-height: 520px; height: clamp(520px, 74vh, 780px); border-radius: var(--sa-radius-l); overflow: hidden;
  background: radial-gradient(120% 90% at 50% 38%, #fff 0%, #f6f3ec 62%, #eee9df 100%);
  box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--ink) 6%, transparent);
}

/* --- Liste / 3B görünüm düğmesi ------------------------------------------- */
.of-viewbar { display: flex; justify-content: flex-end; }

/* --- 3B sahne (ofis-3d.js) ---------------------------------------------------- */
.of3d { position: absolute; inset: 0; }
.of3d__canvas { display: block; width: 100%; height: 100%; cursor: grab; touch-action: none; outline: none; }
.of3d__canvas:active { cursor: grabbing; }
.of3d__canvas:focus-visible { box-shadow: inset 0 0 0 3px var(--accent); border-radius: inherit; }
.of3d__labels { position: absolute; inset: 0; overflow: hidden; pointer-events: none; z-index: 1; }
.of3d__pin { position: absolute; left: 0; top: 0; will-change: transform; }
/* Kişi künyesi (her zaman görünür): beyaz yüzey, ince çizgi, 8px yarıçap; ölçek --ts ile kamera uzaklığından gelir */
.of3d__stack { transform: translate(-50%, calc(-100% - 6px)) scale(var(--ts, 1)); transform-origin: 50% 100%; display: grid; justify-items: center; transition: opacity .2s var(--sa-ease); }
.of3d__stack.is-quiet { opacity: 0; }
.of3d__stack.is-hide { opacity: 0; visibility: hidden; transition: opacity .15s var(--sa-ease), visibility 0s .15s; }
.of3d__tag {
  position: relative; display: inline-flex; align-items: center; gap: 7px; background: #fff; color: #111113;
  font-family: var(--sa-font, "Geist", "Helvetica Neue", Arial, system-ui, sans-serif); white-space: nowrap;
  border: 1px solid #DCDCD5; border-radius: 8px;
  box-shadow: 0 1px 0 rgb(17 17 19 / .04), 0 8px 18px -10px rgb(17 17 19 / .35);
  transition: border-color .2s var(--sa-ease), box-shadow .2s var(--sa-ease), opacity .2s var(--sa-ease);
}
.of3d__tag { padding: 3px 9px 3px 8px; line-height: 1.25; }
.of3d__name { font-size: 11.5px; font-weight: 600; letter-spacing: -.01em; white-space: nowrap; }
.of3d__tag.is-hover { border-color: #2448F0; }
.of-3d .of-task { position: static; }
.of3d__tag.is-off { opacity: .75; color: var(--muted); }
/* durum çipi künyenin sağ üst köşesine yapışır */
.of3d__chip {
  position: absolute; right: 4px; bottom: calc(100% + 2px); padding: 1px 7px; border-radius: 999px; font-size: 9.5px; font-weight: 600; line-height: 1.5;
  background: #2448F0; color: #fff; box-shadow: 0 0 0 1.5px #fff;
  animation: of3d-pop .35s var(--sa-ease) both;
}
.of3d__chip::before, .of3d__chip::after { content: none; }
.of3d__chip[data-step="teslim"] { background: #1D7A4A; color: #fff; }
.of3d__chip[data-step="hata"] { background: #B3261E; color: #fff; }
/* oda etiketi: eski stil korunur */
.of3d__room {
  display: inline-flex; align-items: center; gap: 6px; padding: 5px 12px 5px 10px; border-radius: 999px;
  background: rgb(255 255 255 / .94); color: var(--ink); font-size: 12.5px; font-weight: 600; line-height: 1.3; letter-spacing: -.005em;
  white-space: nowrap; max-width: none; transform: translate(-50%, 4px);
  border: 1px solid color-mix(in srgb, var(--room) 35%, transparent);
  box-shadow: 0 1px 0 rgb(17 17 19 / .06), 0 6px 14px -8px rgb(17 17 19 / .45);
}
.of3d__room.is-off { background: rgb(255 255 255 / .7); color: var(--muted); font-weight: 500; }
.of3d__tag.is-gm { border-color: #111113; }
.of3d__dot { width: 8px; height: 8px; border-radius: 3px; background: var(--room, #2448F0); flex: none; }
.of3d__room.is-off .of3d__dot { background: var(--line); }
.of3d__lock { width: 13px; height: 13px; flex: none; color: var(--muted); }
@keyframes of3d-pop { from { opacity: 0; transform: translateY(4px) scale(.92); } }
.of3d__home { position: absolute; z-index: 3; left: 14px; top: 14px; background: rgb(255 255 255 / .92); }
.of3d__zoom { position: absolute; z-index: 3; right: 14px; bottom: 14px; display: grid; gap: 6px; }
.of3d__zoom button { width: 36px; padding: 0; font-size: 18px; line-height: 1; background: rgb(255 255 255 / .92); }
.of3d__hint {
  position: absolute; z-index: 3; left: 50%; bottom: 14px; transform: translateX(-50%); margin: 0; padding: 5px 12px; border-radius: 999px;
  background: rgb(255 255 255 / .85); color: var(--ink-2); font-size: 12.5px; pointer-events: none;
  transition: opacity .5s var(--sa-ease);
}
.of3d__hint.is-gone { opacity: 0; }
/* kişiler yüklenirken sakin gösterge */
.of3d__loading {
  position: absolute; z-index: 3; right: 14px; top: 14px; display: inline-flex; align-items: center; gap: 8px; margin: 0;
  padding: 6px 12px; border-radius: 999px; background: rgb(255 255 255 / .9); color: var(--ink-2); font-size: 12.5px;
  pointer-events: none; transition: opacity .5s var(--sa-ease);
}
.of3d__loading.is-gone { opacity: 0; }
.of3d__loading-dot { width: 7px; height: 7px; border-radius: 50%; background: var(--accent); animation: of3d-breathe 1.6s ease-in-out infinite; }
@keyframes of3d-breathe { 50% { opacity: .25; transform: scale(.8); } }
@media (prefers-reduced-motion: reduce) {
  .of3d__chip, .of3d__loading-dot { animation: none; }
  .of3d__tag, .of3d__hint, .of3d__loading { transition: none; }
}

.of-list { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 360px), 1fr)); gap: 16px; align-items: start; }

/* --- Oda ------------------------------------------------------------------- */
.of-room {
  background: var(--surface); border-radius: var(--sa-radius-l); padding: 18px 18px 8px;
  display: grid; gap: 6px; min-width: 0; scroll-margin-top: calc(var(--nav-h) + 16px);
  box-shadow: 0 1px 0 color-mix(in srgb, var(--ink) 5%, transparent);
  transition: box-shadow .3s var(--sa-ease);
}
.of-room.is-focus { box-shadow: 0 0 0 2px var(--room); }
.of-room__head { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 10px; padding-bottom: 10px; border-bottom: 1px solid var(--line); }
.of-room__head h2 { font-size: 18px; letter-spacing: var(--sa-track-tight); }
.of-room__swatch { width: 10px; height: 10px; border-radius: 3px; background: var(--room); flex: none; }
.of-room__count { font-size: 13px; color: var(--muted); }
.of-room__head .lock { margin-left: auto; }
.of-room[data-state="closed"], .of-room[data-state="locked"], .of-room[data-state="showcase"] { background: color-mix(in srgb, var(--surface) 55%, var(--bg)); box-shadow: none; border: 1px dashed var(--line); }
.of-room[data-state="closed"] .of-room__swatch, .of-room[data-state="locked"] .of-room__swatch, .of-room[data-state="showcase"] .of-room__swatch { background: var(--line); }
.of-room__foot { display: grid; gap: 10px; padding: 12px 0 10px; border-top: 1px solid var(--line); }
.of-room__foot p { font-size: 14px; color: var(--ink-2); }
.of-room--reception { grid-column: 1 / -1; }
.of-room--reception .of-agents { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 320px), 1fr)); column-gap: 16px; }

/* --- Ajan satırı ------------------------------------------------------------- */
.of-agents { list-style: none; margin: 0; padding: 0; }
.of-agents li + li { border-top: 1px solid color-mix(in srgb, var(--line) 60%, transparent); }
.of-agent {
  --b-bg: transparent; --b-line: transparent;
  width: 100%; min-height: 0; padding: 12px 4px; border-radius: var(--sa-radius-s);
  display: grid; grid-template-columns: 36px minmax(0, 1fr) auto; align-items: start; gap: 12px;
  text-align: left; color: var(--ink); text-decoration: none; font-weight: 400; line-height: 1.4;
}
button.of-agent:hover, a.of-agent:hover { background: color-mix(in srgb, var(--surface-2) 55%, var(--surface)); border-color: transparent; }
button.of-agent:active { transform: none; }
.of-agent__avatar {
  width: 36px; height: 36px; border-radius: 50%; display: grid; place-items: center;
  font-size: 12px; font-weight: 600; letter-spacing: .02em; color: var(--ink);
  background: color-mix(in srgb, var(--room) 16%, var(--surface));
  box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--room) 30%, transparent);
}
.of-agent__body { display: grid; gap: 2px; min-width: 0; }
.of-agent__name { font-size: 15px; font-weight: 500; }
.of-agent__desc { font-size: 13px; color: var(--muted); }
.of-agent__meta { display: grid; justify-items: end; gap: 6px; font-size: 13px; white-space: nowrap; }
.of-agent__cost { color: var(--ink-2); font-variant-numeric: tabular-nums; }
.of-agent__go { color: var(--accent); font-weight: 500; }
.of-agent.is-off { color: var(--ink-2); }
.of-agent.is-off .of-agent__avatar { background: var(--surface-2); box-shadow: none; color: var(--muted); }

/* Durum balonu: yalnızca gerçekten olan adım */
.of-state, .of-agent__state {
  display: inline-flex; align-items: center; gap: 6px; padding: 3px 9px; border-radius: 999px;
  font-size: 12px; font-weight: 500; background: var(--surface-2); color: var(--ink-2); white-space: nowrap;
}
.of-state::before, .of-agent__state::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: currentColor; opacity: .55; }
[data-step="sirada"] { background: var(--surface-2); color: var(--ink-2); }
[data-step="marka"], [data-step="yaziyor"], [data-step="kontrol"], [data-step="kalite"] { background: var(--accent-soft); color: var(--accent); }
[data-step="marka"]::before, [data-step="yaziyor"]::before, [data-step="kontrol"]::before, [data-step="kalite"]::before { opacity: 1; animation: blink 1s ease-in-out infinite; }
[data-step="teslim"] { background: var(--of-ok-soft); color: var(--of-ok); }
[data-step="teslim"]::before, [data-step="hata"]::before { opacity: 1; }
[data-step="hata"] { background: var(--danger-soft); color: var(--danger); }
@keyframes blink { 50% { opacity: .25; } }

/* --- Görev kutusu ---------------------------------------------------------- */
.of-task {
  position: sticky; bottom: 16px; z-index: 5;
  display: grid; gap: 10px; padding: 16px; border-radius: var(--sa-radius-l);
  background: var(--surface); border: 1px solid var(--line);
  box-shadow: 0 18px 48px -28px color-mix(in srgb, var(--ink) 45%, transparent);
}
.of-task label { font-size: 14px; font-weight: 500; }
.of-task__text { display: grid; gap: 6px; }
.of-task textarea { min-height: 56px; }
.of-task__row { display: flex; flex-wrap: wrap; align-items: flex-end; gap: 10px 14px; }
.of-task__to { display: grid; gap: 6px; flex: 1 1 260px; min-width: 0; }
.of-task__cost { font-size: 13px; color: var(--muted); flex: 1 1 200px; padding-bottom: 12px; }
.of-task .primary { min-height: 48px; padding: 0 26px; }

/* Seçim kutusu ve sayı alanı (panel.css yalnızca metin alanlarını biçimler) */
.ofis select, .ofis input[type="number"] {
  width: 100%; min-height: 48px; padding: 10px 14px; color: var(--ink);
  background: var(--bg); border: 1px solid var(--line); border-radius: var(--sa-radius-m);
}
.ofis select { appearance: none; padding-right: 40px; background-image: linear-gradient(45deg, transparent 50%, var(--ink-2) 50%), linear-gradient(135deg, var(--ink-2) 50%, transparent 50%); background-position: calc(100% - 20px) 50%, calc(100% - 15px) 50%; background-size: 5px 5px; background-repeat: no-repeat; }
.ofis select:focus, .ofis input[type="number"]:focus { outline: none; background-color: var(--surface); border-color: var(--accent); box-shadow: 0 0 0 4px color-mix(in srgb, var(--accent) 16%, transparent); }
.ofis select[multiple] { background-image: none; padding-right: 14px; }

/* --- Sağ panel: sekmeler ------------------------------------------------------ */
.of-side {
  position: sticky; top: calc(var(--nav-h) + 16px);
  max-height: calc(100vh - var(--nav-h) - 32px); overflow: auto;
  background: var(--surface); border-radius: var(--sa-radius-l); padding: 8px 8px 16px;
  box-shadow: 0 1px 0 color-mix(in srgb, var(--ink) 5%, transparent);
}
.of-tabs { display: flex; gap: 4px; padding: 4px; margin-bottom: 8px; background: var(--surface-2); border-radius: 999px; position: sticky; top: 0; z-index: 1; }
.of-tabs button {
  flex: 1 1 0; min-width: 0; min-height: 38px; padding: 0 10px; border: 0; border-radius: 999px;
  background: transparent; color: var(--ink-2); font-size: 13px; font-weight: 500; white-space: nowrap;
}
.of-tabs button:hover { border: 0; color: var(--ink); }
.of-tabs button[aria-selected="true"] { background: var(--surface); color: var(--ink); box-shadow: 0 1px 2px color-mix(in srgb, var(--ink) 12%, transparent); }
.of-tabs__n { font-variant-numeric: tabular-nums; color: var(--accent); }
.of-tabs__n:empty { display: none; }
.of-panel { padding: 4px 6px; outline-offset: -2px; }
.of-feed { display: grid; gap: 10px; }
.of-empty { font-size: 14px; color: var(--muted); padding: 16px 4px; }

/* Canlı akış satırı */
.of-live { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 2px 10px; padding: 10px 4px; border-bottom: 1px solid var(--line); font-size: 14px; }
.of-live:last-child { border-bottom: 0; }
.of-live__name { font-weight: 500; }
.of-live__meta { grid-column: 1 / -1; font-size: 12px; color: var(--muted); overflow-wrap: anywhere; }
.of-live__err { grid-column: 1 / -1; font-size: 13px; color: var(--danger); }
.of-live .btn--sm { grid-column: 1 / -1; justify-self: start; min-height: 34px; padding: 0 12px; font-size: 13px; }

/* --- Taslak ve teslim kartı -------------------------------------------------- */
.of-draft { display: grid; gap: 10px; padding: 14px; border: 1px solid var(--line); border-radius: var(--sa-radius-m); background: var(--surface); min-width: 0; }
.of-draft__nobrand { font-size: 13px; color: var(--ink-2); background: var(--surface-2); border-radius: var(--sa-radius-s); padding: 8px 10px; }
.of-draft__head { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 10px; }
.of-draft__head strong { font-size: 15px; font-weight: 500; }
.of-draft__meta { font-size: 12px; color: var(--muted); overflow-wrap: anywhere; }
.of-draft__body { min-width: 0; max-height: 420px; overflow: auto; padding-right: 4px; }
.of-draft__body[data-loading] { color: var(--muted); font-size: 14px; }
.of-draft__actions { display: flex; flex-wrap: wrap; gap: 8px; }
.of-draft__actions .btn--sm, .of-draft__actions button { min-height: 36px; padding: 0 14px; font-size: 13px; }
.of-draft__fix { display: grid; gap: 6px; }
.of-draft__fix-row { display: flex; gap: 8px; }
.of-draft__fix input { min-height: 44px; padding: 10px 14px; flex: 1; min-width: 0; }
.of-draft__hint { font-size: 12px; color: var(--muted); }
.of-qa { margin: 0 0 10px; font-size: 13px; color: var(--ink-2); background: var(--surface-2); border-radius: var(--sa-radius-s); padding: 8px 10px; }
.of-qa[data-ok] { background: var(--of-ok-soft); color: var(--of-ok); }
.of-qa ul { margin: 6px 0 0; padding-left: 18px; color: var(--ink-2); }
.of-draft__handoff { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; font-size: 13px; color: var(--muted); }
.of-draft__handoff button { min-height: 32px; padding: 0 12px; font-size: 13px; }
.of-draft .field-error:empty { display: none; }

/* Güvenli Markdown çıktısı */
.of-md { display: grid; gap: 10px; font-size: 15px; line-height: 1.55; overflow-wrap: anywhere; }
.of-md h3 { font-size: 18px; color: var(--ink); letter-spacing: var(--sa-track-tight); }
.of-md h4 { font-size: 15px; font-weight: 600; margin-top: 6px; }
.of-md h5 { font-size: 14px; font-weight: 600; color: var(--ink-2); }
.of-md p { max-width: none; }
.of-md ul, .of-md ol { padding-left: 20px; display: grid; gap: 4px; }
.of-md strong { font-weight: 600; }
.of-md__table { overflow-x: auto; border: 1px solid var(--line); border-radius: var(--sa-radius-s); }
.of-md table { font-size: 13px; }
.of-md th, .of-md td { padding: 8px 10px; }
.of-media { display: grid; grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); gap: 10px; }
.of-media figure { margin: 0; display: grid; gap: 6px; font-size: 12px; color: var(--muted); }
.of-media img { width: 100%; aspect-ratio: 1; object-fit: contain; background: var(--surface-2); border-radius: var(--sa-radius-s); }
.of-media .of-media__none { display: grid; place-items: center; aspect-ratio: 1; padding: 8px; text-align: center; background: var(--surface-2); border-radius: var(--sa-radius-s); }
.of-draft audio { width: 100%; }

/* --- Ajan kartı ve onay kutusu (dialog) ------------------------------------- */
.of-dialog {
  width: min(640px, calc(100% - 24px)); max-height: calc(100dvh - 24px); padding: 0; border: 0;
  border-radius: var(--sa-radius-l); background: var(--surface); color: var(--ink);
  box-shadow: 0 40px 100px -40px color-mix(in srgb, var(--ink) 60%, transparent);
}
.of-dialog--small { width: min(460px, calc(100% - 24px)); }
.of-dialog::backdrop { background: color-mix(in srgb, var(--sa-dark) 45%, transparent); }
.of-dialog[open] { animation: of-in .25s var(--sa-ease) both; }
@keyframes of-in { from { opacity: 0; transform: translateY(10px); } }
.of-dialog__in { display: grid; gap: 18px; padding: clamp(20px, 4vw, 28px); }
.of-dialog__head { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 6px 16px; align-items: start; }
.of-dialog__head h2 { font-size: clamp(22px, 3vw, 28px); }
.of-dialog__head p:not(.eyebrow) { grid-column: 1 / -1; color: var(--ink-2); font-size: 15px; }
.of-detail__facts { display: grid; gap: 8px; margin: 0; padding: 12px 14px; border-radius: var(--sa-radius-s); background: var(--surface-2); }
.of-detail__row { display: grid; grid-template-columns: 110px minmax(0, 1fr); gap: 12px; font-size: 14px; }
.of-detail__row dt { color: var(--muted); }
.of-detail__row dd { margin: 0; color: var(--ink); }
.of-detail__job { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 12px; padding: 6px 0; }
.of-detail__when { color: var(--ink-2); font-size: 13px; }
.of-detail__job .btn--sm { margin-left: auto; }
.of-detail__hint { margin: 0; }
.of-dialog__close { min-height: 40px; width: 40px; padding: 0; font-size: 20px; line-height: 1; }
.of-pill { justify-self: start; display: inline-flex; padding: 4px 12px; border-radius: 999px; background: var(--accent-soft); color: var(--accent); font-size: 13px; font-weight: 500; }
.of-form { display: grid; gap: 16px; }
.of-field { display: grid; gap: 6px; min-width: 0; }
.of-field > label, .of-field legend { font-size: 15px; font-weight: 500; }
.of-field textarea { min-height: 96px; }
.of-field .chips { margin-top: 2px; }
.of-field--bad input, .of-field--bad textarea, .of-field--bad select { border-color: var(--danger); }
.of-form__foot { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 16px; }
.of-form__foot .primary { min-height: 50px; padding: 0 28px; }
.of-recent { display: grid; gap: 8px; padding-top: 16px; border-top: 1px solid var(--line); }
.of-recent h3 { font-size: 13px; }
.of-recent ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 6px; font-size: 14px; }
.of-recent li { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 4px 10px; }
.of-confirm { display: grid; gap: 16px; padding: clamp(20px, 4vw, 28px); }
.of-confirm p { font-size: 17px; line-height: 1.5; }

/* --- Bildirim -------------------------------------------------------------- */
.of-toast {
  position: fixed; left: 50%; bottom: 24px; z-index: 60; max-width: calc(100% - 32px);
  padding: 12px 18px; border-radius: 999px; background: var(--ink); color: var(--bg); font-size: 14px;
  transform: translate(-50%, 160%); opacity: 0; transition: transform .3s var(--sa-ease), opacity .3s var(--sa-ease);
  pointer-events: none;
}
.of-toast.is-on { transform: translate(-50%, 0); opacity: 1; }
.of-toast.is-bad { background: var(--danger); color: var(--accent-ink); }

/* --- Ekip ve davet sayfaları -------------------------------------------------- */
.of-team { display: grid; gap: 20px; max-width: 880px; width: 100%; }
.of-team__head { display: grid; gap: 10px; }
.of-team__head h1 { font-size: clamp(32px, 4vw, 52px); }
.of-note { background: var(--accent-soft); color: var(--accent); padding: 12px 16px; border-radius: var(--sa-radius-m); font-size: 15px; max-width: none; }
.of-members { list-style: none; padding: 0; margin: 0; border-top: 1px solid var(--line); }
.of-members li { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px 16px; padding: 14px 0; border-bottom: 1px solid var(--line); }
.of-members form { margin: 0; }
.of-members__who { display: grid; gap: 2px; min-width: 0; }
.of-members__mail { font-weight: 500; overflow-wrap: anywhere; }
.of-invite { padding-top: 12px; gap: 10px; }
.of-invite h3 { font-size: 17px; color: var(--ink); }
.of-invite__row { display: flex; flex-wrap: wrap; gap: 10px; }
.of-invite__row input { flex: 1 1 240px; min-width: 0; }
.of-rooms-form fieldset[disabled] { opacity: .6; }

/* --- Dar ekran ---------------------------------------------------------------- */
@media (max-width: 1100px) {
  .of-layout { grid-template-columns: minmax(0, 1fr); }
  .of-side { position: static; max-height: none; }
}
@media (max-width: 760px) {
  .of-task { position: static; order: -1; box-shadow: none; }
  .of-meta { gap: 8px 20px; }
  .of-strip { align-items: flex-start; }
  .of-room { padding: 16px 14px 6px; }
  .of-agent { grid-template-columns: 32px minmax(0, 1fr); }
  .of-agent__avatar { width: 32px; height: 32px; }
  .of-agent__meta { grid-column: 2; justify-items: start; display: flex; flex-wrap: wrap; gap: 8px; }
  .of-dialog { width: calc(100% - 16px); max-height: calc(100dvh - 16px); }
  .of-tabs button { font-size: 12px; padding: 0 6px; }
}

@media (prefers-reduced-motion: reduce) {
  [data-step]::before { animation: none !important; }
  .of-dialog[open] { animation: none; }
}

/* --- Arşiv ve karar günlüğü ----------------------------------------------- */
.of-archive { display: grid; gap: 20px; max-width: 1040px; width: 100%; min-width: 0; --of-ok: #1D7A4A; --room: var(--accent); }
.of-archive__meta { color: var(--muted); font-size: 14px; }
.of-tabs { display: flex; gap: 8px; border-bottom: 1px solid var(--line); }
.of-tabs a { padding: 10px 14px; color: var(--ink-2); text-decoration: none; border-bottom: 2px solid transparent; }
.of-tabs a[aria-current="page"] { color: var(--ink); border-bottom-color: var(--accent); font-weight: 600; }
.of-archive__filters { display: flex; flex-wrap: wrap; gap: 8px; }
.of-archive__filters input[type="search"] { flex: 1 1 220px; min-width: 0; }
.of-archive__table { width: 100%; border-collapse: collapse; font-size: 14px; }
.of-archive__table th, .of-archive__table td { text-align: left; padding: 10px 12px; border-bottom: 1px solid var(--line); vertical-align: top; overflow-wrap: anywhere; }
.of-archive__pager { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 16px; color: var(--muted); font-size: 14px; }
.of-print table { width: 100%; border-collapse: collapse; }
.of-print th, .of-print td { border: 1px solid var(--line); padding: 6px 8px; text-align: left; }
.of-print .print-section { break-inside: auto; page-break-inside: auto; }
.of-print .print-section > h2::before { content: none; }
.of-print .of-md { gap: 8px; }
/* Canlı akıştaki gündelik ofis hareketleri: iş değildir, daha sakin görünür */
.of-live--act { opacity: .82; padding-block: 8px; }
.of-live--act .of-live__name { font-weight: 400; }
.of-live--act .of-live__meta { grid-column: auto; align-self: center; white-space: nowrap; }

/* --- Basit ofis (ofis-mini.js): dar ekran ya da WebGL yok; 3B sahnenin iki boyutlu kat planı ------------- */
.omini { display: grid; gap: 12px; margin: 0 0 20px; }
.omini[hidden] { display: none; }
.omini__lobby, .omini__room {
  background: var(--surface, #fff); border-radius: 18px; padding: 14px;
  box-shadow: 0 1px 0 rgb(17 17 19 / .04), 0 0 0 1px var(--line);
}
.omini__lobby-head, .omini__room-head { display: flex; align-items: center; gap: 8px; min-width: 0; }
.omini__title { font-size: 15px; font-weight: 600; letter-spacing: -.01em; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.omini__room-head {
  width: 100%; min-height: 32px; padding: 0; border: 0; background: none; color: var(--ink); text-align: left; justify-content: flex-start; cursor: pointer; font: inherit;
}
.omini__dot { flex: none; width: 9px; height: 9px; border-radius: 3px; background: var(--c, #2448F0); }
.omini__count {
  margin-left: auto; min-width: 22px; height: 22px; padding: 0 7px; border-radius: 999px; display: inline-grid; place-items: center;
  background: var(--c, #2448F0); color: #fff; font-size: 12px; font-weight: 600; font-variant-numeric: tabular-nums;
}
.omini__room-head .lock { margin-left: auto; }
.omini__grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
@media (min-width: 768px) { .omini__grid { grid-template-columns: repeat(3, minmax(0, 1fr)); } }

/* masalar: boş masa sakin bir kare, dolu masada kişi (baş harfleri oda renginde) oturur */
.omini__desks { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 6px; margin-top: 12px; }
.omini__desk {
  position: relative; aspect-ratio: 1; width: 100%; height: auto; min-width: 0; min-height: 0; padding: 0; border: 0; border-radius: 9px; cursor: pointer;
  background: var(--surface-2, #f1efea); display: grid; place-items: center; font: inherit;
}
.omini__desk.is-empty { cursor: default; }
.omini__desk:disabled { cursor: default; }
.omini__desk .omini__av { visibility: hidden; }
.omini__desk.is-in .omini__av { visibility: visible; }
.omini__av {
  width: 30px; height: 30px; border-radius: 999px; display: grid; place-items: center;
  background: var(--c, #2448F0); color: #fff; font-size: 10.5px; font-weight: 600; letter-spacing: .02em;
}
.omini__desk.is-busy::after, .omini__seat.is-busy::after {
  content: ""; position: absolute; right: 3px; top: 3px; width: 7px; height: 7px; border-radius: 999px;
  background: #2448F0; box-shadow: 0 0 0 2px var(--surface, #fff); animation: omini-pulse 1.4s ease-in-out infinite;
}
.omini__desk[data-durum="teslim"].is-in::after {
  content: ""; position: absolute; right: 3px; top: 3px; width: 7px; height: 7px; border-radius: 999px; background: var(--of-ok);
  box-shadow: 0 0 0 2px var(--surface, #fff);
}
.omini__desk.is-err { box-shadow: inset 0 0 0 1.5px #d93025; }
.omini__room.is-off { opacity: .55; }
.omini__room.is-off .omini__dot { background: var(--ink-2); }
@keyframes omini-pulse { 50% { opacity: .35; } }
@media (prefers-reduced-motion: reduce) {
  .omini__desk.is-busy::after, .omini__seat.is-busy::after { animation: none; }

}

/* giriş: Genel Müdür, Kalite Kontrol ve Onay masası */
.omini__lobby { --c: #111113; }
.omini__lobby-seats { display: flex; gap: 10px; margin-top: 12px; }
.omini__seat {
  position: relative; display: inline-flex; align-items: center; gap: 8px; padding: 6px 12px 6px 6px; border: 0; border-radius: 999px;
  background: var(--surface-2, #f1efea); color: var(--ink); cursor: pointer; font: inherit; font-size: 13px; min-height: 44px;
}
.omini__seat .omini__av { width: 32px; height: 32px; }
.omini__chip { font-size: 12px; color: var(--ink-2); }
.omini__approval { margin-left: auto; display: inline-flex; align-items: center; gap: 6px; color: var(--ink-2); font-size: 13px; font-variant-numeric: tabular-nums; }
.omini__tray { width: 16px; height: 11px; border: 1.5px solid currentColor; border-top: 0; border-radius: 0 0 3px 3px; }
.omini__approval.is-full { color: var(--of-ok); font-weight: 600; }

/* odadaki o anki işler: ad ve adım */
.omini__live { list-style: none; margin: 10px 0 0; padding: 0; display: grid; grid-template-columns: minmax(0, 1fr); gap: 4px; }
.omini__live li { min-width: 0; }
.omini__room, .omini__lobby { min-width: 0; }
.omini__live[hidden] { display: none; }
.omini__row {
  width: 100%; max-width: 100%; display: flex; flex-wrap: wrap; align-items: center; justify-content: flex-start; gap: 4px 8px; padding: 6px 0; border: 0; background: none; cursor: pointer;
  color: var(--ink); font: inherit; font-size: 13px; text-align: left; min-height: 32px;
}
.omini__row-name { min-width: 0; flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.omini__row .of-state { flex: none; }

/* Telefonda 3B sahne: sayfa sahnenin altından ve üstünden kaydırılabilsin diye ekranın bir kısmını kaplar */
@media (max-width: 767px) {
  .of-scene { min-height: 360px; height: 62vh; height: 62svh; }
}
