@import url('https://fonts.googleapis.com/css2?family=IBM+Plex+Mono:wght@400;500&display=swap');

*, ::before, ::after{
  --tw-border-spacing-x: 0;
  --tw-border-spacing-y: 0;
  --tw-translate-x: 0;
  --tw-translate-y: 0;
  --tw-rotate: 0;
  --tw-skew-x: 0;
  --tw-skew-y: 0;
  --tw-scale-x: 1;
  --tw-scale-y: 1;
  --tw-pan-x:  ;
  --tw-pan-y:  ;
  --tw-pinch-zoom:  ;
  --tw-scroll-snap-strictness: proximity;
  --tw-gradient-from-position:  ;
  --tw-gradient-via-position:  ;
  --tw-gradient-to-position:  ;
  --tw-ordinal:  ;
  --tw-slashed-zero:  ;
  --tw-numeric-figure:  ;
  --tw-numeric-spacing:  ;
  --tw-numeric-fraction:  ;
  --tw-ring-inset:  ;
  --tw-ring-offset-width: 0px;
  --tw-ring-offset-color: #fff;
  --tw-ring-color: rgb(59 130 246 / 0.5);
  --tw-ring-offset-shadow: 0 0 #0000;
  --tw-ring-shadow: 0 0 #0000;
  --tw-shadow: 0 0 #0000;
  --tw-shadow-colored: 0 0 #0000;
  --tw-blur:  ;
  --tw-brightness:  ;
  --tw-contrast:  ;
  --tw-grayscale:  ;
  --tw-hue-rotate:  ;
  --tw-invert:  ;
  --tw-saturate:  ;
  --tw-sepia:  ;
  --tw-drop-shadow:  ;
  --tw-backdrop-blur:  ;
  --tw-backdrop-brightness:  ;
  --tw-backdrop-contrast:  ;
  --tw-backdrop-grayscale:  ;
  --tw-backdrop-hue-rotate:  ;
  --tw-backdrop-invert:  ;
  --tw-backdrop-opacity:  ;
  --tw-backdrop-saturate:  ;
  --tw-backdrop-sepia:  ;
  --tw-contain-size:  ;
  --tw-contain-layout:  ;
  --tw-contain-paint:  ;
  --tw-contain-style:  ;
}

::backdrop{
  --tw-border-spacing-x: 0;
  --tw-border-spacing-y: 0;
  --tw-translate-x: 0;
  --tw-translate-y: 0;
  --tw-rotate: 0;
  --tw-skew-x: 0;
  --tw-skew-y: 0;
  --tw-scale-x: 1;
  --tw-scale-y: 1;
  --tw-pan-x:  ;
  --tw-pan-y:  ;
  --tw-pinch-zoom:  ;
  --tw-scroll-snap-strictness: proximity;
  --tw-gradient-from-position:  ;
  --tw-gradient-via-position:  ;
  --tw-gradient-to-position:  ;
  --tw-ordinal:  ;
  --tw-slashed-zero:  ;
  --tw-numeric-figure:  ;
  --tw-numeric-spacing:  ;
  --tw-numeric-fraction:  ;
  --tw-ring-inset:  ;
  --tw-ring-offset-width: 0px;
  --tw-ring-offset-color: #fff;
  --tw-ring-color: rgb(59 130 246 / 0.5);
  --tw-ring-offset-shadow: 0 0 #0000;
  --tw-ring-shadow: 0 0 #0000;
  --tw-shadow: 0 0 #0000;
  --tw-shadow-colored: 0 0 #0000;
  --tw-blur:  ;
  --tw-brightness:  ;
  --tw-contrast:  ;
  --tw-grayscale:  ;
  --tw-hue-rotate:  ;
  --tw-invert:  ;
  --tw-saturate:  ;
  --tw-sepia:  ;
  --tw-drop-shadow:  ;
  --tw-backdrop-blur:  ;
  --tw-backdrop-brightness:  ;
  --tw-backdrop-contrast:  ;
  --tw-backdrop-grayscale:  ;
  --tw-backdrop-hue-rotate:  ;
  --tw-backdrop-invert:  ;
  --tw-backdrop-opacity:  ;
  --tw-backdrop-saturate:  ;
  --tw-backdrop-sepia:  ;
  --tw-contain-size:  ;
  --tw-contain-layout:  ;
  --tw-contain-paint:  ;
  --tw-contain-style:  ;
}

/*
! tailwindcss v3.4.19 | MIT License | https://tailwindcss.com
*/

/*
1. Prevent padding and border from affecting element width. (https://github.com/mozdevs/cssremedy/issues/4)
2. Allow adding a border to an element by just adding a border-width. (https://github.com/tailwindcss/tailwindcss/pull/116)
*/

*,
::before,
::after {
  box-sizing: border-box;
  /* 1 */
  border-width: 0;
  /* 2 */
  border-style: solid;
  /* 2 */
  border-color: #e5e7eb;
  /* 2 */
}

::before,
::after {
  --tw-content: '';
}

/*
1. Use a consistent sensible line-height in all browsers.
2. Prevent adjustments of font size after orientation changes in iOS.
3. Use a more readable tab size.
4. Use the user's configured `sans` font-family by default.
5. Use the user's configured `sans` font-feature-settings by default.
6. Use the user's configured `sans` font-variation-settings by default.
7. Disable tap highlights on iOS
*/

html,
:host {
  line-height: 1.5;
  /* 1 */
  -webkit-text-size-adjust: 100%;
  /* 2 */
  -moz-tab-size: 4;
  /* 3 */
  -o-tab-size: 4;
     tab-size: 4;
  /* 3 */
  font-family: ui-sans-serif, system-ui, sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol", "Noto Color Emoji";
  /* 4 */
  font-feature-settings: normal;
  /* 5 */
  font-variation-settings: normal;
  /* 6 */
  -webkit-tap-highlight-color: transparent;
  /* 7 */
}

/*
1. Remove the margin in all browsers.
2. Inherit line-height from `html` so users can set them as a class directly on the `html` element.
*/

body {
  margin: 0;
  /* 1 */
  line-height: inherit;
  /* 2 */
}

/*
1. Add the correct height in Firefox.
2. Correct the inheritance of border color in Firefox. (https://bugzilla.mozilla.org/show_bug.cgi?id=190655)
3. Ensure horizontal rules are visible by default.
*/

hr {
  height: 0;
  /* 1 */
  color: inherit;
  /* 2 */
  border-top-width: 1px;
  /* 3 */
}

/*
Add the correct text decoration in Chrome, Edge, and Safari.
*/

abbr:where([title]) {
  -webkit-text-decoration: underline dotted;
          text-decoration: underline dotted;
}

/*
Remove the default font size and weight for headings.
*/

h1,
h2,
h3,
h4,
h5,
h6 {
  font-size: inherit;
  font-weight: inherit;
}

/*
Reset links to optimize for opt-in styling instead of opt-out.
*/

a {
  color: inherit;
  text-decoration: inherit;
}

/*
Add the correct font weight in Edge and Safari.
*/

b,
strong {
  font-weight: bolder;
}

/*
1. Use the user's configured `mono` font-family by default.
2. Use the user's configured `mono` font-feature-settings by default.
3. Use the user's configured `mono` font-variation-settings by default.
4. Correct the odd `em` font sizing in all browsers.
*/

code,
kbd,
samp,
pre {
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
  /* 1 */
  font-feature-settings: normal;
  /* 2 */
  font-variation-settings: normal;
  /* 3 */
  font-size: 1em;
  /* 4 */
}

/*
Add the correct font size in all browsers.
*/

small {
  font-size: 80%;
}

/*
Prevent `sub` and `sup` elements from affecting the line height in all browsers.
*/

sub,
sup {
  font-size: 75%;
  line-height: 0;
  position: relative;
  vertical-align: baseline;
}

sub {
  bottom: -0.25em;
}

sup {
  top: -0.5em;
}

/*
1. Remove text indentation from table contents in Chrome and Safari. (https://bugs.chromium.org/p/chromium/issues/detail?id=999088, https://bugs.webkit.org/show_bug.cgi?id=201297)
2. Correct table border color inheritance in all Chrome and Safari. (https://bugs.chromium.org/p/chromium/issues/detail?id=935729, https://bugs.webkit.org/show_bug.cgi?id=195016)
3. Remove gaps between table borders by default.
*/

table {
  text-indent: 0;
  /* 1 */
  border-color: inherit;
  /* 2 */
  border-collapse: collapse;
  /* 3 */
}

/*
1. Change the font styles in all browsers.
2. Remove the margin in Firefox and Safari.
3. Remove default padding in all browsers.
*/

button,
input,
optgroup,
select,
textarea {
  font-family: inherit;
  /* 1 */
  font-feature-settings: inherit;
  /* 1 */
  font-variation-settings: inherit;
  /* 1 */
  font-size: 100%;
  /* 1 */
  font-weight: inherit;
  /* 1 */
  line-height: inherit;
  /* 1 */
  letter-spacing: inherit;
  /* 1 */
  color: inherit;
  /* 1 */
  margin: 0;
  /* 2 */
  padding: 0;
  /* 3 */
}

/*
Remove the inheritance of text transform in Edge and Firefox.
*/

button,
select {
  text-transform: none;
}

/*
1. Correct the inability to style clickable types in iOS and Safari.
2. Remove default button styles.
*/

button,
input:where([type='button']),
input:where([type='reset']),
input:where([type='submit']) {
  -webkit-appearance: button;
  /* 1 */
  background-color: transparent;
  /* 2 */
  background-image: none;
  /* 2 */
}

/*
Use the modern Firefox focus style for all focusable elements.
*/

:-moz-focusring {
  outline: auto;
}

