/* ── Universal Sans (Personal Use) — yerel TTF, Grok yazı tipi ── */
@font-face {
  font-family: 'Universal Sans Text';
  src: url('UniversalSans400.woff2') format('woff2');
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: 'Universal Sans Text';
  src: url('UniversalSans550.woff2') format('woff2');
  font-weight: 550;
  font-style: normal;
  font-display: swap;
}

::selection {
    background-color: var(--bd) !important; /* Arka plan rengi değişkenin */
}

*,
*::before,
*::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box
}

.material-symbols-outlined {
  font-family: 'Material Symbols Outlined';
  font-weight: normal;
  font-style: normal;
  font-size: inherit;
  display: inline-block;
  line-height: 1;
  text-transform: none;
  letter-spacing: normal;
  word-wrap: normal;
  white-space: nowrap;
  direction: ltr;
  -webkit-font-smoothing: antialiased;
}

:root {
  /* ── MONO KARBON paleti (Grok-vari saf siyah, düz & teknik) ── */
  --bg: #000000;
  --sb: #000000;
  --sf: #161616;
  --sf2: #1f1f1f;
  --bd: #1e1e1e;
  --bd2: #2a2a2a;
  --tx: #f5f5f5;
  --mu: #9a9a9a;
  --dm: #5a5a5a;
  --aa: linear-gradient(90deg, #ff66c4, #ffde59);
  --red: #e55865;
  --grn: #4ade80;
  --blu: #60a5fa;
  --ora: #fb923c;
  --ease: .15s ease;
  /* keskin köşe ölçekleri */
  --r-sm: 6px;
  --r-md: 8px;
  --r-lg: 10px;
}

body {
  font-family: 'DM Sans', sans-serif;
  background: #000;
  color: #fff;
}

/* ── ESKİ KLASİK TEMA ── */
body.theme-klasik {
  --bg: #0c0c0c;
  --sb: #101010;
  --sf: #161616;
  --sf2: #1c1c1c;
  --bd: #222;
  --bd2: #2a2a2a;
  --tx: #e8e8e8;
  --mu: #888;
  --dm: #444;
  --aa: #ff66c4;
  --ab: #ffde59;
}

body.theme-klasik .sb {
  background: linear-gradient(180deg, var(--sb) 0%, color-mix(in srgb, var(--sb) 94%, var(--aa) 6%) 100%) !important;
  backdrop-filter: none !important;
  -webkit-backdrop-filter: none !important;
  border-right: 1px solid rgba(255, 255, 255, .05) !important
}

body.theme-klasik .main {
  background: var(--bg) !important;
  backdrop-filter: none !important
}

body.theme-klasik .tb {
  background: color-mix(in srgb, var(--bg) 75%, transparent) !important;
  backdrop-filter: blur(20px) !important
}

body.theme-klasik .ic {
  background: var(--sf) !important;
  border-color: var(--bd2) !important;
  backdrop-filter: none !important
}

body.theme-klasik .msg.user .mb {
  background: var(--sf) !important;
  border-color: var(--bd2) !important;
  backdrop-filter: none !important
}

body.theme-klasik .cw {
  background: #080808 !important;
  border-color: #1e1e1e !important
}

body.theme-klasik .ch {
  background: #0c0c0c !important;
  border-bottom-color: #1e1e1e !important
}

body.theme-klasik .mbox {
  background: var(--sf) !important;
  border-color: var(--bd2) !important;
  backdrop-filter: none !important
}

body.theme-klasik .settings-content {
  background: var(--bg) !important
}

body.theme-klasik .modal {
  backdrop-filter: blur(4px) !important
}

/* ── LIGHT MODE ── */
body[class*="theme-"] .sbtn {
  background: var(--aa) !important;
  color: var(--bg) !important
}

body[class*="theme-"] .sbtn:hover {
  opacity: .85;
  transform: scale(1.06)
}

body[class*="theme-"] .abtn {
  background: var(--aa) !important;
  color: var(--bg) !important;
  border-color: var(--aa) !important
}

body[class*="theme-"] .sbrand {
  background: var(--aa);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent
}

body[class*="theme-"] .tog-btn.on {
  background: var(--aa) !important
}

body[class*="theme-"] .mem-chip {
  background: rgba(0, 0, 0, .1);
  border-color: var(--aa);
  color: var(--aa)
}

body[class*="theme-"] .mode-badge {
  border-color: var(--aa) !important;
  color: var(--aa) !important
}

body[class*="theme-"] .pers-card.on {
  border-color: var(--aa);
  background: color-mix(in srgb, var(--aa) 12%, transparent)
}

body[class*="theme-"] .tab.active {
  background: var(--aa);
  color: var(--bg)
}

body[class*="theme-"] .amd code:not([class]) {
  color: var(--aa)
}

body[class*="theme-"] .sh-cmd {
  color: var(--aa)
}

body[class*="theme-"] .macb.tts-on svg {
  stroke: url(#macbGradient);
  fill: none;
}

body[class*="theme-"] .macb.tts-on .material-symbols-outlined {
  background: var(--aa);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

body.lm {
  --bg: #F3F3F3;
  --sb: #EFEFEF;
  --sf: rgba(0, 0, 0, .04);
  --sf2: rgba(0, 0, 0, .07);
  --bd: rgba(0, 0, 0, .08);
  --bd2: rgba(0, 0, 0, .12);
  --tx: #171717;
  --mu: #777777;
  --dm: #BBBBBB;
  background: #f3f3f3 !important;
  color: #171717 !important;
}

body.lm #app-dot-canvas,
body.lm .app-gradient-overlay {
  display: none !important
}

body.lm .sb {
  background: rgba(245, 245, 245, .85) !important;
  backdrop-filter: blur(20px) !important;
  -webkit-backdrop-filter: blur(20px) !important;
  border-right-color: rgba(0, 0, 0, .06) !important
}

body.lm .main {
  background: rgba(243, 243, 243, .6) !important
}

body.lm .tb {
  background: rgba(243, 243, 243, .7) !important;
  backdrop-filter: blur(24px) !important;
  -webkit-backdrop-filter: blur(24px) !important;
  border-bottom-color: rgba(0, 0, 0, .06) !important
}

body.lm .ic {
  background: rgba(255, 255, 255, .7) !important;
  border-color: rgba(0, 0, 0, .1) !important;
  backdrop-filter: blur(12px) !important;
  -webkit-backdrop-filter: blur(12px) !important
}

body.lm .msg.user .mb {
  background: rgba(0, 0, 0, .04) !important;
  border-color: rgba(0, 0, 0, .08) !important;
  color: #171717 !important;
  backdrop-filter: none !important
}

body.lm .cw {
  background: #f8f8f8 !important;
  border-color: #ddd !important;
  backdrop-filter: none !important
}

body.lm .ch {
  background: #f0f0f0 !important;
  border-color: #ddd !important
}

body.lm .cl2 {
  color: #aaa !important
}

body.lm .cw pre code {
  color: #24292e !important
}

body.lm .mbox {
  background: rgba(255, 255, 255, .92) !important;
  border-color: rgba(0, 0, 0, .1) !important;
  color: #171717 !important
}

body.lm .settings-grid-modal .mbox {
  background: rgba(255, 255, 255, .95) !important
}

body.lm .settings-sidebar {
  background: rgba(240, 240, 240, .9) !important;
  border-right-color: rgba(0, 0, 0, .06) !important
}

body.lm .settings-content {
  background: rgba(248, 248, 248, .9) !important;
  color: #171717 !important
}

body.lm .otp-inp {
  background: rgba(0, 0, 0, .04) !important;
  border-color: rgba(0, 0, 0, .15) !important;
  color: #171717 !important
}

body.lm .voice-inline {
  background: #fff !important;
}

body.lm .settings-card {
  background: rgba(0, 0, 0, .03) !important;
  border-color: rgba(0, 0, 0, .06) !important
}

body.lm .modal {
  background: rgba(255, 255, 255, .5) !important
}

/* ── ARKA PLAN RESMİ AKTİFKEN ── */
body.with-bg #app-dot-canvas,
body.with-bg .app-gradient-overlay {
  display: none !important
}

body.with-bg {
  background-size: cover !important;
  background-position: center !important;
  background-attachment: fixed !important
}

body.with-bg .sb {
  background: rgba(0, 0, 0, 0.55) !important;
  backdrop-filter: blur(16px) !important;
  -webkit-backdrop-filter: blur(16px) !important
}

body.with-bg .main {
  background: rgba(0, 0, 0, 0.4) !important
}

body.with-bg .tb {
  background: rgba(0, 0, 0, 0.35) !important;
  backdrop-filter: blur(20px) !important;
  border-bottom-color: rgba(255, 255, 255, 0.08) !important
}

body.with-bg .ic {
  background: rgba(0, 0, 0, 0.5) !important;
  border-color: rgba(255, 255, 255, 0.12) !important
}

body.with-bg .msg.user .mb {
  background: rgba(30, 30, 30, 0.8) !important;
  border-color: rgba(255, 255, 255, 0.12) !important
}

body.with-bg .msg.ai .mb {
  background: rgba(20, 20, 20, 0.7) !important;
  border-radius: 12px;
  padding: 12px 16px;
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px)
}

body.with-bg .cw {
  background: rgba(0, 0, 0, 0.7) !important;
  border-color: rgba(255, 255, 255, 0.1) !important
}

body.with-bg .ci:hover {
  background: rgba(255, 255, 255, 0.08) !important
}

body.with-bg .ci.on {
  background: rgba(255, 255, 255, 0.12) !important
}

body.with-bg .sbf {
  border-top-color: rgba(255, 255, 255, 0.08) !important
}

body.with-bg .sbh {
  border-bottom-color: rgba(255, 255, 255, 0.08) !important
}

/* Light + arka plan */
body.lm.with-bg {
  color: #fff !important
}

body.lm.with-bg .sb {
  background: rgba(255, 255, 255, 0.65) !important
}

body.lm.with-bg .main {
  background: rgba(255, 255, 255, 0.5) !important
}

body.lm.with-bg .tb {
  background: rgba(255, 255, 255, 0.6) !important
}

body.lm.with-bg .ic {
  background: rgba(255, 255, 255, 0.75) !important;
  border-color: rgba(0, 0, 0, 0.08) !important
}

body.lm.with-bg .msg.user .mb {
  background: rgba(255, 255, 255, 0.85) !important;
  border-color: rgba(0, 0, 0, 0.08) !important
}

body.lm.with-bg .msg.ai .mb {
  background: rgba(255, 255, 255, 0.82) !important
}

body.lm.with-bg .cw {
  background: rgba(250, 250, 250, 0.9) !important;
  border-color: rgba(0, 0, 0, 0.06) !important
}

body.lm ::-webkit-scrollbar-thumb {
  background: #ccc
}

body,
body.lm {
  transition: background .35s, color .35s
}

body * {
  transition: background-color .3s, border-color .3s, color .2s
}

body * svg,
body * img,
body * .tc,
body * .ld span {
  transition: none !important
}

.screen {
  position: fixed;
  inset: 0;
  transition: opacity .35s ease
}

.hidden {
  opacity: 0 !important;
  pointer-events: none !important
}
