/* Yönetim (design V5 parity): Temsilci-Profilleri, Yonetim-Kuyruklar, Santral-Baglanti, Yonetim-Sonuc-Kodlari,
   Yonetim-Mola-Turleri. Sizes and colours are the design's inline styles; every class starts with ad-. */

/* ----------------------------------------------------------------- page, header, body */
.ad-page { flex-grow: 1; display: flex; flex-direction: column; height: 100vh; min-height: 0; line-height: normal; }  /* the design's */
.top.ad-top { gap: 22px; }
.ad-btn { height: 36px; box-sizing: border-box; display: inline-flex; align-items: center; padding: 0 14px; border: 1px solid var(--p-e0e0e0);
  border-radius: 10px; background: var(--card); color: var(--text); font-family: inherit; font-size: 13px; cursor: pointer; white-space: nowrap; }
.ad-btn:hover:not(:disabled) { background: var(--p-fafafa); }
.ad-btn:disabled { color: var(--i-a8a8a8); cursor: default; }
.ad-body { flex: 1 1 auto; min-height: 0; padding: 16px; display: flex; gap: 16px; }
.ad-empty { margin: 0; padding: 26px; text-align: center; color: var(--muted); font-size: 13px; }
.ad-muted { font-size: 12px; line-height: 17px; color: var(--muted); }
.ad-a { font-size: 12.5px; font-weight: 600; text-decoration: none; color: var(--green-ink); }
.ad-a:hover { color: var(--i-3a5507); }
.ad-link { padding: 0; border: 0; background: none; font-family: inherit; font-size: 12px; font-weight: 600; color: var(--green-ink); text-decoration: none;
  cursor: pointer; white-space: nowrap; }
.ad-link:hover { color: var(--i-3a5507); }

/* ----------------------------------------------------------------- list card (left) */
.ad-card { box-sizing: border-box; background: var(--card); border: 1px solid var(--line); border-radius: 16px; }
.ad-main { flex-grow: 1; min-width: 0; display: flex; flex-direction: column; overflow: hidden; }
.ad-scroll { flex: 0 1 auto; min-height: 0; overflow-y: auto; display: flex; flex-direction: column; }
.ad-bar { display: flex; align-items: center; gap: 10px; padding: 14px 16px; border-bottom: 1px solid var(--line-soft); }
.ad-bar h2 { margin: 0; font-size: 15px; font-weight: 600; color: var(--ink); flex-grow: 1; }
.ad-bar-note { font-size: 12.5px; color: var(--text-2); }
.ad-head { display: grid; gap: 12px; padding: 10px 16px; border-bottom: 1px solid var(--line-soft); font-size: 12px; font-weight: 600; color: var(--muted); }
.ad-row { display: grid; gap: 12px; align-items: center; width: 100%; min-height: 50px; padding: 6px 16px; box-sizing: border-box; border: 0;
  border-bottom: 1px solid var(--p-f4f4f4); background: var(--card); font-family: inherit; text-align: left; color: inherit; flex-shrink: 0; }
button.ad-row { cursor: pointer; }
button.ad-row:hover { background: var(--p-fbfcf9); }
.ad-row[aria-pressed="true"], .ad-row[aria-pressed="true"]:hover { background: var(--lime-soft); }
.ad-g-agents { grid-template-columns: 150px 112px 88px minmax(0, 1fr) minmax(0, 1fr) 110px; }
.ad-g-queues { grid-template-columns: minmax(0, 1fr) 110px 120px 130px 80px; }
.ad-g-codes { grid-template-columns: minmax(0, 1fr) 210px 150px 120px 60px; }
.ad-g-breaks { grid-template-columns: minmax(0, 1fr) 100px 90px 150px 150px 60px; }
/* İşlem geçmişi: time, who, what, the details (old → new values) */
.ad-g-audit { grid-template-columns: 116px 150px minmax(0, 1fr) minmax(0, 1.3fr); }
.ad-audit .ad-row { align-items: start; padding-top: 10px; padding-bottom: 10px; min-height: 0; }
.ad-audit .ad-cell { line-height: 17px; overflow-wrap: anywhere; }
.ad-audit .ad-bar { flex-wrap: wrap; row-gap: 8px; }
.ad-more { margin: 12px 16px; height: 32px; padding: 0 12px; border: 1px solid var(--p-e0e0e0); border-radius: 9px; background: var(--card);
  font-family: inherit; font-size: 12.5px; color: var(--text); cursor: pointer; align-self: flex-start; }
.ad-more:hover { background: var(--p-fafafa); }
.ad-row.ad-g-queues { min-height: 56px; padding: 8px 16px; }
.ad-row.ad-g-breaks { min-height: 48px; }
.ad-search { width: 220px; height: 34px; box-sizing: border-box; border: 1px solid var(--p-e0e0e0); border-radius: 10px; padding: 0 12px;
  font-family: inherit; font-size: 13px; color: var(--ink); background: var(--card); }
.ad-filter { display: flex; gap: 4px; padding: 3px; border: 1px solid var(--line); border-radius: 11px; }
.ad-filter button { height: 28px; padding: 0 10px; border: 0; border-radius: 8px; background: transparent; font-family: inherit; font-size: 12.5px;
  color: var(--text); cursor: pointer; white-space: nowrap; }
.ad-filter button[aria-pressed="true"] { background: var(--p-f1f3ee); font-weight: 600; color: var(--ink); }

