/* TG Destek Paneli — premium tasarım sistemi. Açık/koyu tema, yumuşak yükseklikler, ikon hizalı bileşenler. */
:root {
  --bg: #f6f8fb; --bg-2: #eef1f6; --panel: #ffffff; --panel-2: #fbfcfe;
  --line: #e4e8ef; --line-strong: #d4dae4;
  --text: #121826; --text-2: #3b4458; --muted: #6b7688; --faint: #9aa4b5;
  --accent: #3b6ff6; --accent-2: #5b8bff; --accent-ink: #ffffff; --accent-soft: #eaf0ff; --accent-border: #cfdcff;
  --ok: #17935a; --ok-soft: #e3f6ec; --warn: #b7791f; --warn-soft: #fbf2e2; --bad: #d64545; --bad-soft: #fdeceb;
  --in: #ffffff; --out: #e8f0ff; --out-ink: #16233d;
  --mask: #efe9fb; --mask-ink: #6b46c1;
  --radius: 12px; --radius-sm: 8px; --radius-lg: 16px;
  --sh-1: 0 1px 2px rgba(18,26,46,.06), 0 1px 1px rgba(18,26,46,.04);
  --sh-2: 0 4px 12px rgba(18,26,46,.08), 0 2px 4px rgba(18,26,46,.04);
  --sh-3: 0 12px 32px rgba(18,26,46,.14), 0 4px 8px rgba(18,26,46,.06);
  --ring: 0 0 0 3px rgba(59,111,246,.28);
  --ease: 180ms cubic-bezier(.4,0,.2,1);
  --grad: linear-gradient(135deg, #3b6ff6, #6a4bf0);
  --font: "Inter var", Inter, system-ui, -apple-system, "Segoe UI", Roboto, "Noto Sans", "Helvetica Neue", Arial, sans-serif;
  font-family: var(--font); font-size: 14px; line-height: 1.5;
  -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility;
  font-feature-settings: "cv02","cv03","cv04","ss01"; color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #0c1118; --bg-2: #0f1620; --panel: #141b26; --panel-2: #18212e;
    --line: #243040; --line-strong: #30404f;
    --text: #e8edf5; --text-2: #c2ccdb; --muted: #8b97aa; --faint: #68758a;
    --accent: #5b8bff; --accent-2: #7aa2ff; --accent-ink: #0a1324; --accent-soft: #17233c; --accent-border: #27385c;
    --ok: #35c07d; --ok-soft: #122a1e; --warn: #e0a942; --warn-soft: #2c2413; --bad: #f06a6a; --bad-soft: #2e1717;
    --in: #1a2330; --out: #1e3353; --out-ink: #dde8fb;
    --mask: #2a2246; --mask-ink: #c6b4ff;
    --sh-1: 0 1px 2px rgba(0,0,0,.4); --sh-2: 0 6px 16px rgba(0,0,0,.5); --sh-3: 0 16px 40px rgba(0,0,0,.6);
    --ring: 0 0 0 3px rgba(91,139,255,.35); color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --bg: #0c1118; --bg-2: #0f1620; --panel: #141b26; --panel-2: #18212e;
  --line: #243040; --line-strong: #30404f;
  --text: #e8edf5; --text-2: #c2ccdb; --muted: #8b97aa; --faint: #68758a;
  --accent: #5b8bff; --accent-2: #7aa2ff; --accent-ink: #0a1324; --accent-soft: #17233c; --accent-border: #27385c;
  --ok: #35c07d; --ok-soft: #122a1e; --warn: #e0a942; --warn-soft: #2c2413; --bad: #f06a6a; --bad-soft: #2e1717;
  --in: #1a2330; --out: #1e3353; --out-ink: #dde8fb; --mask: #2a2246; --mask-ink: #c6b4ff;
  --sh-1: 0 1px 2px rgba(0,0,0,.4); --sh-2: 0 6px 16px rgba(0,0,0,.5); --sh-3: 0 16px 40px rgba(0,0,0,.6);
  --ring: 0 0 0 3px rgba(91,139,255,.35); color-scheme: dark;
}
* { box-sizing: border-box; }
html, body { margin: 0; height: 100%; background: var(--bg); color: var(--text); }
body { background: radial-gradient(1200px 600px at 100% -10%, color-mix(in srgb, var(--accent) 7%, transparent), transparent 60%), var(--bg); }
::selection { background: color-mix(in srgb, var(--accent) 24%, transparent); }
svg { display: block; }
.ic { width: 18px; height: 18px; stroke: currentColor; stroke-width: 1.9; fill: none; stroke-linecap: round; stroke-linejoin: round; flex-shrink: 0; }
.ic-sm { width: 15px; height: 15px; } .ic-lg { width: 22px; height: 22px; }

/* scrollbar */
* { scrollbar-width: thin; scrollbar-color: var(--line-strong) transparent; }
*::-webkit-scrollbar { width: 10px; height: 10px; }
*::-webkit-scrollbar-thumb { background: var(--line-strong); border-radius: 99px; border: 3px solid transparent; background-clip: content-box; }
*::-webkit-scrollbar-thumb:hover { background: var(--faint); background-clip: content-box; }

button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; border: 1px solid var(--line-strong); background: var(--panel); border-radius: var(--radius-sm); padding: 8px 14px; font-weight: 500;
  display: inline-flex; align-items: center; gap: 7px; transition: background var(--ease), border-color var(--ease), box-shadow var(--ease), transform var(--ease); }