/*
Remove the additional `:invalid` styles in Firefox. (https://github.com/mozilla/gecko-dev/blob/2f9eacd9d3d995c937b4251a5557d95d494c9be1/layout/style/res/forms.css#L728-L737)
*/

:-moz-ui-invalid {
  box-shadow: none;
}

/*
Add the correct vertical alignment in Chrome and Firefox.
*/

progress {
  vertical-align: baseline;
}

/*
Correct the cursor style of increment and decrement buttons in Safari.
*/

::-webkit-inner-spin-button,
::-webkit-outer-spin-button {
  height: auto;
}

/*
1. Correct the odd appearance in Chrome and Safari.
2. Correct the outline style in Safari.
*/

[type='search'] {
  -webkit-appearance: textfield;
  /* 1 */
  outline-offset: -2px;
  /* 2 */
}

/*
Remove the inner padding in Chrome and Safari on macOS.
*/

::-webkit-search-decoration {
  -webkit-appearance: none;
}

/*
1. Correct the inability to style clickable types in iOS and Safari.
2. Change font properties to `inherit` in Safari.
*/

::-webkit-file-upload-button {
  -webkit-appearance: button;
  /* 1 */
  font: inherit;
  /* 2 */
}

/*
Add the correct display in Chrome and Safari.
*/

summary {
  display: list-item;
}

/*
Removes the default spacing and border for appropriate elements.
*/

blockquote,
dl,
dd,
h1,
h2,
h3,
h4,
h5,
h6,
hr,
figure,
p,
pre {
  margin: 0;
}

fieldset {
  margin: 0;
  padding: 0;
}

legend {
  padding: 0;
}

ol,
ul,
menu {
  list-style: none;
  margin: 0;
  padding: 0;
}

/*
Reset default styling for dialogs.
*/

dialog {
  padding: 0;
}

/*
Prevent resizing textareas horizontally by default.
*/

textarea {
  resize: vertical;
}

/*
1. Reset the default placeholder opacity in Firefox. (https://github.com/tailwindlabs/tailwindcss/issues/3300)
2. Set the default placeholder color to the user's configured gray 400 color.
*/

input::-moz-placeholder, textarea::-moz-placeholder {
  opacity: 1;
  /* 1 */
  color: #9ca3af;
  /* 2 */
}

input::placeholder,
textarea::placeholder {
  opacity: 1;
  /* 1 */
  color: #9ca3af;
  /* 2 */
}

/*
Set the default cursor for buttons.
*/

button,
[role="button"] {
  cursor: pointer;
}

/*
Make sure disabled buttons don't get the pointer cursor.
*/

:disabled {
  cursor: default;
}

/*
1. Make replaced elements `display: block` by default. (https://github.com/mozdevs/cssremedy/issues/14)
2. Add `vertical-align: middle` to align replaced elements more sensibly by default. (https://github.com/jensimmons/cssremedy/issues/14#issuecomment-634934210)
   This can trigger a poorly considered lint error in some tools but is included by design.
*/

img,
svg,
video,
canvas,
audio,
iframe,
embed,
object {
  display: block;
  /* 1 */
  vertical-align: middle;
  /* 2 */
}

/*
Constrain images and videos to the parent width and preserve their intrinsic aspect ratio. (https://github.com/mozdevs/cssremedy/issues/14)
*/

img,
video {
  max-width: 100%;
  height: auto;
}

/* Make elements with the HTML hidden attribute stay hidden by default */

[hidden]:where(:not([hidden="until-found"])) {
  display: none;
}

html {
  font-size: 12px;
}

body {
  font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  font-size: 1rem;
  background: radial-gradient(1200px 700px at 15% 0%, #f8fafc 0%, #f3f4f6 45%, #eef2f7 100%);
  color: #0f172a;
}

code,
  pre,
  .mono {
  font-family: 'IBM Plex Mono', ui-monospace, SFMono-Regular, Menlo, monospace;
}

.container{
  width: 100%;
}

@media (min-width: 640px){
  .container{
    max-width: 640px;
  }
}

@media (min-width: 768px){
  .container{
    max-width: 768px;
  }
}

@media (min-width: 1024px){
  .container{
    max-width: 1024px;
  }
}

@media (min-width: 1280px){
  .container{
    max-width: 1280px;
  }
}

@media (min-width: 1536px){
  .container{
    max-width: 1536px;
  }
}

.sr-only{
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border-width: 0;
}

.\!visible{
  visibility: visible !important;
}

.visible{
  visibility: visible;
}

.fixed{
  position: fixed;
}

.m-0{
  margin: 0px;
}

.mb-1{
  margin-bottom: 0.25rem;
}

.mb-2{
  margin-bottom: 0.5rem;
}

.mb-3{
  margin-bottom: 0.75rem;
}

.mt-3{
  margin-top: 0.75rem;
}

.block{
  display: block;
}

.flex{
  display: flex;
}

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

.table{
  display: table;
}

.grid{
  display: grid;
}

.hidden{
  display: none;
}

.h-5{
  height: 1.25rem;
}

.h-\[14px\]{
  height: 14px;
}

.max-h-56{
  max-height: 14rem;
}

.min-h-5{
  min-height: 1.25rem;
}

.min-h-\[calc\(100vh-40px\)\]{
  min-height: calc(100vh - 40px);
}

.w-5{
  width: 1.25rem;
}

.w-\[14px\]{
  width: 14px;
}

.w-full{
  width: 100%;
}

.min-w-0{
  min-width: 0px;
}

.max-w-\[400px\]{
  max-width: 400px;
}

.flex-1{
  flex: 1 1 0%;
}

.transform{
  transform: translate(var(--tw-translate-x), var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y));
}

.resize{
  resize: both;
}

.flex-col{
  flex-direction: column;
}

.flex-wrap{
  flex-wrap: wrap;
}

.items-center{
  align-items: center;
}

.justify-center{
  justify-content: center;
}

.justify-between{
  justify-content: space-between;
}

.gap-0\.5{
  gap: 0.125rem;
}

.gap-1{
  gap: 0.25rem;
}

.gap-2{
  gap: 0.5rem;
}

.overflow-auto{
  overflow: auto;
}

.truncate{
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.rounded{
  border-radius: 0.25rem;
}

.rounded-full{
  border-radius: 9999px;
}

.rounded-xl{
  border-radius: 0.75rem;
}

.border{
  border-width: 1px;
}

.border-t{
  border-top-width: 1px;
}

.border-blue-200\/30{
  border-color: rgb(191 219 254 / 0.3);
}

.border-slate-100{
  --tw-border-opacity: 1;
  border-color: rgb(241 245 249 / var(--tw-border-opacity, 1));
}

.border-slate-200{
  --tw-border-opacity: 1;
  border-color: rgb(226 232 240 / var(--tw-border-opacity, 1));
}

.border-slate-200\/20{
  border-color: rgb(226 232 240 / 0.2);
}

.bg-white{
  --tw-bg-opacity: 1;
  background-color: rgb(255 255 255 / var(--tw-bg-opacity, 1));
}

.p-0{
  padding: 0px;
}

.p-2{
  padding: 0.5rem;
}

.p-6{
  padding: 1.5rem;
}

.px-1\.5{
  padding-left: 0.375rem;
  padding-right: 0.375rem;
}

.py-0\.5{
  padding-top: 0.125rem;
  padding-bottom: 0.125rem;
}

.pt-1{
  padding-top: 0.25rem;
}

.text-\[10px\]{
  font-size: 10px;
}

.text-\[9px\]{
  font-size: 9px;
}

.text-sm{
  font-size: 0.875rem;
  line-height: 1.25rem;
}

.font-medium{
  font-weight: 500;
}

.font-semibold{
  font-weight: 600;
}

.leading-5{
  line-height: 1.25rem;
}

.text-blue-600{
  --tw-text-opacity: 1;
  color: rgb(37 99 235 / var(--tw-text-opacity, 1));
}

.text-slate-400{
  --tw-text-opacity: 1;
  color: rgb(148 163 184 / var(--tw-text-opacity, 1));
}

.text-slate-500{
  --tw-text-opacity: 1;
  color: rgb(100 116 139 / var(--tw-text-opacity, 1));
}

.text-slate-600{
  --tw-text-opacity: 1;
  color: rgb(71 85 105 / var(--tw-text-opacity, 1));
}

.text-slate-700{
  --tw-text-opacity: 1;
  color: rgb(51 65 85 / var(--tw-text-opacity, 1));
}

.text-slate-800{
  --tw-text-opacity: 1;
  color: rgb(30 41 59 / var(--tw-text-opacity, 1));
}

.shadow-none{
  --tw-shadow: 0 0 #0000;
  --tw-shadow-colored: 0 0 #0000;
  box-shadow: var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow);
}

.shadow-sm{
  --tw-shadow: 0 1px 2px 0 rgb(0 0 0 / 0.05);
  --tw-shadow-colored: 0 1px 2px 0 var(--tw-shadow-color);
  box-shadow: var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow);
}

.blur{
  --tw-blur: blur(8px);
  filter: var(--tw-blur) var(--tw-brightness) var(--tw-contrast) var(--tw-grayscale) var(--tw-hue-rotate) var(--tw-invert) var(--tw-saturate) var(--tw-sepia) var(--tw-drop-shadow);
}

.filter{
  filter: var(--tw-blur) var(--tw-brightness) var(--tw-contrast) var(--tw-grayscale) var(--tw-hue-rotate) var(--tw-invert) var(--tw-saturate) var(--tw-sepia) var(--tw-drop-shadow);
}

.ca-shell {
  padding: 0;
  min-height: 100vh;
  display: block;
}