/* cells */
.ad-name { font-size: 13px; font-weight: 600; color: var(--ink); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ad-name small { font-weight: 400; color: var(--muted); }
.ad-phone { display: inline-flex; align-items: center; gap: 6px; font-size: 12.5px; color: var(--text); white-space: nowrap;
  font-variant-numeric: tabular-nums; overflow: hidden; }
.ad-phone i { width: 7px; height: 7px; border-radius: 2px; flex-shrink: 0; }
.ad-pill { justify-self: start; display: inline-flex; align-items: center; height: 24px; padding: 0 9px; border-radius: 999px; font-size: 12px;
  font-weight: 700; white-space: nowrap; }
.ad-txt { font-size: 12.5px; line-height: 17px; color: var(--text); }
.ad-txt.none { color: var(--i-b0b0b0); }
.ad-now { display: inline-flex; align-items: center; gap: 6px; min-width: 0; font-size: 12.5px; color: var(--text); white-space: nowrap; }
.ad-now i { width: 7px; height: 7px; border-radius: 50%; flex-shrink: 0; }
.ad-now span { overflow: hidden; text-overflow: ellipsis; }
.ad-qname { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.ad-qname b { font-size: 13.5px; font-weight: 600; color: var(--ink); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ad-qname small { font-size: 12px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ad-tag { justify-self: start; display: inline-flex; align-items: center; height: 22px; padding: 0 8px; border-radius: 999px; font-size: 11.5px;
  font-weight: 700; white-space: nowrap; }
.ad-tag.w6 { font-weight: 600; }
.ad-cell { font-size: 12.5px; color: var(--text); }
.ad-cell.num { font-variant-numeric: tabular-nums; }
.ad-cell.ink { color: var(--ink); }
.ad-chk { display: inline-flex; align-items: center; }
.ad-chk input, .ad-opt input, .ad-check input { accent-color: var(--green-text); width: 16px; height: 16px; }
.ad-bname { display: flex; align-items: center; gap: 10px; min-width: 0; }
.ad-bname i { width: 10px; height: 10px; border-radius: 50%; background: var(--violet); flex-shrink: 0; }
.ad-bname b { font-size: 13.5px; font-weight: 600; color: var(--ink); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ad-info { margin-top: auto; display: flex; gap: 10px; align-items: flex-start; padding: 12px 16px; border-top: 1px solid var(--line-soft); }
.ad-info svg { flex-shrink: 0; margin-top: 1px; }
.ad-info span { font-size: 12.5px; line-height: 18px; color: var(--text); }
.ad-info b { font-weight: 700; }

/* result code tabs */
.ad-tabs { display: flex; align-items: center; gap: 6px; padding: 14px 16px; border-bottom: 1px solid var(--line-soft); }
.ad-tab { display: inline-flex; align-items: center; gap: 6px; height: 32px; padding: 0 12px; border-radius: 10px; border: 1px solid var(--p-e4e4e4);
  background: var(--card); font-family: inherit; font-size: 13px; font-weight: 400; color: var(--ink); cursor: pointer; white-space: nowrap; }
.ad-tab[aria-selected="true"] { border-color: var(--lime); background: var(--lime-soft); font-weight: 600; }
.ad-tab span { font-size: 12px; color: var(--muted); }

/* ----------------------------------------------------------------- right panel */
.ad-aside { flex-shrink: 0; box-sizing: border-box; background: var(--card); border: 1px solid var(--line); border-radius: 16px; padding: 18px;
  display: flex; flex-direction: column; gap: 14px; overflow: hidden; }
/* the content scrolls when it is taller than the panel; Vazgeç / Kaydet stay at the bottom */
.ad-aside-body { flex: 1 1 auto; min-height: 0; overflow-y: auto; display: flex; flex-direction: column; gap: inherit;
  margin: -4px -8px -4px -4px; padding: 4px 8px 4px 4px; }
.ad-aside-body > * { flex-shrink: 0; }
.ad-aside-body > h2 { margin: 0; font-size: 16px; font-weight: 600; color: var(--ink); }
.ad-aside.w360 { width: 360px; gap: 13px; }
.ad-aside.w380 { width: 380px; }
.ad-aside.w340 { width: 340px; }
.ad-aside > h2 { margin: 0; font-size: 16px; font-weight: 600; color: var(--ink); }
.ad-sec { display: flex; flex-direction: column; gap: 6px; }
.ad-sec.g8 { gap: 8px; }
.ad-label { font-size: 12px; font-weight: 600; color: var(--text-2); }
.ad-desc { font-size: 12px; line-height: 17px; color: var(--text); }
.ad-desc2 { font-size: 12.5px; line-height: 18px; color: var(--text); }
.ad-radio { display: grid; gap: 4px; padding: 4px; border: 1px solid var(--line); border-radius: 12px; }
.ad-radio.c2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.ad-radio.c3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.ad-radio button { height: 34px; min-width: 0; padding: 0 4px; border: 0; border-radius: 9px; background: transparent; color: var(--text); font-family: inherit;
  font-size: 13px; font-weight: 400; cursor: pointer; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ad-radio button[aria-checked="true"] { background: var(--inverse); color: var(--on-inverse); font-weight: 600; }
.ad-radio button:disabled { cursor: default; }
.ad-radio button:disabled:not([aria-checked="true"]) { color: var(--i-a8a8a8); }

/* agent profile */
.ad-prof-head { display: flex; align-items: center; gap: 12px; }
.ad-avatar { width: 42px; height: 42px; border-radius: 50%; background: var(--f-caf264); color: var(--avatar-ink); font-size: 14px; font-weight: 700;
  display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.ad-prof-id { display: flex; flex-direction: column; gap: 2px; min-width: 0; flex-grow: 1; }
.ad-prof-id h2 { margin: 0; font-size: 17px; font-weight: 600; color: var(--ink); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ad-prof-id span { font-size: 12.5px; color: var(--text-2); }
.ad-prof-head { position: relative; }
.ad-prof-head .ad-link { position: absolute; top: 3px; right: 0; }
.ad-prof-head.has-link .ad-prof-id h2 { padding-right: 52px; }
.ad-account { display: flex; flex-direction: column; gap: 10px; padding: 12px; border: 1px solid var(--p-eceee9); border-radius: 12px; background: var(--p-fafbf8); }
.ad-fs { margin: 0; padding: 0; border: 0; min-width: 0; display: flex; flex-direction: column; gap: 6px; }
.ad-fs legend { padding: 0; margin-bottom: 6px; font-size: 12px; font-weight: 600; color: var(--text-2); }
.ad-fs.off { opacity: 0.45; }
.ad-opt { display: flex; align-items: center; gap: 10px; height: 30px; font-size: 13px; color: var(--ink); }
.ad-opt .grow { flex-grow: 1; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ad-opt .meta { font-size: 12px; color: var(--muted); white-space: nowrap; }
.ad-karma { padding: 12px 14px; border-radius: 12px; background: var(--lime-soft); border: 1px solid var(--p-dcebb8); display: flex; flex-direction: column; gap: 4px; }
.ad-karma-head { display: flex; align-items: center; gap: 8px; }
.ad-karma-head b { font-size: 12.5px; font-weight: 600; color: var(--i-3a5507); flex-grow: 1; }
.ad-karma-text { font-size: 12.5px; line-height: 18px; color: var(--i-2e3a1c); }

/* footer buttons */
.ad-foot { margin-top: auto; flex-shrink: 0; display: flex; flex-direction: column; gap: 8px; }
.ad-foot > span { font-size: 12px; line-height: 17px; color: var(--muted); }
.ad-foot-btns { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
.ad-cancel, .ad-save { height: 36px; box-sizing: border-box; display: inline-flex; align-items: center; border-radius: 10px; font-family: inherit;
  font-size: 13px; cursor: pointer; white-space: nowrap; }
.ad-cancel { padding: 0 14px; border: 1px solid var(--p-e0e0e0); background: var(--card); color: var(--text); }
.ad-save { padding: 0 16px; border: 0; background: var(--lime); color: var(--lime-ink); font-weight: 700; }
.ad-cancel:hover { background: var(--p-fafafa); }
.ad-save:hover:not(:disabled) { background: var(--f-a7db2e); }
.ad-save:disabled { background: var(--p-e3eec4); color: var(--i-6f7a58); cursor: default; }
.ad-foot.big .ad-cancel, .ad-foot.big .ad-save { height: 40px; justify-content: center; border-radius: 12px; }
.ad-foot.big .ad-save { font-size: 13.5px; }

/* queue settings */
.ad-title { display: flex; flex-direction: column; gap: 2px; }
.ad-title h2 { margin: 0; font-size: 17px; font-weight: 600; color: var(--ink); }
.ad-title-input { width: 100%; box-sizing: border-box; margin: 0; padding: 0; border: 0; border-bottom: 1px dashed transparent; border-radius: 0;
  background: transparent; font-family: inherit; font-size: 17px; font-weight: 600; line-height: 1.4; color: var(--ink); outline: none; }
.ad-title-input:hover, .ad-title-input:focus { border-bottom-color: var(--p-b9c2ae); }
.ad-title-input::placeholder { color: var(--i-a8a8a8); }
.ad-sub { font-size: 12.5px; color: var(--text-2); }
.ad-dl { margin: 0; display: flex; flex-direction: column; gap: 10px; }
.ad-dl.g12 { gap: 12px; }
.ad-dl > div { display: flex; flex-direction: column; gap: 2px; }
.ad-dl dt { font-size: 12px; color: var(--muted); }
.ad-dl dd { margin: 0; font-size: 13px; line-height: 18px; color: var(--ink); }
.ad-dl dd.off { color: var(--muted); }
/* Kuyruklar: the panel in setting groups, a label and its control per row (explanations behind the (i)) */
.ad-qg { display: flex; flex-direction: column; gap: 8px; padding-top: 12px; border-top: 1px solid var(--line-soft); }
.ad-qg > h3 { margin: 0; font-size: 13px; font-weight: 600; color: var(--ink); }
.ad-qrow { display: grid; grid-template-columns: 128px minmax(0, 1fr); align-items: center; gap: 8px; min-height: 34px; }
.ad-qk { display: inline-flex; align-items: center; gap: 3px; font-size: 12.5px; color: var(--text-2); }
.ad-qv { min-width: 0; display: flex; align-items: center; flex-wrap: wrap; gap: 6px; font-size: 13px; color: var(--ink); }
.ad-qv > .ad-radio, .ad-qv > .sel-wrap, .ad-qv > .ad-input { flex: 1 1 auto; }
.ad-qv > .ad-radio button { height: 30px; }
.ad-qtext { font-size: 12.5px; line-height: 17px; color: var(--text); }
.ad-numbox { display: inline-flex; align-items: center; gap: 6px; font-size: 12.5px; color: var(--text-2); }
.ad-numbox .ad-input { width: 50px; padding: 0 8px; text-align: right; -moz-appearance: textfield; appearance: textfield; }
.ad-numbox .ad-input::-webkit-inner-spin-button, .ad-numbox .ad-input::-webkit-outer-spin-button { -webkit-appearance: none; margin: 0; }
.ad-qdet { padding-top: 12px; border-top: 1px solid var(--line-soft); }
.ad-qdet > summary { font-size: 13px; }
.ad-qdet-in { display: flex; flex-direction: column; gap: 8px; margin-top: 8px; }
.ad-pbx-box { padding: 12px 14px; border-radius: 12px; background: var(--p-f4f7fc); border: 1px solid var(--p-dfe7f4); font-size: 13px; line-height: 19px; color: var(--ink); }
.ad-member { display: flex; align-items: center; gap: 10px; min-height: 35px; border-bottom: 1px solid var(--p-f4f4f4); }   /* 34 + border */
.ad-member .no { width: 20px; height: 20px; border-radius: 50%; background: var(--p-f1f3ee); color: var(--text); font-size: 11px; font-weight: 700;
  display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.ad-member .n { flex-grow: 1; min-width: 0; font-size: 13px; font-weight: 500; color: var(--ink); }
.ad-member .p { font-size: 12px; color: var(--text-2); white-space: nowrap; }
.ad-x { width: 0; height: 22px; margin-left: -10px; padding: 0; border: 0; border-radius: 6px; background: transparent; color: var(--i-8a8a8a);
  font-size: 16px; line-height: 1; cursor: pointer; overflow: hidden; flex-shrink: 0; }
.ad-member:hover .ad-x, .ad-x:focus-visible { width: 22px; margin-left: 0; }
.ad-x:hover { background: var(--gray-bg); color: var(--red-ink); }
.ad-add { align-self: flex-start; height: 30px; margin-top: 4px; padding: 0 10px; border: 1px dashed var(--p-d6d6d6); border-radius: 9px; background: var(--card);
  font-family: inherit; font-size: 12.5px; color: var(--text); cursor: pointer; }

/* values edited in place inside a sentence: they read like the design's text, with a dashed underline */
.ad-in { box-sizing: content-box; height: 17px; margin: 0; padding: 0 1px; border: 0; border-bottom: 1px dashed var(--p-bfc7b2); border-radius: 0;
  background: transparent; font: inherit; color: inherit; vertical-align: baseline; }
.ad-in:focus { outline: none; border-bottom: 1px solid var(--green); background: var(--lime-soft); }
input.ad-in { width: 2.6ch; text-align: center; -moz-appearance: textfield; appearance: textfield; }
input.ad-in.txt { text-align: left; }
input.ad-in::-webkit-inner-spin-button, input.ad-in::-webkit-outer-spin-button { -webkit-appearance: none; margin: 0; }
input.ad-in::placeholder { color: var(--i-a8a8a8); }
select.ad-in { height: 18px; padding-right: 13px; -webkit-appearance: none; appearance: none; cursor: pointer;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='10' viewBox='0 0 24 24' fill='none' stroke='%23707070' stroke-width='2.4' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E") no-repeat right 1px center; }

/* forms in the right panel (new and edited rows) */
.ad-form { display: flex; flex-direction: column; gap: 12px; }
.ad-grid2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.ad-field { display: flex; flex-direction: column; gap: 5px; min-width: 0; }
.ad-field > span { font-size: 12px; font-weight: 600; color: var(--text-2); }
.ad-field small { font-size: 12px; line-height: 17px; color: var(--muted); }
.ad-input, .ad-select { width: 100%; height: 34px; box-sizing: border-box; border: 1px solid var(--p-e0e0e0); border-radius: 10px; padding: 0 12px;
  font-family: inherit; font-size: 13px; color: var(--ink); background: var(--card); }
.ad-input:focus, .ad-select:focus { outline: 2px solid var(--green); outline-offset: 0; border-color: transparent; }
.ad-input:disabled, .ad-select:disabled { background: var(--p-fafafa); color: var(--text-2); }
.ad-check { display: inline-flex; align-items: center; gap: 8px; font-size: 13px; color: var(--ink); cursor: pointer; }
.ad-checks { display: flex; gap: 16px; flex-wrap: wrap; }
.ad-editor-head { display: flex; align-items: flex-start; gap: 8px; }
.ad-editor-head h2 { margin: 0; flex-grow: 1; font-size: 16px; font-weight: 600; color: var(--ink); }
.ad-topic { display: flex; align-items: center; gap: 8px; }
.ad-topic .ad-input { flex-grow: 1; }

/* break rules */
.ad-rule { display: flex; align-items: flex-start; gap: 10px; font-size: 13px; line-height: 18px; color: var(--ink); }
.ad-rule > input { accent-color: var(--green-text); width: 16px; height: 16px; margin: 1px 0 0; flex-shrink: 0; }
.ad-rule > input[aria-disabled="true"] { cursor: default; }
.ad-rule > span { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.ad-rule b { font-weight: 600; }
.ad-rule small { font-size: 12.5px; line-height: 18px; color: var(--text-2); }
.ad-left { flex-grow: 1; min-width: 0; display: flex; flex-direction: column; gap: 16px; }
.ad-left > .ad-main { flex: 0 1 auto; }
.ad-sys { flex: 1 1 auto; min-height: 0; padding: 16px 18px; display: flex; flex-direction: column; gap: 10px; }
.ad-sys-head { display: flex; align-items: baseline; gap: 8px; }
.ad-sys-head h2 { margin: 0; font-size: 15px; font-weight: 600; color: var(--ink); flex-grow: 1; }
.ad-sys-head span { font-size: 12.5px; color: var(--muted); }
.ad-sys-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.ad-sys-card { padding: 12px 14px; border-radius: 12px; border: 1px solid var(--p-ececec); display: flex; flex-direction: column; gap: 6px; }
.ad-sys-card > span:last-child { font-size: 12.5px; line-height: 18px; color: var(--text); }
.ad-state { align-self: flex-start; display: inline-flex; align-items: center; gap: 6px; height: 22px; padding: 0 8px; border-radius: 999px;
  font-size: 11.5px; font-weight: 700; white-space: nowrap; }
.ad-state i { width: 6px; height: 6px; border-radius: 50%; }

/* ----------------------------------------------------------------- Santral */
.ad-col { display: flex; flex-direction: column; gap: 16px; min-height: 0; }
.ad-col.left { width: 330px; flex-shrink: 0; overflow-y: auto; }
.ad-col.right { flex-grow: 1; min-width: 0; }
.ad-box { box-sizing: border-box; background: var(--card); border: 1px solid var(--line); border-radius: 16px; padding: 16px; display: flex;
  flex-direction: column; gap: 10px; }
.ad-box.wide { padding: 16px 18px; }
.ad-box > h2, .ad-box-head h2 { margin: 0; font-size: 15px; font-weight: 600; color: var(--ink); }
.ad-box > h2.first { margin-bottom: 2px; }
.ad-box-head { display: flex; align-items: baseline; gap: 8px; }
.ad-box-head h2.grow { flex-grow: 1; }
.ad-box-head span { font-size: 12px; color: var(--muted); }
.ad-box-head span.lg { font-size: 12.5px; }
.ad-caps { gap: 6px; }
.ad-caps .ad-box-head { gap: 10px; }
.ad-conn { display: flex; flex-direction: column; gap: 6px; padding: 12px 14px; border-radius: 12px; border: 1.5px solid var(--line); background: var(--card);
  font-family: inherit; text-align: left; cursor: pointer; color: inherit; }
.ad-conn[aria-pressed="true"] { border-color: var(--lime); background: var(--lime-soft); }
.ad-conn-top { display: flex; align-items: center; gap: 8px; width: 100%; }
.ad-conn-top b { font-size: 14px; font-weight: 700; color: var(--ink); flex-grow: 1; }
.ad-st { display: inline-flex; align-items: center; gap: 5px; height: 22px; padding: 0 8px; border-radius: 999px; font-size: 11.5px; font-weight: 700;
  white-space: nowrap; }
.ad-st i { width: 6px; height: 6px; border-radius: 50%; }
.ad-conn-env { font-size: 12.5px; font-weight: 600; color: var(--text); }
.ad-conn-env.bad { color: var(--red-ink); }
/* technical details stay folded: Gelişmiş */
.ad-tech { font-size: 12px; color: var(--text-2); }
.ad-tech summary { cursor: pointer; font-weight: 600; color: var(--green-ink); padding: 2px 0; }
.ad-tech dl { margin: 6px 0 0; display: flex; flex-direction: column; gap: 4px; }
.ad-tech dl > div { display: grid; grid-template-columns: 150px minmax(0, 1fr); gap: 8px; }
.ad-tech dt { color: var(--muted); }
.ad-tech dd { margin: 0; min-width: 0; overflow-wrap: anywhere; }
.ad-tech code { font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: 11.5px; color: var(--text); }
/* unsaved changes next to Kaydet */
.ad-suggest { position: relative; }
.ad-suggest .sel-menu.ad-suggest-menu { position: absolute; top: calc(100% + 4px); left: 0; right: 0; max-height: 200px; }
.ad-warn-note { margin: -4px 0 0; padding: 8px 10px; border-radius: 10px; background: var(--p-fff8ea); border: 1px solid var(--p-f1ddae); font-size: 12px;
  line-height: 17px; color: var(--i-5c3d06); }
.ad-foot > .ad-dirty { display: inline-flex; align-items: center; gap: 6px; font-size: 12px; font-weight: 600; color: var(--amber-ink); white-space: nowrap; }
.ad-dirty i { width: 7px; height: 7px; border-radius: 50%; background: var(--amber); }
.ad-conn-meta { font-size: 12px; line-height: 17px; color: var(--text-2); overflow-wrap: anywhere; }
.ad-conn-add { display: flex; flex-direction: column; align-items: flex-start; gap: 3px; padding: 12px 14px; border-radius: 12px;
  border: 1.5px dashed var(--p-d6d6d6); background: var(--card); font-family: inherit; text-align: left; cursor: pointer; color: inherit; }
.ad-conn-add b { font-size: 13.5px; font-weight: 600; color: var(--ink); }
.ad-conn-add span { font-size: 12px; color: var(--text-2); }
.ad-big { display: flex; align-items: baseline; gap: 8px; }
.ad-big b { font-size: 24px; font-weight: 700; color: var(--ink); font-variant-numeric: tabular-nums; }
.ad-big span { font-size: 12.5px; line-height: 17px; color: var(--text); }
.ad-seats { display: flex; flex-direction: column; gap: 2px; }
.ad-seats-list { display: flex; flex-direction: column; max-height: 122px; overflow-y: auto; }
.ad-seat { display: grid; grid-template-columns: 8px minmax(0, 1fr) auto; gap: 8px; align-items: center; min-height: 24px; font-size: 12px;
  color: var(--text); border-bottom: 1px solid var(--p-f6f6f6); }
.ad-seat i { width: 7px; height: 7px; border-radius: 50%; background: var(--p-c8c8c8); }
.ad-seat i.on { background: var(--green); }
.ad-seat code { font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: 11.5px; color: var(--text); }
.ad-seat span { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ad-seat span.free { color: var(--i-a8a8a8); }
.ad-seat .ad-seat-st { font-size: 11.5px; color: var(--muted); }
.ad-seat .ad-seat-st.on { color: var(--i-3a5507); }
.ad-g-caps { grid-template-columns: minmax(0, 1fr) 124px 124px 170px; }
.ad-caps-h { display: grid; gap: 12px; padding: 6px 0; border-bottom: 1px solid var(--line-soft); font-size: 12px; font-weight: 600; color: var(--muted); }
.ad-caps-r { display: grid; gap: 12px; align-items: center; min-height: 32px; border-bottom: 1px solid var(--p-f6f6f6); }   /* 31 + border */
.ad-caps-r > span:first-child { font-size: 13px; color: var(--ink); }
.ad-caps-r > span:last-child { font-size: 12.5px; color: var(--text-2); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ad-cap { justify-self: start; display: inline-flex; align-items: center; gap: 5px; height: 22px; padding: 0 8px; border-radius: 999px;
  font-size: 11.5px; font-weight: 700; white-space: nowrap; }
.ad-legend { display: flex; flex-wrap: wrap; gap: 6px 16px; padding-top: 4px; font-size: 12px; color: var(--text-2); }
.ad-legend span { display: inline-flex; align-items: center; gap: 6px; }
.ad-legend i { width: 8px; height: 8px; border-radius: 50%; }
.ad-two { flex: 1 1 auto; min-height: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.ad-two > .ad-box { min-height: 0; overflow-y: auto; }
.ad-map { display: grid; grid-template-columns: 110px 18px minmax(0, 1fr) 70px; gap: 8px; align-items: center; min-height: 31px;
  border-bottom: 1px solid var(--p-f6f6f6); }
.ad-map code { font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: 12px; color: var(--text); white-space: nowrap; overflow: hidden;
  text-overflow: ellipsis; }
.ad-map code.none { color: var(--i-a8a8a8); }
.ad-map b { font-size: 13px; font-weight: 600; color: var(--ink); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ad-map span { font-size: 12px; color: var(--text-2); text-align: right; }
.ad-foot-note { margin-top: auto; font-size: 12px; line-height: 17px; color: var(--muted); }
.ad-ivr-list { display: flex; flex-direction: column; gap: 2px; }
.ad-ivr-list > span { font-size: 12.5px; color: var(--text-2); padding-bottom: 4px; }
.ad-ivr { display: flex; align-items: center; gap: 10px; min-height: 30px; border-left: 2px solid var(--p-e6e8e3); padding-left: 12px; }
.ad-key { width: 22px; height: 22px; border-radius: 6px; background: var(--p-f1f3ee); color: var(--ink); font-size: 12px; font-weight: 700; display: flex;
  align-items: center; justify-content: center; flex-shrink: 0; }
.ad-ivr b { font-size: 13px; font-weight: 400; color: var(--ink); flex-grow: 1; }
.ad-ivr em { display: inline-flex; align-items: center; height: 22px; padding: 0 8px; border-radius: 999px; background: var(--p-eaf1fb); color: var(--blue);
  font-size: 11.5px; font-weight: 600; font-style: normal; white-space: nowrap; }

.ad-group { padding: 16px 16px 8px; font-size: 12px; font-weight: 600; color: var(--muted); border-bottom: 1px solid var(--line-soft); flex-shrink: 0; }

/* ----------------------------------------------------------------- narrower than the design (1440): slimmer panels and columns */
@media (max-width: 1400px) and (min-width: 1101px) {
  .ad-aside.w360 { width: 340px; }
  .ad-aside.w380 { width: 340px; }
  .ad-aside.w340 { width: 310px; }
  .ad-col.left { width: 300px; }
  .ad-g-agents { grid-template-columns: 132px 104px 76px minmax(0, 1fr) minmax(0, 1fr) 104px; }
  .ad-g-queues { grid-template-columns: minmax(0, 1fr) 100px 104px 120px 64px; }
  .ad-g-codes { grid-template-columns: minmax(0, 1fr) 170px 110px 100px 44px; }
  .ad-g-breaks { grid-template-columns: minmax(0, 1fr) 84px 80px 132px 132px 44px; }
  .ad-g-caps { grid-template-columns: minmax(0, 1fr) 112px 112px 140px; }
}

/* ----------------------------------------------------------------- smaller screens: the panels stack, the page scrolls */
@media (max-height: 620px) {
  .ad-page { height: auto; min-height: 100vh; }
  .ad-main, .ad-aside, .ad-aside-body, .ad-col.left, .ad-two > .ad-box { overflow: visible; }
}
@media (max-width: 1100px) {
  .ad-page { height: auto; min-height: 100vh; }
  .ad-body { flex-direction: column; }
  .ad-aside.w360, .ad-aside.w380, .ad-aside.w340, .ad-col.left { width: auto; }
  .ad-aside, .ad-aside-body, .ad-col.left, .ad-two > .ad-box { overflow: visible; }
  .ad-main { overflow-x: auto; }
  .ad-scroll { min-width: 760px; }
  .ad-main .ad-head { min-width: 760px; }
}
@media (max-width: 700px) {
  .top.ad-top { gap: 8px 16px; }
  .ad-top .top-tabs { max-width: 100%; overflow-x: auto; }
  .ad-filter { max-width: 100%; overflow-x: auto; }
  .ad-body { padding: 12px 16px; }
  .ad-two, .ad-sys-grid { grid-template-columns: minmax(0, 1fr); }
  .ad-bar { flex-wrap: wrap; }
  .ad-search { width: 100%; }
}

/* rows with a checkbox: the name opens the editor */
.ad-row[aria-selected="true"] { background: var(--lime-soft); }
div.ad-row.ad-g-codes, div.ad-row.ad-g-breaks { cursor: pointer; }
div.ad-row.ad-g-codes:hover, div.ad-row.ad-g-breaks:hover { background: var(--p-fbfcf9); }
div.ad-row[aria-selected="true"]:hover { background: var(--lime-soft); }
.ad-rowbtn { margin: 0; padding: 0; border: 0; background: none; font: inherit; color: inherit; text-align: left; cursor: pointer; min-width: 0; }

/* ----------------------------------------------------------------- Otomasyonlar (automations.js): list, AI agents, the rule editor */
.ad-aside.w440 { width: 440px; }
.ad-btn.sm { height: 30px; padding: 0 11px; font-size: 12.5px; border-radius: 9px; }
.ad-empty.sm { padding: 16px; }
.au-left { min-width: 0; }
.au-left > .au-list { flex: 1 1 auto; min-height: 0; }
.au-left > .au-ai { flex-shrink: 0; display: flex; flex-direction: column; max-height: 40%; overflow-y: auto; }
.au-g { grid-template-columns: minmax(0, 1fr) 150px 96px 96px; }
.au-g-ai { grid-template-columns: minmax(0, 1fr) 150px 70px 64px; }
div.ad-row.au-g { cursor: pointer; min-height: 58px; padding: 8px 16px; }
div.ad-row.au-g:hover { background: var(--p-fbfcf9); }
div.ad-row.au-g[aria-pressed="true"] { background: var(--lime-soft); }
div.ad-row.au-g:focus-visible { outline: 2px solid var(--green); outline-offset: -2px; }
.au-group { display: flex; align-items: baseline; gap: 8px; color: var(--ink); font-size: 12.5px; }
.au-group span { font-weight: 400; color: var(--muted); }
.au-name { display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.au-name b { font-size: 13.5px; font-weight: 600; color: var(--ink); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.au-name small { font-size: 12px; line-height: 16px; color: var(--text-2); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical;
  overflow: hidden; }
.au-last { display: block; margin-top: 2px; font-size: 11.5px; color: var(--i-8a8a8a); white-space: nowrap; }
.au-ctl { display: flex; align-items: center; justify-content: flex-end; gap: 8px; }
.au-order { display: inline-flex; gap: 2px; }
.au-order button { width: 22px; height: 22px; padding: 0; border: 1px solid var(--p-e4e4e4); border-radius: 6px; background: var(--card); color: var(--text-2);
  font-size: 12px; line-height: 1; cursor: pointer; }
.au-order button:hover:not(:disabled) { background: var(--p-f4f6f1); color: var(--ink); }
.au-order button:disabled { opacity: 0.35; cursor: default; }
.au-switch { position: relative; width: 36px; height: 20px; padding: 0; border: 0; border-radius: 999px; background: var(--p-d5d5d5); cursor: pointer;
  flex-shrink: 0; transition: background 0.15s; }
.au-switch i { position: absolute; top: 2px; left: 2px; width: 16px; height: 16px; border-radius: 50%; background: var(--card);
  box-shadow: 0 1px 2px var(--shade-25); transition: left 0.15s; }
.au-switch[aria-checked="true"] { background: var(--green); }
.au-switch[aria-checked="true"] i { left: 18px; }
.au-switch:disabled { cursor: default; opacity: 0.6; }
.au-switch:focus-visible { outline: 2px solid var(--green); outline-offset: 2px; }
.au-code { font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: 12px; color: var(--text); }
.au-hello { gap: 12px; }
.au-hello p { margin: 0; }
.au-start { align-self: flex-start; padding: 0 16px; }
/* templates */
.au-tpls { gap: 14px; }
.au-tpl-group { display: flex; flex-direction: column; gap: 8px; }
.au-tpl-group h3 { margin: 0; font-size: 12px; font-weight: 600; color: var(--muted); }
.au-tpl { display: flex; flex-direction: column; gap: 3px; padding: 11px 13px; border: 1px solid var(--line); border-radius: 12px; background: var(--card);
  font-family: inherit; text-align: left; color: inherit; cursor: pointer; }
.au-tpl:hover { border-color: var(--p-cfe68e); background: var(--p-fbfdf5); }
.au-tpl b { font-size: 13.5px; font-weight: 600; color: var(--ink); }
.au-tpl span { font-size: 12.5px; line-height: 17px; color: var(--text); }
.au-tpl em { font-style: normal; font-size: 11.5px; font-weight: 600; color: var(--green-ink); }
.au-tpl.blank { border-style: dashed; }
/* the editor */
.au-title-row { display: flex; align-items: center; gap: 10px; }
.au-title-row > .ad-title-input, .au-title-row > h2 { flex-grow: 1; min-width: 0; }
.au-del { color: var(--red-ink); }
.au-del:hover { color: var(--i-8f1b1b); }
.au-del.sure { padding: 3px 8px; border-radius: 7px; background: var(--p-fdecec); }
.au-sentence { line-height: 18px; }
.ad-qg > h3 .au-h-note { margin-left: 6px; font-size: 12px; font-weight: 400; color: var(--muted); }
.au-scope { gap: 5px; }
.au-scope .chip-toggle { height: 28px; padding: 0 10px; font-size: 12px; }
.au-scope .chip-toggle small { font-weight: 400; color: var(--muted); }
.au-scope .chip-toggle:disabled { cursor: default; }
.au-cond, .au-act { display: flex; flex-direction: column; gap: 6px; padding: 8px; border: 1px solid var(--p-eceee9); border-radius: 12px; background: var(--p-fafbf8); }
.au-cond-1 { display: flex; align-items: center; gap: 6px; }
.au-cond-1 > .sel-wrap:first-child { flex: 1 1 auto; }
.au-cond-1 > .sel-wrap:nth-child(2) { flex: 0 0 132px; }
.au-cond-2, .au-act-2 { display: flex; align-items: center; flex-wrap: wrap; gap: 6px; }
.au-cond-2 > .ad-input, .au-act-2 > .ad-input, .au-act-2 > .sel-wrap, .au-act-2 > .ad-radio { flex: 1 1 auto; }
.au-cond .ad-select, .au-act .ad-select, .au-cond .ad-input, .au-act .ad-input { height: 32px; background: var(--card); }
.au-act .ad-radio button { height: 28px; }
.au-x { width: 26px; height: 26px; padding: 0; border: 0; border-radius: 7px; background: transparent; color: var(--i-8a8a8a); font-size: 17px;
  line-height: 1; cursor: pointer; flex-shrink: 0; }
.au-x:hover { background: var(--gray-bg); color: var(--red-ink); }
.au-range { display: inline-flex; align-items: center; gap: 6px; }
.au-range .sel-wrap { width: 96px; }
.au-days { display: inline-flex; flex-wrap: wrap; gap: 4px; }
.au-days button { height: 28px; min-width: 40px; padding: 0 8px; border: 1px solid var(--p-e0e0e0); border-radius: 8px; background: var(--card);
  font-family: inherit; font-size: 12px; color: var(--text); cursor: pointer; }
.au-days button[aria-pressed="true"] { border-color: var(--p-cfe68e); background: var(--p-f1f8dd); color: var(--i-3a5507); font-weight: 600; }
.au-days button:disabled { cursor: default; }
.au-list-in { height: auto; min-height: 52px; padding: 7px 12px; line-height: 18px; resize: vertical; }
.au-short { max-width: 180px; }
.au-act-1 { display: flex; align-items: center; gap: 6px; min-height: 26px; }
.au-act-1 b { font-size: 13px; font-weight: 600; color: var(--ink); }
.au-act-1 .grow { flex-grow: 1; }
.au-no { width: 20px; height: 20px; border-radius: 50%; background: var(--p-e9efdc); color: var(--i-3a5507); font-size: 11px; font-weight: 700; display: flex;
  align-items: center; justify-content: center; flex-shrink: 0; }
.au-warn { font-size: 12px; line-height: 17px; color: var(--amber-ink); }
.au-test > summary { font-weight: 600; color: var(--green-ink); cursor: pointer; }
.au-try { align-self: flex-start; }
.au-result { display: flex; flex-direction: column; gap: 6px; padding: 10px 12px; border-radius: 12px; border: 1px solid var(--line); background: var(--p-f7f7f7); }
.au-result.yes { border-color: var(--p-cfe68e); background: var(--lime-soft); }
.au-result > b { font-size: 13.5px; color: var(--ink); }
.au-result ul { margin: 0; padding: 0; list-style: none; display: flex; flex-direction: column; gap: 3px; }
.au-result li { position: relative; padding-left: 18px; font-size: 12.5px; line-height: 17px; color: var(--text); }
.au-result li::before { position: absolute; left: 0; top: 0; font-weight: 700; }
.au-result li.ok::before { content: '✓'; color: var(--green-ink); }
.au-result li.no::before { content: '✗'; color: var(--red-ink); }
.au-result > span { font-size: 12.5px; line-height: 17px; color: var(--ink); }
.au-result > small { font-size: 11.5px; color: var(--muted); }
.au-run { display: grid; grid-template-columns: 92px minmax(0, 1fr); gap: 8px; padding: 6px 0; border-bottom: 1px solid var(--p-f4f4f4); }
.au-run-t { font-size: 12px; color: var(--muted); font-variant-numeric: tabular-nums; }
.au-run-b { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.au-run-b b { font-size: 12.5px; font-weight: 600; color: var(--ink); }
.au-run-b small { font-size: 12px; line-height: 16px; }
.au-run-b small.ok { color: var(--i-3a5507); }
.au-run-b small.no { color: var(--i-8f1b1b); }
.au-use { align-self: flex-start; }
/* Kuyruklar › Otomasyonlar */
.ad-qauto { display: flex; flex-direction: column; gap: 2px; padding: 7px 0; border-bottom: 1px solid var(--p-f4f4f4); text-decoration: none; color: inherit; }
.ad-qauto b { font-size: 13px; font-weight: 600; color: var(--ink); }
.ad-qauto b em { font-style: normal; font-weight: 400; color: var(--i-8a8a8a); }
.ad-qauto small { font-size: 12px; line-height: 16px; color: var(--text-2); }
.ad-qauto:hover b { color: var(--green-ink); }
@media (max-width: 1400px) and (min-width: 1101px) {
  .ad-aside.w440 { width: 400px; }
  .au-g { grid-template-columns: minmax(0, 1fr) 120px 84px 92px; }
}
@media (max-width: 1100px) {
  .ad-aside.w440 { width: auto; }
  .au-left > .au-ai { max-height: none; }
}

/* Yönetim header: with seven tabs the row is wider than a narrow window; the tabs scroll, the add button stays */
@media (max-width: 1280px) {
  .ad-top .top-tabs { min-width: 0; overflow-x: auto; scrollbar-width: none; }
  .ad-top .top-tabs::-webkit-scrollbar { display: none; }
  .ad-top .top-tabs a { flex-shrink: 0; }
  .ad-top .title, .ad-top .ad-btn { flex-shrink: 0; }
}
