/* ==========================================================================
   Groyt Dashboard — 30 Eylül (3): Oylama, Otomatik Cevap, Yetkili
   İstatistikleri, Jail, Sayaçlar, Rol Log.
   --------------------------------------------------------------------------
   Renkler style.css tokenlarından; vurgu Groyt kehribarı (#FFC107 = --blue).
   Düzen kararları viewport'a değil gerçek kap genişliğine (container query)
   göre: ayarlar paneli geniş ekranda bile ~680px. Esnek (flex-wrap ile
   kendiliğinden daralan) dar sütun yok; ızgaralar sabit sütun sayılı.
   ========================================================================== */
.p3 {
  --p3-amber: #FFC107;
  --p3-amber-soft: rgba(255, 193, 7, 0.1);
  --p3-amber-line: rgba(255, 193, 7, 0.34);
  --p3-green: #34d399;
  --p3-red: #f87171;
  --p3-line: rgba(255, 255, 255, 0.08);
  container: p3sec / inline-size;
}
.p3 :focus-visible,
.p3-wide-drawer :focus-visible,
.p3-side-drawer :focus-visible,
.p3-dialog :focus-visible,
.p3-jump-card:focus-visible { outline: 2px solid var(--blue-bright); outline-offset: 2px; }
.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; }

/* ------------------------------------------------------------ ortak parçalar */
.p3-subhead { display: flex; align-items: flex-end; justify-content: space-between; gap: 12px; margin-top: 8px; }
.p3-subhead-title { font-size: 15.5px; font-weight: 700; color: var(--text-primary); display: flex; align-items: center; gap: 8px; }
.p3-subhead-desc { font-size: 12.5px; color: var(--text-tertiary); margin-top: 2px; }
.p3-tab-count { display: inline-grid; place-items: center; min-width: 20px; padding: 0 6px; height: 20px; border-radius: 999px; font-size: 11.5px; font-weight: 700; background: rgba(255, 255, 255, 0.08); color: var(--text-secondary); }
.p3-tab-count:empty { display: none; }
.modlog-type-tab.active .p3-tab-count { background: rgba(255, 218, 71, 0.2); color: var(--text-primary); }

.p3-card { padding: 16px 18px; border-radius: var(--radius-sm); background: var(--surface); border: 1px solid var(--border); display: flex; flex-direction: column; gap: 14px; }
.p3-card-title { display: flex; align-items: center; gap: 8px; font-weight: 700; font-size: 14.5px; }
.p3-list { display: flex; flex-direction: column; gap: 10px; }
.p3-grid-2 { display: grid; grid-template-columns: minmax(0, 1fr); gap: 14px; }
.p3-grid-2 > .form-group { margin-bottom: 0; }
@container p3sec (min-width: 600px) { .p3-grid-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@container gwed (min-width: 600px) { .p3-grid-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); } }

.p3-badge { display: inline-flex; align-items: center; gap: 4px; padding: 2px 9px; border-radius: 999px; font-size: 11.5px; font-weight: 600; white-space: nowrap; background: rgba(255, 255, 255, 0.07); border: 1px solid var(--border-strong); color: var(--text-secondary); }
.p3-badge.is-amber { background: rgba(255, 193, 7, 0.1); border-color: rgba(255, 193, 7, 0.34); color: var(--blue-bright); }
.p3-badge:empty { display: none; }