.ca-window {
  width: 100vw;
  min-height: 100vh;
  border-radius: 0;
  background: #ffffff;
  box-shadow: none;
  overflow: hidden;
  border: 0;
}

.ca-titlebar {
  position: sticky;
  top: 0;
  z-index: 30;
  height: 44px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 0.6rem;
  padding: 0 0.9rem;
  background: rgba(255, 255, 255, 0.85);
  -webkit-backdrop-filter: blur(10px);
          backdrop-filter: blur(10px);
  border-bottom: 1px solid rgba(148, 163, 184, 0.28);
}

.ca-titlebar-left {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
}

.ca-dot {
  width: 12px;
  height: 12px;
  border-radius: 999px;
  box-shadow: inset 0 0 0 1px rgba(15, 23, 42, 0.12);
}

.ca-dot.is-red {
  background: #ff5f57;
}

.ca-dot.is-yellow {
  background: #ffbd2e;
}

.ca-dot.is-green {
  background: #28c840;
}

.ca-titlebar-center {
  display: inline-flex;
  align-items: baseline;
  justify-content: flex-start;
  gap: 0.5rem;
  min-width: 0;
  /* Ensure the title group is anchored to the left edge of the titlebar cell. */
  justify-self: start;
  width: 100%;
}

.ca-brand {
  font-size: 0.9rem;
  font-weight: 700;
  color: #111827;
  white-space: nowrap;
}

.ca-sep {
  color: rgba(148, 163, 184, 0.9);
  font-size: 0.85rem;
}

.ca-doc-title {
  font-size: 0.88rem;
  font-weight: 600;
  color: #334155;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.ca-titlebar-right {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
}

.ca-diff {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  border: 1px solid rgba(148, 163, 184, 0.35);
  background: rgba(248, 250, 252, 0.8);
  color: #334155;
  border-radius: 999px;
  padding: 0.28rem 0.55rem;
  font-size: 0.75rem;
  font-weight: 650;
  white-space: nowrap;
}

.ca-diff-add {
  color: #16a34a;
  font-weight: 750;
}

.ca-diff-del {
  color: #ef4444;
  font-weight: 750;
}

.ca-pill {
  border: 1px solid rgba(148, 163, 184, 0.35);
  background: rgba(248, 250, 252, 0.8);
  color: #334155;
  border-radius: 999px;
  padding: 0.28rem 0.65rem;
  font-size: 0.75rem;
  font-weight: 650;
  white-space: nowrap;
}

.ca-pill:hover {
  background: rgba(255, 255, 255, 0.9);
}

.ca-pill.is-muted {
  color: #64748b;
}

.ca-pill.has-caret::after {
  content: '▾';
  margin-left: 0.35rem;
  font-size: 0.75em;
  opacity: 0.7;
}

.ca-pill:disabled {
  opacity: 0.7;
  cursor: default;
}

.ca-select {
  border: 1px solid rgba(148, 163, 184, 0.35);
  background: rgba(248, 250, 252, 0.8);
  color: #334155;
  border-radius: 999px;
  padding: 0.28rem 0.55rem;
  font-size: 0.75rem;
  font-weight: 650;
}

.app-layout {
  --sidebar-width: 260px;
  --col-main: 1fr;
  --col-inspector-a: 0.9fr;
  --col-inspector-b: 0.9fr;
  --col-resizer: 1px;
  display: grid;
  grid-template-columns:
    minmax(220px, var(--sidebar-width))
    var(--col-resizer)
    minmax(360px, var(--col-main))
    var(--col-resizer)
    minmax(260px, var(--col-inspector-a))
    var(--col-resizer)
    minmax(260px, var(--col-inspector-b));
  gap: 0;
  align-items: stretch;
}

.app-sidebar {
  min-width: 0;
  max-height: 100%;
  border: 0;
  border-radius: 0;
  background: #f8fafc;
  box-shadow: none;
  border-right: 0;
}

.ca-layout {
  height: calc(100vh - 44px);
  background: #f8fafc;
}

.ca-main {
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 0;
  padding: 0;
  background: #ffffff;
  border-right: 0;
  min-height: 0;
}

.ca-col-main {
  grid-column: 3;
}

body:not(.thread-open) .ca-col-main {
  grid-column: 3;
}

.ca-col-main #connect-inline-slot {
  border-bottom: 1px solid rgba(226, 232, 240, 0.95);
}

.ca-connect-panel {
  width: 100%;
  border: 0;
  border-radius: 0;
  box-shadow: none;
  background: transparent;
  padding: 0.75rem 0.9rem;
  max-width: none;
}

/* Ensure the thread panel fills the main column when visible. */

#thread-panel {
  flex: 1;
}

.inspector-col {
  min-width: 0;
  min-height: 0;
  position: relative;
  display: flex;
  flex-direction: column;
  padding: 0;
  background: #ffffff;
  border-right: 0;
}

.inspector-col.inspector-col-last {
  border-right: 0;
}

.inspector-col.is-disabled {
  opacity: 0.92;
}

.inspector-col.is-disabled .inspector-panel {
  filter: grayscale(0.1);
  opacity: 0.55;
  pointer-events: none;
}

.inspector-empty-overlay {
  position: absolute;
  inset: 0;
  border: 1px dashed rgba(148, 163, 184, 0.55);
  border-radius: 0;
  background: rgba(248, 250, 252, 0.82);
  -webkit-backdrop-filter: blur(6px);
          backdrop-filter: blur(6px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1.2rem;
  color: #64748b;
  font-size: 0.85rem;
  font-weight: 650;
  text-align: center;
}

.inspector-empty-overlay.hidden {
  display: none;
}

/* Inspector is always present on desktop. On small screens we hide it via media query. */

.ca-empty {
  border: 0;
  border-top: 1px solid rgba(226, 232, 240, 0.95);
  background: transparent;
  padding: 0.85rem 0.9rem;
  font-size: 0.82rem;
  color: #64748b;
}

.ca-thread-panel {
  border-radius: 0;
  background: transparent;
  border: 0;
  box-shadow: none;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 0;
  min-height: 0;
}

.ca-thread-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 0.8rem;
  padding: 0.75rem 0.9rem;
  border-bottom: 1px solid rgba(226, 232, 240, 0.95);
}

.ca-thread-header-left {
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
}

.ca-thread-title {
  border: 0;
  outline: none;
  background: transparent;
  font-size: 1.05rem;
  font-weight: 700;
  color: #111827;
  padding: 0.2rem 0.15rem;
}

.ca-thread-id {
  margin: 0;
  font-size: 0.75rem;
  color: #94a3b8;
}

.ca-thread-status {
  font-size: 0.75rem;
  color: #94a3b8;
}

.ca-sidebar {
  padding: 0.7rem;
  display: flex;
  flex-direction: column;
  gap: 0.8rem;
}

.ca-side-nav {
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
}

.ca-nav-item {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  padding: 0.55rem 0.6rem;
  border-radius: 0.9rem;
  border: 0;
  background: transparent;
  color: #334155;
  font-size: 0.85rem;
  font-weight: 600;
  text-decoration: none;
  cursor: pointer;
}

.ca-nav-item:hover {
  background: rgba(255, 255, 255, 0.6);
  color: #111827;
}

.ca-nav-icon {
  width: 20px;
  height: 20px;
  border-radius: 0.55rem;
  background: rgba(255, 255, 255, 0.65);
  position: relative;
  flex-shrink: 0;
}

.ca-nav-icon::before {
  content: '';
  position: absolute;
  inset: 3px;
  background: #64748b;
  -webkit-mask-repeat: no-repeat;
  -webkit-mask-position: center;
  -webkit-mask-size: contain;
  mask-repeat: no-repeat;
  mask-position: center;
  mask-size: contain;
}

.ca-nav-item:hover .ca-nav-icon::before {
  background: #111827;
}

.ca-nav-icon[data-icon='new']::before {
  -webkit-mask-image: url("data:image/svg+xml,%3Csvg%20xmlns%3D%27http%3A//www.w3.org/2000/svg%27%20viewBox%3D%270%200%2024%2024%27%20fill%3D%27black%27%3E%3Cpath%20d%3D%27M11%205a1%201%200%200%201%202%200v6h6a1%201%200%200%201%200%202h-6v6a1%201%200%200%201-2%200v-6H5a1%201%200%200%201%200-2h6V5z%27/%3E%3C/svg%3E");
  mask-image: url("data:image/svg+xml,%3Csvg%20xmlns%3D%27http%3A//www.w3.org/2000/svg%27%20viewBox%3D%270%200%2024%2024%27%20fill%3D%27black%27%3E%3Cpath%20d%3D%27M11%205a1%201%200%200%201%202%200v6h6a1%201%200%200%201%200%202h-6v6a1%201%200%200%201-2%200v-6H5a1%201%200%200%201%200-2h6V5z%27/%3E%3C/svg%3E");
}

.ca-nav-icon[data-icon='automations']::before {
  -webkit-mask-image: url("data:image/svg+xml,%3Csvg%20xmlns%3D%27http%3A//www.w3.org/2000/svg%27%20viewBox%3D%270%200%2024%2024%27%20fill%3D%27black%27%3E%3Cpath%20d%3D%27M12%202a10%2010%200%201%200%2010%2010A10.01%2010.01%200%200%200%2012%202zm1%2011h-2V7h2v6zm0%204h-2v-2h2v2z%27/%3E%3C/svg%3E");
  mask-image: url("data:image/svg+xml,%3Csvg%20xmlns%3D%27http%3A//www.w3.org/2000/svg%27%20viewBox%3D%270%200%2024%2024%27%20fill%3D%27black%27%3E%3Cpath%20d%3D%27M12%202a10%2010%200%201%200%2010%2010A10.01%2010.01%200%200%200%2012%202zm1%2011h-2V7h2v6zm0%204h-2v-2h2v2z%27/%3E%3C/svg%3E");
}