button:hover { background: var(--panel-2); border-color: var(--accent-border); }
button:active { transform: translateY(.5px); }
button:focus-visible { outline: none; box-shadow: var(--ring); }
button.primary { background: var(--grad); border-color: transparent; color: var(--accent-ink); box-shadow: var(--sh-1); }
button.primary:hover { filter: brightness(1.05); }
button.ghost { border-color: transparent; background: transparent; }
button.ghost:hover { background: var(--bg-2); }
button.danger { color: var(--bad); border-color: color-mix(in srgb, var(--bad) 30%, var(--line)); }
button.danger:hover { background: var(--bad-soft); border-color: var(--bad); }
button.link { border: none; background: none; color: var(--accent); padding: 2px 4px; font-weight: 500; gap: 4px; }
button.link:hover { background: none; text-decoration: underline; }
button.icon { padding: 8px; border-radius: var(--radius-sm); }
button:disabled { opacity: .5; cursor: default; transform: none; }
button.loading { color: transparent !important; position: relative; pointer-events: none; }
button.loading::after { content: ""; position: absolute; inset: 0; margin: auto; width: 16px; height: 16px; border: 2px solid currentColor; border-top-color: transparent; border-radius: 50%; color: var(--accent); animation: spin .6s linear infinite; }
button.primary.loading::after { color: var(--accent-ink); }
@keyframes spin { to { transform: rotate(360deg); } }

input, select, textarea { border: 1px solid var(--line-strong); background: var(--panel); border-radius: var(--radius-sm); padding: 9px 12px; width: 100%; transition: border-color var(--ease), box-shadow var(--ease); }
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--accent); box-shadow: var(--ring); }
input::placeholder, textarea::placeholder { color: var(--faint); }
textarea { resize: vertical; }
label { display: block; font-size: 12px; font-weight: 500; color: var(--text-2); margin: 12px 0 5px; }
h1, h2, h3 { margin: 0 0 12px; font-weight: 650; letter-spacing: -.01em; }
h1 { font-size: 22px; } h2 { font-size: 19px; } h3 { font-size: 15px; }
a { color: var(--accent); text-decoration: none; } a:hover { text-decoration: underline; }
.muted { color: var(--muted); } .small { font-size: 12px; } .faint { color: var(--faint); }
.boot { padding: 60px; text-align: center; color: var(--muted); }
.row { display: flex; gap: 8px; align-items: center; } .row.wrap { flex-wrap: wrap; } .grow { flex: 1; min-width: 0; }