.p3-strip { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 12px 16px; border-radius: var(--radius-sm); font-size: 13.5px; line-height: 1.5; border: 1px solid; }
.p3-strip > span { min-width: 0; }
/* Düğmesiz şerit düz paragraf gibi aksın (metin parçaları flex öğesine bölünmesin). */
.p3-strip:not(:has(> .btn, > button)) { display: block; }
.p3-strip.is-info { background: rgba(96, 165, 250, 0.08); border-color: rgba(96, 165, 250, 0.3); color: #bfdbfe; }
.p3-strip.is-warn { background: rgba(240, 178, 50, 0.1); border-color: rgba(240, 178, 50, 0.38); color: #f7d58a; }
.p3-strip.is-error { background: rgba(239, 68, 68, 0.1); border-color: rgba(239, 68, 68, 0.32); color: #fca5a5; }
.p3-strip.is-success { background: rgba(52, 211, 153, 0.09); border-color: rgba(52, 211, 153, 0.32); color: #86efac; }
.p3-strip.is-muted { background: var(--surface); border-color: var(--border); color: var(--text-secondary); }
.p3-strip .btn { flex-shrink: 0; }

.p3-hint { font-size: 13px; margin: 0; color: var(--text-secondary); }
.p3-hint[hidden] { display: none; }
.p3-hint.is-success { color: #86efac; }
.p3-hint.is-error { color: #fca5a5; }
.p3-hint.is-warn { color: #f7d58a; }
.p3-hint a { color: var(--blue-bright); font-weight: 600; text-decoration: underline; text-underline-offset: 3px; }
.p3-actions { display: flex; align-items: center; gap: 10px; }
.p3-savebar { position: sticky; bottom: 12px; z-index: 5; display: flex; align-items: center; gap: 10px; padding: 12px 14px; border-radius: var(--radius-sm); background: rgba(9, 11, 20, 0.94); border: 1px solid var(--border-strong); backdrop-filter: blur(10px); }
.p3-savebar .p3-hint { flex: 1; min-width: 0; }

.p3-counter { font-size: 11.5px; color: var(--text-tertiary); font-variant-numeric: tabular-nums; white-space: nowrap; }
.p3-counter.is-near { color: #f7d58a; }
.p3-field-error { margin: 6px 0 0; font-size: 12.5px; color: #fca5a5; }
.has-error > .form-input, .has-error > .form-textarea, .has-error > .form-select,
.has-error input.form-input, .has-error textarea.form-textarea { border-color: rgba(248, 113, 113, 0.65); }
.has-error .ar-chip-input, .has-error .chip-select-summary { border-color: rgba(248, 113, 113, 0.65); }

.p3-link-btn { padding: 0; background: none; border: 0; font: inherit; font-size: 12.5px; font-weight: 600; color: var(--blue-bright); text-decoration: underline; text-underline-offset: 3px; cursor: var(--c-link); }
.p3-icon-btn { display: inline-grid; place-items: center; width: 36px; height: 36px; flex-shrink: 0; border-radius: 9px; background: var(--surface); border: 1px solid var(--border); color: var(--text-secondary); font-size: 14px; cursor: var(--c-link); transition: background-color 0.15s, color 0.15s, border-color 0.15s; }
.p3-icon-btn:hover:not(:disabled) { background: var(--surface-strong); color: var(--text-primary); border-color: var(--border-strong); }
.p3-icon-btn.is-danger:hover:not(:disabled) { background: rgba(239, 68, 68, 0.14); color: #fca5a5; border-color: rgba(248, 113, 113, 0.38); }
.p3-icon-btn:disabled { opacity: 0.4; cursor: var(--c-unavail); }
.p3-handle { display: inline-grid; place-items: center; width: 28px; height: 36px; flex-shrink: 0; border-radius: 8px; background: none; border: 1px dashed transparent; color: var(--text-tertiary); font-size: 14px; letter-spacing: -3px; cursor: var(--c-move); touch-action: none; }
.p3-handle:hover:not(:disabled), .p3-handle:focus-visible { color: var(--text-primary); border-color: var(--border-strong); }
.p3-handle:disabled { cursor: var(--c-normal); opacity: 0.3; }
[data-sort-item].is-dragging { opacity: 0.85; border-color: var(--p3-amber-line, rgba(255, 193, 7, 0.34)) !important; box-shadow: 0 10px 26px -12px rgba(0, 0, 0, 0.7); }

/* Çipler (süre, bekleme) — dokunma hedefi en az 40px, mobilde 44px */
.p3-chips { display: grid; grid-template-columns: repeat(auto-fill, minmax(76px, 1fr)); gap: 8px; }
.p3-chip { min-height: 40px; padding: 6px 12px; border-radius: 10px; font: inherit; font-size: 13px; font-weight: 600; white-space: nowrap; background: var(--surface); border: 1px solid var(--border); color: var(--text-secondary); cursor: var(--c-link); transition: background-color 0.15s, color 0.15s, border-color 0.15s; }
.p3-chip:hover:not(:disabled) { color: var(--text-primary); border-color: var(--border-strong); }
.p3-chip.is-active { background: rgba(255, 193, 7, 0.14); border-color: rgba(255, 193, 7, 0.55); color: var(--text-primary); }
.p3-chip:disabled { opacity: 0.4; cursor: var(--c-unavail); }
.p3-chip-sm { min-height: 32px; padding: 4px 10px; font-size: 12.5px; font-family: ui-monospace, SFMono-Regular, Menlo, monospace; }

/* Segment seçici */
.p3-seg { display: grid; grid-auto-flow: column; grid-auto-columns: minmax(0, 1fr); gap: 4px; padding: 4px; border-radius: 12px; background: rgba(255, 255, 255, 0.03); border: 1px solid var(--border); }
.p3-seg button { min-height: 38px; padding: 6px 12px; border-radius: 9px; font: inherit; font-size: 13px; font-weight: 600; white-space: nowrap; background: none; border: 0; color: var(--text-secondary); cursor: var(--c-link); transition: background-color 0.15s, color 0.15s; }
.p3-seg button:hover { color: var(--text-primary); background: rgba(255, 255, 255, 0.05); }
.p3-seg button.is-active { background: linear-gradient(120deg, var(--blue), var(--blue-bright)); color: #1a1408; }
.p3-seg-sm button { min-height: 32px; font-size: 12.5px; padding: 4px 10px; }

.p3-inline-toggle { display: flex; align-items: center; gap: 12px; min-height: 44px; font-size: 13.5px; color: var(--text-primary); cursor: var(--c-link); }
.p3-inline-toggle small { color: var(--text-tertiary); }
.p3-mini-switch { display: inline-flex; align-items: center; gap: 6px; font-size: 12px; font-weight: 600; color: var(--text-secondary); cursor: var(--c-link); white-space: nowrap; }
.p3-mini-switch input { width: 16px; height: 16px; accent-color: var(--blue); }
.p3-preview-switches { display: flex; gap: 14px; }
.gw-pane-head:has(.p3-preview-switches) { align-items: center; }

/* Seçim kartları (eşleşme kipi, kategori türü) */
.p3-choice-cards { display: grid; grid-template-columns: minmax(0, 1fr); gap: 10px; }
@container p3sec (min-width: 540px) { .p3-choice-cards { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@container gwed (min-width: 540px) { .p3-choice-cards { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.p3-choice { position: relative; display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 12px; align-items: center; min-height: 56px; padding: 12px 14px; border-radius: var(--radius-sm); background: var(--surface); border: 1.5px solid var(--border); cursor: var(--c-link); transition: border-color 0.2s var(--ease), background-color 0.2s var(--ease); }
.p3-choice:not(:has(.p3-choice-icon)) { grid-template-columns: minmax(0, 1fr); }
.p3-choice:hover { border-color: var(--border-strong); }
.p3-choice input { position: absolute; opacity: 0; pointer-events: none; }
.p3-choice:has(input:focus-visible) { box-shadow: 0 0 0 3px rgba(255, 193, 7, 0.35); }
.p3-choice.is-selected, .p3-choice:has(input:checked) { border-color: rgba(255, 193, 7, 0.7); background: rgba(255, 193, 7, 0.07); }
.p3-choice-icon { display: grid; place-items: center; width: 38px; height: 38px; border-radius: 10px; font-size: 19px; background: var(--surface-strong); }
.p3-choice-text { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.p3-choice-text strong { font-size: 13.5px; }
.p3-choice-text small { font-size: 12px; line-height: 1.45; color: var(--text-tertiary); }

.p3-search { position: relative; display: block; }
.p3-search svg { position: absolute; left: 12px; top: 50%; width: 16px; height: 16px; transform: translateY(-50%); color: var(--text-tertiary); pointer-events: none; }
.p3-search .form-input { padding-left: 38px; }

.p3-empty { display: flex; flex-direction: column; align-items: center; gap: 12px; padding: 32px 20px; text-align: center; border-radius: var(--radius-sm); background: var(--surface); border: 1px dashed var(--border-strong); color: var(--text-secondary); }
.p3-empty p { margin: 0; max-width: 52ch; line-height: 1.6; }
.p3-empty-icon { font-size: 34px; }
.p3-empty-search { margin: 0; color: var(--text-tertiary); font-size: 13.5px; }
.p3-avatar { width: 34px; height: 34px; border-radius: 50%; object-fit: cover; flex-shrink: 0; background: var(--surface-strong); }
.p3-avatar-sm { width: 28px; height: 28px; }
.p3-avatar-fallback { display: inline-grid; place-items: center; font-size: 12px; font-weight: 700; color: var(--text-secondary); }
.p3-premium-card { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; gap: 14px; align-items: center; padding: 16px 18px; border-radius: var(--radius-sm); background: radial-gradient(120% 160% at 0% 0%, rgba(255, 193, 7, 0.16), transparent 60%), var(--surface); border: 1px solid rgba(255, 193, 7, 0.4); }
.p3-premium-card p { margin: 2px 0 0; font-size: 13px; color: var(--text-secondary); }
.p3-premium-icon { font-size: 26px; }
.p3-premium-card[hidden] { display: none; }

/* İskelet (yükleniyor) */
.p3-skeleton { pointer-events: none; min-height: 72px; }
.sk-block { display: block; height: 14px; border-radius: 7px; width: 70%; background: linear-gradient(90deg, rgba(255, 255, 255, 0.04) 25%, rgba(255, 255, 255, 0.09) 50%, rgba(255, 255, 255, 0.04) 75%); background-size: 200% 100%; animation: p3Shimmer 1.3s linear infinite; }
.sk-block.w60 { width: 60%; } .sk-block.w40 { width: 40%; } .sk-block.w20 { width: 20%; } .sk-block.w10 { width: 10%; }
@keyframes p3Shimmer { to { background-position: -200% 0; } }

/* Oto-Mod'dan yeni sayfaya geçiş kartı */
.p3-jump-card { display: grid; grid-template-columns: 44px minmax(0, 1fr) auto; gap: 14px; align-items: center; width: 100%; padding: 14px 16px; border-radius: var(--radius-sm); text-align: left; font: inherit; color: inherit; cursor: var(--c-link); background: linear-gradient(120deg, rgba(255, 193, 7, 0.1), rgba(255, 255, 255, 0.02)); border: 1px solid rgba(255, 193, 7, 0.34); transition: transform 0.25s var(--ease), border-color 0.2s; }
.p3-jump-card:hover { transform: translateY(-1px); border-color: rgba(255, 218, 71, 0.7); }
.p3-jump-icon { display: grid; place-items: center; width: 44px; height: 44px; border-radius: 12px; font-size: 22px; background: var(--surface-strong); }
.p3-jump-text { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.p3-jump-text small { font-size: 12.5px; color: var(--text-tertiary); }
.p3-jump-arrow { color: var(--blue-bright); font-size: 18px; }

/* Bildirim */
.p3-toast { position: fixed; left: 50%; bottom: 28px; z-index: 400; transform: translateX(-50%); max-width: min(560px, calc(100vw - 32px)); padding: 12px 18px; border-radius: 14px; font-size: 14px; font-weight: 600; line-height: 1.45; color: #1a1408; background: linear-gradient(120deg, var(--blue), var(--blue-bright)); box-shadow: 0 14px 30px -10px rgba(255, 193, 7, 0.6); animation: p3ToastIn 0.25s var(--ease); }
.p3-toast.is-error { color: #fff; background: #b91c1c; box-shadow: 0 14px 30px -10px rgba(185, 28, 28, 0.6); }
.p3-toast a { color: inherit; text-decoration: underline; }
.p3-toast[hidden] { display: none; }
@keyframes p3ToastIn { from { opacity: 0; transform: translate(-50%, 8px); } }

/* Onay penceresi */
.p3-dialog-overlay { position: fixed; inset: 0; z-index: 350; display: grid; place-items: center; padding: 16px; background: rgba(5, 6, 11, 0.76); backdrop-filter: blur(4px); animation: member-card-fade 0.18s var(--ease); }
.p3-dialog-overlay[hidden] { display: none; }
.p3-dialog { width: min(480px, 100%); padding: 22px 22px 18px; border-radius: var(--radius-md); background: var(--bg-alt); border: 1px solid var(--border-strong); box-shadow: 0 30px 80px -20px rgba(0, 0, 0, 0.8); display: flex; flex-direction: column; gap: 12px; }
.p3-dialog-title { margin: 0; font-size: 17px; }
.p3-dialog-text { font-size: 14px; line-height: 1.6; color: var(--text-secondary); }
.p3-dialog-text strong { color: var(--text-primary); }
.p3-dialog-input { margin: 0; }
.p3-dialog-actions { display: flex; justify-content: flex-end; gap: 8px; margin-top: 4px; }

/* Çekmeceler */
.p3-wide-drawer { padding-top: 26px; }
.p3-side-drawer { width: min(520px, 100%); }
.p3-drawer-head { margin-bottom: 0; }
/* Kapat düğmesi (sağ üst, 32px) başlıklara binmesin. */
.p3-wide-drawer .gw-pane-head, .p3-wide-drawer .p3-drawer-head { padding-right: 44px; }

/* ======================================================= A) OYLAMA */
.p3-editor .gw-form-pane { gap: 16px; }
.pl-options { display: flex; flex-direction: column; gap: 8px; }
.pl-option { display: grid; grid-template-columns: 28px 30px minmax(0, 1fr) 36px; gap: 8px; align-items: center; padding: 4px; border-radius: 12px; border: 1px solid transparent; background: transparent; }
.pl-option-badge { font-size: 20px; text-align: center; }
.pl-option.has-error .form-input { border-color: rgba(248, 113, 113, 0.65); }
.pl-option .p3-field-error { grid-column: 3 / -1; margin-top: 0; }
.p3-lock-note { color: #f7d58a; }
.pl-card .pl-desc { line-height: 1.55; }
.pl-card .pl-desc .dc-emoji { width: 18px; height: 18px; vertical-align: -4px; }
.pl-card .pl-desc .dc-subtext, .gw-card .dc-subtext { font-size: 12px; color: #949ba4; }
.pl-card .dc-h { color: #f2f3f5; font-weight: 700; }
.pl-card .dc-blank { height: 0.5em; }
.pl-button-row { margin-top: 6px; }
.pl-button-row + .pl-button-row { margin-top: 6px; }

.pl-row { display: grid; grid-template-columns: 52px minmax(0, 1fr) auto; grid-template-areas: "thumb main creator" "actions actions actions"; gap: 10px 14px; align-items: center; padding: 14px 16px; border-radius: var(--radius-sm); background: var(--surface); border: 1px solid var(--border); }
.pl-row.is-ended { background: rgba(255, 255, 255, 0.025); }
.pl-thumb { grid-area: thumb; width: 52px; height: 52px; border-radius: 10px; object-fit: cover; background: var(--surface-strong); }
.pl-thumb-empty { display: grid; place-items: center; font-size: 24px; }
.pl-main { grid-area: main; min-width: 0; display: flex; flex-direction: column; gap: 4px; }
.pl-title { display: flex; align-items: center; gap: 6px; min-width: 0; }
.pl-title strong { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; font-size: 14.5px; line-height: 1.35; overflow-wrap: anywhere; }
.pl-meta { font-size: 12.5px; color: var(--text-tertiary); }
.pl-lead { display: grid; grid-template-columns: minmax(0, 1fr) auto; grid-template-areas: "label label" "bar pct"; gap: 4px 10px; align-items: center; font-size: 12.5px; color: var(--text-secondary); }
.pl-lead-label { grid-area: label; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pl-lead-pct { grid-area: pct; font-variant-numeric: tabular-nums; font-weight: 700; color: var(--text-primary); }
.pl-lead-empty { display: block; color: var(--text-tertiary); }
.pl-mini-bar { grid-area: bar; display: block; height: 6px; border-radius: 999px; background: var(--surface-strong); overflow: hidden; }
.pl-mini-bar > span { display: block; height: 100%; border-radius: 999px; background: var(--blue); }
.pl-creator { grid-area: creator; }
.pl-actions { grid-area: actions; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 6px; }
.pl-actions .btn { justify-content: center; }
@container p3sec (min-width: 600px) {
  .pl-actions { display: flex; justify-content: flex-end; }
  .pl-lead { grid-template-columns: minmax(0, 1fr) minmax(80px, 160px) auto; grid-template-areas: "label bar pct"; }
}
.pl-actions .btn { white-space: nowrap; }
@container p3sec (min-width: 860px) {
  .pl-row { grid-template-columns: 52px minmax(0, 1fr) auto auto; grid-template-areas: "thumb main creator actions"; }
}

/* ================================================ C) OTOMATİK CEVAP */
.ar-toolbar { gap: 12px; }
.ar-toolbar-row { display: grid; grid-template-columns: minmax(0, 1fr) auto auto; gap: 14px; align-items: center; }
.ar-toolbar-toggle { display: flex; align-items: center; gap: 12px; }
.ar-toolbar-toggle-text { display: flex; flex-direction: column; }
.ar-count { font-size: 13.5px; color: var(--text-secondary); white-space: nowrap; display: inline-flex; align-items: center; gap: 8px; }
.ar-count strong { font-size: 16px; color: var(--text-primary); font-variant-numeric: tabular-nums; }

.ar-row { display: grid; grid-template-columns: 12px minmax(0, 1fr); grid-template-areas: "dot main" ". actions"; gap: 10px 12px; align-items: center; padding: 14px 16px; border-radius: var(--radius-sm); background: var(--surface); border: 1px solid var(--border); }
.ar-row.is-off .ar-main { opacity: 0.6; }
.ar-dot { grid-area: dot; width: 10px; height: 10px; border-radius: 50%; background: #80848e; align-self: start; margin-top: 6px; }
.ar-dot.is-on { background: #23a55a; box-shadow: 0 0 0 3px rgba(35, 165, 90, 0.18); }
.ar-main { grid-area: main; min-width: 0; display: flex; flex-direction: column; gap: 4px; }
.ar-title { display: flex; align-items: center; gap: 8px; min-width: 0; }
.ar-title strong { font-size: 15px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ar-meta { font-size: 12.5px; color: var(--text-tertiary); }
.ar-snippet { font-size: 13px; color: var(--text-secondary); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ar-actions { grid-area: actions; display: flex; align-items: center; justify-content: flex-end; gap: 10px; }
@container p3sec (min-width: 640px) {
  .ar-row { grid-template-columns: 12px minmax(0, 1fr) auto; grid-template-areas: "dot main actions"; }
}

.ar-chip-input { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; min-height: 46px; padding: 6px 8px; border-radius: 10px; background: rgba(255, 255, 255, 0.03); border: 1px solid var(--border-strong); cursor: var(--c-text); }
.ar-chip-input:focus-within { border-color: rgba(255, 218, 71, 0.5); }
.ar-chips { display: contents; }
.ar-chip-input input { flex: 1 0 180px; min-width: 0; height: 32px; padding: 0 6px; background: none; border: 0; color: var(--text-primary); font: inherit; font-size: 14px; outline: none; }
.word-chip.is-conflict { background: rgba(239, 68, 68, 0.16); border-color: rgba(248, 113, 113, 0.6); color: #fecaca; }

.ar-replies { display: flex; flex-direction: column; gap: 10px; }
.ar-reply { display: grid; grid-template-columns: 28px minmax(0, 1fr) 36px; gap: 8px; align-items: start; padding: 10px; border-radius: 12px; background: var(--surface); border: 1px solid var(--border); }
.ar-reply .p3-handle, .ar-reply .p3-icon-btn { margin-top: 22px; }
.ar-reply-body { min-width: 0; display: flex; flex-direction: column; gap: 4px; }
.ar-reply-body .form-textarea { min-height: 64px; }
.ar-reply .p3-field-error { grid-column: 2 / -1; }
.ar-replies-foot { display: grid; grid-template-columns: auto minmax(0, 260px); justify-content: space-between; gap: 12px; align-items: center; margin-top: 10px; }
.ar-vars { display: flex; flex-direction: column; gap: 6px; margin-top: 12px; }
.ar-var-chips { display: flex; flex-wrap: wrap; gap: 6px; }
.ar-var-chips .p3-chip { min-height: 32px; }
.ar-toggles { gap: 10px; }
.form-row-toggle.is-disabled { opacity: 0.55; }
.ar-restrict .eb-group-badge { white-space: nowrap; }
.ar-facts { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; margin: 0; padding: 14px; border-radius: var(--radius-sm); background: var(--surface); border: 1px solid var(--border); }
.ar-facts dt { font-size: 11px; font-weight: 700; letter-spacing: 0.04em; text-transform: uppercase; color: var(--text-tertiary); }
.ar-facts dd { margin: 2px 0 0; font-size: 13.5px; }
@container gwed (min-width: 700px) { .ar-facts { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
.ar-test-row { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 8px; }

/* Discord sohbeti görünümü */
.ar-chat { display: flex; flex-direction: column; gap: 14px; min-height: 200px; padding: 16px; border-radius: var(--radius-sm); background: #313338; border: 1px solid rgba(0, 0, 0, 0.3); }
.ar-msg { display: grid; grid-template-columns: 40px minmax(0, 1fr); gap: 12px; }
.ar-msg-avatar { width: 40px; height: 40px; border-radius: 50%; object-fit: cover; background: #1e1f22; }
.ar-msg-body { min-width: 0; display: flex; flex-direction: column; gap: 3px; }
.ar-msg-head { display: flex; align-items: center; gap: 6px; }
.ar-msg-author { font-weight: 600; font-size: 14.5px; color: #f2f3f5; }
.ar-msg-text { font-size: 14.5px; line-height: 1.45; color: #dbdee1; word-break: break-word; }
.ar-reply-line { font-size: 12.5px; color: #b5bac1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ar-reply-line strong { color: #c9cdfb; }
.ar-embed { margin-top: 4px; max-width: 460px; }
.ar-no-match { margin: 0; padding: 10px 12px; border-radius: 8px; font-size: 13px; color: #b5bac1; background: rgba(0, 0, 0, 0.18); }
.ar-alt-badge { align-self: flex-start; padding: 4px 10px; border-radius: 999px; font-size: 12px; font-weight: 600; color: var(--blue-bright); background: rgba(255, 193, 7, 0.12); border: 1px solid rgba(255, 193, 7, 0.34); }
.ar-chat-foot { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.ar-reply-indicator { font-size: 12.5px; color: var(--text-tertiary); font-variant-numeric: tabular-nums; }

/* =================================== D) YETKİLİ İSTATİSTİKLERİ */
.st-top { display: flex; flex-direction: column; gap: 14px; }
.st-periods { max-width: 620px; }
.st-tiles { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
@container p3sec (min-width: 620px) { .st-tiles { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
.st-tile { display: flex; flex-direction: column; gap: 6px; padding: 14px 16px; border-radius: var(--radius-sm); background: var(--surface); border: 1px solid var(--border); }
.st-tile-label { font-size: 12px; font-weight: 600; color: var(--text-tertiary); }
.st-tile-num { font: 800 22px 'Orbitron', sans-serif; color: var(--text-primary); font-variant-numeric: tabular-nums; }
.st-tiles-sub { grid-column: 1 / -1; margin: 0; font-size: 12.5px; color: var(--text-tertiary); }
.st-formula { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; font-size: 13px; color: var(--text-secondary); }
.st-formula:empty { display: none; }

.st-board { container: stboard / inline-size; }
.st-table-wrap { overflow-x: auto; border-radius: var(--radius-sm); border: 1px solid var(--border); background: var(--surface); }
.st-table { width: 100%; min-width: 640px; border-collapse: collapse; font-size: 13.5px; }
.st-table th { position: sticky; top: 0; padding: 0; text-align: left; font-size: 11.5px; font-weight: 700; letter-spacing: 0.04em; text-transform: uppercase; color: var(--text-tertiary); background: rgba(9, 11, 20, 0.96); border-bottom: 1px solid var(--border); }
.st-sort { display: inline-flex; align-items: center; gap: 4px; width: 100%; min-height: 40px; padding: 8px 12px; background: none; border: 0; font: inherit; color: inherit; text-transform: inherit; letter-spacing: inherit; cursor: var(--c-link); }
.st-sort:hover, .st-sort.is-active { color: var(--text-primary); }
.st-sort-caret { font-size: 10px; opacity: 0.7; }
.st-table td { padding: 10px 12px; border-bottom: 1px solid var(--p3-line, rgba(255, 255, 255, 0.06)); vertical-align: middle; }
.st-table tbody tr:last-child td { border-bottom: 0; }
.st-row { cursor: var(--c-link); transition: background-color 0.15s; }
.st-row:hover, .st-row:focus-visible { background: rgba(255, 255, 255, 0.04); outline: none; }
.st-row:focus-visible td:first-child { box-shadow: inset 3px 0 0 var(--blue-bright); }
.st-row.is-top-1 td:first-child { box-shadow: inset 3px 0 0 #FFC107; }
.st-row.is-top-2 td:first-child { box-shadow: inset 3px 0 0 #8fd6ff; }
.st-row.is-top-3 td:first-child { box-shadow: inset 3px 0 0 #ff7a45; }
.st-c-rank { width: 56px; text-align: center; }
.st-c-num { text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }
th.st-c-num .st-sort { justify-content: flex-end; }
.st-c-points { min-width: 120px; font-variant-numeric: tabular-nums; }
.st-medal { font-size: 20px; filter: drop-shadow(0 0 6px color-mix(in srgb, var(--rank-color) 45%, transparent)); }
.st-rank-num { font-weight: 700; color: var(--text-tertiary); font-variant-numeric: tabular-nums; }
.st-user { display: flex; align-items: center; gap: 10px; min-width: 0; }
.st-user-text { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.st-user-text strong { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.st-user-text small { font-size: 11.5px; color: var(--text-tertiary); }
.st-role { display: inline-flex; align-items: center; gap: 6px; font-size: 12px; color: var(--text-secondary); white-space: nowrap; }
.st-role-dot { width: 10px; height: 10px; border-radius: 50%; flex-shrink: 0; }
.st-bar { display: block; height: 5px; margin-top: 6px; border-radius: 999px; background: var(--surface-strong); overflow: hidden; }
.st-bar > span { display: block; height: 100%; border-radius: 999px; background: var(--blue); transition: width 0.6s var(--ease); }
.st-tip { position: relative; display: inline-block; padding: 2px 6px; border-radius: 6px; border-bottom: 1px dashed var(--text-tertiary); cursor: var(--c-help); }
.st-tip::after { content: attr(data-tip); position: absolute; right: 0; bottom: calc(100% + 8px); z-index: 20; min-width: 150px; padding: 8px 10px; border-radius: 8px; white-space: pre; text-align: left; font-size: 12.5px; line-height: 1.6; color: var(--text-primary); background: #111421; border: 1px solid var(--border-strong); box-shadow: 0 10px 24px -10px rgba(0, 0, 0, 0.8); opacity: 0; visibility: hidden; transform: translateY(4px); transition: opacity 0.15s, transform 0.15s, visibility 0.15s; pointer-events: none; }
.st-tip:hover::after, .st-tip:focus-visible::after { opacity: 1; visibility: visible; transform: translateY(0); }
.st-cards { display: none; flex-direction: column; gap: 10px; }
.st-card { display: flex; flex-direction: column; gap: 8px; width: 100%; padding: 14px; border-radius: var(--radius-sm); text-align: left; font: inherit; color: inherit; cursor: var(--c-link); background: var(--surface); border: 1px solid var(--border); }
.st-card.is-top-1 { border-color: rgba(255, 193, 7, 0.5); }
.st-card.is-top-2 { border-color: rgba(143, 214, 255, 0.5); }
.st-card.is-top-3 { border-color: rgba(255, 122, 69, 0.5); }
.st-card-head { display: grid; grid-template-columns: 32px 34px minmax(0, 1fr) auto; gap: 10px; align-items: center; }
.st-card-points { display: flex; flex-direction: column; align-items: flex-end; font-weight: 800; font-size: 17px; font-variant-numeric: tabular-nums; }
.st-card-points small { font-size: 11px; font-weight: 600; color: var(--text-tertiary); }
.st-card-stats { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 6px; font-size: 12.5px; color: var(--text-secondary); }
@container stboard (max-width: 560px) {
  .st-table-wrap { display: none; }
  .st-cards { display: flex; }
}
@container stboard (max-width: 380px) { .st-card-stats { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.st-pager { display: flex; align-items: center; justify-content: center; gap: 14px; font-size: 13px; color: var(--text-secondary); }
.st-skeleton { display: flex; flex-direction: column; gap: 10px; padding: 14px; border-radius: var(--radius-sm); background: var(--surface); border: 1px solid var(--border); }
.st-sk-row { display: grid; grid-template-columns: 40px minmax(0, 1fr) 100px; gap: 14px; align-items: center; }
.st-sk-row .sk-block { width: 100%; }
.st-settings .form-group { margin-bottom: 0; }
.st-weights { display: grid; grid-template-columns: minmax(0, 1fr); gap: 12px; margin-top: 8px; }
@container p3sec (min-width: 600px) { .st-weights { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.st-weight { display: flex; flex-direction: column; gap: 6px; }
.st-weight .form-hint { margin: 0; }

.st-detail { display: flex; flex-direction: column; gap: 14px; }
.st-role-chips { display: flex; flex-wrap: wrap; gap: 6px; }
.st-role-chip { display: inline-flex; align-items: center; gap: 6px; padding: 3px 10px; border-radius: 999px; font-size: 12px; background: var(--surface); border: 1px solid var(--border); }
.st-pcards { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.st-pcard { display: flex; flex-direction: column; gap: 4px; padding: 12px 14px; border-radius: var(--radius-sm); background: var(--surface); border: 1px solid var(--border); }
.st-pcard-label { font-size: 11.5px; font-weight: 700; color: var(--text-tertiary); text-transform: uppercase; letter-spacing: 0.04em; }
.st-pcard-num { font-size: 20px; font-weight: 800; font-variant-numeric: tabular-nums; }
.st-pcard-num small { font-size: 12px; font-weight: 600; color: var(--text-tertiary); }
.st-pcard-rank { font-size: 12.5px; color: var(--text-secondary); }
.st-pcard-empty { font-size: 13px; color: var(--text-tertiary); margin-top: 6px; }
.st-chart-controls { display: grid; grid-template-columns: minmax(0, 1fr); gap: 8px; }
.st-chart { position: relative; }
.st-chart-svg { display: block; width: 100%; height: auto; overflow: visible; }
.st-grid { stroke: rgba(255, 255, 255, 0.08); stroke-width: 1; }
.st-axis { fill: var(--text-tertiary); font-size: 10.5px; font-family: inherit; }
.st-chart-bar path { fill: #FFC107; transition: fill 0.15s; }
.st-chart-bar.is-hover path, .st-chart-bar:focus path { fill: #FFDA47; }
.st-chart-bar { outline: none; cursor: var(--c-normal); }
.st-chart-hit { fill: transparent; }
.st-chart-bar.is-hover .st-chart-hit, .st-chart-bar:focus .st-chart-hit { fill: rgba(255, 255, 255, 0.04); }
.st-chart-tip { position: absolute; top: -6px; width: 140px; padding: 8px 10px; border-radius: 8px; display: flex; flex-direction: column; gap: 2px; font-size: 12px; color: var(--text-secondary); background: #111421; border: 1px solid var(--border-strong); pointer-events: none; transform: translateY(-100%); }
.st-chart-tip strong { font-size: 14px; color: var(--text-primary); }
.st-chart-tip[hidden] { display: none; }
.st-breakdown { display: flex; flex-direction: column; gap: 8px; }
.st-bd-row { display: grid; grid-template-columns: 120px minmax(0, 1fr) 44px; gap: 10px; align-items: center; font-size: 13px; }
.st-bd-row .st-bar { margin-top: 0; height: 8px; }
.st-bd-num { text-align: right; font-weight: 700; font-variant-numeric: tabular-nums; }

/* ================================================ E) JAIL */
.jail-health { display: flex; flex-direction: column; gap: 10px; }
.jail-health:empty { display: none; }
.jail-setup-wait { margin: 0; }
.jail-setup-summary ul { margin: 0; padding-left: 4px; list-style: none; display: flex; flex-direction: column; gap: 6px; font-size: 13.5px; }
.jail-setup-summary .is-warn { color: #f7d58a; }
.jail-settings .form-group { margin-bottom: 0; }
.jail-duration { display: grid; grid-template-columns: 120px minmax(0, 1fr) 120px; gap: 8px; }
.jail-board { container: jailboard / inline-size; }
.jail-table { min-width: 620px; }
.jail-table th { padding: 10px 12px; }
.jail-when { display: flex; flex-direction: column; gap: 2px; }
.jail-when small { font-size: 11.5px; color: var(--text-tertiary); font-weight: 400; }
.jail-user-badges { display: flex; gap: 4px; margin-top: 2px; }
.jail-row { cursor: var(--c-link); }
.jail-row:hover, .jail-row:focus-visible { background: rgba(255, 255, 255, 0.04); outline: none; }
.jail-reason { max-width: 220px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.jail-nowrap { white-space: nowrap; font-variant-numeric: tabular-nums; }
.jail-remaining { font-weight: 700; color: var(--blue-bright); }
.jail-cards { display: none; flex-direction: column; gap: 10px; }
.jail-card { display: flex; flex-direction: column; gap: 10px; padding: 14px; border-radius: var(--radius-sm); background: var(--surface); border: 1px solid var(--border); }
.jail-card-main { display: flex; flex-direction: column; gap: 6px; padding: 0; text-align: left; background: none; border: 0; font: inherit; color: inherit; cursor: var(--c-link); }
.jail-card-reason { font-size: 13px; color: var(--text-secondary); }
.jail-card-meta { display: flex; align-items: center; gap: 8px; font-size: 12.5px; }
.jail-card .btn { align-self: flex-start; }
@container jailboard (max-width: 620px) {
  .jail-table-wrap { display: none; }
  .jail-cards { display: flex; }
}
.jail-history { display: flex; flex-direction: column; gap: 12px; }
.jail-timeline { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; }
.jail-tl-item { position: relative; display: grid; grid-template-columns: 32px minmax(0, 1fr); gap: 12px; padding-bottom: 16px; }
.jail-tl-item:not(:last-child)::before { content: ''; position: absolute; left: 15px; top: 32px; bottom: 0; width: 2px; background: var(--border); }
.jail-tl-icon { display: grid; place-items: center; width: 32px; height: 32px; border-radius: 50%; font-size: 15px; background: var(--surface-strong); border: 1px solid var(--border-strong); }
.jail-tl-item.is-released .jail-tl-icon, .jail-tl-item.is-expired .jail-tl-icon { border-color: rgba(52, 211, 153, 0.5); }
.jail-tl-item.is-jailed .jail-tl-icon, .jail-tl-item.is-rejailed .jail-tl-icon { border-color: rgba(248, 113, 113, 0.5); }
.jail-tl-item.is-release_failed .jail-tl-icon { border-color: rgba(240, 178, 50, 0.6); }
.jail-tl-body { display: flex; flex-direction: column; gap: 2px; min-width: 0; padding-top: 4px; }
.jail-tl-meta { font-size: 12px; color: var(--text-tertiary); }
.jail-tl-reason { font-size: 13px; color: var(--text-secondary); }
.jail-tl-detail { font-size: 12px; color: var(--text-tertiary); overflow-wrap: anywhere; }

/* ================================================ F) ROL LOG */
.log-category-group { display: flex; flex-direction: column; gap: 10px; }
.log-category-group + .log-category-group { margin-top: 18px; }
.log-category-group-title { font-size: 11.5px; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; color: var(--text-tertiary); }
.log-category-item { display: flex; flex-direction: column; gap: 8px; }
.log-category-item .form-hint { margin-top: 4px; }
.log-example { display: flex; flex-direction: column; gap: 6px; padding: 12px; border-radius: var(--radius-sm); background: rgba(0, 0, 0, 0.18); border: 1px dashed var(--border); }
.log-example-label { font-size: 11px; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; color: var(--text-tertiary); }
.log-example-embed { max-width: 460px; }
.log-example .form-hint { margin: 0; }

/* Sunucu Kayıtları — rol log kaydı */
.modlog-roles { display: flex; flex-direction: column; gap: 6px; margin-top: 6px; }
.modlog-roles-row { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; font-size: 12.5px; color: var(--text-secondary); }
.modlog-roles-label { min-width: 104px; font-weight: 700; color: var(--text-primary); }
.modlog-role-chip { display: inline-flex; align-items: center; gap: 5px; padding: 2px 8px; border-radius: 999px; background: var(--surface-strong); border: 1px solid var(--border); }
.modlog-role-dot { width: 8px; height: 8px; border-radius: 50%; }

/* ================================================ G) SAYAÇLAR */
.ct-stats { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 8px; }
.ct-stat { display: flex; flex-direction: column; align-items: center; gap: 2px; padding: 12px 6px; border-radius: var(--radius-sm); background: var(--surface); border: 1px solid var(--border); }
.ct-stat-icon { font-size: 17px; }
.ct-stat-num { font-weight: 800; font-size: 16px; font-variant-numeric: tabular-nums; }
.ct-stat-label { font-size: 11.5px; color: var(--text-tertiary); }
.ct-stats:empty { display: none; }
@container p3sec (max-width: 520px) { .ct-stats { grid-template-columns: repeat(3, minmax(0, 1fr)); } }

.ct-layout { display: grid; grid-template-columns: minmax(0, 1fr); gap: 18px; }
@container p3sec (min-width: 820px) { .ct-layout { grid-template-columns: minmax(300px, 360px) minmax(0, 1fr); align-items: start; } }
.ct-preview-col, .ct-form-col { min-width: 0; display: flex; flex-direction: column; gap: 8px; }
.ct-form-col .form-group { margin-bottom: 0; }
.ct-discord { padding: 0 0 10px; border-radius: 10px; background: #2b2d31; border: 1px solid rgba(0, 0, 0, 0.35); font-size: 14px; color: #949ba4; overflow: hidden; }
.ct-dc-server { display: flex; justify-content: space-between; align-items: center; padding: 12px 14px; font-weight: 700; color: #f2f3f5; border-bottom: 1px solid rgba(0, 0, 0, 0.35); box-shadow: 0 1px 0 rgba(255, 255, 255, 0.03); }
.ct-dc-cat { display: flex; align-items: center; gap: 4px; padding: 16px 10px 4px; font-size: 11.5px; font-weight: 700; letter-spacing: 0.02em; color: #949ba4; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ct-dc-channel { display: grid; grid-template-columns: 20px minmax(0, 1fr) auto; gap: 6px; align-items: center; margin: 1px 8px; padding: 6px 8px; border-radius: 4px; color: #949ba4; }
.ct-dc-channel:not(.is-dim):hover { background: rgba(78, 80, 88, 0.3); color: #dbdee1; }
.ct-dc-channel.is-error .ct-dc-name { color: #fca5a5; }
.ct-dc-name { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-weight: 500; }
.ct-dc-lock { font-size: 11px; opacity: 0.7; }
.ct-dc-icon { text-align: center; font-size: 13px; }
.ct-dc-empty { margin: 6px 16px; font-size: 12.5px; font-style: italic; }
.is-dim { opacity: 0.45; }

.ct-types { display: flex; flex-direction: column; gap: 16px; }
.ct-group { display: flex; flex-direction: column; gap: 8px; }
.ct-group-title { font-size: 12px; font-weight: 700; letter-spacing: 0.05em; text-transform: uppercase; color: var(--text-tertiary); }
/* Kart en az 260px: geniş kapta 3'lü, orta kapta 2'li, dar kapta tek sütun. */
.ct-grid, .ct-roles { display: grid; grid-template-columns: minmax(0, 1fr); gap: 10px; align-items: start; }
@container p3sec (min-width: 540px) { .ct-grid, .ct-roles { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@container p3sec (min-width: 860px) { .ct-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
.ct-type { display: flex; flex-direction: column; gap: 10px; min-width: 0; padding: 14px; border-radius: var(--radius-sm); background: var(--surface); border: 1px solid var(--border); transition: border-color 0.2s, background-color 0.2s; }
.ct-type.is-on { border-color: rgba(255, 193, 7, 0.45); background: linear-gradient(160deg, rgba(255, 193, 7, 0.06), rgba(255, 255, 255, 0.02)); }
.ct-type.p3-skeleton { min-height: 92px; }
.ct-type-head { display: grid; grid-template-columns: 34px minmax(0, 1fr) auto; gap: 10px; align-items: center; }
.ct-type-emoji { display: grid; place-items: center; width: 34px; height: 34px; border-radius: 9px; font-size: 18px; background: var(--surface-strong); }
.ct-type-text { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.ct-type-text strong { font-size: 13.5px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ct-type-text small { font-size: 12px; line-height: 1.4; color: var(--text-tertiary); }
.ct-source { margin: 0; font-size: 11.5px; color: var(--text-tertiary); }
.ct-editor { display: flex; flex-direction: column; gap: 6px; padding-top: 10px; border-top: 1px solid var(--border); }
.ct-ph-chips { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; }
.ct-name-preview { padding: 7px 10px; border-radius: 6px; font-size: 13px; color: #dbdee1; background: #2b2d31; overflow-wrap: anywhere; }
.ct-name-preview.is-error { color: #fecaca; background: rgba(239, 68, 68, 0.14); border: 1px solid rgba(248, 113, 113, 0.5); }
.ct-role-add { display: grid; grid-template-columns: minmax(0, 320px) auto; gap: 8px; align-items: center; }
.ct-existing { display: grid; grid-template-columns: 34px minmax(0, 1fr); gap: 12px; align-items: center; padding: 12px 14px; border-radius: var(--radius-sm); background: var(--surface); border: 1px solid var(--border); }
.ct-existing-main { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.ct-existing-main strong { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ct-existing-main .form-hint { margin: 0; }
.ct-existing-notes { font-size: 12.5px; color: var(--text-secondary); }
.ct-existing-notes .is-warn { color: #f7d58a; }

/* -------------------------------------------------------------- mobil */
@media (max-width: 640px) {
  .p3-chip { min-height: 44px; }
  .p3-seg button { min-height: 44px; }
  .p3-icon-btn { width: 44px; height: 44px; }
  .p3-handle { height: 44px; }
  .ar-toolbar-row { grid-template-columns: minmax(0, 1fr) auto; }
  .ar-toolbar-row .btn { grid-column: 1 / -1; justify-content: center; }
  .ar-replies-foot { grid-template-columns: minmax(0, 1fr); }
  .p3-premium-card { grid-template-columns: auto minmax(0, 1fr); }
  .p3-premium-card .btn { grid-column: 1 / -1; justify-content: center; }
  .p3-preview-switches { flex-direction: column; gap: 6px; align-items: flex-end; }
  .p3-savebar { flex-wrap: wrap; }
  .p3-savebar .p3-hint { flex-basis: 100%; }
  .jail-duration { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
  .jail-duration #jailDurationMode { grid-column: 1 / -1; }
  .ct-role-add { grid-template-columns: minmax(0, 1fr); }
  .st-bd-row { grid-template-columns: 100px minmax(0, 1fr) 40px; }
  .p3-dialog-actions .btn { flex: 1; justify-content: center; }
}



/* ==========================================================================
   1 Ekim — Anti-Nuke: 🤖 Onaylı Botlar + 🛡️ Karantinadakiler (Güvenlik)
   Tek satırlık geniş satırlar; dar kapta (container query) düğmeler alta iner.
   ========================================================================== */
.anb { gap: 12px; }
.anb .form-hint { margin: 0; }
.anb-toolbar { display: flex; align-items: center; gap: 12px; padding: 8px 12px; border-radius: 10px; background: rgba(255, 255, 255, 0.03); border: 1px solid var(--border); }
.anb-toolbar[hidden] { display: none; }
.anb-toolbar .anb-remove-selected { margin-left: auto; }
.anb-list { display: flex; flex-direction: column; gap: 8px; }
.anb-row { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; align-items: center; gap: 12px; padding: 10px 12px; border-radius: 10px; background: var(--surface); border: 1px solid var(--border); transition: border-color 0.15s, background-color 0.15s; }
.anb-row.is-selected { border-color: var(--p3-amber-line); background: var(--p3-amber-soft); }
.anb-check { width: 16px; height: 16px; accent-color: var(--blue); cursor: var(--c-link); }
.anb-sub { display: flex; align-items: center; gap: 6px; min-width: 0; }
.anb-sub small, .anq-badges small { color: var(--text-tertiary); font-size: 12px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.anb-empty { padding: 22px 18px; }
.anb-empty .p3-empty-icon { font-size: 28px; }
@container p3sec (max-width: 420px) {
  .anb-row { grid-template-columns: auto minmax(0, 1fr); }
  .anb-row .anb-remove { grid-column: 1 / -1; width: 100%; }
  .anb-toolbar { flex-wrap: wrap; }
}

.anq { display: flex; flex-direction: column; gap: 12px; }
.anq-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.anq-head .form-hint { margin: 0; }
.anq-head .btn { margin-left: auto; }
.anq-list { display: flex; flex-direction: column; gap: 10px; }
.anq-row { display: flex; flex-direction: column; gap: 10px; padding: 14px 16px; border-radius: var(--radius-sm); background: var(--surface); border: 1px solid var(--border); }
.anq-top { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: 14px; }
.anq-badges { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; }
.anq-badge-white { background: rgba(255, 255, 255, 0.1); color: var(--text-primary); }
.anq-actions { display: flex; gap: 8px; }
.anq-btn-wrap { display: inline-flex; }
.anq-btn-wrap .btn:disabled { pointer-events: none; opacity: 0.45; filter: saturate(0.35); box-shadow: none; transform: none; }
.anq-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 14px; font-size: 12.5px; color: var(--text-secondary); }
.anq-layer { font-weight: 600; color: var(--text-primary); }
.anq-meta small { color: var(--text-tertiary); font-size: 12px; }
.anq-roles { border-top: 1px solid var(--p3-line); padding-top: 8px; }
.anq-roles > summary { cursor: var(--c-link); font-size: 13px; color: var(--text-secondary); list-style: none; display: flex; align-items: center; gap: 6px; }
.anq-roles > summary::-webkit-details-marker { display: none; }
.anq-roles > summary::before { content: '▸'; color: var(--text-tertiary); transition: transform 0.15s; }
.anq-roles[open] > summary::before { transform: rotate(90deg); }
.anq-roles > summary strong { color: var(--text-primary); }
.anq-role-list { list-style: none; margin: 8px 0 0; padding: 0; display: grid; grid-template-columns: minmax(0, 1fr); gap: 6px; }
@container p3sec (min-width: 560px) { .anq-role-list { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.anq-role { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 8px; padding: 6px 10px; border-radius: 8px; background: rgba(255, 255, 255, 0.03); font-size: 13px; }
.anq-dot { width: 10px; height: 10px; border-radius: 50%; flex-shrink: 0; background: #99aab5; }
.anq-role.is-deleted { color: var(--text-tertiary); }
.anq-role.is-deleted .anq-dot { background: transparent; border: 1px dashed var(--text-tertiary); }
.anq-role-note { font-size: 11.5px; color: var(--text-tertiary); }
.anq-role-note.is-warn { color: #f7d58a; }
.anq-fail-list { margin: 6px 0 0; padding-left: 18px; font-size: 12.5px; list-style: disc; }
.anq-more { margin: 0; text-align: center; }
@container p3sec (max-width: 560px) {
  .anq-top { grid-template-columns: minmax(0, 1fr); }
  .anq-actions { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .anq-btn-wrap, .anq-btn-wrap .btn { width: 100%; }
}
@container p3sec (max-width: 360px) {
  .anq-actions { grid-template-columns: minmax(0, 1fr); }
}

/* ==========================================================================
   2 Ekim — 🩺 Genel Bakış: ⛓️ Jail kutucuğu (ızgaranın başında, tam satır,
   yatay) + ⚖️ bekleyen itiraz rozeti. Dar kapta (container query) alt alta.
   ========================================================================== */
.ov-tile { grid-column: 1 / -1; container: ovtile / inline-size; display: flex; flex-direction: column; gap: 12px; padding: 16px 18px; border-radius: var(--radius-sm); background: var(--surface); border: 1px solid var(--border); cursor: var(--c-link); transition: border-color 0.15s, background-color 0.15s; }
.ov-tile:hover { border-color: rgba(255, 218, 71, 0.4); background: var(--surface-strong); }
.ov-tile.is-on { border-color: rgba(52, 211, 153, 0.22); }
.ov-tile.is-warn { border-color: rgba(240, 178, 50, 0.38); }
.ov-tile.is-forbidden, .ov-tile.is-loading, .ov-tile.is-idle { cursor: var(--c-normal); }
.ov-tile.is-forbidden:hover, .ov-tile.is-loading:hover, .ov-tile.is-idle:hover { border-color: var(--border); background: var(--surface); }
.ov-tile :focus-visible { outline: 2px solid var(--blue-bright); outline-offset: 2px; }
.ov-head { display: flex; align-items: center; gap: 12px; min-width: 0; }
.ov-icon { display: grid; place-items: center; width: 36px; height: 36px; flex-shrink: 0; border-radius: 10px; background: rgba(255, 193, 7, 0.1); font-size: 18px; }
.ov-title { display: flex; align-items: center; flex-wrap: wrap; gap: 6px 10px; min-width: 0; font-size: 14.5px; color: var(--text-primary); }
.ov-head-actions { display: flex; align-items: center; gap: 8px; margin-left: auto; }
.ov-status { display: inline-flex; align-items: center; gap: 4px; padding: 2px 10px; border-radius: 999px; font-size: 12px; font-weight: 700; white-space: nowrap; border: 1px solid var(--border-strong); background: rgba(255, 255, 255, 0.06); color: var(--text-secondary); }
.ov-status.sk-block { width: 74px; height: 20px; padding: 0; border: 0; }
.ov-status.is-on { background: rgba(52, 211, 153, 0.1); border-color: rgba(52, 211, 153, 0.34); color: #86efac; }
.ov-status.is-warn { background: rgba(240, 178, 50, 0.1); border-color: rgba(240, 178, 50, 0.4); color: #f7d58a; }
.ov-appeal-badge { display: inline-flex; align-items: center; gap: 5px; padding: 5px 12px; border-radius: 999px; font: inherit; font-size: 12.5px; font-weight: 600; white-space: nowrap; cursor: var(--c-link); background: rgba(255, 193, 7, 0.12); border: 1px solid rgba(255, 193, 7, 0.4); color: var(--blue-bright); transition: background-color 0.15s; }
.ov-appeal-badge:hover { background: rgba(255, 193, 7, 0.2); }
.ov-appeal-badge strong { color: var(--text-primary); }
.ov-issue { margin: 0; font-size: 13px; color: #f7d58a; }
.ov-jail-body { display: grid; grid-template-columns: auto auto minmax(0, 1fr); align-items: center; gap: 12px 28px; min-height: 44px; }
.ov-jail-body > .sk-block { height: 16px; }
.ov-jail-body > .ov-sk-big { height: 34px; width: 56px; }
.ov-count { display: flex; align-items: center; gap: 12px; }
.ov-big { font-size: 34px; font-weight: 800; line-height: 1; color: var(--text-primary); font-variant-numeric: tabular-nums; }
.ov-count-label { display: flex; flex-direction: column; gap: 3px; font-size: 13px; font-weight: 600; color: var(--text-secondary); }
.ov-count-label small { font-size: 12px; font-weight: 500; color: var(--text-tertiary); }
.ov-faces { display: flex; align-items: center; }
.ov-face { display: inline-flex; border-radius: 50%; box-shadow: 0 0 0 2px var(--surface-strong); }
.ov-face + .ov-face, .ov-face + .ov-face-more { margin-left: -8px; }
.ov-face-more { display: inline-grid; place-items: center; min-width: 28px; height: 28px; padding: 0 6px; border-radius: 999px; font-size: 11.5px; font-weight: 700; background: var(--surface-strong); border: 1px solid var(--border-strong); color: var(--text-secondary); }
.ov-empty { margin: 0; font-size: 14px; color: var(--text-secondary); grid-column: 1 / 3; }
.ov-tags { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 6px; }
.ov-tag { padding: 2px 9px; border-radius: 999px; font-size: 11.5px; color: var(--text-tertiary); background: rgba(255, 255, 255, 0.04); border: 1px solid var(--border); white-space: nowrap; }
.ov-setup, .ov-error { display: flex; align-items: center; justify-content: space-between; gap: 12px; font-size: 13.5px; color: var(--text-secondary); }
.ov-error { color: #fca5a5; }
.ov-locked { margin: 0; font-size: 13.5px; color: var(--text-secondary); }
@container ovtile (max-width: 540px) {
  .ov-head { flex-wrap: wrap; }
  .ov-head-actions { width: 100%; margin-left: 0; justify-content: space-between; }
  .ov-jail-body { grid-template-columns: minmax(0, 1fr); gap: 10px; }
  .ov-faces { justify-self: start; }
  .ov-tags { grid-column: 1 / -1; justify-content: flex-start; }
  .ov-empty { grid-column: 1 / -1; }
}

/* ==========================================================================
   2 Ekim — ⚖️ Ceza İtirazları
   ========================================================================== */
.apl-health { display: flex; flex-direction: column; gap: 8px; }
.apl-health:empty { display: none; }
.apl-settings .form-group { margin-bottom: 0; }
.apl-settings .form-row-toggle { margin: 0; }
.toggle.is-disabled { opacity: 0.45; cursor: var(--c-unavail); }
.toggle.is-disabled input { cursor: var(--c-unavail); }
.form-hint.is-warn { color: #f7d58a; }
.apl-types { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
.apl-type { display: flex; align-items: center; gap: 10px; padding: 10px 12px; border-radius: 10px; background: var(--surface); border: 1px solid var(--border); cursor: var(--c-link); font-size: 13.5px; font-weight: 600; color: var(--text-secondary); transition: border-color 0.15s, background-color 0.15s; }
.apl-type input { width: 16px; height: 16px; accent-color: var(--blue); cursor: var(--c-link); flex-shrink: 0; }
.apl-type.is-on { border-color: var(--p3-amber-line); background: var(--p3-amber-soft); color: var(--text-primary); }
.apl-focus { margin-top: 4px; }
.apl-list { display: flex; flex-direction: column; gap: 10px; }
.apl-card { display: flex; flex-direction: column; gap: 10px; padding: 14px 16px; border-radius: var(--radius-sm); background: var(--surface); border: 1px solid var(--border); border-left: 3px solid var(--border-strong); }
.apl-card.is-pending { border-left-color: var(--p3-amber); }
.apl-card.is-accepted { border-left-color: var(--p3-green); }
.apl-card.is-rejected { border-left-color: var(--p3-red); }
.apl-card.is-focus { box-shadow: 0 0 0 2px var(--p3-amber-line); }
.apl-top { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: 14px; }
.apl-sub { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 10px; font-size: 12px; }
.apl-sub small { color: var(--text-tertiary); font-size: 12px; }
.apl-type-badge { display: inline-flex; align-items: center; gap: 4px; padding: 1px 8px; border-radius: 999px; font-size: 11.5px; font-weight: 700; white-space: nowrap; background: rgba(255, 255, 255, 0.07); border: 1px solid var(--border-strong); color: var(--text-primary); }
.apl-type-badge.is-ban { background: rgba(239, 68, 68, 0.1); border-color: rgba(239, 68, 68, 0.32); color: #fca5a5; }
.apl-type-badge.is-timeout { background: rgba(96, 165, 250, 0.1); border-color: rgba(96, 165, 250, 0.32); color: #bfdbfe; }
.apl-type-badge.is-jail { background: rgba(167, 139, 250, 0.1); border-color: rgba(167, 139, 250, 0.32); color: #ddd6fe; }
.apl-time { color: var(--text-tertiary); white-space: nowrap; }
.apl-actions { display: flex; gap: 8px; }
.apl-actions .btn:disabled { opacity: 0.55; pointer-events: none; }
.apl-reject:hover { border-color: rgba(239, 68, 68, 0.5); color: #fca5a5; }
.apl-status { display: inline-flex; align-items: center; gap: 4px; padding: 3px 11px; border-radius: 999px; font-size: 12px; font-weight: 700; white-space: nowrap; border: 1px solid; }
.apl-status.is-accepted { background: rgba(52, 211, 153, 0.1); border-color: rgba(52, 211, 153, 0.34); color: #86efac; }
.apl-status.is-rejected { background: rgba(239, 68, 68, 0.1); border-color: rgba(239, 68, 68, 0.32); color: #fca5a5; }
.apl-field, .apl-body { display: grid; grid-template-columns: 96px minmax(0, 1fr); gap: 4px 12px; font-size: 13.5px; line-height: 1.55; color: var(--text-primary); }
.apl-label { padding-top: 2px; font-size: 11px; font-weight: 700; letter-spacing: 0.04em; text-transform: uppercase; color: var(--text-tertiary); }
.apl-field-text { overflow-wrap: anywhere; white-space: pre-line; }
.apl-text { margin: 0; overflow: hidden; overflow-wrap: anywhere; white-space: pre-line; display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 3; line-clamp: 3; }
.apl-text.is-expanded { display: block; -webkit-line-clamp: unset; line-clamp: none; overflow: visible; }
.apl-more { grid-column: 2; justify-self: start; }
.apl-more[hidden] { display: none; }
.apl-decision { display: flex; flex-direction: column; gap: 8px; padding-top: 10px; border-top: 1px solid var(--p3-line); }
.apl-decision-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 14px; font-size: 12.5px; color: var(--text-secondary); }
.apl-muted { color: var(--text-tertiary); font-style: normal; font-size: 12px; }
.apl-mention { padding: 0 4px; border-radius: 4px; background: rgba(88, 101, 242, 0.18); color: #c9cdfb; }
.apl-link { align-self: flex-start; font-size: 12.5px; font-weight: 600; color: var(--blue-bright); text-underline-offset: 3px; }
.apl-dialog-warn { margin: 12px 0 10px; }
@container p3sec (max-width: 560px) {
  .apl-top { grid-template-columns: minmax(0, 1fr); }
  .apl-actions { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .apl-actions .btn { width: 100%; }
  .apl-field, .apl-body { grid-template-columns: minmax(0, 1fr); }
  .apl-more { grid-column: 1; }
}
@container p3sec (max-width: 440px) {
  .apl-types, .apl-actions { grid-template-columns: minmax(0, 1fr); }
}

/* 🧾 Sunucu Kayıtları — ⚖️ İtiraz kararı etiketleri */
.modlog-appeal { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; margin-top: 6px; }
.modlog-appeal-action { padding: 2px 10px; border-radius: 999px; font-size: 12px; font-weight: 700; background: rgba(255, 255, 255, 0.07); border: 1px solid var(--border-strong); color: var(--text-primary); }
.modlog-appeal-action.is-accepted { background: rgba(52, 211, 153, 0.1); border-color: rgba(52, 211, 153, 0.34); color: #86efac; }
.modlog-appeal-action.is-rejected { background: rgba(239, 68, 68, 0.1); border-color: rgba(239, 68, 68, 0.32); color: #fca5a5; }
.modlog-appeal-chip { padding: 2px 9px; border-radius: 999px; font: inherit; font-size: 12px; color: var(--text-secondary); background: rgba(255, 255, 255, 0.04); border: 1px solid var(--border); }
.modlog-appeal-chip.is-link { cursor: var(--c-link); color: var(--blue-bright); border-color: rgba(255, 193, 7, 0.34); background: rgba(255, 193, 7, 0.08); }
.modlog-appeal-chip.is-link:hover { background: rgba(255, 193, 7, 0.16); }