.ca-nav-icon[data-icon='skills']::before {
  -webkit-mask-image: url("data:image/svg+xml,%3Csvg%20xmlns%3D%27http%3A//www.w3.org/2000/svg%27%20viewBox%3D%270%200%2024%2024%27%20fill%3D%27black%27%3E%3Cpath%20d%3D%27M12%202l8%204v6c0%205-3.4%209.4-8%2010-4.6-.6-8-5-8-10V6l8-4zm0%202.2L6%207v5c0%203.9%202.5%207.2%206%207.8%203.5-.6%206-3.9%206-7.8V7l-6-2.8z%27/%3E%3C/svg%3E");
  mask-image: url("data:image/svg+xml,%3Csvg%20xmlns%3D%27http%3A//www.w3.org/2000/svg%27%20viewBox%3D%270%200%2024%2024%27%20fill%3D%27black%27%3E%3Cpath%20d%3D%27M12%202l8%204v6c0%205-3.4%209.4-8%2010-4.6-.6-8-5-8-10V6l8-4zm0%202.2L6%207v5c0%203.9%202.5%207.2%206%207.8%203.5-.6%206-3.9%206-7.8V7l-6-2.8z%27/%3E%3C/svg%3E");
}

.ca-nav-icon[data-icon='settings']::before {
  -webkit-mask-image: url("data:image/svg+xml,%3Csvg%20xmlns%3D%27http%3A//www.w3.org/2000/svg%27%20viewBox%3D%270%200%2024%2024%27%20fill%3D%27black%27%3E%3Cpath%20d%3D%27M19.14%2012.94c.04-.31.06-.63.06-.94s-.02-.63-.06-.94l2.03-1.58a.5.5%200%200%200%20.12-.64l-1.92-3.32a.5.5%200%200%200-.6-.22l-2.39.96c-.5-.38-1.03-.7-1.62-.94l-.36-2.54A.5.5%200%200%200%2014%201h-4a.5.5%200%200%200-.49.42l-.36%202.54c-.59.24-1.13.56-1.62.94l-2.39-.96a.5.5%200%200%200-.6.22L2.72%207.48a.5.5%200%200%200%20.12.64l2.03%201.58c-.04.31-.06.63-.06.94s.02.63.06.94l-2.03%201.58a.5.5%200%200%200-.12.64l1.92%203.32c.13.23.39.32.6.22l2.39-.96c.5.38%201.03.7%201.62.94l.36%202.54c.04.24.25.42.49.42h4c.24%200%20.45-.18.49-.42l.36-2.54c.59-.24%201.13-.56%201.62-.94l2.39.96c.22.09.47%200%20.6-.22l1.92-3.32a.5.5%200%200%200-.12-.64l-2.03-1.58zM12%2015.5A3.5%203.5%200%201%201%2012%208a3.5%203.5%200%200%201%200%207.5z%27/%3E%3C/svg%3E");
  mask-image: url("data:image/svg+xml,%3Csvg%20xmlns%3D%27http%3A//www.w3.org/2000/svg%27%20viewBox%3D%270%200%2024%2024%27%20fill%3D%27black%27%3E%3Cpath%20d%3D%27M19.14%2012.94c.04-.31.06-.63.06-.94s-.02-.63-.06-.94l2.03-1.58a.5.5%200%200%200%20.12-.64l-1.92-3.32a.5.5%200%200%200-.6-.22l-2.39.96c-.5-.38-1.03-.7-1.62-.94l-.36-2.54A.5.5%200%200%200%2014%201h-4a.5.5%200%200%200-.49.42l-.36%202.54c-.59.24-1.13.56-1.62.94l-2.39-.96a.5.5%200%200%200-.6.22L2.72%207.48a.5.5%200%200%200%20.12.64l2.03%201.58c-.04.31-.06.63-.06.94s.02.63.06.94l-2.03%201.58a.5.5%200%200%200-.12.64l1.92%203.32c.13.23.39.32.6.22l2.39-.96c.5.38%201.03.7%201.62.94l.36%202.54c.04.24.25.42.49.42h4c.24%200%20.45-.18.49-.42l.36-2.54c.59-.24%201.13-.56%201.62-.94l2.39.96c.22.09.47%200%20.6-.22l1.92-3.32a.5.5%200%200%200-.12-.64l-2.03-1.58zM12%2015.5A3.5%203.5%200%201%201%2012%208a3.5%203.5%200%200%201%200%207.5z%27/%3E%3C/svg%3E");
}

.ca-side-section {
  min-height: 0;
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
}

.ca-repo-list {
  min-height: 0;
  overflow: auto;
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
  padding-right: 0.1rem;
}

.ca-side-section-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 0.2rem;
}

.ca-side-section-title {
  font-size: 0.8rem;
  color: #6b7280;
  font-weight: 700;
}

.ca-icon-button {
  width: 26px;
  height: 26px;
  border-radius: 0.65rem;
  border: 1px solid rgba(148, 163, 184, 0.35);
  background: rgba(255, 255, 255, 0.7);
  color: #64748b;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.ca-icon-button svg {
  width: 16px;
  height: 16px;
}

.ca-thread-filter {
  width: 100%;
  border-radius: 0.95rem;
  border: 1px solid rgba(148, 163, 184, 0.35);
  background: rgba(255, 255, 255, 0.7);
  padding: 0.5rem 0.7rem;
  font-size: 0.8rem;
  color: #334155;
  outline: none;
}

.ca-thread-filter::-moz-placeholder {
  color: #94a3b8;
}

.ca-thread-filter::placeholder {
  color: #94a3b8;
}

.ca-side-footer {
  margin-top: auto;
}

.ca-thread-leading {
  color: #9ca3af;
  margin-right: 0.35rem;
}