.pill { display: inline-flex; align-items: center; gap: 5px; font-size: 11.5px; font-weight: 550; padding: 2px 9px; border-radius: 99px; background: var(--bg-2); color: var(--text-2); white-space: nowrap; border: 1px solid transparent; line-height: 1.7; }
.pill .ic { width: 12px; height: 12px; stroke-width: 2.2; }
.pill.ok { color: var(--ok); background: var(--ok-soft); } .pill.warn { color: var(--warn); background: var(--warn-soft); }
.pill.bad { color: var(--bad); background: var(--bad-soft); } .pill.acc { color: var(--accent); background: var(--accent-soft); }
.dot { width: 8px; height: 8px; border-radius: 50%; background: var(--faint); display: inline-block; flex-shrink: 0; }
.dot.ok { background: var(--ok); } .dot.bad { background: var(--bad); } .dot.warn { background: var(--warn); }
.dot.live { background: var(--ok); box-shadow: 0 0 0 0 color-mix(in srgb, var(--ok) 60%, transparent); animation: pulse 2s infinite; }
@keyframes pulse { 0% { box-shadow: 0 0 0 0 color-mix(in srgb, var(--ok) 55%, transparent); } 70% { box-shadow: 0 0 0 6px transparent; } 100% { box-shadow: 0 0 0 0 transparent; } }
.mask { display: inline-flex; align-items: center; gap: 3px; background: var(--mask); color: var(--mask-ink); border-radius: 5px; padding: 0 5px 0 4px; font-size: 12px; font-weight: 500; white-space: nowrap; vertical-align: baseline; }
.mask svg { width: 11px; height: 11px; }
.card { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 18px; box-shadow: var(--sh-1); }
.notice { border-left: 3px solid var(--warn); background: var(--warn-soft); padding: 9px 12px; border-radius: var(--radius-sm); font-size: 13px; color: var(--text-2); }
.notice.bad { border-color: var(--bad); background: var(--bad-soft); } .notice.info { border-color: var(--accent); background: var(--accent-soft); }

#toast { position: fixed; bottom: 20px; left: 50%; transform: translateX(-50%); z-index: 60; display: flex; flex-direction: column; gap: 8px; align-items: center; }
#toast .t { display: flex; align-items: center; gap: 9px; background: var(--panel); color: var(--text); padding: 11px 16px; border-radius: var(--radius); box-shadow: var(--sh-3); border: 1px solid var(--line); max-width: 92vw; font-weight: 500; animation: toastIn .28s cubic-bezier(.2,.8,.2,1); }
#toast .t .ic { color: var(--ok); } #toast .t.bad .ic { color: var(--bad); }
@keyframes toastIn { from { opacity: 0; transform: translateY(12px) scale(.96); } to { opacity: 1; transform: none; } }

