/* ============================================================
   AI Lawyer — Design System
   Classic legal: navy + brass, serif headings, clean sans UI
   ============================================================ */

:root {
  /* Navy scale */
  --navy-950: #0b1626;
  --navy-900: #0f1d33;
  --navy-850: #13243f;
  --navy-800: #182c4a;
  --navy-700: #213a5e;
  --navy-600: #2e4a73;
  --navy-500: #3d5d8a;

  /* Brass / gold accent (muted, restrained) */
  --brass-600: #9a7636;
  --brass-500: #b08a47;
  --brass-400: #c6a468;
  --brass-300: #d4bd92;
  --brass-200: #ecdcbd;

  /* Warm neutral paper */
  --paper:     #f6f4ef;
  --paper-2:   #efece4;
  --card:      #ffffff;
  --card-2:    #fbfaf7;

  /* Ink / text */
  --ink-900:   #16202e;
  --ink-700:   #364152;
  --ink-500:   #5a6473;
  --ink-400:   #828b98;

  /* Lines */
  --line:      #e4e0d6;
  --line-2:    #d8d3c6;
  --line-navy: rgba(255,255,255,0.10);

  /* Status hues (muted) */
  --c-claude:  #c08552;
  --c-gpt:     #2f8f7a;
  --c-gemini:  #4471c4;
  --c-grok:    #5b6470;
  --c-deepseek:#7a59b8;
  --c-mistral: #c2603e;

  --ok:        #2f7d5b;
  --warn:      #b07d2a;
  --danger:    #b1442f;

  --radius:    14px;
  --radius-sm: 9px;
  --radius-lg: 20px;

  --shadow-sm: 0 1px 2px rgba(15,29,51,.06), 0 1px 3px rgba(15,29,51,.05);
  --shadow-md: 0 4px 14px rgba(15,29,51,.08), 0 2px 6px rgba(15,29,51,.05);
  --shadow-lg: 0 18px 50px rgba(11,22,38,.18), 0 6px 18px rgba(11,22,38,.10);

  --serif: "Source Serif 4", Georgia, "Times New Roman", serif;
  --sans:  "IBM Plex Sans", system-ui, -apple-system, sans-serif;
  --mono:  "IBM Plex Mono", ui-monospace, "SF Mono", monospace;
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  height: 100%;
  background: var(--paper);
  color: var(--ink-900);
  font-family: var(--sans);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

#root { height: 100%; }

button { font-family: inherit; cursor: pointer; }
::selection { background: var(--brass-200); color: var(--ink-900); }

/* ---- Scrollbars ---- */
.scroll { scrollbar-width: thin; scrollbar-color: var(--line-2) transparent; }
.scroll::-webkit-scrollbar { width: 9px; height: 9px; }
.scroll::-webkit-scrollbar-thumb { background: var(--line-2); border-radius: 20px; border: 2px solid transparent; background-clip: content-box; }
.scroll::-webkit-scrollbar-thumb:hover { background: var(--ink-400); background-clip: content-box; }
.scroll-navy { scrollbar-color: rgba(255,255,255,.18) transparent; }
.scroll-navy::-webkit-scrollbar-thumb { background: rgba(255,255,255,.16); }
.scroll-navy::-webkit-scrollbar-thumb:hover { background: rgba(255,255,255,.28); }

/* ============================================================
   APP SHELL
   ============================================================ */
.app {
  display: grid;
  grid-template-columns: 296px 1fr;
  height: 100%;
  overflow: hidden;
}

/* ============================================================
   SIDEBAR
   ============================================================ */
.sidebar {
  background:
    radial-gradient(120% 60% at 0% 0%, rgba(176,138,71,.10), transparent 60%),
    linear-gradient(180deg, var(--navy-900), var(--navy-950));
  color: #e9edf4;
  display: flex;
  flex-direction: column;
  border-right: 1px solid rgba(0,0,0,.25);
  min-height: 0;
}

.sb-brand {
  padding: 22px 22px 18px;
  border-bottom: 1px solid var(--line-navy);
  display: flex;
  align-items: center;
  gap: 13px;
}
.sb-brand .wordmark { display: flex; flex-direction: column; line-height: 1; }
.sb-brand .wordmark .name {
  font-family: var(--serif);
  font-weight: 600;
  font-size: 21px;
  letter-spacing: .2px;
  color: #fff;
}
.sb-brand .wordmark .name em { font-style: italic; color: var(--brass-400); }
.sb-brand .wordmark .sub {
  font-size: 11px;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: rgba(233,237,244,.55);
  margin-top: 6px;
  font-weight: 500;
}

.sb-new {
  margin: 16px 16px 8px;
  padding: 12px 16px;
  border-radius: var(--radius-sm);
  background: linear-gradient(180deg, var(--navy-600), var(--navy-700));
  color: #fff;
  border: 1px solid rgba(255,255,255,.12);
  font-size: 14px;
  font-weight: 600;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  box-shadow: 0 2px 8px rgba(0,0,0,.25), inset 0 1px 0 rgba(255,255,255,.08);
  transition: transform .12s ease, filter .15s ease;
}
.sb-new:hover { filter: brightness(1.1); transform: translateY(-1px); }
.sb-new:active { transform: translateY(0); }
.sb-new .plus { color: var(--brass-400); font-size: 17px; line-height: 1; }

.sb-list { flex: 1; overflow-y: auto; padding: 10px 10px 18px; min-height: 0; }
.sb-group-label {
  font-size: 10.5px;
  letter-spacing: .16em;
  text-transform: uppercase;
  color: rgba(233,237,244,.42);
  font-weight: 600;
  padding: 12px 10px 7px;
}
.sb-item {
  display: block;
  width: 100%;
  text-align: left;
  background: transparent;
  border: 1px solid transparent;
  color: #d7deea;
  padding: 9px 11px;
  border-radius: 9px;
  margin-bottom: 2px;
  transition: background .12s ease, border-color .12s ease;
}
.sb-item:hover { background: rgba(255,255,255,.05); }
.sb-item.active {
  background: rgba(176,138,71,.13);
  border-color: rgba(176,138,71,.30);
}
.sb-item .t {
  font-size: 13.5px;
  font-weight: 500;
  line-height: 1.35;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
  color: #eef2f7;
}
.sb-item.active .t { color: #fff; }
.sb-item .meta {
  display: flex; align-items: center; justify-content: space-between;
  margin-top: 4px;
  font-size: 11px;
  color: rgba(215,222,234,.5);
}
.sb-item .meta .pill {
  font-family: var(--mono);
  font-size: 10px;
  color: var(--brass-400);
  letter-spacing: .03em;
}

.sb-foot {
  border-top: 1px solid var(--line-navy);
  padding: 12px 16px;
  display: flex; align-items: center; gap: 10px;
  font-size: 12.5px;
  color: rgba(233,237,244,.6);
}
.sb-foot .ava {
  width: 30px; height: 30px; border-radius: 8px;
  background: linear-gradient(180deg, var(--brass-400), var(--brass-600));
  color: var(--navy-950); font-weight: 700; font-size: 13px;
  display: grid; place-items: center;
  font-family: var(--serif);
}
.sb-foot .who { line-height: 1.2; }
.sb-foot .who b { color: #fff; font-weight: 600; display: block; font-size: 13px; }

/* ============================================================
   MAIN
   ============================================================ */
.main { display: flex; flex-direction: column; min-width: 0; min-height: 0; background: var(--paper); }

.topbar {
  height: 66px;
  flex: 0 0 auto;
  display: flex; align-items: center; justify-content: space-between;
  padding: 0 26px;
  background: rgba(246,244,239,.85);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
}
.tb-left { display: flex; align-items: center; gap: 14px; min-width: 0; }
.tb-title { min-width: 0; }
.tb-title .h {
  font-family: var(--serif);
  font-size: 17px; font-weight: 600; color: var(--ink-900);
  line-height: 1.2;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 46vw;
}
.tb-title .panel-dots { display: flex; align-items: center; gap: 6px; margin-top: 5px; }
.tb-title .panel-dots .lbl { font-size: 11px; color: var(--ink-400); margin-right: 2px; font-weight: 500; }
.tb-title .panel-dots .d { width: 8px; height: 8px; border-radius: 50%; }

.tb-right { display: flex; align-items: center; gap: 14px; }

/* language segmented control */
.lang {
  display: inline-flex;
  background: var(--paper-2);
  border: 1px solid var(--line-2);
  border-radius: 9px;
  padding: 3px;
  gap: 2px;
}
.lang button {
  border: 0; background: transparent;
  font-size: 12px; font-weight: 600; letter-spacing: .04em;
  color: var(--ink-500);
  padding: 5px 11px; border-radius: 6px;
  transition: all .12s ease;
}
.lang button:hover { color: var(--ink-900); }
.lang button.on {
  background: var(--navy-800); color: #fff;
  box-shadow: var(--shadow-sm);
}

.ghost-btn {
  border: 1px solid var(--line-2);
  background: var(--card);
  color: var(--ink-700);
  font-size: 13px; font-weight: 600;
  padding: 8px 15px; border-radius: 9px;
  transition: all .12s ease;
}
.ghost-btn:hover { border-color: var(--ink-400); color: var(--ink-900); }

/* ---- conversation scroll area ---- */
.thread {
  flex: 1; overflow-y: auto; min-height: 0;
  padding: 34px 26px 30px;
}
.thread-inner { max-width: 880px; margin: 0 auto; }

/* user message */
.msg-user { display: flex; justify-content: flex-end; margin-bottom: 28px; }
.msg-user .bubble {
  max-width: 76%;
  background: var(--navy-800);
  color: #f2f5fa;
  padding: 15px 19px;
  border-radius: 16px 16px 5px 16px;
  box-shadow: var(--shadow-md);
  font-size: 15px; line-height: 1.55;
  display: flex; flex-direction: column; align-items: flex-start;
}
.msg-user .bubble .doc {
  margin-top: 12px;
  display: inline-flex; align-items: center; gap: 9px;
  background: rgba(255,255,255,.10);
  border: 1px solid rgba(255,255,255,.16);
  padding: 8px 12px; border-radius: 9px;
  font-size: 12.5px; color: #e7ecf4;
}
.msg-user .bubble .doc .ic {
  width: 22px; height: 26px; border-radius: 3px;
  background: linear-gradient(180deg,#fff,#dfe6f0);
  position: relative; flex: 0 0 auto;
}
.msg-user .bubble .doc .ic:after {
  content:""; position:absolute; top:0; right:0; width:8px; height:8px;
  background: var(--navy-700); clip-path: polygon(0 0,100% 100%,0 100%);
}

/* ---- panel of models ---- */
.panel { margin-bottom: 26px; }
.panel-head {
  display: flex; align-items: center; gap: 10px;
  margin-bottom: 13px;
}
.panel-head .lab {
  font-size: 12px; font-weight: 600; letter-spacing: .12em; text-transform: uppercase;
  color: var(--ink-500);
}
.panel-head .rule { flex: 1; height: 1px; background: var(--line); }
.panel-head .count {
  font-family: var(--mono); font-size: 11.5px; color: var(--brass-600);
  background: rgba(176,138,71,.10); border: 1px solid rgba(176,138,71,.22);
  padding: 2px 8px; border-radius: 20px;
}

.model-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 11px;
}
.mcard {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 13px 14px 12px;
  box-shadow: var(--shadow-sm);
  text-align: left; width: 100%;
  transition: transform .14s ease, box-shadow .14s ease, border-color .14s ease;
  position: relative;
}
.mcard:hover { transform: translateY(-2px); box-shadow: var(--shadow-md); border-color: var(--line-2); }
.mcard.open { border-color: var(--navy-600); box-shadow: var(--shadow-md); }
.mcard .top { display: flex; align-items: center; gap: 8px; }
.mcard .dot { width: 9px; height: 9px; border-radius: 50%; flex: 0 0 auto; box-shadow: 0 0 0 3px rgba(0,0,0,.025); }
.mcard .nm { font-family: var(--mono); font-size: 12.5px; font-weight: 600; color: var(--ink-900); letter-spacing: -.01em; }
.mcard .chev { margin-left: auto; color: var(--ink-400); transition: transform .18s ease; font-size: 11px; }
.mcard.open .chev { transform: rotate(180deg); }

.mcard .verdict {
  display: inline-flex; align-items: center;
  margin-top: 11px;
  font-size: 11.5px; font-weight: 600;
  padding: 4px 9px; border-radius: 7px;
  letter-spacing: .01em;
  white-space: nowrap;
}
.v-ok   { background: rgba(47,125,91,.10); color: var(--ok); }
.v-warn { background: rgba(176,125,42,.12); color: var(--warn); }
.v-info { background: rgba(46,74,115,.10); color: var(--navy-600); }

.mcard .conf { margin-top: 11px; }
.mcard .conf .barwrap { height: 4px; background: var(--paper-2); border-radius: 20px; overflow: hidden; }
.mcard .conf .bar { height: 100%; border-radius: 20px; }
.mcard .conf .ct { display: flex; justify-content: space-between; margin-top: 6px; font-size: 10.5px; color: var(--ink-400); }
.mcard .conf .ct b { color: var(--ink-700); font-weight: 600; font-family: var(--mono); }

.mcard .body {
  font-size: 13px; line-height: 1.6; color: var(--ink-700);
  overflow: hidden;
  max-height: 0; opacity: 0;
  transition: max-height .26s ease, opacity .2s ease, margin-top .2s ease, padding-top .2s ease;
}
.mcard.open .body {
  max-height: 320px; opacity: 1;
  margin-top: 11px; padding-top: 11px;
  border-top: 1px dashed var(--line-2);
}

/* thinking state */
.mcard.thinking { background: var(--card-2); }
.mcard.thinking .nm { color: var(--ink-400); }
.dots3 { display: inline-flex; gap: 4px; margin-top: 13px; }
.dots3 span {
  width: 6px; height: 6px; border-radius: 50%; background: var(--ink-400);
  animation: blink 1.2s infinite ease-in-out;
}
.dots3 span:nth-child(2) { animation-delay: .2s; }
.dots3 span:nth-child(3) { animation-delay: .4s; }
@keyframes blink { 0%,80%,100%{opacity:.25;transform:translateY(0)} 40%{opacity:1;transform:translateY(-2px)} }

/* ============================================================
   SYNTHESIS HERO
   ============================================================ */
.synth {
  margin-top: 4px;
  background:
    linear-gradient(180deg, rgba(176,138,71,.05), transparent 120px),
    var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  overflow: hidden;
  position: relative;
}
.synth:before {
  content:""; position: absolute; left: 0; top: 0; bottom: 0; width: 4px;
  background: linear-gradient(180deg, var(--brass-400), var(--brass-600));
}
.synth-head {
  display: flex; align-items: center; gap: 13px;
  padding: 18px 24px;
  background: linear-gradient(180deg, var(--navy-850), var(--navy-900));
  color: #fff;
}
.synth-head .meta { line-height: 1.25; min-width: 0; flex: 1; }
.synth-head .meta .k {
  font-family: var(--serif); font-size: 18px; font-weight: 600; color: #fff;
  white-space: nowrap;
}
.synth-head .meta .k em { color: var(--brass-400); font-style: italic; }
.synth-head .meta .by { font-size: 11.5px; color: rgba(233,237,244,.6); margin-top: 3px; font-family: var(--mono); }
.synth-head .tag {
  margin-left: auto;
  font-size: 11px; font-weight: 600; letter-spacing: .1em; text-transform: uppercase;
  color: var(--brass-400);
  border: 1px solid rgba(176,138,71,.4);
  padding: 5px 11px; border-radius: 20px;
}

.synth-body { padding: 22px 26px 26px; }
.synth-lede {
  font-family: var(--serif);
  font-size: 18px; line-height: 1.55; color: var(--ink-900);
  margin: 0 0 20px;
}
.synth-lede b { color: var(--navy-700); font-weight: 700; }

.synth-sec { margin-top: 20px; }
.synth-sec .sh {
  display: flex; align-items: center; gap: 9px;
  font-size: 11.5px; font-weight: 700; letter-spacing: .13em; text-transform: uppercase;
  color: var(--brass-600);
  margin-bottom: 11px;
}
.synth-sec .sh .mk { width: 6px; height: 6px; background: var(--brass-500); transform: rotate(45deg); }

.kpoints { list-style: none; margin: 0; padding: 0; display: grid; gap: 9px; }
.kpoints li {
  display: flex; gap: 11px; align-items: flex-start;
  font-size: 14.5px; line-height: 1.55; color: var(--ink-700);
}
.kpoints li .b {
  flex: 0 0 auto; margin-top: 8px; width: 6px; height: 6px; border-radius: 50%;
  background: var(--navy-600);
}

.steps { list-style: none; margin: 0; padding: 0; display: grid; gap: 11px; }
.steps li {
  display: flex; gap: 13px; align-items: flex-start;
  font-size: 14.5px; line-height: 1.55; color: var(--ink-700);
}
.steps li .n {
  flex: 0 0 auto;
  width: 26px; height: 26px; border-radius: 50%;
  background: var(--navy-800); color: #fff;
  font-family: var(--serif); font-weight: 600; font-size: 13px;
  display: grid; place-items: center;
  margin-top: 1px;
}
.steps li b { color: var(--ink-900); font-weight: 600; }

.risk {
  margin-top: 22px;
  display: flex; gap: 13px;
  background: rgba(177,68,47,.05);
  border: 1px solid rgba(177,68,47,.18);
  border-radius: var(--radius);
  padding: 15px 17px;
}
.risk .ic {
  flex: 0 0 auto; width: 28px; height: 28px; border-radius: 8px;
  background: rgba(177,68,47,.12); color: var(--danger);
  display: grid; place-items: center; font-weight: 800; font-family: var(--serif);
}
.risk .tx { font-size: 13.5px; line-height: 1.55; color: var(--ink-700); }
.risk .tx b { color: var(--danger); }

.synth-foot {
  margin-top: 22px; padding-top: 16px;
  border-top: 1px solid var(--line);
  display: flex; align-items: center; gap: 16px; flex-wrap: wrap;
}
.synth-foot .agree {
  display: flex; align-items: center; gap: 8px;
  font-size: 12.5px; color: var(--ink-500);
}
.synth-foot .agree .pips { display: flex; gap: 3px; }
.synth-foot .agree .pips i { width: 7px; height: 14px; border-radius: 2px; background: var(--ok); display: inline-block; }
.synth-foot .agree .pips i.off { background: var(--line-2); }
.synth-foot .acts { margin-left: auto; display: flex; gap: 8px; }
.synth-foot .acts button {
  border: 1px solid var(--line-2); background: var(--card);
  color: var(--ink-600); font-size: 12.5px; font-weight: 600;
  padding: 7px 13px; border-radius: 8px; transition: all .12s ease;
  display: inline-flex; align-items: center; gap: 7px;
}
.synth-foot .acts button:hover { border-color: var(--ink-400); color: var(--ink-900); background: var(--card-2); }

.disclaimer {
  max-width: 880px; margin: 22px auto 0;
  font-size: 11.5px; color: var(--ink-400); line-height: 1.5;
  display: flex; gap: 9px; align-items: flex-start;
}
.disclaimer .s { color: var(--brass-500); font-weight: 700; }

/* ============================================================
   COMPOSER
   ============================================================ */
.composer-wrap {
  flex: 0 0 auto;
  padding: 14px 26px 18px;
  background: linear-gradient(180deg, rgba(246,244,239,0), var(--paper) 36%);
  border-top: 1px solid var(--line);
}
.composer {
  max-width: 880px; margin: 0 auto;
  display: flex; align-items: flex-end; gap: 10px;
  background: var(--card);
  border: 1.5px solid var(--line-2);
  border-radius: 16px;
  padding: 9px 9px 9px 12px;
  box-shadow: var(--shadow-md);
  transition: border-color .15s ease, box-shadow .15s ease;
}
.composer.focus { border-color: var(--navy-600); box-shadow: 0 0 0 4px rgba(46,74,115,.10), var(--shadow-md); }
.composer .attach {
  flex: 0 0 auto; width: 38px; height: 38px; border-radius: 10px;
  border: 1px solid var(--line); background: var(--card-2);
  color: var(--ink-500); display: grid; place-items: center;
  transition: all .12s ease;
}
.composer .attach:hover { color: var(--navy-700); border-color: var(--line-2); }
.composer textarea {
  flex: 1; border: 0; outline: 0; resize: none; background: transparent;
  font-family: var(--sans); font-size: 15px; line-height: 1.5; color: var(--ink-900);
  padding: 9px 4px; max-height: 160px; min-height: 24px;
}
.composer textarea::placeholder { color: var(--ink-400); }
.composer .send {
  flex: 0 0 auto; width: 40px; height: 40px; border-radius: 11px;
  background: linear-gradient(180deg, var(--navy-700), var(--navy-850));
  color: #fff; border: 1px solid rgba(255,255,255,.12);
  display: grid; place-items: center;
  box-shadow: 0 2px 8px rgba(15,29,51,.25);
  transition: filter .12s ease, transform .12s ease;
}
.composer .send:hover { filter: brightness(1.12); transform: translateY(-1px); }
.composer .send:disabled { opacity: .4; cursor: default; transform: none; filter: none; }
.composer-hint {
  max-width: 880px; margin: 9px auto 0;
  text-align: center; font-size: 11.5px; color: var(--ink-400);
}
.composer-hint b { color: var(--ink-500); font-weight: 600; }

/* attached chips in composer */
.attached-row { max-width: 880px; margin: 0 auto 9px; display: flex; gap: 8px; flex-wrap: wrap; }
.attached-row .chip {
  display: inline-flex; align-items: center; gap: 8px;
  background: var(--card); border: 1px solid var(--line-2);
  padding: 6px 10px; border-radius: 9px; font-size: 12px; color: var(--ink-700);
  box-shadow: var(--shadow-sm);
}
.attached-row .chip .x { color: var(--ink-400); cursor: pointer; font-weight: 700; }
.attached-row .chip .x:hover { color: var(--danger); }

/* ---- disclosure for individual answers ---- */
.disclose {
  margin: 16px 0 4px;
  display: inline-flex; align-items: center; gap: 9px;
  background: transparent; border: 1px solid var(--line-2);
  color: var(--ink-600); font-size: 13px; font-weight: 600;
  padding: 8px 14px; border-radius: 20px; transition: all .12s ease;
}
.disclose:hover { border-color: var(--navy-600); color: var(--navy-700); background: var(--card); }
.disclose .chev { transition: transform .2s ease; font-size: 10px; }
.disclose.open .chev { transform: rotate(180deg); }

/* entrance */
.enter { animation: rise .4s cubic-bezier(.2,.7,.2,1) both; }
@keyframes rise { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }

@media (max-width: 1080px) {
  .model-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 860px) {
  .app { grid-template-columns: 1fr; }
  .sidebar { display: none; }
}

/* ============================================================
   LIVE dodatki — login, intake, markdown, empty
   ============================================================ */
.boot { display:flex; align-items:center; justify-content:center; height:100%; color:var(--ink-400); font-size:24px; }

.login-screen { display:flex; align-items:center; justify-content:center; height:100%;
  background:radial-gradient(1200px 600px at 50% -10%, var(--navy-800), var(--navy-950)); }
.login-card { background:var(--card); border:1px solid var(--line); border-radius:var(--radius-lg);
  padding:38px 34px; width:340px; text-align:center; box-shadow:var(--shadow-lg);
  display:flex; flex-direction:column; align-items:center; gap:10px; }
.login-brand { font-family:var(--serif); font-size:26px; color:var(--ink-900); margin-top:6px; }
.login-brand em { color:var(--brass-600); font-style:italic; }
.login-sub { font-size:12.5px; color:var(--ink-400); text-transform:uppercase; letter-spacing:.12em; margin-bottom:8px; }
.login-input { width:100%; padding:12px 14px; border:1px solid var(--line-2); border-radius:var(--radius-sm);
  font-family:var(--sans); font-size:15px; outline:none; transition:border .15s; }
.login-input:focus { border-color:var(--navy-500); }
.login-input.err { border-color:var(--danger); }
.login-err { color:var(--danger); font-size:13px; }
.login-btn { width:100%; padding:12px; border:none; border-radius:var(--radius-sm); cursor:pointer;
  background:var(--navy-800); color:#fff; font-size:15px; font-weight:600; transition:filter .15s; }
.login-btn:hover:not(:disabled) { filter:brightness(1.12); }
.login-btn:disabled { opacity:.5; cursor:default; }

.empty-hint { display:flex; flex-direction:column; align-items:center; justify-content:center;
  gap:14px; padding:60px 20px; color:var(--ink-400); text-align:center; }
.empty-hint p { font-family:var(--serif); font-size:17px; color:var(--ink-500); max-width:380px; }

.thinking-row { display:flex; align-items:center; gap:10px; padding:14px 4px; color:var(--ink-400); font-size:14px; }

/* intake */
.intake { margin:6px 0 14px; border:1px solid var(--line-2); border-left:3px solid var(--brass-500);
  border-radius:var(--radius-sm); background:var(--card-2); overflow:hidden; }
.intake-head { width:100%; display:flex; align-items:center; gap:9px; padding:11px 14px; cursor:pointer;
  background:transparent; border:none; font-family:var(--sans); font-size:13.5px; font-weight:600;
  color:var(--navy-800); text-align:left; }
.intake-head .ico { font-size:14px; }
.intake-head .lab { flex:1; }
.intake-head .chev { color:var(--ink-400); transition:transform .2s; }
.intake.open .intake-head .chev { transform:rotate(180deg); }
.intake-body { padding:4px 16px 16px; font-size:14px; color:var(--ink-700); line-height:1.6; }
.intake-body p { margin:6px 0; }
.intake-body b { color:var(--navy-800); }

/* model card body markdown clamp */
.mcard .body.clamp { display:-webkit-box; -webkit-line-clamp:4; -webkit-box-orient:vertical;
  overflow:hidden; }
.mcard .body { font-size:13px; line-height:1.55; color:var(--ink-700); text-align:left; }
.mcard .body p { margin:5px 0; }
.mcard .body h1,.mcard .body h2,.mcard .body h3 { font-size:13.5px; margin:6px 0 3px; }

/* synthesis markdown */
.synth-md { font-size:15px; line-height:1.7; color:var(--ink-900); }
.synth-md h1 { font-family:var(--serif); font-size:22px; margin:4px 0 12px; color:var(--navy-900); }
.synth-md h2 { font-family:var(--serif); font-size:19px; margin:18px 0 8px; color:var(--navy-800);
  border-bottom:1px solid var(--line); padding-bottom:4px; }
.synth-md h3 { font-size:16px; margin:14px 0 6px; color:var(--navy-700); }
.synth-md p { margin:9px 0; }
.synth-md ul,.synth-md ol { margin:9px 0; padding-left:22px; }
.synth-md li { margin:5px 0; }
.synth-md b { color:var(--navy-800); }
.synth-md a { color:var(--brass-600); text-decoration:underline; word-break:break-all; }
.synth-md code { font-family:var(--mono); font-size:13px; background:var(--paper-2); padding:1px 5px; border-radius:4px; }
.synth-md pre { background:var(--navy-950); color:#e8eef7; padding:14px; border-radius:var(--radius-sm); overflow-x:auto; }
.synth-md pre code { background:none; color:inherit; }
.synth-md table { border-collapse:collapse; width:100%; margin:12px 0; font-size:13.5px; }
.synth-md th,.synth-md td { border:1px solid var(--line-2); padding:7px 10px; text-align:left; }
.synth-md th { background:var(--paper-2); font-weight:600; }
.sb-empty { padding:16px 14px; color:var(--ink-400); font-size:13px; }

/* ============================================================
   FIX: model kartice — poln prikaz odgovora (povozi staro demo logiko)
   ============================================================ */
.mcard .body {
  max-height: none !important;
  opacity: 1 !important;
  overflow: visible !important;
  margin-top: 10px;
  font-size: 13px; line-height: 1.6; color: var(--ink-700);
}
/* zaprta kartica: predogled nekaj vrstic */
.mcard:not(.open) .body.clamp {
  display: -webkit-box !important;
  -webkit-line-clamp: 3 !important;
  -webkit-box-orient: vertical !important;
  overflow: hidden !important;
  max-height: none !important;
}
/* odprta kartica: cel tekst, brez rezanja */
.mcard.open .body {
  display: block !important;
  -webkit-line-clamp: unset !important;
  max-height: none !important;
  overflow: visible !important;
}
.mcard.open .body * { max-height: none !important; }
/* da gumb-kartica lahko raste */
.mcard { height: auto !important; overflow: visible !important; }
.mcard .body a { color: var(--brass-600); text-decoration: underline; word-break: break-word; }
.mcard .body ul, .mcard .body ol { padding-left: 18px; margin: 6px 0; }
.mcard .body table { width:100%; border-collapse:collapse; font-size:12px; margin:8px 0; }
.mcard .body th, .mcard .body td { border:1px solid var(--line-2); padding:4px 6px; }

/* ============================================================
   MOBILE — responsive (telefon)
   ============================================================ */
.tb-menu { display: none; background: none; border: none; color: var(--ink-700);
  padding: 6px; margin-right: 6px; cursor: pointer; align-items: center; }
.sb-close { display: none; margin-left: auto; background: none; border: none;
  color: var(--ink-400); cursor: pointer; padding: 4px; }
.sidebar-overlay { display: none; }

@media (max-width: 860px) {
  .app { grid-template-columns: 1fr; }

  /* sidebar postane drsni predal */
  .sidebar {
    display: flex !important;
    position: fixed; top: 0; left: 0; bottom: 0;
    width: 82%; max-width: 320px; z-index: 1000;
    transform: translateX(-100%);
    transition: transform .26s ease;
    box-shadow: 0 0 40px rgba(0,0,0,.35);
  }
  .sidebar.mobile-open { transform: translateX(0); }
  .sb-close { display: inline-flex; }

  .sidebar-overlay {
    display: block; position: fixed; inset: 0;
    background: rgba(8,14,24,.5); z-index: 999;
  }

  .tb-menu { display: inline-flex; }

  /* topbar bolj kompakten */
  .topbar { padding: 10px 12px; gap: 8px; }
  .tb-title .h { font-size: 15px; max-width: 50vw; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
  .panel-dots { display: none; }
  .ghost-btn span, .ghost-btn { font-size: 0; }
  .ghost-btn svg { width: 18px; height: 18px; }
  .lang button { padding: 5px 8px; font-size: 12px; }

  /* vsebina */
  .thread { padding: 12px 12px 0; }
  .thread-inner { max-width: 100%; }
  .model-grid { grid-template-columns: 1fr !important; gap: 8px; }
  .synth { border-radius: 12px; }
  .synth-body { padding: 16px 14px; }
  .synth-md { font-size: 14.5px; }
  .synth-md h1 { font-size: 19px; }
  .synth-md h2 { font-size: 17px; }
  .synth-md table { font-size: 12px; display: block; overflow-x: auto; }
  .msg-user .bubble { max-width: 88%; }
  .composer-wrap { padding: 10px 12px; }
  .composer textarea { font-size: 16px; } /* prepreci zoom na iOS */
  .intake-body { font-size: 13.5px; }
  .mcard .body { font-size: 13.5px; }

  /* disclaimer manjsi */
  .disclaimer { font-size: 11px; padding: 10px 12px; }
}

@media (max-width: 480px) {
  .tb-title .h { max-width: 40vw; }
  .sidebar { width: 88%; }
  .login-card { width: 90%; max-width: 340px; }
}

/* intake meta vrstica */
.intake-body .intake-meta { font-size: 12px; color: var(--ink-400); margin-top: 10px;
  padding-top: 8px; border-top: 1px solid var(--line); font-family: var(--mono); }
.intake-body p { margin: 7px 0; }
.intake-body p b { color: var(--navy-800); }

/* ===== Iskalnik po projektih ===== */
.sb-search { position: relative; padding: 0 14px 10px; }
.sb-search input {
  width: 100%; box-sizing: border-box; padding: 9px 30px 9px 12px;
  border: 1px solid var(--line); border-radius: 9px; font-size: 13px;
  background: rgba(255,255,255,.06); color: inherit; font-family: var(--sans);
}
.sb-search input::placeholder { color: var(--ink-400); }
.sb-search input:focus { outline: none; border-color: var(--brass, #c6a468); }
.sb-search-x {
  position: absolute; right: 22px; top: 8px; background: none; border: none;
  color: var(--ink-400); cursor: pointer; padding: 2px; display: inline-flex;
}
.sb-result { display: block; }
.sb-snip { font-size: 11.5px; color: var(--ink-400); margin-top: 3px; line-height: 1.4; }
.sb-snip-tag { display: inline-block; color: var(--brass, #c6a468); margin-right: 4px; font-weight: 600; }
.sb-snip-txt { display: block; overflow: hidden; text-overflow: ellipsis;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }


/* ===== Google prijava ===== */
.login-google {
  display: flex; align-items: center; justify-content: center; gap: 10px;
  width: 100%; box-sizing: border-box; padding: 11px 14px; margin-top: 4px;
  border: 1px solid var(--line); border-radius: 10px; background: #fff;
  color: #1f2430; font-weight: 600; font-size: 14px; text-decoration: none;
  font-family: var(--sans); cursor: pointer; transition: background .15s, box-shadow .15s;
}
.login-google:hover { background: #f7f8fa; box-shadow: 0 1px 4px rgba(0,0,0,.08); }
.login-or {
  display: flex; align-items: center; text-align: center;
  color: var(--ink-400); font-size: 12px; margin: 14px 0 10px; gap: 10px;
}
.login-or::before, .login-or::after {
  content: ""; flex: 1; height: 1px; background: var(--line);
}


/* ===== Izvozni meni ===== */
.exp-wrap { position: relative; display: inline-block; }
.exp-menu {
  position: absolute; bottom: calc(100% + 6px); right: 0; z-index: 50;
  background: #fff; border: 1px solid var(--line); border-radius: 10px;
  box-shadow: 0 8px 28px rgba(8,14,24,.16); padding: 8px; min-width: 190px;
}
.exp-group { padding: 4px; }
.exp-group + .exp-group { border-top: 1px solid var(--line); margin-top: 4px; }
.exp-lbl { font-size: 11px; color: var(--ink-400); margin: 2px 4px 6px; font-weight: 600; }
.exp-menu button {
  display: inline-block; margin: 2px 4px 2px 0; padding: 6px 14px;
  border: 1px solid var(--line); border-radius: 7px; background: #fafafa;
  font-size: 13px; cursor: pointer; font-family: var(--sans); color: var(--navy-800);
}
.exp-menu button:hover { background: var(--brass-50, #f3ead8); border-color: var(--brass-400, #c6a468); }


/* ===== Prikaz porabe ===== */
.usage-pill {
  display: inline-flex; align-items: center; gap: 6px; padding: 5px 10px;
  border: 1px solid var(--line); border-radius: 999px; background: rgba(198,164,104,.08);
  font-size: 12px; font-family: var(--mono); white-space: nowrap;
}
.usage-pill .up-lbl { color: var(--ink-400); }
.usage-pill .up-val { color: var(--brass-600, #9c7b3e); font-weight: 700; }
.cost-btn {
  display: inline-flex; align-items: center; gap: 4px; padding: 6px 10px;
  border: 1px solid var(--line); border-radius: 8px; background: #fafafa;
  font-size: 12.5px; font-family: var(--mono); cursor: pointer; color: var(--ink-700);
}
.cost-btn:hover { background: var(--brass-50, #f3ead8); }
.cost-detail {
  margin: 10px 16px 14px; border: 1px solid var(--line); border-radius: 10px;
  overflow: hidden; font-size: 12.5px;
}
.cost-row { display: flex; align-items: center; padding: 7px 12px; gap: 10px; }
.cost-row + .cost-row { border-top: 1px solid var(--line); }
.cost-row .cm-name { flex: 1; color: var(--navy-800); }
.cost-row .cm-tok { color: var(--ink-400); font-family: var(--mono); font-size: 11px; }
.cost-row .cm-cost { font-family: var(--mono); font-weight: 600; color: var(--ink-700); min-width: 70px; text-align: right; }
.cost-total { background: rgba(198,164,104,.1); font-weight: 700; }
.cost-total .cm-cost { color: var(--brass-600, #9c7b3e); }
@media (max-width: 860px) { .usage-pill .up-lbl { display: none; } }

/* ===== Thinking panel: faze + pravni izreki ===== */
.think-panel { padding: 18px 20px; }
.think-phase { display: flex; align-items: flex-start; gap: 14px; }
.tp-steps { display: flex; flex-direction: column; gap: 5px; }
.tp-step {
  font-size: 13.5px; color: var(--ink-400, #8a8f9a); transition: color .3s ease, opacity .3s ease;
  font-family: var(--sans); opacity: .55; font-weight: 500;
  display: flex; align-items: baseline; gap: 2px;
  -webkit-font-smoothing: antialiased;
}
.tp-step .tp-mark { display: inline-block; width: 16px; flex: 0 0 16px; color: var(--ink-400, #b0b4bd); }
/* aktivnost oznacimo z barvo + markerjem, NE s krepko pisavo (da ni reflowa/prekrivanja med animacijo) */
.tp-step.active { color: var(--navy-800, #1f2a3d); opacity: 1; }
.tp-step.active .tp-mark { color: var(--brass-600, #c6a468); }
.tp-step.done { color: var(--ink-700, #5a6072); opacity: .85; }
.tp-step.done .tp-mark { color: #5fa463; }

.think-maxim {
  margin-top: 16px; padding: 14px 16px; border-left: 3px solid var(--brass-400, #c6a468);
  background: rgba(198,164,104,.07); border-radius: 0 8px 8px 0;
  transition: opacity .4s ease, transform .4s ease;
}
.think-maxim.in { opacity: 1; transform: translateY(0); }
.think-maxim.out { opacity: 0; transform: translateY(4px); }
.think-maxim .tm-la {
  font-family: "Source Serif 4", Georgia, serif; font-style: italic; font-size: 16px;
  color: var(--navy-800, #1f2a3d); margin-bottom: 3px;
}
.think-maxim .tm-tr { font-size: 13px; color: var(--ink-700, #6a7180); }
@media (max-width: 860px) {
  .think-panel { padding: 14px 14px; }
  .tp-step { font-size: 12.5px; }
  .think-maxim .tm-la { font-size: 14.5px; }
}


/* ===== Koncni dokument (ovoj v sintezi) ===== */
.final-doc {
  margin: 16px 0; padding: 18px 20px; border: 1px solid var(--brass-400, #c6a468);
  border-radius: 10px; background: #fffdf8; position: relative;
}
.final-doc .fd-tag {
  display: inline-block; font-family: var(--mono); font-size: 11px; letter-spacing: .06em;
  color: var(--brass-600, #9c7b3e); margin-bottom: 10px; padding: 3px 8px;
  border: 1px solid var(--brass-400, #c6a468); border-radius: 999px; background: rgba(198,164,104,.08);
}
.exp-doc { border-top: 1px solid var(--line); margin-top: 4px; }
.exp-doc .exp-lbl { color: var(--brass-600, #9c7b3e); }


/* ===== Panel: seznam levo + odgovor desno ===== */
.panel-split {
  display: grid; grid-template-columns: 240px 1fr; gap: 16px;
  border: 1px solid var(--line); border-radius: var(--radius);
  background: var(--card); overflow: hidden; min-height: 280px;
}
.ps-list {
  display: flex; flex-direction: column; gap: 2px;
  padding: 10px; border-right: 1px solid var(--line);
  background: var(--card-2, #fafafa);
}
.mrow {
  display: flex; align-items: center; gap: 9px; width: 100%;
  padding: 10px 11px; border-radius: 9px; border: 1px solid transparent;
  background: transparent; text-align: left; cursor: pointer;
  transition: background .14s, border-color .14s;
}
.mrow:hover { background: rgba(0,0,0,.03); }
.mrow.active { background: var(--card); border-color: var(--navy-600); box-shadow: var(--shadow-sm); }
.mrow .dot { width: 9px; height: 9px; border-radius: 50%; flex: 0 0 auto; }
.mrow .nm { font-family: var(--mono); font-size: 12px; font-weight: 600; color: var(--ink-900); flex: 1; letter-spacing: -.01em; }
.mrow .chev { color: var(--ink-400); transform: rotate(-90deg); }
.mrow.active .chev { color: var(--navy-600); }
.dots3.mini { margin: 0; }

.ps-detail { padding: 18px 20px; overflow-y: auto; max-height: 560px; }
.ps-detail-head { display: flex; align-items: center; gap: 9px; margin-bottom: 12px; padding-bottom: 11px; border-bottom: 1px dashed var(--line-2); }
.ps-detail-head .dot { width: 10px; height: 10px; border-radius: 50%; }
.ps-detail-head .nm { font-family: var(--mono); font-size: 13px; font-weight: 700; color: var(--ink-900); }
.ps-detail-body { font-size: 13.5px; line-height: 1.65; color: var(--ink-700); }
.ps-empty { color: var(--ink-400); font-size: 13px; padding: 20px; }

@media (max-width: 860px) {
  .panel-split { grid-template-columns: 1fr; min-height: 0; }
  .ps-list { flex-direction: column; border-right: none; border-bottom: 1px solid var(--line); }
  .ps-detail { max-height: none; }
}

/* ===== Jezikovni preklopnik: namizje vrsta / mobilno strnjeno ===== */
.lang-row { display: inline-flex; gap: 2px; }
.lang-compact { display: none; position: relative; }
.lang-cur {
  display: inline-flex; align-items: center; gap: 5px;
  border: 0; background: var(--navy-800); color: #fff;
  font-size: 12px; font-weight: 700; letter-spacing: .04em;
  padding: 6px 11px; border-radius: 7px; cursor: pointer;
}
.lang-menu {
  position: absolute; top: calc(100% + 6px); right: 0; z-index: 60;
  background: var(--card); border: 1px solid var(--line-2); border-radius: 10px;
  box-shadow: var(--shadow-md); padding: 4px; min-width: 92px;
  display: flex; flex-direction: column; gap: 2px;
}
.lang-menu button {
  border: 0; background: transparent; text-align: left;
  font-size: 13px; font-weight: 600; color: var(--ink-700);
  padding: 9px 12px; border-radius: 7px; cursor: pointer;
}
.lang-menu button:hover { background: rgba(0,0,0,.04); }
.lang-menu button.on { background: var(--navy-800); color: #fff; }

@media (max-width: 860px) {
  .lang { background: transparent; border: 0; padding: 0; }
  .lang-row { display: none; }
  .lang-compact { display: inline-flex; }
}


/* ===== Pripis modela v protislovjih (klikljiva znacka) ===== */
.model-tag {
  display: inline-flex; align-items: center; gap: 5px;
  border: 1px solid var(--line-2); background: var(--paper-2);
  border-radius: 999px; padding: 1px 9px 1px 7px; margin: 0 2px;
  font-family: var(--mono); font-size: 11px; font-weight: 600;
  color: var(--ink-700); cursor: pointer; vertical-align: baseline;
  transition: background .12s, border-color .12s, transform .1s;
}
.model-tag:hover { background: var(--card); border-color: var(--navy-600); transform: translateY(-1px); }
.model-tag .mt-dot { width: 7px; height: 7px; border-radius: 50%; flex: 0 0 auto; }
.mt-opus { background: #b5762e; }
.mt-gpt { background: #2f8f5b; }
.mt-gemini { background: #3b6fd4; }
.mt-grok { background: #555a66; }
.mt-deepseek { background: #6b4fc7; }
.mt-mistral { background: #c0492e; }

/* ===== Mikrofon (govor v besedilo) ===== */
.composer .mic {
  display: inline-flex; align-items: center; justify-content: center;
  width: 38px; height: 38px; border-radius: 10px;
  border: 1px solid var(--line-2); background: var(--card);
  color: var(--ink-700); cursor: pointer; flex: 0 0 auto;
  transition: background .14s, color .14s, border-color .14s;
}
.composer .mic:hover { background: var(--paper-2); color: var(--ink-900); }
.composer .mic:disabled { opacity: .5; cursor: default; }
.composer .mic.rec {
  background: #c0392b; border-color: #c0392b; color: #fff;
  animation: micpulse 1.2s ease-in-out infinite;
}
@keyframes micpulse {
  0%,100% { box-shadow: 0 0 0 0 rgba(192,57,43,.45); }
  50% { box-shadow: 0 0 0 6px rgba(192,57,43,0); }
}
.composer .mic.busy { color: var(--brass-600, #9c7b3e); }


/* ===== Sidebar akcije (preimenuj/izbrisi) ===== */
.sb-item { display: flex; align-items: flex-start; gap: 6px; }
.sb-item-main { flex: 1; min-width: 0; cursor: pointer; }
.sb-actions { display: flex; gap: 4px; opacity: .35; flex: 0 0 auto; align-items: center; transition: opacity .2s ease; }
.sb-item:hover .sb-actions, .sb-item.active .sb-actions { opacity: 1; }
.sb-act {
  border: 0; background: transparent; color: var(--ink-400, #9aa0ab);
  padding: 4px; border-radius: 6px; cursor: pointer; display: inline-flex;
}
.sb-act { color: #8a909c; }
.sb-act:hover { background: rgba(198,164,104,.18); color: #9c7b3e; }
.sb-act-del { color: #c5897e; }
.sb-act-del:hover { background: rgba(192,57,43,.12); color: #c0392b; }

/* ===== Modalno okno (brisanje) ===== */
.modal-overlay {
  position: fixed; inset: 0; z-index: 200; background: rgba(15,20,30,.55);
  display: flex; align-items: center; justify-content: center; padding: 20px;
  backdrop-filter: blur(2px);
}
.modal {
  background: var(--card, #fff); border-radius: 16px; max-width: 440px; width: 100%;
  padding: 26px 26px 22px; box-shadow: 0 24px 60px rgba(0,0,0,.3); text-align: center;
}
.modal-icon {
  width: 48px; height: 48px; border-radius: 50%; margin: 0 auto 14px;
  display: flex; align-items: center; justify-content: center;
  background: rgba(192,57,43,.1); color: #c0392b;
}
.modal h3 { margin: 0 0 8px; font-size: 18px; color: var(--ink-900); }
.del-q { font-size: 14px; color: var(--ink-700); margin: 0 0 6px; }
.del-warn { font-size: 12.5px; color: #c0392b; margin: 0 0 16px; line-height: 1.5; }
.del-code-row { display: flex; flex-direction: column; align-items: center; gap: 6px; margin-bottom: 10px; }
.del-code-lbl { font-size: 12px; color: var(--ink-500); }
.del-code {
  font-family: var(--mono); font-size: 22px; font-weight: 700; letter-spacing: .28em;
  color: var(--navy-800); background: var(--paper-2); padding: 8px 16px; border-radius: 8px;
  border: 1px dashed var(--line-2); user-select: none;
}
.del-input {
  width: 100%; text-align: center; font-family: var(--mono); font-size: 18px; letter-spacing: .2em;
  padding: 11px; border: 1px solid var(--line-2); border-radius: 9px; margin-bottom: 18px;
  text-transform: uppercase;
}
.del-input:focus { outline: none; border-color: var(--navy-600); }
.modal-actions { display: flex; gap: 10px; justify-content: center; }
.btn-ghost {
  border: 1px solid var(--line-2); background: var(--card); color: var(--ink-700);
  padding: 10px 18px; border-radius: 9px; cursor: pointer; font-size: 14px; font-weight: 600;
}
.btn-ghost:hover { background: var(--paper-2); }
.btn-danger {
  border: 0; background: #c0392b; color: #fff;
  padding: 10px 18px; border-radius: 9px; cursor: pointer; font-size: 14px; font-weight: 700;
}
.btn-danger:disabled { opacity: .4; cursor: default; }
.btn-danger:not(:disabled):hover { background: #a93226; }


/* ===== Drag & drop nalaganje datotek ===== */
.main { position: relative; }
.drop-overlay {
  position: absolute; inset: 0; z-index: 90;
  background: rgba(20,44,74,.32); backdrop-filter: blur(2px);
  display: flex; align-items: center; justify-content: center;
  pointer-events: none; padding: 24px;
}
.drop-card {
  background: var(--card, #fff); border: 2px dashed var(--navy-500, #3d5d8a);
  border-radius: 16px; padding: 28px 40px; text-align: center;
  box-shadow: 0 16px 48px rgba(0,0,0,.22); color: var(--navy-800, #182c4a);
}
.drop-card p { margin: 12px 0 4px; font-size: 17px; font-weight: 700; }
.drop-card span { font-size: 12.5px; color: var(--ink-500, #6b7280); letter-spacing: .02em; }


/* ===== Hitro / Panel preklop (segmenti enake visine) ===== */
.mode-row {
  max-width: 880px; margin: 0 auto;
  display:flex; align-items:center; gap:12px; padding:10px 0 0;
}
.mode-switch {
  display:flex; flex:0 0 auto; width:220px; height:38px;
  background:#e6eaf0; border:1px solid #d3dae4;
  border-radius:999px; padding:4px; box-sizing:border-box;
  box-shadow: inset 0 1px 2px rgba(30,50,80,.08);
}
.mode-opt {
  flex:1 1 0; height:100%;
  display:inline-flex; align-items:center; justify-content:center; gap:6px;
  border:none; background:transparent; cursor:pointer;
  font-size:13px; font-weight:600; color:#5b6472;
  border-radius:999px; transition:background .18s, color .18s;
  white-space:nowrap; line-height:1; padding:0 8px;
}
.mode-opt:not(.on):hover { color:#2a3340; }
.mode-opt.on { background:#23406b; color:#fff; }
.mode-opt.on.panel { background:#9c7b3e; }
.mode-opt:disabled { cursor:default; }
.mode-desc { font-size:12px; color:#9aa3af; line-height:1.3; }

@media (max-width: 760px) {
  .mode-row { max-width:none; padding:10px 12px 0; }
  .mode-switch { flex:1 1 auto; width:auto; }
  .mode-desc { display:none; }
}

/* ===== Hitri klepet bubble ===== */
.chat-bubble { max-width:760px; margin:6px 0 18px; background:var(--card,#fff);
  border:1px solid var(--line-2,#dce2ea); border-left:3px solid #c6a468;
  border-radius:12px; padding:14px 18px; box-shadow:0 1px 4px rgba(0,0,0,.05); }
.chat-tag { display:inline-flex; align-items:center; gap:5px; font-size:11px; font-weight:700;
  letter-spacing:.03em; text-transform:uppercase; color:#9c7b3e; margin-bottom:8px; }
.chat-body { font-size:14.5px; line-height:1.62; color:var(--ink-800,#1f2937); }
.chat-body p:first-child { margin-top:0; }
.chat-body p:last-child { margin-bottom:0; }


/* Send gumb v PANEL nacinu - zlat z ikono tehtnice */
.composer .send.send-panel {
  background: linear-gradient(180deg, #b5904a, #9c7b3e);
  box-shadow: 0 2px 10px rgba(156,123,62,.38);
  border-color: rgba(255,255,255,.18);
}
.composer .send.send-panel:hover { filter: brightness(1.06); }


/* Gumb "Poslji v panel" pod hitrim klepetom */
.chat-actions { margin-top: 12px; padding-top: 10px; border-top: 1px solid var(--line-1,#eef1f5); }
.to-panel-btn {
  display: inline-flex; align-items: center; gap: 7px;
  background: linear-gradient(180deg, #b5904a, #9c7b3e); color: #fff;
  border: 1px solid rgba(255,255,255,.18); border-radius: 9px;
  padding: 8px 14px; font-size: 13px; font-weight: 600; cursor: pointer;
  box-shadow: 0 2px 8px rgba(156,123,62,.30); transition: filter .12s, transform .08s;
}
.to-panel-btn:hover:not(:disabled) { filter: brightness(1.07); }
.to-panel-btn:active:not(:disabled) { transform: translateY(1px); }
.to-panel-btn:disabled { opacity: .5; cursor: default; }


/* Ime odvetnika v spodnjem levem kotu */
.sidebar { display: flex; flex-direction: column; }
.sidebar-foot { margin-top: auto; padding: 14px 18px; border-top: 1px solid var(--line,#e6e8ee); }
.sidebar-foot .sf-name { font-size: 13.5px; font-weight: 700; color: var(--navy-800,#182c4a); }
.sidebar-foot .sf-sub { font-size: 11px; color: var(--ink-500,#8a93a3); margin-top: 2px; line-height: 1.35; }

.chat-think { padding:10px 4px; }
.chat-think .tp-steps { gap:6px; }

/* login: animiran gradient na naslovu + ime odvetnika */
.login-brand.shimmer {
  background: linear-gradient(100deg, var(--ink-900) 0%, var(--ink-900) 35%, var(--brass-400) 50%, var(--ink-900) 65%, var(--ink-900) 100%);
  background-size: 220% 100%;
  -webkit-background-clip: text; background-clip: text;
  -webkit-text-fill-color: transparent; color: transparent;
  animation: brandShimmer 4.5s ease-in-out infinite;
}
.login-brand.shimmer em { -webkit-text-fill-color: transparent; color: transparent; }
@keyframes brandShimmer { 0% { background-position: 130% 0; } 100% { background-position: -30% 0; } }
.login-lawyer { font-family:var(--serif); font-size:13.5px; color:var(--brass-600); margin-top:2px; margin-bottom:10px; letter-spacing:.01em; }

/* ===== Mobilni proporci besedila (telefon) ===== */
@media (max-width: 600px) {
  .synth-body { padding: 16px 16px 18px; }
  .synth-md { font-size: 14px; line-height: 1.55; }
  .synth-md h1 { font-size: 19px; margin: 2px 0 8px; }
  .synth-md h2 { font-size: 16.5px; margin: 14px 0 5px; }
  .synth-md h3 { font-size: 14.5px; margin: 11px 0 4px; }
  .synth-md p { margin: 6px 0; }
  .synth-md ul, .synth-md ol { margin: 6px 0; padding-left: 18px; }
  .synth-md li { margin: 3px 0; }
  .chat-bubble { padding: 12px 14px; margin: 4px 0 12px; }
  .chat-body { font-size: 14px; line-height: 1.5; }
  .ps-detail-body { font-size: 13.5px; line-height: 1.5; }
  .thread-inner { padding-left: 12px; padding-right: 12px; }
}