.ca-thread-label {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.ca-thread-age {
  color: #9ca3af;
  font-size: 0.75rem;
}

.ca-thread-right {
  margin-left: auto;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  flex-shrink: 0;
}

.ca-thread-diff {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  border: 1px solid rgba(148, 163, 184, 0.28);
  background: rgba(255, 255, 255, 0.7);
  border-radius: 999px;
  padding: 0.18rem 0.45rem;
  font-size: 0.72rem;
  font-weight: 700;
  color: #334155;
}

.ca-thread-diff-add {
  color: #16a34a;
}

.ca-thread-diff-del {
  color: #ef4444;
}

.ca-repo-icon {
  width: 18px;
  height: 18px;
  border-radius: 0.55rem;
  background: rgba(255, 255, 255, 0.65);
  position: relative;
  flex-shrink: 0;
}

.ca-repo-icon::before {
  content: '';
  position: absolute;
  inset: 3px;
  background: #64748b;
  -webkit-mask-repeat: no-repeat;
  -webkit-mask-position: center;
  -webkit-mask-size: contain;
  mask-repeat: no-repeat;
  mask-position: center;
  mask-size: contain;
  -webkit-mask-image: url("data:image/svg+xml,%3Csvg%20xmlns%3D%27http%3A//www.w3.org/2000/svg%27%20viewBox%3D%270%200%2024%2024%27%20fill%3D%27black%27%3E%3Cpath%20d%3D%27M10%204l2%202h8c1.1%200%202%20.9%202%202v10c0%201.1-.9%202-2%202H4c-1.1%200-2-.9-2-2V6c0-1.1.9-2%202-2h6z%27/%3E%3C/svg%3E");
  mask-image: url("data:image/svg+xml,%3Csvg%20xmlns%3D%27http%3A//www.w3.org/2000/svg%27%20viewBox%3D%270%200%2024%2024%27%20fill%3D%27black%27%3E%3Cpath%20d%3D%27M10%204l2%202h8c1.1%200%202%20.9%202%202v10c0%201.1-.9%202-2%202H4c-1.1%200-2-.9-2-2V6c0-1.1.9-2%202-2h6z%27/%3E%3C/svg%3E");
}

.ca-repo-block {
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
  padding: 0.1rem 0.1rem 0.25rem;
  border-radius: 1rem;
}

.ca-repo-block.is-target {
  background: rgba(255, 255, 255, 0.55);
  box-shadow: inset 0 0 0 1px rgba(148, 163, 184, 0.18);
}

.ca-repo-toggle {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  padding: 0.45rem 0.55rem;
  border: 0;
  background: transparent;
  border-radius: 0.95rem;
  cursor: pointer;
  color: #475569;
}

.ca-repo-toggle:hover {
  background: rgba(255, 255, 255, 0.65);
  color: #0f172a;
}

.ca-repo-toggle.is-target {
  background: rgba(255, 255, 255, 0.7);
  color: #0f172a;
}

.ca-repo-left {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  min-width: 0;
}

.ca-caret {
  width: 14px;
  text-align: center;
  color: #9ca3af;
  font-size: 0.8rem;
  flex-shrink: 0;
}

.ca-repo-name {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 0.82rem;
  font-weight: 650;
}

.ca-repo-right {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  flex-shrink: 0;
}

.ca-repo-count {
  font-size: 0.72rem;
  color: #9ca3af;
}

.ca-repo-add {
  width: 22px;
  height: 22px;
  border-radius: 999px;
  border: 1px solid rgba(148, 163, 184, 0.28);
  background: rgba(255, 255, 255, 0.75);
  color: #334155;
  font-size: 0.8rem;
  font-weight: 800;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
}

.ca-repo-add:hover {
  background: rgba(255, 255, 255, 0.95);
}

.ca-thread-list {
  display: flex;
  flex-direction: column;
  gap: 0.12rem;
  padding: 0.1rem 0.1rem 0.2rem 1.25rem;
}

.ca-thread-empty {
  padding: 0.2rem 0.6rem 0.35rem 1.25rem;
  font-size: 0.75rem;
  color: #94a3b8;
}

.ca-thread-row {
  display: flex;
  align-items: center;
  gap: 0.35rem;
}

.ca-thread-button {
  flex: 1;
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  border: 0;
  background: transparent;
  color: #475569;
  font-size: 0.82rem;
  padding: 0.38rem 0.55rem;
  border-radius: 0.95rem;
  cursor: pointer;
}

.ca-thread-button:hover {
  background: rgba(255, 255, 255, 0.65);
  color: #0f172a;
}

.ca-thread-button.is-active {
  background: rgba(17, 24, 39, 0.09);
  color: #0f172a;
}

.ca-thread-leading {
  width: 8px;
  height: 8px;
  border-radius: 999px;
  background: #cbd5e1;
  flex-shrink: 0;
}

.ca-thread-button.is-active .ca-thread-leading {
  background: #111827;
}

.ca-thread-delete {
  opacity: 0;
  pointer-events: none;
  border: 1px solid rgba(148, 163, 184, 0.28);
  background: rgba(255, 255, 255, 0.7);
  border-radius: 0.85rem;
  padding: 0.22rem 0.45rem;
  font-size: 0.72rem;
  color: #64748b;
  cursor: pointer;
  flex-shrink: 0;
}

.ca-thread-row:hover .ca-thread-delete {
  opacity: 1;
  pointer-events: auto;
}

.ca-thread-delete:hover {
  background: rgba(255, 255, 255, 0.95);
  color: #0f172a;
}

.sidebar-resizer {
  position: relative;
  width: var(--col-resizer);
  cursor: col-resize;
  align-self: stretch;
  background: rgba(226, 232, 240, 0.95);
  border: 0;
  transition: opacity 120ms ease;
}

.sidebar-resizer::after {
  content: none;
}

.sidebar-resizer:hover {
  opacity: 1;
}

.sidebar-resizer:hover::after {
  background: #94a3b8;
}

.sidebar-resizer:focus-visible {
  outline: 2px solid #1e293b;
  outline-offset: 2px;
}

body.sidebar-resizing,
body.sidebar-resizing * {
  -webkit-user-select: none;
     -moz-user-select: none;
          user-select: none;
  cursor: col-resize !important;
}

.col-resizer {
  position: relative;
  width: var(--col-resizer);
  cursor: col-resize;
  align-self: stretch;
  background: rgba(226, 232, 240, 0.95);
  border: 0;
}

/* Make the hit area wider without changing the visual divider thickness. */

.sidebar-resizer::before,
.col-resizer::before {
  content: '';
  position: absolute;
  top: 0;
  bottom: 0;
  left: -6px;
  width: 13px;
  background: transparent;
}

body.columns-resizing,
body.columns-resizing * {
  -webkit-user-select: none;
     -moz-user-select: none;
          user-select: none;
  cursor: col-resize !important;
}

.icon-action {
  width: 1.85rem;
  height: 1.85rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0;
}

.icon-action svg {
  width: 1rem;
  height: 1rem;
}

.thread-picker-overlay {
  position: fixed;
  inset: 0;
  background: rgba(15, 23, 42, 0.42);
  z-index: 940;
}

.thread-picker-modal {
  position: fixed;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  width: min(520px, calc(100vw - 1rem));
  max-height: min(78vh, 720px);
  z-index: 950;
  border: 1px solid #cbd5e1;
  border-radius: 0.8rem;
  background: #ffffff;
  box-shadow: 0 20px 40px rgba(15, 23, 42, 0.3);
  padding: 0.75rem;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.thread-picker-modal.hidden,
.thread-picker-modal[aria-hidden='true'] {
  display: none;
}

.thread-picker-modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
}

.thread-picker-upload-frame {
  border: 1px dashed #cbd5e1;
  border-radius: 0.7rem;
  padding: 0.55rem;
  background:
    linear-gradient(180deg, rgba(248, 250, 252, 0.95) 0%, rgba(241, 245, 249, 0.95) 100%);
  display: flex;
  flex-direction: column;
  gap: 0.45rem;
}

.thread-picker-upload-head {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  font-size: 0.88rem;
  line-height: 1.3;
}

.thread-picker-upload-icon {
  width: 1.8rem;
  height: 1.8rem;
  border-radius: 0.4rem;
  border: 1px solid #cbd5e1;
  background: #fff;
  color: #64748b;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.thread-picker-upload-icon svg {
  width: 1.05rem;
  height: 1.05rem;
}

.thread-picker-path {
  border: 1px solid #e2e8f0;
  border-radius: 0.5rem;
  padding: 0.52rem 0.62rem;
  background: #f8fafc;
  display: flex;
  align-items: center;
  gap: 0.22rem;
  overflow-x: auto;
  white-space: nowrap;
  min-height: 2.35rem;
}

.thread-picker-crumb {
  border: 0;
  background: transparent;
  color: #334155;
  font-size: 0.82rem;
  line-height: 1.2;
  font-weight: 600;
  padding: 0.1rem 0.1rem;
  border-radius: 0.25rem;
}

.thread-picker-crumb:hover {
  background: #e2e8f0;
}

.thread-picker-crumb-sep {
  color: #94a3b8;
  font-size: 0.8rem;
  -webkit-user-select: none;
     -moz-user-select: none;
          user-select: none;
}

.thread-picker-list {
  border: 1px solid #e2e8f0;
  border-radius: 0.5rem;
  padding: 0.25rem;
  background: #fff;
}

.thread-picker-entry {
  width: 100%;
  border: 0;
  background: transparent;
  border-radius: 0.45rem;
  padding: 0.52rem 0.58rem;
  display: flex;
  align-items: center;
  gap: 0.62rem;
  text-align: left;
  color: #475569;
}

.thread-picker-entry:hover {
  background: #f8fafc;
}

.thread-picker-entry.is-selected {
  background: #e2e8f0;
  color: #0f172a;
}

.thread-picker-entry-icon {
  width: 1.52rem;
  height: 1.52rem;
  border-radius: 0.3rem;
  border: 1px solid #cbd5e1;
  background: #fff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.thread-picker-entry-icon svg {
  width: 1rem;
  height: 1rem;
}

.thread-picker-entry-icon.is-dir {
  color: #334155;
}

.thread-picker-entry-icon.is-file {
  color: #64748b;
}

.thread-picker-entry-label {
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 0.05rem;
}

.thread-picker-entry-name {
  font-size: 0.9rem;
  line-height: 1.25;
  color: inherit;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}

.thread-picker-entry-meta {
  font-size: 0.76rem;
  line-height: 1.2;
  color: #94a3b8;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}

.thread-picker-entry.is-selected .thread-picker-entry-meta {
  color: #64748b;
}

body.thread-picker-open {
  overflow: hidden;
}

.muted {
  color: #94a3b8;
  font-size: 0.9rem;
  line-height: 1.5;
}

.text-\[9px\] {
  font-size: 1rem;
  line-height: 1.4;
}

.text-\[10px\] {
  font-size: 1rem;
  line-height: 1.45;
}

.text-\[11px\] {
  font-size: 1rem;
  line-height: 1.5;
}

.text-xs {
  font-size: 1rem;
  line-height: 1.5;
}

.text-sm {
  font-size: 1.05rem;
  line-height: 1.6;
}

.p-1\.5 {
  padding: 0.75rem;
}

.gap-1 {
  gap: 0.5rem;
}

.copy-action {
  min-width: 58px;
  padding: 0.32rem 0.72rem;
  border-radius: 0.48rem;
  border: 1px solid #cbd5e1;
  background: linear-gradient(180deg, #ffffff 0%, #f8fafc 100%);
  color: #334155;
  font-size: 0.78rem;
  font-weight: 600;
  line-height: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.08);
  transition: transform 120ms ease, box-shadow 120ms ease, border-color 120ms ease, color 120ms ease;
}

.copy-action:hover {
  border-color: #94a3b8;
  color: #0f172a;
  box-shadow: 0 2px 7px rgba(15, 23, 42, 0.1);
}

.copy-action:active {
  transform: translateY(1px);
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.08);
}

.copy-action.is-success {
  border-color: #14b8a6;
  color: #0f766e;
}

.copy-action:disabled {
  opacity: 0.85;
  cursor: default;
}

.chat-log {
  border: 0;
  border-radius: 0;
  padding: 0.85rem 0.9rem;
  background: transparent;
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
  overflow: auto;
  height: auto;
  flex: 1;
  min-height: 0;
}

.chat-empty {
  color: #64748b;
  font-size: 0.82rem;
  text-align: center;
  padding: 1.2rem 0.8rem;
}

.chat-row {
  display: flex;
}

.chat-row.user {
  justify-content: flex-end;
}

.chat-row.assistant,
.chat-row.system {
  justify-content: flex-start;
}

.chat-bubble {
  max-width: 95%;
  border-radius: 1.05rem;
  border: 1px solid rgba(148, 163, 184, 0.4);
  padding: 0.65rem 0.85rem;
  text-align: left;
  display: flex;
  flex-direction: column;
  gap: 0.42rem;
  box-shadow: 0 1px 0 rgba(15, 23, 42, 0.04);
  cursor: pointer;
  transition: transform 130ms ease, box-shadow 130ms ease, border-color 130ms ease;
}

.chat-bubble:focus-visible {
  outline: 2px solid rgba(15, 118, 110, 0.8);
  outline-offset: 2px;
}

.chat-bubble:hover {
  transform: none;
  box-shadow: 0 10px 30px rgba(15, 23, 42, 0.08);
  border-color: #94a3b8;
}

.chat-bubble.user {
  background: #111827;
  color: #f9fafb;
  border-color: rgba(17, 24, 39, 0.9);
}

.chat-bubble.assistant {
  background: #ffffff;
  color: #0f172a;
}

.chat-bubble.system {
  background: #f8fafc;
  border-color: rgba(148, 163, 184, 0.4);
  color: #334155;
}

.progress-row .chat-bubble.system {
  background: #eef2ff;
  border-color: #c7d2fe;
  color: #1e1b4b;
}

.progress-row.progress-closed .chat-bubble.system {
  opacity: 0.75;
  filter: saturate(0.8);
}

.progress-row.progress-current .chat-bubble.system {
  box-shadow: 0 10px 24px rgba(15, 23, 42, 0.12);
  border-color: #818cf8;
}

.chat-body {
  font-size: 0.94rem;
  line-height: 1.55;
  white-space: pre-wrap;
  word-break: break-word;
}

.chat-meta {
  font-size: 0.7rem;
  line-height: 1.2;
  opacity: 0.78;
}

.ca-compose {
  border-radius: 0;
  border: 0;
  border-top: 1px solid rgba(226, 232, 240, 0.95);
  background: #ffffff;
  padding: 0.7rem 0.9rem;
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
  box-shadow: none;
}

.ca-compose-input {
  width: 100%;
  border: 0;
  outline: none;
  resize: none;
  font-size: 0.9rem;
  line-height: 1.45;
  color: #111827;
  background: transparent;
  min-height: 44px;
  max-height: 180px;
  overflow-y: auto;
}

.ca-compose-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
}