/* giriş */
.auth { max-width: 400px; margin: 8vh auto; padding: 0 18px; }
.auth .card { padding: 28px; box-shadow: var(--sh-2); }
.auth .brand { display: flex; align-items: center; gap: 10px; margin-bottom: 18px; }
.auth .brand img { width: 34px; height: 34px; border-radius: 9px; box-shadow: var(--sh-1); }
.auth h1 { font-size: 20px; margin: 0; }
.auth .qr { display: grid; place-items: center; padding: 14px; background: #fff; border-radius: var(--radius); margin: 8px 0; }
.auth .qr svg { width: 196px; height: 196px; }
.code { font-family: ui-monospace, "SF Mono", Menlo, Consolas, monospace; background: var(--bg-2); padding: 3px 7px; border-radius: 6px; word-break: break-all; font-size: 13px; border: 1px solid var(--line); }

/* kabuk / üst çubuk */
.shell { display: flex; flex-direction: column; height: 100vh; height: 100dvh; }
.top { display: flex; align-items: center; gap: 14px; padding: 0 16px; height: 56px; background: color-mix(in srgb, var(--panel) 86%, transparent); backdrop-filter: saturate(1.4) blur(10px); border-bottom: 1px solid var(--line); flex-shrink: 0; z-index: 20; }
.top .brand { font-weight: 700; display: flex; align-items: center; gap: 9px; letter-spacing: -.02em; }
.top .brand img { width: 26px; height: 26px; border-radius: 7px; }
.top nav { display: flex; gap: 3px; }
.top nav a { display: flex; align-items: center; gap: 7px; padding: 8px 13px; border-radius: var(--radius-sm); color: var(--muted); font-weight: 550; transition: background var(--ease), color var(--ease); }
.top nav a:hover { background: var(--bg-2); color: var(--text); text-decoration: none; }
.top nav a.on { background: var(--accent-soft); color: var(--accent); }
.top .who { margin-left: auto; display: flex; gap: 12px; align-items: center; }
.main { flex: 1; min-height: 0; display: flex; }
.page { flex: 1; overflow: auto; padding: 24px; }
.page-inner { max-width: 1180px; margin: 0 auto; }

/* sohbet düzeni */
.inbox { display: grid; grid-template-columns: 340px 1fr 320px; flex: 1; min-height: 0; }
.col { min-height: 0; display: flex; flex-direction: column; border-right: 1px solid var(--line); background: var(--panel); }
.col.mid { background: var(--bg); }
.col.right { border-right: none; overflow: auto; }
.listhead { padding: 12px; border-bottom: 1px solid var(--line); display: flex; flex-direction: column; gap: 10px; background: var(--panel); }
.search { position: relative; }
.search .ic { position: absolute; left: 11px; top: 50%; transform: translateY(-50%); color: var(--faint); pointer-events: none; }
.search input { padding-left: 36px; background: var(--bg-2); border-color: transparent; }
.search input:focus { background: var(--panel); border-color: var(--accent); }
.filters { display: flex; gap: 5px; flex-wrap: wrap; }
.filters button { padding: 4px 11px; font-size: 12px; font-weight: 550; border-radius: 99px; border-color: var(--line); color: var(--muted); }
.filters button:hover { color: var(--text); }
.filters button.on { background: var(--accent); color: var(--accent-ink); border-color: var(--accent); }
.chatlist { overflow: auto; flex: 1; }
.ci { display: flex; gap: 11px; padding: 11px 13px; cursor: pointer; border-left: 2.5px solid transparent; transition: background var(--ease); position: relative; }
.ci:hover { background: var(--bg-2); } .ci.on { background: var(--accent-soft); border-left-color: var(--accent); }
.ci + .ci::before { content: ""; position: absolute; top: 0; left: 64px; right: 13px; border-top: 1px solid var(--line); }
.av { width: 42px; height: 42px; border-radius: 13px; display: grid; place-items: center; font-weight: 650; font-size: 13px; color: #fff; flex-shrink: 0; box-shadow: var(--sh-1); letter-spacing: .02em; }
.av.sm { width: 32px; height: 32px; border-radius: 10px; font-size: 11px; }
.ci .l1 { display: flex; justify-content: space-between; gap: 6px; align-items: baseline; }
.ci .name { font-weight: 650; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ci .prev { color: var(--muted); font-size: 13px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; margin-top: 1px; }
.ci .prev .mask { font-size: 11px; padding: 0 3px; }
.ci .l3 { display: flex; gap: 5px; margin-top: 5px; flex-wrap: wrap; align-items: center; }
.badge { background: var(--accent); color: var(--accent-ink); border-radius: 99px; font-size: 11px; font-weight: 650; padding: 1px 7px; min-width: 20px; text-align: center; margin-left: auto; }
.chathead { padding: 9px 16px; background: color-mix(in srgb, var(--panel) 88%, transparent); backdrop-filter: blur(8px); border-bottom: 1px solid var(--line); display: flex; align-items: center; gap: 11px; min-height: 58px; z-index: 5; }
.msgs { flex: 1; overflow: auto; padding: 16px 20px; display: flex; flex-direction: column; gap: 3px; scroll-behavior: smooth; }
.msg { max-width: min(640px, 78%); padding: 8px 12px; border-radius: 14px; background: var(--in); border: 1px solid var(--line); align-self: flex-start; position: relative; box-shadow: var(--sh-1); margin-top: 7px; animation: msgIn .22s ease; }
@keyframes msgIn { from { opacity: 0; transform: translateY(4px); } to { opacity: 1; transform: none; } }
.msg.out { background: var(--out); color: var(--out-ink); align-self: flex-end; border-color: transparent; }
.msg.grouped { margin-top: 2px; }
.msg.grouped.in { border-top-left-radius: 6px; } .msg.grouped.out { border-top-right-radius: 6px; }
.msg .meta { font-size: 10.5px; color: var(--muted); display: flex; gap: 6px; justify-content: flex-end; margin-top: 3px; align-items: center; }
.msg.out .meta { color: color-mix(in srgb, var(--out-ink) 55%, transparent); }
.msg .who { font-size: 12px; color: var(--accent); font-weight: 650; margin-bottom: 3px; }
.msg .body { white-space: pre-wrap; word-wrap: break-word; overflow-wrap: anywhere; }
.msg .quote { border-left: 2.5px solid var(--accent); padding: 3px 9px; margin-bottom: 5px; font-size: 12px; background: color-mix(in srgb, var(--accent) 7%, transparent); border-radius: 6px; color: var(--text-2); }
.msg .fwd { font-size: 12px; color: var(--muted); font-style: italic; margin-bottom: 3px; display: flex; gap: 4px; align-items: center; }
.msg .att { margin: 5px 0; padding: 10px; background: color-mix(in srgb, var(--muted) 9%, transparent); border-radius: 10px; font-size: 13px; display: flex; flex-direction: column; gap: 6px; }
.msg .att .att-h { display: flex; align-items: center; gap: 7px; font-weight: 550; }
.msg .att img { max-width: 100%; max-height: 320px; border-radius: 8px; }
.msg .acts { display: none; position: absolute; top: -14px; right: 8px; gap: 2px; background: var(--panel); border: 1px solid var(--line); border-radius: 9px; padding: 2px; box-shadow: var(--sh-2); }
.msg:hover .acts { display: flex; }
.msg .acts button { padding: 4px; font-size: 11px; border: none; background: none; }
.msg .acts button:hover { background: var(--bg-2); }
.msg.service { align-self: center; background: none; border: none; box-shadow: none; color: var(--muted); font-size: 12px; padding: 4px; margin-top: 4px; }
.daysep { align-self: center; font-size: 11px; font-weight: 550; color: var(--muted); background: var(--panel); border: 1px solid var(--line); padding: 2px 12px; border-radius: 99px; margin: 10px 0 4px; box-shadow: var(--sh-1); }
.st { display: inline-flex; align-items: center; gap: 3px; }
.st-sending { color: var(--muted); } .st-sent { color: var(--ok); } .st-failed { color: var(--bad); font-weight: 600; }
.msg.out .st-sent { color: color-mix(in srgb, var(--ok) 85%, var(--out-ink)); }
.composer { background: var(--panel); border-top: 1px solid var(--line); padding: 10px 14px 12px; display: flex; flex-direction: column; gap: 8px; }
.composer .box { position: relative; display: flex; align-items: flex-end; gap: 8px; background: var(--bg-2); border: 1px solid var(--line-strong); border-radius: var(--radius); padding: 6px 6px 6px 10px; transition: border-color var(--ease), box-shadow var(--ease); }
.composer .box:focus-within { border-color: var(--accent); box-shadow: var(--ring); background: var(--panel); }
.composer textarea { border: none; background: none; padding: 7px 2px; min-height: 24px; max-height: 180px; }
.composer textarea:focus { box-shadow: none; }
.composer .tools { display: flex; gap: 2px; align-items: center; }
.composer .send { border-radius: 10px; padding: 9px; }
.composer .replybar { font-size: 12px; background: var(--bg-2); padding: 6px 10px; border-radius: var(--radius-sm); display: flex; justify-content: space-between; align-items: center; gap: 8px; border-left: 2.5px solid var(--accent); }
.composer .hint { font-size: 11px; color: var(--faint); display: flex; gap: 10px; }
.typing { font-size: 12px; color: var(--warn); padding: 2px 16px; min-height: 18px; display: flex; align-items: center; gap: 6px; }
.typing .dots { display: inline-flex; gap: 2px; } .typing .dots i { width: 4px; height: 4px; border-radius: 50%; background: currentColor; animation: td 1.2s infinite; } .typing .dots i:nth-child(2){animation-delay:.2s}.typing .dots i:nth-child(3){animation-delay:.4s}
@keyframes td { 0%,60%,100%{opacity:.3}30%{opacity:1} }
.empty { margin: auto; color: var(--muted); text-align: center; padding: 40px 24px; display: flex; flex-direction: column; align-items: center; gap: 12px; max-width: 320px; }
.empty .ic { width: 44px; height: 44px; stroke-width: 1.5; color: var(--faint); }
.empty h3 { color: var(--text-2); margin: 0; } .empty p { margin: 0; font-size: 13px; }
.side { padding: 16px; display: flex; flex-direction: column; gap: 16px; }
.side section { border-bottom: 1px solid var(--line); padding-bottom: 14px; }
.side section:last-child { border: none; padding-bottom: 0; }
.side h3 { display: flex; align-items: center; gap: 7px; font-size: 13px; text-transform: uppercase; letter-spacing: .04em; color: var(--muted); }
.side h3 .ic { width: 15px; height: 15px; color: var(--faint); }
.note { background: var(--bg-2); border-radius: 10px; padding: 9px 11px; margin-top: 7px; font-size: 13px; white-space: pre-wrap; overflow-wrap: anywhere; border: 1px solid var(--line); }
.note .nm { font-size: 11px; color: var(--muted); display: flex; justify-content: space-between; margin-bottom: 3px; }
.note.real { border-color: color-mix(in srgb, var(--bad) 30%, var(--line)); }
.kv { display: grid; grid-template-columns: auto 1fr; gap: 6px 12px; font-size: 13px; }
.kv dt { color: var(--muted); } .kv dd { margin: 0; color: var(--text); }
.canned { position: absolute; bottom: calc(100% + 6px); left: 0; right: 0; max-height: 280px; overflow: auto; background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--sh-3); z-index: 10; }
.canned div { padding: 9px 12px; cursor: pointer; border-bottom: 1px solid var(--line); }
.canned div:last-child { border: none; } .canned div:hover { background: var(--accent-soft); }

/* pano / yönetim */
.grid { display: grid; gap: 14px; grid-template-columns: repeat(auto-fill, minmax(210px, 1fr)); }
.stat { position: relative; overflow: hidden; display: flex; flex-direction: column; gap: 4px; }
.stat .top { display: flex; align-items: center; justify-content: space-between; }
.stat .ico { width: 34px; height: 34px; border-radius: 10px; display: grid; place-items: center; background: var(--accent-soft); color: var(--accent); }
.stat .ico .ic { width: 18px; height: 18px; }
.stat .n { font-size: 28px; font-weight: 700; letter-spacing: -.02em; line-height: 1.1; }
.stat .k { color: var(--muted); font-size: 13px; font-weight: 500; }
.stat.ok .ico { background: var(--ok-soft); color: var(--ok); } .stat.warn .ico { background: var(--warn-soft); color: var(--warn); } .stat.bad .ico { background: var(--bad-soft); color: var(--bad); }
table { width: 100%; border-collapse: collapse; font-size: 13px; }
th, td { text-align: left; padding: 9px 10px; border-bottom: 1px solid var(--line); vertical-align: middle; }
th { color: var(--muted); font-weight: 550; font-size: 11.5px; text-transform: uppercase; letter-spacing: .03em; }
tbody tr { transition: background var(--ease); } tbody tr:hover { background: var(--bg-2); }
.tabs { display: flex; gap: 5px; flex-wrap: wrap; margin-bottom: 18px; }
.tabs a { display: flex; align-items: center; gap: 7px; padding: 8px 13px; border-radius: var(--radius-sm); color: var(--muted); background: var(--panel); border: 1px solid var(--line); font-weight: 550; }
.tabs a:hover { color: var(--text); border-color: var(--accent-border); text-decoration: none; }
.tabs a.on { color: var(--accent); border-color: var(--accent); background: var(--accent-soft); }
.stack > * + * { margin-top: 16px; }
.real { color: var(--bad); font-weight: 600; }
.leak { background: var(--bad-soft); color: var(--bad); padding: 10px 12px; border-radius: var(--radius-sm); display: flex; gap: 8px; align-items: center; font-weight: 500; }
.okbox { background: var(--ok-soft); color: var(--ok); padding: 10px 12px; border-radius: var(--radius-sm); display: flex; gap: 8px; align-items: center; font-weight: 500; }
pre.json { background: var(--bg-2); padding: 12px; border-radius: var(--radius-sm); overflow: auto; max-height: 420px; font-size: 12px; font-family: ui-monospace, Menlo, Consolas, monospace; border: 1px solid var(--line); }
.modal-bg { position: fixed; inset: 0; background: rgba(10,15,25,.5); backdrop-filter: blur(3px); display: grid; place-items: center; z-index: 50; padding: 18px; animation: fade .2s ease; }
@keyframes fade { from { opacity: 0; } to { opacity: 1; } }
.modal { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius-lg); padding: 22px; width: min(540px, 100%); max-height: 90vh; overflow: auto; box-shadow: var(--sh-3); animation: pop .22s cubic-bezier(.2,.8,.2,1); }
@keyframes pop { from { opacity: 0; transform: scale(.96) translateY(8px); } to { opacity: 1; transform: none; } }
.back { display: none; }

/* iskelet yükleme */
.skel { background: linear-gradient(90deg, var(--bg-2) 25%, color-mix(in srgb, var(--muted) 12%, var(--bg-2)) 37%, var(--bg-2) 63%); background-size: 400% 100%; animation: shimmer 1.4s infinite; border-radius: 6px; }
@keyframes shimmer { 0% { background-position: 100% 0; } 100% { background-position: -100% 0; } }
.skel-ci { display: flex; gap: 11px; padding: 11px 13px; align-items: center; }
.skel-ci .a { width: 42px; height: 42px; border-radius: 13px; flex-shrink: 0; } .skel-ci .l { flex: 1; } .skel-ci .l div { height: 10px; margin: 4px 0; }
.skel-msg { height: 40px; border-radius: 14px; margin: 7px 0; }

@media (prefers-reduced-motion: reduce) { * { animation-duration: .001ms !important; transition-duration: .001ms !important; } }
@media (max-width: 1100px) { .inbox { grid-template-columns: 300px 1fr; } .col.right { display: none; } .inbox.info .col.right { display: flex; position: fixed; right: 0; top: 56px; bottom: 0; width: 330px; z-index: 30; box-shadow: var(--sh-3); } }
@media (max-width: 720px) {
  .top nav a span { display: none; } .top .who .nm { display: none; } .page { padding: 14px; }
  .inbox { grid-template-columns: 1fr; } .inbox .col.mid { display: none; }
  .inbox.open .col.left { display: none; } .inbox.open .col.mid { display: flex; }
  .inbox.info .col.right { width: 100%; } .back { display: inline-flex; } .msg { max-width: 90%; }
}