.ca-compose-left {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  min-width: 0;
}

.ca-compose-ghost {
  width: 30px;
  height: 30px;
  border-radius: 999px;
  border: 1px solid rgba(148, 163, 184, 0.35);
  background: rgba(248, 250, 252, 0.8);
  color: #334155;
  font-weight: 700;
  line-height: 30px;
  text-align: center;
  cursor: pointer;
}

.ca-compose-model {
  max-width: 260px;
}

.ca-compose-mode {
  border: 1px solid rgba(148, 163, 184, 0.28);
  background: rgba(248, 250, 252, 0.85);
  color: #64748b;
  border-radius: 999px;
  padding: 0.28rem 0.55rem;
  font-size: 0.75rem;
  font-weight: 650;
  white-space: nowrap;
}

.ca-compose-mode.is-remote {
  background: rgba(236, 253, 245, 0.9);
  border-color: rgba(16, 185, 129, 0.28);
  color: #047857;
}

.ca-compose-effort {
  border: 1px solid rgba(148, 163, 184, 0.28);
  background: rgba(248, 250, 252, 0.85);
  color: #475569;
  border-radius: 999px;
  padding: 0.28rem 0.55rem;
  font-size: 0.75rem;
  font-weight: 650;
  white-space: nowrap;
}

.ca-compose-send {
  width: 36px;
  height: 36px;
  border-radius: 999px;
  border: 0;
  background: #111827;
  color: #ffffff;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.ca-compose-send:hover {
  background: #0b1220;
}

.message-detail-overlay {
  position: fixed;
  inset: 0;
  background: rgba(15, 23, 42, 0.45);
  opacity: 0;
  pointer-events: none;
  transition: opacity 150ms ease;
  z-index: 920;
}

.message-detail-modal {
  position: fixed;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -48%);
  width: min(880px, calc(100vw - 1.5rem));
  max-height: min(80vh, 920px);
  border-radius: 0.9rem;
  border: 1px solid #cbd5e1;
  background: #ffffff;
  box-shadow: 0 18px 40px rgba(15, 23, 42, 0.28);
  z-index: 930;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.commit-overlay {
  position: fixed;
  inset: 0;
  background: rgba(15, 23, 42, 0.45);
  opacity: 0;
  pointer-events: none;
  transition: opacity 150ms ease;
  z-index: 952;
}

.commit-modal {
  position: fixed;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -48%);
  width: min(520px, calc(100vw - 1.5rem));
  border-radius: 0.95rem;
  border: 1px solid rgba(148, 163, 184, 0.35);
  background: #ffffff;
  box-shadow: 0 18px 40px rgba(15, 23, 42, 0.28);
  z-index: 954;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.commit-modal.hidden,
.commit-modal[aria-hidden='true'] {
  display: none;
}

.commit-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.6rem;
  padding: 0.7rem 0.85rem;
  border-bottom: 1px solid rgba(148, 163, 184, 0.18);
  background: rgba(248, 250, 252, 0.95);
  font-size: 0.85rem;
  font-weight: 750;
  color: #0f172a;
}

.commit-close {
  border: 1px solid rgba(148, 163, 184, 0.28);
  background: rgba(255, 255, 255, 0.9);
  color: #475569;
  border-radius: 0.85rem;
  padding: 0.25rem 0.55rem;
  font-size: 0.75rem;
  font-weight: 650;
  cursor: pointer;
}

.commit-body {
  padding: 0.85rem;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.commit-label {
  font-size: 0.75rem;
  color: #64748b;
  font-weight: 700;
}

.commit-input {
  width: 100%;
  border-radius: 0.85rem;
  border: 1px solid rgba(148, 163, 184, 0.35);
  background: rgba(255, 255, 255, 0.95);
  padding: 0.55rem 0.7rem;
  font-size: 0.9rem;
  color: #0f172a;
  outline: none;
}

.commit-help {
  margin: 0;
  font-size: 0.74rem;
  color: #94a3b8;
}

.commit-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 0.5rem;
  padding: 0.75rem 0.85rem;
  border-top: 1px solid rgba(148, 163, 184, 0.18);
  background: rgba(248, 250, 252, 0.95);
}

.commit-btn {
  border: 1px solid rgba(148, 163, 184, 0.35);
  background: rgba(255, 255, 255, 0.95);
  color: #334155;
  border-radius: 0.9rem;
  padding: 0.35rem 0.7rem;
  font-size: 0.78rem;
  font-weight: 750;
  cursor: pointer;
}

.commit-btn.primary {
  background: #111827;
  border-color: #111827;
  color: #f8fafc;
}

body.commit-modal-open .commit-overlay {
  opacity: 1;
  pointer-events: auto;
}

body.commit-modal-open {
  overflow: hidden;
}

.settings-overlay {
  position: fixed;
  inset: 0;
  background: rgba(15, 23, 42, 0.45);
  opacity: 0;
  pointer-events: none;
  transition: opacity 150ms ease;
  z-index: 960;
}

.settings-modal {
  position: fixed;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -48%);
  width: min(640px, calc(100vw - 1.2rem));
  max-height: min(82vh, 980px);
  border-radius: 0.95rem;
  border: 1px solid rgba(226, 232, 240, 0.95);
  background: #ffffff;
  box-shadow: 0 18px 40px rgba(15, 23, 42, 0.22);
  z-index: 970;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.settings-modal.hidden,
.settings-modal[aria-hidden='true'] {
  display: none;
}

.settings-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.6rem;
  padding: 0.7rem 0.85rem;
  border-bottom: 1px solid rgba(226, 232, 240, 0.95);
  background: rgba(248, 250, 252, 0.95);
  font-size: 0.85rem;
  font-weight: 750;
  color: #0f172a;
}

.settings-close {
  border: 1px solid rgba(148, 163, 184, 0.28);
  background: rgba(255, 255, 255, 0.9);
  color: #475569;
  border-radius: 0.85rem;
  padding: 0.25rem 0.55rem;
  font-size: 0.75rem;
  font-weight: 650;
  cursor: pointer;
}

.settings-body {
  padding: 0.85rem;
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
  overflow: auto;
}

.settings-section {
  border: 1px solid rgba(226, 232, 240, 0.95);
  border-radius: 0.85rem;
  padding: 0.75rem;
  background: #ffffff;
}

.settings-section-title {
  margin: 0 0 0.55rem 0;
  font-size: 0.82rem;
  font-weight: 800;
  color: #111827;
}

.settings-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.8rem;
}

.settings-label {
  font-size: 0.78rem;
  font-weight: 700;
  color: #334155;
}

.settings-select {
  border: 1px solid rgba(148, 163, 184, 0.35);
  background: rgba(248, 250, 252, 0.85);
  color: #334155;
  border-radius: 0.85rem;
  padding: 0.35rem 0.6rem;
  font-size: 0.78rem;
  font-weight: 650;
  min-width: 150px;
}

.settings-toggle {
  width: 44px;
  height: 22px;
  accent-color: #0f766e;
}

.settings-btn {
  border: 1px solid rgba(148, 163, 184, 0.35);
  background: rgba(255, 255, 255, 0.95);
  color: #334155;
  border-radius: 0.9rem;
  padding: 0.45rem 0.75rem;
  font-size: 0.78rem;
  font-weight: 750;
  cursor: pointer;
}

.settings-btn.danger {
  border-color: rgba(239, 68, 68, 0.35);
  color: #b91c1c;
  background: rgba(254, 242, 242, 0.9);
}

.settings-hint {
  margin: 0.55rem 0 0;
  font-size: 0.74rem;
  color: #64748b;
  line-height: 1.45;
}

body.settings-modal-open .settings-overlay {
  opacity: 1;
  pointer-events: auto;
}

body.settings-modal-open {
  overflow: hidden;
}

.message-detail-modal.hidden,
.message-detail-modal[aria-hidden='true'] {
  display: none;
}

.message-detail-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  padding: 0.75rem 0.85rem;
  border-bottom: 1px solid #e2e8f0;
  background: #f8fafc;
}

#message-detail-title {
  font-size: 0.92rem;
  font-weight: 600;
  color: #0f172a;
}

.message-detail-close {
  border: 1px solid #cbd5e1;
  border-radius: 0.5rem;
  background: #fff;
  color: #334155;
  font-size: 0.78rem;
  font-weight: 600;
  padding: 0.35rem 0.6rem;
}

.message-detail-content {
  margin: 0;
  padding: 0.9rem;
  overflow: auto;
  font-size: 0.76rem;
  line-height: 1.45;
  color: #0f172a;
  background: #ffffff;
  white-space: normal;
  word-break: break-word;
}

.detail-grid {
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
}

.detail-row {
  display: grid;
  grid-template-columns: minmax(110px, 0.33fr) minmax(0, 1fr);
  gap: 0.65rem;
  align-items: start;
  padding: 0.5rem 0;
  border-bottom: 1px solid #e2e8f0;
}

.detail-row:last-child {
  border-bottom: 0;
}

.detail-key {
  font-size: 0.72rem;
  font-weight: 700;
  color: #475569;
  letter-spacing: 0.02em;
  text-transform: none;
}

.detail-value {
  font-size: 0.8rem;
  color: #0f172a;
  line-height: 1.55;
  white-space: pre-wrap;
  word-break: break-word;
}

.detail-value.is-null {
  color: #64748b;
  font-style: italic;
}

.detail-pre {
  margin: 0;
  padding: 0.6rem 0.7rem;
  border: 1px solid #e2e8f0;
  border-radius: 0.6rem;
  background: #f8fafc;
  font-size: 0.76rem;
  line-height: 1.45;
  white-space: pre-wrap;
}

.detail-details {
  border: 1px solid #e2e8f0;
  border-radius: 0.65rem;
  padding: 0.5rem 0.65rem;
  background: #ffffff;
}

.detail-details summary {
  cursor: pointer;
  font-size: 0.76rem;
  font-weight: 700;
  color: #334155;
  outline: none;
}

.detail-details[open] summary {
  margin-bottom: 0.45rem;
}

body.message-detail-modal-open {
  overflow: hidden;
}

body.message-detail-modal-open .message-detail-overlay {
  opacity: 1;
  pointer-events: auto;
}

/* States managed by JS */

body:not(.authenticated) .requires-auth {
  display: none;
}

body.authenticated .login-view {
  display: none;
}

/* connection-panel is now toggled inline (no modal). */

.thread-split {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(340px, 420px);
  gap: 0.65rem;
  align-items: start;
  min-height: 0;
}

.thread-main {
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  min-height: 0;
  flex: 1;
}

.choice-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  align-items: flex-start;
}

.choice-chips.hidden {
  display: none;
}

.choice-chip {
  border: 1px solid #cbd5e1;
  background: rgba(248, 250, 252, 0.9);
  border-radius: 999px;
  padding: 0.28rem 0.65rem;
  font-size: 0.74rem;
  font-weight: 700;
  color: #334155;
  transition: background 120ms ease, border-color 120ms ease, transform 120ms ease;
}

.choice-chip:hover {
  background: #f8fafc;
  border-color: #94a3b8;
}

.choice-chip:active {
  transform: translateY(1px);
}

.ca-inspector-tabs {
  display: none;
}

.ca-pane {
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  gap: 0;
}

.ca-pane-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.6rem;
  padding: 0.6rem 0.75rem;
  border-bottom: 1px solid rgba(148, 163, 184, 0.22);
  background: rgba(248, 250, 252, 0.9);
}

.ca-pane-title {
  font-size: 0.82rem;
  font-weight: 800;
  color: #111827;
}

.ca-pane-actions {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  min-width: 0;
}

.ca-pane-badge {
  border: 1px solid rgba(148, 163, 184, 0.35);
  background: rgba(255, 255, 255, 0.8);
  border-radius: 999px;
  padding: 0.2rem 0.55rem;
  font-size: 0.72rem;
  font-weight: 700;
  color: #334155;
  white-space: nowrap;
}

.ca-pane-badge.is-muted {
  background: rgba(248, 250, 252, 0.8);
  color: #64748b;
}

.ca-files-filter {
  width: min(220px, 38vw);
  border-radius: 999px;
  border: 1px solid rgba(148, 163, 184, 0.35);
  background: rgba(255, 255, 255, 0.85);
  padding: 0.25rem 0.55rem;
  font-size: 0.75rem;
  color: #334155;
  outline: none;
}

.ca-files-filter::-moz-placeholder {
  color: #94a3b8;
}

.ca-files-filter::placeholder {
  color: #94a3b8;
}

.inspector-tabs {
  display: flex;
  align-items: stretch;
  gap: 0;
  border-bottom: 1px solid rgba(148, 163, 184, 0.28);
  background: #f8fafc;
}

.inspector-tab {
  flex: 1;
  border: 0;
  background: transparent;
  padding: 0.5rem 0.4rem;
  font-size: 0.75rem;
  font-weight: 700;
  color: #64748b;
  cursor: pointer;
}

.inspector-tab:hover {
  background: #f8fafc;
  color: #334155;
}

.inspector-tab.is-active {
  background: #f8fafc;
  color: #0f172a;
}

.inspector-panel {
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 0;
  overflow: auto;
  flex: 1;
  min-height: 0;
}

.inspector-panel.ca-pane {
  padding: 0;
  overflow: hidden;
  gap: 0;
}

.inspector-block {
  border: 0;
  border-top: 1px solid rgba(226, 232, 240, 0.95);
  border-radius: 0;
  background: transparent;
  overflow: hidden;
}

.inspector-block-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  padding: 0.55rem 0.75rem;
  border-bottom: 1px solid rgba(226, 232, 240, 0.95);
  background: transparent;
}

/* Sidebar thread list styling (Codex-like) */

.ca-repo-block {
  background: transparent !important;
  border: 0 !important;
  padding: 0.25rem !important;
}

.ca-repo-toggle {
  padding: 0.5rem 0.55rem !important;
  border-radius: 0.85rem !important;
  background: transparent !important;
  color: #334155 !important;
}

.ca-repo-toggle:hover {
  background: rgba(255, 255, 255, 0.55) !important;
}

.ca-thread-list {
  padding: 0.25rem 0.15rem;
}

.ca-thread-row {
  border-radius: 0.85rem;
  padding-right: 0.25rem;
}

.ca-thread-button {
  padding: 0.5rem 0.6rem !important;
  border-radius: 0.85rem !important;
  color: #374151 !important;
  background: transparent !important;
}

.ca-thread-button:hover {
  background: rgba(255, 255, 255, 0.55) !important;
  color: #111827 !important;
}

.ca-thread-button.is-active {
  background: rgba(255, 255, 255, 0.85) !important;
  color: #111827 !important;
  box-shadow: 0 1px 0 rgba(15, 23, 42, 0.06), 0 10px 24px rgba(15, 23, 42, 0.06) !important;
}

.ca-thread-delete {
  opacity: 0;
  pointer-events: none;
  transition: opacity 120ms ease;
}

.ca-thread-row:hover .ca-thread-delete,
.ca-thread-delete:focus-visible {
  opacity: 1;
  pointer-events: auto;
}

.inspector-block-title {
  font-size: 0.75rem;
  font-weight: 800;
  color: #334155;
}

.inspector-block-actions {
  display: flex;
  align-items: center;
  gap: 0.4rem;
}

.inspector-mini {
  border: 1px solid #cbd5e1;
  background: #ffffff;
  color: #334155;
  border-radius: 0.45rem;
  padding: 0.2rem 0.45rem;
  font-size: 0.72rem;
  font-weight: 700;
  transition: background 120ms ease, border-color 120ms ease;
}

.inspector-mini:hover {
  background: #f8fafc;
  border-color: #94a3b8;
}

.inspector-toggle {
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
  font-size: 0.72rem;
  font-weight: 700;
  color: #64748b;
}

.inspector-toggle input {
  transform: translateY(0.5px);
}

.inspector-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: #0f172a;
  color: #f8fafc;
  border-radius: 999px;
  padding: 0.05rem 0.42rem;
  font-size: 0.7rem;
  font-weight: 800;
  line-height: 1.2;
}

.inspector-badge.hidden {
  display: none;
}

.approvals {
  padding: 0.5rem;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.approval-card {
  border: 1px solid #e2e8f0;
  border-radius: 0.65rem;
  background: #ffffff;
  padding: 0.55rem;
  display: flex;
  flex-direction: column;
  gap: 0.45rem;
}

.approval-head {
  display: flex;
  flex-direction: column;
  gap: 0.1rem;
}

.approval-title {
  display: inline-flex;
  align-items: baseline;
  gap: 0.4rem;
  font-size: 0.78rem;
  color: #0f172a;
}

.approval-id {
  font-size: 0.72rem;
  font-weight: 700;
  color: #64748b;
}

.approval-method {
  font-size: 0.72rem;
  color: #475569;
}

.approval-json {
  margin: 0;
  padding: 0.45rem 0.5rem;
  border: 1px solid #e2e8f0;
  border-radius: 0.55rem;
  background: #f8fafc;
  font-size: 0.68rem;
  line-height: 1.35;
  overflow: auto;
  max-height: 120px;
}

.approval-field {
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
}

.approval-field label {
  font-size: 0.72rem;
  font-weight: 700;
  color: #64748b;
}

.approval-field textarea,
.approval-field input {
  border: 1px solid #cbd5e1;
  border-radius: 0.55rem;
  padding: 0.35rem 0.45rem;
  font-size: 0.74rem;
}

.approval-actions {
  display: flex;
  align-items: center;
  gap: 0.35rem;
  flex-wrap: wrap;
}

.approval-btn {
  border: 1px solid #cbd5e1;
  border-radius: 0.55rem;
  padding: 0.28rem 0.6rem;
  font-size: 0.74rem;
  font-weight: 800;
  background: #ffffff;
  color: #334155;
  transition: transform 120ms ease, box-shadow 120ms ease, background 120ms ease, border-color 120ms ease;
}

.approval-btn.primary {
  background: #0f172a;
  color: #f8fafc;
  border-color: #0f172a;
}

.approval-btn.danger {
  background: #ffffff;
  color: #b91c1c;
  border-color: #fecaca;
}

.approval-btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 8px 18px rgba(15, 23, 42, 0.1);
}

.approval-btn:active {
  transform: translateY(1px);
  box-shadow: none;
}

.approval-status {
  font-size: 0.72rem;
  color: #64748b;
}

.git-changes-layout {
  display: grid;
  grid-template-columns: minmax(180px, 0.42fr) minmax(0, 1fr);
  gap: 0;
  padding: 0;
  align-items: stretch;
  height: auto;
  flex: 1;
  min-height: 0;
}

.git-changes-list {
  border: 0;
  border-right: 1px solid rgba(226, 232, 240, 0.95);
  border-radius: 0;
  background: transparent;
  padding: 0.35rem 0.45rem;
  max-height: none;
  overflow: auto;
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.git-empty {
  font-size: 0.74rem;
  color: #94a3b8;
  padding: 0.35rem 0.4rem;
}

.git-change {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  border: 0;
  border-radius: 0.45rem;
  background: transparent;
  padding: 0.35rem 0.45rem;
  font-size: 0.72rem;
  color: #334155;
  text-align: left;
}

.git-status {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 2.2rem;
  height: 1.15rem;
  padding: 0 0.35rem;
  border-radius: 999px;
  font-size: 0.62rem;
  font-weight: 800;
  letter-spacing: 0.02em;
  border: 1px solid rgba(148, 163, 184, 0.35);
  background: #f8fafc;
  color: #475569;
  flex-shrink: 0;
}

.git-change[data-git-status^='A'] .git-status,
.git-change[data-git-status^='??'] .git-status {
  background: #ecfdf5;
  border-color: rgba(16, 185, 129, 0.35);
  color: #047857;
}

.git-change[data-git-status^='M'] .git-status {
  background: #eff6ff;
  border-color: rgba(59, 130, 246, 0.35);
  color: #1d4ed8;
}

.git-change[data-git-status^='D'] .git-status {
  background: #fef2f2;
  border-color: rgba(239, 68, 68, 0.35);
  color: #b91c1c;
}

.git-change[data-git-status^='R'] .git-status,
.git-change[data-git-status^='C'] .git-status {
  background: #f5f3ff;
  border-color: rgba(139, 92, 246, 0.35);
  color: #6d28d9;
}

.git-path {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.git-change:hover {
  background: #f8fafc;
}

.git-change.is-selected {
  background: #e2e8f0;
  border-color: #cbd5e1;
  color: #0f172a;
}

.git-diff {
  margin: 0;
  padding: 0.55rem 0.65rem;
  border: 0;
  border-radius: 0;
  background: transparent;
  max-height: none;
  overflow: auto;
  font-size: 0.68rem;
  line-height: 1.35;
  white-space: pre;
}

.event-log {
  padding: 0.4rem;
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
  max-height: 200px;
  overflow: auto;
}

.event-row {
  border: 1px solid #e2e8f0;
  border-radius: 0.55rem;
  background: #ffffff;
  padding: 0.35rem 0.45rem;
  text-align: left;
  font-size: 0.72rem;
  color: #334155;
  transition: background 120ms ease, border-color 120ms ease;
}

.event-row:hover {
  background: #f8fafc;
  border-color: #cbd5e1;
}

.files-toolbar {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.5rem;
}

.ca-files-toolbar {
  padding: 0.55rem 0.75rem;
  border-bottom: 1px solid rgba(148, 163, 184, 0.18);
  background: rgba(248, 250, 252, 0.7);
}

.files-path {
  flex: 1;
  min-width: 0;
  border: 1px solid #cbd5e1;
  border-radius: 0.55rem;
  padding: 0.3rem 0.45rem;
  font-size: 0.74rem;
  background: #ffffff;
  color: #0f172a;
}

.files-message {
  min-height: 1.1em;
  padding: 0.35rem 0.75rem 0.5rem;
  font-size: 0.72rem;
  color: #64748b;
}

.files-split {
  display: grid;
  grid-template-rows: 160px 1fr;
  gap: 0.5rem;
  padding: 0.5rem;
}

.ca-files-split {
  display: flex;
  flex-direction: column;
  gap: 0;
  padding: 0;
}

.files-list {
  border: 0;
  border-radius: 0;
  background: transparent;
  padding: 0.35rem 0.45rem;
  overflow: auto;
}

.ca-pane-files .files-list {
  border: 0;
  border-radius: 0;
  padding: 0.35rem 0.45rem;
  max-height: 420px;
}

.ca-files-view {
  display: none;
}

.file-row {
  display: flex;
  align-items: center;
  gap: 0.45rem;
  border-radius: 0.45rem;
  padding: 0.32rem 0.4rem;
  cursor: pointer;
  color: #334155;
}

.file-row:hover {
  background: #f8fafc;
}

.file-row.active {
  background: #e2e8f0;
  color: #0f172a;
}

.file-type {
  width: 16px;
  height: 16px;
  border: 0;
  border-radius: 0;
  padding: 0;
  background: #64748b;
  -webkit-mask-repeat: no-repeat;
  -webkit-mask-position: center;
  -webkit-mask-size: contain;
  mask-repeat: no-repeat;
  mask-position: center;
  mask-size: contain;
  flex-shrink: 0;
}

.file-row.dir .file-type {
  background: #64748b;
  -webkit-mask-image: url("data:image/svg+xml,%3Csvg%20xmlns%3D%27http%3A//www.w3.org/2000/svg%27%20viewBox%3D%270%200%2024%2024%27%20fill%3D%27black%27%3E%3Cpath%20d%3D%27M10%204l2%202h8c1.1%200%202%20.9%202%202v10c0%201.1-.9%202-2%202H4c-1.1%200-2-.9-2-2V6c0-1.1.9-2%202-2h6z%27/%3E%3C/svg%3E");
  mask-image: url("data:image/svg+xml,%3Csvg%20xmlns%3D%27http%3A//www.w3.org/2000/svg%27%20viewBox%3D%270%200%2024%2024%27%20fill%3D%27black%27%3E%3Cpath%20d%3D%27M10%204l2%202h8c1.1%200%202%20.9%202%202v10c0%201.1-.9%202-2%202H4c-1.1%200-2-.9-2-2V6c0-1.1.9-2%202-2h6z%27/%3E%3C/svg%3E");
}

.file-row.file .file-type {
  background: #475569;
  -webkit-mask-image: url("data:image/svg+xml,%3Csvg%20xmlns%3D%27http%3A//www.w3.org/2000/svg%27%20viewBox%3D%270%200%2024%2024%27%20fill%3D%27black%27%3E%3Cpath%20d%3D%27M6%202h9l5%205v15c0%201.1-.9%202-2%202H6c-1.1%200-2-.9-2-2V4c0-1.1.9-2%202-2zm8%201v5h5%27/%3E%3C/svg%3E");
  mask-image: url("data:image/svg+xml,%3Csvg%20xmlns%3D%27http%3A//www.w3.org/2000/svg%27%20viewBox%3D%270%200%2024%2024%27%20fill%3D%27black%27%3E%3Cpath%20d%3D%27M6%202h9l5%205v15c0%201.1-.9%202-2%202H6c-1.1%200-2-.9-2-2V4c0-1.1.9-2%202-2zm8%201v5h5%27/%3E%3C/svg%3E");
}

.file-name {
  min-width: 0;
  font-size: 0.74rem;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.files-view {
  border: 0;
  border-radius: 0;
  background: transparent;
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

.files-view-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.4rem;
  padding: 0.4rem 0.5rem;
  border-bottom: 1px solid #e2e8f0;
  background: #f8fafc;
}

.files-current {
  max-width: 170px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 0.68rem;
  color: #334155;
}

.files-view-actions {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
}

.files-content,
.files-diff {
  margin: 0;
  padding: 0.55rem;
  font-size: 0.68rem;
  line-height: 1.35;
  white-space: pre;
  overflow: auto;
}

.files-content {
  max-height: 140px;
}

.files-diff {
  border-top: 1px solid #e2e8f0;
  max-height: 200px;
  background: #ffffff;
}

/* Keep the 4-column (sidebar + main + 2 inspector panes) layout on desktop sizes.
   We only collapse on small screens (see the 640px breakpoint below). */

@media (max-width: 640px) {
  html {
    font-size: 14px;
  }

  .app-layout {
    grid-template-columns: minmax(180px, 56vw) 2px minmax(0, 1fr);
    gap: 0;
  }

  #main-resizer,
  #inspector-resizer,
  #inspector-activity-col,
  #inspector-files-col {
    display: none;
  }

  .sidebar-resizer {
    width: 2px;
  }

  .text-\[9px\] {
    font-size: 0.75rem;
  }

  .text-\[10px\] {
    font-size: 0.8rem;
  }

  .text-\[11px\] {
    font-size: 0.85rem;
  }

  .chat-bubble {
    max-width: 95%;
  }

  .message-detail-modal {
    width: calc(100vw - 0.7rem);
    max-height: 86vh;
  }

  .thread-picker-modal {
    width: calc(100vw - 0.8rem);
    max-height: 86vh;
    padding: 0.6rem;
  }
}

.hover\:bg-slate-50:hover{
  --tw-bg-opacity: 1;
  background-color: rgb(248 250 252 / var(--tw-bg-opacity, 1));
}

.hover\:underline:hover{
  text-decoration-line: underline;
}
